Skip to content

Commit

Permalink
Accessible Name for URL Input (#527)
Browse files Browse the repository at this point in the history
Adds an aria-label attribute to the to link dialog's form input
  • Loading branch information
dctalbot authored and javan committed Aug 15, 2018
1 parent 41eefb2 commit 1f9b090
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/trix/config/lang.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Trix.config.lang =
strike: "Strikethrough"
undo: "Undo"
unlink: "Unlink"
url: "URL"
urlPlaceholder: "Enter a URL…"
GB: "GB"
KB: "KB"
Expand Down
2 changes: 1 addition & 1 deletion src/trix/config/toolbar.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Trix.config.toolbar =
<div class="trix-dialogs" data-trix-dialogs>
<div class="trix-dialog trix-dialog--link" data-trix-dialog="href" data-trix-dialog-attribute="href">
<div class="trix-dialog__link-fields">
<input type="url" name="href" class="trix-input trix-input--dialog" placeholder="#{lang.urlPlaceholder}" required data-trix-input>
<input type="url" name="href" class="trix-input trix-input--dialog" placeholder="#{lang.urlPlaceholder}" aria-label="#{lang.url}" required data-trix-input>
<div class="trix-button-group">
<input type="button" class="trix-button trix-button--dialog" value="#{lang.link}" data-trix-method="setAttribute">
<input type="button" class="trix-button trix-button--dialog" value="#{lang.unlink}" data-trix-method="removeAttribute">
Expand Down

0 comments on commit 1f9b090

Please sign in to comment.