diff --git a/playwright/cps-accessibility.spec.ts b/playwright/cps-accessibility.spec.ts index d45ee3c4b..55d8be9ed 100644 --- a/playwright/cps-accessibility.spec.ts +++ b/playwright/cps-accessibility.spec.ts @@ -195,7 +195,7 @@ const components: ComponentEntry[] = [ name: 'Sidebar menu', selector: 'cps-sidebar-menu' }, - // { route: '/switch', name: 'Switch', selector: 'cps-switch' }, + { route: '/switch', name: 'Switch', selector: 'cps-switch' }, { route: '/tab-group', name: 'Tabs', diff --git a/projects/composition/src/app/api-data/cps-switch.json b/projects/composition/src/app/api-data/cps-switch.json index a2053f90a..54122d361 100644 --- a/projects/composition/src/app/api-data/cps-switch.json +++ b/projects/composition/src/app/api-data/cps-switch.json @@ -11,7 +11,15 @@ "readonly": false, "type": "string", "default": "", - "description": "Label of the component." + "description": "Label of the switch component." + }, + { + "name": "ariaLabel", + "optional": false, + "readonly": false, + "type": "string", + "default": "", + "description": "Aria label for the switch component, used for accessibility, it takes precedence over label." }, { "name": "disabled", @@ -19,7 +27,7 @@ "readonly": false, "type": "boolean", "default": "false", - "description": "Determines whether the component is disabled." + "description": "Determines whether the switch component is disabled." }, { "name": "infoTooltip", diff --git a/projects/composition/src/app/pages/switch-page/switch-page.component.html b/projects/composition/src/app/pages/switch-page/switch-page.component.html index ec27ca5d8..312d4c072 100644 --- a/projects/composition/src/app/pages/switch-page/switch-page.component.html +++ b/projects/composition/src/app/pages/switch-page/switch-page.component.html @@ -7,7 +7,7 @@ infoTooltip="Provide any information here"> - +