@thi.ng/meta-css 0.1.2 → 0.2.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/specs/grid.json CHANGED
@@ -1,41 +1,39 @@
1
1
  {
2
2
  "tables": {
3
- "cols-rows": {
4
- "1": "1fr",
5
- "2": "1fr 1fr",
6
- "3": "1fr 1fr 1fr",
7
- "4": "repeat(4,1fr)",
8
- "5": "repeat(5,1fr)",
9
- "6": "repeat(6,1fr)",
10
- "7": "repeat(7,1fr)",
11
- "8": "repeat(8,1fr)",
12
- "9": "repeat(9,1fr)",
13
- "10": "repeat(10,1fr)"
14
- }
3
+ "cols-rows": [
4
+ "1fr",
5
+ "1fr 1fr",
6
+ "1fr 1fr 1fr",
7
+ "repeat(4,1fr)",
8
+ "repeat(5,1fr)",
9
+ "repeat(6,1fr)",
10
+ "repeat(7,1fr)",
11
+ "repeat(8,1fr)",
12
+ "repeat(9,1fr)",
13
+ "repeat(10,1fr)"
14
+ ]
15
15
  },
16
16
  "specs": [
17
17
  {
18
- "comment": "grid column layout",
19
- "prefix": "gc",
20
- "index": "v",
21
- "prop": "grid-template-columns",
22
- "items": "cols-rows",
23
- "unit": "cols-rows"
18
+ "user": "grid layout",
19
+ "name": "gc<k>",
20
+ "key": "i1",
21
+ "props": "grid-template-columns",
22
+ "values": "cols-rows"
24
23
  },
25
24
  {
26
- "comment": "grid row layout",
27
- "prefix": "gr",
28
- "index": "v",
29
- "prop": "grid-template-rows",
30
- "items": "cols-rows",
31
- "unit": "cols-rows"
25
+ "user": "grid layout",
26
+ "name": "gr<k>",
27
+ "key": "i1",
28
+ "props": "grid-template-rows",
29
+ "values": "cols-rows"
32
30
  },
33
31
  {
34
- "comment": "grid gaps",
35
- "prefix": "gap",
36
- "index": "i",
37
- "prop": "gap",
38
- "items": [0, 0.125, 0.25, 0.5, 1, 2]
32
+ "user": "grid layout",
33
+ "name": "gap<k>",
34
+ "props": "gap",
35
+ "values": [0, 0.125, 0.25, 0.5, 1, 2],
36
+ "unit": "rem"
39
37
  }
40
38
  ]
41
39
  }
package/specs/lists.json CHANGED
@@ -1,11 +1,10 @@
1
1
  {
2
2
  "specs": [
3
3
  {
4
- "prefix": "",
5
- "index": "v",
6
- "prop": "list-style",
7
- "items": { "list": "none" },
8
- "unit": null
4
+ "user": "lists",
5
+ "name": "<k>",
6
+ "props": "list-style",
7
+ "values": { "list": "none" }
9
8
  }
10
9
  ]
11
10
  }
@@ -4,20 +4,29 @@
4
4
  },
5
5
  "specs": [
6
6
  {
7
- "comment": "paddings",
8
- "prefix": "p",
9
- "index": "i",
10
- "prop": "padding",
11
- "items": "margins",
12
- "var": "all"
7
+ "user": "padding",
8
+ "name": "p<vid><k>",
9
+ "props": "padding<var>",
10
+ "values": "margins",
11
+ "unit": "rem",
12
+ "var": ["a", "h", "v", "t", "r", "b", "l"]
13
13
  },
14
14
  {
15
- "comment": "margins",
16
- "prefix": "m",
17
- "index": "i",
18
- "prop": "margin",
19
- "items": "margins",
20
- "var": "all"
15
+ "user": "margin",
16
+ "name": "m<vid><k>",
17
+ "props": "margin<var>",
18
+ "values": "margins",
19
+ "unit": "rem",
20
+ "var": ["a", "h", "v", "t", "r", "b", "l"]
21
+ },
22
+ {
23
+ "user": "margin",
24
+ "name": "<k>",
25
+ "props": {
26
+ "margin-left": "<v>",
27
+ "margin-right": "<v>"
28
+ },
29
+ "values": { "center": "auto" }
21
30
  }
22
31
  ]
23
32
  }
@@ -4,25 +4,11 @@
4
4
  },
5
5
  "specs": [
6
6
  {
7
- "prefix": "overflow",
8
- "index": "v",
9
- "def": { "overflow": "*" },
10
- "items": "overflow",
11
- "unit": null
12
- },
13
- {
14
- "prefix": "overflow-x-",
15
- "index": "v",
16
- "def": { "overflow-x": "*" },
17
- "items": "overflow",
18
- "unit": null
19
- },
20
- {
21
- "prefix": "overflow-y-",
22
- "index": "v",
23
- "def": { "overflow-y": "*" },
24
- "items": "overflow",
25
- "unit": null
7
+ "user": "overflow",
8
+ "name": "overflow<var>-<v>",
9
+ "props": { "overflow<var>": "<v>" },
10
+ "values": "overflow",
11
+ "var": ["", "x", "y"]
26
12
  }
27
13
  ]
28
14
  }
@@ -4,28 +4,24 @@
4
4
  },
5
5
  "specs": [
6
6
  {
7
- "prefix": "",
8
- "index": "v",
9
- "prop": "position",
10
- "items": ["absolute", "relative", "fixed"],
11
- "unit": null
7
+ "user": "positions",
8
+ "name": "<v>",
9
+ "props": "position",
10
+ "values": ["absolute", "relative", "fixed", "sticky"]
12
11
  },
13
12
  {
14
- "comment": "positions",
15
- "prefix": "*-",
16
- "index": "v",
17
- "def": {
18
- "*": "*"
19
- },
20
- "items": "pos",
21
- "var": "TRBL"
13
+ "user": "positions",
14
+ "name": "<var>-<v>",
15
+ "props": "<var>",
16
+ "values": "pos",
17
+ "unit": "rem",
18
+ "var": ["top", "right", "bottom", "left"]
22
19
  },
23
20
  {
24
- "prefix": "z-",
25
- "index": "v",
26
- "prop": "z-index",
27
- "items": [0, 1, 2, 3, 4, 5, 999, 9999],
28
- "unit": null
21
+ "user": "z-indices",
22
+ "name": "z-<v>",
23
+ "props": "z-index",
24
+ "values": [0, 1, 2, 3, 4, 5, 999, 9999]
29
25
  }
30
26
  ]
31
27
  }
@@ -0,0 +1,26 @@
1
+ {
2
+ "tables": {
3
+ "shadows": [
4
+ "0 0 2px 0px #0003",
5
+ "0 0 4px #0003",
6
+ "0 0 4px 1px #0003",
7
+ "0 0 8px 2px #0003"
8
+ ]
9
+ },
10
+ "specs": [
11
+ {
12
+ "user": "shadow",
13
+ "name": "shadow-<k>",
14
+ "key": "i1",
15
+ "props": "box-shadow",
16
+ "values": "shadows"
17
+ },
18
+ {
19
+ "user": "shadow",
20
+ "name": "i-shadow-<k>",
21
+ "key": "i1",
22
+ "props": { "box-shadow": "<v> inset" },
23
+ "values": "shadows"
24
+ }
25
+ ]
26
+ }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "tables": {
3
- "font-families": {
3
+ "families": {
4
4
  "system": "-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'",
5
5
  "sans-serif": "'Helvetica Neue', Helvetica, Arial, sans-serif",
6
6
  "serif": "Georgia, 'Times New Roman', Times, serif",
@@ -10,67 +10,65 @@
10
10
  },
11
11
  "specs": [
12
12
  {
13
- "comment": "font families",
14
- "prefix": "",
15
- "index": "v",
16
- "prop": "font-family",
17
- "items": "font-families",
18
- "unit": "font-families"
13
+ "user": "font families",
14
+ "name": "<k>",
15
+ "props": "font-family",
16
+ "values": "families"
19
17
  },
20
18
  {
21
- "comment": "font scale",
22
- "prefix": "f",
23
- "index": "i1",
24
- "prop": "font-size",
25
- "items": [3, 2.25, 1.5, 1.25, 1, 0.875, 0.75]
19
+ "user": "font sizes",
20
+ "name": "f<k>",
21
+ "key": "i1",
22
+ "props": "font-size",
23
+ "values": [3, 2.25, 1.5, 1.25, 1, 0.875, 0.75],
24
+ "unit": "rem"
26
25
  },
27
26
  {
28
- "comment": "named font scales",
29
- "prefix": "f-",
30
- "index": "v",
31
- "prop": "font-size",
32
- "items": {
27
+ "user": "font sizes",
28
+ "name": "f-<k>",
29
+ "props": "font-size",
30
+ "values": {
33
31
  "title": "6rem",
34
32
  "subtitle": "5rem"
35
- },
36
- "unit": null
33
+ }
37
34
  },
38
35
  {
39
- "comment": "font weights",
40
- "prefix": "fw",
41
- "index": "v",
42
- "def": { "font-weight": "*" },
43
- "items": "100s",
44
- "unit": null
36
+ "user": "font weights",
37
+ "name": "fw<v>",
38
+ "props": "font-weight",
39
+ "values": "100s"
45
40
  },
46
41
  {
47
- "comment": "named font weights",
48
- "prefix": "",
49
- "index": "v",
50
- "prop": "font-weight",
51
- "items": {
42
+ "user": "font weights",
43
+ "name": "<k>",
44
+ "props": "font-weight",
45
+ "values": {
52
46
  "normal": 400,
53
47
  "b": 700
54
- },
55
- "unit": null
48
+ }
49
+ },
50
+ {
51
+ "user": "font variants",
52
+ "name": "<k>",
53
+ "key": "v",
54
+ "props": "font-variant",
55
+ "values": ["small-caps"]
56
56
  },
57
57
  {
58
- "comment": "text decorations",
59
- "prefix": "",
60
- "index": "v",
61
- "prop": "text-decoration",
62
- "items": {
58
+ "user": "text decorations",
59
+ "name": "<k>",
60
+ "props": "text-decoration",
61
+ "values": {
63
62
  "underline": "underline",
64
63
  "no-underline": "none",
65
64
  "strike": "line-through"
66
- },
67
- "unit": null
65
+ }
68
66
  },
69
67
  {
70
- "prefix": "tt",
71
- "index": "v",
72
- "prop": "text-transform",
73
- "items": {
68
+ "user": "text transforms",
69
+ "name": "tt<k>",
70
+ "props": "text-transform",
71
+ "values": {
74
72
  "c": "capitalize",
75
73
  "l": "lowercase",
76
74
  "i": "initial",
@@ -78,50 +76,59 @@
78
76
  "u": "uppercase",
79
77
  "fw": "full-width",
80
78
  "fsk": "full-size-kana"
81
- },
82
- "unit": null
79
+ }
83
80
  },
84
81
  {
85
- "prefix": "t",
86
- "index": "v",
87
- "prop": "text-align",
88
- "items": {
82
+ "user": "text align",
83
+ "name": "t<k>",
84
+ "props": "text-align",
85
+ "values": {
89
86
  "c": "center",
90
87
  "j": "justify",
91
88
  "l": "left",
92
89
  "r": "right"
93
- },
94
- "unit": null
90
+ }
95
91
  },
96
92
  {
97
- "prefix": "v-",
98
- "index": "v",
99
- "prop": "vertical-align",
100
- "items": {
93
+ "user": "vertical align",
94
+ "name": "v-<k>",
95
+ "props": "vertical-align",
96
+ "values": {
101
97
  "btm": "bottom",
102
98
  "mid": "middle",
103
99
  "top": "top"
104
- },
105
- "unit": null
100
+ }
106
101
  },
107
102
  {
108
- "prefix": "lh-",
109
- "index": "v",
110
- "prop": "line-height",
111
- "items": {
103
+ "user": "line heights",
104
+ "name": "lh-<k>",
105
+ "props": "line-height",
106
+ "values": {
112
107
  "solid": 1,
113
108
  "title": 1.25,
114
109
  "copy": 1.5,
115
110
  "double": 2
116
- },
117
- "unit": null
111
+ }
118
112
  },
119
113
  {
120
- "prefix": "ws-",
121
- "index": "v",
122
- "prop": "white-space",
123
- "items": ["normal", "nowrap", "pre"],
124
- "unit": null
114
+ "user": "whitespace",
115
+ "name": "ws-<k>",
116
+ "props": "white-space",
117
+ "values": ["normal", "nowrap", "pre"]
118
+ },
119
+ {
120
+ "user": "letter spacing",
121
+ "name": "ls-<k>",
122
+ "props": "letter-spacing",
123
+ "values": {
124
+ "-2": -0.05,
125
+ "-1": -0.025,
126
+ "0": 0,
127
+ "1": 0.05,
128
+ "2": 0.1,
129
+ "3": 0.2
130
+ },
131
+ "unit": "em"
125
132
  }
126
133
  ]
127
134
  }