From b67849e34b257e735c941b5443f16039ef95f54d Mon Sep 17 00:00:00 2001 From: Meet Shah <128205241+Meetpidev@users.noreply.github.com> Date: Sun, 10 Nov 2024 18:12:48 +0530 Subject: [PATCH] Update show.ejs --- views/show.ejs | 176 +++++++++++++++++-------------------------------- 1 file changed, 61 insertions(+), 115 deletions(-) diff --git a/views/show.ejs b/views/show.ejs index 722fc678..0d0a463c 100644 --- a/views/show.ejs +++ b/views/show.ejs @@ -88,7 +88,16 @@ margin-right: 0.5rem; transition: transform 0.3s ease; } +.review-card { + transition: transform 0.3s ease, box-shadow 0.3s ease; + padding: 0.7rem; +} +@media (max-width: 768px) { + .review-card { + margin-bottom: 20px; /* Adjust spacing for smaller screens */ + } +} #review_logo:hover{ transform: scale(1.2); cursor: pointer; @@ -401,123 +410,60 @@ -
-
- - <% if (list.reviews.length == 0) { %> -
⭐ No review posted yet for this property.
- <% } %> - <% if (list.reviews.length > 0) { %> -

🌟 All Reviews

-
- <% for (let i = 0; i < list.reviews.length; i++) { %> - <% let review = list.reviews[i]; %> -
-
-
-
-

- <% if (review.author && review.author.profilePicture && review.author.profilePicture.purl) { %> - <% - let normalReviewerProfile = review.author.profilePicture.purl; - let lowResReviewerProfile = normalReviewerProfile.replace("/upload", "/upload/q_auto,e_blur:50,w_250,h_250"); - %> - - <% } else { %> - - <% } %> - - <% if (review.author) { %> - <%= review.author.username %> owner - <% } else { %> - Unknown author - <% } %> -

- -
- <% if (currUser && review.author && currUser._id.equals(review.author._id)) { %> -
- -
- <% } %> -
-
- -

- <% for (let j = 1; j <= 5; j++) { %> - <% if (j <= review.rating) { %> - - <% } else { %> - - <% } %> - <% } %> -

- -

- <%= review.Comments.length > 150 ? review.Comments.substring(0, 150) + '... ' : review.Comments %> - <% if (review.Comments.length > 150) { %> - Read more - <% } %> -

- - - Verified by Wanderlust - -
-
- - - - -
- <% } %> - + +
+
+ <% if (list.reviews.length == 0) { %> +
⭐ No review posted yet for this property.
+ <% } %> + <% if (list.reviews.length > 0) { %> +

🌟 All Reviews

+
+ <% for (let i = 0; i < list.reviews.length; i++) { %> + <% let review = list.reviews[i]; %> +
+
+
+
+

+ <% if (review.author && review.author.profilePicture && review.author.profilePicture.purl) { %> + <% let normalReviewerProfile = review.author.profilePicture.purl; %> + + <% } else { %> + + <% } %> + <% if (review.author) { %> + <%= review.author.username %> owner + <% } else { %> + Unknown author + <% } %> +

+
+

+ <% for (let j = 1; j <= 5; j++) { %> + <% if (j <= review.rating) { %> + + <% } else { %> + + <% } %> + <% } %> +

+

+ <%= review.Comments.length > 150 ? review.Comments.substring(0, 150) + '... ' : review.Comments %> + <% if (review.Comments.length > 150) { %> + Read more + <% } %> +

+ + Verified by Wanderlust +
- <% } %> +
+ <% } %> +
+ <% } %> +