Improved accessibility (#118):

* adding role="button" or type="button" where missing.
This commit is contained in:
John Livingston
2024-08-20 15:30:45 +02:00
parent 9e252193d4
commit cee42b4bcc
11 changed files with 24 additions and 19 deletions

View File

@ -117,7 +117,7 @@ export const tplExternalLoginModal = (el, o) => {
<div class="livechat-external-login-modal-external-auth-oidc-block">
${
externalButtons.map(button => html`
<button
<button type="button"
class="btn btn-primary ${button.class}"
@click=${
(ev) => {
@ -187,7 +187,9 @@ export const tplExternalLoginModal = (el, o) => {
// eslint-disable-next-line no-undef
__(LOC_login_remote_peertube_video_not_found_try_anyway)
}
<button class="btn btn-primary" @click=${() => el.openUrlTargetTop(o.remote_peertube_try_anyway_url)}>${
<button type="button" class="btn btn-primary"
@click=${() => el.openUrlTargetTop(o.remote_peertube_try_anyway_url)}
>${
// eslint-disable-next-line no-undef
__(LOC_login_remote_peertube_video_not_found_try_anyway_button)
}</button>

View File

@ -117,7 +117,7 @@ const tplViewerMode = (o) => {
: html`
<hr>
<div class="livechat-viewer-mode-external-login">
<button class="btn btn-primary" @click=${ev => {
<button type="button" class="btn btn-primary" @click=${ev => {
ev.preventDefault()
api.modal.show('converse-livechat-external-login')
}}>${i18nExternalLogin}</button>