Skip to content

Commit

Permalink
Update docs for v1.0.0 alpha.5 (#70)
Browse files Browse the repository at this point in the history
* Document `ignoreElements` input

* Update changelog for v1.0.0-alpha.5
  • Loading branch information
mxmason authored Nov 29, 2021
1 parent 25f04c8 commit 0565530
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 6 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

Prior to v1.0.0-alpha.1, logs were generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).

## [v1.0.0-alpha.5](https://github.com/netlify-labs/netlify-plugin-a11y/compare/v1.0.0-alpha.4...v1.0.0-alpha.5)

### Added
- New input: `ignoreElements`. Used to indicate to the test runner elements which should be ignored during a11y testing.
### Changed
- Lowers minimum required version of Node from `12.13.0` to `12.0.0`.
- Internal: Uses a local server powered by the Node `http` module to host files prior to testing. This local server makes tests more accurate and more secure!
## [v1.0.0-alpha.4](https://github.com/netlify-labs/netlify-plugin-a11y/compare/v1.0.0-alpha.3...v1.0.0-alpha.4)
### Changed
- Added a pre-release notice to the README, as well as other copy cleanup.
Expand Down
15 changes: 9 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,13 @@ If you want to use the plugin's default settings (check **all** pages of your si
If you've installed the plugin via `netlify.toml`, you can add a `[[plugins.inputs]]` field to change how the plugin behaves. This table outlines the inputs the plugin accepts. All of them are optional.


| Input name | Description | Value type | Possible values | Default value |
|---------------------|----------------------------------------------------------|------------------|-----------------------------------------------|---------------|
| `checkPaths` | Indicates which pages of your site to check | Array of strings | Any directories or HTML files in your project | `['/']` |
| `failWithIssues` | Whether the build should fail if a11y issues are found | Boolean | `true` or `false` | `true` |
| `ignoreDirectories` | Directories that *should not* be checked for a11y issues | Array of strings | Any directories in your project | `[]` |
| `wcagLevel` | The WCAG standard level against which pages are checked | String | `'WCAG2A'` or `'WCAGA2A'` or `'WCAG2AAA'` | `'WCAG2AA'` |
| Input name | Description | Value type | Possible values | Default value |
|---------------------|-----------------------------------------------------------|-----------------------|-------------------------------------------------------|---------------|
| `checkPaths` | Indicates which pages of your site to check | Array of strings | Any directories or HTML files in your project | `['/']` |
| `failWithIssues` | Whether the build should fail if a11y issues are found | Boolean | `true` or `false` | `true` |
| `ignoreDirectories` | Directories that *should not* be checked for a11y issues | Array of strings | Any directories in your project | `[]` |
| `ignoreElements` | Indicates elements that should be ignored by a11y testing | String (CSS selector) | Comma-separated string of CSS selectors | `undefined` |
| `wcagLevel` | The WCAG standard level against which pages are checked | String | `'WCAG2A'` or `'WCAGA2A'` or `'WCAG2AAA'` | `'WCAG2AA'` |

Here's how these inputs can be used in `netlify.toml`, with comments to explain how each input affects the plugin's behavior:

Expand All @@ -111,6 +112,8 @@ Here's how these inputs can be used in `netlify.toml`, with comments to explain
failWithIssues = false
# Ignore all HTML files in `/admin`
ignoreDirectories = ['/admin']
# Ignore any accessibility issues associated with an element matching this selector
ignoreElements = '.jumbotron > h2'
# Perform a11y check against WCAG 2.1 AAA
wcagLevel = 'WCAG2AAA'
```

0 comments on commit 0565530

Please sign in to comment.