Conversation
Simplify the codebase by deleting unused infrastructure that was ported from FidoCadJ (or stubbed for future work) but never wired to a consumer. No behavioral change; full test suite, production build, and export fixtures remain green. - Strip boilerplate @file/@author/@copyright headers from src and test (per AGENTS.md "no boilerplate file headers"). - Remove dead files: FontG, UndoState, LibraryListenerAdapter. - Remove the unused LibraryModel observer system (event classes, listener registration, and fire* plumbing); no production code ever registered a listener. - Delete 54 never-called accessor methods and the fields they orphaned, plus the unused createRenderCtx factory. - Delete the abandoned AbstractExport base class (no exporter extended it); keep the live escapeLatex helper, renamed to LatexEscape. Net: ~2,400 lines removed across 185 files.
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
Simplifies the codebase by deleting unused infrastructure that was ported from FidoCadJ (or stubbed for future work) but never wired to a consumer. No behavioral change — the full Vitest suite (721 tests), production build, and the byte-stable export fixtures all remain green.
Net: ~2,400 lines removed across 185 files; 10 files deleted, 1 added.
What changed, by tier
1 — Boilerplate & dead files
@file/@author/@date/@brief/@copyrightheaders fromsrc/andtest/(per AGENTS.md's "Do not add boilerplate file headers").FontG.ts,UndoState.ts(+ its test),LibraryListenerAdapter.ts.2 — Unused observer system in
LibraryModelAddEvent,RemoveEvent,RenameEvent,KeyChangeEvent,LibraryListener), listener registration, and allfire*plumbing. No production code ever registered a listener — the macro-picker UI rebuilds via a directforceUpdate()(pull), not the push-based events.3 — Dead accessors & orphaned state
getX/setX/isXmethods across 18 files (mostly Java-port stubs: "Phase 4" placeholders, always-truevalidators, unwired image-overlay controls), plus the fields they orphaned and the unusedcreateRenderCtxfactory.4 — Abandoned exporter base class
AbstractExport(~226 lines) — written but never extended; the four exporters allimplements ExportInterfacedirectly. Kept the liveescapeLatexhelper, moved toLatexEscape.ts.What was intentionally left alone
getX()/setX()→ public-field conversion: accessor names are shared across many classes and TS has no method→field inline refactor, so a mechanical text rewrite isn't safe. Limited to dead-accessor removal.Verification
npm run verify(tsc strict + 721 tests) ✅npm run build✅npm run lint— 0 errors (3 pre-existing warnings, untouched files) ✅