@solostylist/ui-kit 1.0.166 → 1.0.168

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 (241) hide show
  1. package/dist/{Typography-B7LOtCzI.js → Typography-C8jwvSWe.js} +1 -1
  2. package/dist/main.d.ts +5 -3
  3. package/dist/main.js +182 -172
  4. package/dist/s-accordion/index.js +2 -2
  5. package/dist/s-accordion/s-accordion.d.ts +17 -1
  6. package/dist/s-accordion/s-accordion.js +252 -238
  7. package/dist/s-action-overlay/index.js +1 -1
  8. package/dist/s-action-overlay/s-action-overlay.d.ts +34 -1
  9. package/dist/s-action-overlay/s-action-overlay.js +67 -55
  10. package/dist/s-ai-tool-bar/index.d.ts +2 -0
  11. package/dist/s-ai-tool-bar/index.js +3 -2
  12. package/dist/s-ai-tool-bar/s-ai-tool-bar.d.ts +43 -22
  13. package/dist/s-ai-tool-bar/s-ai-tool-bar.js +336 -255
  14. package/dist/s-autocomplete/index.js +2 -2
  15. package/dist/s-autocomplete/s-autocomplete.d.ts +13 -15
  16. package/dist/s-autocomplete/s-autocomplete.js +25 -17
  17. package/dist/s-avatar/index.js +2 -2
  18. package/dist/s-avatar/s-avatar.d.ts +16 -1
  19. package/dist/s-avatar/s-avatar.js +23 -10
  20. package/dist/s-blur-text/index.js +2 -2
  21. package/dist/s-blur-text/s-blur-text.d.ts +4 -13
  22. package/dist/s-blur-text/s-blur-text.js +57 -51
  23. package/dist/s-breadcrumbs/index.js +2 -2
  24. package/dist/s-breadcrumbs/s-breadcrumbs.d.ts +20 -1
  25. package/dist/s-breadcrumbs/s-breadcrumbs.js +39 -30
  26. package/dist/s-button/index.js +2 -2
  27. package/dist/s-button/s-button.d.ts +7 -1
  28. package/dist/s-button/s-button.js +15 -5
  29. package/dist/s-button-link/index.js +2 -2
  30. package/dist/s-button-link/s-button-link.d.ts +12 -26
  31. package/dist/s-button-link/s-button-link.js +36 -26
  32. package/dist/s-carousel/index.js +1 -1
  33. package/dist/s-carousel/s-carousel.d.ts +11 -1
  34. package/dist/s-carousel/s-carousel.js +233 -223
  35. package/dist/s-category-card/index.js +2 -2
  36. package/dist/s-category-card/s-category-card.d.ts +28 -1
  37. package/dist/s-category-card/s-category-card.js +77 -58
  38. package/dist/s-chat-input/index.js +2 -2
  39. package/dist/s-chat-input/s-chat-input.d.ts +12 -1
  40. package/dist/s-chat-input/s-chat-input.js +92 -82
  41. package/dist/s-chat-message/index.js +2 -2
  42. package/dist/s-chat-message/s-chat-message.d.ts +22 -1
  43. package/dist/s-chat-message/s-chat-message.js +144 -133
  44. package/dist/s-checkbox/index.js +2 -2
  45. package/dist/s-checkbox/s-checkbox.d.ts +2 -15
  46. package/dist/s-checkbox/s-checkbox.js +20 -10
  47. package/dist/s-chip/index.js +2 -2
  48. package/dist/s-chip/s-chip.d.ts +7 -1
  49. package/dist/s-chip/s-chip.js +15 -5
  50. package/dist/s-chips/index.js +2 -2
  51. package/dist/s-chips/s-chips.d.ts +5 -18
  52. package/dist/s-chips/s-chips.js +56 -41
  53. package/dist/s-comment-message/index.js +2 -2
  54. package/dist/s-comment-message/s-comment-message.d.ts +26 -1
  55. package/dist/s-comment-message/s-comment-message.js +95 -89
  56. package/dist/s-copyable-text/index.js +1 -1
  57. package/dist/s-copyable-text/s-copyable-text.d.ts +9 -36
  58. package/dist/s-copyable-text/s-copyable-text.js +31 -21
  59. package/dist/s-countdown/index.d.ts +3 -2
  60. package/dist/s-countdown/index.js +4 -3
  61. package/dist/s-countdown/s-count-box.d.ts +39 -0
  62. package/dist/s-countdown/s-count-box.js +112 -0
  63. package/dist/s-countdown/s-count-down.d.ts +6 -50
  64. package/dist/s-countdown/s-count-down.js +110 -175
  65. package/dist/s-data-table/index.js +2 -2
  66. package/dist/s-data-table/s-data-table.d.ts +9 -65
  67. package/dist/s-data-table/s-data-table.js +381 -371
  68. package/dist/s-date-picker/index.js +2 -2
  69. package/dist/s-date-picker/s-date-picker.d.ts +6 -17
  70. package/dist/s-date-picker/s-date-picker.js +124 -107
  71. package/dist/s-datetime-picker/index.js +2 -2
  72. package/dist/s-datetime-picker/s-datetime-picker.d.ts +5 -16
  73. package/dist/s-datetime-picker/s-datetime-picker.js +897 -887
  74. package/dist/s-dialog/index.js +2 -2
  75. package/dist/s-dialog/s-dialog.d.ts +3 -16
  76. package/dist/s-dialog/s-dialog.js +32 -23
  77. package/dist/s-dialog-confirm/index.js +3 -3
  78. package/dist/s-dialog-confirm/s-dialog-confirm.d.ts +5 -13
  79. package/dist/s-dialog-confirm/s-dialog-confirm.js +55 -48
  80. package/dist/s-dialog-message/index.js +4 -4
  81. package/dist/s-dialog-message/s-dialog-message.d.ts +5 -15
  82. package/dist/s-dialog-message/s-dialog-message.js +45 -38
  83. package/dist/s-empty/index.js +2 -2
  84. package/dist/s-empty/s-empty.d.ts +5 -20
  85. package/dist/s-empty/s-empty.js +14 -4
  86. package/dist/s-error/index.js +2 -2
  87. package/dist/s-error/s-error.d.ts +5 -20
  88. package/dist/s-error/s-error.js +16 -6
  89. package/dist/s-error-layout/index.js +2 -2
  90. package/dist/s-error-layout/s-error-layout.d.ts +6 -1
  91. package/dist/s-error-layout/s-error-layout.js +60 -51
  92. package/dist/s-file-dropzone/index.js +2 -2
  93. package/dist/s-file-dropzone/s-file-dropzone.d.ts +6 -51
  94. package/dist/s-file-dropzone/s-file-dropzone.js +64 -54
  95. package/dist/s-file-icon/index.js +2 -2
  96. package/dist/s-file-icon/s-file-icon.d.ts +5 -25
  97. package/dist/s-file-icon/s-file-icon.js +14 -8
  98. package/dist/s-flex-box/index.js +2 -2
  99. package/dist/s-flex-box/s-flex-box.d.ts +10 -1
  100. package/dist/s-flex-box/s-flex-box.js +14 -4
  101. package/dist/s-form/index.js +2 -2
  102. package/dist/s-form/s-form.d.ts +5 -14
  103. package/dist/s-form/s-form.js +19 -9
  104. package/dist/s-gallery/index.js +33 -3
  105. package/dist/s-gallery/s-gallery.d.ts +3 -36
  106. package/dist/s-gallery/s-gallery.js +108 -78
  107. package/dist/s-glow-button/s-glow-button.d.ts +6 -42
  108. package/dist/s-glow-button/s-glow-button.js +29 -47
  109. package/dist/s-gradient-icon/index.d.ts +1 -1
  110. package/dist/s-gradient-icon/index.js +1 -1
  111. package/dist/s-gradient-icon/s-gradient-icon.d.ts +8 -68
  112. package/dist/s-gradient-icon/s-gradient-icon.js +54 -44
  113. package/dist/s-i18n-provider/index.js +1 -1
  114. package/dist/s-i18n-provider/s-i18n-provider.d.ts +5 -33
  115. package/dist/s-i18n-provider/s-i18n-provider.js +25 -15
  116. package/dist/s-icon-button/index.js +2 -2
  117. package/dist/s-icon-button/s-icon-button.d.ts +6 -19
  118. package/dist/s-icon-button/s-icon-button.js +14 -4
  119. package/dist/s-image-comparison/s-image-comparison.js +50 -45
  120. package/dist/s-image-modal/index.js +3 -3
  121. package/dist/s-image-modal/s-image-modal.d.ts +4 -20
  122. package/dist/s-image-modal/s-image-modal.js +150 -135
  123. package/dist/s-item-not-found/index.js +2 -2
  124. package/dist/s-item-not-found/s-item-not-found.d.ts +14 -1
  125. package/dist/s-item-not-found/s-item-not-found.js +21 -10
  126. package/dist/s-label/index.js +2 -2
  127. package/dist/s-label/s-label.d.ts +9 -25
  128. package/dist/s-label/s-label.js +19 -9
  129. package/dist/s-language-switcher/index.js +3 -3
  130. package/dist/s-language-switcher/s-language-switcher.d.ts +20 -33
  131. package/dist/s-language-switcher/s-language-switcher.js +137 -115
  132. package/dist/s-lazy-image/index.js +10 -2
  133. package/dist/s-lazy-image/s-lazy-image.d.ts +12 -58
  134. package/dist/s-lazy-image/s-lazy-image.js +53 -58
  135. package/dist/s-localization-provider/index.js +2 -2
  136. package/dist/s-localization-provider/s-localization-provider.d.ts +6 -27
  137. package/dist/s-localization-provider/s-localization-provider.js +157 -149
  138. package/dist/s-moving-border/index.js +2 -2
  139. package/dist/s-moving-border/s-moving-border.d.ts +3 -33
  140. package/dist/s-moving-border/s-moving-border.js +65 -55
  141. package/dist/s-multi-select/index.js +2 -2
  142. package/dist/s-multi-select/s-multi-select.d.ts +5 -15
  143. package/dist/s-multi-select/s-multi-select.js +54 -45
  144. package/dist/s-no-ssr/index.js +2 -2
  145. package/dist/s-no-ssr/s-no-ssr.d.ts +5 -33
  146. package/dist/s-no-ssr/s-no-ssr.js +21 -11
  147. package/dist/s-overlay-scrollbar/index.js +2 -2
  148. package/dist/s-overlay-scrollbar/s-overlay-scrollbar.d.ts +10 -1
  149. package/dist/s-overlay-scrollbar/s-overlay-scrollbar.js +16 -11
  150. package/dist/s-pagination/index.js +2 -2
  151. package/dist/s-pagination/s-pagination.d.ts +5 -23
  152. package/dist/s-pagination/s-pagination.js +17 -11
  153. package/dist/s-pixel-reveal/index.d.ts +2 -0
  154. package/dist/s-pixel-reveal/index.js +4 -0
  155. package/dist/s-pixel-reveal/package.json +5 -0
  156. package/dist/s-pixel-reveal/s-pixel-reveal.d.ts +27 -0
  157. package/dist/s-pixel-reveal/s-pixel-reveal.js +156 -0
  158. package/dist/s-radial-pulse-animate/index.js +2 -2
  159. package/dist/s-radial-pulse-animate/s-radial-pulse-animate.d.ts +12 -1
  160. package/dist/s-radial-pulse-animate/s-radial-pulse-animate.js +52 -42
  161. package/dist/s-rating/index.js +2 -2
  162. package/dist/s-rating/s-rating.d.ts +7 -1
  163. package/dist/s-rating/s-rating.js +15 -5
  164. package/dist/s-review/index.js +2 -2
  165. package/dist/s-review/s-review.d.ts +25 -1
  166. package/dist/s-review/s-review.js +104 -97
  167. package/dist/s-scroll-reveal/index.js +2 -2
  168. package/dist/s-scroll-reveal/s-scroll-reveal.d.ts +17 -36
  169. package/dist/s-scroll-reveal/s-scroll-reveal.js +43 -33
  170. package/dist/s-scroll-to-top/index.js +2 -2
  171. package/dist/s-scroll-to-top/s-scroll-to-top.d.ts +12 -17
  172. package/dist/s-scroll-to-top/s-scroll-to-top.js +20 -15
  173. package/dist/s-select/index.js +2 -2
  174. package/dist/s-select/s-select.d.ts +3 -22
  175. package/dist/s-select/s-select.js +76 -72
  176. package/dist/s-select-list/index.js +2 -2
  177. package/dist/s-select-list/s-select-list.d.ts +16 -19
  178. package/dist/s-select-list/s-select-list.js +33 -28
  179. package/dist/s-skeleton/index.js +2 -2
  180. package/dist/s-skeleton/s-skeleton.d.ts +6 -22
  181. package/dist/s-skeleton/s-skeleton.js +28 -18
  182. package/dist/s-snackbar-message/index.js +4 -4
  183. package/dist/s-snackbar-message/s-snackbar-message.d.ts +5 -23
  184. package/dist/s-snackbar-message/s-snackbar-message.js +38 -31
  185. package/dist/s-spotlight-cursor/index.js +2 -2
  186. package/dist/s-spotlight-cursor/s-spotlight-cursor.d.ts +10 -44
  187. package/dist/s-spotlight-cursor/s-spotlight-cursor.js +35 -29
  188. package/dist/s-stripe/index.d.ts +4 -1
  189. package/dist/s-stripe/index.js +7 -4
  190. package/dist/s-stripe/s-stripe-cvc.d.ts +8 -0
  191. package/dist/s-stripe/s-stripe-cvc.js +15 -0
  192. package/dist/s-stripe/s-stripe-expiry.d.ts +8 -0
  193. package/dist/s-stripe/s-stripe-expiry.js +15 -0
  194. package/dist/s-stripe/s-stripe-number.d.ts +8 -0
  195. package/dist/s-stripe/s-stripe-number.js +15 -0
  196. package/dist/s-stripe/s-stripe.d.ts +6 -85
  197. package/dist/s-stripe/s-stripe.js +24 -27
  198. package/dist/s-stripe/stripe-input.js +22 -18
  199. package/dist/s-tabs/index.js +6 -6
  200. package/dist/s-tabs/s-tab-panel.d.ts +11 -1
  201. package/dist/s-tabs/s-tab-panel.js +25 -16
  202. package/dist/s-tabs/s-tab.js +9 -5
  203. package/dist/s-tabs/s-tabs.d.ts +24 -3
  204. package/dist/s-tabs/s-tabs.js +34 -25
  205. package/dist/s-text-editor/index.js +3 -3
  206. package/dist/s-text-editor/s-text-editor-toolbar.js +91 -76
  207. package/dist/s-text-editor/s-text-editor.d.ts +13 -11
  208. package/dist/s-text-editor/s-text-editor.js +44 -30
  209. package/dist/s-text-field/index.js +2 -2
  210. package/dist/s-text-field/s-text-field.d.ts +6 -15
  211. package/dist/s-text-field/s-text-field.js +38 -28
  212. package/dist/s-text-shimmer/index.js +2 -2
  213. package/dist/s-text-shimmer/s-text-shimmer.d.ts +10 -1
  214. package/dist/s-text-shimmer/s-text-shimmer.js +27 -18
  215. package/dist/s-text-truncation/index.js +2 -2
  216. package/dist/s-text-truncation/s-text-truncation.d.ts +9 -38
  217. package/dist/s-text-truncation/s-text-truncation.js +34 -20
  218. package/dist/s-theme-demo/s-theme-demo.js +238 -223
  219. package/dist/s-theme-provider/index.js +1 -1
  220. package/dist/s-theme-provider/s-theme-provider.d.ts +5 -17
  221. package/dist/s-theme-provider/s-theme-provider.js +44 -34
  222. package/dist/s-theme-switch/s-theme-switch.js +23 -19
  223. package/dist/s-tip/index.js +2 -2
  224. package/dist/s-tip/s-tip.d.ts +5 -22
  225. package/dist/s-tip/s-tip.js +22 -12
  226. package/dist/s-two-pane-layout/index.js +10 -2
  227. package/dist/s-two-pane-layout/s-two-pane-layout.d.ts +7 -1
  228. package/dist/s-two-pane-layout/s-two-pane-layout.js +58 -48
  229. package/dist/s-typewriter-text/index.js +2 -2
  230. package/dist/s-typewriter-text/s-typewriter-text.d.ts +17 -1
  231. package/dist/s-typewriter-text/s-typewriter-text.js +37 -27
  232. package/dist/s-zoom-image/index.js +10 -2
  233. package/dist/s-zoom-image/s-zoom-image.d.ts +10 -42
  234. package/dist/s-zoom-image/s-zoom-image.js +62 -52
  235. package/dist/theme/components/alert.d.ts +1440 -1440
  236. package/dist/theme/components/button.d.ts +2156 -2156
  237. package/dist/theme/components/chip.d.ts +2 -2
  238. package/dist/theme/customizations/data-display.js +1 -1
  239. package/dist/{typographyClasses-C7fhAsUD.js → typographyClasses-DDyl9mok.js} +4 -4
  240. package/dist/{useMobilePicker-DgxcRrRB.js → useMobilePicker-C1RZZUWr.js} +1 -1
  241. package/package.json +10 -4
@@ -1,34 +1,37 @@
1
- import { j as e } from "../jsx-runtime-OVHDjVDe.js";
2
- import I, { useEffect as oe, useState as W, useMemo as D, useCallback as k } from "react";
3
- import { c as L } from "../createSvgIcon-DxwgGAVe.js";
4
- import { C as se } from "../Close-BRlEKA2Q.js";
5
- import { D as te } from "../Download-UsLvGg3y.js";
6
- import { TextField as G, Typography as ne, Box as n, Slider as le, alpha as z, Divider as ae, Tooltip as B, IconButton as P, Dialog as ce, DialogTitle as ie, DialogContent as de } from "@mui/material";
7
- import { createPortal as xe } from "react-dom";
8
- const he = L(/* @__PURE__ */ e.jsx("path", {
1
+ import { j as o } from "../jsx-runtime-OVHDjVDe.js";
2
+ import b, { useEffect as le, useState as N, useMemo as J, useCallback as w } from "react";
3
+ import { c as P } from "../createSvgIcon-DxwgGAVe.js";
4
+ import { C as ae } from "../Close-BRlEKA2Q.js";
5
+ import { D as re } from "../Download-UsLvGg3y.js";
6
+ import { TextField as Q, Typography as se, Box as r, Slider as ie, alpha as R, Checkbox as de, Divider as ue, Tooltip as _, IconButton as S, Dialog as ce, DialogTitle as fe, DialogContent as pe } from "@mui/material";
7
+ import { createPortal as me } from "react-dom";
8
+ import { SSelect as he } from "../s-select/s-select.js";
9
+ const xe = P(/* @__PURE__ */ o.jsx("path", {
9
10
  d: "M19 7v2.99s-1.99.01-2 0V7h-3s.01-1.99 0-2h3V2h2v3h3v2zm-3 4V8h-3V5H5c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-8zM5 19l3-4 2 3 3-4 4 5z"
10
- }), "AddPhotoAlternate"), me = L(/* @__PURE__ */ e.jsx("path", {
11
+ }), "AddPhotoAlternate"), ye = P(/* @__PURE__ */ o.jsx("path", {
11
12
  d: "M12 6v3l4-4-4-4v3c-4.42 0-8 3.58-8 8 0 1.57.46 3.03 1.24 4.26L6.7 14.8c-.45-.83-.7-1.79-.7-2.8 0-3.31 2.69-6 6-6m6.76 1.74L17.3 9.2c.44.84.7 1.79.7 2.8 0 3.31-2.69 6-6 6v-3l-4 4 4 4v-3c4.42 0 8-3.58 8-8 0-1.57-.46-3.03-1.24-4.26"
12
- }), "Autorenew"), fe = L(/* @__PURE__ */ e.jsx("path", {
13
+ }), "Autorenew"), ge = P(/* @__PURE__ */ o.jsx("path", {
13
14
  d: "M11 7h2v2h-2zm0 4h2v6h-2zm1-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8"
14
- }), "InfoOutlined"), ue = L(/* @__PURE__ */ e.jsx("path", {
15
+ }), "InfoOutlined"), be = P(/* @__PURE__ */ o.jsx("path", {
15
16
  d: "M8 5v14l11-7z"
16
- }), "PlayArrow"), ye = I.memo(({ input: o, value: c, onChange: m, onFocus: t, onBlur: f, disabled: x }) => /* @__PURE__ */ e.jsx(
17
- G,
17
+ }), "PlayArrow");
18
+ var W = /* @__PURE__ */ ((e) => (e.TEXTAREA = "textarea", e.SLIDER = "slider", e.IMAGE = "image", e.NUMBER = "number", e.SELECT = "select", e.CHECKBOX = "checkbox", e))(W || {});
19
+ const ve = b.memo(({ input: e, value: a, onChange: c, onFocus: l, onBlur: f, disabled: d }) => /* @__PURE__ */ o.jsx(
20
+ Q,
18
21
  {
19
- value: c,
20
- onChange: (h) => m(h.target.value),
21
- onFocus: t,
22
+ value: a,
23
+ onChange: (u) => c(u.target.value),
24
+ onFocus: l,
22
25
  onBlur: f,
23
- placeholder: o.placeholder || o.label,
24
- disabled: x,
26
+ placeholder: e.placeholder || e.label,
27
+ disabled: d,
25
28
  multiline: !0,
26
- minRows: o.minRows ?? 2,
27
- maxRows: o.maxRows ?? 5,
29
+ minRows: e.minRows ?? 2,
30
+ maxRows: e.maxRows ?? 5,
28
31
  fullWidth: !0
29
32
  }
30
- )), J = I.memo((o) => /* @__PURE__ */ e.jsx(
31
- ne,
33
+ )), F = b.memo((e) => /* @__PURE__ */ o.jsx(
34
+ se,
32
35
  {
33
36
  variant: "caption",
34
37
  sx: {
@@ -39,34 +42,34 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
39
42
  width: "100% !important",
40
43
  textAlign: "center"
41
44
  },
42
- children: o.label
45
+ children: e.label
43
46
  }
44
- )), je = I.memo(({ input: o, value: c, onChange: m, isExpanded: t, onFocus: f, onBlur: x, disabled: h }) => /* @__PURE__ */ e.jsxs(
45
- n,
47
+ )), je = b.memo(({ input: e, value: a, onChange: c, isExpanded: l, onFocus: f, onBlur: d, disabled: u }) => /* @__PURE__ */ o.jsxs(
48
+ r,
46
49
  {
47
50
  sx: {
48
- width: t ? 120 : 60,
51
+ width: l ? 120 : 60,
49
52
  transition: "width 0.3s ease",
50
53
  display: "flex",
51
54
  flexDirection: "column"
52
55
  },
53
56
  children: [
54
- /* @__PURE__ */ e.jsx(J, { label: o.label }),
55
- /* @__PURE__ */ e.jsx(
56
- G,
57
+ /* @__PURE__ */ o.jsx(F, { label: e.label }),
58
+ /* @__PURE__ */ o.jsx(
59
+ Q,
57
60
  {
58
61
  type: "number",
59
- value: c ?? o.defaultValue ?? 0,
60
- onChange: (g) => m(Number(g.target.value)),
62
+ value: a ?? e.defaultValue ?? 0,
63
+ onChange: (h) => c(Number(h.target.value)),
61
64
  onFocus: f,
62
- onBlur: x,
63
- disabled: h,
65
+ onBlur: d,
66
+ disabled: u,
64
67
  size: "small",
65
68
  slotProps: {
66
69
  htmlInput: {
67
- min: o.min,
68
- max: o.max,
69
- step: o.step
70
+ min: e.min,
71
+ max: e.max,
72
+ step: e.step
70
73
  }
71
74
  },
72
75
  sx: {
@@ -78,128 +81,158 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
78
81
  )
79
82
  ]
80
83
  }
81
- )), ge = I.memo(({ input: o, value: c, onChange: m, isExpanded: t, onFocus: f, onBlur: x, disabled: h }) => /* @__PURE__ */ e.jsxs(
82
- n,
84
+ )), we = b.memo(({ input: e, value: a, onChange: c, isExpanded: l, onFocus: f, onBlur: d, disabled: u }) => /* @__PURE__ */ o.jsxs(
85
+ r,
83
86
  {
84
87
  sx: {
85
- width: t ? 160 : 60,
88
+ width: l ? 180 : 80,
86
89
  transition: "width 0.3s ease",
87
90
  display: "flex",
88
91
  flexDirection: "column"
89
92
  },
90
93
  children: [
91
- /* @__PURE__ */ e.jsx(J, { label: o.label }),
92
- /* @__PURE__ */ e.jsxs(n, { sx: { display: "flex", alignItems: "center", height: 36 }, children: [
93
- t && /* @__PURE__ */ e.jsx(
94
- le,
94
+ /* @__PURE__ */ o.jsx(F, { label: e.label }),
95
+ /* @__PURE__ */ o.jsx(
96
+ he,
97
+ {
98
+ value: a ?? e.defaultValue ?? "",
99
+ onChange: (h) => c(h.target.value),
100
+ onFocus: f,
101
+ onBlur: d,
102
+ disabled: u,
103
+ placeholder: e.placeholder,
104
+ options: e.options || [],
105
+ optionLabel: e.optionLabel,
106
+ optionValue: e.optionValue,
107
+ searchable: e.searchable,
108
+ searchPlaceholder: e.searchPlaceholder,
109
+ size: "small"
110
+ }
111
+ )
112
+ ]
113
+ }
114
+ )), Ie = b.memo(({ input: e, value: a, onChange: c, isExpanded: l, onFocus: f, onBlur: d, disabled: u }) => /* @__PURE__ */ o.jsxs(
115
+ r,
116
+ {
117
+ sx: {
118
+ width: l ? 160 : 60,
119
+ transition: "width 0.3s ease",
120
+ display: "flex",
121
+ flexDirection: "column"
122
+ },
123
+ children: [
124
+ /* @__PURE__ */ o.jsx(F, { label: e.label }),
125
+ /* @__PURE__ */ o.jsxs(r, { sx: { display: "flex", alignItems: "center", height: 36 }, children: [
126
+ l && /* @__PURE__ */ o.jsx(
127
+ ie,
95
128
  {
96
- value: c ?? o.defaultValue ?? o.min ?? 0,
97
- onChange: (g, v) => m(v),
129
+ value: a ?? e.defaultValue ?? e.min ?? 0,
130
+ onChange: (h, I) => c(I),
98
131
  onMouseDown: f,
99
- onMouseUp: x,
100
- disabled: h,
101
- min: o.min ?? 0,
102
- max: o.max ?? 100,
103
- step: o.step ?? 1,
132
+ onMouseUp: d,
133
+ disabled: u,
134
+ min: e.min ?? 0,
135
+ max: e.max ?? 100,
136
+ step: e.step ?? 1,
104
137
  size: "small",
105
138
  sx: { flex: 1 }
106
139
  }
107
140
  ),
108
- /* @__PURE__ */ e.jsx(
109
- n,
141
+ /* @__PURE__ */ o.jsx(
142
+ r,
110
143
  {
111
144
  sx: {
112
145
  minWidth: 60,
113
146
  textAlign: "center",
114
147
  fontWeight: 500,
115
148
  fontSize: "0.875rem",
116
- width: t ? "auto" : "100%"
149
+ width: l ? "auto" : "100%"
117
150
  },
118
- children: c ?? o.defaultValue ?? o.min ?? 0
151
+ children: a ?? e.defaultValue ?? e.min ?? 0
119
152
  }
120
153
  )
121
154
  ] })
122
155
  ]
123
156
  }
124
- )), pe = I.memo(({ input: o, value: c, onChange: m, disabled: t }) => {
125
- const f = I.useRef(null), [x, h] = I.useState([]), [g, v] = I.useState(null), w = o.multiple ?? !1, b = o.maxImages ?? 5;
126
- oe(() => {
127
- let d = [];
128
- return h(((l) => {
129
- if (!l) return [];
130
- const p = Array.isArray(l) ? l : [l], a = [];
131
- return p.forEach((C) => {
132
- if (C instanceof File) {
133
- const S = URL.createObjectURL(C);
134
- a.push(S), d.push(S);
135
- } else typeof C == "string" && a.push(C);
136
- }), a;
137
- })(c)), () => {
138
- d.forEach((l) => URL.revokeObjectURL(l));
157
+ )), ke = b.memo(({ input: e, value: a, onChange: c, disabled: l }) => {
158
+ const f = b.useRef(null), [d, u] = b.useState([]), [h, I] = b.useState(null), j = e.multiple ?? !1, k = e.maxImages ?? 5;
159
+ le(() => {
160
+ let m = [];
161
+ return u(((s) => {
162
+ if (!s) return [];
163
+ const v = Array.isArray(s) ? s : [s], i = [];
164
+ return v.forEach((V) => {
165
+ if (V instanceof File) {
166
+ const B = URL.createObjectURL(V);
167
+ i.push(B), m.push(B);
168
+ } else typeof V == "string" && i.push(V);
169
+ }), i;
170
+ })(a)), () => {
171
+ m.forEach((s) => URL.revokeObjectURL(s));
139
172
  };
140
- }, [c]);
141
- const u = (d) => {
142
- const i = d.target.files;
143
- if (!(!i || i.length === 0)) {
144
- if (w) {
145
- const l = Array.isArray(c) ? c : c ? [c] : [], p = Array.from(i).slice(0, b - l.length), a = [...l, ...p];
146
- m(a);
173
+ }, [a]);
174
+ const x = (m) => {
175
+ const p = m.target.files;
176
+ if (!(!p || p.length === 0)) {
177
+ if (j) {
178
+ const s = Array.isArray(a) ? a : a instanceof File || typeof a == "string" ? [a] : [], v = Array.from(p).slice(0, k - s.length), i = [...s, ...v];
179
+ c(i);
147
180
  } else
148
- m(i[0]);
149
- d.target.value = "";
181
+ c(p[0]);
182
+ m.target.value = "";
150
183
  }
151
- }, O = (d, i) => {
152
- if (d.stopPropagation(), w && Array.isArray(c)) {
153
- const l = c.filter((p, a) => a !== i);
154
- m(l.length > 0 ? l : null);
184
+ }, M = (m, p) => {
185
+ if (m.stopPropagation(), j && Array.isArray(a)) {
186
+ const s = a.filter((v, i) => i !== p);
187
+ c(s.length > 0 ? s : null);
155
188
  } else
156
- m(null);
157
- }, T = () => {
158
- var d;
159
- t || w && x.length >= b || (d = f.current) == null || d.click();
160
- }, E = w && x.length < b;
161
- return /* @__PURE__ */ e.jsxs(n, { sx: { display: "flex", alignItems: "center", gap: 0.75 }, children: [
162
- /* @__PURE__ */ e.jsx(
189
+ c(null);
190
+ }, z = () => {
191
+ var m;
192
+ l || j && d.length >= k || (m = f.current) == null || m.click();
193
+ }, D = j && d.length < k;
194
+ return /* @__PURE__ */ o.jsxs(r, { sx: { display: "flex", alignItems: "center", gap: 0.75 }, children: [
195
+ /* @__PURE__ */ o.jsx(
163
196
  "input",
164
197
  {
165
198
  ref: f,
166
199
  type: "file",
167
200
  accept: "image/*",
168
- multiple: w,
169
- onChange: u,
170
- disabled: t,
201
+ multiple: j,
202
+ onChange: x,
203
+ disabled: l,
171
204
  style: { display: "none" }
172
205
  }
173
206
  ),
174
- x.map((d, i) => /* @__PURE__ */ e.jsxs(
175
- n,
207
+ d.map((m, p) => /* @__PURE__ */ o.jsxs(
208
+ r,
176
209
  {
177
- onMouseEnter: () => v(i),
178
- onMouseLeave: () => v(null),
210
+ onMouseEnter: () => I(p),
211
+ onMouseLeave: () => I(null),
179
212
  sx: {
180
213
  width: 50,
181
214
  height: 50,
182
215
  border: 1,
183
- borderColor: t ? "action.disabled" : "primary.main",
216
+ borderColor: l ? "action.disabled" : "primary.main",
184
217
  borderRadius: 1,
185
218
  display: "flex",
186
219
  alignItems: "center",
187
220
  justifyContent: "center",
188
- cursor: t ? "not-allowed" : "default",
221
+ cursor: l ? "not-allowed" : "default",
189
222
  position: "relative",
190
223
  overflow: "hidden",
191
224
  transition: "all 0.2s",
192
- "&:hover": t ? {} : {
225
+ "&:hover": l ? {} : {
193
226
  borderColor: "primary.dark"
194
227
  }
195
228
  },
196
229
  children: [
197
- /* @__PURE__ */ e.jsx(
198
- n,
230
+ /* @__PURE__ */ o.jsx(
231
+ r,
199
232
  {
200
233
  component: "img",
201
- src: d,
202
- alt: `Preview ${i + 1}`,
234
+ src: m,
235
+ alt: `Preview ${p + 1}`,
203
236
  sx: {
204
237
  width: "100%",
205
238
  height: "100%",
@@ -207,10 +240,10 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
207
240
  }
208
241
  }
209
242
  ),
210
- !t && g === i && /* @__PURE__ */ e.jsx(
211
- n,
243
+ !l && h === p && /* @__PURE__ */ o.jsx(
244
+ r,
212
245
  {
213
- onClick: (l) => O(l, i),
246
+ onClick: (s) => M(s, p),
214
247
  sx: {
215
248
  position: "absolute",
216
249
  top: 0,
@@ -220,15 +253,15 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
220
253
  display: "flex",
221
254
  alignItems: "center",
222
255
  justifyContent: "center",
223
- bgcolor: z("#000", 0.5),
256
+ bgcolor: R("#000", 0.5),
224
257
  cursor: "pointer",
225
258
  transition: "background-color 0.2s",
226
259
  "&:hover": {
227
- bgcolor: z("#000", 0.65)
260
+ bgcolor: R("#000", 0.65)
228
261
  }
229
262
  },
230
- children: /* @__PURE__ */ e.jsx(
231
- se,
263
+ children: /* @__PURE__ */ o.jsx(
264
+ ae,
232
265
  {
233
266
  sx: {
234
267
  fontSize: 16,
@@ -240,114 +273,142 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
240
273
  )
241
274
  ]
242
275
  },
243
- i
276
+ p
244
277
  )),
245
- (x.length === 0 || E) && /* @__PURE__ */ e.jsx(
246
- n,
278
+ (d.length === 0 || D) && /* @__PURE__ */ o.jsx(
279
+ r,
247
280
  {
248
- onClick: T,
281
+ onClick: z,
249
282
  sx: {
250
283
  width: 50,
251
284
  height: 50,
252
285
  border: 1,
253
- borderColor: t ? "action.disabled" : "divider",
286
+ borderColor: l ? "action.disabled" : "divider",
254
287
  borderRadius: 1,
255
288
  display: "flex",
256
289
  alignItems: "center",
257
290
  justifyContent: "center",
258
- cursor: t ? "not-allowed" : "pointer",
259
- bgcolor: z("#000", 0.02),
291
+ cursor: l ? "not-allowed" : "pointer",
292
+ bgcolor: R("#000", 0.02),
260
293
  transition: "all 0.2s",
261
- "&:hover": t ? {} : {
294
+ "&:hover": l ? {} : {
262
295
  borderColor: "primary.main",
263
- bgcolor: z("#000", 0.04)
296
+ bgcolor: R("#000", 0.04)
264
297
  }
265
298
  },
266
- children: /* @__PURE__ */ e.jsx(
267
- he,
299
+ children: /* @__PURE__ */ o.jsx(
300
+ xe,
268
301
  {
269
302
  sx: {
270
303
  fontSize: 20,
271
- color: t ? "action.disabled" : "text.secondary"
304
+ color: l ? "action.disabled" : "text.secondary"
272
305
  }
273
306
  }
274
307
  )
275
308
  }
276
309
  )
277
310
  ] });
278
- }), H = (o) => {
279
- switch (o.input.type) {
311
+ }), Ve = b.memo(({ input: e, value: a, onChange: c, onFocus: l, onBlur: f, disabled: d }) => /* @__PURE__ */ o.jsxs(
312
+ r,
313
+ {
314
+ sx: {
315
+ display: "flex",
316
+ flexDirection: "column",
317
+ alignItems: "center",
318
+ minWidth: 60
319
+ },
320
+ children: [
321
+ /* @__PURE__ */ o.jsx(F, { label: e.label }),
322
+ /* @__PURE__ */ o.jsx(
323
+ de,
324
+ {
325
+ checked: a ?? e.defaultValue ?? !1,
326
+ onChange: (u) => c(u.target.checked),
327
+ onFocus: l,
328
+ onBlur: f,
329
+ disabled: d,
330
+ size: "small"
331
+ }
332
+ )
333
+ ]
334
+ }
335
+ )), O = (e) => {
336
+ switch (e.input.type) {
280
337
  case "textarea":
281
- return /* @__PURE__ */ e.jsx(ye, { ...o });
338
+ return /* @__PURE__ */ o.jsx(ve, { ...e });
282
339
  case "number":
283
- return /* @__PURE__ */ e.jsx(je, { ...o });
340
+ return /* @__PURE__ */ o.jsx(je, { ...e });
284
341
  case "slider":
285
- return /* @__PURE__ */ e.jsx(ge, { ...o });
342
+ return /* @__PURE__ */ o.jsx(Ie, { ...e });
343
+ case "select":
344
+ return /* @__PURE__ */ o.jsx(we, { ...e });
286
345
  case "image":
287
- return /* @__PURE__ */ e.jsx(pe, { input: o.input, value: o.value, onChange: o.onChange, disabled: o.disabled });
346
+ return /* @__PURE__ */ o.jsx(ke, { input: e.input, value: e.value, onChange: e.onChange, disabled: e.disabled });
347
+ case "checkbox":
348
+ return /* @__PURE__ */ o.jsx(Ve, { ...e });
288
349
  default:
289
350
  return null;
290
351
  }
291
- }, Re = ({
292
- inputs: o = [],
293
- onProcess: c,
294
- onReset: m,
295
- onDownload: t,
352
+ }, U = ({
353
+ inputs: e = [],
354
+ onProcess: a,
355
+ onReset: c,
356
+ onDownload: l,
296
357
  processing: f = !1,
297
- uploading: x = !1,
298
- inputValues: h = {},
299
- onInputChange: g,
300
- customActionButtons: v,
301
- hideProcessButton: w = !1,
302
- processButtonDisabled: b = !1,
303
- getInputDisabled: u,
304
- processTooltip: O = "Process",
305
- downloadTooltip: T = "Download",
306
- resetTooltip: E = "Reset",
307
- infoTooltip: d = "Information",
308
- infoTitle: i = "Tool Information",
309
- infoContent: l,
310
- position: p = "bottom",
311
- relative: a = !1
358
+ uploading: d = !1,
359
+ inputValues: u = {},
360
+ onInputChange: h,
361
+ customActionButtons: I,
362
+ hideProcessButton: j = !1,
363
+ processButtonDisabled: k = !1,
364
+ getInputDisabled: x,
365
+ processTooltip: M = "Process",
366
+ downloadTooltip: z = "Download",
367
+ resetTooltip: D = "Reset",
368
+ infoTooltip: m = "Information",
369
+ infoTitle: p = "Tool Information",
370
+ infoContent: s,
371
+ position: v = "bottom",
372
+ relative: i = !1
312
373
  }) => {
313
- const [C, S] = W(!1), [K, _] = W(!1), [Q, q] = W(!1), A = C || K, N = D(() => o.length === 0 ? !0 : o.every((r) => {
314
- if (!r.required) return !0;
315
- const s = h[r.key];
316
- return r.type === "textarea" ? s && typeof s == "string" && s.trim() !== "" : r.type === "number" || r.type === "slider" ? s != null : !0;
317
- }), [o, h]), { imageInputs: U, textareaInputs: X, paramInputs: V } = D(() => o.reduce(
318
- (r, s) => (s.type === "image" ? r.imageInputs.push(s) : s.type === "textarea" ? r.textareaInputs.push(s) : r.paramInputs.push(s), r),
374
+ const [V, B] = N(!1), [Y, H] = N(!1), [Z, K] = N(!1), C = V || Y, X = J(() => e.length === 0 ? !0 : e.every((t) => {
375
+ if (!t.required) return !0;
376
+ const n = u[t.key];
377
+ return t.type === "textarea" ? n && typeof n == "string" && n.trim() !== "" : t.type === "number" || t.type === "slider" ? n != null : t.type === "select" ? n != null && n !== "" : !0;
378
+ }), [e, u]), { imageInputs: E, textareaInputs: G, paramInputs: L } = J(() => e.reduce(
379
+ (t, n) => (n.type === "image" ? t.imageInputs.push(n) : n.type === "textarea" ? t.textareaInputs.push(n) : t.paramInputs.push(n), t),
319
380
  {
320
381
  imageInputs: [],
321
382
  textareaInputs: [],
322
383
  paramInputs: []
323
384
  }
324
- ), [o]), Y = k(() => S(!0), []), Z = k(() => S(!1), []), R = k(() => _(!0), []), F = k(() => {
325
- setTimeout(() => _(!1), 200);
326
- }, []), M = k(
327
- (r, s, j) => {
328
- g == null || g(r, s, j);
385
+ ), [e]), ee = w(() => B(!0), []), oe = w(() => B(!1), []), T = w(() => H(!0), []), q = w(() => {
386
+ setTimeout(() => H(!1), 200);
387
+ }, []), A = w(
388
+ (t, n, g) => {
389
+ h == null || h(t, n, g);
329
390
  },
330
- [g]
331
- ), ee = k(() => q(!0), []), re = k(() => q(!1), []), $ = /* @__PURE__ */ e.jsxs(
332
- n,
391
+ [h]
392
+ ), te = w(() => K(!0), []), ne = w(() => K(!1), []), $ = /* @__PURE__ */ o.jsxs(
393
+ r,
333
394
  {
334
395
  sx: {
335
- position: a ? "relative" : "fixed",
336
- [p]: a ? "auto" : 20,
337
- left: a ? "auto" : "50%",
338
- transform: a ? "none" : "translateX(-50%)",
339
- zIndex: a ? "auto" : 1300,
340
- display: a ? "flex" : "block",
341
- justifyContent: a ? "center" : "initial",
342
- mt: a && p === "top" ? 2 : 0,
343
- mb: a && p === "bottom" ? 2 : 0
396
+ position: i ? "relative" : "fixed",
397
+ [v]: i ? "auto" : 20,
398
+ left: i ? "auto" : "50%",
399
+ transform: i ? "none" : "translateX(-50%)",
400
+ zIndex: i ? "auto" : 1300,
401
+ display: i ? "flex" : "block",
402
+ justifyContent: i ? "center" : "initial",
403
+ mt: i && v === "top" ? 2 : 0,
404
+ mb: i && v === "bottom" ? 2 : 0
344
405
  },
345
406
  children: [
346
- /* @__PURE__ */ e.jsxs(
347
- n,
407
+ /* @__PURE__ */ o.jsxs(
408
+ r,
348
409
  {
349
- onMouseEnter: Y,
350
- onMouseLeave: Z,
410
+ onMouseEnter: ee,
411
+ onMouseLeave: oe,
351
412
  sx: {
352
413
  display: "flex",
353
414
  flexDirection: "column",
@@ -355,35 +416,36 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
355
416
  p: 2,
356
417
  borderRadius: 2,
357
418
  border: 1,
358
- borderColor: "divider"
419
+ borderColor: "divider",
420
+ bgcolor: "background.default"
359
421
  },
360
422
  children: [
361
- X.length > 0 && /* @__PURE__ */ e.jsx(n, { sx: { display: "flex", flexDirection: "column", gap: 2 }, children: X.map((r) => {
362
- const s = h[r.key], j = (u == null ? void 0 : u(r.key)) ?? !1;
363
- return r.renderInput ? /* @__PURE__ */ e.jsx(n, { children: r.renderInput({
364
- value: s,
365
- onChange: (y) => M(r.key, y),
366
- isExpanded: A,
367
- onFocus: R,
368
- onBlur: F,
369
- disabled: j
370
- }) }, r.key) : /* @__PURE__ */ e.jsx(
371
- H,
423
+ G.length > 0 && /* @__PURE__ */ o.jsx(r, { sx: { display: "flex", flexDirection: "column", gap: 2 }, children: G.map((t) => {
424
+ const n = u[t.key], g = (x == null ? void 0 : x(t.key)) ?? !1;
425
+ return t.renderInput ? /* @__PURE__ */ o.jsx(r, { children: t.renderInput({
426
+ value: n,
427
+ onChange: (y) => A(t.key, y),
428
+ isExpanded: C,
429
+ onFocus: T,
430
+ onBlur: q,
431
+ disabled: g
432
+ }) }, t.key) : /* @__PURE__ */ o.jsx(
433
+ O,
372
434
  {
373
- input: r,
374
- value: s,
375
- onChange: (y) => M(r.key, y),
376
- isExpanded: A,
377
- onFocus: R,
378
- onBlur: F,
379
- disabled: j
435
+ input: t,
436
+ value: n,
437
+ onChange: (y) => A(t.key, y),
438
+ isExpanded: C,
439
+ onFocus: T,
440
+ onBlur: q,
441
+ disabled: g
380
442
  },
381
- r.key
443
+ t.key
382
444
  );
383
445
  }) }),
384
- /* @__PURE__ */ e.jsxs(n, { sx: { display: "flex", alignItems: "center", gap: 0.5 }, children: [
385
- /* @__PURE__ */ e.jsx(
386
- n,
446
+ /* @__PURE__ */ o.jsxs(r, { sx: { display: "flex", alignItems: "center", gap: 0.5 }, children: [
447
+ /* @__PURE__ */ o.jsx(
448
+ r,
387
449
  {
388
450
  sx: {
389
451
  display: "flex",
@@ -391,72 +453,72 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
391
453
  gap: 2,
392
454
  flex: 1
393
455
  },
394
- children: (U.length > 0 || V.length > 0) && /* @__PURE__ */ e.jsxs(n, { sx: { display: "flex", alignItems: "flex-end", gap: 1.5 }, children: [
395
- U.map((r) => {
396
- const s = h[r.key], j = (u == null ? void 0 : u(r.key)) ?? !1;
397
- return r.renderInput ? /* @__PURE__ */ e.jsx(n, { children: r.renderInput({
398
- value: s,
399
- onChange: (y) => M(r.key, y),
400
- isExpanded: A,
401
- onFocus: R,
402
- onBlur: F,
403
- disabled: j
404
- }) }, r.key) : /* @__PURE__ */ e.jsx(
405
- H,
456
+ children: (E.length > 0 || L.length > 0) && /* @__PURE__ */ o.jsxs(r, { sx: { display: "flex", alignItems: "flex-end", gap: 1.5 }, children: [
457
+ E.map((t) => {
458
+ const n = u[t.key], g = (x == null ? void 0 : x(t.key)) ?? !1;
459
+ return t.renderInput ? /* @__PURE__ */ o.jsx(r, { children: t.renderInput({
460
+ value: n,
461
+ onChange: (y) => A(t.key, y),
462
+ isExpanded: C,
463
+ onFocus: T,
464
+ onBlur: q,
465
+ disabled: g
466
+ }) }, t.key) : /* @__PURE__ */ o.jsx(
467
+ O,
406
468
  {
407
- input: r,
408
- value: s,
409
- onChange: (y) => M(r.key, y),
410
- isExpanded: A,
411
- onFocus: R,
412
- onBlur: F,
413
- disabled: j
469
+ input: t,
470
+ value: n,
471
+ onChange: (y) => A(t.key, y),
472
+ isExpanded: C,
473
+ onFocus: T,
474
+ onBlur: q,
475
+ disabled: g
414
476
  },
415
- r.key
477
+ t.key
416
478
  );
417
479
  }),
418
- V.map((r) => {
419
- const s = h[r.key], j = (u == null ? void 0 : u(r.key)) ?? !1;
420
- return r.renderInput ? /* @__PURE__ */ e.jsx(n, { children: r.renderInput({
421
- value: s,
422
- onChange: (y) => M(r.key, y),
423
- isExpanded: A,
424
- onFocus: R,
425
- onBlur: F,
426
- disabled: j
427
- }) }, r.key) : /* @__PURE__ */ e.jsx(
428
- H,
480
+ L.map((t) => {
481
+ const n = u[t.key], g = (x == null ? void 0 : x(t.key)) ?? !1;
482
+ return t.renderInput ? /* @__PURE__ */ o.jsx(r, { children: t.renderInput({
483
+ value: n,
484
+ onChange: (y) => A(t.key, y),
485
+ isExpanded: C,
486
+ onFocus: T,
487
+ onBlur: q,
488
+ disabled: g
489
+ }) }, t.key) : /* @__PURE__ */ o.jsx(
490
+ O,
429
491
  {
430
- input: r,
431
- value: s,
432
- onChange: (y) => M(r.key, y),
433
- isExpanded: A,
434
- onFocus: R,
435
- onBlur: F,
436
- disabled: j
492
+ input: t,
493
+ value: n,
494
+ onChange: (y) => A(t.key, y),
495
+ isExpanded: C,
496
+ onFocus: T,
497
+ onBlur: q,
498
+ disabled: g
437
499
  },
438
- r.key
500
+ t.key
439
501
  );
440
502
  })
441
503
  ] })
442
504
  }
443
505
  ),
444
- (U.length > 0 || V.length > 0) && /* @__PURE__ */ e.jsx(ae, { orientation: "vertical", flexItem: !0, sx: { mx: 0.5, flexShrink: 0 } }),
445
- /* @__PURE__ */ e.jsxs(n, { sx: { display: "flex", alignItems: "center", gap: 0.75, ml: "auto" }, children: [
446
- v,
447
- l && /* @__PURE__ */ e.jsx(B, { title: d, children: /* @__PURE__ */ e.jsx(P, { onClick: ee, children: /* @__PURE__ */ e.jsx(fe, {}) }) }),
448
- /* @__PURE__ */ e.jsx(B, { title: T, children: /* @__PURE__ */ e.jsx(P, { onClick: t, children: /* @__PURE__ */ e.jsx(te, {}) }) }),
449
- /* @__PURE__ */ e.jsx(B, { title: E, children: /* @__PURE__ */ e.jsx(P, { onClick: m, children: /* @__PURE__ */ e.jsx(me, {}) }) }),
450
- !w && /* @__PURE__ */ e.jsx(B, { title: O, children: /* @__PURE__ */ e.jsx("span", { children: /* @__PURE__ */ e.jsx(
451
- P,
506
+ (E.length > 0 || L.length > 0) && /* @__PURE__ */ o.jsx(ue, { orientation: "vertical", flexItem: !0, sx: { mx: 0.5, flexShrink: 0 } }),
507
+ /* @__PURE__ */ o.jsxs(r, { sx: { display: "flex", alignItems: "center", gap: 0.75, ml: "auto" }, children: [
508
+ I,
509
+ s && /* @__PURE__ */ o.jsx(_, { title: m, children: /* @__PURE__ */ o.jsx(S, { onClick: te, children: /* @__PURE__ */ o.jsx(ge, {}) }) }),
510
+ /* @__PURE__ */ o.jsx(_, { title: z, children: /* @__PURE__ */ o.jsx(S, { onClick: l, children: /* @__PURE__ */ o.jsx(re, {}) }) }),
511
+ /* @__PURE__ */ o.jsx(_, { title: D, children: /* @__PURE__ */ o.jsx(S, { onClick: c, children: /* @__PURE__ */ o.jsx(ye, {}) }) }),
512
+ !j && /* @__PURE__ */ o.jsx(_, { title: M, children: /* @__PURE__ */ o.jsx("span", { children: /* @__PURE__ */ o.jsx(
513
+ S,
452
514
  {
453
- onClick: c,
454
- disabled: b || !N || x || f,
515
+ onClick: a,
516
+ disabled: k || !X || d || f,
455
517
  size: "large",
456
- children: /* @__PURE__ */ e.jsx(
457
- ue,
518
+ children: /* @__PURE__ */ o.jsx(
519
+ be,
458
520
  {
459
- color: b || !N || x || f ? "disabled" : "primary"
521
+ color: k || !X || d || f ? "disabled" : "primary"
460
522
  }
461
523
  )
462
524
  }
@@ -466,15 +528,34 @@ const he = L(/* @__PURE__ */ e.jsx("path", {
466
528
  ]
467
529
  }
468
530
  ),
469
- l && /* @__PURE__ */ e.jsxs(ce, { open: Q, onClose: re, maxWidth: "sm", fullWidth: !0, children: [
470
- /* @__PURE__ */ e.jsx(ie, { children: i }),
471
- /* @__PURE__ */ e.jsx(de, { children: l })
531
+ s && /* @__PURE__ */ o.jsxs(ce, { open: Z, onClose: ne, maxWidth: "sm", fullWidth: !0, children: [
532
+ /* @__PURE__ */ o.jsx(fe, { children: p }),
533
+ /* @__PURE__ */ o.jsx(pe, { children: s })
472
534
  ] })
473
535
  ]
474
536
  }
475
537
  );
476
- return !a && typeof window < "u" ? xe($, document.body) : $;
538
+ return !i && typeof window < "u" ? me($, document.body) : $;
477
539
  };
540
+ U.displayName = "SAiToolBar";
541
+ try {
542
+ W.displayName = "SAiToolBarInputType", W.__docgenInfo = { description: "Supported input types for SAiToolBar", displayName: "SAiToolBarInputType", props: {} };
543
+ } catch {
544
+ }
545
+ try {
546
+ U.displayName = "SAiToolBar", U.__docgenInfo = { description: `A dynamic floating toolbar for AI tools with expandable inputs and action buttons.
547
+ Features smooth expand/collapse animations, multiple input types, built-in validation,
548
+ and portal rendering for proper z-index handling.`, displayName: "SAiToolBar", props: { inputs: { defaultValue: { value: "[]" }, description: "Configuration for input fields", name: "inputs", required: !1, type: { name: "SAiToolBarInput[]" } }, onProcess: { defaultValue: null, description: "Callback when process button is clicked", name: "onProcess", required: !1, type: { name: "(() => void)" } }, onReset: { defaultValue: null, description: "Callback when reset button is clicked", name: "onReset", required: !1, type: { name: "(() => void)" } }, onDownload: { defaultValue: null, description: "Callback when download button is clicked", name: "onDownload", required: !1, type: { name: "(() => void)" } }, processing: { defaultValue: { value: "false" }, description: "Whether the toolbar is in processing state", name: "processing", required: !1, type: { name: "boolean" } }, uploading: { defaultValue: { value: "false" }, description: "Whether the toolbar is in uploading state", name: "uploading", required: !1, type: { name: "boolean" } }, inputValues: { defaultValue: { value: "{}" }, description: "Input values controlled externally", name: "inputValues", required: !1, type: { name: "Record<string, SAiToolBarValue>" } }, onInputChange: { defaultValue: null, description: "Callback when input values change", name: "onInputChange", required: !1, type: { name: "((key: string, value: SAiToolBarValue, file?: File) => void)" } }, customActionButtons: { defaultValue: null, description: "Custom action buttons between inputs and standard actions", name: "customActionButtons", required: !1, type: { name: "ReactNode" } }, hideProcessButton: { defaultValue: { value: "false" }, description: "Hide the main process button", name: "hideProcessButton", required: !1, type: { name: "boolean" } }, processButtonDisabled: { defaultValue: { value: "false" }, description: "Override to disable the process button", name: "processButtonDisabled", required: !1, type: { name: "boolean" } }, getInputDisabled: { defaultValue: null, description: "Function to check if an input should be disabled", name: "getInputDisabled", required: !1, type: { name: "((inputKey: string) => boolean)" } }, processTooltip: { defaultValue: { value: "Process" }, description: "Tooltip for process button", name: "processTooltip", required: !1, type: { name: "string" } }, downloadTooltip: { defaultValue: { value: "Download" }, description: "Tooltip for download button", name: "downloadTooltip", required: !1, type: { name: "string" } }, resetTooltip: { defaultValue: { value: "Reset" }, description: "Tooltip for reset button", name: "resetTooltip", required: !1, type: { name: "string" } }, infoTooltip: { defaultValue: { value: "Information" }, description: "Tooltip for info button", name: "infoTooltip", required: !1, type: { name: "string" } }, infoTitle: { defaultValue: { value: "Tool Information" }, description: "Info dialog title", name: "infoTitle", required: !1, type: { name: "string" } }, infoContent: { defaultValue: null, description: "Info dialog content", name: "infoContent", required: !1, type: { name: "ReactNode" } }, position: { defaultValue: { value: "bottom" }, description: "Position of the toolbar", name: "position", required: !1, type: { name: "enum", value: [{ value: '"top"' }, { value: '"bottom"' }] } }, relative: { defaultValue: { value: "false" }, description: "Use relative positioning within container instead of fixed viewport positioning", name: "relative", required: !1, type: { name: "boolean" } } } };
549
+ } catch {
550
+ }
551
+ try {
552
+ saitoolbar.displayName = "saitoolbar", saitoolbar.__docgenInfo = { description: `A dynamic floating toolbar for AI tools with expandable inputs and action buttons.
553
+ Features smooth expand/collapse animations, multiple input types, built-in validation,
554
+ and portal rendering for proper z-index handling.`, displayName: "saitoolbar", props: { inputs: { defaultValue: { value: "[]" }, description: "Configuration for input fields", name: "inputs", required: !1, type: { name: "SAiToolBarInput[]" } }, onProcess: { defaultValue: null, description: "Callback when process button is clicked", name: "onProcess", required: !1, type: { name: "(() => void)" } }, onReset: { defaultValue: null, description: "Callback when reset button is clicked", name: "onReset", required: !1, type: { name: "(() => void)" } }, onDownload: { defaultValue: null, description: "Callback when download button is clicked", name: "onDownload", required: !1, type: { name: "(() => void)" } }, processing: { defaultValue: { value: "false" }, description: "Whether the toolbar is in processing state", name: "processing", required: !1, type: { name: "boolean" } }, uploading: { defaultValue: { value: "false" }, description: "Whether the toolbar is in uploading state", name: "uploading", required: !1, type: { name: "boolean" } }, inputValues: { defaultValue: { value: "{}" }, description: "Input values controlled externally", name: "inputValues", required: !1, type: { name: "Record<string, SAiToolBarValue>" } }, onInputChange: { defaultValue: null, description: "Callback when input values change", name: "onInputChange", required: !1, type: { name: "((key: string, value: SAiToolBarValue, file?: File) => void)" } }, customActionButtons: { defaultValue: null, description: "Custom action buttons between inputs and standard actions", name: "customActionButtons", required: !1, type: { name: "ReactNode" } }, hideProcessButton: { defaultValue: { value: "false" }, description: "Hide the main process button", name: "hideProcessButton", required: !1, type: { name: "boolean" } }, processButtonDisabled: { defaultValue: { value: "false" }, description: "Override to disable the process button", name: "processButtonDisabled", required: !1, type: { name: "boolean" } }, getInputDisabled: { defaultValue: null, description: "Function to check if an input should be disabled", name: "getInputDisabled", required: !1, type: { name: "((inputKey: string) => boolean)" } }, processTooltip: { defaultValue: { value: "Process" }, description: "Tooltip for process button", name: "processTooltip", required: !1, type: { name: "string" } }, downloadTooltip: { defaultValue: { value: "Download" }, description: "Tooltip for download button", name: "downloadTooltip", required: !1, type: { name: "string" } }, resetTooltip: { defaultValue: { value: "Reset" }, description: "Tooltip for reset button", name: "resetTooltip", required: !1, type: { name: "string" } }, infoTooltip: { defaultValue: { value: "Information" }, description: "Tooltip for info button", name: "infoTooltip", required: !1, type: { name: "string" } }, infoTitle: { defaultValue: { value: "Tool Information" }, description: "Info dialog title", name: "infoTitle", required: !1, type: { name: "string" } }, infoContent: { defaultValue: null, description: "Info dialog content", name: "infoContent", required: !1, type: { name: "ReactNode" } }, position: { defaultValue: { value: "bottom" }, description: "Position of the toolbar", name: "position", required: !1, type: { name: "enum", value: [{ value: '"top"' }, { value: '"bottom"' }] } }, relative: { defaultValue: { value: "false" }, description: "Use relative positioning within container instead of fixed viewport positioning", name: "relative", required: !1, type: { name: "boolean" } } } };
555
+ } catch {
556
+ }
478
557
  export {
479
- Re as default
558
+ U as SAiToolBar,
559
+ W as SAiToolBarInputType,
560
+ U as default
480
561
  };