Skip to content

Add imperative vibration API and device verification controls - #30

Merged
joeblau merged 4 commits into
mainfrom
feat/imperative-haptics
Oct 18, 2026
Merged

joeblau merged 4 commits into
mainfrom
feat/imperative-haptics

Conversation

@joeblau

@joeblau joeblau commented Oct 18, 2026

Copy link
Copy Markdown
Contributor

Semantic controllers cannot request browser feedback through the component API. Add canTriggerHaptic() and triggerHaptic() with the component's vibration presets, custom patterns, duration cap, and intensity modulation. Requests resolve explicit acceptance/failure results, use current browser capabilities, and create no auxiliary DOM.

iOS imperative ticks remain unavailable, including during transient activation. WebKit's trusted-event enforcement (WebKit/WebKit@fc1ef83) rejects script-generated label activation. A successful browser vibration request is also explicitly distinguished from observed tactile output.

Related to #27. This completes its browser API work; the proposed native imperative route and physical-device requirements remain open. #7/#9 and the full-certification tracker #1 must stay open without the required physical and VoiceOver observations.

Add synchronous, awaited, and timer examples to the live documentation, update the physical-device procedure, and mark the API unreleased (published 0.1.0 does not contain these exports).

Validation: 132 tests with 100% runtime coverage; React 18/19 matrix; ESM/CommonJS, SSR, declarations and isolated packed consumers; bundle 4516 gzip bytes within 8192-byte budget; six Chromium/WebKit library tests; 27 documentation checks including imperative acceptance, rejection and iOS fallback; documentation typecheck, static build and snippet checks; lint.

@joeblau
joeblau merged commit 0f20a59 into main Oct 18, 2026
5 checks passed
@joeblau
joeblau deleted the feat/imperative-haptics branch October 18, 2026 16:31
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