@a11y-hud/angular 1.0.0-rc.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -4
- package/{dist/fesm2022 → fesm2022}/a11y-hud-angular.mjs +6 -6
- package/fesm2022/a11y-hud-angular.mjs.map +1 -0
- package/package.json +17 -38
- package/{dist/types → types}/a11y-hud-angular.d.ts +3 -3
- package/dist/LICENSE +0 -21
- package/dist/README.md +0 -132
- package/dist/fesm2022/a11y-hud-angular.mjs.map +0 -1
package/README.md
CHANGED
|
@@ -8,7 +8,7 @@ Angular adapter for [a11y-hud](https://www.npmjs.com/package/a11y-hud) — run a
|
|
|
8
8
|
npm install a11y-hud @a11y-hud/angular
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
Peer dependencies: `@angular/core >=
|
|
11
|
+
Peer dependencies: `@angular/core >=20.0.0 <23.0.0` (Angular 20–22).
|
|
12
12
|
|
|
13
13
|
## Usage
|
|
14
14
|
|
|
@@ -83,7 +83,7 @@ The `scope` input accepts a template reference variable (typed as `Element` by A
|
|
|
83
83
|
|
|
84
84
|
### Route change rescans
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
The component rescans after every render commit via `afterEveryRender`, which covers Angular Router navigations and any re-render that does not change an `@Input()` value. No extra wiring needed.
|
|
87
87
|
|
|
88
88
|
If you need a manual rescan on a specific navigation event (for example, inside a `CanActivate` guard or a resolver), call `runScan()` on the component or through `A11yHudService`:
|
|
89
89
|
|
|
@@ -113,19 +113,33 @@ export class AppComponent {
|
|
|
113
113
|
|
|
114
114
|
| Input | Type | Default | Description |
|
|
115
115
|
|---|---|---|---|
|
|
116
|
-
| `theme` | `'auto'
|
|
116
|
+
| `theme` | `Theme` | `'auto'` | Panel theme — `'auto'`, `'default'`, `'light'`, `'high-contrast'`, `'github-dark'`, `'github-light'`, `'tokyo-night'`, `'solarized-dark'` |
|
|
117
117
|
| `scope` | `ElementRef<Element> \| Element \| null` | `null` | Restrict scan to this element |
|
|
118
118
|
| `autoScan` | `boolean` | `true` | Rescan on DOM mutations |
|
|
119
119
|
| `debounce` | `number` | `500` | MutationObserver debounce in ms |
|
|
120
|
+
| `runOnly` | `string[]` | — | Restrict axe to specific rule-set tags |
|
|
121
|
+
|
|
122
|
+
`A11yHudComponent` also exposes `runScan()`, `setTheme()`, `setRunOnly()`, `exportResults()` and `ignores` for use via `@ViewChild`.
|
|
120
123
|
|
|
121
124
|
## `A11yHudService` methods
|
|
122
125
|
|
|
123
126
|
| Method | Description |
|
|
124
127
|
|---|---|
|
|
125
128
|
| `init(options?)` | Mount the HUD; call once in `ngOnInit` or `ngAfterViewInit` |
|
|
126
|
-
| `
|
|
129
|
+
| `initialized` | Getter — `true` once `init()` has run |
|
|
130
|
+
| `runScan()` | Trigger a manual scan, returns `Promise<AxeResults \| null>` (`null` before `init()`) |
|
|
127
131
|
| `setTheme(theme)` | Switch the theme at runtime |
|
|
132
|
+
| `setRunOnly(tags)` | Change the active axe rule-set tags |
|
|
133
|
+
| `exportResults()` | Last scan as a JSON string, or `null` |
|
|
134
|
+
| `ignores` | Ignore-list API (`add`, `remove`, `clear`, `list`, `exportJson`, `importJson`) |
|
|
128
135
|
| `syncScope(scope)` | Update the scan scope |
|
|
136
|
+
| `syncTheme(theme)` / `syncAutoScan(autoScan)` / `syncDebounce(debounce)` | Push option changes to the mounted element |
|
|
137
|
+
|
|
138
|
+
The service is `@Injectable()` without `providedIn` — list it in a component's `providers` (the component does this for you). It unmounts the HUD in `ngOnDestroy`.
|
|
139
|
+
|
|
140
|
+
## Server-side rendering
|
|
141
|
+
|
|
142
|
+
Importing `@a11y-hud/angular` is safe on the server (Angular SSR, Analog); the HUD mounts in `ngAfterViewInit` / `init()`, so nothing renders server-side.
|
|
129
143
|
|
|
130
144
|
## License
|
|
131
145
|
|
|
@@ -94,10 +94,10 @@ class A11yHudService {
|
|
|
94
94
|
this.instance = null;
|
|
95
95
|
this.el = null;
|
|
96
96
|
}
|
|
97
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.
|
|
98
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.
|
|
97
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.24", ngImport: i0, type: A11yHudService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
98
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.24", ngImport: i0, type: A11yHudService });
|
|
99
99
|
}
|
|
100
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.
|
|
100
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.24", ngImport: i0, type: A11yHudService, decorators: [{
|
|
101
101
|
type: Injectable
|
|
102
102
|
}] });
|
|
103
103
|
|
|
@@ -164,10 +164,10 @@ class A11yHudComponent {
|
|
|
164
164
|
get ignores() {
|
|
165
165
|
return this.service.ignores;
|
|
166
166
|
}
|
|
167
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.
|
|
168
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.
|
|
167
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.24", ngImport: i0, type: A11yHudComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
168
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.24", type: A11yHudComponent, isStandalone: true, selector: "a11y-hud-angular", inputs: { theme: "theme", scope: "scope", autoScan: "autoScan", debounce: "debounce", runOnly: "runOnly" }, providers: [A11yHudService], usesOnChanges: true, ngImport: i0, template: "", isInline: true });
|
|
169
169
|
}
|
|
170
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.
|
|
170
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.24", ngImport: i0, type: A11yHudComponent, decorators: [{
|
|
171
171
|
type: Component,
|
|
172
172
|
args: [{
|
|
173
173
|
standalone: true,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"a11y-hud-angular.mjs","sources":["../../src/service.ts","../../src/component.ts","../../src/a11y-hud-angular.ts"],"sourcesContent":["import { type ElementRef, Injectable, inject, NgZone, type OnDestroy } from \"@angular/core\";\nimport type { A11yHudElement, A11yHudInstance, AxeResults, Theme } from \"a11y-hud\";\nimport { mount } from \"a11y-hud\";\nimport type { ScopeInput, UseA11yHudOptions } from \"./types.js\";\n\nfunction resolveScope(scope: ScopeInput): Element | undefined {\n if (scope == null) return undefined;\n return scope instanceof Element ? scope : (scope as ElementRef<Element>).nativeElement;\n}\n\n@Injectable()\nexport class A11yHudService implements OnDestroy {\n private readonly ngZone = inject(NgZone);\n private instance: A11yHudInstance | null = null;\n private el: A11yHudElement | null = null;\n\n init(options: UseA11yHudOptions = {}): void {\n const { theme, autoScan, debounce, runOnly } = options;\n this.instance = mount({\n ...(theme !== undefined && { theme }),\n ...(autoScan !== undefined && { autoScan }),\n ...(debounce !== undefined && { debounce }),\n ...(runOnly !== undefined && { runOnly }),\n });\n this.el = document.querySelector<A11yHudElement>(\"a11y-hud\");\n if (this.el) {\n this.el.scopeElement = resolveScope(options.scope);\n }\n }\n\n syncScope(scope: ScopeInput): void {\n const el = this.el;\n if (!el) return;\n el.scopeElement = resolveScope(scope);\n }\n\n syncTheme(theme: Theme | undefined): void {\n if (theme !== undefined) this.instance?.setTheme(theme);\n }\n\n syncAutoScan(autoScan: boolean | undefined): void {\n const el = this.el;\n if (!el || autoScan === undefined) return;\n if (autoScan === false) {\n el.removeAttribute(\"auto-scan\");\n } else {\n el.setAttribute(\"auto-scan\", \"\");\n }\n }\n\n syncDebounce(debounce: number | undefined): void {\n const el = this.el;\n if (!el || debounce === undefined) return;\n el.setAttribute(\"debounce\", String(debounce));\n }\n\n runScan(): Promise<AxeResults | null> {\n return this.ngZone.runOutsideAngular(() => this.instance?.runScan() ?? Promise.resolve(null));\n }\n\n setTheme(theme: Theme): void {\n this.instance?.setTheme(theme);\n }\n\n setRunOnly(tags: string[]): void {\n this.instance?.setRunOnly(tags);\n }\n\n exportResults(): string | null {\n return this.instance?.exportResults() ?? null;\n }\n\n get ignores() {\n const inst = this.instance;\n return {\n add(ruleId: string, selector?: string): void {\n inst?.ignores.add(ruleId, selector);\n },\n remove(ruleId: string, selector?: string): void {\n inst?.ignores.remove(ruleId, selector);\n },\n clear(): void {\n inst?.ignores.clear();\n },\n list() {\n return inst?.ignores.list() ?? [];\n },\n exportJson(): string {\n return inst?.ignores.exportJson() ?? \"[]\";\n },\n importJson(json: string): void {\n inst?.ignores.importJson(json);\n },\n };\n }\n\n get initialized(): boolean {\n return this.instance !== null;\n }\n\n ngOnDestroy(): void {\n this.instance?.unmount();\n this.instance = null;\n this.el = null;\n }\n}\n","import {\n type AfterViewInit,\n afterEveryRender,\n Component,\n Input,\n inject,\n type OnChanges,\n type SimpleChanges,\n} from \"@angular/core\";\nimport type { AxeResults, Theme } from \"a11y-hud\";\nimport { A11yHudService } from \"./service.js\";\nimport type { ScopeInput } from \"./types.js\";\n\n@Component({\n standalone: true,\n selector: \"a11y-hud-angular\",\n template: \"\",\n providers: [A11yHudService],\n})\nexport class A11yHudComponent implements AfterViewInit, OnChanges {\n @Input() theme?: Theme;\n @Input() scope: ScopeInput = null;\n @Input() autoScan?: boolean;\n @Input() debounce?: number;\n @Input() runOnly?: string[];\n\n private readonly service = inject(A11yHudService);\n\n constructor() {\n // Render-settled rescan: mirrors React's useEffect(fn) (no deps). Fires after\n // every Angular render commit — catches route changes and any re-render that\n // does not alter @Input() values, which ngOnChanges would otherwise miss.\n afterEveryRender(() => {\n if (!this.service.initialized) return;\n this.service.syncScope(this.scope);\n void this.service.runScan();\n });\n }\n\n ngAfterViewInit(): void {\n this.service.init({\n ...(this.theme !== undefined && { theme: this.theme }),\n scope: this.scope,\n ...(this.autoScan !== undefined && { autoScan: this.autoScan }),\n ...(this.debounce !== undefined && { debounce: this.debounce }),\n ...(this.runOnly !== undefined && { runOnly: this.runOnly }),\n });\n void this.service.runScan();\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (!this.service.initialized) return;\n\n if (\"scope\" in changes) {\n this.service.syncScope(this.scope);\n void this.service.runScan();\n }\n if (\"theme\" in changes) {\n this.service.syncTheme(this.theme);\n }\n if (\"autoScan\" in changes) {\n this.service.syncAutoScan(this.autoScan);\n }\n if (\"debounce\" in changes) {\n this.service.syncDebounce(this.debounce);\n }\n if (\"runOnly\" in changes) {\n this.service.setRunOnly(this.runOnly ?? []);\n }\n }\n\n runScan(): Promise<AxeResults | null> {\n return this.service.runScan();\n }\n\n setTheme(theme: Theme): void {\n this.service.setTheme(theme);\n }\n\n setRunOnly(tags: string[]): void {\n this.service.setRunOnly(tags);\n }\n\n exportResults(): string | null {\n return this.service.exportResults();\n }\n\n get ignores() {\n return this.service.ignores;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAKA,SAAS,YAAY,CAAC,KAAiB,EAAA;IACrC,IAAI,KAAK,IAAI,IAAI;AAAE,QAAA,OAAO,SAAS;AACnC,IAAA,OAAO,KAAK,YAAY,OAAO,GAAG,KAAK,GAAI,KAA6B,CAAC,aAAa;AACxF;MAGa,cAAc,CAAA;AACR,IAAA,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC;IAChC,QAAQ,GAA2B,IAAI;IACvC,EAAE,GAA0B,IAAI;IAExC,IAAI,CAAC,UAA6B,EAAE,EAAA;QAClC,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,OAAO;AACtD,QAAA,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;YACpB,IAAI,KAAK,KAAK,SAAS,IAAI,EAAE,K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I,CAAC;IAC/B;IAEA,aAAa,GAAA;AACX,QAAA,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE;IACrC;AAEA,IAAA,IAAI,OAAO,GAAA;AACT,QAAA,OAAO,IAAI,CAAC,OAAO,CAAC,OAAO;IAC7B;wGAtEW,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAhB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,gBAAgB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,kBAAA,EAAA,MAAA,EAAA,EAAA,KAAA,EAAA,OAAA,EAAA,KAAA,EAAA,OAAA,EAAA,QAAA,EAAA,UAAA,EAAA,QAAA,EAAA,UAAA,EAAA,OAAA,EAAA,SAAA,EAAA,EAAA,SAAA,EAFhB,CAAC,cAAc,CAAC,+CADjB,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA;;4FAGD,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAN5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,kBAAkB;AAC5B,oBAAA,QAAQ,EAAE,EAAE;oBACZ,SAAS,EAAE,CAAC,cAAc,CAAC;AAC5B,iBAAA;;sBAEE;;sBACA;;sBACA;;sBACA;;sBACA;;;ACxBH;;AAEG;;"}
|
package/package.json
CHANGED
|
@@ -1,43 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@a11y-hud/angular",
|
|
3
|
-
"version": "1.0.0
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"description": "Angular adapter for a11y-hud — run axe-core accessibility audits in your Angular app with no DevTools required.",
|
|
5
5
|
"type": "module",
|
|
6
|
-
"exports": {
|
|
7
|
-
".": {
|
|
8
|
-
"types": "./dist/types/a11y-hud-angular.d.ts",
|
|
9
|
-
"default": "./dist/fesm2022/a11y-hud-angular.mjs"
|
|
10
|
-
}
|
|
11
|
-
},
|
|
12
|
-
"module": "./dist/fesm2022/a11y-hud-angular.mjs",
|
|
13
|
-
"types": "./dist/types/a11y-hud-angular.d.ts",
|
|
14
6
|
"sideEffects": false,
|
|
15
|
-
"files": [
|
|
16
|
-
"dist",
|
|
17
|
-
"LICENSE",
|
|
18
|
-
"README.md"
|
|
19
|
-
],
|
|
20
7
|
"dependencies": {
|
|
21
|
-
"
|
|
22
|
-
"
|
|
8
|
+
"a11y-hud": "1.0.0",
|
|
9
|
+
"tslib": "^2.8.1"
|
|
23
10
|
},
|
|
24
11
|
"peerDependencies": {
|
|
25
12
|
"@angular/core": ">=20.0.0 <23.0.0"
|
|
26
13
|
},
|
|
27
|
-
"devDependencies": {
|
|
28
|
-
"@angular/compiler": "^21.0.0",
|
|
29
|
-
"@angular/compiler-cli": "^21.0.0",
|
|
30
|
-
"@angular/core": "^21.0.0",
|
|
31
|
-
"@angular/platform-browser": "^21.0.0",
|
|
32
|
-
"@angular/platform-browser-dynamic": "^21.0.0",
|
|
33
|
-
"@playwright/test": "^1.49.1",
|
|
34
|
-
"@vitest/coverage-v8": "^4.1.5",
|
|
35
|
-
"jsdom": "^29.1.1",
|
|
36
|
-
"ng-packagr": "^21.0.0",
|
|
37
|
-
"typescript": "~6.0.3",
|
|
38
|
-
"vitest": "^4.1.5",
|
|
39
|
-
"zone.js": "^0.16.1"
|
|
40
|
-
},
|
|
41
14
|
"engines": {
|
|
42
15
|
"node": ">=22"
|
|
43
16
|
},
|
|
@@ -62,13 +35,19 @@
|
|
|
62
35
|
"overlay",
|
|
63
36
|
"hud"
|
|
64
37
|
],
|
|
65
|
-
"
|
|
66
|
-
"
|
|
67
|
-
"
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
"
|
|
38
|
+
"publishConfig": {
|
|
39
|
+
"directory": "dist",
|
|
40
|
+
"linkDirectory": true
|
|
41
|
+
},
|
|
42
|
+
"module": "fesm2022/a11y-hud-angular.mjs",
|
|
43
|
+
"typings": "types/a11y-hud-angular.d.ts",
|
|
44
|
+
"exports": {
|
|
45
|
+
"./package.json": {
|
|
46
|
+
"default": "./package.json"
|
|
47
|
+
},
|
|
48
|
+
".": {
|
|
49
|
+
"types": "./types/a11y-hud-angular.d.ts",
|
|
50
|
+
"default": "./fesm2022/a11y-hud-angular.mjs"
|
|
51
|
+
}
|
|
73
52
|
}
|
|
74
53
|
}
|
|
@@ -13,7 +13,7 @@ interface UseA11yHudOptions {
|
|
|
13
13
|
}
|
|
14
14
|
type A11yHudProps = UseA11yHudOptions;
|
|
15
15
|
interface UseA11yHudReturn {
|
|
16
|
-
runScan(): Promise<AxeResults>;
|
|
16
|
+
runScan(): Promise<AxeResults | null>;
|
|
17
17
|
setTheme(theme: Theme): void;
|
|
18
18
|
setRunOnly(tags: string[]): void;
|
|
19
19
|
exportResults(): string | null;
|
|
@@ -37,7 +37,7 @@ declare class A11yHudComponent implements AfterViewInit, OnChanges {
|
|
|
37
37
|
constructor();
|
|
38
38
|
ngAfterViewInit(): void;
|
|
39
39
|
ngOnChanges(changes: SimpleChanges): void;
|
|
40
|
-
runScan(): Promise<AxeResults>;
|
|
40
|
+
runScan(): Promise<AxeResults | null>;
|
|
41
41
|
setTheme(theme: Theme): void;
|
|
42
42
|
setRunOnly(tags: string[]): void;
|
|
43
43
|
exportResults(): string | null;
|
|
@@ -62,7 +62,7 @@ declare class A11yHudService implements OnDestroy {
|
|
|
62
62
|
syncTheme(theme: Theme | undefined): void;
|
|
63
63
|
syncAutoScan(autoScan: boolean | undefined): void;
|
|
64
64
|
syncDebounce(debounce: number | undefined): void;
|
|
65
|
-
runScan(): Promise<AxeResults>;
|
|
65
|
+
runScan(): Promise<AxeResults | null>;
|
|
66
66
|
setTheme(theme: Theme): void;
|
|
67
67
|
setRunOnly(tags: string[]): void;
|
|
68
68
|
exportResults(): string | null;
|
package/dist/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2026 Arthur Vasconcelos
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
package/dist/README.md
DELETED
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
# @a11y-hud/angular
|
|
2
|
-
|
|
3
|
-
Angular adapter for [a11y-hud](https://www.npmjs.com/package/a11y-hud) — run axe-core accessibility audits inside your Angular app with no browser extension required.
|
|
4
|
-
|
|
5
|
-
## Install
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
npm install a11y-hud @a11y-hud/angular
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
Peer dependencies: `@angular/core >= 20.0.0 < 23.0.0` (Angular 20 and 21).
|
|
12
|
-
|
|
13
|
-
## Usage
|
|
14
|
-
|
|
15
|
-
### Component
|
|
16
|
-
|
|
17
|
-
Drop `<a11y-hud-angular>` into your root component's template. It renders nothing into the Angular tree — the HUD panel is appended to `document.body` as a Custom Element.
|
|
18
|
-
|
|
19
|
-
```typescript
|
|
20
|
-
import { Component } from '@angular/core';
|
|
21
|
-
import { A11yHudComponent } from '@a11y-hud/angular';
|
|
22
|
-
|
|
23
|
-
@Component({
|
|
24
|
-
standalone: true,
|
|
25
|
-
imports: [A11yHudComponent],
|
|
26
|
-
template: `
|
|
27
|
-
<a11y-hud-angular [theme]="'auto'" />
|
|
28
|
-
<router-outlet />
|
|
29
|
-
`,
|
|
30
|
-
})
|
|
31
|
-
export class AppComponent {}
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
### Service
|
|
35
|
-
|
|
36
|
-
Use `A11yHudService` when you need programmatic access to `runScan` or `setTheme`.
|
|
37
|
-
|
|
38
|
-
```typescript
|
|
39
|
-
import { Component, OnInit } from '@angular/core';
|
|
40
|
-
import { A11yHudService } from '@a11y-hud/angular';
|
|
41
|
-
|
|
42
|
-
@Component({
|
|
43
|
-
standalone: true,
|
|
44
|
-
providers: [A11yHudService],
|
|
45
|
-
template: `<button (click)="scan()">Scan now</button>`,
|
|
46
|
-
})
|
|
47
|
-
export class DevToolsComponent implements OnInit {
|
|
48
|
-
constructor(private readonly hud: A11yHudService) {}
|
|
49
|
-
|
|
50
|
-
ngOnInit() {
|
|
51
|
-
this.hud.init({ theme: 'auto' });
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
scan() {
|
|
55
|
-
void this.hud.runScan();
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
### Subtree scoping
|
|
61
|
-
|
|
62
|
-
Restrict the scan to a specific subtree by passing a template reference variable or an `ElementRef`.
|
|
63
|
-
|
|
64
|
-
```typescript
|
|
65
|
-
import { Component } from '@angular/core';
|
|
66
|
-
import { A11yHudComponent } from '@a11y-hud/angular';
|
|
67
|
-
import { RouterOutlet } from '@angular/router';
|
|
68
|
-
|
|
69
|
-
@Component({
|
|
70
|
-
standalone: true,
|
|
71
|
-
imports: [A11yHudComponent, RouterOutlet],
|
|
72
|
-
template: `
|
|
73
|
-
<a11y-hud-angular [scope]="mainRef" />
|
|
74
|
-
<main #mainRef>
|
|
75
|
-
<router-outlet />
|
|
76
|
-
</main>
|
|
77
|
-
`,
|
|
78
|
-
})
|
|
79
|
-
export class AppComponent {}
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
The `scope` input accepts a template reference variable (typed as `Element` by Angular's template checker), an `ElementRef<Element>` from `@ViewChild`, or `null` to restore full-page scanning.
|
|
83
|
-
|
|
84
|
-
### Route change rescans
|
|
85
|
-
|
|
86
|
-
Angular Router navigation mutates the DOM — the core's built-in `MutationObserver` picks up these changes and rescans automatically. No extra wiring needed.
|
|
87
|
-
|
|
88
|
-
If you need a manual rescan on a specific navigation event (for example, inside a `CanActivate` guard or a resolver), call `runScan()` on the component or through `A11yHudService`:
|
|
89
|
-
|
|
90
|
-
```typescript
|
|
91
|
-
import { Component, ViewChild } from '@angular/core';
|
|
92
|
-
import { Router, NavigationEnd } from '@angular/router';
|
|
93
|
-
import { A11yHudComponent } from '@a11y-hud/angular';
|
|
94
|
-
import { filter } from 'rxjs/operators';
|
|
95
|
-
|
|
96
|
-
@Component({
|
|
97
|
-
standalone: true,
|
|
98
|
-
imports: [A11yHudComponent],
|
|
99
|
-
template: `<a11y-hud-angular #hud />`,
|
|
100
|
-
})
|
|
101
|
-
export class AppComponent {
|
|
102
|
-
@ViewChild('hud') hud!: A11yHudComponent;
|
|
103
|
-
|
|
104
|
-
constructor(router: Router) {
|
|
105
|
-
router.events
|
|
106
|
-
.pipe(filter(e => e instanceof NavigationEnd))
|
|
107
|
-
.subscribe(() => this.hud.runScan());
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
## Inputs
|
|
113
|
-
|
|
114
|
-
| Input | Type | Default | Description |
|
|
115
|
-
|---|---|---|---|
|
|
116
|
-
| `theme` | `'auto' \| 'default' \| 'light' \| 'high-contrast'` | `'auto'` | Panel color theme |
|
|
117
|
-
| `scope` | `ElementRef<Element> \| Element \| null` | `null` | Restrict scan to this element |
|
|
118
|
-
| `autoScan` | `boolean` | `true` | Rescan on DOM mutations |
|
|
119
|
-
| `debounce` | `number` | `500` | MutationObserver debounce in ms |
|
|
120
|
-
|
|
121
|
-
## `A11yHudService` methods
|
|
122
|
-
|
|
123
|
-
| Method | Description |
|
|
124
|
-
|---|---|
|
|
125
|
-
| `init(options?)` | Mount the HUD; call once in `ngOnInit` or `ngAfterViewInit` |
|
|
126
|
-
| `runScan()` | Trigger a manual scan, returns `Promise<AxeResults>` |
|
|
127
|
-
| `setTheme(theme)` | Switch the theme at runtime |
|
|
128
|
-
| `syncScope(scope)` | Update the scan scope |
|
|
129
|
-
|
|
130
|
-
## License
|
|
131
|
-
|
|
132
|
-
MIT © Arthur Vasconcelos
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"a11y-hud-angular.mjs","sources":["../../src/service.ts","../../src/component.ts","../../src/a11y-hud-angular.ts"],"sourcesContent":["import { type ElementRef, Injectable, inject, NgZone, type OnDestroy } from \"@angular/core\";\nimport type { A11yHudElement, A11yHudInstance, AxeResults, Theme } from \"a11y-hud\";\nimport { mount } from \"a11y-hud\";\nimport type { ScopeInput, UseA11yHudOptions } from \"./types.js\";\n\nfunction resolveScope(scope: ScopeInput): Element | undefined {\n if (scope == null) return undefined;\n return scope instanceof Element ? scope : (scope as ElementRef<Element>).nativeElement;\n}\n\n@Injectable()\nexport class A11yHudService implements OnDestroy {\n private readonly ngZone = inject(NgZone);\n private instance: A11yHudInstance | null = null;\n private el: A11yHudElement | null = null;\n\n init(options: UseA11yHudOptions = {}): void {\n const { theme, autoScan, debounce, runOnly } = options;\n this.instance = mount({\n ...(theme !== undefined && { theme }),\n ...(autoScan !== undefined && { autoScan }),\n ...(debounce !== undefined && { debounce }),\n ...(runOnly !== undefined && { runOnly }),\n });\n this.el = document.querySelector<A11yHudElement>(\"a11y-hud\");\n if (this.el) {\n this.el.scopeElement = resolveScope(options.scope);\n }\n }\n\n syncScope(scope: ScopeInput): void {\n const el = this.el;\n if (!el) return;\n el.scopeElement = resolveScope(scope);\n }\n\n syncTheme(theme: Theme | undefined): void {\n if (theme !== undefined) this.instance?.setTheme(theme);\n }\n\n syncAutoScan(autoScan: boolean | undefined): void {\n const el = this.el;\n if (!el || autoScan === undefined) return;\n if (autoScan === false) {\n el.removeAttribute(\"auto-scan\");\n } else {\n el.setAttribute(\"auto-scan\", \"\");\n }\n }\n\n syncDebounce(debounce: number | undefined): void {\n const el = this.el;\n if (!el || debounce === undefined) return;\n el.setAttribute(\"debounce\", String(debounce));\n }\n\n runScan(): Promise<AxeResults> {\n return this.ngZone.runOutsideAngular(\n () => this.instance?.runScan() ?? Promise.resolve(null as unknown as AxeResults)\n );\n }\n\n setTheme(theme: Theme): void {\n this.instance?.setTheme(theme);\n }\n\n setRunOnly(tags: string[]): void {\n this.instance?.setRunOnly(tags);\n }\n\n exportResults(): string | null {\n return this.instance?.exportResults() ?? null;\n }\n\n get ignores() {\n const inst = this.instance;\n return {\n add(ruleId: string, selector?: string): void {\n inst?.ignores.add(ruleId, selector);\n },\n remove(ruleId: string, selector?: string): void {\n inst?.ignores.remove(ruleId, selector);\n },\n clear(): void {\n inst?.ignores.clear();\n },\n list() {\n return inst?.ignores.list() ?? [];\n },\n exportJson(): string {\n return inst?.ignores.exportJson() ?? \"[]\";\n },\n importJson(json: string): void {\n inst?.ignores.importJson(json);\n },\n };\n }\n\n get initialized(): boolean {\n return this.instance !== null;\n }\n\n ngOnDestroy(): void {\n this.instance?.unmount();\n this.instance = null;\n this.el = null;\n }\n}\n","import {\n type AfterViewInit,\n afterEveryRender,\n Component,\n Input,\n inject,\n type OnChanges,\n type SimpleChanges,\n} from \"@angular/core\";\nimport type { AxeResults, Theme } from \"a11y-hud\";\nimport { A11yHudService } from \"./service.js\";\nimport type { ScopeInput } from \"./types.js\";\n\n@Component({\n standalone: true,\n selector: \"a11y-hud-angular\",\n template: \"\",\n providers: [A11yHudService],\n})\nexport class A11yHudComponent implements AfterViewInit, OnChanges {\n @Input() theme?: Theme;\n @Input() scope: ScopeInput = null;\n @Input() autoScan?: boolean;\n @Input() debounce?: number;\n @Input() runOnly?: string[];\n\n private readonly service = inject(A11yHudService);\n\n constructor() {\n // Render-settled rescan: mirrors React's useEffect(fn) (no deps). Fires after\n // every Angular render commit — catches route changes and any re-render that\n // does not alter @Input() values, which ngOnChanges would otherwise miss.\n afterEveryRender(() => {\n if (!this.service.initialized) return;\n this.service.syncScope(this.scope);\n void this.service.runScan();\n });\n }\n\n ngAfterViewInit(): void {\n this.service.init({\n ...(this.theme !== undefined && { theme: this.theme }),\n scope: this.scope,\n ...(this.autoScan !== undefined && { autoScan: this.autoScan }),\n ...(this.debounce !== undefined && { debounce: this.debounce }),\n ...(this.runOnly !== undefined && { runOnly: this.runOnly }),\n });\n void this.service.runScan();\n }\n\n ngOnChanges(changes: SimpleChanges): void {\n if (!this.service.initialized) return;\n\n if (\"scope\" in changes) {\n this.service.syncScope(this.scope);\n void this.service.runScan();\n }\n if (\"theme\" in changes) {\n this.service.syncTheme(this.theme);\n }\n if (\"autoScan\" in changes) {\n this.service.syncAutoScan(this.autoScan);\n }\n if (\"debounce\" in changes) {\n this.service.syncDebounce(this.debounce);\n }\n if (\"runOnly\" in changes) {\n this.service.setRunOnly(this.runOnly ?? []);\n }\n }\n\n runScan(): Promise<AxeResults> {\n return this.service.runScan();\n }\n\n setTheme(theme: Theme): void {\n this.service.setTheme(theme);\n }\n\n setRunOnly(tags: string[]): void {\n this.service.setRunOnly(tags);\n }\n\n exportResults(): string | null {\n return this.service.exportResults();\n }\n\n get ignores() {\n return this.service.ignores;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAKA,SAAS,YAAY,CAAC,KAAiB,EAAA;IACrC,IAAI,KAAK,IAAI,IAAI;AAAE,QAAA,OAAO,SAAS;AACnC,IAAA,OAAO,KAAK,YAAY,OAAO,GAAG,KAAK,GAAI,KAA6B,CAAC,aAAa;AACxF;MAGa,cAAc,CAAA;AACR,IAAA,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC;IAChC,QAAQ,GAA2B,IAAI;IACvC,EAAE,GAA0B,IAAI;IAExC,IAAI,CAAC,UAA6B,EAAE,EAAA;QAClC,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,OAAO;AACtD,QAAA,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;YACpB,IAAI,KAAK,KAAK,SAAS,IAAI,EAAE,KAAK,EAAE,CAAC;YACrC,IAAI,QAAQ,KAAK,SAAS,IAAI,EAAE,QAAQ,EAAE,CAAC;YAC3C,IAAI,QAAQ,KAAK,SAAS,IAAI,EAAE,QAAQ,EAAE,CAAC;YAC3C,IAAI,OAAO,KAAK,SAAS,IAAI,EAAE,OAAO,EAAE,CAAC;AAC1C,SAAA,CAAC;QACF,IAAI,CAAC,EAAE,GAAG,QAAQ,CAAC,aAAa,CAAiB,UAAU,CAAC;AAC5D,QAAA,IAAI,IAAI,CAAC,EAAE,EAAE;YACX,IAAI,CAAC,EAAE,CAAC,YAAY,GAAG,YAAY,CAAC,OAAO,CAAC,KAAK,CAAC;QACpD;IACF;AAEA,IAAA,SAAS,CAAC,KAAiB,EAAA;AACzB,QAAA,MAAM,EAAE,GAAG,IAAI,CAAC,EAAE;AAClB,QAAA,IAAI,CAAC,EAAE;YAAE;AACT,QAAA,EAAE,CAAC,YAAY,GAAG,YAAY,CAAC,KAAK,CAAC;IACvC;AAEA,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