Commit Graph
18 Commits
Author SHA1 Message Date
Gregory Schier 0a7a9f7a2b Run the desktop's model layer in the browser
The browser host now stores data through yaak-models compiled to wasm — the
same queries, migrations, cascade rules, duplicate naming and first-run
bootstrap the desktop and CLI use — instead of a TypeScript port of them.

- crates/yaak-web: the wasm crate. boot() registers an IndexedDB-backed VFS
  and calls init_standalone; rpc(cmd, payload, label) answers the models_*
  commands via ClientDb and returns the model_writes it caused; blob get/put
  through blob_manager. Built like yaak-templates (pkg/ committed); the
  build script keeps pkg/ and says so when no wasm-capable clang is present,
  so a desktop bootstrap never depends on one.
- models_ops moves from crates/yaak into yaak-models so the wasm crate can
  use it without the send engine.
- The database lives in a SharedWorker (packages/platform/src/web/worker.ts):
  one process holds the data and pushes writes to every tab, as on the
  desktop. Where SharedWorker is missing or its script cannot be fetched, a
  dedicated worker guarded by a Web Lock takes over and a second tab is told
  so. The worker imports the wasm lazily so a tab's connect is answered
  instantly; the tab reconnects if it isn't.
- packages/platform/src/web loses models.ts, schema.ts, db.ts and the
  BroadcastChannel; commands.ts forwards model commands to the worker and
  keeps the fixed answers and refusals.

Verified in Chrome, dev and production builds: bootstrap, CRUD across every
model type, serde defaults, engine-format ids, Rust copy naming, folder
cascade with per-descendant events, single-event workspace delete, reload
persistence, two tabs coherent, Send declined with a toast, 8/8 reloads
rendering in ~100 ms.
2026-08-15 15:48:49 -07:00
Gregory Schier d43de3d95a Keep nested worktrees out of test runs
Test runs from the repo root were picking up every git worktree under .claude,
running 648 tests across 102 files instead of 322 across 34. That made results
misleading rather than just noisy: a failure in an unrelated worktree showed up
as a failure here.

Ignores the directory too. Only settings.local.json was listed, while rules.md
stays tracked.
2026-08-13 09:04:02 -07:00
Gregory Schier dcfdf077e7 Add staged pre-commit checks 2026-05-13 14:22:43 -07:00
Gregory SchierandClaude Opus 4.6 b4a1c418bb Run oxfmt across repo, add format script and docs
Add .oxfmtignore to skip generated bindings and wasm-pack output.
Add npm format script, update DEVELOPMENT.md for Vite+ toolchain,
and format all non-generated files with oxfmt.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 10:15:49 -07:00
Gregory Schier 45262edfbd Migrate to Vite+ unified toolchain (#428) 2026-03-13 09:27:56 -07:00
Gregory Schier 101b6284d6 [WIP] Refactor to NPM workspaces (#104) 2024-09-22 21:27:10 -07:00
Gregory Schier 016c3f7dac Response viewer for PDF (#48)
This PR adds a response viewer for PDF files using `react-pdf`
2024-06-10 08:57:08 -07:00
Gregory Schier acc07780a7 Some fixes after upgrading react-query 2024-05-10 09:19:29 -07:00
Gregory Schier 896e3d5831 Upgrade to Tauri 2.0 (#23) 2024-05-04 14:14:19 -07:00
Gregory Schier 56a30aa7c4 Panel icons 2023-03-25 23:29:04 -07:00
Gregory Schier d7ff52038d Fix header editor and scroll in general 2023-03-13 19:37:36 -07:00
Gregory Schier 90c873e37e Back to React 2023-03-13 09:50:49 -07:00
Gregory Schier 364cdb06df Remove wasm stuff 2023-03-12 21:25:31 -07:00
Gregory Schier 971cd02142 Fix eslint errors 2023-03-11 23:29:25 -08:00
Gregory Schier d8da396c2f Fix Codemirror performance!! 2023-03-09 10:50:55 -08:00
Gregory Schier 5fbc5edb15 Switch to Preact!!! 2023-03-09 00:47:25 -08:00
Gregory Schier de8a36d04b Initial start for WASM 2023-02-18 20:17:01 -08:00
Gregory Schier f3fc1fc0c4 Initial setup Vite Tauri 2023-02-15 16:58:56 -08:00