@playbooks/ui
Version:
An interface library for Playbooks.
50 lines (49 loc) • 1.6 kB
JavaScript
;
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const require$$0 = require("react/jsx-runtime");
const html = require("./toast-context-kVz4KXNu.cjs");
const InputGroup = ({
name = "InputGroup",
active,
tailwind,
className,
children,
...props
}) => {
const { theme } = html.useInterface();
const base = theme.inputGroup();
const computed = { ...base, ...props, tailwind, className, name };
return /* @__PURE__ */ require$$0.jsx(html.Div, { ...computed, children });
};
const InputAppend = ({
name = "InputAppend",
icon,
taskRunning,
tailwind,
className,
children,
...props
}) => {
const { theme } = html.useInterface();
const base = theme.inputAppend();
const computed = { ...base, ...props, tailwind, className, name };
return /* @__PURE__ */ require$$0.jsx(html.Div, { ...computed, children: icon ? /* @__PURE__ */ require$$0.jsx(html.Icon, { icon: (icon == null ? void 0 : icon.icon) || icon, ...icon }) : children });
};
const InputPrepend = ({
name = "InputPrepend",
icon,
taskRunning,
onClick,
tailwind,
className,
children,
...props
}) => {
const { theme } = html.useInterface();
const base = theme.inputPrepend();
const computed = { ...base, ...props, tailwind, className, name };
return /* @__PURE__ */ require$$0.jsx(html.Div, { ...computed, children: icon ? /* @__PURE__ */ require$$0.jsx(html.Icon, { icon: (icon == null ? void 0 : icon.icon) || icon, ...icon }) : children });
};
exports.InputAppend = InputAppend;
exports.InputGroup = InputGroup;
exports.InputPrepend = InputPrepend;