gpt4 book ai didi

javascript - JQuery: $(this).text ('some_text' );导致我的链接有边框

转载 作者:行者123 更新时间:2023-11-28 02:55:49 25 4
gpt4 key购买 nike

我有以下代码:

$('a.btn-slide').toggle(function() {
$("#SliderDIV").slideDown("fast");
$(this).text('Hide/Show');
});

仅在 Firefox 中,当我单击 a href 链接来隐藏/显示 DIV 时,Firefox 会在 href 链接周围显示虚线边框(我不明白为什么,也不应该如此)。

但是,在 IE 和 Chrome 中,当我切换链接时 - 它不会在链接周围创建这种奇怪的边框。

最佳答案

因此,您想要摆脱 dotted outline

就这么做

a {
outline: none;
}

但这会影响使用键盘导航的用户。他们将无法再确定他们现在点击了哪个链接。

关于javascript - JQuery: $(this).text ('some_text' );导致我的链接有边框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2701004/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com