首页 前端知识 vue element项目中报错Blocked aria-hidden on an element because its descendant retained focus. The focus m

vue element项目中报错Blocked aria-hidden on an element because its descendant retained focus. The focus m

2025-03-27 13:03:56 前端知识 前端哥 333 875 我要收藏

问题描述

在vue+element项目开发过程中 有一个页面使用了el-radio组件  但是在切换时会报错Blocked aria-hidden on an element because its descendant retained focus. The focus must not be hidden from assistive technology users. Avoid using aria-hidden on a focused element or its ancestor. Consider using the inert attribute instead, which will also prevent focus. For more details, see the aria-hidden section of the WAI-ARIA specification

解决方式

浏览器检测策略导致

//lang="scss"
/deep/ .el-radio__original {
display: none !important;
}
/deep/.el-radio:focus:not(.is-focus):not(:active):not(.is-disabled) .el-radio__inner {
box-shadow: none !important;
}
复制

添加后完美解决

转载请注明出处或者链接地址:https://www.qianduange.cn//article/24377.html
标签
评论
还可以输入200
共0条数据,当前/页
发布的文章

【Linux笔记】基础IO(上)

2025-03-27 13:03:40

大家推荐的文章
会员中心 联系我 留言建议 回顶部
娴忚鍣ㄥ崌绾ф彁绀猴細鎮ㄧ殑娴忚鍣ㄧ増鏈緝浣庯紝寤鸿鎮ㄧ珛鍗冲崌绾т负鐭ヤ簡鏋侀€熸祻瑙堝櫒锛屾瀬閫熴€佸畨鍏ㄣ€佺畝绾︼紝涓婄綉閫熷害鏇村揩锛�绔嬪嵆涓嬭浇
复制成功!