fix: scroll setting preferences

This commit is contained in:
Faisal Amir 2025-03-13 13:45:48 +07:00
parent 24e301854c
commit 6def8193cb

View File

@ -3,7 +3,7 @@ import { useCallback } from 'react'
import { useTheme } from 'next-themes' import { useTheme } from 'next-themes'
import { fs, joinPath } from '@janhq/core' import { fs, joinPath } from '@janhq/core'
import { Button, Select, Switch } from '@janhq/joi' import { Button, ScrollArea, Select, Switch } from '@janhq/joi'
import { useAtom, useAtomValue } from 'jotai' import { useAtom, useAtomValue } from 'jotai'
import { twMerge } from 'tailwind-merge' import { twMerge } from 'tailwind-merge'
@ -73,6 +73,10 @@ export default function AppearanceOptions() {
) )
return ( return (
<ScrollArea
type={showScrollBar ? 'always' : 'scroll'}
className="h-full w-full px-4"
>
<div className="m-4 block"> <div className="m-4 block">
<div className="flex w-full flex-col items-start justify-between gap-4 border-b border-[hsla(var(--app-border))] py-4 first:pt-0 last:border-none sm:flex-row"> <div className="flex w-full flex-col items-start justify-between gap-4 border-b border-[hsla(var(--app-border))] py-4 first:pt-0 last:border-none sm:flex-row">
<div className="flex-shrink-0 space-y-1"> <div className="flex-shrink-0 space-y-1">
@ -215,5 +219,6 @@ export default function AppearanceOptions() {
</div> </div>
</div> </div>
</div> </div>
</ScrollArea>
) )
} }