@surea11y/pack-raweb 0.0.0-stage → 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/index.js ADDED
@@ -0,0 +1,42 @@
1
+ /* SPDX-License-Identifier: MPL-2.0 */
2
+
3
+ 'use strict';
4
+
5
+ /**
6
+ * RAWeb 1.1, Luxembourg's framework for assessing the accessibility of
7
+ * websites, as a pack for @surea11y/core. Passed to a scan in
8
+ * engineOptions.packs with @surea11y/pack-rgaa, which it builds on, it brings
9
+ * the standard (RAWeb's criteria and tests, in its own French and English,
10
+ * standard-data.js), one rollup per criterion, the raweb-1.1 profile and the
11
+ * law it is used for, and RAWeb's methodology as the procedures a person
12
+ * follows.
13
+ *
14
+ * RAWeb is an adaptation of RGAA 4.1.2: the pack takes pack-rgaa's data and
15
+ * rule map (core's deriveStandard) and runs pack-rgaa's rules (uses), with
16
+ * the changes RAWeb's wording requires (docs/RULE_MAP_REVIEW.md). It has no
17
+ * rules of its own.
18
+ */
19
+
20
+ const { definePack, standardFromData } = require('@surea11y/core/pack');
21
+ const rgaa = require('@surea11y/pack-rgaa');
22
+ const { name, version } = require('./package.json');
23
+ const { STANDARD_DATA } = require('./standard-data');
24
+
25
+ const standard = standardFromData(STANDARD_DATA, {
26
+ report: { titleLang: 'fr' }
27
+ });
28
+
29
+ module.exports = definePack({
30
+ name,
31
+ version,
32
+ namespace: 'raweb',
33
+ // The pack uses other packs (uses), its standard is derived from
34
+ // pack-rgaa's data, and it routes findings by fields of pack-rgaa's rules:
35
+ // core's APIs for these are experimental until 1.18.0 or later, so the
36
+ // range takes no later minor.
37
+ core: '~1.17.0',
38
+ description: 'RAWeb 1.1, the Luxembourg accessibility framework',
39
+ uses: [rgaa],
40
+ rules: [],
41
+ standard
42
+ });