mirror of
https://github.com/zadam/trilium.git
synced 2025-12-06 23:44:25 +01:00
fix(launch_bar): wrong position of dropdown
This commit is contained in:
parent
b99d4532df
commit
3a8dcae53a
@ -26,7 +26,7 @@ export function LaunchBarActionButton(props: Omit<ActionButtonProps, "className"
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
export function LaunchBarDropdownButton({ children, icon, ...props }: Pick<DropdownProps, "title" | "children" | "onShown" | "dropdownOptions" | "dropdownRef"> & { icon: string }) {
|
export function LaunchBarDropdownButton({ children, icon, dropdownOptions, ...props }: Pick<DropdownProps, "title" | "children" | "onShown" | "dropdownOptions" | "dropdownRef"> & { icon: string }) {
|
||||||
const { isHorizontalLayout } = useContext(LaunchBarContext);
|
const { isHorizontalLayout } = useContext(LaunchBarContext);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@ -37,6 +37,12 @@ export function LaunchBarDropdownButton({ children, icon, ...props }: Pick<Dropd
|
|||||||
text={<Icon icon={icon} />}
|
text={<Icon icon={icon} />}
|
||||||
titlePosition={isHorizontalLayout ? "bottom" : "right"}
|
titlePosition={isHorizontalLayout ? "bottom" : "right"}
|
||||||
titleOptions={{ animation: false }}
|
titleOptions={{ animation: false }}
|
||||||
|
dropdownOptions={{
|
||||||
|
...dropdownOptions,
|
||||||
|
popperConfig: {
|
||||||
|
placement: isHorizontalLayout ? "bottom" : "right"
|
||||||
|
}
|
||||||
|
}}
|
||||||
{...props}
|
{...props}
|
||||||
>{children}</Dropdown>
|
>{children}</Dropdown>
|
||||||
)
|
)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user