created:3/5/2021
updated:3/5/2021
loc
37
comments
32%
passed
10
coverage
50%

Toggle

avatar of atanasster

Toggle components can be used to edit boolean values. Uses react-switch component.

Tests results

Status
Full name
Title
Time(ms)
Toggle.test.ts(10 tests)
passed
Toggle > overview
snapshot
95
passed
Toggle > overview
accessibility
376
passed
Toggle > label
snapshot
518
passed
Toggle > label
accessibility
930
passed
Toggle > customIcons
snapshot
91
passed
Toggle > customIcons
accessibility
186
passed
Toggle > octicons
snapshot
42
passed
Toggle > octicons
accessibility
400
passed
Toggle > checkbox
snapshot
60
total 10 tests

Tests coverage

Kind
Total
Covered
Skipped
%
Toggle.tsx
lines
11
11
0
100%
functions
1
1
0
100%
statements
12
12
0
100%
branches
4
2
0
50%

A11y tests

 
id
description
aria-allowed-attr

Ensures ARIA attributes are allowed for an element's role...

aria-allowed-role

Ensures role attribute has an appropriate value for the element...

aria-required-attr

Ensures elements with ARIA roles have all required ARIA attributes...

aria-roles

Ensures all elements with a role attribute use a valid value...

aria-valid-attr-value

Ensures all ARIA attributes have valid values...

aria-valid-attr

Ensures attributes that begin with aria- are valid ARIA attributes...

avoid-inline-spacing

Ensure that text spacing set through style attributes can be adjusted with custom stylesheets...

form-field-multiple-labels

Ensures form field does not have multiple label elements...

label-title-only

Ensures that every form element has a visible label and is not solely labeled using hidden labels, or the title or aria-describedby attributes...

label

Ensures every form element has a label...

nested-interactive

Ensure controls are not nested as they are not announced by screen readers...

Viewport

320px
375px
768px
1024px