@deepnoid/ui 0.1.83 → 0.1.86

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.
Files changed (36) hide show
  1. package/.turbo/turbo-build.log +143 -143
  2. package/dist/{chunk-4ORPRDPL.mjs → chunk-D6OJWEZM.mjs} +1 -1
  3. package/dist/{chunk-7GFYCPP3.mjs → chunk-Q3JMHIW5.mjs} +2 -2
  4. package/dist/{chunk-B6YYZVT6.mjs → chunk-V5OCV42N.mjs} +35 -8
  5. package/dist/{chunk-FKHKYVZH.mjs → chunk-VSURAISO.mjs} +40 -10
  6. package/dist/components/accordion/accordionItem.d.mts +2 -5
  7. package/dist/components/accordion/accordionItem.d.ts +2 -5
  8. package/dist/components/accordion/accordionItem.js +34 -4646
  9. package/dist/components/accordion/accordionItem.mjs +1 -4
  10. package/dist/components/accordion/index.d.mts +0 -3
  11. package/dist/components/accordion/index.d.ts +0 -3
  12. package/dist/components/accordion/index.js +33 -4647
  13. package/dist/components/accordion/index.mjs +1 -4
  14. package/dist/components/breadcrumb/breadcrumb.mjs +3 -3
  15. package/dist/components/breadcrumb/index.mjs +3 -3
  16. package/dist/components/button/button.d.mts +4 -2
  17. package/dist/components/button/button.d.ts +4 -2
  18. package/dist/components/button/button.js +26 -5
  19. package/dist/components/button/button.mjs +2 -2
  20. package/dist/components/button/icon-button.mjs +2 -2
  21. package/dist/components/button/index.js +26 -5
  22. package/dist/components/button/index.mjs +3 -3
  23. package/dist/components/fileUpload/fileUpload.js +26 -5
  24. package/dist/components/fileUpload/fileUpload.mjs +4 -4
  25. package/dist/components/fileUpload/index.js +26 -5
  26. package/dist/components/fileUpload/index.mjs +4 -4
  27. package/dist/components/modal/index.js +26 -5
  28. package/dist/components/modal/index.mjs +4 -4
  29. package/dist/components/modal/modal.js +26 -5
  30. package/dist/components/modal/modal.mjs +4 -4
  31. package/dist/components/ripple/index.mjs +3 -3
  32. package/dist/components/table/index.mjs +3 -3
  33. package/dist/index.js +804 -759
  34. package/dist/index.mjs +17 -17
  35. package/package.json +1 -1
  36. package/dist/{chunk-Z6IOS3S6.mjs → chunk-P6CRHHI3.mjs} +3 -3
@@ -5,11 +5,8 @@ import {
5
5
  } from "../../chunk-EKLA6ZR4.mjs";
6
6
  import {
7
7
  accordionItem_default
8
- } from "../../chunk-FKHKYVZH.mjs";
9
- import "../../chunk-ZYIIXWVY.mjs";
10
- import "../../chunk-JP4TEWP7.mjs";
8
+ } from "../../chunk-VSURAISO.mjs";
11
9
  import "../../chunk-E3G5QXSH.mjs";
12
- import "../../chunk-RRONV7YA.mjs";
13
10
  import "../../chunk-CDXBML6O.mjs";
14
11
  import "../../chunk-AC6TWLRT.mjs";
15
12
  export {
@@ -5,11 +5,11 @@ import {
5
5
  import "../../chunk-MY5U63QO.mjs";
6
6
  import "../../chunk-JBSV7GCL.mjs";
7
7
  import "../../chunk-ITWKPTSD.mjs";
8
- import "../../chunk-B6YYZVT6.mjs";
9
- import "../../chunk-Z6IOS3S6.mjs";
8
+ import "../../chunk-V5OCV42N.mjs";
9
+ import "../../chunk-P6CRHHI3.mjs";
10
10
  import "../../chunk-6WSACUIB.mjs";
11
- import "../../chunk-6PNKRBUT.mjs";
12
11
  import "../../chunk-LXHUO6VM.mjs";
12
+ import "../../chunk-6PNKRBUT.mjs";
13
13
  import "../../chunk-ZYIIXWVY.mjs";
14
14
  import "../../chunk-JP4TEWP7.mjs";
15
15
  import "../../chunk-E3G5QXSH.mjs";
@@ -6,11 +6,11 @@ import {
6
6
  import "../../chunk-MY5U63QO.mjs";
7
7
  import "../../chunk-JBSV7GCL.mjs";
8
8
  import "../../chunk-ITWKPTSD.mjs";
9
- import "../../chunk-B6YYZVT6.mjs";
10
- import "../../chunk-Z6IOS3S6.mjs";
9
+ import "../../chunk-V5OCV42N.mjs";
10
+ import "../../chunk-P6CRHHI3.mjs";
11
11
  import "../../chunk-6WSACUIB.mjs";
12
- import "../../chunk-6PNKRBUT.mjs";
13
12
  import "../../chunk-LXHUO6VM.mjs";
13
+ import "../../chunk-6PNKRBUT.mjs";
14
14
  import "../../chunk-ZYIIXWVY.mjs";
15
15
  import "../../chunk-JP4TEWP7.mjs";
16
16
  import "../../chunk-E3G5QXSH.mjs";
@@ -1,6 +1,7 @@
1
1
  import * as tailwind_variants from 'tailwind-variants';
2
2
  import { VariantProps } from 'tailwind-variants';
3
- import react__default, { ButtonHTMLAttributes, ReactNode } from 'react';
3
+ import * as react from 'react';
4
+ import { ButtonHTMLAttributes, ReactNode } from 'react';
4
5
  import { SlotsToClasses } from '../../utils/types.mjs';
5
6
 
6
7
  interface Props extends ButtonHTMLAttributes<HTMLButtonElement> {
@@ -9,9 +10,10 @@ interface Props extends ButtonHTMLAttributes<HTMLButtonElement> {
9
10
  endContent?: ReactNode;
10
11
  disableRipple?: boolean;
11
12
  classNames?: SlotsToClasses<ButtonSlots>;
13
+ asChild?: boolean;
12
14
  }
13
15
  type ButtonProps = Props & ButtonVariantProps;
14
- declare const Button: react__default.ForwardRefExoticComponent<Props & ButtonVariantProps & react__default.RefAttributes<HTMLButtonElement>>;
16
+ declare const Button: react.ForwardRefExoticComponent<Props & ButtonVariantProps & react.RefAttributes<HTMLButtonElement>>;
15
17
 
16
18
  declare const buttonStyle: tailwind_variants.TVReturnType<{
17
19
  variant: {
@@ -1,6 +1,7 @@
1
1
  import * as tailwind_variants from 'tailwind-variants';
2
2
  import { VariantProps } from 'tailwind-variants';
3
- import react__default, { ButtonHTMLAttributes, ReactNode } from 'react';
3
+ import * as react from 'react';
4
+ import { ButtonHTMLAttributes, ReactNode } from 'react';
4
5
  import { SlotsToClasses } from '../../utils/types.js';
5
6
 
6
7
  interface Props extends ButtonHTMLAttributes<HTMLButtonElement> {
@@ -9,9 +10,10 @@ interface Props extends ButtonHTMLAttributes<HTMLButtonElement> {
9
10
  endContent?: ReactNode;
10
11
  disableRipple?: boolean;
11
12
  classNames?: SlotsToClasses<ButtonSlots>;
13
+ asChild?: boolean;
12
14
  }
13
15
  type ButtonProps = Props & ButtonVariantProps;
14
- declare const Button: react__default.ForwardRefExoticComponent<Props & ButtonVariantProps & react__default.RefAttributes<HTMLButtonElement>>;
16
+ declare const Button: react.ForwardRefExoticComponent<Props & ButtonVariantProps & react.RefAttributes<HTMLButtonElement>>;
15
17
 
16
18
  declare const buttonStyle: tailwind_variants.TVReturnType<{
17
19
  variant: {
@@ -105,7 +105,7 @@ __export(button_exports, {
105
105
  default: () => button_default
106
106
  });
107
107
  module.exports = __toCommonJS(button_exports);
108
- var import_react2 = __toESM(require("react"));
108
+ var import_react2 = require("react");
109
109
 
110
110
  // src/utils/tailwind-variants.ts
111
111
  var import_tailwind_variants = require("tailwind-variants");
@@ -5073,7 +5073,7 @@ function useRipple(props = {}) {
5073
5073
  var import_jsx_runtime4 = require("react/jsx-runtime");
5074
5074
  var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5075
5075
  const [props, variantProps] = mapPropsVariants(originalProps, buttonStyle.variantKeys);
5076
- const { classNames, startContent, endContent, disableRipple, children, ...buttonProps } = props;
5076
+ const { classNames, startContent, endContent, disableRipple, asChild, children, ...buttonProps } = props;
5077
5077
  const slots = (0, import_react2.useMemo)(() => buttonStyle({ ...variantProps }), [variantProps]);
5078
5078
  const { onPress: onRipplePressHandler, onClear: onClearRipple, ripples } = useRipple();
5079
5079
  const handlePress = (0, import_react2.useCallback)(
@@ -5115,25 +5115,46 @@ var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5115
5115
  [slots, classNames, originalProps.size]
5116
5116
  );
5117
5117
  const renderContent = (content) => {
5118
- if (import_react2.default.isValidElement(content)) {
5118
+ if ((0, import_react2.isValidElement)(content)) {
5119
5119
  const _content = content;
5120
5120
  const existingProps = _content.props;
5121
5121
  const mergedProps = {
5122
5122
  ...getContentProps(),
5123
5123
  className: `${getContentProps().className || ""} ${existingProps.className || ""}`.trim()
5124
5124
  };
5125
- return import_react2.default.cloneElement(content, mergedProps);
5125
+ return (0, import_react2.cloneElement)(content, mergedProps);
5126
5126
  } else {
5127
5127
  const contentProps = getContentProps();
5128
5128
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { ...contentProps, children: content });
5129
5129
  }
5130
5130
  };
5131
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5131
+ const buttonContent = /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5132
5132
  startContent && renderContent(startContent),
5133
5133
  children,
5134
5134
  endContent && renderContent(endContent),
5135
5135
  !disableRipple && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ripple_default, { ...getRippleProps() })
5136
5136
  ] }) });
5137
+ if (asChild && (0, import_react2.isValidElement)(children)) {
5138
+ const childElement = children;
5139
+ const baseProps = getBaseProps();
5140
+ const mergedProps = {
5141
+ ...childElement.props,
5142
+ ...baseProps,
5143
+ className: `${baseProps.className || ""} ${childElement.props.className || ""}`.trim(),
5144
+ onClick: (e) => {
5145
+ var _a, _b, _c;
5146
+ (_b = (_a = childElement.props).onClick) == null ? void 0 : _b.call(_a, e);
5147
+ (_c = baseProps.onClick) == null ? void 0 : _c.call(baseProps, e);
5148
+ },
5149
+ onMouseDown: (e) => {
5150
+ var _a, _b, _c;
5151
+ (_b = (_a = childElement.props).onMouseDown) == null ? void 0 : _b.call(_a, e);
5152
+ (_c = baseProps.onMouseDown) == null ? void 0 : _c.call(baseProps, e);
5153
+ }
5154
+ };
5155
+ return (0, import_react2.cloneElement)(childElement, mergedProps);
5156
+ }
5157
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: buttonContent });
5137
5158
  });
5138
5159
  Button.displayName = "Button";
5139
5160
  var button_default = Button;
@@ -1,10 +1,10 @@
1
1
  "use client";
2
2
  import {
3
3
  button_default
4
- } from "../../chunk-B6YYZVT6.mjs";
4
+ } from "../../chunk-V5OCV42N.mjs";
5
5
  import "../../chunk-6WSACUIB.mjs";
6
- import "../../chunk-6PNKRBUT.mjs";
7
6
  import "../../chunk-LXHUO6VM.mjs";
7
+ import "../../chunk-6PNKRBUT.mjs";
8
8
  import "../../chunk-ZYIIXWVY.mjs";
9
9
  import "../../chunk-JP4TEWP7.mjs";
10
10
  import "../../chunk-E3G5QXSH.mjs";
@@ -1,10 +1,10 @@
1
1
  "use client";
2
2
  import {
3
3
  icon_button_default
4
- } from "../../chunk-Z6IOS3S6.mjs";
4
+ } from "../../chunk-P6CRHHI3.mjs";
5
5
  import "../../chunk-6WSACUIB.mjs";
6
- import "../../chunk-6PNKRBUT.mjs";
7
6
  import "../../chunk-LXHUO6VM.mjs";
7
+ import "../../chunk-6PNKRBUT.mjs";
8
8
  import "../../chunk-ZYIIXWVY.mjs";
9
9
  import "../../chunk-JP4TEWP7.mjs";
10
10
  import "../../chunk-E3G5QXSH.mjs";
@@ -110,7 +110,7 @@ __export(button_exports, {
110
110
  module.exports = __toCommonJS(button_exports);
111
111
 
112
112
  // src/components/button/button.tsx
113
- var import_react2 = __toESM(require("react"));
113
+ var import_react2 = require("react");
114
114
 
115
115
  // src/utils/tailwind-variants.ts
116
116
  var import_tailwind_variants = require("tailwind-variants");
@@ -5078,7 +5078,7 @@ function useRipple(props = {}) {
5078
5078
  var import_jsx_runtime4 = require("react/jsx-runtime");
5079
5079
  var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5080
5080
  const [props, variantProps] = mapPropsVariants(originalProps, buttonStyle.variantKeys);
5081
- const { classNames, startContent, endContent, disableRipple, children, ...buttonProps } = props;
5081
+ const { classNames, startContent, endContent, disableRipple, asChild, children, ...buttonProps } = props;
5082
5082
  const slots = (0, import_react2.useMemo)(() => buttonStyle({ ...variantProps }), [variantProps]);
5083
5083
  const { onPress: onRipplePressHandler, onClear: onClearRipple, ripples } = useRipple();
5084
5084
  const handlePress = (0, import_react2.useCallback)(
@@ -5120,25 +5120,46 @@ var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5120
5120
  [slots, classNames, originalProps.size]
5121
5121
  );
5122
5122
  const renderContent = (content) => {
5123
- if (import_react2.default.isValidElement(content)) {
5123
+ if ((0, import_react2.isValidElement)(content)) {
5124
5124
  const _content = content;
5125
5125
  const existingProps = _content.props;
5126
5126
  const mergedProps = {
5127
5127
  ...getContentProps(),
5128
5128
  className: `${getContentProps().className || ""} ${existingProps.className || ""}`.trim()
5129
5129
  };
5130
- return import_react2.default.cloneElement(content, mergedProps);
5130
+ return (0, import_react2.cloneElement)(content, mergedProps);
5131
5131
  } else {
5132
5132
  const contentProps = getContentProps();
5133
5133
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { ...contentProps, children: content });
5134
5134
  }
5135
5135
  };
5136
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5136
+ const buttonContent = /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5137
5137
  startContent && renderContent(startContent),
5138
5138
  children,
5139
5139
  endContent && renderContent(endContent),
5140
5140
  !disableRipple && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ripple_default, { ...getRippleProps() })
5141
5141
  ] }) });
5142
+ if (asChild && (0, import_react2.isValidElement)(children)) {
5143
+ const childElement = children;
5144
+ const baseProps = getBaseProps();
5145
+ const mergedProps = {
5146
+ ...childElement.props,
5147
+ ...baseProps,
5148
+ className: `${baseProps.className || ""} ${childElement.props.className || ""}`.trim(),
5149
+ onClick: (e) => {
5150
+ var _a, _b, _c;
5151
+ (_b = (_a = childElement.props).onClick) == null ? void 0 : _b.call(_a, e);
5152
+ (_c = baseProps.onClick) == null ? void 0 : _c.call(baseProps, e);
5153
+ },
5154
+ onMouseDown: (e) => {
5155
+ var _a, _b, _c;
5156
+ (_b = (_a = childElement.props).onMouseDown) == null ? void 0 : _b.call(_a, e);
5157
+ (_c = baseProps.onMouseDown) == null ? void 0 : _c.call(baseProps, e);
5158
+ }
5159
+ };
5160
+ return (0, import_react2.cloneElement)(childElement, mergedProps);
5161
+ }
5162
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: buttonContent });
5142
5163
  });
5143
5164
  Button.displayName = "Button";
5144
5165
  var button_default = Button;
@@ -8,13 +8,13 @@ import {
8
8
  } from "../../chunk-ITWKPTSD.mjs";
9
9
  import {
10
10
  button_default
11
- } from "../../chunk-B6YYZVT6.mjs";
11
+ } from "../../chunk-V5OCV42N.mjs";
12
12
  import {
13
13
  icon_button_default
14
- } from "../../chunk-Z6IOS3S6.mjs";
14
+ } from "../../chunk-P6CRHHI3.mjs";
15
15
  import "../../chunk-6WSACUIB.mjs";
16
- import "../../chunk-6PNKRBUT.mjs";
17
16
  import "../../chunk-LXHUO6VM.mjs";
17
+ import "../../chunk-6PNKRBUT.mjs";
18
18
  import "../../chunk-ZYIIXWVY.mjs";
19
19
  import "../../chunk-JP4TEWP7.mjs";
20
20
  import "../../chunk-E3G5QXSH.mjs";
@@ -5414,7 +5414,7 @@ var inputStyle = tv(
5414
5414
  );
5415
5415
 
5416
5416
  // src/components/button/button.tsx
5417
- var import_react3 = __toESM(require("react"));
5417
+ var import_react3 = require("react");
5418
5418
 
5419
5419
  // src/components/ripple/ripple.tsx
5420
5420
  var import_framer_motion = require("framer-motion");
@@ -5486,7 +5486,7 @@ function useRipple(props = {}) {
5486
5486
  var import_jsx_runtime5 = require("react/jsx-runtime");
5487
5487
  var Button = (0, import_react3.forwardRef)((originalProps, ref) => {
5488
5488
  const [props, variantProps] = mapPropsVariants(originalProps, buttonStyle.variantKeys);
5489
- const { classNames, startContent, endContent, disableRipple, children, ...buttonProps } = props;
5489
+ const { classNames, startContent, endContent, disableRipple, asChild, children, ...buttonProps } = props;
5490
5490
  const slots = (0, import_react3.useMemo)(() => buttonStyle({ ...variantProps }), [variantProps]);
5491
5491
  const { onPress: onRipplePressHandler, onClear: onClearRipple, ripples } = useRipple();
5492
5492
  const handlePress = (0, import_react3.useCallback)(
@@ -5528,25 +5528,46 @@ var Button = (0, import_react3.forwardRef)((originalProps, ref) => {
5528
5528
  [slots, classNames, originalProps.size]
5529
5529
  );
5530
5530
  const renderContent = (content) => {
5531
- if (import_react3.default.isValidElement(content)) {
5531
+ if ((0, import_react3.isValidElement)(content)) {
5532
5532
  const _content = content;
5533
5533
  const existingProps = _content.props;
5534
5534
  const mergedProps = {
5535
5535
  ...getContentProps(),
5536
5536
  className: `${getContentProps().className || ""} ${existingProps.className || ""}`.trim()
5537
5537
  };
5538
- return import_react3.default.cloneElement(content, mergedProps);
5538
+ return (0, import_react3.cloneElement)(content, mergedProps);
5539
5539
  } else {
5540
5540
  const contentProps = getContentProps();
5541
5541
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { ...contentProps, children: content });
5542
5542
  }
5543
5543
  };
5544
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { ...getBaseProps(), children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
5544
+ const buttonContent = /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_jsx_runtime5.Fragment, { children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
5545
5545
  startContent && renderContent(startContent),
5546
5546
  children,
5547
5547
  endContent && renderContent(endContent),
5548
5548
  !disableRipple && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ripple_default, { ...getRippleProps() })
5549
5549
  ] }) });
5550
+ if (asChild && (0, import_react3.isValidElement)(children)) {
5551
+ const childElement = children;
5552
+ const baseProps = getBaseProps();
5553
+ const mergedProps = {
5554
+ ...childElement.props,
5555
+ ...baseProps,
5556
+ className: `${baseProps.className || ""} ${childElement.props.className || ""}`.trim(),
5557
+ onClick: (e) => {
5558
+ var _a, _b, _c;
5559
+ (_b = (_a = childElement.props).onClick) == null ? void 0 : _b.call(_a, e);
5560
+ (_c = baseProps.onClick) == null ? void 0 : _c.call(baseProps, e);
5561
+ },
5562
+ onMouseDown: (e) => {
5563
+ var _a, _b, _c;
5564
+ (_b = (_a = childElement.props).onMouseDown) == null ? void 0 : _b.call(_a, e);
5565
+ (_c = baseProps.onMouseDown) == null ? void 0 : _c.call(baseProps, e);
5566
+ }
5567
+ };
5568
+ return (0, import_react3.cloneElement)(childElement, mergedProps);
5569
+ }
5570
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { ...getBaseProps(), children: buttonContent });
5550
5571
  });
5551
5572
  Button.displayName = "Button";
5552
5573
  var button_default = Button;
@@ -3,17 +3,17 @@ import {
3
3
  FileUpload,
4
4
  fileUploadStyle,
5
5
  fileUpload_default
6
- } from "../../chunk-7GFYCPP3.mjs";
6
+ } from "../../chunk-Q3JMHIW5.mjs";
7
7
  import "../../chunk-2GCSFWHD.mjs";
8
8
  import "../../chunk-MVL7HJSH.mjs";
9
9
  import "../../chunk-MY5U63QO.mjs";
10
10
  import "../../chunk-JBSV7GCL.mjs";
11
11
  import "../../chunk-ITWKPTSD.mjs";
12
- import "../../chunk-B6YYZVT6.mjs";
13
- import "../../chunk-Z6IOS3S6.mjs";
12
+ import "../../chunk-V5OCV42N.mjs";
13
+ import "../../chunk-P6CRHHI3.mjs";
14
14
  import "../../chunk-6WSACUIB.mjs";
15
- import "../../chunk-6PNKRBUT.mjs";
16
15
  import "../../chunk-LXHUO6VM.mjs";
16
+ import "../../chunk-6PNKRBUT.mjs";
17
17
  import "../../chunk-ZYIIXWVY.mjs";
18
18
  import "../../chunk-JP4TEWP7.mjs";
19
19
  import "../../chunk-E3G5QXSH.mjs";
@@ -5414,7 +5414,7 @@ var inputStyle = tv(
5414
5414
  );
5415
5415
 
5416
5416
  // src/components/button/button.tsx
5417
- var import_react3 = __toESM(require("react"));
5417
+ var import_react3 = require("react");
5418
5418
 
5419
5419
  // src/components/ripple/ripple.tsx
5420
5420
  var import_framer_motion = require("framer-motion");
@@ -5486,7 +5486,7 @@ function useRipple(props = {}) {
5486
5486
  var import_jsx_runtime5 = require("react/jsx-runtime");
5487
5487
  var Button = (0, import_react3.forwardRef)((originalProps, ref) => {
5488
5488
  const [props, variantProps] = mapPropsVariants(originalProps, buttonStyle.variantKeys);
5489
- const { classNames, startContent, endContent, disableRipple, children, ...buttonProps } = props;
5489
+ const { classNames, startContent, endContent, disableRipple, asChild, children, ...buttonProps } = props;
5490
5490
  const slots = (0, import_react3.useMemo)(() => buttonStyle({ ...variantProps }), [variantProps]);
5491
5491
  const { onPress: onRipplePressHandler, onClear: onClearRipple, ripples } = useRipple();
5492
5492
  const handlePress = (0, import_react3.useCallback)(
@@ -5528,25 +5528,46 @@ var Button = (0, import_react3.forwardRef)((originalProps, ref) => {
5528
5528
  [slots, classNames, originalProps.size]
5529
5529
  );
5530
5530
  const renderContent = (content) => {
5531
- if (import_react3.default.isValidElement(content)) {
5531
+ if ((0, import_react3.isValidElement)(content)) {
5532
5532
  const _content = content;
5533
5533
  const existingProps = _content.props;
5534
5534
  const mergedProps = {
5535
5535
  ...getContentProps(),
5536
5536
  className: `${getContentProps().className || ""} ${existingProps.className || ""}`.trim()
5537
5537
  };
5538
- return import_react3.default.cloneElement(content, mergedProps);
5538
+ return (0, import_react3.cloneElement)(content, mergedProps);
5539
5539
  } else {
5540
5540
  const contentProps = getContentProps();
5541
5541
  return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { ...contentProps, children: content });
5542
5542
  }
5543
5543
  };
5544
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { ...getBaseProps(), children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
5544
+ const buttonContent = /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_jsx_runtime5.Fragment, { children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
5545
5545
  startContent && renderContent(startContent),
5546
5546
  children,
5547
5547
  endContent && renderContent(endContent),
5548
5548
  !disableRipple && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ripple_default, { ...getRippleProps() })
5549
5549
  ] }) });
5550
+ if (asChild && (0, import_react3.isValidElement)(children)) {
5551
+ const childElement = children;
5552
+ const baseProps = getBaseProps();
5553
+ const mergedProps = {
5554
+ ...childElement.props,
5555
+ ...baseProps,
5556
+ className: `${baseProps.className || ""} ${childElement.props.className || ""}`.trim(),
5557
+ onClick: (e) => {
5558
+ var _a, _b, _c;
5559
+ (_b = (_a = childElement.props).onClick) == null ? void 0 : _b.call(_a, e);
5560
+ (_c = baseProps.onClick) == null ? void 0 : _c.call(baseProps, e);
5561
+ },
5562
+ onMouseDown: (e) => {
5563
+ var _a, _b, _c;
5564
+ (_b = (_a = childElement.props).onMouseDown) == null ? void 0 : _b.call(_a, e);
5565
+ (_c = baseProps.onMouseDown) == null ? void 0 : _c.call(baseProps, e);
5566
+ }
5567
+ };
5568
+ return (0, import_react3.cloneElement)(childElement, mergedProps);
5569
+ }
5570
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("button", { ...getBaseProps(), children: buttonContent });
5550
5571
  });
5551
5572
  Button.displayName = "Button";
5552
5573
  var button_default = Button;
@@ -2,17 +2,17 @@
2
2
  import "../../chunk-RLXOHILK.mjs";
3
3
  import {
4
4
  fileUpload_default
5
- } from "../../chunk-7GFYCPP3.mjs";
5
+ } from "../../chunk-Q3JMHIW5.mjs";
6
6
  import "../../chunk-2GCSFWHD.mjs";
7
7
  import "../../chunk-MVL7HJSH.mjs";
8
8
  import "../../chunk-MY5U63QO.mjs";
9
9
  import "../../chunk-JBSV7GCL.mjs";
10
10
  import "../../chunk-ITWKPTSD.mjs";
11
- import "../../chunk-B6YYZVT6.mjs";
12
- import "../../chunk-Z6IOS3S6.mjs";
11
+ import "../../chunk-V5OCV42N.mjs";
12
+ import "../../chunk-P6CRHHI3.mjs";
13
13
  import "../../chunk-6WSACUIB.mjs";
14
- import "../../chunk-6PNKRBUT.mjs";
15
14
  import "../../chunk-LXHUO6VM.mjs";
15
+ import "../../chunk-6PNKRBUT.mjs";
16
16
  import "../../chunk-ZYIIXWVY.mjs";
17
17
  import "../../chunk-JP4TEWP7.mjs";
18
18
  import "../../chunk-E3G5QXSH.mjs";
@@ -5007,7 +5007,7 @@ var Icon = ({ name, size = "md", fill = false, className, onClick, ...props }) =
5007
5007
  var Icon_default = Icon;
5008
5008
 
5009
5009
  // src/components/button/button.tsx
5010
- var import_react2 = __toESM(require("react"));
5010
+ var import_react2 = require("react");
5011
5011
 
5012
5012
  // src/components/ripple/ripple.tsx
5013
5013
  var import_framer_motion = require("framer-motion");
@@ -5079,7 +5079,7 @@ function useRipple(props = {}) {
5079
5079
  var import_jsx_runtime4 = require("react/jsx-runtime");
5080
5080
  var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5081
5081
  const [props, variantProps] = mapPropsVariants(originalProps, buttonStyle.variantKeys);
5082
- const { classNames, startContent, endContent, disableRipple, children, ...buttonProps } = props;
5082
+ const { classNames, startContent, endContent, disableRipple, asChild, children, ...buttonProps } = props;
5083
5083
  const slots = (0, import_react2.useMemo)(() => buttonStyle({ ...variantProps }), [variantProps]);
5084
5084
  const { onPress: onRipplePressHandler, onClear: onClearRipple, ripples } = useRipple();
5085
5085
  const handlePress = (0, import_react2.useCallback)(
@@ -5121,25 +5121,46 @@ var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5121
5121
  [slots, classNames, originalProps.size]
5122
5122
  );
5123
5123
  const renderContent = (content) => {
5124
- if (import_react2.default.isValidElement(content)) {
5124
+ if ((0, import_react2.isValidElement)(content)) {
5125
5125
  const _content = content;
5126
5126
  const existingProps = _content.props;
5127
5127
  const mergedProps = {
5128
5128
  ...getContentProps(),
5129
5129
  className: `${getContentProps().className || ""} ${existingProps.className || ""}`.trim()
5130
5130
  };
5131
- return import_react2.default.cloneElement(content, mergedProps);
5131
+ return (0, import_react2.cloneElement)(content, mergedProps);
5132
5132
  } else {
5133
5133
  const contentProps = getContentProps();
5134
5134
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { ...contentProps, children: content });
5135
5135
  }
5136
5136
  };
5137
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5137
+ const buttonContent = /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5138
5138
  startContent && renderContent(startContent),
5139
5139
  children,
5140
5140
  endContent && renderContent(endContent),
5141
5141
  !disableRipple && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ripple_default, { ...getRippleProps() })
5142
5142
  ] }) });
5143
+ if (asChild && (0, import_react2.isValidElement)(children)) {
5144
+ const childElement = children;
5145
+ const baseProps = getBaseProps();
5146
+ const mergedProps = {
5147
+ ...childElement.props,
5148
+ ...baseProps,
5149
+ className: `${baseProps.className || ""} ${childElement.props.className || ""}`.trim(),
5150
+ onClick: (e) => {
5151
+ var _a, _b, _c;
5152
+ (_b = (_a = childElement.props).onClick) == null ? void 0 : _b.call(_a, e);
5153
+ (_c = baseProps.onClick) == null ? void 0 : _c.call(baseProps, e);
5154
+ },
5155
+ onMouseDown: (e) => {
5156
+ var _a, _b, _c;
5157
+ (_b = (_a = childElement.props).onMouseDown) == null ? void 0 : _b.call(_a, e);
5158
+ (_c = baseProps.onMouseDown) == null ? void 0 : _c.call(baseProps, e);
5159
+ }
5160
+ };
5161
+ return (0, import_react2.cloneElement)(childElement, mergedProps);
5162
+ }
5163
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: buttonContent });
5143
5164
  });
5144
5165
  Button.displayName = "Button";
5145
5166
  var button_default = Button;
@@ -2,17 +2,17 @@
2
2
  import "../../chunk-DJOG6Z35.mjs";
3
3
  import {
4
4
  modal_default
5
- } from "../../chunk-4ORPRDPL.mjs";
5
+ } from "../../chunk-D6OJWEZM.mjs";
6
6
  import "../../chunk-SE5TU755.mjs";
7
7
  import "../../chunk-AF4I7ZQS.mjs";
8
8
  import "../../chunk-MY5U63QO.mjs";
9
9
  import "../../chunk-JBSV7GCL.mjs";
10
10
  import "../../chunk-ITWKPTSD.mjs";
11
- import "../../chunk-B6YYZVT6.mjs";
12
- import "../../chunk-Z6IOS3S6.mjs";
11
+ import "../../chunk-V5OCV42N.mjs";
12
+ import "../../chunk-P6CRHHI3.mjs";
13
13
  import "../../chunk-6WSACUIB.mjs";
14
- import "../../chunk-6PNKRBUT.mjs";
15
14
  import "../../chunk-LXHUO6VM.mjs";
15
+ import "../../chunk-6PNKRBUT.mjs";
16
16
  import "../../chunk-ZYIIXWVY.mjs";
17
17
  import "../../chunk-JP4TEWP7.mjs";
18
18
  import "../../chunk-E3G5QXSH.mjs";
@@ -5005,7 +5005,7 @@ var Icon = ({ name, size = "md", fill = false, className, onClick, ...props }) =
5005
5005
  var Icon_default = Icon;
5006
5006
 
5007
5007
  // src/components/button/button.tsx
5008
- var import_react2 = __toESM(require("react"));
5008
+ var import_react2 = require("react");
5009
5009
 
5010
5010
  // src/components/ripple/ripple.tsx
5011
5011
  var import_framer_motion = require("framer-motion");
@@ -5077,7 +5077,7 @@ function useRipple(props = {}) {
5077
5077
  var import_jsx_runtime4 = require("react/jsx-runtime");
5078
5078
  var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5079
5079
  const [props, variantProps] = mapPropsVariants(originalProps, buttonStyle.variantKeys);
5080
- const { classNames, startContent, endContent, disableRipple, children, ...buttonProps } = props;
5080
+ const { classNames, startContent, endContent, disableRipple, asChild, children, ...buttonProps } = props;
5081
5081
  const slots = (0, import_react2.useMemo)(() => buttonStyle({ ...variantProps }), [variantProps]);
5082
5082
  const { onPress: onRipplePressHandler, onClear: onClearRipple, ripples } = useRipple();
5083
5083
  const handlePress = (0, import_react2.useCallback)(
@@ -5119,25 +5119,46 @@ var Button = (0, import_react2.forwardRef)((originalProps, ref) => {
5119
5119
  [slots, classNames, originalProps.size]
5120
5120
  );
5121
5121
  const renderContent = (content) => {
5122
- if (import_react2.default.isValidElement(content)) {
5122
+ if ((0, import_react2.isValidElement)(content)) {
5123
5123
  const _content = content;
5124
5124
  const existingProps = _content.props;
5125
5125
  const mergedProps = {
5126
5126
  ...getContentProps(),
5127
5127
  className: `${getContentProps().className || ""} ${existingProps.className || ""}`.trim()
5128
5128
  };
5129
- return import_react2.default.cloneElement(content, mergedProps);
5129
+ return (0, import_react2.cloneElement)(content, mergedProps);
5130
5130
  } else {
5131
5131
  const contentProps = getContentProps();
5132
5132
  return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { ...contentProps, children: content });
5133
5133
  }
5134
5134
  };
5135
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5135
+ const buttonContent = /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: originalProps.isLoading ? renderContent(/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Icon_default, { name: "loading", className: "animate-spin" })) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
5136
5136
  startContent && renderContent(startContent),
5137
5137
  children,
5138
5138
  endContent && renderContent(endContent),
5139
5139
  !disableRipple && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ripple_default, { ...getRippleProps() })
5140
5140
  ] }) });
5141
+ if (asChild && (0, import_react2.isValidElement)(children)) {
5142
+ const childElement = children;
5143
+ const baseProps = getBaseProps();
5144
+ const mergedProps = {
5145
+ ...childElement.props,
5146
+ ...baseProps,
5147
+ className: `${baseProps.className || ""} ${childElement.props.className || ""}`.trim(),
5148
+ onClick: (e) => {
5149
+ var _a, _b, _c;
5150
+ (_b = (_a = childElement.props).onClick) == null ? void 0 : _b.call(_a, e);
5151
+ (_c = baseProps.onClick) == null ? void 0 : _c.call(baseProps, e);
5152
+ },
5153
+ onMouseDown: (e) => {
5154
+ var _a, _b, _c;
5155
+ (_b = (_a = childElement.props).onMouseDown) == null ? void 0 : _b.call(_a, e);
5156
+ (_c = baseProps.onMouseDown) == null ? void 0 : _c.call(baseProps, e);
5157
+ }
5158
+ };
5159
+ return (0, import_react2.cloneElement)(childElement, mergedProps);
5160
+ }
5161
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("button", { ...getBaseProps(), children: buttonContent });
5141
5162
  });
5142
5163
  Button.displayName = "Button";
5143
5164
  var button_default = Button;
@@ -1,17 +1,17 @@
1
1
  "use client";
2
2
  import {
3
3
  modal_default
4
- } from "../../chunk-4ORPRDPL.mjs";
4
+ } from "../../chunk-D6OJWEZM.mjs";
5
5
  import "../../chunk-SE5TU755.mjs";
6
6
  import "../../chunk-AF4I7ZQS.mjs";
7
7
  import "../../chunk-MY5U63QO.mjs";
8
8
  import "../../chunk-JBSV7GCL.mjs";
9
9
  import "../../chunk-ITWKPTSD.mjs";
10
- import "../../chunk-B6YYZVT6.mjs";
11
- import "../../chunk-Z6IOS3S6.mjs";
10
+ import "../../chunk-V5OCV42N.mjs";
11
+ import "../../chunk-P6CRHHI3.mjs";
12
12
  import "../../chunk-6WSACUIB.mjs";
13
- import "../../chunk-6PNKRBUT.mjs";
14
13
  import "../../chunk-LXHUO6VM.mjs";
14
+ import "../../chunk-6PNKRBUT.mjs";
15
15
  import "../../chunk-ZYIIXWVY.mjs";
16
16
  import "../../chunk-JP4TEWP7.mjs";
17
17
  import "../../chunk-E3G5QXSH.mjs";