@xuda.io/xuda-framework-plugin-tailwind
Version:
Xuda Tailwind UI Framework plugin
1,487 lines (1,456 loc) • 657 kB
JavaScript
const Va = {
primary: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
secondary: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
tertiary: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
success: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
warning: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
danger: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
light: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
medium: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 ",
dark: " border-gray-300 bg-white bg-red-600 text-gray-700 hover:bg-gray-50 focus:ring-indigo-500 "
}, Cf = class {
init(H) {
var we;
if (!((we = H == null ? void 0 : H.theme) != null && we.init))
return console.warn("UI framework theme setup not found");
var ce = "xuda-framework-plugin-tailwind-script-" + Date.now();
const be = document.createElement("script");
return be.setAttribute("id", ce), be.innerHTML = H.theme.init, document.head.append(be), ce;
}
discard(H) {
document.getElementById(H).remove();
}
refresh(H, ce) {
return $(H);
}
rootTagName() {
return "div";
}
customUiClasses() {
return [];
}
renderEngineProperties() {
return {
restrict_tags: !0,
engine: function() {
},
tags: {
col: {
attributes: {
type: {
label: "Modal Position",
type: "string",
render: "select",
options: [
{ label: "Stretch", value: "stretch" },
{ label: "Start", value: "start" },
{ label: "Center", value: "center" },
{ label: "End", value: "end" }
]
}
},
render() {
return "<div > <button/> </div>";
}
}
},
tags2: { img: ["src", "alt"] },
classes: [],
common_tags: []
};
}
}, Sf = class {
setter(H, ce) {
if ($(H).prop("tagName") === "SELECT")
setTimeout(() => {
$(H).val(_.toString(ce));
}, 250);
else
switch ($(H).attr("type")) {
case "radio":
$(H).attr("value") === ce ? $(H).prop("checked", !0) : $(H).prop("checked", !1);
break;
case "checkbox":
ce ? $(H).prop("checked", !0) : $(H).prop("checked", !1);
break;
case "time":
ce.length === 5 && (ce = ce + ":00", $(H).val(ce));
break;
default:
$(H).val(ce);
}
}
getter(H) {
switch ($(H).attr("type")) {
case "radio":
if ($(H).attr("checked") || $(H).is(":checked"))
return $(H).attr("checked", !0), $(H).attr("value");
break;
case "checkbox":
if ($(H).attr("checked") || $(H).is(":checked"))
return $(H).attr("checked", !0), $(H).attr("value");
break;
default:
return $(H).val();
}
}
listener(H, ce) {
$(H).on("change", (be) => {
ce(be);
});
}
}, _f = class {
async create(H, ce, be) {
let we = "";
switch (H) {
case "error":
we = '<svg class="w-6 h-6 text-red-500" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>', console.info(ce);
break;
case "success":
we = '<svg class="w-6 h-6 text-green-500" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>';
break;
case "info":
we = '<svg class="w-6 h-6 text-gray-500" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>';
break;
case "warning":
we = '<svg class="w-6 h-6 text-yellow-500" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"></path></svg>', console.info(ce);
break;
}
this.$html = $(`
<div class="w-full flex flex-col items-center space-y-4 sm:items-end">
<div class="max-w-sm w-full bg-white shadow-lg rounded-lg pointer-events-auto ring-1 ring-black ring-opacity-5 overflow-hidden">
<div class="p-4">
<div class="flex items-start">
<div class="flex-shrink-0">
${we}
</div>
<div class="ms-3 w-0 flex-1 pt-0.5">
<p class="text-sm font-medium text-gray-900"></p>
${be}
<p class="text-sm text-gray-500">
${ce}
</p>
</div>
<div class="ml-4 flex-shrink-0 flex">
<button class="bg-white rounded-md inline-flex text-gray-400 hover:text-gray-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500">
<span class="sr-only">Close</span>
<svg class="h-5 w-5" viewBox="0 0 20 20" fill="currentColor" aria-hidden="true">
<path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"></path>
</svg>
</button>
</div>
</div>
</div>
</div>
</div>
`), $("#tailwind_toast_controller").append(this.$html.hide().fadeIn()), this.$html.find("button").click(() => {
this.$html.remove();
}), setTimeout(() => {
this.$html.fadeOut("slow", function() {
$(this).remove();
});
}, 5e3);
}
init(H) {
}
close() {
this.$html.remove();
}
}, Ef = class {
async create() {
const ce = (function() {
var be = void 0;
return {
create: function() {
be = Date.now();
},
present: function() {
const we = $(`<div id="tailwind_loader_${be}" class="absolute z-[999] inset-0 px-4 sm:inset-0 sm:flex sm:items-center sm:justify-center spinny">
<div class="absolute inset-0 transition-opacity">
<div class="absolute inset-0 rounded-md bg-gray-900 opacity-30"></div>
</div>
<div class="transform transition-all sm:max-w-2xl w-full h-full flex items-center" role="dialog" aria-modal="true" aria-labelledby="modal-headline">
<div class="spinner spinner-add ease-linear my-auto mx-auto">
${text || "Please wait.."}
</div>
</div>
</div>`);
return $("#tailwind_loader_" + be).remove(), $("body").prepend(we), we;
},
dismiss: function() {
$("#tailwind_loader_" + be).remove();
}
};
}).create();
return ce.present(), ce;
}
init(H) {
}
close(H) {
$("#tailwind_loader_" + H).remove();
}
}, Of = class {
async open(H) {
this.SESSION_ID = H.SESSION_ID;
const ce = function() {
return {
create: function(we) {
},
present: function() {
$("#xu_popover_modal_" + H.SESSION_ID).remove();
const we = `
<div id="xu_popover_modal_${H.SESSION_ID}" class="absolute z-10 inline-block w-64 text-sm font-light text-gray-500 transition-opacity duration-300 bg-white border border-gray-200 rounded-lg shadow-sm dark:text-gray-400 dark:bg-gray-800 dark:border-gray-600 " >
<xu-popover-content-${H.SESSION_ID}>
</div>
`;
return $("body").prepend(we), we;
},
dismiss: function() {
$("#xu_popover_modal_" + H.SESSION_ID).remove();
}
};
};
new ce().present();
}
async set(H) {
}
async close(H) {
$("#xu_popover_modal_" + this.SESSION_ID).remove();
}
}, Rf = class {
async create(H, ce, be, we) {
var Ye = "";
we.forEach((Be) => {
Ye += `
<button id="${Be.role || Be}_button" type="button" class=" ${Va[Be.cssClass] || Va.secondary} mt-3 w-full inline-flex justify-center rounded-md border shadow-sm px-4 py-2 text-base font-medium focus:outline-none focus:ring-2 focus:ring-offset-2 sm:mt-0 sm:ml-3 sm:w-auto sm:text-sm">
${Be.text || Be}
</button>
`;
}), this.$html = $(`
<div class="fixed z-10 inset-0 overflow-y-auto" aria-labelledby="modal-title" role="dialog" aria-modal="true">
<div class="flex items-end justify-center min-h-screen pt-4 px-4 pb-20 text-center sm:block sm:p-0">
<div class="fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity" aria-hidden="true"></div>
<span class="hidden sm:inline-block sm:align-middle sm:h-screen" aria-hidden="true">​</span>
<div class="inline-block align-bottom bg-white rounded-lg text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-lg sm:w-full">
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4">
<div class="sm:flex sm:items-start">
<div class="mx-auto flex-shrink-0 flex items-center justify-center h-12 w-12 rounded-full bg-red-100 sm:mx-0 sm:h-10 sm:w-10">
<!-- Heroicon name: outline/exclamation -->
<svg class="h-6 w-6 text-red-600" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor" aria-hidden="true">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z" />
</svg>
</div>
<div class="mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left">
<h3 class="text-lg leading-6 font-medium text-gray-900" id="modal-title">
${ce}
</h3>
<div class="mt-2">
<p class="text-sm text-gray-500">
${be}
</p>
</div>
</div>
</div>
</div>
<div class="bg-gray-50 px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse">
${Ye}
</div>
</div>
</div>
</div>
`), $("body").append(this.$html), we.forEach((Be) => {
$(`#${Be.role || Be}_button`).click(() => {
this.$html.remove(), Be.handler && Be.handler();
});
});
}
async update(H) {
}
async close(H) {
this.$html.remove();
}
}, Tf = class {
async create(H) {
var we, Ye, Be, Ft, ir, z, I, He;
let be = ` <div class="border-b py-3 px-4 flex items-center justify-between">
<h3 class="font-medium leading-6 text-gray-900 sm:text-lg" id="modal-title"> ${(we = H.properties) == null ? void 0 : we.name} </h3>
${(Ye = H.properties) != null && Ye.disableModalClose ? "" : `
<button type="button" class="">
<svg class="h-5 w-5" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor" aria-hidden="true"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"></path></svg>
</button>
`}
</div>`;
return this.template = $(`
<div class="relative z-10">
<div class="fixed inset-0 z-10 overflow-y-auto">
${(Be = H.properties) != null && Be.allowBackdropDismiss ? '<div class="fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity backDrop"></div>' : ""}
<div class="flex min-h-full items-${(Ft = H == null ? void 0 : H.properties) != null && Ft.modalPosition ? (ir = H.properties) == null ? void 0 : ir.modalPosition : "end"} justify-center sm:items-center">
<div class="relative mx-4 my-2 w-full transform overflow-hidden rounded-lg border border-gray-50 shadow-xl transition-all sm:max-w-lg bg-white">
${(z = H.properties) != null && z.hideHeader ? "" : be}
<div class="template_body">
</div>
</div>
</div>
</div>
</div>
`), this.close_callback = H.close_callback, this.modal_id = H.modal_id, this.modal = $("<" + H.modal_id + ">"), $("body").append(this.modal), $(H.modal_id).html(this.template), (I = H.properties) != null && I.disableModalClose || $(H.modal_id).find("button").click(() => {
this.close();
}), (He = H == null ? void 0 : H.properties) != null && He.allowBackdropDismiss && $(H.modal_id).find(".backDrop").click(() => {
this.close();
}), this;
}
async init(H) {
const ce = document.querySelector("xu-modal-controller");
var be = $(H.modal_id), we = $(ce).data().xuControllerParams[H.modal_id];
H.$container && (be.attr("id", H.$container.attr("id")), $.each(H.$container.data(), function(Ye, Be) {
be.data(Ye, Be);
})), be.find(".template_body").html(we.$dialogDiv);
}
async present(H) {
await H.present();
}
async properties() {
return {
modalPosition: {
label: "Modal Position",
type: "string",
render: "select",
options: [
{ label: "Stretch", value: "stretch" },
{ label: "Start", value: "start" },
{ label: "Center", value: "center" },
{ label: "End", value: "end" }
]
},
allowBackdropDismiss: {
label: "Allow Backdrop Dismiss",
type: "bool",
render: "checkbox"
},
allowModalClose: {
label: "Allow Modal Close",
type: "bool",
render: "checkbox"
},
hideHeader: {
label: "Hide Header",
render: "checkbox",
type: "bool"
}
};
}
async close() {
this.modal.remove(), this.close_callback && this.close_callback(this.modal_id);
}
}, $f = class {
async create(H) {
var be, we, Ye;
this.$page = $("<div>");
const ce = $(` <div class="flex py-3 px-2 border-b">
<h3 class="font-medium leading-6 text-gray-900 sm:text-lg" id="modal-title">${H.properties.name}</h3>
</div>
`);
(be = H == null ? void 0 : H.properties) != null && be.disablePageBack || $(` <button type="button" class="mr-3">
<svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M9.707 16.707a1 1 0 01-1.414 0l-6-6a1 1 0 010-1.414l6-6a1 1 0 011.414 1.414L5.414 9H17a1 1 0 110 2H5.414l4.293 4.293a1 1 0 010 1.414z" clip-rule="evenodd"></path></svg>
</button>`).prependTo(ce).off("click").on("click", async () => {
this.page_back_callback();
}), (we = H == null ? void 0 : H.properties) != null && we.hideHeader || (Ye = H == null ? void 0 : H.properties) != null && Ye.disablePageBack || ce.appendTo(this.$page);
}
async init(H) {
H.callback = (ce, be) => {
$(ce).append(this.$page.children()), $(ce).append(H.div), this.page_back_callback = be;
};
}
async properties() {
return {
allowPageBack: {
label: "Allow Page Back",
render: "checkbox",
type: "bool"
},
hideHeader: {
label: "Hide Header",
render: "checkbox",
type: "bool"
}
};
}
}, If = () => {
Promise.resolve().then(() => kf);
};
(() => {
var H = Object.create, ce = Object.defineProperty, be = Object.getOwnPropertyDescriptor, we = Object.getOwnPropertyNames, Ye = Object.getPrototypeOf, Be = Object.prototype.hasOwnProperty, Ft = (e) => ce(e, "__esModule", {
value: !0
}), ir = (e) => {
if (typeof require < "u") return require(e);
throw new Error('Dynamic require of "' + e + '" is not supported');
}, z = (e, t) => () => (e && (t = e(e = 0)), t), I = (e, t) => () => (t || e(
(t = {
exports: {}
}).exports,
t
), t.exports), He = (e, t) => {
Ft(e);
for (var r in t)
ce(e, r, {
get: t[r],
enumerable: !0
});
}, Ga = (e, t, r) => {
if (t && typeof t == "object" || typeof t == "function")
for (let n of we(t))
!Be.call(e, n) && n !== "default" && ce(e, n, {
get: () => t[n],
enumerable: !(r = be(t, n)) || r.enumerable
});
return e;
}, $e = (e) => Ga(
Ft(
ce(
e != null ? H(Ye(e)) : {},
"default",
e && e.__esModule && "default" in e ? {
get: () => e.default,
enumerable: !0
} : {
value: e,
enumerable: !0
}
)
),
e
), ze, R = z(() => {
ze = {
platform: "",
env: {},
versions: {
node: "14.17.6"
}
};
}), $i, Qe, mt = z(() => {
R(), $i = 0, Qe = {
readFileSync: (e) => self[e] || "",
statSync: () => ({
mtimeMs: $i++
}),
promises: {
readFile: (e) => Promise.resolve(self[e] || "")
}
};
}), Ii = I((e, t) => {
R();
var r = class {
constructor(n = {}) {
if (!(n.maxSize && n.maxSize > 0)) throw new TypeError("`maxSize` must be a number greater than 0");
if (typeof n.maxAge == "number" && n.maxAge === 0) throw new TypeError("`maxAge` must be a number greater than 0");
this.maxSize = n.maxSize, this.maxAge = n.maxAge || 1 / 0, this.onEviction = n.onEviction, this.cache = /* @__PURE__ */ new Map(), this.oldCache = /* @__PURE__ */ new Map(), this._size = 0;
}
_emitEvictions(n) {
if (typeof this.onEviction == "function") for (let [i, o] of n) this.onEviction(i, o.value);
}
_deleteIfExpired(n, i) {
return typeof i.expiry == "number" && i.expiry <= Date.now() ? (typeof this.onEviction == "function" && this.onEviction(n, i.value), this.delete(n)) : !1;
}
_getOrDeleteIfExpired(n, i) {
if (this._deleteIfExpired(n, i) === !1) return i.value;
}
_getItemValue(n, i) {
return i.expiry ? this._getOrDeleteIfExpired(n, i) : i.value;
}
_peek(n, i) {
let o = i.get(n);
return this._getItemValue(n, o);
}
_set(n, i) {
this.cache.set(n, i), this._size++, this._size >= this.maxSize && (this._size = 0, this._emitEvictions(this.oldCache), this.oldCache = this.cache, this.cache = /* @__PURE__ */ new Map());
}
_moveToRecent(n, i) {
this.oldCache.delete(n), this._set(n, i);
}
*_entriesAscending() {
for (let n of this.oldCache) {
let [i, o] = n;
this.cache.has(i) || this._deleteIfExpired(i, o) === !1 && (yield n);
}
for (let n of this.cache) {
let [i, o] = n;
this._deleteIfExpired(i, o) === !1 && (yield n);
}
}
get(n) {
if (this.cache.has(n)) {
let i = this.cache.get(n);
return this._getItemValue(n, i);
}
if (this.oldCache.has(n)) {
let i = this.oldCache.get(n);
if (this._deleteIfExpired(n, i) === !1) return this._moveToRecent(n, i), i.value;
}
}
set(n, i, { maxAge: o = this.maxAge === 1 / 0 ? void 0 : Date.now() + this.maxAge } = {}) {
this.cache.has(n) ? this.cache.set(n, {
value: i,
maxAge: o
}) : this._set(n, {
value: i,
expiry: o
});
}
has(n) {
return this.cache.has(n) ? !this._deleteIfExpired(n, this.cache.get(n)) : this.oldCache.has(n) ? !this._deleteIfExpired(n, this.oldCache.get(n)) : !1;
}
peek(n) {
if (this.cache.has(n)) return this._peek(n, this.cache);
if (this.oldCache.has(n)) return this._peek(n, this.oldCache);
}
delete(n) {
let i = this.cache.delete(n);
return i && this._size--, this.oldCache.delete(n) || i;
}
clear() {
this.cache.clear(), this.oldCache.clear(), this._size = 0;
}
resize(n) {
if (!(n && n > 0)) throw new TypeError("`maxSize` must be a number greater than 0");
let i = [...this._entriesAscending()], o = i.length - n;
o < 0 ? (this.cache = new Map(i), this.oldCache = /* @__PURE__ */ new Map(), this._size = i.length) : (o > 0 && this._emitEvictions(i.slice(0, o)), this.oldCache = new Map(i.slice(o)), this.cache = /* @__PURE__ */ new Map(), this._size = 0), this.maxSize = n;
}
*keys() {
for (let [n] of this) yield n;
}
*values() {
for (let [, n] of this) yield n;
}
*[Symbol.iterator]() {
for (let n of this.cache) {
let [i, o] = n;
this._deleteIfExpired(i, o) === !1 && (yield [i, o.value]);
}
for (let n of this.oldCache) {
let [i, o] = n;
this.cache.has(i) || this._deleteIfExpired(i, o) === !1 && (yield [i, o.value]);
}
}
*entriesDescending() {
let n = [...this.cache];
for (let i = n.length - 1; i >= 0; --i) {
let o = n[i], [a, l] = o;
this._deleteIfExpired(a, l) === !1 && (yield [a, l.value]);
}
n = [...this.oldCache];
for (let i = n.length - 1; i >= 0; --i) {
let o = n[i], [a, l] = o;
this.cache.has(a) || this._deleteIfExpired(a, l) === !1 && (yield [a, l.value]);
}
}
*entriesAscending() {
for (let [n, i] of this._entriesAscending()) yield [n, i.value];
}
get size() {
if (!this._size) return this.oldCache.size;
let n = 0;
for (let i of this.oldCache.keys()) this.cache.has(i) || n++;
return Math.min(this._size + n, this.maxSize);
}
};
t.exports = r;
}), Pi, qa = z(() => {
R(), Pi = (e) => e && e._hash;
});
function Li(e) {
return Pi(e, {
ignoreUnknown: !0
});
}
var Ya = z(() => {
R(), qa();
});
function or(e) {
if (e = `${e}`, e === "0") return "0";
if (/^[+-]?(\d+|\d*\.\d+)(e[+-]?\d+)?(%|\w+)?$/.test(e)) return e.replace(/^[+-]?/, (r) => r === "-" ? "" : "-");
let t = ["var", "calc", "min", "max", "clamp"];
for (let r of t) if (e.includes(`${r}(`)) return `calc(${e} * -1)`;
}
var Yr = z(() => {
R();
}), Di, Qa = z(() => {
R(), Di = [
"preflight",
"container",
"accessibility",
"pointerEvents",
"visibility",
"position",
"inset",
"isolation",
"zIndex",
"order",
"gridColumn",
"gridColumnStart",
"gridColumnEnd",
"gridRow",
"gridRowStart",
"gridRowEnd",
"float",
"clear",
"margin",
"boxSizing",
"lineClamp",
"display",
"aspectRatio",
"size",
"height",
"maxHeight",
"minHeight",
"width",
"minWidth",
"maxWidth",
"flex",
"flexShrink",
"flexGrow",
"flexBasis",
"tableLayout",
"captionSide",
"borderCollapse",
"borderSpacing",
"transformOrigin",
"translate",
"rotate",
"skew",
"scale",
"transform",
"animation",
"cursor",
"touchAction",
"userSelect",
"resize",
"scrollSnapType",
"scrollSnapAlign",
"scrollSnapStop",
"scrollMargin",
"scrollPadding",
"listStylePosition",
"listStyleType",
"listStyleImage",
"appearance",
"columns",
"breakBefore",
"breakInside",
"breakAfter",
"gridAutoColumns",
"gridAutoFlow",
"gridAutoRows",
"gridTemplateColumns",
"gridTemplateRows",
"flexDirection",
"flexWrap",
"placeContent",
"placeItems",
"alignContent",
"alignItems",
"justifyContent",
"justifyItems",
"gap",
"space",
"divideWidth",
"divideStyle",
"divideColor",
"divideOpacity",
"placeSelf",
"alignSelf",
"justifySelf",
"overflow",
"overscrollBehavior",
"scrollBehavior",
"textOverflow",
"hyphens",
"whitespace",
"textWrap",
"wordBreak",
"borderRadius",
"borderWidth",
"borderStyle",
"borderColor",
"borderOpacity",
"backgroundColor",
"backgroundOpacity",
"backgroundImage",
"gradientColorStops",
"boxDecorationBreak",
"backgroundSize",
"backgroundAttachment",
"backgroundClip",
"backgroundPosition",
"backgroundRepeat",
"backgroundOrigin",
"fill",
"stroke",
"strokeWidth",
"objectFit",
"objectPosition",
"padding",
"textAlign",
"textIndent",
"verticalAlign",
"fontFamily",
"fontSize",
"fontWeight",
"textTransform",
"fontStyle",
"fontVariantNumeric",
"lineHeight",
"letterSpacing",
"textColor",
"textOpacity",
"textDecoration",
"textDecorationColor",
"textDecorationStyle",
"textDecorationThickness",
"textUnderlineOffset",
"fontSmoothing",
"placeholderColor",
"placeholderOpacity",
"caretColor",
"accentColor",
"opacity",
"backgroundBlendMode",
"mixBlendMode",
"boxShadow",
"boxShadowColor",
"outlineStyle",
"outlineWidth",
"outlineOffset",
"outlineColor",
"ringWidth",
"ringColor",
"ringOpacity",
"ringOffsetWidth",
"ringOffsetColor",
"blur",
"brightness",
"contrast",
"dropShadow",
"grayscale",
"hueRotate",
"invert",
"saturate",
"sepia",
"filter",
"backdropBlur",
"backdropBrightness",
"backdropContrast",
"backdropGrayscale",
"backdropHueRotate",
"backdropInvert",
"backdropOpacity",
"backdropSaturate",
"backdropSepia",
"backdropFilter",
"transitionProperty",
"transitionDelay",
"transitionDuration",
"transitionTimingFunction",
"willChange",
"contain",
"content",
"forcedColorAdjust"
];
});
function Ka(e, t) {
return e === void 0 ? t : Array.isArray(e) ? e : [...new Set(t.filter((r) => e !== !1 && e[r] !== !1).concat(Object.keys(e).filter((r) => e[r] !== !1)))];
}
var Xa = z(() => {
R();
}), Bi = {};
He(Bi, {
default: () => ot
});
var ot, Qr = z(() => {
R(), ot = new Proxy(
{},
{
get: () => String
}
);
});
function Kr(e, t, r) {
typeof ze < "u" && ze.env.JEST_WORKER_ID || r && Xr.has(r) || (r && Xr.add(r), console.warn(""), t.forEach((n) => console.warn(e, "-", n)));
}
function ji(e) {
return ot.dim(e);
}
var Xr, Ce, et = z(() => {
R(), Qr(), Xr = /* @__PURE__ */ new Set(), Ce = {
info(e, t) {
Kr(ot.bold(ot.cyan("info")), ...Array.isArray(e) ? [e] : [t, e]);
},
warn(e, t) {
["content-problems"].includes(e) || Kr(ot.bold(ot.yellow("warn")), ...Array.isArray(e) ? [e] : [t, e]);
},
risk(e, t) {
Kr(ot.bold(ot.magenta("risk")), ...Array.isArray(e) ? [e] : [t, e]);
}
};
}), Jr = {};
He(Jr, {
default: () => Zr
});
function Nt({ version: e, from: t, to: r }) {
Ce.warn(`${t}-color-renamed`, [`As of Tailwind CSS ${e}, \`${t}\` has been renamed to \`${r}\`.`, "Update your configuration file to silence this warning."]);
}
var Zr, en = z(() => {
R(), et(), Zr = {
inherit: "inherit",
current: "currentColor",
transparent: "transparent",
black: "#000",
white: "#fff",
slate: {
50: "#f8fafc",
100: "#f1f5f9",
200: "#e2e8f0",
300: "#cbd5e1",
400: "#94a3b8",
500: "#64748b",
600: "#475569",
700: "#334155",
800: "#1e293b",
900: "#0f172a",
950: "#020617"
},
gray: {
50: "#f9fafb",
100: "#f3f4f6",
200: "#e5e7eb",
300: "#d1d5db",
400: "#9ca3af",
500: "#6b7280",
600: "#4b5563",
700: "#374151",
800: "#1f2937",
900: "#111827",
950: "#030712"
},
zinc: {
50: "#fafafa",
100: "#f4f4f5",
200: "#e4e4e7",
300: "#d4d4d8",
400: "#a1a1aa",
500: "#71717a",
600: "#52525b",
700: "#3f3f46",
800: "#27272a",
900: "#18181b",
950: "#09090b"
},
neutral: {
50: "#fafafa",
100: "#f5f5f5",
200: "#e5e5e5",
300: "#d4d4d4",
400: "#a3a3a3",
500: "#737373",
600: "#525252",
700: "#404040",
800: "#262626",
900: "#171717",
950: "#0a0a0a"
},
stone: {
50: "#fafaf9",
100: "#f5f5f4",
200: "#e7e5e4",
300: "#d6d3d1",
400: "#a8a29e",
500: "#78716c",
600: "#57534e",
700: "#44403c",
800: "#292524",
900: "#1c1917",
950: "#0c0a09"
},
red: {
50: "#fef2f2",
100: "#fee2e2",
200: "#fecaca",
300: "#fca5a5",
400: "#f87171",
500: "#ef4444",
600: "#dc2626",
700: "#b91c1c",
800: "#991b1b",
900: "#7f1d1d",
950: "#450a0a"
},
orange: {
50: "#fff7ed",
100: "#ffedd5",
200: "#fed7aa",
300: "#fdba74",
400: "#fb923c",
500: "#f97316",
600: "#ea580c",
700: "#c2410c",
800: "#9a3412",
900: "#7c2d12",
950: "#431407"
},
amber: {
50: "#fffbeb",
100: "#fef3c7",
200: "#fde68a",
300: "#fcd34d",
400: "#fbbf24",
500: "#f59e0b",
600: "#d97706",
700: "#b45309",
800: "#92400e",
900: "#78350f",
950: "#451a03"
},
yellow: {
50: "#fefce8",
100: "#fef9c3",
200: "#fef08a",
300: "#fde047",
400: "#facc15",
500: "#eab308",
600: "#ca8a04",
700: "#a16207",
800: "#854d0e",
900: "#713f12",
950: "#422006"
},
lime: {
50: "#f7fee7",
100: "#ecfccb",
200: "#d9f99d",
300: "#bef264",
400: "#a3e635",
500: "#84cc16",
600: "#65a30d",
700: "#4d7c0f",
800: "#3f6212",
900: "#365314",
950: "#1a2e05"
},
green: {
50: "#f0fdf4",
100: "#dcfce7",
200: "#bbf7d0",
300: "#86efac",
400: "#4ade80",
500: "#22c55e",
600: "#16a34a",
700: "#15803d",
800: "#166534",
900: "#14532d",
950: "#052e16"
},
emerald: {
50: "#ecfdf5",
100: "#d1fae5",
200: "#a7f3d0",
300: "#6ee7b7",
400: "#34d399",
500: "#10b981",
600: "#059669",
700: "#047857",
800: "#065f46",
900: "#064e3b",
950: "#022c22"
},
teal: {
50: "#f0fdfa",
100: "#ccfbf1",
200: "#99f6e4",
300: "#5eead4",
400: "#2dd4bf",
500: "#14b8a6",
600: "#0d9488",
700: "#0f766e",
800: "#115e59",
900: "#134e4a",
950: "#042f2e"
},
cyan: {
50: "#ecfeff",
100: "#cffafe",
200: "#a5f3fc",
300: "#67e8f9",
400: "#22d3ee",
500: "#06b6d4",
600: "#0891b2",
700: "#0e7490",
800: "#155e75",
900: "#164e63",
950: "#083344"
},
sky: {
50: "#f0f9ff",
100: "#e0f2fe",
200: "#bae6fd",
300: "#7dd3fc",
400: "#38bdf8",
500: "#0ea5e9",
600: "#0284c7",
700: "#0369a1",
800: "#075985",
900: "#0c4a6e",
950: "#082f49"
},
blue: {
50: "#eff6ff",
100: "#dbeafe",
200: "#bfdbfe",
300: "#93c5fd",
400: "#60a5fa",
500: "#3b82f6",
600: "#2563eb",
700: "#1d4ed8",
800: "#1e40af",
900: "#1e3a8a",
950: "#172554"
},
indigo: {
50: "#eef2ff",
100: "#e0e7ff",
200: "#c7d2fe",
300: "#a5b4fc",
400: "#818cf8",
500: "#6366f1",
600: "#4f46e5",
700: "#4338ca",
800: "#3730a3",
900: "#312e81",
950: "#1e1b4b"
},
violet: {
50: "#f5f3ff",
100: "#ede9fe",
200: "#ddd6fe",
300: "#c4b5fd",
400: "#a78bfa",
500: "#8b5cf6",
600: "#7c3aed",
700: "#6d28d9",
800: "#5b21b6",
900: "#4c1d95",
950: "#2e1065"
},
purple: {
50: "#faf5ff",
100: "#f3e8ff",
200: "#e9d5ff",
300: "#d8b4fe",
400: "#c084fc",
500: "#a855f7",
600: "#9333ea",
700: "#7e22ce",
800: "#6b21a8",
900: "#581c87",
950: "#3b0764"
},
fuchsia: {
50: "#fdf4ff",
100: "#fae8ff",
200: "#f5d0fe",
300: "#f0abfc",
400: "#e879f9",
500: "#d946ef",
600: "#c026d3",
700: "#a21caf",
800: "#86198f",
900: "#701a75",
950: "#4a044e"
},
pink: {
50: "#fdf2f8",
100: "#fce7f3",
200: "#fbcfe8",
300: "#f9a8d4",
400: "#f472b6",
500: "#ec4899",
600: "#db2777",
700: "#be185d",
800: "#9d174d",
900: "#831843",
950: "#500724"
},
rose: {
50: "#fff1f2",
100: "#ffe4e6",
200: "#fecdd3",
300: "#fda4af",
400: "#fb7185",
500: "#f43f5e",
600: "#e11d48",
700: "#be123c",
800: "#9f1239",
900: "#881337",
950: "#4c0519"
},
get lightBlue() {
return Nt({
version: "v2.2",
from: "lightBlue",
to: "sky"
}), this.sky;
},
get warmGray() {
return Nt({
version: "v3.0",
from: "warmGray",
to: "stone"
}), this.stone;
},
get trueGray() {
return Nt({
version: "v3.0",
from: "trueGray",
to: "neutral"
}), this.neutral;
},
get coolGray() {
return Nt({
version: "v3.0",
from: "coolGray",
to: "gray"
}), this.gray;
},
get blueGray() {
return Nt({
version: "v3.0",
from: "blueGray",
to: "slate"
}), this.slate;
}
};
});
function Ui(e, ...t) {
var r, n;
for (let i of t) {
for (let o in i) (r = e == null ? void 0 : e.hasOwnProperty) != null && r.call(e, o) || (e[o] = i[o]);
for (let o of Object.getOwnPropertySymbols(i)) (n = e == null ? void 0 : e.hasOwnProperty) != null && n.call(e, o) || (e[o] = i[o]);
}
return e;
}
var Ja = z(() => {
R();
});
function zt(e) {
if (Array.isArray(e)) return e;
let t = e.split("[").length - 1, r = e.split("]").length - 1;
if (t !== r) throw new Error(`Path is invalid. Has unbalanced brackets: ${e}`);
return e.split(/\.(?![^\[]*\])|[\[\]]/g).filter(Boolean);
}
var tn = z(() => {
R();
});
function tt(e, t) {
var r, n;
return Ht.future.includes(t) ? e.future === "all" || (((r = e == null ? void 0 : e.future) == null ? void 0 : r[t]) ?? rn[t] ?? !1) : Ht.experimental.includes(t) ? e.experimental === "all" || (((n = e == null ? void 0 : e.experimental) == null ? void 0 : n[t]) ?? rn[t] ?? !1) : !1;
}
function Mi(e) {
return e.experimental === "all" ? Ht.experimental : Object.keys((e == null ? void 0 : e.experimental) ?? {}).filter((t) => Ht.experimental.includes(t) && e.experimental[t]);
}
function Za(e) {
if (ze.env.JEST_WORKER_ID === void 0 && Mi(e).length > 0) {
let t = Mi(e).map((r) => ot.yellow(r)).join(", ");
Ce.warn("experimental-flags-enabled", [`You have enabled experimental features: ${t}`, "Experimental features in Tailwind CSS are not covered by semver, may introduce breaking changes, and can change at any time."]);
}
}
var rn, Ht, gt = z(() => {
R(), Qr(), et(), rn = {
optimizeUniversalDefaults: !1,
generalizedModifiers: !0,
disableColorOpacityUtilitiesByDefault: !1,
relativeContentPathsByDefault: !1
}, Ht = {
future: ["hoverOnlyWhenSupported", "respectDefaultRingColorOpacity", "disableColorOpacityUtilitiesByDefault", "relativeContentPathsByDefault"],
experimental: ["optimizeUniversalDefaults", "generalizedModifiers"]
};
});
function el(e) {
(() => {
if (e.purge || !e.content || !Array.isArray(e.content) && !(typeof e.content == "object" && e.content !== null)) return !1;
if (Array.isArray(e.content)) return e.content.every((t) => typeof t == "string" ? !0 : !(typeof (t == null ? void 0 : t.raw) != "string" || t != null && t.extension && typeof (t == null ? void 0 : t.extension) != "string"));
if (typeof e.content == "object" && e.content !== null) {
if (Object.keys(e.content).some((t) => !["files", "relative", "extract", "transform"].includes(t))) return !1;
if (Array.isArray(e.content.files)) {
if (!e.content.files.every((t) => typeof t == "string" ? !0 : !(typeof (t == null ? void 0 : t.raw) != "string" || t != null && t.extension && typeof (t == null ? void 0 : t.extension) != "string"))) return !1;
if (typeof e.content.extract == "object") {
for (let t of Object.values(e.content.extract)) if (typeof t != "function") return !1;
} else if (!(e.content.extract === void 0 || typeof e.content.extract == "function")) return !1;
if (typeof e.content.transform == "object") {
for (let t of Object.values(e.content.transform)) if (typeof t != "function") return !1;
} else if (!(e.content.transform === void 0 || typeof e.content.transform == "function")) return !1;
if (typeof e.content.relative != "boolean" && typeof e.content.relative < "u") return !1;
}
return !0;
}
return !1;
})() || Ce.warn("purge-deprecation", ["The `purge`/`content` options have changed in Tailwind CSS v3.0.", "Update your configuration file to eliminate this warning.", "https://tailwindcss.com/docs/upgrade-guide#configure-content-sources"]), e.safelist = (() => {
var i;
let { content: t, purge: r, safelist: n } = e;
return Array.isArray(n) ? n : Array.isArray(t == null ? void 0 : t.safelist) ? t.safelist : Array.isArray(r == null ? void 0 : r.safelist) ? r.safelist : Array.isArray((i = r == null ? void 0 : r.options) == null ? void 0 : i.safelist) ? r.options.safelist : [];
})(), e.blocklist = (() => {
let { blocklist: t } = e;
if (Array.isArray(t)) {
if (t.every((r) => typeof r == "string")) return t;
Ce.warn("blocklist-invalid", ["The `blocklist` option must be an array of strings.", "https://tailwindcss.com/docs/content-configuration#discarding-classes"]);
}
return [];
})(), typeof e.prefix == "function" ? (Ce.warn("prefix-function", ["As of Tailwind CSS v3.0, `prefix` cannot be a function.", "Update `prefix` in your configuration to be a string to eliminate this warning.", "https://tailwindcss.com/docs/upgrade-guide#prefix-cannot-be-a-function"]), e.prefix = "") : e.prefix = e.prefix ?? "", e.content = {
relative: (() => {
let { content: t } = e;
return t != null && t.relative ? t.relative : tt(e, "relativeContentPathsByDefault");
})(),
files: (() => {
let { content: t, purge: r } = e;
return Array.isArray(r) ? r : Array.isArray(r == null ? void 0 : r.content) ? r.content : Array.isArray(t) ? t : Array.isArray(t == null ? void 0 : t.content) ? t.content : Array.isArray(t == null ? void 0 : t.files) ? t.files : [];
})(),
extract: (() => {
let t = (() => {
var i, o, a, l, s, c, d, u, p, f;
return (i = e.purge) != null && i.extract ? e.purge.extract : (o = e.content) != null && o.extract ? e.content.extract : (l = (a = e.purge) == null ? void 0 : a.extract) != null && l.DEFAULT ? e.purge.extract.DEFAULT : (c = (s = e.content) == null ? void 0 : s.extract) != null && c.DEFAULT ? e.content.extract.DEFAULT : (u = (d = e.purge) == null ? void 0 : d.options) != null && u.extractors ? e.purge.options.extractors : (f = (p = e.content) == null ? void 0 : p.options) != null && f.extractors ? e.content.options.extractors : {};
})(), r = {}, n = (() => {
var i, o, a, l;
if ((o = (i = e.purge) == null ? void 0 : i.options) != null && o.defaultExtractor) return e.purge.options.defaultExtractor;
if ((l = (a = e.content) == null ? void 0 : a.options) != null && l.defaultExtractor) return e.content.options.defaultExtractor;
})();
if (n !== void 0 && (r.DEFAULT = n), typeof t == "function") r.DEFAULT = t;
else if (Array.isArray(t)) for (let { extensions: i, extractor: o } of t ?? []) for (let a of i) r[a] = o;
else typeof t == "object" && t !== null && Object.assign(r, t);
return r;
})(),
transform: (() => {
let t = (() => {
var n, i, o, a, l, s;
return (n = e.purge) != null && n.transform ? e.purge.transform : (i = e.content) != null && i.transform ? e.content.transform : (a = (o = e.purge) == null ? void 0 : o.transform) != null && a.DEFAULT ? e.purge.transform.DEFAULT : (s = (l = e.content) == null ? void 0 : l.transform) != null && s.DEFAULT ? e.content.transform.DEFAULT : {};
})(), r = {};
return typeof t == "function" ? r.DEFAULT = t : typeof t == "object" && t !== null && Object.assign(r, t), r;
})()
};
for (let t of e.content.files)
if (typeof t == "string" && /{([^,]*?)}/g.test(t)) {
Ce.warn("invalid-glob-braces", [`The glob pattern ${ji(t)} in your Tailwind CSS configuration is invalid.`, `Update it to ${ji(t.replace(/{([^,]*?)}/g, "$1"))} to silence this warning.`]);
break;
}
return e;
}
var tl = z(() => {
R(), gt(), et();
});
function rt(e) {
if (Object.prototype.toString.call(e) !== "[object Object]") return !1;
let t = Object.getPrototypeOf(e);
return t === null || Object.getPrototypeOf(t) === null;
}
var Wt = z(() => {
R();
});
function Vt(e) {
return Array.isArray(e) ? e.map((t) => Vt(t)) : typeof e == "object" && e !== null ? Object.fromEntries(Object.entries(e).map(([t, r]) => [t, Vt(r)])) : e;
}
var nn = z(() => {
R();
});
function on(e) {
return e.replace(/\\,/g, "\\2c ");
}
var sn = z(() => {
R();
}), an, rl = z(() => {
R(), an = {
aliceblue: [240, 248, 255],
antiquewhite: [250, 235, 215],
aqua: [0, 255, 255],
aquamarine: [127, 255, 212],
azure: [240, 255, 255],
beige: [245, 245, 220],
bisque: [255, 228, 196],
black: [0, 0, 0],
blanchedalmond: [255, 235, 205],
blue: [0, 0, 255],
blueviolet: [138, 43, 226],
brown: [165, 42, 42],
burlywood: [222, 184, 135],
cadetblue: [95, 158, 160],
chartreuse: [127, 255, 0],
chocolate: [210, 105, 30],
coral: [255, 127, 80],
cornflowerblue: [100, 149, 237],
cornsilk: [255, 248, 220],
crimson: [220, 20, 60],
cyan: [0, 255, 255],
darkblue: [0, 0, 139],
darkcyan: [0, 139, 139],
darkgoldenrod: [184, 134, 11],
darkgray: [169, 169, 169],
darkgreen: [0, 100, 0],
darkgrey: [169, 169, 169],
darkkhaki: [189, 183, 107],
darkmagenta: [139, 0, 139],
darkolivegreen: [85, 107, 47],
darkorange: [255, 140, 0],
darkorchid: [153, 50, 204],
darkred: [139, 0, 0],
darksalmon: [233, 150, 122],
darkseagreen: [143, 188, 143],
darkslateblue: [72, 61, 139],
darkslategray: [47, 79, 79],
darkslategrey: [47, 79, 79],
darkturquoise: [0, 206, 209],
darkviolet: [148, 0, 211],
deeppink: [255, 20, 147],
deepskyblue: [0, 191, 255],
dimgray: [105, 105, 105],
dimgrey: [105, 105, 105],
dodgerblue: [30, 144, 255],
firebrick: [178, 34, 34],
floralwhite: [255, 250, 240],
forestgreen: [34, 139, 34],
fuchsia: [255, 0, 255],
gainsboro: [220, 220, 220],
ghostwhite: [248, 248, 255],
gold: [255, 215, 0],
goldenrod: [218, 165, 32],
gray: [128, 128, 128],
green: [0, 128, 0],
greenyellow: [173, 255, 47],
grey: [128, 128, 128],
honeydew: [240, 255, 240],
hotpink: [255, 105, 180],
indianred: [205, 92, 92],
indigo: [75, 0, 130],
ivory: [255, 255, 240],
khaki: [240, 230, 140],
lavender: [230, 230, 250],
lavenderblush: [255, 240, 245],
lawngreen: [124, 252, 0],
lemonchiffon: [255, 250, 205],
lightblue: [173, 216, 230],
lightcoral: [240, 128, 128],
lightcyan: [224, 255, 255],
lightgoldenrodyellow: [250, 250, 210],
lightgray: [211, 211, 211],
lightgreen: [144, 238, 144],
lightgrey: [211, 211, 211],
lightpink: [255, 182, 193],
lightsalmon: [255, 160, 122],
lightseagreen: [32, 178, 170],
lightskyblue: [135, 206, 250],
lightslategray: [119, 136, 153],
lightslategrey: [119, 136, 153],
lightsteelblue: [176, 196, 222],
lightyellow: [255, 255, 224],
lime: [0, 255, 0],
limegreen: [50, 205, 50],
linen: [250, 240, 230],
magenta: [255, 0, 255],
maroon: [128, 0, 0],
mediumaquamarine: [102, 205, 170],
mediumblue: [0, 0, 205],
mediumorchid: [186, 85, 211],
mediumpurple: [147, 112, 219],
mediumseagreen: [60, 179, 113],
mediumslateblue: [123, 104, 238],
mediumspringgreen: [0, 250, 154],
mediumturquoise: [72, 209, 204],
mediumvioletred: [199, 21, 133],
midnightblue: [25, 25, 112],
mintcream: [245, 255, 250],
mistyrose: [255, 228, 225],
moccasin: [255, 228, 181],
navajowhite: [255, 222, 173],
navy: [0, 0, 128],
oldlace: [253, 245, 230],
olive: [128, 128, 0],
olivedrab: [107, 142, 35],
orange: [255, 165, 0],
orangered: [255, 69, 0],
orchid: [218, 112, 214],
palegoldenrod: [238, 232, 170],
palegreen: [152, 251, 152],
paleturquoise: [175, 238, 238],
palevioletred: [219, 112, 147],
papayawhip: [255, 239, 213],
peachpuff: [255, 218, 185],
peru: [205, 133, 63],
pink: [255, 192, 203],
plum: [221, 160, 221],
powderblue: [176, 224, 230],
purple: [128, 0, 128],
rebeccapurple: [102, 51, 153],
red: [255, 0, 0],
rosybrown: [188, 143, 143],
royalblue: [65, 105, 225],
saddlebrown: [139, 69, 19],
salmon: [250, 128, 114],
sandybrown: [244, 164, 96],
seagreen: [46, 139, 87],
seashell: [255, 245, 238],
sienna: [160, 82, 45],
silver: [192, 192, 192],
skyblue: [135, 206, 235],
slateblue: [106, 90, 205],
slategray: [112, 128, 144],
slategrey: [112, 128, 144],
snow: [255, 250, 250],
springgreen: [0, 255, 127],
steelblue: [70, 130, 180],
tan: [210, 180, 140],
teal: [0, 128, 128],
thistle: [216, 191, 216],
tomato: [255, 99, 71],
turquoise: [64, 224, 208],
violet: [238, 130, 238],
wheat: [245, 222, 179],
white: [255, 255, 255],
whitesmoke: [245, 245, 245],
yellow: [255, 255, 0],
yellowgreen: [154, 205, 50]
};
});
function ln(e, { loose: t = !1 } = {}) {
var o, a;
if (typeof e != "string") return null;
if (e = e.trim(), e === "transparent")
return {
mode: "rgb",
color: ["0", "0", "0"],
alpha: "0"
};
if (e in an)
return {
mode: "rgb",
color: an[e].map((l) => l.toString())
};
let r = e.replace(zi, (l, s, c, d, u) => ["#", s, s, c, c, d, d, u ? u + u : ""].join("")).match(Ni);
if (r !== null)
return {
mode: "rgb",
color: [parseInt(r[1], 16), parseInt(r[2], 16), parseInt(r[3], 16)].map((l) => l.toString()),
alpha: r[4] ? (parseInt(r[4], 16) / 255).toString() : void 0
};
let n = e.match(Hi) ?? e.match(Wi);
if (n === null) return null;
let i = [n[2], n[3], n[4]].filter(Boolean).map((l) => l.toString());
return i.length === 2 && i[0].startsWith("var(") ? {
mode: n[1],
color: [i[0]],
alpha: i[1]
} : !t && i.length !== 3 || i.length < 3 && !i.some((l) => /^var\(.*?\)$/.test(l)) ? null : {
mode: n[1],
color: i,
alpha: (a = (o = n[5]) == null ? void 0 : o.toString) == null ? void 0 : a.call(o)
};
}
function Fi({ mode: e, color: t, alpha: r }) {
let n = r !== void 0;
return e === "rgba" || e === "hsla" ? `${e}(${t.join(", ")}${n ? `, ${r}` : ""})` : `${e}(${t.join(" ")}${n ? ` / ${r}` : ""})`;
}
var Ni, zi, ct, Gt, cn, ut, Hi, Wi, Vi = z(() => {
R(), rl(), Ni = /^#([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})?$/i, zi = /^#([a-f\d])([a-f\d])(