aliascss 1.2.0 → 1.2.1

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.
Files changed (44) hide show
  1. package/aliascss.config.js +14 -137
  2. package/custom-compilers.js +15 -1
  3. package/dist/aliascss.js +1 -1
  4. package/lib/css-properties-all.js +2 -2
  5. package/lib/custom-css-compilers.d.ts +19 -0
  6. package/lib/custom-css-compilers.js +216 -0
  7. package/lib/prebuild-w3s.d.ts +4 -0
  8. package/lib/prebuild-w3s.js +4 -0
  9. package/lib/prebuild.d.ts +35 -2
  10. package/lib/prebuild.js +90 -55
  11. package/lib/returnStatement.js +13 -11
  12. package/lib/static/customStaticClassNames.js +173 -130
  13. package/package.json +3 -1
  14. package/ui-dev/app/index.bk +45 -0
  15. package/ui-dev/app/index.html +41 -0
  16. package/ui-dev/app/index.html.css +312 -0
  17. package/ui-dev/app/index.html.module.css +272 -0
  18. package/ui-dev/button.html +3 -2
  19. package/ui-dev/button.html.css +358 -0
  20. package/ui-dev/button.html.module.css +272 -0
  21. package/ui-dev/card-section-row-container-box-bk.html +154 -0
  22. package/ui-dev/card-section-row-container-box-bk.html.css +321 -0
  23. package/ui-dev/card-section-row-container-box-bk.html.module.css +272 -0
  24. package/ui-dev/card-section-row-container-box.html +40 -43
  25. package/ui-dev/card-section-row-container-box.html.css +346 -0
  26. package/ui-dev/card-section-row-container-box.html.module.css +272 -0
  27. package/ui-dev/index-preview-one.html +72 -0
  28. package/ui-dev/index-preview-one.html.css +293 -0
  29. package/ui-dev/index-preview-one.html.module.css +272 -0
  30. package/ui-dev/index-test.html +79 -0
  31. package/ui-dev/index-test.html.css +300 -0
  32. package/ui-dev/index-test.html.module.css +272 -0
  33. package/ui-dev/index.html +5 -2
  34. package/ui-dev/index.html.css +445 -0
  35. package/ui-dev/index.html.module.css +272 -0
  36. package/ui-dev/nav-red.html +1 -0
  37. package/ui-dev/nav-red.html.css +366 -0
  38. package/ui-dev/nav-red.html.module.css +272 -0
  39. package/ui-dev/navbar-demo.html +1 -0
  40. package/ui-dev/navbar-demo.html.css +368 -0
  41. package/ui-dev/navbar-demo.html.module.css +272 -0
  42. package/ui-dev/tooltip.html +1 -0
  43. package/ui-dev/tooltip.html.css +307 -0
  44. package/ui-dev/tooltip.html.module.css +272 -0
@@ -2581,7 +2581,7 @@ const cssProps = {
2581
2581
  compiler: length,
2582
2582
  values: ['reset:re', 'normal:nl']
2583
2583
  },
2584
- // ----------------SVG---
2584
+ // ----------------SVG-----------------------------
2585
2585
  // 'alignment-baseline':{
2586
2586
  // alias:'',
2587
2587
  // type:'',
@@ -2678,7 +2678,7 @@ const cssProps = {
2678
2678
  compiler: color,
2679
2679
  values: ['transparent:t'],
2680
2680
  },
2681
- // Custom
2681
+ // ---------------------------------CUSTOM
2682
2682
  // padding, margin
2683
2683
  'padding-x': {
2684
2684
  type: 'group',
@@ -0,0 +1,19 @@
1
+ type Property = {
2
+ alias?: string;
3
+ property?: string;
4
+ test?: RegExp;
5
+ type?: string;
6
+ values?: string[];
7
+ groups?: {
8
+ [key: string]: string;
9
+ };
10
+ compiler?: (a: string, b: {
11
+ [key: string]: {
12
+ [key: string]: string;
13
+ };
14
+ }) => any;
15
+ };
16
+ declare const cssCustomCompilers: {
17
+ [key: string]: Property;
18
+ };
19
+ export default cssCustomCompilers;
@@ -0,0 +1,216 @@
1
+ const cssCustomCompilers = {
2
+ // padding, margin
3
+ 'padding-x': {
4
+ type: 'group',
5
+ compiler: (y) => {
6
+ if (/^--[a-z]/.test(y)) {
7
+ return `padding-left:var(${y});padding-right:var(${y})`;
8
+ }
9
+ const value = y.split('-');
10
+ if (value.length === 3) {
11
+ return `padding-left:${value[1]};padding-right:${value[2]}`;
12
+ }
13
+ else if (value.length === 2) {
14
+ return `padding-left:${value[1]};padding-right:${value[1]}`;
15
+ }
16
+ // else{
17
+ // return `padding-left:${y};padding-right:${y}`;
18
+ // }
19
+ },
20
+ groups: {
21
+ 0: "padding-left:0;padding-right:0",
22
+ },
23
+ },
24
+ 'px': {
25
+ type: 'group',
26
+ compiler: (y) => {
27
+ if (/^--[a-z]/.test(y)) {
28
+ return `padding-left:var(${y});padding-right:var(${y})`;
29
+ }
30
+ const value = y.split('-');
31
+ if (value.length === 3) {
32
+ return `padding-left:${value[1]};padding-right:${value[2]}`;
33
+ }
34
+ else if (value.length === 2) {
35
+ return `padding-left:${value[1]};padding-right:${value[1]}`;
36
+ }
37
+ // else{
38
+ // return `padding-left:${y};padding-right:${y}`;
39
+ // }
40
+ },
41
+ groups: {
42
+ 0: "padding-left:0;padding-right:0",
43
+ },
44
+ },
45
+ 'padding-y': {
46
+ type: 'group',
47
+ compiler: (y) => {
48
+ if (/^--[a-z]/.test(y)) {
49
+ return `padding-top:var(${y});padding-bottom:var(${y})`;
50
+ }
51
+ const value = y.split('-');
52
+ if (value.length === 3) {
53
+ return `padding-top:${value[1]};padding-bottom:${value[2]}`;
54
+ }
55
+ else if (value.length === 2) {
56
+ return `padding-top:${value[1]};padding-bottom:${value[1]}`;
57
+ }
58
+ // else{
59
+ // return `padding-top:${y};padding-bottom:${y}`;
60
+ // }
61
+ },
62
+ groups: {
63
+ 0: "padding-top:0;padding-bottom:0",
64
+ },
65
+ },
66
+ 'py': {
67
+ type: 'group',
68
+ compiler: (y) => {
69
+ if (/^--[a-z]/.test(y)) {
70
+ return `padding-top:var(${y});padding-bottom:var(${y})`;
71
+ }
72
+ const value = y.split('-');
73
+ if (value.length === 3) {
74
+ return `padding-top:${value[1]};padding-bottom:${value[2]}`;
75
+ }
76
+ else if (value.length === 2) {
77
+ return `padding-top:${value[1]};padding-bottom:${value[1]}`;
78
+ }
79
+ // else{
80
+ // return `padding-top:${y};padding-bottom:${y}`;
81
+ // }
82
+ },
83
+ groups: {
84
+ 0: "padding-top:0;padding-bottom:0",
85
+ },
86
+ },
87
+ // Margin
88
+ 'margin-x': {
89
+ type: 'group',
90
+ compiler: (y) => {
91
+ if (/^--[a-z]/.test(y)) {
92
+ return `margin-left:var(${y});margin-right:var(${y})`;
93
+ }
94
+ const value = y.replace(/--/g, '-M').split('-');
95
+ if (value.length === 3) {
96
+ return `margin-left:${value[1].replace("M", '-')};margin-right:${value[2].replace("M", '-')}`;
97
+ }
98
+ else if (value.length === 2) {
99
+ return `margin-left:${value[1].replace("M", '-')};margin-right:${value[1].replace("M", '-')}`;
100
+ }
101
+ // else{
102
+ // return `margin-left:${y};margin-right:${y}`;
103
+ // }
104
+ },
105
+ groups: {
106
+ 0: "margin-left:0;margin-right:0",
107
+ },
108
+ },
109
+ 'mx': {
110
+ type: 'group',
111
+ compiler: (y) => {
112
+ if (/^--[a-z]/.test(y)) {
113
+ return `margin-left:var(${y});margin-right:var(${y})`;
114
+ }
115
+ const value = y.replace(/--/g, '-M').split('-');
116
+ if (value.length === 3) {
117
+ return `margin-left:${value[1].replace("M", '-')};margin-right:${value[2].replace("M", '-')}`;
118
+ }
119
+ else if (value.length === 2) {
120
+ return `margin-left:${value[1].replace("M", '-')};margin-right:${value[1].replace("M", '-')}`;
121
+ }
122
+ // else{
123
+ // return `margin-left:${y};margin-right:${y}`;
124
+ // }
125
+ },
126
+ groups: {
127
+ 0: "margin-left:0;margin-right:0",
128
+ },
129
+ },
130
+ 'margin-y': {
131
+ type: 'group',
132
+ compiler: (y) => {
133
+ if (/^--[a-z]/.test(y)) {
134
+ return `margin-top:var(${y});margin-bottom:var(${y})`;
135
+ }
136
+ const value = y.replace(/--/g, '-M').split('-');
137
+ if (value.length === 3) {
138
+ return `margin-top:${value[1].replace("M", '-')};margin-bottom:${value[2].replace("M", '-')}`;
139
+ }
140
+ else if (value.length === 2) {
141
+ return `margin-top:${value[1].replace("M", '-')};margin-bottom:${value[1].replace("M", '-')}`;
142
+ }
143
+ // else{
144
+ // return `margin-top:${y};margin-bottom:${y}`;
145
+ // }
146
+ },
147
+ groups: {
148
+ 0: "margin-top:0;margin-bottom:0",
149
+ },
150
+ },
151
+ 'my': {
152
+ type: 'group',
153
+ compiler: (y) => {
154
+ if (/^--[a-z]/.test(y)) {
155
+ return `margin-top:var(${y});margin-bottom:var(${y})`;
156
+ }
157
+ const value = y.replace(/--/g, '-M').split('-');
158
+ if (value.length === 3) {
159
+ return `margin-top:${value[1].replace("M", '-')};margin-bottom:${value[2].replace("M", '-')}`;
160
+ }
161
+ else if (value.length === 2) {
162
+ return `margin-top:${value[1].replace("M", '-')};margin-bottom:${value[1].replace("M", '-')}`;
163
+ }
164
+ // else{
165
+ // return `margin-top:${y};margin-bottom:${y}`;
166
+ // }
167
+ },
168
+ groups: {
169
+ 0: "margin-top:0;margin-bottom:0",
170
+ },
171
+ },
172
+ // ---------------------x-custom-compiler
173
+ 'x-square': {
174
+ type: 'group',
175
+ compiler: (value) => {
176
+ const v = value.replace(/^-([-]?[\d])/g, '$1');
177
+ return `width:calc(${v} + var(--x-square-grow,0px) - var(--x-square-shrink,0px)); flex-basis:calc(${v} + var(--x-square-grow,0px) - var(--x-square-shrink,0px)); flex-shrink:0;flex-grow:0;height:calc(${v} + var(--x-square-grow,0px) - var(--x-square-shrink,0px))`;
178
+ },
179
+ },
180
+ 'x-circle': {
181
+ type: 'group',
182
+ compiler: (value) => {
183
+ const v = value.replace(/^-([-]?[\d])/g, '$1');
184
+ return `width:calc(${v} + var(--x-circle-grow,0px) - var(--x-circle-shrink,0px)); height:calc(${v} + var(--x-circle-grow,0px) - var(--x-circle-shrink,0px)); border-radius:50%;`;
185
+ },
186
+ },
187
+ 'x-width': {
188
+ property: 'width',
189
+ compiler: (value) => {
190
+ if (/^--[a-zA-Z]/.test(value)) {
191
+ if (value.includes(':')) {
192
+ const val = value.slice(value.indexOf(':')).replace(':', '');
193
+ const cssVar = value.replace(val, '').replace(':', '');
194
+ return `calc(var(${cssVar},${val}) + var(--x-width-grow,0px) - var(--x-width-shrink,0px))`;
195
+ }
196
+ return `calc(var(${value}) + var(--x-width-grow,0px) - var(--x-width-shrink,0px))`;
197
+ }
198
+ return `calc(${value.replace(/^-([-]?[\d])/g, '$1')} + var(--x-width-grow,0px) - var(--x-width-shrink,0px))`;
199
+ },
200
+ },
201
+ 'x-height': {
202
+ property: 'height',
203
+ compiler: (value) => {
204
+ if (/^--[a-zA-Z]/.test(value)) {
205
+ if (value.includes(':')) {
206
+ const val = value.slice(value.indexOf(':')).replace(':', '');
207
+ const cssVar = value.replace(val, '').replace(':', '');
208
+ return `calc(var(${cssVar},${val}) + var(--x-height-grow,0px) - var(--x-height-shrink,0px))`;
209
+ }
210
+ return `calc(var(${value}) + var(--x-height-grow,0px) - var(--x-height-shrink,0px))`;
211
+ }
212
+ return `calc(${value.replace(/^-([-]?[\d])/g, '$1')} + var(--x-height-grow,0px) - var(--x-height-shrink,0px))`;
213
+ },
214
+ },
215
+ };
216
+ export default cssCustomCompilers;
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ 'x-iconbar': string;
3
+ };
4
+ export default _default;
@@ -0,0 +1,4 @@
1
+ export default {
2
+ // x-icon-bar
3
+ 'x-iconbar': 'w-50px oh br-5px [class~=x-iconbar-horizontal][df,w-100p] bg-lg-primary300-primary500 __[class~=x-iconbar-item][db,tac,p-12px,tn-all-0d3s,c-primary200,fs-22px,--h-bgc-primary600] __[class~=x-iconbar-item][flex-1] __[class~=x-iconbar-active]-bgc-primary800'
4
+ };
package/lib/prebuild.d.ts CHANGED
@@ -1,13 +1,46 @@
1
1
  declare const _default: {
2
+ 'x-screen-root': string;
2
3
  'x-section': string;
4
+ 'x-container': string;
3
5
  'x-row': string;
4
6
  'x-col': string;
5
- 'x-container': string;
6
7
  'x-box': string;
7
8
  'x-card': string;
8
9
  'x-divider-text': string;
9
10
  'x-divider': string;
10
11
  'x-button': string;
11
- 'x-tooltip': string;
12
+ 'x-arrow': string;
13
+ 'x-dollar': string;
14
+ 'x-cent': string;
15
+ 'x-pound': string;
16
+ 'x-currency': string;
17
+ 'x-yen': string;
18
+ 'x-latin-f': string;
19
+ 'x-armenian-dram': string;
20
+ 'x-afghani': string;
21
+ 'x-bengali-mark': string;
22
+ 'x-bengali-sign': string;
23
+ 'x-gujarati-sign': string;
24
+ 'x-tamil-sign': string;
25
+ 'x-thai-baht': string;
26
+ 'x-khmer-riel': string;
27
+ 'x-rial': string;
28
+ 'x-wancho-ngun': string;
29
+ 'x-euro-currency': string;
30
+ 'x-euro': string;
31
+ 'x-franc': string;
32
+ 'x-lira': string;
33
+ 'x-naira': string;
34
+ 'x-rupee': string;
35
+ 'x-peso': string;
36
+ 'x-shekel': string;
37
+ 'x-won': string;
38
+ 'x-tugrik': string;
39
+ 'x-drachma': string;
40
+ 'x-kip': string;
41
+ 'x-guarani': string;
42
+ 'x-hryvnia': string;
43
+ 'x-cedi': string;
44
+ 'x-menu': string;
12
45
  };
13
46
  export default _default;
package/lib/prebuild.js CHANGED
@@ -1,68 +1,103 @@
1
1
  export default {
2
- 'x-section': `p--section-padding:40px bgc--section-bg:transparent [class~=section-spacious]--section-padding:80px
3
- [class~=section-colored]--section-bg:f0f4f8`,
4
- 'x-row': `df fww g-16px m--8px __all-margin-8px __all-flex-1 [class~=row-no-wrap]-fwn [class~=row-center]-jcc`,
5
- 'x-col': `df fww g-16px m--8px __all-margin-8px __all-flex-1 [class~=col-no-wrap]-fwn [class~=col-center]-jcc
6
- [class~=col-1][flex-0-0-8.33%]
7
- [class~=col-2][flex-0-0-16.66%]
8
- [class~=col-3][flex-0-0-25%]
9
- [class~=col-4][flex-0-0-33.33%]
10
- [class~=col-5][flex-0-0-41.66%]
11
- [class~=col-6][flex-0-0-50%]
12
- [class~=col-7][flex-0-0-58.33%]
13
- [class~=col-8][flex-0-0-66.66%]
14
- [class~=col-9][flex-0-0-75%]
15
- [class~=col-10][flex-0-0-83.33%]
16
- [class~=col-full][flex-grow:1]`,
17
- 'x-container': `width-100p xw--container-width:1200px margin-0-auto p--container-padding:16px
18
- [class~=container-fluid][--container-width:100%]
19
- [class~=container-narrow][--container-width:800px]`,
20
- 'x-box': `bgc--box-bg:ffffff p--box-padding:16px br--box-border-radius:8px border--box-border:1px-solid-e0e0e0
21
- [class~=box-shadow]-bxs-0px-2px-8px-0000000000d1`,
22
- 'x-card': `bgc--card-bg:ffffff padding--card-padding:24px br--card-border-radius:12px bxs--card-shadow:0px-4px-12px-0000000000d1
23
- --hover-transform-translateY--4px --hover-bxs-0-8px-24px-0000000000d15
24
- transition-transform-0.3s-ease__box-shadow-0.3s-ease
25
- [class~=card-dark][--card-bg:1a1a1a,--card-shadow:0px-4px-12px-0000000000d3,color--card-color:ffffff]`,
2
+ // x-screen
3
+ 'x-screen-root': `oh pr
4
+ __[class~=x-screen][tdu--x-screen-transition-duration:0d35s,pa,ttf--x-screen-transition-timing-function:eio,transition-property-transform_height_width,transform-translateY-0px]
5
+ __[class~=x-screen][w--x-screen-width:100p,h--x-screen-height:100p]
6
+ __[class~=x-screen][class~=x-screen-active]-transform-translate-0
7
+ __[class~=x-screen][x-screen-active]--x-screen-offset:0p
8
+ __[class~=x-screen-up][zi-2,t-0,l-0,transform-translateY--t-up,--t-up:calc(0%-var(--x-screen-offset,100%))]
9
+ __[class~=x-screen-down][zi-3,btm-0px,l-0,transform-translateY--t-down,--t-down:calc(var(--x-screen-offset,100%)-0%)]
10
+ __[class~=x-screen-left][zi-4,transform-translateX--t-left,--t-left:calc(0%-var(--x-screen-offset,100%))]
11
+ __[class~=x-screen-right][zi-5,t0,r0,transform-translateX--t-right,--t-right:calc(var(--x-screen-offset,100%)-0%)]`,
12
+ // Box-and-button
13
+ 'x-section': `w--x-section-width:100p p--x-section-padding:20px [class~=x-section-spacious]--x-section-padding:80px height--x-section-height:auto`,
14
+ 'x-container': `width-100p xw--x-container-width:1200px margin-0-auto p--x-container-padding:16px
15
+ [class~=x-container-fluid][--x-container-width:100%]
16
+ [class~=x-container-narrow][--x-container-width:800px]`,
17
+ 'x-row': `df fww g-16px m--8px __all-margin-8px __all-flex-1 [class~=x-row-no-wrap]-fwn [class~=x-row-center]-jcc`,
18
+ 'x-col': `df fww g-16px m--8px __all-margin-8px __all-flex-1 [class~=x-col-no-wrap]-fwn [class~=x-col-center]-jcc
19
+ [class~=x-col-full][flex-grow:1]`,
20
+ 'x-box': `bgc--x-box-bg:ffffff p--x-box-padding:16px br--x-box-border-radius:8px border--x-box-border:1px-solid-e0e0e0
21
+ [class~=x-box-shadow]-bxs-0px-2px-8px-0000000000d1`,
22
+ 'x-card': `bgc--x-card-bg:ffffff padding--x-card-padding:24px br--x-card-border-radius:12px bxs--x-card-shadow:0px-4px-12px-0000000000d1
23
+ [class~=x-card-interactive][--hover-transform-translateY--4px,--hover-bxs-0-8px-24px-0000000000d15]
24
+ transition-transform-0.3s-ease__box-shadow-0.3s-ease
25
+ [class~=x-card-dark][--x-card-bg:1a1a1a,--x-card-shadow:0px-4px-12px-0000000000d3,color--x-card-color:ffffff]`,
26
26
  'x-divider-text': `[df,aic,g12px]
27
- --before[df,cont,bgc--divider-color:gray,flex-1,h--divider-width:1px]
28
- --after[df,cont,bgc--divider-color:gray,flex-1,h--divider-width:1px]
27
+ --before[df,cont,bgc--x-divider-color:gray,flex-1,h--x-divider-width:1px]
28
+ --after[df,cont,bgc--x-divider-color:gray,flex-1,h--x-divider-width:1px]
29
29
  `,
30
- 'x-divider': `border-top-width--divider-width:1px
31
- border-top-color--divider-color:gray
32
- border-top-style--divider-style:solid bsbb db`,
30
+ 'x-divider': `border-top-width--x-divider-width:1px
31
+ border-top-color--x-divider-color:gray
32
+ border-top-style--x-divider-style:solid bsbb db`,
33
33
  'x-button': `dib aic jcc cp tdn tn-all-0d3s
34
- c--button-color:ffffff
35
- p--button-padding:8px-16px
36
- fs--button-font-size:16px
37
- br--button-border-radius:4px
38
- b--button-border:2px-solid--border-color
39
- --border-color:transparent
40
- bg--button-bg:gray-600
34
+ c--x-button-color:ffffff
35
+ p--x-button-padding:8px-16px
36
+ fs--x-button-font-size:16px
37
+ br--x-button-border-radius:4px
38
+ b--x-button-border:2px-solid--border-color
39
+ --x-button-border-color:transparent
40
+ bg--x-button-bg:gray-600
41
41
  --hover-opacity-0d9
42
42
  --hover-transform-translateY--1px
43
43
  --active-transform-translateY-0px
44
44
 
45
- [class~=button-primary][--button-bg:primary600,--button-soft-bg:primary100,--button-color:ffffff]
46
- [class~=button-success][--button-bg:success600,--button-soft-bg:success100,--button-color:ffffff]
47
- [class~=button-error][--button-bg:error600,--button-soft-bg:error100,--button-color:ffffff]
48
- [class~=button-warning][--button-bg:warning600,--button-soft-bg:warning100,--button-color:ffffff]
49
-
45
+ [class~=x-button-primary][--x-button-bg:primary600,--x-button-soft-bg:primary100,--x-button-color:ffffff]
46
+ [class~=x-button-success][--x-button-bg:success600,--x-button-soft-bg:success100,--x-button-color:ffffff]
47
+ [class~=x-button-error][--x-button-bg:error600,--x-button-soft-bg:error100,--x-button-color:ffffff]
48
+ [class~=x-button-warning][--x-button-bg:warning600,--x-button-soft-bg:warning100,--x-button-color:ffffff]
49
+
50
50
  [disabled]-bg-cccccc
51
51
  [disabled]-color-666666
52
52
  [disabled]-opacity-0.7
53
53
  [disabled]-cursor-not-allowed
54
-
55
- [class~=button-small][--button-padding:6px-12px,--button-font-size:14px]
56
- [class~=button-large][--button-padding:12px-24px,--button-font-size:18px]
57
- [class~=button-outline][bg-transparent,--button-color:--button-bg:gray-600,--border-color:--button-color,--hover-bg--button-color:gray-600,--hover-color-ffffff]
58
- [class~=button-text][bgc-transparent,--button-border:none,--hover-bg--button-soft-bg:gray100,--button-color:--button-bg:gray600,--button-padding:4px-8px]`,
59
- 'x-tooltip': `df pr p-8px-12px bgc--tooltip-color b-1px-s-gray100 shadow-lg text-xs c-fff br-8px fw5 dif jcc aic --tooltip-color:gray600
60
- --bf-pa --bf-cont --bf-w-12px --bf-h-12px --bf-bgc-inherit --bf-shadow-lg --bf-tf-r-45deg
61
- --bf-l--4px
62
- [class~=tooltip-up]--bf-t--4px
63
- [class~=tooltip-up]--bf-l--calc-midpoint
64
- [class~=tooltip-left]--bf-r--4px
65
- [class~=tooltip-left]--bf-l-initial
66
- [class~=tooltip-down]--bf-btm--4px
67
- [class~=tooltip-down]--bf-l--calc-midpoint --calc-midpoint:calc(50%-6px)`,
54
+
55
+ [class~=x-button-sm][--x-button-padding:6px-12px,--x-button-font-size:14px]
56
+ [class~=x-button-lg][--x-button-padding:12px-24px,--x-button-font-size:18px]
57
+ [class~=x-button-outline][bg-transparent,--x-button-color:--x-button-bg:gray-600,--border-color:--x-button-color,--hover-bg--x-button-color:gray-600,--hover-color-ffffff]
58
+ [class~=x-button-text][bgc-transparent,--x-button-border:none,--hover-bg--x-button-soft-bg:gray100,--x-button-color:--x-button-bg:gray600,--x-button-padding:4px-8px]`,
59
+ 'x-arrow': `[bss,bc--x-arrow-color:black,bw-0px-3px-3px-0,dib,p-3px] [class~=x-arrow-left]-tf-r-135deg [class~=x-arrow-up]-tf-r--135deg [class~=x-arrow-right]-tf-r--45deg [class~=x-arrow-down]-tf-r-45deg`,
60
+ // CSS entities
61
+ 'x-dollar': '-—af-cont_0024',
62
+ 'x-cent': '-—af-cont_00A2',
63
+ 'x-pound': '-—af-cont_00A3',
64
+ 'x-currency': '-—af-cont_00A4',
65
+ 'x-yen': '-—af-cont_00A5',
66
+ 'x-latin-f': '-—af-cont_0192', /* Florin */
67
+ 'x-armenian-dram': '-—af-cont_058F',
68
+ 'x-afghani': '-—af-cont_060B',
69
+ 'x-bengali-mark': '-—af-cont_09F2',
70
+ 'x-bengali-sign': '-—af-cont_09F3',
71
+ 'x-gujarati-sign': '-—af-cont_0AF1',
72
+ 'x-tamil-sign': '-—af-cont_0BF9',
73
+ 'x-thai-baht': '-—af-cont_0E3F',
74
+ 'x-khmer-riel': '-—af-cont_17DB',
75
+ 'x-rial': '-—af-cont_FDFC',
76
+ 'x-wancho-ngun': '-—af-cont_1E2FF',
77
+ 'x-euro-currency': '-—af-cont_20A0', /* Historical ECU */
78
+ 'x-euro': '-—af-cont_20AC',
79
+ 'x-franc': '-—af-cont_20A3',
80
+ 'x-lira': '-—af-cont_20A4',
81
+ 'x-naira': '-—af-cont_20A6',
82
+ 'x-rupee': '-—af-cont_20B9',
83
+ 'x-peso': '-—af-cont_20B1',
84
+ 'x-shekel': '-—af-cont_20AA',
85
+ 'x-won': '-—af-cont_20A9',
86
+ 'x-tugrik': '-—af-cont_20AE',
87
+ 'x-drachma': '-—af-cont_20AF',
88
+ 'x-kip': '-—af-cont_20AD',
89
+ 'x-guarani': '-—af-cont_20B2',
90
+ 'x-hryvnia': '-—af-cont_20B4',
91
+ 'x-cedi': '-—af-cont_20B5',
92
+ // --
93
+ 'x-menu': `pr x-menu-rounded cp w-35px h-30px bg-lg-transparent_0px_12d5px-currentColor_12d5px_17d5px-transparent_17d5px_35px
94
+ tn-all-0d5s [class~=x-menu-open]-bg-none
95
+ [x-menu-open]-bg-none
96
+ --af[pa,t0,h-5px,w-35px,bgc-currentColor,cont]
97
+ [class~=x-menu-rounded]--af-br-5px
98
+ --bf[btm-0,pa,h-5px,w-35px,bgc-currentColor,cont,]
99
+ [class~=x-menu-rounded]--bf-br-5px tn-all-0d5s
100
+ --af-tn-all-0d5s --bf-tn-all-0d5s
101
+ [class~=x-menu-open][--af-tf-r-45deg,--af-t-50p,--bf-tf-r--45deg,--bf-t50p,--af-tn-all-0d5s,--bf-tn-all-0d5s]
102
+ [x-menu-open][--af-tf-r-45deg,--af-t-50p,--bf-tf-r--45deg,--bf-t50p,--af-tn-all-0d5s,--bf-tn-all-0d5s]`,
68
103
  };
@@ -11,6 +11,8 @@ import cssProps from "./css-properties-all.js";
11
11
  import { staticClassNamesAlias } from "./static/staticClassNamesAlias.js";
12
12
  import postcss from "postcss";
13
13
  import { splitByCommaOutsideParens } from "./utils/helper.js";
14
+ import cssCustomCompilers from "./custom-css-compilers.js";
15
+ // import customGroups from './prebuild.js';
14
16
  const [staticClassNamesWithAlias, cssPropsWithAlias] = createCompilerObj(cssProps, config.globalValues);
15
17
  export const compiler = {
16
18
  // cache will cache propertyAndValue
@@ -19,7 +21,7 @@ export const compiler = {
19
21
  mediaSelector: Object.assign({}, media.target),
20
22
  mediaTest: null,
21
23
  staticClassNames: Object.assign(Object.assign({}, staticClassNamesAlias), staticClassNamesWithAlias),
22
- cssProps: Object.assign({}, cssPropsWithAlias),
24
+ cssProps: Object.assign(Object.assign({}, cssPropsWithAlias), cssCustomCompilers),
23
25
  prefix: null,
24
26
  rawCSS: null,
25
27
  customGroupStatement: null,
@@ -102,16 +104,16 @@ export const compiler = {
102
104
  const pnv = workingClassName.replace(/^-([a-zA-Z])/, '$1');
103
105
  let result = '';
104
106
  // x-class
105
- if (/^(x-width|x-height)/.test(pnv)) {
106
- const extract = getPropertyAndValue(pnv.replace('x-', ''), this.cssProps, this.staticClassNames, this.custom, extractProperty);
107
- if (typeof extract === 'string') {
108
- const [p, v] = extract.split(':');
109
- if (p && v) {
110
- result = `${p}:calc(${v} + var(--${p}-grow) - var(--${p}-shrink));--${p}:${v};--${p}-grow:0px;--${p}-shrink:0px`;
111
- }
112
- }
113
- }
114
- else if (this.cache.propertyAndValue.hasOwnProperty(pnv)) {
107
+ // if(/^(x-width|x-height)/.test(pnv)){
108
+ // const extract=getPropertyAndValue(pnv.replace('x-',''), this.cssProps, this.staticClassNames, this.custom,extractProperty);
109
+ // if(typeof extract === 'string'){
110
+ // const [p,v]=extract.split(':');
111
+ // if(p && v){
112
+ // result=`${p}:calc(${v} + var(--x-${p}-grow,0px) - var(--x-${p}-shrink,0px));`
113
+ // }
114
+ // }
115
+ // }else
116
+ if (this.cache.propertyAndValue.hasOwnProperty(pnv)) {
115
117
  result = this.cache.propertyAndValue[pnv];
116
118
  }
117
119
  else {