@tbela99/css-parser 0.0.1-alpha3

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.
@@ -0,0 +1,708 @@
1
+ var properties = {
2
+ inset: {
3
+ shorthand: "inset",
4
+ properties: [
5
+ "top",
6
+ "right",
7
+ "bottom",
8
+ "left"
9
+ ],
10
+ types: [
11
+ "Length",
12
+ "Perc"
13
+ ],
14
+ multiple: false,
15
+ separator: null,
16
+ keywords: [
17
+ "auto"
18
+ ]
19
+ },
20
+ top: {
21
+ shorthand: "inset"
22
+ },
23
+ right: {
24
+ shorthand: "inset"
25
+ },
26
+ bottom: {
27
+ shorthand: "inset"
28
+ },
29
+ left: {
30
+ shorthand: "inset"
31
+ },
32
+ margin: {
33
+ shorthand: "margin",
34
+ properties: [
35
+ "margin-top",
36
+ "margin-right",
37
+ "margin-bottom",
38
+ "margin-left"
39
+ ],
40
+ types: [
41
+ "Length",
42
+ "Perc"
43
+ ],
44
+ multiple: false,
45
+ separator: null,
46
+ keywords: [
47
+ "auto"
48
+ ]
49
+ },
50
+ "margin-top": {
51
+ shorthand: "margin"
52
+ },
53
+ "margin-right": {
54
+ shorthand: "margin"
55
+ },
56
+ "margin-bottom": {
57
+ shorthand: "margin"
58
+ },
59
+ "margin-left": {
60
+ shorthand: "margin"
61
+ },
62
+ padding: {
63
+ shorthand: "padding",
64
+ properties: [
65
+ "padding-top",
66
+ "padding-right",
67
+ "padding-bottom",
68
+ "padding-left"
69
+ ],
70
+ types: [
71
+ "Length",
72
+ "Perc"
73
+ ],
74
+ keywords: [
75
+ ]
76
+ },
77
+ "padding-top": {
78
+ shorthand: "padding"
79
+ },
80
+ "padding-right": {
81
+ shorthand: "padding"
82
+ },
83
+ "padding-bottom": {
84
+ shorthand: "padding"
85
+ },
86
+ "padding-left": {
87
+ shorthand: "padding"
88
+ },
89
+ "border-radius": {
90
+ shorthand: "border-radius",
91
+ properties: [
92
+ "border-top-left-radius",
93
+ "border-top-right-radius",
94
+ "border-bottom-right-radius",
95
+ "border-bottom-left-radius"
96
+ ],
97
+ types: [
98
+ "Length",
99
+ "Perc"
100
+ ],
101
+ multiple: true,
102
+ separator: "/",
103
+ keywords: [
104
+ ]
105
+ },
106
+ "border-top-left-radius": {
107
+ shorthand: "border-radius"
108
+ },
109
+ "border-top-right-radius": {
110
+ shorthand: "border-radius"
111
+ },
112
+ "border-bottom-right-radius": {
113
+ shorthand: "border-radius"
114
+ },
115
+ "border-bottom-left-radius": {
116
+ shorthand: "border-radius"
117
+ },
118
+ "border-width": {
119
+ shorthand: "border-width",
120
+ properties: [
121
+ "border-top-width",
122
+ "border-right-width",
123
+ "border-bottom-width",
124
+ "border-left-width"
125
+ ],
126
+ types: [
127
+ "Length",
128
+ "Perc"
129
+ ],
130
+ keywords: [
131
+ "thin",
132
+ "medium",
133
+ "thick"
134
+ ]
135
+ },
136
+ "border-top-width": {
137
+ shorthand: "border-width"
138
+ },
139
+ "border-right-width": {
140
+ shorthand: "border-width"
141
+ },
142
+ "border-bottom-width": {
143
+ shorthand: "border-width"
144
+ },
145
+ "border-left-width": {
146
+ shorthand: "border-width"
147
+ },
148
+ "border-style": {
149
+ shorthand: "border-style",
150
+ properties: [
151
+ "border-top-style",
152
+ "border-right-style",
153
+ "border-bottom-style",
154
+ "border-left-style"
155
+ ],
156
+ types: [
157
+ ],
158
+ keywords: [
159
+ "none",
160
+ "hidden",
161
+ "dotted",
162
+ "dashed",
163
+ "solid",
164
+ "double",
165
+ "groove",
166
+ "ridge",
167
+ "inset",
168
+ "outset"
169
+ ]
170
+ },
171
+ "border-top-style": {
172
+ shorthand: "border-style"
173
+ },
174
+ "border-right-style": {
175
+ shorthand: "border-style"
176
+ },
177
+ "border-bottom-style": {
178
+ shorthand: "border-style"
179
+ },
180
+ "border-left-style": {
181
+ shorthand: "border-style"
182
+ },
183
+ "border-color": {
184
+ shorthand: "border-color",
185
+ properties: [
186
+ "border-top-color",
187
+ "border-right-color",
188
+ "border-bottom-color",
189
+ "border-left-color"
190
+ ],
191
+ types: [
192
+ "Color"
193
+ ],
194
+ keywords: [
195
+ ]
196
+ },
197
+ "border-top-color": {
198
+ shorthand: "border-color"
199
+ },
200
+ "border-right-color": {
201
+ shorthand: "border-color"
202
+ },
203
+ "border-bottom-color": {
204
+ shorthand: "border-color"
205
+ },
206
+ "border-left-color": {
207
+ shorthand: "border-color"
208
+ }
209
+ };
210
+ var map = {
211
+ outline: {
212
+ shorthand: "outline",
213
+ pattern: "outline-color outline-style outline-width",
214
+ keywords: [
215
+ "none"
216
+ ],
217
+ "default": [
218
+ "0",
219
+ "none"
220
+ ],
221
+ properties: {
222
+ "outline-color": {
223
+ types: [
224
+ "Color"
225
+ ],
226
+ "default": [
227
+ "currentColor",
228
+ "invert"
229
+ ],
230
+ keywords: [
231
+ "currentColor",
232
+ "invert"
233
+ ]
234
+ },
235
+ "outline-style": {
236
+ types: [
237
+ ],
238
+ "default": [
239
+ "none"
240
+ ],
241
+ keywords: [
242
+ "auto",
243
+ "none",
244
+ "dotted",
245
+ "dashed",
246
+ "solid",
247
+ "double",
248
+ "groove",
249
+ "ridge",
250
+ "inset",
251
+ "outset"
252
+ ]
253
+ },
254
+ "outline-width": {
255
+ types: [
256
+ "Length",
257
+ "Perc"
258
+ ],
259
+ "default": [
260
+ "medium"
261
+ ],
262
+ keywords: [
263
+ "thin",
264
+ "medium",
265
+ "thick"
266
+ ]
267
+ }
268
+ }
269
+ },
270
+ "outline-color": {
271
+ shorthand: "outline"
272
+ },
273
+ "outline-style": {
274
+ shorthand: "outline"
275
+ },
276
+ "outline-width": {
277
+ shorthand: "outline"
278
+ },
279
+ font: {
280
+ shorthand: "font",
281
+ pattern: "font-weight font-style font-size line-height font-stretch font-variant font-family",
282
+ keywords: [
283
+ "caption",
284
+ "icon",
285
+ "menu",
286
+ "message-box",
287
+ "small-caption",
288
+ "status-bar",
289
+ "-moz-window, ",
290
+ "-moz-document, ",
291
+ "-moz-desktop, ",
292
+ "-moz-info, ",
293
+ "-moz-dialog",
294
+ "-moz-button",
295
+ "-moz-pull-down-menu",
296
+ "-moz-list",
297
+ "-moz-field"
298
+ ],
299
+ "default": [
300
+ ],
301
+ properties: {
302
+ "font-weight": {
303
+ types: [
304
+ "Number"
305
+ ],
306
+ "default": [
307
+ "normal",
308
+ "400"
309
+ ],
310
+ keywords: [
311
+ "normal",
312
+ "bold",
313
+ "lighter",
314
+ "bolder"
315
+ ],
316
+ constraints: {
317
+ value: {
318
+ min: "1",
319
+ max: "1000"
320
+ }
321
+ },
322
+ mapping: {
323
+ thin: "100",
324
+ hairline: "100",
325
+ "extra light": "200",
326
+ "ultra light": "200",
327
+ light: "300",
328
+ normal: "400",
329
+ regular: "400",
330
+ medium: "500",
331
+ "semi bold": "600",
332
+ "demi bold": "600",
333
+ bold: "700",
334
+ "extra bold": "800",
335
+ "ultra bold": "800",
336
+ black: "900",
337
+ heavy: "900",
338
+ "extra black": "950",
339
+ "ultra black": "950"
340
+ }
341
+ },
342
+ "font-style": {
343
+ types: [
344
+ "Angle"
345
+ ],
346
+ "default": [
347
+ "normal"
348
+ ],
349
+ keywords: [
350
+ "normal",
351
+ "italic",
352
+ "oblique"
353
+ ]
354
+ },
355
+ "font-size": {
356
+ types: [
357
+ "Length",
358
+ "Perc"
359
+ ],
360
+ "default": [
361
+ ],
362
+ keywords: [
363
+ "xx-small",
364
+ "x-small",
365
+ "small",
366
+ "medium",
367
+ "large",
368
+ "x-large",
369
+ "xx-large",
370
+ "xxx-large",
371
+ "larger",
372
+ "smaller"
373
+ ],
374
+ required: true
375
+ },
376
+ "line-height": {
377
+ types: [
378
+ "Length",
379
+ "Perc",
380
+ "Number"
381
+ ],
382
+ "default": [
383
+ "normal"
384
+ ],
385
+ keywords: [
386
+ "normal"
387
+ ],
388
+ previous: "font-size",
389
+ prefix: {
390
+ typ: "Literal",
391
+ val: "/"
392
+ }
393
+ },
394
+ "font-stretch": {
395
+ types: [
396
+ "Perc"
397
+ ],
398
+ "default": [
399
+ "normal"
400
+ ],
401
+ keywords: [
402
+ "ultra-condensed",
403
+ "extra-condensed",
404
+ "condensed",
405
+ "semi-condensed",
406
+ "normal",
407
+ "semi-expanded",
408
+ "expanded",
409
+ "extra-expanded",
410
+ "ultra-expanded"
411
+ ],
412
+ mapping: {
413
+ "ultra-condensed": "50%",
414
+ "extra-condensed": "62.5%",
415
+ condensed: "75%",
416
+ "semi-condensed": "87.5%",
417
+ normal: "100%",
418
+ "semi-expanded": "112.5%",
419
+ expanded: "125%",
420
+ "extra-expanded": "150%",
421
+ "ultra-expanded": "200%"
422
+ }
423
+ },
424
+ "font-variant": {
425
+ types: [
426
+ ],
427
+ "default": [
428
+ "normal"
429
+ ],
430
+ keywords: [
431
+ "normal",
432
+ "none",
433
+ "common-ligatures",
434
+ "no-common-ligatures",
435
+ "discretionary-ligatures",
436
+ "no-discretionary-ligatures",
437
+ "historical-ligatures",
438
+ "no-historical-ligatures",
439
+ "contextual",
440
+ "no-contextual",
441
+ "historical-forms",
442
+ "small-caps",
443
+ "all-small-caps",
444
+ "petite-caps",
445
+ "all-petite-caps",
446
+ "unicase",
447
+ "titling-caps",
448
+ "ordinal",
449
+ "slashed-zero",
450
+ "lining-nums",
451
+ "oldstyle-nums",
452
+ "proportional-nums",
453
+ "tabular-nums",
454
+ "diagonal-fractions",
455
+ "stacked-fractions",
456
+ "ordinal",
457
+ "slashed-zero",
458
+ "ruby",
459
+ "jis78",
460
+ "jis83",
461
+ "jis90",
462
+ "jis04",
463
+ "simplified",
464
+ "traditional",
465
+ "full-width",
466
+ "proportional-width",
467
+ "ruby",
468
+ "sub",
469
+ "super",
470
+ "text",
471
+ "emoji",
472
+ "unicode"
473
+ ]
474
+ },
475
+ "font-family": {
476
+ types: [
477
+ "String",
478
+ "Iden"
479
+ ],
480
+ "default": [
481
+ ],
482
+ keywords: [
483
+ "serif",
484
+ "sans-serif",
485
+ "monospace",
486
+ "cursive",
487
+ "fantasy",
488
+ "system-ui",
489
+ "ui-serif",
490
+ "ui-sans-serif",
491
+ "ui-monospace",
492
+ "ui-rounded",
493
+ "math",
494
+ "emoji",
495
+ "fangsong"
496
+ ],
497
+ required: true,
498
+ multiple: true,
499
+ separator: {
500
+ typ: "Comma"
501
+ }
502
+ }
503
+ }
504
+ },
505
+ "font-weight": {
506
+ shorthand: "font"
507
+ },
508
+ "font-style": {
509
+ shorthand: "font"
510
+ },
511
+ "font-size": {
512
+ shorthand: "font"
513
+ },
514
+ "line-height": {
515
+ shorthand: "font"
516
+ },
517
+ "font-stretch": {
518
+ shorthand: "font"
519
+ },
520
+ "font-variant": {
521
+ shorthand: "font"
522
+ },
523
+ "font-family": {
524
+ shorthand: "font"
525
+ },
526
+ background: {
527
+ shorthand: "background",
528
+ pattern: "background-repeat background-color background-image background-attachment background-clip background-origin background-position background-size",
529
+ keywords: [
530
+ "none"
531
+ ],
532
+ "default": [
533
+ ],
534
+ multiple: true,
535
+ separator: {
536
+ typ: "Comma"
537
+ },
538
+ properties: {
539
+ "background-repeat": {
540
+ types: [
541
+ ],
542
+ "default": [
543
+ "repeat"
544
+ ],
545
+ multiple: true,
546
+ keywords: [
547
+ "repeat-x",
548
+ "repeat-y",
549
+ "repeat",
550
+ "space",
551
+ "round",
552
+ "no-repeat"
553
+ ],
554
+ mapping: {
555
+ "repeat no-repeat": "repeat-x",
556
+ "no-repeat repeat": "repeat-y",
557
+ "repeat repeat": "repeat",
558
+ "space space": "space",
559
+ "round round": "round",
560
+ "no-repeat no-repeat": "no-repeat"
561
+ }
562
+ },
563
+ "background-color": {
564
+ types: [
565
+ "Color"
566
+ ],
567
+ "default": [
568
+ "transparent"
569
+ ],
570
+ keywords: [
571
+ ]
572
+ },
573
+ "background-image": {
574
+ types: [
575
+ "UrlFunc"
576
+ ],
577
+ "default": [
578
+ "none"
579
+ ],
580
+ keywords: [
581
+ "none"
582
+ ]
583
+ },
584
+ "background-attachment": {
585
+ types: [
586
+ ],
587
+ "default": [
588
+ "scroll"
589
+ ],
590
+ keywords: [
591
+ "scroll",
592
+ "fixed",
593
+ "local"
594
+ ]
595
+ },
596
+ "background-clip": {
597
+ types: [
598
+ ],
599
+ "default": [
600
+ "border-box"
601
+ ],
602
+ keywords: [
603
+ "border-box",
604
+ "padding-box",
605
+ "content-box",
606
+ "text"
607
+ ]
608
+ },
609
+ "background-origin": {
610
+ types: [
611
+ ],
612
+ "default": [
613
+ "padding-box"
614
+ ],
615
+ keywords: [
616
+ "border-box",
617
+ "padding-box",
618
+ "content-box"
619
+ ]
620
+ },
621
+ "background-position": {
622
+ multiple: true,
623
+ types: [
624
+ "Perc",
625
+ "Length"
626
+ ],
627
+ "default": [
628
+ "0 0",
629
+ "top left",
630
+ "left top"
631
+ ],
632
+ keywords: [
633
+ "top",
634
+ "left",
635
+ "center",
636
+ "bottom",
637
+ "right"
638
+ ],
639
+ mapping: {
640
+ left: "0",
641
+ top: "0",
642
+ center: "50%",
643
+ bottom: "100%",
644
+ right: "100%"
645
+ },
646
+ constraints: {
647
+ mapping: {
648
+ max: 2
649
+ }
650
+ }
651
+ },
652
+ "background-size": {
653
+ multiple: true,
654
+ previous: "background-position",
655
+ prefix: {
656
+ typ: "Literal",
657
+ val: "/"
658
+ },
659
+ types: [
660
+ "Perc",
661
+ "Length"
662
+ ],
663
+ "default": [
664
+ "auto",
665
+ "auto auto"
666
+ ],
667
+ keywords: [
668
+ "auto",
669
+ "cover",
670
+ "contain"
671
+ ],
672
+ mapping: {
673
+ "auto auto": "auto"
674
+ }
675
+ }
676
+ }
677
+ },
678
+ "background-repeat": {
679
+ shorthand: "background"
680
+ },
681
+ "background-color": {
682
+ shorthand: "background"
683
+ },
684
+ "background-image": {
685
+ shorthand: "background"
686
+ },
687
+ "background-attachment": {
688
+ shorthand: "background"
689
+ },
690
+ "background-clip": {
691
+ shorthand: "background"
692
+ },
693
+ "background-origin": {
694
+ shorthand: "background"
695
+ },
696
+ "background-position": {
697
+ shorthand: "background"
698
+ },
699
+ "background-size": {
700
+ shorthand: "background"
701
+ }
702
+ };
703
+ var config = {
704
+ properties: properties,
705
+ map: map
706
+ };
707
+
708
+ export { config as default, map, properties };