简体   繁体   English

我所有使用 FontAwesome 的 HTML 标签似乎都添加了 aria-hidden="true" 。 这是怎么回事?

[英]All my HTML tags that use FontAwesome seem to some have aria-hidden="true" added to them. How is this happening?

I'm currently using Bootstrap 4 and FontAwesome on my website.我目前在我的网站上使用 Bootstrap 4 和 FontAwesome。 I'm working on ADA compliance now.我现在正在研究 ADA 合规性。

The crazy thing is that it seems that every HTML tag that uses FontAwesome somehow gets aria-hidden="true" added to it.疯狂的是,似乎每个使用 FontAwesome 的 HTML 标签都以某种方式添加了 aria-hidden="true" 。 Is this by default?这是默认的吗? How do I prevent this from occurring?我如何防止这种情况发生?

I've looked through to see if I can find that being added on any JavaScript files, but I'm not seeing anything.我已经查看了是否可以找到添加到任何 JavaScript 文件中的内容,但我什么也没看到。

It's fine that the tags get it, but not the anchor tags.标签得到它很好,但不是锚标签。

If you're using the CDN, it's possible that the auto-accessibility option is enabled, which is designed to automatically inject the aria-hidden tags for you.如果您使用的是 CDN,则可能启用了自动辅助功能选项,该选项旨在为您自动注入aria-hidden标签。

https://cdn.fontawesome.com/help#qa-autoa11y https://cdn.fontawesome.com/help#qa-autoa11y

If enabled as a feature in your embed code, Font Awesome CDN will try to identify [accessibility scenarios] in your UI as well as provide the modern and proper syntax assistive technologies recognize.如果在您的嵌入代码中作为一项功能启用,Font Awesome CDN 将尝试在您的 UI 中识别 [可访问性场景],并提供现代和正确的语法辅助技术识别。 For icons that have semantic or interactive meaning, this means you'll need to provide a proper text alternative to be used.对于具有语义或交互意义的图标,这意味着您需要提供一个合适的替代文本来使用。

Log into your Font Awesome kit, choose the Settings tab, and confirm that the checkbox for Auto-Accessibility is unchecked under the Features section.登录您的 Font Awesome 工具包,选择“设置”选项卡,并确认“功能”部分下的“自动辅助功能”复选框未选中。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用Selenium单击aria-hidden =“true”的元素 - How to click on an element with aria-hidden=“true” using Selenium 如何在 C# 中使用 Selenium 发送带有 aria-hidden="true" 的元素的键 - How to Sendkeys on an element with aria-hidden=“true” using Selenium in c# 在页面加载中隐藏了HTML表的所有TD和TR标签 - Have All TD and TR Tags of HTML Table Hidden on Page Load 我的可拖动弹出窗口还拖动了拥有它们的可视元素。 我怎样才能解决这个问题? - My drag-able popups also drag the visual element owning them. How can I fix this? 绑定即使在我使用完控件之后也将它们保留在内存中。 如何释放它们? - Binding keeps my controls in memory even after I'm done with them. How can I free them? 阅读所有电话联系人并进行更新。 Windows Phone 8 - Read all phone contacts and update them. windows phone 8 如果我有 XmlNodeList 并且我想从中创建两个 XmlNodeList,如何将 XmlNode 添加到 XmlNode 列表中。? - How can I add a XmlNode to XmlNode List , if I have XmlNodeList and I want to create two XmlNodeList out of them.? 通过xpath属性查找所有元素(aria-required = true)。//*[@ aria-required ='true'] - Find all elements by xpath attribute (aria-required = true) .//*[@aria-required='true'] 我正在使用 c# 使用 iText 7 将多​​个 PDF 合并到一个文件夹中。 在我合并它们之后,它们似乎都留在了记忆中。 我该如何清除它们? - I am merging multi PDFs in a folder using iText 7 using c#. After I have merged them , they all seem to stay in memory. How do I clear them out? 如果用户想在列表中输入多个学生姓名,我该如何重复该条件,以及如何列出所有学生姓名。 在我输入“N”之后 - How can i repeat the condition if the user wants to input many student name in the list and how can i list all of them. after i input "N"
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM