@js-empire/emperor-ui 1.3.11 → 1.3.12

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 (585) hide show
  1. package/.cursor/rules/code-conventions.mdc +50 -0
  2. package/.husky/pre-commit +4 -0
  3. package/.prettierrc +10 -0
  4. package/.storybook/main.ts +24 -0
  5. package/.storybook/preview.ts +19 -0
  6. package/.storybook/vitest.setup.ts +7 -0
  7. package/.vscode/extensions.json +1 -0
  8. package/dist/emperor-ui.js +158 -4236
  9. package/dist/emperor-ui.umd.cjs +52 -1
  10. package/dist/icons/emperor-ui-logo.ico +0 -0
  11. package/dist/images/avatar-female.jpg +0 -0
  12. package/dist/images/avatar-male.jpg +0 -0
  13. package/dist/images/emperor-ui-logo.png +0 -0
  14. package/dist/index-4OxAyqvp.js +5 -0
  15. package/dist/index-CHrqdTZ9.js +290 -0
  16. package/dist/index-DXWNWGH3.js +57021 -0
  17. package/dist/index.d.ts +1357 -0
  18. package/dist/src-UW24ZMRV-DQtCWsbT.js +5 -0
  19. package/eslint.config.js +34 -0
  20. package/index.html +13 -0
  21. package/package.json +10 -57
  22. package/public/icons/emperor-ui-logo.ico +0 -0
  23. package/public/images/avatar-female.jpg +0 -0
  24. package/public/images/avatar-male.jpg +0 -0
  25. package/public/images/emperor-ui-logo.png +0 -0
  26. package/src/animations/blink.ts +26 -0
  27. package/src/animations/floating.ts +12 -0
  28. package/src/animations/index.ts +2 -0
  29. package/src/components/atoms/brand/brand.stories.tsx +29 -0
  30. package/src/components/atoms/brand/brand.tsx +56 -0
  31. package/src/components/atoms/brand/index.ts +1 -0
  32. package/src/components/atoms/brand/styles/classes.ts +9 -0
  33. package/src/components/atoms/brand/styles/index.ts +2 -0
  34. package/src/components/atoms/brand/styles/styles.ts +0 -0
  35. package/src/components/atoms/color-picker/color-picker.tsx +12 -0
  36. package/src/components/atoms/color-picker/free-color-picker.tsx +58 -0
  37. package/src/components/atoms/color-picker/index.ts +3 -0
  38. package/src/components/atoms/color-picker/preset-color-picker.tsx +66 -0
  39. package/src/components/atoms/color-picker/stories/color-picker.stories.tsx +63 -0
  40. package/src/components/atoms/column/column.stories.tsx +37 -0
  41. package/src/components/atoms/column/column.tsx +21 -0
  42. package/src/components/atoms/column/index.ts +1 -0
  43. package/src/components/atoms/container/column.stories.tsx +37 -0
  44. package/src/components/atoms/container/container.tsx +28 -0
  45. package/src/components/atoms/container/index.ts +1 -0
  46. package/src/components/atoms/copy-button/copy-button.tsx +73 -0
  47. package/src/components/atoms/copy-button/index.ts +1 -0
  48. package/src/components/atoms/copy-button/stories/copy-button.stories.tsx +21 -0
  49. package/src/components/atoms/field/field.tsx +81 -0
  50. package/src/components/atoms/field/index.ts +3 -0
  51. package/src/components/atoms/field/styles/classes.ts +9 -0
  52. package/src/components/atoms/field/styles/index.ts +1 -0
  53. package/src/components/atoms/field/units/autocomplete-field.tsx +49 -0
  54. package/src/components/atoms/field/units/checkbox-field.tsx +35 -0
  55. package/src/components/atoms/field/units/index.ts +7 -0
  56. package/src/components/atoms/field/units/input-field.tsx +35 -0
  57. package/src/components/atoms/field/units/radio-field.tsx +43 -0
  58. package/src/components/atoms/field/units/select-field.tsx +50 -0
  59. package/src/components/atoms/field/units/switch-field.tsx +35 -0
  60. package/src/components/atoms/field/units/textarea-field.tsx +37 -0
  61. package/src/components/atoms/filter/filter.tsx +93 -0
  62. package/src/components/atoms/filter/index.ts +3 -0
  63. package/src/components/atoms/filter/stories/filter.stories.tsx +238 -0
  64. package/src/components/atoms/filter/styles/classes.ts +20 -0
  65. package/src/components/atoms/filter/styles/index.ts +1 -0
  66. package/src/components/atoms/filter/units/autocomplete-filter.tsx +66 -0
  67. package/src/components/atoms/filter/units/checkbox-filter.tsx +42 -0
  68. package/src/components/atoms/filter/units/checkbox-group-filter.tsx +68 -0
  69. package/src/components/atoms/filter/units/date-filter.tsx +46 -0
  70. package/src/components/atoms/filter/units/index.ts +9 -0
  71. package/src/components/atoms/filter/units/numeric-filter.tsx +41 -0
  72. package/src/components/atoms/filter/units/range-filter.tsx +65 -0
  73. package/src/components/atoms/filter/units/search-filter.tsx +53 -0
  74. package/src/components/atoms/filter/units/select-filter.tsx +57 -0
  75. package/src/components/atoms/filter/units/switch-filter.tsx +35 -0
  76. package/src/components/atoms/index.ts +11 -0
  77. package/src/components/atoms/portal/index.ts +1 -0
  78. package/src/components/atoms/portal/portal.stories.tsx +43 -0
  79. package/src/components/atoms/portal/portal.tsx +25 -0
  80. package/src/components/atoms/row/index.ts +1 -0
  81. package/src/components/atoms/row/row.stories.tsx +37 -0
  82. package/src/components/atoms/row/row.tsx +26 -0
  83. package/src/components/atoms/theme-switch/index.ts +1 -0
  84. package/src/components/atoms/theme-switch/styles/classes.ts +16 -0
  85. package/src/components/atoms/theme-switch/styles/index.ts +1 -0
  86. package/src/components/atoms/theme-switch/theme-switch.stories.tsx +26 -0
  87. package/src/components/atoms/theme-switch/theme-switch.tsx +54 -0
  88. package/src/components/atoms/uploader/components/avatar-label.tsx +102 -0
  89. package/src/components/atoms/uploader/components/index.ts +8 -0
  90. package/src/components/atoms/uploader/components/upload-file-error-box.tsx +40 -0
  91. package/src/components/atoms/uploader/components/upload-file-input.tsx +36 -0
  92. package/src/components/atoms/uploader/components/upload-file-label.tsx +92 -0
  93. package/src/components/atoms/uploader/components/upload-file-listing.tsx +64 -0
  94. package/src/components/atoms/uploader/components/uploader-title.tsx +21 -0
  95. package/src/components/atoms/uploader/components/uploader.tsx +89 -0
  96. package/src/components/atoms/uploader/components/view-image-modal.tsx +41 -0
  97. package/src/components/atoms/uploader/index.ts +1 -0
  98. package/src/components/atoms/uploader/stories/uploader.stories.tsx +202 -0
  99. package/src/components/index.ts +4 -0
  100. package/src/components/molecules/index.ts +4 -0
  101. package/src/components/molecules/item-card/components/actions/index.ts +3 -0
  102. package/src/components/molecules/item-card/components/actions/item-actions-buttons.tsx +43 -0
  103. package/src/components/molecules/item-card/components/actions/item-actions-dropdown.tsx +57 -0
  104. package/src/components/molecules/item-card/components/actions/item-actions-overlay.tsx +50 -0
  105. package/src/components/molecules/item-card/components/additions/index.ts +2 -0
  106. package/src/components/molecules/item-card/components/additions/item-banner.tsx +22 -0
  107. package/src/components/molecules/item-card/components/additions/loading-item.tsx +88 -0
  108. package/src/components/molecules/item-card/components/card/index.ts +4 -0
  109. package/src/components/molecules/item-card/components/card/item-card-body.tsx +74 -0
  110. package/src/components/molecules/item-card/components/card/item-card-footer.tsx +79 -0
  111. package/src/components/molecules/item-card/components/card/item-card-header.tsx +69 -0
  112. package/src/components/molecules/item-card/components/card/item-card.tsx +123 -0
  113. package/src/components/molecules/item-card/components/index.ts +3 -0
  114. package/src/components/molecules/item-card/index.ts +2 -0
  115. package/src/components/molecules/item-card/stories/item-card.stories.tsx +218 -0
  116. package/src/components/molecules/item-card/styles/classes.ts +141 -0
  117. package/src/components/molecules/item-card/styles/index.ts +1 -0
  118. package/src/components/molecules/nav-bar/index.ts +3 -0
  119. package/src/components/molecules/nav-bar/nav-bar-item.tsx +64 -0
  120. package/src/components/molecules/nav-bar/nav-bar.tsx +57 -0
  121. package/src/components/molecules/nav-bar/stories/hover-effect/nav-bar-hover-effect.stories.tsx +52 -0
  122. package/src/components/molecules/nav-bar/stories/nav-bar.stories.tsx +50 -0
  123. package/src/components/molecules/nav-bar/styles/classes.ts +68 -0
  124. package/src/components/molecules/nav-bar/styles/index.ts +2 -0
  125. package/src/components/molecules/nav-bar/styles/styles.ts +85 -0
  126. package/src/components/molecules/nav-bar/sub-items-box.tsx +58 -0
  127. package/src/components/molecules/scaffold/index.ts +2 -0
  128. package/src/components/molecules/scaffold/scaffold.stories.tsx +21 -0
  129. package/src/components/molecules/scaffold/scaffold.tsx +23 -0
  130. package/src/components/molecules/scaffold/styles/index.ts +1 -0
  131. package/src/components/molecules/scaffold/styles/scaffold-classes.ts +10 -0
  132. package/src/components/molecules/side-bar/compact-side-bar.tsx +77 -0
  133. package/src/components/molecules/side-bar/index.ts +1 -0
  134. package/src/components/molecules/side-bar/side-bar-drawer.tsx +113 -0
  135. package/src/components/molecules/side-bar/side-bar.stories.tsx +111 -0
  136. package/src/components/molecules/side-bar/side-bar.tsx +31 -0
  137. package/src/components/molecules/side-bar/styles/classes.ts +28 -0
  138. package/src/components/molecules/side-bar/styles/index.ts +2 -0
  139. package/src/components/molecules/side-bar/styles/styles.ts +13 -0
  140. package/src/components/organisms/deletion-confirmor/deletion-confirmor.tsx +110 -0
  141. package/src/components/organisms/deletion-confirmor/index.ts +3 -0
  142. package/src/components/organisms/deletion-confirmor/stories/components.tsx +25 -0
  143. package/src/components/organisms/deletion-confirmor/stories/deletion-confirmor.stories.tsx +78 -0
  144. package/src/components/organisms/deletion-confirmor/styles/classes.ts +28 -0
  145. package/src/components/organisms/deletion-confirmor/styles/index.ts +2 -0
  146. package/src/components/organisms/deletion-confirmor/styles/styles.ts +4 -0
  147. package/src/components/organisms/footer/copy-rights-box.tsx +27 -0
  148. package/src/components/organisms/footer/footer.tsx +75 -0
  149. package/src/components/organisms/footer/index.ts +5 -0
  150. package/src/components/organisms/footer/policies-box.tsx +27 -0
  151. package/src/components/organisms/footer/quick-links-box.tsx +46 -0
  152. package/src/components/organisms/footer/social-links-box.tsx +33 -0
  153. package/src/components/organisms/footer/stories/footer.stories.tsx +61 -0
  154. package/src/components/organisms/footer/styles/classes.ts +71 -0
  155. package/src/components/organisms/footer/styles/index.ts +2 -0
  156. package/src/components/organisms/footer/styles/styles.ts +6 -0
  157. package/src/components/organisms/form-builder/form-builder.stories.tsx +144 -0
  158. package/src/components/organisms/form-builder/form-builder.tsx +75 -0
  159. package/src/components/organisms/form-builder/index.ts +1 -0
  160. package/src/components/organisms/header/header.tsx +87 -0
  161. package/src/components/organisms/header/index.ts +1 -0
  162. package/src/components/organisms/header/segmented-header-content.tsx +29 -0
  163. package/src/components/organisms/header/stories/header.stories.tsx +144 -0
  164. package/src/components/organisms/header/styles/classes.ts +22 -0
  165. package/src/components/organisms/header/styles/index.ts +2 -0
  166. package/src/components/organisms/header/styles/styles.ts +39 -0
  167. package/src/components/organisms/index.ts +6 -0
  168. package/src/components/organisms/item-details/index.ts +1 -0
  169. package/src/components/organisms/item-details/item-details.tsx +6 -0
  170. package/src/components/organisms/listings/empty-listings.tsx +80 -0
  171. package/src/components/organisms/listings/index.ts +3 -0
  172. package/src/components/organisms/listings/listings.tsx +96 -0
  173. package/src/components/organisms/listings/stories/grid-listings.stories.tsx +153 -0
  174. package/src/components/organisms/listings/stories/list-listings.stories.tsx +171 -0
  175. package/src/components/organisms/listings/styles/classes.ts +49 -0
  176. package/src/components/organisms/listings/styles/index.ts +2 -0
  177. package/src/components/organisms/listings/styles/styles.ts +6 -0
  178. package/src/components/templates/index.ts +1 -0
  179. package/src/components/templates/landing-page/index.ts +1 -0
  180. package/src/components/templates/landing-page/landing-page.stories.tsx +21 -0
  181. package/src/components/templates/landing-page/landing-page.tsx +57 -0
  182. package/src/components/templates/landing-page/styles/classes.ts +11 -0
  183. package/src/components/templates/landing-page/styles/index.ts +1 -0
  184. package/src/constants/animations.ts +14 -0
  185. package/src/constants/card.tsx +42 -0
  186. package/src/constants/defaults.ts +59 -0
  187. package/src/constants/fake.ts +5 -0
  188. package/src/constants/footer.tsx +157 -0
  189. package/src/constants/index.ts +6 -0
  190. package/src/constants/uploader.ts +33 -0
  191. package/src/context/emperor-ui-context.ts +6 -0
  192. package/src/context/form-builder-context.tsx +8 -0
  193. package/src/context/index.ts +4 -0
  194. package/src/context/navigation-context.ts +6 -0
  195. package/src/context/uploader-context.ts +6 -0
  196. package/src/enums/index.ts +2 -0
  197. package/src/enums/placeholders.ts +5 -0
  198. package/src/enums/preserved-keys.ts +3 -0
  199. package/src/examples/index.ts +1 -0
  200. package/src/hooks/index.ts +8 -0
  201. package/src/hooks/use-emperor-ui.ts +12 -0
  202. package/src/hooks/use-filters.ts +20 -0
  203. package/src/hooks/use-form-builder-context.ts +16 -0
  204. package/src/hooks/use-navigation.ts +12 -0
  205. package/src/hooks/use-search-params-handler.tsx +186 -0
  206. package/src/hooks/use-uploader-context.ts +14 -0
  207. package/src/hooks/use-uploader.tsx +164 -0
  208. package/src/hooks/use-window-size.tsx +53 -0
  209. package/src/i18n/configs/i18n.ts +7 -0
  210. package/src/i18n/configs/index.ts +1 -0
  211. package/src/i18n/constants/index.ts +1 -0
  212. package/src/i18n/constants/locales.ts +4 -0
  213. package/src/i18n/index.ts +5 -0
  214. package/src/i18n/locales/ar.ts +15 -0
  215. package/src/i18n/locales/atoms/ar.ts +18 -0
  216. package/src/i18n/locales/atoms/en.ts +18 -0
  217. package/src/i18n/locales/atoms/index.ts +2 -0
  218. package/src/i18n/locales/common/ar.ts +1 -0
  219. package/src/i18n/locales/common/en.ts +1 -0
  220. package/src/i18n/locales/common/index.ts +2 -0
  221. package/src/i18n/locales/en.ts +15 -0
  222. package/src/i18n/locales/index.ts +4 -0
  223. package/src/i18n/locales/molecules/ar.ts +1 -0
  224. package/src/i18n/locales/molecules/en.ts +1 -0
  225. package/src/i18n/locales/molecules/index.ts +2 -0
  226. package/src/i18n/locales/organisms/ar.ts +11 -0
  227. package/src/i18n/locales/organisms/en.ts +11 -0
  228. package/src/i18n/locales/organisms/index.ts +2 -0
  229. package/src/i18n/locales/templates/ar.ts +1 -0
  230. package/src/i18n/locales/templates/en.ts +1 -0
  231. package/src/i18n/locales/templates/index.ts +2 -0
  232. package/src/i18n/locales/toasts/ar.ts +1 -0
  233. package/src/i18n/locales/toasts/en.ts +1 -0
  234. package/src/i18n/locales/toasts/index.ts +2 -0
  235. package/src/i18n/types/index.ts +2 -0
  236. package/{dist/src/i18n/types/locale.d.ts → src/i18n/types/locale.ts} +3 -1
  237. package/{dist/src/i18n/types/toasts.d.ts → src/i18n/types/toasts.ts} +2 -1
  238. package/src/i18n/utils/get-locales.ts +4 -0
  239. package/src/i18n/utils/index.ts +2 -0
  240. package/src/i18n/utils/localize.ts +15 -0
  241. package/src/index.ts +14 -0
  242. package/src/mocks/constants.ts +103 -0
  243. package/src/mocks/deletion-confirmor.ts +16 -0
  244. package/src/mocks/header.tsx +118 -0
  245. package/src/mocks/index.ts +6 -0
  246. package/src/mocks/listings.tsx +154 -0
  247. package/src/mocks/locales/index.ts +1 -0
  248. package/src/mocks/locales/uploader.ts +33 -0
  249. package/src/mocks/types.ts +64 -0
  250. package/src/providers/config-provider.tsx +72 -0
  251. package/src/providers/emperor-ui-provider.tsx +35 -0
  252. package/src/providers/form-builder-provider-context.tsx +18 -0
  253. package/src/providers/index.ts +6 -0
  254. package/src/providers/navigation-provider.tsx +42 -0
  255. package/src/providers/theme-provider.tsx +16 -0
  256. package/src/providers/uploader-provider.tsx +53 -0
  257. package/src/styles/globals.css +38 -0
  258. package/src/styles/hero.ts +3 -0
  259. package/src/styles/index.css +18 -0
  260. package/src/types/components/atoms/brand.ts +13 -0
  261. package/src/types/components/atoms/color-picker/color-picker.ts +21 -0
  262. package/src/types/components/atoms/color-picker/index.ts +1 -0
  263. package/src/types/components/atoms/column.ts +3 -0
  264. package/{dist/src/types/components/atoms/container.d.ts → src/types/components/atoms/container.ts} +2 -1
  265. package/src/types/components/atoms/field/field.ts +61 -0
  266. package/src/types/components/atoms/field/index.ts +1 -0
  267. package/src/types/components/atoms/filter/filter.ts +52 -0
  268. package/src/types/components/atoms/filter/index.ts +2 -0
  269. package/{dist/src/types/components/atoms/filter/select-filter.d.ts → src/types/components/atoms/filter/select-filter.ts} +4 -3
  270. package/src/types/components/atoms/index.ts +9 -0
  271. package/src/types/components/atoms/portal.ts +6 -0
  272. package/src/types/components/atoms/row.ts +3 -0
  273. package/src/types/components/atoms/uploader.ts +103 -0
  274. package/src/types/components/index.ts +4 -0
  275. package/src/types/components/molecules/footer/footer.ts +68 -0
  276. package/src/types/components/molecules/footer/index.ts +1 -0
  277. package/src/types/components/molecules/header/header.ts +51 -0
  278. package/src/types/components/molecules/header/index.ts +1 -0
  279. package/src/types/components/molecules/index.ts +9 -0
  280. package/src/types/components/molecules/item-card/index.ts +1 -0
  281. package/src/types/components/molecules/item-card/item-card.ts +69 -0
  282. package/src/types/components/molecules/item-details/index.ts +1 -0
  283. package/src/types/components/molecules/item-details/item-details.ts +9 -0
  284. package/src/types/components/molecules/listings/index.ts +1 -0
  285. package/src/types/components/molecules/listings/listings.ts +29 -0
  286. package/src/types/components/molecules/nav-bar/index.ts +1 -0
  287. package/src/types/components/molecules/nav-bar/nav-bar.ts +66 -0
  288. package/src/types/components/molecules/scaffold/index.ts +1 -0
  289. package/src/types/components/molecules/scaffold/scaffold.ts +9 -0
  290. package/src/types/components/molecules/side-bar/index.ts +1 -0
  291. package/src/types/components/molecules/side-bar/side-bar.ts +40 -0
  292. package/src/types/components/molecules/theme-switch/index.ts +1 -0
  293. package/src/types/components/molecules/theme-switch/theme-switch.ts +9 -0
  294. package/src/types/components/organisms/deletion-confirmor/deletion-confirmor.ts +22 -0
  295. package/src/types/components/organisms/deletion-confirmor/index.ts +1 -0
  296. package/src/types/components/organisms/filters/filters.ts +11 -0
  297. package/src/types/components/organisms/filters/index.ts +1 -0
  298. package/src/types/components/organisms/form-builder/context.ts +6 -0
  299. package/src/types/components/organisms/form-builder/form-builder.ts +39 -0
  300. package/src/types/components/organisms/form-builder/index.ts +2 -0
  301. package/src/types/components/organisms/index.ts +3 -0
  302. package/src/types/components/templates/index.ts +1 -0
  303. package/src/types/components/templates/landing-page.ts +10 -0
  304. package/src/types/context/config.ts +24 -0
  305. package/src/types/context/index.ts +4 -0
  306. package/src/types/context/localization.ts +24 -0
  307. package/src/types/context/navigation.ts +17 -0
  308. package/src/types/context/theme.ts +33 -0
  309. package/src/types/index.ts +3 -0
  310. package/{dist/src/types/shared/components.d.ts → src/types/shared/components.ts} +9 -6
  311. package/src/types/shared/index.ts +1 -0
  312. package/src/utils/cn.ts +6 -0
  313. package/src/utils/compress-images.ts +36 -0
  314. package/src/utils/index.ts +5 -0
  315. package/src/utils/locales.ts +54 -0
  316. package/src/utils/storybook.tsx +15 -0
  317. package/src/utils/uploader.ts +170 -0
  318. package/tsconfig.app.json +37 -0
  319. package/tsconfig.json +7 -0
  320. package/tsconfig.node.json +25 -0
  321. package/vite.config.ts +44 -0
  322. package/vitest.shims.d.ts +1 -0
  323. package/dist/src/animations/blink.d.ts +0 -7
  324. package/dist/src/animations/floating.d.ts +0 -2
  325. package/dist/src/animations/index.d.ts +0 -2
  326. package/dist/src/components/atoms/brand/brand.d.ts +0 -14
  327. package/dist/src/components/atoms/brand/index.d.ts +0 -1
  328. package/dist/src/components/atoms/brand/styles/classes.d.ts +0 -3
  329. package/dist/src/components/atoms/brand/styles/index.d.ts +0 -2
  330. package/dist/src/components/atoms/brand/styles/styles.d.ts +0 -1
  331. package/dist/src/components/atoms/color-picker/color-picker.d.ts +0 -2
  332. package/dist/src/components/atoms/color-picker/free-color-picker.d.ts +0 -2
  333. package/dist/src/components/atoms/color-picker/index.d.ts +0 -3
  334. package/dist/src/components/atoms/color-picker/preset-color-picker.d.ts +0 -2
  335. package/dist/src/components/atoms/column/column.d.ts +0 -2
  336. package/dist/src/components/atoms/column/index.d.ts +0 -1
  337. package/dist/src/components/atoms/container/container.d.ts +0 -2
  338. package/dist/src/components/atoms/container/index.d.ts +0 -1
  339. package/dist/src/components/atoms/copy-button/copy-button.d.ts +0 -3
  340. package/dist/src/components/atoms/copy-button/index.d.ts +0 -1
  341. package/dist/src/components/atoms/field/field.d.ts +0 -3
  342. package/dist/src/components/atoms/field/index.d.ts +0 -3
  343. package/dist/src/components/atoms/field/styles/classes.d.ts +0 -3
  344. package/dist/src/components/atoms/field/styles/index.d.ts +0 -1
  345. package/dist/src/components/atoms/field/units/autocomplete-field.d.ts +0 -3
  346. package/dist/src/components/atoms/field/units/checkbox-field.d.ts +0 -3
  347. package/dist/src/components/atoms/field/units/index.d.ts +0 -7
  348. package/dist/src/components/atoms/field/units/input-field.d.ts +0 -3
  349. package/dist/src/components/atoms/field/units/radio-field.d.ts +0 -3
  350. package/dist/src/components/atoms/field/units/select-field.d.ts +0 -3
  351. package/dist/src/components/atoms/field/units/switch-field.d.ts +0 -3
  352. package/dist/src/components/atoms/field/units/textarea-field.d.ts +0 -3
  353. package/dist/src/components/atoms/filter/filter.d.ts +0 -2
  354. package/dist/src/components/atoms/filter/index.d.ts +0 -3
  355. package/dist/src/components/atoms/filter/styles/classes.d.ts +0 -3
  356. package/dist/src/components/atoms/filter/styles/index.d.ts +0 -1
  357. package/dist/src/components/atoms/filter/units/autocomplete-filter.d.ts +0 -2
  358. package/dist/src/components/atoms/filter/units/checkbox-filter.d.ts +0 -2
  359. package/dist/src/components/atoms/filter/units/checkbox-group-filter.d.ts +0 -2
  360. package/dist/src/components/atoms/filter/units/date-filter.d.ts +0 -2
  361. package/dist/src/components/atoms/filter/units/index.d.ts +0 -9
  362. package/dist/src/components/atoms/filter/units/numeric-filter.d.ts +0 -2
  363. package/dist/src/components/atoms/filter/units/range-filter.d.ts +0 -2
  364. package/dist/src/components/atoms/filter/units/search-filter.d.ts +0 -2
  365. package/dist/src/components/atoms/filter/units/select-filter.d.ts +0 -2
  366. package/dist/src/components/atoms/filter/units/switch-filter.d.ts +0 -2
  367. package/dist/src/components/atoms/index.d.ts +0 -11
  368. package/dist/src/components/atoms/portal/index.d.ts +0 -1
  369. package/dist/src/components/atoms/portal/portal.d.ts +0 -2
  370. package/dist/src/components/atoms/row/index.d.ts +0 -1
  371. package/dist/src/components/atoms/row/row.d.ts +0 -2
  372. package/dist/src/components/atoms/theme-switch/index.d.ts +0 -1
  373. package/dist/src/components/atoms/theme-switch/styles/classes.d.ts +0 -3
  374. package/dist/src/components/atoms/theme-switch/styles/index.d.ts +0 -1
  375. package/dist/src/components/atoms/theme-switch/theme-switch.d.ts +0 -2
  376. package/dist/src/components/atoms/uploader/components/avatar-label.d.ts +0 -1
  377. package/dist/src/components/atoms/uploader/components/index.d.ts +0 -8
  378. package/dist/src/components/atoms/uploader/components/upload-file-error-box.d.ts +0 -1
  379. package/dist/src/components/atoms/uploader/components/upload-file-input.d.ts +0 -1
  380. package/dist/src/components/atoms/uploader/components/upload-file-label.d.ts +0 -1
  381. package/dist/src/components/atoms/uploader/components/upload-file-listing.d.ts +0 -1
  382. package/dist/src/components/atoms/uploader/components/uploader-title.d.ts +0 -2
  383. package/dist/src/components/atoms/uploader/components/uploader.d.ts +0 -19
  384. package/dist/src/components/atoms/uploader/components/view-image-modal.d.ts +0 -1
  385. package/dist/src/components/atoms/uploader/index.d.ts +0 -1
  386. package/dist/src/components/index.d.ts +0 -4
  387. package/dist/src/components/molecules/index.d.ts +0 -4
  388. package/dist/src/components/molecules/item-card/components/actions/index.d.ts +0 -3
  389. package/dist/src/components/molecules/item-card/components/actions/item-actions-buttons.d.ts +0 -6
  390. package/dist/src/components/molecules/item-card/components/actions/item-actions-dropdown.d.ts +0 -2
  391. package/dist/src/components/molecules/item-card/components/actions/item-actions-overlay.d.ts +0 -4
  392. package/dist/src/components/molecules/item-card/components/additions/index.d.ts +0 -2
  393. package/dist/src/components/molecules/item-card/components/additions/item-banner.d.ts +0 -2
  394. package/dist/src/components/molecules/item-card/components/additions/loading-item.d.ts +0 -2
  395. package/dist/src/components/molecules/item-card/components/card/index.d.ts +0 -4
  396. package/dist/src/components/molecules/item-card/components/card/item-card-body.d.ts +0 -2
  397. package/dist/src/components/molecules/item-card/components/card/item-card-footer.d.ts +0 -2
  398. package/dist/src/components/molecules/item-card/components/card/item-card-header.d.ts +0 -2
  399. package/dist/src/components/molecules/item-card/components/card/item-card.d.ts +0 -2
  400. package/dist/src/components/molecules/item-card/components/index.d.ts +0 -3
  401. package/dist/src/components/molecules/item-card/index.d.ts +0 -2
  402. package/dist/src/components/molecules/item-card/styles/classes.d.ts +0 -33
  403. package/dist/src/components/molecules/item-card/styles/index.d.ts +0 -1
  404. package/dist/src/components/molecules/nav-bar/index.d.ts +0 -3
  405. package/dist/src/components/molecules/nav-bar/nav-bar-item.d.ts +0 -6
  406. package/dist/src/components/molecules/nav-bar/nav-bar.d.ts +0 -13
  407. package/dist/src/components/molecules/nav-bar/styles/classes.d.ts +0 -11
  408. package/dist/src/components/molecules/nav-bar/styles/index.d.ts +0 -2
  409. package/dist/src/components/molecules/nav-bar/styles/styles.d.ts +0 -5
  410. package/dist/src/components/molecules/nav-bar/sub-items-box.d.ts +0 -2
  411. package/dist/src/components/molecules/scaffold/index.d.ts +0 -2
  412. package/dist/src/components/molecules/scaffold/scaffold.d.ts +0 -3
  413. package/dist/src/components/molecules/scaffold/styles/index.d.ts +0 -1
  414. package/dist/src/components/molecules/scaffold/styles/scaffold-classes.d.ts +0 -1
  415. package/dist/src/components/molecules/side-bar/compact-side-bar.d.ts +0 -2
  416. package/dist/src/components/molecules/side-bar/index.d.ts +0 -1
  417. package/dist/src/components/molecules/side-bar/side-bar-drawer.d.ts +0 -2
  418. package/dist/src/components/molecules/side-bar/side-bar.d.ts +0 -15
  419. package/dist/src/components/molecules/side-bar/styles/classes.d.ts +0 -6
  420. package/dist/src/components/molecules/side-bar/styles/index.d.ts +0 -2
  421. package/dist/src/components/molecules/side-bar/styles/styles.d.ts +0 -3
  422. package/dist/src/components/organisms/deletion-confirmor/deletion-confirmor.d.ts +0 -2
  423. package/dist/src/components/organisms/deletion-confirmor/index.d.ts +0 -3
  424. package/dist/src/components/organisms/deletion-confirmor/stories/components.d.ts +0 -2
  425. package/dist/src/components/organisms/deletion-confirmor/styles/classes.d.ts +0 -4
  426. package/dist/src/components/organisms/deletion-confirmor/styles/index.d.ts +0 -2
  427. package/dist/src/components/organisms/deletion-confirmor/styles/styles.d.ts +0 -2
  428. package/dist/src/components/organisms/footer/copy-rights-box.d.ts +0 -2
  429. package/dist/src/components/organisms/footer/footer.d.ts +0 -11
  430. package/dist/src/components/organisms/footer/index.d.ts +0 -5
  431. package/dist/src/components/organisms/footer/policies-box.d.ts +0 -2
  432. package/dist/src/components/organisms/footer/quick-links-box.d.ts +0 -2
  433. package/dist/src/components/organisms/footer/social-links-box.d.ts +0 -2
  434. package/dist/src/components/organisms/footer/styles/classes.d.ts +0 -9
  435. package/dist/src/components/organisms/footer/styles/index.d.ts +0 -2
  436. package/dist/src/components/organisms/footer/styles/styles.d.ts +0 -2
  437. package/dist/src/components/organisms/form-builder/form-builder.d.ts +0 -3
  438. package/dist/src/components/organisms/form-builder/index.d.ts +0 -1
  439. package/dist/src/components/organisms/header/header.d.ts +0 -8
  440. package/dist/src/components/organisms/header/index.d.ts +0 -1
  441. package/dist/src/components/organisms/header/segmented-header-content.d.ts +0 -2
  442. package/dist/src/components/organisms/header/styles/classes.d.ts +0 -3
  443. package/dist/src/components/organisms/header/styles/index.d.ts +0 -2
  444. package/dist/src/components/organisms/header/styles/styles.d.ts +0 -6
  445. package/dist/src/components/organisms/index.d.ts +0 -6
  446. package/dist/src/components/organisms/item-details/index.d.ts +0 -1
  447. package/dist/src/components/organisms/item-details/item-details.d.ts +0 -2
  448. package/dist/src/components/organisms/listings/empty-listings.d.ts +0 -9
  449. package/dist/src/components/organisms/listings/index.d.ts +0 -3
  450. package/dist/src/components/organisms/listings/listings.d.ts +0 -2
  451. package/dist/src/components/organisms/listings/styles/classes.d.ts +0 -10
  452. package/dist/src/components/organisms/listings/styles/index.d.ts +0 -2
  453. package/dist/src/components/organisms/listings/styles/styles.d.ts +0 -2
  454. package/dist/src/components/templates/index.d.ts +0 -1
  455. package/dist/src/components/templates/landing-page/index.d.ts +0 -1
  456. package/dist/src/components/templates/landing-page/landing-page.d.ts +0 -10
  457. package/dist/src/components/templates/landing-page/styles/classes.d.ts +0 -3
  458. package/dist/src/components/templates/landing-page/styles/index.d.ts +0 -1
  459. package/dist/src/constants/animations.d.ts +0 -5
  460. package/dist/src/constants/card.d.ts +0 -3
  461. package/dist/src/constants/defaults.d.ts +0 -2
  462. package/dist/src/constants/fake.d.ts +0 -2
  463. package/dist/src/constants/footer.d.ts +0 -6
  464. package/dist/src/constants/index.d.ts +0 -6
  465. package/dist/src/constants/uploader.d.ts +0 -8
  466. package/dist/src/context/emperor-ui-context.d.ts +0 -2
  467. package/dist/src/context/form-builder-context.d.ts +0 -3
  468. package/dist/src/context/index.d.ts +0 -4
  469. package/dist/src/context/navigation-context.d.ts +0 -2
  470. package/dist/src/context/uploader-context.d.ts +0 -2
  471. package/dist/src/enums/index.d.ts +0 -2
  472. package/dist/src/enums/placeholders.d.ts +0 -5
  473. package/dist/src/enums/preserved-keys.d.ts +0 -3
  474. package/dist/src/examples/index.d.ts +0 -1
  475. package/dist/src/hooks/index.d.ts +0 -8
  476. package/dist/src/hooks/use-emperor-ui.d.ts +0 -1
  477. package/dist/src/hooks/use-filters.d.ts +0 -4
  478. package/dist/src/hooks/use-form-builder-context.d.ts +0 -3
  479. package/dist/src/hooks/use-navigation.d.ts +0 -1
  480. package/dist/src/hooks/use-search-params-handler.d.ts +0 -17
  481. package/dist/src/hooks/use-uploader-context.d.ts +0 -1
  482. package/dist/src/hooks/use-uploader.d.ts +0 -2
  483. package/dist/src/hooks/use-window-size.d.ts +0 -7
  484. package/dist/src/i18n/configs/i18n.d.ts +0 -6
  485. package/dist/src/i18n/configs/index.d.ts +0 -1
  486. package/dist/src/i18n/constants/index.d.ts +0 -1
  487. package/dist/src/i18n/constants/locales.d.ts +0 -4
  488. package/dist/src/i18n/index.d.ts +0 -5
  489. package/dist/src/i18n/locales/ar.d.ts +0 -32
  490. package/dist/src/i18n/locales/atoms/ar.d.ts +0 -16
  491. package/dist/src/i18n/locales/atoms/en.d.ts +0 -16
  492. package/dist/src/i18n/locales/atoms/index.d.ts +0 -2
  493. package/dist/src/i18n/locales/common/ar.d.ts +0 -1
  494. package/dist/src/i18n/locales/common/en.d.ts +0 -1
  495. package/dist/src/i18n/locales/common/index.d.ts +0 -2
  496. package/dist/src/i18n/locales/en.d.ts +0 -32
  497. package/dist/src/i18n/locales/index.d.ts +0 -4
  498. package/dist/src/i18n/locales/molecules/ar.d.ts +0 -1
  499. package/dist/src/i18n/locales/molecules/en.d.ts +0 -1
  500. package/dist/src/i18n/locales/molecules/index.d.ts +0 -2
  501. package/dist/src/i18n/locales/organisms/ar.d.ts +0 -10
  502. package/dist/src/i18n/locales/organisms/en.d.ts +0 -10
  503. package/dist/src/i18n/locales/organisms/index.d.ts +0 -2
  504. package/dist/src/i18n/locales/templates/ar.d.ts +0 -1
  505. package/dist/src/i18n/locales/templates/en.d.ts +0 -1
  506. package/dist/src/i18n/locales/templates/index.d.ts +0 -2
  507. package/dist/src/i18n/locales/toasts/ar.d.ts +0 -1
  508. package/dist/src/i18n/locales/toasts/en.d.ts +0 -1
  509. package/dist/src/i18n/locales/toasts/index.d.ts +0 -2
  510. package/dist/src/i18n/types/index.d.ts +0 -2
  511. package/dist/src/i18n/utils/get-locales.d.ts +0 -2
  512. package/dist/src/i18n/utils/index.d.ts +0 -2
  513. package/dist/src/i18n/utils/localize.d.ts +0 -6
  514. package/dist/src/index.d.ts +0 -10
  515. package/dist/src/mocks/constants.d.ts +0 -10
  516. package/dist/src/mocks/deletion-confirmor.d.ts +0 -7
  517. package/dist/src/mocks/header.d.ts +0 -5
  518. package/dist/src/mocks/index.d.ts +0 -6
  519. package/dist/src/mocks/listings.d.ts +0 -14
  520. package/dist/src/mocks/locales/index.d.ts +0 -1
  521. package/dist/src/mocks/locales/uploader.d.ts +0 -2
  522. package/dist/src/mocks/types.d.ts +0 -28
  523. package/dist/src/providers/config-provider.d.ts +0 -2
  524. package/dist/src/providers/emperor-ui-provider.d.ts +0 -4
  525. package/dist/src/providers/form-builder-provider-context.d.ts +0 -7
  526. package/dist/src/providers/index.d.ts +0 -6
  527. package/dist/src/providers/navigation-provider.d.ts +0 -2
  528. package/dist/src/providers/theme-provider.d.ts +0 -5
  529. package/dist/src/providers/uploader-provider.d.ts +0 -2
  530. package/dist/src/styles/hero.d.ts +0 -2
  531. package/dist/src/types/components/atoms/brand.d.ts +0 -12
  532. package/dist/src/types/components/atoms/color-picker/color-picker.d.ts +0 -10
  533. package/dist/src/types/components/atoms/color-picker/index.d.ts +0 -1
  534. package/dist/src/types/components/atoms/column.d.ts +0 -2
  535. package/dist/src/types/components/atoms/field/field.d.ts +0 -36
  536. package/dist/src/types/components/atoms/field/index.d.ts +0 -1
  537. package/dist/src/types/components/atoms/filter/filter.d.ts +0 -35
  538. package/dist/src/types/components/atoms/filter/index.d.ts +0 -2
  539. package/dist/src/types/components/atoms/index.d.ts +0 -9
  540. package/dist/src/types/components/atoms/portal.d.ts +0 -5
  541. package/dist/src/types/components/atoms/row.d.ts +0 -2
  542. package/dist/src/types/components/atoms/uploader.d.ts +0 -84
  543. package/dist/src/types/components/index.d.ts +0 -4
  544. package/dist/src/types/components/molecules/footer/footer.d.ts +0 -60
  545. package/dist/src/types/components/molecules/footer/index.d.ts +0 -1
  546. package/dist/src/types/components/molecules/header/header.d.ts +0 -38
  547. package/dist/src/types/components/molecules/header/index.d.ts +0 -1
  548. package/dist/src/types/components/molecules/index.d.ts +0 -9
  549. package/dist/src/types/components/molecules/item-card/index.d.ts +0 -1
  550. package/dist/src/types/components/molecules/item-card/item-card.d.ts +0 -57
  551. package/dist/src/types/components/molecules/item-details/index.d.ts +0 -1
  552. package/dist/src/types/components/molecules/item-details/item-details.d.ts +0 -7
  553. package/dist/src/types/components/molecules/listings/index.d.ts +0 -1
  554. package/dist/src/types/components/molecules/listings/listings.d.ts +0 -22
  555. package/dist/src/types/components/molecules/nav-bar/index.d.ts +0 -1
  556. package/dist/src/types/components/molecules/nav-bar/nav-bar.d.ts +0 -45
  557. package/dist/src/types/components/molecules/scaffold/index.d.ts +0 -1
  558. package/dist/src/types/components/molecules/scaffold/scaffold.d.ts +0 -7
  559. package/dist/src/types/components/molecules/side-bar/index.d.ts +0 -1
  560. package/dist/src/types/components/molecules/side-bar/side-bar.d.ts +0 -36
  561. package/dist/src/types/components/molecules/theme-switch/index.d.ts +0 -1
  562. package/dist/src/types/components/molecules/theme-switch/theme-switch.d.ts +0 -7
  563. package/dist/src/types/components/organisms/deletion-confirmor/deletion-confirmor.d.ts +0 -20
  564. package/dist/src/types/components/organisms/deletion-confirmor/index.d.ts +0 -1
  565. package/dist/src/types/components/organisms/filters/filters.d.ts +0 -9
  566. package/dist/src/types/components/organisms/filters/index.d.ts +0 -1
  567. package/dist/src/types/components/organisms/form-builder/context.d.ts +0 -5
  568. package/dist/src/types/components/organisms/form-builder/form-builder.d.ts +0 -26
  569. package/dist/src/types/components/organisms/form-builder/index.d.ts +0 -2
  570. package/dist/src/types/components/organisms/index.d.ts +0 -3
  571. package/dist/src/types/components/templates/index.d.ts +0 -1
  572. package/dist/src/types/components/templates/landing-page.d.ts +0 -8
  573. package/dist/src/types/context/config.d.ts +0 -19
  574. package/dist/src/types/context/index.d.ts +0 -4
  575. package/dist/src/types/context/localization.d.ts +0 -17
  576. package/dist/src/types/context/navigation.d.ts +0 -15
  577. package/dist/src/types/context/theme.d.ts +0 -32
  578. package/dist/src/types/index.d.ts +0 -3
  579. package/dist/src/types/shared/index.d.ts +0 -1
  580. package/dist/src/utils/cn.d.ts +0 -2
  581. package/dist/src/utils/compress-images.d.ts +0 -2
  582. package/dist/src/utils/index.d.ts +0 -5
  583. package/dist/src/utils/locales.d.ts +0 -10
  584. package/dist/src/utils/storybook.d.ts +0 -4
  585. package/dist/src/utils/uploader.d.ts +0 -40
@@ -1,4238 +1,160 @@
1
- "use client";
2
- import { jsx as r, jsxs as b, Fragment as se } from "react/jsx-runtime";
3
- import { createContext as X, useMemo as E, useState as I, forwardRef as P, useContext as Z, useCallback as R, useEffect as O, useRef as Et, Children as De, isValidElement as Lt, cloneElement as Pt } from "react";
4
- import At from "clsx";
5
- import { twMerge as zt } from "tailwind-merge";
6
- import { Card as Te, CardHeader as Be, CardBody as _e, CardFooter as Re } from "@heroui/card";
7
- import { Skeleton as T } from "@heroui/skeleton";
8
- import { motion as F, AnimatePresence as Vt } from "framer-motion";
9
- import { FacebookIcon as kt, TwitterIcon as Ft, InstagramIcon as Mt, LinkedinIcon as Dt, YoutubeIcon as Tt, Trash2 as Y, Pencil as Oe, Eye as ue, InfoIcon as me, MailIcon as pe, ServerIcon as fe, SettingsIcon as Bt, HelpCircleIcon as _t, LifeBuoyIcon as Rt, HomeIcon as Ue, LogOutIcon as Ot, Star as Ut, EllipsisVertical as Ht, UploadCloud as jt, Search as Gt, SunIcon as Wt, MoonIcon as qt, Copy as Kt, Check as $t, Inbox as Xt } from "lucide-react";
10
- import { ToastProvider as Zt, addToast as W } from "@heroui/toast";
11
- import { Image as he } from "@heroui/image";
12
- import { Chip as Yt } from "@heroui/chip";
13
- import { Button as L } from "@heroui/button";
14
- import { Dropdown as Jt, DropdownTrigger as Qt, DropdownMenu as ea, DropdownItem as ta } from "@heroui/dropdown";
15
- import { Tooltip as aa } from "@heroui/tooltip";
16
- import { cva as w } from "class-variance-authority";
17
- import { Link as J } from "@heroui/link";
18
- import { createPortal as He } from "react-dom";
19
- import { Avatar as ra } from "@heroui/avatar";
20
- import { Spinner as ge } from "@heroui/spinner";
21
- import { useDisclosure as je, Modal as Ge, ModalContent as We, ModalBody as qe, ModalHeader as na, ModalFooter as oa } from "@heroui/modal";
22
- import { Input as Q, Textarea as sa } from "@heroui/input";
23
- import { useDebounce as ia } from "use-debounce";
24
- import { Select as ve, SelectItem as be } from "@heroui/select";
25
- import { Autocomplete as Ke, AutocompleteItem as $e } from "@heroui/autocomplete";
26
- import { DatePicker as la } from "@heroui/date-picker";
27
- import { parseDate as ca } from "@internationalized/date";
28
- import { Checkbox as we, CheckboxGroup as da } from "@heroui/checkbox";
29
- import { Switch as Xe } from "@heroui/switch";
30
- import { Slider as ua } from "@heroui/slider";
31
- import { Controller as U, useForm as ma, useWatch as pa } from "react-hook-form";
32
- import { RadioGroup as fa, Radio as ha } from "@heroui/radio";
33
- import { ThemeProvider as Ze, useTheme as ga } from "next-themes";
34
- import { motion as Ie, AnimatePresence as va } from "motion/react";
35
- import { Pagination as ba } from "@heroui/pagination";
36
- import { HeroUIProvider as wa } from "@heroui/system";
37
- import xa from "browser-image-compression";
38
- import { Divider as xe } from "@heroui/divider";
39
- import { Drawer as ya, DrawerContent as Ca, DrawerHeader as Ia, DrawerBody as Sa, DrawerFooter as Na } from "@heroui/drawer";
40
- import { ScrollShadow as Ye } from "@heroui/scroll-shadow";
41
- function c(...e) {
42
- return zt(At(e));
43
- }
44
- var A = /* @__PURE__ */ ((e) => (e.ARABIC = "ar", e.ENGLISH = "en", e))(A || {});
45
- A.ARABIC, A.ENGLISH;
46
- const ee = (e) => e === "en" ? Qe : Je, Ea = {}, La = {}, Pa = {}, Aa = {}, za = {
47
- colorPicker: {
48
- invalidColorFormat: "يرجى إدخال لون صالح (مثال: #000000 أو #fff)"
49
- },
50
- uploader: {
51
- dropHere: "أسقط الملف هنا",
52
- selectFile: "حدد ملفًا أو اسحبه وأفلته هنا",
53
- selectionTypes: "JPG, PNG أو PDF، حجم الملف لا يزيد عن 10MB",
54
- selectBtn: "حدد ملف",
55
- errorUploadingFile: "لم يتم تحميل أي ملف",
56
- maxNumImages: "تم تجاوز الحد الأقصى للصور المرفوعة: ",
57
- errorUploadedTypes: "نوع الملف المرفوع غير مسموح به",
58
- maxSizeExceededError: "يمكنك فقط رفع ملفات/صور بحجم أقل من MAX_FILE_SIZE ميغابايت، بينما حجم الملف الذي رفعته هو UPLOADED_FILE_SIZE ميغابايت",
59
- duplicatesDenied: "لا يمكنك رفع صور تحمل نفس الاسم، يمكنك إعادة تسميتها قبل عملية الرفع"
60
- }
61
- }, Va = {
62
- colorPicker: {
63
- invalidColorFormat: "Please enter a valid color (e.g., #000000 or #fff)"
64
- },
65
- uploader: {
66
- dropHere: "Drop file here",
67
- selectFile: "Select a file or drag and drop here",
68
- selectionTypes: "JPG, PNG or PDF, file size no more than 10MB",
69
- selectBtn: "Select file",
70
- errorUploadingFile: "No file was uploaded",
71
- maxNumImages: "Maximum number of uploaded images exceeded: ",
72
- errorUploadedTypes: "The uploaded file type is not allowed.",
73
- maxSizeExceededError: "You can only upload files/images with less than MAX_FILE_SIZE Mega Bytes, you're file's size is UPLOADED_FILE_SIZE Mega Bytes",
74
- duplicatesDenied: "You can't upload images with duplicate names, you may rename them before the upload process"
75
- }
76
- }, ka = {}, Fa = {}, Ma = {
77
- deletionConfirmor: {
78
- confirm: "تأكيد",
79
- decline: "إلغاء"
80
- },
81
- listings: {
82
- emptyTitle: "لا توجد عناصر",
83
- emptyDescription: "لم نجد أي عناصر تطابق بحثك. جرّب تعديل الفلاتر أو البحث لاحقاً."
84
- }
85
- }, Da = {
86
- deletionConfirmor: {
87
- confirm: "Confirm",
88
- decline: "Decline"
89
- },
90
- listings: {
91
- emptyTitle: "No listings found",
92
- emptyDescription: "We couldn't find any listings matching your search. Try adjusting your filters or check back later."
93
- }
94
- }, Ta = {}, Ba = {}, Je = {
95
- common: Ea,
96
- toasts: Pa,
97
- atoms: za,
98
- molecules: ka,
99
- organisms: Ma,
100
- templates: Ta
101
- }, Qe = {
102
- common: La,
103
- toasts: Aa,
104
- atoms: Va,
105
- molecules: Fa,
106
- organisms: Da,
107
- templates: Ba
108
- }, B = {
109
- layout: {
110
- withScaffold: !0
111
- },
112
- interLocalization: {
113
- lang: "en",
114
- languages: ["en", "ar"],
115
- defaultLanguage: "en",
116
- dir: "ltr",
117
- isMultiLingual: !1,
118
- locales: {
119
- en: Qe,
120
- ar: Je
121
- }
122
- },
123
- theme: {
124
- components: {
125
- input: {
126
- variant: "faded",
127
- labelPlacement: "outside",
128
- size: "sm"
129
- },
130
- textarea: {
131
- variant: "faded",
132
- labelPlacement: "outside",
133
- size: "sm"
134
- },
135
- button: {
136
- variant: "faded",
137
- size: "sm"
138
- },
139
- select: {
140
- variant: "faded",
141
- labelPlacement: "outside",
142
- placeholder: "Select an option",
143
- size: "sm"
144
- },
145
- selectItem: {
146
- variant: "faded"
147
- },
148
- autocomplete: {
149
- variant: "faded",
150
- labelPlacement: "outside",
151
- size: "sm"
152
- },
153
- autocompleteItem: {
154
- variant: "faded"
155
- },
156
- datePicker: {
157
- variant: "faded",
158
- labelPlacement: "outside",
159
- size: "sm"
160
- }
161
- }
162
- }
163
- }, ko = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.", q = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui. Etiam rhoncus. Maecenas tempus, tellus eget condimentum rhoncus, sem quam semper libero, sit amet adipiscing sem neque sed ipsum. Nam quam nunc, blandit vel, luctus pulvinar, hendrerit id, lorem. Maecenas nec odio et ante tincidunt tempus. Donec vitae sapien ut libero venenatis faucibus. Nullam quis ante. Etiam sit amet orci eget eros faucibus tincidunt. Duis leo. Sed fringilla mauris sit amet nibh. Donec sodales sagittis magna. Sed consequat, leo eget bibendum sodales, augue velit cursus nunc,", et = [
164
- "image/jpeg",
165
- "image/jpg",
166
- "image/png",
167
- "image/webp",
168
- "image/gif",
169
- "image/bmp",
170
- "image/svg+xml",
171
- "image/tiff",
172
- "image/x-icon"
173
- ], tt = ["application/pdf"], at = [
174
- "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
175
- ], rt = [
176
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
177
- "application/vnd.ms-excel",
178
- "text/csv"
179
- ], nt = 1024, _a = {
180
- image: [".jpg", ".jpeg", ".png"],
181
- doc: [".doc", ".docx"],
182
- pdf: [".pdf"],
183
- video: [".mp4"],
184
- sheet: [".xlsx", ".xlx", ".xls", ".csv"]
185
- }, Fo = [
186
- {
187
- title: "Products",
188
- links: [
189
- {
190
- label: "Product 1",
191
- href: "/product-1"
192
- },
193
- {
194
- label: "Product 2",
195
- href: "/product-2"
196
- },
197
- {
198
- label: "Product 3",
199
- href: "/product-3"
200
- }
201
- ]
202
- },
203
- {
204
- title: "Services",
205
- links: [
206
- {
207
- label: "Service 1",
208
- href: "/service-1"
209
- },
210
- {
211
- label: "Service 2",
212
- href: "/service-2"
213
- },
214
- {
215
- label: "Service 3",
216
- href: "/service-3"
217
- },
218
- {
219
- label: "Service 4",
220
- href: "/service-4"
221
- }
222
- ]
223
- },
224
- {
225
- title: "Resources",
226
- links: [
227
- {
228
- label: "Resource 1",
229
- href: "/resource-1"
230
- }
231
- ]
232
- },
233
- {
234
- title: "Company",
235
- links: [
236
- {
237
- label: "About Us",
238
- href: "/about-us"
239
- },
240
- {
241
- label: "Careers",
242
- href: "/careers"
243
- },
244
- {
245
- label: "Blog",
246
- href: "/blog"
247
- }
248
- ]
249
- },
250
- {
251
- title: "Support",
252
- links: [
253
- {
254
- label: "Contact Us",
255
- href: "/contact-us"
256
- }
257
- ]
258
- }
259
- ], Mo = [
260
- {
261
- label: "Privacy Policy",
262
- href: "/privacy-policy"
263
- },
264
- {
265
- label: "Terms of Service",
266
- href: "/terms-of-service"
267
- },
268
- {
269
- label: "Cookie Policy",
270
- href: "/cookie-policy"
271
- }
272
- ], Do = {
273
- year: 2026,
274
- text: "All rights reserved - Emperor UI"
275
- }, To = {
276
- mobile: "+964 770 000 0000",
277
- email: "contact@emperorui.com",
278
- website: "https://jsempire.com",
279
- workingHours: "Monday - Friday: 9:00 AM - 5:00 PM",
280
- addresses: [
281
- {
282
- country: "Jordan",
283
- street: "Amman, Jordan",
284
- city: "Amman",
285
- state: "Amman",
286
- zip: "11111"
287
- },
288
- {
289
- country: "Saudi Arabia",
290
- street: "Riyadh, Saudi Arabia",
291
- city: "Riyadh",
292
- state: "Riyadh",
293
- zip: "11111"
294
- }
295
- ]
296
- }, Bo = [
297
- {
298
- href: "https://facebook.com",
299
- icon: /* @__PURE__ */ r(kt, {})
300
- },
301
- {
302
- href: "https://twitter.com",
303
- icon: /* @__PURE__ */ r(Ft, {})
304
- },
305
- {
306
- href: "https://instagram.com",
307
- icon: /* @__PURE__ */ r(Mt, {})
308
- },
309
- {
310
- href: "https://linkedin.com",
311
- icon: /* @__PURE__ */ r(Dt, {})
312
- },
313
- {
314
- href: "https://youtube.com",
315
- icon: /* @__PURE__ */ r(Tt, {})
316
- }
317
- ], ot = ({}) => ({
318
- initial: { opacity: 0, y: 12 },
319
- animate: { opacity: 1, y: 0 },
320
- transition: { duration: 0.3, ease: "easeOut" },
321
- whileHover: {
322
- y: -4
323
- }
324
- }), Ra = [
325
- {
326
- key: "view",
327
- label: "View details",
328
- color: "primary",
329
- variant: "flat",
330
- size: "sm",
331
- startContent: /* @__PURE__ */ r(ue, { className: "size-4" })
332
- },
333
- {
334
- key: "edit",
335
- label: "Edit",
336
- color: "secondary",
337
- variant: "flat",
338
- size: "sm",
339
- startContent: /* @__PURE__ */ r(Oe, { className: "size-4" })
340
- },
341
- {
342
- key: "delete",
343
- label: "Delete",
344
- color: "danger",
345
- variant: "flat",
346
- size: "sm",
347
- startContent: /* @__PURE__ */ r(Y, { className: "size-4" })
348
- }
349
- ], _o = Ra.map((e) => ({
350
- ...e,
351
- variant: "solid",
352
- size: "lg",
353
- startContent: {
354
- view: /* @__PURE__ */ r(ue, { className: "size-5" }),
355
- edit: /* @__PURE__ */ r(Oe, { className: "size-5" }),
356
- delete: /* @__PURE__ */ r(Y, { className: "size-5" })
357
- }[e?.key]
358
- })), ie = X(
359
- void 0
360
- ), st = X(void 0), it = X(
361
- void 0
362
- ), lt = X(null);
363
- function Oa({
364
- children: e,
365
- config: t = B
366
- }) {
367
- const a = E(() => ({
368
- config: {
369
- layout: {
370
- ...B?.layout,
371
- ...t?.layout
372
- },
373
- interLocalization: {
374
- ...B?.interLocalization,
375
- ...t?.interLocalization,
376
- locales: {
377
- [A.ENGLISH]: Ne({
378
- defaultLocales: B?.interLocalization?.locales?.[A.ENGLISH],
379
- configLocales: t?.interLocalization?.locales?.[A.ENGLISH]
380
- }),
381
- [A.ARABIC]: Ne({
382
- defaultLocales: B?.interLocalization?.locales?.[A.ARABIC],
383
- configLocales: t?.interLocalization?.locales?.[A.ARABIC]
384
- })
385
- }
386
- },
387
- theme: {
388
- ...B?.theme,
389
- ...t?.theme,
390
- components: {
391
- ...B?.theme?.components,
392
- ...t?.theme?.components
393
- }
394
- }
395
- }
396
- }), [t]);
397
- return t.layout?.withScaffold ?? !0 ? /* @__PURE__ */ r(ie.Provider, { value: a, children: /* @__PURE__ */ r(Tr, { children: e }) }) : /* @__PURE__ */ r(ie.Provider, { value: a, children: e });
398
- }
399
- function Ua({
400
- children: e,
401
- ...t
402
- }) {
403
- return /* @__PURE__ */ r(Oa, { ...t, children: /* @__PURE__ */ r(wa, { children: /* @__PURE__ */ r(Ha, { children: /* @__PURE__ */ b(Ze, { children: [
404
- /* @__PURE__ */ r(
405
- Zt,
406
- {
407
- placement: "top-center",
408
- toastProps: {
409
- radius: "lg",
410
- size: "lg",
411
- color: "primary",
412
- variant: "flat",
413
- timeout: 4e3
414
- },
415
- ...t?.config?.toast
416
- }
417
- ),
418
- e
419
- ] }) }) }) });
420
- }
421
- var ct = /* @__PURE__ */ ((e) => (e.COMPACT_SIDEBAR_ID = "emperor-compact-sidebar", e))(ct || {}), dt = /* @__PURE__ */ ((e) => (e.PLACEHOLDER_MALE_AVATAR = "https://api.dicebear.com/7.x/avataaars/svg?seed=male", e.PLACEHOLDER_FEMALE_AVATAR = "https://api.dicebear.com/7.x/avataaars/svg?seed=female", e))(dt || {});
422
- function Ha({ children: e }) {
423
- const [t, a] = I(null), [n, o] = I([]), [s, i] = I(!1), [l, d] = I(!1), u = E(() => ({
424
- hoveredItemId: t,
425
- subItems: n,
426
- isSubItemsBoxOpen: s,
427
- subItemsBoxIsHovered: l,
428
- setHoveredItemId: a,
429
- setSubItems: o,
430
- setIsSubItemsBoxOpen: i,
431
- setSubItemsBoxIsHovered: d
432
- }), [t, n, s, l]);
433
- return /* @__PURE__ */ b(
434
- st.Provider,
435
- {
436
- value: u,
437
- "data-slot": "emperor-navigation-provider",
438
- children: [
439
- /* @__PURE__ */ r(
440
- "div",
441
- {
442
- id: ct.COMPACT_SIDEBAR_ID,
443
- "data-slot": "emperor-compact-sidebar"
444
- }
445
- ),
446
- e
447
- ]
448
- }
449
- );
450
- }
451
- function ja({
452
- children: e,
453
- ...t
454
- }) {
455
- const { isOpen: a, onOpen: n, onOpenChange: o } = je(), [s, i] = I(null), l = E(
456
- () => !!s?.view && !!s?.file?.name && s?.type === "image",
457
- [s]
458
- ), d = E(() => ({
459
- isOpen: a,
460
- onOpen: n,
461
- onOpenChange: o,
462
- selectedFile: s,
463
- setSelectedFile: i,
464
- isFileViewable: l,
465
- ...t
466
- }), [
467
- a,
468
- l,
469
- s,
470
- n,
471
- o,
472
- i,
473
- t
474
- ]);
475
- return /* @__PURE__ */ r(
476
- it.Provider,
477
- {
478
- value: d,
479
- "data-slot": "emperor-uploader-provider",
480
- children: e
481
- }
482
- );
483
- }
484
- function Ro({ children: e }) {
485
- return /* @__PURE__ */ r(Ze, { attribute: "class", defaultTheme: "system", enableSystem: !0, children: e });
486
- }
487
- function Ga({
488
- children: e,
489
- value: t
490
- }) {
491
- return /* @__PURE__ */ r(lt.Provider, { value: t, children: e });
492
- }
493
- const Oo = ({
494
- config: e = B
495
- }) => [
496
- (t) => /* @__PURE__ */ r(Ua, { config: e, children: /* @__PURE__ */ r(t, {}) })
497
- ];
498
- async function Wa(e, t) {
499
- try {
500
- if (!e?.file) return null;
501
- const a = await xa(e?.file, {
502
- maxSizeMB: t || 2,
503
- useWebWorker: !0,
504
- // Optimize performance
505
- initialQuality: 0.8
506
- // Adjust the compression quality (0.1 to 1)
507
- }), n = new File([a], e?.file?.name, {
508
- type: a.type
509
- });
510
- return {
511
- ...e,
512
- file: n
513
- };
514
- } catch (a) {
515
- return console.error("Image compression failed:", a), null;
516
- }
517
- }
518
- const qa = (e) => et.includes(e) ? "image" : tt.includes(e) ? "pdf" : at.includes(e) ? "doc" : rt.includes(e) ? "sheet" : null, Ka = (e) => {
519
- const t = [];
520
- return e.forEach((a) => {
521
- a === "image" && t.push(...et), a === "doc" && t.push(...at), a === "pdf" && t.push(...tt), a === "sheet" && t.push(...rt);
522
- }), t;
523
- }, $a = ({
524
- files: e,
525
- fileName: t
526
- }) => e?.filter(({ file: a }) => a?.name === t)?.length > 0, Xa = ({
527
- fileSize: e,
528
- maxFileSize: t
529
- }) => e > t * 1024;
530
- async function Za({
531
- uploadedFiles: e,
532
- maxFileSize: t = nt * 10,
533
- compressFiles: a,
534
- uploaderLocale: n,
535
- preventDuplicates: o,
536
- files: s
537
- }) {
538
- let i = !1;
539
- return {
540
- compressedFiles: await Promise.all(
541
- e?.map(async (d) => Xa({ fileSize: d?.size, maxFileSize: t }) ? (W({
542
- title: n.maxSizeExceededError.replace("MAX_FILE_SIZE", (t / 1024 || 0)?.toString()).replace(
543
- "UPLOADED_FILE_SIZE",
544
- (d?.size / 1024 / 1024 || 0)?.toFixed(1)?.toString()
545
- )
546
- }), a ? (await Wa({ file: d }))?.file : (i = !0, d)) : (o && $a({ fileName: d?.name, files: s }) && (W({
547
- title: n.duplicatesDenied
548
- }), i = !0), d))
549
- ),
550
- isInValid: i
551
- };
552
- }
553
- async function Ya({
554
- uploadedFiles: e,
555
- uploaderLocale: t,
556
- allowedTypes: a,
557
- isMulti: n,
558
- setFiles: o
559
- }) {
560
- return e?.map((s) => {
561
- if (s) {
562
- const i = qa(s?.type);
563
- if (!i) {
564
- W({
565
- title: `${t.errorUploadedTypes} ${a.join(", ")}`
566
- });
567
- return;
568
- }
569
- const l = new FileReader();
570
- l.onload = () => {
571
- o((d) => [
572
- ...n ? d : [],
573
- {
574
- file: s,
575
- view: l.result,
576
- type: i,
577
- url: URL.createObjectURL(s)
578
- }
579
- ]);
580
- }, l.readAsDataURL(s);
581
- }
582
- });
583
- }
584
- const te = ({
585
- defaultUploaderLocale: e,
586
- configUploaderLocale: t,
587
- contextUploaderLocale: a
588
- }) => ({
589
- ...e,
590
- ...t || {},
591
- ...a || {}
592
- }), Se = (e) => typeof e == "object" && e !== null && !Array.isArray(e), Ne = ({
593
- defaultLocales: e,
594
- configLocales: t
595
- }) => {
596
- const a = (n, o) => {
597
- if (o == null || Object.keys(o).length === 0)
598
- return n;
599
- const s = { ...n };
600
- for (const i of Object.keys(o)) {
601
- const l = o[i], d = n[i];
602
- l !== void 0 && (Se(l) && Se(d) ? s[i] = a(
603
- d,
604
- l
605
- ) : s[i] = l);
606
- }
607
- return s;
608
- };
609
- return a(
610
- e,
611
- t
612
- );
613
- }, Ja = w(["flex flex-col w-full"], {
614
- variants: {
615
- variant: {
616
- default: []
617
- }
618
- },
619
- defaultVariants: {},
620
- compoundVariants: []
621
- }), Ee = [
622
- "laptops",
623
- "desktops",
624
- "monitors",
625
- "keyboards",
626
- "mice",
627
- "headsets",
628
- "printers",
629
- "storage",
630
- "components",
631
- "networking"
632
- ], Le = [
633
- "Apple",
634
- "Dell",
635
- "HP",
636
- "Lenovo",
637
- "Asus",
638
- "Acer",
639
- "MSI",
640
- "Razer",
641
- "Samsung",
642
- "Microsoft"
643
- ], Pe = [
644
- "black",
645
- "gray",
646
- "white",
647
- "silver",
648
- "blue",
649
- "red"
650
- ], le = /* @__PURE__ */ new Date("2026-02-04T00:00:00.000Z"), Ae = [
651
- "Excellent performance for the price.",
652
- "Very quiet and fast machine.",
653
- "Solid build quality and screen.",
654
- "Battery life could be better.",
655
- "Perfect for gaming and streaming.",
656
- "Great value, highly recommended.",
657
- "Runs cool even under heavy load.",
658
- "Keyboard and trackpad feel premium.",
659
- "Display is bright and color-accurate.",
660
- "Setup was easy and straightforward."
661
- ], ze = [
662
- "Ahmed K.",
663
- "Sara M.",
664
- "Omar A.",
665
- "Lina H.",
666
- "Mohammed S.",
667
- "Nour E.",
668
- "Youssef R.",
669
- "Fatima D.",
670
- "Hassan T.",
671
- "Mona L."
672
- ], Ve = [
673
- 'Ultrabook Pro 14" Laptop',
674
- "Gaming Beast RTX Desktop",
675
- "Office Essential Mini PC",
676
- 'Curved 27" 2K Monitor',
677
- "Mechanical RGB Gaming Keyboard",
678
- "Wireless Silent Mouse",
679
- "Studio USB-C Headset",
680
- "All-in-One Color Printer",
681
- "1TB NVMe PCIe 4.0 SSD",
682
- "High-Airflow ATX Case"
683
- ], ke = [
684
- "Powerful and lightweight device ideal for productivity, study, and everyday use.",
685
- "High-end desktop designed for 1440p and 4K gaming with excellent cooling.",
686
- "Compact form factor PC optimized for office applications and web browsing.",
687
- "High refresh rate display with vivid colors and thin bezels for immersive work.",
688
- "Durable keyboard with customizable RGB lighting and fast mechanical switches.",
689
- "Ergonomic wireless mouse with precise sensor and long battery life.",
690
- "Comfortable over-ear headset with crystal-clear microphone and rich sound.",
691
- "Fast wireless printer with automatic duplex printing and mobile support.",
692
- "Next-generation SSD with blazing read and write speeds for fast boot times.",
693
- "Spacious case with optimized airflow, cable management, and tempered glass."
694
- ], Fe = [
695
- "https://images.pexels.com/photos/18105/pexels-photo.jpg",
696
- "https://images.pexels.com/photos/1714208/pexels-photo-1714208.jpeg",
697
- "https://images.pexels.com/photos/1714341/pexels-photo-1714341.jpeg",
698
- "https://images.pexels.com/photos/2047905/pexels-photo-2047905.jpeg",
699
- "https://images.pexels.com/photos/163117/keyboard-black-notebook-input-163117.jpeg",
700
- "https://images.pexels.com/photos/3829246/pexels-photo-3829246.jpeg",
701
- "https://images.pexels.com/photos/3394664/pexels-photo-3394664.jpeg",
702
- "https://images.pexels.com/photos/3996439/pexels-photo-3996439.jpeg",
703
- "https://images.pexels.com/photos/97077/pexels-photo-97077.jpeg",
704
- "https://images.pexels.com/photos/3945650/pexels-photo-3945650.jpeg"
705
- ], Qa = 2e3, Uo = (e, t = Qa) => () => new Promise((a) => {
706
- setTimeout(() => {
707
- e(), a();
708
- }, t);
709
- }), $ = [
710
- {
711
- id: "info",
712
- label: "Info",
713
- href: "#info",
714
- Icon: me
715
- },
716
- {
717
- id: "contact",
718
- label: "Contact",
719
- href: "#contact",
720
- Icon: pe
721
- },
722
- {
723
- id: "services",
724
- label: "Services",
725
- href: "#services",
726
- Icon: fe
727
- },
728
- {
729
- id: "settings",
730
- label: "Settings",
731
- href: "#settings",
732
- Icon: Bt
733
- },
734
- {
735
- id: "help",
736
- label: "Help",
737
- href: "#help",
738
- Icon: _t
739
- },
740
- {
741
- id: "support",
742
- label: "Support",
743
- href: "#support",
744
- Icon: Rt
745
- }
746
- ], Me = [
747
- {
748
- id: "home",
749
- label: "Home",
750
- href: "#home",
751
- Icon: Ue
752
- },
753
- {
754
- id: "about",
755
- label: "About",
756
- href: "#about",
757
- Icon: me
758
- },
759
- {
760
- id: "contact",
761
- label: "Contact",
762
- href: "#contact",
763
- Icon: pe
764
- },
765
- {
766
- id: "services",
767
- label: "Services",
768
- href: "#services",
769
- Icon: fe
770
- }
771
- ], er = [
772
- {
773
- id: "home",
774
- label: "Home",
775
- href: "#home",
776
- Icon: Ue,
777
- subItems: $
778
- },
779
- {
780
- id: "about",
781
- label: "About",
782
- href: "#about",
783
- Icon: me,
784
- subItems: $
785
- },
786
- {
787
- id: "contact",
788
- label: "Contact",
789
- href: "#contact",
790
- Icon: pe,
791
- subItems: $
792
- },
793
- {
794
- id: "services",
795
- label: "Services",
796
- href: "#services",
797
- Icon: fe,
798
- subItems: $
799
- }
800
- ], tr = [
801
- {
802
- key: "logout",
803
- label: "Logout",
804
- color: "danger",
805
- onPress: () => console.log("logout"),
806
- startContent: /* @__PURE__ */ r(Ot, {})
807
- }
808
- ], ye = (e, t) => Array.from({ length: e }, (a, n) => {
809
- const o = t + n + 1, s = n % 5 + 1 + n % 3 * 0.1, i = Number(Math.min(5, s).toFixed(1)), l = Ae[n % Ae?.length], d = ze[n % ze.length];
810
- return {
811
- id: o,
812
- rating: i,
813
- comment: l,
814
- author: d,
815
- createdAt: le,
816
- updatedAt: le
817
- };
818
- }), ar = ye(10, 0), rr = ye(50, 10), nr = ye(100, 60), or = (e) => {
819
- const t = e % 5 + 1, a = [];
820
- for (let n = 0; n < t; n += 1) {
821
- const o = {
822
- label: Ee[(e + n) % Ee.length],
823
- startContent: /* @__PURE__ */ r(Ut, { className: "size-3 fill-current" })
824
- };
825
- a.includes(o) || a.push(o);
826
- }
827
- return a;
828
- }, sr = (e) => {
829
- if (e < 10) return ar;
830
- if (e < 30) return rr;
831
- const a = e % (100 + 1);
832
- return nr.slice(0, a);
833
- }, ir = (e) => {
834
- if (!e.length) return 0;
835
- const a = e.reduce((n, o) => n + o.rating, 0) / e.length;
836
- return Number(a.toFixed(1));
837
- }, ut = Array.from(
838
- { length: 50 },
839
- (e, t) => {
840
- const a = t + 1, n = Le[t % Le.length], o = Pe[t % Pe.length], s = Ve[t % Ve.length], i = ke[t % ke.length], l = Fe[t % Fe.length], d = 300 + t % 10 * 75, u = t % 3 * 50, p = d + u, m = t % 7 !== 0, f = t % 6 === 0, h = t % 5 === 0, v = sr(t), g = ir(v), y = new Date(
841
- le.getTime() - t * 24 * 60 * 60 * 1e3
842
- ), S = y;
843
- return {
844
- id: a,
845
- title: s,
846
- description: i,
847
- image: l,
848
- price: p,
849
- categories: or(t),
850
- isAvailable: m,
851
- isBestSeller: f,
852
- isTopRated: h,
853
- averageRating: g,
854
- reviews: v,
855
- brand: n,
856
- color: o,
857
- createdAt: y,
858
- updatedAt: S
859
- };
860
- }
861
- ), Ho = async ({
862
- page: e = 1,
863
- pageSize: t = 12
864
- }) => {
865
- const a = ut.slice((e - 1) * t, e * t);
866
- return await new Promise((n) => {
867
- setTimeout(n, 2e3);
868
- }), {
869
- items: a
870
- };
871
- }, jo = async () => (await new Promise((e) => {
872
- setTimeout(e, 2e3);
873
- }), {
874
- item: ut[0]
875
- }), Go = {
876
- [A.ENGLISH]: {
877
- dropHere: "Drop your custom file here",
878
- selectFile: "Choose a custom file or drag it here",
879
- selectionTypes: "PNG, JPG or PDF, max size 5MB (custom localized)",
880
- selectBtn: "Browse custom files",
881
- errorUploadingFile: "Custom error: please upload at least one file",
882
- maxNumImages: "Custom limit reached for uploaded images: ",
883
- errorUploadedTypes: "Custom error: allowed file types are only: ",
884
- maxSizeExceededError: "Custom error: maximum allowed size is MAX_FILE_SIZE MB, but your file is UPLOADED_FILE_SIZE MB",
885
- duplicatesDenied: "Custom error: duplicate file names are not allowed, please rename before uploading"
886
- },
887
- [A.ARABIC]: {
888
- dropHere: "أسقط الملف المخصص هنا",
889
- selectFile: "اختر ملفًا مخصصًا أو اسحبه إلى هنا",
890
- selectionTypes: "PNG، JPG أو PDF، الحجم الأقصى 5MB (نص مخصص)",
891
- selectBtn: "استعراض الملفات المخصصة",
892
- errorUploadingFile: "خطأ مخصص: يرجى رفع ملف واحد على الأقل",
893
- maxNumImages: "خطأ مخصص: تم الوصول إلى الحد الأقصى للصور المرفوعة: ",
894
- errorUploadedTypes: "خطأ مخصص: يمكنك فقط رفع الملفات من الأنواع التالية: ",
895
- maxSizeExceededError: "خطأ مخصص: الحد الأقصى المسموح هو MAX_FILE_SIZE ميغابايت، بينما حجم ملفك هو UPLOADED_FILE_SIZE ميغابايت",
896
- duplicatesDenied: "خطأ مخصص: لا يمكنك رفع ملفات بأسماء مكررة، يرجى إعادة تسميتها قبل الرفع"
897
- }
898
- }, lr = {
899
- enabled: !0,
900
- blur: 10,
901
- backgroundColor: "#006fed",
902
- foregroundColor: "#fff",
903
- opacity: 40
904
- }, Wo = P(({ className: e, variant: t = "default", children: a, ...n }, o) => /* @__PURE__ */ b(
905
- "main",
906
- {
907
- ref: o,
908
- "data-slot": "emperor-landing-page",
909
- className: c(Ja({ className: e })),
910
- ...n,
911
- children: [
912
- /* @__PURE__ */ b(Wn, { variant: "floating", glassEffect: lr, children: [
913
- /* @__PURE__ */ r(ce, {}),
914
- /* @__PURE__ */ r(
915
- Ct,
916
- {
917
- items: er,
918
- hoverEffect: "none",
919
- variant: "default",
920
- className: "hidden md:flex",
921
- subItemsColumns: 4
922
- }
923
- )
924
- ] }),
925
- /* @__PURE__ */ b("main", { className: "w-full container mx-auto p-5 pt-24 flex flex-col gap-6", children: [
926
- /* @__PURE__ */ r("p", { children: q }),
927
- /* @__PURE__ */ r("p", { children: q }),
928
- /* @__PURE__ */ r("p", { children: q }),
929
- /* @__PURE__ */ r("p", { children: q }),
930
- /* @__PURE__ */ r("p", { children: q })
931
- ] }),
932
- a
933
- ]
934
- }
935
- ));
936
- function mt({
937
- className: e,
938
- classNames: t,
939
- hoverEffect: a = "none",
940
- orientation: n = "vertical"
941
- }) {
942
- return /* @__PURE__ */ r(
943
- F.div,
944
- {
945
- ...ot({}),
946
- "data-slot": "emperor-ui-item-card",
947
- className: c(
948
- ht({ orientation: n }),
949
- t?.base,
950
- e
951
- ),
952
- children: /* @__PURE__ */ b(
953
- Te,
954
- {
955
- shadow: "sm",
956
- "data-slot": "emperor-ui-item-card-main-wrapper",
957
- className: c(
958
- gt({ orientation: n }),
959
- t?.mainWrapper
960
- ),
961
- children: [
962
- /* @__PURE__ */ r(
963
- Be,
964
- {
965
- "data-slot": "emperor-ui-item-card-header",
966
- className: c(bt({ orientation: n }), t?.header),
967
- children: /* @__PURE__ */ r(
968
- T,
969
- {
970
- className: c(
971
- vt({ orientation: n }),
972
- t?.imageWrapper
973
- )
974
- }
975
- )
976
- }
977
- ),
978
- /* @__PURE__ */ b(
979
- _e,
980
- {
981
- "data-slot": "emperor-ui-item-card-body",
982
- className: c(wt({ orientation: n }), t?.body),
983
- children: [
984
- /* @__PURE__ */ b("div", { className: "flex items-start justify-between gap-2", children: [
985
- /* @__PURE__ */ r(T, { className: "h-5 flex-1 rounded-lg" }),
986
- /* @__PURE__ */ r(T, { className: "size-8 shrink-0 rounded-lg" })
987
- ] }),
988
- /* @__PURE__ */ r(T, { className: "h-4 w-4/5 rounded-lg" }),
989
- /* @__PURE__ */ r(T, { className: "h-4 w-full rounded-lg" })
990
- ]
991
- }
992
- ),
993
- /* @__PURE__ */ r(
994
- Re,
995
- {
996
- "data-slot": "emperor-ui-item-card-footer",
997
- className: c(xt({ orientation: n }), t?.footer),
998
- children: /* @__PURE__ */ b(
999
- "menu",
1000
- {
1001
- "data-slot": "emperor-ui-item-card-chips",
1002
- className: c(yt({ orientation: n }), t?.chips),
1003
- children: [
1004
- " ",
1005
- /* @__PURE__ */ r(T, { className: "h-6 w-16 rounded-full" }),
1006
- /* @__PURE__ */ r(T, { className: "h-6 w-20 rounded-full" }),
1007
- /* @__PURE__ */ r(T, { className: "h-6 w-14 rounded-full" })
1008
- ]
1009
- }
1010
- )
1011
- }
1012
- )
1013
- ]
1014
- }
1015
- )
1016
- }
1017
- );
1018
- }
1019
- function cr({
1020
- item: e,
1021
- orientation: t,
1022
- classNames: a
1023
- }) {
1024
- return e?.banner ? /* @__PURE__ */ r(
1025
- "div",
1026
- {
1027
- "data-slot": "emperor-ui-item-card-banner",
1028
- className: c(xr({ orientation: t }), a?.banner),
1029
- children: e?.banner
1030
- }
1031
- ) : null;
1032
- }
1033
- function x() {
1034
- const e = Z(ie);
1035
- if (!e)
1036
- throw new Error("useEmperorUI must be used within a EmperorUIProvider");
1037
- return e;
1038
- }
1039
- function pt() {
1040
- const e = Z(st);
1041
- if (!e)
1042
- throw new Error("useNavigation must be used within a NavigationProvider");
1043
- return e;
1044
- }
1045
- const ne = "URLSearchParamsChange";
1046
- function V() {
1047
- const e = R(() => {
1048
- if (typeof window > "u")
1049
- return {};
1050
- const u = new URLSearchParams(window.location.search);
1051
- return Array.from(u.entries()).reduce((p, [m, f]) => (p[m] = f, p), {});
1052
- }, []), [t, a] = I(
1053
- () => e()
1054
- ), n = R(
1055
- ({ searchParams: u }) => {
1056
- if (typeof window > "u") return;
1057
- const p = u.toString(), m = p ? `?${p}` : "", f = `${window.location.pathname}${m}${window.location.hash}`, h = `${window.location.pathname}${window.location.search}${window.location.hash}`;
1058
- f !== h && (window.history.replaceState(window.history.state, "", f), window.dispatchEvent(new Event(ne)));
1059
- },
1060
- []
1061
- ), o = R(
1062
- ({
1063
- params: u,
1064
- options: p = { replace: !0 }
1065
- }) => {
1066
- if (typeof window > "u") return;
1067
- const m = new URLSearchParams(window.location.search);
1068
- let f = !1;
1069
- Object.entries(u).forEach(([h, v]) => {
1070
- if (v == null || v === "") {
1071
- const C = m.has(h);
1072
- m.delete(h), C && (f = !0);
1073
- return;
1074
- }
1075
- const g = String(v);
1076
- if (p.replace) {
1077
- const C = m.getAll(h);
1078
- if (C.length === 1 && C[0] === g)
1079
- return;
1080
- m.delete(h), m.append(h, g), f = !0;
1081
- return;
1082
- }
1083
- m.getAll(h).some(
1084
- (C) => C === g
1085
- ) || (m.append(h, g), f = !0);
1086
- }), f && n({ searchParams: m });
1087
- },
1088
- // eslint-disable-next-line react-hooks/exhaustive-deps
1089
- []
1090
- ), s = R(
1091
- ({ key: u }) => {
1092
- if (typeof window > "u")
1093
- return;
1094
- const p = new URLSearchParams(window.location.search);
1095
- p.delete(u), n({ searchParams: p });
1096
- },
1097
- // eslint-disable-next-line react-hooks/exhaustive-deps
1098
- []
1099
- ), i = R(
1100
- ({ keys: u }) => {
1101
- if (typeof window > "u") return;
1102
- const p = new URLSearchParams(window.location.search);
1103
- let m = !1;
1104
- u.forEach((f) => {
1105
- const h = p.has(f);
1106
- p.delete(f), h && (m = !0);
1107
- }), m && n({ searchParams: p });
1108
- },
1109
- // eslint-disable-next-line react-hooks/exhaustive-deps
1110
- []
1111
- ), l = R(() => {
1112
- typeof window > "u" || window.location.search && n({ searchParams: new URLSearchParams() });
1113
- }, [n]), d = R((u) => typeof window > "u" ? null : new URLSearchParams(window.location.search).get(u), []);
1114
- return O(() => {
1115
- if (typeof window > "u")
1116
- return;
1117
- const u = () => {
1118
- a(e());
1119
- };
1120
- return u(), window.addEventListener("popstate", u), window.addEventListener(ne, u), () => {
1121
- window.removeEventListener("popstate", u), window.removeEventListener(ne, u);
1122
- };
1123
- }, [e]), {
1124
- getParam: d,
1125
- allParams: t,
1126
- setParams: o,
1127
- deleteParam: s,
1128
- deleteParams: i,
1129
- clearParams: l
1130
- };
1131
- }
1132
- function H() {
1133
- const e = Z(it);
1134
- if (!e)
1135
- throw new Error(
1136
- "useUploaderContext must be used within a UploaderProvider"
1137
- );
1138
- return e;
1139
- }
1140
- const qo = ({
1141
- labelContent: e,
1142
- labelId: t,
1143
- fileTypes: a,
1144
- isRequired: n = !1,
1145
- isDraggable: o = !0,
1146
- isMulti: s = !1,
1147
- preventDuplicates: i = !0,
1148
- maxCount: l = 10,
1149
- maxFileSize: d = nt * 10,
1150
- compressFiles: u = !1,
1151
- onChange: p = () => {
1152
- },
1153
- locales: m
1154
- }) => {
1155
- const { config: f } = x(), [h, v] = I([]), [g, y] = I(!1), S = f?.interLocalization?.locales, C = f?.interLocalization?.lang || f?.interLocalization?.defaultLanguage || "en", z = ee(C), M = te({
1156
- defaultUploaderLocale: z.atoms.uploader,
1157
- configUploaderLocale: S?.[C]?.atoms?.uploader,
1158
- contextUploaderLocale: m
1159
- });
1160
- return {
1161
- files: h,
1162
- fileTypes: a,
1163
- labelId: t,
1164
- isRequired: n,
1165
- labelContent: e,
1166
- isDraggable: o,
1167
- isMulti: s,
1168
- handleClearFile: (N) => {
1169
- if (v((D) => D?.filter((_) => _?.file?.name !== N)), t) {
1170
- const D = document.getElementById(t);
1171
- D && (D.value = "");
1172
- }
1173
- },
1174
- onInputChange: async (N) => {
1175
- if (console.log("files: ", N.target.files), (!N.target.files || !N.target.files?.[0]) && (!N?.dataTransfer?.files || !N?.dataTransfer?.files[0]))
1176
- return W({
1177
- title: M.errorUploadingFile
1178
- });
1179
- const D = Ka(a);
1180
- if (!N.target.files && !N.dataTransfer.files) return;
1181
- const _ = Array.from(
1182
- N.target.files || N.dataTransfer.files
1183
- );
1184
- if (s && (_?.length > l || h?.length + _?.length > l)) {
1185
- W({
1186
- title: `${M.maxNumImages} ${l}`
1187
- });
1188
- return;
1189
- }
1190
- if (!_?.map((re) => re?.type)?.every((re) => D.includes(re))) {
1191
- W({
1192
- title: M.errorUploadedTypes
1193
- });
1194
- return;
1195
- }
1196
- const { compressedFiles: Ce, isInValid: ae } = await Za({
1197
- uploadedFiles: _,
1198
- maxFileSize: d,
1199
- compressFiles: u,
1200
- preventDuplicates: i,
1201
- files: h,
1202
- uploaderLocale: M
1203
- });
1204
- ae || (y(!0), await Promise.all(
1205
- await Ya({
1206
- uploadedFiles: Ce,
1207
- uploaderLocale: M,
1208
- allowedTypes: D,
1209
- isMulti: s,
1210
- setFiles: v
1211
- })
1212
- ).finally(() => {
1213
- y(!1);
1214
- }), setTimeout(() => {
1215
- p();
1216
- }, 200), N.target && "value" in N.target && N.target.files && (N.target.value = ""));
1217
- },
1218
- setFiles: v,
1219
- isLoading: g,
1220
- locales: m
1221
- };
1222
- }, K = {
1223
- sm: 640,
1224
- md: 768,
1225
- lg: 1024,
1226
- xl: 1280,
1227
- "2xl": 1536
1228
- }, dr = () => {
1229
- const [e, t] = I({ width: 0, height: 0 });
1230
- O(() => {
1231
- function s() {
1232
- t({ width: window.innerWidth, height: window.innerHeight });
1233
- }
1234
- return window.addEventListener("resize", s), s(), () => window.removeEventListener("resize", s);
1235
- }, []);
1236
- const a = E(() => e?.width > K?.["2xl"] ? "2xl" : e?.width > K?.xl ? "xl" : e?.width > K?.lg ? "lg" : e?.width > K?.md ? "md" : e?.width > K?.sm ? "sm" : "base", [e]), n = E(
1237
- () => ["base", "sm", "md"].includes(a),
1238
- [a]
1239
- ), o = E(
1240
- () => ["base"].includes(a),
1241
- [a]
1242
- );
1243
- return {
1244
- viewportWidth: e.width,
1245
- viewportHeight: e.height,
1246
- currentScreen: a,
1247
- isSmallDevice: n,
1248
- isExtraSmallDevice: o
1249
- };
1250
- };
1251
- function Ko() {
1252
- const { allParams: e, clearParams: t } = V();
1253
- return { filters: E(() => Object.keys(e).length ? e : null, [e]), clearFilters: t };
1254
- }
1255
- function j() {
1256
- const e = Z(lt);
1257
- if (!e)
1258
- throw new Error(
1259
- "'useFormBuilder' must be used within a 'FormBuilderProvider', make sure to wrap 'Field' components with 'FormBuilder' as well."
1260
- );
1261
- return e;
1262
- }
1263
- function ur({
1264
- variants: e,
1265
- isLoading: t = !1,
1266
- className: a,
1267
- classNames: n,
1268
- item: o,
1269
- actions: s = [],
1270
- hoverEffect: i = "none",
1271
- onActionClick: l,
1272
- orientation: d = "vertical",
1273
- actionsViewVariant: u = "dropdown"
1274
- }) {
1275
- const { isExtraSmallDevice: p } = dr(), m = p ? "vertical" : d;
1276
- if (t)
1277
- return /* @__PURE__ */ r(
1278
- mt,
1279
- {
1280
- className: a,
1281
- classNames: n,
1282
- orientation: m
1283
- }
1284
- );
1285
- const f = s && s.length > 0, h = u === "dropdown", v = u === "hover-overlay";
1286
- return /* @__PURE__ */ r(
1287
- F.div,
1288
- {
1289
- "data-slot": "emperor-ui-item-card",
1290
- className: c(
1291
- ht({ orientation: m }),
1292
- "group",
1293
- n?.base,
1294
- a
1295
- ),
1296
- variants: e,
1297
- ...ot({}),
1298
- children: /* @__PURE__ */ b(
1299
- Te,
1300
- {
1301
- shadow: "sm",
1302
- "data-slot": "emperor-ui-item-card-main-wrapper",
1303
- className: c(
1304
- gt({ orientation: m }),
1305
- "relative overflow-hidden",
1306
- n?.mainWrapper
1307
- ),
1308
- children: [
1309
- /* @__PURE__ */ r(
1310
- mr,
1311
- {
1312
- item: o,
1313
- orientation: m,
1314
- classNames: n,
1315
- actions: s,
1316
- onActionClick: l,
1317
- actionsViewVariant: h ? "dropdown" : u
1318
- }
1319
- ),
1320
- /* @__PURE__ */ r(
1321
- pr,
1322
- {
1323
- item: o,
1324
- orientation: m,
1325
- classNames: n,
1326
- actions: s,
1327
- onActionClick: l,
1328
- actionsViewVariant: h ? "dropdown" : u
1329
- }
1330
- ),
1331
- /* @__PURE__ */ r(
1332
- fr,
1333
- {
1334
- item: o,
1335
- orientation: m,
1336
- classNames: n,
1337
- actions: s,
1338
- onActionClick: l,
1339
- actionsViewVariant: u
1340
- }
1341
- ),
1342
- v && f && /* @__PURE__ */ r(
1343
- gr,
1344
- {
1345
- actions: s,
1346
- classNames: n,
1347
- onActionClick: l,
1348
- orientation: m
1349
- }
1350
- )
1351
- ]
1352
- }
1353
- )
1354
- }
1355
- );
1356
- }
1357
- function mr({
1358
- item: e,
1359
- orientation: t,
1360
- classNames: a,
1361
- actions: n,
1362
- onActionClick: o,
1363
- actionsViewVariant: s = "dropdown"
1364
- }) {
1365
- return /* @__PURE__ */ b(
1366
- Be,
1367
- {
1368
- "data-slot": "emperor-ui-item-card-header",
1369
- className: c(bt({ orientation: t }), a?.header),
1370
- children: [
1371
- e?.image && /* @__PURE__ */ r(
1372
- "div",
1373
- {
1374
- "data-slot": "emperor-ui-item-card-image-wrapper",
1375
- className: c(
1376
- vt({ orientation: t }),
1377
- a?.imageWrapper
1378
- ),
1379
- children: /* @__PURE__ */ r(
1380
- he,
1381
- {
1382
- "data-slot": "emperor-ui-item-card-image",
1383
- src: e?.image?.src,
1384
- alt: e?.image?.alt,
1385
- className: c("size-full object-cover", a?.image),
1386
- radius: "none",
1387
- removeWrapper: !0
1388
- }
1389
- )
1390
- }
1391
- ),
1392
- /* @__PURE__ */ r(
1393
- cr,
1394
- {
1395
- item: e,
1396
- orientation: t,
1397
- classNames: a
1398
- }
1399
- ),
1400
- t === "vertical" && s === "dropdown" && /* @__PURE__ */ r(
1401
- ft,
1402
- {
1403
- actions: n,
1404
- classNames: a,
1405
- onActionClick: o
1406
- }
1407
- )
1408
- ]
1409
- }
1410
- );
1411
- }
1412
- function pr({
1413
- item: e,
1414
- orientation: t,
1415
- classNames: a,
1416
- actions: n,
1417
- onActionClick: o,
1418
- actionsViewVariant: s = "dropdown"
1419
- }) {
1420
- return /* @__PURE__ */ b(
1421
- _e,
1422
- {
1423
- "data-slot": "emperor-ui-item-card-body",
1424
- className: c(wt({ orientation: t }), a?.body),
1425
- children: [
1426
- e?.title && /* @__PURE__ */ r(
1427
- "h3",
1428
- {
1429
- "data-slot": "emperor-ui-item-card-title",
1430
- className: c(vr({ orientation: t }), a?.title),
1431
- children: e?.title
1432
- }
1433
- ),
1434
- e?.description && /* @__PURE__ */ r(
1435
- "p",
1436
- {
1437
- "data-slot": "emperor-ui-item-card-description",
1438
- className: c(
1439
- wr({ orientation: t }),
1440
- a?.description
1441
- ),
1442
- children: e?.description
1443
- }
1444
- ),
1445
- e?.price && /* @__PURE__ */ r(
1446
- "p",
1447
- {
1448
- "data-slot": "emperor-ui-item-card-price",
1449
- className: c(br({ orientation: t }), a?.price),
1450
- children: e?.price
1451
- }
1452
- ),
1453
- t === "horizontal" && s === "dropdown" && /* @__PURE__ */ r(
1454
- ft,
1455
- {
1456
- actions: n,
1457
- classNames: a,
1458
- onActionClick: o
1459
- }
1460
- )
1461
- ]
1462
- }
1463
- );
1464
- }
1465
- function fr({
1466
- item: e,
1467
- orientation: t,
1468
- classNames: a,
1469
- actions: n,
1470
- onActionClick: o,
1471
- actionsViewVariant: s = "dropdown"
1472
- }) {
1473
- return /* @__PURE__ */ b(
1474
- Re,
1475
- {
1476
- "data-slot": "emperor-ui-item-card-footer",
1477
- className: c(xt({ orientation: t }), a?.footer),
1478
- children: [
1479
- e?.chips && e?.chips?.length > 0 && /* @__PURE__ */ r(
1480
- "menu",
1481
- {
1482
- "data-slot": "emperor-ui-item-card-chips",
1483
- className: c(yt({ orientation: t }), a?.chips),
1484
- children: e?.chips?.map(
1485
- ({
1486
- label: i,
1487
- className: l,
1488
- classNames: d,
1489
- ...u
1490
- }, p) => /* @__PURE__ */ r(
1491
- Yt,
1492
- {
1493
- "data-slot": "emperor-ui-item-card-chip",
1494
- className: c(l, a?.chip),
1495
- classNames: {
1496
- content: "text-xs mx-1",
1497
- ...d
1498
- },
1499
- size: "sm",
1500
- variant: "flat",
1501
- color: "primary",
1502
- ...u,
1503
- children: i
1504
- },
1505
- p
1506
- )
1507
- )
1508
- }
1509
- ),
1510
- s === "buttons" && n && n?.length > 0 && /* @__PURE__ */ r(
1511
- hr,
1512
- {
1513
- actions: n,
1514
- classNames: a,
1515
- onActionClick: o,
1516
- className: "ml-auto"
1517
- }
1518
- )
1519
- ]
1520
- }
1521
- );
1522
- }
1523
- function ft({
1524
- actions: e,
1525
- classNames: t,
1526
- onActionClick: a
1527
- }) {
1528
- return !e || e?.length === 0 ? null : /* @__PURE__ */ b(Jt, { placement: "bottom-end", children: [
1529
- /* @__PURE__ */ r(Qt, { "data-slot": "emperor-ui-item-card-actions-dropdown-trigger", children: /* @__PURE__ */ r(
1530
- L,
1531
- {
1532
- isIconOnly: !0,
1533
- size: "sm",
1534
- variant: "flat",
1535
- radius: "full",
1536
- className: c(
1537
- "absolute right-2 top-2 z-10 size-7 min-w-7 backdrop-blur-lg",
1538
- "border border-default-300",
1539
- t?.dropdown
1540
- ),
1541
- children: /* @__PURE__ */ r(Ht, { className: "size-4" })
1542
- }
1543
- ) }),
1544
- /* @__PURE__ */ r(
1545
- ea,
1546
- {
1547
- "data-slot": "emperor-ui-item-card-actions-dropdown-menu",
1548
- "aria-label": "Card actions",
1549
- onAction: (n) => a?.(String(n)),
1550
- items: e,
1551
- children: ({ key: n, label: o, ...s }) => /* @__PURE__ */ r(
1552
- ta,
1553
- {
1554
- "data-slot": "emperor-ui-item-card-actions-dropdown-item",
1555
- textValue: o,
1556
- title: o,
1557
- ...s
1558
- },
1559
- n
1560
- )
1561
- }
1562
- )
1563
- ] });
1564
- }
1565
- function hr({
1566
- actions: e,
1567
- classNames: t,
1568
- onActionClick: a,
1569
- className: n
1570
- }) {
1571
- return !e || e.length === 0 ? null : /* @__PURE__ */ r(
1572
- "div",
1573
- {
1574
- "data-slot": "emperor-ui-item-card-actions-buttons",
1575
- className: c("flex flex-wrap gap-2", t?.actions, n),
1576
- children: e.map(
1577
- ({ key: o, label: s, className: i, ...l }, d) => /* @__PURE__ */ r(
1578
- L,
1579
- {
1580
- "data-slot": "emperor-ui-item-card-actions-button",
1581
- size: "sm",
1582
- className: c(t?.action, i),
1583
- onPress: () => o && a?.(String(o)),
1584
- ...l,
1585
- children: s
1586
- },
1587
- o ?? d
1588
- )
1589
- )
1590
- }
1591
- );
1592
- }
1593
- function gr({
1594
- actions: e,
1595
- classNames: t,
1596
- onActionClick: a,
1597
- orientation: n
1598
- }) {
1599
- return !e || e?.length === 0 ? null : /* @__PURE__ */ r(
1600
- "div",
1601
- {
1602
- "data-slot": "emperor-ui-item-card-actions-overlay",
1603
- className: c(
1604
- "absolute inset-0 z-20 gap-3 flex items-center justify-center bg-black/60 opacity-0",
1605
- n === "horizontal" ? "flex-row" : "flex-col",
1606
- "transition-opacity duration-200 group-hover:opacity-100",
1607
- t?.actions
1608
- ),
1609
- children: e?.map(
1610
- ({ key: o, label: s, className: i, ...l }, d) => /* @__PURE__ */ r(aa, { content: s, children: /* @__PURE__ */ r(
1611
- L,
1612
- {
1613
- "data-slot": "emperor-ui-item-card-actions-overlay-button",
1614
- isIconOnly: !0,
1615
- radius: "full",
1616
- className: c(t?.action, i),
1617
- onPress: () => o && a?.(String(o)),
1618
- ...l
1619
- },
1620
- o ?? d
1621
- ) })
1622
- )
1623
- }
1624
- );
1625
- }
1626
- const ht = w(["w-full relative"], {
1627
- variants: {
1628
- orientation: {
1629
- vertical: "max-w-80",
1630
- horizontal: "min-w-full max-w-full"
1631
- }
1632
- },
1633
- defaultVariants: {},
1634
- compoundVariants: []
1635
- }), gt = w(["size-full"], {
1636
- variants: {
1637
- orientation: {
1638
- vertical: "flex flex-col",
1639
- horizontal: "grid grid-cols-[200px_auto]"
1640
- }
1641
- },
1642
- defaultVariants: {},
1643
- compoundVariants: []
1644
- }), vt = w(
1645
- ["relative aspect-4/3 overflow-hidden"],
1646
- {
1647
- variants: {
1648
- orientation: {
1649
- vertical: "w-full",
1650
- horizontal: "w-fit h-full"
1651
- }
1652
- },
1653
- defaultVariants: {},
1654
- compoundVariants: []
1655
- }
1656
- ), bt = w(["relative p-0"], {
1657
- variants: {
1658
- orientation: {
1659
- vertical: "",
1660
- horizontal: "row-span-2"
1661
- }
1662
- },
1663
- defaultVariants: {},
1664
- compoundVariants: []
1665
- }), wt = w(["relative flex flex-col gap-2 p-4"], {
1666
- variants: {
1667
- orientation: {
1668
- vertical: "",
1669
- horizontal: ""
1670
- }
1671
- },
1672
- defaultVariants: {},
1673
- compoundVariants: []
1674
- }), xt = w(
1675
- ["flex flex-wrap flex-col p-4 gap-4 items-start"],
1676
- {
1677
- variants: {
1678
- orientation: {
1679
- vertical: "",
1680
- horizontal: "justify-end"
1681
- }
1682
- },
1683
- defaultVariants: {},
1684
- compoundVariants: []
1685
- }
1686
- ), vr = w(
1687
- ["line-clamp-1 font-semibold text-foreground"],
1688
- {
1689
- variants: {
1690
- orientation: {
1691
- vertical: "",
1692
- horizontal: "w-[calc(100%-30px)]"
1693
- }
1694
- },
1695
- defaultVariants: {},
1696
- compoundVariants: []
1697
- }
1698
- ), br = w(["text-2xl font-bold text-foreground"], {
1699
- variants: {
1700
- orientation: {
1701
- vertical: "",
1702
- horizontal: ""
1703
- }
1704
- },
1705
- defaultVariants: {},
1706
- compoundVariants: []
1707
- }), wr = w(
1708
- ["line-clamp-2 text-sm text-default-600"],
1709
- {
1710
- variants: {
1711
- orientation: {
1712
- vertical: "",
1713
- horizontal: ""
1714
- }
1715
- },
1716
- defaultVariants: {},
1717
- compoundVariants: []
1718
- }
1719
- ), yt = w(["flex flex-wrap items-center gap-2 p-1"], {
1720
- variants: {
1721
- orientation: {
1722
- vertical: "",
1723
- horizontal: ""
1724
- }
1725
- },
1726
- defaultVariants: {},
1727
- compoundVariants: []
1728
- }), xr = w(
1729
- [
1730
- "absolute left-0 top-0 z-10 px-2 py-1 text-xs font-semibold",
1731
- "bg-primary-500/50 backdrop-blur-sm text-center flex justify-center items-center",
1732
- "-rotate-45 w-full text-white"
1733
- ],
1734
- {
1735
- variants: {
1736
- orientation: {
1737
- vertical: "-translate-x-28 translate-y-7",
1738
- horizontal: "-translate-x-14 translate-y-7"
1739
- }
1740
- },
1741
- defaultVariants: {},
1742
- compoundVariants: []
1743
- }
1744
- ), yr = w(["relative flex items-center gap-3"], {
1745
- variants: {
1746
- hoverEffect: {
1747
- default: [],
1748
- solid: [],
1749
- underline: [],
1750
- ghost: [],
1751
- bordered: [],
1752
- none: []
1753
- },
1754
- variant: {
1755
- default: [],
1756
- solid: [],
1757
- bordered: []
1758
- }
1759
- },
1760
- defaultVariants: {
1761
- hoverEffect: "default",
1762
- variant: "default"
1763
- }
1764
- }), Cr = w(["size-full flex items-center"], {
1765
- variants: {
1766
- variant: {
1767
- default: [],
1768
- solid: [],
1769
- bordered: []
1770
- }
1771
- },
1772
- defaultVariants: {
1773
- variant: "default"
1774
- }
1775
- }), Ir = w(
1776
- [
1777
- "relative cursor-pointer px-4 py-2 transition-all font-semibold flex items-center gap-2"
1778
- ],
1779
- {
1780
- variants: {
1781
- hoverEffect: {
1782
- default: [],
1783
- solid: ["hover:opacity-80"],
1784
- underline: [
1785
- "relative font-bold",
1786
- "before:absolute before:bottom-0 before:left-0",
1787
- "before:h-0.5 before:w-full before:bg-current before:rounded-lg",
1788
- "before:scale-x-0 before:transition-transform hover:before:scale-x-100"
1789
- ],
1790
- ghost: [],
1791
- bordered: ["last:border-r-2! first:border-l-2!"],
1792
- none: []
1793
- },
1794
- variant: {
1795
- default: [],
1796
- solid: [],
1797
- bordered: ["last:border-r-2! first:border-l-2!"]
1798
- }
1799
- },
1800
- defaultVariants: {
1801
- hoverEffect: "default",
1802
- variant: "default"
1803
- }
1804
- }
1805
- ), Sr = ({
1806
- primaryColor: e,
1807
- foregroundColor: t,
1808
- variant: a
1809
- }) => a === "solid" ? {
1810
- backgroundColor: e,
1811
- color: t
1812
- } : {}, Nr = ({}) => ({}), Er = ({
1813
- foregroundColor: e,
1814
- hoverEffect: t,
1815
- primaryColor: a,
1816
- isHovered: n,
1817
- variant: o
1818
- }) => t === "solid" ? {
1819
- color: e,
1820
- backgroundColor: a
1821
- } : t === "underline" ? {
1822
- // color: primaryColor,
1823
- } : t === "ghost" ? {
1824
- color: n ? a : e,
1825
- backgroundColor: n ? "transparent" : a,
1826
- borderColor: n ? a : "transparent",
1827
- borderWidth: "2px",
1828
- borderStyle: "solid"
1829
- } : t === "bordered" ? {
1830
- color: n ? e : a,
1831
- backgroundColor: n ? a : "transparent",
1832
- borderColor: n ? "transparent" : a,
1833
- borderTopWidth: "2px",
1834
- borderBottomWidth: "2px",
1835
- borderRightWidth: "1px",
1836
- borderLeftWidth: "1px",
1837
- borderStyle: "solid"
1838
- } : o === "bordered" ? {
1839
- color: a,
1840
- backgroundColor: "transparent",
1841
- borderColor: a,
1842
- borderTopWidth: "2px",
1843
- borderBottomWidth: "2px",
1844
- borderRightWidth: "1px",
1845
- borderLeftWidth: "1px",
1846
- borderStyle: "solid"
1847
- } : {}, Ct = P(
1848
- ({
1849
- className: e,
1850
- hoverEffect: t = "default",
1851
- variant: a = "default",
1852
- items: n = [],
1853
- subItemsColumns: o = 3,
1854
- ...s
1855
- }, i) => /* @__PURE__ */ b(
1856
- "nav",
1857
- {
1858
- ref: i,
1859
- "data-slot": "emperor-nav-bar",
1860
- className: c(yr({ hoverEffect: t, variant: a, className: e })),
1861
- style: Sr({
1862
- variant: a
1863
- }),
1864
- ...s,
1865
- children: [
1866
- /* @__PURE__ */ r(
1867
- "ul",
1868
- {
1869
- className: c(Cr({ className: e })),
1870
- style: Nr({}),
1871
- "data-slot": "emperor-nav-bar-menu",
1872
- children: n?.map((l) => /* @__PURE__ */ r(
1873
- Pr,
1874
- {
1875
- item: l,
1876
- variant: a,
1877
- hoverEffect: t
1878
- },
1879
- l.id
1880
- ))
1881
- }
1882
- ),
1883
- /* @__PURE__ */ r(Lr, { subItemsColumns: o })
1884
- ]
1885
- }
1886
- )
1887
- ), Lr = ({ subItemsColumns: e = 3 }) => {
1888
- const {
1889
- hoveredItemId: t,
1890
- subItems: a,
1891
- isSubItemsBoxOpen: n,
1892
- subItemsBoxIsHovered: o,
1893
- setSubItemsBoxIsHovered: s,
1894
- setIsSubItemsBoxOpen: i
1895
- } = pt(), l = n || o;
1896
- return /* @__PURE__ */ r(
1897
- "div",
1898
- {
1899
- className: c(
1900
- "absolute top-full left-0 w-full overflow-hidden bg-background",
1901
- "transition-all duration-300 ease-in-out z-50"
1902
- ),
1903
- style: {
1904
- maxHeight: l ? `${Number(a.length / e) * 70}px` : "0px"
1905
- },
1906
- onMouseEnter: () => {
1907
- s(!0), i(!0);
1908
- },
1909
- onMouseLeave: () => {
1910
- s(!1), t || i(!1);
1911
- },
1912
- children: /* @__PURE__ */ r(
1913
- "ul",
1914
- {
1915
- className: "grid border border-gray-200",
1916
- style: { gridTemplateColumns: `repeat(${e}, 1fr)` },
1917
- children: a?.map(({ id: d, href: u, label: p, Icon: m }) => /* @__PURE__ */ b(
1918
- J,
1919
- {
1920
- href: u,
1921
- className: c(
1922
- " w-full flex items-center gap-2 text-foreground p-2 transition-all duration-300 ease-in-out",
1923
- "hover:text-background hover:bg-primary"
1924
- ),
1925
- children: [
1926
- m && /* @__PURE__ */ r(m, { className: "size-4" }),
1927
- p && /* @__PURE__ */ r("p", { children: p })
1928
- ]
1929
- },
1930
- d
1931
- ))
1932
- }
1933
- )
1934
- }
1935
- );
1936
- }, Pr = P(({ className: e, item: t, variant: a, hoverEffect: n, ...o }, s) => {
1937
- const {
1938
- hoveredItemId: i,
1939
- subItemsBoxIsHovered: l,
1940
- setSubItems: d,
1941
- setHoveredItemId: u,
1942
- setIsSubItemsBoxOpen: p
1943
- } = pt(), { id: m, label: f, Icon: h, subItems: v } = t, g = i === m, y = (S) => {
1944
- if (S) {
1945
- u(S), v && v.length > 0 ? (d(v), p(!0)) : p(!1);
1946
- return;
1947
- }
1948
- u(null), l || p(!1);
1949
- };
1950
- return /* @__PURE__ */ b(
1951
- "li",
1952
- {
1953
- ref: s,
1954
- "data-slot": "emperor-nav-bar-item",
1955
- style: Er({
1956
- hoverEffect: n,
1957
- isHovered: g,
1958
- variant: a
1959
- }),
1960
- className: c(Ir({ hoverEffect: n, variant: a })),
1961
- onMouseEnter: () => y(m),
1962
- onMouseLeave: () => y(null),
1963
- ...o,
1964
- children: [
1965
- h && /* @__PURE__ */ r(h, { className: "size-4" }),
1966
- f && /* @__PURE__ */ r("p", { children: f })
1967
- ]
1968
- }
1969
- );
1970
- }), Ar = ({
1971
- foregroundColor: e,
1972
- primaryColor: t,
1973
- isHovered: a
1974
- }) => ({
1975
- color: a ? e : "inherit",
1976
- backgroundColor: a ? t : "transparent"
1977
- }), zr = w([""], {
1978
- variants: {
1979
- variant: {
1980
- default: [],
1981
- compact: []
1982
- }
1983
- },
1984
- defaultVariants: {},
1985
- compoundVariants: []
1986
- }), Vr = w(
1987
- [
1988
- "w-full cursor-pointer px-6 py-2 transition-all font-semibold text-sm flex items-center gap-2"
1989
- ],
1990
- {
1991
- variants: {
1992
- variant: {
1993
- default: [],
1994
- compact: []
1995
- }
1996
- },
1997
- defaultVariants: {},
1998
- compoundVariants: []
1999
- }
2000
- ), kr = ({
2001
- isOpen: e,
2002
- onOpenChange: t,
2003
- triggerProps: a,
2004
- classNames: n,
2005
- header: o,
2006
- items: s = [],
2007
- actions: i = [],
2008
- variant: l = "default"
2009
- }) => {
2010
- const { config: d } = x(), [u, p] = I(null), { content: m, ...f } = a || {}, h = d?.interLocalization?.dir, v = h === "rtl";
2011
- return /* @__PURE__ */ b(se, { children: [
2012
- /* @__PURE__ */ r(
2013
- L,
2014
- {
2015
- variant: "ghost",
2016
- isIconOnly: !0,
2017
- size: "sm",
2018
- onPress: () => t?.(!0),
2019
- className: c(n?.trigger),
2020
- ...f,
2021
- children: m
2022
- }
2023
- ),
2024
- /* @__PURE__ */ r(
2025
- ya,
2026
- {
2027
- isOpen: e,
2028
- onOpenChange: t,
2029
- placement: v ? "right" : "left",
2030
- size: "sm",
2031
- dir: h,
2032
- className: "p-0",
2033
- children: /* @__PURE__ */ b(Ca, { className: "p-0", children: [
2034
- /* @__PURE__ */ r(Ia, { className: c("text-xl font-bold", n?.title), children: o }),
2035
- /* @__PURE__ */ r(Sa, { className: c("p-0 mt-4 h-fit"), children: /* @__PURE__ */ r(
2036
- Ye,
2037
- {
2038
- as: "ul",
2039
- hideScrollBar: !0,
2040
- "data-slot": "emperor-side-bar-menu",
2041
- className: c("max-h-[60vh] overflow-y-auto", n?.menu),
2042
- children: s?.map(({ id: g, label: y, href: S, Icon: C }) => /* @__PURE__ */ b(
2043
- "li",
2044
- {
2045
- "data-slot": "emperor-side-bar-item",
2046
- style: Ar({
2047
- isHovered: u === g
2048
- }),
2049
- className: c(
2050
- Vr({ variant: l }),
2051
- n?.menuItem
2052
- ),
2053
- onMouseEnter: () => p(g),
2054
- onMouseLeave: () => p(null),
2055
- children: [
2056
- C && /* @__PURE__ */ r(C, { className: "size-4" }),
2057
- y && /* @__PURE__ */ r("p", { children: y })
2058
- ]
2059
- },
2060
- S
2061
- ))
2062
- }
2063
- ) }),
2064
- i && i?.length > 0 && /* @__PURE__ */ b(se, { children: [
2065
- /* @__PURE__ */ r(xe, { className: "m-auto w-11/12" }),
2066
- /* @__PURE__ */ r(Na, { className: c(n?.actionsWrapper), children: i?.map(({ key: g, label: y, ...S }) => /* @__PURE__ */ r(
2067
- L,
2068
- {
2069
- variant: "ghost",
2070
- size: "sm",
2071
- className: c(n?.actionItem),
2072
- ...S,
2073
- children: y
2074
- },
2075
- g
2076
- )) })
2077
- ] })
2078
- ] })
2079
- }
2080
- )
2081
- ] });
2082
- }, Fr = ({
2083
- items: e = [],
2084
- isOpen: t,
2085
- onOpenChange: a,
2086
- triggerProps: n
2087
- }) => {
2088
- const { content: o, ...s } = n || {};
2089
- return /* @__PURE__ */ b(
2090
- "div",
2091
- {
2092
- className: c(
2093
- "flex flex-col gap-4 p-2",
2094
- "h-[calc(100vh-16px)] bg-gray-200 m-2 rounded-lg overflow-hidden",
2095
- "transition-width ease-in-out duration-300",
2096
- t ? "w-[20vw]" : "w-[48px]"
2097
- ),
2098
- children: [
2099
- /* @__PURE__ */ r("div", { className: "w-fit flex flex-col", children: /* @__PURE__ */ r(
2100
- L,
2101
- {
2102
- variant: "light",
2103
- size: "sm",
2104
- onPress: () => a?.(!0),
2105
- className: c("min-w-7 w-fit px-0.5"),
2106
- ...s,
2107
- children: o
2108
- }
2109
- ) }),
2110
- /* @__PURE__ */ r(xe, {}),
2111
- /* @__PURE__ */ r(
2112
- Ye,
2113
- {
2114
- as: "ul",
2115
- hideScrollBar: !0,
2116
- className: "max-h-[70vh] flex flex-col gap-4 p-0 overflow-y-auto",
2117
- children: e?.map(({ id: i, Icon: l, label: d }) => /* @__PURE__ */ b(
2118
- "li",
2119
- {
2120
- className: "w-fit flex items-center justify-center gap-3 ms-1.5 cursor-pointer",
2121
- children: [
2122
- l && /* @__PURE__ */ r(l, { className: "size-5" }),
2123
- d && t && /* @__PURE__ */ r("p", { className: c("text-sm font-semibold"), children: d })
2124
- ]
2125
- },
2126
- i
2127
- ))
2128
- }
2129
- )
2130
- ]
2131
- }
2132
- );
2133
- }, Mr = (e) => {
2134
- const [t, a] = I(null);
2135
- return O(() => {
2136
- const n = document.getElementById("emperor-compact-sidebar");
2137
- setTimeout(() => {
2138
- a(n);
2139
- }, 100);
2140
- }, []), t ? He(/* @__PURE__ */ r(Fr, { ...e }), t) : null;
2141
- }, Dr = P((e, t) => {
2142
- const { variant: a = "default", className: n, classNames: o } = e;
2143
- return /* @__PURE__ */ b(
2144
- "div",
2145
- {
2146
- ref: t,
2147
- "data-slot": "emperor-side-bar",
2148
- className: c(
2149
- zr({
2150
- variant: a,
2151
- className: c(n, o?.base)
2152
- })
2153
- ),
2154
- ...e,
2155
- children: [
2156
- a === "default" && /* @__PURE__ */ r(kr, { ...e }),
2157
- a === "compact" && /* @__PURE__ */ r(Mr, { ...e })
2158
- ]
2159
- }
2160
- );
2161
- }), Tr = P(
2162
- ({ className: e, children: t, ...a }, n) => {
2163
- const { config: o } = x();
2164
- return /* @__PURE__ */ r(
2165
- "main",
2166
- {
2167
- ref: n,
2168
- dir: o?.interLocalization?.dir,
2169
- "data-slot": "scaffold",
2170
- className: c(Br({ className: e }), e),
2171
- ...a,
2172
- children: t
2173
- }
2174
- );
2175
- }
2176
- ), Br = w(
2177
- ["flex flex-col min-h-screen w-full max-w-screen"],
2178
- {
2179
- variants: {},
2180
- defaultVariants: {},
2181
- compoundVariants: []
2182
- }
2183
- ), _r = w([""], {
2184
- variants: {
2185
- variant: {}
2186
- },
2187
- defaultVariants: {},
2188
- compoundVariants: []
2189
- }), ce = P(
2190
- ({
2191
- className: e,
2192
- variant: t,
2193
- src: a,
2194
- alt: n = "Emperor UI",
2195
- name: o = "Emperor UI",
2196
- isIconOnly: s = !1,
2197
- classNames: i,
2198
- ...l
2199
- }, d) => /* @__PURE__ */ b(
2200
- de,
2201
- {
2202
- ref: d,
2203
- "data-slot": "emperor-brand",
2204
- className: c(
2205
- _r({ variant: t, className: c(e, i?.base) })
2206
- ),
2207
- ...l,
2208
- children: [
2209
- a && /* @__PURE__ */ r(
2210
- he,
2211
- {
2212
- "data-slot": "emperor-brand-logo",
2213
- src: a,
2214
- alt: n,
2215
- radius: "md",
2216
- className: c("min-w-7 min-h-7 size-7", i?.logo)
2217
- }
2218
- ),
2219
- o && !s && /* @__PURE__ */ r(
2220
- "p",
2221
- {
2222
- "data-slot": "emperor-brand-name",
2223
- className: c("font-semibold text-lg", i?.name),
2224
- children: o
2225
- }
2226
- )
2227
- ]
2228
- }
2229
- )
2230
- ), Rr = w(["flex flex-col gap-3"], {
2231
- variants: {},
2232
- defaultVariants: {},
2233
- compoundVariants: []
2234
- }), $o = P(({ className: e, children: t, ...a }, n) => /* @__PURE__ */ r("section", { ref: n, className: c(Rr({ className: e })), ...a, children: t })), Or = w(["flex w-full container p-4 mx-auto"], {
2235
- variants: {},
2236
- defaultVariants: {},
2237
- compoundVariants: []
2238
- }), Xo = P(({ className: e, children: t, ...a }, n) => /* @__PURE__ */ r(
2239
- "section",
2240
- {
2241
- ref: n,
2242
- "data-slot": "container",
2243
- className: c(Or({ className: e })),
2244
- ...a,
2245
- children: t
2246
- }
2247
- )), Ur = w(["flex items-center gap-3"], {
2248
- variants: {},
2249
- defaultVariants: {},
2250
- compoundVariants: []
2251
- }), de = P(({ className: e, children: t, ...a }, n) => /* @__PURE__ */ r(
2252
- "section",
2253
- {
2254
- ref: n,
2255
- "data-slot": "row",
2256
- className: c(Ur({ className: e })),
2257
- ...a,
2258
- children: t
2259
- }
2260
- ));
2261
- function Zo({
2262
- children: e,
2263
- containerId: t,
2264
- isVisible: a = !0
2265
- }) {
2266
- const [n, o] = I(null);
2267
- return O(() => {
2268
- const s = document.getElementById(t);
2269
- setTimeout(() => {
2270
- o(s);
2271
- }, 100);
2272
- }, [t]), !n || !a ? null : He(e, n);
2273
- }
2274
- const Hr = w(["w-full flex flex-col gap-2"], {
2275
- variants: {},
2276
- defaultVariants: {},
2277
- compoundVariants: []
2278
- }), Yo = P(({ className: e, ...t }, a) => {
2279
- const {
2280
- isAvatar: n,
2281
- hideListing: o,
2282
- isFileViewable: s,
2283
- hideErrorMessage: i,
2284
- // Uploader API — must not be forwarded to a DOM element (React warns on unknown props).
2285
- selectedFile: l,
2286
- setSelectedFile: d,
2287
- labelId: u,
2288
- labelContent: p,
2289
- avatarLabelContent: m,
2290
- title: f,
2291
- errorMessage: h,
2292
- isRequired: v,
2293
- isDraggable: g,
2294
- isLoading: y,
2295
- isMulti: S,
2296
- placeholderImage: C,
2297
- files: z,
2298
- fileTypes: M,
2299
- onInputChange: G,
2300
- handleClearFile: Nt,
2301
- modal: N,
2302
- classNames: D,
2303
- locales: _,
2304
- setFiles: Ce,
2305
- ...ae
2306
- } = t;
2307
- return /* @__PURE__ */ r(ja, { ...t, children: /* @__PURE__ */ b(
2308
- "div",
2309
- {
2310
- ref: a,
2311
- className: c(Hr({ className: e })),
2312
- ...ae,
2313
- children: [
2314
- /* @__PURE__ */ r(Xr, {}),
2315
- n ? /* @__PURE__ */ r(jr, {}) : /* @__PURE__ */ r(Gr, {}),
2316
- !o && /* @__PURE__ */ r(qr, {}),
2317
- !i && /* @__PURE__ */ r(Kr, {}),
2318
- /* @__PURE__ */ r($r, {}),
2319
- s && /* @__PURE__ */ r(Wr, {})
2320
- ]
2321
- }
2322
- ) });
2323
- });
2324
- function jr() {
2325
- const { config: e } = x(), [t, a] = I(null), {
2326
- labelId: n,
2327
- classNames: o,
2328
- labelContent: s,
2329
- isDraggable: i,
2330
- onInputChange: l,
2331
- avatarLabelContent: d,
2332
- placeholderImage: u,
2333
- files: p,
2334
- isLoading: m,
2335
- isMulti: f,
2336
- locales: h
2337
- } = H(), v = e?.interLocalization?.locales, g = e?.interLocalization?.lang || e?.interLocalization?.defaultLanguage || "en", y = ee(g), S = te({
2338
- defaultUploaderLocale: y.atoms.uploader,
2339
- configUploaderLocale: v?.[g]?.atoms?.uploader,
2340
- contextUploaderLocale: h
2341
- }), C = (G) => {
2342
- G.preventDefault(), l && l(G);
2343
- }, z = (G) => {
2344
- G.preventDefault(), a(S.dropHere);
2345
- }, M = () => {
2346
- a("");
2347
- };
2348
- return !f && p?.length > 0 ? null : m ? /* @__PURE__ */ b("div", { className: c("mx-auto", o?.label), children: [
2349
- /* @__PURE__ */ r(ge, { className: "mx-auto", size: "lg" }),
2350
- ";"
2351
- ] }) : /* @__PURE__ */ b(
2352
- "label",
2353
- {
2354
- className: c(
2355
- "w-full cursor-pointer mx-auto transition-opacity flex flex-col gap-5",
2356
- t && "opacity-60",
2357
- o?.label
2358
- ),
2359
- htmlFor: n,
2360
- onDrop: i ? C : () => {
2361
- },
2362
- onDragOver: i ? z : () => {
2363
- },
2364
- onDragLeave: i ? M : () => {
2365
- },
2366
- children: [
2367
- d,
2368
- s || /* @__PURE__ */ r(
2369
- ra,
2370
- {
2371
- src: p?.[0]?.view || u || dt.PLACEHOLDER_MALE_AVATAR,
2372
- alt: "avatar",
2373
- size: "lg",
2374
- className: c("size-24", o?.avatar)
2375
- }
2376
- )
2377
- ]
2378
- }
2379
- );
2380
- }
2381
- function Gr() {
2382
- const { config: e } = x(), [t, a] = I(""), {
2383
- labelId: n,
2384
- classNames: o,
2385
- labelContent: s,
2386
- isDraggable: i,
2387
- onInputChange: l,
2388
- isLoading: d,
2389
- isMulti: u,
2390
- files: p,
2391
- locales: m
2392
- } = H(), f = e?.interLocalization?.locales, h = e?.interLocalization?.lang || e?.interLocalization?.defaultLanguage || "en", v = ee(h), g = te({
2393
- defaultUploaderLocale: v.atoms.uploader,
2394
- configUploaderLocale: f?.[h]?.atoms?.uploader,
2395
- contextUploaderLocale: m
2396
- }), y = (z) => {
2397
- z.preventDefault(), l && l(z);
2398
- }, S = (z) => {
2399
- z.preventDefault(), a(g.dropHere);
2400
- }, C = () => {
2401
- a("");
2402
- };
2403
- return !u && p?.length > 0 ? null : d ? /* @__PURE__ */ b("div", { className: c("w-full flex mx-auto", o?.label), children: [
2404
- /* @__PURE__ */ r(ge, { className: "mx-auto", size: "lg" }),
2405
- ";"
2406
- ] }) : /* @__PURE__ */ r(
2407
- "label",
2408
- {
2409
- className: c("w-full cursor-pointer mx-auto", o?.label),
2410
- htmlFor: n,
2411
- onDrop: i ? y : () => {
2412
- },
2413
- onDragOver: i ? S : () => {
2414
- },
2415
- onDragLeave: i ? C : () => {
2416
- },
2417
- children: s || /* @__PURE__ */ b("div", { className: "pointer-events-none flex size-full flex-col items-center justify-center gap-2 rounded-md border border-dashed bg-primary/10 px-2 py-8 text-xs", children: [
2418
- /* @__PURE__ */ r(jt, { className: "size-10 text-primary" }),
2419
- /* @__PURE__ */ r("p", { className: "font-bold", children: g.selectFile }),
2420
- /* @__PURE__ */ r("p", { className: "opacity-70", children: g.selectionTypes }),
2421
- t && /* @__PURE__ */ r("p", { className: "text-sm font-bold", children: t })
2422
- ] })
2423
- }
2424
- );
2425
- }
2426
- function Wr() {
2427
- const { config: e } = x(), { modal: t, selectedFile: a } = H(), n = e?.interLocalization?.lang || "en", o = a?.view, s = a?.file?.name;
2428
- return !o || !s ? null : /* @__PURE__ */ r(
2429
- Ge,
2430
- {
2431
- placement: "center",
2432
- isOpen: t?.isOpen,
2433
- dir: n === "ar" ? "rtl" : "ltr",
2434
- onClose: t?.onClose,
2435
- onOpenChange: t?.onOpenChange,
2436
- size: "xl",
2437
- ...t,
2438
- children: /* @__PURE__ */ r(We, { className: "px-5", children: /* @__PURE__ */ r(qe, { className: "h-[60vh]", children: /* @__PURE__ */ r(
2439
- he,
2440
- {
2441
- className: "size-full rounded-md object-cover",
2442
- src: o,
2443
- alt: s,
2444
- width: 500,
2445
- height: 500
2446
- }
2447
- ) }) })
2448
- }
2449
- );
2450
- }
2451
- function qr() {
2452
- const { files: e, setSelectedFile: t, handleClearFile: a, classNames: n, modal: o } = H();
2453
- return /* @__PURE__ */ r("ul", { className: c("w-full flex flex-col gap-2", n?.listing), children: e?.map((s) => {
2454
- const i = o?.onOpen && s?.view && s?.file?.name && s?.type === "image";
2455
- return s ? /* @__PURE__ */ b(
2456
- "li",
2457
- {
2458
- className: c(
2459
- "flex justify-between items-center p-2 gap-2 w-full border border-black/30 rounded-lg",
2460
- n?.listingItem
2461
- ),
2462
- children: [
2463
- /* @__PURE__ */ r("p", { className: "w-full line-clamp-1 text-xs max-w-60", children: s?.file?.name }),
2464
- /* @__PURE__ */ r(
2465
- L,
2466
- {
2467
- isIconOnly: !0,
2468
- variant: "flat",
2469
- radius: "full",
2470
- className: "size-6 min-w-6",
2471
- color: "danger",
2472
- onPress: () => a(s?.file?.name),
2473
- startContent: /* @__PURE__ */ r(Y, { className: "rounded-lg size-3" })
2474
- }
2475
- ),
2476
- i && /* @__PURE__ */ r(
2477
- L,
2478
- {
2479
- isIconOnly: !0,
2480
- variant: "flat",
2481
- radius: "full",
2482
- className: "size-6 min-w-6",
2483
- color: "primary",
2484
- onPress: () => {
2485
- t?.(s), o?.onOpen?.();
2486
- },
2487
- startContent: /* @__PURE__ */ r(ue, { className: "rounded-lg size-3" })
2488
- }
2489
- )
2490
- ]
2491
- },
2492
- s?.file?.name
2493
- ) : null;
2494
- }) });
2495
- }
2496
- function Kr() {
2497
- const { config: e } = x(), { files: t, isRequired: a, classNames: n, errorMessage: o, locales: s } = H(), i = e?.interLocalization?.locales, l = e?.interLocalization?.lang || e?.interLocalization?.defaultLanguage || "en", d = ee(l), u = te({
2498
- defaultUploaderLocale: d.atoms.uploader,
2499
- configUploaderLocale: i?.[l]?.atoms?.uploader,
2500
- contextUploaderLocale: s
2501
- });
2502
- return E(
2503
- () => t?.length === 0 && a,
2504
- [t, a]
2505
- ) ? /* @__PURE__ */ r("p", { className: c("text-[14px] text-danger", n?.error), children: o ?? u.errorUploadingFile }) : null;
2506
- }
2507
- function $r() {
2508
- const {
2509
- fileTypes: e = [],
2510
- isMulti: t,
2511
- labelId: a,
2512
- onInputChange: n,
2513
- classNames: o
2514
- } = H();
2515
- return /* @__PURE__ */ r(
2516
- "input",
2517
- {
2518
- id: a,
2519
- type: "file",
2520
- accept: (() => {
2521
- const i = [];
2522
- return e?.forEach((l) => {
2523
- i.push(..._a?.[l] || []);
2524
- }), i.join(", ");
2525
- })(),
2526
- className: c("hidden", o?.input),
2527
- onChange: n,
2528
- multiple: t
2529
- }
2530
- );
2531
- }
2532
- function Xr({ ...e }) {
2533
- const { title: t, classNames: a } = H();
2534
- return t ? /* @__PURE__ */ r(
2535
- "h3",
2536
- {
2537
- className: c("text-lg font-bold", a?.title),
2538
- "data-slot": "emperor-uploader-title",
2539
- ...e,
2540
- children: t
2541
- }
2542
- ) : null;
2543
- }
2544
- const k = w([""], {
2545
- variants: {
2546
- type: {
2547
- search: "",
2548
- select: "",
2549
- autocomplete: "",
2550
- date: "",
2551
- numeric: "",
2552
- checkbox: "",
2553
- checkboxGroup: "",
2554
- radio: "",
2555
- switch: "",
2556
- range: ""
2557
- }
2558
- },
2559
- defaultVariants: {},
2560
- compoundVariants: []
2561
- });
2562
- function Jo({
2563
- className: e,
2564
- type: t,
2565
- searchProps: a,
2566
- selectProps: n,
2567
- autocompleteProps: o,
2568
- dateProps: s,
2569
- numericProps: i,
2570
- checkboxProps: l,
2571
- checkboxGroupProps: d,
2572
- radioProps: u,
2573
- switchProps: p,
2574
- rangeProps: m,
2575
- paramKey: f,
2576
- options: h,
2577
- ...v
2578
- }) {
2579
- const g = { paramKey: f }, y = {
2580
- search: /* @__PURE__ */ r(Zr, { searchProps: a, ...g, ...v }),
2581
- select: /* @__PURE__ */ r(
2582
- Yr,
2583
- {
2584
- selectProps: n,
2585
- options: h,
2586
- ...g,
2587
- ...v
2588
- }
2589
- ),
2590
- autocomplete: /* @__PURE__ */ r(
2591
- Jr,
2592
- {
2593
- autocompleteProps: o,
2594
- options: h,
2595
- ...g,
2596
- ...v
2597
- }
2598
- ),
2599
- date: /* @__PURE__ */ r(Qr, { dateProps: s, ...g, ...v }),
2600
- numeric: /* @__PURE__ */ r(en, { numericProps: i, ...g, ...v }),
2601
- checkbox: /* @__PURE__ */ r(
2602
- tn,
2603
- {
2604
- checkboxProps: l,
2605
- ...g,
2606
- ...v
2607
- }
2608
- ),
2609
- checkboxGroup: /* @__PURE__ */ r(
2610
- an,
2611
- {
2612
- checkboxGroupProps: d,
2613
- options: h,
2614
- ...g,
2615
- ...v
2616
- }
2617
- ),
2618
- switch: /* @__PURE__ */ r(rn, { switchProps: p, ...g, ...v }),
2619
- range: /* @__PURE__ */ r(nn, { rangeProps: m, ...g, ...v })
2620
- };
2621
- return /* @__PURE__ */ r(
2622
- "div",
2623
- {
2624
- "data-slot": "emperor-ui-filter",
2625
- className: c(
2626
- k({ type: t }),
2627
- e,
2628
- v?.classNames?.base
2629
- ),
2630
- children: y[t]
2631
- }
2632
- );
2633
- }
2634
- function Zr({
2635
- classNames: e,
2636
- searchProps: t,
2637
- paramKey: a
2638
- }) {
2639
- const { config: n } = x(), o = n?.theme?.components?.input, [s, i] = I(
2640
- t?.defaultValue || ""
2641
- ), { setParams: l } = V(), [d] = ia(s, 700);
2642
- return O(() => {
2643
- l({
2644
- params: {
2645
- [a]: d
2646
- }
2647
- });
2648
- }, [d]), /* @__PURE__ */ r(
2649
- Q,
2650
- {
2651
- ...o,
2652
- ...t,
2653
- endContent: /* @__PURE__ */ r(Gt, { className: "size-4" }),
2654
- value: s,
2655
- onValueChange: i,
2656
- className: c(k({ type: "search" }), e?.field),
2657
- classNames: {
2658
- input: "min-w-40",
2659
- label: "font-semibold",
2660
- ...o?.classNames,
2661
- ...t?.classNames
2662
- }
2663
- }
2664
- );
2665
- }
2666
- function Yr({
2667
- classNames: e,
2668
- selectProps: t,
2669
- selectItemProps: a,
2670
- paramKey: n,
2671
- options: o
2672
- }) {
2673
- const { getParam: s, setParams: i } = V(), { config: l } = x(), d = l?.theme?.components?.select, u = l?.theme?.components?.selectItem, p = n ?? "select", m = s(p);
2674
- if (!o?.length)
2675
- throw new Error("Filter with type 'select' must have 'options' property.");
2676
- return /* @__PURE__ */ r(
2677
- ve,
2678
- {
2679
- ...d,
2680
- ...t,
2681
- selectedKeys: m ? [m] : [],
2682
- onSelectionChange: (f) => {
2683
- const h = Array.from(f)[0];
2684
- i({
2685
- params: { [p]: h ? String(h) : void 0 }
2686
- });
2687
- },
2688
- className: c(k({ type: "select" }), e?.field),
2689
- classNames: {
2690
- trigger: "min-w-40",
2691
- label: "font-semibold",
2692
- ...d?.classNames,
2693
- ...t?.classNames
2694
- },
2695
- children: o.map((f) => /* @__PURE__ */ r(be, { ...u, ...a, children: f.label }, f.key))
2696
- }
2697
- );
2698
- }
2699
- function Jr({
2700
- classNames: e,
2701
- autocompleteProps: t,
2702
- autocompleteItemProps: a,
2703
- paramKey: n,
2704
- options: o
2705
- }) {
2706
- const { config: s } = x(), i = s?.theme?.components?.autocomplete, l = s?.theme?.components?.autocompleteItem, { getParam: d, setParams: u } = V(), p = d(n);
2707
- if (!o?.length)
2708
- throw new Error(
2709
- "Filter with type 'autocomplete' must have 'options' property."
2710
- );
2711
- return /* @__PURE__ */ r(
2712
- Ke,
2713
- {
2714
- ...i,
2715
- ...t,
2716
- selectedKey: p || null,
2717
- onSelectionChange: (m) => u({
2718
- params: {
2719
- [n]: m ? String(m) : void 0
2720
- }
2721
- }),
2722
- className: c(k({ type: "autocomplete" }), e?.field),
2723
- classNames: {
2724
- base: "min-w-40",
2725
- ...i?.classNames,
2726
- ...t?.classNames
2727
- },
2728
- children: (o || [])?.map((m) => /* @__PURE__ */ r(
2729
- $e,
2730
- {
2731
- ...l,
2732
- ...a,
2733
- children: m.label
2734
- },
2735
- m.key
2736
- ))
2737
- }
2738
- );
2739
- }
2740
- function Qr({
2741
- classNames: e,
2742
- dateProps: t,
2743
- paramKey: a
2744
- }) {
2745
- const { getParam: n, setParams: o } = V(), { config: s } = x(), i = s?.theme?.components?.datePicker, l = n(a), d = l && /^\d{4}-\d{2}-\d{2}$/.test(l) ? ca(l) : null;
2746
- return /* @__PURE__ */ r(
2747
- la,
2748
- {
2749
- ...i,
2750
- ...t,
2751
- value: d,
2752
- onChange: (u) => o({
2753
- params: {
2754
- [a]: u ? String(u) : void 0
2755
- }
2756
- }),
2757
- className: c(k({ type: "date" }), e?.field),
2758
- classNames: {
2759
- label: "font-semibold",
2760
- ...i?.classNames,
2761
- ...t?.classNames
2762
- }
2763
- }
2764
- );
2765
- }
2766
- function en({
2767
- classNames: e,
2768
- numericProps: t,
2769
- paramKey: a
2770
- }) {
2771
- const { getParam: n, setParams: o } = V(), { config: s } = x(), i = s?.theme?.components?.input, l = n(a);
2772
- return /* @__PURE__ */ r(
2773
- Q,
2774
- {
2775
- ...i,
2776
- ...t,
2777
- type: "number",
2778
- value: l ?? "",
2779
- onValueChange: (d) => o({
2780
- params: { [a]: d || void 0 }
2781
- }),
2782
- className: c(k({ type: "numeric" }), e?.field),
2783
- classNames: {
2784
- input: "min-w-40",
2785
- label: "font-semibold",
2786
- ...i?.classNames,
2787
- ...t?.classNames
2788
- }
2789
- }
2790
- );
2791
- }
2792
- function tn({
2793
- classNames: e,
2794
- checkboxProps: t,
2795
- paramKey: a
2796
- }) {
2797
- const { config: n } = x(), o = n?.theme?.components?.checkbox, { getParam: s, setParams: i } = V(), { isSelected: l } = E(() => {
2798
- const d = s(a);
2799
- return { value: d, isSelected: d === "true" || d === "1" || d === "yes" };
2800
- }, [a]);
2801
- return /* @__PURE__ */ r(
2802
- we,
2803
- {
2804
- ...o,
2805
- ...t,
2806
- isSelected: l,
2807
- onValueChange: (d) => i({
2808
- params: { [a]: d ? "true" : void 0 }
2809
- }),
2810
- className: c(k({ type: "checkbox" }), e?.field)
2811
- }
2812
- );
2813
- }
2814
- function an({
2815
- classNames: e,
2816
- checkboxGroupProps: t,
2817
- paramKey: a,
2818
- options: n
2819
- }) {
2820
- const { config: o } = x(), s = o?.theme?.components?.checkboxGroup, i = o?.theme?.components?.checkbox, { getParam: l, setParams: d } = V(), { value: u } = E(() => {
2821
- const p = l(a);
2822
- return { value: p ? p.split(",").filter(Boolean) : [] };
2823
- }, [a]);
2824
- if (!n?.length)
2825
- throw new Error(
2826
- "Filter with type 'checkboxGroup' must have 'options' property."
2827
- );
2828
- return /* @__PURE__ */ r(
2829
- da,
2830
- {
2831
- ...s,
2832
- ...t,
2833
- value: u,
2834
- onValueChange: (p) => d({
2835
- params: {
2836
- [a]: p.length > 0 ? p.join(",") : void 0
2837
- }
2838
- }),
2839
- classNames: {
2840
- label: "font-semibold",
2841
- ...s?.classNames,
2842
- ...t?.classNames
2843
- },
2844
- className: c(
2845
- k({ type: "checkboxGroup" }),
2846
- e?.field
2847
- ),
2848
- children: n.map((p) => /* @__PURE__ */ r(we, { ...i, value: p.key, children: p.label }, p.key))
2849
- }
2850
- );
2851
- }
2852
- function rn({
2853
- classNames: e,
2854
- switchProps: t,
2855
- paramKey: a
2856
- }) {
2857
- const { getParam: n, setParams: o } = V(), { config: s } = x(), i = s?.theme?.components?.switch, l = n(a);
2858
- return /* @__PURE__ */ r(
2859
- Xe,
2860
- {
2861
- ...i,
2862
- ...t,
2863
- isSelected: l === "true" || l === "1" || l === "yes",
2864
- onValueChange: (u) => o({
2865
- params: { [a]: u ? "true" : void 0 }
2866
- }),
2867
- className: c(k({ type: "switch" }), e?.field)
2868
- }
2869
- );
2870
- }
2871
- function nn({
2872
- classNames: e,
2873
- rangeProps: t,
2874
- paramKey: a
2875
- }) {
2876
- const { getParam: n, setParams: o, allParams: s } = V(), { config: i } = x(), l = i?.theme?.components?.slider, d = t?.minValue ?? 0, u = t?.maxValue ?? 100, p = E(() => {
2877
- const m = n(a), f = [d, u];
2878
- if (m == null) return f;
2879
- const [h, v] = m.split(",").map(Number);
2880
- return !Number.isNaN(h) && !Number.isNaN(v) && h <= v ? [h, v] : f;
2881
- }, [a, d, u, s]);
2882
- return /* @__PURE__ */ r(
2883
- ua,
2884
- {
2885
- ...l,
2886
- ...t,
2887
- value: p,
2888
- onChange: (m) => {
2889
- const f = Array.isArray(m) ? m : [m], h = f.length === 2 && f[0] === d && f[1] === u;
2890
- o({
2891
- params: {
2892
- [a]: f.length === 2 && !h ? `${f[0]},${f[1]}` : void 0
2893
- }
2894
- });
2895
- },
2896
- classNames: {
2897
- base: "min-w-40",
2898
- label: "font-semibold",
2899
- ...l?.classNames,
2900
- ...t?.classNames
2901
- },
2902
- className: c(k({ type: "range" }), e?.field)
2903
- }
2904
- );
2905
- }
2906
- function on({
2907
- className: e,
2908
- classNames: t,
2909
- name: a,
2910
- type: n,
2911
- inputProps: o,
2912
- textareaProps: s,
2913
- checkboxProps: i,
2914
- selectProps: l,
2915
- selectItemProps: d,
2916
- autocompleteProps: u,
2917
- autocompleteItemProps: p,
2918
- switchProps: m,
2919
- radioGroupProps: f,
2920
- options: h,
2921
- children: v
2922
- }) {
2923
- const g = {
2924
- input: /* @__PURE__ */ r(ln, { name: a, inputProps: o }),
2925
- textarea: /* @__PURE__ */ r(cn, { name: a, textareaProps: s }),
2926
- checkbox: /* @__PURE__ */ r(dn, { name: a, checkboxProps: i, children: v }),
2927
- select: /* @__PURE__ */ r(
2928
- un,
2929
- {
2930
- name: a,
2931
- options: h,
2932
- selectProps: l,
2933
- selectItemProps: d
2934
- }
2935
- ),
2936
- autocomplete: /* @__PURE__ */ r(
2937
- mn,
2938
- {
2939
- name: a,
2940
- options: h,
2941
- autocompleteProps: u,
2942
- autocompleteItemProps: p
2943
- }
2944
- ),
2945
- switch: /* @__PURE__ */ r(pn, { name: a, switchProps: m, children: v }),
2946
- radio: /* @__PURE__ */ r(
2947
- fn,
2948
- {
2949
- name: a,
2950
- options: h,
2951
- radioGroupProps: f
2952
- }
2953
- )
2954
- };
2955
- return /* @__PURE__ */ r(
2956
- "div",
2957
- {
2958
- "data-slot": "emperor-ui-field",
2959
- className: c(sn({}), e, t?.base),
2960
- children: g[n]
2961
- }
2962
- );
2963
- }
2964
- const sn = w([""], {
2965
- variants: {
2966
- variant: {}
2967
- },
2968
- defaultVariants: {},
2969
- compoundVariants: []
2970
- });
2971
- function ln({
2972
- inputProps: e,
2973
- name: t
2974
- }) {
2975
- const { config: a } = x(), n = a?.theme?.components?.input, { control: o } = j();
2976
- return /* @__PURE__ */ r(
2977
- U,
2978
- {
2979
- control: o,
2980
- name: t,
2981
- render: ({ field: s, fieldState: i }) => /* @__PURE__ */ r(
2982
- Q,
2983
- {
2984
- ...n,
2985
- ...e,
2986
- value: s.value ? String(s.value) : "",
2987
- onBlur: s.onBlur,
2988
- onValueChange: s.onChange,
2989
- isInvalid: e?.isInvalid ?? !!i.error,
2990
- errorMessage: e?.errorMessage ?? i.error?.message
2991
- }
2992
- )
2993
- }
2994
- );
2995
- }
2996
- function cn({
2997
- textareaProps: e,
2998
- name: t
2999
- }) {
3000
- const { config: a } = x(), n = a?.theme?.components?.textarea, { control: o } = j();
3001
- return /* @__PURE__ */ r(
3002
- U,
3003
- {
3004
- control: o,
3005
- name: t,
3006
- render: ({ field: s, fieldState: i }) => /* @__PURE__ */ r(
3007
- sa,
3008
- {
3009
- ...n,
3010
- ...e,
3011
- value: s.value ? String(s.value) : "",
3012
- onBlur: s.onBlur,
3013
- onValueChange: s.onChange,
3014
- isInvalid: e?.isInvalid ?? !!i.error,
3015
- errorMessage: e?.errorMessage ?? i.error?.message
3016
- }
3017
- )
3018
- }
3019
- );
3020
- }
3021
- function dn({
3022
- checkboxProps: e,
3023
- name: t,
3024
- children: a
3025
- }) {
3026
- const { config: n } = x(), o = n?.theme?.components?.checkbox, { control: s } = j();
3027
- return /* @__PURE__ */ r(
3028
- U,
3029
- {
3030
- control: s,
3031
- name: t,
3032
- render: ({ field: { value: i, onChange: l } }) => /* @__PURE__ */ r(
3033
- we,
3034
- {
3035
- ...o,
3036
- ...e,
3037
- isSelected: !!i,
3038
- onValueChange: l,
3039
- children: a
3040
- }
3041
- )
3042
- }
3043
- );
3044
- }
3045
- function un({
3046
- options: e,
3047
- selectItemProps: t,
3048
- selectProps: a,
3049
- name: n
3050
- }) {
3051
- const { config: o } = x(), s = o?.theme?.components?.select;
3052
- if (!e?.length)
3053
- throw new Error("Field with type 'select' must include 'options'.");
3054
- const { control: i } = j();
3055
- return /* @__PURE__ */ r(
3056
- U,
3057
- {
3058
- control: i,
3059
- name: n,
3060
- render: ({ field: l }) => /* @__PURE__ */ r(
3061
- ve,
3062
- {
3063
- ...s,
3064
- ...a,
3065
- selectedKeys: l.value ? [String(l.value)] : [],
3066
- onSelectionChange: (d) => {
3067
- const u = Array.from(d)[0];
3068
- l.onChange(u ? String(u) : "");
3069
- },
3070
- children: e.map((d) => /* @__PURE__ */ r(be, { ...t, children: d.label }, d.key))
3071
- }
3072
- )
3073
- }
3074
- );
3075
- }
3076
- function mn({
3077
- autocompleteItemProps: e,
3078
- autocompleteProps: t,
3079
- options: a,
3080
- name: n
3081
- }) {
3082
- const { config: o } = x(), s = o?.theme?.components?.autocomplete;
3083
- if (!a?.length)
3084
- throw new Error("Field with type 'autocomplete' must include 'options'.");
3085
- const { control: i } = j();
3086
- return /* @__PURE__ */ r(
3087
- U,
3088
- {
3089
- control: i,
3090
- name: n,
3091
- render: ({ field: l }) => /* @__PURE__ */ r(
3092
- Ke,
3093
- {
3094
- ...s,
3095
- ...t,
3096
- selectedKey: l.value ? String(l.value) : null,
3097
- onSelectionChange: (d) => l.onChange(d ? String(d) : ""),
3098
- children: a.map((d) => /* @__PURE__ */ r($e, { ...e, children: d.label }, d.key))
3099
- }
3100
- )
3101
- }
3102
- );
3103
- }
3104
- function pn({
3105
- switchProps: e,
3106
- name: t,
3107
- children: a
3108
- }) {
3109
- const { config: n } = x(), o = n?.theme?.components?.switch, { control: s } = j();
3110
- return /* @__PURE__ */ r(
3111
- U,
3112
- {
3113
- control: s,
3114
- name: t,
3115
- render: ({ field: i }) => /* @__PURE__ */ r(
3116
- Xe,
3117
- {
3118
- ...o,
3119
- ...e,
3120
- isSelected: !!i.value,
3121
- onValueChange: i.onChange,
3122
- children: a
3123
- }
3124
- )
3125
- }
3126
- );
3127
- }
3128
- function fn({
3129
- options: e,
3130
- radioGroupProps: t,
3131
- name: a
3132
- }) {
3133
- const { config: n } = x(), o = n?.theme?.components?.radio, { control: s } = j();
3134
- if (!e?.length)
3135
- throw new Error("Field with type 'radio' must include 'options'.");
3136
- return /* @__PURE__ */ r(
3137
- U,
3138
- {
3139
- control: s,
3140
- name: a,
3141
- render: ({ field: i }) => /* @__PURE__ */ r(
3142
- fa,
3143
- {
3144
- ...o,
3145
- ...t,
3146
- value: i.value ? String(i.value) : "",
3147
- onValueChange: i.onChange,
3148
- children: e.map((l) => /* @__PURE__ */ r(ha, { value: l.key, children: l.label }, l.key))
3149
- }
3150
- )
3151
- }
3152
- );
3153
- }
3154
- const hn = w(
3155
- [
3156
- "flex items-center justify-center size-9 rounded-lg transition-all duration-300 text-foreground/80 cursor-pointer",
3157
- "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2 ",
3158
- "hover:bg-default-100 hover:text-foreground"
3159
- ],
3160
- {
3161
- variants: {
3162
- variant: {}
3163
- },
3164
- defaultVariants: {},
3165
- compoundVariants: []
3166
- }
3167
- );
3168
- function Qo({
3169
- className: e,
3170
- classNames: t,
3171
- ...a
3172
- }) {
3173
- const { setTheme: n, resolvedTheme: o } = ga(), s = () => {
3174
- n(o === "dark" ? "light" : "dark");
3175
- };
3176
- return /* @__PURE__ */ r(
3177
- Ie.button,
3178
- {
3179
- "data-slot": "emperor-ui-theme-knob",
3180
- className: c(hn(), e, t?.base),
3181
- onClick: s,
3182
- initial: !1,
3183
- whileHover: { scale: 1.08 },
3184
- whileTap: { scale: 0.92 },
3185
- transition: {
3186
- type: "spring",
3187
- stiffness: 500,
3188
- damping: 28
3189
- },
3190
- ...a,
3191
- children: /* @__PURE__ */ r("span", { className: "relative flex size-5 items-center justify-center", children: /* @__PURE__ */ r(va, { mode: "wait", children: /* @__PURE__ */ r(
3192
- Ie.span,
3193
- {
3194
- initial: { opacity: 0 },
3195
- animate: { opacity: 1 },
3196
- exit: { opacity: 0 },
3197
- transition: { duration: 0.2 },
3198
- className: "absolute inset-0 flex items-center justify-center",
3199
- children: o === "dark" ? /* @__PURE__ */ r(Wt, { className: "size-5" }) : /* @__PURE__ */ r(qt, { className: "size-5" })
3200
- },
3201
- o ?? "loading"
3202
- ) }) })
3203
- }
3204
- );
3205
- }
3206
- function es({ ...e }) {
3207
- return e?.inputType === "preset" ? /* @__PURE__ */ r(vn, { ...e }) : /* @__PURE__ */ r(gn, { ...e });
3208
- }
3209
- function gn({
3210
- className: e,
3211
- classNames: t,
3212
- value: a = "#000000",
3213
- onChange: n,
3214
- defaultValue: o,
3215
- inputType: s = "free",
3216
- ...i
3217
- }) {
3218
- const { config: l } = x(), d = l?.interLocalization?.locales, u = l?.interLocalization?.lang, m = d?.[u ?? "en"]?.atoms?.colorPicker?.invalidColorFormat, f = E(() => a ? !/^#([0-9A-Fa-f]{3}|[0-9A-Fa-f]{6})$/.test(a) : !0, [a]);
3219
- return /* @__PURE__ */ r(
3220
- Q,
3221
- {
3222
- labelPlacement: "outside",
3223
- variant: "faded",
3224
- className: c(e),
3225
- classNames: { label: "font-bold", input: "h-12", ...t },
3226
- defaultValue: o,
3227
- value: a,
3228
- onValueChange: n,
3229
- isInvalid: f,
3230
- errorMessage: f ? m : void 0,
3231
- endContent: /* @__PURE__ */ r(It, { value: a }),
3232
- startContent: /* @__PURE__ */ r(
3233
- "input",
3234
- {
3235
- type: "color",
3236
- className: "color-swatch",
3237
- value: a,
3238
- onChange: (h) => {
3239
- n?.(h.target.value);
3240
- }
3241
- }
3242
- ),
3243
- ...i
3244
- }
3245
- );
3246
- }
3247
- function vn({
3248
- className: e,
3249
- classNames: t,
3250
- value: a = "#000000",
3251
- onChange: n,
3252
- defaultValue: o,
3253
- inputType: s,
3254
- presets: i = [],
3255
- ...l
3256
- }) {
3257
- if (s === "preset" && (!i || i?.length === 0))
3258
- throw new Error(
3259
- "Presets array is required in the ColorPicker when the input type is 'preset'."
3260
- );
3261
- return /* @__PURE__ */ r(
3262
- ve,
3263
- {
3264
- labelPlacement: "outside",
3265
- variant: "faded",
3266
- className: c(e),
3267
- classNames: {
3268
- label: "font-bold",
3269
- input: "h-12",
3270
- trigger: "min-w-52",
3271
- ...t
3272
- },
3273
- selectedKeys: a ? [a] : void 0,
3274
- defaultSelectedKeys: o ? [o] : void 0,
3275
- onSelectionChange: (d) => n?.(d?.currentKey ?? ""),
3276
- endContent: /* @__PURE__ */ r(It, { value: a }),
3277
- renderValue: () => /* @__PURE__ */ b("div", { className: "flex items-center gap-2 text-gray-600", children: [
3278
- /* @__PURE__ */ r(
3279
- "div",
3280
- {
3281
- style: { backgroundColor: a },
3282
- className: "size-4 rounded-full border border-gray-300"
3283
- }
3284
- ),
3285
- a
3286
- ] }),
3287
- ...l,
3288
- children: Array.from(new Set(i))?.map((d) => /* @__PURE__ */ r(
3289
- be,
3290
- {
3291
- startContent: /* @__PURE__ */ r(
3292
- "div",
3293
- {
3294
- style: { backgroundColor: d },
3295
- className: "size-4 rounded-full border border-gray-300"
3296
- }
3297
- ),
3298
- children: d
3299
- },
3300
- d
3301
- ))
3302
- }
3303
- );
3304
- }
3305
- function It({ value: e }) {
3306
- const [t, a] = I("copy"), n = Et(null), o = () => {
3307
- t === "copy" && (n.current && clearTimeout(n.current), navigator.clipboard.writeText(e), a("loading"), n.current = setTimeout(() => {
3308
- a("success"), n.current = setTimeout(() => a("copy"), 2e3);
3309
- }, 500));
3310
- };
3311
- return O(
3312
- () => () => {
3313
- n.current && clearTimeout(n.current);
3314
- },
3315
- []
3316
- ), /* @__PURE__ */ r(
3317
- L,
3318
- {
3319
- variant: "light",
3320
- size: "sm",
3321
- isIconOnly: !0,
3322
- onPress: o,
3323
- disabled: t !== "copy",
3324
- startContent: /* @__PURE__ */ r("span", { className: "relative size-4", children: /* @__PURE__ */ r(Vt, { mode: "wait", children: /* @__PURE__ */ b(
3325
- F.span,
3326
- {
3327
- initial: { opacity: 0 },
3328
- animate: { opacity: 1 },
3329
- exit: { opacity: 0 },
3330
- transition: { duration: 0.2 },
3331
- className: "absolute inset-0 flex items-center justify-center",
3332
- children: [
3333
- t === "copy" && /* @__PURE__ */ r(Kt, { className: "size-4" }),
3334
- t === "loading" && /* @__PURE__ */ r(
3335
- ge,
3336
- {
3337
- size: "sm",
3338
- classNames: {
3339
- circle1: "border-b-current",
3340
- circle2: "border-current"
3341
- }
3342
- }
3343
- ),
3344
- t === "success" && /* @__PURE__ */ r($t, { className: "size-4 text-success" })
3345
- ]
3346
- },
3347
- t
3348
- ) }) })
3349
- }
3350
- );
3351
- }
3352
- const bn = w(["p-0"], {
3353
- variants: {},
3354
- defaultVariants: {},
3355
- compoundVariants: []
3356
- }), wn = w([], {
3357
- variants: {},
3358
- defaultVariants: {},
3359
- compoundVariants: []
3360
- }), xn = w([], {
3361
- variants: {},
3362
- defaultVariants: {},
3363
- compoundVariants: []
3364
- }), yn = w(
3365
- ["flex gap-2 justify-end flex-wrap"],
3366
- {
3367
- variants: {},
3368
- defaultVariants: {},
3369
- compoundVariants: []
3370
- }
3371
- ), ts = ({}) => ({});
3372
- function Cn({
3373
- isOpen: e,
3374
- onClose: t,
3375
- title: a,
3376
- description: n,
3377
- className: o,
3378
- classNames: s,
3379
- confirmProps: i,
3380
- declineProps: l
3381
- }) {
3382
- const { config: d } = x(), u = d?.interLocalization?.lang ?? "en", m = d?.interLocalization?.locales?.[u]?.organisms?.deletionConfirmor, f = (h) => {
3383
- typeof l?.onPress == "function" && l.onPress(h), t();
3384
- };
3385
- return /* @__PURE__ */ r(
3386
- Ge,
3387
- {
3388
- placement: "center",
3389
- isOpen: e,
3390
- onClose: t,
3391
- onOpenChange: (h) => {
3392
- h || t();
3393
- },
3394
- dir: u === "ar" ? "rtl" : "ltr",
3395
- classNames: o || s?.base ? { base: c(o, s?.base) } : void 0,
3396
- children: /* @__PURE__ */ b(
3397
- We,
3398
- {
3399
- className: c(bn(), s?.content),
3400
- children: [
3401
- /* @__PURE__ */ r(
3402
- na,
3403
- {
3404
- className: c(wn(), s?.header),
3405
- children: a
3406
- }
3407
- ),
3408
- /* @__PURE__ */ r(
3409
- qe,
3410
- {
3411
- className: c(xn(), s?.body),
3412
- children: n
3413
- }
3414
- ),
3415
- /* @__PURE__ */ b(
3416
- oa,
3417
- {
3418
- className: c(yn(), s?.footer),
3419
- children: [
3420
- /* @__PURE__ */ r(
3421
- L,
3422
- {
3423
- variant: "flat",
3424
- size: "sm",
3425
- ...l,
3426
- onPress: f,
3427
- className: c(l?.className, s?.declineButton),
3428
- children: l?.children ?? m?.decline
3429
- }
3430
- ),
3431
- /* @__PURE__ */ r(
3432
- L,
3433
- {
3434
- color: "danger",
3435
- size: "sm",
3436
- startContent: i?.isLoading ? void 0 : i?.startContent ?? /* @__PURE__ */ r(Y, { className: "size-4", "aria-hidden": !0 }),
3437
- ...i,
3438
- className: c(i?.className, s?.confirmButton),
3439
- children: i?.children ?? m?.confirm
3440
- }
3441
- )
3442
- ]
3443
- }
3444
- )
3445
- ]
3446
- }
3447
- )
3448
- }
3449
- );
3450
- }
3451
- const as = (e) => {
3452
- const [t, a] = I(!1);
3453
- return /* @__PURE__ */ b("div", { className: "flex flex-col gap-4", children: [
3454
- /* @__PURE__ */ r(L, { color: "danger", onPress: () => a(!0), children: "Delete item" }),
3455
- /* @__PURE__ */ r(
3456
- Cn,
3457
- {
3458
- confirmProps: {
3459
- onPress: () => a(!1)
3460
- },
3461
- ...e,
3462
- isOpen: t,
3463
- onClose: () => a(!1)
3464
- }
3465
- )
3466
- ] });
3467
- };
3468
- function rs({ className: e }) {
3469
- return /* @__PURE__ */ r("div", { className: c("", e), children: "ItemDetails Component" });
3470
- }
3471
- const In = w(["w-full p-4 gap-4 relative"], {
3472
- variants: {
3473
- layout: {
3474
- grid: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4",
3475
- list: "flex flex-col gap-4",
3476
- carousel: "flex flex-col gap-4"
3477
- }
3478
- },
3479
- defaultVariants: {},
3480
- compoundVariants: []
3481
- }), Sn = w([""], {
3482
- variants: {
3483
- layout: {
3484
- grid: "size-full",
3485
- list: "w-full h-fit",
3486
- carousel: ""
3487
- }
3488
- },
3489
- defaultVariants: {},
3490
- compoundVariants: []
3491
- }), Nn = w(["mx-auto my-5 col-span-full"], {
3492
- variants: {
3493
- layout: {
3494
- grid: "",
3495
- list: "",
3496
- carousel: ""
3497
- }
3498
- },
3499
- defaultVariants: {},
3500
- compoundVariants: []
3501
- }), En = w(
3502
- [
3503
- "flex flex-col items-center justify-center min-h-[280px] w-full py-12 px-4",
3504
- "text-center"
3505
- ],
3506
- {
3507
- variants: {},
3508
- defaultVariants: {},
3509
- compoundVariants: []
3510
- }
3511
- ), Ln = ({}) => ({});
3512
- function ns({
3513
- items: e = [],
3514
- isLoading: t = !1,
3515
- className: a,
3516
- classNames: n,
3517
- layout: o = "grid",
3518
- actions: s = [],
3519
- onActionClick: i,
3520
- pagination: l
3521
- }) {
3522
- const d = {
3523
- grid: "vertical",
3524
- list: "horizontal",
3525
- carousel: "vertical"
3526
- }[o], u = e?.length === 0;
3527
- return /* @__PURE__ */ b(
3528
- F.section,
3529
- {
3530
- "data-slot": "emperor-ui-listings",
3531
- className: c(In({ className: a, layout: o })),
3532
- style: Ln({}),
3533
- initial: "hidden",
3534
- animate: "visible",
3535
- children: [
3536
- t && Array.from({ length: l?.pageSize || 12 }).map((p, m) => /* @__PURE__ */ r(
3537
- mt,
3538
- {
3539
- className: a,
3540
- classNames: n,
3541
- orientation: d
3542
- },
3543
- m
3544
- )),
3545
- !t && u && /* @__PURE__ */ r(zn, { className: "col-span-full" }),
3546
- !t && !u && e?.map(
3547
- ({
3548
- item: p,
3549
- actions: m,
3550
- onActionClick: f
3551
- }) => /* @__PURE__ */ r(
3552
- ur,
3553
- {
3554
- className: c(Sn({ layout: o }), n?.item),
3555
- item: p,
3556
- isLoading: t,
3557
- actions: m || s || [],
3558
- onActionClick: f || i,
3559
- orientation: d
3560
- },
3561
- p?.key
3562
- )
3563
- ),
3564
- !t && !u && l && /* @__PURE__ */ r(
3565
- ba,
3566
- {
3567
- className: c(
3568
- Nn({ layout: o }),
3569
- n?.pagination
3570
- ),
3571
- classNames: {
3572
- next: "rtl:rotate-180 cursor-pointer",
3573
- prev: "rtl:rotate-180 cursor-pointer",
3574
- item: "cursor-pointer",
3575
- chevronNext: "rtl:rotate-180 cursor-pointer",
3576
- forwardIcon: "rtl:rotate-180 cursor-pointer"
3577
- },
3578
- total: l?.pagesCount,
3579
- page: l?.page,
3580
- onChange: l?.setPage,
3581
- variant: "faded",
3582
- showControls: !0,
3583
- color: "primary",
3584
- initialPage: 1,
3585
- showShadow: !0
3586
- }
3587
- )
3588
- ]
3589
- }
3590
- );
3591
- }
3592
- const Pn = {
3593
- animate: {
3594
- y: [0, -6, 0],
3595
- transition: {
3596
- duration: 3,
3597
- repeat: 1 / 0,
3598
- ease: "easeInOut"
3599
- }
3600
- }
3601
- }, An = {
3602
- hidden: { opacity: 0 },
3603
- visible: {
3604
- opacity: 1,
3605
- transition: {
3606
- staggerChildren: 0.12,
3607
- delayChildren: 0.08
3608
- }
3609
- }
3610
- }, oe = {
3611
- hidden: { opacity: 0, y: 16 },
3612
- visible: {
3613
- opacity: 1,
3614
- y: 0,
3615
- transition: { duration: 0.4, ease: "easeOut" }
3616
- }
3617
- };
3618
- function zn({
3619
- className: e,
3620
- classNames: t
3621
- }) {
3622
- const { config: a } = x(), n = a?.interLocalization?.locales, o = a?.interLocalization?.lang, i = n?.[o || "en"]?.organisms?.listings;
3623
- return /* @__PURE__ */ b(
3624
- F.div,
3625
- {
3626
- "data-slot": "emperor-ui-empty-listings",
3627
- className: c(En(), e),
3628
- variants: An,
3629
- initial: "hidden",
3630
- animate: "visible",
3631
- children: [
3632
- /* @__PURE__ */ r(
3633
- F.div,
3634
- {
3635
- className: c(
3636
- "flex items-center justify-center rounded-2xl bg-default-100/80 p-6 mb-5",
3637
- t?.iconWrapper
3638
- ),
3639
- variants: oe,
3640
- children: /* @__PURE__ */ r(
3641
- F.div,
3642
- {
3643
- variants: Pn,
3644
- animate: "animate",
3645
- className: "flex items-center justify-center",
3646
- children: /* @__PURE__ */ r(
3647
- Xt,
3648
- {
3649
- className: "size-14 text-default-400",
3650
- strokeWidth: 1.25,
3651
- "aria-hidden": !0
3652
- }
3653
- )
3654
- }
3655
- )
3656
- }
3657
- ),
3658
- /* @__PURE__ */ r(
3659
- F.h2,
3660
- {
3661
- className: c(
3662
- "text-xl font-semibold text-foreground mb-2",
3663
- t?.title
3664
- ),
3665
- variants: oe,
3666
- children: i?.emptyTitle
3667
- }
3668
- ),
3669
- /* @__PURE__ */ r(
3670
- F.p,
3671
- {
3672
- className: c(
3673
- "text-sm text-default-500 max-w-sm",
3674
- t?.description
3675
- ),
3676
- variants: oe,
3677
- children: i?.emptyDescription
3678
- }
3679
- )
3680
- ]
3681
- }
3682
- );
3683
- }
3684
- const Vn = w(
3685
- [
3686
- "w-full grid md:grid-cols-[1fr_2fr] gap-4 p-5 min-h-80",
3687
- "bg-foreground text-background"
3688
- ],
3689
- {
3690
- variants: {
3691
- variant: {
3692
- default: []
3693
- }
3694
- },
3695
- defaultVariants: {},
3696
- compoundVariants: []
3697
- }
3698
- ), kn = w(["flex flex-col gap-4"], {
3699
- variants: {},
3700
- defaultVariants: {},
3701
- compoundVariants: []
3702
- }), Fn = w(
3703
- [
3704
- "col-span-full w-fit flex flex-col items-center gap-4 p-5 text-center",
3705
- "md:flex-row"
3706
- ],
3707
- {
3708
- variants: {},
3709
- defaultVariants: {},
3710
- compoundVariants: []
3711
- }
3712
- ), Mn = w(
3713
- ["w-fit flex p-5 gap-4 items-center flex-wrap"],
3714
- {
3715
- variants: {},
3716
- defaultVariants: {},
3717
- compoundVariants: []
3718
- }
3719
- ), Dn = w(
3720
- ["col-span-full w-fit flex p-2 mx-auto text-center"],
3721
- {
3722
- variants: {},
3723
- defaultVariants: {},
3724
- compoundVariants: []
3725
- }
3726
- );
3727
- w([""], {
3728
- variants: {},
3729
- defaultVariants: {},
3730
- compoundVariants: []
3731
- });
3732
- const Tn = w(
3733
- [
3734
- "grid gap-4 p-5 w-fit mx-auto",
3735
- "sm:w-full sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4"
3736
- ],
3737
- {
3738
- variants: {},
3739
- defaultVariants: {},
3740
- compoundVariants: []
3741
- }
3742
- ), Bn = ({}) => ({}), os = P(
3743
- ({
3744
- className: e,
3745
- classNames: t,
3746
- policies: a,
3747
- copyRights: n,
3748
- socialLinks: o,
3749
- contacts: s,
3750
- quickLinks: i,
3751
- variant: l = "default",
3752
- children: d,
3753
- ...u
3754
- }, p) => /* @__PURE__ */ b(
3755
- "footer",
3756
- {
3757
- ref: p,
3758
- "data-slot": "emperor-ui-footer",
3759
- className: c(
3760
- Vn({
3761
- variant: l,
3762
- className: c(e, t?.base)
3763
- })
3764
- ),
3765
- style: Bn({}),
3766
- ...u,
3767
- children: [
3768
- /* @__PURE__ */ r(
3769
- "div",
3770
- {
3771
- "data-slot": "emperor-footer-content",
3772
- className: c(
3773
- kn({
3774
- className: c(e, t?.content)
3775
- })
3776
- ),
3777
- children: d
3778
- }
3779
- ),
3780
- /* @__PURE__ */ r(Un, { quickLinks: i, classNames: t }),
3781
- /* @__PURE__ */ r(xe, { className: "col-span-full bg-background/30" }),
3782
- /* @__PURE__ */ b(
3783
- "div",
3784
- {
3785
- className: c(
3786
- "col-span-full flex flex-col gap-4 justify-between items-center w-full",
3787
- "md:flex-row"
3788
- ),
3789
- children: [
3790
- /* @__PURE__ */ r(On, { socialLinks: o, classNames: t }),
3791
- /* @__PURE__ */ r(_n, { policies: a, classNames: t })
3792
- ]
3793
- }
3794
- ),
3795
- /* @__PURE__ */ r(Rn, { copyRights: n, classNames: t })
3796
- ]
3797
- }
3798
- )
3799
- );
3800
- function _n({ policies: e, classNames: t }) {
3801
- return /* @__PURE__ */ r(
3802
- "section",
3803
- {
3804
- "data-slot": "emperor-footer-policies",
3805
- className: c(
3806
- Fn({
3807
- className: c(t?.policiesWrapper)
3808
- })
3809
- ),
3810
- children: e?.map((a) => /* @__PURE__ */ r(
3811
- J,
3812
- {
3813
- href: a.href,
3814
- className: c(t?.policy),
3815
- children: a.label
3816
- },
3817
- a.href
3818
- ))
3819
- }
3820
- );
3821
- }
3822
- function Rn({ copyRights: e, classNames: t }) {
3823
- return /* @__PURE__ */ r(
3824
- "section",
3825
- {
3826
- "data-slot": "emperor-footer-policies",
3827
- className: c(
3828
- Dn({
3829
- className: c(t?.copyRightsWrapper)
3830
- })
3831
- ),
3832
- children: /* @__PURE__ */ b(
3833
- "p",
3834
- {
3835
- className: c(
3836
- "flex items-center gap-1 text-sm text-gray-400 text-center",
3837
- t?.copyRightsText
3838
- ),
3839
- children: [
3840
- /* @__PURE__ */ r("span", { children: "©" }),
3841
- /* @__PURE__ */ r("span", { children: e?.year }),
3842
- /* @__PURE__ */ r("span", { children: e?.text })
3843
- ]
3844
- }
3845
- )
3846
- }
3847
- );
3848
- }
3849
- function On({ socialLinks: e, classNames: t }) {
3850
- return /* @__PURE__ */ r(
3851
- "section",
3852
- {
3853
- "data-slot": "emperor-footer-social-links",
3854
- className: c(
3855
- Mn({
3856
- className: c(t?.socialLinksWrapper)
3857
- })
3858
- ),
3859
- children: e?.map(({ href: a, icon: n, label: o }) => /* @__PURE__ */ b(
3860
- J,
3861
- {
3862
- href: a,
3863
- className: c(
3864
- "flex items-center gap-2 text-sm text-gray-400 hover:text-white transition-all duration-300 ease-in-out",
3865
- t?.socialLink
3866
- ),
3867
- target: "_blank",
3868
- rel: "noopener noreferrer",
3869
- children: [
3870
- n,
3871
- o
3872
- ]
3873
- },
3874
- a
3875
- ))
3876
- }
3877
- );
3878
- }
3879
- function Un({ quickLinks: e, classNames: t }) {
3880
- return /* @__PURE__ */ r(
3881
- "section",
3882
- {
3883
- "data-slot": "emperor-footer-quick-links",
3884
- className: c(
3885
- Tn({
3886
- className: c(t?.quickLinksWrapper)
3887
- })
3888
- ),
3889
- children: e?.map(({ links: a, title: n }) => /* @__PURE__ */ b(
3890
- "div",
3891
- {
3892
- className: c("flex flex-col gap-4", t?.quickLinksItem),
3893
- children: [
3894
- /* @__PURE__ */ r(
3895
- "h3",
3896
- {
3897
- className: c("text-lg font-semibold", t?.quickLinksTitle),
3898
- children: n
3899
- }
3900
- ),
3901
- /* @__PURE__ */ r("ul", { className: c("flex flex-col gap-2", t?.quickLinksList), children: a?.map(({ href: o, label: s, isExternal: i }) => /* @__PURE__ */ r(
3902
- J,
3903
- {
3904
- href: o,
3905
- target: i ? "_blank" : "_self",
3906
- className: c(
3907
- " text-gray-400 hover:text-white transition-all duration-300 ease-in-out",
3908
- t?.quickLinksLink
3909
- ),
3910
- children: s
3911
- },
3912
- o
3913
- )) })
3914
- ]
3915
- },
3916
- n
3917
- ))
3918
- }
3919
- );
3920
- }
3921
- const Hn = w(
3922
- ["flex min-h-16 items-center justify-between gap-4 px-6 w-full"],
3923
- {
3924
- variants: {
3925
- variant: {
3926
- default: ["flex-nowrap w-full"],
3927
- floating: [
3928
- "fixed min-h-14 w-[90vw] rounded-full shadow-lg",
3929
- "top-3 left-1/2 -translate-x-1/2 z-10"
3930
- ],
3931
- light: [],
3932
- "segmented-floating": [
3933
- "fixed min-h-12 w-[90vw] top-3 left-1/2 -translate-x-1/2 z-10"
3934
- ]
3935
- }
3936
- },
3937
- defaultVariants: {},
3938
- compoundVariants: []
3939
- }
3940
- ), St = ({
3941
- glassEffect: e
3942
- }) => ({
3943
- backgroundColor: e?.backgroundColor ? `${e?.backgroundColor}${e?.opacity ?? 30}` : "transparent",
3944
- backdropFilter: `blur(${e?.blur ?? 0}px)`,
3945
- color: e?.foregroundColor
3946
- }), jn = ({
3947
- primaryColor: e,
3948
- foregroundColor: t,
3949
- variant: a,
3950
- glassEffect: n
3951
- }) => n?.enabled && a !== "segmented-floating" ? St({
3952
- glassEffect: {
3953
- ...n,
3954
- foregroundColor: n?.foregroundColor ?? t
3955
- }
3956
- }) : ["default", "floating"].includes(a ?? "") ? {
3957
- backgroundColor: e,
3958
- color: t
3959
- } : {}, Gn = ({
3960
- children: e,
3961
- glassEffect: t
3962
- }) => /* @__PURE__ */ r(de, { className: "w-full min-h-12 justify-between", children: De.toArray(e).map((a, n) => /* @__PURE__ */ r(
3963
- de,
3964
- {
3965
- className: "rounded-full min-h-12 px-5",
3966
- style: {
3967
- ...t ? St({
3968
- glassEffect: t
3969
- }) : {}
3970
- },
3971
- children: a
3972
- },
3973
- n
3974
- )) }), Wn = P(
3975
- ({ className: e, variant: t = "default", glassEffect: a, children: n, ...o }, s) => {
3976
- const { isOpen: i, onOpenChange: l } = je(), d = n || /* @__PURE__ */ b(se, { children: [
3977
- /* @__PURE__ */ r(
3978
- Dr,
3979
- {
3980
- items: Me,
3981
- actions: tr,
3982
- isOpen: i,
3983
- onOpenChange: l,
3984
- header: /* @__PURE__ */ r(ce, { className: "text-white" }),
3985
- triggerProps: {
3986
- startContent: /* @__PURE__ */ r(
3987
- ce,
3988
- {
3989
- className: "text-white",
3990
- classNames: {
3991
- logo: "size-6"
3992
- }
3993
- }
3994
- ),
3995
- isIconOnly: !1,
3996
- variant: "light"
3997
- }
3998
- }
3999
- ),
4000
- /* @__PURE__ */ r(
4001
- Ct,
4002
- {
4003
- className: "hidden md:flex mx-auto",
4004
- items: Me,
4005
- hoverEffect: {
4006
- default: "default",
4007
- floating: "underline",
4008
- light: "underline",
4009
- "segmented-floating": "default"
4010
- }[t],
4011
- variant: {
4012
- default: "default",
4013
- floating: "default",
4014
- light: "default",
4015
- "segmented-floating": "default"
4016
- }[t]
4017
- }
4018
- )
4019
- ] });
4020
- return /* @__PURE__ */ r(
4021
- "header",
4022
- {
4023
- ref: s,
4024
- "data-slot": "emperor-header",
4025
- className: c(Hn({ variant: t, className: e })),
4026
- style: jn({
4027
- variant: t,
4028
- glassEffect: a
4029
- }),
4030
- ...o,
4031
- children: t === "segmented-floating" ? /* @__PURE__ */ r(Gn, { glassEffect: a, children: d }) : d
4032
- }
4033
- );
4034
- }
4035
- );
4036
- function ss({
4037
- children: e,
4038
- className: t,
4039
- classNames: a,
4040
- formProps: n,
4041
- onSubmit: o,
4042
- onSuccess: s,
4043
- onError: i,
4044
- onValuesChange: l
4045
- }) {
4046
- const { control: d, handleSubmit: u } = ma(n), p = E(() => ({}), []), m = pa({ control: d }) ?? p, f = De.toArray(e);
4047
- f.forEach((g) => {
4048
- if (!Lt(g) || g.type !== on)
4049
- throw new Error(
4050
- "FormBuilder accepts only 'Field' components as children."
4051
- );
4052
- });
4053
- const h = f.map(
4054
- (g) => Pt(g)
4055
- );
4056
- O(() => {
4057
- l?.(m);
4058
- }, [m, l]);
4059
- const v = async (g) => {
4060
- try {
4061
- await o(g), s?.(g);
4062
- } catch (y) {
4063
- i?.(y);
4064
- }
4065
- };
4066
- return /* @__PURE__ */ r(Ga, { value: { control: d, formValues: m }, children: /* @__PURE__ */ r(
4067
- "form",
4068
- {
4069
- className: c(t, a?.base),
4070
- onSubmit: u(
4071
- v,
4072
- (g) => i?.({
4073
- errors: g
4074
- })
4075
- ),
4076
- children: h
4077
- }
4078
- ) });
4079
- }
1
+ import { dB as a, dC as i, dD as o, dE as r, dF as t, dG as l, dH as d, dI as C, dJ as f, dK as n, dL as E, dM as I, dN as _, dO as m, dP as S, dQ as p, dR as T, dS as c, dT as M, dU as F, dV as g, dW as A, dX as O, dY as L, dZ as u, d_ as B, d$ as P, e0 as D, e1 as R, e2 as K, e3 as N, e4 as U, e5 as x, e6 as y, e7 as W, e8 as h, e9 as k, ea as v, eb as H, ec as G, ed as w, ee as V, ef as b, eg as Y, eh as z, ei as Q, ej as q, ek as J, el as X, em as Z, en as $, eo as j, ep as ee, eq as se, er as ae, es as ie, et as oe, eu as re, ev as te, ew as le, ex as de, ey as Ce, ez as fe, eA as ne, eB as Ee, eC as Ie, eD as _e, eE as me, eF as Se, eG as pe, eH as Te, eI as ce, eJ as Me, eK as Fe, eL as ge, eM as Ae, eN as Oe, eO as Le, eP as ue, eQ as Be, eR as Pe, eS as De, eT as Re, eU as Ke, eV as Ne, eW as Ue, eX as xe, eY as ye, eZ as We, e_ as he, e$ as ke, f0 as ve, f1 as He, f2 as Ge, f3 as we, f4 as Ve, f5 as be, f6 as Ye, f7 as ze, f8 as Qe, f9 as qe, fa as Je, fb as Xe, fc as Ze, fd as $e, fe as je, ff as es, fg as ss, fh as as, fi as is, fj as os, fk as rs, fl as ts, fm as ls, fn as ds, fo as Cs, fp as fs, fq as ns, fr as Es, fs as Is, ft as _s, fu as ms, fv as Ss, fw as ps, fx as Ts, fy as cs, fz as Ms, fA as Fs, fB as gs, fC as As, fD as Os, fE as Ls, fF as us, fG as Bs, fH as Ps, fI as Ds, fJ as Rs, fK as Ks, fL as Ns, fM as Us, fN as xs, fO as ys, fP as Ws, fQ as hs, fR as ks, fS as vs, fT as Hs, fU as Gs, fV as ws, fW as Vs, fX as bs, fY as Ys, fZ as zs, f_ as Qs, f$ as qs, g0 as Js, g1 as Xs } from "./index-DXWNWGH3.js";
4080
2
  export {
4081
- at as ALLOWED_DOC_TYPES,
4082
- et as ALLOWED_IMAGES_TYPES,
4083
- tt as ALLOWED_PDF_TYPES,
4084
- rt as ALLOWED_SHEET_TYPES,
4085
- mn as AutocompleteField,
4086
- Jr as AutocompleteFilter,
4087
- jr as AvatarLabel,
4088
- ce as Brand,
4089
- dn as CheckboxField,
4090
- tn as CheckboxFilter,
4091
- an as CheckboxGroupFilter,
4092
- es as ColorPicker,
4093
- $o as Column,
4094
- Oa as ConfigProvider,
4095
- Xo as Container,
4096
- It as CopyButton,
4097
- Rn as CopyRightsBox,
4098
- Qr as DateFilter,
4099
- Cn as DeletionConfirmor,
4100
- as as DeletionConfirmorWithTrigger,
4101
- ie as EmperorUIContext,
4102
- Ua as EmperorUIProvider,
4103
- zn as EmptyListings,
4104
- q as FAKE_PARAGRAPH,
4105
- ko as FAKE_SENTENCE,
4106
- on as Field,
4107
- Jo as Filter,
4108
- os as Footer,
4109
- ss as FormBuilder,
4110
- lt as FormBuilderContext,
4111
- Ga as FormBuilderProvider,
4112
- gn as FreeColorPicker,
4113
- Wn as Header,
4114
- Ra as ITEM_CARD_ACTIONS,
4115
- _o as ITEM_CARD_ACTIONS_OVERLAY,
4116
- ln as InputField,
4117
- hr as ItemActionsButtons,
4118
- ft as ItemActionsDropdown,
4119
- gr as ItemActionsOverlay,
4120
- cr as ItemBanner,
4121
- ur as ItemCard,
4122
- pr as ItemCardBody,
4123
- fr as ItemCardFooter,
4124
- mr as ItemCardHeader,
4125
- rs as ItemDetails,
4126
- Wo as LandingPage,
4127
- ns as Listings,
4128
- mt as LoadingItem,
4129
- Qa as MOCK_AWAITING_DELETE_MS,
4130
- le as MOCK_BASE_DATE,
4131
- Pe as MOCK_COLORS,
4132
- tr as MOCK_HEADER_ACTIONS,
4133
- Me as MOCK_HEADER_ITEMS,
4134
- er as MOCK_HEADER_ITEMS_WITH_SUB_ITEMS,
4135
- $ as MOCK_HEADER_SUB_ITEMS,
4136
- Le as MOCK_ITEM_BRANDS,
4137
- Ee as MOCK_ITEM_CATEGORIES,
4138
- ar as MOCK_ITEM_REVIEWS_1,
4139
- rr as MOCK_ITEM_REVIEWS_2,
4140
- nr as MOCK_ITEM_REVIEWS_3,
4141
- ut as MOCK_LISTINGS,
4142
- ke as MOCK_LISTING_DESCRIPTIONS,
4143
- Fe as MOCK_LISTING_IMAGES,
4144
- Ve as MOCK_LISTING_TITLES,
4145
- ze as MOCK_REVIEW_AUTHORS,
4146
- Ae as MOCK_REVIEW_COMMENTS,
4147
- Ct as NavBar,
4148
- Pr as NavBarItem,
4149
- st as NavigationContext,
4150
- Ha as NavigationProvider,
4151
- en as NumericFilter,
4152
- nt as ONE_MEGABYTE,
4153
- dt as Placeholders,
4154
- _n as PoliciesBox,
4155
- Zo as Portal,
4156
- ct as PreservedKeys,
4157
- vn as PresetColorPicker,
4158
- Un as QuickLinksBox,
4159
- fn as RadioField,
4160
- nn as RangeFilter,
4161
- de as Row,
4162
- Tr as Scaffold,
4163
- Zr as SearchFilter,
4164
- un as SelectField,
4165
- Yr as SelectFilter,
4166
- Dr as SideBar,
4167
- On as SocialLinksBox,
4168
- Lr as SubItemsBox,
4169
- pn as SwitchField,
4170
- rn as SwitchFilter,
4171
- cn as TextareaField,
4172
- Ro as ThemeProvider,
4173
- Qo as ThemeSwitch,
4174
- Kr as UploadFileErrorBox,
4175
- $r as UploadFileInput,
4176
- Gr as UploadFileLabel,
4177
- qr as UploadFileListing,
4178
- Yo as Uploader,
4179
- it as UploaderContext,
4180
- ja as UploaderProvider,
4181
- Xr as UploaderTitle,
4182
- Wr as ViewImageModal,
4183
- c as cn,
4184
- Wa as compressImage,
4185
- To as contacts,
4186
- Do as copyRights,
4187
- B as defaultEmperorUIConfig,
4188
- xn as deletionConfirmorBodyClasses,
4189
- bn as deletionConfirmorContentClasses,
4190
- yn as deletionConfirmorFooterClasses,
4191
- wn as deletionConfirmorHeaderClasses,
4192
- ts as deletionConfirmorStyles,
4193
- En as emptyListingsClasses,
4194
- sn as fieldClasses,
4195
- _a as fileTypesMapping,
4196
- k as filterClasses,
4197
- Ka as getAllowedTypes,
4198
- ot as getCardMotion,
4199
- jo as getListing,
4200
- Ho as getListings,
4201
- Oo as getStorybookDecorators,
4202
- $a as isFileDuplicated,
4203
- Xa as isMaxFileSizeExceeded,
4204
- xr as itemBannerClasses,
4205
- wt as itemBodyClasses,
4206
- ht as itemCardMotionClasses,
4207
- yt as itemChipsClasses,
4208
- wr as itemDescriptionClasses,
4209
- xt as itemFooterClasses,
4210
- bt as itemHeaderClasses,
4211
- vt as itemImageWrapperClasses,
4212
- gt as itemMainWrapperClasses,
4213
- br as itemPriceClasses,
4214
- vr as itemTitleClasses,
4215
- In as listingsClasses,
4216
- Sn as listingsItemClasses,
4217
- Nn as listingsPaginationClasses,
4218
- Ln as listingsStyles,
4219
- qa as mapFileType,
4220
- Ne as mergeLocales,
4221
- te as mergeUploaderLocale,
4222
- Uo as mockAwaitingDelete,
4223
- Mo as policies,
4224
- Fo as quickLinks,
4225
- Ya as refineUploadedFiles,
4226
- Br as scaffoldClasses,
4227
- Bo as socialLinks,
4228
- Go as uploaderLocalesMock,
4229
- x as useEmperorUI,
4230
- Ko as useFilters,
4231
- j as useFormBuilder,
4232
- pt as useNavigation,
4233
- V as useSearchParamsHandler,
4234
- qo as useUploader,
4235
- H as useUploaderContext,
4236
- dr as useWindowSize,
4237
- Za as validateUploadedFiles
3
+ a as ALLOWED_DOC_TYPES,
4
+ i as ALLOWED_IMAGES_TYPES,
5
+ o as ALLOWED_PDF_TYPES,
6
+ r as ALLOWED_SHEET_TYPES,
7
+ t as AutocompleteField,
8
+ l as AutocompleteFilter,
9
+ d as AvatarLabel,
10
+ C as Brand,
11
+ f as CheckboxField,
12
+ n as CheckboxFilter,
13
+ E as CheckboxGroupFilter,
14
+ I as ColorPicker,
15
+ _ as Column,
16
+ m as ConfigProvider,
17
+ S as Container,
18
+ p as CopyButton,
19
+ T as CopyRightsBox,
20
+ c as DateFilter,
21
+ M as DeletionConfirmor,
22
+ F as DeletionConfirmorWithTrigger,
23
+ g as EmperorUIContext,
24
+ A as EmperorUIProvider,
25
+ O as EmptyListings,
26
+ L as FAKE_PARAGRAPH,
27
+ u as FAKE_SENTENCE,
28
+ B as Field,
29
+ P as Filter,
30
+ D as Footer,
31
+ R as FormBuilder,
32
+ K as FormBuilderContext,
33
+ N as FormBuilderProvider,
34
+ U as FreeColorPicker,
35
+ x as Header,
36
+ y as ITEM_CARD_ACTIONS,
37
+ W as ITEM_CARD_ACTIONS_OVERLAY,
38
+ h as InputField,
39
+ k as ItemActionsButtons,
40
+ v as ItemActionsDropdown,
41
+ H as ItemActionsOverlay,
42
+ G as ItemBanner,
43
+ w as ItemCard,
44
+ V as ItemCardBody,
45
+ b as ItemCardFooter,
46
+ Y as ItemCardHeader,
47
+ z as ItemDetails,
48
+ Q as LandingPage,
49
+ q as Listings,
50
+ J as LoadingItem,
51
+ X as MOCK_AWAITING_DELETE_MS,
52
+ Z as MOCK_BASE_DATE,
53
+ $ as MOCK_COLORS,
54
+ j as MOCK_HEADER_ACTIONS,
55
+ ee as MOCK_HEADER_ITEMS,
56
+ se as MOCK_HEADER_ITEMS_WITH_SUB_ITEMS,
57
+ ae as MOCK_HEADER_SUB_ITEMS,
58
+ ie as MOCK_ITEM_BRANDS,
59
+ oe as MOCK_ITEM_CATEGORIES,
60
+ re as MOCK_ITEM_REVIEWS_1,
61
+ te as MOCK_ITEM_REVIEWS_2,
62
+ le as MOCK_ITEM_REVIEWS_3,
63
+ de as MOCK_LISTINGS,
64
+ Ce as MOCK_LISTING_DESCRIPTIONS,
65
+ fe as MOCK_LISTING_IMAGES,
66
+ ne as MOCK_LISTING_TITLES,
67
+ Ee as MOCK_REVIEW_AUTHORS,
68
+ Ie as MOCK_REVIEW_COMMENTS,
69
+ _e as NavBar,
70
+ me as NavBarItem,
71
+ Se as NavigationContext,
72
+ pe as NavigationProvider,
73
+ Te as NumericFilter,
74
+ ce as ONE_MEGABYTE,
75
+ Me as Placeholders,
76
+ Fe as PoliciesBox,
77
+ ge as Portal,
78
+ Ae as PreservedKeys,
79
+ Oe as PresetColorPicker,
80
+ Le as QuickLinksBox,
81
+ ue as RadioField,
82
+ Be as RangeFilter,
83
+ Pe as Row,
84
+ De as Scaffold,
85
+ Re as SearchFilter,
86
+ Ke as SelectField,
87
+ Ne as SelectFilter,
88
+ Ue as SideBar,
89
+ xe as SocialLinksBox,
90
+ ye as SubItemsBox,
91
+ We as SwitchField,
92
+ he as SwitchFilter,
93
+ ke as TextareaField,
94
+ ve as ThemeProvider,
95
+ He as ThemeSwitch,
96
+ Ge as UploadFileErrorBox,
97
+ we as UploadFileInput,
98
+ Ve as UploadFileLabel,
99
+ be as UploadFileListing,
100
+ Ye as Uploader,
101
+ ze as UploaderContext,
102
+ Qe as UploaderProvider,
103
+ qe as UploaderTitle,
104
+ Je as ViewImageModal,
105
+ Xe as cn,
106
+ Ze as compressImage,
107
+ $e as contacts,
108
+ je as copyRights,
109
+ es as defaultEmperorUIConfig,
110
+ ss as deletionConfirmorBodyClasses,
111
+ as as deletionConfirmorContentClasses,
112
+ is as deletionConfirmorFooterClasses,
113
+ os as deletionConfirmorHeaderClasses,
114
+ rs as deletionConfirmorStyles,
115
+ ts as emptyListingsClasses,
116
+ ls as fieldClasses,
117
+ ds as fileTypesMapping,
118
+ Cs as filterClasses,
119
+ fs as getAllowedTypes,
120
+ ns as getCardMotion,
121
+ Es as getListing,
122
+ Is as getListings,
123
+ _s as getStorybookDecorators,
124
+ ms as isFileDuplicated,
125
+ Ss as isMaxFileSizeExceeded,
126
+ ps as itemBannerClasses,
127
+ Ts as itemBodyClasses,
128
+ cs as itemCardMotionClasses,
129
+ Ms as itemChipsClasses,
130
+ Fs as itemDescriptionClasses,
131
+ gs as itemFooterClasses,
132
+ As as itemHeaderClasses,
133
+ Os as itemImageWrapperClasses,
134
+ Ls as itemMainWrapperClasses,
135
+ us as itemPriceClasses,
136
+ Bs as itemTitleClasses,
137
+ Ps as listingsClasses,
138
+ Ds as listingsItemClasses,
139
+ Rs as listingsPaginationClasses,
140
+ Ks as listingsStyles,
141
+ Ns as mapFileType,
142
+ Us as mergeLocales,
143
+ xs as mergeUploaderLocale,
144
+ ys as mockAwaitingDelete,
145
+ Ws as policies,
146
+ hs as quickLinks,
147
+ ks as refineUploadedFiles,
148
+ vs as scaffoldClasses,
149
+ Hs as socialLinks,
150
+ Gs as uploaderLocalesMock,
151
+ ws as useEmperorUI,
152
+ Vs as useFilters,
153
+ bs as useFormBuilder,
154
+ Ys as useNavigation,
155
+ zs as useSearchParamsHandler,
156
+ Qs as useUploader,
157
+ qs as useUploaderContext,
158
+ Js as useWindowSize,
159
+ Xs as validateUploadedFiles
4238
160
  };