@llmnative/react 1.30.0 → 1.31.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.css +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +31 -16
- package/dist/index.mjs.map +1 -1
- package/dist/types/src/components/blocks/Dropdown.d.ts +12 -1
- package/dist/types/src/components/widgets/Chatbot.d.ts +6 -0
- package/llms-full.txt +14 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -4309,26 +4309,38 @@ var ia = ({ children: e, badge: t = void 0, display: n = "dynamic", className: r
|
|
|
4309
4309
|
badge: t,
|
|
4310
4310
|
className: i || f.Dropdown.badgeClassName
|
|
4311
4311
|
}, m);
|
|
4312
|
-
}, aa = ({ children: e, url: t = void 0, onClick: n = void 0, icon: r = void 0, className: i = void 0 }) => {
|
|
4313
|
-
let
|
|
4314
|
-
n?.(e), !e.defaultPrevented &&
|
|
4315
|
-
},
|
|
4312
|
+
}, aa = ({ children: e, url: t = void 0, onClick: n = void 0, icon: r = void 0, className: i = void 0, actions: a = void 0 }) => {
|
|
4313
|
+
let o = Y("dropdown"), s = d.useContext(ta), c = (e) => {
|
|
4314
|
+
n?.(e), !e.defaultPrevented && s?.closeOnSelect && s.close();
|
|
4315
|
+
}, l = r ? /* @__PURE__ */ d.createElement("span", { className: "inline-flex min-w-0 items-center gap-2" }, /* @__PURE__ */ d.createElement("span", { className: "inline-flex h-4 w-4 shrink-0 items-center justify-center text-muted-foreground" }, /* @__PURE__ */ d.createElement(Q, {
|
|
4316
4316
|
name: r,
|
|
4317
4317
|
size: 16
|
|
4318
|
-
})), /* @__PURE__ */ d.createElement("span", { className: "min-w-0" }, e)) : e
|
|
4319
|
-
return t ? /* @__PURE__ */ d.createElement(O, {
|
|
4318
|
+
})), /* @__PURE__ */ d.createElement("span", { className: "min-w-0" }, e)) : e, u = t ? /* @__PURE__ */ d.createElement(O, {
|
|
4320
4319
|
to: t,
|
|
4321
|
-
onClick:
|
|
4320
|
+
onClick: c,
|
|
4322
4321
|
role: "menuitem",
|
|
4323
|
-
className: X("flex w-full cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground", i ||
|
|
4324
|
-
},
|
|
4325
|
-
onClick:
|
|
4322
|
+
className: X("flex w-full cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground", i || o.Dropdown.menuItemClass)
|
|
4323
|
+
}, l) : n ? /* @__PURE__ */ d.createElement("button", {
|
|
4324
|
+
onClick: c,
|
|
4326
4325
|
role: "menuitem",
|
|
4327
|
-
className: X("flex w-full cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-left text-sm outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground", i ||
|
|
4328
|
-
},
|
|
4326
|
+
className: X("flex w-full cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-left text-sm outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground", i || o.Dropdown.menuItemClass)
|
|
4327
|
+
}, l) : /* @__PURE__ */ d.createElement("span", {
|
|
4329
4328
|
role: "menuitem",
|
|
4330
|
-
className: X("flex w-full select-none items-center rounded-sm px-2 py-1.5 text-sm", i ||
|
|
4331
|
-
},
|
|
4329
|
+
className: X("flex w-full select-none items-center rounded-sm px-2 py-1.5 text-sm", i || o.Dropdown.menuItemClass)
|
|
4330
|
+
}, l);
|
|
4331
|
+
return a?.length ? /* @__PURE__ */ d.createElement("div", { className: "group/dropdown-item flex w-full min-w-0 items-center gap-0.5" }, /* @__PURE__ */ d.createElement("div", { className: "min-w-0 flex-1" }, u), a.map((e) => /* @__PURE__ */ d.createElement("button", {
|
|
4332
|
+
key: e.label,
|
|
4333
|
+
type: "button",
|
|
4334
|
+
title: e.label,
|
|
4335
|
+
"aria-label": e.label,
|
|
4336
|
+
onClick: (t) => {
|
|
4337
|
+
t.stopPropagation(), e.onClick(), e.closeOnClick && s?.close();
|
|
4338
|
+
},
|
|
4339
|
+
className: "inline-flex h-7 w-7 shrink-0 items-center justify-center rounded-sm text-muted-foreground opacity-0 transition-opacity hover:bg-accent hover:text-foreground focus:opacity-100 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring group-hover/dropdown-item:opacity-100 group-focus-within/dropdown-item:opacity-100 [@media(hover:none)]:opacity-100"
|
|
4340
|
+
}, /* @__PURE__ */ d.createElement(Q, {
|
|
4341
|
+
name: e.icon,
|
|
4342
|
+
size: 14
|
|
4343
|
+
})))) : u;
|
|
4332
4344
|
}, oa = ({ children: e, className: t }) => {
|
|
4333
4345
|
let n = Y("dropdown");
|
|
4334
4346
|
return /* @__PURE__ */ d.createElement("div", { className: X("px-2 py-1.5 text-xs font-medium uppercase tracking-wide text-muted-foreground", t || n.Dropdown.menuHeaderClass) }, e);
|
|
@@ -9718,11 +9730,14 @@ function Pu({ name: e, value: t, onChange: n, placeholder: r, running: i = !1, o
|
|
|
9718
9730
|
key: e.key,
|
|
9719
9731
|
type: "button",
|
|
9720
9732
|
title: e.label,
|
|
9721
|
-
|
|
9733
|
+
"aria-label": e.label,
|
|
9734
|
+
disabled: e.disabled,
|
|
9735
|
+
onClick: e.onClick,
|
|
9736
|
+
className: e.showLabel && e.label ? `${Tu} flex w-auto items-center gap-1.5 px-2 text-xs disabled:cursor-not-allowed disabled:opacity-50` : `${Tu} flex items-center justify-center disabled:cursor-not-allowed disabled:opacity-50`
|
|
9722
9737
|
}, /* @__PURE__ */ d.createElement(Q, {
|
|
9723
9738
|
name: e.icon,
|
|
9724
9739
|
size: 13
|
|
9725
|
-
}))), /* @__PURE__ */ d.createElement("div", { className: "mx-1 h-4 w-px shrink-0 bg-border" })), f.length > 0 && /* @__PURE__ */ d.createElement(na, {
|
|
9740
|
+
}), e.showLabel && e.label && /* @__PURE__ */ d.createElement("span", { className: "whitespace-nowrap" }, e.label))), /* @__PURE__ */ d.createElement("div", { className: "mx-1 h-4 w-px shrink-0 bg-border" })), f.length > 0 && /* @__PURE__ */ d.createElement(na, {
|
|
9726
9741
|
trigger: {
|
|
9727
9742
|
icon: "cpu",
|
|
9728
9743
|
text: ve ?? h ?? N.defaultOption
|