feat(app): new layout

This commit is contained in:
Adam
2026-01-12 10:11:29 -06:00
parent 9f66a45970
commit 679270d9e0
19 changed files with 681 additions and 276 deletions

View File

@@ -53,6 +53,7 @@ export const { use: useLayout, provider: LayoutProvider } = createSimpleContext(
sidebar: {
opened: false,
width: 280,
workspaces: false,
},
terminal: {
height: 280,
@@ -304,6 +305,13 @@ export const { use: useLayout, provider: LayoutProvider } = createSimpleContext(
resize(width: number) {
setStore("sidebar", "width", width)
},
workspaces: createMemo(() => store.sidebar.workspaces ?? false),
setWorkspaces(value: boolean) {
setStore("sidebar", "workspaces", value)
},
toggleWorkspaces() {
setStore("sidebar", "workspaces", (x) => !x)
},
},
terminal: {
height: createMemo(() => store.terminal.height),

View File

@@ -14,7 +14,7 @@ export const { use: useSync, provider: SyncProvider } = createSimpleContext({
const sdk = useSDK()
const [store, setStore] = globalSync.child(sdk.directory)
const absolute = (path: string) => (store.path.directory + "/" + path).replace("//", "/")
const chunk = 200
const chunk = 400
const inflight = new Map<string, Promise<void>>()
const inflightDiff = new Map<string, Promise<void>>()
const inflightTodo = new Map<string, Promise<void>>()