Presentation: subtoolbar (and other floating editor UI) leak into presentation when open #120
Labels
No labels
prio_critical
prio_low
type_bug
type_contact
type_issue
type_lead
type_question
type_story
type_task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lhumina_code/hero_whiteboard#120
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Open the freehand drawing tool so its sub-menu (color / thickness picker) is visible, then start presentation. The sub-menu stays on top of the spotlight overlay during presentation.
Steps to reproduce
Expected
The sub-toolbar is hidden during presentation, like the rest of the editor chrome.
Actual
The sub-toolbar stays visible and floats above the slide.
Root cause
crates/hero_whiteboard_ui/templates/web/board.htmlsets:.wb-subtoolbaris missing from that list. Same gap exists for.wb-emoji-picker(emoji picker),.wb-context-menu(right-click menu), and#theme-panel(theme picker popup) — any of those left open when the user starts presenting will leak into the presentation overlay.Fix
Extend the
body.wb-presenting ... { display: none !important; }selector list to include.wb-subtoolbar,.wb-emoji-picker,.wb-context-menu, and#theme-panel. Pure CSS; no JS changes needed.Implementation Spec for Issue #120
Objective
Hide every piece of editor floating UI during presentation, including the freehand drawing sub-toolbar, emoji picker, context menu, and theme panel — none of which the existing
body.wb-presentingrule covered.Files to Modify
crates/hero_whiteboard_ui/templates/web/board.html— extend thebody.wb-presenting … { display: none !important; }selector list.crates/hero_whiteboard_ui/templates/web/board_view.html— viewer template has its own copy of the same rule. Same extension.Implementation Plan
Step 1: Extend the hide list in both templates
Files: both templates above.
Replace:
with:
(
board_view.htmldoesn't render the toolbar/sub-toolbar/properties panel — but adding the selectors there is harmless and keeps the two rule sets in lockstep, so a future addition to either template is automatically covered.)Dependencies: none.
Acceptance Criteria
cargo fmt,cargo clippy --workspace --all-targets -- -D warnings,cargo test --workspace --libclean.Notes
startPresentation: the CSS hide is enough — the elements are still in the DOM with their state preserved, so exit returns the user to where they were. Forcing them closed would lose state and require teardown logic per element. CSS-only is simpler and reversible.Implementation Summary
Pure CSS extension to the
body.wb-presenting … { display: none !important; }rule in both templates.crates/hero_whiteboard_ui/templates/web/board.htmlandboard_view.htmlAdded four selectors to the existing list:
.wb-subtoolbar— fixes the reported bug (freehand drawing sub-menu leaking)..wb-emoji-picker— same risk for the emoji picker..wb-context-menu— right-click menu would also leak.#theme-panel— theme picker dropdown.board_view.htmlalso picked up.wb-toolbarand#properties-panelto keep the rule sets in lockstep across templates (they don't render those elements today, but a future addition is automatically covered).Test Results
cargo fmt --all -- --check— cleancargo clippy --workspace --all-targets -- -D warnings— cleancargo test --workspace --lib— 0 failedcargo check -p hero_whiteboard_ui— clean (Askama re-compiled both templates)Manual smoke
Notes