Skip to content

Complete dashboard redesign and onboarding overhaul#242

Merged
elkimek merged 24 commits into
mainfrom
redesign
May 19, 2026
Merged

Complete dashboard redesign and onboarding overhaul#242
elkimek merged 24 commits into
mainfrom
redesign

Conversation

@elkimek
Copy link
Copy Markdown
Owner

@elkimek elkimek commented May 18, 2026

Full Branch Review Request

This PR is the complete redesign branch into main, not a single-commit follow-up. Please review the end-to-end branch diff across all commits and changed files.

Scope at creation:

  • Base: main at c2a61d3
  • Head: redesign at a97ca7c
  • Commits: 15
  • Changed files: 88

What Changed

Product redesign

  • Reworked the app shell, sidebar, navigation structure, dashboard presentation, and theme polish.
  • Added persistent lens-style routes for Labs, Genome, Body, Light, Insight, and Recommendations.
  • Added mobile bottom navigation and mobile touch-target polish.
  • Added dashboard.png for the repository page.

Empty-state onboarding

  • Split the guided tour into separate empty-profile and populated-dashboard tours.
  • Runs the empty-profile guided tour on first visit.
  • After the empty tour, opens chat as the primary path for a new user.
  • Simplified the empty dashboard by removing the crowded manual-context surface.
  • Keeps direct import available, but routes new users through chat/context collection first.
  • Supports no-provider users without pushing AI setup before context collection.

Performance and loading

  • Improved Lighthouse startup behavior and empty-state LCP/CLS.
  • Deferred startup-heavy work such as sync/SNP initialization after first paint.
  • Lazy-loaded PDF import code through shared js/import-loader.js.
  • Expanded service-worker app shell coverage for newly reachable modules.

Accessibility and quality

  • Addressed axe accessibility findings from the redesign audit.
  • Improved mobile interaction/touch ergonomics.
  • Added and updated tests around guided tours, onboarding, chat, sync lazy loading, and shared import loading.
  • Addressed prior automated review findings around chat continuation heuristics, lazy loader retry behavior, and duplicate PDF import loaders.

Review Focus

Please review the whole branch for:

  • Behavioral regressions in import, dashboard navigation, chat onboarding, and profile switching.
  • Mobile layout, touch behavior, and empty-state usability.
  • Performance risks from the redesigned shell and newly added routes.
  • Accessibility issues that remain after the axe pass.
  • File-size/refactoring opportunities that should block merge versus follow-up cleanup.
  • Service worker/cache invalidation correctness for the static app.

Verification Run

  • node tests/test-chat-actions.js
  • node tests/test-correctness-phase2.js
  • node tests/test-sync.js
  • npm test
  • PORT=8000 node tests/test-dev-server-origin.js
  • PORT=8000 NODE_PATH=node_modules PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome node run-tests.js
  • Focused Puppeteer first-run onboarding smoke
  • git diff --check

Notes

  • This replaces closed PR Redesign dashboard onboarding and guided tour #241, whose description was too narrow and could make reviewers focus only on the latest follow-up commit.
  • Untracked local files intentionally excluded from this PR: AGENTS.md, tests/test-theme-responsive-e2e.js.
  • The optional local responsive E2E file remains untracked and is not part of this PR.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 18, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
get-based Ready Ready Preview, Comment May 19, 2026 4:11am

@greptile-apps
Copy link
Copy Markdown

greptile-apps Bot commented May 18, 2026

Greptile Summary

This PR merges the full redesign branch: a comprehensive dashboard and onboarding overhaul, new persistent lens-style navigation routes, performance improvements via deferred sync/SNP init and lazy PDF import loading, and expanded PWA service-worker shell coverage.

  • New lens routes (Labs, Genome, Body, Light, Insight, Recommendations) are wired through a validated navigate() router with per-profile last-view persistence; the sidebar is rebuilt around SVG icons and grouped sections.
  • Onboarding is split into an empty-profile tour and a populated-dashboard tour; the AI provider quiz is now session-gated (sessionStorage providerRequested) rather than permanently skippable via localStorage, correctly routing new users through context collection first.
  • Performance and correctness fixes from prior review round are present: !response.ok guard in cacheResponse, 800 ms maybeShowAnalyticsConsent deferral, loadPdfImport() try/catch in both drop-zone and file-input handlers, and removal of high/low from the incomplete-response heuristic.

Confidence Score: 4/5

Safe to merge with two known rough edges: the auto-continuation error path that silently drops the first-leg response on a mid-continuation failure, and the open-code-fence gap in the incompleteness heuristic.

The bulk of the redesign is behaviorally correct and the prior-review fixes are all present. The chat continuation feature has a latent gap: when _callChatAPIWithContinuation throws a non-abort error on the second leg, aiMsgEl.textContent — which already contains the full first-leg response — is never pushed to chatHistory, so the user loses that text on reload. This path is exercised any time a network error or rate-limit hits a continuation request, which is more likely now that continuation fires automatically after every long response.

js/chat.js — the sendChatMessage and runDiscussionRound non-AbortError catch blocks; service-worker.js — the expanded APP_SHELL list where a single bad path blocks install for new users.

Important Files Changed

Filename Overview
js/chat.js Auto-continuation logic added; non-AbortError catch paths still do not persist first-leg text to chatHistory on continuation failure
service-worker.js cacheResponse !response.ok guard added; expanded APP_SHELL creates atomic install risk if any path is wrong
js/main.js Deferred initSync and lazy PDF import; analytics consent properly re-deferred to 800ms
js/views.js New validated router with per-profile last-view persistence and five new lens views
js/nav.js Full sidebar rebuild with SVG icon system and persistent lens entries
js/import-loader.js Correct lazy-loader with retry-safe reset-on-failure pattern
js/sync.js primeSyncState for pre-paint readiness; lazy BIP-39/QR loaders with reset-on-failure
js/tour.js Split empty-profile and populated-dashboard tours; completion opens chat panel
js/pdf-import.js Import preview UI revamped with accessible markup, filter/search, and ARIA live region

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Page load / DOMContentLoaded] --> B[primeSyncState]
    B --> C[navigate to getInitialView]
    C --> D{route valid?}
    D -- no --> E[dashboard]
    D -- yes --> F[restored last view]
    E & F --> G[rAF + setTimeout 0]
    G --> H[initSync deferred]
    G --> I[ensureSNPTable deferred]
    C --> J[renderChatMessages]
    J --> K{chatHistory empty?}
    K -- no --> L[show conversation]
    K -- yes --> M{hasProfile?}
    M -- no --> N[Stage 1: profile form]
    M -- yes --> O{isAIPaused?}
    O -- yes --> P[re-enable prompt]
    O -- no --> Q{providerRequested in sessionStorage?}
    Q -- yes --> R[Stage 2: provider quiz]
    Q -- no --> S{hasData and extrasDone?}
    S -- no --> T[Stage 3: context tasks]
    T --> U[Connect AI sets sessionStorage flag]
    U --> R
    T --> W[Import labs via lazy loadPdfImport]
    T --> X[Skip to extrasDone]
    S -- yes --> Y[Stage 4: regular chat UI]
Loading

Reviews (8): Last reviewed commit: "Guard service worker cache writes" | Re-trigger Greptile

Comment thread js/views.js
Comment thread js/main.js
Comment thread js/chat.js Outdated
Comment thread js/main.js Outdated
Copy link
Copy Markdown
Owner Author

elkimek commented May 18, 2026

Follow-up for Greptile full-branch review pushed in d56bb85.

Fixed:

  • Guarded PDF import lazy-load failures in both file input and drop-zone paths, with user-visible retryable errors.
  • Cleared selected file input after lazy-load failure.
  • Removed high/low from the chat continuation trailing-word heuristic.
  • Restored the 800 ms deferred analytics-consent timing after initial navigation.
  • Added regression assertions for the reviewed cases and bumped version.js.

Verification after the fix:

  • node tests/test-chat-actions.js
  • node tests/test-correctness-phase2.js
  • npm test
  • PORT=8000 node tests/test-dev-server-origin.js
  • PORT=8000 NODE_PATH=node_modules PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome node run-tests.js
  • git diff --check

Untracked local files remain excluded from the PR.

Copy link
Copy Markdown
Owner Author

elkimek commented May 18, 2026

Mobile theme chrome follow-up pushed in de1d0d7.

Fixes the mobile system/browser navigation color drifting light under dark custom themes, especially synth-sunrise:

  • Applies the saved app theme to theme-color metas in the inline head script before main app boot.
  • Updates root color-scheme during runtime theme/sunset changes.
  • Sets document root background + dark default color scheme, with light theme opting into light controls.
  • Aligns manifest default theme_color with the dark app chrome.

Verification:

  • node tests/test-a11y-phase3.js
  • node tests/test-correctness-phase2.js
  • focused mobile Puppeteer smoke for synth/light/neuromancer/sunset chrome metadata
  • npm test
  • git diff --check

Comment thread service-worker.js
Comment thread service-worker.js Outdated
@elkimek elkimek merged commit 4294c07 into main May 19, 2026
5 checks passed
@elkimek elkimek deleted the redesign branch May 19, 2026 09:18
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