govuk_publishing_components 61.3.0 → 61.4.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.
- checksums.yaml +4 -4
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-form-change-tracker.js +147 -0
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-form-tracker.js +1 -1
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4-publishing.js +1 -0
- data/app/assets/stylesheets/component_guide/application.scss +1 -2
- data/app/assets/stylesheets/govuk_publishing_components/components/_attachment.scss +0 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/_breadcrumbs.scss +0 -21
- data/app/assets/stylesheets/govuk_publishing_components/components/_emergency-banner.scss +0 -13
- data/app/assets/stylesheets/govuk_publishing_components/components/_notice.scss +0 -3
- data/app/assets/stylesheets/govuk_publishing_components/components/_signup-link.scss +2 -2
- data/app/assets/stylesheets/govuk_publishing_components/components/_success-alert.scss +0 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/_tabs.scss +0 -23
- data/app/assets/stylesheets/govuk_publishing_components/components/_translation-nav.scss +2 -11
- data/app/controllers/govuk_publishing_components/component_guide_controller.rb +0 -44
- data/app/views/govuk_publishing_components/component_guide/preview.html.erb +1 -17
- data/app/views/govuk_publishing_components/components/_attachment.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/_breadcrumbs.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/_emergency_banner.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/_layout_for_public.html.erb +6 -4
- data/app/views/govuk_publishing_components/components/_published_dates.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/_signup_link.html.erb +2 -2
- data/app/views/govuk_publishing_components/components/_success_alert.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/_translation_nav.html.erb +1 -1
- data/app/views/layouts/govuk_publishing_components/application.html.erb +9 -2
- data/config/locales/es.yml +2 -2
- data/lib/govuk_publishing_components/config.rb +5 -1
- data/lib/govuk_publishing_components/presenters/translation_nav_helper.rb +4 -0
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/node_modules/axe-core/README.md +4 -4
- data/node_modules/axe-core/axe.d.ts +74 -10
- data/node_modules/axe-core/axe.js +17306 -17047
- data/node_modules/axe-core/axe.min.js +2 -2
- data/node_modules/axe-core/locales/_template.json +18 -10
- data/node_modules/axe-core/locales/de.json +5 -1
- data/node_modules/axe-core/locales/ja.json +127 -118
- data/node_modules/axe-core/locales/pt_PT.json +1123 -0
- data/node_modules/axe-core/locales/ru.json +1127 -0
- data/node_modules/axe-core/package.json +9 -9
- data/node_modules/axe-core/sri-history.json +4 -0
- metadata +5 -1
|
@@ -155,7 +155,7 @@ declare namespace axe {
|
|
|
155
155
|
toolOptions: RunOptions;
|
|
156
156
|
passes: Result[];
|
|
157
157
|
violations: Result[];
|
|
158
|
-
incomplete:
|
|
158
|
+
incomplete: IncompleteResult[];
|
|
159
159
|
inapplicable: Result[];
|
|
160
160
|
}
|
|
161
161
|
interface Result {
|
|
@@ -167,6 +167,9 @@ declare namespace axe {
|
|
|
167
167
|
tags: TagValue[];
|
|
168
168
|
nodes: NodeResult[];
|
|
169
169
|
}
|
|
170
|
+
interface IncompleteResult extends Result {
|
|
171
|
+
error?: Omit<RuleError, 'errorNode'>;
|
|
172
|
+
}
|
|
170
173
|
interface NodeResult {
|
|
171
174
|
html: string;
|
|
172
175
|
impact?: ImpactValue;
|
|
@@ -204,6 +207,21 @@ declare namespace axe {
|
|
|
204
207
|
fail: string | { [key: string]: string };
|
|
205
208
|
incomplete?: string | { [key: string]: string };
|
|
206
209
|
}
|
|
210
|
+
interface RuleError {
|
|
211
|
+
name: string;
|
|
212
|
+
message: string;
|
|
213
|
+
stack: string;
|
|
214
|
+
ruleId?: string;
|
|
215
|
+
method?: string;
|
|
216
|
+
cause?: SerialError;
|
|
217
|
+
errorNode?: SerialDqElement;
|
|
218
|
+
}
|
|
219
|
+
interface SerialError {
|
|
220
|
+
message: string;
|
|
221
|
+
stack: string;
|
|
222
|
+
name: string;
|
|
223
|
+
cause?: SerialError;
|
|
224
|
+
}
|
|
207
225
|
interface CheckLocale {
|
|
208
226
|
[key: string]: CheckMessages;
|
|
209
227
|
}
|
|
@@ -342,6 +360,9 @@ declare namespace axe {
|
|
|
342
360
|
interface DqElement extends SerialDqElement {
|
|
343
361
|
element: Element;
|
|
344
362
|
toJSON(): SerialDqElement;
|
|
363
|
+
}
|
|
364
|
+
interface DqElementConstructor {
|
|
365
|
+
new (elm: Element, options?: { absolutePaths?: boolean }): DqElement;
|
|
345
366
|
mergeSpecs(
|
|
346
367
|
childSpec: SerialDqElement,
|
|
347
368
|
parentSpec: SerialDqElement
|
|
@@ -365,23 +386,25 @@ declare namespace axe {
|
|
|
365
386
|
frameContext: FrameContextObject;
|
|
366
387
|
}
|
|
367
388
|
|
|
368
|
-
interface RawCheckResult
|
|
389
|
+
interface RawCheckResult
|
|
390
|
+
extends Omit<CheckResult, 'relatedNodes' | 'impact'> {
|
|
369
391
|
relatedNodes?: Array<SerialDqElement | DqElement>;
|
|
392
|
+
impact?: ImpactValue;
|
|
370
393
|
}
|
|
371
394
|
|
|
372
|
-
interface RawNodeResult<T extends 'passed' | 'failed' | '
|
|
395
|
+
interface RawNodeResult<T extends 'passed' | 'failed' | 'cantTell'> {
|
|
373
396
|
node: SerialDqElement | DqElement;
|
|
374
397
|
any: RawCheckResult[];
|
|
375
398
|
all: RawCheckResult[];
|
|
376
399
|
none: RawCheckResult[];
|
|
377
|
-
impact: ImpactValue |
|
|
400
|
+
impact: ImpactValue | undefined;
|
|
378
401
|
result: T;
|
|
379
402
|
}
|
|
380
403
|
|
|
381
404
|
interface RawResult extends Omit<Result, 'nodes'> {
|
|
382
405
|
inapplicable: Array<never>;
|
|
383
406
|
passes: RawNodeResult<'passed'>[];
|
|
384
|
-
incomplete: RawNodeResult<'
|
|
407
|
+
incomplete: RawNodeResult<'cantTell'>[];
|
|
385
408
|
violations: RawNodeResult<'failed'>[];
|
|
386
409
|
pageLevel: boolean;
|
|
387
410
|
result: 'failed' | 'passed' | 'incomplete' | 'inapplicable';
|
|
@@ -405,6 +428,42 @@ declare namespace axe {
|
|
|
405
428
|
boundingClientRect: DOMRect;
|
|
406
429
|
}
|
|
407
430
|
|
|
431
|
+
type GridCell = VirtualNode[];
|
|
432
|
+
|
|
433
|
+
interface Grid {
|
|
434
|
+
container: VirtualNode | null;
|
|
435
|
+
cells: unknown; // opaque implementation detail
|
|
436
|
+
boundaries?: DOMRect;
|
|
437
|
+
toGridIndex(num: number): number;
|
|
438
|
+
getCellFromPoint(point: { x: number; y: number }): GridCell;
|
|
439
|
+
loopGridPosition(
|
|
440
|
+
gridPosition: DOMRect,
|
|
441
|
+
callback: (gridCell: GridCell, pos: { row: number; col: number }) => void
|
|
442
|
+
): void;
|
|
443
|
+
getGridPositionOfRect(
|
|
444
|
+
rect: { top: number; right: number; bottom: number; left: number },
|
|
445
|
+
margin?: number
|
|
446
|
+
): DOMRect;
|
|
447
|
+
}
|
|
448
|
+
|
|
449
|
+
interface CustomNodeSerializer<T = SerialDqElement> {
|
|
450
|
+
toSpec: (dqElm: DqElement) => T;
|
|
451
|
+
mergeSpecs: (nodeSpec: T, parentFrameSpec: T) => T;
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
interface NodeSerializer {
|
|
455
|
+
update: <T>(serializer: CustomNodeSerializer<T>) => void;
|
|
456
|
+
toSpec: (node: Element | VirtualNode) => SerialDqElement;
|
|
457
|
+
dqElmToSpec: (
|
|
458
|
+
dqElm: DqElement | SerialDqElement,
|
|
459
|
+
options?: RunOptions
|
|
460
|
+
) => SerialDqElement;
|
|
461
|
+
mergeSpecs: (
|
|
462
|
+
nodeSpec: SerialDqElement,
|
|
463
|
+
parentFrameSpec: SerialDqElement
|
|
464
|
+
) => SerialDqElement;
|
|
465
|
+
}
|
|
466
|
+
|
|
408
467
|
interface Utils {
|
|
409
468
|
getFrameContexts: (
|
|
410
469
|
context?: ElementContext,
|
|
@@ -422,16 +481,20 @@ declare namespace axe {
|
|
|
422
481
|
isLabelledShadowDomSelector: (
|
|
423
482
|
selector: unknown
|
|
424
483
|
) => selector is LabelledShadowDomSelector;
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
484
|
+
RuleError: new (options: {
|
|
485
|
+
error: Error;
|
|
486
|
+
ruleId?: string;
|
|
487
|
+
method?: string;
|
|
488
|
+
errorNode?: SerialDqElement;
|
|
489
|
+
}) => RuleError;
|
|
490
|
+
serializeError: (error: Error) => SerialError;
|
|
491
|
+
DqElement: DqElementConstructor;
|
|
430
492
|
uuid: (
|
|
431
493
|
options?: { random?: Uint8Array | Array<number> },
|
|
432
494
|
buf?: Uint8Array | Array<number>,
|
|
433
495
|
offset?: number
|
|
434
496
|
) => string | Uint8Array | Array<number>;
|
|
497
|
+
nodeSerializer: NodeSerializer;
|
|
435
498
|
}
|
|
436
499
|
|
|
437
500
|
interface Aria {
|
|
@@ -441,6 +504,7 @@ declare namespace axe {
|
|
|
441
504
|
interface Dom {
|
|
442
505
|
isFocusable: (node: Element | VirtualNode) => boolean;
|
|
443
506
|
isNativelyFocusable: (node: Element | VirtualNode) => boolean;
|
|
507
|
+
getNodeGrid: (node: Node | VirtualNode) => Grid;
|
|
444
508
|
}
|
|
445
509
|
|
|
446
510
|
type AccessibleTextOptions = {
|