1 min read
Write Review
Last Updated - Platform 24.0 - SDK 19.0The Write Review screen presents a form with rating, title, text and more for the user to submit a product review.
Deeplinks
reviews/{product-id}/writereviews/{product-id}/write?listing_id={listing-id}&variant_id={variant-id}
Replace the various {token}
tokens with their specified values.
Ensure that values are properly URL encoded (spaces must be encoded as %20
for example).
Add the is_modal=1
query string to present this view modally (preferable).
Heading
The heading label can be easily customised to better direct the user.
Rating
The rating input view allows the user to tap on a star to select a rating from 1 and 5 inclusive. For accessibility users this view is read as an adjustable view allowing the user to increase or decrease the rating.
The user must select a rating to be able to submit the review.
Container.shared.views.ratingInputView.replace { PoqRatingInputView() }
Title
The title input view is an optional field that allows the user to enter a title for their review.
Text
The write review input view is an optional field that allows the user to enter the main body text of the review. This uses a UITextView rather than a UITextField under the hood.
Name
The name input view is an optional field that allows the user to leave their name against their review.
This may be required by some providers as an email or similar field. This should be easy to customise by customising and injecting a WriteReviewView
.
Recommended
The recommended input view is a boolean input that the user can toggle to indicate if they would recommend the product to others.
This is shown on the Review List screen reviews as a recommended tag.