fix dropdown overlapping with welcome screen

This commit is contained in:
Ryan Di
2025-09-23 12:45:45 +10:00
parent e101c2ca7c
commit 995357cbf9
2 changed files with 24 additions and 14 deletions

View File

@@ -60,16 +60,6 @@ export const MobileMenu = ({
MainMenuTunnel, MainMenuTunnel,
DefaultSidebarTriggerTunnel, DefaultSidebarTriggerTunnel,
} = useTunnels(); } = useTunnels();
const renderToolbar = () => {
return (
<MobileToolBar
appState={appState}
app={app}
onHandToolToggle={onHandToolToggle}
/>
);
};
const renderAppTopBar = () => { const renderAppTopBar = () => {
if ( if (
appState.viewModeEnabled || appState.viewModeEnabled ||
@@ -99,13 +89,25 @@ export const MobileMenu = ({
); );
}; };
const renderToolbar = () => {
return (
<MobileToolBar
appState={appState}
app={app}
onHandToolToggle={onHandToolToggle}
/>
);
};
return ( return (
<> <>
{renderSidebars()} {renderSidebars()}
<FixedSideContainer side="top" className="App-top-bar"> {/* welcome screen, bottom bar, and top bar all have the same z-index */}
{renderAppTopBar()} {/* ordered in this reverse order so that top bar is on top */}
<div className="App-welcome-screen">
{renderWelcomeScreen && <WelcomeScreenCenterTunnel.Out />} {renderWelcomeScreen && <WelcomeScreenCenterTunnel.Out />}
</FixedSideContainer> </div>
<div <div
className="App-bottom-bar" className="App-bottom-bar"
style={{ style={{
@@ -141,6 +143,10 @@ export const MobileMenu = ({
)} )}
</Island> </Island>
</div> </div>
<FixedSideContainer side="top" className="App-top-bar">
{renderAppTopBar()}
</FixedSideContainer>
</> </>
); );
}; };

View File

@@ -237,6 +237,10 @@ body.excalidraw-cursor-resize * {
flex-direction: column; flex-direction: column;
} }
.App-welcome-screen {
z-index: var(--zIndex-layerUI);
}
.App-bottom-bar { .App-bottom-bar {
position: absolute; position: absolute;
// account for margins // account for margins
@@ -246,7 +250,7 @@ body.excalidraw-cursor-resize * {
left: 50%; left: 50%;
transform: translateX(-50%); transform: translateX(-50%);
--bar-padding: calc(4 * var(--space-factor)); --bar-padding: calc(4 * var(--space-factor));
z-index: 3; z-index: var(--zIndex-layerUI);
display: flex; display: flex;
flex-direction: column; flex-direction: column;