stylelint-config-ccb 1.9.6 → 1.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +280 -32
- package/package.json +16 -6
package/index.js
CHANGED
|
@@ -6,7 +6,8 @@ module.exports = {
|
|
|
6
6
|
'stylelint-order',
|
|
7
7
|
'stylelint-selector-no-empty',
|
|
8
8
|
'stylelint-color-format',
|
|
9
|
-
'stylelint-prettier'
|
|
9
|
+
'stylelint-prettier',
|
|
10
|
+
'stylelint-a11y',
|
|
10
11
|
],
|
|
11
12
|
rules: {
|
|
12
13
|
/* stylelint-config-standard overwrites */
|
|
@@ -17,16 +18,16 @@ module.exports = {
|
|
|
17
18
|
'always',
|
|
18
19
|
{
|
|
19
20
|
except: [
|
|
20
|
-
'empty'
|
|
21
|
-
]
|
|
22
|
-
}
|
|
21
|
+
'empty',
|
|
22
|
+
],
|
|
23
|
+
},
|
|
23
24
|
],
|
|
24
25
|
'value-keyword-case': [
|
|
25
26
|
'lower',
|
|
26
27
|
{
|
|
27
28
|
ignoreProperties: ['unicode-range'],
|
|
28
|
-
camelCaseSvgKeywords: true
|
|
29
|
-
}
|
|
29
|
+
camelCaseSvgKeywords: true,
|
|
30
|
+
},
|
|
30
31
|
],
|
|
31
32
|
'number-max-precision': 5,
|
|
32
33
|
/* todo update these based on 'selector-id-pattern': [
|
|
@@ -47,17 +48,17 @@ module.exports = {
|
|
|
47
48
|
'border-width': 2,
|
|
48
49
|
border: 3,
|
|
49
50
|
margin: 2,
|
|
50
|
-
padding: 2
|
|
51
|
+
padding: 2,
|
|
51
52
|
},
|
|
52
53
|
|
|
53
54
|
'rule-selector-property-disallowed-list': {
|
|
54
|
-
html: ['background', 'background-color', 'background-image', /^background/]
|
|
55
|
+
html: ['background', 'background-color', 'background-image', /^background/],
|
|
55
56
|
},
|
|
56
57
|
|
|
57
58
|
'at-rule-allowed-list': ['import', 'media', 'keyframes', 'charset', 'font-face', 'page', 'supports'],
|
|
58
59
|
'at-rule-disallowed-list': ['custom-selector', '-moz-document'],
|
|
59
60
|
'at-rule-property-required-list': {
|
|
60
|
-
'font-face': ['font-display', 'font-family', 'font-style', 'src']
|
|
61
|
+
'font-face': ['font-display', 'font-family', 'font-style', 'src'],
|
|
61
62
|
},
|
|
62
63
|
'color-no-hex': true,
|
|
63
64
|
'comment-word-disallowed-list': [
|
|
@@ -76,7 +77,7 @@ module.exports = {
|
|
|
76
77
|
'retarded', 'sane', 'sanity-check', 'sexy', 'sherpa', 'slave',
|
|
77
78
|
'smartphone', 'tarball', 'textbox', 'tribal', 'voodoo', 'webmaster',
|
|
78
79
|
'whitehat', 'white-hat', 'whitelist', 'white-list', 'whitelisted',
|
|
79
|
-
'white-listed', 'whitelisting', 'white-listing', 'ymmv'
|
|
80
|
+
'white-listed', 'whitelisting', 'white-listing', 'ymmv',
|
|
80
81
|
],
|
|
81
82
|
'declaration-property-unit-allowed-list': {
|
|
82
83
|
'font-size': ['rem', 'em'],
|
|
@@ -85,7 +86,7 @@ module.exports = {
|
|
|
85
86
|
'line-height': [],
|
|
86
87
|
'z-index': [],
|
|
87
88
|
opacity: [],
|
|
88
|
-
'letter-spacing': ['em']
|
|
89
|
+
'letter-spacing': ['em'],
|
|
89
90
|
},
|
|
90
91
|
'declaration-property-value-allowed-list': {
|
|
91
92
|
'text-decoration': ['inherit', 'underline', 'none'],
|
|
@@ -97,14 +98,15 @@ module.exports = {
|
|
|
97
98
|
fill: ['currentColor', 'inherit', 'none'],
|
|
98
99
|
overflow: ['initial', 'hidden', 'clip', 'auto'],
|
|
99
100
|
overflowX: ['initial', 'hidden', 'clip', 'auto'],
|
|
100
|
-
overflowY: ['initial', 'hidden', 'clip', 'auto']
|
|
101
|
+
overflowY: ['initial', 'hidden', 'clip', 'auto'],
|
|
101
102
|
},
|
|
102
103
|
'declaration-property-value-disallowed-list': {
|
|
103
|
-
outline: ['none'],
|
|
104
|
+
outline: ['none', '0'],
|
|
104
105
|
color: ['rebeccapurple'],
|
|
105
106
|
fill: ['rebeccapurple'],
|
|
106
107
|
'background-color': ['rebeccapurple', 'none'],
|
|
107
|
-
'font-size': ['0']
|
|
108
|
+
'font-size': ['0'],
|
|
109
|
+
'text-align': ['justify'],
|
|
108
110
|
},
|
|
109
111
|
'function-url-scheme-allowed-list': ['data', 'https'],
|
|
110
112
|
'function-disallowed-list': ['gray', 'color-mod', 'color', 'rgba', 'hsla'],
|
|
@@ -373,7 +375,7 @@ module.exports = {
|
|
|
373
375
|
/* opinionated */
|
|
374
376
|
'float',
|
|
375
377
|
|
|
376
|
-
'font-smooth'
|
|
378
|
+
'font-smooth',
|
|
377
379
|
],
|
|
378
380
|
'time-min-milliseconds': 75,
|
|
379
381
|
'selector-no-qualifying-type': true,
|
|
@@ -382,21 +384,257 @@ module.exports = {
|
|
|
382
384
|
'selector-max-universal': 0,
|
|
383
385
|
'selector-max-pseudo-class': 2,
|
|
384
386
|
'selector-max-type': 2,
|
|
385
|
-
'selector-disallowed-list': [
|
|
387
|
+
'selector-disallowed-list': [
|
|
388
|
+
':root',
|
|
389
|
+
// legacy elements
|
|
390
|
+
'applet',
|
|
391
|
+
'acronym',
|
|
392
|
+
'bgsound',
|
|
393
|
+
'dir',
|
|
394
|
+
'frame',
|
|
395
|
+
'frameset',
|
|
396
|
+
'noframes',
|
|
397
|
+
'hgroup',
|
|
398
|
+
'isindex',
|
|
399
|
+
'listing',
|
|
400
|
+
'nextid',
|
|
401
|
+
'noembed',
|
|
402
|
+
'plaintext',
|
|
403
|
+
'rb',
|
|
404
|
+
'rtc',
|
|
405
|
+
'strike',
|
|
406
|
+
'xmp',
|
|
407
|
+
'basefont',
|
|
408
|
+
'big',
|
|
409
|
+
'blink',
|
|
410
|
+
'center',
|
|
411
|
+
'font',
|
|
412
|
+
'marquee',
|
|
413
|
+
'multicol',
|
|
414
|
+
'nobr',
|
|
415
|
+
'spacer',
|
|
416
|
+
'tt',
|
|
417
|
+
'keygen',
|
|
418
|
+
'menu',
|
|
419
|
+
'menuitem',
|
|
420
|
+
// legacy attributes
|
|
421
|
+
'[dropzone]',
|
|
422
|
+
'a[charset]',
|
|
423
|
+
'link[charset]',
|
|
424
|
+
'a[coords]',
|
|
425
|
+
'a[shape]',
|
|
426
|
+
'a[methods]',
|
|
427
|
+
'link[methods]',
|
|
428
|
+
'a[name]',
|
|
429
|
+
'option[name]',
|
|
430
|
+
'embed[name]',
|
|
431
|
+
'img[name]',
|
|
432
|
+
'a[rev]',
|
|
433
|
+
'link[rev]',
|
|
434
|
+
'a[urn]',
|
|
435
|
+
'link[urn]',
|
|
436
|
+
'form[accept]',
|
|
437
|
+
'head[profile]',
|
|
438
|
+
'html[version]',
|
|
439
|
+
'link[target]',
|
|
440
|
+
'param[type]',
|
|
441
|
+
'param[valuetype]',
|
|
442
|
+
'script[language]',
|
|
443
|
+
'script[event]',
|
|
444
|
+
'script[for]',
|
|
445
|
+
'table[datapagesize]',
|
|
446
|
+
'table[summary]',
|
|
447
|
+
'td[axis]',
|
|
448
|
+
'th[axis]',
|
|
449
|
+
'td[scope]',
|
|
450
|
+
'td[abbr]',
|
|
451
|
+
'a[datasrc]',
|
|
452
|
+
'applet[datasrc]',
|
|
453
|
+
'button[datasrc]',
|
|
454
|
+
'div[datasrc]',
|
|
455
|
+
'frame[datasrc]',
|
|
456
|
+
'label[datasrc]',
|
|
457
|
+
'legend[datasrc]',
|
|
458
|
+
'marquee[datasrc]',
|
|
459
|
+
'option[datasrc]',
|
|
460
|
+
'span[datasrc]',
|
|
461
|
+
'table[datasrc]',
|
|
462
|
+
'a[datafld]',
|
|
463
|
+
'applet[datafld]',
|
|
464
|
+
'button[datafld]',
|
|
465
|
+
'div[datafld]',
|
|
466
|
+
'fieldset[datafld]',
|
|
467
|
+
'frame[datafld]',
|
|
468
|
+
'label[datafld]',
|
|
469
|
+
'legend[datafld]',
|
|
470
|
+
'marquee[datafld]',
|
|
471
|
+
'param[datafld]',
|
|
472
|
+
'span[datafld]',
|
|
473
|
+
'button[dataformatas]',
|
|
474
|
+
'div[dataformatas]',
|
|
475
|
+
'label[dataformatas]',
|
|
476
|
+
'legend[dataformatas]',
|
|
477
|
+
'marquee[dataformatas]',
|
|
478
|
+
'option[dataformatas]',
|
|
479
|
+
'span[dataformatas]',
|
|
480
|
+
'table[dataformatas]',
|
|
481
|
+
'body[alink]',
|
|
482
|
+
'body[bgcolor]',
|
|
483
|
+
'table[bgcolor]',
|
|
484
|
+
'td[bgcolor]',
|
|
485
|
+
'th[bgcolor]',
|
|
486
|
+
'tr[bgcolor]',
|
|
487
|
+
'body[link]',
|
|
488
|
+
'body[marginbottom]',
|
|
489
|
+
'body[marginheight]',
|
|
490
|
+
'body[marginleft]',
|
|
491
|
+
'body[marginright]',
|
|
492
|
+
'body[margintop]',
|
|
493
|
+
'body[marginwidth]',
|
|
494
|
+
'body[text]',
|
|
495
|
+
'body[vlink]',
|
|
496
|
+
'col[char]',
|
|
497
|
+
'tbody[char]',
|
|
498
|
+
'thead[char]',
|
|
499
|
+
'tfoot[char]',
|
|
500
|
+
'td[char]',
|
|
501
|
+
'th[char]',
|
|
502
|
+
'tr[char]',
|
|
503
|
+
'col[charoff]',
|
|
504
|
+
'tbody[charoff]',
|
|
505
|
+
'thead[charoff]',
|
|
506
|
+
'tfoot[charoff]',
|
|
507
|
+
'td[charoff]',
|
|
508
|
+
'th[charoff]',
|
|
509
|
+
'tr[charoff]',
|
|
510
|
+
'col[valign]',
|
|
511
|
+
'tbody[valign]',
|
|
512
|
+
'thead[valign]',
|
|
513
|
+
'tfoot[valign]',
|
|
514
|
+
'td[valign]',
|
|
515
|
+
'th[valign]',
|
|
516
|
+
'tr[valign]',
|
|
517
|
+
'col[width]',
|
|
518
|
+
'pre[width]',
|
|
519
|
+
'table[width]',
|
|
520
|
+
'td[width]',
|
|
521
|
+
'th[width]',
|
|
522
|
+
'dl[compact]',
|
|
523
|
+
'ol[compact]',
|
|
524
|
+
'ul[compact]',
|
|
525
|
+
'h1[align]',
|
|
526
|
+
'h2[align]',
|
|
527
|
+
'h3[align]',
|
|
528
|
+
'h4[align]',
|
|
529
|
+
'h5[align]',
|
|
530
|
+
'h6[align]',
|
|
531
|
+
'caption[align]',
|
|
532
|
+
'col[align]',
|
|
533
|
+
'div[align]',
|
|
534
|
+
'legend[align]',
|
|
535
|
+
'p[align]',
|
|
536
|
+
'table[align]',
|
|
537
|
+
'tbody[align]',
|
|
538
|
+
'thead[align]',
|
|
539
|
+
'tfoot[align]',
|
|
540
|
+
'td[align]',
|
|
541
|
+
'th[align]',
|
|
542
|
+
'tr[align]',
|
|
543
|
+
'li[type]',
|
|
544
|
+
'ul[type]',
|
|
545
|
+
'table[cellpadding]',
|
|
546
|
+
'table[cellspacing]',
|
|
547
|
+
'table[frame]',
|
|
548
|
+
'table[rules]',
|
|
549
|
+
'td[height]',
|
|
550
|
+
'th[height]',
|
|
551
|
+
'td[nowrap]',
|
|
552
|
+
'th[nowrap]',
|
|
553
|
+
'body[background]',
|
|
554
|
+
'table[background]',
|
|
555
|
+
'thead[background]',
|
|
556
|
+
'tbody[background]',
|
|
557
|
+
'tfoot[background]',
|
|
558
|
+
'tr[background]',
|
|
559
|
+
'td[background]',
|
|
560
|
+
'th[background]',
|
|
561
|
+
'embed[name]',
|
|
562
|
+
'img[name]',
|
|
563
|
+
'area[nohref]',
|
|
564
|
+
'area[type]',
|
|
565
|
+
'area[hreflang]',
|
|
566
|
+
'input[ismap]',
|
|
567
|
+
'input[usemap]',
|
|
568
|
+
'iframe[longdesc]',
|
|
569
|
+
'img[longdesc]',
|
|
570
|
+
'img[lowsrc]',
|
|
571
|
+
'object[archive]',
|
|
572
|
+
'object[classid]',
|
|
573
|
+
'object[code]',
|
|
574
|
+
'object[codebase]',
|
|
575
|
+
'object[codetype]',
|
|
576
|
+
'object[declare]',
|
|
577
|
+
'object[standby]',
|
|
578
|
+
'iframe[datasrc]',
|
|
579
|
+
'img[datasrc]',
|
|
580
|
+
'input[datasrc]',
|
|
581
|
+
'object[datasrc]',
|
|
582
|
+
'select[datasrc]',
|
|
583
|
+
'textarea[datasrc]',
|
|
584
|
+
'iframe[datafld]',
|
|
585
|
+
'img[datafld]',
|
|
586
|
+
'input[datafld]',
|
|
587
|
+
'object[datafld]',
|
|
588
|
+
'select[datafld]',
|
|
589
|
+
'textarea[datafld]',
|
|
590
|
+
'input[dataformatas]',
|
|
591
|
+
'object[dataformatas]',
|
|
592
|
+
'select[dataformatas]',
|
|
593
|
+
'iframe[marginheight]',
|
|
594
|
+
'iframe[marginwidth]',
|
|
595
|
+
'br[clear]',
|
|
596
|
+
'hr[width]',
|
|
597
|
+
'embed[hspace]',
|
|
598
|
+
'iframe[hspace]',
|
|
599
|
+
'input[hspace]',
|
|
600
|
+
'img[hspace]',
|
|
601
|
+
'object[hspace]',
|
|
602
|
+
'embed[vspace]',
|
|
603
|
+
'iframe[vspace]',
|
|
604
|
+
'input[vspace]',
|
|
605
|
+
'img[vspace]',
|
|
606
|
+
'object[vspace]',
|
|
607
|
+
'hr[color]',
|
|
608
|
+
'hr[noshade]',
|
|
609
|
+
'hr[size]',
|
|
610
|
+
'iframe[align]',
|
|
611
|
+
'embed[align]',
|
|
612
|
+
'hr[align]',
|
|
613
|
+
'input[align]',
|
|
614
|
+
'img[align]',
|
|
615
|
+
'object[align]',
|
|
616
|
+
'iframe[allowtransparency]',
|
|
617
|
+
'iframe[frameborder]',
|
|
618
|
+
'iframe[framespacing]',
|
|
619
|
+
'iframe[scrolling]',
|
|
620
|
+
'img[border]',
|
|
621
|
+
'object[border]',
|
|
622
|
+
'input[inputmode]',
|
|
623
|
+
],
|
|
386
624
|
'selector-pseudo-class-disallowed-list': [':scope', ':has', ':matches'],
|
|
387
625
|
'unit-disallowed-list': [
|
|
388
626
|
'cm', 'mm', 'Q', 'in', 'pc', 'pt',
|
|
389
627
|
'ex', 'ch',
|
|
390
|
-
's'
|
|
628
|
+
's',
|
|
391
629
|
],
|
|
392
630
|
|
|
393
631
|
'font-weight-notation': [
|
|
394
632
|
'numeric',
|
|
395
633
|
{
|
|
396
634
|
ignore: [
|
|
397
|
-
'relative'
|
|
398
|
-
]
|
|
399
|
-
}
|
|
635
|
+
'relative',
|
|
636
|
+
],
|
|
637
|
+
},
|
|
400
638
|
],
|
|
401
639
|
'function-url-no-scheme-relative': true,
|
|
402
640
|
'max-nesting-depth': 2,
|
|
@@ -428,14 +666,24 @@ module.exports = {
|
|
|
428
666
|
true,
|
|
429
667
|
{
|
|
430
668
|
quoteProps: 'preserve',
|
|
431
|
-
printWidth: 120
|
|
432
|
-
}
|
|
669
|
+
printWidth: 120,
|
|
670
|
+
},
|
|
433
671
|
],
|
|
434
672
|
|
|
435
673
|
'color-format/format': {
|
|
436
|
-
format: 'rgb'
|
|
674
|
+
format: 'rgb',
|
|
437
675
|
},
|
|
438
676
|
|
|
677
|
+
'a11y/font-size-is-readable': true,
|
|
678
|
+
'a11y/media-prefers-reduced-motion': true,
|
|
679
|
+
'a11y/no-obsolete-attribute': true,
|
|
680
|
+
'a11y/no-obsolete-element': true,
|
|
681
|
+
'a11y/no-spread-text': true,
|
|
682
|
+
'a11y/no-outline-none': true,
|
|
683
|
+
'a11y/no-text-align-justify': true,
|
|
684
|
+
// also covered with declaration-property-value-allowed-list
|
|
685
|
+
'a11y/content-property-no-static-value': true,
|
|
686
|
+
|
|
439
687
|
'plugin/stylelint-selector-no-empty': true,
|
|
440
688
|
|
|
441
689
|
'order/order': [
|
|
@@ -446,15 +694,15 @@ module.exports = {
|
|
|
446
694
|
'declarations',
|
|
447
695
|
{
|
|
448
696
|
type: 'at-rule',
|
|
449
|
-
name: 'supports'
|
|
697
|
+
name: 'supports',
|
|
450
698
|
},
|
|
451
699
|
{
|
|
452
700
|
type: 'at-rule',
|
|
453
|
-
name: 'media'
|
|
701
|
+
name: 'media',
|
|
454
702
|
},
|
|
455
|
-
'rules'
|
|
703
|
+
'rules',
|
|
456
704
|
],
|
|
457
|
-
{ severity: 'warning' }
|
|
705
|
+
{ severity: 'warning' },
|
|
458
706
|
],
|
|
459
707
|
'order/properties-order': [
|
|
460
708
|
[
|
|
@@ -936,12 +1184,12 @@ module.exports = {
|
|
|
936
1184
|
'offset-path',
|
|
937
1185
|
'offset-distance',
|
|
938
1186
|
'offset-rotate',
|
|
939
|
-
'offset-anchor'
|
|
1187
|
+
'offset-anchor',
|
|
940
1188
|
],
|
|
941
1189
|
{
|
|
942
1190
|
unspecified: 'bottom',
|
|
943
|
-
severity: 'warning'
|
|
944
|
-
}
|
|
945
|
-
]
|
|
946
|
-
}
|
|
1191
|
+
severity: 'warning',
|
|
1192
|
+
},
|
|
1193
|
+
],
|
|
1194
|
+
},
|
|
947
1195
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "stylelint-config-ccb",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.11.0",
|
|
4
4
|
"description": "Stylelint config which extends stylelint-config-standard",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"stylelint",
|
|
@@ -17,17 +17,27 @@
|
|
|
17
17
|
"index.js"
|
|
18
18
|
],
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"
|
|
20
|
+
"@ronilaukkarinen/stylelint-a11y": "^1.2.4",
|
|
21
|
+
"prettier": "^2.7.1",
|
|
21
22
|
"stylelint-color-format": "^1.1.0",
|
|
22
|
-
"stylelint-config-standard": "^
|
|
23
|
+
"stylelint-config-standard": "^26.0.0",
|
|
23
24
|
"stylelint-order": "^5.0.0",
|
|
24
25
|
"stylelint-prettier": "^2.0.0",
|
|
25
|
-
"stylelint-selector-no-empty": "^1.0.
|
|
26
|
+
"stylelint-selector-no-empty": "^1.0.9"
|
|
26
27
|
},
|
|
27
28
|
"devDependencies": {
|
|
28
|
-
"
|
|
29
|
+
"eslint": "^8.18.0",
|
|
30
|
+
"eslint-config-ccb": "^0.0.14",
|
|
31
|
+
"stylelint": "^14.9.1"
|
|
29
32
|
},
|
|
30
33
|
"peerDependencies": {
|
|
31
|
-
"stylelint": ">=14.
|
|
34
|
+
"stylelint": ">=14.9.0"
|
|
35
|
+
},
|
|
36
|
+
"eslintConfig": {
|
|
37
|
+
"extends": "ccb",
|
|
38
|
+
"env": {
|
|
39
|
+
"node": true,
|
|
40
|
+
"es2022": true
|
|
41
|
+
}
|
|
32
42
|
}
|
|
33
43
|
}
|