Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions desktop/AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ Persisted per profile via `upsertProfileRemote` / Rust `ServerProfile`.
| Off | `bundles/active/app/` | `bundles/active/forms/` |
| On | `bundles/dev-local/app/` (mirror) | `bundles/dev-local/forms/` (mirror if `<folder>/forms` exists) |

Synk downloads and **Refresh from server** on the Bundles page only touch `bundles/active/`. The source folder on disk is **never** modified.
Synk downloads and **Download & apply** on the Bundles page only touch `bundles/active/`. The source folder on disk is **never** modified.

**Bundle download:** `download_and_apply_app_bundle` (TS: `tauriClient.downloadAndApplyAppBundle()`) — native Rust HTTP download; no zip bytes over IPC. Progress events: `bundle/apply-progress`, `bundle/index-rebuild`. Observation index rebuild runs in the background after apply.

### UI

Expand All @@ -64,13 +66,15 @@ On success, Zustand bumps `devMirrorGeneration` so embeds and form lists reload.
- `src/hooks/useDeveloperMode.ts` — profile read/write, refresh, generation counter from store.
- `src/components/DeveloperModePanel.tsx` — full vs banner UI; auto-mirror `useEffect` only on `variant="full"`.
- `src/lib/bundleLayout.ts` — `bundleSegment()`, `bundleFormsRel()`.
- `src/store/useCustodianStore.ts` — `devMirrorGeneration`, `devBusy`, `devError`, `refreshDevMirror`.
- `src/store/useCustodianStore.ts` — `devMirrorGeneration`, `devBusy`, `devError`, `refreshDevMirror`, `bundleActivity`.
- `src/lib/bundleTauriEvents.ts` — bundle apply progress listeners.

### Key Rust

- `profile_developer_mode`, `bundle_segment`, `bundle_form_roots_for_ctx`
- Dev-aware: `list_active_bundle_forms`, `read_bundle_form_spec`, `get_active_bundle_forms_file_base_url`, `scan_bundle_custom_question_types`, `bundle_app_config_path`
- Tests: `validate_custom_app_dev_source_requires_index_html`, `mirror_custom_app_dev_folder_copies_tree`
- `download_and_apply_app_bundle` — streamed Synkronus zip download + apply (never pass large binaries through WebView IPC as `number[]`)
- Tests: `validate_custom_app_dev_source_requires_index_html`, `mirror_custom_app_dev_folder_copies_tree`, `apply_app_bundle_zip_at_workspace_writes_state_and_active`

### Errors

Expand Down
8 changes: 5 additions & 3 deletions desktop/docs/UI_FEEDBACK.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ Single source of truth for how the shell surfaces status, errors, and confirmati

## Progress banner (full-width)

**Use for:** long-running sync and import jobs only.
**Use for:** long-running sync, import, and **app bundle download/apply** jobs.

- Renders below the mode switch / dev bar in `Shell`.
- Shows spinner + status text; dismissible but reappears on next activity.
- Do not use for quick actions (save, auth, bundle download).
- Shows spinner + status text; optional determinate progress bar when `bundleActivity.total > 0`.
- Dismissible but reappears on next activity.
- Bundle apply: Rust emits `bundle/apply-progress` and `bundle/index-rebuild`; `bundleActivity` in `useCustodianStore` drives the banner.
- Do not use for quick actions (save, auth, dev mirror refresh).

## Toasts (bottom-right stack)

Expand Down
18 changes: 17 additions & 1 deletion desktop/src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion desktop/src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ serde = { version = "1", features = ["derive"] }
serde_json = "1"
chrono = { version = "0.4", features = ["serde"] }
rusqlite = { version = "0.32", features = ["bundled", "chrono", "serde_json"] }
reqwest = { version = "0.12", features = ["json", "rustls-tls", "multipart"] }
reqwest = { version = "0.12", features = ["json", "rustls-tls", "multipart", "stream"] }
futures-util = "0.3"
rayon = "1"
uuid = { version = "1", features = ["v4", "serde"] }
thiserror = "2"
Expand Down
Loading
Loading