node-sass
Advanced tools
Comparing version 3.13.0 to 3.14.0-0
{ | ||
"name": "node-sass", | ||
"version": "3.13.0", | ||
"version": "3.14.0-0", | ||
"libsass": "3.3.6", | ||
@@ -65,2 +65,4 @@ "description": "Wrapper around libsass", | ||
"lodash.clonedeep": "^4.3.2", | ||
"lodash.isarray": "^4.0.0", | ||
"lodash.mergewith": "^4.6.0", | ||
"meow": "^3.7.0", | ||
@@ -83,4 +85,4 @@ "mkdirp": "^0.5.1", | ||
"rimraf": "^2.5.2", | ||
"sass-spec": "^3.3.6-3" | ||
"sass-spec": "^3.4.0-0" | ||
} | ||
} |
@@ -36,2 +36,5 @@ ```C | ||
// create file urls for sources | ||
bool source_map_file_urls; | ||
// Disable sourceMappingUrl in css output | ||
@@ -38,0 +41,0 @@ bool omit_source_map_url; |
@@ -37,2 +37,6 @@ Sass Contexts come in two flavors: | ||
```C | ||
// create file urls for sources | ||
bool source_map_file_urls; | ||
``` | ||
```C | ||
// Disable sourceMappingUrl in css output | ||
@@ -178,2 +182,3 @@ bool omit_source_map_url; | ||
void sass_delete_compiler (struct Sass_Compiler* compiler); | ||
void sass_delete_options(struct Sass_Options* options); | ||
@@ -229,2 +234,3 @@ // Release all memory allocated and also ourself | ||
bool sass_option_get_source_map_contents (struct Sass_Options* options); | ||
bool sass_option_get_source_map_file_urls (struct Sass_Options* options); | ||
bool sass_option_get_omit_source_map_url (struct Sass_Options* options); | ||
@@ -249,2 +255,3 @@ bool sass_option_get_is_indented_syntax_src (struct Sass_Options* options); | ||
void sass_option_set_source_map_contents (struct Sass_Options* options, bool source_map_contents); | ||
void sass_option_set_source_map_file_urls (struct Sass_Options* options, bool source_map_file_urls); | ||
void sass_option_set_omit_source_map_url (struct Sass_Options* options, bool omit_source_map_url); | ||
@@ -251,0 +258,0 @@ void sass_option_set_is_indented_syntax_src (struct Sass_Options* options, bool is_indented_syntax_src); |
@@ -133,2 +133,6 @@ ## Introduction | ||
const char* libsass_version(void); | ||
// Implemented sass language version | ||
// Hardcoded version 3.4 for time being | ||
const char* libsass_language_version(void); | ||
``` | ||
@@ -135,0 +139,0 @@ |
@@ -14,2 +14,4 @@ By using custom importers, Sass stylesheets can be implemented in any possible way, such as by being loaded via a remote server. Please note: this feature is experimental and is implemented differently than importers in Ruby Sass. Imports must be relative to the parent import context and therefore we need to pass this information to the importer callback. This is currently done by passing the complete import string/path of the previous import context. | ||
Please note that LibSass doesn't use the srcmap parameter yet. It has been added to not deprecate the C-API once support has been implemented. It will be used to re-map the actual sourcemap with the provided ones. | ||
### Basic Usage | ||
@@ -16,0 +18,0 @@ |
@@ -1,3 +0,10 @@ | ||
`Sass_Values` are used to pass values and their types between the implementer and LibSass. Sass knows various different value types (including nested arrays and hash-maps). If you implement a binding to another programming language, you have to find a way to convert `Sass_Values` between the targeted language and C. `Sass_Values` are currently only used by custom functions. | ||
`Sass_Values` are used to pass values and their types between the implementer | ||
and LibSass. Sass knows various different value types (including nested arrays | ||
and hash-maps). If you implement a binding to another programming language, you | ||
have to find a way to [marshal] [1] (convert) `Sass_Values` between the target | ||
language and C. `Sass_Values` are currently only used by custom functions, but | ||
it should also be possible to use them without a compiler context. | ||
[1]: https://en.wikipedia.org/wiki/Marshalling_%28computer_science%29 | ||
### Basic Usage | ||
@@ -26,4 +33,15 @@ | ||
SASS_COMMA, | ||
SASS_SPACE | ||
SASS_SPACE, | ||
// only used internally to represent a hash map before evaluation | ||
// otherwise we would be too early to check for duplicate keys | ||
SASS_HASH | ||
}; | ||
// Value Operators | ||
enum Sass_OP { | ||
AND, OR, // logical connectives | ||
EQ, NEQ, GT, GTE, LT, LTE, // arithmetic relations | ||
ADD, SUB, MUL, DIV, MOD, // arithmetic functions | ||
NUM_OPS // so we know how big to make the op table | ||
}; | ||
``` | ||
@@ -37,2 +55,28 @@ | ||
// Creator functions for all value types | ||
union Sass_Value* sass_make_null (void); | ||
union Sass_Value* sass_make_boolean (bool val); | ||
union Sass_Value* sass_make_string (const char* val); | ||
union Sass_Value* sass_make_qstring (const char* val); | ||
union Sass_Value* sass_make_number (double val, const char* unit); | ||
union Sass_Value* sass_make_color (double r, double g, double b, double a); | ||
union Sass_Value* sass_make_list (size_t len, enum Sass_Separator sep); | ||
union Sass_Value* sass_make_map (size_t len); | ||
union Sass_Value* sass_make_error (const char* msg); | ||
union Sass_Value* sass_make_warning (const char* msg); | ||
// Generic destructor function for all types | ||
// Will release memory of all associated Sass_Values | ||
// Means we will delete recursively for lists and maps | ||
void sass_delete_value (union Sass_Value* val); | ||
// Make a deep cloned copy of the given sass value | ||
union Sass_Value* sass_clone_value (const union Sass_Value* val); | ||
// Stringify a Sass_Values and also return the result as a Sass_Value (of type STRING) | ||
union Sass_Value* sass_value_stringify (const union Sass_Value* a, bool compressed, int precision); | ||
// Execute an operation for two Sass_Values and return the result as a Sass_Value too | ||
union Sass_Value* sass_value_op (enum Sass_OP op, const union Sass_Value* a, const union Sass_Value* b); | ||
// Return the sass tag for a generic sass value | ||
@@ -63,2 +107,4 @@ // Check is needed before accessing specific values! | ||
void sass_string_set_value (union Sass_Value* v, char* value); | ||
bool sass_string_is_quoted(const union Sass_Value* v); | ||
void sass_string_set_quoted(union Sass_Value* v, bool quoted); | ||
@@ -90,3 +136,3 @@ // Getters and setters for Sass_Boolean | ||
size_t sass_map_get_length (const union Sass_Value* v); | ||
// Getters and setters for Sass_List keys and values | ||
// Getters and setters for Sass_Map keys and values | ||
union Sass_Value* sass_map_get_key (const union Sass_Value* v, size_t i); | ||
@@ -104,21 +150,2 @@ void sass_map_set_key (union Sass_Value* v, size_t i, union Sass_Value*); | ||
void sass_warning_set_message (union Sass_Value* v, char* msg); | ||
// Creator functions for all value types | ||
union Sass_Value* sass_make_null (void); | ||
union Sass_Value* sass_make_boolean (bool val); | ||
union Sass_Value* sass_make_string (const char* val); | ||
union Sass_Value* sass_make_number (double val, const char* unit); | ||
union Sass_Value* sass_make_color (double r, double g, double b, double a); | ||
union Sass_Value* sass_make_list (size_t len, enum Sass_Separator sep); | ||
union Sass_Value* sass_make_map (size_t len); | ||
union Sass_Value* sass_make_error (const char* msg); | ||
union Sass_Value* sass_make_warning (const char* msg); | ||
// Generic destructor function for all types | ||
// Will release memory of all associated Sass_Values | ||
// Means we will delete recursively for lists and maps | ||
void sass_delete_value (union Sass_Value* val); | ||
// Make a deep cloned copy of the given sass value | ||
union Sass_Value* sass_clone_value (const union Sass_Value* val); | ||
``` | ||
@@ -125,0 +152,0 @@ |
@@ -6,2 +6,5 @@ There are several implementations of `libsass` for a variety of languages. Here are just a few of them. Note, some implementations may or may not be up to date. We have not verified whether they work. | ||
### Elixir | ||
* [sass.ex](https://github.com/scottdavis/sass.ex) | ||
### Go | ||
@@ -36,2 +39,3 @@ * [go-libsass](https://github.com/wellington/go-libsass) | ||
* [sassphp](https://github.com/sensational/sassphp) | ||
* [php-sass](https://github.com/lesstif/php-sass) | ||
@@ -38,0 +42,0 @@ ### Python |
@@ -6,3 +6,3 @@ LibSass | ||
[![Linux CI](https://travis-ci.org/sass/libsass.svg?branch=master)](https://travis-ci.org/sass/libsass) | ||
[![Unix CI](https://travis-ci.org/sass/libsass.svg?branch=master)](https://travis-ci.org/sass/libsass) | ||
[![Windows CI](https://ci.appveyor.com/api/projects/status/github/sass/libsass?svg=true)](https://ci.appveyor.com/project/sass/libsass/branch/master) | ||
@@ -38,5 +38,5 @@ [![Bountysource](https://www.bountysource.com/badge/tracker?tracker_id=283068)](https://www.bountysource.com/trackers/283068-libsass?utm_source=283068&utm_medium=shield&utm_campaign=TRACKER_BADGE) | ||
Well, luckily, [SassC](http://github.com/sass/sassc) is the official binary wrapper for | ||
LibSass and is *always* kept in sync. SassC uses a git submodule | ||
to include LibSass. When developing LibSass, its best to actually | ||
check out SassC and develop in that directory with the SassC spec | ||
LibSass and is *always* kept in sync. SassC is used by continous integration systems in | ||
LibSass repository. When developing LibSass, it is best to actually | ||
checkout SassC and develop in that directory with the SassC spec | ||
and tests there. | ||
@@ -53,2 +53,8 @@ | ||
### DEBUG builds | ||
Set the environment variable `DEBUG` to `1` to enable debug builds that can be debugged | ||
with `gdb`, `lldb` and others. E.g.: use `$ DEBUG=1 ./script/spec` to run the tests with | ||
a debug build. | ||
Library Usage | ||
@@ -87,2 +93,6 @@ ------------- | ||
sass2scss was originally written by [Marcel Greter][@mgreter] | ||
and he happily agreed to have it merged into the project. | ||
[@hcatlin]: https://github.com/hcatlin | ||
@@ -94,4 +104,1 @@ [@akhleung]: https://github.com/akhleung | ||
[@xzyfer]: https://github.com/xzyfer | ||
sass2scss was originally written by [Marcel Greter](@mgreter) | ||
and he happily agreed to have it merged into the project. |
@@ -10,3 +10,5 @@ var assert = require('assert'), | ||
readYaml = require('read-yaml'), | ||
objectMerge = require('object-merge'), | ||
mergeWith = require('lodash.mergewith'), | ||
assign = require('lodash.assign'), | ||
isArray = require('lodash.isarray'), | ||
glob = require('glob'), | ||
@@ -36,3 +38,3 @@ specPath = require('sass-spec').dirname.replace(/\\/g, '/'), | ||
if (exists(testCase.optionsPath)) { | ||
options = objectMerge(options, readYaml.sync(testCase.optionsPath)); | ||
options = mergeWith(assign({}, options), readYaml.sync(testCase.optionsPath), customizer); | ||
} | ||
@@ -46,2 +48,3 @@ testCase.includePaths = [ | ||
testCase.todo = options[':todo'] !== undefined && options[':todo'] !== null && options[':todo'].indexOf(impl) !== -1; | ||
testCase.only = options[':only_on'] !== undefined && options[':only_on'] !== null && options[':only_on']; | ||
testCase.warningTodo = options[':warning_todo'] !== undefined && options[':warning_todo'] !== null && options[':warning_todo'].indexOf(impl) !== -1; | ||
@@ -65,2 +68,4 @@ testCase.startVersion = parseFloat(options[':start_version']) || 0; | ||
this.skip('Test marked with TODO'); | ||
} else if (test.only && test.only.indexOf(impl) === -1) { | ||
this.skip('Tests marked for only: ' + test.only.join(', ')); | ||
} else if (version < test.startVersion) { | ||
@@ -116,2 +121,9 @@ this.skip('Tests marked for newer Sass versions only'); | ||
}; | ||
function customizer(objValue, srcValue) { | ||
if (isArray(objValue)) { | ||
return objValue.concat(srcValue); | ||
} | ||
} | ||
var executeSuite = function(suite, tests) { | ||
@@ -121,3 +133,3 @@ var suiteFolderLength = suite.folder.split('/').length; | ||
if (exists(optionsFile)) { | ||
suite.options = objectMerge(suite.options, readYaml.sync(optionsFile)); | ||
suite.options = mergeWith(assign({}, suite.options), readYaml.sync(optionsFile), customizer); | ||
} | ||
@@ -152,3 +164,3 @@ | ||
suites: [], | ||
options: suite.options | ||
options: assign({}, suite.options), | ||
}, | ||
@@ -169,3 +181,3 @@ tests.slice(prevSuiteStart, i) | ||
suites: [], | ||
options: suite.options | ||
options: assign({}, suite.options), | ||
}, | ||
@@ -172,0 +184,0 @@ tests.slice(prevSuiteStart, tests.length) |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1676799
314
4613
18
1
+ Addedlodash.isarray@^4.0.0
+ Addedlodash.mergewith@^4.6.0
+ Addedlodash.isarray@4.0.0(transitive)
+ Addedlodash.mergewith@4.6.2(transitive)