feat(launcher): Oral/Poster Kiosk mode preset toggle + ae_mode WS command

Adds a two-button Session Mode Preset toggle in Display & App Modes cfg:
- 'Oral / Default' restores all menus/headers/iframe off
- 'Poster Kiosk'   sets iframe=true + hides menu, header, footer

When WS is connected (local_push or remote controller), tapping a preset
sends ae_mode:poster / ae_mode:oral to all connected devices so an operator
can reconfigure the whole room from one device.

ae_mode:{poster|oral} command handler added to handle_ws_recv() in
+layout.svelte — receives and applies the same preset on remote devices.
This commit is contained in:
Scott Idem
2026-03-13 13:58:37 -04:00
parent 1417fafcd3
commit ce0c8b03c9
2 changed files with 91 additions and 1 deletions

View File

@@ -415,6 +415,21 @@
else if (zoom_target === 'zoom') modal_zoom_fit = false;
} else if (cmd.startsWith('ae_refresh:')) {
if (cmd.split(':')[1] == 'now') location.reload();
} else if (cmd.startsWith('ae_mode:')) {
// WHY: Allows a controller to remotely push a display mode preset
// (e.g. switch all poster kiosks into kiosk mode without touching each device).
const mode_target = cmd.split(':')[1];
if (mode_target === 'poster') {
$ae_loc.iframe = true;
$events_loc.launcher.hide__launcher_menu = true;
$events_loc.launcher.hide__launcher_header = true;
$events_loc.launcher.hide__launcher_footer = true;
} else if (mode_target === 'oral') {
$ae_loc.iframe = false;
$events_loc.launcher.hide__launcher_menu = false;
$events_loc.launcher.hide__launcher_header = false;
$events_loc.launcher.hide__launcher_footer = false;
}
}
}
}