@mcptoolshop/a11y-ci 0.2.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 +35 -0
- package/bin/a11y-ci.js +26 -0
- package/package.json +35 -0
- package/postinstall.js +11 -0
package/README.md
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# @mikeyfrilot/a11y-ci
|
|
2
|
+
|
|
3
|
+
npm wrapper for [a11y-ci](https://pypi.org/project/a11y-ci/) - CI gate for accessibility scorecards (low-vision-first).
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install -g @mikeyfrilot/a11y-ci
|
|
9
|
+
# or
|
|
10
|
+
npx @mikeyfrilot/a11y-ci --help
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Prerequisites
|
|
14
|
+
|
|
15
|
+
Requires the Python `a11y-ci` package:
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
pip install a11y-ci
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Usage
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
a11y-ci check scorecard.json
|
|
25
|
+
a11y-ci gate --min-score 80
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Links
|
|
29
|
+
|
|
30
|
+
- **PyPI**: https://pypi.org/project/a11y-ci/
|
|
31
|
+
- **GitHub**: https://github.com/mcp-tool-shop/a11y-ci
|
|
32
|
+
|
|
33
|
+
## License
|
|
34
|
+
|
|
35
|
+
MIT
|
package/bin/a11y-ci.js
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
const { spawn } = require('child_process');
|
|
3
|
+
|
|
4
|
+
async function main() {
|
|
5
|
+
const args = process.argv.slice(2);
|
|
6
|
+
const a11yCi = spawn('a11y-ci', args, {
|
|
7
|
+
stdio: 'inherit',
|
|
8
|
+
shell: true
|
|
9
|
+
});
|
|
10
|
+
|
|
11
|
+
a11yCi.on('close', (code) => {
|
|
12
|
+
process.exit(code || 0);
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
a11yCi.on('error', (err) => {
|
|
16
|
+
console.error('❌ a11y-ci is not installed.');
|
|
17
|
+
console.error('');
|
|
18
|
+
console.error('Please install a11y-ci using pip:');
|
|
19
|
+
console.error(' pip install a11y-ci');
|
|
20
|
+
console.error('');
|
|
21
|
+
console.error('PyPI: https://pypi.org/project/a11y-ci/');
|
|
22
|
+
process.exit(1);
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
main();
|
package/package.json
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@mcptoolshop/a11y-ci",
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"description": "npm wrapper for a11y-ci - CI gate for accessibility scorecards",
|
|
5
|
+
"bin": {
|
|
6
|
+
"a11y-ci": "./bin/a11y-ci.js"
|
|
7
|
+
},
|
|
8
|
+
"scripts": {
|
|
9
|
+
"postinstall": "node postinstall.js"
|
|
10
|
+
},
|
|
11
|
+
"keywords": [
|
|
12
|
+
"accessibility",
|
|
13
|
+
"a11y",
|
|
14
|
+
"ci",
|
|
15
|
+
"testing",
|
|
16
|
+
"wcag",
|
|
17
|
+
"python",
|
|
18
|
+
"wrapper"
|
|
19
|
+
],
|
|
20
|
+
"author": "mcp-tool-shop <64996768+mcp-tool-shop@users.noreply.github.com>",
|
|
21
|
+
"license": "MIT",
|
|
22
|
+
"repository": {
|
|
23
|
+
"type": "git",
|
|
24
|
+
"url": "https://github.com/mcp-tool-shop/a11y-ci.git",
|
|
25
|
+
"directory": "npm"
|
|
26
|
+
},
|
|
27
|
+
"homepage": "https://github.com/mcp-tool-shop/a11y-ci#readme",
|
|
28
|
+
"engines": {
|
|
29
|
+
"node": ">=18.0.0"
|
|
30
|
+
},
|
|
31
|
+
"publishConfig": {
|
|
32
|
+
"access": "public",
|
|
33
|
+
"registry": "https://registry.npmjs.org"
|
|
34
|
+
}
|
|
35
|
+
}
|
package/postinstall.js
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
console.log('');
|
|
3
|
+
console.log('📦 @mikeyfrilot/a11y-ci installed!');
|
|
4
|
+
console.log('');
|
|
5
|
+
console.log('⚠️ This is an npm wrapper for the Python package "a11y-ci".');
|
|
6
|
+
console.log('');
|
|
7
|
+
console.log('To use a11y-ci, install the Python package:');
|
|
8
|
+
console.log(' pip install a11y-ci');
|
|
9
|
+
console.log('');
|
|
10
|
+
console.log('PyPI: https://pypi.org/project/a11y-ci/');
|
|
11
|
+
console.log('');
|