diff --git a/packages/excalidraw/components/IconPicker.scss b/packages/excalidraw/components/IconPicker.scss index 2e9493f4b3..cf99f81329 100644 --- a/packages/excalidraw/components/IconPicker.scss +++ b/packages/excalidraw/components/IconPicker.scss @@ -8,7 +8,6 @@ border: 0 solid color.adjust(#fff, $alpha: -0.75); box-shadow: var(--shadow-island-stronger); border-radius: 4px; - position: absolute; :root[dir="rtl"] & { padding: 0.4rem; } diff --git a/packages/excalidraw/components/IconPicker.tsx b/packages/excalidraw/components/IconPicker.tsx index ad1b86625e..ac05a93d44 100644 --- a/packages/excalidraw/components/IconPicker.tsx +++ b/packages/excalidraw/components/IconPicker.tsx @@ -8,7 +8,7 @@ import { atom, useAtom } from "../editor-jotai"; import { getLanguage, t } from "../i18n"; import Collapsible from "./Stats/Collapsible"; -import { useEditorInterface, useExcalidrawContainer } from "./App"; +import { useExcalidrawContainer } from "./App"; import "./IconPicker.scss"; @@ -79,7 +79,6 @@ function Picker({ onChange: (value: T) => void; onClose: () => void; }) { - const editorInterface = useEditorInterface(); const { container } = useExcalidrawContainer(); const [showMoreOptions, setShowMoreOptions] = useAtom(moreOptionsAtom); const allSections = [...visibleSections, ...hiddenSections]; @@ -248,41 +247,37 @@ function Picker({ ), ); - const isMobile = editorInterface.formFactor === "phone"; - return ( -
-
- {renderSections(visibleSections)} +
+ {renderSections(visibleSections)} - {hiddenSections.length > 0 && ( - { - setShowMoreOptions((value) => !value); - }} - className="picker-collapsible" - > -
- {renderSections(hiddenSections)} -
-
- )} -
+ {hiddenSections.length > 0 && ( + { + setShowMoreOptions((value) => !value); + }} + className="picker-collapsible" + > +
+ {renderSections(hiddenSections)} +
+
+ )}
);