| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| OpenPublisher-5-x86_64.AppImage | 2026-10-06 | 166.4 MB | |
| openpublisher5_amd64-windows-portable.exe | 2026-10-06 | 183.2 MB | |
| openpublisher5_amd64-windows.exe | 2026-10-06 | 165.2 MB | |
| openpublisher5_amd64-macos.dmg | 2026-10-06 | 233.1 MB | |
| openpublisher5_amd64-linux.run | 2026-10-06 | 193.4 MB | |
| openpublisher5_amd64-linux.rpm | 2026-10-06 | 215.4 MB | |
| openpublisher5_amd64-linux.flatpak | 2026-10-06 | 153.6 MB | |
| openpublisher5_amd64-linux.deb | 2026-10-06 | 156.2 MB | |
| openpublisher5_amd64-freebsd.pkg | 2026-10-06 | 185.5 MB | |
| 5.4.3_ Auto-Reset Hue _ Dedicated Theme Studio Engine source code.tar.gz | 2026-10-06 | 22.5 MB | |
| 5.4.3_ Auto-Reset Hue _ Dedicated Theme Studio Engine source code.zip | 2026-10-06 | 22.7 MB | |
| README.md | 2026-10-06 | 12.5 kB | |
| Totals: 12 Items | 1.7 GB | 0 | |
🚀 Summary
Version 5.4.3 of Open Publisher introduces a critical usability fix in the Theme Studio alongside a major codebase architectural cleanup:
- Hue Shift Auto-Reset: When changing themes, the Hue Shift slider automatically resets to 0°, eliminating color distortion carryover so the canvas faithfully matches the preview swatch in the catalog.
- Dedicated Theme Studio Architecture: Extracted the entire 7,420-line Theme Studio subsystem out of
extensions/legacy-fixes.jsinto its own dedicated, standalone module atextensions/theme-studio.js, returninglegacy-fixes.jsto its true intended scope (~2,380 lines).
🔍 Problems Solved & Key Enhancements
- Elimination of Hue Shift Carryover on Theme Change:
- Problem: When a user modified the Hue Shift slider (e.g., rotating colors by 180° to test variations) and subsequently selected a different theme from the ribbon strip or popover catalog, the slider retained the previous theme's shifted hue. Newly selected themes immediately rendered on the canvas with distorted, rotated colors (for instance, navy turning amber or crimson turning teal), causing an unexpected mismatch between the catalog swatch card and the canvas background.
-
Solution in v5.4.3: Added an automatic hue reset hook directly inside
applyThemeToCanvas. Whenever a theme swatch is clicked,#ts-hue-sliderresets to0,#ts-hue-badgeresets to0°, the slider track fill resets to 0%, and the canvas composite filter immediately updates tohue-rotate(0deg). -
100% Visual Parity Between Swatch Previews and Canvas Output:
-
Swatch cards represent authentic base palettes (0° hue shift). Resetting hue upon swatch selection guarantees that the rendered page background on the canvas faithfully matches the preview card clicked in the catalog.
-
Architectural Extraction of Theme Studio Subsystem:
- Problem: Historically, the modernized Theme Studio was added inside
extensions/legacy-fixes.jsas an override to replace the older 24-swatch#theme-group. Successive feature expansions (6 sliders, pattern zoom, Canvas 2D raster print baking, and 700 themes) bloatedlegacy-fixes.jsto nearly 10,000 lines, obscuring actual legacy fixes with a massive, active core subsystem. -
Solution in v5.4.3: Extracted the entire Theme Studio subsystem (7,420 lines) into a dedicated module:
extensions/theme-studio.js.legacy-fixes.jshas been streamlined back down to ~2,380 lines. -
Active Page Model & History Synchronization:
-
The active page data model (
state.pages[index].themeSettings.hue) updates to"0"in lockstep with the UI. An undo history checkpoint is recorded viapushHistory()so users can undo theme changes smoothly. -
Preserved Document Loading Integrity:
-
The auto-reset hook executes exclusively on user swatch clicks (
applyThemeToCanvas). Saved documents with intentional custom hue shifts continue to load accurately viawindow.restoreThemeFromSave. -
Print Pre-Baking Fidelity:
- The Canvas 2D Print Pre-Baking Engine (
window.bakeThemeBackgroundForPrint) readsdata-theme-hue="0"upon theme switch, ensuring printed and PDF-exported outputs reflect authentic theme colors.
🛠️ Complete Architectural Breakdown
1. Dedicated Engine: extensions/theme-studio.js
- Module Separation: The complete Theme Studio engine now lives in its own dedicated file:
extensions/theme-studio.js. - Contained Components:
- Full 700-theme curated catalog across all 5 categories (Fine Papers, Gradients, Corporate, Dark Mode, Pastels).
- Compact 8-column ribbon gallery container and action controls (
#ts-gallery-container,#ts-gallery-up,#ts-gallery-down,#ts-gallery-more). - Categorized catalog popover panel with real-time search, badge counts, and pin-open auditioning (
#ts-gallery-popover). - Symmetrical 6-slider dual-column adjustment suite (Saturation, Brightness, Contrast, Hue Shift, Texture Opacity, Pattern Zoom).
- Canvas 2D raster pre-baking engine for 100% print, PDF, and export fidelity (
window.bakeThemeBackgroundForPrint). - Document restoration and persistence handlers (
window.restoreThemeFromSave). - Load Order in
index.html: Loaded immediately beforelegacy-fixes.js: ```html
<script src="extensions/ui-interactions.js?v=5.4.3"></script>
```
2. Streamlined extensions/legacy-fixes.js
- Shrunk from 9,805 lines down to 2,386 lines, returning the file exclusively to its intended purpose of providing targeted legacy browser and backward-compatibility patches.
3. Theme Selection Lifecycle Hook (applyThemeToCanvas)
- Execution Flow:
- Captures selected swatch metadata (
id,name,type,c1,c2,url). - Anchors metadata attributes to the
#paperDOM node. - Auto-Reset Logic:
javascript // Reset Hue Shift back to 0 so new theme matches its swatch preview in the gallery/popover const hueSliderEl = document.getElementById('ts-hue-slider'); if (hueSliderEl) { hueSliderEl.value = 0; } const hueBadgeEl = document.getElementById('ts-hue-badge'); if (hueBadgeEl) { hueBadgeEl.textContent = '0°'; } paper.setAttribute('data-theme-hue', '0'); - Synchronizes active swatch highlights across ribbon strip and popover.
- Rebuilds theme DOM container layers (
.op-theme-container,.op-theme-bg, and.op-theme-tex). - Executes
updateLiveFilters()to refresh slider track fills and composite CSS filters. - Calls
pushHistory()to save the action into the undo stack.
4. UI & Filter Pipeline Synchronization (updateLiveFilters)
- Slider Track Gradient Fill: Calls
updateSliderTrackFill(hueSlider, 0, 360, 0)to reset the background track fill of the slider to 0% progress. - Badge Reset: Updates
#ts-hue-badgepill text to0°. - CSS Filter String: Updates
.op-theme-containerfilter tosaturate(${sat}%) brightness(${bri}%) contrast(${con}%) hue-rotate(0deg). - Page Model Persist: Sets
state.pages[state.currentPageIndex].themeSettings.hue = "0".
🛠️ Files Modified
- extensions/theme-studio.js: Newly extracted dedicated engine file containing the full Theme Studio subsystem (700 themes, 6 sliders, Canvas 2D raster print baking, and hue auto-reset).
- extensions/legacy-fixes.js: Removed 7,420 lines of Theme Studio code, streamlining the file back to its core purpose.
- index.html: Added
extensions/theme-studio.js?v=5.4.3script tag and synchronized all cachebusters to?v=5.4.3. - sw.js: Updated Service Worker cache name to
open-publisher-v5-4-3and version headers. - extensions/pwa-install.js: Bumped version header and SW registration query to
sw.js?v=5.4.3. - extensions/geo-defense.js: Bumped version header to
(v5.4.3). - elements/arrow/arrow.js: Bumped version comments and console initialization to
v5.4.3. - elements/templates/templates.js: Bumped template index and file fetch queries to
?v=5.4.3. - ui/dashboard.js: Bumped template index and file fetch queries to
?v=5.4.3. - style.css: Updated component banner to
v5.4.3.
🧪 Verification & Automated Testing
Validated through two comprehensive automated Playwright end-to-end test suites (test_hue_reset.py and test_themes_700.py):
| Test Scenario | Verification Metric | Result | Output Details |
|---|---|---|---|
| Initial Theme Selection | Select theme from ribbon gallery strip | Passed | Applied cleanly to canvas with data-theme-hue="0" |
| Hue Shift Scrubbing | Adjust #ts-hue-slider to 180° |
Passed | Slider reads 180, badge displays "180°", paper attribute set to "180", and canvas filter reflects hue-rotate(180deg) |
| Ribbon Swatch Auto-Reset | Click second swatch in ribbon track | Passed | Slider automatically resets to 0, badge resets to "0°", paper attribute resets to "0", page model hue set to "0", and canvas renders hue-rotate(0deg) |
| Slider Track Fill Reset | Verify background fill of #ts-hue-slider |
Passed | Track gradient fill resets to 0% fill level |
| Popover Swatch Auto-Reset | Adjust hue to 270°, open popover, and select swatch | Passed | Slider automatically resets to 0, badge resets to "0°", paper attribute resets to "0", and canvas renders hue-rotate(0deg) |
| Page Model Synchronization | Inspect state.pages[currentPageIndex].themeSettings.hue |
Passed | Active page data model reflects hue: "0" |
| Canvas 2D Print Pre-Baking | Trigger beforeprint event after theme switch |
Passed | Offscreen print spooler confirms dataHue: "0", matching authentic swatch colors |
| Dedicated Engine Extraction | Load app with extracted theme-studio.js |
Passed | Ribbon mounts cleanly, #advanced-theme-studio operational, console confirms v5.4.3 |
| Full 700-Theme Catalog | Inspect ribbon track and popover swatches | Passed | Exactly 700 swatches verified across all 5 category sections with zero errors |
| Real-Time Search & Pin-Open | Search query and auditioning in popover | Passed | Popover remains open while applying themes; search filtering instant |
✅ Complete v5.4.3 Feature & Verification Checklist
- [x] Auto-Reset Hue Shift on Theme Selection: Added automatic hue reset in
applyThemeToCanvas, ensuring that whenever a user selects a new theme swatch, the Hue Shift slider resets to0. - [x] Numeric Badge Reset: Updated
#ts-hue-badgepill text to immediately display0°upon theme selection. - [x] Dynamic Track Fill Reset: Reset the slider track gradient fill back to 0% progress.
- [x] Filter Pipeline Reset: Canvas composite filter immediately updates to
hue-rotate(0deg), eliminating lingering color shifts from prior themes. - [x] Page Model Synchronization: Synchronized
state.pages[state.currentPageIndex].themeSettings.hue = "0"so page switching preserves authentic theme colors. - [x] Dedicated
theme-studio.jsEngine: Extracted Theme Studio (7,420 lines) intoextensions/theme-studio.js, reducinglegacy-fixes.jsfrom 9,805 lines down to 2,386 lines. - [x] Cross-View Support: Verified auto-reset functionality across both ribbon gallery swatches and popover catalog swatches.
- [x] Pin-Open Auditioning Maintained: Auditioning multiple themes consecutively inside the popover catalog works seamlessly, resetting hue on every click while keeping the menu open.
- [x] Document Loading Protection: Confirmed that
window.restoreThemeFromSaveretains saved custom hue angles when opening existing documents. - [x] Print Pre-Baking Integration: Confirmed that
window.bakeThemeBackgroundForPrintreadsdata-theme-hue="0"after a theme change, pre-baking authentic rasters for printing. - [x] Cachebuster Synchronization: Updated all 78 cachebusters in
index.htmlto?v=5.4.3. - [x] Service Worker & PWA Update: Bumped Service Worker cache name to
open-publisher-v5-4-3and PWA registration query tosw.js?v=5.4.3. - [x] Subsystem Version Bumps: Synchronized headers and comments across
geo-defense.js,arrow.js,templates.js,dashboard.js,style.css, andlegacy-fixes.js. - [x] Automated Playwright Test Suites: Passed 100% of automated tests across both
test_hue_reset.pyandtest_themes_700.py.
🎉 Version 5.4.3 - Open Publisher