@tempots/beatui 0.82.1 → 0.83.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (462) hide show
  1. package/dist/ar-CBrjAlIY.cjs +1 -0
  2. package/dist/ar-DjMvIww5.js +175 -0
  3. package/dist/{ar-NCCPhOpI.js → ar-DwDxAANU.js} +16 -1
  4. package/dist/ar-kZBzg02I.cjs +1 -0
  5. package/dist/auth/index.cjs.js +1 -1
  6. package/dist/auth/index.es.js +33 -32
  7. package/dist/{auth-divider-Wr-S16kF.js → auth-divider-C3_CgC0l.js} +589 -569
  8. package/dist/auth-divider-C4WTL71M.cjs +1 -0
  9. package/dist/beatui.css +5678 -1438
  10. package/dist/beatui.tailwind.css +5662 -1422
  11. package/dist/better-auth/index.cjs.js +1 -1
  12. package/dist/better-auth/index.es.js +18 -31
  13. package/dist/{colors-B2yrgHSW.cjs → colors-BI0YhONJ.cjs} +1 -1
  14. package/dist/{colors-DPo9GEJR.js → colors-BmLYKmoH.js} +38 -30
  15. package/dist/de-B03SM9eF.cjs +1 -0
  16. package/dist/{de-BVK2MkCk.js → de-CSGSC0xX.js} +18 -3
  17. package/dist/de-CrBw41po.cjs +1 -0
  18. package/dist/{de-f2xcEb34.js → de-wChFYqM4.js} +79 -5
  19. package/dist/deep-merge-CmQoIYPC.js +1689 -0
  20. package/dist/deep-merge-UghuPcyW.cjs +1 -0
  21. package/dist/{duration-input-B9UNmUCh.cjs → duration-input-BJzKgI15.cjs} +1 -1
  22. package/dist/{duration-input-DqcJbxKD.js → duration-input-DaB6s0rL.js} +4 -4
  23. package/dist/editor-toolbar-group-BslfdazC.js +32 -0
  24. package/dist/editor-toolbar-group-_V1rDM-1.cjs +1 -0
  25. package/dist/{es-BxBeTRCv.cjs → es-BRa0hV-7.cjs} +1 -1
  26. package/dist/es-Ca5xT3NE.cjs +1 -0
  27. package/dist/es-CmPF3IGl.js +175 -0
  28. package/dist/{es-BQS8PL9j.js → es-dR46FTMF.js} +16 -1
  29. package/dist/{fa-DxPseW3g.cjs → fa-BxCSKn9j.cjs} +1 -1
  30. package/dist/fa-D696e75R.js +175 -0
  31. package/dist/fa-DhZJYuC6.cjs +1 -0
  32. package/dist/{fa-T-tkJSJr.js → fa-FsHBFjdY.js} +16 -1
  33. package/dist/fr-1nSKSIlw.cjs +1 -0
  34. package/dist/{fr-yOW_68YY.js → fr-B0jeX1Hx.js} +83 -9
  35. package/dist/{fr-CSRRhyCG.js → fr-Di6BT9_V.js} +18 -3
  36. package/dist/fr-Dq6RAY9s.cjs +1 -0
  37. package/dist/he-BBX1h9uD.cjs +1 -0
  38. package/dist/{he-Bxdc4M08.js → he-CXujw1Lw.js} +16 -1
  39. package/dist/he-DhcurPt5.cjs +1 -0
  40. package/dist/he-SgAsIYJA.js +175 -0
  41. package/dist/{hi-CJeFvTBe.js → hi-Bvh4d9bO.js} +16 -1
  42. package/dist/hi-Cd0YQZTU.cjs +1 -0
  43. package/dist/hi-CxsIxbfM.cjs +1 -0
  44. package/dist/hi-s9oiIihq.js +175 -0
  45. package/dist/{index-Bt7FYl80.cjs → index-Bm43lZqE.cjs} +2 -2
  46. package/dist/{index-05UbKOYe.cjs → index-C2_iX1um.cjs} +1 -1
  47. package/dist/{index-C2Lq1m45.js → index-C32iUFIr.js} +5 -5
  48. package/dist/{index-lYhXnu6I.js → index-CEqc0H3v.js} +1 -1
  49. package/dist/index-DH37GTQj.cjs +1 -0
  50. package/dist/{index-DklKfzD4.js → index-Di1_W_7Q.js} +351 -361
  51. package/dist/index.cjs.js +4 -4
  52. package/dist/index.es.js +6220 -3084
  53. package/dist/input-container-CSi72GI1.cjs +1 -0
  54. package/dist/{input-container-DiCjOzR2.js → input-container-Nx0gMAzS.js} +86 -75
  55. package/dist/it-ByIEk5Cq.cjs +1 -0
  56. package/dist/it-D_IcaYxp.cjs +1 -0
  57. package/dist/{it-6e6X-4BB.js → it-Dc4IMciD.js} +80 -6
  58. package/dist/{it-Zmp0BhIj.js → it-EWhykhHv.js} +18 -3
  59. package/dist/ja-CMGqpPo7.cjs +1 -0
  60. package/dist/{ja-BxNuNo2H.js → ja-D2t2g5xj.js} +85 -11
  61. package/dist/ja-DV6Fpp18.cjs +1 -0
  62. package/dist/{ja-DWjoA-hQ.js → ja-YZ0P5woj.js} +16 -1
  63. package/dist/json-schema/index.cjs.js +1 -1
  64. package/dist/json-schema/index.es.js +191 -185
  65. package/dist/json-schema-display/index.cjs.js +1 -1
  66. package/dist/json-schema-display/index.es.js +1 -1
  67. package/dist/json-structure/index.cjs.js +1 -1
  68. package/dist/json-structure/index.es.js +679 -660
  69. package/dist/ko-BPl5rP97.cjs +1 -0
  70. package/dist/ko-BRylA5JZ.js +175 -0
  71. package/dist/ko-DR1f0as8.cjs +1 -0
  72. package/dist/{ko-BOlI-33h.js → ko-U7BSUAxZ.js} +16 -1
  73. package/dist/lexical/index.cjs.js +31 -31
  74. package/dist/lexical/index.es.js +5248 -5221
  75. package/dist/lexical.css +5 -7
  76. package/dist/menu-CX72LaZ3.cjs +1 -0
  77. package/dist/menu-D_slbwl8.js +374 -0
  78. package/dist/{modal-v3u2Fpnd.js → modal-DaI1jH-X.js} +4 -4
  79. package/dist/{modal-I5srcntN.cjs → modal-kyZfvVZb.cjs} +1 -1
  80. package/dist/nl-BSfaHFt0.cjs +1 -0
  81. package/dist/{nl-Dr-l6zUy.cjs → nl-CQF0N7Mc.cjs} +1 -1
  82. package/dist/{nl-kQNcAdY1.js → nl-CqAxoB4J.js} +18 -3
  83. package/dist/nl-Dh7LUWAn.js +176 -0
  84. package/dist/{notice-CLDdy1MW.cjs → notice-Bc1L4Zpr.cjs} +1 -1
  85. package/dist/{notice-BuZvdvZh.js → notice-Dz4nX57_.js} +4 -4
  86. package/dist/{oneof-branch-detection-Dt8ss9lc.js → oneof-branch-detection-BED_n2MT.js} +522 -519
  87. package/dist/{oneof-branch-detection-DsM1K5xc.cjs → oneof-branch-detection-Vov_e3kI.cjs} +4 -4
  88. package/dist/{pl-CKyPFvss.js → pl-C-weXGCB.js} +16 -1
  89. package/dist/pl-D-O4sCnr.cjs +1 -0
  90. package/dist/{pl-Bs4nLJ__.js → pl-XEG-p1Q9.js} +77 -3
  91. package/dist/{pl-BK0i_yvq.cjs → pl-y_w3DWF3.cjs} +1 -1
  92. package/dist/prosemirror/index.cjs.js +1 -1
  93. package/dist/prosemirror/index.es.js +1 -1
  94. package/dist/{pt-DBmUhaNI.js → pt-BjNGOoZH.js} +18 -3
  95. package/dist/pt-DYsDA2sZ.js +175 -0
  96. package/dist/pt-DqaZWmbG.cjs +1 -0
  97. package/dist/pt-chEEYLlt.cjs +1 -0
  98. package/dist/ru-B46hVpFF.cjs +1 -0
  99. package/dist/{ru-Bi1_DEKM.js → ru-BTKBykp-.js} +86 -12
  100. package/dist/{ru-CsJ_yT-7.js → ru-CFmeZBXK.js} +16 -1
  101. package/dist/ru-CISMzCHR.cjs +1 -0
  102. package/dist/{styles-url-B2dzXrYt.cjs → styles-url-CVCcF0ra.cjs} +1 -1
  103. package/dist/{styles-url-Cw_mxshe.js → styles-url-DUdp56Ts.js} +1 -1
  104. package/dist/tailwind/index.cjs.js +1 -1
  105. package/dist/tailwind/index.es.js +3 -3
  106. package/dist/tailwind/preset.cjs.js +1 -1
  107. package/dist/tailwind/preset.es.js +74 -4
  108. package/dist/tailwind/vite-plugin.cjs.js +10 -10
  109. package/dist/tailwind/vite-plugin.es.js +289 -410
  110. package/dist/text-input-8v79fzEy.cjs +1 -0
  111. package/dist/text-input-CPJzUC2r.js +45 -0
  112. package/dist/{toolbar-D994_E_s.js → toolbar-CjQG7l7X.js} +1 -1
  113. package/dist/{toolbar-x0_8lmKu.cjs → toolbar-D3ZsC0g_.cjs} +1 -1
  114. package/dist/{tr-Bn5ldVJs.js → tr-C5X2gFZS.js} +17 -2
  115. package/dist/tr-CaMaflJL.cjs +1 -0
  116. package/dist/{tr-DiYB-FwX.js → tr-Cp8ZCUic.js} +77 -3
  117. package/dist/{tr-CgJ8uhZu.cjs → tr-mWu2E__o.cjs} +1 -1
  118. package/dist/{translations-Cq8bUKJP.js → translations-BGblCUBj.js} +144 -70
  119. package/dist/translations-CZ0KOii3.cjs +1 -0
  120. package/dist/translations-gVgMyNno.cjs +1 -0
  121. package/dist/translations-jUYta1_1.js +87 -0
  122. package/dist/types/auth/index.d.ts +13 -0
  123. package/dist/types/auth-i18n/default.d.ts +14 -0
  124. package/dist/types/auth-i18n/locales/ar.d.ts +14 -0
  125. package/dist/types/auth-i18n/locales/de.d.ts +14 -0
  126. package/dist/types/auth-i18n/locales/en.d.ts +14 -0
  127. package/dist/types/auth-i18n/locales/es.d.ts +14 -0
  128. package/dist/types/auth-i18n/locales/fa.d.ts +14 -0
  129. package/dist/types/auth-i18n/locales/fr.d.ts +14 -0
  130. package/dist/types/auth-i18n/locales/he.d.ts +14 -0
  131. package/dist/types/auth-i18n/locales/hi.d.ts +14 -0
  132. package/dist/types/auth-i18n/locales/it.d.ts +14 -0
  133. package/dist/types/auth-i18n/locales/ja.d.ts +14 -0
  134. package/dist/types/auth-i18n/locales/ko.d.ts +14 -0
  135. package/dist/types/auth-i18n/locales/nl.d.ts +14 -0
  136. package/dist/types/auth-i18n/locales/pl.d.ts +14 -0
  137. package/dist/types/auth-i18n/locales/pt.d.ts +14 -0
  138. package/dist/types/auth-i18n/locales/ru.d.ts +14 -0
  139. package/dist/types/auth-i18n/locales/tr.d.ts +14 -0
  140. package/dist/types/auth-i18n/locales/ur.d.ts +14 -0
  141. package/dist/types/auth-i18n/locales/vi.d.ts +14 -0
  142. package/dist/types/auth-i18n/locales/zh.d.ts +14 -0
  143. package/dist/types/auth-i18n/translations.d.ts +14 -0
  144. package/dist/types/beatui-i18n/default.d.ts +99 -0
  145. package/dist/types/beatui-i18n/index.d.ts +11 -0
  146. package/dist/types/beatui-i18n/locales/en.d.ts +63 -0
  147. package/dist/types/beatui-i18n/translations.d.ts +87 -0
  148. package/dist/types/better-auth/components/authenticated.d.ts +2 -2
  149. package/dist/types/better-auth/components/better-auth-container.d.ts +1 -1
  150. package/dist/types/better-auth/components/better-auth-modal.d.ts +1 -1
  151. package/dist/types/better-auth/index.d.ts +13 -0
  152. package/dist/types/better-auth/provider.d.ts +33 -0
  153. package/dist/types/better-auth/types.d.ts +112 -0
  154. package/dist/types/components/auth/auth-container.d.ts +63 -2
  155. package/dist/types/components/auth/auth-divider.d.ts +30 -0
  156. package/dist/types/components/auth/auth-email-prop.d.ts +25 -0
  157. package/dist/types/components/auth/index.d.ts +9 -0
  158. package/dist/types/components/auth/password-strength-indicator.d.ts +58 -0
  159. package/dist/types/components/auth/reset-password-form.d.ts +33 -0
  160. package/dist/types/components/auth/schemas.d.ts +183 -5
  161. package/dist/types/components/auth/signin-form.d.ts +33 -0
  162. package/dist/types/components/auth/signup-form.d.ts +36 -0
  163. package/dist/types/components/auth/social-login-button.d.ts +213 -0
  164. package/dist/types/components/auth/social-providers.d.ts +27 -1
  165. package/dist/types/components/auth/types.d.ts +299 -0
  166. package/dist/types/components/auth/utils.d.ts +198 -0
  167. package/dist/types/components/beatui.d.ts +35 -0
  168. package/dist/types/components/button/button.d.ts +61 -0
  169. package/dist/types/components/button/close-button.d.ts +32 -1
  170. package/dist/types/components/button/index.d.ts +2 -0
  171. package/dist/types/components/button/toggle-button-group.d.ts +95 -0
  172. package/dist/types/components/button/toggle-button.d.ts +60 -0
  173. package/dist/types/components/data/avatar-group.d.ts +74 -0
  174. package/dist/types/components/data/avatar.d.ts +62 -0
  175. package/dist/types/components/data/badge.d.ts +49 -2
  176. package/dist/types/components/data/calendar-shared.d.ts +59 -0
  177. package/dist/types/components/data/calendar.d.ts +107 -0
  178. package/dist/types/components/data/history-timeline.d.ts +35 -0
  179. package/dist/types/components/data/icon-badge.d.ts +14 -0
  180. package/dist/types/components/data/icon.d.ts +55 -4
  181. package/dist/types/components/data/index.d.ts +9 -0
  182. package/dist/types/components/data/page-drop-zone.d.ts +61 -8
  183. package/dist/types/components/data/presence-overlay.d.ts +26 -0
  184. package/dist/types/components/data/progress-bar.d.ts +81 -0
  185. package/dist/types/components/data/range-calendar.d.ts +104 -0
  186. package/dist/types/components/data/skeleton.d.ts +70 -0
  187. package/dist/types/components/data/table.d.ts +38 -11
  188. package/dist/types/components/data/tag.d.ts +40 -0
  189. package/dist/types/components/data/unstyled-drop-zone.d.ts +73 -0
  190. package/dist/types/components/form/control/control.d.ts +155 -0
  191. package/dist/types/components/form/control/date-utils.d.ts +81 -0
  192. package/dist/types/components/form/control/ensure-control.d.ts +28 -0
  193. package/dist/types/components/form/control/form-status.d.ts +63 -0
  194. package/dist/types/components/form/control/index.d.ts +10 -0
  195. package/dist/types/components/form/control/list-control.d.ts +100 -1
  196. package/dist/types/components/form/control/list-item-controls.d.ts +65 -0
  197. package/dist/types/components/form/controller/color-controller.d.ts +29 -1
  198. package/dist/types/components/form/controller/controller-validation.d.ts +31 -0
  199. package/dist/types/components/form/controller/controller.d.ts +286 -0
  200. package/dist/types/components/form/controller/index.d.ts +12 -0
  201. package/dist/types/components/form/controller/path.d.ts +69 -0
  202. package/dist/types/components/form/controller/union-controller.d.ts +106 -11
  203. package/dist/types/components/form/controller/utils.d.ts +67 -0
  204. package/dist/types/components/form/input/advanced-slider.d.ts +143 -0
  205. package/dist/types/components/form/input/appearance-selector.d.ts +39 -0
  206. package/dist/types/components/form/input/base64-input.d.ts +34 -0
  207. package/dist/types/components/form/input/base64s-input.d.ts +47 -0
  208. package/dist/types/components/form/input/bigint-input.d.ts +27 -0
  209. package/dist/types/components/form/input/checkbox-input.d.ts +46 -0
  210. package/dist/types/components/form/input/color-input.d.ts +42 -0
  211. package/dist/types/components/form/input/color-swatch-input.d.ts +53 -0
  212. package/dist/types/components/form/input/combobox-input.d.ts +73 -0
  213. package/dist/types/components/form/input/combobox-tags-input.d.ts +54 -0
  214. package/dist/types/components/form/input/date-input.d.ts +33 -0
  215. package/dist/types/components/form/input/date-time-input.d.ts +34 -0
  216. package/dist/types/components/form/input/dropdown-base.d.ts +52 -0
  217. package/dist/types/components/form/input/dropdown-input.d.ts +86 -0
  218. package/dist/types/components/form/input/duration-input.d.ts +18 -0
  219. package/dist/types/components/form/input/duration-mask.d.ts +24 -0
  220. package/dist/types/components/form/input/editable-text.d.ts +33 -0
  221. package/dist/types/components/form/input/email-input.d.ts +34 -0
  222. package/dist/types/components/form/input/file-input.d.ts +33 -0
  223. package/dist/types/components/form/input/files-input.d.ts +44 -0
  224. package/dist/types/components/form/input/index.d.ts +5 -0
  225. package/dist/types/components/form/input/input-adornment.d.ts +38 -0
  226. package/dist/types/components/form/input/input-container.d.ts +65 -0
  227. package/dist/types/components/form/input/input-options.d.ts +70 -0
  228. package/dist/types/components/form/input/input-wrapper.d.ts +78 -0
  229. package/dist/types/components/form/input/instant-input.d.ts +18 -0
  230. package/dist/types/components/form/input/lazy-native-select.d.ts +43 -0
  231. package/dist/types/components/form/input/list-input.d.ts +50 -0
  232. package/dist/types/components/form/input/mask-input.d.ts +158 -0
  233. package/dist/types/components/form/input/native-select.d.ts +50 -0
  234. package/dist/types/components/form/input/nullable-base64-input.d.ts +25 -0
  235. package/dist/types/components/form/input/nullable-bigint-input.d.ts +26 -0
  236. package/dist/types/components/form/input/nullable-date-input.d.ts +18 -0
  237. package/dist/types/components/form/input/nullable-date-time-input.d.ts +19 -0
  238. package/dist/types/components/form/input/nullable-duration-input.d.ts +19 -0
  239. package/dist/types/components/form/input/nullable-email-input.d.ts +18 -0
  240. package/dist/types/components/form/input/nullable-instant-input.d.ts +19 -0
  241. package/dist/types/components/form/input/nullable-mask-input.d.ts +24 -0
  242. package/dist/types/components/form/input/nullable-number-input.d.ts +29 -0
  243. package/dist/types/components/form/input/nullable-password-input.d.ts +18 -0
  244. package/dist/types/components/form/input/nullable-plain-date-input.d.ts +18 -0
  245. package/dist/types/components/form/input/nullable-plain-date-time-input.d.ts +18 -0
  246. package/dist/types/components/form/input/nullable-plain-month-day-input.d.ts +18 -0
  247. package/dist/types/components/form/input/nullable-plain-time-input.d.ts +18 -0
  248. package/dist/types/components/form/input/nullable-plain-year-month-input.d.ts +18 -0
  249. package/dist/types/components/form/input/nullable-rating-input.d.ts +33 -0
  250. package/dist/types/components/form/input/nullable-text-area.d.ts +27 -0
  251. package/dist/types/components/form/input/nullable-text-input.d.ts +18 -0
  252. package/dist/types/components/form/input/nullable-url-input.d.ts +18 -0
  253. package/dist/types/components/form/input/nullable-utils.d.ts +22 -2
  254. package/dist/types/components/form/input/nullable-uuid-input.d.ts +18 -0
  255. package/dist/types/components/form/input/nullable-zoned-date-time-input.d.ts +20 -0
  256. package/dist/types/components/form/input/number-input.d.ts +49 -0
  257. package/dist/types/components/form/input/option.d.ts +165 -0
  258. package/dist/types/components/form/input/otp-input.d.ts +77 -0
  259. package/dist/types/components/form/input/password-input.d.ts +39 -0
  260. package/dist/types/components/form/input/plain-date-input.d.ts +17 -0
  261. package/dist/types/components/form/input/plain-date-time-input.d.ts +17 -0
  262. package/dist/types/components/form/input/plain-month-day-input.d.ts +18 -0
  263. package/dist/types/components/form/input/plain-time-input.d.ts +17 -0
  264. package/dist/types/components/form/input/plain-year-month-input.d.ts +17 -0
  265. package/dist/types/components/form/input/radio-group.d.ts +108 -0
  266. package/dist/types/components/form/input/rating-input.d.ts +57 -0
  267. package/dist/types/components/form/input/segmented-input.d.ts +70 -1
  268. package/dist/types/components/form/input/select-tags-input.d.ts +69 -0
  269. package/dist/types/components/form/input/slider-input.d.ts +82 -0
  270. package/dist/types/components/form/input/switch.d.ts +59 -1
  271. package/dist/types/components/form/input/tag-input.d.ts +19 -0
  272. package/dist/types/components/form/input/tag-utils.d.ts +111 -0
  273. package/dist/types/components/form/input/tags-input.d.ts +18 -0
  274. package/dist/types/components/form/input/text-area.d.ts +42 -0
  275. package/dist/types/components/form/input/text-input.d.ts +63 -1
  276. package/dist/types/components/form/input/url-input.d.ts +34 -0
  277. package/dist/types/components/form/input/uuid-input.d.ts +19 -0
  278. package/dist/types/components/form/input/zoned-date-time-input.d.ts +20 -0
  279. package/dist/types/components/form/schema/standard-schema-v1.d.ts +98 -23
  280. package/dist/types/components/form/use-form.d.ts +146 -2
  281. package/dist/types/components/i18n/index.d.ts +9 -0
  282. package/dist/types/components/i18n/locale-direction.d.ts +21 -1
  283. package/dist/types/components/i18n/locale-selector.d.ts +45 -0
  284. package/dist/types/components/i18n/make-i18nprovider.d.ts +42 -0
  285. package/dist/types/components/json-schema/schema-types.d.ts +133 -0
  286. package/dist/types/components/json-structure/controls/deprecation-utils.d.ts +2 -3
  287. package/dist/types/components/json-structure/structure-types.d.ts +473 -19
  288. package/dist/types/components/layout/accordion.d.ts +77 -0
  289. package/dist/types/components/layout/action-card.d.ts +90 -2
  290. package/dist/types/components/layout/app-shell.d.ts +76 -0
  291. package/dist/types/components/layout/card.d.ts +27 -0
  292. package/dist/types/components/layout/center.d.ts +39 -0
  293. package/dist/types/components/layout/collapse.d.ts +28 -0
  294. package/dist/types/components/layout/divider.d.ts +84 -0
  295. package/dist/types/components/layout/group.d.ts +15 -0
  296. package/dist/types/components/layout/index.d.ts +2 -0
  297. package/dist/types/components/layout/nine-slice-scroll-view.d.ts +105 -0
  298. package/dist/types/components/layout/scrollable-panel.d.ts +54 -0
  299. package/dist/types/components/layout/sink.d.ts +46 -0
  300. package/dist/types/components/layout/stack.d.ts +16 -0
  301. package/dist/types/components/layout/with-breakpoint.d.ts +194 -0
  302. package/dist/types/components/lexical/code/language-selector.d.ts +2 -2
  303. package/dist/types/components/lexical/floating/block-handle.d.ts +2 -2
  304. package/dist/types/components/lexical/floating/floating-toolbar.d.ts +2 -2
  305. package/dist/types/components/lexical/floating/slash-command-palette.d.ts +2 -2
  306. package/dist/types/components/lexical/table/table-controls.d.ts +2 -2
  307. package/dist/types/components/lexical/toolbar/lexical-toolbar.d.ts +2 -2
  308. package/dist/types/components/lexical/toolbar/toolbar-helpers.d.ts +4 -2
  309. package/dist/types/components/misc/empty-state.d.ts +86 -0
  310. package/dist/types/components/misc/expando.d.ts +81 -0
  311. package/dist/types/components/misc/index.d.ts +2 -1
  312. package/dist/types/components/misc/link-portal.d.ts +40 -2
  313. package/dist/types/components/misc/notice.d.ts +93 -0
  314. package/dist/types/components/misc/notification-panel.d.ts +21 -0
  315. package/dist/types/components/misc/notification-provider.d.ts +141 -0
  316. package/dist/types/components/misc/notification.d.ts +93 -0
  317. package/dist/types/components/misc/style-portal.d.ts +31 -1
  318. package/dist/types/components/monaco/monaco-editor-input.d.ts +59 -2
  319. package/dist/types/components/navigation/breadcrumbs.d.ts +96 -0
  320. package/dist/types/components/navigation/flyout.d.ts +118 -16
  321. package/dist/types/components/navigation/index.d.ts +3 -0
  322. package/dist/types/components/navigation/link/link.d.ts +100 -0
  323. package/dist/types/components/navigation/menu.d.ts +155 -35
  324. package/dist/types/components/navigation/pagination.d.ts +82 -0
  325. package/dist/types/components/navigation/sidebar/sidebar-group.d.ts +42 -0
  326. package/dist/types/components/navigation/sidebar/sidebar-link.d.ts +101 -0
  327. package/dist/types/components/navigation/sidebar/sidebar-separator.d.ts +17 -0
  328. package/dist/types/components/navigation/sidebar/sidebar.d.ts +57 -0
  329. package/dist/types/components/navigation/tabs/tabs.d.ts +3 -2
  330. package/dist/types/components/navigation/toolbar/toolbar.d.ts +125 -0
  331. package/dist/types/components/navigation/tree-view.d.ts +95 -0
  332. package/dist/types/components/overlay/announcement-bar.d.ts +41 -2
  333. package/dist/types/components/overlay/block-command-palette.d.ts +25 -0
  334. package/dist/types/components/overlay/command-palette.d.ts +17 -0
  335. package/dist/types/components/overlay/dialogs.d.ts +213 -0
  336. package/dist/types/components/overlay/drawer.d.ts +76 -12
  337. package/dist/types/components/overlay/index.d.ts +4 -0
  338. package/dist/types/components/overlay/lightbox.d.ts +53 -10
  339. package/dist/types/components/overlay/modal.d.ts +113 -13
  340. package/dist/types/components/overlay/overlay.d.ts +61 -0
  341. package/dist/types/components/overlay/popover.d.ts +100 -0
  342. package/dist/types/components/overlay/ribbon.d.ts +58 -9
  343. package/dist/types/components/prosemirror/etoolbar-button.d.ts +10 -0
  344. package/dist/types/components/prosemirror/etoolbar-group.d.ts +10 -0
  345. package/dist/types/components/prosemirror/link-control.d.ts +43 -2
  346. package/dist/types/components/prosemirror/prosemirror-toolbar.d.ts +46 -6
  347. package/dist/types/components/prosemirror/utils.d.ts +113 -1
  348. package/dist/types/components/theme/style-utils.d.ts +95 -0
  349. package/dist/types/components/theme/theme.d.ts +39 -0
  350. package/dist/types/components/theme/types.d.ts +133 -1
  351. package/dist/types/components/typography/index.d.ts +1 -0
  352. package/dist/types/components/typography/kbd.d.ts +48 -0
  353. package/dist/types/components/typography/label.d.ts +45 -0
  354. package/dist/types/index.d.ts +14 -0
  355. package/dist/types/json-schema/index.d.ts +13 -0
  356. package/dist/types/json-schema-display/index.d.ts +12 -0
  357. package/dist/types/json-structure/index.d.ts +9 -4
  358. package/dist/types/markdown/index.d.ts +13 -0
  359. package/dist/types/monaco/index.d.ts +17 -0
  360. package/dist/types/monaco/lazy-loader.d.ts +79 -0
  361. package/dist/types/monaco/styles-url.d.ts +11 -0
  362. package/dist/types/monaco/styles.d.ts +11 -0
  363. package/dist/types/monaco/types.d.ts +47 -0
  364. package/dist/types/prosemirror/index.d.ts +12 -0
  365. package/dist/types/prosemirror/styles-url.d.ts +11 -0
  366. package/dist/types/prosemirror/styles.d.ts +10 -0
  367. package/dist/types/tailwind/google-fonts.d.ts +15 -0
  368. package/dist/types/tailwind/index.d.ts +13 -0
  369. package/dist/types/tailwind/preset.d.ts +111 -0
  370. package/dist/types/tailwind/vite-plugin.d.ts +39 -4
  371. package/dist/types/tokens/base-colors.d.ts +21 -0
  372. package/dist/types/tokens/breakpoints.d.ts +67 -0
  373. package/dist/types/tokens/colors.d.ts +213 -4
  374. package/dist/types/tokens/motion.d.ts +142 -3
  375. package/dist/types/tokens/radius.d.ts +99 -0
  376. package/dist/types/tokens/shadows.d.ts +85 -0
  377. package/dist/types/tokens/spacing.d.ts +111 -0
  378. package/dist/types/tokens/text-shadows.d.ts +82 -0
  379. package/dist/types/tokens/typography.d.ts +313 -25
  380. package/dist/types/tokens/z-index.d.ts +62 -0
  381. package/dist/types/utils/color.d.ts +297 -28
  382. package/dist/types/utils/download.d.ts +92 -0
  383. package/dist/types/utils/focus-trap.d.ts +67 -11
  384. package/dist/types/utils/format-file-size.d.ts +44 -0
  385. package/dist/ur-B6yB2JQ7.cjs +1 -0
  386. package/dist/ur-CvGP14xo.cjs +1 -0
  387. package/dist/{ur-Bg9eX81v.js → ur-Deo004ME.js} +16 -1
  388. package/dist/{ur-B69X-xNs.js → ur-DkIYJxsF.js} +82 -8
  389. package/dist/use-animated-toggle-89fKlXxy.js +195 -0
  390. package/dist/use-animated-toggle-DrqK7nUS.cjs +1 -0
  391. package/dist/{use-form-B56E_x5Y.js → use-form-BurzbPVV.js} +190 -2
  392. package/dist/{use-form-Cnp3XQ5X.cjs → use-form-Uree6QFy.cjs} +1 -1
  393. package/dist/vi-BYk1rJDv.js +53 -0
  394. package/dist/vi-DKw6PBja.js +175 -0
  395. package/dist/vi-Df4WZe9y.cjs +1 -0
  396. package/dist/vi-DneuUbkq.cjs +1 -0
  397. package/dist/{widget-customization-Ds9sicAg.js → widget-customization-0is7oTeP.js} +205 -204
  398. package/dist/widget-customization-B-LmxkPE.cjs +1 -0
  399. package/dist/zh-C5a9NGFW.cjs +1 -0
  400. package/dist/zh-CaKHseXJ.js +175 -0
  401. package/dist/zh-DFHuW_5g.cjs +1 -0
  402. package/dist/{zh-BIykcEu9.js → zh-DR7QaM65.js} +16 -1
  403. package/package.json +1 -1
  404. package/dist/ar-BsUm-TCn.cjs +0 -1
  405. package/dist/ar-D7CXDmVZ.cjs +0 -1
  406. package/dist/ar-nOSKXpIW.js +0 -101
  407. package/dist/auth-divider-BqZPH1-z.cjs +0 -1
  408. package/dist/de-BUFLEyKr.cjs +0 -1
  409. package/dist/de-WzsOu9Gn.cjs +0 -1
  410. package/dist/deep-merge-BYm0y62g.js +0 -1620
  411. package/dist/deep-merge-d7sf0xmN.cjs +0 -1
  412. package/dist/editor-toolbar-group--a-xgsJw.cjs +0 -1
  413. package/dist/editor-toolbar-group-CVpl5mxF.js +0 -31
  414. package/dist/es-CDqqzpCw.js +0 -101
  415. package/dist/es-Ds2Xf3wV.cjs +0 -1
  416. package/dist/fa-C7tE_hR3.js +0 -101
  417. package/dist/fa-Ct1UtDB7.cjs +0 -1
  418. package/dist/fr-Cdyopuz3.cjs +0 -1
  419. package/dist/fr-CzAkRFed.cjs +0 -1
  420. package/dist/he-D2oUloCJ.js +0 -101
  421. package/dist/he-DarDNPn0.cjs +0 -1
  422. package/dist/he-DlXALrK7.cjs +0 -1
  423. package/dist/hi-3dBhLwDs.cjs +0 -1
  424. package/dist/hi-D5ZlZoQq.js +0 -101
  425. package/dist/hi-tATwsXJ6.cjs +0 -1
  426. package/dist/index-DE2tjivA.cjs +0 -1
  427. package/dist/input-container-C6qEIjcA.cjs +0 -1
  428. package/dist/it-BmFag7j0.cjs +0 -1
  429. package/dist/it-DohtcWi9.cjs +0 -1
  430. package/dist/ja-Dj-bAKLf.cjs +0 -1
  431. package/dist/ja-eyTArrgS.cjs +0 -1
  432. package/dist/ko-BFLCDMMs.cjs +0 -1
  433. package/dist/ko-BomUE-yQ.cjs +0 -1
  434. package/dist/ko-Ch0jFsBV.js +0 -101
  435. package/dist/menu-CZzRsQP_.js +0 -372
  436. package/dist/menu-ClrU72xH.cjs +0 -1
  437. package/dist/nl-Bx2ACvr4.cjs +0 -1
  438. package/dist/nl-NuTdZO1s.js +0 -102
  439. package/dist/pl-QHl6sl8f.cjs +0 -1
  440. package/dist/pt-BETjHZrL.js +0 -101
  441. package/dist/pt-DZGw2Z-1.cjs +0 -1
  442. package/dist/pt-oBMmVYcu.cjs +0 -1
  443. package/dist/ru-CtxMmoa6.cjs +0 -1
  444. package/dist/ru-D03IuLqh.cjs +0 -1
  445. package/dist/text-input-B3VBat1k.js +0 -44
  446. package/dist/text-input-Ds8e7Z1G.cjs +0 -1
  447. package/dist/tr-B_-_1wua.cjs +0 -1
  448. package/dist/translations-B4-Zd2LM.cjs +0 -1
  449. package/dist/translations-D62qqNV9.cjs +0 -1
  450. package/dist/translations-DPr6c05Z.js +0 -67
  451. package/dist/ur-DvqAg9gW.cjs +0 -1
  452. package/dist/ur-DyUSmIbo.cjs +0 -1
  453. package/dist/use-animated-toggle-ChycsEoj.js +0 -175
  454. package/dist/use-animated-toggle-DR6CyMac.cjs +0 -1
  455. package/dist/vi-BdzxA60L.js +0 -101
  456. package/dist/vi-CBmPaHxg.cjs +0 -1
  457. package/dist/vi-D5R3YcU0.cjs +0 -1
  458. package/dist/vi-DhdsHHf_.js +0 -38
  459. package/dist/widget-customization-Dk7XcVly.cjs +0 -1
  460. package/dist/zh-CCGXcj5r.cjs +0 -1
  461. package/dist/zh-Cb1b8uik.cjs +0 -1
  462. package/dist/zh-Dn1UJiZa.js +0 -101
@@ -1,54 +1,126 @@
1
1
  /**
2
- * Color validation utilities for BeatUI color inputs
2
+ * Color validation, conversion, and formatting utilities for BeatUI.
3
+ *
4
+ * Provides comprehensive color handling including validation for multiple color
5
+ * formats (hex, RGB, RGBA, HSL), conversion between color spaces (RGB, HSL, HWB,
6
+ * OKLCH), contrast ratio calculation, and color string formatting.
7
+ *
8
+ * @module
3
9
  */
4
10
  /**
5
- * Validates if a string is a valid hex color
11
+ * Validates if a string is a valid hex color (3 or 6 character format, with or without `#`).
12
+ *
6
13
  * @param color - The color string to validate
7
- * @returns true if valid hex color, false otherwise
14
+ * @returns `true` if valid hex color, `false` otherwise
15
+ *
16
+ * @example
17
+ * ```ts
18
+ * isValidHexColor('#ff0000') // true
19
+ * isValidHexColor('abc') // true
20
+ * isValidHexColor('#gggggg') // false
21
+ * ```
8
22
  */
9
23
  export declare function isValidHexColor(color: string): boolean;
10
24
  /**
11
- * Validates if a string is a valid RGB color
12
- * @param color - The color string to validate (e.g., "rgb(255, 0, 0)")
13
- * @returns true if valid RGB color, false otherwise
25
+ * Validates if a string is a valid CSS `rgb()` color with values in range 0-255.
26
+ *
27
+ * @param color - The color string to validate (e.g., `"rgb(255, 0, 0)"`)
28
+ * @returns `true` if valid RGB color, `false` otherwise
29
+ *
30
+ * @example
31
+ * ```ts
32
+ * isValidRgbColor('rgb(255, 0, 0)') // true
33
+ * isValidRgbColor('rgb(300, 0, 0)') // false (out of range)
34
+ * isValidRgbColor('rgba(0, 0, 0, 1)') // false (use isValidRgbaColor)
35
+ * ```
14
36
  */
15
37
  export declare function isValidRgbColor(color: string): boolean;
16
38
  /**
17
- * Validates if a string is a valid RGBA color
18
- * @param color - The color string to validate (e.g., "rgba(255, 0, 0, 0.5)")
19
- * @returns true if valid RGBA color, false otherwise
39
+ * Validates if a string is a valid CSS `rgba()` color with values in range
40
+ * 0-255 for RGB and 0-1 for alpha.
41
+ *
42
+ * @param color - The color string to validate (e.g., `"rgba(255, 0, 0, 0.5)"`)
43
+ * @returns `true` if valid RGBA color, `false` otherwise
44
+ *
45
+ * @example
46
+ * ```ts
47
+ * isValidRgbaColor('rgba(255, 0, 0, 0.5)') // true
48
+ * isValidRgbaColor('rgba(255, 0, 0, 2)') // false (alpha out of range)
49
+ * ```
20
50
  */
21
51
  export declare function isValidRgbaColor(color: string): boolean;
22
52
  /**
23
- * Validates if a string is a valid HSL color
24
- * @param color - The color string to validate (e.g., "hsl(120, 100%, 50%)")
25
- * @returns true if valid HSL color, false otherwise
53
+ * Validates if a string is a valid CSS `hsl()` color with hue 0-360 and
54
+ * saturation/lightness 0-100%.
55
+ *
56
+ * @param color - The color string to validate (e.g., `"hsl(120, 100%, 50%)"`)
57
+ * @returns `true` if valid HSL color, `false` otherwise
58
+ *
59
+ * @example
60
+ * ```ts
61
+ * isValidHslColor('hsl(120, 100%, 50%)') // true
62
+ * isValidHslColor('hsl(400, 100%, 50%)') // false (hue out of range)
63
+ * ```
26
64
  */
27
65
  export declare function isValidHslColor(color: string): boolean;
28
66
  /**
29
- * Validates if a string is any valid color format
67
+ * Validates if a string is a valid color in any supported format
68
+ * (hex, RGB, RGBA, or HSL).
69
+ *
30
70
  * @param color - The color string to validate
31
- * @returns true if valid color in any supported format, false otherwise
71
+ * @returns `true` if valid color in any supported format, `false` otherwise
72
+ *
73
+ * @example
74
+ * ```ts
75
+ * isValidColor('#ff0000') // true
76
+ * isValidColor('rgb(255, 0, 0)') // true
77
+ * isValidColor('not-a-color') // false
78
+ * ```
32
79
  */
33
80
  export declare function isValidColor(color: string): boolean;
34
81
  /**
35
- * Normalizes a hex color to always include the # prefix and be 6 characters
82
+ * Normalizes a hex color to always include the `#` prefix and be 6 characters
83
+ * (lowercase). Expands 3-character shorthand to full 6-character form.
84
+ *
36
85
  * @param color - The hex color to normalize
37
- * @returns normalized hex color or null if invalid
86
+ * @returns Normalized hex color string (e.g., `'#ff0000'`) or `null` if invalid
87
+ *
88
+ * @example
89
+ * ```ts
90
+ * normalizeHexColor('abc') // '#aabbcc'
91
+ * normalizeHexColor('#FF0000') // '#ff0000'
92
+ * normalizeHexColor('invalid') // null
93
+ * ```
38
94
  */
39
95
  export declare function normalizeHexColor(color: string): string | null;
40
96
  /**
41
- * Converts RGB values to hex color
42
- * @param r - Red value (0-255)
43
- * @param g - Green value (0-255)
44
- * @param b - Blue value (0-255)
45
- * @returns hex color string
97
+ * Converts RGB channel values to a hex color string. Values are clamped to 0-255.
98
+ *
99
+ * @param r - Red channel value (0-255)
100
+ * @param g - Green channel value (0-255)
101
+ * @param b - Blue channel value (0-255)
102
+ * @returns Hex color string with `#` prefix (e.g., `'#ff0000'`)
103
+ *
104
+ * @example
105
+ * ```ts
106
+ * rgbToHex(255, 0, 0) // '#ff0000'
107
+ * rgbToHex(0, 128, 255) // '#0080ff'
108
+ * ```
46
109
  */
47
110
  export declare function rgbToHex(r: number, g: number, b: number): string;
48
111
  /**
49
- * Converts hex color to RGB values
50
- * @param hex - Hex color string (with or without #)
51
- * @returns RGB values object or null if invalid
112
+ * Converts a hex color string to RGB channel values. Handles both 3-character
113
+ * and 6-character hex values, with or without the `#` prefix.
114
+ *
115
+ * @param hex - Hex color string (with or without `#`)
116
+ * @returns Object with `r`, `g`, `b` properties (0-255 each) or `null` if invalid
117
+ *
118
+ * @example
119
+ * ```ts
120
+ * hexToRgb('#ff0000') // { r: 255, g: 0, b: 0 }
121
+ * hexToRgb('abc') // { r: 170, g: 187, b: 204 }
122
+ * hexToRgb('invalid') // null
123
+ * ```
52
124
  */
53
125
  export declare function hexToRgb(hex: string): {
54
126
  r: number;
@@ -56,22 +128,219 @@ export declare function hexToRgb(hex: string): {
56
128
  b: number;
57
129
  } | null;
58
130
  /**
59
- * Gets the contrast ratio between two colors
60
- * @param color1 - First color (hex format)
61
- * @param color2 - Second color (hex format)
62
- * @returns contrast ratio or null if invalid colors
131
+ * Calculates the WCAG 2.0 contrast ratio between two hex colors.
132
+ * The ratio ranges from 1:1 (identical) to 21:1 (black on white).
133
+ * A ratio of at least 4.5 is required for WCAG AA text compliance.
134
+ *
135
+ * @param color1 - First color in hex format
136
+ * @param color2 - Second color in hex format
137
+ * @returns The contrast ratio as a number, or `null` if either color is invalid
138
+ *
139
+ * @example
140
+ * ```ts
141
+ * getContrastRatio('#000000', '#ffffff') // 21
142
+ * getContrastRatio('#ff0000', '#00ff00') // ~2.91
143
+ * ```
63
144
  */
64
145
  export declare function getContrastRatio(color1: string, color2: string): number | null;
146
+ /**
147
+ * Parses any supported CSS color string into an `[r, g, b, a]` tuple.
148
+ *
149
+ * Supported formats:
150
+ * - Hex: `#RGB`, `#RGBA`, `#RRGGBB`, `#RRGGBBAA` (with or without `#`)
151
+ * - RGB: `rgb(r, g, b)`
152
+ * - RGBA: `rgba(r, g, b, a)`
153
+ * - HSL/HSLA: `hsl(h, s%, l%)`, `hsla(h, s%, l%, a)`, and modern syntax
154
+ * - HWB: `hwb(h w% b% / a)`
155
+ * - OKLCH: `oklch(L C h / a)`
156
+ *
157
+ * @param v - The color string to parse
158
+ * @returns A tuple of `[red, green, blue, alpha]` where RGB are 0-255 and alpha is 0-1.
159
+ * Returns `[0, 0, 0, 1]` for empty or unparseable input.
160
+ *
161
+ * @example
162
+ * ```ts
163
+ * parseAnyColor('#ff0000') // [255, 0, 0, 1]
164
+ * parseAnyColor('rgba(0, 128, 255, 0.5)') // [0, 128, 255, 0.5]
165
+ * parseAnyColor('oklch(0.623 0.214 259.815)') // [approximately 59, 130, 246, 1]
166
+ * ```
167
+ */
65
168
  export declare function parseAnyColor(v: string): [number, number, number, number];
169
+ /**
170
+ * Formats RGBA values into a CSS `rgba()` string. Alpha is clamped to 0-1
171
+ * and rounded to 2 decimal places; RGB values are rounded to integers.
172
+ *
173
+ * @param r - Red channel (0-255)
174
+ * @param g - Green channel (0-255)
175
+ * @param b - Blue channel (0-255)
176
+ * @param a - Alpha channel (0-1)
177
+ * @returns A CSS `rgba()` string (e.g., `'rgba(255, 0, 0, 0.5)'`)
178
+ *
179
+ * @example
180
+ * ```ts
181
+ * toRgbaString(255, 0, 0, 0.5) // 'rgba(255, 0, 0, 0.5)'
182
+ * ```
183
+ */
66
184
  export declare function toRgbaString(r: number, g: number, b: number, a: number): string;
185
+ /**
186
+ * Creates a seeded pseudo-random number generator using the Mulberry32 algorithm.
187
+ * Useful for generating deterministic "random" values (e.g., for color hashing).
188
+ *
189
+ * @param seed - The integer seed value
190
+ * @returns A function that returns the next pseudo-random number in the range [0, 1)
191
+ *
192
+ * @example
193
+ * ```ts
194
+ * const random = mulberry32(42)
195
+ * random() // 0.6011037519201636 (deterministic)
196
+ * random() // 0.4321023514959961
197
+ * ```
198
+ */
67
199
  export declare function mulberry32(seed: number): () => number;
200
+ /**
201
+ * Converts HSL color values to RGB. Hue is wrapped to 0-360 range.
202
+ *
203
+ * @param h - Hue in degrees (0-360)
204
+ * @param s - Saturation as a fraction (0-1)
205
+ * @param l - Lightness as a fraction (0-1)
206
+ * @returns A tuple of `[red, green, blue]` with values 0-255
207
+ *
208
+ * @example
209
+ * ```ts
210
+ * hslToRgb(0, 1, 0.5) // [255, 0, 0] (red)
211
+ * hslToRgb(120, 1, 0.5) // [0, 255, 0] (green)
212
+ * ```
213
+ */
68
214
  export declare function hslToRgb(h: number, s: number, l: number): [number, number, number];
215
+ /**
216
+ * Converts HWB (Hue-Whiteness-Blackness) color values to RGB.
217
+ * If whiteness + blackness exceeds 1, they are scaled proportionally.
218
+ *
219
+ * @param h - Hue in degrees (0-360)
220
+ * @param w - Whiteness as a fraction (0-1)
221
+ * @param bl - Blackness as a fraction (0-1)
222
+ * @returns A tuple of `[red, green, blue]` with values 0-255
223
+ *
224
+ * @example
225
+ * ```ts
226
+ * hwbToRgb(0, 0, 0) // [255, 0, 0] (pure red)
227
+ * hwbToRgb(0, 0.5, 0.5) // [128, 128, 128] (gray)
228
+ * ```
229
+ */
69
230
  export declare function hwbToRgb(h: number, w: number, bl: number): [number, number, number];
231
+ /**
232
+ * Converts RGB color values to HSL. Returns rounded integer values.
233
+ *
234
+ * @param r - Red channel (0-255)
235
+ * @param g - Green channel (0-255)
236
+ * @param b - Blue channel (0-255)
237
+ * @returns A tuple of `[hue, saturation, lightness]` where hue is 0-360 and
238
+ * saturation/lightness are 0-100 (percentage)
239
+ *
240
+ * @example
241
+ * ```ts
242
+ * rgbToHsl(255, 0, 0) // [0, 100, 50]
243
+ * rgbToHsl(0, 128, 255) // [210, 100, 50]
244
+ * ```
245
+ */
70
246
  export declare function rgbToHsl(r: number, g: number, b: number): [number, number, number];
247
+ /**
248
+ * Converts RGB color values to HWB (Hue-Whiteness-Blackness).
249
+ *
250
+ * @param r - Red channel (0-255)
251
+ * @param g - Green channel (0-255)
252
+ * @param b - Blue channel (0-255)
253
+ * @returns A tuple of `[hue, whiteness, blackness]` where hue is 0-360 and
254
+ * whiteness/blackness are 0-100 (percentage)
255
+ *
256
+ * @example
257
+ * ```ts
258
+ * rgbToHwb(255, 0, 0) // [0, 0, 0]
259
+ * rgbToHwb(128, 128, 128) // [0, 50, 50]
260
+ * ```
261
+ */
71
262
  export declare function rgbToHwb(r: number, g: number, b: number): [number, number, number];
263
+ /**
264
+ * Converts an sRGB channel value (0-255) to linear RGB (0-1).
265
+ * Applies the standard sRGB gamma decompression curve.
266
+ *
267
+ * @param u - sRGB channel value (0-255)
268
+ * @returns Linear RGB value (0-1)
269
+ */
72
270
  export declare function srgbToLinear(u: number): number;
271
+ /**
272
+ * Converts a linear RGB value (0-1) to an sRGB channel value (0-255).
273
+ * Applies the standard sRGB gamma compression curve, clamping and rounding the result.
274
+ *
275
+ * @param u - Linear RGB value (0-1)
276
+ * @returns sRGB channel value (0-255)
277
+ */
73
278
  export declare function linearToSrgb(u: number): number;
279
+ /**
280
+ * Converts OKLCH color values to sRGB. Uses the OKLab intermediate color space
281
+ * with matrix transforms to linear sRGB.
282
+ *
283
+ * @param L - Lightness (0-1)
284
+ * @param C - Chroma (0 to approximately 0.4)
285
+ * @param hDeg - Hue angle in degrees (0-360)
286
+ * @returns A tuple of `[red, green, blue]` with values 0-255
287
+ *
288
+ * @example
289
+ * ```ts
290
+ * oklchToRgb(0.623, 0.214, 259.815) // approximately [59, 130, 246] (blue-500)
291
+ * ```
292
+ */
74
293
  export declare function oklchToRgb(L: number, C: number, hDeg: number): [number, number, number];
294
+ /**
295
+ * Converts sRGB color values to OKLCH color space.
296
+ *
297
+ * @param r - Red channel (0-255)
298
+ * @param g - Green channel (0-255)
299
+ * @param b - Blue channel (0-255)
300
+ * @returns A tuple of `[lightness, chroma, hue]` where lightness is 0-1,
301
+ * chroma is 0 to ~0.4, and hue is 0-360 degrees
302
+ *
303
+ * @example
304
+ * ```ts
305
+ * rgbToOklch(59, 130, 246) // approximately [0.623, 0.214, 259.815]
306
+ * ```
307
+ */
75
308
  export declare function rgbToOklch(r: number, g: number, b: number): [number, number, number];
309
+ /**
310
+ * Formats RGBA color values into a CSS color string in the specified format.
311
+ *
312
+ * @param r - Red channel (0-255)
313
+ * @param g - Green channel (0-255)
314
+ * @param b - Blue channel (0-255)
315
+ * @param a - Alpha channel (0-1)
316
+ * @param fmt - The output format: `'hex'`, `'rgb'`, `'rgba'`, `'hsl'`, `'hsla'`, `'hwb'`, or `'oklch'`
317
+ * @param alphaEnabled - Whether to include alpha in formats that support it (hex, oklch)
318
+ * @returns A CSS color string in the requested format
319
+ *
320
+ * @example
321
+ * ```ts
322
+ * formatColor(255, 0, 0, 1, 'hex') // '#ff0000'
323
+ * formatColor(255, 0, 0, 0.5, 'hex', true) // '#ff000080'
324
+ * formatColor(255, 0, 0, 1, 'hsl') // 'hsl(0, 100%, 50%)'
325
+ * formatColor(255, 0, 0, 1, 'oklch') // 'oklch(0.628 0.258 29.2)'
326
+ * ```
327
+ */
76
328
  export declare function formatColor(r: number, g: number, b: number, a: number, fmt: 'hex' | 'rgb' | 'rgba' | 'hsl' | 'hsla' | 'hwb' | 'oklch', alphaEnabled?: boolean): string;
329
+ /**
330
+ * Resolves the effective color format based on whether alpha is enabled.
331
+ * When alpha is enabled, `'rgb'` becomes `'rgba'` and `'hsl'` becomes `'hsla'`.
332
+ * When alpha is disabled, `'rgba'` becomes `'rgb'` and `'hsla'` becomes `'hsl'`.
333
+ * Other formats (hex, hwb, oklch) are returned unchanged.
334
+ *
335
+ * @param fmt - The requested color format
336
+ * @param alphaEnabled - Whether alpha channel is enabled
337
+ * @returns The resolved effective color format
338
+ *
339
+ * @example
340
+ * ```ts
341
+ * resolveEffectiveFormat('rgb', true) // 'rgba'
342
+ * resolveEffectiveFormat('rgba', false) // 'rgb'
343
+ * resolveEffectiveFormat('hex', true) // 'hex'
344
+ * ```
345
+ */
77
346
  export declare function resolveEffectiveFormat(fmt: 'hex' | 'rgb' | 'rgba' | 'hsl' | 'hsla' | 'hwb' | 'oklch', alphaEnabled: boolean): 'hex' | 'rgb' | 'rgba' | 'hsl' | 'hsla' | 'hwb' | 'oklch';
@@ -1,24 +1,116 @@
1
+ /**
2
+ * File download utilities for BeatUI.
3
+ *
4
+ * Provides functions for downloading files from URLs, creating downloads from
5
+ * in-memory content, and monitoring download progress with reactive signals.
6
+ *
7
+ * @module
8
+ */
1
9
  import { Signal } from '@tempots/dom';
10
+ /**
11
+ * Represents an in-progress download with a known content length.
12
+ */
2
13
  export interface Progress {
14
+ /** Discriminant for the `DownloadResult` union. */
3
15
  type: 'progress';
16
+ /** Download progress as a fraction from 0 to 1. */
4
17
  value: number;
5
18
  }
19
+ /**
20
+ * Represents an in-progress download with an unknown content length.
21
+ */
6
22
  export interface Undetermined {
23
+ /** Discriminant for the `DownloadResult` union. */
7
24
  type: 'undetermined';
8
25
  }
26
+ /**
27
+ * Represents a completed download with the resulting file.
28
+ */
9
29
  export interface Done {
30
+ /** Discriminant for the `DownloadResult` union. */
10
31
  type: 'done';
32
+ /** The downloaded file. */
11
33
  file: File;
12
34
  }
35
+ /**
36
+ * Represents a failed download with the error that occurred.
37
+ */
13
38
  export interface DownloadError {
39
+ /** Discriminant for the `DownloadResult` union. */
14
40
  type: 'error';
41
+ /** The error that caused the download failure. */
15
42
  error: Error;
16
43
  }
44
+ /**
45
+ * Discriminated union representing the current state of a monitored download.
46
+ * Use the `type` property to determine the current state.
47
+ */
17
48
  export type DownloadResult = Progress | Undetermined | Done | DownloadError;
49
+ /**
50
+ * Downloads a file from a URL and triggers a browser download dialog.
51
+ * Falls back to opening the URL in a new tab if the fetch fails (e.g., due to CORS).
52
+ *
53
+ * @param url - The URL to download from
54
+ * @param filename - The suggested filename for the download
55
+ * @default filename ''
56
+ *
57
+ * @example
58
+ * ```ts
59
+ * await downloadUrl('https://example.com/file.pdf', 'document.pdf')
60
+ * ```
61
+ */
18
62
  export declare const downloadUrl: (url: string, filename?: string) => Promise<void>;
63
+ /**
64
+ * Creates a browser download from in-memory content (string or binary data).
65
+ *
66
+ * @param content - The content to download, either a string or a `Uint8Array`
67
+ * @param filename - The suggested filename for the download
68
+ * @param type - The MIME type of the content
69
+ * @default type 'application/octet-stream'
70
+ *
71
+ * @example
72
+ * ```ts
73
+ * downloadContent('Hello, world!', 'hello.txt', 'text/plain')
74
+ * downloadContent(new Uint8Array([0x89, 0x50, 0x4e, 0x47]), 'image.png', 'image/png')
75
+ * ```
76
+ */
19
77
  export declare const downloadContent: (content: string | Uint8Array<ArrayBuffer>, filename: string, type?: string) => void;
78
+ /**
79
+ * Downloads a file from a URL while providing real-time progress monitoring
80
+ * through a reactive signal. Returns both the progress signal and a cancel function.
81
+ *
82
+ * The signal emits:
83
+ * - `{ type: 'progress', value: 0..1 }` when content length is known
84
+ * - `{ type: 'undetermined' }` when content length is unknown
85
+ * - `{ type: 'done', file }` on successful completion
86
+ * - `{ type: 'error', error }` on failure
87
+ *
88
+ * @param url - The URL to download from
89
+ * @returns An object with a `signal` for monitoring progress and a `cancel` function to abort
90
+ *
91
+ * @example
92
+ * ```ts
93
+ * const { signal, cancel } = downloadUrlAndMonitor('https://example.com/large-file.zip')
94
+ * signal.on(result => {
95
+ * if (result.type === 'progress') console.log(`${result.value * 100}%`)
96
+ * if (result.type === 'done') downloadFile(result.file)
97
+ * })
98
+ * // To cancel: cancel()
99
+ * ```
100
+ */
20
101
  export declare const downloadUrlAndMonitor: (url: string) => {
21
102
  signal: Signal<DownloadResult>;
22
103
  cancel: () => void;
23
104
  };
105
+ /**
106
+ * Triggers a browser download dialog for a `File` object.
107
+ *
108
+ * @param file - The `File` object to download
109
+ *
110
+ * @example
111
+ * ```ts
112
+ * const file = new File(['content'], 'example.txt', { type: 'text/plain' })
113
+ * downloadFile(file)
114
+ * ```
115
+ */
24
116
  export declare const downloadFile: (file: File) => void;
@@ -1,30 +1,86 @@
1
+ /**
2
+ * Focus trap utilities for BeatUI.
3
+ *
4
+ * Provides a focus trap implementation that constrains keyboard focus within
5
+ * a container element. Supports Tab/Shift+Tab cycling, Escape key handling,
6
+ * click-outside detection, initial focus targeting, and focus restoration
7
+ * on deactivation. Integrates with the `@tempots/dom` reactive rendering system.
8
+ *
9
+ * @module
10
+ */
1
11
  import { Renderable } from '@tempots/dom';
2
12
  /**
3
- * Focus trap options
13
+ * Configuration options for the focus trap behavior.
4
14
  */
5
15
  export interface FocusTrapOptions {
6
- /** Whether the focus trap is active */
16
+ /**
17
+ * Whether the focus trap is active.
18
+ * @default true
19
+ */
7
20
  active?: boolean;
8
- /** Whether to handle escape key */
21
+ /**
22
+ * Whether pressing Escape deactivates the focus trap.
23
+ * @default true
24
+ */
9
25
  escapeDeactivates?: boolean;
10
- /** Callback when escape key is pressed */
26
+ /** Callback invoked when the Escape key is pressed (if `escapeDeactivates` is true). */
11
27
  onEscape?: () => void;
12
- /** Element to focus initially (if not provided, focuses first focusable element) */
28
+ /**
29
+ * Element to receive initial focus when the trap activates.
30
+ * Can be an `HTMLElement` or a function returning one.
31
+ * If not provided, the first focusable element in the container is focused.
32
+ */
13
33
  initialFocus?: HTMLElement | (() => HTMLElement | null);
14
- /** Element to return focus to when trap is deactivated */
34
+ /**
35
+ * Element to return focus to when the trap is deactivated.
36
+ * Can be an `HTMLElement` or a function returning one.
37
+ * If not provided, focus returns to the element that was focused before activation.
38
+ */
15
39
  returnFocus?: HTMLElement | (() => HTMLElement | null);
16
- /** Whether to prevent outside clicks */
40
+ /**
41
+ * Whether clicking outside the container triggers deactivation.
42
+ * @default false
43
+ */
17
44
  clickOutsideDeactivates?: boolean;
18
- /** Callback when clicking outside */
45
+ /** Callback invoked when a click occurs outside the container (if `clickOutsideDeactivates` is true). */
19
46
  onClickOutside?: () => void;
20
47
  }
21
48
  /**
22
- * Creates a focus trap within an element
23
- * Returns a TNode that should be added to the container element
49
+ * Creates a focus trap `Renderable` that constrains keyboard focus within
50
+ * the parent container element. When added to a container, it intercepts
51
+ * Tab/Shift+Tab navigation to cycle through focusable children, optionally
52
+ * handles Escape key, and restores focus on disposal.
53
+ *
54
+ * @param options - Configuration for the focus trap behavior
55
+ * @returns A `Renderable` that should be included as a child of the container element
56
+ *
57
+ * @example
58
+ * ```ts
59
+ * html.div(
60
+ * FocusTrap({
61
+ * escapeDeactivates: true,
62
+ * onEscape: () => closeDialog(),
63
+ * }),
64
+ * html.button('Close'),
65
+ * html.input({ type: 'text' }),
66
+ * )
67
+ * ```
24
68
  */
25
69
  export declare function FocusTrap(options?: FocusTrapOptions): Renderable;
26
70
  /**
27
- * Hook for managing focus trap state
71
+ * Creates a focus trap controller with `activate` and `deactivate` methods.
72
+ * Each call to `activate()` or `deactivate()` returns a new `Renderable`
73
+ * configured with the provided options.
74
+ *
75
+ * @param options - Configuration for the focus trap behavior
76
+ * @returns An object with `activate` and `deactivate` methods that return `Renderable` instances
77
+ *
78
+ * @example
79
+ * ```ts
80
+ * const trap = useFocusTrap({ onEscape: () => console.log('escaped') })
81
+ * // trap.activate() returns a Renderable with active=true
82
+ * // trap.deactivate() returns a Renderable with active=false
83
+ * ```
28
84
  */
29
85
  export declare function useFocusTrap(options?: FocusTrapOptions): {
30
86
  activate: () => Renderable;
@@ -1,6 +1,50 @@
1
+ /**
2
+ * File size formatting utilities for BeatUI.
3
+ *
4
+ * Provides human-readable file size formatting with locale-aware number formatting,
5
+ * configurable units, and support for both `number` and `bigint` inputs.
6
+ *
7
+ * @module
8
+ */
9
+ /**
10
+ * Options for configuring file size formatting behavior.
11
+ */
1
12
  export type FormatFileSizeOptions = {
13
+ /**
14
+ * Array of unit labels from smallest to largest.
15
+ * @default ['B', 'KB', 'MB', 'GB', 'TB']
16
+ */
2
17
  units?: string[];
18
+ /**
19
+ * Number of decimal places to show for values above bytes.
20
+ * @default 0
21
+ */
3
22
  decimalPlaces?: number;
23
+ /**
24
+ * BCP 47 locale string for number formatting (e.g., `'en-US'`, `'de-DE'`).
25
+ * Uses the browser default locale if not specified.
26
+ */
4
27
  locale?: string;
5
28
  };
29
+ /**
30
+ * Formats a byte count into a human-readable file size string using
31
+ * `Intl.NumberFormat` for locale-aware formatting.
32
+ *
33
+ * Automatically selects the most appropriate unit (B, KB, MB, GB, TB) based
34
+ * on the magnitude. Supports both `number` and `bigint` inputs for handling
35
+ * very large file sizes without precision loss.
36
+ *
37
+ * @param bytes - The file size in bytes (supports `number` or `bigint`)
38
+ * @param options - Formatting options
39
+ * @returns A formatted file size string (e.g., `'1 KB'`, `'2.5 MB'`)
40
+ *
41
+ * @example
42
+ * ```ts
43
+ * formatFileSize(0) // '0 B'
44
+ * formatFileSize(1024) // '1 KB'
45
+ * formatFileSize(1536, { decimalPlaces: 1 }) // '1.5 KB'
46
+ * formatFileSize(1073741824n) // '1 GB'
47
+ * formatFileSize(1024, { locale: 'de-DE' }) // '1 KB' (with German formatting)
48
+ * ```
49
+ */
6
50
  export declare function formatFileSize(bytes: number | bigint, { units, decimalPlaces, locale, }?: FormatFileSizeOptions): string;
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r={signInTitle:"سائن ان",signInButton:"سائن ان",emailLabel:"ای میل",passwordLabel:"پاس ورڈ",rememberMeLabel:"مجھے یاد رکھیں",forgotPasswordLink:"پاس ورڈ بھول گئے؟",noAccountLink:"اکاؤنٹ نہیں ہے؟ سائن اپ کریں",signUpTitle:"سائن اپ",signUpButton:"سائن اپ",nameLabel:"نام",confirmPasswordLabel:"پاس ورڈ کی تصدیق کریں",acceptTermsLabel:"میں شرائط و ضوابط کو قبول کرتا ہوں",hasAccountLink:"پہلے سے اکاؤنٹ ہے؟ سائن ان کریں",resetPasswordTitle:"پاس ورڈ ری سیٹ کریں",resetPasswordButton:"پاس ورڈ ری سیٹ کریں",resetPasswordDescription:"اپنا پاس ورڈ ری سیٹ کرنے کے لیے اپنا ای میل درج کریں۔",backToSignInLink:"سائن ان پر واپس جائیں",continueWithProvider:e=>`${e} کے ساتھ جاری رکھیں`,passwordStrengthWeak:"کمزور",passwordStrengthFair:"ٹھیک",passwordStrengthGood:"اچھا",passwordStrengthStrong:"مضبوط",orDivider:"یا",error:"ایک خرابی ہوئی",required:"ضروری",authenticationTitle:"تصدیق",passwordMinLength:e=>`پاس ورڈ کم از کم ${e} حروف کا ہونا چاہیے`,passwordRequireUppercase:"پاس ورڈ میں کم از کم ایک بڑا حرف ہونا چاہیے",passwordRequireLowercase:"پاس ورڈ میں کم از کم ایک چھوٹا حرف ہونا چاہیے",passwordRequireNumber:"پاس ورڈ میں کم از کم ایک نمبر ہونا چاہیے",passwordRequireSpecialChar:"پاس ورڈ میں کم از کم ایک خاص حرف ہونا چاہیے",emailRequired:"ای میل ضروری ہے",invalidEmail:"براہ کرم ایک درست ای میل پتہ درج کریں",passwordRequired:"پاس ورڈ ضروری ہے",nameRequired:"نام ضروری ہے",confirmPasswordRequired:"براہ کرم پاس ورڈ کی تصدیق کریں",acceptTermsRequired:"آپ کو شرائط و ضوابط قبول کرنا ضروری ہے",passwordsDoNotMatch:"پاس ورڈ مماثل نہیں ہیں",invalidPassword:"غلط پاس ورڈ",invalidEmailAddress:"غلط ای میل"};exports.default=r;
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./translations-gVgMyNno.cjs"),r={loadingExtended:"لوڈ ہو رہا ہے، براہ کرم انتظار کریں",loadingShort:"لوڈ ہو رہا ہے...",locale:"زبان",iconDescription:"آئیکن",loadingIcon:"لوڈنگ آئیکن",failedToLoadIcon:"آئیکن لوڈ کرنے میں ناکام",editLabel:"ترمیم",selectOne:"ایک منتخب کریں",selectNone:"کوئی نہیں",selectMany:"متعدد منتخب کریں",noResults:"کوئی نتیجہ نہیں",passwordPlaceholderText:"خفیہ پاس ورڈ",togglePasswordVisibility:"پاس ورڈ کی مرئیت تبدیل کریں",toggleMenu:"مینو ٹوگل کریں",toggleAside:"سائیڈ پینل ٹوگل کریں",mainNavigation:"بنیادی نیویگیشن",sidebar:"سائیڈ بار",closeDrawer:"دراز بند کریں",closeModal:"ماڈل بند کریں",confirm:"تصدیق",cancel:"منسوخ",addLabel:"شامل کریں",removeItem:"آئٹم ہٹائیں",currentLocale:"اردو",ar:"عربی",de:"جرمن",en:"انگریزی",es:"ہسپانوی",fr:"فرانسیسی",he:"عبرانی",hi:"ہندی",it:"اطالوی",ja:"جاپانی",ko:"کوریائی",nl:"ڈچ",pl:"پولش",pt:"پرتگالی",ru:"روسی",tr:"ترکی",vi:"ویتنامی",zh:"چینی",fa:"فارسی",ur:"اردو",emailPlaceholderText:"اپنا ای میل داخل کریں",incrementValue:"قدر اضافہ کریں",decrementValue:"قدر کم کریں",dropZoneInstructions:e=>e?"منتخب کرنے کے لیے کلک کریں یا فائلیں یہاں گھسیٹیں، یا فائل منتخب کرنے کے لیے Enter یا Space دبائیں":"فائلیں یہاں گھسیٹیں",fileSizeUnits:["بائٹس","KB","MB","GB","TB"],removeFile:"فائل حذف کریں",clearAllFiles:"تمام فائلیں صاف کریں",clearValue:"قدر صاف کریں",unknownType:"نامعلوم قسم",filesInputInstructions:(e,o,n)=>{let l=e==null||e>1?"منتخب کرنے کے لیے کلک کریں یا فائلیں یہاں گھسیٹیں":"منتخب کرنے کے لیے کلک کریں یا فائل یہاں گھسیٹیں";if(e||o){const t=[];if(e!=null&&e>1&&t.push(`زیادہ سے زیادہ ${e} فائلیں`),o&&n){const a=i.formatFileSize(o,{units:n});t.push(`ہر ایک زیادہ سے زیادہ ${a}`)}t.length>0&&(l+=` (${t.join("، ")})`)}return l},paginationLabel:"صفحہ بندی",firstPage:"پہلا صفحہ",previousPage:"پچھلا صفحہ",nextPage:"اگلا صفحہ",lastPage:"آخری صفحہ",breadcrumbs:"بریڈ کرمبز",commandPalette:"کمانڈ پیلیٹ",typeACommand:"کمانڈ ٹائپ کریں...",noResultsFound:"کوئی نتیجہ نہیں ملا",noMatchingCommands:"کوئی مماثل کمانڈ نہیں ملی",appearanceSystem:"سسٹم",appearanceLight:"ہلکا",appearanceDark:"گہرا",ok:"OK",changeTypeConfirmation:"قسم تبدیل کرنے سے موجودہ قدر صاف ہو جائے گی۔ جاری رکھیں؟",notifications:"اطلاعات",markAllAsRead:"سب کو پڑھا ہوا نشان زد کریں",noNotifications:"کوئی اطلاع نہیں",schemaConflictsDetected:"اسکیما تنازعات کا پتا چلا",schemaViolationsDetected:"اسکیما خلاف ورزیوں کا پتا چلا",properties:"خصوصیات",uploading:"اپ لوڈ ہو رہا ہے...",dropFilesOrBrowse:"فائلیں یہاں چھوڑیں یا براؤز کرنے کے لیے کلک کریں",acceptedTypes:e=>`قابل قبول اقسام: ${e}`,enterUrlPrompt:"URL درج کریں:",exceeded:"(حد سے تجاوز)",pdfPreview:"PDF پیش نظارہ",lexical:{fontFamily:"فونٹ فیملی",fontSize:"فونٹ سائز",fontColor:"فونٹ رنگ",highlightColor:"ہائی لائٹ رنگ",backgroundColor:"پس منظر رنگ",bold:"بولڈ",italic:"ترچھا",underline:"خط کشیدہ",strikethrough:"کٹا ہوا",code:"کوڈ",clearFormatting:"فارمیٹنگ صاف کریں",normal:"عام",heading:e=>`سرخی ${e}`,bulletList:"بلٹ فہرست",orderedList:"نمبر شدہ فہرست",checkList:"چیک فہرست",indent:"اندر کریں",outdent:"باہر کریں",blockquote:"اقتباس",codeBlock:"کوڈ بلاک",horizontalRule:"افقی لکیر",insertTable:"ٹیبل داخل کریں",link:"لنک",undo:"واپس",redo:"دوبارہ",cut:"کاٹیں",copy:"نقل",paste:"چسپاں",defaultOption:"پہلے سے طے شدہ",slashCommands:"سلیش کمانڈز",noCommandsFound:"کوئی کمانڈ نہیں ملی",changeBlockType:"بلاک کی قسم تبدیل کریں",blockTypes:"بلاک کی اقسام",enterUrl:"URL درج کریں:"},prosemirror:{bold:"Bold",italic:"Italic",code:"Code",link:"Link",removeLink:"Remove Link",heading:e=>`Heading ${e}`,bulletList:"Bullet List",orderedList:"Ordered List",blockquote:"Blockquote",codeBlock:"Code Block",horizontalRule:"Horizontal Rule",linkUrlPlaceholder:"https://example.com"},pdfPageViewer:{loading:"Loading PDF...",loadFailed:"Failed to load PDF",invalidPdf:"Invalid PDF file",pageOutOfRange:(e,o)=>`Page ${e} is out of range (1-${o})`,renderFailed:"Failed to render PDF page"}};exports.default=r;