@transkripid/flowbite-react
Version:
Official React components built for Flowbite and Tailwind CSS - Transkrip.id fork
42 lines (41 loc) • 1.49 kB
JavaScript
import { jsx as G } from "react/jsx-runtime";
import { c as N } from "react/compiler-runtime";
import { Children as b, cloneElement as v } from "react";
import { twMerge as B } from "tailwind-merge";
import { mergeDeep as T } from "../../helpers/merge-deep.mjs";
import { getTheme as j } from "../../theme-store/index.mjs";
const w = (f) => {
const e = N(20);
let t, l, r, m, i, o;
e[0] !== f ? ({
children: t,
className: l,
outline: r,
pill: m,
theme: o,
...i
} = f, e[0] = f, e[1] = t, e[2] = l, e[3] = r, e[4] = m, e[5] = i, e[6] = o) : (t = e[1], l = e[2], r = e[3], m = e[4], i = e[5], o = e[6]);
let p;
e[7] !== o ? (p = o === void 0 ? {} : o, e[7] = o, e[8] = p) : p = e[8];
const u = p;
let h, n;
e[9] !== t || e[10] !== r || e[11] !== m ? (n = b.map(t, (d, g) => v(d, {
outline: r,
pill: m,
positionInGroup: g === 0 ? "start" : g === t.length - 1 ? "end" : "middle"
})), e[9] = t, e[10] = r, e[11] = m, e[12] = n) : n = e[12], h = n;
const a = h;
let s;
if (e[13] !== l || e[14] !== u) {
const d = T(j().buttonGroup, u);
s = B(d.base, l), e[13] = l, e[14] = u, e[15] = s;
} else
s = e[15];
let c;
return e[16] !== a || e[17] !== i || e[18] !== s ? (c = /* @__PURE__ */ G("div", { className: s, role: "group", ...i, children: a }), e[16] = a, e[17] = i, e[18] = s, e[19] = c) : c = e[19], c;
};
w.displayName = "Button.Group";
export {
w as ButtonGroup
};
//# sourceMappingURL=ButtonGroup.mjs.map