不知道這是否與:visited
鏈接或帶有陰影的常規樣式相關,但我無法讓它覆蓋。無法刪除已訪問鏈接上的盒子陰影 - 應用兩次
https://jsfiddle.net/pt39v1yy/1/
我最初試圖改變箱陰影的顏色,但後來意識到它沒有重寫的事情,所以我試圖刪除以及,仍然一無所獲。我嘗試添加!important,unset,initial等,但檢查總是顯示原始的box-shadow沒有被刪除,就像它不能被覆蓋。
a:not(.btn) {
text-decoration: none;
border-bottom: 3px solid #b4e7f8;
box-shadow: inset 0 -4px 0 #b4e7f8;
-webkit-transition: background .35s cubic-bezier(.33,.66,.66,1);
transition: background .35s cubic-bezier(.33,.66,.66,1);
color: inherit;
}
a:not(.btn):hover{
background: #b4e7f8;
text-decoration: none;
}
a:not(.btn):visited {
border-bottom: 3px solid #beb4f8;
background: #beb4f8;
-webkit-box-shadow: none;
-moz-box-shadow: none;
box-shadow: none;
color: inherit;
}