const rules = [
{
pattern: 'Should have an accessible name.',
comment: `Can be named by children (children should be purely presentational and
do not include interactive elements).`,
status: 'DONE',
tests: 'DONE',
},
{
pattern: 'Should be focusable and tabable.',
status: 'DONE',
tests: 'DONE',
},
{
pattern: 'Should have visible checked / unchecked / disabled style.',
status: 'DONE',
tests: 'N/A',
},
{
pattern: 'Should have visible focus and hover style.',
status: 'DONE',
tests: 'N/A',
},
{
pattern:
'Should have a label with 4.5:1 contrast ratio against the background.',
comment: 'black against white: 21:1.',
status: 'DONE',
tests: 'N/A',
},
{
pattern:
'Should have a selected indicator with 3:1 contrast ratio against the background.',
comment: 'black against white: 21:1',
status: 'DONE',
tests: 'N/A',
},
{
pattern: 'Should respect Windows High Contrast mode.',
status: 'DONE',
tests: 'N/A',
},
{
pattern: 'Should respect prefers reduce motion settings.',
status: 'DONE',
tests: 'N/A',
},
{
pattern:
'Should be checked by pressing Space and mouse click.',
comment:
"If the Radio with focus is unchecked, it's state will be changed to checked.",
status: 'DONE',
tests: 'DONE',
},
{
pattern: 'Should be focused and checked by pressing arrows.',
status: 'DONE',
tests: 'N/A',
},
{
pattern: 'Can have an accessible description.',
comment:
'Can be described by setting a value for description prop.',
status: 'DONE',
tests: 'DONE',
},
];
export const singleSelectRules = [
{
pattern: 'Should have a role radio.',
status: 'DONE',
tests: 'DONE',
},
{
pattern:
'Should be nested in a radiogroup or be grouped by using name attribute.',
comment: 'ChipGroup component can be used.',
status: 'DONE',
tests: 'N/A',
},
];
export const multiSelectRules = [
{
pattern: 'Should have a role checkbox.',
status: 'DONE',
tests: 'DONE',
},
{
pattern:
'Can be nested in a group or be grouped by using name attribute.',
comment: 'ChipGroup component can be used.',
status: 'DONE',
tests: 'N/A',
},
];
export const groupRules = [
{
pattern: 'Can have an accessible name.',
comment: `Can be named by:
aria-label propIDREF) set for the aria-labelledby
prop that refers to an element.aria-describedby prop.',
status: 'DONE',
tests: 'DONE',
},
];
export const singleSelectGroupRules = [
{
pattern: 'Should have a role radiogroup.',
status: 'DONE',
tests: 'DONE',
},
{
pattern: 'Should have only one checked chip at a time.',
status: 'DONE',
tests: 'DONE',
},
];
export const multiSelectGroupRules = [
{
pattern: 'Should have a role group.',
status: 'DONE',
tests: 'DONE',
},
{
pattern: 'Can have multiple checked chips at a time.',
status: 'DONE',
tests: 'DONE',
},
];
export default rules;