CSS
CSS
ウィンドウサイズ
code: (css)
@media (max-width: 750px){
/* mobile */
}
@media (min-width: 750px){
/* desktop */
}
:not
code: (css)
.fancy {
text-shadow: 2px 2px 3px gold;
}
/* '.fancy' クラスの中にない <p> 要素 */
p:not(.fancy) {
color: green;
}
/* <p> 要素ではない要素 */
body :not(p) {
text-decoration: underline;
}
/* <div> または <span> 要素ではない要素 */
body :not(div):not(span) {
font-weight: bold;
}
/* '.crazy' または '.fancy' ではない要素 */
/* なお、この文法は十分に対応されていません。 */
body :not(.crazy, .fancy) {
font-family: sans-serif;
}
Sass