darken background if sidebar open for small screen
This commit is contained in:
parent
c14bc86a5f
commit
93d262e2c8
1 changed files with 16 additions and 2 deletions
|
|
@ -22,6 +22,7 @@ import {
|
||||||
ScrollBoxRenderable,
|
ScrollBoxRenderable,
|
||||||
addDefaultParsers,
|
addDefaultParsers,
|
||||||
MacOSScrollAccel,
|
MacOSScrollAccel,
|
||||||
|
RGBA,
|
||||||
type ScrollAcceleration,
|
type ScrollAcceleration,
|
||||||
} from "@opentui/core"
|
} from "@opentui/core"
|
||||||
import { Prompt, type PromptRef } from "@tui/component/prompt"
|
import { Prompt, type PromptRef } from "@tui/component/prompt"
|
||||||
|
|
@ -1024,8 +1025,21 @@ export function Session() {
|
||||||
<Sidebar sessionID={route.sessionID} />
|
<Sidebar sessionID={route.sessionID} />
|
||||||
</Show>
|
</Show>
|
||||||
<Show when={sidebarOverlay()}>
|
<Show when={sidebarOverlay()}>
|
||||||
<box position="absolute" right={0} top={0} height={dimensions().height} zIndex={100}>
|
<box
|
||||||
<Sidebar sessionID={route.sessionID} />
|
position="absolute"
|
||||||
|
left={0}
|
||||||
|
top={0}
|
||||||
|
width={dimensions().width}
|
||||||
|
height={dimensions().height}
|
||||||
|
backgroundColor={RGBA.fromInts(0, 0, 0, 150)}
|
||||||
|
zIndex={100}
|
||||||
|
flexDirection="row"
|
||||||
|
justifyContent="flex-end"
|
||||||
|
onMouseUp={() => setSidebar("hide")}
|
||||||
|
>
|
||||||
|
<box onMouseUp={(e) => e.stopPropagation()}>
|
||||||
|
<Sidebar sessionID={route.sessionID} />
|
||||||
|
</box>
|
||||||
</box>
|
</box>
|
||||||
</Show>
|
</Show>
|
||||||
</box>
|
</box>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue