Lesscss>引导程序的darken()和lighten()无法编译 [英] Lesscss > bootstrap's darken() and lighten() don't compile

查看:341
本文介绍了Lesscss>引导程序的darken()和lighten()无法编译的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的Less文件未按应有的方式进行编译.我使用的是Bootstrap较少的文件,最近的文件.

My Less files aren't compiling as they should. I'm using the Bootstrap less files, most recent ones.

看起来好像更少的文件由于darken()和lighten()类而失败.

It looks like the less-files are failing because of the darken() and lighten() classes.

错误是:

lessc致命错误:预期的颜色值:在background-color: darken(@inputBackground, 1%);处失败 /Applications/MAMP/htdocs/foobar/application/less/forms.less上线 195

lessc fatal error: expected color value: failed at background-color: darken(@inputBackground, 1%); /Applications/MAMP/htdocs/foobar/application/less/forms.less on line 195

当我转到该行时,我找到lighten()的darken(),将其删除,错误消失了.但是出现一个新的错误,也就是lighten()类的darken()行.奇怪,对吧?有人知道有什么解决方法吗?因为我不想到处删除lighten()和darken(),所以它们是Bootstrap中最好的功能!

When I go to that line, I find the darken() of lighten(), remove that and the error is gone. But a new error appears, also a line with the darken() of lighten() class. Strange, right, or isn't it? Is there a fix someone knows about? Because I don't wanna remove the lighten() and darken() everywhere, they're the nicest functions in Bootstrap less!

在SublimeText2中没有BOM的情况下将文件保存到UTF8

Saved the files to UTF8 without BOM already in SublimeText2

奇怪,当它在我的NAS上时,它可以工作.在我的MacBook上不是本地的.这是OSX问题吗?

strange, it works when it's on my NAS. Not local on my MacBook.. Is it a OSX issue?

推荐答案

一旦我更改了较少文件@import规则的顺序,我的问题就解决了.颜色定义应在调用darken()之前进行解析.

My problems were solved once I changed the order of less file @import rules. The colour definition should be parsed before darken() is called.

这篇关于Lesscss>引导程序的darken()和lighten()无法编译的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆