Skip to content

Major redesign towards a server rendered app#101

Merged
shaddi merged 4 commits into
mainfrom
server-rendered-app
Jun 13, 2026
Merged

Major redesign towards a server rendered app#101
shaddi merged 4 commits into
mainfrom
server-rendered-app

Conversation

@shaddi

@shaddi shaddi commented Jun 13, 2026

Copy link
Copy Markdown
Member

This is pretty much a rewrite of the entire BDK application's user experience, while maintaining the core coverage computation more-or-less unchanged. The biggest architectural change is moving away from a next.js/React-based SPA to an htmx-based server-side rendered app. Most of the application is just forms so it's simpler and cleaner to use that approach rather than treating everything as a dynamic component; this will also massively simplify the frontend codebase.

The more substantial change is a significant overhaul of the whole user experience to bring BDK more in line with the original "turbotax for BDC" vision. We introduce an explicit notion of "filings" that are tied to the BDC cadence, add a checklist of remaining tasks to complete before a filing can be submitted (essentially checking what the user has entered so far and directing them to the next task), and make the new filing flow more explicit for return users (including adding checks on fabric version matches). We add a number of more utilitarian UX improvements -- backend async tasks now have a single status endpoint that can update the UI when any org member is making an update, while also explaining what is being updated; the entry for coverages and plans is simplified and restructured; and the entire application doesn't force any specific order of inputting data (e.g., a user can proceed with adding all their coverages and service plans without uploading a fabric.

This is largely additions because we are preserving the old SPA-based version of BDK alongside this and just updating our routes to point to the new server-side rendered app's endpoints. In principle, the entire old version of BDK is still there and accessible.

For testing -- I've ensured that the same coverage files and edits submitted via the new UI produce identical outputs as the current prod version, and I've manually tested all flows through the create/edit/finalize process for a submission.

shaddi added 4 commits June 12, 2026 00:46
- Service plans: named speed/latency/category bundles per technology,
  one default per technology per filing, assignable per file. Plan
  values write through to the per-file columns, so the compute and
  export pipeline is unchanged.
- BDC filing windows as pure date math (June/December data dates,
  weekend-rolled due dates, fabric version numbering), an explicit
  filed/reopened status, and folder lineage for snapshots.
- Fabric intake v2: classifies CostQuest delivery files by role
  (active / non-BSL / supplemental), checks the delivery's fabric
  version against the filing's window (overridable), and replaces a
  prior delivery cleanly. Supplemental addresses feed search only.
- An org-scoped jobs stream (SSE) with a plain-language catalog of
  worker operations, and a sweep that fails tasks orphaned by a dead
  worker instead of leaving them pending forever.
- A per-file coverage buffer override for wired files (100 m default).
- Contract tests for the file, fabric, map, export, and organization
  endpoints, which previously had none.
A site-wide theme picked in the admin panel (three civic variants,
light default) and stored as a site setting; admin management of users
(disable/enable, password reset, org reassignment) and organizations
(create, rename, delete) with audit logging; verification and reset
emails carry clickable links instead of bare tokens.
A complete server-rendered workflow beside the existing SPA, served by
Flask through nginx and styled by a shared civic design system
(Jinja2 + htmx pages; the map is a standalone MapLibre island):

- a guided setup funnel: organization, fabric delivery, first coverage
  files, then into the app;
- files & plans: fabric intake with vintage warnings, coverage files
  with technology/plan pickers and the wired buffer setting, plan
  management with per-technology defaults;
- the map studio: one location layer colored by served state,
  plan-aware point popups answered from the database, drawn-area edits
  with per-technology verbs (exclude / set plan), and saved edits that
  reopen for reshaping (vertex drag, midpoint insertion) or deletion;
- submissions: a debt selector listing exactly what stands between the
  filing and a valid availability CSV, generation as a tracked job
  with an inline snapshot, explicit filed/reopen status;
- a filing switcher: carry-forward into a newly opened BDC window and
  creation of any past window's filing (copy or from scratch);
- auth pages (login, register, reset, verify) on the same shell;
- a live job pill and tray over the org-scoped SSE stream.

The SPA keeps working unchanged at / until cutover; the new pages live
at their final paths (/setup, /files, /map, /submissions, /org). An
end-to-end replay drives the new endpoints and asserts the generated
export is identical to the legacy pipeline's.
@shaddi shaddi merged commit bed430a into main Jun 13, 2026
3 checks passed
@shaddi shaddi deleted the server-rendered-app branch June 13, 2026 04:39
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.

1 participant