我想练习我的CSS(眨眼)干,我卡在如何解决这个问题。如何指定可以匹配给定选择器的多个类?
如何减少这样的:
table.shipmentItemList TD.title,
table.shipmentItemList TD.author,
table.shipmentItemList TD.options {
font-size: 1.0em;
font-weight: normal;
}
为了这样的事情:
table.shipmentItemList TD.title, TD.author, TD.options {
font-size: 1.0em;
font-weight: normal;
}
或者更好的是这样的:
table.shipmentItemList TD .title, .author, .options {
font-size: 1.0em;
font-weight: normal;
}
如果你希望做那种在CSS中的事情,你将不得不看看LESS或SASS。由于你的代码在标准的CSS中表现的非常好。 – Kyle 2012-08-15 12:57:57