@tiiqu/ui
Version:
A customizable, accessible, and developer-friendly React UI component library powered by Tailwind CSS, TypeScript, and Vite
1,863 lines (1,862 loc) • 93 kB
JavaScript
'use client';
import { jsxs as M, jsx as f, Fragment as Fe } from "react/jsx-runtime";
import { useCallback as E, useRef as me, useState as re, useEffect as We, useId as Ie, useImperativeHandle as De, isValidElement as U, cloneElement as ae } from "react";
import './index.css';function Ke(e) {
return /* @__PURE__ */ M(
"svg",
{
xmlns: "http://www.w3.org/2000/svg",
width: "1em",
height: "1em",
viewBox: "0 0 24 24",
"aria-hidden": "true",
...e,
children: [
/* @__PURE__ */ f("rect", { width: 6, height: 14, x: 1, y: 4, fill: "currentColor", children: /* @__PURE__ */ f(
"animate",
{
id: "svgSpinnersBarsFade0",
fill: "freeze",
attributeName: "opacity",
begin: "0;svgSpinnersBarsFade1.end-0.25s",
dur: "0.75s",
values: "1;0.2"
}
) }),
/* @__PURE__ */ f("rect", { width: 6, height: 14, x: 9, y: 4, fill: "currentColor", opacity: 0.4, children: /* @__PURE__ */ f(
"animate",
{
fill: "freeze",
attributeName: "opacity",
begin: "svgSpinnersBarsFade0.begin+0.15s",
dur: "0.75s",
values: "1;0.2"
}
) }),
/* @__PURE__ */ f(
"rect",
{
width: 6,
height: 14,
x: 17,
y: 4,
fill: "currentColor",
opacity: 0.3,
children: /* @__PURE__ */ f(
"animate",
{
id: "svgSpinnersBarsFade1",
fill: "freeze",
attributeName: "opacity",
begin: "svgSpinnersBarsFade0.begin+0.3s",
dur: "0.75s",
values: "1;0.2"
}
)
}
)
]
}
);
}
function Se(e) {
var o, t, r = "";
if (typeof e == "string" || typeof e == "number") r += e;
else if (typeof e == "object") if (Array.isArray(e)) {
var n = e.length;
for (o = 0; o < n; o++) e[o] && (t = Se(e[o])) && (r && (r += " "), r += t);
} else for (t in e) e[t] && (r && (r += " "), r += t);
return r;
}
function Re() {
for (var e, o, t = 0, r = "", n = arguments.length; t < n; t++) (e = arguments[t]) && (o = Se(e)) && (r && (r += " "), r += o);
return r;
}
const ve = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, Ce = Re, Oe = (e, o) => (t) => {
var r;
if (o?.variants == null) return Ce(e, t?.class, t?.className);
const { variants: n, defaultVariants: a } = o, s = Object.keys(n).map((p) => {
const c = t?.[p], h = a?.[p];
if (c === null) return null;
const y = ve(c) || ve(h);
return n[p][y];
}), m = t && Object.entries(t).reduce((p, c) => {
let [h, y] = c;
return y === void 0 || (p[h] = y), p;
}, {}), d = o == null || (r = o.compoundVariants) === null || r === void 0 ? void 0 : r.reduce((p, c) => {
let { class: h, className: y, ...x } = c;
return Object.entries(x).every((k) => {
let [w, z] = k;
return Array.isArray(z) ? z.includes({
...a,
...m
}[w]) : {
...a,
...m
}[w] === z;
}) ? [
...p,
h,
y
] : p;
}, []);
return Ce(e, s, d, t?.class, t?.className);
}, He = Oe(
"inline-flex items-center justify-center gap-1 py-2 cursor-pointer transition-all duration-300 ease-in-out px-4 text-base",
{
variants: {
intent: {
primary: "bg-primary text-white",
secondary: "bg-secondary text-white",
primary_outline: "bg-white text-primary border border-primary",
secondary_outline: "bg-white text-secondary border border-secondary",
primary_borderless: "text-primary",
secondary_borderless: "text-secondary",
gray_outline: "bg-white text-black border border-gray"
},
size: {
small: "text-sm",
medium: "text-base"
},
radius: {
none: "rounded-none",
sm: "rounded-sm",
md: "rounded-md",
lg: "rounded-lg",
xl: "rounded-xl",
full: "rounded-full"
},
fullWidth: {
true: "w-full",
false: "w-fit"
},
disabled: {
false: null,
true: "opacity-45 cursor-not-allowed"
},
loading: {
true: "cursor-not-allowed relative",
false: ""
},
iconPosition: {
left: "flex-row",
right: "flex-row-reverse"
}
},
compoundVariants: [
{
intent: "primary",
disabled: !1,
className: "hover:brightness-90"
},
{
intent: "secondary",
disabled: !1,
className: "hover:brightness-75"
},
{
intent: "primary_outline",
disabled: !1,
className: "hover:bg-primary/10"
},
{
intent: "secondary_outline",
disabled: !1,
className: "hover:bg-secondary/10"
},
{
intent: "primary_borderless",
disabled: !1,
className: "hover:bg-primary/10 disabled:bg-[#68e9da]"
},
{
intent: "secondary_borderless",
disabled: !1,
className: "hover:bg-secondary/10"
}
],
defaultVariants: {
disabled: !1,
intent: "primary",
size: "medium",
radius: "lg",
fullWidth: !0,
loading: !1,
iconPosition: "left"
}
}
), pe = "-", Ue = (e) => {
const o = Xe(e), {
conflictingClassGroups: t,
conflictingClassGroupModifiers: r
} = e;
return {
getClassGroupId: (s) => {
const m = s.split(pe);
return m[0] === "" && m.length !== 1 && m.shift(), Pe(m, o) || qe(s);
},
getConflictingClassGroupIds: (s, m) => {
const d = t[s] || [];
return m && r[s] ? [...d, ...r[s]] : d;
}
};
}, Pe = (e, o) => {
if (e.length === 0)
return o.classGroupId;
const t = e[0], r = o.nextPart.get(t), n = r ? Pe(e.slice(1), r) : void 0;
if (n)
return n;
if (o.validators.length === 0)
return;
const a = e.join(pe);
return o.validators.find(({
validator: s
}) => s(a))?.classGroupId;
}, Ne = /^\[(.+)\]$/, qe = (e) => {
if (Ne.test(e)) {
const o = Ne.exec(e)[1], t = o?.substring(0, o.indexOf(":"));
if (t)
return "arbitrary.." + t;
}
}, Xe = (e) => {
const {
theme: o,
classGroups: t
} = e, r = {
nextPart: /* @__PURE__ */ new Map(),
validators: []
};
for (const n in t)
ce(t[n], r, n, o);
return r;
}, ce = (e, o, t, r) => {
e.forEach((n) => {
if (typeof n == "string") {
const a = n === "" ? o : ze(o, n);
a.classGroupId = t;
return;
}
if (typeof n == "function") {
if (Je(n)) {
ce(n(r), o, t, r);
return;
}
o.validators.push({
validator: n,
classGroupId: t
});
return;
}
Object.entries(n).forEach(([a, s]) => {
ce(s, ze(o, a), t, r);
});
});
}, ze = (e, o) => {
let t = e;
return o.split(pe).forEach((r) => {
t.nextPart.has(r) || t.nextPart.set(r, {
nextPart: /* @__PURE__ */ new Map(),
validators: []
}), t = t.nextPart.get(r);
}), t;
}, Je = (e) => e.isThemeGetter, Ye = (e) => {
if (e < 1)
return {
get: () => {
},
set: () => {
}
};
let o = 0, t = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map();
const n = (a, s) => {
t.set(a, s), o++, o > e && (o = 0, r = t, t = /* @__PURE__ */ new Map());
};
return {
get(a) {
let s = t.get(a);
if (s !== void 0)
return s;
if ((s = r.get(a)) !== void 0)
return n(a, s), s;
},
set(a, s) {
t.has(a) ? t.set(a, s) : n(a, s);
}
};
}, de = "!", ue = ":", Qe = ue.length, Ze = (e) => {
const {
prefix: o,
experimentalParseClassName: t
} = e;
let r = (n) => {
const a = [];
let s = 0, m = 0, d = 0, p;
for (let k = 0; k < n.length; k++) {
let w = n[k];
if (s === 0 && m === 0) {
if (w === ue) {
a.push(n.slice(d, k)), d = k + Qe;
continue;
}
if (w === "/") {
p = k;
continue;
}
}
w === "[" ? s++ : w === "]" ? s-- : w === "(" ? m++ : w === ")" && m--;
}
const c = a.length === 0 ? n : n.substring(d), h = et(c), y = h !== c, x = p && p > d ? p - d : void 0;
return {
modifiers: a,
hasImportantModifier: y,
baseClassName: h,
maybePostfixModifierPosition: x
};
};
if (o) {
const n = o + ue, a = r;
r = (s) => s.startsWith(n) ? a(s.substring(n.length)) : {
isExternal: !0,
modifiers: [],
hasImportantModifier: !1,
baseClassName: s,
maybePostfixModifierPosition: void 0
};
}
if (t) {
const n = r;
r = (a) => t({
className: a,
parseClassName: n
});
}
return r;
}, et = (e) => e.endsWith(de) ? e.substring(0, e.length - 1) : e.startsWith(de) ? e.substring(1) : e, tt = (e) => {
const o = Object.fromEntries(e.orderSensitiveModifiers.map((r) => [r, !0]));
return (r) => {
if (r.length <= 1)
return r;
const n = [];
let a = [];
return r.forEach((s) => {
s[0] === "[" || o[s] ? (n.push(...a.sort(), s), a = []) : a.push(s);
}), n.push(...a.sort()), n;
};
}, rt = (e) => ({
cache: Ye(e.cacheSize),
parseClassName: Ze(e),
sortModifiers: tt(e),
...Ue(e)
}), ot = /\s+/, nt = (e, o) => {
const {
parseClassName: t,
getClassGroupId: r,
getConflictingClassGroupIds: n,
sortModifiers: a
} = o, s = [], m = e.trim().split(ot);
let d = "";
for (let p = m.length - 1; p >= 0; p -= 1) {
const c = m[p], {
isExternal: h,
modifiers: y,
hasImportantModifier: x,
baseClassName: k,
maybePostfixModifierPosition: w
} = t(c);
if (h) {
d = c + (d.length > 0 ? " " + d : d);
continue;
}
let z = !!w, S = r(z ? k.substring(0, w) : k);
if (!S) {
if (!z) {
d = c + (d.length > 0 ? " " + d : d);
continue;
}
if (S = r(k), !S) {
d = c + (d.length > 0 ? " " + d : d);
continue;
}
z = !1;
}
const q = a(y).join(":"), K = x ? q + de : q, V = K + S;
if (s.includes(V))
continue;
s.push(V);
const $ = n(S, z);
for (let j = 0; j < $.length; ++j) {
const O = $[j];
s.push(K + O);
}
d = c + (d.length > 0 ? " " + d : d);
}
return d;
};
function st() {
let e = 0, o, t, r = "";
for (; e < arguments.length; )
(o = arguments[e++]) && (t = Te(o)) && (r && (r += " "), r += t);
return r;
}
const Te = (e) => {
if (typeof e == "string")
return e;
let o, t = "";
for (let r = 0; r < e.length; r++)
e[r] && (o = Te(e[r])) && (t && (t += " "), t += o);
return t;
};
function at(e, ...o) {
let t, r, n, a = s;
function s(d) {
const p = o.reduce((c, h) => h(c), e());
return t = rt(p), r = t.cache.get, n = t.cache.set, a = m, m(d);
}
function m(d) {
const p = r(d);
if (p)
return p;
const c = nt(d, t);
return n(d, c), c;
}
return function() {
return a(st.apply(null, arguments));
};
}
const v = (e) => {
const o = (t) => t[e] || [];
return o.isThemeGetter = !0, o;
}, Le = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, Ee = /^\((?:(\w[\w-]*):)?(.+)\)$/i, it = /^\d+\/\d+$/, lt = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, ct = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, dt = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, ut = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, mt = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, F = (e) => it.test(e), b = (e) => !!e && !Number.isNaN(Number(e)), L = (e) => !!e && Number.isInteger(Number(e)), ie = (e) => e.endsWith("%") && b(e.slice(0, -1)), T = (e) => lt.test(e), pt = () => !0, ft = (e) => (
// `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
// For example, `hsl(0 0% 0%)` would be classified as a length without this check.
// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
ct.test(e) && !dt.test(e)
), je = () => !1, gt = (e) => ut.test(e), bt = (e) => mt.test(e), ht = (e) => !i(e) && !l(e), yt = (e) => W(e, Ve, je), i = (e) => Le.test(e), B = (e) => W(e, $e, ft), le = (e) => W(e, Ct, b), Ae = (e) => W(e, Ge, je), wt = (e) => W(e, Be, bt), ee = (e) => W(e, _e, gt), l = (e) => Ee.test(e), H = (e) => D(e, $e), xt = (e) => D(e, Nt), Me = (e) => D(e, Ge), kt = (e) => D(e, Ve), vt = (e) => D(e, Be), te = (e) => D(e, _e, !0), W = (e, o, t) => {
const r = Le.exec(e);
return r ? r[1] ? o(r[1]) : t(r[2]) : !1;
}, D = (e, o, t = !1) => {
const r = Ee.exec(e);
return r ? r[1] ? o(r[1]) : t : !1;
}, Ge = (e) => e === "position" || e === "percentage", Be = (e) => e === "image" || e === "url", Ve = (e) => e === "length" || e === "size" || e === "bg-size", $e = (e) => e === "length", Ct = (e) => e === "number", Nt = (e) => e === "family-name", _e = (e) => e === "shadow", zt = () => {
const e = v("color"), o = v("font"), t = v("text"), r = v("font-weight"), n = v("tracking"), a = v("leading"), s = v("breakpoint"), m = v("container"), d = v("spacing"), p = v("radius"), c = v("shadow"), h = v("inset-shadow"), y = v("text-shadow"), x = v("drop-shadow"), k = v("blur"), w = v("perspective"), z = v("aspect"), S = v("ease"), q = v("animate"), K = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], V = () => [
"center",
"top",
"bottom",
"left",
"right",
"top-left",
// Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
"left-top",
"top-right",
// Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
"right-top",
"bottom-right",
// Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
"right-bottom",
"bottom-left",
// Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
"left-bottom"
], $ = () => [...V(), l, i], j = () => ["auto", "hidden", "clip", "visible", "scroll"], O = () => ["auto", "contain", "none"], g = () => [l, i, d], R = () => [F, "full", "auto", ...g()], fe = () => [L, "none", "subgrid", l, i], ge = () => ["auto", {
span: ["full", L, l, i]
}, L, l, i], X = () => [L, "auto", l, i], be = () => ["auto", "min", "max", "fr", l, i], oe = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], _ = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], P = () => ["auto", ...g()], G = () => [F, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...g()], u = () => [e, l, i], he = () => [...V(), Me, Ae, {
position: [l, i]
}], ye = () => ["no-repeat", {
repeat: ["", "x", "y", "space", "round"]
}], we = () => ["auto", "cover", "contain", kt, yt, {
size: [l, i]
}], ne = () => [ie, H, B], A = () => [
// Deprecated since Tailwind CSS v4.0.0
"",
"none",
"full",
p,
l,
i
], I = () => ["", b, H, B], J = () => ["solid", "dashed", "dotted", "double"], xe = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], C = () => [b, ie, Me, Ae], ke = () => [
// Deprecated since Tailwind CSS v4.0.0
"",
"none",
k,
l,
i
], Y = () => ["none", b, l, i], Q = () => ["none", b, l, i], se = () => [b, l, i], Z = () => [F, "full", ...g()];
return {
cacheSize: 500,
theme: {
animate: ["spin", "ping", "pulse", "bounce"],
aspect: ["video"],
blur: [T],
breakpoint: [T],
color: [pt],
container: [T],
"drop-shadow": [T],
ease: ["in", "out", "in-out"],
font: [ht],
"font-weight": ["thin", "extralight", "light", "normal", "medium", "semibold", "bold", "extrabold", "black"],
"inset-shadow": [T],
leading: ["none", "tight", "snug", "normal", "relaxed", "loose"],
perspective: ["dramatic", "near", "normal", "midrange", "distant", "none"],
radius: [T],
shadow: [T],
spacing: ["px", b],
text: [T],
"text-shadow": [T],
tracking: ["tighter", "tight", "normal", "wide", "wider", "widest"]
},
classGroups: {
// --------------
// --- Layout ---
// --------------
/**
* Aspect Ratio
* @see https://tailwindcss.com/docs/aspect-ratio
*/
aspect: [{
aspect: ["auto", "square", F, i, l, z]
}],
/**
* Container
* @see https://tailwindcss.com/docs/container
* @deprecated since Tailwind CSS v4.0.0
*/
container: ["container"],
/**
* Columns
* @see https://tailwindcss.com/docs/columns
*/
columns: [{
columns: [b, i, l, m]
}],
/**
* Break After
* @see https://tailwindcss.com/docs/break-after
*/
"break-after": [{
"break-after": K()
}],
/**
* Break Before
* @see https://tailwindcss.com/docs/break-before
*/
"break-before": [{
"break-before": K()
}],
/**
* Break Inside
* @see https://tailwindcss.com/docs/break-inside
*/
"break-inside": [{
"break-inside": ["auto", "avoid", "avoid-page", "avoid-column"]
}],
/**
* Box Decoration Break
* @see https://tailwindcss.com/docs/box-decoration-break
*/
"box-decoration": [{
"box-decoration": ["slice", "clone"]
}],
/**
* Box Sizing
* @see https://tailwindcss.com/docs/box-sizing
*/
box: [{
box: ["border", "content"]
}],
/**
* Display
* @see https://tailwindcss.com/docs/display
*/
display: ["block", "inline-block", "inline", "flex", "inline-flex", "table", "inline-table", "table-caption", "table-cell", "table-column", "table-column-group", "table-footer-group", "table-header-group", "table-row-group", "table-row", "flow-root", "grid", "inline-grid", "contents", "list-item", "hidden"],
/**
* Screen Reader Only
* @see https://tailwindcss.com/docs/display#screen-reader-only
*/
sr: ["sr-only", "not-sr-only"],
/**
* Floats
* @see https://tailwindcss.com/docs/float
*/
float: [{
float: ["right", "left", "none", "start", "end"]
}],
/**
* Clear
* @see https://tailwindcss.com/docs/clear
*/
clear: [{
clear: ["left", "right", "both", "none", "start", "end"]
}],
/**
* Isolation
* @see https://tailwindcss.com/docs/isolation
*/
isolation: ["isolate", "isolation-auto"],
/**
* Object Fit
* @see https://tailwindcss.com/docs/object-fit
*/
"object-fit": [{
object: ["contain", "cover", "fill", "none", "scale-down"]
}],
/**
* Object Position
* @see https://tailwindcss.com/docs/object-position
*/
"object-position": [{
object: $()
}],
/**
* Overflow
* @see https://tailwindcss.com/docs/overflow
*/
overflow: [{
overflow: j()
}],
/**
* Overflow X
* @see https://tailwindcss.com/docs/overflow
*/
"overflow-x": [{
"overflow-x": j()
}],
/**
* Overflow Y
* @see https://tailwindcss.com/docs/overflow
*/
"overflow-y": [{
"overflow-y": j()
}],
/**
* Overscroll Behavior
* @see https://tailwindcss.com/docs/overscroll-behavior
*/
overscroll: [{
overscroll: O()
}],
/**
* Overscroll Behavior X
* @see https://tailwindcss.com/docs/overscroll-behavior
*/
"overscroll-x": [{
"overscroll-x": O()
}],
/**
* Overscroll Behavior Y
* @see https://tailwindcss.com/docs/overscroll-behavior
*/
"overscroll-y": [{
"overscroll-y": O()
}],
/**
* Position
* @see https://tailwindcss.com/docs/position
*/
position: ["static", "fixed", "absolute", "relative", "sticky"],
/**
* Top / Right / Bottom / Left
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
inset: [{
inset: R()
}],
/**
* Right / Left
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
"inset-x": [{
"inset-x": R()
}],
/**
* Top / Bottom
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
"inset-y": [{
"inset-y": R()
}],
/**
* Start
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
start: [{
start: R()
}],
/**
* End
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
end: [{
end: R()
}],
/**
* Top
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
top: [{
top: R()
}],
/**
* Right
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
right: [{
right: R()
}],
/**
* Bottom
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
bottom: [{
bottom: R()
}],
/**
* Left
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
left: [{
left: R()
}],
/**
* Visibility
* @see https://tailwindcss.com/docs/visibility
*/
visibility: ["visible", "invisible", "collapse"],
/**
* Z-Index
* @see https://tailwindcss.com/docs/z-index
*/
z: [{
z: [L, "auto", l, i]
}],
// ------------------------
// --- Flexbox and Grid ---
// ------------------------
/**
* Flex Basis
* @see https://tailwindcss.com/docs/flex-basis
*/
basis: [{
basis: [F, "full", "auto", m, ...g()]
}],
/**
* Flex Direction
* @see https://tailwindcss.com/docs/flex-direction
*/
"flex-direction": [{
flex: ["row", "row-reverse", "col", "col-reverse"]
}],
/**
* Flex Wrap
* @see https://tailwindcss.com/docs/flex-wrap
*/
"flex-wrap": [{
flex: ["nowrap", "wrap", "wrap-reverse"]
}],
/**
* Flex
* @see https://tailwindcss.com/docs/flex
*/
flex: [{
flex: [b, F, "auto", "initial", "none", i]
}],
/**
* Flex Grow
* @see https://tailwindcss.com/docs/flex-grow
*/
grow: [{
grow: ["", b, l, i]
}],
/**
* Flex Shrink
* @see https://tailwindcss.com/docs/flex-shrink
*/
shrink: [{
shrink: ["", b, l, i]
}],
/**
* Order
* @see https://tailwindcss.com/docs/order
*/
order: [{
order: [L, "first", "last", "none", l, i]
}],
/**
* Grid Template Columns
* @see https://tailwindcss.com/docs/grid-template-columns
*/
"grid-cols": [{
"grid-cols": fe()
}],
/**
* Grid Column Start / End
* @see https://tailwindcss.com/docs/grid-column
*/
"col-start-end": [{
col: ge()
}],
/**
* Grid Column Start
* @see https://tailwindcss.com/docs/grid-column
*/
"col-start": [{
"col-start": X()
}],
/**
* Grid Column End
* @see https://tailwindcss.com/docs/grid-column
*/
"col-end": [{
"col-end": X()
}],
/**
* Grid Template Rows
* @see https://tailwindcss.com/docs/grid-template-rows
*/
"grid-rows": [{
"grid-rows": fe()
}],
/**
* Grid Row Start / End
* @see https://tailwindcss.com/docs/grid-row
*/
"row-start-end": [{
row: ge()
}],
/**
* Grid Row Start
* @see https://tailwindcss.com/docs/grid-row
*/
"row-start": [{
"row-start": X()
}],
/**
* Grid Row End
* @see https://tailwindcss.com/docs/grid-row
*/
"row-end": [{
"row-end": X()
}],
/**
* Grid Auto Flow
* @see https://tailwindcss.com/docs/grid-auto-flow
*/
"grid-flow": [{
"grid-flow": ["row", "col", "dense", "row-dense", "col-dense"]
}],
/**
* Grid Auto Columns
* @see https://tailwindcss.com/docs/grid-auto-columns
*/
"auto-cols": [{
"auto-cols": be()
}],
/**
* Grid Auto Rows
* @see https://tailwindcss.com/docs/grid-auto-rows
*/
"auto-rows": [{
"auto-rows": be()
}],
/**
* Gap
* @see https://tailwindcss.com/docs/gap
*/
gap: [{
gap: g()
}],
/**
* Gap X
* @see https://tailwindcss.com/docs/gap
*/
"gap-x": [{
"gap-x": g()
}],
/**
* Gap Y
* @see https://tailwindcss.com/docs/gap
*/
"gap-y": [{
"gap-y": g()
}],
/**
* Justify Content
* @see https://tailwindcss.com/docs/justify-content
*/
"justify-content": [{
justify: [...oe(), "normal"]
}],
/**
* Justify Items
* @see https://tailwindcss.com/docs/justify-items
*/
"justify-items": [{
"justify-items": [..._(), "normal"]
}],
/**
* Justify Self
* @see https://tailwindcss.com/docs/justify-self
*/
"justify-self": [{
"justify-self": ["auto", ..._()]
}],
/**
* Align Content
* @see https://tailwindcss.com/docs/align-content
*/
"align-content": [{
content: ["normal", ...oe()]
}],
/**
* Align Items
* @see https://tailwindcss.com/docs/align-items
*/
"align-items": [{
items: [..._(), {
baseline: ["", "last"]
}]
}],
/**
* Align Self
* @see https://tailwindcss.com/docs/align-self
*/
"align-self": [{
self: ["auto", ..._(), {
baseline: ["", "last"]
}]
}],
/**
* Place Content
* @see https://tailwindcss.com/docs/place-content
*/
"place-content": [{
"place-content": oe()
}],
/**
* Place Items
* @see https://tailwindcss.com/docs/place-items
*/
"place-items": [{
"place-items": [..._(), "baseline"]
}],
/**
* Place Self
* @see https://tailwindcss.com/docs/place-self
*/
"place-self": [{
"place-self": ["auto", ..._()]
}],
// Spacing
/**
* Padding
* @see https://tailwindcss.com/docs/padding
*/
p: [{
p: g()
}],
/**
* Padding X
* @see https://tailwindcss.com/docs/padding
*/
px: [{
px: g()
}],
/**
* Padding Y
* @see https://tailwindcss.com/docs/padding
*/
py: [{
py: g()
}],
/**
* Padding Start
* @see https://tailwindcss.com/docs/padding
*/
ps: [{
ps: g()
}],
/**
* Padding End
* @see https://tailwindcss.com/docs/padding
*/
pe: [{
pe: g()
}],
/**
* Padding Top
* @see https://tailwindcss.com/docs/padding
*/
pt: [{
pt: g()
}],
/**
* Padding Right
* @see https://tailwindcss.com/docs/padding
*/
pr: [{
pr: g()
}],
/**
* Padding Bottom
* @see https://tailwindcss.com/docs/padding
*/
pb: [{
pb: g()
}],
/**
* Padding Left
* @see https://tailwindcss.com/docs/padding
*/
pl: [{
pl: g()
}],
/**
* Margin
* @see https://tailwindcss.com/docs/margin
*/
m: [{
m: P()
}],
/**
* Margin X
* @see https://tailwindcss.com/docs/margin
*/
mx: [{
mx: P()
}],
/**
* Margin Y
* @see https://tailwindcss.com/docs/margin
*/
my: [{
my: P()
}],
/**
* Margin Start
* @see https://tailwindcss.com/docs/margin
*/
ms: [{
ms: P()
}],
/**
* Margin End
* @see https://tailwindcss.com/docs/margin
*/
me: [{
me: P()
}],
/**
* Margin Top
* @see https://tailwindcss.com/docs/margin
*/
mt: [{
mt: P()
}],
/**
* Margin Right
* @see https://tailwindcss.com/docs/margin
*/
mr: [{
mr: P()
}],
/**
* Margin Bottom
* @see https://tailwindcss.com/docs/margin
*/
mb: [{
mb: P()
}],
/**
* Margin Left
* @see https://tailwindcss.com/docs/margin
*/
ml: [{
ml: P()
}],
/**
* Space Between X
* @see https://tailwindcss.com/docs/margin#adding-space-between-children
*/
"space-x": [{
"space-x": g()
}],
/**
* Space Between X Reverse
* @see https://tailwindcss.com/docs/margin#adding-space-between-children
*/
"space-x-reverse": ["space-x-reverse"],
/**
* Space Between Y
* @see https://tailwindcss.com/docs/margin#adding-space-between-children
*/
"space-y": [{
"space-y": g()
}],
/**
* Space Between Y Reverse
* @see https://tailwindcss.com/docs/margin#adding-space-between-children
*/
"space-y-reverse": ["space-y-reverse"],
// --------------
// --- Sizing ---
// --------------
/**
* Size
* @see https://tailwindcss.com/docs/width#setting-both-width-and-height
*/
size: [{
size: G()
}],
/**
* Width
* @see https://tailwindcss.com/docs/width
*/
w: [{
w: [m, "screen", ...G()]
}],
/**
* Min-Width
* @see https://tailwindcss.com/docs/min-width
*/
"min-w": [{
"min-w": [
m,
"screen",
/** Deprecated. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
"none",
...G()
]
}],
/**
* Max-Width
* @see https://tailwindcss.com/docs/max-width
*/
"max-w": [{
"max-w": [
m,
"screen",
"none",
/** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
"prose",
/** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
{
screen: [s]
},
...G()
]
}],
/**
* Height
* @see https://tailwindcss.com/docs/height
*/
h: [{
h: ["screen", "lh", ...G()]
}],
/**
* Min-Height
* @see https://tailwindcss.com/docs/min-height
*/
"min-h": [{
"min-h": ["screen", "lh", "none", ...G()]
}],
/**
* Max-Height
* @see https://tailwindcss.com/docs/max-height
*/
"max-h": [{
"max-h": ["screen", "lh", ...G()]
}],
// ------------------
// --- Typography ---
// ------------------
/**
* Font Size
* @see https://tailwindcss.com/docs/font-size
*/
"font-size": [{
text: ["base", t, H, B]
}],
/**
* Font Smoothing
* @see https://tailwindcss.com/docs/font-smoothing
*/
"font-smoothing": ["antialiased", "subpixel-antialiased"],
/**
* Font Style
* @see https://tailwindcss.com/docs/font-style
*/
"font-style": ["italic", "not-italic"],
/**
* Font Weight
* @see https://tailwindcss.com/docs/font-weight
*/
"font-weight": [{
font: [r, l, le]
}],
/**
* Font Stretch
* @see https://tailwindcss.com/docs/font-stretch
*/
"font-stretch": [{
"font-stretch": ["ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "normal", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded", ie, i]
}],
/**
* Font Family
* @see https://tailwindcss.com/docs/font-family
*/
"font-family": [{
font: [xt, i, o]
}],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-normal": ["normal-nums"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-ordinal": ["ordinal"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-slashed-zero": ["slashed-zero"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-figure": ["lining-nums", "oldstyle-nums"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-spacing": ["proportional-nums", "tabular-nums"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-fraction": ["diagonal-fractions", "stacked-fractions"],
/**
* Letter Spacing
* @see https://tailwindcss.com/docs/letter-spacing
*/
tracking: [{
tracking: [n, l, i]
}],
/**
* Line Clamp
* @see https://tailwindcss.com/docs/line-clamp
*/
"line-clamp": [{
"line-clamp": [b, "none", l, le]
}],
/**
* Line Height
* @see https://tailwindcss.com/docs/line-height
*/
leading: [{
leading: [
/** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
a,
...g()
]
}],
/**
* List Style Image
* @see https://tailwindcss.com/docs/list-style-image
*/
"list-image": [{
"list-image": ["none", l, i]
}],
/**
* List Style Position
* @see https://tailwindcss.com/docs/list-style-position
*/
"list-style-position": [{
list: ["inside", "outside"]
}],
/**
* List Style Type
* @see https://tailwindcss.com/docs/list-style-type
*/
"list-style-type": [{
list: ["disc", "decimal", "none", l, i]
}],
/**
* Text Alignment
* @see https://tailwindcss.com/docs/text-align
*/
"text-alignment": [{
text: ["left", "center", "right", "justify", "start", "end"]
}],
/**
* Placeholder Color
* @deprecated since Tailwind CSS v3.0.0
* @see https://v3.tailwindcss.com/docs/placeholder-color
*/
"placeholder-color": [{
placeholder: u()
}],
/**
* Text Color
* @see https://tailwindcss.com/docs/text-color
*/
"text-color": [{
text: u()
}],
/**
* Text Decoration
* @see https://tailwindcss.com/docs/text-decoration
*/
"text-decoration": ["underline", "overline", "line-through", "no-underline"],
/**
* Text Decoration Style
* @see https://tailwindcss.com/docs/text-decoration-style
*/
"text-decoration-style": [{
decoration: [...J(), "wavy"]
}],
/**
* Text Decoration Thickness
* @see https://tailwindcss.com/docs/text-decoration-thickness
*/
"text-decoration-thickness": [{
decoration: [b, "from-font", "auto", l, B]
}],
/**
* Text Decoration Color
* @see https://tailwindcss.com/docs/text-decoration-color
*/
"text-decoration-color": [{
decoration: u()
}],
/**
* Text Underline Offset
* @see https://tailwindcss.com/docs/text-underline-offset
*/
"underline-offset": [{
"underline-offset": [b, "auto", l, i]
}],
/**
* Text Transform
* @see https://tailwindcss.com/docs/text-transform
*/
"text-transform": ["uppercase", "lowercase", "capitalize", "normal-case"],
/**
* Text Overflow
* @see https://tailwindcss.com/docs/text-overflow
*/
"text-overflow": ["truncate", "text-ellipsis", "text-clip"],
/**
* Text Wrap
* @see https://tailwindcss.com/docs/text-wrap
*/
"text-wrap": [{
text: ["wrap", "nowrap", "balance", "pretty"]
}],
/**
* Text Indent
* @see https://tailwindcss.com/docs/text-indent
*/
indent: [{
indent: g()
}],
/**
* Vertical Alignment
* @see https://tailwindcss.com/docs/vertical-align
*/
"vertical-align": [{
align: ["baseline", "top", "middle", "bottom", "text-top", "text-bottom", "sub", "super", l, i]
}],
/**
* Whitespace
* @see https://tailwindcss.com/docs/whitespace
*/
whitespace: [{
whitespace: ["normal", "nowrap", "pre", "pre-line", "pre-wrap", "break-spaces"]
}],
/**
* Word Break
* @see https://tailwindcss.com/docs/word-break
*/
break: [{
break: ["normal", "words", "all", "keep"]
}],
/**
* Overflow Wrap
* @see https://tailwindcss.com/docs/overflow-wrap
*/
wrap: [{
wrap: ["break-word", "anywhere", "normal"]
}],
/**
* Hyphens
* @see https://tailwindcss.com/docs/hyphens
*/
hyphens: [{
hyphens: ["none", "manual", "auto"]
}],
/**
* Content
* @see https://tailwindcss.com/docs/content
*/
content: [{
content: ["none", l, i]
}],
// -------------------
// --- Backgrounds ---
// -------------------
/**
* Background Attachment
* @see https://tailwindcss.com/docs/background-attachment
*/
"bg-attachment": [{
bg: ["fixed", "local", "scroll"]
}],
/**
* Background Clip
* @see https://tailwindcss.com/docs/background-clip
*/
"bg-clip": [{
"bg-clip": ["border", "padding", "content", "text"]
}],
/**
* Background Origin
* @see https://tailwindcss.com/docs/background-origin
*/
"bg-origin": [{
"bg-origin": ["border", "padding", "content"]
}],
/**
* Background Position
* @see https://tailwindcss.com/docs/background-position
*/
"bg-position": [{
bg: he()
}],
/**
* Background Repeat
* @see https://tailwindcss.com/docs/background-repeat
*/
"bg-repeat": [{
bg: ye()
}],
/**
* Background Size
* @see https://tailwindcss.com/docs/background-size
*/
"bg-size": [{
bg: we()
}],
/**
* Background Image
* @see https://tailwindcss.com/docs/background-image
*/
"bg-image": [{
bg: ["none", {
linear: [{
to: ["t", "tr", "r", "br", "b", "bl", "l", "tl"]
}, L, l, i],
radial: ["", l, i],
conic: [L, l, i]
}, vt, wt]
}],
/**
* Background Color
* @see https://tailwindcss.com/docs/background-color
*/
"bg-color": [{
bg: u()
}],
/**
* Gradient Color Stops From Position
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-from-pos": [{
from: ne()
}],
/**
* Gradient Color Stops Via Position
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-via-pos": [{
via: ne()
}],
/**
* Gradient Color Stops To Position
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-to-pos": [{
to: ne()
}],
/**
* Gradient Color Stops From
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-from": [{
from: u()
}],
/**
* Gradient Color Stops Via
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-via": [{
via: u()
}],
/**
* Gradient Color Stops To
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-to": [{
to: u()
}],
// ---------------
// --- Borders ---
// ---------------
/**
* Border Radius
* @see https://tailwindcss.com/docs/border-radius
*/
rounded: [{
rounded: A()
}],
/**
* Border Radius Start
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-s": [{
"rounded-s": A()
}],
/**
* Border Radius End
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-e": [{
"rounded-e": A()
}],
/**
* Border Radius Top
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-t": [{
"rounded-t": A()
}],
/**
* Border Radius Right
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-r": [{
"rounded-r": A()
}],
/**
* Border Radius Bottom
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-b": [{
"rounded-b": A()
}],
/**
* Border Radius Left
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-l": [{
"rounded-l": A()
}],
/**
* Border Radius Start Start
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-ss": [{
"rounded-ss": A()
}],
/**
* Border Radius Start End
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-se": [{
"rounded-se": A()
}],
/**
* Border Radius End End
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-ee": [{
"rounded-ee": A()
}],
/**
* Border Radius End Start
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-es": [{
"rounded-es": A()
}],
/**
* Border Radius Top Left
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-tl": [{
"rounded-tl": A()
}],
/**
* Border Radius Top Right
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-tr": [{
"rounded-tr": A()
}],
/**
* Border Radius Bottom Right
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-br": [{
"rounded-br": A()
}],
/**
* Border Radius Bottom Left
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-bl": [{
"rounded-bl": A()
}],
/**
* Border Width
* @see https://tailwindcss.com/docs/border-width
*/
"border-w": [{
border: I()
}],
/**
* Border Width X
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-x": [{
"border-x": I()
}],
/**
* Border Width Y
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-y": [{
"border-y": I()
}],
/**
* Border Width Start
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-s": [{
"border-s": I()
}],
/**
* Border Width End
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-e": [{
"border-e": I()
}],
/**
* Border Width Top
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-t": [{
"border-t": I()
}],
/**
* Border Width Right
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-r": [{
"border-r": I()
}],
/**
* Border Width Bottom
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-b": [{
"border-b": I()
}],
/**
* Border Width Left
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-l": [{
"border-l": I()
}],
/**
* Divide Width X
* @see https://tailwindcss.com/docs/border-width#between-children
*/
"divide-x": [{
"divide-x": I()
}],
/**
* Divide Width X Reverse
* @see https://tailwindcss.com/docs/border-width#between-children
*/
"divide-x-reverse": ["divide-x-reverse"],
/**
* Divide Width Y
* @see https://tailwindcss.com/docs/border-width#between-children
*/
"divide-y": [{
"divide-y": I()
}],
/**
* Divide Width Y Reverse
* @see https://tailwindcss.com/docs/border-width#between-children
*/
"divide-y-reverse": ["divide-y-reverse"],
/**
* Border Style
* @see https://tailwindcss.com/docs/border-style
*/
"border-style": [{
border: [...J(), "hidden", "none"]
}],
/**
* Divide Style
* @see https://tailwindcss.com/docs/border-style#setting-the-divider-style
*/
"divide-style": [{
divide: [...J(), "hidden", "none"]
}],
/**
* Border Color
* @see https://tailwindcss.com/docs/border-color
*/
"border-color": [{
border: u()
}],
/**
* Border Color X
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-x": [{
"border-x": u()
}],
/**
* Border Color Y
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-y": [{
"border-y": u()
}],
/**
* Border Color S
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-s": [{
"border-s": u()
}],
/**
* Border Color E
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-e": [{
"border-e": u()
}],
/**
* Border Color Top
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-t": [{
"border-t": u()
}],
/**
* Border Color Right
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-r": [{
"border-r": u()
}],
/**
* Border Color Bottom
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-b": [{
"border-b": u()
}],
/**
* Border Color Left
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-l": [{
"border-l": u()
}],
/**
* Divide Color
* @see https://tailwindcss.com/docs/divide-color
*/
"divide-color": [{
divide: u()
}],
/**
* Outline Style
* @see https://tailwindcss.com/docs/outline-style
*/
"outline-style": [{
outline: [...J(), "none", "hidden"]
}],
/**
* Outline Offset
* @see https://tailwindcss.com/docs/outline-offset
*/
"outline-offset": [{
"outline-offset": [b, l, i]
}],
/**
* Outline Width
* @see https://tailwindcss.com/docs/outline-width
*/
"outline-w": [{
outline: ["", b, H, B]
}],
/**
* Outline Color
* @see https://tailwindcss.com/docs/outline-color
*/
"outline-color": [{
outline: u()
}],
// ---------------
// --- Effects ---
// ---------------
/**
* Box Shadow
* @see https://tailwindcss.com/docs/box-shadow
*/
shadow: [{
shadow: [
// Deprecated since Tailwind CSS v4.0.0
"",
"none",
c,
te,
ee
]
}],
/**
* Box Shadow Color
* @see https://tailwindcss.com/docs/box-shadow#setting-the-shadow-color
*/
"shadow-color": [{
shadow: u()
}],
/**
* Inset Box Shadow
* @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-shadow
*/
"inset-shadow": [{
"inset-shadow": ["none", h, te, ee]
}],
/**
* Inset Box Shadow Color
* @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-shadow-color
*/
"inset-shadow-color": [{
"inset-shadow": u()
}],
/**
* Ring Width
* @see https://tailwindcss.com/docs/box-shadow#adding-a-ring
*/
"ring-w": [{
ring: