我正在运行以下命令:
ng build --prod --aot --base-href ./
并收到以下提示:
ERROR in Module build failed (from ./node_modules/sass-loader/lib/loader.js):
$clr-popover-box-shadow-color: rgba(clr-getColor(dark), 0.25);
^
Argument `$color` of `rgba($color, $alpha)` must be a color
in /Users/allan/git/dcfrontend/node_modules/@clr/ui/src/utils/_variables.global.scss (line 84, column 32)
我正在使用 Angular 7 和 Clarity 1.04。
以下是我从 angular.json
中提取出来的内容:
"styles": [
"node_modules/@clr/icons/clr-icons.min.css",
"node_modules/@clr/ui/clr-ui.min.css",
"node_modules/prismjs/themes/prism-solarizedlight.css",
"src/styles.css",
"node_modules/lato-font/css/lato-font.min.css"
],
"scripts": [
"node_modules/core-js/client/shim.min.js",
"node_modules/mutationobserver-shim/dist/mutationobserver.min.js",
"node_modules/@webcomponents/custom-elements/custom-elements.min.js",
"node_modules/web-animations-js/web-animations.min.js",
"node_modules/prismjs/prism.js",
"node_modules/prismjs/components/prism-typescript.min.js",
"node_modules/@clr/icons/clr-icons.min.js"
]
_variables.global.scss
文件,谢谢。 - Atomzwiebackclr-getColor(dark)
返回什么?它不能是有效的颜色,否则您不会得到这些错误,可能是格式错误? - Atomzwieback