I have the following polymer element, that inherits the "paper-behaviors/paper-button-behavior" but doesn´t provide any kind of auditive feedback when the user clicks the button. it just reads the text of the button, but no information about if it is or not pressed. I've tested it Talkback for Android and Narrator for Windows. I cant change the HTML , I need to make it work in a direct and easy way, I´m pretty new with polymer 2 and this is driving me to a sad place. any hint on how to make this button accessible and ay11 compliant?
I have tried replacing the button for a checkbox, and that does work well, but is not approved by the company due to backwards compatibility risks.
<option-button class="optionsButton" role="button" aria-labelledby="button-0" tabindex="0" selected="" aria-pressed="true">
<div class="amount">Button text</div>
</option-button>
<script>
class option-button extends Polymer.mixinBehaviors([Polymer.PaperButtonBehavior], Polymer.Element) {
static get is() { return 'option-button; }
static get properties() {
return {
message : {
type: String,
notify: true
}
}
}
}
customElements.define(option-button.is, option-button);
</script>