From 8694342fc6981361f728d6c98bdbfa85610344df Mon Sep 17 00:00:00 2001 From: Cody Garcia Date: Wed, 16 Oct 2024 00:32:37 -0700 Subject: [PATCH] finished pr --- graphics.d.ts | 8 +-- package-lock.json | 10 +++ package.json | 3 +- src/screens/LegalRights/VideoPage/index.tsx | 33 ++++++---- src/screens/LegalRights/VideoPage/styles.ts | 29 ++++++++- src/screens/LegalRights/index.tsx | 70 ++++++++++++++++++--- src/screens/LegalRights/styles.ts | 4 +- 7 files changed, 128 insertions(+), 29 deletions(-) diff --git a/graphics.d.ts b/graphics.d.ts index 55f46f9..d2ae3fb 100644 --- a/graphics.d.ts +++ b/graphics.d.ts @@ -22,7 +22,7 @@ declare module '*.jpeg' { export default value; } -// declare module '*.mp4' { -// const src: string; -// export default src; -// } +declare module '*.mp4' { + const source: { uri: string }; + export default source; +} diff --git a/package-lock.json b/package-lock.json index 512a706..6612237 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,6 +12,7 @@ "@react-navigation/native-stack": "^6.11.0", "@supabase/supabase-js": "^2.45.4", "expo": "~51.0.21", + "expo-av": "~14.0.7", "expo-status-bar": "~1.12.1", "react": "18.2.0", "react-native": "^0.74.5", @@ -8556,6 +8557,15 @@ "expo": "*" } }, + "node_modules/expo-av": { + "version": "14.0.7", + "resolved": "https://registry.npmjs.org/expo-av/-/expo-av-14.0.7.tgz", + "integrity": "sha512-FvKZxyy+2/qcCmp+e1GTK3s4zH8ZO1RfjpqNxh7ARlS1oH8HPtk1AyZAMo52tHz3yQ3UIqxQ2YbI9CFb4065lA==", + "license": "MIT", + "peerDependencies": { + "expo": "*" + } + }, "node_modules/expo-constants": { "version": "16.0.2", "license": "MIT", diff --git a/package.json b/package.json index 10a594f..95beb2e 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,8 @@ "react-native": "^0.74.5", "react-native-safe-area-context": "4.10.5", "react-native-screens": "3.31.1", - "react-native-video": "^6.6.4" + "react-native-video": "^6.6.4", + "expo-av": "~14.0.7" }, "devDependencies": { "@babel/core": "^7.20.0", diff --git a/src/screens/LegalRights/VideoPage/index.tsx b/src/screens/LegalRights/VideoPage/index.tsx index f430539..0049c94 100644 --- a/src/screens/LegalRights/VideoPage/index.tsx +++ b/src/screens/LegalRights/VideoPage/index.tsx @@ -1,19 +1,28 @@ -import { Button, Image, Text, View } from 'react-native'; -// import PreaVideo from '@/assets/videos/da_link.mp4'; -import Video from 'react-native-video'; +import { Pressable, ScrollView, Text, View } from 'react-native'; +import { Video } from 'expo-av'; import { styles } from './styles'; export default function VideoPage() { return ( - <> - this is video yup - {/*