【发布时间】:2020-08-05 13:11:59
【问题描述】:
如果我调用 SASS 命令如下所示:
call sass C:\Users\simon\source\repos\Pippo\ClickR\\Styles\main.scss C:\Users\simon\source\repos\Pippo\ClickR\\Styles\main.css
我收到以下错误:
Error: Invalid CSS after "": expected media query list, was ""only screen an..."
on line 348 of C:/Users/simon/source/repos/Pippo/ClickR/Styles/foundation/components/_top-bar.scss
from line 22 of C:/Users/simon/source/repos/Pippo/ClickR/Styles/_foundation.scss
from line 3 of C:\Users\simon\source\repos\Pippo\ClickR\\Styles\main.scss
Use --trace for backtrace.
这是产生错误的代码:
_top-bar.scss
....
$topbar-media-query: "only screen and (min-width:"#{$topbar-breakpoint}")" !default;
....
@media #{$topbar-media-query} {
.top-bar {
background: $topbar-bg;
@include clearfix;
overflow: visible;
.toggle-topbar { display: none; }
.title-area { float: $default-float; }
.name h1 a { width: auto; }
input,
.button {
line-height: 2em;
font-size: emCalc(14px);
height: 2em;
padding: 0 10px;
position: relative;
top: 8px;
}
&.expanded { background: $topbar-bg; }
}
....
我该如何解决? 谢谢, 西蒙娜
【问题讨论】:
-
您应该包含有问题的 SCSS 文件的内容。
标签: ruby sass stylesheet