Accessibility: Add WCAG accessibility issue automation (#31479)

This commit is contained in:
Tom Ross 2022-02-18 15:11:05 +00:00 committed by GitHub
parent bbcce5e8f2
commit 9d80bba425
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 59 additions and 0 deletions

View File

@ -0,0 +1,37 @@
name: Accessibility issue
description: Create an issue that is automatically attached to the WCAG 2.1 AA Tracking Issue
title: '[Accessibility]: '
labels:
- 'accessibility'
- 'wcag/2.1'
- 'wcag/2.1/fixing'
- 'estimate/3d'
body:
- type: markdown
attributes:
value: |
Thanks for your contribution to the accessibility of Sourcegraph!
Please note that this issue has been automatically given an estimate of **3 days**.
You can modify this estimate by changing the label from *estimate/3d* to *estimate/Xd* where X is the correct number of days.
- type: textarea
id: problem-description
attributes:
label: Problem description
description: Please describe the issue is as much detail as possible
validations:
required: true
- type: textarea
id: solution-description
attributes:
label: Expected behavior
description: Please describe the expected behavior
validations:
required: true
- type: textarea
id: additional-details
attributes:
label: Additional details
description: Notes and/or screenshot describing the problem, details how to replicate, etc
validations:
required: false

View File

@ -198,3 +198,25 @@ jobs:
}
}
}' -f project=$PROJECT_ID -f node_id=$NODE_ID
wcag-accessibility-board:
runs-on: ubuntu-latest
env:
PROJECT_ID: PN_kwDOADy5QM4AAyDB # https://github.com/orgs/sourcegraph/projects/238
GITHUB_TOKEN: ${{ secrets.GH_PROJECTS_ACTION_TOKEN }}
steps:
- name: Get issue if relevant
if: ${{ contains(github.event.issue.labels.*.name, 'wcag/2.1') }}
env:
NODE_ID: ${{ github.event.issue.node_id }}
run: echo 'NODE_ID='$NODE_ID >> $GITHUB_ENV
- name: Add to Accessibility board
if: ${{ env.NODE_ID != '' }}
run: |
gh api graphql --header 'GraphQL-Features: projects_next_graphql' -f query='
mutation($project:ID!, $node_id:ID!) {
addProjectNextItem(input: {projectId: $project, contentId: $node_id}) {
projectNextItem {
id
}
}
}' -f project=$PROJECT_ID -f node_id=$NODE_ID