4

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

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

The error is:

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

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!

Saved the files to UTF8 without BOM already in SublimeText2

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

user1670816
  • 401
  • 2
  • 5
  • 17
  • Are you sure you are compiling and modifying the right files on your local ? And check the `@inputBackground` value, since the error tells us that it's not a color. (note: 1%, really?) – Sherbrow Mar 02 '13 at 14:46
  • Yes, I'm for sure. That are just Bootstrap standard values, don't know if I edited the 1% from 10% or not. – user1670816 Mar 02 '13 at 16:08
  • Actually, 1% is the default value, my bad. Can you try to compile a simple file with `.test { background-color: darken(#fff, 1%); }` ? – Sherbrow Mar 02 '13 at 22:09

1 Answers1

2

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