Skip to content

fix(runtime): harden navigation against overlays, scroll, and stray touches#3

Open
Reebz wants to merge 1 commit into
bluedusk:mainfrom
Reebz:fix/nav-input-hardening
Open

fix(runtime): harden navigation against overlays, scroll, and stray touches#3
Reebz wants to merge 1 commit into
bluedusk:mainfrom
Reebz:fix/nav-input-hardening

Conversation

@Reebz

@Reebz Reebz commented Jun 9, 2026

Copy link
Copy Markdown

What

Input handling that leaked while presenting and while viewing on touch devices.

  • Overlay guard. goTo() early-returns when the skill's own .diagram-lightbox.active is open or any [data-blocks-nav]:not([hidden]) element is present, so arrow keys, wheel, and swipe no longer move the slide behind a modal. The marker also gives authors a hook for their own overlays.
  • Wheel handler. Bails when the pointer sits over a scrollable ancestor, so a wide .code-body scrolls instead of changing slides. It ignores sub-threshold deltas and navigates on the dominant axis only, which fixes the diagonal-scroll misread.
  • Touch handler. Captures start position and time, bails on multi-touch and on flip-card, link, button, and form targets, and requires horizontal dominance, a minimum distance, and a maximum duration before navigating.
  • replayActiveSlide(). A standalone public function that restarts a slide's staggered entry animations, leaving the existing next, prev, keyboard, and dot contract untouched.

Every change is mirrored into both assets/slides-runtime.js and the inline runtime in references/html-template.md, and replayActiveSlide() is documented in SKILL.md and references/presentation-layer.md.

Test

testing/fixtures/deck-overlay-and-codeblock.html (added) exercises the overlay block and the horizontal code-block scroll. A vertical scroll over a tall card and a two-finger gesture no longer navigate, and a deliberate horizontal swipe still does.

Dependencies

Touches slides-runtime.js, so it is cleanest to merge after the runtime null-guard PR.

Co-Authored-By: Leslie Barbara Knope (Claude Opus 4.8 (1M context)) noreply@anthropic.com

…ouches

Navigation leaked through overlays, misread diagonal scroll, and stole horizontal scroll from wide code blocks, and touch swipes fired on vertical drags and flip-card taps. Add an overlay guard, axis-locked wheel and touch handling that respects scrollable targets, and a standalone replayActiveSlide() for restarting a slide's entry animations.

Co-Authored-By: Leslie Barbara Knope (Claude Opus 4.8 (1M context)) <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 9, 2026

Copy link
Copy Markdown

@Reebz is attempting to deploy a commit to the bluedusk's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant