Skip to content

feat: notebook loading state for daemon-owned doc population #599

@rgbkrk

Description

@rgbkrk

With daemon-owned notebook loading (#598), the frontend won't have cells immediately at window creation — it receives them via Automerge sync once the daemon loads the file and the relay forwards the doc.

This is usually fast (especially for previously-opened notebooks where the daemon already has the doc), but there's a real window where the frontend has an empty doc. That window should feel intentional and polished.

What to build

  • Loading state in the notebook UI while waiting for the first sync payload
  • Transition from loading → cells rendered should feel seamless
  • Handle edge cases: daemon slow to connect, large notebooks, daemon restart mid-load

Detection

The frontend WASM handle knows when it has cells: handle.get_cells_json() returns [] until the first sync lands. useSyncExternalStore already drives re-renders on sync, so the transition from empty → populated should be automatic.

Design considerations

  • Keep it lightweight — a skeleton/shimmer or simple spinner, not a full splash screen
  • Consider whether the loading state should be per-cell or whole-notebook
  • The window title / tab should still show the notebook name immediately (Tauri knows the path from the open request)

Dependencies

Blocked on #598 (daemon-owned loading) — until then, cells are populated synchronously before the window opens and there's no loading state to show.

Size

S–M

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions