Files
KX-Bridge-Release/web/themes
viewit 13f84979fe fix(ui): move power switch from Dashboard card to header
Wrong placement: a standalone Dashboard card was awkward and easy to
miss depending on layout/scroll position, and didn't fit the
multi-printer case as naturally as the header does - the header
already tracks the active printer via renderPrinterDropdown() (single
name display + dropdown when >1 printer configured), so hooking the
power toggle in there means it always reflects whichever printer is
currently active, including after switching via the dropdown.

Replaces the removed card-power dashboard card with a compact
segmented An/Aus toggle in the header, next to the printer name and
before the status badge - same has_power_control gating and
/kx/printers/{id}/power + power-status endpoints as before, just
relocated and restyled for the header's smaller scale (.h-power-btn
instead of the dashboard-sized .spd-btn, same spd-active highlight
convention for the current state).

Also reverts the DASH_CARD_KEYS/DASH_DEFAULT_LAYOUT change and the
initDashGrid() backward-compat migration for old saved layouts, since
there's no longer a "power" grid card to add.
2026-08-24 19:05:25 +02:00
..