The download address of the accessibility tools I use: Information Accessibility Toolbar: Website Information Accessibility Transformation Consulting, Accessibility Assistive Tools, Accessibility Tools, Assistive Browsing Tools, Accessibility Toolbars, Aging, Elderly Mode, Voice Services for the Blind, Barrier-free reading, cross cursor, plain text, barrier-free plug-in source code, barrier-free consulting transformation, text-to-speech tts, wcag2.0 https://gitee.com/tywAmblyopia/ToolsUI After downloading, put the canyou folder in the root Directory (same level as the written html page)
Then add a click event to the barrier-free button you prepared in the project's head.html (encapsulated head)
<a href="javascript:" onclick="showBarrierFree()" accesskey="g" target="_self">无障碍浏览</a>
function ShowDetail() {
// 已经点击无障碍后不再第二次弹出无障碍工具条
if (window.top.document.getElementById("rrbay_wzatool")) {
return false;
}
// 跳转
var url = "?url=" + document.location.href;
location_href('/项目文件夹/canyou/default.html' + url);
}
function location_href(url) { location.href = url }
Note that you must use this kind of jump. If you jump directly, you will jump to 404 first, and it will be easy to use after refreshing.
Reference: The use of barrier-free bars in vue_vue barrier-free reading_One tear blog-CSDN blog