File tree 1 file changed +38
-38
lines changed
1 file changed +38
-38
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,43 @@ import * as ValueParser from './value-parser'
29
29
const IS_VALID_STATIC_UTILITY_NAME = / ^ - ? [ a - z ] [ a - z A - Z 0 - 9 / % . _ - ] * $ /
30
30
const IS_VALID_FUNCTIONAL_UTILITY_NAME = / ^ - ? [ a - z ] [ a - z A - Z 0 - 9 / % . _ - ] * - \* $ /
31
31
32
+ const DEFAULT_SPACING_SUGGESTIONS = [
33
+ '0' ,
34
+ '0.5' ,
35
+ '1' ,
36
+ '1.5' ,
37
+ '2' ,
38
+ '2.5' ,
39
+ '3' ,
40
+ '3.5' ,
41
+ '4' ,
42
+ '5' ,
43
+ '6' ,
44
+ '7' ,
45
+ '8' ,
46
+ '9' ,
47
+ '10' ,
48
+ '11' ,
49
+ '12' ,
50
+ '14' ,
51
+ '16' ,
52
+ '20' ,
53
+ '24' ,
54
+ '28' ,
55
+ '32' ,
56
+ '36' ,
57
+ '40' ,
58
+ '44' ,
59
+ '48' ,
60
+ '52' ,
61
+ '56' ,
62
+ '60' ,
63
+ '64' ,
64
+ '72' ,
65
+ '80' ,
66
+ '96' ,
67
+ ]
68
+
32
69
type CompileFn < T extends Candidate [ 'kind' ] > = (
33
70
value : Extract < Candidate , { kind : T } > ,
34
71
) => AstNode [ ] | undefined | null
@@ -476,44 +513,7 @@ export function createUtilities(theme: Theme) {
476
513
477
514
suggest ( name , ( ) => [
478
515
{
479
- values : theme . get ( [ '--spacing' ] )
480
- ? [
481
- '0' ,
482
- '0.5' ,
483
- '1' ,
484
- '1.5' ,
485
- '2' ,
486
- '2.5' ,
487
- '3' ,
488
- '3.5' ,
489
- '4' ,
490
- '5' ,
491
- '6' ,
492
- '7' ,
493
- '8' ,
494
- '9' ,
495
- '10' ,
496
- '11' ,
497
- '12' ,
498
- '14' ,
499
- '16' ,
500
- '20' ,
501
- '24' ,
502
- '28' ,
503
- '32' ,
504
- '36' ,
505
- '40' ,
506
- '44' ,
507
- '48' ,
508
- '52' ,
509
- '56' ,
510
- '60' ,
511
- '64' ,
512
- '72' ,
513
- '80' ,
514
- '96' ,
515
- ]
516
- : [ ] ,
516
+ values : theme . get ( [ '--spacing' ] ) ? DEFAULT_SPACING_SUGGESTIONS : [ ] ,
517
517
supportsNegative,
518
518
supportsFractions,
519
519
valueThemeKeys : themeKeys ,
You can’t perform that action at this time.
0 commit comments