mirror of
https://github.com/aljazceru/opencode.git
synced 2025-12-25 03:34:22 +01:00
Added big dot (●) indicator for current session in modal (#3980)
Co-authored-by: opencode-agent[bot] <opencode-agent[bot]@users.noreply.github.com> Co-authored-by: rekram1-node <rekram1-node@users.noreply.github.com> Co-authored-by: Aiden Cline <aidenpcline@gmail.com>
This commit is contained in:
committed by
GitHub
parent
e52bfab79d
commit
49e4cfb286
@@ -20,6 +20,10 @@ export function DialogSessionList() {
|
||||
|
||||
const deleteKeybind = "ctrl+d"
|
||||
|
||||
const currentSessionID = createMemo(() =>
|
||||
route.data.type === "session" ? route.data.sessionID : undefined
|
||||
)
|
||||
|
||||
const options = createMemo(() => {
|
||||
const today = new Date().toDateString()
|
||||
return sync.data.session
|
||||
@@ -50,6 +54,7 @@ export function DialogSessionList() {
|
||||
title="Sessions"
|
||||
options={options()}
|
||||
limit={50}
|
||||
current={currentSessionID()}
|
||||
onMove={() => {
|
||||
setToDelete(undefined)
|
||||
}}
|
||||
|
||||
@@ -273,6 +273,11 @@ function Option(props: {
|
||||
const { theme } = useTheme()
|
||||
return (
|
||||
<>
|
||||
<Show when={props.current && !props.active}>
|
||||
<text flexShrink={0} fg={theme.primary} marginRight={0.5}>
|
||||
●
|
||||
</text>
|
||||
</Show>
|
||||
<text
|
||||
flexGrow={1}
|
||||
fg={props.active ? theme.background : props.current ? theme.primary : theme.text}
|
||||
|
||||
Reference in New Issue
Block a user