@react-email/tailwind 1.0.0 → 1.0.2
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/dist/index.d.ts +19 -2
- package/dist/index.js +20 -20
- package/dist/index.mjs +281 -272
- package/dist/tailwindcss/config.d.ts +376 -0
- package/dist/tailwindcss/generated/.gitkeep +0 -0
- package/dist/tailwindcss/generated/colors.d.ts +298 -0
- package/dist/tailwindcss/generated/corePluginList.d.ts +1 -0
- package/dist/tailwindcss/generated/default-theme.d.ts +397 -0
- package/dist/tailwindcss/index.d.ts +11 -0
- package/package.json +6 -6
- package/dist/hooks/use-suspensed-promise.d.ts +0 -2
- package/dist/hooks/use-suspensed-promise.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/tailwind.d.ts +0 -14
- package/dist/tailwind.d.ts.map +0 -1
- package/dist/tailwind.spec.d.ts +0 -2
- package/dist/tailwind.spec.d.ts.map +0 -1
- package/dist/utils/compatibility/convert-css-property-to-react-property.d.ts +0 -2
- package/dist/utils/compatibility/convert-css-property-to-react-property.d.ts.map +0 -1
- package/dist/utils/compatibility/escape-class-name.d.ts +0 -9
- package/dist/utils/compatibility/escape-class-name.d.ts.map +0 -1
- package/dist/utils/compatibility/escape-class-name.spec.d.ts +0 -2
- package/dist/utils/compatibility/escape-class-name.spec.d.ts.map +0 -1
- package/dist/utils/compatibility/sanitize-class-name.d.ts +0 -8
- package/dist/utils/compatibility/sanitize-class-name.d.ts.map +0 -1
- package/dist/utils/compatibility/sanitize-class-name.spec.d.ts +0 -2
- package/dist/utils/compatibility/sanitize-class-name.spec.d.ts.map +0 -1
- package/dist/utils/compatibility/unescape-class.d.ts +0 -2
- package/dist/utils/compatibility/unescape-class.d.ts.map +0 -1
- package/dist/utils/css/make-inline-styles-for.d.ts +0 -6
- package/dist/utils/css/make-inline-styles-for.d.ts.map +0 -1
- package/dist/utils/css/make-inline-styles-for.spec.d.ts +0 -2
- package/dist/utils/css/make-inline-styles-for.spec.d.ts.map +0 -1
- package/dist/utils/css/media-queries/sanitize-media-queries.d.ts +0 -17
- package/dist/utils/css/media-queries/sanitize-media-queries.d.ts.map +0 -1
- package/dist/utils/css/media-queries/sanitize-media-queries.spec.d.ts +0 -2
- package/dist/utils/css/media-queries/sanitize-media-queries.spec.d.ts.map +0 -1
- package/dist/utils/css/minify-css.d.ts +0 -2
- package/dist/utils/css/minify-css.d.ts.map +0 -1
- package/dist/utils/css/resolve-all-css-variables.d.ts +0 -3
- package/dist/utils/css/resolve-all-css-variables.d.ts.map +0 -1
- package/dist/utils/css/resolve-all-css-variables.spec.d.ts +0 -2
- package/dist/utils/css/resolve-all-css-variables.spec.d.ts.map +0 -1
- package/dist/utils/css/sanitize-declarations.d.ts +0 -10
- package/dist/utils/css/sanitize-declarations.d.ts.map +0 -1
- package/dist/utils/react/is-component.d.ts +0 -2
- package/dist/utils/react/is-component.d.ts.map +0 -1
- package/dist/utils/react/map-react-tree.d.ts +0 -15
- package/dist/utils/react/map-react-tree.d.ts.map +0 -1
- package/dist/utils/react/map-react-tree.spec.d.ts +0 -2
- package/dist/utils/react/map-react-tree.spec.d.ts.map +0 -1
- package/dist/utils/tailwindcss/clone-element-with-inlined-styles.d.ts +0 -10
- package/dist/utils/tailwindcss/clone-element-with-inlined-styles.d.ts.map +0 -1
- package/dist/utils/tailwindcss/setup-tailwind-context.d.ts +0 -4
- package/dist/utils/tailwindcss/setup-tailwind-context.d.ts.map +0 -1
- package/dist/utils/tailwindcss/setup-tailwind.d.ts +0 -5
- package/dist/utils/tailwindcss/setup-tailwind.d.ts.map +0 -1
- package/dist/utils/tailwindcss/setup-tailwind.spec.d.ts +0 -2
- package/dist/utils/tailwindcss/setup-tailwind.spec.d.ts.map +0 -1
- package/dist/utils/text/from-dash-case-to-camel-case.d.ts +0 -2
- package/dist/utils/text/from-dash-case-to-camel-case.d.ts.map +0 -1
|
@@ -0,0 +1,397 @@
|
|
|
1
|
+
type CSSDeclarationList = Record<string, string>
|
|
2
|
+
export type DefaultTheme = {
|
|
3
|
+
animation: Record<'none' | 'spin' | 'ping' | 'pulse' | 'bounce', string>
|
|
4
|
+
aria: Record<
|
|
5
|
+
| 'busy'
|
|
6
|
+
| 'checked'
|
|
7
|
+
| 'disabled'
|
|
8
|
+
| 'expanded'
|
|
9
|
+
| 'hidden'
|
|
10
|
+
| 'pressed'
|
|
11
|
+
| 'readonly'
|
|
12
|
+
| 'required'
|
|
13
|
+
| 'selected',
|
|
14
|
+
string
|
|
15
|
+
>
|
|
16
|
+
aspectRatio: Record<'auto' | 'square' | 'video', string>
|
|
17
|
+
backgroundImage: Record<
|
|
18
|
+
| 'none'
|
|
19
|
+
| 'gradient-to-t'
|
|
20
|
+
| 'gradient-to-tr'
|
|
21
|
+
| 'gradient-to-r'
|
|
22
|
+
| 'gradient-to-br'
|
|
23
|
+
| 'gradient-to-b'
|
|
24
|
+
| 'gradient-to-bl'
|
|
25
|
+
| 'gradient-to-l'
|
|
26
|
+
| 'gradient-to-tl',
|
|
27
|
+
string
|
|
28
|
+
>
|
|
29
|
+
backgroundPosition: Record<
|
|
30
|
+
| 'bottom'
|
|
31
|
+
| 'center'
|
|
32
|
+
| 'left'
|
|
33
|
+
| 'left-bottom'
|
|
34
|
+
| 'left-top'
|
|
35
|
+
| 'right'
|
|
36
|
+
| 'right-bottom'
|
|
37
|
+
| 'right-top'
|
|
38
|
+
| 'top',
|
|
39
|
+
string
|
|
40
|
+
>
|
|
41
|
+
backgroundSize: Record<'auto' | 'cover' | 'contain', string>
|
|
42
|
+
blur: Record<'0' | 'none' | 'sm' | 'DEFAULT' | 'md' | 'lg' | 'xl' | '2xl' | '3xl', string>
|
|
43
|
+
borderRadius: Record<
|
|
44
|
+
'none' | 'sm' | 'DEFAULT' | 'md' | 'lg' | 'xl' | '2xl' | '3xl' | 'full',
|
|
45
|
+
string
|
|
46
|
+
>
|
|
47
|
+
borderWidth: Record<'0' | '2' | '4' | '8' | 'DEFAULT', string>
|
|
48
|
+
boxShadow: Record<'sm' | 'DEFAULT' | 'md' | 'lg' | 'xl' | '2xl' | 'inner' | 'none', string>
|
|
49
|
+
brightness: Record<
|
|
50
|
+
'0' | '50' | '75' | '90' | '95' | '100' | '105' | '110' | '125' | '150' | '200',
|
|
51
|
+
string
|
|
52
|
+
>
|
|
53
|
+
columns: Record<
|
|
54
|
+
| '1'
|
|
55
|
+
| '2'
|
|
56
|
+
| '3'
|
|
57
|
+
| '4'
|
|
58
|
+
| '5'
|
|
59
|
+
| '6'
|
|
60
|
+
| '7'
|
|
61
|
+
| '8'
|
|
62
|
+
| '9'
|
|
63
|
+
| '10'
|
|
64
|
+
| '11'
|
|
65
|
+
| '12'
|
|
66
|
+
| 'auto'
|
|
67
|
+
| '3xs'
|
|
68
|
+
| '2xs'
|
|
69
|
+
| 'xs'
|
|
70
|
+
| 'sm'
|
|
71
|
+
| 'md'
|
|
72
|
+
| 'lg'
|
|
73
|
+
| 'xl'
|
|
74
|
+
| '2xl'
|
|
75
|
+
| '3xl'
|
|
76
|
+
| '4xl'
|
|
77
|
+
| '5xl'
|
|
78
|
+
| '6xl'
|
|
79
|
+
| '7xl',
|
|
80
|
+
string
|
|
81
|
+
>
|
|
82
|
+
content: Record<'none', string>
|
|
83
|
+
contrast: Record<'0' | '50' | '75' | '100' | '125' | '150' | '200', string>
|
|
84
|
+
cursor: Record<
|
|
85
|
+
| 'auto'
|
|
86
|
+
| 'default'
|
|
87
|
+
| 'pointer'
|
|
88
|
+
| 'wait'
|
|
89
|
+
| 'text'
|
|
90
|
+
| 'move'
|
|
91
|
+
| 'help'
|
|
92
|
+
| 'not-allowed'
|
|
93
|
+
| 'none'
|
|
94
|
+
| 'context-menu'
|
|
95
|
+
| 'progress'
|
|
96
|
+
| 'cell'
|
|
97
|
+
| 'crosshair'
|
|
98
|
+
| 'vertical-text'
|
|
99
|
+
| 'alias'
|
|
100
|
+
| 'copy'
|
|
101
|
+
| 'no-drop'
|
|
102
|
+
| 'grab'
|
|
103
|
+
| 'grabbing'
|
|
104
|
+
| 'all-scroll'
|
|
105
|
+
| 'col-resize'
|
|
106
|
+
| 'row-resize'
|
|
107
|
+
| 'n-resize'
|
|
108
|
+
| 'e-resize'
|
|
109
|
+
| 's-resize'
|
|
110
|
+
| 'w-resize'
|
|
111
|
+
| 'ne-resize'
|
|
112
|
+
| 'nw-resize'
|
|
113
|
+
| 'se-resize'
|
|
114
|
+
| 'sw-resize'
|
|
115
|
+
| 'ew-resize'
|
|
116
|
+
| 'ns-resize'
|
|
117
|
+
| 'nesw-resize'
|
|
118
|
+
| 'nwse-resize'
|
|
119
|
+
| 'zoom-in'
|
|
120
|
+
| 'zoom-out',
|
|
121
|
+
string
|
|
122
|
+
>
|
|
123
|
+
dropShadow: Record<'sm' | 'DEFAULT' | 'md' | 'lg' | 'xl' | '2xl' | 'none', string | string[]>
|
|
124
|
+
flex: Record<'1' | 'auto' | 'initial' | 'none', string>
|
|
125
|
+
flexGrow: Record<'0' | 'DEFAULT', string>
|
|
126
|
+
flexShrink: Record<'0' | 'DEFAULT', string>
|
|
127
|
+
fontFamily: Record<'sans' | 'serif' | 'mono', string[]>
|
|
128
|
+
fontSize: Record<
|
|
129
|
+
| 'xs'
|
|
130
|
+
| 'sm'
|
|
131
|
+
| 'base'
|
|
132
|
+
| 'lg'
|
|
133
|
+
| 'xl'
|
|
134
|
+
| '2xl'
|
|
135
|
+
| '3xl'
|
|
136
|
+
| '4xl'
|
|
137
|
+
| '5xl'
|
|
138
|
+
| '6xl'
|
|
139
|
+
| '7xl'
|
|
140
|
+
| '8xl'
|
|
141
|
+
| '9xl',
|
|
142
|
+
[string, { lineHeight: string }]
|
|
143
|
+
>
|
|
144
|
+
fontWeight: Record<
|
|
145
|
+
| 'thin'
|
|
146
|
+
| 'extralight'
|
|
147
|
+
| 'light'
|
|
148
|
+
| 'normal'
|
|
149
|
+
| 'medium'
|
|
150
|
+
| 'semibold'
|
|
151
|
+
| 'bold'
|
|
152
|
+
| 'extrabold'
|
|
153
|
+
| 'black',
|
|
154
|
+
string
|
|
155
|
+
>
|
|
156
|
+
gradientColorStopPositions: Record<
|
|
157
|
+
| '0%'
|
|
158
|
+
| '5%'
|
|
159
|
+
| '10%'
|
|
160
|
+
| '15%'
|
|
161
|
+
| '20%'
|
|
162
|
+
| '25%'
|
|
163
|
+
| '30%'
|
|
164
|
+
| '35%'
|
|
165
|
+
| '40%'
|
|
166
|
+
| '45%'
|
|
167
|
+
| '50%'
|
|
168
|
+
| '55%'
|
|
169
|
+
| '60%'
|
|
170
|
+
| '65%'
|
|
171
|
+
| '70%'
|
|
172
|
+
| '75%'
|
|
173
|
+
| '80%'
|
|
174
|
+
| '85%'
|
|
175
|
+
| '90%'
|
|
176
|
+
| '95%'
|
|
177
|
+
| '100%',
|
|
178
|
+
string
|
|
179
|
+
>
|
|
180
|
+
grayscale: Record<'0' | 'DEFAULT', string>
|
|
181
|
+
gridAutoColumns: Record<'auto' | 'min' | 'max' | 'fr', string>
|
|
182
|
+
gridAutoRows: Record<'auto' | 'min' | 'max' | 'fr', string>
|
|
183
|
+
gridColumn: Record<
|
|
184
|
+
| 'auto'
|
|
185
|
+
| 'span-1'
|
|
186
|
+
| 'span-2'
|
|
187
|
+
| 'span-3'
|
|
188
|
+
| 'span-4'
|
|
189
|
+
| 'span-5'
|
|
190
|
+
| 'span-6'
|
|
191
|
+
| 'span-7'
|
|
192
|
+
| 'span-8'
|
|
193
|
+
| 'span-9'
|
|
194
|
+
| 'span-10'
|
|
195
|
+
| 'span-11'
|
|
196
|
+
| 'span-12'
|
|
197
|
+
| 'span-full',
|
|
198
|
+
string
|
|
199
|
+
>
|
|
200
|
+
gridColumnEnd: Record<
|
|
201
|
+
'1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '13' | 'auto',
|
|
202
|
+
string
|
|
203
|
+
>
|
|
204
|
+
gridColumnStart: Record<
|
|
205
|
+
'1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '13' | 'auto',
|
|
206
|
+
string
|
|
207
|
+
>
|
|
208
|
+
gridRow: Record<
|
|
209
|
+
| 'auto'
|
|
210
|
+
| 'span-1'
|
|
211
|
+
| 'span-2'
|
|
212
|
+
| 'span-3'
|
|
213
|
+
| 'span-4'
|
|
214
|
+
| 'span-5'
|
|
215
|
+
| 'span-6'
|
|
216
|
+
| 'span-7'
|
|
217
|
+
| 'span-8'
|
|
218
|
+
| 'span-9'
|
|
219
|
+
| 'span-10'
|
|
220
|
+
| 'span-11'
|
|
221
|
+
| 'span-12'
|
|
222
|
+
| 'span-full',
|
|
223
|
+
string
|
|
224
|
+
>
|
|
225
|
+
gridRowEnd: Record<
|
|
226
|
+
'1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '13' | 'auto',
|
|
227
|
+
string
|
|
228
|
+
>
|
|
229
|
+
gridRowStart: Record<
|
|
230
|
+
'1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | '13' | 'auto',
|
|
231
|
+
string
|
|
232
|
+
>
|
|
233
|
+
gridTemplateColumns: Record<
|
|
234
|
+
'1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | 'none' | 'subgrid',
|
|
235
|
+
string
|
|
236
|
+
>
|
|
237
|
+
gridTemplateRows: Record<
|
|
238
|
+
'1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12' | 'none' | 'subgrid',
|
|
239
|
+
string
|
|
240
|
+
>
|
|
241
|
+
hueRotate: Record<'0' | '15' | '30' | '60' | '90' | '180', string>
|
|
242
|
+
invert: Record<'0' | 'DEFAULT', string>
|
|
243
|
+
keyframes: Record<'spin' | 'ping' | 'pulse' | 'bounce', Record<string, CSSDeclarationList>>
|
|
244
|
+
letterSpacing: Record<'tighter' | 'tight' | 'normal' | 'wide' | 'wider' | 'widest', string>
|
|
245
|
+
lineHeight: Record<
|
|
246
|
+
| '3'
|
|
247
|
+
| '4'
|
|
248
|
+
| '5'
|
|
249
|
+
| '6'
|
|
250
|
+
| '7'
|
|
251
|
+
| '8'
|
|
252
|
+
| '9'
|
|
253
|
+
| '10'
|
|
254
|
+
| 'none'
|
|
255
|
+
| 'tight'
|
|
256
|
+
| 'snug'
|
|
257
|
+
| 'normal'
|
|
258
|
+
| 'relaxed'
|
|
259
|
+
| 'loose',
|
|
260
|
+
string
|
|
261
|
+
>
|
|
262
|
+
listStyleType: Record<'none' | 'disc' | 'decimal', string>
|
|
263
|
+
listStyleImage: Record<'none', string>
|
|
264
|
+
lineClamp: Record<'1' | '2' | '3' | '4' | '5' | '6', string>
|
|
265
|
+
objectPosition: Record<
|
|
266
|
+
| 'bottom'
|
|
267
|
+
| 'center'
|
|
268
|
+
| 'left'
|
|
269
|
+
| 'left-bottom'
|
|
270
|
+
| 'left-top'
|
|
271
|
+
| 'right'
|
|
272
|
+
| 'right-bottom'
|
|
273
|
+
| 'right-top'
|
|
274
|
+
| 'top',
|
|
275
|
+
string
|
|
276
|
+
>
|
|
277
|
+
opacity: Record<
|
|
278
|
+
| '0'
|
|
279
|
+
| '5'
|
|
280
|
+
| '10'
|
|
281
|
+
| '15'
|
|
282
|
+
| '20'
|
|
283
|
+
| '25'
|
|
284
|
+
| '30'
|
|
285
|
+
| '35'
|
|
286
|
+
| '40'
|
|
287
|
+
| '45'
|
|
288
|
+
| '50'
|
|
289
|
+
| '55'
|
|
290
|
+
| '60'
|
|
291
|
+
| '65'
|
|
292
|
+
| '70'
|
|
293
|
+
| '75'
|
|
294
|
+
| '80'
|
|
295
|
+
| '85'
|
|
296
|
+
| '90'
|
|
297
|
+
| '95'
|
|
298
|
+
| '100',
|
|
299
|
+
string
|
|
300
|
+
>
|
|
301
|
+
order: Record<
|
|
302
|
+
| '1'
|
|
303
|
+
| '2'
|
|
304
|
+
| '3'
|
|
305
|
+
| '4'
|
|
306
|
+
| '5'
|
|
307
|
+
| '6'
|
|
308
|
+
| '7'
|
|
309
|
+
| '8'
|
|
310
|
+
| '9'
|
|
311
|
+
| '10'
|
|
312
|
+
| '11'
|
|
313
|
+
| '12'
|
|
314
|
+
| 'first'
|
|
315
|
+
| 'last'
|
|
316
|
+
| 'none',
|
|
317
|
+
string
|
|
318
|
+
>
|
|
319
|
+
outlineOffset: Record<'0' | '1' | '2' | '4' | '8', string>
|
|
320
|
+
outlineWidth: Record<'0' | '1' | '2' | '4' | '8', string>
|
|
321
|
+
ringOffsetWidth: Record<'0' | '1' | '2' | '4' | '8', string>
|
|
322
|
+
ringWidth: Record<'0' | '1' | '2' | '4' | '8' | 'DEFAULT', string>
|
|
323
|
+
rotate: Record<'0' | '1' | '2' | '3' | '6' | '12' | '45' | '90' | '180', string>
|
|
324
|
+
saturate: Record<'0' | '50' | '100' | '150' | '200', string>
|
|
325
|
+
scale: Record<'0' | '50' | '75' | '90' | '95' | '100' | '105' | '110' | '125' | '150', string>
|
|
326
|
+
screens: Record<'sm' | 'md' | 'lg' | 'xl' | '2xl', string>
|
|
327
|
+
sepia: Record<'0' | 'DEFAULT', string>
|
|
328
|
+
skew: Record<'0' | '1' | '2' | '3' | '6' | '12', string>
|
|
329
|
+
spacing: Record<
|
|
330
|
+
| '0'
|
|
331
|
+
| '1'
|
|
332
|
+
| '2'
|
|
333
|
+
| '3'
|
|
334
|
+
| '4'
|
|
335
|
+
| '5'
|
|
336
|
+
| '6'
|
|
337
|
+
| '7'
|
|
338
|
+
| '8'
|
|
339
|
+
| '9'
|
|
340
|
+
| '10'
|
|
341
|
+
| '11'
|
|
342
|
+
| '12'
|
|
343
|
+
| '14'
|
|
344
|
+
| '16'
|
|
345
|
+
| '20'
|
|
346
|
+
| '24'
|
|
347
|
+
| '28'
|
|
348
|
+
| '32'
|
|
349
|
+
| '36'
|
|
350
|
+
| '40'
|
|
351
|
+
| '44'
|
|
352
|
+
| '48'
|
|
353
|
+
| '52'
|
|
354
|
+
| '56'
|
|
355
|
+
| '60'
|
|
356
|
+
| '64'
|
|
357
|
+
| '72'
|
|
358
|
+
| '80'
|
|
359
|
+
| '96'
|
|
360
|
+
| 'px'
|
|
361
|
+
| '0.5'
|
|
362
|
+
| '1.5'
|
|
363
|
+
| '2.5'
|
|
364
|
+
| '3.5',
|
|
365
|
+
string
|
|
366
|
+
>
|
|
367
|
+
strokeWidth: Record<'0' | '1' | '2', string>
|
|
368
|
+
textDecorationThickness: Record<'0' | '1' | '2' | '4' | '8' | 'auto' | 'from-font', string>
|
|
369
|
+
textUnderlineOffset: Record<'0' | '1' | '2' | '4' | '8' | 'auto', string>
|
|
370
|
+
transformOrigin: Record<
|
|
371
|
+
| 'center'
|
|
372
|
+
| 'top'
|
|
373
|
+
| 'top-right'
|
|
374
|
+
| 'right'
|
|
375
|
+
| 'bottom-right'
|
|
376
|
+
| 'bottom'
|
|
377
|
+
| 'bottom-left'
|
|
378
|
+
| 'left'
|
|
379
|
+
| 'top-left',
|
|
380
|
+
string
|
|
381
|
+
>
|
|
382
|
+
transitionDelay: Record<
|
|
383
|
+
'0' | '75' | '100' | '150' | '200' | '300' | '500' | '700' | '1000',
|
|
384
|
+
string
|
|
385
|
+
>
|
|
386
|
+
transitionDuration: Record<
|
|
387
|
+
'0' | '75' | '100' | '150' | '200' | '300' | '500' | '700' | '1000' | 'DEFAULT',
|
|
388
|
+
string
|
|
389
|
+
>
|
|
390
|
+
transitionProperty: Record<
|
|
391
|
+
'none' | 'all' | 'DEFAULT' | 'colors' | 'opacity' | 'shadow' | 'transform',
|
|
392
|
+
string
|
|
393
|
+
>
|
|
394
|
+
transitionTimingFunction: Record<'DEFAULT' | 'linear' | 'in' | 'out' | 'in-out', string>
|
|
395
|
+
willChange: Record<'auto' | 'scroll' | 'contents' | 'transform', string>
|
|
396
|
+
zIndex: Record<'0' | '10' | '20' | '30' | '40' | '50' | 'auto', string>
|
|
397
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { PluginCreator } from 'postcss'
|
|
2
|
+
import type { Config } from './config.d'
|
|
3
|
+
|
|
4
|
+
declare const plugin: PluginCreator<string | Config | { config: string | Config }>
|
|
5
|
+
|
|
6
|
+
declare type _Config = Config
|
|
7
|
+
declare namespace plugin {
|
|
8
|
+
export type { _Config as Config }
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export = plugin
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@react-email/tailwind",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "A React component to wrap emails with Tailwind CSS",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -45,13 +45,13 @@
|
|
|
45
45
|
"eslint-plugin-regex": "1.10.0",
|
|
46
46
|
"postcss": "8.4.40",
|
|
47
47
|
"postcss-selector-parser": "6.0.16",
|
|
48
|
-
"react-dom": "19.0.0-rc-
|
|
48
|
+
"react-dom": "19.0.0-rc-02c0e824-20241028",
|
|
49
49
|
"shelljs": "0.8.5",
|
|
50
50
|
"tailwindcss": "3.4.10",
|
|
51
51
|
"tsup": "7.2.0",
|
|
52
52
|
"typescript": "5.1.6",
|
|
53
|
-
"vite": "5.
|
|
54
|
-
"vite-plugin-dts": "
|
|
53
|
+
"vite": "5.2.14",
|
|
54
|
+
"vite-plugin-dts": "4.2.4",
|
|
55
55
|
"vitest": "1.1.1",
|
|
56
56
|
"yalc": "1.0.0-pre.53",
|
|
57
57
|
"@react-email/button": "^0.0.18",
|
|
@@ -59,8 +59,8 @@
|
|
|
59
59
|
"@react-email/heading": "0.0.14",
|
|
60
60
|
"@react-email/hr": "0.0.10",
|
|
61
61
|
"@react-email/html": "0.0.10",
|
|
62
|
-
"eslint-config-custom": "0.0.0",
|
|
63
62
|
"@react-email/link": "0.0.11",
|
|
63
|
+
"eslint-config-custom": "0.0.0",
|
|
64
64
|
"@react-email/render": "1.0.2",
|
|
65
65
|
"tsconfig": "0.0.0"
|
|
66
66
|
},
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
"access": "public"
|
|
69
69
|
},
|
|
70
70
|
"scripts": {
|
|
71
|
-
"build": "tsc && NODE_ENV=production vite build --mode production",
|
|
71
|
+
"build": "tsc && NODE_ENV=production vite build --mode production && node ./copy-tailwind-types.mjs",
|
|
72
72
|
"dev": "vite build --watch",
|
|
73
73
|
"clean": "rm -rf dist",
|
|
74
74
|
"lint": "eslint .",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"use-suspensed-promise.d.ts","sourceRoot":"","sources":["../../src/hooks/use-suspensed-promise.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,mBAAmB,kDAEzB,MAAM,WAuBZ,CAAC"}
|
package/dist/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC"}
|
package/dist/tailwind.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import type { Config as TailwindOriginalConfig } from "tailwindcss";
|
|
3
|
-
export type TailwindConfig = Pick<TailwindOriginalConfig, "important" | "prefix" | "separator" | "safelist" | "blocklist" | "presets" | "future" | "experimental" | "darkMode" | "theme" | "corePlugins" | "plugins">;
|
|
4
|
-
export interface TailwindProps {
|
|
5
|
-
children: React.ReactNode;
|
|
6
|
-
config?: TailwindConfig;
|
|
7
|
-
}
|
|
8
|
-
export interface EmailElementProps {
|
|
9
|
-
children?: React.ReactNode;
|
|
10
|
-
className?: string;
|
|
11
|
-
style?: React.CSSProperties;
|
|
12
|
-
}
|
|
13
|
-
export declare const Tailwind: React.FC<TailwindProps>;
|
|
14
|
-
//# sourceMappingURL=tailwind.d.ts.map
|
package/dist/tailwind.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tailwind.d.ts","sourceRoot":"","sources":["../src/tailwind.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,EAAE,MAAM,IAAI,sBAAsB,EAAE,MAAM,aAAa,CAAC;AAOpE,MAAM,MAAM,cAAc,GAAG,IAAI,CAC/B,sBAAsB,EACpB,WAAW,GACX,QAAQ,GACR,WAAW,GACX,UAAU,GACV,WAAW,GACX,SAAS,GACT,QAAQ,GACR,cAAc,GACd,UAAU,GACV,OAAO,GACP,aAAa,GACb,SAAS,CACZ,CAAC;AAEF,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,MAAM,CAAC,EAAE,cAAc,CAAC;CACzB;AAED,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;CAC7B;AAED,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CA8E5C,CAAC"}
|
package/dist/tailwind.spec.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tailwind.spec.d.ts","sourceRoot":"","sources":["../src/tailwind.spec.tsx"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"convert-css-property-to-react-property.d.ts","sourceRoot":"","sources":["../../../src/utils/compatibility/convert-css-property-to-react-property.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,iCAAiC,SAAU,MAAM,WAY7D,CAAC"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Escapes all characters that may not be accepted on
|
|
3
|
-
* CSS selectors by using the regex "[^a-zA-Z0-9\-_]".
|
|
4
|
-
*
|
|
5
|
-
* Also does a bit more trickery to avoid escaping already
|
|
6
|
-
* escaped characters.
|
|
7
|
-
*/
|
|
8
|
-
export declare const escapeClassName: (className: string) => string;
|
|
9
|
-
//# sourceMappingURL=escape-class-name.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"escape-class-name.d.ts","sourceRoot":"","sources":["../../../src/utils/compatibility/escape-class-name.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,eAAO,MAAM,eAAe,cAAe,MAAM,WAUhD,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"escape-class-name.spec.d.ts","sourceRoot":"","sources":["../../../src/utils/compatibility/escape-class-name.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Replaces special characters to avoid problems on email clients.
|
|
3
|
-
*
|
|
4
|
-
* @param className - This should not come with any escaped charcters, it should come the same
|
|
5
|
-
* as is on the `className` attribute on React elements.
|
|
6
|
-
*/
|
|
7
|
-
export declare const sanitizeClassName: (className: string) => string;
|
|
8
|
-
//# sourceMappingURL=sanitize-class-name.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sanitize-class-name.d.ts","sourceRoot":"","sources":["../../../src/utils/compatibility/sanitize-class-name.ts"],"names":[],"mappings":"AAaA;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,cAAe,MAAM,WAgBlD,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sanitize-class-name.spec.d.ts","sourceRoot":"","sources":["../../../src/utils/compatibility/sanitize-class-name.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"unescape-class.d.ts","sourceRoot":"","sources":["../../../src/utils/compatibility/unescape-class.ts"],"names":[],"mappings":"AAAA,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,UAEhD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"make-inline-styles-for.d.ts","sourceRoot":"","sources":["../../../src/utils/css/make-inline-styles-for.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAQ,MAAM,SAAS,CAAC;AAuB1C,wBAAgB,mBAAmB,CACjC,SAAS,EAAE,MAAM,EACjB,kBAAkB,EAAE,IAAI;;;EA6BzB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"make-inline-styles-for.spec.d.ts","sourceRoot":"","sources":["../../../src/utils/css/make-inline-styles-for.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { AtRule, Root } from "postcss";
|
|
2
|
-
/**
|
|
3
|
-
* This function goes through a few steps to ensure the best email client support and
|
|
4
|
-
* to ensure that the media queries are going to applied correctly alongisde
|
|
5
|
-
* the inline styles.
|
|
6
|
-
*
|
|
7
|
-
* What it does is:
|
|
8
|
-
* 1. Ignore all the rules that have any pseudo selectors
|
|
9
|
-
* 2. Converts all declarations in all rules into being important ones
|
|
10
|
-
* 3. Sanitizes all the selectors of all rules in the media queries
|
|
11
|
-
* 4. Merges at rules that have equivalent parameters
|
|
12
|
-
*/
|
|
13
|
-
export declare const sanitizeMediaQueries: (root: Root) => {
|
|
14
|
-
mediaQueryClasses: string[];
|
|
15
|
-
sanitizedAtRules: AtRule[];
|
|
16
|
-
};
|
|
17
|
-
//# sourceMappingURL=sanitize-media-queries.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sanitize-media-queries.d.ts","sourceRoot":"","sources":["../../../../src/utils/css/media-queries/sanitize-media-queries.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAG5C;;;;;;;;;;GAUG;AACH,eAAO,MAAM,oBAAoB,SAAU,IAAI;;;CAgD9C,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sanitize-media-queries.spec.d.ts","sourceRoot":"","sources":["../../../../src/utils/css/media-queries/sanitize-media-queries.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"minify-css.d.ts","sourceRoot":"","sources":["../../../src/utils/css/minify-css.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,QAAS,MAAM,KAAG,MAoBvC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"resolve-all-css-variables.d.ts","sourceRoot":"","sources":["../../../src/utils/css/resolve-all-css-variables.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,IAAI,EAQV,MAAM,SAAS,CAAC;AAwBjB,eAAO,MAAM,sBAAsB,SAAU,IAAI,SAkFhD,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"resolve-all-css-variables.spec.d.ts","sourceRoot":"","sources":["../../../src/utils/css/resolve-all-css-variables.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { AtRule, Root, Rule } from "postcss";
|
|
2
|
-
/**
|
|
3
|
-
* Meant to do all the things necessary, in a per-declaration basis, to have the best email client
|
|
4
|
-
* support possible.
|
|
5
|
-
*
|
|
6
|
-
* Currently it only converts all `rgb` declaration values that use a space-based syntax
|
|
7
|
-
* into a command based one since the space-based isn't well supported.
|
|
8
|
-
*/
|
|
9
|
-
export declare const sanitizeDeclarations: (nodeContainingDeclarations: Rule | AtRule | Root) => void;
|
|
10
|
-
//# sourceMappingURL=sanitize-declarations.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sanitize-declarations.d.ts","sourceRoot":"","sources":["../../../src/utils/css/sanitize-declarations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAElD;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB,+BACH,IAAI,GAAG,MAAM,GAAG,IAAI,SAcjD,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"is-component.d.ts","sourceRoot":"","sources":["../../../src/utils/react/is-component.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,WAAW,YACb,MAAM,YAAY,kFAO5B,CAAC"}
|