diff --git a/projects/demo/src/app/components/custom-menu/custom-menu.component.html b/projects/demo/src/app/components/custom-menu/custom-menu.component.html index ba49ac3a..e40333b4 100644 --- a/projects/demo/src/app/components/custom-menu/custom-menu.component.html +++ b/projects/demo/src/app/components/custom-menu/custom-menu.component.html @@ -1,5 +1,7 @@
+ [ariaLabel]="title | async" +>
diff --git a/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.html b/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.html index 1e8cd2c3..cd3aab30 100644 --- a/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.html +++ b/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.html @@ -1,14 +1,19 @@ -
{{ getName(activeItem || group) | async }} -
+ -
-
+
+
diff --git a/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.ts b/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.ts index e427cc93..acd7eac0 100644 --- a/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.ts +++ b/projects/ngx-editor/src/lib/modules/menu/dropdown/dropdown.component.ts @@ -51,6 +51,10 @@ export class DropdownComponent implements OnInit, OnDestroy { return this.ngxeService.locals.get(key); } + getIsDropdownActive(item:string): boolean { + return this.activeItem === item; + } + toggleDropdown(e: MouseEvent): void { e.preventDefault(); this.isDropdownOpen = !this.isDropdownOpen; diff --git a/projects/ngx-editor/src/lib/modules/menu/image/image.component.html b/projects/ngx-editor/src/lib/modules/menu/image/image.component.html index 72e0ba48..03a61da7 100644 --- a/projects/ngx-editor/src/lib/modules/menu/image/image.component.html +++ b/projects/ngx-editor/src/lib/modules/menu/image/image.component.html @@ -1,10 +1,14 @@ -
+ [ariaLabel]="getLabel('insertImage') | async" + aria-haspopup="dialog" + [ariaExpanded]="showPopup" +>
diff --git a/projects/ngx-editor/src/lib/modules/menu/insert-command/insert-command.component.html b/projects/ngx-editor/src/lib/modules/menu/insert-command/insert-command.component.html index 68884640..f9128bd9 100644 --- a/projects/ngx-editor/src/lib/modules/menu/insert-command/insert-command.component.html +++ b/projects/ngx-editor/src/lib/modules/menu/insert-command/insert-command.component.html @@ -1,7 +1,8 @@ -
+ [ariaLabel]="getTitle(name) | async" +> diff --git a/projects/ngx-editor/src/lib/modules/menu/link/link.component.html b/projects/ngx-editor/src/lib/modules/menu/link/link.component.html index d667baaa..39765b66 100644 --- a/projects/ngx-editor/src/lib/modules/menu/link/link.component.html +++ b/projects/ngx-editor/src/lib/modules/menu/link/link.component.html @@ -1,11 +1,15 @@ -
+ [ariaLabel]="title | async" + aria-haspopup="dialog" + [ariaExpanded]="showPopup" +>
diff --git a/projects/ngx-editor/src/lib/modules/menu/toggle-command/toggle-command.component.html b/projects/ngx-editor/src/lib/modules/menu/toggle-command/toggle-command.component.html index b80b5f83..53fed76b 100644 --- a/projects/ngx-editor/src/lib/modules/menu/toggle-command/toggle-command.component.html +++ b/projects/ngx-editor/src/lib/modules/menu/toggle-command/toggle-command.component.html @@ -1,8 +1,10 @@ -
+ [ariaLabel]="getTitle(name) | async" +>