Skip to content

Commit b791100

Browse files
committed
changed wording and order of comments
1 parent d10cfc4 commit b791100

2 files changed

Lines changed: 22 additions & 19 deletions

File tree

my-app/src/presenters/ReviewPresenter.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ export const ReviewPresenter = observer(({ model, course }) => {
3030
if(!model?.user?.uid)
3131
setErrorMessage("You need to be logged in to post a comment - Posting anonymously is possible.");
3232
else if(reviews.filter((review)=>{return review.uid == model?.user?.uid}).length > 0)
33-
setErrorMessage("Everyone can only post once. Submitting a new comment will override the old one.");
33+
setErrorMessage("Everyone can only post once. Submitting a new comment will replace the old one.");
3434
}
3535
updateError();
3636
}, [reviews, model?.user?.uid]);

my-app/src/views/ReviewView.jsx

Lines changed: 21 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,22 @@ export function ReviewView(props) {
8787
/>
8888
</div>
8989

90+
91+
92+
{/* Professor Rating */}
93+
<div className="text-center">
94+
<p className="font-semibold text-gray-700 text-sm mb-1">
95+
Professor Rating
96+
</p>
97+
<RatingComponent
98+
className="flex gap-1 text-base justify-center"
99+
value={formData.professorRating}
100+
onChange={(val) =>
101+
setFormData({ ...formData, professorRating: val })
102+
}
103+
/>
104+
</div>
105+
90106
{/* Difficulty Rating */}
91107
<div className="relative" ref={difficultyRef}>
92108
<div className="flex items-center justify-center gap-2">
@@ -122,20 +138,6 @@ export function ReviewView(props) {
122138
</div>
123139
</div>
124140

125-
{/* Professor Rating */}
126-
<div className="text-center">
127-
<p className="font-semibold text-gray-700 text-sm mb-1">
128-
Professor Rating
129-
</p>
130-
<RatingComponent
131-
className="flex gap-1 text-base justify-center"
132-
value={formData.professorRating}
133-
onChange={(val) =>
134-
setFormData({ ...formData, professorRating: val })
135-
}
136-
/>
137-
</div>
138-
139141
{/* Grade Section */}
140142
<div className="relative" ref={gradeRef}>
141143
<div className="flex items-center justify-center gap-2">
@@ -348,10 +350,7 @@ export function ReviewView(props) {
348350
<p className="text-sm text-gray-600">N/A</p>
349351
)}
350352
</div>
351-
<div>
352-
<p className="text-sm font-semibold text-gray-700">Difficulty</p>
353-
<p className="text-sm text-gray-600">{mapDifficultyRating(rev.difficultyRating)}</p>
354-
</div>
353+
355354
<div>
356355
<p className="text-sm font-semibold text-gray-700">Professor Rating</p>
357356
{rev.professorRating > 0 ? (
@@ -364,6 +363,10 @@ export function ReviewView(props) {
364363
<p className="text-sm text-gray-600">N/A</p>
365364
)}
366365
</div>
366+
<div>
367+
<p className="text-sm font-semibold text-gray-700">Difficulty</p>
368+
<p className="text-sm text-gray-600">{mapDifficultyRating(rev.difficultyRating)}</p>
369+
</div>
367370
<div>
368371
<p className="text-sm font-semibold text-gray-700">Professor</p>
369372
<p className="text-sm text-gray-600">{rev.professorName || "N/A"}</p>

0 commit comments

Comments
 (0)