diff options
| author | Adam <[email protected]> | 2025-09-24 15:49:40 -0500 |
|---|---|---|
| committer | Adam <[email protected]> | 2025-09-24 15:49:40 -0500 |
| commit | 3b20bf6d4f744e63faa8b798ca911a93338dc4f3 (patch) | |
| tree | ac5970c9886ca3f4ac5249426e6c29e57e705528 /packages/app/src/context | |
| parent | c3e52580b000d9f8e51a6768226d99e113164bbd (diff) | |
| download | opencode-3b20bf6d4f744e63faa8b798ca911a93338dc4f3.tar.gz opencode-3b20bf6d4f744e63faa8b798ca911a93338dc4f3.zip | |
fix(app): changes view
Diffstat (limited to 'packages/app/src/context')
| -rw-r--r-- | packages/app/src/context/local.tsx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/packages/app/src/context/local.tsx b/packages/app/src/context/local.tsx index 804bb0674..b512ef470 100644 --- a/packages/app/src/context/local.tsx +++ b/packages/app/src/context/local.tsx @@ -124,11 +124,12 @@ function init() { return store.node[store.active] }) const opened = createMemo(() => store.opened.map((x) => store.node[x])) - const changes = createMemo(() => new Set(sync.data.changes.map((f) => f.path))) + const changeset = createMemo(() => new Set(sync.data.changes.map((f) => f.path))) + const changes = createMemo(() => Array.from(changeset()).sort((a, b) => a.localeCompare(b))) const status = (path: string) => sync.data.changes.find((f) => f.path === path) const changed = (path: string) => { - const set = changes() + const set = changeset() if (set.has(path)) return true for (const p of set) { if (p.startsWith(path ? path + "/" : "")) return true |
