Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Add accessibility coverage for PackageSizeIncreaseAnalysis

Aperta
#3,078 0 commenti 1 reazione 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@userquin ci sta già lavorando.

Dal 25/7/2026.

  • #3077 di @userquin — chiusa senza merge

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

a11y

Summary

Add automated Vitest accessibility coverage for PackageSizeIncreaseAnalysis and remove its temporary exclusion from the component-coverage guard.

The component currently depends on the worker-backed useAnalyzeCauseWorker composable, so the test must isolate the UI from real Web Worker and IndexedDB behaviour.

Required changes

  • Add an accessibility/component test for app/components/Package/SizeIncreaseAnalysis.vue.
  • Mock useAnalyzeCauseWorker (and the worker boundary if the established test setup requires it) with reactive, type-safe state and no-op actions.
  • Cover the initial available state and assert that axe reports no accessibility violations.
  • Remove the Package/SizeIncreaseAnalysis.vue TODO/entry from SKIPPED_COMPONENTS in test/unit/a11y-component-coverage.spec.ts.

Rationale

The current skip leaves the new package-size analysis UI outside the repository’s required component accessibility coverage. A deterministic mock prevents browser-worker and IndexedDB dependencies from making the test brittle.

Affected areas

  • app/components/Package/SizeIncreaseAnalysis.vue
  • app/composables/pkg-size/useAnalyzeCauseWorker.ts
  • test/nuxt/a11y.spec.ts (or the established component-test location)
  • test/unit/a11y-component-coverage.spec.ts

Acceptance criteria

  • A Vitest test mounts PackageSizeIncreaseAnalysis with a mocked analysis composable.
  • The test performs an axe accessibility assertion without starting a real worker.
  • The temporary coverage skip and its TODO are removed.
  • The relevant test suite passes.

Requested by @userquin.

Backlinks: https://github.com/npmx-dev/npmx.dev/pull/3077 and https://github.com/npmx-dev/npmx.dev/pull/3077#discussion_r3649237902

Lingua principale
TypeScript
Stelle
3.6k
Fork
533
Merge medio
5g 1h
PR unite (30g)
36

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di npmx-dev/npmx.dev

Tutte le issue di npmx-dev/npmx.dev

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.