From 7083d4efe942508b97393416feef7704f8bd844b Mon Sep 17 00:00:00 2001 From: sergeyteleshev Date: Mon, 20 May 2024 11:12:24 +0200 Subject: [PATCH] CB-5092 fix: selectors and nodes context menu do not break layout for small screens --- webapp/packages/core-blocks/src/FormControls/Combobox.tsx | 8 ++------ webapp/packages/core-blocks/src/Menu/Menu.tsx | 1 + 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/webapp/packages/core-blocks/src/FormControls/Combobox.tsx b/webapp/packages/core-blocks/src/FormControls/Combobox.tsx index 857b60da24..20cb42cd88 100644 --- a/webapp/packages/core-blocks/src/FormControls/Combobox.tsx +++ b/webapp/packages/core-blocks/src/FormControls/Combobox.tsx @@ -106,6 +106,7 @@ export const Combobox: ComboboxType = observer(function Combobox({ placement: 'bottom-end', currentId: null, gutter: 4, + unstable_fixed: true, }); if (readOnly) { @@ -150,11 +151,6 @@ export const Combobox: ComboboxType = observer(function Combobox({ } } - function handleArrowClick(e: React.MouseEvent) { - e.preventDefault(); - handleClick(); - } - const handleChange = useCallback( (event: React.ChangeEvent) => { const value = event.target.value; @@ -303,7 +299,7 @@ export const Combobox: ComboboxType = observer(function Combobox({ onClick={handleClick} {...rest} /> - + diff --git a/webapp/packages/core-blocks/src/Menu/Menu.tsx b/webapp/packages/core-blocks/src/Menu/Menu.tsx index 4188661bdc..90b52d21c9 100644 --- a/webapp/packages/core-blocks/src/Menu/Menu.tsx +++ b/webapp/packages/core-blocks/src/Menu/Menu.tsx @@ -70,6 +70,7 @@ export const Menu = observer( placement, visible, rtl, + unstable_fixed: true, }); const styles = useS(style);