Skip to content

Commit

Permalink
Fix prettier conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
Valerie Young committed Oct 22, 2020
2 parents 61a2ade + 6485d4c commit f666e9d
Show file tree
Hide file tree
Showing 178 changed files with 27,800 additions and 20,917 deletions.
2 changes: 1 addition & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "eslint:recommended",
"extends": ["eslint:recommended", "plugin:prettier/recommended"],
"env": {
"browser": true
},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverage-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
node test/util/report.js >> coverage.log || true
- name: Comment on PR
uses: actions/github-script@0.9.0
uses: actions/github-script@v3
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
Expand Down
16 changes: 16 additions & 0 deletions .github/workflows/cspell-problem-matcher.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"problemMatcher": [
{
"owner": "cspell",
"pattern": [
{
"regexp": "^(.*):(\\d+):(\\d+)\\s+\\-\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4
}
]
}
]
}
6 changes: 4 additions & 2 deletions .github/workflows/lint-css.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
- "dependabot/**"
paths:
- "package*.json"
- ".prettier*"
- ".stylelint*"
- "**/*.css"
- ".github/workflows/lint-css.yml"
Expand All @@ -13,21 +14,22 @@ on:
pull_request:
paths:
- "package*.json"
- ".prettier*"
- ".stylelint*"
- "**/*.css"
- ".github/workflows/lint-css.yml"
- "!common/**"

jobs:
lint:
lint-css:
runs-on: ubuntu-latest

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v2.1.2

- uses: xt0rted/stylelint-problem-matcher@v1

Expand Down
40 changes: 40 additions & 0 deletions .github/workflows/lint-html.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: HTML Linting
on:
push:
branches-ignore:
- "dependabot/**"
paths:
- "package*.json"
- ".vnurc"
- "aria-practices.html"
- "examples/**/*.html"
- ".github/workflows/lint-html.yml"
- ".github/workflows/vnu-jar-problem-matcher.json"

pull_request:
paths:
- "package*.json"
- ".vnurc"
- "aria-practices.html"
- "examples/**/*.html"
- ".github/workflows/lint-html.yml"
- ".github/workflows/vnu-jar-problem-matcher.json"

jobs:
lint-html:
runs-on: ubuntu-latest

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/[email protected]

- name: Install npm dependencies
run: npm ci

- name: HTML Validator
run: |
echo "::add-matcher::.github/workflows/vnu-jar-problem-matcher.json"
npm run lint:html
8 changes: 6 additions & 2 deletions .github/workflows/lint-js.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
name: JavaScript Linting
on:
push:
branches-ignore:
- "dependabot/**"
paths:
- "package*.json"
- ".prettier*"
- ".eslint*"
- "**/*.js"
- ".github/workflows/lint-js.yml"
Expand All @@ -11,13 +14,14 @@ on:
pull_request:
paths:
- "package*.json"
- ".prettier*"
- ".eslint*"
- "**/*.js"
- ".github/workflows/lint-js.yml"
- "!common/**"

jobs:
lint:
lint-js:
runs-on: ubuntu-latest

steps:
Expand All @@ -27,7 +31,7 @@ jobs:
# setup-node task is used without a particular version in order to load
# the ESLint problem matchers
- name: Set up Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v2.1.2

- name: Install npm dependencies
run: npm ci
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/regression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ on:
- "!examples/landmarks/**"

jobs:
deploy:
regression:
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand All @@ -33,7 +33,7 @@ jobs:
fetch-depth: 0

- name: Set up Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v2.1.2

- name: Install npm dependencies
run: npm ci
Expand Down
41 changes: 41 additions & 0 deletions .github/workflows/spelling.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Spellcheck

on:
push:
branches-ignore:
- "dependabot/**"
paths:
- "package*.json"
- "cspell.json"
- "aria-practices.html"
- "examples/**/*.html"
- ".github/workflows/cspell-problem-matcher.json"
- ".github/workflows/spelling.yml"

pull_request:
paths:
- "package*.json"
- "cspell.json"
- "aria-practices.html"
- "examples/**/*.html"
- ".github/workflows/cspell-problem-matcher.json"
- ".github/workflows/spelling.yml"

jobs:
spelling:
runs-on: ubuntu-latest

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/[email protected]

- name: Install npm dependencies
run: npm ci

- name: cSpell
run: |
echo "::add-matcher::.github/workflows/cspell-problem-matcher.json"
npm run lint:spelling
17 changes: 17 additions & 0 deletions .github/workflows/vnu-jar-problem-matcher.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"problemMatcher": [
{
"owner": "vnu-jar",
"pattern": [
{
"regexp": "^\"file:(.*)\":(\\d+).(\\d+)-\\d+\\.\\d+:\\s(error|warning):\\s(.*)$",
"file": 1,
"line": 2,
"column": 3,
"severity": 4,
"message": 5
}
]
}
]
}
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Ignore external copied w3c files
common
3 changes: 3 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"singleQuote": true
}
5 changes: 3 additions & 2 deletions .stylelintrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "stylelint-config-standard",
"extends": ["stylelint-config-standard", "stylelint-prettier/recommended"],
"rules": {
"media-feature-name-no-unknown": [
true,
Expand All @@ -9,6 +9,7 @@
]
}
],
"no-descending-specificity": null
"no-descending-specificity": null,
"prettier/prettier": [true, {"singleQuote": false}]
}
}
17 changes: 2 additions & 15 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,6 @@ node_js:
git:
depth: 3

stages:
- Lint
install: true

jobs:
fast_finish: true
allow_failures:
- env: ALLOW_FAILURE=true

include:
- stage: Lint
name: HTML Linting
script: npm run vnu-jar
- stage: Lint
name: Spellcheck
script: npm run lint:spelling
env: ALLOW_FAILURE=true
script: true
2 changes: 0 additions & 2 deletions .vnurc
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,3 @@ Attribute “aria-posinset” not allowed on element “tr” at this point.
Attribute “aria-setsize” not allowed on element “tr” at this point.
# Ignoring role meter
Bad value “meter” for attribute “role” on element “div”.
# Deleted Section Archive
The “longdesc” attribute on the “img” element is obsolete. Use a regular “a” element to link to the description.
2 changes: 1 addition & 1 deletion aria-practices.html
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,7 @@ <h3>Carousel (Slide Show or Image Rotator)</h3>
<section class="notoc">
<h4>Examples</h4>
<ul>
<li><a href="examples/carousel/carousel-1.html">Auto-Rotating Image Carousel with Buttons for Slide Control:</a> A basic image carousel that demonstrates the accessibility features necessary for carousels that rotate automatically on page load and also enables users to choose which slide is displayed with buttons for previous and next slide.</li>
<li><a href="examples/carousel/carousel-1-prev-next.html">Auto-Rotating Image Carousel with Buttons for Slide Control:</a> A basic image carousel that demonstrates the accessibility features necessary for carousels that rotate automatically on page load and also enables users to choose which slide is displayed with buttons for previous and next slide.</li>
<li><a href="examples/carousel/carousel-2-tablist.html">Auto-Rotating Image Carousel with Tabs for Slide Control:</a> An image carousel that demonstrates accessibility features necessary for carousels that rotate automatically on page load and also enables users to choose which slide is displayed with a set of tabs.</li>
</ul>
</section>
Expand Down
6 changes: 6 additions & 0 deletions cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,14 @@
"src=\"(?:[^\\\"]+|\\.)*\"",
"class=\"(?:[^\\\"]+|\\.)*\"",
"data-test-id=\"(?:[^\\\"]+|\\.)*\"",
"aria-activedescendant=\"(?:[^\\\"]+|\\.)*\"",
"aria-controls=\"(?:[^\\\"]+|\\.)*\"",
"aria-describedby=\"(?:[^\\\"]+|\\.)*\"",
"aria-details=\"(?:[^\\\"]+|\\.)*\"",
"aria-errormessage=\"(?:[^\\\"]+|\\.)*\"",
"aria-flowto=\"(?:[^\\\"]+|\\.)*\"",
"aria-labelledby=\"(?:[^\\\"]+|\\.)*\"",
"aria-owns=\"(?:[^\\\"]+|\\.)*\"",
"href=\"(?:[^\\\"]+|\\.)*\"",
"for=\"(?:[^\\\"]+|\\.)*\"",
"data-(.*[=> ]?)"
Expand Down
Loading

0 comments on commit f666e9d

Please sign in to comment.