我想用不同颜色的活动标签链接颜色,我该如何使用CSS修复它。
每个标签的静态ID为:
我试过这段代码:
/* Color Tabs */
/* -- Focus ----------------------------------*/
#SR_tabInfosGen_tab .t-Tabs-link:focus {
font-weight:bold;
box-shadow :0 2px 0 #336193 inset !important;
}
#SR_tabDec_tab .t-Tabs-link:focus {
font-weight:bold;
box-shadow :0 2px 0 #1E8449 inset !important;
}
#SR_tabPiecesJoi_tab .t-Tabs-link:focus {
font-weight:bold;
box-shadow :0 2px 0 #c03a2b inset !important;
}
*/ -- Hover ----------------------------------*/
#SR_tabInfosGen_tab .t-Tabs-link:hover {
font-weight:bold;
box-shadow :0 2px 0 #336193 inset !important;
}
#SR_tabDec_tab .t-Tabs-link:hover {
font-weight:bold;
box-shadow :0 2px 0 #1E8449 inset !important;
}
#SR_tabPiecesJoi_tab .t-Tabs-link:hover {
font-weight:bold;
box-shadow :0 2px 0 #c03a2b inset !important;
}
/* -- First Active ----------------------------------*/
.is-active > .t-Tabs-link {
font-weight:bold;
box-shadow :0 2px 0 #336193 inset !important;
}
/* END Color Tabs */

<ul class="t-Tabs t-Tabs--pill a-Tabs" role="tablist" style="white-space: nowrap; overflow-x: hidden;">
<li class="t-Tabs-item a-Tabs-selected is-active" aria-controls="SR_tabInfosGen" role="tab" id="SR_tabInfosGen_tab" aria-selected="true">
<a href="#SR_tabInfosGen" class="t-Tabs-link" role="presentation"><span>Informations Générales</span>
</a>
</li>
<li class="t-Tabs-item a-Tabs-after" aria-controls="SR_tabDec" role="tab" id="SR_tabDec_tab" aria-selected="false">
<a href="#SR_tabDec" class="t-Tabs-link" tabindex="-1" role="presentation"><span>Décisions</span>
</a>
</li>
<li class="t-Tabs-item a-Tabs-after" aria-controls="SR_tabPiecesJoi" role="tab" id="SR_tabPiecesJoi_tab" aria-selected="false">
<a href="#SR_tabPiecesJoi" class="t-Tabs-link" tabindex="-1" role="presentation"><span>Pièces Jointes</span>
</a>
</li>
</ul>
&#13;
但它的效果只有一半,因为当我失去焦点时,盒子阴影就不会出现了。