在 Firefox 下,无法为 SVG 中的 <a> link 元素获取键盘焦点
Cannot get keyboard focused for <a> link elements in SVG under Firefox
我想通过键盘的 TAB 键通过添加 <a>
link 围绕一些其他标签(如 <path>
等)来聚焦对象。这里是一个参考 link: SVG focusable attribute is not working
使用上面link中的方法,我可以在Chrome下成功聚焦我想要的对象,但它在Firefox下不起作用,谁能告诉为什么Firefox不支持这个?谢谢
Tabindex 和 focus/blur 对 SVG 的支持刚刚在 Firefox 和 will appear in version 51 中实现。
如果需要,您现在可以在 Nightly 中看到它。
我想通过键盘的 TAB 键通过添加 <a>
link 围绕一些其他标签(如 <path>
等)来聚焦对象。这里是一个参考 link: SVG focusable attribute is not working
使用上面link中的方法,我可以在Chrome下成功聚焦我想要的对象,但它在Firefox下不起作用,谁能告诉为什么Firefox不支持这个?谢谢
Tabindex 和 focus/blur 对 SVG 的支持刚刚在 Firefox 和 will appear in version 51 中实现。
如果需要,您现在可以在 Nightly 中看到它。