Files
buzz/desktop
Matt Toohey 3ed98a8048 feat(desktop): serve Project Canvas avatars over a host route
Canvas frames run with `connect-src 'none'`, so a widget's only avatar
source was a `data:` URL inlined into the RPC reply. Every picture was
therefore charged against the 64 KiB port-message ceiling, and overrunning
it failed the whole lookup — display names included — so the host could
inline only a handful and the rest fell back to initials.

Add `buzz-canvas://…/__buzz/avatar/<pubkey>`: the host publishes fetched
avatar bytes to the backend, and the frame loads them as ordinary images,
lazily and cached, outside any message. Widgets pass `pubkey` to
`sdk.ui.avatar` instead of `avatarUrl`; the existing `avatarUrl` path
still renders, so packages written before the route keep working.

The store is keyed by project rather than by load, because publishing and
frame creation race in both directions and a 404 is never retried. It is
bounded by an LRU over 4 projects, 64 avatars and 512 KiB per project, and
32 KiB per avatar. Bytes are magic-byte-matched against their declared
type, the content type served is an allowlisted `&'static str` rather than
the caller's string, the route requires `project.people.read`, and the
project comes from the bound load, never from the request.

Signed-off-by: Matt Toohey <contact@matttoohey.com>
2026-09-02 15:02:24 +10:00
..
2026-03-09 13:02:11 -07:00
2026-06-11 15:06:24 +00:00
2026-03-09 13:02:11 -07:00

Buzz

Desktop chat shell with:

  • Tauri + React + TypeScript + Vite
  • Tailwind CSS
  • shadcn/ui-ready shared components
  • Biome (lint/format/check)
  • Feature-driven frontend structure

Scripts

  • pnpm dev - run the web frontend
  • pnpm tauri dev - run the desktop app
  • pnpm build - typecheck and build frontend
  • pnpm typecheck - TypeScript checks
  • pnpm lint - Biome lint
  • pnpm format - Biome format (write)
  • pnpm check - Biome check

Structure

  • src/shared - reusable app-wide code (ui, lib, styles)
  • src/features - feature modules (vertical slices)
  • src/app - top-level app composition