diff --git a/.eslintrc.js b/.eslintrc.js index 78053b5..fc76cab 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -10,7 +10,6 @@ module.exports = { 'tests/*', '/*.cjs', '/*.js', - '/*.ts', '/**/*.test.ts', 'test/*', ], diff --git a/.github/SECURITY.md b/.github/SECURITY.md index c8ee568..7e4576d 100644 --- a/.github/SECURITY.md +++ b/.github/SECURITY.md @@ -10,5 +10,6 @@ Support is not provided for any forks or mirrors of movie-web. ## Reporting a Vulnerability There are two ways you can contact the movie-web maintainers to report a vulnerability: - - Email [security@movie-web.app](mailto:security@movie-web.app) - - Report the vulnerability in the [movie-web Discord server](https://discord.movie-web.app) + +- Email [security@movie-web.app](mailto:security@movie-web.app) +- Report the vulnerability in the [movie-web Discord server](https://discord.movie-web.app) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index c072b7f..6a115ea 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -1,6 +1,6 @@ This pull request resolves #XXX - - [ ] I have read and agreed to the [code of conduct](https://github.com/movie-web/movie-web/blob/dev/.github/CODE_OF_CONDUCT.md). - - [ ] I have read and complied with the [contributing guidelines](https://github.com/movie-web/movie-web/blob/dev/.github/CONTRIBUTING.md). - - [ ] What I'm implementing was assigned to me and is an [approved issue](https://github.com/movie-web/movie-web/issues?q=is%3Aopen+is%3Aissue+label%3Aapproved). For reference, please take a look at our [GitHub projects](https://github.com/movie-web/movie-web/projects). - - [ ] I have tested all of my changes. +- [ ] I have read and agreed to the [code of conduct](https://github.com/movie-web/movie-web/blob/dev/.github/CODE_OF_CONDUCT.md). +- [ ] I have read and complied with the [contributing guidelines](https://github.com/movie-web/movie-web/blob/dev/.github/CONTRIBUTING.md). +- [ ] What I'm implementing was assigned to me and is an [approved issue](https://github.com/movie-web/movie-web/issues?q=is%3Aopen+is%3Aissue+label%3Aapproved). For reference, please take a look at our [GitHub projects](https://github.com/movie-web/movie-web/projects). +- [ ] I have tested all of my changes. diff --git a/.npmrc b/.npmrc index 19be10e..c07a71c 100644 --- a/.npmrc +++ b/.npmrc @@ -1,2 +1,3 @@ strict-peer-dependencies=false auto-install-peers=true +node-linker=hoisted diff --git a/.nvmrc b/.nvmrc new file mode 100644 index 0000000..d4c3d32 --- /dev/null +++ b/.nvmrc @@ -0,0 +1 @@ +20.10 diff --git a/apps/mobile/.eslintrc.js b/apps/mobile/.eslintrc.js new file mode 100644 index 0000000..e3da589 --- /dev/null +++ b/apps/mobile/.eslintrc.js @@ -0,0 +1,31 @@ +module.exports = { + extends: ['../../.eslintrc.js'], + ignorePatterns: ['/*.js', '/*.d.ts'], + overrides: [ + { + files: ['*.ts', '*.tsx', '*.js', '*.jsx'], + rules: {}, + }, + { + files: ['*.ts', '*.tsx'], + rules: {}, + }, + { + files: ['*.js', '*.jsx'], + rules: {}, + }, + ], + rules: { + 'react/jsx-uses-react': 'off', + 'react/react-in-jsx-scope': 'off', + 'react/require-default-props': 'off', + 'react/destructuring-assignment': 'off', + 'react/jsx-filename-extension': [ + 'error', + { extensions: ['.js', '.tsx', '.jsx'] }, + ], + 'react/jsx-props-no-spreading': 'off', + 'react/no-unstable-nested-components': 'off', + 'no-use-before-define': 'off', + }, +}; diff --git a/apps/mobile/.gitignore b/apps/mobile/.gitignore new file mode 100644 index 0000000..0b37b6e --- /dev/null +++ b/apps/mobile/.gitignore @@ -0,0 +1,41 @@ +# Learn more https://docs.github.com/en/get-started/getting-started-with-git/ignoring-files + +# dependencies +node_modules/ + +# Expo +.expo/ +dist/ +web-build/ + +# Native +*.orig.* +*.jks +*.p8 +*.p12 +*.key +*.mobileprovision + +# Metro +.metro-health-check* + +# debug +npm-debug.* +yarn-debug.* +yarn-error.* + +# macOS +.DS_Store +*.pem + +# local env files +.env*.local + +# typescript +*.tsbuildinfo + +# @generated expo-cli sync-2b81b286409207a5da26e14c78851eb30d8ccbdb +# The following patterns were generated by expo-cli + +expo-env.d.ts +# @end expo-cli \ No newline at end of file diff --git a/apps/mobile/app.json b/apps/mobile/app.json new file mode 100644 index 0000000..6e6d68e --- /dev/null +++ b/apps/mobile/app.json @@ -0,0 +1,35 @@ +{ + "expo": { + "name": "mobile", + "slug": "mobile", + "version": "1.0.0", + "orientation": "portrait", + "icon": "./assets/images/icon.png", + "scheme": "myapp", + "userInterfaceStyle": "automatic", + "splash": { + "image": "./assets/images/splash.png", + "resizeMode": "contain", + "backgroundColor": "#ffffff" + }, + "assetBundlePatterns": ["**/*"], + "ios": { + "supportsTablet": true + }, + "android": { + "adaptiveIcon": { + "foregroundImage": "./assets/images/adaptive-icon.png", + "backgroundColor": "#ffffff" + } + }, + "web": { + "bundler": "metro", + "output": "static", + "favicon": "./assets/images/favicon.png" + }, + "plugins": ["expo-router"], + "experiments": { + "typedRoutes": true + } + } +} diff --git a/apps/mobile/app/(tabs)/_layout.tsx b/apps/mobile/app/(tabs)/_layout.tsx new file mode 100644 index 0000000..1d235a1 --- /dev/null +++ b/apps/mobile/app/(tabs)/_layout.tsx @@ -0,0 +1,56 @@ +import FontAwesome from '@expo/vector-icons/FontAwesome'; +import { Link, Tabs } from 'expo-router'; +import { Pressable, useColorScheme } from 'react-native'; + +import Colors from '../../constants/Colors'; + +/** + * You can explore the built-in icon families and icons on the web at https://icons.expo.fyi/ + */ +function TabBarIcon(props: { + name: React.ComponentProps['name']; + color: string; +}) { + return ; +} + +export default function TabLayout() { + const colorScheme = useColorScheme(); + + return ( + + , + headerRight: () => ( + + + {({ pressed }) => ( + + )} + + + ), + }} + /> + , + }} + /> + + ); +} diff --git a/apps/mobile/app/(tabs)/index.tsx b/apps/mobile/app/(tabs)/index.tsx new file mode 100644 index 0000000..3a5bb5f --- /dev/null +++ b/apps/mobile/app/(tabs)/index.tsx @@ -0,0 +1,35 @@ +import { StyleSheet } from 'react-native'; + +import EditScreenInfo from '../../components/EditScreenInfo'; +import { Text, View } from '../../components/Themed'; + +export default function TabOneScreen() { + return ( + + Tab One + + + + ); +} + +const styles = StyleSheet.create({ + container: { + flex: 1, + alignItems: 'center', + justifyContent: 'center', + }, + title: { + fontSize: 20, + fontWeight: 'bold', + }, + separator: { + marginVertical: 30, + height: 1, + width: '80%', + }, +}); diff --git a/apps/mobile/app/(tabs)/two.tsx b/apps/mobile/app/(tabs)/two.tsx new file mode 100644 index 0000000..cc6a377 --- /dev/null +++ b/apps/mobile/app/(tabs)/two.tsx @@ -0,0 +1,35 @@ +import { StyleSheet } from 'react-native'; + +import EditScreenInfo from '../../components/EditScreenInfo'; +import { Text, View } from '../../components/Themed'; + +export default function TabTwoScreen() { + return ( + + Tab Two + + + + ); +} + +const styles = StyleSheet.create({ + container: { + flex: 1, + alignItems: 'center', + justifyContent: 'center', + }, + title: { + fontSize: 20, + fontWeight: 'bold', + }, + separator: { + marginVertical: 30, + height: 1, + width: '80%', + }, +}); diff --git a/apps/mobile/app/+html.tsx b/apps/mobile/app/+html.tsx new file mode 100644 index 0000000..2fe2848 --- /dev/null +++ b/apps/mobile/app/+html.tsx @@ -0,0 +1,46 @@ +import { ScrollViewStyleReset } from 'expo-router/html'; + +// This file is web-only and used to configure the root HTML for every +// web page during static rendering. +// The contents of this function only run in Node.js environments and +// do not have access to the DOM or browser APIs. +export default function Root({ children }: { children: React.ReactNode }) { + return ( + + + + + + {/* + This viewport disables scaling which makes the mobile website act more like a native app. + However this does reduce built-in accessibility. If you want to enable scaling, use this instead: + + */} + + {/* + Disable body scrolling on web. This makes ScrollView components work closer to how they do on native. + However, body scrolling is often nice to have for mobile web. If you want to enable it, remove this line. + */} + + + {/* Using raw CSS styles as an escape-hatch to ensure the background color never flickers in dark-mode. */} +