Announcer
The <velin-announcer> component exposes an ARIA live region for polite screen-reader updates after async actions. Added in 0.7.5.
Example
<velin-announcer></velin-announcer>
<script>
VelinAnnouncer.announceGlobal('Saved');
</script>
JavaScript API
| API | Description |
|---|---|
VelinAnnouncer.announceGlobal(message) | Announce via the first velin-announcer on the page |
element.announce(message) | Announce on a specific instance |
Import
Load the bundle once, then use the custom element in your markup:
<script type="module" src="../../dist/velinstyle-components.min.js"></script>
<velin-announcer>…</velin-announcer>