-
Notifications
You must be signed in to change notification settings - Fork 3
Review
Sam Liu edited this page Mar 5, 2021
·
3 revisions
src/components/Review
: holds all components associated with landlord/building reviews.
Review
|
--- Rating
- Takes in a rating as a prop.
- Renders a horizontal list of five heart icons with
rating
corresponding to the number of filled hearts. All remaining hearts are left unfilled.
type Props = {
readonly rating: number;
};
- Takes in info about a review as props.
- Renders a card showing the rating, date, and corresponding text of a review. The rating is rendered with a
Rating
component. - Responsive sizing is supported by
material-ui
's grid layout. On desktop, a vertical list ofReview
components will take up 9/12 of the screen size and resize to take up the full width of the screen on mobile.
type Props = {
readonly overallRating: number;
readonly date: Date;
readonly text: string;
};