是否可以在jquery日历中更改周末日期的字体颜色?我尝试使用类ui-datepicker-week-end,但它只改变了Sun和Sat的字体颜色。我想要的是改变落在太阳和坐着的日子的颜色。
你的选择器需要更多的特异性,因为ui-datepicker-week-end
在<td>
上,但是里面有<a>
和ui-state-default
,如下所示:
.ui-datepicker-week-end, .ui-datepicker-week-end a.ui-state-default {color:red;}
You can test it here。如果你很好奇,日间单元格的标记是这样的:
<td class="ui-datepicker-week-end">
<a class="ui-state-default" href="#">DAY NUMBER</a>
</td>