Skip to content

feat: tap recognizer with full test infrastructure - #1

Merged
akoreh merged 4 commits into
mainfrom
feature/tap
Apr 2, 2026
Merged

feat: tap recognizer with full test infrastructure#1
akoreh merged 4 commits into
mainfrom
feature/tap

Conversation

@akoreh

@akoreh akoreh commented Apr 2, 2026

Copy link
Copy Markdown
Owner

Summary

  • Core gesture recognition infrastructure: Manager, BaseRecognizer, Arbitrator, PointerTracker
  • TapRecognizer with convenience tap() function, threshold/interval options, CustomEvent dispatch
  • Full test infrastructure: vitest + jsdom unit tests (549 tests), Playwright E2E (3 browsers), Stryker mutation testing (94.35%)
  • CI pipeline, linting (ESLint + Prettier), husky pre-commit hooks, size-limit checks
  • VitePress documentation site with interactive TapDemo, API reference, guides
  • Examples harness served by Vite dev server

Test plan

  • npm test — 549 unit tests pass
  • npm run test:e2e — Playwright tests pass on chromium/firefox/webkit
  • npm run build — tsup builds cleanly with declarations
  • npm run lint — no ESLint errors
  • npm run test:mutate — Stryker score above 85% threshold

akoreh added 4 commits April 2, 2026 14:47
Core: PointerTracker, BaseRecognizer, Manager, Arbitrator
Recognizer: TapRecognizer with convenience API, state machine, threshold/interval
Testing: 144 unit tests (vitest), 54 E2E tests (Playwright x3 browsers), Stryker mutation testing at 94.35%
Tooling: ESLint strict, Prettier, husky pre-commit, size-limit, GitHub Actions CI, dependabot
Docs: VitePress site with Gruvbox theme, interactive demos, API reference, guides
- Manager calls setPointerCapture on pointerdown so recognizers receive
  move/up/cancel even when the pointer leaves the element bounds
- TapRecognizer defaults moved from instance fields to module-level const
- PointerTracker.onPointerDown guards against duplicate pointer IDs
- getting-started.md: RECOGNIZED → Recognized (matches enum value)
- tap.md: Failed→Idle reset is deferred to pointerup/cancel, not automatic
- .gitignore: add tmp/
@akoreh
akoreh merged commit 9eb1c61 into main Apr 2, 2026
5 checks passed
@akoreh
akoreh deleted the feature/tap branch April 3, 2026 06:03
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