about summary refs log tree commit diff
path: root/src/view/com/util/layouts/withBreakpoints.tsx
diff options
context:
space:
mode:
authorPaul Frazee <pfrazee@gmail.com>2023-08-30 15:15:10 -0700
committerPaul Frazee <pfrazee@gmail.com>2023-08-30 15:15:10 -0700
commit8ed6e72ea4a5b6546ecbbee6aa4233ee6b3aed21 (patch)
treeaa944955dbd07fdb10fed60c6e9ef20741c86869 /src/view/com/util/layouts/withBreakpoints.tsx
parent05d1d8d8a4565e7d042f8c09760186b4037dcd2f (diff)
downloadvoidsky-8ed6e72ea4a5b6546ecbbee6aa4233ee6b3aed21.tar.zst
More fixes to mobile onboard
Diffstat (limited to 'src/view/com/util/layouts/withBreakpoints.tsx')
-rw-r--r--src/view/com/util/layouts/withBreakpoints.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/view/com/util/layouts/withBreakpoints.tsx b/src/view/com/util/layouts/withBreakpoints.tsx
index 4214c1040..dc3f50dc9 100644
--- a/src/view/com/util/layouts/withBreakpoints.tsx
+++ b/src/view/com/util/layouts/withBreakpoints.tsx
@@ -1,6 +1,6 @@
 import React from 'react'
-import {useMediaQuery} from 'react-responsive'
 import {isNative} from 'platform/detection'
+import {useWebMediaQueries} from 'lib/hooks/useWebMediaQueries'
 
 export const withBreakpoints =
   <P extends object>(
@@ -9,8 +9,7 @@ export const withBreakpoints =
     Desktop: React.ComponentType<P>,
   ): React.FC<P> =>
   (props: P) => {
-    const isTabletOrMobile = useMediaQuery({query: '(max-width: 1224px)'})
-    const isMobile = useMediaQuery({query: '(max-width: 800px)'})
+    const {isMobile, isTabletOrMobile} = useWebMediaQueries()
 
     if (isMobile || isNative) {
       return <Mobile {...props} />