android13/external/chromium-trace/catapult/third_party/polymer/components/iron-a11y-announcer
liiir1985 7f62dcda9f initial 2024-06-22 20:45:49 +08:00
..
.github initial 2024-06-22 20:45:49 +08:00
demo initial 2024-06-22 20:45:49 +08:00
test initial 2024-06-22 20:45:49 +08:00
.bower.json initial 2024-06-22 20:45:49 +08:00
.travis.yml initial 2024-06-22 20:45:49 +08:00
CONTRIBUTING.md initial 2024-06-22 20:45:49 +08:00
README.md initial 2024-06-22 20:45:49 +08:00
bower.json initial 2024-06-22 20:45:49 +08:00
index.html initial 2024-06-22 20:45:49 +08:00
iron-a11y-announcer.html initial 2024-06-22 20:45:49 +08:00

README.md

Build status

Demo and API docs

##<iron-a11y-announcer>

iron-a11y-announcer is a singleton element that is intended to add a11y to features that require on-demand announcement from screen readers. In order to make use of the announcer, it is best to request its availability in the announcing element.

Example:

Polymer({

  is: 'x-chatty',

  attached: function() {
    // This will create the singleton element if it has not
    // been created yet:
    Polymer.IronA11yAnnouncer.requestAvailability();
  }
});

After the iron-a11y-announcer has been made available, elements can make announces by firing bubbling iron-announce events.

Example:

this.fire('iron-announce', {
  text: 'This is an announcement!'
}, { bubbles: true });

Note: announcements are only audible if you have a screen reader enabled.