2020-08-04 23:37:35 +02:00
|
|
|
"use strict";
|
|
|
|
|
|
|
|
module.exports = {
|
2020-08-05 00:10:06 +02:00
|
|
|
extends: ["stylelint-config-standard", "stylelint-config-prettier"],
|
2020-08-04 23:37:35 +02:00
|
|
|
rules: {
|
2020-08-04 23:50:46 +02:00
|
|
|
// Add some exceptions for recommended rules
|
|
|
|
"at-rule-no-unknown": [true, {ignoreAtRules: ["extend"]}],
|
|
|
|
|
|
|
|
// Disable recommended rules we don't comply with yet
|
|
|
|
"font-family-no-missing-generic-family-keyword": null,
|
|
|
|
"no-descending-specificity": null,
|
|
|
|
|
2020-08-05 00:10:06 +02:00
|
|
|
// Disable standard rules we don't comply with yet
|
|
|
|
"comment-empty-line-before": null,
|
|
|
|
"declaration-empty-line-before": null,
|
2020-08-04 23:37:35 +02:00
|
|
|
|
2020-08-05 00:43:16 +02:00
|
|
|
// Additional stylistic rules
|
|
|
|
"font-family-name-quotes": "always-where-recommended",
|
2020-08-05 00:44:06 +02:00
|
|
|
"function-url-quotes": "never",
|
2020-08-05 00:43:16 +02:00
|
|
|
|
2020-08-04 23:37:35 +02:00
|
|
|
// Limit language features
|
2018-10-10 18:49:38 +02:00
|
|
|
"color-no-hex": true,
|
2019-01-23 00:33:18 +01:00
|
|
|
"color-named": "never",
|
2020-09-03 00:52:03 +02:00
|
|
|
"declaration-property-value-disallowed-list": {
|
2020-08-05 20:32:25 +02:00
|
|
|
// thin/medium/thick is under-specified, please use pixels
|
|
|
|
"/^(border(-top|-right|-bottom|-left)?|outline)(-width)?$/": [
|
|
|
|
/\b(thin|medium|thick)\b/,
|
|
|
|
],
|
|
|
|
},
|
2020-09-03 00:52:03 +02:00
|
|
|
"function-disallowed-list": [
|
2020-08-05 20:32:25 +02:00
|
|
|
// We use hsl(a) instead of rgb(a)
|
|
|
|
"rgb",
|
|
|
|
"rgba",
|
|
|
|
],
|
|
|
|
|
|
|
|
// Zulip CSS should have no dependencies on external resources
|
|
|
|
"function-url-no-scheme-relative": true,
|
2020-09-03 00:52:03 +02:00
|
|
|
"function-url-scheme-allowed-list": [],
|
2020-08-06 01:53:56 +02:00
|
|
|
|
|
|
|
// We use autoprefixer to generate vendor prefixes
|
|
|
|
"at-rule-no-vendor-prefix": true,
|
|
|
|
"media-feature-name-no-vendor-prefix": true,
|
|
|
|
"property-no-vendor-prefix": true,
|
|
|
|
"selector-no-vendor-prefix": true,
|
|
|
|
"value-no-vendor-prefix": true,
|
2020-08-04 23:37:35 +02:00
|
|
|
},
|
|
|
|
};
|