Repository navigation
Conversation
…any items Generic multi-select from a hierarchical catalog (products with variants, category trees): leaf-only selection with tri-state parents, search that auto-expands to matches, a role=tree with roving focus, and one onCommit with the picked leaves. Group rows open/close on click with an eased height and a rotating caret; item rows tick on click. Labels in English and Japanese. Includes docs, a changeset, and a /showcase/tree-picker page. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 12, 2026
Contributor
Code Metrics Report
Details | | main (95bc8f2) | #597 (1e1a88c) | +/- |
|---------------------|----------------|----------------|-------|
+ | Coverage | 88.7% | 88.8% | +0.1% |
| Files | 208 | 216 | +8 |
| Lines | 6285 | 6488 | +203 |
+ | Covered | 5575 | 5766 | +191 |
+ | Test Execution Time | 2m21s | 1m32s | -49s |Code coverage of files in pull request scope (0.0% → 94.0%, patch 94.0%)
Reported by octocov |
# Conflicts: # docs-manifest.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
TreePicker: a dialog for picking many items out of a hierarchical catalog (products with variants, category trees, warehouses → bins) and handing them back in one batch.It is generic and standalone.
datais opaque to the picker, andonCommitreturns the picked leaves for the app to use. It was split out of #595 so it can be reviewed on its own; #595 (LineItems) builds on it, and its demo uses the picker for "Bulk add".Behaviour
prefers-reduced-motion.role="tree"with roving focus.treeitemalready exposes checked and expanded state.defineI18nLabels; any label prop overrides them.Dialog, so open/close uses the shared dialog motion. A separate draft PR proposes tuning that motion for every dialog.Notes for review
renderRow({ node, depth }),matchesSearch({ node, query })), so fields can be added later without breaking callers.i18n.tsimports@/contexts/appshell-contextfirst, as a side effect. This works around a pre-existing module cycle in@/hooks/i18n, and will be removed when that cycle is fixed separately.Test plan
vitest: 53 TreePicker tests (selection, search, keyboard, row clicks, snapshots), plus the full suitetsc,oxlint,pnpm docs:check,check-dts/showcase/tree-picker: open, expand, pick, commit🤖 Generated with Claude Code