@unmail/react 0.1.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/dist/index.js ADDED
@@ -0,0 +1,3653 @@
1
+ //#region rolldown:runtime
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __copyProps = (to, from, except, desc) => {
9
+ if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
10
+ key = keys[i];
11
+ if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
12
+ get: ((k) => from[k]).bind(null, key),
13
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
14
+ });
15
+ }
16
+ return to;
17
+ };
18
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
19
+ value: mod,
20
+ enumerable: true
21
+ }) : target, mod));
22
+
23
+ //#endregion
24
+ let react = require("react");
25
+ react = __toESM(react);
26
+ let react_jsx_runtime = require("react/jsx-runtime");
27
+ react_jsx_runtime = __toESM(react_jsx_runtime);
28
+ let marked = require("marked");
29
+ marked = __toESM(marked);
30
+ let html_to_text = require("html-to-text");
31
+ html_to_text = __toESM(html_to_text);
32
+ let prettier_standalone = require("prettier/standalone");
33
+ prettier_standalone = __toESM(prettier_standalone);
34
+ let prettier_plugins_html = require("prettier/plugins/html");
35
+ prettier_plugins_html = __toESM(prettier_plugins_html);
36
+ let node_stream = require("node:stream");
37
+ node_stream = __toESM(node_stream);
38
+ let css_tree = require("css-tree");
39
+ css_tree = __toESM(css_tree);
40
+ let tailwindcss = require("tailwindcss");
41
+ tailwindcss = __toESM(tailwindcss);
42
+
43
+ //#region src/components/body.tsx
44
+ const marginProperties = [
45
+ "margin",
46
+ "marginTop",
47
+ "marginBottom",
48
+ "marginRight",
49
+ "marginLeft",
50
+ "marginInline",
51
+ "marginBlock",
52
+ "marginBlockStart",
53
+ "marginBlockEnd",
54
+ "marginInlineStart",
55
+ "marginInlineEnd"
56
+ ];
57
+ const Body = react.forwardRef(({ children, style,...props }, ref) => {
58
+ const bodyStyle = {
59
+ background: style?.background,
60
+ backgroundColor: style?.backgroundColor
61
+ };
62
+ if (style) for (const property of marginProperties) bodyStyle[property] = style[property] !== void 0 ? 0 : void 0;
63
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("body", {
64
+ ...props,
65
+ style: bodyStyle,
66
+ ref,
67
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("table", {
68
+ border: 0,
69
+ width: "100%",
70
+ cellPadding: "0",
71
+ cellSpacing: "0",
72
+ role: "presentation",
73
+ align: "center",
74
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tbody", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tr", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("td", {
75
+ style,
76
+ children
77
+ }) }) })
78
+ })
79
+ });
80
+ });
81
+ Body.displayName = "Body";
82
+
83
+ //#endregion
84
+ //#region src/utils/parse-padding.ts
85
+ function convertToPx(value) {
86
+ let px = 0;
87
+ if (!value) return px;
88
+ if (typeof value === "number") return value;
89
+ const matches = /^([\d.]+)(px|em|rem|%)$/.exec(value);
90
+ if (matches && matches.length === 3) {
91
+ const numValue = Number.parseFloat(matches[1]);
92
+ switch (matches[2]) {
93
+ case "px": return numValue;
94
+ case "em":
95
+ case "rem":
96
+ px = numValue * 16;
97
+ return px;
98
+ case "%":
99
+ px = numValue / 100 * 600;
100
+ return px;
101
+ default: return numValue;
102
+ }
103
+ }
104
+ return 0;
105
+ }
106
+ function parsePaddingValue(value) {
107
+ if (typeof value === "number") return {
108
+ paddingTop: value,
109
+ paddingBottom: value,
110
+ paddingLeft: value,
111
+ paddingRight: value
112
+ };
113
+ if (typeof value === "string") {
114
+ const values = value.toString().trim().split(/\s+/);
115
+ if (values.length === 1) return {
116
+ paddingTop: values[0],
117
+ paddingBottom: values[0],
118
+ paddingLeft: values[0],
119
+ paddingRight: values[0]
120
+ };
121
+ if (values.length === 2) return {
122
+ paddingTop: values[0],
123
+ paddingRight: values[1],
124
+ paddingBottom: values[0],
125
+ paddingLeft: values[1]
126
+ };
127
+ if (values.length === 3) return {
128
+ paddingTop: values[0],
129
+ paddingRight: values[1],
130
+ paddingBottom: values[2],
131
+ paddingLeft: values[1]
132
+ };
133
+ if (values.length === 4) return {
134
+ paddingTop: values[0],
135
+ paddingRight: values[1],
136
+ paddingBottom: values[2],
137
+ paddingLeft: values[3]
138
+ };
139
+ }
140
+ return {
141
+ paddingTop: void 0,
142
+ paddingBottom: void 0,
143
+ paddingLeft: void 0,
144
+ paddingRight: void 0
145
+ };
146
+ }
147
+ function parsePadding(properties) {
148
+ let paddingTop;
149
+ let paddingRight;
150
+ let paddingBottom;
151
+ let paddingLeft;
152
+ for (const [key, value] of Object.entries(properties)) if (key === "padding") ({paddingTop, paddingBottom, paddingLeft, paddingRight} = parsePaddingValue(value));
153
+ else if (key === "paddingTop") paddingTop = value;
154
+ else if (key === "paddingRight") paddingRight = value;
155
+ else if (key === "paddingBottom") paddingBottom = value;
156
+ else if (key === "paddingLeft") paddingLeft = value;
157
+ return {
158
+ paddingTop: paddingTop ? convertToPx(paddingTop) : void 0,
159
+ paddingRight: paddingRight ? convertToPx(paddingRight) : void 0,
160
+ paddingBottom: paddingBottom ? convertToPx(paddingBottom) : void 0,
161
+ paddingLeft: paddingLeft ? convertToPx(paddingLeft) : void 0
162
+ };
163
+ }
164
+
165
+ //#endregion
166
+ //#region src/utils/px-to-pt.ts
167
+ const pxToPt = (px) => typeof px === "number" && !Number.isNaN(Number(px)) ? px * 3 / 4 : void 0;
168
+
169
+ //#endregion
170
+ //#region src/components/button.tsx
171
+ const maxFontWidth = 5;
172
+ function computeFontWidthAndSpaceCount(expectedWidth) {
173
+ if (expectedWidth === 0) return [0, 0];
174
+ let smallestSpaceCount = 0;
175
+ const computeRequiredFontWidth = () => {
176
+ if (smallestSpaceCount > 0) return expectedWidth / smallestSpaceCount / 2;
177
+ return Number.POSITIVE_INFINITY;
178
+ };
179
+ while (computeRequiredFontWidth() > maxFontWidth) smallestSpaceCount++;
180
+ return [computeRequiredFontWidth(), smallestSpaceCount];
181
+ }
182
+ const Button = react.forwardRef(({ children, style, target = "_blank",...props }, ref) => {
183
+ const { paddingTop, paddingRight, paddingBottom, paddingLeft } = parsePadding(style ?? {});
184
+ const textRaise = pxToPt((paddingTop ?? 0) + (paddingBottom ?? 0));
185
+ const [plFontWidth, plSpaceCount] = computeFontWidthAndSpaceCount(paddingLeft ?? 0);
186
+ const [prFontWidth, prSpaceCount] = computeFontWidthAndSpaceCount(paddingRight ?? 0);
187
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("a", {
188
+ ...props,
189
+ ref,
190
+ style: {
191
+ lineHeight: "100%",
192
+ textDecoration: "none",
193
+ display: "inline-block",
194
+ maxWidth: "100%",
195
+ msoPaddingAlt: "0px",
196
+ ...style,
197
+ paddingTop,
198
+ paddingRight,
199
+ paddingBottom,
200
+ paddingLeft
201
+ },
202
+ target,
203
+ children: [
204
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { dangerouslySetInnerHTML: { __html: `<!--[if mso]><i style="mso-font-width:${plFontWidth * 100}%;mso-text-raise:${textRaise}" hidden>${"&#8202;".repeat(plSpaceCount)}</i><![endif]-->` } }),
205
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
206
+ style: {
207
+ maxWidth: "100%",
208
+ display: "inline-block",
209
+ lineHeight: "120%",
210
+ msoPaddingAlt: "0px",
211
+ msoTextRaise: pxToPt(paddingBottom)
212
+ },
213
+ children
214
+ }),
215
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { dangerouslySetInnerHTML: { __html: `<!--[if mso]><i style="mso-font-width:${prFontWidth * 100}%" hidden>${"&#8202;".repeat(prSpaceCount)}&#8203;</i><![endif]-->` } })
216
+ ]
217
+ });
218
+ });
219
+ Button.displayName = "Button";
220
+
221
+ //#endregion
222
+ //#region src/components/column.tsx
223
+ const Column = react.forwardRef(({ children, style,...props }, ref) => {
224
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("td", {
225
+ ...props,
226
+ ref,
227
+ style,
228
+ children
229
+ });
230
+ });
231
+ Column.displayName = "Column";
232
+
233
+ //#endregion
234
+ //#region src/components/container.tsx
235
+ const Container = react.forwardRef(({ children, style,...props }, ref) => {
236
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("table", {
237
+ align: "center",
238
+ width: "100%",
239
+ ...props,
240
+ border: 0,
241
+ cellPadding: "0",
242
+ cellSpacing: "0",
243
+ ref,
244
+ role: "presentation",
245
+ style: {
246
+ maxWidth: "37.5em",
247
+ ...style
248
+ },
249
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tbody", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tr", {
250
+ style: { width: "100%" },
251
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("td", { children })
252
+ }) })
253
+ });
254
+ });
255
+ Container.displayName = "Container";
256
+
257
+ //#endregion
258
+ //#region src/components/font.tsx
259
+ /** The component MUST be placed inside the <Head> component */
260
+ const Font = ({ fontFamily, fallbackFontFamily, webFont, fontStyle = "normal", fontWeight = 400 }) => {
261
+ const src = webFont ? `src: url(${webFont.url}) format('${webFont.format}');` : "";
262
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("style", { dangerouslySetInnerHTML: { __html: `
263
+ @font-face {
264
+ font-family: '${fontFamily}';
265
+ font-style: ${fontStyle};
266
+ font-weight: ${fontWeight};
267
+ mso-font-alt: '${Array.isArray(fallbackFontFamily) ? fallbackFontFamily[0] : fallbackFontFamily}';
268
+ ${src}
269
+ }
270
+
271
+ * {
272
+ font-family: '${fontFamily}', ${Array.isArray(fallbackFontFamily) ? fallbackFontFamily.join(", ") : fallbackFontFamily};
273
+ }
274
+ ` } });
275
+ };
276
+
277
+ //#endregion
278
+ //#region src/components/head.tsx
279
+ const Head = react.forwardRef(({ children,...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("head", {
280
+ ...props,
281
+ ref,
282
+ children: [
283
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("meta", {
284
+ content: "text/html; charset=UTF-8",
285
+ httpEquiv: "Content-Type"
286
+ }),
287
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("meta", { name: "x-apple-disable-message-reformatting" }),
288
+ children
289
+ ]
290
+ }));
291
+ Head.displayName = "Head";
292
+
293
+ //#endregion
294
+ //#region src/utils/spaces.ts
295
+ const withSpace = (value, properties) => {
296
+ const styles = {};
297
+ if (value === void 0) return styles;
298
+ if (Number.isNaN(Number.parseFloat(String(value)))) return styles;
299
+ for (const property of properties) styles[property] = `${value}px`;
300
+ return styles;
301
+ };
302
+ const withMargin = (props) => {
303
+ const candidates = [
304
+ withSpace(props.m, ["margin"]),
305
+ withSpace(props.mx, ["marginLeft", "marginRight"]),
306
+ withSpace(props.my, ["marginTop", "marginBottom"]),
307
+ withSpace(props.mt, ["marginTop"]),
308
+ withSpace(props.mr, ["marginRight"]),
309
+ withSpace(props.mb, ["marginBottom"]),
310
+ withSpace(props.ml, ["marginLeft"])
311
+ ];
312
+ const mergedStyles = {};
313
+ for (const style of candidates) if (Object.keys(style).length > 0) Object.assign(mergedStyles, style);
314
+ return mergedStyles;
315
+ };
316
+
317
+ //#endregion
318
+ //#region src/components/heading.tsx
319
+ const Heading = react.forwardRef(({ as: Tag = "h1", children, style, m, mx, my, mt, mr, mb, ml,...props }, ref) => {
320
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Tag, {
321
+ ...props,
322
+ ref,
323
+ style: {
324
+ ...withMargin({
325
+ m,
326
+ mx,
327
+ my,
328
+ mt,
329
+ mr,
330
+ mb,
331
+ ml
332
+ }),
333
+ ...style
334
+ },
335
+ children
336
+ });
337
+ });
338
+ Heading.displayName = "Heading";
339
+
340
+ //#endregion
341
+ //#region src/components/hr.tsx
342
+ const Hr = react.forwardRef(({ style,...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("hr", {
343
+ ...props,
344
+ ref,
345
+ style: {
346
+ width: "100%",
347
+ border: "none",
348
+ borderTop: "1px solid #eaeaea",
349
+ ...style
350
+ }
351
+ }));
352
+ Hr.displayName = "Hr";
353
+
354
+ //#endregion
355
+ //#region src/components/html.tsx
356
+ const Html = react.forwardRef(({ children, lang = "en", dir = "ltr",...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("html", {
357
+ ...props,
358
+ dir,
359
+ lang,
360
+ ref,
361
+ children
362
+ }));
363
+ Html.displayName = "Html";
364
+
365
+ //#endregion
366
+ //#region src/components/img.tsx
367
+ const Img = react.forwardRef(({ alt, src, width, height, style,...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("img", {
368
+ ...props,
369
+ alt,
370
+ height,
371
+ ref,
372
+ src,
373
+ style: {
374
+ display: "block",
375
+ outline: "none",
376
+ border: "none",
377
+ textDecoration: "none",
378
+ ...style
379
+ },
380
+ width
381
+ }));
382
+ Img.displayName = "Img";
383
+
384
+ //#endregion
385
+ //#region src/components/link.tsx
386
+ const Link = react.forwardRef(({ target = "_blank", style,...props }, ref) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
387
+ ...props,
388
+ ref,
389
+ style: {
390
+ color: "#067df7",
391
+ textDecorationLine: "none",
392
+ ...style
393
+ },
394
+ target,
395
+ children: props.children
396
+ }));
397
+ Link.displayName = "Link";
398
+
399
+ //#endregion
400
+ //#region src/utils/markdown-styles.ts
401
+ const emptyStyle = {};
402
+ const baseHeaderStyles = {
403
+ fontWeight: "500",
404
+ paddingTop: 20
405
+ };
406
+ const codeInline = {
407
+ color: "#212529",
408
+ fontSize: "87.5%",
409
+ display: "inline",
410
+ background: " #f8f8f8",
411
+ fontFamily: "SFMono-Regular,Menlo,Monaco,Consolas,monospace"
412
+ };
413
+ const codeBlock = {
414
+ ...codeInline,
415
+ display: "block",
416
+ paddingTop: 10,
417
+ paddingRight: 10,
418
+ paddingLeft: 10,
419
+ paddingBottom: 1,
420
+ marginBottom: 20,
421
+ background: " #f8f8f8"
422
+ };
423
+ const defaultMarkdownStyles = {
424
+ h1: {
425
+ ...baseHeaderStyles,
426
+ fontSize: "2.5rem"
427
+ },
428
+ h2: {
429
+ ...baseHeaderStyles,
430
+ fontSize: "2rem"
431
+ },
432
+ h3: {
433
+ ...baseHeaderStyles,
434
+ fontSize: "1.75rem"
435
+ },
436
+ h4: {
437
+ ...baseHeaderStyles,
438
+ fontSize: "1.5rem"
439
+ },
440
+ h5: {
441
+ ...baseHeaderStyles,
442
+ fontSize: "1.25rem"
443
+ },
444
+ h6: {
445
+ ...baseHeaderStyles,
446
+ fontSize: "1rem"
447
+ },
448
+ blockQuote: {
449
+ background: "#f9f9f9",
450
+ borderLeft: "10px solid #ccc",
451
+ margin: "1.5em 10px",
452
+ padding: "1em 10px"
453
+ },
454
+ bold: { fontWeight: "bold" },
455
+ italic: { fontStyle: "italic" },
456
+ link: {
457
+ color: "#007bff",
458
+ textDecoration: "underline",
459
+ backgroundColor: "transparent"
460
+ },
461
+ codeBlock: {
462
+ ...codeBlock,
463
+ wordWrap: "break-word"
464
+ },
465
+ codeInline: {
466
+ ...codeInline,
467
+ wordWrap: "break-word"
468
+ },
469
+ p: emptyStyle,
470
+ li: emptyStyle,
471
+ ul: emptyStyle,
472
+ ol: emptyStyle,
473
+ image: emptyStyle,
474
+ br: emptyStyle,
475
+ hr: emptyStyle,
476
+ table: emptyStyle,
477
+ thead: emptyStyle,
478
+ tbody: emptyStyle,
479
+ th: emptyStyle,
480
+ td: emptyStyle,
481
+ tr: emptyStyle,
482
+ strikethrough: emptyStyle
483
+ };
484
+
485
+ //#endregion
486
+ //#region src/utils/parse-css-in-js-to-inline-css.ts
487
+ function camelToKebabCase(str) {
488
+ return str.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
489
+ }
490
+ function escapeQuotes(value) {
491
+ if (typeof value === "string" && value.includes("\"")) return value.replace(/"/g, "&#x27;");
492
+ return value;
493
+ }
494
+ const numericalCssProperties = [
495
+ "width",
496
+ "height",
497
+ "margin",
498
+ "marginTop",
499
+ "marginRight",
500
+ "marginBottom",
501
+ "marginLeft",
502
+ "padding",
503
+ "paddingTop",
504
+ "paddingRight",
505
+ "paddingBottom",
506
+ "paddingLeft",
507
+ "borderWidth",
508
+ "borderTopWidth",
509
+ "borderRightWidth",
510
+ "borderBottomWidth",
511
+ "borderLeftWidth",
512
+ "outlineWidth",
513
+ "top",
514
+ "right",
515
+ "bottom",
516
+ "left",
517
+ "fontSize",
518
+ "letterSpacing",
519
+ "wordSpacing",
520
+ "maxWidth",
521
+ "minWidth",
522
+ "maxHeight",
523
+ "minHeight",
524
+ "borderRadius",
525
+ "borderTopLeftRadius",
526
+ "borderTopRightRadius",
527
+ "borderBottomLeftRadius",
528
+ "borderBottomRightRadius",
529
+ "textIndent",
530
+ "gridColumnGap",
531
+ "gridRowGap",
532
+ "gridGap",
533
+ "translateX",
534
+ "translateY"
535
+ ];
536
+ function parseCssInJsToInlineCss(cssProperties) {
537
+ if (!cssProperties) return "";
538
+ return Object.entries(cssProperties).map(([property, value]) => {
539
+ if (typeof value === "number" && numericalCssProperties.includes(property)) return `${camelToKebabCase(property)}:${value}px`;
540
+ const escapedValue = escapeQuotes(value);
541
+ return `${camelToKebabCase(property)}:${escapedValue}`;
542
+ }).join(";");
543
+ }
544
+
545
+ //#endregion
546
+ //#region src/components/markdown.tsx
547
+ const Markdown = react.forwardRef(({ children, markdownContainerStyles, markdownCustomStyles,...props }, ref) => {
548
+ const finalStyles = {
549
+ ...defaultMarkdownStyles,
550
+ ...markdownCustomStyles
551
+ };
552
+ const renderer = new marked.Renderer();
553
+ renderer.blockquote = ({ tokens }) => {
554
+ const text = renderer.parser.parse(tokens);
555
+ return `<blockquote${parseCssInJsToInlineCss(finalStyles.blockQuote) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.blockQuote)}"` : ""}>\n${text}</blockquote>\n`;
556
+ };
557
+ renderer.br = () => {
558
+ return `<br${parseCssInJsToInlineCss(finalStyles.br) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.br)}"` : ""} />`;
559
+ };
560
+ renderer.code = ({ text }) => {
561
+ const escaped = `${text.replace(/\n$/, "")}\n`;
562
+ return `<pre${parseCssInJsToInlineCss(finalStyles.codeBlock) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.codeBlock)}"` : ""}><code>${escaped}</code></pre>\n`;
563
+ };
564
+ renderer.codespan = ({ text }) => {
565
+ return `<code${parseCssInJsToInlineCss(finalStyles.codeInline) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.codeInline)}"` : ""}>${text}</code>`;
566
+ };
567
+ renderer.del = ({ tokens }) => {
568
+ const text = renderer.parser.parseInline(tokens);
569
+ return `<del${parseCssInJsToInlineCss(finalStyles.strikethrough) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.strikethrough)}"` : ""}>${text}</del>`;
570
+ };
571
+ renderer.em = ({ tokens }) => {
572
+ const text = renderer.parser.parseInline(tokens);
573
+ return `<em${parseCssInJsToInlineCss(finalStyles.italic) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.italic)}"` : ""}>${text}</em>`;
574
+ };
575
+ renderer.heading = ({ tokens, depth }) => {
576
+ const text = renderer.parser.parseInline(tokens);
577
+ return `<h${depth}${parseCssInJsToInlineCss(finalStyles[`h${depth}`]) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles[`h${depth}`])}"` : ""}>${text}</h${depth}>`;
578
+ };
579
+ renderer.hr = () => {
580
+ return `<hr${parseCssInJsToInlineCss(finalStyles.hr) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.hr)}"` : ""} />\n`;
581
+ };
582
+ renderer.image = ({ href, text, title }) => {
583
+ return `<img src="${href.replaceAll("\"", "&quot;")}" alt="${text.replaceAll("\"", "&quot;")}"${title ? ` title="${title}"` : ""}${parseCssInJsToInlineCss(finalStyles.image) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.image)}"` : ""}>`;
584
+ };
585
+ renderer.link = ({ href, title, tokens }) => {
586
+ const text = renderer.parser.parseInline(tokens);
587
+ return `<a href="${href}" target="_blank"${title ? ` title="${title}"` : ""}${parseCssInJsToInlineCss(finalStyles.link) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.link)}"` : ""}>${text}</a>`;
588
+ };
589
+ renderer.listitem = ({ tokens }) => {
590
+ const text = tokens.some((token) => token.type === "list") ? renderer.parser.parse(tokens) : renderer.parser.parseInline(tokens);
591
+ return `<li${parseCssInJsToInlineCss(finalStyles.li) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.li)}"` : ""}>${text}</li>\n`;
592
+ };
593
+ renderer.list = ({ items, ordered, start }) => {
594
+ const type = ordered ? "ol" : "ul";
595
+ const startAt = ordered && start !== 1 ? ` start="${start}"` : "";
596
+ const styles = parseCssInJsToInlineCss(finalStyles[ordered ? "ol" : "ul"]);
597
+ return `<${type}${startAt}${styles !== "" ? ` style="${styles}"` : ""}>\n` + items.map((item) => renderer.listitem(item)).join("") + `</${type}>\n`;
598
+ };
599
+ renderer.paragraph = ({ tokens }) => {
600
+ const text = renderer.parser.parseInline(tokens);
601
+ return `<p${parseCssInJsToInlineCss(finalStyles.p) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.p)}"` : ""}>${text}</p>\n`;
602
+ };
603
+ renderer.strong = ({ tokens }) => {
604
+ const text = renderer.parser.parseInline(tokens);
605
+ return `<strong${parseCssInJsToInlineCss(finalStyles.bold) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.bold)}"` : ""}>${text}</strong>`;
606
+ };
607
+ renderer.table = ({ header, rows }) => {
608
+ const styleTable = parseCssInJsToInlineCss(finalStyles.table);
609
+ const styleThead = parseCssInJsToInlineCss(finalStyles.thead);
610
+ const styleTbody = parseCssInJsToInlineCss(finalStyles.tbody);
611
+ const theadRow = renderer.tablerow({ text: header.map((cell) => renderer.tablecell(cell)).join("") });
612
+ const tbodyRows = rows.map((row) => renderer.tablerow({ text: row.map((cell) => renderer.tablecell(cell)).join("") })).join("");
613
+ const thead = `<thead${styleThead ? ` style="${styleThead}"` : ""}>\n${theadRow}</thead>`;
614
+ const tbody = `<tbody${styleTbody ? ` style="${styleTbody}"` : ""}>${tbodyRows}</tbody>`;
615
+ return `<table${styleTable ? ` style="${styleTable}"` : ""}>\n${thead}\n${tbody}</table>\n`;
616
+ };
617
+ renderer.tablecell = ({ tokens, align, header }) => {
618
+ const text = renderer.parser.parseInline(tokens);
619
+ const type = header ? "th" : "td";
620
+ return `${align ? `<${type} align="${align}"${parseCssInJsToInlineCss(finalStyles.td) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.td)}"` : ""}>` : `<${type}${parseCssInJsToInlineCss(finalStyles.td) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.td)}"` : ""}>`}${text}</${type}>\n`;
621
+ };
622
+ renderer.tablerow = ({ text }) => {
623
+ return `<tr${parseCssInJsToInlineCss(finalStyles.tr) !== "" ? ` style="${parseCssInJsToInlineCss(finalStyles.tr)}"` : ""}>\n${text}</tr>\n`;
624
+ };
625
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
626
+ ...props,
627
+ dangerouslySetInnerHTML: { __html: marked.marked.parse(children, {
628
+ renderer,
629
+ async: false
630
+ }) },
631
+ ref,
632
+ style: markdownContainerStyles
633
+ });
634
+ });
635
+ Markdown.displayName = "Markdown";
636
+
637
+ //#endregion
638
+ //#region src/components/preview.tsx
639
+ const PREVIEW_MAX_LENGTH = 150;
640
+ const whiteSpaceCodes = "\xA0‌​‍‎‏";
641
+ const renderWhiteSpace = (text) => {
642
+ if (text.length >= PREVIEW_MAX_LENGTH) return null;
643
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { children: whiteSpaceCodes.repeat(PREVIEW_MAX_LENGTH - text.length) });
644
+ };
645
+ const Preview = react.forwardRef(({ children = "",...props }, ref) => {
646
+ const text = (Array.isArray(children) ? children.join("") : children).substring(0, PREVIEW_MAX_LENGTH);
647
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
648
+ style: {
649
+ display: "none",
650
+ overflow: "hidden",
651
+ lineHeight: "1px",
652
+ opacity: 0,
653
+ maxHeight: 0,
654
+ maxWidth: 0
655
+ },
656
+ ...props,
657
+ ref,
658
+ children: [text, renderWhiteSpace(text)]
659
+ });
660
+ });
661
+ Preview.displayName = "Preview";
662
+
663
+ //#endregion
664
+ //#region src/components/row.tsx
665
+ const Row = react.forwardRef(({ children, style,...props }, ref) => {
666
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("table", {
667
+ align: "center",
668
+ width: "100%",
669
+ border: 0,
670
+ cellPadding: "0",
671
+ cellSpacing: "0",
672
+ role: "presentation",
673
+ ...props,
674
+ ref,
675
+ style,
676
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tbody", {
677
+ style: { width: "100%" },
678
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tr", {
679
+ style: { width: "100%" },
680
+ children
681
+ })
682
+ })
683
+ });
684
+ });
685
+ Row.displayName = "Row";
686
+
687
+ //#endregion
688
+ //#region src/components/section.tsx
689
+ const Section = react.forwardRef(({ children, style,...props }, ref) => {
690
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("table", {
691
+ align: "center",
692
+ width: "100%",
693
+ border: 0,
694
+ cellPadding: "0",
695
+ cellSpacing: "0",
696
+ role: "presentation",
697
+ ...props,
698
+ ref,
699
+ style,
700
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tbody", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tr", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("td", { children }) }) })
701
+ });
702
+ });
703
+ Section.displayName = "Section";
704
+
705
+ //#endregion
706
+ //#region src/utils/compute-margins.ts
707
+ function parseMarginValue(value) {
708
+ if (typeof value === "number") return {
709
+ marginTop: value,
710
+ marginBottom: value,
711
+ marginLeft: value,
712
+ marginRight: value
713
+ };
714
+ if (typeof value === "string") {
715
+ const values = value.toString().trim().split(/\s+/);
716
+ if (values.length === 1) return {
717
+ marginTop: values[0],
718
+ marginBottom: values[0],
719
+ marginLeft: values[0],
720
+ marginRight: values[0]
721
+ };
722
+ if (values.length === 2) return {
723
+ marginTop: values[0],
724
+ marginRight: values[1],
725
+ marginBottom: values[0],
726
+ marginLeft: values[1]
727
+ };
728
+ if (values.length === 3) return {
729
+ marginTop: values[0],
730
+ marginRight: values[1],
731
+ marginBottom: values[2],
732
+ marginLeft: values[1]
733
+ };
734
+ if (values.length === 4) return {
735
+ marginTop: values[0],
736
+ marginRight: values[1],
737
+ marginBottom: values[2],
738
+ marginLeft: values[3]
739
+ };
740
+ }
741
+ return {
742
+ marginTop: void 0,
743
+ marginBottom: void 0,
744
+ marginLeft: void 0,
745
+ marginRight: void 0
746
+ };
747
+ }
748
+ function computeMargins(properties) {
749
+ let result = {
750
+ marginTop: void 0,
751
+ marginRight: void 0,
752
+ marginBottom: void 0,
753
+ marginLeft: void 0
754
+ };
755
+ for (const [key, value] of Object.entries(properties)) if (key === "margin") result = parseMarginValue(value);
756
+ else if (key === "marginTop") result.marginTop = value;
757
+ else if (key === "marginRight") result.marginRight = value;
758
+ else if (key === "marginBottom") result.marginBottom = value;
759
+ else if (key === "marginLeft") result.marginLeft = value;
760
+ return result;
761
+ }
762
+
763
+ //#endregion
764
+ //#region src/components/text.tsx
765
+ const Text = react.forwardRef(({ style,...props }, ref) => {
766
+ const defaultMargins = {};
767
+ if (style?.marginTop === void 0) defaultMargins.marginTop = "16px";
768
+ if (style?.marginBottom === void 0) defaultMargins.marginBottom = "16px";
769
+ const margins = computeMargins({
770
+ ...defaultMargins,
771
+ ...style
772
+ });
773
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
774
+ ...props,
775
+ ref,
776
+ style: {
777
+ fontSize: "14px",
778
+ lineHeight: "24px",
779
+ ...style,
780
+ ...margins
781
+ }
782
+ });
783
+ });
784
+ Text.displayName = "Text";
785
+
786
+ //#endregion
787
+ //#region src/render/plain-text-selectors.ts
788
+ const plainTextSelectors = [
789
+ {
790
+ selector: "img",
791
+ format: "skip"
792
+ },
793
+ {
794
+ selector: "[data-skip-in-text]",
795
+ format: "skip"
796
+ },
797
+ {
798
+ selector: "a",
799
+ options: { linkBrackets: false }
800
+ }
801
+ ];
802
+
803
+ //#endregion
804
+ //#region src/render/pretty.ts
805
+ async function pretty(html) {
806
+ return prettier_standalone.format(html, {
807
+ parser: "html",
808
+ plugins: [prettier_plugins_html],
809
+ htmlWhitespaceSensitivity: "ignore"
810
+ });
811
+ }
812
+
813
+ //#endregion
814
+ //#region src/render/read-stream.ts
815
+ async function readStream(stream) {
816
+ let result = "";
817
+ const decoder = new TextDecoder("utf-8");
818
+ if ("pipeTo" in stream) {
819
+ const writableStream = new WritableStream({
820
+ write(chunk) {
821
+ result += decoder.decode(chunk, { stream: true });
822
+ },
823
+ close() {
824
+ result += decoder.decode();
825
+ }
826
+ });
827
+ await stream.pipeTo(writableStream);
828
+ } else {
829
+ const writable = new node_stream.Writable({
830
+ write(chunk, _encoding, callback) {
831
+ result += decoder.decode(chunk, { stream: true });
832
+ callback();
833
+ },
834
+ final(callback) {
835
+ result += decoder.decode();
836
+ callback();
837
+ }
838
+ });
839
+ await new Promise((resolve, reject) => {
840
+ writable.on("pipe", (source) => {
841
+ source.on("error", (err) => {
842
+ writable.destroy(err);
843
+ });
844
+ });
845
+ writable.on("error", reject);
846
+ writable.on("close", () => {
847
+ resolve();
848
+ });
849
+ stream.pipe(writable);
850
+ });
851
+ }
852
+ return result;
853
+ }
854
+
855
+ //#endregion
856
+ //#region src/render/error-boundary.tsx
857
+ function createErrorBoundary(reject) {
858
+ if (!react.default.Component) return (props) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: props.children });
859
+ return class ErrorBoundary extends react.default.Component {
860
+ componentDidCatch(error) {
861
+ reject(error);
862
+ }
863
+ render() {
864
+ return this.props.children;
865
+ }
866
+ };
867
+ }
868
+
869
+ //#endregion
870
+ //#region src/render/render.tsx
871
+ const doctype = "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">";
872
+ async function render(element, options) {
873
+ const reactDOMServer = await import("react-dom/server").then((m) => {
874
+ if ("default" in m) return m.default;
875
+ return m;
876
+ });
877
+ let markup;
878
+ await new Promise((resolve, reject) => {
879
+ if (Object.hasOwn(reactDOMServer, "renderToReadableStream") && typeof WritableStream !== "undefined") {
880
+ const ErrorBoundary = createErrorBoundary(reject);
881
+ reactDOMServer.renderToReadableStream(/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorBoundary, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react.Suspense, { children: element }) }), {
882
+ progressiveChunkSize: Number.POSITIVE_INFINITY,
883
+ onError(error) {
884
+ throw error;
885
+ }
886
+ }).then((stream) => readStream(stream)).then((result) => {
887
+ markup = result;
888
+ resolve();
889
+ }).catch(reject);
890
+ } else {
891
+ const ErrorBoundary = createErrorBoundary(reject);
892
+ const stream = reactDOMServer.renderToPipeableStream(/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorBoundary, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react.Suspense, { children: element }) }), {
893
+ async onAllReady() {
894
+ markup = await readStream(stream);
895
+ resolve();
896
+ },
897
+ onError(error) {
898
+ reject(error);
899
+ },
900
+ progressiveChunkSize: Number.POSITIVE_INFINITY
901
+ });
902
+ }
903
+ });
904
+ if (options?.plainText) return (0, html_to_text.convert)(markup, {
905
+ selectors: plainTextSelectors,
906
+ ...options.plainText === true ? options.htmlToTextOptions : {}
907
+ });
908
+ const html = `${doctype}${markup.replace(/<!DOCTYPE.*?>/, "")}`;
909
+ if (options?.pretty) return pretty(html);
910
+ return html;
911
+ }
912
+
913
+ //#endregion
914
+ //#region src/tailwind/utils/is-rule-inlinable.ts
915
+ function isRuleInlinable(rule) {
916
+ const hasAtRuleInside = (0, css_tree.find)(rule, (node) => node.type === "Atrule") !== null;
917
+ const hasPseudoSelector = (0, css_tree.find)(rule, (node) => node.type === "PseudoClassSelector" || node.type === "PseudoElementSelector") !== null;
918
+ return !hasAtRuleInside && !hasPseudoSelector;
919
+ }
920
+
921
+ //#endregion
922
+ //#region src/tailwind/utils/is-part-inlinable.ts
923
+ function isPartInlinable(part) {
924
+ const hasAtRuleInside = (0, css_tree.find)(part, (node) => node.type === "Atrule") !== null;
925
+ const hasPseudoSelector = (0, css_tree.find)(part, (node) => node.type === "PseudoClassSelector" || node.type === "PseudoElementSelector") !== null;
926
+ return !hasAtRuleInside && !hasPseudoSelector;
927
+ }
928
+
929
+ //#endregion
930
+ //#region src/tailwind/utils/split-mixed-rule.ts
931
+ function splitMixedRule(rule) {
932
+ const ruleCloneInlinable = (0, css_tree.clone)(rule);
933
+ const ruleCloneNonInlinable = (0, css_tree.clone)(rule);
934
+ const inlinableParts = [];
935
+ const nonInlinableParts = [];
936
+ for (const part of ruleCloneInlinable.block.children.toArray()) if (isPartInlinable(part)) inlinableParts.push(part);
937
+ else nonInlinableParts.push(part);
938
+ return {
939
+ inlinablePart: inlinableParts.length > 0 ? {
940
+ ...ruleCloneInlinable,
941
+ block: {
942
+ type: "Block",
943
+ children: new css_tree.List().fromArray(inlinableParts)
944
+ }
945
+ } : null,
946
+ nonInlinablePart: nonInlinableParts.length > 0 ? {
947
+ ...ruleCloneNonInlinable,
948
+ block: {
949
+ type: "Block",
950
+ children: new css_tree.List().fromArray(nonInlinableParts)
951
+ }
952
+ } : null
953
+ };
954
+ }
955
+
956
+ //#endregion
957
+ //#region src/tailwind/utils/extract-rules-per-class.ts
958
+ function extractRulesPerClass(root, classes) {
959
+ const classSet = new Set(classes);
960
+ const inlinableRules = /* @__PURE__ */ new Map();
961
+ const nonInlinableRules = /* @__PURE__ */ new Map();
962
+ (0, css_tree.walk)(root, {
963
+ visit: "Rule",
964
+ enter(rule) {
965
+ const selectorClasses = [];
966
+ (0, css_tree.walk)(rule, {
967
+ visit: "ClassSelector",
968
+ enter(classSelector) {
969
+ selectorClasses.push(css_tree.string.decode(classSelector.name));
970
+ }
971
+ });
972
+ if (isRuleInlinable(rule)) {
973
+ for (const className of selectorClasses) if (classSet.has(className)) inlinableRules.set(className, rule);
974
+ } else {
975
+ const { inlinablePart, nonInlinablePart } = splitMixedRule(rule);
976
+ for (const className of selectorClasses) {
977
+ if (!classSet.has(className)) continue;
978
+ if (inlinablePart) inlinableRules.set(className, inlinablePart);
979
+ if (nonInlinablePart) nonInlinableRules.set(className, nonInlinablePart);
980
+ }
981
+ }
982
+ }
983
+ });
984
+ return {
985
+ inlinable: inlinableRules,
986
+ nonInlinable: nonInlinableRules
987
+ };
988
+ }
989
+
990
+ //#endregion
991
+ //#region src/tailwind/utils/get-custom-properties.ts
992
+ function getCustomProperties(node) {
993
+ const customProperties = /* @__PURE__ */ new Map();
994
+ (0, css_tree.walk)(node, {
995
+ visit: "Atrule",
996
+ enter(atrule) {
997
+ if (atrule.name === "property" && atrule.prelude) {
998
+ const prelude = (0, css_tree.generate)(atrule.prelude);
999
+ if (prelude.startsWith("--")) {
1000
+ let syntax;
1001
+ let inherits;
1002
+ let initialValue;
1003
+ (0, css_tree.walk)(atrule, {
1004
+ visit: "Declaration",
1005
+ enter(declaration) {
1006
+ if (declaration.property === "syntax") syntax = declaration;
1007
+ if (declaration.property === "inherits") inherits = declaration;
1008
+ if (declaration.property === "initial-value") initialValue = declaration;
1009
+ }
1010
+ });
1011
+ customProperties.set(prelude, {
1012
+ syntax,
1013
+ inherits,
1014
+ initialValue
1015
+ });
1016
+ }
1017
+ }
1018
+ }
1019
+ });
1020
+ return customProperties;
1021
+ }
1022
+
1023
+ //#endregion
1024
+ //#region src/tailwind/utils/from-dash-case-to-camel-case.ts
1025
+ const fromDashCaseToCamelCase = (text) => {
1026
+ return text.replace(/-(\w|$)/g, (_, p1) => p1.toUpperCase());
1027
+ };
1028
+
1029
+ //#endregion
1030
+ //#region src/tailwind/utils/get-react-property.ts
1031
+ function getReactProperty(prop) {
1032
+ const modifiedProp = prop.toLowerCase();
1033
+ if (modifiedProp.startsWith("--")) return modifiedProp;
1034
+ if (modifiedProp.startsWith("-ms-")) return fromDashCaseToCamelCase(modifiedProp.slice(1));
1035
+ return fromDashCaseToCamelCase(modifiedProp);
1036
+ }
1037
+
1038
+ //#endregion
1039
+ //#region src/tailwind/utils/unwrap-value.ts
1040
+ function unwrapValue(value) {
1041
+ if (value.type === "Value" && value.children.size === 1) return value.children.first ?? value;
1042
+ return value;
1043
+ }
1044
+
1045
+ //#endregion
1046
+ //#region src/tailwind/utils/make-inline-styles-for.ts
1047
+ function makeInlineStylesFor(inlinableRules, customProperties) {
1048
+ const styles = {};
1049
+ const localVariableDeclarations = /* @__PURE__ */ new Map();
1050
+ for (const rule of inlinableRules) (0, css_tree.walk)(rule, {
1051
+ visit: "Declaration",
1052
+ enter(declaration) {
1053
+ if (declaration.property.startsWith("--")) localVariableDeclarations.set(declaration.property, declaration);
1054
+ }
1055
+ });
1056
+ for (const rule of inlinableRules) {
1057
+ (0, css_tree.walk)(rule, {
1058
+ visit: "Function",
1059
+ enter(func, funcParentListItem) {
1060
+ if (func.name === "var") {
1061
+ let variableName;
1062
+ (0, css_tree.walk)(func, {
1063
+ visit: "Identifier",
1064
+ enter(identifier) {
1065
+ variableName = identifier.name;
1066
+ return this.break;
1067
+ }
1068
+ });
1069
+ if (variableName) {
1070
+ const definition = localVariableDeclarations.get(variableName);
1071
+ if (definition) funcParentListItem.data = unwrapValue(definition.value);
1072
+ else {
1073
+ const customProperty = customProperties.get(variableName);
1074
+ if (customProperty?.initialValue) funcParentListItem.data = unwrapValue(customProperty.initialValue.value);
1075
+ }
1076
+ }
1077
+ }
1078
+ }
1079
+ });
1080
+ (0, css_tree.walk)(rule, {
1081
+ visit: "Declaration",
1082
+ enter(declaration) {
1083
+ if (declaration.property.startsWith("--")) return;
1084
+ styles[getReactProperty(declaration.property)] = (0, css_tree.generate)(declaration.value) + (declaration.important ? "!important" : "");
1085
+ }
1086
+ });
1087
+ }
1088
+ return styles;
1089
+ }
1090
+
1091
+ //#endregion
1092
+ //#region src/tailwind/utils/resolve-all-css-variables.ts
1093
+ function doSelectorsIntersect(first, second) {
1094
+ if ((0, css_tree.generate)(first) === (0, css_tree.generate)(second)) return true;
1095
+ let hasSomeUniversal = false;
1096
+ const walker = (node, _parentListItem, parentList) => {
1097
+ if (hasSomeUniversal) return;
1098
+ if (node.type === "PseudoClassSelector" && node.name === "root") hasSomeUniversal = true;
1099
+ if (node.type === "TypeSelector" && node.name === "*" && parentList.size === 1) hasSomeUniversal = true;
1100
+ };
1101
+ (0, css_tree.walk)(first, walker);
1102
+ (0, css_tree.walk)(second, walker);
1103
+ if (hasSomeUniversal) return true;
1104
+ return false;
1105
+ }
1106
+ function resolveAllCssVariables(node) {
1107
+ const variableDefinitions = /* @__PURE__ */ new Set();
1108
+ const variableUses = /* @__PURE__ */ new Set();
1109
+ const path = [];
1110
+ (0, css_tree.walk)(node, {
1111
+ leave() {
1112
+ path.shift();
1113
+ },
1114
+ enter(node$1) {
1115
+ if (node$1.type === "Declaration") {
1116
+ const declaration = node$1;
1117
+ if (path.some((ancestor) => ancestor.type === "Atrule" && ancestor.name === "layer" && ancestor.prelude !== null && (0, css_tree.generate)(ancestor.prelude).includes("properties"))) {
1118
+ path.unshift(node$1);
1119
+ return;
1120
+ }
1121
+ if (/--[\S]+/.test(declaration.property)) variableDefinitions.add({
1122
+ declaration,
1123
+ path: [...path],
1124
+ variableName: declaration.property,
1125
+ definition: (0, css_tree.generate)(declaration.value)
1126
+ });
1127
+ else {
1128
+ function parseVariableUsesFrom(node$2) {
1129
+ (0, css_tree.walk)(node$2, {
1130
+ visit: "Function",
1131
+ enter(funcNode) {
1132
+ if (funcNode.name === "var") {
1133
+ const children = funcNode.children.toArray();
1134
+ const name = (0, css_tree.generate)(children[0]);
1135
+ const fallback = children[2] ? (0, css_tree.generate)(children[2]) : void 0;
1136
+ variableUses.add({
1137
+ declaration,
1138
+ path: [...path],
1139
+ fallback,
1140
+ variableName: name,
1141
+ raw: (0, css_tree.generate)(funcNode)
1142
+ });
1143
+ if (fallback?.includes("var(")) parseVariableUsesFrom((0, css_tree.parse)(fallback, { context: "value" }));
1144
+ }
1145
+ }
1146
+ });
1147
+ }
1148
+ parseVariableUsesFrom(declaration.value);
1149
+ }
1150
+ }
1151
+ path.unshift(node$1);
1152
+ }
1153
+ });
1154
+ for (const use of variableUses) {
1155
+ let hasReplaced = false;
1156
+ for (const definition of variableDefinitions) {
1157
+ if (use.variableName !== definition.variableName) continue;
1158
+ if (use.path[0]?.type === "Block" && use.path[1]?.type === "Atrule" && use.path[2]?.type === "Block" && use.path[3]?.type === "Rule" && definition.path[0].type === "Block" && definition.path[1].type === "Rule" && doSelectorsIntersect(use.path[3].prelude, definition.path[1].prelude)) {
1159
+ use.declaration.value = (0, css_tree.parse)((0, css_tree.generate)(use.declaration.value).replaceAll(use.raw, definition.definition), { context: "value" });
1160
+ hasReplaced = true;
1161
+ break;
1162
+ }
1163
+ if (use.path[0]?.type === "Block" && use.path[1]?.type === "Rule" && definition.path[0]?.type === "Block" && definition.path[1]?.type === "Rule" && doSelectorsIntersect(use.path[1].prelude, definition.path[1].prelude)) {
1164
+ use.declaration.value = (0, css_tree.parse)((0, css_tree.generate)(use.declaration.value).replaceAll(use.raw, definition.definition), { context: "value" });
1165
+ hasReplaced = true;
1166
+ break;
1167
+ }
1168
+ }
1169
+ if (!hasReplaced && use.fallback) use.declaration.value = (0, css_tree.parse)((0, css_tree.generate)(use.declaration.value).replaceAll(use.raw, use.fallback), { context: "value" });
1170
+ }
1171
+ }
1172
+
1173
+ //#endregion
1174
+ //#region src/tailwind/utils/resolve-calc-expressions.ts
1175
+ /**
1176
+ * Intentionally only resolves `*` and `/` operations without dealing with parenthesis,
1177
+ * because this is the only thing required to run Tailwind v4.
1178
+ */
1179
+ function resolveCalcExpressions(node) {
1180
+ (0, css_tree.walk)(node, {
1181
+ visit: "Function",
1182
+ enter(func, funcListItem) {
1183
+ if (func.name === "calc") {
1184
+ func.children.forEach((child, item) => {
1185
+ const left = item.prev;
1186
+ const right = item.next;
1187
+ if (left && right && child.type === "Operator" && (left.data.type === "Dimension" || left.data.type === "Number" || left.data.type === "Percentage") && (right.data.type === "Dimension" || right.data.type === "Number" || right.data.type === "Percentage")) {
1188
+ if (child.value === "*" || child.value === "/") {
1189
+ const value = (() => {
1190
+ if (child.value === "*") return String(Number.parseFloat(left.data.value) * Number.parseFloat(right.data.value));
1191
+ if (right.data.value === "0") return "0";
1192
+ return String(Number.parseFloat(left.data.value) / Number.parseFloat(right.data.value));
1193
+ })();
1194
+ if (left.data.type === "Dimension" && right.data.type === "Number") {
1195
+ item.data = {
1196
+ type: "Dimension",
1197
+ unit: left.data.unit,
1198
+ value
1199
+ };
1200
+ func.children.remove(left);
1201
+ func.children.remove(right);
1202
+ } else if (left.data.type === "Number" && right.data.type === "Dimension") {
1203
+ item.data = {
1204
+ type: "Dimension",
1205
+ unit: right.data.unit,
1206
+ value
1207
+ };
1208
+ func.children.remove(left);
1209
+ func.children.remove(right);
1210
+ } else if (left.data.type === "Number" && right.data.type === "Number") {
1211
+ item.data = {
1212
+ type: "Number",
1213
+ value
1214
+ };
1215
+ func.children.remove(left);
1216
+ func.children.remove(right);
1217
+ } else if (left.data.type === "Dimension" && right.data.type === "Dimension" && left.data.unit === right.data.unit) {
1218
+ if (child.value === "/") item.data = {
1219
+ type: "Number",
1220
+ value
1221
+ };
1222
+ else item.data = {
1223
+ type: "Dimension",
1224
+ unit: left.data.unit,
1225
+ value
1226
+ };
1227
+ func.children.remove(left);
1228
+ func.children.remove(right);
1229
+ } else if (left.data.type === "Percentage" && right.data.type === "Number") {
1230
+ item.data = {
1231
+ type: "Percentage",
1232
+ value
1233
+ };
1234
+ func.children.remove(left);
1235
+ func.children.remove(right);
1236
+ } else if (left.data.type === "Number" && right.data.type === "Percentage") {
1237
+ item.data = {
1238
+ type: "Percentage",
1239
+ value
1240
+ };
1241
+ func.children.remove(left);
1242
+ func.children.remove(right);
1243
+ } else if (left.data.type === "Percentage" && right.data.type === "Percentage") {
1244
+ if (child.value === "/") item.data = {
1245
+ type: "Number",
1246
+ value
1247
+ };
1248
+ else item.data = {
1249
+ type: "Percentage",
1250
+ value
1251
+ };
1252
+ func.children.remove(left);
1253
+ func.children.remove(right);
1254
+ }
1255
+ }
1256
+ }
1257
+ });
1258
+ if (func.children.size === 1 && func.children.first) funcListItem.data = func.children.first;
1259
+ }
1260
+ }
1261
+ });
1262
+ }
1263
+
1264
+ //#endregion
1265
+ //#region src/tailwind/utils/sanitize-declarations.ts
1266
+ function rgbNode(r, g, b, alpha) {
1267
+ const children = new css_tree.List();
1268
+ children.appendData({
1269
+ type: "Number",
1270
+ value: r.toFixed(0)
1271
+ });
1272
+ children.appendData({
1273
+ type: "Operator",
1274
+ value: ","
1275
+ });
1276
+ children.appendData({
1277
+ type: "Number",
1278
+ value: g.toFixed(0)
1279
+ });
1280
+ children.appendData({
1281
+ type: "Operator",
1282
+ value: ","
1283
+ });
1284
+ children.appendData({
1285
+ type: "Number",
1286
+ value: b.toFixed(0)
1287
+ });
1288
+ if (alpha !== 1 && alpha !== void 0) {
1289
+ children.appendData({
1290
+ type: "Operator",
1291
+ value: ","
1292
+ });
1293
+ children.appendData({
1294
+ type: "Number",
1295
+ value: alpha.toString()
1296
+ });
1297
+ }
1298
+ return {
1299
+ type: "Function",
1300
+ name: "rgb",
1301
+ children
1302
+ };
1303
+ }
1304
+ const LAB_TO_LMS = {
1305
+ l: [.3963377773761749, .2158037573099136],
1306
+ m: [-.1055613458156586, -.0638541728258133],
1307
+ s: [-.0894841775298119, -1.2914855480194092]
1308
+ };
1309
+ const LSM_TO_RGB = {
1310
+ r: [
1311
+ 4.076741636075958,
1312
+ -3.307711539258063,
1313
+ .2309699031821043
1314
+ ],
1315
+ g: [
1316
+ -1.2684379732850315,
1317
+ 2.609757349287688,
1318
+ -.341319376002657
1319
+ ],
1320
+ b: [
1321
+ -.0041960761386756,
1322
+ -.7034186179359362,
1323
+ 1.7076146940746117
1324
+ ]
1325
+ };
1326
+ function lrgbToRgb(input) {
1327
+ const absoluteNumber = Math.abs(input);
1328
+ const sign = input < 0 ? -1 : 1;
1329
+ if (absoluteNumber > .0031308) return sign * (absoluteNumber ** (1 / 2.4) * 1.055 - .055);
1330
+ return input * 12.92;
1331
+ }
1332
+ function clamp(value, min, max) {
1333
+ return Math.min(Math.max(value, min), max);
1334
+ }
1335
+ function oklchToOklab(oklch) {
1336
+ return {
1337
+ l: oklch.l,
1338
+ a: oklch.c * Math.cos(oklch.h / 180 * Math.PI),
1339
+ b: oklch.c * Math.sin(oklch.h / 180 * Math.PI)
1340
+ };
1341
+ }
1342
+ /** Convert oklch to RGB */
1343
+ function oklchToRgb(oklch) {
1344
+ const oklab = oklchToOklab(oklch);
1345
+ const l = (oklab.l + LAB_TO_LMS.l[0] * oklab.a + LAB_TO_LMS.l[1] * oklab.b) ** 3;
1346
+ const m = (oklab.l + LAB_TO_LMS.m[0] * oklab.a + LAB_TO_LMS.m[1] * oklab.b) ** 3;
1347
+ const s = (oklab.l + LAB_TO_LMS.s[0] * oklab.a + LAB_TO_LMS.s[1] * oklab.b) ** 3;
1348
+ const r = 255 * lrgbToRgb(LSM_TO_RGB.r[0] * l + LSM_TO_RGB.r[1] * m + LSM_TO_RGB.r[2] * s);
1349
+ const g = 255 * lrgbToRgb(LSM_TO_RGB.g[0] * l + LSM_TO_RGB.g[1] * m + LSM_TO_RGB.g[2] * s);
1350
+ const b = 255 * lrgbToRgb(LSM_TO_RGB.b[0] * l + LSM_TO_RGB.b[1] * m + LSM_TO_RGB.b[2] * s);
1351
+ return {
1352
+ r: clamp(r, 0, 255),
1353
+ g: clamp(g, 0, 255),
1354
+ b: clamp(b, 0, 255)
1355
+ };
1356
+ }
1357
+ function separateShorthandDeclaration(shorthandToReplace, [start, end]) {
1358
+ shorthandToReplace.property = start;
1359
+ const values = shorthandToReplace.value.type === "Value" ? shorthandToReplace.value.children.toArray().filter((child) => child.type === "Dimension" || child.type === "Number" || child.type === "Percentage") : [shorthandToReplace.value];
1360
+ let endValue = shorthandToReplace.value;
1361
+ if (values.length === 2) {
1362
+ endValue = {
1363
+ type: "Value",
1364
+ children: new css_tree.List().fromArray([values[1]])
1365
+ };
1366
+ shorthandToReplace.value = {
1367
+ type: "Value",
1368
+ children: new css_tree.List().fromArray([values[0]])
1369
+ };
1370
+ }
1371
+ return {
1372
+ type: "Declaration",
1373
+ property: end,
1374
+ value: endValue,
1375
+ important: shorthandToReplace.important
1376
+ };
1377
+ }
1378
+ /**
1379
+ * Does all the necessary transformations on a per-declaration basis to have the best email client
1380
+ * support possible:
1381
+ * - convert `rgb` with space-based syntax into comma-based
1382
+ * - convert `oklch` values into `rgb`
1383
+ * - convert hex values into `rgb`
1384
+ * - convert `color-mix(in oklab, rgb(...) opacity, transparent)` into `rgb` with alpha
1385
+ * - convert `padding-inline` into `padding-left` and `padding-right`
1386
+ * - convert `padding-block` into `padding-top` and `padding-bottom`
1387
+ * - convert `margin-inline` into `margin-left` and `margin-right`
1388
+ * - convert `margin-block` into `margin-top` and `margin-bottom`
1389
+ * - convert `border-radius: calc(infinity * 1px)` into `border-radius: 9999px`
1390
+ */
1391
+ function sanitizeDeclarations(nodeContainingDeclarations) {
1392
+ (0, css_tree.walk)(nodeContainingDeclarations, {
1393
+ visit: "Declaration",
1394
+ enter(declaration, item, list) {
1395
+ if (declaration.value.type === "Raw") declaration.value = (0, css_tree.parse)(declaration.value.value, { context: "value" });
1396
+ if (/border-radius\s*:\s*calc\s*\(\s*infinity\s*\*\s*1px\s*\)/i.test((0, css_tree.generate)(declaration))) declaration.value = (0, css_tree.parse)("9999px", { context: "value" });
1397
+ (0, css_tree.walk)(declaration, {
1398
+ visit: "Function",
1399
+ enter(func, funcParentListItem) {
1400
+ const children = func.children.toArray();
1401
+ if (func.name === "oklch") {
1402
+ let l;
1403
+ let c;
1404
+ let h;
1405
+ let a;
1406
+ for (const child of children) {
1407
+ if (child.type === "Number") {
1408
+ if (l === void 0) {
1409
+ l = Number.parseFloat(child.value);
1410
+ continue;
1411
+ }
1412
+ if (c === void 0) {
1413
+ c = Number.parseFloat(child.value);
1414
+ continue;
1415
+ }
1416
+ if (h === void 0) {
1417
+ h = Number.parseFloat(child.value);
1418
+ continue;
1419
+ }
1420
+ if (a === void 0) {
1421
+ a = Number.parseFloat(child.value);
1422
+ continue;
1423
+ }
1424
+ }
1425
+ if (child.type === "Dimension" && child.unit === "deg") {
1426
+ if (h === void 0) {
1427
+ h = Number.parseFloat(child.value);
1428
+ continue;
1429
+ }
1430
+ }
1431
+ if (child.type === "Percentage") {
1432
+ if (l === void 0) {
1433
+ l = Number.parseFloat(child.value) / 100;
1434
+ continue;
1435
+ }
1436
+ if (a === void 0) a = Number.parseFloat(child.value) / 100;
1437
+ }
1438
+ }
1439
+ if (l === void 0 || c === void 0 || h === void 0) throw new Error("Could not determine the parameters of an oklch() function.", { cause: declaration });
1440
+ const rgb = oklchToRgb({
1441
+ l,
1442
+ c,
1443
+ h
1444
+ });
1445
+ funcParentListItem.data = rgbNode(rgb.r, rgb.g, rgb.b, a);
1446
+ }
1447
+ if (func.name === "rgb") {
1448
+ let r;
1449
+ let g;
1450
+ let b;
1451
+ let a;
1452
+ for (const child of children) {
1453
+ if (child.type === "Number") {
1454
+ if (r === void 0) {
1455
+ r = Number.parseFloat(child.value);
1456
+ continue;
1457
+ }
1458
+ if (g === void 0) {
1459
+ g = Number.parseFloat(child.value);
1460
+ continue;
1461
+ }
1462
+ if (b === void 0) {
1463
+ b = Number.parseFloat(child.value);
1464
+ continue;
1465
+ }
1466
+ if (a === void 0) {
1467
+ a = Number.parseFloat(child.value);
1468
+ continue;
1469
+ }
1470
+ }
1471
+ if (child.type === "Percentage") {
1472
+ if (r === void 0) {
1473
+ r = Number.parseFloat(child.value) * 255 / 100;
1474
+ continue;
1475
+ }
1476
+ if (g === void 0) {
1477
+ g = Number.parseFloat(child.value) * 255 / 100;
1478
+ continue;
1479
+ }
1480
+ if (b === void 0) {
1481
+ b = Number.parseFloat(child.value) * 255 / 100;
1482
+ continue;
1483
+ }
1484
+ if (a === void 0) a = Number.parseFloat(child.value) / 100;
1485
+ }
1486
+ }
1487
+ if (r === void 0 || g === void 0 || b === void 0) throw new Error("Could not determine the parameters of an rgb() function.", { cause: declaration });
1488
+ if (a === void 0 || a === 1) funcParentListItem.data = rgbNode(r, g, b);
1489
+ else funcParentListItem.data = rgbNode(r, g, b, a);
1490
+ }
1491
+ }
1492
+ });
1493
+ (0, css_tree.walk)(declaration, {
1494
+ visit: "Hash",
1495
+ enter(hash, hashParentListItem) {
1496
+ const hex = hash.value.trim();
1497
+ if (hex.length === 3) {
1498
+ hashParentListItem.data = rgbNode(Number.parseInt(hex.charAt(0) + hex.charAt(0), 16), Number.parseInt(hex.charAt(1) + hex.charAt(1), 16), Number.parseInt(hex.charAt(2) + hex.charAt(2), 16));
1499
+ return;
1500
+ }
1501
+ if (hex.length === 4) {
1502
+ hashParentListItem.data = rgbNode(Number.parseInt(hex.charAt(0) + hex.charAt(0), 16), Number.parseInt(hex.charAt(1) + hex.charAt(1), 16), Number.parseInt(hex.charAt(2) + hex.charAt(2), 16), Number.parseInt(hex.charAt(3) + hex.charAt(3), 16) / 255);
1503
+ return;
1504
+ }
1505
+ if (hex.length === 5) {
1506
+ hashParentListItem.data = rgbNode(Number.parseInt(hex.slice(0, 2), 16), Number.parseInt(hex.charAt(2) + hex.charAt(2), 16), Number.parseInt(hex.charAt(3) + hex.charAt(3), 16), Number.parseInt(hex.charAt(4) + hex.charAt(4), 16) / 255);
1507
+ return;
1508
+ }
1509
+ if (hex.length === 6) {
1510
+ hashParentListItem.data = rgbNode(Number.parseInt(hex.slice(0, 2), 16), Number.parseInt(hex.slice(2, 4), 16), Number.parseInt(hex.slice(4, 6), 16));
1511
+ return;
1512
+ }
1513
+ if (hex.length === 7) {
1514
+ hashParentListItem.data = rgbNode(Number.parseInt(hex.slice(0, 2), 16), Number.parseInt(hex.slice(2, 4), 16), Number.parseInt(hex.slice(4, 6), 16), Number.parseInt(hex.charAt(6) + hex.charAt(6), 16) / 255);
1515
+ return;
1516
+ }
1517
+ hashParentListItem.data = rgbNode(Number.parseInt(hex.slice(0, 2), 16), Number.parseInt(hex.slice(2, 4), 16), Number.parseInt(hex.slice(4, 6), 16), Number.parseInt(hex.slice(6, 8), 16) / 255);
1518
+ }
1519
+ });
1520
+ (0, css_tree.walk)(declaration, {
1521
+ visit: "Function",
1522
+ enter(func, parentListItem) {
1523
+ if (func.name === "color-mix") {
1524
+ const children = func.children.toArray();
1525
+ const color = children[3];
1526
+ const opacity = children[4];
1527
+ if (func.children.last?.type === "Identifier" && func.children.last.name === "transparent" && color?.type === "Function" && color?.name === "rgb" && opacity) {
1528
+ color.children.appendData({
1529
+ type: "Operator",
1530
+ value: ","
1531
+ });
1532
+ color.children.appendData(opacity);
1533
+ parentListItem.data = color;
1534
+ }
1535
+ }
1536
+ }
1537
+ });
1538
+ if (declaration.property === "padding-inline") {
1539
+ const paddingRight = separateShorthandDeclaration(declaration, ["padding-left", "padding-right"]);
1540
+ list.insertData(paddingRight, item);
1541
+ }
1542
+ if (declaration.property === "padding-block") {
1543
+ const paddingBottom = separateShorthandDeclaration(declaration, ["padding-top", "padding-bottom"]);
1544
+ list.insertData(paddingBottom, item);
1545
+ }
1546
+ if (declaration.property === "margin-inline") {
1547
+ const marginRight = separateShorthandDeclaration(declaration, ["margin-left", "margin-right"]);
1548
+ list.insertData(marginRight, item);
1549
+ }
1550
+ if (declaration.property === "margin-block") {
1551
+ const marginBottom = separateShorthandDeclaration(declaration, ["margin-top", "margin-bottom"]);
1552
+ list.insertData(marginBottom, item);
1553
+ }
1554
+ }
1555
+ });
1556
+ }
1557
+
1558
+ //#endregion
1559
+ //#region src/tailwind/sanitize-stylesheet.ts
1560
+ function sanitizeStyleSheet(styleSheet) {
1561
+ resolveAllCssVariables(styleSheet);
1562
+ resolveCalcExpressions(styleSheet);
1563
+ sanitizeDeclarations(styleSheet);
1564
+ }
1565
+
1566
+ //#endregion
1567
+ //#region src/tailwind/use-suspended-promise.ts
1568
+ const promiseStates = /* @__PURE__ */ new Map();
1569
+ function useSuspensedPromise(promiseFn, key) {
1570
+ const previousState = promiseStates.get(key);
1571
+ if (previousState) {
1572
+ if ("error" in previousState) throw previousState.error;
1573
+ if ("result" in previousState) return previousState.result;
1574
+ throw previousState.promise;
1575
+ }
1576
+ const state = { promise: promiseFn().then((result) => state.result = result).catch((error) => state.error = error) };
1577
+ promiseStates.set(key, state);
1578
+ throw state.promise;
1579
+ }
1580
+
1581
+ //#endregion
1582
+ //#region src/tailwind/utils/sanitize-class-name.ts
1583
+ const digitToNameMap = {
1584
+ "0": "zero",
1585
+ "1": "one",
1586
+ "2": "two",
1587
+ "3": "three",
1588
+ "4": "four",
1589
+ "5": "five",
1590
+ "6": "six",
1591
+ "7": "seven",
1592
+ "8": "eight",
1593
+ "9": "nine"
1594
+ };
1595
+ function sanitizeClassName(className) {
1596
+ return className.replaceAll("+", "plus").replaceAll("[", "").replaceAll("%", "pc").replaceAll("]", "").replaceAll("(", "").replaceAll(")", "").replaceAll("!", "imprtnt").replaceAll(">", "gt").replaceAll("<", "lt").replaceAll("=", "eq").replace(/^[0-9]/, (digit) => {
1597
+ return digitToNameMap[digit];
1598
+ }).replace(/[^a-zA-Z0-9\-_]/g, "_");
1599
+ }
1600
+
1601
+ //#endregion
1602
+ //#region src/tailwind/utils/sanitize-non-inlinable-rules.ts
1603
+ /**
1604
+ * Ensures the best email client support for non-inlinable rules:
1605
+ * 1. Converts all declarations in non-inlinable rules into !important
1606
+ * 2. Sanitizes class selectors of all non-inlinable rules
1607
+ */
1608
+ function sanitizeNonInlinableRules(node) {
1609
+ (0, css_tree.walk)(node, {
1610
+ visit: "Rule",
1611
+ enter(rule) {
1612
+ if (!isRuleInlinable(rule)) {
1613
+ (0, css_tree.walk)(rule.prelude, (node$1) => {
1614
+ if (node$1.type === "ClassSelector") node$1.name = sanitizeClassName(css_tree.string.decode(node$1.name));
1615
+ });
1616
+ (0, css_tree.walk)(rule, {
1617
+ visit: "Declaration",
1618
+ enter(declaration) {
1619
+ declaration.important = true;
1620
+ }
1621
+ });
1622
+ }
1623
+ }
1624
+ });
1625
+ }
1626
+
1627
+ //#endregion
1628
+ //#region src/tailwind/is-component.ts
1629
+ /**
1630
+ * Components that render standard HTML elements and should be treated as
1631
+ * elements (not traversed through) by the Tailwind tree mapper.
1632
+ */
1633
+ const componentsToTreatAsElements = [
1634
+ Body,
1635
+ Button,
1636
+ Container,
1637
+ Heading,
1638
+ Hr,
1639
+ Img,
1640
+ Link,
1641
+ Preview,
1642
+ Text
1643
+ ];
1644
+ const isComponent = (element) => {
1645
+ return (typeof element.type === "function" || element.type.render !== void 0) && !componentsToTreatAsElements.includes(element.type);
1646
+ };
1647
+
1648
+ //#endregion
1649
+ //#region src/tailwind/map-react-tree.ts
1650
+ /**
1651
+ * Deep maps a React tree from a node, even through its components.
1652
+ * For all the components it finds, it renders them by directly calling them.
1653
+ *
1654
+ * @param process - Callback called every time a new element has been reached.
1655
+ * For components, this is called both before rendering (on props.children)
1656
+ * and after rendering.
1657
+ */
1658
+ function mapReactTree(value, process) {
1659
+ const mapped = react.default.Children.map(value, (node) => {
1660
+ if (react.default.isValidElement(node)) {
1661
+ const newProps = { ...node.props };
1662
+ if (node.props.children && !isComponent(node)) newProps.children = mapReactTree(node.props.children, process);
1663
+ const processed = process(react.default.cloneElement(node, newProps, newProps.children));
1664
+ if (react.default.isValidElement(processed) && isComponent(processed)) return mapReactTree((typeof processed.type === "object" ? processed.type.render : processed.type)(processed.props), process);
1665
+ return processed;
1666
+ }
1667
+ return process(node);
1668
+ });
1669
+ return mapped && mapped.length === 1 ? mapped[0] : mapped;
1670
+ }
1671
+
1672
+ //#endregion
1673
+ //#region src/tailwind/clone-element-with-inlined-styles.ts
1674
+ function cloneElementWithInlinedStyles(element, inlinableRules, nonInlinableRules, customProperties) {
1675
+ const propsToOverwrite = {};
1676
+ if (element.props.className && !isComponent(element)) {
1677
+ const classes = element.props.className.trim().split(/\s+/);
1678
+ const residualClasses = [];
1679
+ const rules = [];
1680
+ for (const className of classes) {
1681
+ const rule = inlinableRules.get(className);
1682
+ if (rule) rules.push(rule);
1683
+ if (nonInlinableRules.has(className)) residualClasses.push(className);
1684
+ else if (!rule) residualClasses.push(className);
1685
+ }
1686
+ propsToOverwrite.style = {
1687
+ ...makeInlineStylesFor(rules, customProperties),
1688
+ ...element.props.style
1689
+ };
1690
+ if (residualClasses.length > 0) propsToOverwrite.className = residualClasses.map((className) => {
1691
+ if (nonInlinableRules.has(className)) return sanitizeClassName(className);
1692
+ return className;
1693
+ }).join(" ");
1694
+ else propsToOverwrite.className = void 0;
1695
+ }
1696
+ const newProps = {
1697
+ ...element.props,
1698
+ ...propsToOverwrite
1699
+ };
1700
+ return react.default.cloneElement(element, newProps, newProps.children);
1701
+ }
1702
+
1703
+ //#endregion
1704
+ //#region src/tailwind/css/index.ts
1705
+ const css$3 = `
1706
+ @layer theme, base, components, utilities;
1707
+
1708
+ @layer theme {
1709
+ @theme default {
1710
+ --font-sans:
1711
+ ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji",
1712
+ "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
1713
+ --font-serif: ui-serif, Georgia, Cambria, "Times New Roman", Times, serif;
1714
+ --font-mono:
1715
+ ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
1716
+ "Courier New", monospace;
1717
+
1718
+ --color-red-50: oklch(97.1% 0.013 17.38);
1719
+ --color-red-100: oklch(93.6% 0.032 17.717);
1720
+ --color-red-200: oklch(88.5% 0.062 18.334);
1721
+ --color-red-300: oklch(80.8% 0.114 19.571);
1722
+ --color-red-400: oklch(70.4% 0.191 22.216);
1723
+ --color-red-500: oklch(63.7% 0.237 25.331);
1724
+ --color-red-600: oklch(57.7% 0.245 27.325);
1725
+ --color-red-700: oklch(50.5% 0.213 27.518);
1726
+ --color-red-800: oklch(44.4% 0.177 26.899);
1727
+ --color-red-900: oklch(39.6% 0.141 25.723);
1728
+ --color-red-950: oklch(25.8% 0.092 26.042);
1729
+
1730
+ --color-orange-50: oklch(98% 0.016 73.684);
1731
+ --color-orange-100: oklch(95.4% 0.038 75.164);
1732
+ --color-orange-200: oklch(90.1% 0.076 70.697);
1733
+ --color-orange-300: oklch(83.7% 0.128 66.29);
1734
+ --color-orange-400: oklch(75% 0.183 55.934);
1735
+ --color-orange-500: oklch(70.5% 0.213 47.604);
1736
+ --color-orange-600: oklch(64.6% 0.222 41.116);
1737
+ --color-orange-700: oklch(55.3% 0.195 38.402);
1738
+ --color-orange-800: oklch(47% 0.157 37.304);
1739
+ --color-orange-900: oklch(40.8% 0.123 38.172);
1740
+ --color-orange-950: oklch(26.6% 0.079 36.259);
1741
+
1742
+ --color-amber-50: oklch(98.7% 0.022 95.277);
1743
+ --color-amber-100: oklch(96.2% 0.059 95.617);
1744
+ --color-amber-200: oklch(92.4% 0.12 95.746);
1745
+ --color-amber-300: oklch(87.9% 0.169 91.605);
1746
+ --color-amber-400: oklch(82.8% 0.189 84.429);
1747
+ --color-amber-500: oklch(76.9% 0.188 70.08);
1748
+ --color-amber-600: oklch(66.6% 0.179 58.318);
1749
+ --color-amber-700: oklch(55.5% 0.163 48.998);
1750
+ --color-amber-800: oklch(47.3% 0.137 46.201);
1751
+ --color-amber-900: oklch(41.4% 0.112 45.904);
1752
+ --color-amber-950: oklch(27.9% 0.077 45.635);
1753
+
1754
+ --color-yellow-50: oklch(98.7% 0.026 102.212);
1755
+ --color-yellow-100: oklch(97.3% 0.071 103.193);
1756
+ --color-yellow-200: oklch(94.5% 0.129 101.54);
1757
+ --color-yellow-300: oklch(90.5% 0.182 98.111);
1758
+ --color-yellow-400: oklch(85.2% 0.199 91.936);
1759
+ --color-yellow-500: oklch(79.5% 0.184 86.047);
1760
+ --color-yellow-600: oklch(68.1% 0.162 75.834);
1761
+ --color-yellow-700: oklch(55.4% 0.135 66.442);
1762
+ --color-yellow-800: oklch(47.6% 0.114 61.907);
1763
+ --color-yellow-900: oklch(42.1% 0.095 57.708);
1764
+ --color-yellow-950: oklch(28.6% 0.066 53.813);
1765
+
1766
+ --color-lime-50: oklch(98.6% 0.031 120.757);
1767
+ --color-lime-100: oklch(96.7% 0.067 122.328);
1768
+ --color-lime-200: oklch(93.8% 0.127 124.321);
1769
+ --color-lime-300: oklch(89.7% 0.196 126.665);
1770
+ --color-lime-400: oklch(84.1% 0.238 128.85);
1771
+ --color-lime-500: oklch(76.8% 0.233 130.85);
1772
+ --color-lime-600: oklch(64.8% 0.2 131.684);
1773
+ --color-lime-700: oklch(53.2% 0.157 131.589);
1774
+ --color-lime-800: oklch(45.3% 0.124 130.933);
1775
+ --color-lime-900: oklch(40.5% 0.101 131.063);
1776
+ --color-lime-950: oklch(27.4% 0.072 132.109);
1777
+
1778
+ --color-green-50: oklch(98.2% 0.018 155.826);
1779
+ --color-green-100: oklch(96.2% 0.044 156.743);
1780
+ --color-green-200: oklch(92.5% 0.084 155.995);
1781
+ --color-green-300: oklch(87.1% 0.15 154.449);
1782
+ --color-green-400: oklch(79.2% 0.209 151.711);
1783
+ --color-green-500: oklch(72.3% 0.219 149.579);
1784
+ --color-green-600: oklch(62.7% 0.194 149.214);
1785
+ --color-green-700: oklch(52.7% 0.154 150.069);
1786
+ --color-green-800: oklch(44.8% 0.119 151.328);
1787
+ --color-green-900: oklch(39.3% 0.095 152.535);
1788
+ --color-green-950: oklch(26.6% 0.065 152.934);
1789
+
1790
+ --color-emerald-50: oklch(97.9% 0.021 166.113);
1791
+ --color-emerald-100: oklch(95% 0.052 163.051);
1792
+ --color-emerald-200: oklch(90.5% 0.093 164.15);
1793
+ --color-emerald-300: oklch(84.5% 0.143 164.978);
1794
+ --color-emerald-400: oklch(76.5% 0.177 163.223);
1795
+ --color-emerald-500: oklch(69.6% 0.17 162.48);
1796
+ --color-emerald-600: oklch(59.6% 0.145 163.225);
1797
+ --color-emerald-700: oklch(50.8% 0.118 165.612);
1798
+ --color-emerald-800: oklch(43.2% 0.095 166.913);
1799
+ --color-emerald-900: oklch(37.8% 0.077 168.94);
1800
+ --color-emerald-950: oklch(26.2% 0.051 172.552);
1801
+
1802
+ --color-teal-50: oklch(98.4% 0.014 180.72);
1803
+ --color-teal-100: oklch(95.3% 0.051 180.801);
1804
+ --color-teal-200: oklch(91% 0.096 180.426);
1805
+ --color-teal-300: oklch(85.5% 0.138 181.071);
1806
+ --color-teal-400: oklch(77.7% 0.152 181.912);
1807
+ --color-teal-500: oklch(70.4% 0.14 182.503);
1808
+ --color-teal-600: oklch(60% 0.118 184.704);
1809
+ --color-teal-700: oklch(51.1% 0.096 186.391);
1810
+ --color-teal-800: oklch(43.7% 0.078 188.216);
1811
+ --color-teal-900: oklch(38.6% 0.063 188.416);
1812
+ --color-teal-950: oklch(27.7% 0.046 192.524);
1813
+
1814
+ --color-cyan-50: oklch(98.4% 0.019 200.873);
1815
+ --color-cyan-100: oklch(95.6% 0.045 203.388);
1816
+ --color-cyan-200: oklch(91.7% 0.08 205.041);
1817
+ --color-cyan-300: oklch(86.5% 0.127 207.078);
1818
+ --color-cyan-400: oklch(78.9% 0.154 211.53);
1819
+ --color-cyan-500: oklch(71.5% 0.143 215.221);
1820
+ --color-cyan-600: oklch(60.9% 0.126 221.723);
1821
+ --color-cyan-700: oklch(52% 0.105 223.128);
1822
+ --color-cyan-800: oklch(45% 0.085 224.283);
1823
+ --color-cyan-900: oklch(39.8% 0.07 227.392);
1824
+ --color-cyan-950: oklch(30.2% 0.056 229.695);
1825
+
1826
+ --color-sky-50: oklch(97.7% 0.013 236.62);
1827
+ --color-sky-100: oklch(95.1% 0.026 236.824);
1828
+ --color-sky-200: oklch(90.1% 0.058 230.902);
1829
+ --color-sky-300: oklch(82.8% 0.111 230.318);
1830
+ --color-sky-400: oklch(74.6% 0.16 232.661);
1831
+ --color-sky-500: oklch(68.5% 0.169 237.323);
1832
+ --color-sky-600: oklch(58.8% 0.158 241.966);
1833
+ --color-sky-700: oklch(50% 0.134 242.749);
1834
+ --color-sky-800: oklch(44.3% 0.11 240.79);
1835
+ --color-sky-900: oklch(39.1% 0.09 240.876);
1836
+ --color-sky-950: oklch(29.3% 0.066 243.157);
1837
+
1838
+ --color-blue-50: oklch(97% 0.014 254.604);
1839
+ --color-blue-100: oklch(93.2% 0.032 255.585);
1840
+ --color-blue-200: oklch(88.2% 0.059 254.128);
1841
+ --color-blue-300: oklch(80.9% 0.105 251.813);
1842
+ --color-blue-400: oklch(70.7% 0.165 254.624);
1843
+ --color-blue-500: oklch(62.3% 0.214 259.815);
1844
+ --color-blue-600: oklch(54.6% 0.245 262.881);
1845
+ --color-blue-700: oklch(48.8% 0.243 264.376);
1846
+ --color-blue-800: oklch(42.4% 0.199 265.638);
1847
+ --color-blue-900: oklch(37.9% 0.146 265.522);
1848
+ --color-blue-950: oklch(28.2% 0.091 267.935);
1849
+
1850
+ --color-indigo-50: oklch(96.2% 0.018 272.314);
1851
+ --color-indigo-100: oklch(93% 0.034 272.788);
1852
+ --color-indigo-200: oklch(87% 0.065 274.039);
1853
+ --color-indigo-300: oklch(78.5% 0.115 274.713);
1854
+ --color-indigo-400: oklch(67.3% 0.182 276.935);
1855
+ --color-indigo-500: oklch(58.5% 0.233 277.117);
1856
+ --color-indigo-600: oklch(51.1% 0.262 276.966);
1857
+ --color-indigo-700: oklch(45.7% 0.24 277.023);
1858
+ --color-indigo-800: oklch(39.8% 0.195 277.366);
1859
+ --color-indigo-900: oklch(35.9% 0.144 278.697);
1860
+ --color-indigo-950: oklch(25.7% 0.09 281.288);
1861
+
1862
+ --color-violet-50: oklch(96.9% 0.016 293.756);
1863
+ --color-violet-100: oklch(94.3% 0.029 294.588);
1864
+ --color-violet-200: oklch(89.4% 0.057 293.283);
1865
+ --color-violet-300: oklch(81.1% 0.111 293.571);
1866
+ --color-violet-400: oklch(70.2% 0.183 293.541);
1867
+ --color-violet-500: oklch(60.6% 0.25 292.717);
1868
+ --color-violet-600: oklch(54.1% 0.281 293.009);
1869
+ --color-violet-700: oklch(49.1% 0.27 292.581);
1870
+ --color-violet-800: oklch(43.2% 0.232 292.759);
1871
+ --color-violet-900: oklch(38% 0.189 293.745);
1872
+ --color-violet-950: oklch(28.3% 0.141 291.089);
1873
+
1874
+ --color-purple-50: oklch(97.7% 0.014 308.299);
1875
+ --color-purple-100: oklch(94.6% 0.033 307.174);
1876
+ --color-purple-200: oklch(90.2% 0.063 306.703);
1877
+ --color-purple-300: oklch(82.7% 0.119 306.383);
1878
+ --color-purple-400: oklch(71.4% 0.203 305.504);
1879
+ --color-purple-500: oklch(62.7% 0.265 303.9);
1880
+ --color-purple-600: oklch(55.8% 0.288 302.321);
1881
+ --color-purple-700: oklch(49.6% 0.265 301.924);
1882
+ --color-purple-800: oklch(43.8% 0.218 303.724);
1883
+ --color-purple-900: oklch(38.1% 0.176 304.987);
1884
+ --color-purple-950: oklch(29.1% 0.149 302.717);
1885
+
1886
+ --color-fuchsia-50: oklch(97.7% 0.017 320.058);
1887
+ --color-fuchsia-100: oklch(95.2% 0.037 318.852);
1888
+ --color-fuchsia-200: oklch(90.3% 0.076 319.62);
1889
+ --color-fuchsia-300: oklch(83.3% 0.145 321.434);
1890
+ --color-fuchsia-400: oklch(74% 0.238 322.16);
1891
+ --color-fuchsia-500: oklch(66.7% 0.295 322.15);
1892
+ --color-fuchsia-600: oklch(59.1% 0.293 322.896);
1893
+ --color-fuchsia-700: oklch(51.8% 0.253 323.949);
1894
+ --color-fuchsia-800: oklch(45.2% 0.211 324.591);
1895
+ --color-fuchsia-900: oklch(40.1% 0.17 325.612);
1896
+ --color-fuchsia-950: oklch(29.3% 0.136 325.661);
1897
+
1898
+ --color-pink-50: oklch(97.1% 0.014 343.198);
1899
+ --color-pink-100: oklch(94.8% 0.028 342.258);
1900
+ --color-pink-200: oklch(89.9% 0.061 343.231);
1901
+ --color-pink-300: oklch(82.3% 0.12 346.018);
1902
+ --color-pink-400: oklch(71.8% 0.202 349.761);
1903
+ --color-pink-500: oklch(65.6% 0.241 354.308);
1904
+ --color-pink-600: oklch(59.2% 0.249 0.584);
1905
+ --color-pink-700: oklch(52.5% 0.223 3.958);
1906
+ --color-pink-800: oklch(45.9% 0.187 3.815);
1907
+ --color-pink-900: oklch(40.8% 0.153 2.432);
1908
+ --color-pink-950: oklch(28.4% 0.109 3.907);
1909
+
1910
+ --color-rose-50: oklch(96.9% 0.015 12.422);
1911
+ --color-rose-100: oklch(94.1% 0.03 12.58);
1912
+ --color-rose-200: oklch(89.2% 0.058 10.001);
1913
+ --color-rose-300: oklch(81% 0.117 11.638);
1914
+ --color-rose-400: oklch(71.2% 0.194 13.428);
1915
+ --color-rose-500: oklch(64.5% 0.246 16.439);
1916
+ --color-rose-600: oklch(58.6% 0.253 17.585);
1917
+ --color-rose-700: oklch(51.4% 0.222 16.935);
1918
+ --color-rose-800: oklch(45.5% 0.188 13.697);
1919
+ --color-rose-900: oklch(41% 0.159 10.272);
1920
+ --color-rose-950: oklch(27.1% 0.105 12.094);
1921
+
1922
+ --color-slate-50: oklch(98.4% 0.003 247.858);
1923
+ --color-slate-100: oklch(96.8% 0.007 247.896);
1924
+ --color-slate-200: oklch(92.9% 0.013 255.508);
1925
+ --color-slate-300: oklch(86.9% 0.022 252.894);
1926
+ --color-slate-400: oklch(70.4% 0.04 256.788);
1927
+ --color-slate-500: oklch(55.4% 0.046 257.417);
1928
+ --color-slate-600: oklch(44.6% 0.043 257.281);
1929
+ --color-slate-700: oklch(37.2% 0.044 257.287);
1930
+ --color-slate-800: oklch(27.9% 0.041 260.031);
1931
+ --color-slate-900: oklch(20.8% 0.042 265.755);
1932
+ --color-slate-950: oklch(12.9% 0.042 264.695);
1933
+
1934
+ --color-gray-50: oklch(98.5% 0.002 247.839);
1935
+ --color-gray-100: oklch(96.7% 0.003 264.542);
1936
+ --color-gray-200: oklch(92.8% 0.006 264.531);
1937
+ --color-gray-300: oklch(87.2% 0.01 258.338);
1938
+ --color-gray-400: oklch(70.7% 0.022 261.325);
1939
+ --color-gray-500: oklch(55.1% 0.027 264.364);
1940
+ --color-gray-600: oklch(44.6% 0.03 256.802);
1941
+ --color-gray-700: oklch(37.3% 0.034 259.733);
1942
+ --color-gray-800: oklch(27.8% 0.033 256.848);
1943
+ --color-gray-900: oklch(21% 0.034 264.665);
1944
+ --color-gray-950: oklch(13% 0.028 261.692);
1945
+
1946
+ --color-zinc-50: oklch(98.5% 0 0);
1947
+ --color-zinc-100: oklch(96.7% 0.001 286.375);
1948
+ --color-zinc-200: oklch(92% 0.004 286.32);
1949
+ --color-zinc-300: oklch(87.1% 0.006 286.286);
1950
+ --color-zinc-400: oklch(70.5% 0.015 286.067);
1951
+ --color-zinc-500: oklch(55.2% 0.016 285.938);
1952
+ --color-zinc-600: oklch(44.2% 0.017 285.786);
1953
+ --color-zinc-700: oklch(37% 0.013 285.805);
1954
+ --color-zinc-800: oklch(27.4% 0.006 286.033);
1955
+ --color-zinc-900: oklch(21% 0.006 285.885);
1956
+ --color-zinc-950: oklch(14.1% 0.005 285.823);
1957
+
1958
+ --color-neutral-50: oklch(98.5% 0 0);
1959
+ --color-neutral-100: oklch(97% 0 0);
1960
+ --color-neutral-200: oklch(92.2% 0 0);
1961
+ --color-neutral-300: oklch(87% 0 0);
1962
+ --color-neutral-400: oklch(70.8% 0 0);
1963
+ --color-neutral-500: oklch(55.6% 0 0);
1964
+ --color-neutral-600: oklch(43.9% 0 0);
1965
+ --color-neutral-700: oklch(37.1% 0 0);
1966
+ --color-neutral-800: oklch(26.9% 0 0);
1967
+ --color-neutral-900: oklch(20.5% 0 0);
1968
+ --color-neutral-950: oklch(14.5% 0 0);
1969
+
1970
+ --color-stone-50: oklch(98.5% 0.001 106.423);
1971
+ --color-stone-100: oklch(97% 0.001 106.424);
1972
+ --color-stone-200: oklch(92.3% 0.003 48.717);
1973
+ --color-stone-300: oklch(86.9% 0.005 56.366);
1974
+ --color-stone-400: oklch(70.9% 0.01 56.259);
1975
+ --color-stone-500: oklch(55.3% 0.013 58.071);
1976
+ --color-stone-600: oklch(44.4% 0.011 73.639);
1977
+ --color-stone-700: oklch(37.4% 0.01 67.558);
1978
+ --color-stone-800: oklch(26.8% 0.007 34.298);
1979
+ --color-stone-900: oklch(21.6% 0.006 56.043);
1980
+ --color-stone-950: oklch(14.7% 0.004 49.25);
1981
+
1982
+ --color-black: #000;
1983
+ --color-white: #fff;
1984
+
1985
+ --spacing: 0.25rem;
1986
+
1987
+ --breakpoint-sm: 40rem;
1988
+ --breakpoint-md: 48rem;
1989
+ --breakpoint-lg: 64rem;
1990
+ --breakpoint-xl: 80rem;
1991
+ --breakpoint-2xl: 96rem;
1992
+
1993
+ --container-3xs: 16rem;
1994
+ --container-2xs: 18rem;
1995
+ --container-xs: 20rem;
1996
+ --container-sm: 24rem;
1997
+ --container-md: 28rem;
1998
+ --container-lg: 32rem;
1999
+ --container-xl: 36rem;
2000
+ --container-2xl: 42rem;
2001
+ --container-3xl: 48rem;
2002
+ --container-4xl: 56rem;
2003
+ --container-5xl: 64rem;
2004
+ --container-6xl: 72rem;
2005
+ --container-7xl: 80rem;
2006
+
2007
+ --text-xs: 0.75rem;
2008
+ --text-xs--line-height: calc(1 / 0.75);
2009
+ --text-sm: 0.875rem;
2010
+ --text-sm--line-height: calc(1.25 / 0.875);
2011
+ --text-base: 1rem;
2012
+ --text-base--line-height: calc(1.5 / 1);
2013
+ --text-lg: 1.125rem;
2014
+ --text-lg--line-height: calc(1.75 / 1.125);
2015
+ --text-xl: 1.25rem;
2016
+ --text-xl--line-height: calc(1.75 / 1.25);
2017
+ --text-2xl: 1.5rem;
2018
+ --text-2xl--line-height: calc(2 / 1.5);
2019
+ --text-3xl: 1.875rem;
2020
+ --text-3xl--line-height: calc(2.25 / 1.875);
2021
+ --text-4xl: 2.25rem;
2022
+ --text-4xl--line-height: calc(2.5 / 2.25);
2023
+ --text-5xl: 3rem;
2024
+ --text-5xl--line-height: 1;
2025
+ --text-6xl: 3.75rem;
2026
+ --text-6xl--line-height: 1;
2027
+ --text-7xl: 4.5rem;
2028
+ --text-7xl--line-height: 1;
2029
+ --text-8xl: 6rem;
2030
+ --text-8xl--line-height: 1;
2031
+ --text-9xl: 8rem;
2032
+ --text-9xl--line-height: 1;
2033
+
2034
+ --font-weight-thin: 100;
2035
+ --font-weight-extralight: 200;
2036
+ --font-weight-light: 300;
2037
+ --font-weight-normal: 400;
2038
+ --font-weight-medium: 500;
2039
+ --font-weight-semibold: 600;
2040
+ --font-weight-bold: 700;
2041
+ --font-weight-extrabold: 800;
2042
+ --font-weight-black: 900;
2043
+
2044
+ --tracking-tighter: -0.05em;
2045
+ --tracking-tight: -0.025em;
2046
+ --tracking-normal: 0em;
2047
+ --tracking-wide: 0.025em;
2048
+ --tracking-wider: 0.05em;
2049
+ --tracking-widest: 0.1em;
2050
+
2051
+ --leading-tight: 1.25;
2052
+ --leading-snug: 1.375;
2053
+ --leading-normal: 1.5;
2054
+ --leading-relaxed: 1.625;
2055
+ --leading-loose: 2;
2056
+
2057
+ --radius-xs: 0.125rem;
2058
+ --radius-sm: 0.25rem;
2059
+ --radius-md: 0.375rem;
2060
+ --radius-lg: 0.5rem;
2061
+ --radius-xl: 0.75rem;
2062
+ --radius-2xl: 1rem;
2063
+ --radius-3xl: 1.5rem;
2064
+ --radius-4xl: 2rem;
2065
+
2066
+ --shadow-2xs: 0 1px rgb(0 0 0 / 0.05);
2067
+ --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);
2068
+ --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
2069
+ --shadow-md:
2070
+ 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
2071
+ --shadow-lg:
2072
+ 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
2073
+ --shadow-xl:
2074
+ 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
2075
+ --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
2076
+
2077
+ --inset-shadow-2xs: inset 0 1px rgb(0 0 0 / 0.05);
2078
+ --inset-shadow-xs: inset 0 1px 1px rgb(0 0 0 / 0.05);
2079
+ --inset-shadow-sm: inset 0 2px 4px rgb(0 0 0 / 0.05);
2080
+
2081
+ --drop-shadow-xs: 0 1px 1px rgb(0 0 0 / 0.05);
2082
+ --drop-shadow-sm: 0 1px 2px rgb(0 0 0 / 0.15);
2083
+ --drop-shadow-md: 0 3px 3px rgb(0 0 0 / 0.12);
2084
+ --drop-shadow-lg: 0 4px 4px rgb(0 0 0 / 0.15);
2085
+ --drop-shadow-xl: 0 9px 7px rgb(0 0 0 / 0.1);
2086
+ --drop-shadow-2xl: 0 25px 25px rgb(0 0 0 / 0.15);
2087
+
2088
+ --text-shadow-2xs: 0px 1px 0px rgb(0 0 0 / 0.15);
2089
+ --text-shadow-xs: 0px 1px 1px rgb(0 0 0 / 0.2);
2090
+ --text-shadow-sm:
2091
+ 0px 1px 0px rgb(0 0 0 / 0.075), 0px 1px 1px rgb(0 0 0 / 0.075),
2092
+ 0px 2px 2px rgb(0 0 0 / 0.075);
2093
+ --text-shadow-md:
2094
+ 0px 1px 1px rgb(0 0 0 / 0.1), 0px 1px 2px rgb(0 0 0 / 0.1),
2095
+ 0px 2px 4px rgb(0 0 0 / 0.1);
2096
+ --text-shadow-lg:
2097
+ 0px 1px 2px rgb(0 0 0 / 0.1), 0px 3px 2px rgb(0 0 0 / 0.1),
2098
+ 0px 4px 8px rgb(0 0 0 / 0.1);
2099
+
2100
+ --ease-in: cubic-bezier(0.4, 0, 1, 1);
2101
+ --ease-out: cubic-bezier(0, 0, 0.2, 1);
2102
+ --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
2103
+
2104
+ --animate-spin: spin 1s linear infinite;
2105
+ --animate-ping: ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
2106
+ --animate-pulse: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
2107
+ --animate-bounce: bounce 1s infinite;
2108
+
2109
+ @keyframes spin {
2110
+ to {
2111
+ transform: rotate(360deg);
2112
+ }
2113
+ }
2114
+
2115
+ @keyframes ping {
2116
+ 75%,
2117
+ 100% {
2118
+ transform: scale(2);
2119
+ opacity: 0;
2120
+ }
2121
+ }
2122
+
2123
+ @keyframes pulse {
2124
+ 50% {
2125
+ opacity: 0.5;
2126
+ }
2127
+ }
2128
+
2129
+ @keyframes bounce {
2130
+ 0%,
2131
+ 100% {
2132
+ transform: translateY(-25%);
2133
+ animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
2134
+ }
2135
+
2136
+ 50% {
2137
+ transform: none;
2138
+ animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
2139
+ }
2140
+ }
2141
+
2142
+ --blur-xs: 4px;
2143
+ --blur-sm: 8px;
2144
+ --blur-md: 12px;
2145
+ --blur-lg: 16px;
2146
+ --blur-xl: 24px;
2147
+ --blur-2xl: 40px;
2148
+ --blur-3xl: 64px;
2149
+
2150
+ --perspective-dramatic: 100px;
2151
+ --perspective-near: 300px;
2152
+ --perspective-normal: 500px;
2153
+ --perspective-midrange: 800px;
2154
+ --perspective-distant: 1200px;
2155
+
2156
+ --aspect-video: 16 / 9;
2157
+
2158
+ --default-transition-duration: 150ms;
2159
+ --default-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
2160
+ --default-font-family: --theme(--font-sans, initial);
2161
+ --default-font-feature-settings: --theme(
2162
+ --font-sans--font-feature-settings,
2163
+ initial
2164
+ );
2165
+ --default-font-variation-settings: --theme(
2166
+ --font-sans--font-variation-settings,
2167
+ initial
2168
+ );
2169
+ --default-mono-font-family: --theme(--font-mono, initial);
2170
+ --default-mono-font-feature-settings: --theme(
2171
+ --font-mono--font-feature-settings,
2172
+ initial
2173
+ );
2174
+ --default-mono-font-variation-settings: --theme(
2175
+ --font-mono--font-variation-settings,
2176
+ initial
2177
+ );
2178
+ }
2179
+
2180
+ /* Deprecated */
2181
+ @theme default inline reference {
2182
+ --blur: 8px;
2183
+ --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
2184
+ --shadow-inner: inset 0 2px 4px 0 rgb(0 0 0 / 0.05);
2185
+ --drop-shadow: 0 1px 2px rgb(0 0 0 / 0.1), 0 1px 1px rgb(0 0 0 / 0.06);
2186
+ --radius: 0.25rem;
2187
+ --max-width-prose: 65ch;
2188
+ }
2189
+ }
2190
+
2191
+ @layer base {
2192
+ /*
2193
+ 1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
2194
+ 2. Remove default margins and padding
2195
+ 3. Reset all borders.
2196
+ */
2197
+
2198
+ *,
2199
+ ::after,
2200
+ ::before,
2201
+ ::backdrop,
2202
+ ::file-selector-button {
2203
+ box-sizing: border-box; /* 1 */
2204
+ margin: 0; /* 2 */
2205
+ padding: 0; /* 2 */
2206
+ border: 0 solid; /* 3 */
2207
+ }
2208
+
2209
+ /*
2210
+ 1. Use a consistent sensible line-height in all browsers.
2211
+ 2. Prevent adjustments of font size after orientation changes in iOS.
2212
+ 3. Use a more readable tab size.
2213
+ 4. Use the user's configured \`sans\` font-family by default.
2214
+ 5. Use the user's configured \`sans\` font-feature-settings by default.
2215
+ 6. Use the user's configured \`sans\` font-variation-settings by default.
2216
+ 7. Disable tap highlights on iOS.
2217
+ */
2218
+
2219
+ html,
2220
+ :host {
2221
+ line-height: 1.5; /* 1 */
2222
+ -webkit-text-size-adjust: 100%; /* 2 */
2223
+ tab-size: 4; /* 3 */
2224
+ font-family: --theme(
2225
+ --default-font-family,
2226
+ ui-sans-serif,
2227
+ system-ui,
2228
+ sans-serif,
2229
+ "Apple Color Emoji",
2230
+ "Segoe UI Emoji",
2231
+ "Segoe UI Symbol",
2232
+ "Noto Color Emoji"
2233
+ ); /* 4 */
2234
+ font-feature-settings: --theme(
2235
+ --default-font-feature-settings,
2236
+ normal
2237
+ ); /* 5 */
2238
+ font-variation-settings: --theme(
2239
+ --default-font-variation-settings,
2240
+ normal
2241
+ ); /* 6 */
2242
+ -webkit-tap-highlight-color: transparent; /* 7 */
2243
+ }
2244
+
2245
+ /*
2246
+ 1. Add the correct height in Firefox.
2247
+ 2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
2248
+ 3. Reset the default border style to a 1px solid border.
2249
+ */
2250
+
2251
+ hr {
2252
+ height: 0; /* 1 */
2253
+ color: inherit; /* 2 */
2254
+ border-top-width: 1px; /* 3 */
2255
+ }
2256
+
2257
+ /*
2258
+ Add the correct text decoration in Chrome, Edge, and Safari.
2259
+ */
2260
+
2261
+ abbr:where([title]) {
2262
+ -webkit-text-decoration: underline dotted;
2263
+ text-decoration: underline dotted;
2264
+ }
2265
+
2266
+ /*
2267
+ Remove the default font size and weight for headings.
2268
+ */
2269
+
2270
+ h1,
2271
+ h2,
2272
+ h3,
2273
+ h4,
2274
+ h5,
2275
+ h6 {
2276
+ font-size: inherit;
2277
+ font-weight: inherit;
2278
+ }
2279
+
2280
+ /*
2281
+ Reset links to optimize for opt-in styling instead of opt-out.
2282
+ */
2283
+
2284
+ a {
2285
+ color: inherit;
2286
+ -webkit-text-decoration: inherit;
2287
+ text-decoration: inherit;
2288
+ }
2289
+
2290
+ /*
2291
+ Add the correct font weight in Edge and Safari.
2292
+ */
2293
+
2294
+ b,
2295
+ strong {
2296
+ font-weight: bolder;
2297
+ }
2298
+
2299
+ /*
2300
+ 1. Use the user's configured \`mono\` font-family by default.
2301
+ 2. Use the user's configured \`mono\` font-feature-settings by default.
2302
+ 3. Use the user's configured \`mono\` font-variation-settings by default.
2303
+ 4. Correct the odd \`em\` font sizing in all browsers.
2304
+ */
2305
+
2306
+ code,
2307
+ kbd,
2308
+ samp,
2309
+ pre {
2310
+ font-family: --theme(
2311
+ --default-mono-font-family,
2312
+ ui-monospace,
2313
+ SFMono-Regular,
2314
+ Menlo,
2315
+ Monaco,
2316
+ Consolas,
2317
+ "Liberation Mono",
2318
+ "Courier New",
2319
+ monospace
2320
+ ); /* 1 */
2321
+ font-feature-settings: --theme(
2322
+ --default-mono-font-feature-settings,
2323
+ normal
2324
+ ); /* 2 */
2325
+ font-variation-settings: --theme(
2326
+ --default-mono-font-variation-settings,
2327
+ normal
2328
+ ); /* 3 */
2329
+ font-size: 1em; /* 4 */
2330
+ }
2331
+
2332
+ /*
2333
+ Add the correct font size in all browsers.
2334
+ */
2335
+
2336
+ small {
2337
+ font-size: 80%;
2338
+ }
2339
+
2340
+ /*
2341
+ Prevent \`sub\` and \`sup\` elements from affecting the line height in all browsers.
2342
+ */
2343
+
2344
+ sub,
2345
+ sup {
2346
+ font-size: 75%;
2347
+ line-height: 0;
2348
+ position: relative;
2349
+ vertical-align: baseline;
2350
+ }
2351
+
2352
+ sub {
2353
+ bottom: -0.25em;
2354
+ }
2355
+
2356
+ sup {
2357
+ top: -0.5em;
2358
+ }
2359
+
2360
+ /*
2361
+ 1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
2362
+ 2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
2363
+ 3. Remove gaps between table borders by default.
2364
+ */
2365
+
2366
+ table {
2367
+ text-indent: 0; /* 1 */
2368
+ border-color: inherit; /* 2 */
2369
+ border-collapse: collapse; /* 3 */
2370
+ }
2371
+
2372
+ /*
2373
+ Use the modern Firefox focus style for all focusable elements.
2374
+ */
2375
+
2376
+ :-moz-focusring {
2377
+ outline: auto;
2378
+ }
2379
+
2380
+ /*
2381
+ Add the correct vertical alignment in Chrome and Firefox.
2382
+ */
2383
+
2384
+ progress {
2385
+ vertical-align: baseline;
2386
+ }
2387
+
2388
+ /*
2389
+ Add the correct display in Chrome and Safari.
2390
+ */
2391
+
2392
+ summary {
2393
+ display: list-item;
2394
+ }
2395
+
2396
+ /*
2397
+ Make lists unstyled by default.
2398
+ */
2399
+
2400
+ ol,
2401
+ ul,
2402
+ menu {
2403
+ list-style: none;
2404
+ }
2405
+
2406
+ /*
2407
+ 1. Make replaced elements \`display: block\` by default. (https://github.com/mozdevs/cssremedy/issues/14)
2408
+ 2. Add \`vertical - align: middle\` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
2409
+ This can trigger a poorly considered lint error in some tools but is included by design.
2410
+ */
2411
+
2412
+ img,
2413
+ svg,
2414
+ video,
2415
+ canvas,
2416
+ audio,
2417
+ iframe,
2418
+ embed,
2419
+ object {
2420
+ display: block; /* 1 */
2421
+ vertical-align: middle; /* 2 */
2422
+ }
2423
+
2424
+ /*
2425
+ Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
2426
+ */
2427
+
2428
+ img,
2429
+ video {
2430
+ max-width: 100%;
2431
+ height: auto;
2432
+ }
2433
+
2434
+ /*
2435
+ 1. Inherit font styles in all browsers.
2436
+ 2. Remove border radius in all browsers.
2437
+ 3. Remove background color in all browsers.
2438
+ 4. Ensure consistent opacity for disabled states in all browsers.
2439
+ */
2440
+
2441
+ button,
2442
+ input,
2443
+ select,
2444
+ optgroup,
2445
+ textarea,
2446
+ ::file-selector-button {
2447
+ font: inherit; /* 1 */
2448
+ font-feature-settings: inherit; /* 1 */
2449
+ font-variation-settings: inherit; /* 1 */
2450
+ letter-spacing: inherit; /* 1 */
2451
+ color: inherit; /* 1 */
2452
+ border-radius: 0; /* 2 */
2453
+ background-color: transparent; /* 3 */
2454
+ opacity: 1; /* 4 */
2455
+ }
2456
+
2457
+ /*
2458
+ Restore default font weight.
2459
+ */
2460
+
2461
+ :where(select:is([multiple], [size])) optgroup {
2462
+ font-weight: bolder;
2463
+ }
2464
+
2465
+ /*
2466
+ Restore indentation.
2467
+ */
2468
+
2469
+ :where(select:is([multiple], [size])) optgroup option {
2470
+ padding-inline-start: 20px;
2471
+ }
2472
+
2473
+ /*
2474
+ Restore space after button.
2475
+ */
2476
+
2477
+ ::file-selector-button {
2478
+ margin-inline-end: 4px;
2479
+ }
2480
+
2481
+ /*
2482
+ Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
2483
+ */
2484
+
2485
+ ::placeholder {
2486
+ opacity: 1;
2487
+ }
2488
+
2489
+ /*
2490
+ Set the default placeholder color to a semi-transparent version of the current text color in browsers that do not
2491
+ crash when using \`color - mix(…)\` with \`currentcolor\`. (https://github.com/tailwindlabs/tailwindcss/issues/17194)
2492
+ */
2493
+
2494
+ @supports (not (-webkit-appearance: -apple-pay-button)) /* Not Safari */ or
2495
+ (contain-intrinsic-size: 1px) /* Safari 17+ */ {
2496
+ ::placeholder {
2497
+ color: color-mix(in oklab, currentcolor 50%, transparent);
2498
+ }
2499
+ }
2500
+
2501
+ /*
2502
+ Prevent resizing textareas horizontally by default.
2503
+ */
2504
+
2505
+ textarea {
2506
+ resize: vertical;
2507
+ }
2508
+
2509
+ /*
2510
+ Remove the inner padding in Chrome and Safari on macOS.
2511
+ */
2512
+
2513
+ ::-webkit-search-decoration {
2514
+ -webkit-appearance: none;
2515
+ }
2516
+
2517
+ /*
2518
+ 1. Ensure date/time inputs have the same height when empty in iOS Safari.
2519
+ 2. Ensure text alignment can be changed on date/time inputs in iOS Safari.
2520
+ */
2521
+
2522
+ ::-webkit-date-and-time-value {
2523
+ min-height: 1lh; /* 1 */
2524
+ text-align: inherit; /* 2 */
2525
+ }
2526
+
2527
+ /*
2528
+ Prevent height from changing on date/time inputs in macOS Safari when the input is set to \`display: block\`.
2529
+ */
2530
+
2531
+ ::-webkit-datetime-edit {
2532
+ display: inline-flex;
2533
+ }
2534
+
2535
+ /*
2536
+ Remove excess padding from pseudo-elements in date/time inputs to ensure consistent height across browsers.
2537
+ */
2538
+
2539
+ ::-webkit-datetime-edit-fields-wrapper {
2540
+ padding: 0;
2541
+ }
2542
+
2543
+ ::-webkit-datetime-edit,
2544
+ ::-webkit-datetime-edit-year-field,
2545
+ ::-webkit-datetime-edit-month-field,
2546
+ ::-webkit-datetime-edit-day-field,
2547
+ ::-webkit-datetime-edit-hour-field,
2548
+ ::-webkit-datetime-edit-minute-field,
2549
+ ::-webkit-datetime-edit-second-field,
2550
+ ::-webkit-datetime-edit-millisecond-field,
2551
+ ::-webkit-datetime-edit-meridiem-field {
2552
+ padding-block: 0;
2553
+ }
2554
+
2555
+ /*
2556
+ Center dropdown marker shown on inputs with paired \`<datalist>\`s in Chrome. (https://github.com/tailwindlabs/tailwindcss/issues/18499)
2557
+ */
2558
+
2559
+ ::-webkit-calendar-picker-indicator {
2560
+ line-height: 1;
2561
+ }
2562
+
2563
+ /*
2564
+ Remove the additional \`: invalid\` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
2565
+ */
2566
+
2567
+ :-moz-ui-invalid {
2568
+ box-shadow: none;
2569
+ }
2570
+
2571
+ /*
2572
+ Correct the inability to style the border radius in iOS Safari.
2573
+ */
2574
+
2575
+ button,
2576
+ input:where([type="button"], [type="reset"], [type="submit"]),
2577
+ ::file-selector-button {
2578
+ appearance: button;
2579
+ }
2580
+
2581
+ /*
2582
+ Correct the cursor style of increment and decrement buttons in Safari.
2583
+ */
2584
+
2585
+ ::-webkit-inner-spin-button,
2586
+ ::-webkit-outer-spin-button {
2587
+ height: auto;
2588
+ }
2589
+
2590
+ /*
2591
+ Make elements with the HTML hidden attribute stay hidden by default.
2592
+ */
2593
+
2594
+ [hidden]:where(:not([hidden="until-found"])) {
2595
+ display: none !important;
2596
+ }
2597
+ }
2598
+
2599
+ @layer utilities {
2600
+ @tailwind utilities;
2601
+ }
2602
+ `;
2603
+ var css_default = css$3;
2604
+
2605
+ //#endregion
2606
+ //#region src/tailwind/css/preflight.ts
2607
+ const css$2 = `
2608
+ /*
2609
+ 1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
2610
+ 2. Remove default margins and padding
2611
+ 3. Reset all borders.
2612
+ */
2613
+
2614
+ *,
2615
+ ::after,
2616
+ ::before,
2617
+ ::backdrop,
2618
+ ::file-selector-button {
2619
+ box-sizing: border-box; /* 1 */
2620
+ margin: 0; /* 2 */
2621
+ padding: 0; /* 2 */
2622
+ border: 0 solid; /* 3 */
2623
+ }
2624
+
2625
+ /*
2626
+ 1. Use a consistent sensible line-height in all browsers.
2627
+ 2. Prevent adjustments of font size after orientation changes in iOS.
2628
+ 3. Use a more readable tab size.
2629
+ 4. Use the user's configured \`sans\` font-family by default.
2630
+ 5. Use the user's configured \`sans\` font-feature-settings by default.
2631
+ 6. Use the user's configured \`sans\` font-variation-settings by default.
2632
+ 7. Disable tap highlights on iOS.
2633
+ */
2634
+
2635
+ html,
2636
+ :host {
2637
+ line-height: 1.5; /* 1 */
2638
+ -webkit-text-size-adjust: 100%; /* 2 */
2639
+ tab-size: 4; /* 3 */
2640
+ font-family: --theme(
2641
+ --default-font-family,
2642
+ ui-sans-serif,
2643
+ system-ui,
2644
+ sans-serif,
2645
+ 'Apple Color Emoji',
2646
+ 'Segoe UI Emoji',
2647
+ 'Segoe UI Symbol',
2648
+ 'Noto Color Emoji'
2649
+ ); /* 4 */
2650
+ font-feature-settings: --theme(--default-font-feature-settings, normal); /* 5 */
2651
+ font-variation-settings: --theme(--default-font-variation-settings, normal); /* 6 */
2652
+ -webkit-tap-highlight-color: transparent; /* 7 */
2653
+ }
2654
+
2655
+ /*
2656
+ 1. Add the correct height in Firefox.
2657
+ 2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
2658
+ 3. Reset the default border style to a 1px solid border.
2659
+ */
2660
+
2661
+ hr {
2662
+ height: 0; /* 1 */
2663
+ color: inherit; /* 2 */
2664
+ border-top-width: 1px; /* 3 */
2665
+ }
2666
+
2667
+ /*
2668
+ Add the correct text decoration in Chrome, Edge, and Safari.
2669
+ */
2670
+
2671
+ abbr:where([title]) {
2672
+ -webkit-text-decoration: underline dotted;
2673
+ text-decoration: underline dotted;
2674
+ }
2675
+
2676
+ /*
2677
+ Remove the default font size and weight for headings.
2678
+ */
2679
+
2680
+ h1,
2681
+ h2,
2682
+ h3,
2683
+ h4,
2684
+ h5,
2685
+ h6 {
2686
+ font-size: inherit;
2687
+ font-weight: inherit;
2688
+ }
2689
+
2690
+ /*
2691
+ Reset links to optimize for opt-in styling instead of opt-out.
2692
+ */
2693
+
2694
+ a {
2695
+ color: inherit;
2696
+ -webkit-text-decoration: inherit;
2697
+ text-decoration: inherit;
2698
+ }
2699
+
2700
+ /*
2701
+ Add the correct font weight in Edge and Safari.
2702
+ */
2703
+
2704
+ b,
2705
+ strong {
2706
+ font-weight: bolder;
2707
+ }
2708
+
2709
+ /*
2710
+ 1. Use the user's configured \`mono\` font-family by default.
2711
+ 2. Use the user's configured \`mono\` font-feature-settings by default.
2712
+ 3. Use the user's configured \`mono\` font-variation-settings by default.
2713
+ 4. Correct the odd \`em\` font sizing in all browsers.
2714
+ */
2715
+
2716
+ code,
2717
+ kbd,
2718
+ samp,
2719
+ pre {
2720
+ font-family: --theme(
2721
+ --default-mono-font-family,
2722
+ ui-monospace,
2723
+ SFMono-Regular,
2724
+ Menlo,
2725
+ Monaco,
2726
+ Consolas,
2727
+ 'Liberation Mono',
2728
+ 'Courier New',
2729
+ monospace
2730
+ ); /* 1 */
2731
+ font-feature-settings: --theme(--default-mono-font-feature-settings, normal); /* 2 */
2732
+ font-variation-settings: --theme(--default-mono-font-variation-settings, normal); /* 3 */
2733
+ font-size: 1em; /* 4 */
2734
+ }
2735
+
2736
+ /*
2737
+ Add the correct font size in all browsers.
2738
+ */
2739
+
2740
+ small {
2741
+ font-size: 80%;
2742
+ }
2743
+
2744
+ /*
2745
+ Prevent \`sub\` and \`sup\` elements from affecting the line height in all browsers.
2746
+ */
2747
+
2748
+ sub,
2749
+ sup {
2750
+ font-size: 75%;
2751
+ line-height: 0;
2752
+ position: relative;
2753
+ vertical-align: baseline;
2754
+ }
2755
+
2756
+ sub {
2757
+ bottom: -0.25em;
2758
+ }
2759
+
2760
+ sup {
2761
+ top: -0.5em;
2762
+ }
2763
+
2764
+ /*
2765
+ 1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
2766
+ 2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
2767
+ 3. Remove gaps between table borders by default.
2768
+ */
2769
+
2770
+ table {
2771
+ text-indent: 0; /* 1 */
2772
+ border-color: inherit; /* 2 */
2773
+ border-collapse: collapse; /* 3 */
2774
+ }
2775
+
2776
+ /*
2777
+ Use the modern Firefox focus style for all focusable elements.
2778
+ */
2779
+
2780
+ :-moz-focusring {
2781
+ outline: auto;
2782
+ }
2783
+
2784
+ /*
2785
+ Add the correct vertical alignment in Chrome and Firefox.
2786
+ */
2787
+
2788
+ progress {
2789
+ vertical-align: baseline;
2790
+ }
2791
+
2792
+ /*
2793
+ Add the correct display in Chrome and Safari.
2794
+ */
2795
+
2796
+ summary {
2797
+ display: list-item;
2798
+ }
2799
+
2800
+ /*
2801
+ Make lists unstyled by default.
2802
+ */
2803
+
2804
+ ol,
2805
+ ul,
2806
+ menu {
2807
+ list-style: none;
2808
+ }
2809
+
2810
+ /*
2811
+ 1. Make replaced elements \`display: block\` by default. (https://github.com/mozdevs/cssremedy/issues/14)
2812
+ 2. Add \`vertical-align: middle\` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
2813
+ This can trigger a poorly considered lint error in some tools but is included by design.
2814
+ */
2815
+
2816
+ img,
2817
+ svg,
2818
+ video,
2819
+ canvas,
2820
+ audio,
2821
+ iframe,
2822
+ embed,
2823
+ object {
2824
+ display: block; /* 1 */
2825
+ vertical-align: middle; /* 2 */
2826
+ }
2827
+
2828
+ /*
2829
+ Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
2830
+ */
2831
+
2832
+ img,
2833
+ video {
2834
+ max-width: 100%;
2835
+ height: auto;
2836
+ }
2837
+
2838
+ /*
2839
+ 1. Inherit font styles in all browsers.
2840
+ 2. Remove border radius in all browsers.
2841
+ 3. Remove background color in all browsers.
2842
+ 4. Ensure consistent opacity for disabled states in all browsers.
2843
+ */
2844
+
2845
+ button,
2846
+ input,
2847
+ select,
2848
+ optgroup,
2849
+ textarea,
2850
+ ::file-selector-button {
2851
+ font: inherit; /* 1 */
2852
+ font-feature-settings: inherit; /* 1 */
2853
+ font-variation-settings: inherit; /* 1 */
2854
+ letter-spacing: inherit; /* 1 */
2855
+ color: inherit; /* 1 */
2856
+ border-radius: 0; /* 2 */
2857
+ background-color: transparent; /* 3 */
2858
+ opacity: 1; /* 4 */
2859
+ }
2860
+
2861
+ /*
2862
+ Restore default font weight.
2863
+ */
2864
+
2865
+ :where(select:is([multiple], [size])) optgroup {
2866
+ font-weight: bolder;
2867
+ }
2868
+
2869
+ /*
2870
+ Restore indentation.
2871
+ */
2872
+
2873
+ :where(select:is([multiple], [size])) optgroup option {
2874
+ padding-inline-start: 20px;
2875
+ }
2876
+
2877
+ /*
2878
+ Restore space after button.
2879
+ */
2880
+
2881
+ ::file-selector-button {
2882
+ margin-inline-end: 4px;
2883
+ }
2884
+
2885
+ /*
2886
+ Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
2887
+ */
2888
+
2889
+ ::placeholder {
2890
+ opacity: 1;
2891
+ }
2892
+
2893
+ /*
2894
+ Set the default placeholder color to a semi-transparent version of the current text color in browsers that do not
2895
+ crash when using \`color-mix(…)\` with \`currentcolor\`. (https://github.com/tailwindlabs/tailwindcss/issues/17194)
2896
+ */
2897
+
2898
+ @supports (not (-webkit-appearance: -apple-pay-button)) /* Not Safari */ or
2899
+ (contain-intrinsic-size: 1px) /* Safari 17+ */ {
2900
+ ::placeholder {
2901
+ color: color-mix(in oklab, currentcolor 50%, transparent);
2902
+ }
2903
+ }
2904
+
2905
+ /*
2906
+ Prevent resizing textareas horizontally by default.
2907
+ */
2908
+
2909
+ textarea {
2910
+ resize: vertical;
2911
+ }
2912
+
2913
+ /*
2914
+ Remove the inner padding in Chrome and Safari on macOS.
2915
+ */
2916
+
2917
+ ::-webkit-search-decoration {
2918
+ -webkit-appearance: none;
2919
+ }
2920
+
2921
+ /*
2922
+ 1. Ensure date/time inputs have the same height when empty in iOS Safari.
2923
+ 2. Ensure text alignment can be changed on date/time inputs in iOS Safari.
2924
+ */
2925
+
2926
+ ::-webkit-date-and-time-value {
2927
+ min-height: 1lh; /* 1 */
2928
+ text-align: inherit; /* 2 */
2929
+ }
2930
+
2931
+ /*
2932
+ Prevent height from changing on date/time inputs in macOS Safari when the input is set to \`display: block\`.
2933
+ */
2934
+
2935
+ ::-webkit-datetime-edit {
2936
+ display: inline-flex;
2937
+ }
2938
+
2939
+ /*
2940
+ Remove excess padding from pseudo-elements in date/time inputs to ensure consistent height across browsers.
2941
+ */
2942
+
2943
+ ::-webkit-datetime-edit-fields-wrapper {
2944
+ padding: 0;
2945
+ }
2946
+
2947
+ ::-webkit-datetime-edit,
2948
+ ::-webkit-datetime-edit-year-field,
2949
+ ::-webkit-datetime-edit-month-field,
2950
+ ::-webkit-datetime-edit-day-field,
2951
+ ::-webkit-datetime-edit-hour-field,
2952
+ ::-webkit-datetime-edit-minute-field,
2953
+ ::-webkit-datetime-edit-second-field,
2954
+ ::-webkit-datetime-edit-millisecond-field,
2955
+ ::-webkit-datetime-edit-meridiem-field {
2956
+ padding-block: 0;
2957
+ }
2958
+
2959
+ /*
2960
+ Center dropdown marker shown on inputs with paired \`<datalist>\`s in Chrome. (https://github.com/tailwindlabs/tailwindcss/issues/18499)
2961
+ */
2962
+
2963
+ ::-webkit-calendar-picker-indicator {
2964
+ line-height: 1;
2965
+ }
2966
+
2967
+ /*
2968
+ Remove the additional \`:invalid\` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
2969
+ */
2970
+
2971
+ :-moz-ui-invalid {
2972
+ box-shadow: none;
2973
+ }
2974
+
2975
+ /*
2976
+ Correct the inability to style the border radius in iOS Safari.
2977
+ */
2978
+
2979
+ button,
2980
+ input:where([type='button'], [type='reset'], [type='submit']),
2981
+ ::file-selector-button {
2982
+ appearance: button;
2983
+ }
2984
+
2985
+ /*
2986
+ Correct the cursor style of increment and decrement buttons in Safari.
2987
+ */
2988
+
2989
+ ::-webkit-inner-spin-button,
2990
+ ::-webkit-outer-spin-button {
2991
+ height: auto;
2992
+ }
2993
+
2994
+ /*
2995
+ Make elements with the HTML hidden attribute stay hidden by default.
2996
+ */
2997
+
2998
+ [hidden]:where(:not([hidden='until-found'])) {
2999
+ display: none !important;
3000
+ }
3001
+ `;
3002
+ var preflight_default = css$2;
3003
+
3004
+ //#endregion
3005
+ //#region src/tailwind/css/theme.ts
3006
+ const css$1 = `
3007
+ @theme default {
3008
+ --font-sans:
3009
+ ui-sans-serif, system-ui, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
3010
+ 'Noto Color Emoji';
3011
+ --font-serif: ui-serif, Georgia, Cambria, 'Times New Roman', Times, serif;
3012
+ --font-mono:
3013
+ ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New',
3014
+ monospace;
3015
+
3016
+ --color-red-50: oklch(97.1% 0.013 17.38);
3017
+ --color-red-100: oklch(93.6% 0.032 17.717);
3018
+ --color-red-200: oklch(88.5% 0.062 18.334);
3019
+ --color-red-300: oklch(80.8% 0.114 19.571);
3020
+ --color-red-400: oklch(70.4% 0.191 22.216);
3021
+ --color-red-500: oklch(63.7% 0.237 25.331);
3022
+ --color-red-600: oklch(57.7% 0.245 27.325);
3023
+ --color-red-700: oklch(50.5% 0.213 27.518);
3024
+ --color-red-800: oklch(44.4% 0.177 26.899);
3025
+ --color-red-900: oklch(39.6% 0.141 25.723);
3026
+ --color-red-950: oklch(25.8% 0.092 26.042);
3027
+
3028
+ --color-orange-50: oklch(98% 0.016 73.684);
3029
+ --color-orange-100: oklch(95.4% 0.038 75.164);
3030
+ --color-orange-200: oklch(90.1% 0.076 70.697);
3031
+ --color-orange-300: oklch(83.7% 0.128 66.29);
3032
+ --color-orange-400: oklch(75% 0.183 55.934);
3033
+ --color-orange-500: oklch(70.5% 0.213 47.604);
3034
+ --color-orange-600: oklch(64.6% 0.222 41.116);
3035
+ --color-orange-700: oklch(55.3% 0.195 38.402);
3036
+ --color-orange-800: oklch(47% 0.157 37.304);
3037
+ --color-orange-900: oklch(40.8% 0.123 38.172);
3038
+ --color-orange-950: oklch(26.6% 0.079 36.259);
3039
+
3040
+ --color-amber-50: oklch(98.7% 0.022 95.277);
3041
+ --color-amber-100: oklch(96.2% 0.059 95.617);
3042
+ --color-amber-200: oklch(92.4% 0.12 95.746);
3043
+ --color-amber-300: oklch(87.9% 0.169 91.605);
3044
+ --color-amber-400: oklch(82.8% 0.189 84.429);
3045
+ --color-amber-500: oklch(76.9% 0.188 70.08);
3046
+ --color-amber-600: oklch(66.6% 0.179 58.318);
3047
+ --color-amber-700: oklch(55.5% 0.163 48.998);
3048
+ --color-amber-800: oklch(47.3% 0.137 46.201);
3049
+ --color-amber-900: oklch(41.4% 0.112 45.904);
3050
+ --color-amber-950: oklch(27.9% 0.077 45.635);
3051
+
3052
+ --color-yellow-50: oklch(98.7% 0.026 102.212);
3053
+ --color-yellow-100: oklch(97.3% 0.071 103.193);
3054
+ --color-yellow-200: oklch(94.5% 0.129 101.54);
3055
+ --color-yellow-300: oklch(90.5% 0.182 98.111);
3056
+ --color-yellow-400: oklch(85.2% 0.199 91.936);
3057
+ --color-yellow-500: oklch(79.5% 0.184 86.047);
3058
+ --color-yellow-600: oklch(68.1% 0.162 75.834);
3059
+ --color-yellow-700: oklch(55.4% 0.135 66.442);
3060
+ --color-yellow-800: oklch(47.6% 0.114 61.907);
3061
+ --color-yellow-900: oklch(42.1% 0.095 57.708);
3062
+ --color-yellow-950: oklch(28.6% 0.066 53.813);
3063
+
3064
+ --color-lime-50: oklch(98.6% 0.031 120.757);
3065
+ --color-lime-100: oklch(96.7% 0.067 122.328);
3066
+ --color-lime-200: oklch(93.8% 0.127 124.321);
3067
+ --color-lime-300: oklch(89.7% 0.196 126.665);
3068
+ --color-lime-400: oklch(84.1% 0.238 128.85);
3069
+ --color-lime-500: oklch(76.8% 0.233 130.85);
3070
+ --color-lime-600: oklch(64.8% 0.2 131.684);
3071
+ --color-lime-700: oklch(53.2% 0.157 131.589);
3072
+ --color-lime-800: oklch(45.3% 0.124 130.933);
3073
+ --color-lime-900: oklch(40.5% 0.101 131.063);
3074
+ --color-lime-950: oklch(27.4% 0.072 132.109);
3075
+
3076
+ --color-green-50: oklch(98.2% 0.018 155.826);
3077
+ --color-green-100: oklch(96.2% 0.044 156.743);
3078
+ --color-green-200: oklch(92.5% 0.084 155.995);
3079
+ --color-green-300: oklch(87.1% 0.15 154.449);
3080
+ --color-green-400: oklch(79.2% 0.209 151.711);
3081
+ --color-green-500: oklch(72.3% 0.219 149.579);
3082
+ --color-green-600: oklch(62.7% 0.194 149.214);
3083
+ --color-green-700: oklch(52.7% 0.154 150.069);
3084
+ --color-green-800: oklch(44.8% 0.119 151.328);
3085
+ --color-green-900: oklch(39.3% 0.095 152.535);
3086
+ --color-green-950: oklch(26.6% 0.065 152.934);
3087
+
3088
+ --color-emerald-50: oklch(97.9% 0.021 166.113);
3089
+ --color-emerald-100: oklch(95% 0.052 163.051);
3090
+ --color-emerald-200: oklch(90.5% 0.093 164.15);
3091
+ --color-emerald-300: oklch(84.5% 0.143 164.978);
3092
+ --color-emerald-400: oklch(76.5% 0.177 163.223);
3093
+ --color-emerald-500: oklch(69.6% 0.17 162.48);
3094
+ --color-emerald-600: oklch(59.6% 0.145 163.225);
3095
+ --color-emerald-700: oklch(50.8% 0.118 165.612);
3096
+ --color-emerald-800: oklch(43.2% 0.095 166.913);
3097
+ --color-emerald-900: oklch(37.8% 0.077 168.94);
3098
+ --color-emerald-950: oklch(26.2% 0.051 172.552);
3099
+
3100
+ --color-teal-50: oklch(98.4% 0.014 180.72);
3101
+ --color-teal-100: oklch(95.3% 0.051 180.801);
3102
+ --color-teal-200: oklch(91% 0.096 180.426);
3103
+ --color-teal-300: oklch(85.5% 0.138 181.071);
3104
+ --color-teal-400: oklch(77.7% 0.152 181.912);
3105
+ --color-teal-500: oklch(70.4% 0.14 182.503);
3106
+ --color-teal-600: oklch(60% 0.118 184.704);
3107
+ --color-teal-700: oklch(51.1% 0.096 186.391);
3108
+ --color-teal-800: oklch(43.7% 0.078 188.216);
3109
+ --color-teal-900: oklch(38.6% 0.063 188.416);
3110
+ --color-teal-950: oklch(27.7% 0.046 192.524);
3111
+
3112
+ --color-cyan-50: oklch(98.4% 0.019 200.873);
3113
+ --color-cyan-100: oklch(95.6% 0.045 203.388);
3114
+ --color-cyan-200: oklch(91.7% 0.08 205.041);
3115
+ --color-cyan-300: oklch(86.5% 0.127 207.078);
3116
+ --color-cyan-400: oklch(78.9% 0.154 211.53);
3117
+ --color-cyan-500: oklch(71.5% 0.143 215.221);
3118
+ --color-cyan-600: oklch(60.9% 0.126 221.723);
3119
+ --color-cyan-700: oklch(52% 0.105 223.128);
3120
+ --color-cyan-800: oklch(45% 0.085 224.283);
3121
+ --color-cyan-900: oklch(39.8% 0.07 227.392);
3122
+ --color-cyan-950: oklch(30.2% 0.056 229.695);
3123
+
3124
+ --color-sky-50: oklch(97.7% 0.013 236.62);
3125
+ --color-sky-100: oklch(95.1% 0.026 236.824);
3126
+ --color-sky-200: oklch(90.1% 0.058 230.902);
3127
+ --color-sky-300: oklch(82.8% 0.111 230.318);
3128
+ --color-sky-400: oklch(74.6% 0.16 232.661);
3129
+ --color-sky-500: oklch(68.5% 0.169 237.323);
3130
+ --color-sky-600: oklch(58.8% 0.158 241.966);
3131
+ --color-sky-700: oklch(50% 0.134 242.749);
3132
+ --color-sky-800: oklch(44.3% 0.11 240.79);
3133
+ --color-sky-900: oklch(39.1% 0.09 240.876);
3134
+ --color-sky-950: oklch(29.3% 0.066 243.157);
3135
+
3136
+ --color-blue-50: oklch(97% 0.014 254.604);
3137
+ --color-blue-100: oklch(93.2% 0.032 255.585);
3138
+ --color-blue-200: oklch(88.2% 0.059 254.128);
3139
+ --color-blue-300: oklch(80.9% 0.105 251.813);
3140
+ --color-blue-400: oklch(70.7% 0.165 254.624);
3141
+ --color-blue-500: oklch(62.3% 0.214 259.815);
3142
+ --color-blue-600: oklch(54.6% 0.245 262.881);
3143
+ --color-blue-700: oklch(48.8% 0.243 264.376);
3144
+ --color-blue-800: oklch(42.4% 0.199 265.638);
3145
+ --color-blue-900: oklch(37.9% 0.146 265.522);
3146
+ --color-blue-950: oklch(28.2% 0.091 267.935);
3147
+
3148
+ --color-indigo-50: oklch(96.2% 0.018 272.314);
3149
+ --color-indigo-100: oklch(93% 0.034 272.788);
3150
+ --color-indigo-200: oklch(87% 0.065 274.039);
3151
+ --color-indigo-300: oklch(78.5% 0.115 274.713);
3152
+ --color-indigo-400: oklch(67.3% 0.182 276.935);
3153
+ --color-indigo-500: oklch(58.5% 0.233 277.117);
3154
+ --color-indigo-600: oklch(51.1% 0.262 276.966);
3155
+ --color-indigo-700: oklch(45.7% 0.24 277.023);
3156
+ --color-indigo-800: oklch(39.8% 0.195 277.366);
3157
+ --color-indigo-900: oklch(35.9% 0.144 278.697);
3158
+ --color-indigo-950: oklch(25.7% 0.09 281.288);
3159
+
3160
+ --color-violet-50: oklch(96.9% 0.016 293.756);
3161
+ --color-violet-100: oklch(94.3% 0.029 294.588);
3162
+ --color-violet-200: oklch(89.4% 0.057 293.283);
3163
+ --color-violet-300: oklch(81.1% 0.111 293.571);
3164
+ --color-violet-400: oklch(70.2% 0.183 293.541);
3165
+ --color-violet-500: oklch(60.6% 0.25 292.717);
3166
+ --color-violet-600: oklch(54.1% 0.281 293.009);
3167
+ --color-violet-700: oklch(49.1% 0.27 292.581);
3168
+ --color-violet-800: oklch(43.2% 0.232 292.759);
3169
+ --color-violet-900: oklch(38% 0.189 293.745);
3170
+ --color-violet-950: oklch(28.3% 0.141 291.089);
3171
+
3172
+ --color-purple-50: oklch(97.7% 0.014 308.299);
3173
+ --color-purple-100: oklch(94.6% 0.033 307.174);
3174
+ --color-purple-200: oklch(90.2% 0.063 306.703);
3175
+ --color-purple-300: oklch(82.7% 0.119 306.383);
3176
+ --color-purple-400: oklch(71.4% 0.203 305.504);
3177
+ --color-purple-500: oklch(62.7% 0.265 303.9);
3178
+ --color-purple-600: oklch(55.8% 0.288 302.321);
3179
+ --color-purple-700: oklch(49.6% 0.265 301.924);
3180
+ --color-purple-800: oklch(43.8% 0.218 303.724);
3181
+ --color-purple-900: oklch(38.1% 0.176 304.987);
3182
+ --color-purple-950: oklch(29.1% 0.149 302.717);
3183
+
3184
+ --color-fuchsia-50: oklch(97.7% 0.017 320.058);
3185
+ --color-fuchsia-100: oklch(95.2% 0.037 318.852);
3186
+ --color-fuchsia-200: oklch(90.3% 0.076 319.62);
3187
+ --color-fuchsia-300: oklch(83.3% 0.145 321.434);
3188
+ --color-fuchsia-400: oklch(74% 0.238 322.16);
3189
+ --color-fuchsia-500: oklch(66.7% 0.295 322.15);
3190
+ --color-fuchsia-600: oklch(59.1% 0.293 322.896);
3191
+ --color-fuchsia-700: oklch(51.8% 0.253 323.949);
3192
+ --color-fuchsia-800: oklch(45.2% 0.211 324.591);
3193
+ --color-fuchsia-900: oklch(40.1% 0.17 325.612);
3194
+ --color-fuchsia-950: oklch(29.3% 0.136 325.661);
3195
+
3196
+ --color-pink-50: oklch(97.1% 0.014 343.198);
3197
+ --color-pink-100: oklch(94.8% 0.028 342.258);
3198
+ --color-pink-200: oklch(89.9% 0.061 343.231);
3199
+ --color-pink-300: oklch(82.3% 0.12 346.018);
3200
+ --color-pink-400: oklch(71.8% 0.202 349.761);
3201
+ --color-pink-500: oklch(65.6% 0.241 354.308);
3202
+ --color-pink-600: oklch(59.2% 0.249 0.584);
3203
+ --color-pink-700: oklch(52.5% 0.223 3.958);
3204
+ --color-pink-800: oklch(45.9% 0.187 3.815);
3205
+ --color-pink-900: oklch(40.8% 0.153 2.432);
3206
+ --color-pink-950: oklch(28.4% 0.109 3.907);
3207
+
3208
+ --color-rose-50: oklch(96.9% 0.015 12.422);
3209
+ --color-rose-100: oklch(94.1% 0.03 12.58);
3210
+ --color-rose-200: oklch(89.2% 0.058 10.001);
3211
+ --color-rose-300: oklch(81% 0.117 11.638);
3212
+ --color-rose-400: oklch(71.2% 0.194 13.428);
3213
+ --color-rose-500: oklch(64.5% 0.246 16.439);
3214
+ --color-rose-600: oklch(58.6% 0.253 17.585);
3215
+ --color-rose-700: oklch(51.4% 0.222 16.935);
3216
+ --color-rose-800: oklch(45.5% 0.188 13.697);
3217
+ --color-rose-900: oklch(41% 0.159 10.272);
3218
+ --color-rose-950: oklch(27.1% 0.105 12.094);
3219
+
3220
+ --color-slate-50: oklch(98.4% 0.003 247.858);
3221
+ --color-slate-100: oklch(96.8% 0.007 247.896);
3222
+ --color-slate-200: oklch(92.9% 0.013 255.508);
3223
+ --color-slate-300: oklch(86.9% 0.022 252.894);
3224
+ --color-slate-400: oklch(70.4% 0.04 256.788);
3225
+ --color-slate-500: oklch(55.4% 0.046 257.417);
3226
+ --color-slate-600: oklch(44.6% 0.043 257.281);
3227
+ --color-slate-700: oklch(37.2% 0.044 257.287);
3228
+ --color-slate-800: oklch(27.9% 0.041 260.031);
3229
+ --color-slate-900: oklch(20.8% 0.042 265.755);
3230
+ --color-slate-950: oklch(12.9% 0.042 264.695);
3231
+
3232
+ --color-gray-50: oklch(98.5% 0.002 247.839);
3233
+ --color-gray-100: oklch(96.7% 0.003 264.542);
3234
+ --color-gray-200: oklch(92.8% 0.006 264.531);
3235
+ --color-gray-300: oklch(87.2% 0.01 258.338);
3236
+ --color-gray-400: oklch(70.7% 0.022 261.325);
3237
+ --color-gray-500: oklch(55.1% 0.027 264.364);
3238
+ --color-gray-600: oklch(44.6% 0.03 256.802);
3239
+ --color-gray-700: oklch(37.3% 0.034 259.733);
3240
+ --color-gray-800: oklch(27.8% 0.033 256.848);
3241
+ --color-gray-900: oklch(21% 0.034 264.665);
3242
+ --color-gray-950: oklch(13% 0.028 261.692);
3243
+
3244
+ --color-zinc-50: oklch(98.5% 0 0);
3245
+ --color-zinc-100: oklch(96.7% 0.001 286.375);
3246
+ --color-zinc-200: oklch(92% 0.004 286.32);
3247
+ --color-zinc-300: oklch(87.1% 0.006 286.286);
3248
+ --color-zinc-400: oklch(70.5% 0.015 286.067);
3249
+ --color-zinc-500: oklch(55.2% 0.016 285.938);
3250
+ --color-zinc-600: oklch(44.2% 0.017 285.786);
3251
+ --color-zinc-700: oklch(37% 0.013 285.805);
3252
+ --color-zinc-800: oklch(27.4% 0.006 286.033);
3253
+ --color-zinc-900: oklch(21% 0.006 285.885);
3254
+ --color-zinc-950: oklch(14.1% 0.005 285.823);
3255
+
3256
+ --color-neutral-50: oklch(98.5% 0 0);
3257
+ --color-neutral-100: oklch(97% 0 0);
3258
+ --color-neutral-200: oklch(92.2% 0 0);
3259
+ --color-neutral-300: oklch(87% 0 0);
3260
+ --color-neutral-400: oklch(70.8% 0 0);
3261
+ --color-neutral-500: oklch(55.6% 0 0);
3262
+ --color-neutral-600: oklch(43.9% 0 0);
3263
+ --color-neutral-700: oklch(37.1% 0 0);
3264
+ --color-neutral-800: oklch(26.9% 0 0);
3265
+ --color-neutral-900: oklch(20.5% 0 0);
3266
+ --color-neutral-950: oklch(14.5% 0 0);
3267
+
3268
+ --color-stone-50: oklch(98.5% 0.001 106.423);
3269
+ --color-stone-100: oklch(97% 0.001 106.424);
3270
+ --color-stone-200: oklch(92.3% 0.003 48.717);
3271
+ --color-stone-300: oklch(86.9% 0.005 56.366);
3272
+ --color-stone-400: oklch(70.9% 0.01 56.259);
3273
+ --color-stone-500: oklch(55.3% 0.013 58.071);
3274
+ --color-stone-600: oklch(44.4% 0.011 73.639);
3275
+ --color-stone-700: oklch(37.4% 0.01 67.558);
3276
+ --color-stone-800: oklch(26.8% 0.007 34.298);
3277
+ --color-stone-900: oklch(21.6% 0.006 56.043);
3278
+ --color-stone-950: oklch(14.7% 0.004 49.25);
3279
+
3280
+ --color-black: #000;
3281
+ --color-white: #fff;
3282
+
3283
+ --spacing: 0.25rem;
3284
+
3285
+ --breakpoint-sm: 40rem;
3286
+ --breakpoint-md: 48rem;
3287
+ --breakpoint-lg: 64rem;
3288
+ --breakpoint-xl: 80rem;
3289
+ --breakpoint-2xl: 96rem;
3290
+
3291
+ --container-3xs: 16rem;
3292
+ --container-2xs: 18rem;
3293
+ --container-xs: 20rem;
3294
+ --container-sm: 24rem;
3295
+ --container-md: 28rem;
3296
+ --container-lg: 32rem;
3297
+ --container-xl: 36rem;
3298
+ --container-2xl: 42rem;
3299
+ --container-3xl: 48rem;
3300
+ --container-4xl: 56rem;
3301
+ --container-5xl: 64rem;
3302
+ --container-6xl: 72rem;
3303
+ --container-7xl: 80rem;
3304
+
3305
+ --text-xs: 0.75rem;
3306
+ --text-xs--line-height: calc(1 / 0.75);
3307
+ --text-sm: 0.875rem;
3308
+ --text-sm--line-height: calc(1.25 / 0.875);
3309
+ --text-base: 1rem;
3310
+ --text-base--line-height: calc(1.5 / 1);
3311
+ --text-lg: 1.125rem;
3312
+ --text-lg--line-height: calc(1.75 / 1.125);
3313
+ --text-xl: 1.25rem;
3314
+ --text-xl--line-height: calc(1.75 / 1.25);
3315
+ --text-2xl: 1.5rem;
3316
+ --text-2xl--line-height: calc(2 / 1.5);
3317
+ --text-3xl: 1.875rem;
3318
+ --text-3xl--line-height: calc(2.25 / 1.875);
3319
+ --text-4xl: 2.25rem;
3320
+ --text-4xl--line-height: calc(2.5 / 2.25);
3321
+ --text-5xl: 3rem;
3322
+ --text-5xl--line-height: 1;
3323
+ --text-6xl: 3.75rem;
3324
+ --text-6xl--line-height: 1;
3325
+ --text-7xl: 4.5rem;
3326
+ --text-7xl--line-height: 1;
3327
+ --text-8xl: 6rem;
3328
+ --text-8xl--line-height: 1;
3329
+ --text-9xl: 8rem;
3330
+ --text-9xl--line-height: 1;
3331
+
3332
+ --font-weight-thin: 100;
3333
+ --font-weight-extralight: 200;
3334
+ --font-weight-light: 300;
3335
+ --font-weight-normal: 400;
3336
+ --font-weight-medium: 500;
3337
+ --font-weight-semibold: 600;
3338
+ --font-weight-bold: 700;
3339
+ --font-weight-extrabold: 800;
3340
+ --font-weight-black: 900;
3341
+
3342
+ --tracking-tighter: -0.05em;
3343
+ --tracking-tight: -0.025em;
3344
+ --tracking-normal: 0em;
3345
+ --tracking-wide: 0.025em;
3346
+ --tracking-wider: 0.05em;
3347
+ --tracking-widest: 0.1em;
3348
+
3349
+ --leading-tight: 1.25;
3350
+ --leading-snug: 1.375;
3351
+ --leading-normal: 1.5;
3352
+ --leading-relaxed: 1.625;
3353
+ --leading-loose: 2;
3354
+
3355
+ --radius-xs: 0.125rem;
3356
+ --radius-sm: 0.25rem;
3357
+ --radius-md: 0.375rem;
3358
+ --radius-lg: 0.5rem;
3359
+ --radius-xl: 0.75rem;
3360
+ --radius-2xl: 1rem;
3361
+ --radius-3xl: 1.5rem;
3362
+ --radius-4xl: 2rem;
3363
+
3364
+ --shadow-2xs: 0 1px rgb(0 0 0 / 0.05);
3365
+ --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);
3366
+ --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
3367
+ --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
3368
+ --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
3369
+ --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
3370
+ --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
3371
+
3372
+ --inset-shadow-2xs: inset 0 1px rgb(0 0 0 / 0.05);
3373
+ --inset-shadow-xs: inset 0 1px 1px rgb(0 0 0 / 0.05);
3374
+ --inset-shadow-sm: inset 0 2px 4px rgb(0 0 0 / 0.05);
3375
+
3376
+ --drop-shadow-xs: 0 1px 1px rgb(0 0 0 / 0.05);
3377
+ --drop-shadow-sm: 0 1px 2px rgb(0 0 0 / 0.15);
3378
+ --drop-shadow-md: 0 3px 3px rgb(0 0 0 / 0.12);
3379
+ --drop-shadow-lg: 0 4px 4px rgb(0 0 0 / 0.15);
3380
+ --drop-shadow-xl: 0 9px 7px rgb(0 0 0 / 0.1);
3381
+ --drop-shadow-2xl: 0 25px 25px rgb(0 0 0 / 0.15);
3382
+
3383
+ --text-shadow-2xs: 0px 1px 0px rgb(0 0 0 / 0.15);
3384
+ --text-shadow-xs: 0px 1px 1px rgb(0 0 0 / 0.2);
3385
+ --text-shadow-sm:
3386
+ 0px 1px 0px rgb(0 0 0 / 0.075), 0px 1px 1px rgb(0 0 0 / 0.075), 0px 2px 2px rgb(0 0 0 / 0.075);
3387
+ --text-shadow-md:
3388
+ 0px 1px 1px rgb(0 0 0 / 0.1), 0px 1px 2px rgb(0 0 0 / 0.1), 0px 2px 4px rgb(0 0 0 / 0.1);
3389
+ --text-shadow-lg:
3390
+ 0px 1px 2px rgb(0 0 0 / 0.1), 0px 3px 2px rgb(0 0 0 / 0.1), 0px 4px 8px rgb(0 0 0 / 0.1);
3391
+
3392
+ --ease-in: cubic-bezier(0.4, 0, 1, 1);
3393
+ --ease-out: cubic-bezier(0, 0, 0.2, 1);
3394
+ --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
3395
+
3396
+ --animate-spin: spin 1s linear infinite;
3397
+ --animate-ping: ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
3398
+ --animate-pulse: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
3399
+ --animate-bounce: bounce 1s infinite;
3400
+
3401
+ @keyframes spin {
3402
+ to {
3403
+ transform: rotate(360deg);
3404
+ }
3405
+ }
3406
+
3407
+ @keyframes ping {
3408
+ 75%,
3409
+ 100% {
3410
+ transform: scale(2);
3411
+ opacity: 0;
3412
+ }
3413
+ }
3414
+
3415
+ @keyframes pulse {
3416
+ 50% {
3417
+ opacity: 0.5;
3418
+ }
3419
+ }
3420
+
3421
+ @keyframes bounce {
3422
+ 0%,
3423
+ 100% {
3424
+ transform: translateY(-25%);
3425
+ animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
3426
+ }
3427
+
3428
+ 50% {
3429
+ transform: none;
3430
+ animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
3431
+ }
3432
+ }
3433
+
3434
+ --blur-xs: 4px;
3435
+ --blur-sm: 8px;
3436
+ --blur-md: 12px;
3437
+ --blur-lg: 16px;
3438
+ --blur-xl: 24px;
3439
+ --blur-2xl: 40px;
3440
+ --blur-3xl: 64px;
3441
+
3442
+ --perspective-dramatic: 100px;
3443
+ --perspective-near: 300px;
3444
+ --perspective-normal: 500px;
3445
+ --perspective-midrange: 800px;
3446
+ --perspective-distant: 1200px;
3447
+
3448
+ --aspect-video: 16 / 9;
3449
+
3450
+ --default-transition-duration: 150ms;
3451
+ --default-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
3452
+ --default-font-family: --theme(--font-sans, initial);
3453
+ --default-font-feature-settings: --theme(--font-sans--font-feature-settings, initial);
3454
+ --default-font-variation-settings: --theme(--font-sans--font-variation-settings, initial);
3455
+ --default-mono-font-family: --theme(--font-mono, initial);
3456
+ --default-mono-font-feature-settings: --theme(--font-mono--font-feature-settings, initial);
3457
+ --default-mono-font-variation-settings: --theme(--font-mono--font-variation-settings, initial);
3458
+ }
3459
+
3460
+ /* Deprecated */
3461
+ @theme default inline reference {
3462
+ --blur: 8px;
3463
+ --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
3464
+ --shadow-inner: inset 0 2px 4px 0 rgb(0 0 0 / 0.05);
3465
+ --drop-shadow: 0 1px 2px rgb(0 0 0 / 0.1), 0 1px 1px rgb(0 0 0 / 0.06);
3466
+ --radius: 0.25rem;
3467
+ --max-width-prose: 65ch;
3468
+ }
3469
+ `;
3470
+ var theme_default = css$1;
3471
+
3472
+ //#endregion
3473
+ //#region src/tailwind/css/utilities.ts
3474
+ const css = `
3475
+ @tailwind utilities;
3476
+ `;
3477
+ var utilities_default = css;
3478
+
3479
+ //#endregion
3480
+ //#region src/tailwind/setup-tailwind.ts
3481
+ async function setupTailwind(config) {
3482
+ const baseCss = `
3483
+ @layer theme, base, components, utilities;
3484
+ @import "tailwindcss/theme.css" layer(theme);
3485
+ @import "tailwindcss/utilities.css" layer(utilities);
3486
+ @config;
3487
+ `;
3488
+ const compiler = await (0, tailwindcss.compile)(baseCss, {
3489
+ async loadModule(id, base, resourceHint) {
3490
+ if (resourceHint === "config") return {
3491
+ path: id,
3492
+ base,
3493
+ module: config
3494
+ };
3495
+ throw new Error(`NO-OP: should we implement support for ${resourceHint}?`);
3496
+ },
3497
+ polyfills: 0,
3498
+ async loadStylesheet(id, base) {
3499
+ if (id === "tailwindcss") return {
3500
+ base,
3501
+ path: "tailwindcss/index.css",
3502
+ content: css_default
3503
+ };
3504
+ if (id === "tailwindcss/preflight.css") return {
3505
+ base,
3506
+ path: id,
3507
+ content: preflight_default
3508
+ };
3509
+ if (id === "tailwindcss/theme.css") return {
3510
+ base,
3511
+ path: id,
3512
+ content: theme_default
3513
+ };
3514
+ if (id === "tailwindcss/utilities.css") return {
3515
+ base,
3516
+ path: id,
3517
+ content: utilities_default
3518
+ };
3519
+ throw new Error("stylesheet not supported, you can only import the ones from tailwindcss");
3520
+ }
3521
+ });
3522
+ let css$4 = baseCss;
3523
+ return {
3524
+ addUtilities: function addUtilities(candidates) {
3525
+ css$4 = compiler.build(candidates);
3526
+ },
3527
+ getStyleSheet: function getCss() {
3528
+ return (0, css_tree.parse)(css$4);
3529
+ }
3530
+ };
3531
+ }
3532
+
3533
+ //#endregion
3534
+ //#region src/tailwind/tailwind.tsx
3535
+ const pixelBasedPreset = { theme: { extend: {
3536
+ fontSize: {
3537
+ xs: ["12px", { lineHeight: "16px" }],
3538
+ sm: ["14px", { lineHeight: "20px" }],
3539
+ base: ["16px", { lineHeight: "24px" }],
3540
+ lg: ["18px", { lineHeight: "28px" }],
3541
+ xl: ["20px", { lineHeight: "28px" }],
3542
+ "2xl": ["24px", { lineHeight: "32px" }],
3543
+ "3xl": ["30px", { lineHeight: "36px" }],
3544
+ "4xl": ["36px", { lineHeight: "36px" }],
3545
+ "5xl": ["48px", { lineHeight: "1" }],
3546
+ "6xl": ["60px", { lineHeight: "1" }],
3547
+ "7xl": ["72px", { lineHeight: "1" }],
3548
+ "8xl": ["96px", { lineHeight: "1" }],
3549
+ "9xl": ["144px", { lineHeight: "1" }]
3550
+ },
3551
+ spacing: {
3552
+ px: "1px",
3553
+ 0: "0",
3554
+ .5: "2px",
3555
+ 1: "4px",
3556
+ 1.5: "6px",
3557
+ 2: "8px",
3558
+ 2.5: "10px",
3559
+ 3: "12px",
3560
+ 3.5: "14px",
3561
+ 4: "16px",
3562
+ 5: "20px",
3563
+ 6: "24px",
3564
+ 7: "28px",
3565
+ 8: "32px",
3566
+ 9: "36px",
3567
+ 10: "40px",
3568
+ 11: "44px",
3569
+ 12: "48px",
3570
+ 14: "56px",
3571
+ 16: "64px",
3572
+ 20: "80px",
3573
+ 24: "96px",
3574
+ 28: "112px",
3575
+ 32: "128px",
3576
+ 36: "144px",
3577
+ 40: "160px",
3578
+ 44: "176px",
3579
+ 48: "192px",
3580
+ 52: "208px",
3581
+ 56: "224px",
3582
+ 60: "240px",
3583
+ 64: "256px",
3584
+ 72: "288px",
3585
+ 80: "320px",
3586
+ 96: "384px"
3587
+ }
3588
+ } } };
3589
+ function Tailwind({ children, config }) {
3590
+ const tailwindSetup = useSuspensedPromise(() => setupTailwind(config ?? {}), JSON.stringify(config, (_key, value) => typeof value === "function" ? value.toString() : value));
3591
+ let classesUsed = [];
3592
+ let mappedChildren = mapReactTree(children, (node) => {
3593
+ if (react.isValidElement(node)) {
3594
+ if (node.props.className) {
3595
+ const classes = node.props.className?.split(/\s+/);
3596
+ classesUsed = [...classesUsed, ...classes];
3597
+ tailwindSetup.addUtilities(classes);
3598
+ }
3599
+ }
3600
+ return node;
3601
+ });
3602
+ const styleSheet = tailwindSetup.getStyleSheet();
3603
+ sanitizeStyleSheet(styleSheet);
3604
+ const { inlinable: inlinableRules, nonInlinable: nonInlinableRules } = extractRulesPerClass(styleSheet, classesUsed);
3605
+ const customProperties = getCustomProperties(styleSheet);
3606
+ const nonInlineStyles = {
3607
+ type: "StyleSheet",
3608
+ children: new css_tree.List().fromArray(Array.from(nonInlinableRules.values()))
3609
+ };
3610
+ sanitizeNonInlinableRules(nonInlineStyles);
3611
+ const hasNonInlineStylesToApply = nonInlinableRules.size > 0;
3612
+ let appliedNonInlineStyles = false;
3613
+ mappedChildren = mapReactTree(mappedChildren, (node) => {
3614
+ if (react.isValidElement(node)) {
3615
+ const elementWithInlinedStyles = cloneElementWithInlinedStyles(node, inlinableRules, nonInlinableRules, customProperties);
3616
+ if (elementWithInlinedStyles.type === "head") {
3617
+ appliedNonInlineStyles = true;
3618
+ const styleElement = /* @__PURE__ */ (0, react_jsx_runtime.jsx)("style", { dangerouslySetInnerHTML: { __html: (0, css_tree.generate)(nonInlineStyles) } });
3619
+ return react.cloneElement(elementWithInlinedStyles, elementWithInlinedStyles.props, styleElement, elementWithInlinedStyles.props.children);
3620
+ }
3621
+ return elementWithInlinedStyles;
3622
+ }
3623
+ return node;
3624
+ });
3625
+ if (hasNonInlineStylesToApply && !appliedNonInlineStyles) throw new Error(`You are trying to use the following Tailwind classes that cannot be inlined: ${Array.from(nonInlinableRules.keys()).join(" ")}.
3626
+ For the media queries to work properly on rendering, they need to be added into a <style> tag inside of a <head> tag.
3627
+ The Tailwind component tried finding a <head> element but was unable to find it.
3628
+
3629
+ Make sure that you have a <head> element at some point inside of the <Tailwind> component at any depth.
3630
+ This can also be unmail's <Head> component.`);
3631
+ return mappedChildren;
3632
+ }
3633
+
3634
+ //#endregion
3635
+ exports.Body = Body;
3636
+ exports.Button = Button;
3637
+ exports.Column = Column;
3638
+ exports.Container = Container;
3639
+ exports.Font = Font;
3640
+ exports.Head = Head;
3641
+ exports.Heading = Heading;
3642
+ exports.Hr = Hr;
3643
+ exports.Html = Html;
3644
+ exports.Img = Img;
3645
+ exports.Link = Link;
3646
+ exports.Markdown = Markdown;
3647
+ exports.Preview = Preview;
3648
+ exports.Row = Row;
3649
+ exports.Section = Section;
3650
+ exports.Tailwind = Tailwind;
3651
+ exports.Text = Text;
3652
+ exports.pixelBasedPreset = pixelBasedPreset;
3653
+ exports.render = render;