Commit Graph

329 Commits

Author SHA1 Message Date
Natalie Weizenbaum
3392db0074
Don't compile .css files in directories to themselves (#862)
This also adds support for compiling .css files in directories *at
all*, which had previously only worked in --watch mode.

Closes #853
2019-10-29 23:48:21 +00:00
Natalie Weizenbaum
1b17ab76cf
Reset the forwarded config to empty for @use and meta.load-module() (#855)
In #827 I made configuration never be null, but this turns out to be
overkill: we still need a way for _loadModule() and _execute() to
distinguish between "use the existing configuration" (for @forward)
and "use no configuration" (for an unconfigured @use or
meta.load-module()). We now use null as a sentinel value there, while
still ensuring that _configuration is non-nullable.

Closes #854
2019-10-22 01:35:11 +01:00
Natalie Weizenbaum
73de08b817
Only generate and update selectors, not rules, in Extender (#856)
We switched to *updating* selectors a while ago so that cloned rules
would continue to see updates in their selectors, but we were still
generating and tracking rules in the Extender. This caused skew
between what rules the extender knew about and what rules actually
existed in situations where rules were copied (such as when resolving
nested media queries).

There's no principled reason the extender needs to know about style
rules at all, so now it just tracks modifiable wrappers of selectors.
These are re-used even when style rules are cloned, so they're safe
from the skew problem.

Closes #843
2019-10-21 21:07:51 +01:00
Natalie Weizenbaum
6b8c168779
Improve error messages for color functions that aren't in sass:color (#844) 2019-10-14 17:56:13 -07:00
Natalie Weizenbaum
e68592f8f3
Allow saturate() in plain CSS files (#845)
Closes #840
2019-10-14 11:47:16 -07:00
Jennifer Thakar
664260159e Update changelog and bump pubspec version 2019-10-10 15:42:39 -07:00
Natalie Weizenbaum
87c9223b66
Fix broken CHANGELOG links (#836) 2019-10-02 11:19:51 -07:00
Natalie Weizenbaum
5052350150 Bump the pubspec and add a changelog entry for @use 2019-10-01 14:54:54 -07:00
Natalie Weizenbaum
d901bcb00c
Properly handle some CSS identifier edge cases (#816)
See sass/sass#2738
Closes #815
2019-09-06 16:54:54 -07:00
Natalie Weizenbaum
aea990d4fc
Properly watch .css files for changes (#814)
Closes #806
2019-09-03 16:42:21 -07:00
Natalie Weizenbaum
4ccddf8b13
Dash-normalize user-defined functions (#813)
Closes #811
2019-09-03 16:00:07 -07:00
Natalie Weizenbaum
35880d171f
Check fs.existsSync() before running fs.statSync() (#812)
This produces non-negligible speed improvements for Node users with
lots of imports.
2019-09-03 13:26:57 -07:00
Natalie Weizenbaum
a89c67b563
Fix unquoted plain-CSS imports (#800)
Closes #799
2019-08-28 14:09:35 -07:00
Natalie Weizenbaum
fc8c987fc1
Fix a few @extend edge cases (#797) 2019-08-16 14:00:14 -07:00
Natalie Weizenbaum
0e5ed4a37d
Fix dash-insensitivity in get-function() (#795)
Closes #792
2019-08-14 12:20:47 -07:00
Natalie Weizenbaum
c8ac543d1e
Re-add support for Node Carbon (#785)
Apparently npm and Yarn won't avoid installing a package version that
declares incompatibility with them, so dropping compatibility for an
old version is actually a breaking change 😭.
2019-07-29 22:32:53 +01:00
Natalie Weizenbaum
d840b84b59 Clarify the error for the wrong number of positional arguments
Closes #776
2019-07-25 08:37:01 +01:00
Natalie Weizenbaum
382af499e0 Avoid double "Error:" headers when reporting selector parse errors
Closes #774
2019-07-25 08:37:01 +01:00
Natalie Weizenbaum
44b542fcef Include argument names when reporting selector parse errors 2019-07-25 08:37:01 +01:00
Natalie Weizenbaum
8d5e3d9a67 Include argument names when reporting range errors
Closes #771
2019-07-25 08:37:00 +01:00
Natalie Weizenbaum
d0f471ca9d Drop support for Node 8.x
url.pathToFileURL, which wasn't supported until Node 10.x, is now used
in node_preamble.
2019-07-22 16:51:15 -07:00
Natalie Weizenbaum
b1707f61cd Release 1.22.8
This doesn't contain any code changes relative to 1.22.7, but the JS
release will pick up mbullington/node_preamble.dart#16.
2019-07-22 14:47:38 -07:00
Natalie Weizenbaum
ea4436b87d
Limit the Dart SDK constraint to ^2.4.0 (#769)
2.3.2 and earlier releases suffered from dart-lang/sdk#37027, which
causes them to fail to parse Dart Sass.

Closes #768
2019-07-18 21:49:36 +01:00
Natalie Weizenbaum
c794abd858 Eagerly dash-normalize Sass identifiers
This avoids using maps and sets with custom equality, which are
moderately inefficient relative to built-in maps and sets on both Node
and the Dart VM. In order to make error messages continue to use the
original identifiers where possible, this updates some of them to rely
more heavily on their associated source spans for context.
2019-07-16 19:42:38 -07:00
Natalie Weizenbaum
535030bb0f Release 1.22.5 2019-07-15 21:59:54 +01:00
Natalie Weizenbaum
0e47e03305
Fix at-rules in nested imports (#758)
Closes #755
2019-07-12 01:55:30 +01:00
Natalie Weizenbaum
d3e288ccf2 Support map-remove() with a named $key argument
Closes #742
2019-07-03 15:31:56 -07:00
Natalie Weizenbaum
eff8c37457 Fix a deadlock in zip()
Closes #739
2019-07-03 15:31:56 -07:00
Natalie Weizenbaum
5ff434da6a Fix join() and append() $separator error messages
Closes #738
2019-07-03 15:31:56 -07:00
Natalie Weizenbaum
47e0cfc8c8 Empty maps have undecided separators
Closes #737
2019-07-03 15:31:56 -07:00
Natalie Weizenbaum
821b5e2521 Fix str-insert() with $index: -1
Closes #733
2019-07-02 17:25:46 -07:00
Natalie Weizenbaum
40df8e3bc1 Fix str-slice() with astral plane characters
Closes #732
2019-07-02 17:25:46 -07:00
Natalie Weizenbaum
2105a138c0 Clamp $alpha in adjust-color() with HSL args
Closes #708
2019-07-02 17:25:45 -07:00
Natalie Weizenbaum
7bfba04b79 Throw an error for plain-CSS invert() with $weight
Closes #705
2019-07-02 17:25:36 -07:00
Natalie Weizenbaum
d5adb4621e Fix invert() with $weight: 50%
Closes #704
2019-07-02 17:25:25 -07:00
Natalie Weizenbaum
9838caff6f Improve errors for alpha() with the wrong number of arguments
Closes #700
2019-07-02 17:25:14 -07:00
Natalie Weizenbaum
ed06a41afc Fix the argument name for a single-argument saturate() function
Closes #699
2019-07-02 16:10:28 -07:00
Natalie Weizenbaum
60af5f6c25
Release 1.22.2 (#745)
The CHANGELOG entry from #727 got misplaced; that code hasn't been
released yet.
2019-07-01 13:31:13 -07:00
Natalie Weizenbaum
532358d7fa
Merge pull request #727 from sass/static-require
Require dependencies in the preamble rather than through JS-interop
2019-06-28 14:32:18 -07:00
Natalie Weizenbaum
2cdbbebcaf
Declare support for Chokidar 3.0.0 (#731)
Closes #730
2019-06-26 16:06:22 -07:00
Natalie Weizenbaum
174ef128a2 Merge remote-tracking branch 'origin/feature.use' into merge-use 2019-06-24 14:12:05 -07:00
Natalie Weizenbaum
494e208067 Require dependencies in the preamble rather than through JS-interop
Closes #726
2019-06-19 19:41:16 +01:00
Natalie Weizenbaum
a46e779675 Clarify !global deprecation warnings
Closes #723
2019-06-18 17:39:29 -07:00
Natalie Weizenbaum
e4b18b5231
Produce better stack traces for syntax errors loaded via import/use (#722)
We now wrap _withStackFrame() around wider sections of code, including
_loadStylesheet() which handles parse errors, so that the @use/@import
stack frames are available.
2019-06-18 17:26:46 -07:00
Natalie Weizenbaum
4716349a0e
Add new module-system features for existing functions (#720) 2019-06-18 12:03:12 -07:00
Natalie Weizenbaum
a87631777b
Declare a "sass" executable in the pubspec (#712) 2019-06-06 21:19:09 +01:00
Natalie Weizenbaum
bea609d74b
Add a top-level warn() function for functions and importers (#711)
In addition to being useful for users of Sass, this will make it
possible for core Sass functions to produce warnings without needing
an explicit reference to the evaluator.
2019-06-06 19:42:44 +01:00
Natalie Weizenbaum
48c284b4ef
Properly mark secure variables so they're decrypted by Travis (#697) 2019-05-31 17:01:33 +01:00
Natalie Weizenbaum
2836780339
Merge pull request #689 from sass/exponent
Fix some number serialization bugs
2019-05-24 15:09:37 -07:00
Natalie Weizenbaum
0fe0208f6e Remove exponent notation for integers on Node.js
Closes #688
2019-05-21 13:36:36 -07:00