Skip to content

refactor(ui): one chip and one tree strip - #446

Merged
daggerok merged 1 commit into
mainfrom
refactor/chip-and-strip
Dec 4, 2026
Merged

daggerok merged 1 commit into
mainfrom
refactor/chip-and-strip

Conversation

@daggerok

@daggerok daggerok commented Dec 4, 2026

Copy link
Copy Markdown
Owner

What

  • src/viewer/ui/Chip.tsx: one chip for the navbar strip (role="button", Enter and Space press it, the checkbox keys stay the checkbox's, Alt+Left and Alt+Right move a movable chip, the fold ▶). The chip lines live here too, with two new kinds for the tree: source (thick dashed) and part (thin solid, plain name). chip.ts is folded into it: on a Mac's case-insensitive disk ./chip and ./Chip resolved to the same file
  • src/viewer/ui/ScopeStrip.tsx: the strip drawn from a scope tree (app/scope-tree.ts): the pinned root chip, the rest in EdgeScrollRow, folds, frames from framedNodes, checkboxes through toggleNode and toggleLeaf, a click on an account through onlyNode, drag and Alt+arrows among the chips of one parent, the focus kept after a key move, a level with one child drawn as one chip (chipKids, chipLabel)
  • AccountTabs.tsx deleted: App feeds ScopeStrip a Fidelity-only tree; the scope, folds and orders stay saved in today's words through leavesOfScope, scopeOfLeaves, foldKey, moveChip in derive.ts (+ test)
  • AdpSourceChips uses Chip and loses its copy of the key handler
  • a11y tests of the strip moved to ScopeStrip (same assertions; the chips' data-scope is now the node id)

Why

Step 4 of the scope tree plan: one chip and one strip for every source. The strip looks and acts exactly as before

Checks

  • bun test: 621 pass, 0 fail
  • parcel build --dist-dir ./.check/out + DIST=.check/out bun src/build/postbuild.ts
  • .claude/tools/etfs/tc/check.sh on the new and changed files: no output
  • git diff --check
  • Chrome on localhost:1237 with made-up data (5 made-up accounts in 2 groups, made-up 401k rows), main vs this branch: text, position, size, classes, aria-expanded, aria-keyshortcuts, title, tabindex, draggable and checkbox state and label of every strip chip, money-source chip and tab on Summary, Positions and ADP Summary at full width and Summary and ADP Summary in a 390 px iframe: identical. The same 30 steps on both (checkboxes, an account chip, Enter and Space, folds, drag of an account within its group and into another group, drag of a group, Alt+Right on an account and a group, the ADP money-source chips and boxes, the logo) give identical saved scope, folds, orders, hidden sources, frames, checkbox states, focus and card title

@daggerok daggerok closed this Dec 4, 2026
@daggerok daggerok reopened this Dec 4, 2026
@daggerok
daggerok merged commit 4037100 into main Dec 4, 2026
1 check passed
@daggerok
daggerok deleted the refactor/chip-and-strip branch December 4, 2026 01:00
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