您好,我遇到以下问题:
“定义 CSS 颜色时需要 at-rule 或选择器。”
我正在使用 VS 代码,并且我已在 https://jigsaw.w3.org/css-validator/validator#css 检查了 CSS
我不知道问题出在哪里!
/* Color Variables */
$red: red;
$green: green;
$orange: orange;
$blue: blue;
$purple: purple;
$white: white;
$black: black;
$bg: /* #eff3f6 */ #e3e5e6;
$darkgray-blue: #354052;
$lightgray-blue: #7f8fa4;
/* Styles */
body {
background: $bg;
font-family: 'Roboto', sans-serif;
letter-spacing: 1px;
}
.text-red {color: $red !important;}
.text-green {color: $green !important;}
.text-orange {color: $orange !important;}
.text-blue {color: $blue !important;}
/* buttons */
.btn-red {
background: $red;
color: $white;
font-size: xx-small;
&:hover, &:focus {
background: darken($red, 8%);
color: white;
} Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号