-
Notifications
You must be signed in to change notification settings - Fork 73
42 lines (40 loc) · 1.8 KB
/
add-a11y-checklist.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Add A11Y checklist
on:
pull_request:
types: [opened, synchronize]
jobs:
add-a11y-check-if-necessary:
name: Add A11Y check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get changed files in the site folder
id: changed-files-specific
uses: tj-actions/changed-files@v36
with:
files: |
site/**
- name: Find Comment
if: steps.changed-files-specific.outputs.any_changed == 'true'
uses: peter-evans/find-comment@v2
id: find-comment
with:
issue-number: ${{ github.event.pull_request.number }} #e.g. 1
comment-author: 'github-actions[bot]'
body-includes: accessibilité
- name: Create comment
if: github.event.pull_request.head.repo.full_name == github.repository && steps.changed-files-specific.outputs.any_changed == 'true' && steps.find-comment.outputs.comment-id == ''
uses: peter-evans/create-or-update-comment@v3
with:
issue-number: ${{ github.event.pull_request.number }}
comment-id: ${{ steps.find-comment.outputs.comment-id }}
body: |
## ♿ Checklist accessibilité :
Quelques points à vérifier pour maintenir une bonne accessibilité du site :
- [ ] les labels des boutons et des liens sont descriptifs
- [ ] un aria-label est ajouté pour préciser l'action d'un bouton ou d'un lien pour les lecteurs d'écran
- [ ] les couleurs du texte est suffisamment constratée par rapport à la couleur de background
- [ ] la fonctionnalité ajoutée est utilisable en navigant au clavier et avec un lecteur d'écran
- [ ] les changements de contexte sont évités ou au minimum annoncés