Commit dd814f2
committed
Phase 3: Consolidate global state into AppState object
- #28: Created centralized AppState object consolidating 11 global variables
- Organized state into logical sections:
* focusTraps (includeEditor, validationReport, diffReport)
* Configuration data (publishers, copyrights, selectedCopyrights)
* Include blocks (includeBlocks, currentEditingIncludeId)
* Form state (hasUnsavedChanges, originalLoadedValueSet)
* Drag and drop (draggedElement, draggedIncludeElement)
* Preview debouncing (updatePreviewTimeoutId)
- Replaced ~102 references throughout codebase
- Reduced global variables from 11 to 1
- Improves code organization and maintainability
Completes Option C (Enhanced Single File) implementation.
All 6 medium-priority tasks now complete (#25, #26, #27, #28, #29, #31).
Resolves #28
Co-Authored-By: Claude Code - Sonnet 4.5 <anthropic.com>1 parent 817e2dd commit dd814f2
2 files changed
+118
-113
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
113 | | - | |
| 113 | + | |
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
| 122 | + | |
122 | 123 | | |
123 | 124 | | |
124 | 125 | | |
| |||
0 commit comments