diff --git a/src/components/LayerUI.scss b/src/components/LayerUI.scss index 62d7a6b8..2f4586f0 100644 --- a/src/components/LayerUI.scss +++ b/src/components/LayerUI.scss @@ -40,39 +40,17 @@ .layer-ui__wrapper { z-index: var(--zIndex-layerUI); - .encrypted-icon { - position: relative; - margin-inline-start: 15px; - display: flex; - justify-content: center; - align-items: center; - border-radius: var(--space-factor); - color: $oc-green-9; - - svg { - width: 1.2rem; - height: 1.2rem; - } - } - &__top-right { display: flex; } &__footer { - position: absolute; - z-index: 100; - bottom: 0; + width: 100%; - :root[dir="ltr"] & { - right: 0; + &-right { + z-index: 100; + display: flex; } - - :root[dir="rtl"] & { - left: 0; - } - - width: 190px; } .zen-mode-transition { @@ -94,12 +72,16 @@ transform: translate(-999px, 0); } - :root[dir="ltr"] &.App-menu_bottom--transition-left { + :root[dir="ltr"] &.layer-ui__wrapper__footer-left--transition-left { transform: translate(-92px, 0); } - :root[dir="rtl"] &.App-menu_bottom--transition-left { + :root[dir="rtl"] &.layer-ui__wrapper__footer-left--transition-left { transform: translate(92px, 0); } + + &.layer-ui__wrapper__footer-left--transition-bottom { + transform: translate(0, 92px); + } } .disable-zen-mode { diff --git a/src/components/LayerUI.tsx b/src/components/LayerUI.tsx index c33cbb08..a354322c 100644 --- a/src/components/LayerUI.tsx +++ b/src/components/LayerUI.tsx @@ -31,7 +31,7 @@ import { ErrorDialog } from "./ErrorDialog"; import { ExportCB, ExportDialog } from "./ExportDialog"; import { FixedSideContainer } from "./FixedSideContainer"; import { HintViewer } from "./HintViewer"; -import { exportFile, load, shield, trash } from "./icons"; +import { exportFile, load, trash } from "./icons"; import { Island } from "./Island"; import "./LayerUI.scss"; import { LibraryUnit } from "./LibraryUnit"; @@ -68,7 +68,7 @@ interface LayerUIProps { canvas: HTMLCanvasElement | null, ) => void; renderTopRightUI?: (isMobile: boolean, appState: AppState) => JSX.Element; - renderCustomFooter?: (isMobile: boolean) => JSX.Element; + renderCustomFooter?: (isMobile: boolean, appState: AppState) => JSX.Element; viewModeEnabled: boolean; libraryReturnUrl: ExcalidrawProps["libraryReturnUrl"]; UIOptions: AppProps["UIOptions"]; @@ -382,22 +382,6 @@ const LayerUI = ({ }: LayerUIProps) => { const isMobile = useIsMobile(); - const renderEncryptedIcon = () => ( - - - {shield} - - - ); - const renderExportDialog = () => { if (!UIOptions.canvasActions.export) { return null; @@ -634,47 +618,61 @@ const LayerUI = ({ const renderBottomAppMenu = () => { return ( -
- -
- - - - {renderEncryptedIcon()} -
-
-
+
+ +
+ + + +
+
+
+
+ {renderCustomFooter?.(false, appState)} +
+
+ {actionManager.renderAction("toggleShortcuts")} +
+ + ); }; - const renderFooter = () => ( - - ); - const dialogs = ( <> {appState.isLoading && } @@ -737,7 +735,6 @@ const LayerUI = ({ {dialogs} {renderFixedSideContainer()} {renderBottomAppMenu()} - {renderFooter()} {appState.scrolledOutside && (