Skip to content

Commit

Permalink
mobile: FullReview: add no description message
Browse files Browse the repository at this point in the history
  • Loading branch information
ericswpark committed Apr 21, 2024
1 parent 3cc329c commit 3d1903d
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions mobile/Components/FullReview/FullReview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,13 @@ function FullReview({ route, navigation }) {
</View>
{isSelfReview && <CustomProperties book_id={bookInfo.id} />}
<Divider bold={true} horizontalInset={true} />
<Text style={{ margin: 15, marginTop: 10 }}>
{reviewSWR.data.description}
</Text>
{reviewSWR.data.description ? (
<Text style={{ margin: 15, marginTop: 10 }}>
{reviewSWR.data.description}
</Text>
) : (
<Text style={{margin: 15, color: "gray"}}>This review has no description.</Text>
)}
</ScrollView>
);
}
Expand Down Expand Up @@ -133,7 +137,14 @@ function CustomProperties({ book_id }: { book_id: string }) {

if (properties == null) {
return (
<View style={{ flex: 1, backgroundColor: "white", margin: 30, alignItems: "center" }}>
<View
style={{
flex: 1,
backgroundColor: "white",
margin: 30,
alignItems: "center",
}}
>
<View style={{ flexDirection: "row" }}>
<Text>Loading custom properties... </Text>
<ActivityIndicator />
Expand Down

0 comments on commit 3d1903d

Please sign in to comment.