Skip to content

Commit

Permalink
Readd comment on accessibility
Browse files Browse the repository at this point in the history
  • Loading branch information
loic-sharma committed Jul 16, 2021
1 parent f60deb8 commit fbe830c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/NuGetGallery/Views/Packages/DisplayPackageV2.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -467,13 +467,19 @@
<option value="@packageManager.Id">@packageManager.Name</option>
}
</select>

<!--In order to statisfy the requirement to announce button status both on NVDA/Narrator, other screen reader like NVDA will
announce the data-content "Copied" everytime when we press button, however, it won't work with Narrator when we use bootstrap popover
because of known issue (https://github.com/twbs/bootstrap/issues/18618).
We add aria-pressed to indicate the whether button is pressed or not, which is workaround only for Narrator announce the status change of button
-->
<button class="btn btn-blue" type="button"
data-toggle="popover" data-placement="bottom" data-content="Copied."
aria-label="CopyLabel" aria-pressed="false" aria-live="polite" role="button">
<span class="ms-Icon ms-Icon--Copy" aria-hidden="true"></span>
</button>
</div>

@{ var firstPackageManager = true; }
@foreach (var packageManager in packageManagers)
{
Expand Down

0 comments on commit fbe830c

Please sign in to comment.