#12377 closed enhancement (fixed)
make set() automatically apply obvious DOMNode attributes, including aria attributes
Reported by: | bill | Owned by: | bill |
---|---|---|---|
Priority: | high | Milestone: | 1.7 |
Component: | Dijit | Version: | 1.6.0rc1 |
Keywords: | 1.7-mobile | Cc: | Douglas Hays, Becky Gibson |
Blocked By: | Blocking: |
Description
By default, make set() automatically copy attributes to the focusNode/domNode for DOMNode native attributes like "title" and "alt". A widget can override this behavior for a particular attribute by having a custom setter (ex: _setTitleAttr) or an entry for title in the deprecated attributeMap object.
This will avoid needing _setXXXAttr() or attributeMap entries for most of these common attribute names (24 currently in the code, with more needed for HTML5, including the aria attributes like aria-labelledby.
Change History (3)
comment:1 Changed 10 years ago by
Keywords: | 1.7-mobile added |
---|
comment:2 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note: See
TracTickets for help on using
tickets.
(In [23988]) Make set() and widget constructor (by default) copy specified attribute to this.focusNode (if defined) or this.domNode otherwise. Widgets can override this behavior with custom setters, including custom setters to do nothing (i.e.: _setFooAttr: null). Only copies attributes with corresponding DOMNode attributes (ex: title, alt, aria-labelledby), and not random attribute names (ex: duration).
Fixes #12377 !strict.