tailwind-to-style 3.3.0 → 4.0.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.
Files changed (51) hide show
  1. package/README.md +208 -1118
  2. package/dist/animations/index.cjs +9391 -0
  3. package/dist/animations/index.d.ts +58 -0
  4. package/dist/animations/index.esm.js +9385 -0
  5. package/dist/animations/index.esm.js.map +1 -0
  6. package/dist/className/index.cjs +2241 -4181
  7. package/dist/className/index.esm.js +2241 -4181
  8. package/dist/className/index.esm.js.map +1 -1
  9. package/dist/core/tws.cjs +136 -114
  10. package/dist/core/tws.cjs.map +1 -0
  11. package/dist/core/tws.esm.js +136 -114
  12. package/dist/core/tws.esm.js.map +1 -1
  13. package/dist/core/twsx.cjs +1971 -3970
  14. package/dist/core/twsx.esm.js +1971 -3970
  15. package/dist/core/twsx.esm.js.map +1 -1
  16. package/dist/core/twsxVariants.cjs +1997 -3986
  17. package/dist/core/twsxVariants.esm.js +1997 -3986
  18. package/dist/core/twsxVariants.esm.js.map +1 -1
  19. package/dist/cx.cjs +2 -2
  20. package/dist/cx.cjs.map +1 -0
  21. package/dist/cx.esm.js +2 -2
  22. package/dist/index.cjs +5253 -9252
  23. package/dist/index.cjs.map +1 -0
  24. package/dist/index.d.ts +4 -1
  25. package/dist/index.esm.js +5251 -9201
  26. package/dist/index.esm.js.map +1 -1
  27. package/dist/index.min.js +1 -1
  28. package/dist/index.min.js.map +1 -1
  29. package/dist/react/index.cjs +10177 -0
  30. package/dist/react/index.cjs.map +1 -0
  31. package/dist/react/index.d.ts +69 -0
  32. package/dist/react/index.esm.js +10173 -0
  33. package/dist/react/index.esm.js.map +1 -0
  34. package/dist/styled/index.cjs +9094 -0
  35. package/dist/styled/index.cjs.map +1 -0
  36. package/dist/styled/index.d.ts +17 -0
  37. package/dist/styled/index.esm.js +9087 -0
  38. package/dist/styled/index.esm.js.map +1 -0
  39. package/dist/tokens/index.cjs +359 -0
  40. package/dist/tokens/index.d.ts +33 -0
  41. package/dist/tokens/index.esm.js +355 -0
  42. package/dist/tokens/index.esm.js.map +1 -0
  43. package/dist/utils/index.cjs +219 -270
  44. package/dist/utils/index.esm.js +219 -270
  45. package/dist/utils/index.esm.js.map +1 -1
  46. package/package.json +33 -24
  47. package/types/animations/index.d.ts +58 -0
  48. package/types/index.d.ts +4 -1
  49. package/types/react/index.d.ts +69 -0
  50. package/types/tokens/index.d.ts +33 -0
  51. package/types/v4.d.ts +191 -0
@@ -5,16 +5,102 @@
5
5
  * @author Bigetion
6
6
  * @license MIT
7
7
  */
8
+ function _arrayLikeToArray(r, a) {
9
+ (null == a || a > r.length) && (a = r.length);
10
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
11
+ return n;
12
+ }
13
+ function _arrayWithHoles(r) {
14
+ if (Array.isArray(r)) return r;
15
+ }
16
+ function _defineProperty(e, r, t) {
17
+ return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
18
+ value: t,
19
+ enumerable: true,
20
+ configurable: true,
21
+ writable: true
22
+ }) : e[r] = t, e;
23
+ }
24
+ function _iterableToArrayLimit(r, l) {
25
+ var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
26
+ if (null != t) {
27
+ var e,
28
+ n,
29
+ i,
30
+ u,
31
+ a = [],
32
+ f = true,
33
+ o = false;
34
+ try {
35
+ if (i = (t = t.call(r)).next, 0 === l) ; else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
36
+ } catch (r) {
37
+ o = true, n = r;
38
+ } finally {
39
+ try {
40
+ if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
41
+ } finally {
42
+ if (o) throw n;
43
+ }
44
+ }
45
+ return a;
46
+ }
47
+ }
48
+ function _nonIterableRest() {
49
+ throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
50
+ }
51
+ function ownKeys(e, r) {
52
+ var t = Object.keys(e);
53
+ if (Object.getOwnPropertySymbols) {
54
+ var o = Object.getOwnPropertySymbols(e);
55
+ r && (o = o.filter(function (r) {
56
+ return Object.getOwnPropertyDescriptor(e, r).enumerable;
57
+ })), t.push.apply(t, o);
58
+ }
59
+ return t;
60
+ }
61
+ function _objectSpread2(e) {
62
+ for (var r = 1; r < arguments.length; r++) {
63
+ var t = null != arguments[r] ? arguments[r] : {};
64
+ r % 2 ? ownKeys(Object(t), true).forEach(function (r) {
65
+ _defineProperty(e, r, t[r]);
66
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
67
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
68
+ });
69
+ }
70
+ return e;
71
+ }
72
+ function _slicedToArray(r, e) {
73
+ return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest();
74
+ }
75
+ function _toPrimitive(t, r) {
76
+ if ("object" != typeof t || !t) return t;
77
+ var e = t[Symbol.toPrimitive];
78
+ if (void 0 !== e) {
79
+ var i = e.call(t, r);
80
+ if ("object" != typeof i) return i;
81
+ throw new TypeError("@@toPrimitive must return a primitive value.");
82
+ }
83
+ return ("string" === r ? String : Number)(t);
84
+ }
85
+ function _toPropertyKey(t) {
86
+ var i = _toPrimitive(t, "string");
87
+ return "symbol" == typeof i ? i : i + "";
88
+ }
89
+ function _unsupportedIterableToArray(r, a) {
90
+ if (r) {
91
+ if ("string" == typeof r) return _arrayLikeToArray(r, a);
92
+ var t = {}.toString.call(r).slice(8, -1);
93
+ return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
94
+ }
95
+ }
96
+
8
97
  const theme = {
9
98
  accentColor: _ref => {
10
- let {
11
- theme
12
- } = _ref;
13
- return {
14
- ...theme("colors"),
99
+ let theme = _ref.theme;
100
+ return _objectSpread2(_objectSpread2({}, theme("colors")), {}, {
15
101
  auto: "auto",
16
102
  custom: "custom_value"
17
- };
103
+ });
18
104
  },
19
105
  animation: {
20
106
  none: "none",
@@ -33,63 +119,43 @@ const theme = {
33
119
  custom: "custom_value"
34
120
  },
35
121
  backdropBlur: _ref2 => {
36
- let {
37
- theme
38
- } = _ref2;
122
+ let theme = _ref2.theme;
39
123
  return theme("blur");
40
124
  },
41
125
  backdropBrightness: _ref3 => {
42
- let {
43
- theme
44
- } = _ref3;
126
+ let theme = _ref3.theme;
45
127
  return theme("brightness");
46
128
  },
47
129
  backdropContrast: _ref4 => {
48
- let {
49
- theme
50
- } = _ref4;
130
+ let theme = _ref4.theme;
51
131
  return theme("contrast");
52
132
  },
53
133
  backdropGrayscale: _ref5 => {
54
- let {
55
- theme
56
- } = _ref5;
134
+ let theme = _ref5.theme;
57
135
  return theme("grayscale");
58
136
  },
59
137
  backdropHueRotate: _ref6 => {
60
- let {
61
- theme
62
- } = _ref6;
138
+ let theme = _ref6.theme;
63
139
  return theme("hueRotate");
64
140
  },
65
141
  backdropInvert: _ref7 => {
66
- let {
67
- theme
68
- } = _ref7;
142
+ let theme = _ref7.theme;
69
143
  return theme("invert");
70
144
  },
71
145
  backdropOpacity: _ref8 => {
72
- let {
73
- theme
74
- } = _ref8;
146
+ let theme = _ref8.theme;
75
147
  return theme("opacity");
76
148
  },
77
149
  backdropSaturate: _ref9 => {
78
- let {
79
- theme
80
- } = _ref9;
150
+ let theme = _ref9.theme;
81
151
  return theme("saturate");
82
152
  },
83
153
  backdropSepia: _ref0 => {
84
- let {
85
- theme
86
- } = _ref0;
154
+ let theme = _ref0.theme;
87
155
  return theme("sepia");
88
156
  },
89
157
  backgroundColor: _ref1 => {
90
- let {
91
- theme
92
- } = _ref1;
158
+ let theme = _ref1.theme;
93
159
  return theme("colors");
94
160
  },
95
161
  backgroundImage: {
@@ -104,9 +170,7 @@ const theme = {
104
170
  "gradient-to-tl": "linear-gradient(to top left, var(--gradient-color-stops))"
105
171
  },
106
172
  backgroundOpacity: _ref10 => {
107
- let {
108
- theme
109
- } = _ref10;
173
+ let theme = _ref10.theme;
110
174
  return theme("opacity");
111
175
  },
112
176
  backgroundPosition: {
@@ -138,18 +202,13 @@ const theme = {
138
202
  custom: "custom_value"
139
203
  },
140
204
  borderColor: _ref11 => {
141
- let {
142
- theme
143
- } = _ref11;
144
- return {
145
- ...theme("colors"),
205
+ let theme = _ref11.theme;
206
+ return _objectSpread2(_objectSpread2({}, theme("colors")), {}, {
146
207
  DEFAULT: "#e5e7eb"
147
- };
208
+ });
148
209
  },
149
210
  borderOpacity: _ref12 => {
150
- let {
151
- theme
152
- } = _ref12;
211
+ let theme = _ref12.theme;
153
212
  return theme("opacity");
154
213
  },
155
214
  borderRadius: {
@@ -167,12 +226,8 @@ const theme = {
167
226
  custom: "custom_value"
168
227
  },
169
228
  borderSpacing: _ref13 => {
170
- let {
171
- theme
172
- } = _ref13;
173
- return {
174
- ...theme("spacing")
175
- };
229
+ let theme = _ref13.theme;
230
+ return _objectSpread2({}, theme("spacing"));
176
231
  },
177
232
  borderWidth: {
178
233
  DEFAULT: "1px",
@@ -195,9 +250,7 @@ const theme = {
195
250
  custom: "custom_value"
196
251
  },
197
252
  boxShadowColor: _ref14 => {
198
- let {
199
- theme
200
- } = _ref14;
253
+ let theme = _ref14.theme;
201
254
  return theme("colors");
202
255
  },
203
256
  brightness: {
@@ -215,9 +268,7 @@ const theme = {
215
268
  custom: "custom_value"
216
269
  },
217
270
  caretColor: _ref15 => {
218
- let {
219
- theme
220
- } = _ref15;
271
+ let theme = _ref15.theme;
221
272
  return theme("colors");
222
273
  },
223
274
  colors: {
@@ -595,21 +646,15 @@ const theme = {
595
646
  "zoom-out": "zoom-out"
596
647
  },
597
648
  divideColor: _ref16 => {
598
- let {
599
- theme
600
- } = _ref16;
649
+ let theme = _ref16.theme;
601
650
  return theme("borderColor");
602
651
  },
603
652
  divideOpacity: _ref17 => {
604
- let {
605
- theme
606
- } = _ref17;
653
+ let theme = _ref17.theme;
607
654
  return theme("borderOpacity");
608
655
  },
609
656
  divideWidth: _ref18 => {
610
- let {
611
- theme
612
- } = _ref18;
657
+ let theme = _ref18.theme;
613
658
  return theme("borderWidth");
614
659
  },
615
660
  dropShadow: {
@@ -622,13 +667,10 @@ const theme = {
622
667
  none: "0 0 #0000"
623
668
  },
624
669
  fill: _ref19 => {
625
- let {
626
- theme
627
- } = _ref19;
628
- return {
629
- none: "none",
630
- ...theme("colors")
631
- };
670
+ let theme = _ref19.theme;
671
+ return _objectSpread2({
672
+ none: "none"
673
+ }, theme("colors"));
632
674
  },
633
675
  flex: {
634
676
  1: "1 1 0%",
@@ -637,12 +679,10 @@ const theme = {
637
679
  none: "none"
638
680
  },
639
681
  flexBasis: _ref20 => {
640
- let {
641
- theme
642
- } = _ref20;
643
- return {
644
- auto: "auto",
645
- ...theme("spacing"),
682
+ let theme = _ref20.theme;
683
+ return _objectSpread2(_objectSpread2({
684
+ auto: "auto"
685
+ }, theme("spacing")), {}, {
646
686
  "1/2": "50%",
647
687
  "1/3": "33.333333%",
648
688
  "2/3": "66.666667%",
@@ -670,7 +710,7 @@ const theme = {
670
710
  "10/12": "83.333333%",
671
711
  "11/12": "91.666667%",
672
712
  full: "100%"
673
- };
713
+ });
674
714
  },
675
715
  flexGrow: {
676
716
  0: "0",
@@ -725,15 +765,11 @@ const theme = {
725
765
  custom: "custom_value"
726
766
  },
727
767
  gap: _ref21 => {
728
- let {
729
- theme
730
- } = _ref21;
768
+ let theme = _ref21.theme;
731
769
  return theme("spacing");
732
770
  },
733
771
  gradientColorStops: _ref22 => {
734
- let {
735
- theme
736
- } = _ref22;
772
+ let theme = _ref22.theme;
737
773
  return theme("colors");
738
774
  },
739
775
  gradientColorStopPositions: {
@@ -904,12 +940,10 @@ const theme = {
904
940
  12: "repeat(12, minmax(0, 1fr))"
905
941
  },
906
942
  height: _ref23 => {
907
- let {
908
- theme
909
- } = _ref23;
910
- return {
911
- auto: "auto",
912
- ...theme("spacing"),
943
+ let theme = _ref23.theme;
944
+ return _objectSpread2(_objectSpread2({
945
+ auto: "auto"
946
+ }, theme("spacing")), {}, {
913
947
  "1/2": "50%",
914
948
  "1/3": "33.333333%",
915
949
  "2/3": "66.666667%",
@@ -934,7 +968,7 @@ const theme = {
934
968
  max: "max-content",
935
969
  fit: "fit-content",
936
970
  custom: "custom_value"
937
- };
971
+ });
938
972
  },
939
973
  hueRotate: {
940
974
  0: "0deg",
@@ -945,12 +979,10 @@ const theme = {
945
979
  180: "180deg"
946
980
  },
947
981
  inset: _ref24 => {
948
- let {
949
- theme
950
- } = _ref24;
951
- return {
952
- auto: "auto",
953
- ...theme("spacing"),
982
+ let theme = _ref24.theme;
983
+ return _objectSpread2(_objectSpread2({
984
+ auto: "auto"
985
+ }, theme("spacing")), {}, {
954
986
  "1/2": "50%",
955
987
  "1/3": "33.333333%",
956
988
  "2/3": "66.666667%",
@@ -958,7 +990,7 @@ const theme = {
958
990
  "2/4": "50%",
959
991
  "3/4": "75%",
960
992
  full: "100%"
961
- };
993
+ });
962
994
  },
963
995
  insetShadow: {
964
996
  xs: "inset 0 1px 1px 0 rgb(0 0 0 / 0.05)",
@@ -1013,20 +1045,14 @@ const theme = {
1013
1045
  decimal: "decimal"
1014
1046
  },
1015
1047
  margin: _ref25 => {
1016
- let {
1017
- theme
1018
- } = _ref25;
1019
- return {
1020
- auto: "auto",
1021
- ...theme("spacing")
1022
- };
1048
+ let theme = _ref25.theme;
1049
+ return _objectSpread2({
1050
+ auto: "auto"
1051
+ }, theme("spacing"));
1023
1052
  },
1024
1053
  maxHeight: _ref26 => {
1025
- let {
1026
- theme
1027
- } = _ref26;
1028
- return {
1029
- ...theme("spacing"),
1054
+ let theme = _ref26.theme;
1055
+ return _objectSpread2(_objectSpread2({}, theme("spacing")), {}, {
1030
1056
  none: "none",
1031
1057
  full: "100%",
1032
1058
  screen: "100vh",
@@ -1036,14 +1062,11 @@ const theme = {
1036
1062
  min: "min-content",
1037
1063
  max: "max-content",
1038
1064
  fit: "fit-content"
1039
- };
1065
+ });
1040
1066
  },
1041
1067
  maxWidth: _ref27 => {
1042
- let {
1043
- theme
1044
- } = _ref27;
1045
- return {
1046
- ...theme("spacing"),
1068
+ let theme = _ref27.theme;
1069
+ return _objectSpread2(_objectSpread2({}, theme("spacing")), {}, {
1047
1070
  none: "none",
1048
1071
  xs: "20rem",
1049
1072
  sm: "24rem",
@@ -1061,14 +1084,11 @@ const theme = {
1061
1084
  max: "max-content",
1062
1085
  fit: "fit-content",
1063
1086
  prose: "65ch"
1064
- };
1087
+ });
1065
1088
  },
1066
1089
  minHeight: _ref28 => {
1067
- let {
1068
- theme
1069
- } = _ref28;
1070
- return {
1071
- ...theme("spacing"),
1090
+ let theme = _ref28.theme;
1091
+ return _objectSpread2(_objectSpread2({}, theme("spacing")), {}, {
1072
1092
  full: "100%",
1073
1093
  screen: "100vh",
1074
1094
  svh: "100svh",
@@ -1077,19 +1097,16 @@ const theme = {
1077
1097
  min: "min-content",
1078
1098
  max: "max-content",
1079
1099
  fit: "fit-content"
1080
- };
1100
+ });
1081
1101
  },
1082
1102
  minWidth: _ref29 => {
1083
- let {
1084
- theme
1085
- } = _ref29;
1086
- return {
1087
- ...theme("spacing"),
1103
+ let theme = _ref29.theme;
1104
+ return _objectSpread2(_objectSpread2({}, theme("spacing")), {}, {
1088
1105
  full: "100%",
1089
1106
  min: "min-content",
1090
1107
  max: "max-content",
1091
1108
  fit: "fit-content"
1092
- };
1109
+ });
1093
1110
  },
1094
1111
  objectPosition: {
1095
1112
  bottom: "bottom",
@@ -1145,9 +1162,7 @@ const theme = {
1145
1162
  custom: "custom_value"
1146
1163
  },
1147
1164
  outlineColor: _ref30 => {
1148
- let {
1149
- theme
1150
- } = _ref30;
1165
+ let theme = _ref30.theme;
1151
1166
  return theme("colors");
1152
1167
  },
1153
1168
  outlineOffset: {
@@ -1159,9 +1174,7 @@ const theme = {
1159
1174
  custom: "custom_value"
1160
1175
  },
1161
1176
  outlineOpacity: _ref31 => {
1162
- let {
1163
- theme
1164
- } = _ref31;
1177
+ let theme = _ref31.theme;
1165
1178
  return theme("opacity");
1166
1179
  },
1167
1180
  outlineWidth: {
@@ -1173,9 +1186,7 @@ const theme = {
1173
1186
  custom: "custom_value"
1174
1187
  },
1175
1188
  padding: _ref32 => {
1176
- let {
1177
- theme
1178
- } = _ref32;
1189
+ let theme = _ref32.theme;
1179
1190
  return theme("spacing");
1180
1191
  },
1181
1192
  perspective: {
@@ -1188,18 +1199,13 @@ const theme = {
1188
1199
  custom: "custom_value"
1189
1200
  },
1190
1201
  ringColor: _ref33 => {
1191
- let {
1192
- theme
1193
- } = _ref33;
1194
- return {
1195
- DEFAULT: "#3b82f6",
1196
- ...theme("colors")
1197
- };
1202
+ let theme = _ref33.theme;
1203
+ return _objectSpread2({
1204
+ DEFAULT: "#3b82f6"
1205
+ }, theme("colors"));
1198
1206
  },
1199
1207
  ringOffsetColor: _ref34 => {
1200
- let {
1201
- theme
1202
- } = _ref34;
1208
+ let theme = _ref34.theme;
1203
1209
  return theme("colors");
1204
1210
  },
1205
1211
  ringOffsetWidth: {
@@ -1211,13 +1217,10 @@ const theme = {
1211
1217
  custom: "custom_value"
1212
1218
  },
1213
1219
  ringOpacity: _ref35 => {
1214
- let {
1215
- theme
1216
- } = _ref35;
1217
- return {
1218
- DEFAULT: "0.5",
1219
- ...theme("opacity")
1220
- };
1220
+ let theme = _ref35.theme;
1221
+ return _objectSpread2({
1222
+ DEFAULT: "0.5"
1223
+ }, theme("opacity"));
1221
1224
  },
1222
1225
  ringWidth: {
1223
1226
  DEFAULT: "3px",
@@ -1262,17 +1265,11 @@ const theme = {
1262
1265
  custom: "custom_value"
1263
1266
  },
1264
1267
  scrollMargin: _ref36 => {
1265
- let {
1266
- theme
1267
- } = _ref36;
1268
- return {
1269
- ...theme("spacing")
1270
- };
1268
+ let theme = _ref36.theme;
1269
+ return _objectSpread2({}, theme("spacing"));
1271
1270
  },
1272
1271
  scrollPadding: _ref37 => {
1273
- let {
1274
- theme
1275
- } = _ref37;
1272
+ let theme = _ref37.theme;
1276
1273
  return theme("spacing");
1277
1274
  },
1278
1275
  screens: {
@@ -1297,12 +1294,8 @@ const theme = {
1297
1294
  custom: "custom_value"
1298
1295
  },
1299
1296
  space: _ref38 => {
1300
- let {
1301
- theme
1302
- } = _ref38;
1303
- return {
1304
- ...theme("spacing")
1305
- };
1297
+ let theme = _ref38.theme;
1298
+ return _objectSpread2({}, theme("spacing"));
1306
1299
  },
1307
1300
  spacing: {
1308
1301
  px: "1px",
@@ -1348,13 +1341,10 @@ const theme = {
1348
1341
  custom: "custom_value"
1349
1342
  },
1350
1343
  stroke: _ref39 => {
1351
- let {
1352
- theme
1353
- } = _ref39;
1354
- return {
1355
- none: "none",
1356
- ...theme("colors")
1357
- };
1344
+ let theme = _ref39.theme;
1345
+ return _objectSpread2({
1346
+ none: "none"
1347
+ }, theme("colors"));
1358
1348
  },
1359
1349
  strokeWidth: {
1360
1350
  0: "0",
@@ -1363,15 +1353,11 @@ const theme = {
1363
1353
  custom: "custom_value"
1364
1354
  },
1365
1355
  textColor: _ref40 => {
1366
- let {
1367
- theme
1368
- } = _ref40;
1356
+ let theme = _ref40.theme;
1369
1357
  return theme("colors");
1370
1358
  },
1371
1359
  textDecorationColor: _ref41 => {
1372
- let {
1373
- theme
1374
- } = _ref41;
1360
+ let theme = _ref41.theme;
1375
1361
  return theme("colors");
1376
1362
  },
1377
1363
  textDecorationThickness: {
@@ -1385,38 +1371,25 @@ const theme = {
1385
1371
  custom: "custom_value"
1386
1372
  },
1387
1373
  textIndent: _ref42 => {
1388
- let {
1389
- theme
1390
- } = _ref42;
1391
- return {
1392
- ...theme("spacing")
1393
- };
1374
+ let theme = _ref42.theme;
1375
+ return _objectSpread2({}, theme("spacing"));
1394
1376
  },
1395
1377
  textOpacity: _ref43 => {
1396
- let {
1397
- theme
1398
- } = _ref43;
1378
+ let theme = _ref43.theme;
1399
1379
  return theme("opacity");
1400
1380
  },
1401
1381
  textShadowBlur: _ref44 => {
1402
- let {
1403
- theme
1404
- } = _ref44;
1382
+ let theme = _ref44.theme;
1405
1383
  return theme("blur");
1406
1384
  },
1407
1385
  textShadowColor: _ref45 => {
1408
- let {
1409
- theme
1410
- } = _ref45;
1411
- return {
1412
- ...theme("colors"),
1386
+ let theme = _ref45.theme;
1387
+ return _objectSpread2(_objectSpread2({}, theme("colors")), {}, {
1413
1388
  DEFAULT: "#e5e7eb"
1414
- };
1389
+ });
1415
1390
  },
1416
1391
  textShadowOpacity: _ref46 => {
1417
- let {
1418
- theme
1419
- } = _ref46;
1392
+ let theme = _ref46.theme;
1420
1393
  return theme("opacity");
1421
1394
  },
1422
1395
  textShadowX: {
@@ -1434,9 +1407,7 @@ const theme = {
1434
1407
  custom: "custom_value"
1435
1408
  },
1436
1409
  textShadowY: _ref47 => {
1437
- let {
1438
- theme
1439
- } = _ref47;
1410
+ let theme = _ref47.theme;
1440
1411
  return theme("textShadowX");
1441
1412
  },
1442
1413
  textUnderlineOffset: {
@@ -1460,11 +1431,8 @@ const theme = {
1460
1431
  "top-left": "top left"
1461
1432
  },
1462
1433
  translate: _ref48 => {
1463
- let {
1464
- theme
1465
- } = _ref48;
1466
- return {
1467
- ...theme("spacing"),
1434
+ let theme = _ref48.theme;
1435
+ return _objectSpread2(_objectSpread2({}, theme("spacing")), {}, {
1468
1436
  "1/2": "50%",
1469
1437
  "1/3": "33.333333%",
1470
1438
  "2/3": "66.666667%",
@@ -1472,15 +1440,13 @@ const theme = {
1472
1440
  "2/4": "50%",
1473
1441
  "3/4": "75%",
1474
1442
  full: "100%"
1475
- };
1443
+ });
1476
1444
  },
1477
1445
  size: _ref49 => {
1478
- let {
1479
- theme
1480
- } = _ref49;
1481
- return {
1482
- auto: "auto",
1483
- ...theme("spacing"),
1446
+ let theme = _ref49.theme;
1447
+ return _objectSpread2(_objectSpread2({
1448
+ auto: "auto"
1449
+ }, theme("spacing")), {}, {
1484
1450
  "1/2": "50%",
1485
1451
  "1/3": "33.333333%",
1486
1452
  "2/3": "66.666667%",
@@ -1511,15 +1477,13 @@ const theme = {
1511
1477
  min: "min-content",
1512
1478
  max: "max-content",
1513
1479
  fit: "fit-content"
1514
- };
1480
+ });
1515
1481
  },
1516
1482
  width: _ref50 => {
1517
- let {
1518
- theme
1519
- } = _ref50;
1520
- return {
1521
- auto: "auto",
1522
- ...theme("spacing"),
1483
+ let theme = _ref50.theme;
1484
+ return _objectSpread2(_objectSpread2({
1485
+ auto: "auto"
1486
+ }, theme("spacing")), {}, {
1523
1487
  "1/2": "50%",
1524
1488
  "1/3": "33.333333%",
1525
1489
  "2/3": "66.666667%",
@@ -1554,7 +1518,7 @@ const theme = {
1554
1518
  min: "min-content",
1555
1519
  max: "max-content",
1556
1520
  fit: "fit-content"
1557
- };
1521
+ });
1558
1522
  },
1559
1523
  willChange: {
1560
1524
  auto: "auto",
@@ -1690,20 +1654,13 @@ const configOptions = {
1690
1654
  vars
1691
1655
  };
1692
1656
 
1693
- /**
1694
- * User Configuration Management
1695
- * Handles theme extensions and custom plugin registration
1696
- */
1697
-
1698
-
1699
1657
  /**
1700
1658
  * User configuration state
1701
1659
  */
1702
1660
  let userConfig = {
1703
1661
  theme: {
1704
1662
  extend: {}
1705
- },
1706
- prefix: ""};
1663
+ }};
1707
1664
 
1708
1665
  // Cache for extended theme to avoid redundant lookups
1709
1666
  const extendedThemeCache = new Map();
@@ -1725,25 +1682,15 @@ function getExtendedTheme(key) {
1725
1682
  return result;
1726
1683
  }
1727
1684
 
1728
- /**
1729
- * Get configured prefix
1730
- * @returns {string} Prefix string
1731
- */
1732
- function getPrefix() {
1733
- return userConfig.prefix;
1734
- }
1735
-
1736
1685
  function isFunction(functionToCheck) {
1737
1686
  return functionToCheck && {}.toString.call(functionToCheck) === "[object Function]";
1738
1687
  }
1739
1688
  function getConfigOptions() {
1740
1689
  let options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
1741
- const {
1742
- theme = {}
1743
- } = options;
1744
- const {
1745
- extend: themeExtend = {}
1746
- } = theme;
1690
+ const _options$theme = options.theme,
1691
+ theme = _options$theme === void 0 ? {} : _options$theme;
1692
+ const _theme$extend = theme.extend,
1693
+ themeExtend = _theme$extend === void 0 ? {} : _theme$extend;
1747
1694
  const newTheme = {};
1748
1695
  const themeKeys = Object.keys(configOptions.theme);
1749
1696
  themeKeys.forEach(key => {
@@ -1787,16 +1734,12 @@ function getConfigOptions() {
1787
1734
  });
1788
1735
  }
1789
1736
  });
1790
-
1791
- // Get user prefix
1792
- const userPrefix = getPrefix();
1793
- const finalPrefix = userPrefix || options.prefix || "";
1794
- return {
1795
- prefix: finalPrefix,
1796
- ...configOptions,
1797
- ...options,
1737
+ const finalPrefix = options.prefix || "";
1738
+ return _objectSpread2(_objectSpread2(_objectSpread2({
1739
+ prefix: finalPrefix
1740
+ }, configOptions), options), {}, {
1798
1741
  theme: newTheme
1799
- };
1742
+ });
1800
1743
  }
1801
1744
  function generateCssString() {
1802
1745
  let getCssString = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : () => {};
@@ -1819,7 +1762,9 @@ function generateCssString() {
1819
1762
  }
1820
1763
  let str = "";
1821
1764
  Object.entries(nOptions).forEach(_ref => {
1822
- let [key, value] = _ref;
1765
+ let _ref2 = _slicedToArray(_ref, 2),
1766
+ key = _ref2[0],
1767
+ value = _ref2[1];
1823
1768
  str += getStr(key.replace("/", "\\/").replace(".", "\\."), value);
1824
1769
  });
1825
1770
  return str;
@@ -1827,14 +1772,18 @@ function generateCssString() {
1827
1772
  const getCssByColors = function (colors) {
1828
1773
  let getStr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : () => {};
1829
1774
  let str = "";
1830
- Object.entries(colors).forEach(_ref2 => {
1831
- let [key1, value1] = _ref2;
1775
+ Object.entries(colors).forEach(_ref3 => {
1776
+ let _ref4 = _slicedToArray(_ref3, 2),
1777
+ key1 = _ref4[0],
1778
+ value1 = _ref4[1];
1832
1779
  if (typeof value1 === "string") {
1833
- str += `${getStr(key1, value1, hexToRgb(value1))} `;
1780
+ str += "".concat(getStr(key1, value1, hexToRgb(value1)), " ");
1834
1781
  } else if (typeof value1 === "object") {
1835
- Object.entries(value1).forEach(_ref3 => {
1836
- let [key2, value2] = _ref3;
1837
- str += `${getStr(`${key1}-${key2}`, value2, hexToRgb(value2))} `;
1782
+ Object.entries(value1).forEach(_ref5 => {
1783
+ let _ref6 = _slicedToArray(_ref5, 2),
1784
+ key2 = _ref6[0],
1785
+ value2 = _ref6[1];
1786
+ str += "".concat(getStr("".concat(key1, "-").concat(key2), value2, hexToRgb(value2)), " ");
1838
1787
  });
1839
1788
  }
1840
1789
  });