mirror of
https://github.com/Jermolene/TiddlyWiki5.git
synced 2025-12-06 02:30:46 -08:00
Add Aria support to edittext widget
This commit is contained in:
parent
4c27c09b4d
commit
6a48032961
1 changed files with 9 additions and 0 deletions
|
|
@ -55,6 +55,15 @@ function SimpleEngine(options) {
|
|||
if(this.widget.isDisabled === "yes") {
|
||||
this.domNode.setAttribute("disabled",true);
|
||||
}
|
||||
if(this.widget.role) {
|
||||
this.domNode.setAttribute("role",this.widget.role);
|
||||
}
|
||||
if(this.widget["aria-autocomplete"]) {
|
||||
this.domNode.setAttribute("aria-autocomplete",this.widget["aria-autocomplete"]);
|
||||
}
|
||||
if(this.widget["aria-controls"]) {
|
||||
this.domNode.setAttribute("aria-autocomplete",this.widget["aria-controls"]);
|
||||
}
|
||||
// Add an input event handler
|
||||
$tw.utils.addEventListeners(this.domNode,[
|
||||
{name: "focus", handlerObject: this, handlerMethod: "handleFocusEvent"},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue