From 4d1cdc067674157eedbde6b9611449c6898d179e Mon Sep 17 00:00:00 2001 From: jeddy3 Date: Sat, 8 Feb 2020 15:45:41 -0500 Subject: [PATCH 1/2] Add value-keyword-case --- index.js | 85 ++++++++++++++++++++++++++++---------------------------- 1 file changed, 43 insertions(+), 42 deletions(-) diff --git a/index.js b/index.js index 902218e..1b973e7 100644 --- a/index.js +++ b/index.js @@ -1,15 +1,15 @@ -"use strict" +"use strict"; module.exports = { - "extends": "stylelint-config-recommended", - "rules": { - "at-rule-empty-line-before": [ "always", { - except: [ - "blockless-after-same-name-blockless", - "first-nested", - ], - ignore: ["after-comment"], - } ], + extends: "stylelint-config-recommended", + rules: { + "at-rule-empty-line-before": [ + "always", + { + except: ["blockless-after-same-name-blockless", "first-nested"], + ignore: ["after-comment"] + } + ], "at-rule-name-case": "lower", "at-rule-name-space-after": "always-single-line", "at-rule-semicolon-newline-after": "always", @@ -22,21 +22,21 @@ module.exports = { "block-opening-brace-space-before": "always", "color-hex-case": "lower", "color-hex-length": "short", - "comment-empty-line-before": [ "always", { - except: ["first-nested"], - ignore: ["stylelint-commands"], - } ], + "comment-empty-line-before": [ + "always", + { + except: ["first-nested"], + ignore: ["stylelint-commands"] + } + ], "comment-whitespace-inside": "always", - "custom-property-empty-line-before": [ "always", { - except: [ - "after-custom-property", - "first-nested", - ], - ignore: [ - "after-comment", - "inside-single-line-block", - ], - } ], + "custom-property-empty-line-before": [ + "always", + { + except: ["after-custom-property", "first-nested"], + ignore: ["after-comment", "inside-single-line-block"] + } + ], "declaration-bang-space-after": "never", "declaration-bang-space-before": "always", "declaration-block-semicolon-newline-after": "always-multi-line", @@ -47,16 +47,13 @@ module.exports = { "declaration-colon-newline-after": "always-multi-line", "declaration-colon-space-after": "always-single-line", "declaration-colon-space-before": "never", - "declaration-empty-line-before": [ "always", { - except: [ - "after-declaration", - "first-nested", - ], - ignore: [ - "after-comment", - "inside-single-line-block", - ], - } ], + "declaration-empty-line-before": [ + "always", + { + except: ["after-declaration", "first-nested"], + ignore: ["after-comment", "inside-single-line-block"] + } + ], "function-comma-newline-after": "always-multi-line", "function-comma-space-after": "always-single-line", "function-comma-space-before": "never", @@ -65,7 +62,7 @@ module.exports = { "function-parentheses-newline-inside": "always-multi-line", "function-parentheses-space-inside": "never-single-line", "function-whitespace-after": "always", - "indentation": 2, + indentation: 2, "length-zero-no-unit": true, "max-empty-lines": 1, "media-feature-colon-space-after": "always", @@ -82,10 +79,13 @@ module.exports = { "number-leading-zero": "always", "number-no-trailing-zeros": true, "property-case": "lower", - "rule-empty-line-before": [ "always-multi-line", { - except: ["first-nested"], - ignore: ["after-comment"], - } ], + "rule-empty-line-before": [ + "always-multi-line", + { + except: ["first-nested"], + ignore: ["after-comment"] + } + ], "selector-attribute-brackets-space-inside": "never", "selector-attribute-operator-space-after": "never", "selector-attribute-operator-space-before": "never", @@ -101,9 +101,10 @@ module.exports = { "selector-pseudo-element-colon-notation": "double", "selector-type-case": "lower", "unit-case": "lower", + "value-keyword-case": "lower", "value-list-comma-newline-after": "always-multi-line", "value-list-comma-space-after": "always-single-line", "value-list-comma-space-before": "never", - "value-list-max-empty-lines": 0, - }, -} + "value-list-max-empty-lines": 0 + } +}; From d16bfc7c3e567af8fc02d9fd4aed2fd7409b9252 Mon Sep 17 00:00:00 2001 From: jeddy3 Date: Sat, 8 Feb 2020 15:48:54 -0500 Subject: [PATCH 2/2] Fix formatting --- index.js | 84 ++++++++++++++++++++++++++++---------------------------- 1 file changed, 42 insertions(+), 42 deletions(-) diff --git a/index.js b/index.js index 1b973e7..12dcbfd 100644 --- a/index.js +++ b/index.js @@ -1,15 +1,15 @@ -"use strict"; +"use strict" module.exports = { - extends: "stylelint-config-recommended", - rules: { - "at-rule-empty-line-before": [ - "always", - { - except: ["blockless-after-same-name-blockless", "first-nested"], - ignore: ["after-comment"] - } - ], + "extends": "stylelint-config-recommended", + "rules": { + "at-rule-empty-line-before": [ "always", { + except: [ + "blockless-after-same-name-blockless", + "first-nested", + ], + ignore: ["after-comment"], + } ], "at-rule-name-case": "lower", "at-rule-name-space-after": "always-single-line", "at-rule-semicolon-newline-after": "always", @@ -22,21 +22,21 @@ module.exports = { "block-opening-brace-space-before": "always", "color-hex-case": "lower", "color-hex-length": "short", - "comment-empty-line-before": [ - "always", - { - except: ["first-nested"], - ignore: ["stylelint-commands"] - } - ], + "comment-empty-line-before": [ "always", { + except: ["first-nested"], + ignore: ["stylelint-commands"], + } ], "comment-whitespace-inside": "always", - "custom-property-empty-line-before": [ - "always", - { - except: ["after-custom-property", "first-nested"], - ignore: ["after-comment", "inside-single-line-block"] - } - ], + "custom-property-empty-line-before": [ "always", { + except: [ + "after-custom-property", + "first-nested", + ], + ignore: [ + "after-comment", + "inside-single-line-block", + ], + } ], "declaration-bang-space-after": "never", "declaration-bang-space-before": "always", "declaration-block-semicolon-newline-after": "always-multi-line", @@ -47,13 +47,16 @@ module.exports = { "declaration-colon-newline-after": "always-multi-line", "declaration-colon-space-after": "always-single-line", "declaration-colon-space-before": "never", - "declaration-empty-line-before": [ - "always", - { - except: ["after-declaration", "first-nested"], - ignore: ["after-comment", "inside-single-line-block"] - } - ], + "declaration-empty-line-before": [ "always", { + except: [ + "after-declaration", + "first-nested", + ], + ignore: [ + "after-comment", + "inside-single-line-block", + ], + } ], "function-comma-newline-after": "always-multi-line", "function-comma-space-after": "always-single-line", "function-comma-space-before": "never", @@ -62,7 +65,7 @@ module.exports = { "function-parentheses-newline-inside": "always-multi-line", "function-parentheses-space-inside": "never-single-line", "function-whitespace-after": "always", - indentation: 2, + "indentation": 2, "length-zero-no-unit": true, "max-empty-lines": 1, "media-feature-colon-space-after": "always", @@ -79,13 +82,10 @@ module.exports = { "number-leading-zero": "always", "number-no-trailing-zeros": true, "property-case": "lower", - "rule-empty-line-before": [ - "always-multi-line", - { - except: ["first-nested"], - ignore: ["after-comment"] - } - ], + "rule-empty-line-before": [ "always-multi-line", { + except: ["first-nested"], + ignore: ["after-comment"], + } ], "selector-attribute-brackets-space-inside": "never", "selector-attribute-operator-space-after": "never", "selector-attribute-operator-space-before": "never", @@ -105,6 +105,6 @@ module.exports = { "value-list-comma-newline-after": "always-multi-line", "value-list-comma-space-after": "always-single-line", "value-list-comma-space-before": "never", - "value-list-max-empty-lines": 0 - } -}; + "value-list-max-empty-lines": 0, + }, +}