mirror of
https://github.com/sst/opencode.git
synced 2025-12-23 10:11:41 +00:00
sync
This commit is contained in:
parent
0bd11e970b
commit
3198bab492
2 changed files with 4 additions and 2 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import { SyntaxStyle, RGBA, type TerminalColors } from "@opentui/core"
|
||||
import { createMemo } from "solid-js"
|
||||
import { createMemo, onMount } from "solid-js"
|
||||
import { useSync } from "@tui/context/sync"
|
||||
import { createSimpleContext } from "./helper"
|
||||
import aura from "./theme/aura.json" with { type: "json" }
|
||||
|
|
@ -144,6 +144,7 @@ export const { use: useTheme, provider: ThemeProvider } = createSimpleContext({
|
|||
themes: DEFAULT_THEMES,
|
||||
mode: props.mode,
|
||||
active: (sync.data.config.theme ?? kv.get("theme", "opencode")) as string,
|
||||
ready: false,
|
||||
})
|
||||
|
||||
const renderer = useRenderer()
|
||||
|
|
@ -187,7 +188,7 @@ export const { use: useTheme, provider: ThemeProvider } = createSimpleContext({
|
|||
kv.set("theme", theme)
|
||||
},
|
||||
get ready() {
|
||||
return sync.ready
|
||||
return store.ready
|
||||
},
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -163,6 +163,7 @@ export namespace Server {
|
|||
return c.json(await Config.get())
|
||||
},
|
||||
)
|
||||
|
||||
.patch(
|
||||
"/config",
|
||||
describeRoute({
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue