about summary refs log tree commit diff
path: root/src/view/com
diff options
context:
space:
mode:
Diffstat (limited to 'src/view/com')
-rw-r--r--src/view/com/auth/SplashScreen.web.tsx1
-rw-r--r--src/view/com/modals/DeleteAccount.tsx1
-rw-r--r--src/view/com/modals/Modal.web.tsx2
-rw-r--r--src/view/com/modals/lang-settings/ContentLanguagesSettings.tsx1
-rw-r--r--src/view/com/modals/lang-settings/PostLanguagesSettings.tsx1
-rw-r--r--src/view/com/pager/Pager.tsx2
-rw-r--r--src/view/com/util/LoadingPlaceholder.tsx12
-rw-r--r--src/view/com/util/Toast.web.tsx12
-rw-r--r--src/view/com/util/Views.web.tsx2
-rw-r--r--src/view/com/util/layouts/LoggedOutLayout.tsx1
-rw-r--r--src/view/com/util/load-latest/LoadLatestBtn.web.tsx2
11 files changed, 31 insertions, 6 deletions
diff --git a/src/view/com/auth/SplashScreen.web.tsx b/src/view/com/auth/SplashScreen.web.tsx
index 22b328582..3c949bb9a 100644
--- a/src/view/com/auth/SplashScreen.web.tsx
+++ b/src/view/com/auth/SplashScreen.web.tsx
@@ -90,6 +90,7 @@ const styles = StyleSheet.create({
   containerInner: {
     height: '100%',
     justifyContent: 'center',
+    // @ts-ignore web only
     paddingBottom: '20vh',
     paddingHorizontal: 20,
   },
diff --git a/src/view/com/modals/DeleteAccount.tsx b/src/view/com/modals/DeleteAccount.tsx
index 98482457c..50a4cd603 100644
--- a/src/view/com/modals/DeleteAccount.tsx
+++ b/src/view/com/modals/DeleteAccount.tsx
@@ -242,6 +242,7 @@ const styles = StyleSheet.create({
     overflow: 'hidden',
     whiteSpace: 'nowrap',
     textOverflow: 'ellipsis',
+    // @ts-ignore only rendered on web
     maxWidth: '400px',
   },
   description: {
diff --git a/src/view/com/modals/Modal.web.tsx b/src/view/com/modals/Modal.web.tsx
index b3a79221d..86fa28faf 100644
--- a/src/view/com/modals/Modal.web.tsx
+++ b/src/view/com/modals/Modal.web.tsx
@@ -145,7 +145,9 @@ const styles = StyleSheet.create({
   },
   container: {
     width: 500,
+    // @ts-ignore web only
     maxWidth: '100vw',
+    // @ts-ignore web only
     maxHeight: '100vh',
     paddingVertical: 20,
     paddingHorizontal: 24,
diff --git a/src/view/com/modals/lang-settings/ContentLanguagesSettings.tsx b/src/view/com/modals/lang-settings/ContentLanguagesSettings.tsx
index e577991c5..910522f90 100644
--- a/src/view/com/modals/lang-settings/ContentLanguagesSettings.tsx
+++ b/src/view/com/modals/lang-settings/ContentLanguagesSettings.tsx
@@ -54,6 +54,7 @@ export function Component({}: {}) {
       style={[
         pal.view,
         styles.container,
+        // @ts-ignore vh is web only
         isMobile
           ? {
               paddingTop: 20,
diff --git a/src/view/com/modals/lang-settings/PostLanguagesSettings.tsx b/src/view/com/modals/lang-settings/PostLanguagesSettings.tsx
index c80f8731c..1ee5c9d1f 100644
--- a/src/view/com/modals/lang-settings/PostLanguagesSettings.tsx
+++ b/src/view/com/modals/lang-settings/PostLanguagesSettings.tsx
@@ -55,6 +55,7 @@ export const Component = observer(() => {
       style={[
         pal.view,
         styles.container,
+        // @ts-ignore vh is on web only
         isMobile
           ? {
               paddingTop: 20,
diff --git a/src/view/com/pager/Pager.tsx b/src/view/com/pager/Pager.tsx
index e2c8bf6d2..ad271da33 100644
--- a/src/view/com/pager/Pager.tsx
+++ b/src/view/com/pager/Pager.tsx
@@ -36,7 +36,7 @@ export const Pager = forwardRef<PagerRef, React.PropsWithChildren<Props>>(
     ref,
   ) => {
     const [selectedPage, setSelectedPage] = React.useState(0)
-    const pagerView = React.useRef<PagerView>()
+    const pagerView = React.useRef<PagerView>(null)
 
     React.useImperativeHandle(ref, () => ({
       setPage: (index: number) => pagerView.current?.setPage(index),
diff --git a/src/view/com/util/LoadingPlaceholder.tsx b/src/view/com/util/LoadingPlaceholder.tsx
index 2f653ee09..bf39fd50c 100644
--- a/src/view/com/util/LoadingPlaceholder.tsx
+++ b/src/view/com/util/LoadingPlaceholder.tsx
@@ -1,5 +1,11 @@
 import React from 'react'
-import {StyleSheet, StyleProp, View, ViewStyle} from 'react-native'
+import {
+  StyleSheet,
+  StyleProp,
+  View,
+  ViewStyle,
+  DimensionValue,
+} from 'react-native'
 import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
 import {HeartIcon} from 'lib/icons'
 import {s} from 'lib/styles'
@@ -11,8 +17,8 @@ export function LoadingPlaceholder({
   height,
   style,
 }: {
-  width: string | number
-  height: string | number
+  width: DimensionValue
+  height: DimensionValue
   style?: StyleProp<ViewStyle>
 }) {
   const theme = useTheme()
diff --git a/src/view/com/util/Toast.web.tsx b/src/view/com/util/Toast.web.tsx
index cfde68536..c295bad69 100644
--- a/src/view/com/util/Toast.web.tsx
+++ b/src/view/com/util/Toast.web.tsx
@@ -4,7 +4,10 @@
 
 import React, {useState, useEffect} from 'react'
 import {StyleSheet, Text, View} from 'react-native'
-import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
+import {
+  FontAwesomeIcon,
+  FontAwesomeIconStyle,
+} from '@fortawesome/react-native-fontawesome'
 
 const DURATION = 3500
 
@@ -32,7 +35,11 @@ export const ToastContainer: React.FC<ToastContainerProps> = ({}) => {
     <>
       {activeToast && (
         <View style={styles.container}>
-          <FontAwesomeIcon icon="check" size={24} style={styles.icon} />
+          <FontAwesomeIcon
+            icon="check"
+            size={24}
+            style={styles.icon as FontAwesomeIconStyle}
+          />
           <Text style={styles.text}>{activeToast.text}</Text>
         </View>
       )}
@@ -57,6 +64,7 @@ const styles = StyleSheet.create({
     position: 'absolute',
     left: 20,
     bottom: 20,
+    // @ts-ignore web only
     width: 'calc(100% - 40px)',
     maxWidth: 350,
     padding: 20,
diff --git a/src/view/com/util/Views.web.tsx b/src/view/com/util/Views.web.tsx
index 58a367f20..bbd9ce04a 100644
--- a/src/view/com/util/Views.web.tsx
+++ b/src/view/com/util/Views.web.tsx
@@ -118,6 +118,7 @@ const styles = StyleSheet.create({
   contentContainer: {
     borderLeftWidth: 1,
     borderRightWidth: 1,
+    // @ts-ignore web only
     minHeight: '100vh',
   },
   container: {
@@ -133,6 +134,7 @@ const styles = StyleSheet.create({
     marginRight: 'auto',
   },
   fixedHeight: {
+    // @ts-ignore web only
     height: '100vh',
   },
   stableGutters: {
diff --git a/src/view/com/util/layouts/LoggedOutLayout.tsx b/src/view/com/util/layouts/LoggedOutLayout.tsx
index daa33cece..9424a7154 100644
--- a/src/view/com/util/layouts/LoggedOutLayout.tsx
+++ b/src/view/com/util/layouts/LoggedOutLayout.tsx
@@ -60,6 +60,7 @@ export const LoggedOutLayout = ({
 const styles = StyleSheet.create({
   container: {
     flexDirection: 'row',
+    // @ts-ignore web only
     height: '100vh',
   },
   side: {
diff --git a/src/view/com/util/load-latest/LoadLatestBtn.web.tsx b/src/view/com/util/load-latest/LoadLatestBtn.web.tsx
index c9576e56b..83c696f7e 100644
--- a/src/view/com/util/load-latest/LoadLatestBtn.web.tsx
+++ b/src/view/com/util/load-latest/LoadLatestBtn.web.tsx
@@ -74,6 +74,7 @@ const styles = StyleSheet.create({
     alignItems: 'center',
     justifyContent: 'center',
     position: 'absolute',
+    // @ts-ignore web only
     left: '50vw',
     // @ts-ignore web only -prf
     transform: 'translateX(-282px)',
@@ -92,6 +93,7 @@ const styles = StyleSheet.create({
     alignItems: 'center',
     justifyContent: 'center',
     position: 'absolute',
+    // @ts-ignore web only
     left: '50vw',
     // @ts-ignore web only -prf
     transform: 'translateX(-50%)',