* @param {import("../../ace-internal").Ace.TextInputAriaOptions} options
(options)
| 756 | * @param {import("../../ace-internal").Ace.TextInputAriaOptions} options |
| 757 | */ |
| 758 | setAriaOptions(options) { |
| 759 | if (options.activeDescendant) { |
| 760 | this.text.setAttribute("aria-haspopup", "true"); |
| 761 | this.text.setAttribute("aria-autocomplete", options.inline ? "both" : "list"); |
| 762 | this.text.setAttribute("aria-activedescendant", options.activeDescendant); |
| 763 | } |
| 764 | else { |
| 765 | this.text.setAttribute("aria-haspopup", "false"); |
| 766 | this.text.setAttribute("aria-autocomplete", "both"); |
| 767 | this.text.removeAttribute("aria-activedescendant"); |
| 768 | } |
| 769 | if (options.role) { |
| 770 | this.text.setAttribute("role", options.role); |
| 771 | } |
| 772 | if (options.setLabel) { |
| 773 | this.text.setAttribute("aria-roledescription", nls("text-input.aria-roledescription", "editor")); |
| 774 | this.setAriaLabel(); |
| 775 | } |
| 776 | } |
| 777 | |
| 778 | focus() { |
| 779 | // On focusing on the textarea, read active row number to assistive tech. |
no test coverage detected