Commit Graph
18 Commits
Author SHA1 Message Date
Cursor AgentandSerhii Dziupin 094fb4fc40 merge main to pick up German locale for custom provider keys
Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-03 08:53:06 +00:00
Cursor AgentandSerhii Dziupin 66c5f0cdd4 fix custom provider edit to preserve config scope
Derive the effective OpenCode config layer (custom > project > user) from
provider sources and send it on PUT /api/provider so project/custom edits
update that layer instead of creating a global user override. Resolve
OPENCODE_CONFIG at call time and add UI/web/VS Code coverage for scoped
upserts.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-03 08:22:30 +00:00
Cursor AgentandSerhii Dziupin b7c09ee137 fix custom provider edit gating and form reset on re-render
Gate Edit/incomplete-auth on config-layer sources so catalog providers
are not treated as editable custom overrides. Snapshot form initial
values when Edit is clicked and ignore same-id initialValues identity
changes so parent re-renders cannot wipe in-progress edits.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-02 12:42:23 +00:00
Cursor AgentandSerhii Dziupin d40bb9e5a0 fix custom provider credentials, edit path, and failure UX
Require an API key or {env:VAR} on client and server, add edit/prefill for
existing custom providers, save auth before config, and surface incomplete
auth plus disconnect after partial failures. Add VS Code parity tests and
drop the unused allProvidersConnected locale key.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-02 11:40:02 +00:00
Cursor AgentandSerhii Dziupin d84e4e0312 test: cover JSON body parsing for /api/provider
Guards the selective express.json allowlist so custom provider upsert
requests keep a parsed body.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-02 10:12:28 +00:00
Cursor AgentandSerhii Dziupin 0131c66bdd fix: parse JSON bodies for /api/provider routes
Custom provider upsert uses PUT /api/provider, which was skipped by the
selective express.json allowlist and always saw an empty body.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-02 09:55:41 +00:00
Cursor AgentandSerhii Dziupin be87e25c7d feat: add custom/other OpenAI-compatible LLM providers
Allow Settings → Providers to define custom providers (id, name, base URL,
API key, models, headers) without code changes. Persist config via OpenCode
layers, store keys through auth.set, and keep web/VS Code parity.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-08-02 09:12:28 +00:00
Cursor AgentandSerhii Dziupin d839c8b0f8 fix(git): pin simple-git to project path for session discovery
simple-git without baseDir inherits process.cwd(), so launching
OpenChamber from a neutral directory (e.g. $HOME) and opening a git
project elsewhere produced repeated "not a git repository" status
errors and could abort project/session enumeration. Always require an
explicit baseDir, soft-handle non-repo GitErrors on status/check
routes, and cover non-git, foreign-cwd, and nested-repo cases.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-31 09:53:09 +00:00
Cursor AgentandSerhii Dziupin be572c1692 fix(files): address autosave migration and review regressions
Seed omitted autoSaveEnabled from the hydrated client preference (including
legacy localStorage) instead of resetting everyone to enabled. Restore SVG
non-editable flags, treat clean draft saves as success, and throw again from
disposed content-cache owners while keeping runtime-switch cache invalidation.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-30 11:29:37 +00:00
Cursor AgentandSerhii Dziupin fc4db0c656 fix(files): keep text opens working after content-cache dispose
React Strict Mode disposed the memoized content-cache owner while the
provider kept reusing it, so validateContextFileOpen threw before any
/api/fs/read and toasted "Failed to open file" for notes.txt. Binaries
still opened because they skip the pre-read. Serve uncached reads from
disposed owners, clear cache on runtime switch without deactivating, and
own the cache lifecycle in an effect.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-30 09:02:14 +00:00
Cursor AgentandSerhii Dziupin d35cf957ac fix(files): pass directory into context panel binary open guard
Scope context-file open validation to the active project directory so
binary opens resolve against the correct workspace root.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-30 08:22:10 +00:00
Cursor AgentandSerhii Dziupin 4f30a00814 fix(files): let context panel open binaries into FilesView safely
Skip UTF-8 pre-read for known binary/image/PDF paths so the shared
editor can show preview or cannot-preview instead of failing open or
decoding binaries as text.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-30 07:05:34 +00:00
Cursor AgentandSerhii Dziupin d79908cc9e test(ui): cover autoSaveEnabled settings sync round-trip
Ensure the new persisted editor autosave flag applies from server
settings, autosaves through appearanceAutoSave, and resets to true when
omitted from an authoritative snapshot.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-30 06:39:57 +00:00
Cursor AgentandSerhii Dziupin 5b727ed53c fix(files): prevent autosave data loss on load lag and binary files
Guard FilesView autosave until the selected file has finished loading,
refuse binary/PDF/office/archive text saves, and add a persisted global
autoSaveEnabled setting (default true) under Settings → General.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-30 06:37:47 +00:00
Cursor AgentandSerhii Dziupin 0caff15b3e fix(desktop): Linux AppImage tray menu and system file-manager icons
Resize Linux tray icons so StatusNotifier hosts show them, add Show/Hide/Close
context-menu actions, and resolve FreeDesktop theme icons for Open-in apps
(including the default file manager) instead of skipping Linux icon fetch.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-07-28 17:57:44 +00:00
Cursor AgentandSerhii Dziupin f172119921 chore(deps): remove unused react-syntax-highlighter
react-syntax-highlighter (and its @types) is no longer imported anywhere —
code highlighting is handled by the Shiki web worker. Drop the dead deps.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-06-26 11:26:11 +00:00
Cursor AgentandSerhii Dziupin 05dd270a9a perf(ui): lazy-load html-to-image and snapDOM
Both are only needed on explicit user actions (export message as image,
capture preview annotation screenshot). Defer them with dynamic import so
~140 KB leaves the eager app-shell graph.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-06-26 11:26:11 +00:00
Cursor AgentandSerhii Dziupin 3d27c0a0ca perf(build): fix bun .bun chunk parsing and isolate Vite preload helper
The manualChunks package-name parser used the first node_modules/ segment,
which under bun's isolated install (.bun/<pkg>@<ver>/node_modules/<pkg>) is
always '.bun'. This collapsed nearly every dependency — including lazy-only
heavy libs (Shiki langs/themes, transformers, katex, mermaid, elkjs, etc.) —
into one 18.5 MB eager 'vendor-.bun' chunk, defeating all code splitting.

- Resolve the real package from the LAST node_modules/ segment.
- Pin Vite's __vitePreload helper to its own chunk so Rollup stops
  co-locating it inside vendor-shiki and dragging Shiki core + the 629 KB
  oniguruma engine into the eager bootstrap.
- Drop the now-dead react-syntax-highlighter chunk rule.

Eager bootstrap graph drops from ~18.5 MB to ~0.44 MB.

Co-authored-by: Serhii Dziupin <makeittech@users.noreply.github.com>
2026-06-26 11:26:11 +00:00