Commit graph

2 commits

Author SHA1 Message Date
be5b3967ba feat(classifier): unify all tables on seltable — multi-sort + autofilter + resize
Every column table in the classifier now has the same three powers: multi-column
sort, per-column autofilters, and drag-resizable widths. Two of the three tables
were each missing one; the fix is to make the shared seltable the single engine.

- shared/seltable.js: add multi-column sort (click a header to sort; shift/ctrl-
  click ADDS a secondary key; asc→desc→off cycle; ▲/▼ + priority indicator) and
  self-contained drag-resizable columns (a .seltable__resizer on each title th —
  no dependency on the classifier-only resize.js, since the tables tool shares
  seltable). New opt-in opts.persistKey persists widths + sort to localStorage.
- By-tracking grid → seltable (target-tree.js): the bespoke merged-cell table is
  replaced by a seltable (status badge, original-name preview link, editable
  tracking/rev/title inputs, ✕). It inherits sort + autofilter + resize for free.
  The Columns ▾ chooser now rebuilds the seltable; widths + sort persist under the
  same prefs key. Grid is self-correcting — a column-set change rebuilds on render.
- Worklist (already seltable): gains sort + resize automatically; the derived
  Source column is marked non-sortable/non-filterable.
- The Rename-in-place spreadsheet already had all three (sort.js + filter.js +
  resize.js) — no change needed there.
- seltable.css: .seltable__resizer / .seltable__sortind / sortable-header cursor.
- tests: seltable multi-sort (header click, shift-add, indicators) + resize
  (drag widens + persists via persistKey); the grid's selectors move off the old
  .ttable--grid onto .seltable__table. 66 classify + 56 classifier/tables green.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-16 08:09:35 -05:00
93f1eb8d63 refactor(seltable): promote to shared/ with per-column autofilters
Move classifier/js/seltable.js → shared/seltable.js so both the classifier and
the tables tool can use it (the MDL realignment splits work across both). Adds
per-column autofilter inputs (one per column, AND-combined) on top of the
programmatic global filter; selection + select-filtered + ctrl-Enter unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-11 14:40:56 -05:00
Renamed from classifier/js/seltable.js (Browse further)