diff --git a/.csslintrc b/.csslintrc deleted file mode 100644 index 177e4fc..0000000 --- a/.csslintrc +++ /dev/null @@ -1,40 +0,0 @@ ---errors=box-model, - display-property-grouping, - duplicate-background-images, - duplicate-properties, - empty-rules, - ids, - import, - important, - known-properties, - outline-none, - overqualified-elements, - qualified-headings, - shorthand, - star-property-hack, - text-indent, - underscore-property-hack, - unique-headings, - unqualified-attributes, - vendor-prefix, - zero-units ---ignore=adjoining-classes, - box-sizing, - bulletproof-font-face, - compatible-vendor-prefixes, - errors, - fallback-colors, - floats, - font-faces, - font-sizes, - gradients, - import-ie-limit, - order-alphabetical, - regex-selectors, - rules-count, - selector-max, - selector-max-approaching, - selector-newline, - universal-selector ---exclude-list=core/assets, - vendor diff --git a/.stylelintrc.json b/.stylelintrc.json new file mode 100644 index 0000000..f04c115 --- /dev/null +++ b/.stylelintrc.json @@ -0,0 +1,17 @@ +{ + "rules": { + "block-no-empty": null, + "block-opening-brace-newline-after": "always", + "block-closing-brace-newline-before": "always", + "color-no-invalid-hex": true, + "indentation": 2, + "max-empty-lines": 2, + "declaration-empty-line-before": "never", + "unit-whitelist": ["deg", "em", "ex", "ms", "rem", "%", "s", "px"] + }, + "ignoreFiles": [ + "core/assets/vendor/**/*.css", + "core/tests/Drupal/Tests/Core/Asset/css_test_files/**/*.css" + ] +} + diff --git a/core/misc/vertical-tabs.css b/core/misc/vertical-tabs.css index ec5d3c1..fc83da5 100644 --- a/core/misc/vertical-tabs.css +++ b/core/misc/vertical-tabs.css @@ -8,8 +8,8 @@ border: 1px solid #ccc; } [dir="rtl"] .vertical-tabs { - margin-left: 0; - margin-right: 15em; + margin-left: 0; + margin-right: 15em; } .vertical-tabs__menu { float: left; /* LTR */ diff --git a/core/modules/ckeditor/css/ckeditor.admin.css b/core/modules/ckeditor/css/ckeditor.admin.css index 8b771c7..82b6c53 100644 --- a/core/modules/ckeditor/css/ckeditor.admin.css +++ b/core/modules/ckeditor/css/ckeditor.admin.css @@ -6,8 +6,6 @@ * "moono". */ - - .ckeditor-toolbar { border: 1px solid #b6b6b6; padding: 0.1667em 0.1667em 0.08em; diff --git a/core/modules/image/css/editors/image.theme.css b/core/modules/image/css/editors/image.theme.css index cb0c7f9..5016365 100644 --- a/core/modules/image/css/editors/image.theme.css +++ b/core/modules/image/css/editors/image.theme.css @@ -50,11 +50,13 @@ border-color: white transparent transparent transparent; } +/* stylelint-disable block-closing-brace-newline-before, block-opening-brace-newline-after */ @keyframes quickedit-image-spin { 0% {transform: rotate(0deg);} 50% {transform: rotate(180deg);} 100% {transform: rotate(360deg);} } +/* stylelint-enable */ .quickedit-image-text { text-align: center; diff --git a/core/modules/outside_in/css/offcanvas.css b/core/modules/outside_in/css/offcanvas.css index fb671db..7e3b168 100644 --- a/core/modules/outside_in/css/offcanvas.css +++ b/core/modules/outside_in/css/offcanvas.css @@ -6,18 +6,18 @@ */ /* Position the dialog-offcanvas tray container outside the right of the viewport. */ .ui-dialog-offcanvas { - box-sizing: border-box; - height: 100%; - overflow: visible; + box-sizing: border-box; + height: 100%; + overflow: visible; } /* Wrap the form that's inside the dialog-offcanvas tray. */ .ui-dialog-offcanvas .ui-dialog-content { - padding: 0 20px; - /* Prevent horizontal scrollbar. */ - overflow-x: hidden; - overflow-y: auto; + padding: 0 20px; + /* Prevent horizontal scrollbar. */ + overflow-x: hidden; + overflow-y: auto; } [dir="rtl"] .ui-dialog-offcanvas .ui-dialog-content { - text-align: right; + text-align: right; } diff --git a/core/modules/outside_in/css/offcanvas.motion.css b/core/modules/outside_in/css/offcanvas.motion.css index 1c06994..5bec16b 100644 --- a/core/modules/outside_in/css/offcanvas.motion.css +++ b/core/modules/outside_in/css/offcanvas.motion.css @@ -12,17 +12,17 @@ /* Transition the dialog-offcanvas tray container, with 2s delay to match main canvas speed. */ .ui-dialog-offcanvas .ui-dialog-content { - -webkit-transition: all .7s ease 2s; - -moz-transition: all .7s ease 2s; - transition: all .7s ease 2s; + -webkit-transition: all .7s ease 2s; + -moz-transition: all .7s ease 2s; + transition: all .7s ease 2s; } @media (max-width: 700px) { - .ui-dialog-offcanvas .ui-dialog-content { - -webkit-transition: all .7s ease; - -moz-transition: all .7s ease; - transition: all .7s ease; - } + .ui-dialog-offcanvas .ui-dialog-content { + -webkit-transition: all .7s ease; + -moz-transition: all .7s ease; + transition: all .7s ease; + } } .dialog-offcanvas__main-canvas { diff --git a/core/modules/outside_in/css/outside_in.toolbar.css b/core/modules/outside_in/css/outside_in.toolbar.css index 3f7e044..a199841 100644 --- a/core/modules/outside_in/css/outside_in.toolbar.css +++ b/core/modules/outside_in/css/outside_in.toolbar.css @@ -62,9 +62,9 @@ button.toolbar-icon.toolbar-icon-edit.toolbar-item:before:focus { } #toolbar-bar.js-outside-in-edit-mode button.toolbar-icon.toolbar-icon-edit.toolbar-item.is-active { - background-image: none; - color: #fff; + background-image: none; + color: #fff; } #toolbar-bar.js-outside-in-edit-mode button.toolbar-icon.toolbar-icon-edit.toolbar-item.is-active:hover { - background-image: linear-gradient(to bottom, #0094f0, #0e69be); + background-image: linear-gradient(to bottom, #0094f0, #0e69be); } diff --git a/core/modules/quickedit/css/quickedit.theme.css b/core/modules/quickedit/css/quickedit.theme.css index 399db7a..db233c8 100644 --- a/core/modules/quickedit/css/quickedit.theme.css +++ b/core/modules/quickedit/css/quickedit.theme.css @@ -174,9 +174,9 @@ padding: 0.1667em 0.2em; } - /** - * Info toolgroup. - */ +/** + * Info toolgroup. + */ .quickedit-toolbar-fullwidth { width: 100%; } diff --git a/core/modules/system/css/system.admin.css b/core/modules/system/css/system.admin.css index 913ce57..8d276f8 100644 --- a/core/modules/system/css/system.admin.css +++ b/core/modules/system/css/system.admin.css @@ -211,7 +211,7 @@ small .admin-link:after { background-color: transparent; } [dir="rtl"] .system-status-report__status-title { - padding: 10px 40px 10px 6px; + padding: 10px 40px 10px 6px; } .system-status-report__status-icon:before { content: ""; diff --git a/core/modules/views_ui/css/views_ui.admin.theme.css b/core/modules/views_ui/css/views_ui.admin.theme.css index 460e75e..3aabe1f 100644 --- a/core/modules/views_ui/css/views_ui.admin.theme.css +++ b/core/modules/views_ui/css/views_ui.admin.theme.css @@ -158,7 +158,7 @@ details.box-padding { /* Hide 'remove' checkboxes. */ .views-remove-checkbox { - display: none; + display: none; } /* sizes the labels of checkboxes and radio button to the height of the text */ diff --git a/core/themes/bartik/color/preview.css b/core/themes/bartik/color/preview.css index ac561d3..48c124e 100644 --- a/core/themes/bartik/color/preview.css +++ b/core/themes/bartik/color/preview.css @@ -78,7 +78,7 @@ } [dir="rtl"] .color-preview-sidebar, [dir="rtl"] .color-preview-content { - float: right; + float: right; } .color-preview-sidebar { margin-left: 15px; /* LTR */ diff --git a/core/themes/bartik/css/components/header.css b/core/themes/bartik/css/components/header.css index 40ea0f0..7c7b8e5 100644 --- a/core/themes/bartik/css/components/header.css +++ b/core/themes/bartik/css/components/header.css @@ -21,7 +21,6 @@ } .region-header .site-branding { float: left; /* LTR */ - /* margin-bottom: 1.857em;*/ } [dir="rtl"] .region-header .site-branding { float: right; diff --git a/core/themes/classy/css/components/form.css b/core/themes/classy/css/components/form.css index 15b8ec2..a3fd9d6 100644 --- a/core/themes/classy/css/components/form.css +++ b/core/themes/classy/css/components/form.css @@ -64,8 +64,8 @@ label.option { } [dir="rtl"] .form-type-radio .description, [dir="rtl"] .form-type-checkbox .description { - margin-left: 0; - margin-right: 2.4em; + margin-left: 0; + margin-right: 2.4em; } .marker { color: #e00; diff --git a/core/themes/classy/css/components/progress.css b/core/themes/classy/css/components/progress.css index 1fb80a6..476e4fd 100644 --- a/core/themes/classy/css/components/progress.css +++ b/core/themes/classy/css/components/progress.css @@ -18,26 +18,12 @@ background: #057ec9; background-image: -webkit-linear-gradient( top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15) ), - -webkit-linear-gradient( left top, - #0094f0 0%, - #0094f0 25%, - #007ecc 25%, - #007ecc 50%, - #0094f0 50%, - #0094f0 75%, - #0094f0 100% ); + -webkit-linear-gradient( left top, #0094f0 0%, #0094f0 25%, #007ecc 25%, #007ecc 50%, #0094f0 50%, #0094f0 75%, #0094f0 100% ); background-image: -webkit-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15)), -webkit-linear-gradient(left top, #0094f0 0%, #0094f0 25%, #007ecc 25%, #007ecc 50%, #0094f0 50%, #0094f0 75%, #0094f0 100%); background-image: linear-gradient( to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15) ), - linear-gradient( to right bottom, - #0094f0 0%, - #0094f0 25%, - #007ecc 25%, - #007ecc 50%, - #0094f0 50%, - #0094f0 75%, - #0094f0 100% ); + linear-gradient( to right bottom, #0094f0 0%, #0094f0 25%, #007ecc 25%, #007ecc 50%, #0094f0 50%, #0094f0 75%, #0094f0 100% ); background-size: 40px 40px; margin-top: -1px; margin-left: -1px; /* LTR */ @@ -60,6 +46,7 @@ /** * Progress bar animations. */ +/* stylelint-disable block-closing-brace-newline-before, block-opening-brace-newline-after */ @-webkit-keyframes animate-stripes { 0% {background-position: 0 0, 0 0;} 100% {background-position: 0 0, -80px 0;} } @@ -69,3 +56,4 @@ @keyframes animate-stripes { 0% {background-position: 0 0, 0 0;} 100% {background-position: 0 0, -80px 0;} } +/* stylelint-enable */ diff --git a/core/themes/seven/css/components/entity-meta.css b/core/themes/seven/css/components/entity-meta.css index 9877ec3..701e8dc 100644 --- a/core/themes/seven/css/components/entity-meta.css +++ b/core/themes/seven/css/components/entity-meta.css @@ -55,5 +55,5 @@ text-shadow: 0 1px 0 white; } .entity-meta details .summary { - display: none; /* Hide JS summaries. @todo Rethink summaries. */ + display: none; /* Hide JS summaries. @todo Rethink summaries. */ } diff --git a/core/themes/seven/css/components/form.css b/core/themes/seven/css/components/form.css index f3acc2c..fa644c0 100644 --- a/core/themes/seven/css/components/form.css +++ b/core/themes/seven/css/components/form.css @@ -255,7 +255,7 @@ select { select:focus, select:hover { background-image: url(../../../../misc/icons/333333/caret-down.svg), - -webkit-linear-gradient(top, #fcfcfa, #e9e9dd); + -webkit-linear-gradient(top, #fcfcfa, #e9e9dd); color: #1a1a1a; } select:hover { diff --git a/core/themes/seven/css/components/jquery.ui/theme.css b/core/themes/seven/css/components/jquery.ui/theme.css index dd81ec2..9bf07a7 100644 --- a/core/themes/seven/css/components/jquery.ui/theme.css +++ b/core/themes/seven/css/components/jquery.ui/theme.css @@ -91,6 +91,7 @@ margin: 2px 0 0 3px; } /* positioning */ +/* stylelint-disable block-closing-brace-newline-before, block-opening-brace-newline-after */ .ui-icon-carat-1-ne { background-position: -16px 0; } .ui-icon-carat-1-e { background-position: -32px 0; } .ui-icon-carat-1-se { background-position: -48px 0; } @@ -264,7 +265,7 @@ .ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; } .ui-icon-grip-diagonal-se { background-position: -80px -224px; } .ui-icon-carat-1-n { background-position: 0 0; } - +/* stylelint-enable */ /** * Accordion */ diff --git a/core/themes/seven/css/components/system-status-report.css b/core/themes/seven/css/components/system-status-report.css index bfcd75c..7869fbd 100644 --- a/core/themes/seven/css/components/system-status-report.css +++ b/core/themes/seven/css/components/system-status-report.css @@ -22,7 +22,7 @@ .system-status-report__entry--warning { background-color: transparent; } - /* Account for native and poly-filled details element */ +/* Account for native and poly-filled details element */ .system-status-report__status-title { position: relative; padding: 1em 1em 1em 3em; /* LTR */ diff --git a/core/themes/seven/css/components/tabs.css b/core/themes/seven/css/components/tabs.css index 28401b4..eff2773 100644 --- a/core/themes/seven/css/components/tabs.css +++ b/core/themes/seven/css/components/tabs.css @@ -123,7 +123,7 @@ li.tabs__tab a { } /* JS dependent styling */ - .is-collapse-enabled .tabs__trigger { +.is-collapse-enabled .tabs__trigger { box-sizing: content-box; display: block; position: absolute; diff --git a/core/themes/seven/css/components/views-ui.css b/core/themes/seven/css/components/views-ui.css index 6849781..7278125 100644 --- a/core/themes/seven/css/components/views-ui.css +++ b/core/themes/seven/css/components/views-ui.css @@ -169,7 +169,7 @@ details.fieldset-no-legend { */ .views-displays .secondary { - text-align: left; /* LTR */ + text-align: left; /* LTR */ } [dir="rtl"] .views-displays .secondary { text-align: right; diff --git a/core/themes/stable/css/ckeditor/ckeditor.admin.css b/core/themes/stable/css/ckeditor/ckeditor.admin.css index 8b771c7..82b6c53 100644 --- a/core/themes/stable/css/ckeditor/ckeditor.admin.css +++ b/core/themes/stable/css/ckeditor/ckeditor.admin.css @@ -6,8 +6,6 @@ * "moono". */ - - .ckeditor-toolbar { border: 1px solid #b6b6b6; padding: 0.1667em 0.1667em 0.08em; diff --git a/core/themes/stable/css/core/vertical-tabs.css b/core/themes/stable/css/core/vertical-tabs.css index ec5d3c1..fc83da5 100644 --- a/core/themes/stable/css/core/vertical-tabs.css +++ b/core/themes/stable/css/core/vertical-tabs.css @@ -8,8 +8,8 @@ border: 1px solid #ccc; } [dir="rtl"] .vertical-tabs { - margin-left: 0; - margin-right: 15em; + margin-left: 0; + margin-right: 15em; } .vertical-tabs__menu { float: left; /* LTR */ diff --git a/core/themes/stable/css/image/editors/image.theme.css b/core/themes/stable/css/image/editors/image.theme.css index 5520758..549a56f 100644 --- a/core/themes/stable/css/image/editors/image.theme.css +++ b/core/themes/stable/css/image/editors/image.theme.css @@ -50,11 +50,13 @@ border-color: white transparent transparent transparent; } +/* stylelint-disable block-closing-brace-newline-before, block-opening-brace-newline-after */ @keyframes quickedit-image-spin { 0% {transform: rotate(0deg);} 50% {transform: rotate(180deg);} 100% {transform: rotate(360deg);} } +/* stylelint-enable */ .quickedit-image-text { text-align: center; diff --git a/core/themes/stable/css/quickedit/quickedit.theme.css b/core/themes/stable/css/quickedit/quickedit.theme.css index 399db7a..db233c8 100644 --- a/core/themes/stable/css/quickedit/quickedit.theme.css +++ b/core/themes/stable/css/quickedit/quickedit.theme.css @@ -174,9 +174,9 @@ padding: 0.1667em 0.2em; } - /** - * Info toolgroup. - */ +/** + * Info toolgroup. + */ .quickedit-toolbar-fullwidth { width: 100%; } diff --git a/core/themes/stable/css/system/system.admin.css b/core/themes/stable/css/system/system.admin.css index cd92b1a..1919732 100644 --- a/core/themes/stable/css/system/system.admin.css +++ b/core/themes/stable/css/system/system.admin.css @@ -211,7 +211,7 @@ small .admin-link:after { background-color: transparent; } [dir="rtl"] .system-status-report__status-title { - padding: 10px 40px 10px 6px; + padding: 10px 40px 10px 6px; } .system-status-report__status-icon:before { content: ""; diff --git a/core/themes/stable/css/views_ui/views_ui.admin.theme.css b/core/themes/stable/css/views_ui/views_ui.admin.theme.css index e4ac1e4..a5f86d8 100644 --- a/core/themes/stable/css/views_ui/views_ui.admin.theme.css +++ b/core/themes/stable/css/views_ui/views_ui.admin.theme.css @@ -158,7 +158,7 @@ details.box-padding { /* Hide 'remove' checkboxes. */ .views-remove-checkbox { - display: none; + display: none; } /* sizes the labels of checkboxes and radio button to the height of the text */