🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Sign inDemoInstall
Socket

postcss-css-variables

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postcss-css-variables - npm Package Compare versions

Comparing version

to
0.7.0

6

CHANGELOG.md
# v0.7.0 - 2017-3-12
- Resolve `var` usage in fallbacks, [#37](https://github.com/MadLittleMods/postcss-css-variables/issues/37)
- Thank you to [@asvny](https://github.com/asvny) and [@marklu](https://github.com/marklu) for the contribution, [#39](https://github.com/MadLittleMods/postcss-css-variables/issues/39) -> [#49](https://github.com/MadLittleMods/postcss-css-variables/pull/49)
# v0.6.0 - 2016-9-23

@@ -3,0 +9,0 @@

0

index.js

@@ -0,0 +0,0 @@ // PostCSS CSS Variables (postcss-css-variables)

@@ -65,3 +65,12 @@ var generateScopeList = require('./generate-scope-list');

// Default to the calculatedInPlaceValue which might be a previous fallback, then try this declarations fallback
var replaceValue = (matchingVarDeclMapItem || {}).calculatedInPlaceValue || fallback;
var replaceValue = (matchingVarDeclMapItem || {}).calculatedInPlaceValue || (function() {
// Resolve `var` values in fallback
var fallbackValue = fallback;
if(fallback) {
var fallbackDecl = decl.clone({ parent: decl.parent, value: fallback });
fallbackValue = resolveValue(fallbackDecl, map, false, true).value;
}
return fallbackValue;
})();
// Otherwise if the dependency health is good(no circular or self references), dive deeper and resolve

@@ -68,0 +77,0 @@ if(matchingVarDeclMapItem !== undefined && !gatherVariableDependencies(variablesUsedInValue, map).hasCircularOrSelfReference) {

2

package.json
{
"name": "postcss-css-variables",
"version": "0.6.0",
"version": "0.7.0",
"description": "PostCSS plugin to transform CSS Custom Properties(CSS variables) syntax into a static representation",

@@ -5,0 +5,0 @@ "keywords": [

@@ -86,3 +86,3 @@ # PostCSS CSS Variables

```css
:root: {
:root {
--some-color: red;

@@ -89,0 +89,0 @@ }