feat(app): new layout
This commit is contained in:
@@ -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),
|
||||
|
||||
@@ -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>>()
|
||||
|
||||
Reference in New Issue
Block a user