ZDDC/classifier/js
ZDDC 203674ee4c feat(classifier): persist & copy files inside .zip archives
Zip members were live-only: expandable while the source was connected, but the
workspace snapshot dropped the archive (.zip became a plain file), so a
classification made inside one vanished on reopen — and copy couldn't extract it
anyway (it tried to walk the archive path as a real directory).

Now zips are first-class:
- snapshotTree/loadSnapshot persist the scanned archive subtree — zip-root +
  virtual folders + members carry isVirtual/zipPath/zipEntryPath, so the tree
  rebuilds on reopen and assignments inside an archive survive. An archive that
  was never opened persists as a lazy 'zip' node that reopens on demand.
- scanner.ensureZipLoaded(rootHandle, zipPath) reloads an archive from the
  workspace root when the in-memory cache is cold (post-restore); scanZipNode
  falls back to it when a restored zip node has no live file object.
- copy.js reads a member via scanner.extractZipMember (Blob from the archive)
  instead of a non-existent file handle; preview.js reloads the archive for a
  restored member before opening it.

This also reconciles export/import with the snapshot: both now keep zip members,
so a round-trip no longer leaves dangling in-archive assignments.

Tests: zip subtree snapshot round-trip; copy extracts a member to the output (45).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-10 13:27:00 -05:00
..
app.js fix(classifier): Show toggles preserve tree state; add Reset to raw input 2026-06-10 13:02:12 -05:00
classify.js feat(classifier): switch dataset export/import to a filename-per-file format 2026-06-10 11:52:44 -05:00
copy.js feat(classifier): persist & copy files inside .zip archives 2026-06-10 13:27:00 -05:00
dnd.js feat(classifier): drag-and-drop assignment (phase 3) 2026-06-09 12:23:38 -05:00
excel.js feat(shared): non-blocking toast helper available to every tool 2026-05-09 19:04:41 -05:00
filter.js Initial commit 2026-04-27 11:05:47 -05:00
persist.js feat(classifier): workspaces — scan-once, resume from snapshot (phase 6) 2026-06-09 15:07:40 -05:00
preview.js feat(classifier): persist & copy files inside .zip archives 2026-06-10 13:27:00 -05:00
resize.js Initial commit 2026-04-27 11:05:47 -05:00
scanner.js feat(classifier): persist & copy files inside .zip archives 2026-06-10 13:27:00 -05:00
selection.js Initial commit 2026-04-27 11:05:47 -05:00
sort.js Initial commit 2026-04-27 11:05:47 -05:00
spreadsheet.js fix(classifier): drop vestigial Save-All delays that masked a fixed await bug 2026-05-21 17:07:28 -05:00
store.js Initial commit 2026-04-27 11:05:47 -05:00
target-tree.js feat(classifier): live filter box above each file tree (reveals matches + path) 2026-06-10 12:37:36 -05:00
tree.js fix(classifier): search opens only the path to a hit, not the whole tree 2026-06-10 13:10:27 -05:00
utils.js Initial commit 2026-04-27 11:05:47 -05:00
validator.js Initial commit 2026-04-27 11:05:47 -05:00
workspace.js feat(classifier): welcome rewrite + resumable scan + reconnect on restore 2026-06-09 16:38:08 -05:00