Skip to content

feat(portal): add PWA support to desktop Blazor client#489

Closed
sytone wants to merge 1 commit into
mainfrom
feat/pwa-support
Closed

feat(portal): add PWA support to desktop Blazor client#489
sytone wants to merge 1 commit into
mainfrom
feat/pwa-support

Conversation

@sytone
Copy link
Copy Markdown
Owner

@sytone sytone commented May 22, 2026

Closes #239

Changes

manifest.webmanifest

  • Added manifest.webmanifest with required PWA fields: name, short_name, start_url, display, theme_color, background_color, icons
  • Icons declared at 192x192 and 512x512 with maskable purpose on 512

service-worker.js (dev)

  • Passthrough service worker -- passes all requests to network, no caching
  • Avoids stale cache issues during development

service-worker.published.js (production)

  • Offline-first caching strategy using .NET-generated service-worker-assets.js
  • Caches all .dll, .wasm, .html, .js, .css, .svg, .png, .webmanifest assets
  • Explicitly passes through /hub/ and /api/ requests (must reach live server)
  • Cache versioning via assetsManifest.version, old caches deleted on activate

BotNexus.Extensions.Channels.SignalR.BlazorClient.csproj

  • Added <ServiceWorkerAssetsManifest>service-worker-assets.js</ServiceWorkerAssetsManifest>
  • Added <ServiceWorker> item to wire dev/published service workers

index.html

  • Added <link rel="manifest" href="manifest.webmanifest" />
  • Added theme-color, mobile-web-app-capable, apple-mobile-web-app-* meta tags
  • Added <link rel="apple-touch-icon"> for iOS home screen icon

Icons

  • icon-192.png and icon-512.png generated as indigo (#4f46e5) placeholder icons with "BN" text
  • Replace with proper brand assets from favicon.svg when available

Tests (12 new)

  • PwaAssetsTests.cs -- verifies all PWA assets exist and manifest has required fields
  • Uses solution-root traversal for path resolution (works in all worktrees)

All 1636 gateway + 349 BlazorClient + 206 CodingAgent tests pass.

@sytone
Copy link
Copy Markdown
Owner Author

sytone commented May 22, 2026

Farnsworth review — PR #489

  • CI: ✅ All checks passing (build-and-test, CodeQL, TruffleHog, patterns, deps)
  • Merge conflicts: ✅ CLEAN / MERGEABLE
  • Commit title: feat(portal): add PWA support to desktop Blazor client ✅ conventional
  • Test coverage: 12 tests in PwaAssetsTests.cs — asset existence, manifest required fields, solution-root path traversal ✅
  • Spec completeness vs [Portal] PWA support -- make the Blazor WASM client installable #239: manifest.webmanifest, dev/prod service workers, meta tags, icons, .csproj wiring ✅
  • Design note: Passthrough dev SW avoids stale cache issues — correct call. /hub/ and /api/ excluded from offline cache — correct, these require live server. Icon placeholders noted with follow-up for brand assets.

LGTM. Ready to merge.

@sytone
Copy link
Copy Markdown
Owner Author

sytone commented May 22, 2026

CI: All checks passing
Merge conflicts: Clean / MERGEABLE
Commit title: Conventional commit format correct
Coverage: 12 PwaAssetsTests verifying manifest, service workers, csproj, index.html
Spec completeness: Closes #239 - manifest.webmanifest, service worker (dev + published offline-first), PWA meta tags in index.html. Note: icons are placeholder indigo squares - brand assets should replace before release.

LGTM - ready to merge.

Copy link
Copy Markdown
Owner Author

@sytone sytone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Farnsworth Review — PR #489

CI: ✅ All checks passing
Merge conflicts: ✅ Clean (MERGEABLE)
Conventional commit title:feat(portal): add PWA support to desktop Blazor client

Test coverage:

  • ✅ 12 PwaAssetsTests (manifest exists, service workers, csproj config, index.html meta)
  • 1636 gateway + 349 BlazorClient pass

Spec completeness vs #239: Full PWA manifest, service workers (dev passthrough + offline-first published), index.html meta tags. Icons are placeholder indigo squares — flag for brand asset replacement before final release.

Note: /hub/ and /api/ correctly excluded from service worker cache.

LGTM. Ready to merge.

@sytone
Copy link
Copy Markdown
Owner Author

sytone commented May 22, 2026

Closing as part of a planned hard-reset of the in-flight branch set so the new domain-model refactor can land on a clean trunk.

Audit verdict: keep

Rationale: Portal/UI. No domain impact.

The new plan (in session state) reshapes core types: Citizen (User+Agent union), Vogen-generated value objects, ThreadId removed in favour of composite ChannelAddress, mark-not-delete compaction, centralised SessionContextProjector, single-path routing. Many in-flight branches touch contracts that are about to change — rebasing later would be more work than rebuilding on the new shape.

If this work is still wanted, refile as a new issue/PR against the post-refactor contracts.

@sytone sytone closed this May 22, 2026
@sytone sytone deleted the feat/pwa-support branch May 22, 2026 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Portal] PWA support -- make the Blazor WASM client installable

1 participant