@holmdigital/standards 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/LICENSE +59 -0
- package/README.md +41 -0
- package/data/ict-manual-checks.json +189 -0
- package/data/rules.de.json +1945 -0
- package/data/rules.en.json +1946 -0
- package/data/rules.es.json +1945 -0
- package/data/rules.fr.json +1945 -0
- package/data/rules.sv.json +1946 -0
- package/data/wcag-to-en301549.json +1946 -0
- package/dist/index.d.mts +117 -0
- package/dist/index.d.ts +117 -0
- package/dist/index.js +10223 -0
- package/dist/index.mjs +10181 -0
- package/package.json +62 -0
- package/schema/convergence-schema.json +191 -0
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
type WCAGLevel = 'A' | 'AA' | 'AAA';
|
|
2
|
+
type WCAGVersion = '2.0' | '2.1' | '2.2';
|
|
3
|
+
type DiggRisk = 'low' | 'medium' | 'high' | 'critical';
|
|
4
|
+
type EAAImpact = 'none' | 'low' | 'medium' | 'high' | 'critical';
|
|
5
|
+
type TestComplexity = 'simple' | 'moderate' | 'complex';
|
|
6
|
+
interface ConvergenceRule {
|
|
7
|
+
ruleId: string;
|
|
8
|
+
wcagCriteria: string;
|
|
9
|
+
wcagLevel: WCAGLevel;
|
|
10
|
+
wcagTitle: string;
|
|
11
|
+
wcagVersion: WCAGVersion;
|
|
12
|
+
en301549Criteria: string;
|
|
13
|
+
en301549Title: string;
|
|
14
|
+
en301549Chapter: number;
|
|
15
|
+
dosLagenApplies: boolean;
|
|
16
|
+
dosLagenReference: string;
|
|
17
|
+
remediation: Remediation;
|
|
18
|
+
holmdigitalInsight: HolmDigitalInsight;
|
|
19
|
+
testability: Testability;
|
|
20
|
+
tags: string[];
|
|
21
|
+
}
|
|
22
|
+
interface Remediation {
|
|
23
|
+
description: string;
|
|
24
|
+
technicalGuidance: string;
|
|
25
|
+
component?: string | null;
|
|
26
|
+
codeExample?: string;
|
|
27
|
+
wcagTechnique?: string[];
|
|
28
|
+
}
|
|
29
|
+
interface HolmDigitalInsight {
|
|
30
|
+
diggRisk: DiggRisk;
|
|
31
|
+
eaaImpact: EAAImpact;
|
|
32
|
+
swedishInterpretation?: string;
|
|
33
|
+
[key: string]: any;
|
|
34
|
+
commonMistakes?: string[];
|
|
35
|
+
diggPrecedent?: string;
|
|
36
|
+
priorityRationale?: string;
|
|
37
|
+
}
|
|
38
|
+
interface Testability {
|
|
39
|
+
automated: boolean;
|
|
40
|
+
requiresManualCheck: boolean;
|
|
41
|
+
pseudoAutomation: boolean;
|
|
42
|
+
complexity: TestComplexity;
|
|
43
|
+
}
|
|
44
|
+
interface EN301549Mapping {
|
|
45
|
+
wcagCriteria: string;
|
|
46
|
+
wcagTitle: string;
|
|
47
|
+
wcagLevel: WCAGLevel;
|
|
48
|
+
en301549Criteria: string;
|
|
49
|
+
en301549Title: string;
|
|
50
|
+
dosLagenApplies: boolean;
|
|
51
|
+
dosLagenReference: string;
|
|
52
|
+
}
|
|
53
|
+
interface ICTManualCheck {
|
|
54
|
+
id: string;
|
|
55
|
+
chapter: number;
|
|
56
|
+
title: string;
|
|
57
|
+
description: string;
|
|
58
|
+
applicableFor: string[];
|
|
59
|
+
manualVerification: boolean;
|
|
60
|
+
checklistItem: string;
|
|
61
|
+
swedishGuidance: string;
|
|
62
|
+
diggRelevance: DiggRisk;
|
|
63
|
+
eaaRelevance: EAAImpact;
|
|
64
|
+
}
|
|
65
|
+
interface ComponentRecommendation {
|
|
66
|
+
component: string;
|
|
67
|
+
description: string;
|
|
68
|
+
codeExample: string;
|
|
69
|
+
wcagCriteria: string[];
|
|
70
|
+
}
|
|
71
|
+
interface RegulatoryReport {
|
|
72
|
+
ruleId: string;
|
|
73
|
+
wcagCriteria: string;
|
|
74
|
+
en301549Criteria: string;
|
|
75
|
+
dosLagenReference: string;
|
|
76
|
+
diggRisk: DiggRisk;
|
|
77
|
+
eaaImpact: EAAImpact;
|
|
78
|
+
remediation: Remediation;
|
|
79
|
+
holmdigitalInsight: HolmDigitalInsight;
|
|
80
|
+
testability: Testability;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
declare function getEN301549Mapping(wcagCriteria: string, lang?: string): EN301549Mapping | null;
|
|
84
|
+
declare function getDOSLagenReference(wcagCriteria: string, lang?: string): string | null;
|
|
85
|
+
declare function getICTManualChecklist(): ICTManualCheck[];
|
|
86
|
+
declare function getICTManualChecksByCategory(category: string): ICTManualCheck[];
|
|
87
|
+
declare function getICTManualChecksByChapter(chapter: number): ICTManualCheck[];
|
|
88
|
+
declare function getRecommendedComponent(ruleId: string, lang?: string): ComponentRecommendation | null;
|
|
89
|
+
declare function getHolmDigitalInsight(ruleId: string, lang?: string): HolmDigitalInsight | null;
|
|
90
|
+
declare function getConvergenceRule(ruleId: string, lang?: string): ConvergenceRule | null;
|
|
91
|
+
declare function getAllConvergenceRules(lang?: string): ConvergenceRule[];
|
|
92
|
+
declare function getConvergenceRulesByLevel(level: WCAGLevel, lang?: string): ConvergenceRule[];
|
|
93
|
+
declare function getConvergenceRulesByDiggRisk(risk: DiggRisk, lang?: string): ConvergenceRule[];
|
|
94
|
+
declare function generateRegulatoryReport(ruleId: string, lang?: string): RegulatoryReport | null;
|
|
95
|
+
declare function searchRulesByTags(tags: string[], lang?: string): ConvergenceRule[];
|
|
96
|
+
declare function getAllTags(lang?: string): string[];
|
|
97
|
+
declare function isWCAGCriteriaSupported(wcagCriteria: string, lang?: string): boolean;
|
|
98
|
+
declare function getDatabaseStats(lang?: string): {
|
|
99
|
+
totalRules: number;
|
|
100
|
+
totalICTChecks: number;
|
|
101
|
+
rulesByLevel: {
|
|
102
|
+
A: number;
|
|
103
|
+
AA: number;
|
|
104
|
+
AAA: number;
|
|
105
|
+
};
|
|
106
|
+
rulesByDiggRisk: {
|
|
107
|
+
low: number;
|
|
108
|
+
medium: number;
|
|
109
|
+
high: number;
|
|
110
|
+
critical: number;
|
|
111
|
+
};
|
|
112
|
+
automatedRules: number;
|
|
113
|
+
manualRules: number;
|
|
114
|
+
pseudoAutomationRules: number;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
export { type ComponentRecommendation, type ConvergenceRule, type DiggRisk, type EAAImpact, type EN301549Mapping, type HolmDigitalInsight, type ICTManualCheck, type RegulatoryReport, type Remediation, type Testability, type WCAGLevel, generateRegulatoryReport, getAllConvergenceRules, getAllTags, getConvergenceRule, getConvergenceRulesByDiggRisk, getConvergenceRulesByLevel, getDOSLagenReference, getDatabaseStats, getEN301549Mapping, getHolmDigitalInsight, getICTManualChecklist, getICTManualChecksByCategory, getICTManualChecksByChapter, getRecommendedComponent, isWCAGCriteriaSupported, searchRulesByTags };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
type WCAGLevel = 'A' | 'AA' | 'AAA';
|
|
2
|
+
type WCAGVersion = '2.0' | '2.1' | '2.2';
|
|
3
|
+
type DiggRisk = 'low' | 'medium' | 'high' | 'critical';
|
|
4
|
+
type EAAImpact = 'none' | 'low' | 'medium' | 'high' | 'critical';
|
|
5
|
+
type TestComplexity = 'simple' | 'moderate' | 'complex';
|
|
6
|
+
interface ConvergenceRule {
|
|
7
|
+
ruleId: string;
|
|
8
|
+
wcagCriteria: string;
|
|
9
|
+
wcagLevel: WCAGLevel;
|
|
10
|
+
wcagTitle: string;
|
|
11
|
+
wcagVersion: WCAGVersion;
|
|
12
|
+
en301549Criteria: string;
|
|
13
|
+
en301549Title: string;
|
|
14
|
+
en301549Chapter: number;
|
|
15
|
+
dosLagenApplies: boolean;
|
|
16
|
+
dosLagenReference: string;
|
|
17
|
+
remediation: Remediation;
|
|
18
|
+
holmdigitalInsight: HolmDigitalInsight;
|
|
19
|
+
testability: Testability;
|
|
20
|
+
tags: string[];
|
|
21
|
+
}
|
|
22
|
+
interface Remediation {
|
|
23
|
+
description: string;
|
|
24
|
+
technicalGuidance: string;
|
|
25
|
+
component?: string | null;
|
|
26
|
+
codeExample?: string;
|
|
27
|
+
wcagTechnique?: string[];
|
|
28
|
+
}
|
|
29
|
+
interface HolmDigitalInsight {
|
|
30
|
+
diggRisk: DiggRisk;
|
|
31
|
+
eaaImpact: EAAImpact;
|
|
32
|
+
swedishInterpretation?: string;
|
|
33
|
+
[key: string]: any;
|
|
34
|
+
commonMistakes?: string[];
|
|
35
|
+
diggPrecedent?: string;
|
|
36
|
+
priorityRationale?: string;
|
|
37
|
+
}
|
|
38
|
+
interface Testability {
|
|
39
|
+
automated: boolean;
|
|
40
|
+
requiresManualCheck: boolean;
|
|
41
|
+
pseudoAutomation: boolean;
|
|
42
|
+
complexity: TestComplexity;
|
|
43
|
+
}
|
|
44
|
+
interface EN301549Mapping {
|
|
45
|
+
wcagCriteria: string;
|
|
46
|
+
wcagTitle: string;
|
|
47
|
+
wcagLevel: WCAGLevel;
|
|
48
|
+
en301549Criteria: string;
|
|
49
|
+
en301549Title: string;
|
|
50
|
+
dosLagenApplies: boolean;
|
|
51
|
+
dosLagenReference: string;
|
|
52
|
+
}
|
|
53
|
+
interface ICTManualCheck {
|
|
54
|
+
id: string;
|
|
55
|
+
chapter: number;
|
|
56
|
+
title: string;
|
|
57
|
+
description: string;
|
|
58
|
+
applicableFor: string[];
|
|
59
|
+
manualVerification: boolean;
|
|
60
|
+
checklistItem: string;
|
|
61
|
+
swedishGuidance: string;
|
|
62
|
+
diggRelevance: DiggRisk;
|
|
63
|
+
eaaRelevance: EAAImpact;
|
|
64
|
+
}
|
|
65
|
+
interface ComponentRecommendation {
|
|
66
|
+
component: string;
|
|
67
|
+
description: string;
|
|
68
|
+
codeExample: string;
|
|
69
|
+
wcagCriteria: string[];
|
|
70
|
+
}
|
|
71
|
+
interface RegulatoryReport {
|
|
72
|
+
ruleId: string;
|
|
73
|
+
wcagCriteria: string;
|
|
74
|
+
en301549Criteria: string;
|
|
75
|
+
dosLagenReference: string;
|
|
76
|
+
diggRisk: DiggRisk;
|
|
77
|
+
eaaImpact: EAAImpact;
|
|
78
|
+
remediation: Remediation;
|
|
79
|
+
holmdigitalInsight: HolmDigitalInsight;
|
|
80
|
+
testability: Testability;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
declare function getEN301549Mapping(wcagCriteria: string, lang?: string): EN301549Mapping | null;
|
|
84
|
+
declare function getDOSLagenReference(wcagCriteria: string, lang?: string): string | null;
|
|
85
|
+
declare function getICTManualChecklist(): ICTManualCheck[];
|
|
86
|
+
declare function getICTManualChecksByCategory(category: string): ICTManualCheck[];
|
|
87
|
+
declare function getICTManualChecksByChapter(chapter: number): ICTManualCheck[];
|
|
88
|
+
declare function getRecommendedComponent(ruleId: string, lang?: string): ComponentRecommendation | null;
|
|
89
|
+
declare function getHolmDigitalInsight(ruleId: string, lang?: string): HolmDigitalInsight | null;
|
|
90
|
+
declare function getConvergenceRule(ruleId: string, lang?: string): ConvergenceRule | null;
|
|
91
|
+
declare function getAllConvergenceRules(lang?: string): ConvergenceRule[];
|
|
92
|
+
declare function getConvergenceRulesByLevel(level: WCAGLevel, lang?: string): ConvergenceRule[];
|
|
93
|
+
declare function getConvergenceRulesByDiggRisk(risk: DiggRisk, lang?: string): ConvergenceRule[];
|
|
94
|
+
declare function generateRegulatoryReport(ruleId: string, lang?: string): RegulatoryReport | null;
|
|
95
|
+
declare function searchRulesByTags(tags: string[], lang?: string): ConvergenceRule[];
|
|
96
|
+
declare function getAllTags(lang?: string): string[];
|
|
97
|
+
declare function isWCAGCriteriaSupported(wcagCriteria: string, lang?: string): boolean;
|
|
98
|
+
declare function getDatabaseStats(lang?: string): {
|
|
99
|
+
totalRules: number;
|
|
100
|
+
totalICTChecks: number;
|
|
101
|
+
rulesByLevel: {
|
|
102
|
+
A: number;
|
|
103
|
+
AA: number;
|
|
104
|
+
AAA: number;
|
|
105
|
+
};
|
|
106
|
+
rulesByDiggRisk: {
|
|
107
|
+
low: number;
|
|
108
|
+
medium: number;
|
|
109
|
+
high: number;
|
|
110
|
+
critical: number;
|
|
111
|
+
};
|
|
112
|
+
automatedRules: number;
|
|
113
|
+
manualRules: number;
|
|
114
|
+
pseudoAutomationRules: number;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
export { type ComponentRecommendation, type ConvergenceRule, type DiggRisk, type EAAImpact, type EN301549Mapping, type HolmDigitalInsight, type ICTManualCheck, type RegulatoryReport, type Remediation, type Testability, type WCAGLevel, generateRegulatoryReport, getAllConvergenceRules, getAllTags, getConvergenceRule, getConvergenceRulesByDiggRisk, getConvergenceRulesByLevel, getDOSLagenReference, getDatabaseStats, getEN301549Mapping, getHolmDigitalInsight, getICTManualChecklist, getICTManualChecksByCategory, getICTManualChecksByChapter, getRecommendedComponent, isWCAGCriteriaSupported, searchRulesByTags };
|