Skip to content

Commit

Permalink
[CSS Stylelint] activates some more rules (#21030)
Browse files Browse the repository at this point in the history
* Expect leading & trailing whitespace in comments for better readability

* disallow unknown units

* disallow unmatchable selectors
  • Loading branch information
sgiehl committed Jul 18, 2023
1 parent d6436aa commit d13d4c4
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 11 deletions.
7 changes: 5 additions & 2 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"customSyntax": "postcss-less"
}
],
"ignoreFiles": ["node_modules/**/*", "vendor/**/*", "tests/**/*", "tmp/**/*", "misc/**/*", "plugins/*/vue/dist/*", "plugins/Morpheus/stylesheets/base/bootstrap.css"],
"ignoreFiles": ["node_modules/**/*", "vendor/**/*", "tests/**/*", "tmp/**/*", "misc/**/*", "plugins/*/vue/dist/*", "plugins/*/tests/**/*", "plugins/Morpheus/stylesheets/base/bootstrap.css"],
"rules": {
"color-no-invalid-hex": true,
"no-irregular-whitespace": true,
Expand All @@ -19,6 +19,9 @@
],
"font-family-no-duplicate-names": true,
"no-duplicate-at-import-rules": true,
"no-duplicate-selectors": true
"no-duplicate-selectors": true,
"comment-whitespace-inside": "always",
"unit-no-unknown": true,
"selector-anb-no-unmatchable": true
}
}
2 changes: 1 addition & 1 deletion plugins/CoreHome/stylesheets/coreHome.less
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
left: 200px;
}

/* Calendar*/
/* Calendar */
div.ui-datepicker {
font-size: 62.5%;
}
Expand Down
4 changes: 2 additions & 2 deletions plugins/CoreHome/stylesheets/jquery.ui.autocomplete.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* Autocomplete
----------------------------------*/
---------------------------------- */
.ui-autocomplete {
position: absolute;
cursor: default;
Expand All @@ -16,7 +16,7 @@
}

/* Menu
----------------------------------*/
---------------------------------- */
.ui-menu {
list-style: none;
padding: 6px;
Expand Down
4 changes: 0 additions & 4 deletions plugins/CoreHome/vue/src/SiteSelector/SiteSelector.less
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,6 @@
.siteSelector.piwikSelector a.title {
padding: 10px 15px 11px 13px;

/*.icon:not(.icon-fixed) {
margin-right: -11px;
}*/

> span {
max-width: 161px;
overflow: hidden;
Expand Down
4 changes: 2 additions & 2 deletions plugins/SegmentEditor/stylesheets/segmentation.less
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* ADDITIONAL STYLES*/
/* ADDITIONAL STYLES */
.youMustBeLoggedIn {
font-size: 8pt;
font-style: italic;
Expand Down Expand Up @@ -380,7 +380,7 @@ html.comparisonsDisabled .segmentationContainer ul.submenu {
background: transparent !important;
}

/* ADDITIONAL STYLES*/
/* ADDITIONAL STYLES */
.segment-element .segment-nav div > ul > li ul {
margin-left: 0;
}
Expand Down

0 comments on commit d13d4c4

Please sign in to comment.