我正在嘗試更改 WooCommerce 結帳頁面的“選擇選項”文本樣式,使其更粗,因為它已褪色,并且在使用 WAVE 掃描時出現可訪問性錯誤。
我已經嘗試過這個 CSS,但沒有任何變化,你能指出我錯在哪里嗎?
Select a category {
color: #cccccc
}
span.select2-selection.select2-selection--single {
color: #000000;
}
span.select2-selection__placeholder {
font-family: Roboto;
font-size: 16px;
line-height: 18px;
font-weight: 400;
font-style: normal;
color: #cccccc;
background-color: #ffffff;
}
或者是否有其他 CSS 可以做到這一點?
該網站是www.defkalionsa.gr
uj5u.com熱心網友回復:
你可以試試下面的css:
.select2-selection__placeholder {
font-weight:bold; /* for your "bolder" request" */
color:black; /* better than gray for accessibility */
}
如果這不起作用,您應該清除瀏覽器快取,并檢查其他樣式宣告是否優先。您可以臨時添加“!important”來覆寫其他宣告。
.select2-selection__placeholder {
font-weight:bold!important;
color:black!important;
}
轉載請註明出處,本文鏈接:https://www.uj5u.com/ruanti/402835.html
標籤:
