From b3c629ef4d8d89e72de9977c051e8e4efbab6e06 Mon Sep 17 00:00:00 2001 From: Ed Sanders Date: Wed, 14 Mar 2018 21:32:46 +0000 Subject: [PATCH] build: Update linters Change-Id: Iee462bae8112755e7cd0c5caa88c3fc6fcdc852e --- .stylelintrc.json | 2 +- package.json | 10 ++++----- resources/forms.less | 42 ++++++++++++++++++------------------ resources/screen-mobile.less | 2 +- 4 files changed, 28 insertions(+), 28 deletions(-) diff --git a/.stylelintrc.json b/.stylelintrc.json index 73f1bdc..0cdedf1 100644 --- a/.stylelintrc.json +++ b/.stylelintrc.json @@ -2,7 +2,7 @@ "extends": "stylelint-config-wikimedia", "rules": { "no-duplicate-selectors": null, - "selector-no-id": null, + "selector-max-id": null, "declaration-no-important": null, "no-descending-specificity": null } diff --git a/package.json b/package.json index 90408a6..3dcc2ca 100644 --- a/package.json +++ b/package.json @@ -4,13 +4,13 @@ "test": "grunt test" }, "devDependencies": { - "eslint-config-wikimedia": "0.4.0", + "eslint-config-wikimedia": "0.5.0", "grunt": "1.0.1", "grunt-banana-checker": "0.6.0", - "grunt-eslint": "20.0.0", + "grunt-eslint": "20.1.0", "grunt-jsonlint": "1.1.0", - "grunt-stylelint": "0.7.0", - "stylelint": "7.8.0", - "stylelint-config-wikimedia": "0.4.1" + "grunt-stylelint": "0.9.0", + "stylelint": "8.2.0", + "stylelint-config-wikimedia": "0.4.2" } } diff --git a/resources/forms.less b/resources/forms.less index a378871..e3e0bca 100644 --- a/resources/forms.less +++ b/resources/forms.less @@ -42,8 +42,8 @@ display: block; padding: 0.25em 0.5em; } - input[type='checkbox'], - input[type='radio'] { + input[ type='checkbox' ], + input[ type='radio' ] { margin-left: 0; } } @@ -96,21 +96,21 @@ label { */ /* pile of bad hacks to try to catch all the different ones */ -#searchInput, -input[name='target'], -input[name='user'], -input[name='mime'], -input[size$='0'], -input[type='text'], -input[type='checkbox'], -input[type='radio'], +input[ name='target' ], +input[ name='user' ], +input[ name='mime' ], +input[ size$='0' ], +input[ type='text' ], +input[ type='checkbox' ], +input[ type='radio' ], input#wpTemplateSandboxPage, input.mw-summary, input.mw-input, .mw-input input, textarea, .mw-ui-input-inline, -.mw-ui-input { +.mw-ui-input, +#searchInput { box-sizing: border-box; padding: 0.25em 0.35em; border: solid 1px @grey; @@ -124,22 +124,22 @@ select { padding: 0.25em; margin: 0.5em 0; } -input[type='checkbox'], -input[type='radio'] { +input[ type='checkbox' ], +input[ type='radio' ] { margin-left: 1em; min-height: 0; } -input[type='checkbox'] { +input[ type='checkbox' ] { border-radius: 2px; } -input[type='radio'] { +input[ type='radio' ] { border-radius: 8px; } .mw-ui-button.mw-ui-progressive, .mw-ui-button.mw-ui-progressive:active, .mw-ui-button.mw-ui-progressive.mw-ui-checked, -input[type='submit'], -input[type='button'], +input[ type='submit' ], +input[ type='button' ], button { padding: 0.25em 1em 0.1em 1em; border: solid 1px @grey; @@ -221,7 +221,7 @@ div.editOptions { label { padding: 0 1em 0 0; } - input[type='submit'] { + input[ type='submit' ] { margin: 0 0 0 4em; } } @@ -229,7 +229,7 @@ div.editOptions { /* Related changes hacks */ .mw-special-Recentchangeslinked { .rcoptions { - input[type='submit'] { + input[ type='submit' ] { float: right; margin: 0 0 0 4em; } @@ -237,7 +237,7 @@ div.editOptions { vertical-align: top; padding-top: 0.75em; } - input[name='target'] { + input[ name='target' ] { float: left; } } @@ -245,7 +245,7 @@ div.editOptions { clear: left; float: left; } - label[for='showlinkedto'] { + label[ for='showlinkedto' ] { padding: 0.4em; float: left; } diff --git a/resources/screen-mobile.less b/resources/screen-mobile.less index 35a1ee4..daa0aef 100644 --- a/resources/screen-mobile.less +++ b/resources/screen-mobile.less @@ -168,7 +168,7 @@ #ca-addsection a { .background-image-svg( 'images/plus-grey.svg', 'images/plus-grey.png' ); } -*[id^='ca-nstab-'] a { +*[ id^='ca-nstab-' ] a { .background-image-svg( 'images/page-grey.svg', 'images/page-grey.png' ); }