Skip to content

Commit

Permalink
hackfix radix dropdown height
Browse files Browse the repository at this point in the history
  • Loading branch information
mozzius committed Jan 26, 2025
1 parent dcfbc12 commit 715a3fc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
5 changes: 4 additions & 1 deletion src/view/screens/Search/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,10 @@ function SearchLanguageDropdown({
</Button>
)}
</Menu.Trigger>
<Menu.Outer>
<Menu.Outer
// HACKFIX: Currently there is no height limit for Radix dropdowns,
// so if it's too tall it just goes off screen. TODO: fix internally -sfn
style={web({maxHeight: '70vh'})}>
<Menu.LabelText>
<Trans>Filter search by language</Trans>
</Menu.LabelText>
Expand Down
7 changes: 5 additions & 2 deletions src/view/shell/desktop/LeftNav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ import {LoadingPlaceholder} from '#/view/com/util/LoadingPlaceholder'
import {PressableWithHover} from '#/view/com/util/PressableWithHover'
import {UserAvatar} from '#/view/com/util/UserAvatar'
import {NavSignupCard} from '#/view/shell/NavSignupCard'
import {atoms as a, tokens, useBreakpoints, useTheme} from '#/alf'
import {atoms as a, tokens, useBreakpoints, useTheme, web} from '#/alf'
import {Button, ButtonIcon, ButtonText} from '#/components/Button'
import {DialogControlProps} from '#/components/Dialog'
import {ArrowBoxLeft_Stroke2_Corner0_Rounded as LeaveIcon} from '#/components/icons/ArrowBoxLeft'
Expand Down Expand Up @@ -235,7 +235,10 @@ function SwitchMenuItems({
closeEverything()
}
return (
<Menu.Outer>
<Menu.Outer
// HACKFIX: Currently there is no height limit for Radix dropdowns,
// so if it's too tall it just goes off screen. TODO: fix internally -sfn
style={web({maxHeight: '70vh'})}>
{accounts && accounts.length > 0 && (
<>
<Menu.Group>
Expand Down

0 comments on commit 715a3fc

Please sign in to comment.