- Implemented custom code block system for frontend and editors
- Integrated Prism.js for syntax highlighting (YAML + HTML support)
- Added copy-to-clipboard functionality with hover-based UI
- Introduced custom Gutenberg block for code input
- Added Classic Editor button for quick code insertion
- Implemented server-side rendering via the_content filter
- Added dedicated styling (code.css) with Dracula-inspired theme
- Added editor preview styling (editor.css) for visual consistency
- Ensured accessibility and keyboard support for copy button
- Optimized asset loading and versioning using filemtime()
This feature provides a lightweight, theme-native alternative to external code highlighting plugins.
- reorganized /inc directory structure for improved separation of concerns
- grouped files into customizer, utilities, and tools
- improved naming consistency across files (e.g. *-settings, template-tags, etc.)
- simplified functions.php includes for better readability and maintainability
- refactored Customizer structure
- extracted image optimizer settings from core-settings into dedicated module
- consolidated settings, UI logic, and styles into a single feature file
- improved naming consistency for hooks and functions
- standardized Image Optimizer admin tool
- renamed "Performance Tools" to "Image Optimizer" across UI and hooks
- updated admin page registration, callback names, and menu labels
- aligned AJAX nonce naming for consistency and clarity
- preserved all existing logic and behavior (no functional changes)
- improved overall code organization and long-term maintainability
no breaking changes
- Reorganized Customizer structure for improved clarity and maintainability
- Introduced consistent default values for all settings to ensure stable fallbacks
when no user preferences are defined
- Refactored scroll-driven TOC implementation:
- Optimized scroll handling using requestAnimationFrame
- Reduced layout thrashing and unnecessary DOM reads
- Improved heading detection logic (deterministic viewport trigger)
- Enhanced positioning logic (responsive alignment + sidebar awareness)
- Improved footer collision handling for more robust layout behavior
- Added optional IntersectionObserver-based TOC implementation:
- Event-driven alternative to scroll-based approach
- Currently not enabled by default
- May not be supported long-term due to less deterministic behavior
- General cleanup and internal consistency improvements
chore: bump version to 2.4.0
The floating TOC positioning logic assumed a correct sidebar reference
when calculating the horizontal offset. However, the selector used
(`aside, .sidebar, #secondary`) could match non-layout elements such as
hidden containers, mobile sidebars, or unrelated widgets.
This resulted in incorrect `getBoundingClientRect()` values and caused
the TOC to be positioned too far left or right, depending on which
element was matched.
Solution:
- Introduced a `getRealSidebar()` helper to dynamically detect the
visually relevant sidebar element.
- Filters out non-visible or irrelevant elements based on size.
- Selects the right-most valid candidate, ensuring correct layout context.
- Uses the actual gap between content and sidebar to position the TOC
symmetrically on the opposite side of the content.
Additional improvements:
- Cached sidebar lookup to avoid repeated DOM queries during scroll.
- Stabilized gap calculation with clamping to prevent layout drift.
Result:
The TOC now consistently aligns with the content column and mirrors
the sidebar spacing correctly across different layouts and breakpoints.
Fix incorrect TOC alignment caused by outdated DOM selector in toc.js.
The content reference element changed during layout refactor, breaking
position calculations for the floating TOC.
Updated contentColumn selector to use .main-wrapper/.container fallback,
ensuring correct left offset and responsive positioning.
Also adds a more robust fallback chain to prevent future regressions
when layout structure changes.
- Fix initial state where cleanup button stayed enabled after full cleanup
- Extend logic to detect "nothing to clean" cases:
- no optimized images available for cleanup
- all originals already deleted
- Align PHP initial render logic with runtime JS behavior
- Improve UX consistency between page load and live updates
- Extend cleanup logic to remove full original image family (including subsizes)
- Fix issue where only the main original file was deleted
- Ensure consistent behavior for both manual batch processing and auto-delete
- Improve cleanup safety by validating optimization state before deletion
- Add AVIF/WebP conversion for uploads and legacy media
- Implement manual batch optimizer via Performance Tools dashboard
- Introduce automatic optimization toggle via Customizer
- Add optional automatic deletion of original images after optimization
- Ensure safe processing with versioned metadata and idempotent operations
- Decouple manual optimization from automation logic using force flag
- Add live progress UI for optimization and cleanup processes
- Improve UX with status indicators, dependency handling and warnings