Skip to content

feat(nav): resolve UX inconsistencies across the application#135

Merged
danielnaab merged 25 commits intomainfrom
story-117/ux-consistency
May 7, 2026
Merged

feat(nav): resolve UX inconsistencies across the application#135
danielnaab merged 25 commits intomainfrom
story-117/ux-consistency

Conversation

@danielnaab
Copy link
Copy Markdown
Member

Summary

  • Move forms under project scope (/:owner/:slug/forms/...) anchoring on the GitHub repo-as-container model
  • Add /projects directory page and unify breadcrumbs across all pages using the flex-breadcrumb design system component
  • Add "Forms" tab to RepoNav, replace currentPath with currentSection for reliable nav highlighting

Story

Closes #117

Acceptance Criteria

  • All navigable pages include consistent breadcrumb trails
  • Navigation patterns are unified — users always know where they are and how to get back
  • Design system components used in production all have complete contracts and metadata — intentionally out of scope, split to separate story
  • A brief walkthrough of the app from landing page through form creation shows no jarring transitions

Test Plan

  • bun run check passes (pre-existing biome noExplicitAny error in unrelated test file)
  • 1372 tests pass, 0 fail
  • Type check clean
  • Project-scoped form routes: landing, session creation, page rendering, review, submit, confirmation
  • /projects directory: lists ready projects, filters non-ready, shows owner links
  • /forms directory: shows project context per form, links into project-scoped URLs
  • Header nav: "Projects" links to /projects, currentSection highlighting works for all sections
  • RepoNav: "Forms" tab appears on all project and form pages
  • Breadcrumbs: consistent on all pages, custom HTML fully replaced
  • Deploy and verify at branch URL

Review Notes

  • Route restructuring: Forms moved from /forms/:specId/... to /:owner/:slug/forms/.... No redirects from old URLs (clean break — this is a lab, not production).
  • Legacy routes removed: All /:specId routes cleaned up. Tests fully migrated.
  • AC 3 split out: Component contract completeness is a separate workstream that doesn't block navigation consistency.
  • Known minor gaps: Chat view missing breadcrumb (full-width layout), tree/blob breadcrumb intermediate items lack hrefs. Neither impacts core navigation flow.

@danielnaab danielnaab temporarily deployed to story-117-ux-consistency May 6, 2026 19:36 Inactive
@danielnaab danielnaab force-pushed the story-117/ux-consistency branch from 13f7f5d to 25e552a Compare May 6, 2026 19:49
@danielnaab danielnaab temporarily deployed to story-117-ux-consistency May 6, 2026 19:49 Inactive
@danielnaab danielnaab temporarily deployed to story-117-ux-consistency May 6, 2026 20:05 Inactive
@danielnaab danielnaab temporarily deployed to story-117-ux-consistency May 7, 2026 03:50 Inactive
danielnaab added 22 commits May 7, 2026 04:18
UX consistency — move forms under project scope, add global projects
directory, unify breadcrumbs, add Forms tab to repo nav.
Expose store.list() with no args through the service interface to support
listing all projects across all users, needed for the upcoming /projects
directory page (story #117).
…hting

Replace URL prefix matching with an explicit section enum so header nav
highlighting works regardless of URL structure. The currentPath prop is
kept as a deprecated fallback during migration.
Add 'forms' to the RepoTab union type and insert a Forms tab between
Overview and Pull Requests in the RepoNav component, linking to
/:owner/:slug/forms.
Refactor createFormRouter to support project-scoped URL shapes
(/:owner/:slug/forms/...) alongside legacy specId-based routes.
Extract resolveFormContext helper to unify spec resolution across
all handlers, reducing repetitive boilerplate.
…ssions pages

Wire up the project-scoped form router in server.tsx between the /forms
mount and the owner catch-all. Update the /forms directory listing to
show a Project column with owner/slug links and route form links through
project-scoped URLs. Update My Sessions to use project-scoped URLs for
active session links when a project can be resolved for the spec.
Adds GET /projects that renders a table of all ready projects with
links to each project and owner profile page, plus breadcrumb nav
and currentSection='projects' for header highlighting.
Change the Projects link from /:user to /projects for both
authenticated and anonymous users.
…ponent

Replace custom breadcrumb HTML (repo-header__path nav elements and
hand-rolled breadcrumb lists) with the flex-breadcrumb design system
component across all owner routes and form handlers. Add breadcrumbs
to form pages that previously lacked them (landing, page, review,
confirmation, forms index, my sessions, profile).
…ion, remove deprecated prop

Replace every Layout currentPath prop with currentSection ('home' | 'forms' | 'projects' | 'catalog')
across 13 source files. Remove the deprecated currentPath prop and backward-compat fallback logic
from LayoutProps. Update tests: remove currentPath fallback test, add no-section-means-no-highlight test.
Projects nav link is now shown to both authenticated and anonymous
users, pointing to /projects directory.
Export RepoNav and RepoTab from owner/components so form routes can
import them. Add RepoNav (current="forms") to all five form handlers
that render in project-scoped mode: handleLanding, handleRenderPage,
handleReview, handleConfirmation, and handleChatView. Only rendered
when ctx.owner and ctx.slug are present. Add test asserting repo-nav
and repo-nav__link--current appear on the form landing page.
…d URLs only

All form interaction routes now use the /:owner/:slug/forms/... pattern.
The /forms mount only serves directory pages (form listing, My Sessions,
submission detail). Tests updated to create project-scoped routers.
…on error view

All Layout calls in owner/index.tsx now carry currentSection="projects" so the
global nav highlights the correct section on profile, project, tree, blob,
commits, settings, and error pages. The validation error re-render path in
forms/index.tsx now renders RepoNav alongside the Breadcrumb, matching the
pattern used in all other form page handlers.
Replace the ad-hoc em-based font-size tokens with a complete USWDS 3.13
rem scale (3xs through 3xl). Rename all references:
- --flex-text-uswds → --flex-text-md
- --flex-text-tag → --flex-text-2xs
- --flex-text-base → --flex-text-2xs
- --flex-font-size-xs → --flex-text-xs

The rem units ensure font sizes respect user browser preferences,
improving accessibility over the previous em-based values.
Migrate 80 raw font-size declarations (px, em, rem literals) to the
new USWDS-aligned --flex-text-* token scale. This eliminates ad-hoc
sizing and ensures all text sizes snap to the accessible rem grid.

Values left as raw: heading sizes (h1-h3), USWDS big-button (1.46rem),
and between-token contextual sizes (1.1em, 1.13rem, 1.25rem, 1.34rem)
that have no exact token match.
USWDS normalizes font sizes for Source Sans Pro cap-height, producing
values like 1.06rem (16.96px) not 1.0625rem (17px). Align our tokens
to the exact USWDS output so conformance tests pass.
…ngs tab

Move Settings from a button to a RepoNav tab. Move contextual actions
(Edit form structure, Fork) below the tab bar into the content area.
Add RepoNav to BlobPage and SettingsPage for consistent navigation.
Show the project name as the h1 title on every tab page (Files,
History, Blob) instead of changing it to the tab name. Add
getProjectName to ProjectService for lightweight name lookups.
Add admin section to currentSection type for upstream compatibility.
danielnaab added 2 commits May 7, 2026 04:32
- Hide duplicate h1 in FormLanding when project header already shows
  the title above the tabs (consistent with all other tab pages)
- Move Edit/Fork buttons inline with the clone-bar row instead of
  a separate line above it
@danielnaab danielnaab temporarily deployed to story-117-ux-consistency May 7, 2026 04:36 Inactive
@danielnaab danielnaab merged commit fa8096b into main May 7, 2026
4 checks passed
@danielnaab danielnaab deleted the story-117/ux-consistency branch May 7, 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.

Resolve UX inconsistencies across the application

1 participant