Skip to content

Commit 4c20d96

Browse files
committed
fix: hide back to top fab in mobile
Signed-off-by: Innei <[email protected]>
1 parent c8f3337 commit 4c20d96

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/components/layout/root/Root.tsx

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { ClientOnly } from '~/components/common/ClientOnly'
22
import { BackToTopFAB, FABContainer } from '~/components/ui/fab'
3+
import { OnlyDesktop } from '~/components/ui/viewport'
34

45
import { Content } from '../content/Content'
56
import { Footer } from '../footer'
@@ -14,7 +15,9 @@ export const Root: Component = ({ children }) => {
1415
<Footer />
1516
<ClientOnly>
1617
<FABContainer>
17-
<BackToTopFAB />
18+
<OnlyDesktop>
19+
<BackToTopFAB />
20+
</OnlyDesktop>
1821
</FABContainer>
1922
</ClientOnly>
2023
</>

0 commit comments

Comments
 (0)