welcome-ui
Version:
Customizable design system with react, typescript, tailwindcss and ariakit.
46 lines (45 loc) • 1.5 kB
JavaScript
"use client";
import { jsxs as t, jsx as o } from "react/jsx-runtime";
import { D as d } from "./NMGNQVTG-a9HpYqEe.js";
import { D as a } from "./T22PY7TE-BxbmImwX.js";
import { u as k } from "./T22PY7TE-BxbmImwX.js";
import { forwardRef as _ } from "react";
import "./Icon-BisRi8B3.js";
import { R as u } from "./index-Dcq5gh3E.js";
import { Text as f } from "./Text.js";
import { c as h } from "./index-PAaZGbyz.js";
const p = "_root_173le_2", v = "_icon_173le_11", x = "_disclosure_173le_23", N = {
root: p,
icon: v,
disclosure: x,
"disclosure-content": "_disclosure-content_173le_48",
"content-child": "_content-child_173le_63"
}, s = h(N), z = _(
({ children: e, className: r, dataTestId: c, store: i, title: n, ...l }, m) => /* @__PURE__ */ t("div", { className: s("root", r), ref: m, ...l, children: [
/* @__PURE__ */ t(
d,
{
className: s("disclosure"),
"data-testid": c ? `${c}-title` : void 0,
store: i,
children: [
/* @__PURE__ */ o(f, { variant: "h5", children: n }),
/* @__PURE__ */ o("div", { className: s("icon"), children: /* @__PURE__ */ o(u, { size: "sm" }) })
]
}
),
/* @__PURE__ */ o(
a,
{
className: s("disclosure-content"),
"data-testid": c ? `${c}-content` : void 0,
store: i,
children: /* @__PURE__ */ o("div", { className: s("content-child"), children: e })
}
)
] })
);
export {
z as Accordion,
k as useAccordion
};