css-declaration-sorter
Advanced tools
Comparing version
[ | ||
"--*", | ||
"all", | ||
"revert", | ||
"display-outside", | ||
"box-suppress", | ||
"display", | ||
"display-inside", | ||
"position", | ||
@@ -15,2 +16,20 @@ "top", | ||
"offset-block-end", | ||
"grid", | ||
"grid-area", | ||
"grid-auto-columns", | ||
"grid-auto-flow", | ||
"grid-auto-rows", | ||
"grid-column", | ||
"grid-column-end", | ||
"grid-column-gap", | ||
"grid-column-start", | ||
"grid-gap", | ||
"grid-row", | ||
"grid-row-end", | ||
"grid-row-gap", | ||
"grid-row-start", | ||
"grid-template", | ||
"grid-template-areas", | ||
"grid-template-columns", | ||
"grid-template-rows", | ||
"flex", | ||
@@ -23,6 +42,3 @@ "flex-basis", | ||
"flex-wrap", | ||
"box-align", | ||
"box-decoration-break", | ||
"box-direction", | ||
"box-orient", | ||
"align-content", | ||
@@ -38,3 +54,2 @@ "align-items", | ||
"shape-outside", | ||
"shape-box", | ||
"shape-image-threshold", | ||
@@ -60,7 +75,4 @@ "orphans", | ||
"transform-box", | ||
"transform-function", | ||
"transform-origin", | ||
"transform-style", | ||
"ruby-align", | ||
"ruby-position", | ||
@@ -72,3 +84,2 @@ "perspective", | ||
"z-index", | ||
"blend-mode", | ||
"mix-blend-mode", | ||
@@ -79,3 +90,2 @@ "backface-visibility", | ||
"clip-path", | ||
"marks", | ||
"mask", | ||
@@ -190,3 +200,2 @@ "mask-type", | ||
"image-rendering", | ||
"mq-boolean", | ||
@@ -210,3 +219,2 @@ "width", | ||
"overflow-clip-box", | ||
"overflow-wrap", | ||
"overflow-x", | ||
@@ -223,4 +231,2 @@ "overflow-y", | ||
"scroll-snap-type", | ||
"scroll-snap-type-x", | ||
"scroll-snap-type-y", | ||
"touch-action", | ||
@@ -255,2 +261,3 @@ "pointer-events", | ||
"line-height", | ||
"display-list", | ||
"list-style", | ||
@@ -263,3 +270,2 @@ "list-style-image", | ||
"unicode-bidi", | ||
"unicode-range", | ||
"text-combine-upright", | ||
@@ -287,5 +293,3 @@ "text-align", | ||
"content", | ||
"widows", | ||
"url", | ||
"custom-ident" | ||
"widows" | ||
] |
[ | ||
"box-sizing", | ||
"display", | ||
"display-outside", | ||
"box-suppress", | ||
"display-inside", | ||
"position", | ||
@@ -13,2 +16,20 @@ "top", | ||
"offset-block-end", | ||
"grid", | ||
"grid-area", | ||
"grid-auto-columns", | ||
"grid-auto-flow", | ||
"grid-auto-rows", | ||
"grid-column", | ||
"grid-column-end", | ||
"grid-column-gap", | ||
"grid-column-start", | ||
"grid-gap", | ||
"grid-row", | ||
"grid-row-end", | ||
"grid-row-gap", | ||
"grid-row-start", | ||
"grid-template", | ||
"grid-template-areas", | ||
"grid-template-columns", | ||
"grid-template-rows", | ||
"flex", | ||
@@ -21,6 +42,3 @@ "flex-basis", | ||
"flex-wrap", | ||
"box-align", | ||
"box-decoration-break", | ||
"box-direction", | ||
"box-orient", | ||
"align-content", | ||
@@ -65,3 +83,2 @@ "align-items", | ||
"overflow-clip-box", | ||
"overflow-wrap", | ||
"overflow-x", | ||
@@ -84,3 +101,2 @@ "overflow-y", | ||
"transform-box", | ||
"transform-function", | ||
"transform-origin", | ||
@@ -183,2 +199,3 @@ "transform-style", | ||
"line-height", | ||
"display-list", | ||
"list-style", | ||
@@ -208,4 +225,2 @@ "list-style-image", | ||
"--*", | ||
"revert", | ||
"all", | ||
@@ -221,3 +236,2 @@ "animation", | ||
"animation-direction", | ||
"blend-mode", | ||
"mix-blend-mode", | ||
@@ -237,3 +251,2 @@ "break-before", | ||
"counter-reset", | ||
"custom-ident", | ||
"cursor", | ||
@@ -245,6 +258,4 @@ "empty-cells", | ||
"ime-mode", | ||
"marks", | ||
"mask", | ||
"mask-type", | ||
"mq-boolean", | ||
"opacity", | ||
@@ -256,4 +267,2 @@ "perspective", | ||
"resize", | ||
"ruby-align", | ||
"ruby-position", | ||
"scroll-behavior", | ||
@@ -265,7 +274,4 @@ "scroll-snap-coordinate", | ||
"scroll-snap-type", | ||
"scroll-snap-type-x", | ||
"scroll-snap-type-y", | ||
"shape-image-threshold", | ||
"shape-margin", | ||
"shape-box", | ||
"shape-outside", | ||
@@ -283,4 +289,2 @@ "tab-size", | ||
"unicode-bidi", | ||
"unicode-range", | ||
"url", | ||
"vertical-align", | ||
@@ -287,0 +291,0 @@ "visibility", |
[ | ||
"--*", | ||
"align-content", | ||
@@ -28,3 +27,2 @@ "align-items", | ||
"background-size", | ||
"blend-mode", | ||
"block-size", | ||
@@ -81,8 +79,6 @@ "border", | ||
"bottom", | ||
"box-align", | ||
"box-decoration-break", | ||
"box-direction", | ||
"box-orient", | ||
"box-shadow", | ||
"box-sizing", | ||
"box-suppress", | ||
"break-after", | ||
@@ -110,5 +106,7 @@ "break-before", | ||
"cursor", | ||
"custom-ident", | ||
"direction", | ||
"display", | ||
"display-inside", | ||
"display-list", | ||
"display-outside", | ||
"empty-cells", | ||
@@ -142,2 +140,20 @@ "filter", | ||
"font-weight", | ||
"grid", | ||
"grid-area", | ||
"grid-auto-columns", | ||
"grid-auto-flow", | ||
"grid-auto-rows", | ||
"grid-column", | ||
"grid-column-end", | ||
"grid-column-gap", | ||
"grid-column-start", | ||
"grid-gap", | ||
"grid-row", | ||
"grid-row-end", | ||
"grid-row-gap", | ||
"grid-row-start", | ||
"grid-template", | ||
"grid-template-areas", | ||
"grid-template-columns", | ||
"grid-template-rows", | ||
"height", | ||
@@ -170,3 +186,2 @@ "hyphens", | ||
"margin-top", | ||
"marks", | ||
"mask", | ||
@@ -183,3 +198,2 @@ "mask-type", | ||
"mix-blend-mode", | ||
"mq-boolean", | ||
"object-fit", | ||
@@ -201,3 +215,2 @@ "object-position", | ||
"overflow-clip-box", | ||
"overflow-wrap", | ||
"overflow-x", | ||
@@ -223,6 +236,3 @@ "overflow-y", | ||
"resize", | ||
"revert", | ||
"right", | ||
"ruby-align", | ||
"ruby-position", | ||
"scroll-behavior", | ||
@@ -234,5 +244,2 @@ "scroll-snap-coordinate", | ||
"scroll-snap-type", | ||
"scroll-snap-type-x", | ||
"scroll-snap-type-y", | ||
"shape-box", | ||
"shape-image-threshold", | ||
@@ -262,3 +269,2 @@ "shape-margin", | ||
"transform-box", | ||
"transform-function", | ||
"transform-origin", | ||
@@ -272,4 +278,2 @@ "transform-style", | ||
"unicode-bidi", | ||
"unicode-range", | ||
"url", | ||
"vertical-align", | ||
@@ -276,0 +280,0 @@ "visibility", |
{ | ||
"name": "css-declaration-sorter", | ||
"version": "1.1.0", | ||
"version": "1.2.0", | ||
"description": "Sorts CSS declarations fast and automatically in a certain order.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -32,3 +32,3 @@ <img alt='CSS declaration sorter logo' src='https://cdn.rawgit.com/Siilwyn/css-declaration-sorter/master/logo.svg' height='260' align='right'> | ||
## Capabilities | ||
- Up-to-date CSS properties from [MDN](https://developer.mozilla.org/), scraped from [DevDocs](https://devdocs.io/). | ||
- Up-to-date CSS properties from the [MDN Web Platform](https://developer.mozilla.org/). | ||
- Sort using your own defined order. | ||
@@ -35,0 +35,0 @@ - Sass support when combined with [postcss-scss](https://github.com/postcss/postcss-scss/). |
@@ -6,14 +6,10 @@ 'use strict'; | ||
var isProperty = function (element) { | ||
return element.type === 'Properties'; | ||
var includes = function (element, searchValue) { | ||
return Boolean(~element.indexOf(searchValue)); | ||
}; | ||
var getName = function (element) { | ||
return element.name; | ||
}; | ||
var options = { | ||
hostname: 'docs.devdocs.io', | ||
hostname: 'developer.mozilla.org', | ||
port: 443, | ||
path: '/css/index.json' | ||
path: '/en-US/docs/Web/CSS$children?expand' | ||
}; | ||
@@ -33,8 +29,13 @@ | ||
result.on('end', function () { | ||
data = JSON.parse(data) | ||
.entries.filter(isProperty) | ||
.map(getName); | ||
data = JSON.parse(data); | ||
cssProperties = JSON.stringify(data, null, 2); | ||
data.subpages.forEach(function (element) { | ||
// Add element if tagged as CSS property and not tagged as Non-standard | ||
if (includes(element.tags, 'CSS Property') && !includes(element.tags, 'Non-standard')) { | ||
cssProperties.push(element.title); | ||
} | ||
}); | ||
cssProperties = JSON.stringify(cssProperties, null, 2); | ||
fs.writeFile('orders/source.json', cssProperties, function (error) { | ||
@@ -41,0 +42,0 @@ if (error) throw error; |
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
28566
2.02%989
1.33%