refactor(chunk): restructured selector resolution and state lookup with unified classification

- Refactored chunk selector resolution to extract and preserve raw selector strings separately from parsed CRC checksums.
- Reorganized chunk state lookup infrastructure with dedicated maps for checksum, leaf, and suffix-based chunk resolution.
- Simplified batch operation CRC validation to auto-accept stale checksums for subsequent operations on the same chunk.
- Unified TypeScript interface and Nix attrset chunk classification with consistent naming and nested expression handling.
- Extracted clipboard utility functions to dedicated module with improved OSC 52 and Termux support.
- Updated chunk read formatting with anchorStyle parameter and ellipsis standardization for improved consistency.
This commit is contained in:
can1357
2026-04-07 03:36:57 +02:00
parent 3944b0f7f5
commit ad4c5917a4
12 changed files with 761 additions and 351 deletions
+4
View File
@@ -1,6 +1,7 @@
# Changelog
## [Unreleased]
### Added
- Added `anchorStyle` parameter to chunk read formatting to control chunk path display format (full, kind, or bare)
@@ -21,6 +22,9 @@
### Changed
- Updated chunk edit prompt documentation to use ellipsis (…) instead of ellipsis (...) for consistency in operation examples
- Modified chunk path parsing to preserve raw selector strings and extract CRC separately, enabling accurate chunk reference round-tripping in read/edit workflows
- Changed chunk edit behavior to auto-accept stale CRC checksums for subsequent operations on the same chunk within a batch, improving usability when applying multiple edits to the same target
- Moved `copyToClipboard` and `readImageFromClipboard` functions to new `utils/clipboard.ts` module with improved OSC 52 support and Termux compatibility
- Updated grep output mode to use `GrepOutputMode` enum from pi-natives instead of string literals
- Changed macOS appearance observer to use `MacAppearanceObserver.start()` class method with error-first callback signature