Files
less.js/test/less/permissive-parse.less
Matthew Dean a75f7d9664 Fixes #3147 #2715 (#3213)
* Adds permissive parsing for at-rules and custom properties
* Added error tests for permissive parsing
* Change custom property value to quoted-like value
* Allow interpolation in unknown at-rules
* Allows variables to fallback to permissive parsing
* Allow escaping of blocks
2018-06-21 23:44:38 -07:00

51 lines
944 B
Plaintext

@function-name: regexp;
@d-value: 15;
@-moz-document @function-name("(\d{0,@{d-value}})") {
a {
color: red;
}
}
.custom-property {
--this: () => {
basically anything until final semi-colon;
even other stuff; // i\'m serious;
};
@this: () => {
basically anything until final semi-colon;
even other stuff; // i\'m serious;
};
--that: @this;
@red: lighten(red, 10%);
--custom-color: @red;
custom-color: $--custom-color;
}
@iostat: 1;
.var {
--fortran: read (*, *, iostat=@iostat) radius, height;
}
@boom-boom: bam;
@-moz-whatever (foo: "(" @boom-boom ")") {
bar: foo;
}
@selectorList: #selector, .bar, foo[attr="blah"];
@{selectorList} {
bar: value;
}
@size: 640px;
@tablet: (min-width: @size);
@media @tablet {
.holy-crap {
this: works;
}
}
// @todo - fix comment absorption after property
.test-comment {
--value: /* { ; } */;
--comment-within: ( /* okay?; comment; */ );
--empty: ;
}