diff --git a/src/app/(tabs)/search/story.tsx b/src/app/(tabs)/search/story.tsx
index 586748a4..ea49c1be 100644
--- a/src/app/(tabs)/search/story.tsx
+++ b/src/app/(tabs)/search/story.tsx
@@ -14,7 +14,6 @@ import { Button } from 'react-native-paper';
import { SafeAreaView } from 'react-native-safe-area-context';
import jsonStory from '../../../database/story.json';
-import globalStyles from '../../../styles/globalStyles';
function htmlParser(htmlString: string) {
const regexHeading = /(
)/;
@@ -57,7 +56,7 @@ function StoryScreen() {
const [author, setAuthor] = useState(String);
const [genres, setGenres] = useState(['']);
const [image, setImage] = useState(String);
- const ref = React.useRef(null);
+ const scrollRef = React.useRef(null);
// Load Wordpress API and its contents
const getStory = async (id: string) => {
@@ -101,7 +100,7 @@ function StoryScreen() {
};
const scrollUp = () => {
- ref.current?.scrollTo({ x: 0, y: 0 });
+ scrollRef.current?.scrollTo({ x: 0, y: 0 });
};
useEffect(() => {
@@ -113,73 +112,75 @@ function StoryScreen() {
{isLoading ? (
) : (
-
+
-
- {title}
+ {title}
-
-
- By {author}
-
+
+
+ By {author}
+
-
- (
-
- {item}
-
- )}
- />
-
+
+ (
+
+ {item}
+
+ )}
+ />
+ {/* */}
-
-
-
+
{heading}
{story}
-
-
-
-
-
- Author's Process
+
- {process}
+ Author's Process
-
-
- By {author}
-
+ {process}
-
-
-
+
+
+ By {author}
+
+
)}
@@ -201,6 +202,7 @@ const tempStyles = StyleSheet.create({
image: {
width: '100%',
height: 153,
+ marginBottom: 16,
},
authorImage: {
backgroundColor: '#D9D9D9',
@@ -210,13 +212,14 @@ const tempStyles = StyleSheet.create({
},
top: {
justifyContent: 'space-between',
- gap: 16,
+ gap: 14,
paddingTop: 20,
- paddingBottom: 34,
+ paddingBottom: 32,
},
bottom: {
+ alignItems: 'flex-start',
justifyContent: 'space-between',
- gap: 16,
+ gap: 14,
paddingBottom: 32,
},
title: {
@@ -225,11 +228,13 @@ const tempStyles = StyleSheet.create({
fontWeight: '400',
textAlign: 'left',
color: 'black',
+ marginBottom: 16,
},
author: {
display: 'flex',
flexDirection: 'row',
gap: 10,
+ marginBottom: 16,
},
authorText: {
fontFamily: 'Avenir',
@@ -243,6 +248,7 @@ const tempStyles = StyleSheet.create({
flexDirection: 'row',
flexWrap: 'wrap',
borderRadius: 10,
+ marginBottom: 16,
},
genresBorder: {
backgroundColor: '#D9D9D9',
@@ -267,6 +273,7 @@ const tempStyles = StyleSheet.create({
textAlign: 'left',
color: 'black',
textDecorationLine: 'underline',
+ backgroundColor: '#D9D9D9',
},
heading: {
fontFamily: 'Avenir',
@@ -282,6 +289,15 @@ const tempStyles = StyleSheet.create({
fontWeight: '400',
textAlign: 'left',
color: 'black',
+ marginBottom: 16,
+ },
+ authorProcess: {
+ fontFamily: 'Avenir',
+ fontSize: 16,
+ fontWeight: '600',
+ textAlign: 'left',
+ color: 'black',
+ marginBottom: 16,
},
process: {
fontFamily: 'Avenir',
@@ -289,11 +305,12 @@ const tempStyles = StyleSheet.create({
fontWeight: '400',
textAlign: 'left',
color: 'black',
+ marginBottom: 16,
},
backToTopButtonText: {
fontFamily: 'Avenir',
fontSize: 12,
- fontWeight: '600',
+ fontWeight: '800',
textAlign: 'left',
color: 'black',
},