infinity-forge 3.4.7 → 3.4.9

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 (292) hide show
  1. package/dist/sites/components/default-pages/blog/components/blog-item/index.d.ts +1 -1
  2. package/dist/sites/components/default-pages/blog/components/blog-item/index.js +1 -1
  3. package/dist/sites/components/default-pages/blog/components/categorias/index.js +1 -1
  4. package/dist/sites/components/default-pages/blog/components/featured-blog/featured-blog-item/index.d.ts +4 -0
  5. package/dist/sites/components/default-pages/blog/components/featured-blog/featured-blog-item/index.js +42 -0
  6. package/dist/sites/components/default-pages/blog/components/featured-blog/index.js +1 -1
  7. package/dist/sites/components/default-pages/blog/components/side-box-newsletter/index.js +1 -1
  8. package/dist/sites/components/default-pages/blog/components/side-box-search/index.js +1 -1
  9. package/dist/sites/components/default-pages/blog/components/title-blog/index.js +1 -1
  10. package/dist/system/presentation/components/data/buttons/sidebar-button/index.js +1 -1
  11. package/dist/system/presentation/components/data/chat/card-message/index.d.ts +1 -1
  12. package/dist/system/presentation/components/data/chat/card-message/index.js +1 -1
  13. package/dist/system/presentation/components/data/chat/loader/index.js +1 -1
  14. package/dist/system/presentation/components/data/menu/components/menu-item/index.js +80 -0
  15. package/dist/system/presentation/components/data/menu/modes/collapsed-menu/index.js +44 -0
  16. package/dist/system/presentation/components/data/menu/modes/collapsed-menu/styles.js +15 -0
  17. package/dist/system/presentation/components/data/menu/modes/opened/index.js +51 -0
  18. package/dist/system/presentation/components/data/menu/modes/opened/styles.js +15 -0
  19. package/dist/system/presentation/components/data/notifications/card/index.d.ts +1 -1
  20. package/dist/system/presentation/components/data/notifications/card/index.js +1 -1
  21. package/dist/system/presentation/components/data/profile-infos/profile/index.js +1 -1
  22. package/dist/system/presentation/components/data/tab/tab-item/index.js +1 -1
  23. package/dist/system/presentation/components/layout/header/components/menu-right/component.d.ts +6 -0
  24. package/dist/system/presentation/components/layout/header/components/menu-right/component.js +35 -0
  25. package/dist/system/presentation/components/layout/header/components/menu-right/index.d.ts +3 -0
  26. package/dist/system/presentation/components/layout/header/components/menu-right/index.js +20 -0
  27. package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/card/index.d.ts +1 -1
  28. package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/card/index.js +3 -3
  29. package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/index.js +3 -3
  30. package/dist/system/presentation/components/layout/header/components/menu-right/messages/content/interfaces.d.ts +1 -1
  31. package/dist/system/presentation/components/layout/header/components/menu-right/messages/index.js +4 -4
  32. package/dist/system/presentation/components/layout/header/components/menu-right/profile/content/index.js +3 -3
  33. package/dist/system/presentation/components/layout/header/components/menu-right/profile/index.js +4 -4
  34. package/dist/system/presentation/components/layout/header/components/search-modal/index.js +40 -0
  35. package/dist/system/presentation/components/layout/header/components/search-modal/search-list/index.js +3 -3
  36. package/dist/system/presentation/components/layout/header/components/search-modal/trigger/index.js +2 -2
  37. package/dist/system/presentation/components/layout/header/version-01/index.js +1 -1
  38. package/dist/system/presentation/components/pages/menus/table/columns.d.ts +1 -1
  39. package/dist/system/presentation/components/pages/menus/table/create.d.ts +1 -1
  40. package/dist/system/presentation/components/pages/menus/table/create.js +1 -1
  41. package/dist/system/presentation/components/pages/menus/table/delete.js +1 -1
  42. package/dist/system/presentation/components/pages/menus/table/edit.d.ts +1 -1
  43. package/dist/system/presentation/components/pages/menus/table/edit.js +1 -0
  44. package/dist/system/presentation/components/pages/menus/table/icon/index.js +34 -0
  45. package/dist/system/presentation/components/pages/users/table/columns.d.ts +1 -1
  46. package/dist/system/presentation/components/pages/users/table/create.d.ts +1 -1
  47. package/dist/system/presentation/components/pages/users/table/create.js +1 -1
  48. package/dist/system/presentation/components/pages/users/table/delete.js +1 -1
  49. package/dist/system/presentation/components/pages/users/table/edit.d.ts +1 -1
  50. package/dist/system/presentation/components/pages/users/table/edit.js +1 -0
  51. package/dist/system/presentation/context/auth/components/login/form-login/index.js +12 -0
  52. package/dist/system/presentation/context/auth/components/login/index.js +1 -1
  53. package/dist/system/presentation/context/auth/components/private-page/index.js +1 -1
  54. package/dist/system/presentation/hooks/locales/ibge/use-load-cities-by-uf/index.d.ts +1 -1
  55. package/dist/system/presentation/hooks/locales/ibge/use-load-cities-by-uf/index.js +1 -1
  56. package/dist/system/presentation/hooks/ui/use-table/components/table/actions/delete/index.d.ts +1 -1
  57. package/dist/system/presentation/hooks/ui/use-table/components/table/actions/delete/index.js +2 -2
  58. package/dist/system/presentation/hooks/ui/use-table/components/table/actions/index.d.ts +1 -1
  59. package/dist/system/presentation/hooks/ui/use-table/components/table/actions/index.js +4 -4
  60. package/dist/system/presentation/hooks/ui/use-table/components/table/active-filters/index.d.ts +1 -1
  61. package/dist/system/presentation/hooks/ui/use-table/components/table/active-filters/index.js +2 -2
  62. package/dist/system/presentation/hooks/ui/use-table/components/table/create/index.d.ts +1 -1
  63. package/dist/system/presentation/hooks/ui/use-table/components/table/create/index.js +3 -3
  64. package/dist/system/presentation/hooks/ui/use-table/components/table/export/index.d.ts +1 -1
  65. package/dist/system/presentation/hooks/ui/use-table/components/table/export/index.js +2 -2
  66. package/dist/system/presentation/hooks/ui/use-table/components/table/filters/index.d.ts +1 -1
  67. package/dist/system/presentation/hooks/ui/use-table/components/table/filters/index.js +3 -3
  68. package/dist/system/presentation/hooks/ui/use-table/components/table/index.d.ts +2 -0
  69. package/dist/system/presentation/hooks/ui/use-table/components/table/index.js +105 -0
  70. package/dist/system/presentation/hooks/ui/use-table/components/table/interfaces.d.ts +14 -0
  71. package/dist/system/presentation/hooks/ui/use-table/components/table/pagination/index.d.ts +1 -1
  72. package/dist/system/presentation/hooks/ui/use-table/components/table/pagination/index.js +3 -3
  73. package/dist/system/presentation/hooks/ui/use-table/components/table/skeleton-table/index.js +2 -2
  74. package/dist/system/presentation/hooks/ui/use-table/components/table/thead-item/index.d.ts +1 -1
  75. package/dist/system/presentation/hooks/ui/use-table/components/table/thead-item/index.js +2 -2
  76. package/dist/system/presentation/hooks/ui/use-table/components/table/thead-item/interfaces.d.ts +1 -1
  77. package/dist/system/presentation/hooks/ui/use-table/query/hook.js +1 -1
  78. package/dist/ui/components/carousel/carousel-lib/core/modules/observer/observer.js +2 -2
  79. package/dist/ui/components/carousel/carousel-lib/core/modules/resize/resize.js +1 -1
  80. package/dist/ui/components/form/input-cep/use-cep/providers/ibge/hook.d.ts +1 -1
  81. package/dist/ui/components/form/input-cep/use-cep/providers/ibge/hook.js +1 -1
  82. package/dist/ui/components/form/input-cep/use-cep/providers/ibge/index.d.ts +3 -3
  83. package/dist/ui/components/form/input-cep/use-cep/providers/ibge/index.js +3 -3
  84. package/dist/ui/components/form/input-date-picker/calendar/calendar-header/index.js +62 -0
  85. package/dist/ui/components/form/input-date-picker/calendar/days/index.d.ts +2 -0
  86. package/dist/ui/components/form/input-date-picker/calendar/days/index.js +87 -0
  87. package/dist/ui/components/form/input-date-picker/calendar/months/index.d.ts +2 -0
  88. package/dist/ui/components/form/input-date-picker/calendar/months/index.js +66 -0
  89. package/dist/ui/components/form/input-file/render-files/file-item/button-upload-image-mobile/index.d.ts +1 -1
  90. package/dist/ui/components/form/input-file/render-files/file-item/button-upload-image-mobile/index.js +1 -1
  91. package/dist/ui/components/form/input-file/render-files/file-item/index.d.ts +3 -0
  92. package/dist/ui/components/form/input-file/render-files/file-item/index.js +49 -0
  93. package/dist/ui/components/form/input-mask/lib/core/errors/SyntheticChangeError.d.ts +1 -1
  94. package/dist/ui/components/form/input-mask/lib/core/hooks/useInput.d.ts +1 -1
  95. package/dist/ui/components/form/input-mask/lib/core/hooks/useInput.js +2 -2
  96. package/dist/ui/components/form/input-mask/lib/core/index.d.ts +5 -0
  97. package/dist/ui/components/form/input-mask/lib/core/index.js +15 -0
  98. package/dist/ui/components/form/input-mask/lib/core/utils/setInputAttributes.d.ts +1 -1
  99. package/dist/ui/components/form/input-mask/lib/mask/InputMask.d.ts +6 -0
  100. package/dist/ui/components/form/input-mask/lib/mask/InputMask.js +44 -0
  101. package/dist/ui/components/form/input-mask/lib/mask/index.d.ts +5 -0
  102. package/dist/ui/components/form/input-mask/lib/mask/index.js +26 -0
  103. package/dist/ui/components/form/input-mask/lib/mask/types.d.ts +61 -0
  104. package/dist/ui/components/form/input-mask/lib/mask/useMask.d.ts +3 -0
  105. package/dist/ui/components/form/input-mask/lib/mask/useMask.js +150 -0
  106. package/dist/ui/components/form/input-mask/lib/mask/utils/filter.d.ts +1 -1
  107. package/dist/ui/components/form/input-mask/lib/mask/utils/format.d.ts +1 -1
  108. package/dist/ui/components/form/input-mask/lib/mask/utils/formatToParts.d.ts +1 -1
  109. package/dist/ui/components/form/input-mask/lib/mask/utils/formatToReplacementObject.d.ts +1 -1
  110. package/dist/ui/components/form/input-mask/lib/mask/utils/resolveDetail.d.ts +1 -1
  111. package/dist/ui/components/form/input-mask/lib/mask/utils/resolveDetail.js +3 -3
  112. package/dist/ui/components/form/input-mask/lib/mask/utils/resolveSelection.d.ts +2 -2
  113. package/dist/ui/components/form/input-mask/lib/mask/utils/unformat.d.ts +1 -1
  114. package/dist/ui/components/form/input-mask/lib/mask/utils/validate.d.ts +1 -1
  115. package/dist/ui/components/form/input-mask/lib/mask/utils.d.ts +63 -0
  116. package/dist/ui/components/form/input-mask/lib/mask/utils.js +114 -0
  117. package/dist/ui/components/form/input-mask/lib/number-format/InputNumberFormat.d.ts +6 -0
  118. package/dist/ui/components/form/input-mask/lib/number-format/InputNumberFormat.js +58 -0
  119. package/dist/ui/components/form/input-mask/lib/number-format/index.d.ts +4 -0
  120. package/dist/ui/components/form/input-mask/lib/number-format/index.js +11 -0
  121. package/dist/ui/components/form/input-mask/lib/number-format/types.d.ts +26 -0
  122. package/dist/ui/components/form/input-mask/lib/number-format/useNumberFormat.d.ts +3 -0
  123. package/dist/ui/components/form/input-mask/lib/number-format/useNumberFormat.js +208 -0
  124. package/dist/ui/components/form/input-mask/lib/number-format/utils/localizeValues.d.ts +1 -1
  125. package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveDetail.d.ts +2 -2
  126. package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveDetail.js +1 -1
  127. package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveMinimumFractionDigits.d.ts +1 -1
  128. package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveOptions.d.ts +1 -1
  129. package/dist/ui/components/form/input-mask/lib/number-format/utils/resolveSelection.d.ts +2 -2
  130. package/dist/ui/components/form/input-seo/input-meta-image/index.d.ts +1 -1
  131. package/dist/ui/components/form/input-seo/input-meta-image/index.js +1 -1
  132. package/dist/ui/components/menu-mobile/components/nav-links/index.js +1 -1
  133. package/package.json +2 -2
  134. package/dist/fonts/arima-bold.ttf +0 -0
  135. package/dist/fonts/baijamjuree-bold.ttf +0 -0
  136. package/dist/fonts/baijamjuree-regular.ttf +0 -0
  137. package/dist/fonts/barlow-bold.ttf +0 -0
  138. package/dist/fonts/barlow-medium.ttf +0 -0
  139. package/dist/fonts/barlow-regular.ttf +0 -0
  140. package/dist/fonts/bigshouldersdisplay-bold.ttf +0 -0
  141. package/dist/fonts/bigshouldersdisplay-medium.ttf +0 -0
  142. package/dist/fonts/bigshouldersdisplay-regular.ttf +0 -0
  143. package/dist/fonts/bigshouldersdisplay-semibold.ttf +0 -0
  144. package/dist/fonts/bricolage-bold.ttf +0 -0
  145. package/dist/fonts/bricolage-medium.ttf +0 -0
  146. package/dist/fonts/bricolage-regular.ttf +0 -0
  147. package/dist/fonts/dmsans-bold.ttf +0 -0
  148. package/dist/fonts/dmsans-medium.ttf +0 -0
  149. package/dist/fonts/dmsans-regular.ttf +0 -0
  150. package/dist/fonts/dmsans-semibold.ttf +0 -0
  151. package/dist/fonts/exo-medium.ttf +0 -0
  152. package/dist/fonts/figtree-bold.ttf +0 -0
  153. package/dist/fonts/figtree-regular.ttf +0 -0
  154. package/dist/fonts/firasans-bold.ttf +0 -0
  155. package/dist/fonts/firasans-medium.ttf +0 -0
  156. package/dist/fonts/firasans-regular.ttf +0 -0
  157. package/dist/fonts/firasans-semibold.ttf +0 -0
  158. package/dist/fonts/heebo-bold.ttf +0 -0
  159. package/dist/fonts/heebo-medium.ttf +0 -0
  160. package/dist/fonts/heebo-regular.ttf +0 -0
  161. package/dist/fonts/heebo-semibold.ttf +0 -0
  162. package/dist/fonts/ibm-bold.ttf +0 -0
  163. package/dist/fonts/ibm-light.ttf +0 -0
  164. package/dist/fonts/ibm-medium.ttf +0 -0
  165. package/dist/fonts/ibm-regular.ttf +0 -0
  166. package/dist/fonts/ibm-semibold.ttf +0 -0
  167. package/dist/fonts/ibm-thin.ttf +0 -0
  168. package/dist/fonts/inter-bold.ttf +0 -0
  169. package/dist/fonts/inter-light.ttf +0 -0
  170. package/dist/fonts/inter-medium.ttf +0 -0
  171. package/dist/fonts/inter-regular.ttf +0 -0
  172. package/dist/fonts/inter-semibold.ttf +0 -0
  173. package/dist/fonts/jakarta-bold.ttf +0 -0
  174. package/dist/fonts/jakarta-light.ttf +0 -0
  175. package/dist/fonts/jakarta-medium.ttf +0 -0
  176. package/dist/fonts/jakarta-regular.ttf +0 -0
  177. package/dist/fonts/kalnia-bold.ttf +0 -0
  178. package/dist/fonts/kalnia-light.ttf +0 -0
  179. package/dist/fonts/kalnia-medium.ttf +0 -0
  180. package/dist/fonts/kalnia-regular.ttf +0 -0
  181. package/dist/fonts/kalnia-semibold.ttf +0 -0
  182. package/dist/fonts/kalnia-thin.ttf +0 -0
  183. package/dist/fonts/khand-bold.ttf +0 -0
  184. package/dist/fonts/khand-medium.ttf +0 -0
  185. package/dist/fonts/khand-regular.ttf +0 -0
  186. package/dist/fonts/khand-semibold.ttf +0 -0
  187. package/dist/fonts/lexend-bold.ttf +0 -0
  188. package/dist/fonts/lexend-light.ttf +0 -0
  189. package/dist/fonts/lexend-medium.ttf +0 -0
  190. package/dist/fonts/lexend-regular.ttf +0 -0
  191. package/dist/fonts/lexend-semibold.ttf +0 -0
  192. package/dist/fonts/manrope-bold.ttf +0 -0
  193. package/dist/fonts/manrope-medium.ttf +0 -0
  194. package/dist/fonts/manrope-regular.ttf +0 -0
  195. package/dist/fonts/manrope-semiBold.ttf +0 -0
  196. package/dist/fonts/montserrat-bold.ttf +0 -0
  197. package/dist/fonts/montserrat-light.ttf +0 -0
  198. package/dist/fonts/montserrat-medium.ttf +0 -0
  199. package/dist/fonts/montserrat-regular.ttf +0 -0
  200. package/dist/fonts/montserrat-semibold.ttf +0 -0
  201. package/dist/fonts/nunito-bold.ttf +0 -0
  202. package/dist/fonts/nunito-medium.ttf +0 -0
  203. package/dist/fonts/nunito-regular.ttf +0 -0
  204. package/dist/fonts/objective-bold.otf +0 -0
  205. package/dist/fonts/objective-medium.otf +0 -0
  206. package/dist/fonts/objective-regular.otf +0 -0
  207. package/dist/fonts/onest-black.ttf +0 -0
  208. package/dist/fonts/onest-bold.ttf +0 -0
  209. package/dist/fonts/onest-extrabold.ttf +0 -0
  210. package/dist/fonts/onest-extralight.ttf +0 -0
  211. package/dist/fonts/onest-light.ttf +0 -0
  212. package/dist/fonts/onest-medium.ttf +0 -0
  213. package/dist/fonts/onest-regular.ttf +0 -0
  214. package/dist/fonts/onest-semibold.ttf +0 -0
  215. package/dist/fonts/onest-thin.ttf +0 -0
  216. package/dist/fonts/opensans-bold.ttf +0 -0
  217. package/dist/fonts/opensans-medium.ttf +0 -0
  218. package/dist/fonts/opensans-regular.ttf +0 -0
  219. package/dist/fonts/oswald-bold.ttf +0 -0
  220. package/dist/fonts/oswald-light.ttf +0 -0
  221. package/dist/fonts/oswald-medium.ttf +0 -0
  222. package/dist/fonts/oswald-regular.ttf +0 -0
  223. package/dist/fonts/oswald-semibold.ttf +0 -0
  224. package/dist/fonts/outfit-bold.ttf +0 -0
  225. package/dist/fonts/outfit-light.ttf +0 -0
  226. package/dist/fonts/outfit-medium.ttf +0 -0
  227. package/dist/fonts/outfit-regular.ttf +0 -0
  228. package/dist/fonts/outfit-semibold.ttf +0 -0
  229. package/dist/fonts/paytone-regular.ttf +0 -0
  230. package/dist/fonts/playfairdisplay-bold.ttf +0 -0
  231. package/dist/fonts/playfairdisplay-medium.ttf +0 -0
  232. package/dist/fonts/playfairdisplay-regular.ttf +0 -0
  233. package/dist/fonts/playfairdisplay-semibold.ttf +0 -0
  234. package/dist/fonts/poppins-bold.ttf +0 -0
  235. package/dist/fonts/poppins-medium.ttf +0 -0
  236. package/dist/fonts/poppins-regular.ttf +0 -0
  237. package/dist/fonts/raleway-bold.ttf +0 -0
  238. package/dist/fonts/raleway-regular.ttf +0 -0
  239. package/dist/fonts/rethinksans-bold.ttf +0 -0
  240. package/dist/fonts/rethinksans-medium.ttf +0 -0
  241. package/dist/fonts/rethinksans-regular.ttf +0 -0
  242. package/dist/fonts/rethinksans-semibold.ttf +0 -0
  243. package/dist/fonts/roboto-bold.ttf +0 -0
  244. package/dist/fonts/roboto-light.ttf +0 -0
  245. package/dist/fonts/roboto-medium.ttf +0 -0
  246. package/dist/fonts/roboto-regular.ttf +0 -0
  247. package/dist/fonts/robotocondensed-black-italic.ttf +0 -0
  248. package/dist/fonts/robotocondensed-black.ttf +0 -0
  249. package/dist/fonts/robotocondensed-bold-italic.ttf +0 -0
  250. package/dist/fonts/robotocondensed-bold.ttf +0 -0
  251. package/dist/fonts/robotocondensed-extrabold-italic.ttf +0 -0
  252. package/dist/fonts/robotocondensed-extrabold.ttf +0 -0
  253. package/dist/fonts/robotocondensed-extralight-italic.ttf +0 -0
  254. package/dist/fonts/robotocondensed-extralight.ttf +0 -0
  255. package/dist/fonts/robotocondensed-light-italic.ttf +0 -0
  256. package/dist/fonts/robotocondensed-light.ttf +0 -0
  257. package/dist/fonts/robotocondensed-medium-italic.ttf +0 -0
  258. package/dist/fonts/robotocondensed-medium.ttf +0 -0
  259. package/dist/fonts/robotocondensed-regular-italic.ttf +0 -0
  260. package/dist/fonts/robotocondensed-regular.ttf +0 -0
  261. package/dist/fonts/robotocondensed-semi-bold-italic.ttf +0 -0
  262. package/dist/fonts/robotocondensed-semi-bold.ttf +0 -0
  263. package/dist/fonts/robotocondensed-thin-italic.ttf +0 -0
  264. package/dist/fonts/robotocondensed-thin.ttf +0 -0
  265. package/dist/fonts/rubik-regular.ttf +0 -0
  266. package/dist/fonts/ruda-bold.ttf +0 -0
  267. package/dist/fonts/ruda-medium.ttf +0 -0
  268. package/dist/fonts/ruda-regular.ttf +0 -0
  269. package/dist/fonts/ruda-semibold.ttf +0 -0
  270. package/dist/fonts/russoone-regular.ttf +0 -0
  271. package/dist/fonts/shentox-regular.otf +0 -0
  272. package/dist/fonts/shentox-semibold.otf +0 -0
  273. package/dist/fonts/sofiasanscondensed-bold.ttf +0 -0
  274. package/dist/fonts/sofiasanscondensed-medium.ttf +0 -0
  275. package/dist/fonts/sofiasanscondensed-regular.ttf +0 -0
  276. package/dist/fonts/sofiasanscondensed-semibold.ttf +0 -0
  277. package/dist/fonts/sora-bold.ttf +0 -0
  278. package/dist/fonts/sora-regular.ttf +0 -0
  279. package/dist/fonts/staatliches-regular.ttf +0 -0
  280. package/dist/fonts/teko-bold.ttf +0 -0
  281. package/dist/fonts/teko-light.ttf +0 -0
  282. package/dist/fonts/teko-medium.ttf +0 -0
  283. package/dist/fonts/teko-regular.ttf +0 -0
  284. package/dist/fonts/teko-semiBold.ttf +0 -0
  285. package/dist/fonts/titilliumweb-bold.ttf +0 -0
  286. package/dist/fonts/titilliumweb-light.ttf +0 -0
  287. package/dist/fonts/titilliumweb-regular.ttf +0 -0
  288. package/dist/fonts/yanone-bold.ttf +0 -0
  289. package/dist/fonts/yanone-light.ttf +0 -0
  290. package/dist/fonts/yanone-medium.ttf +0 -0
  291. package/dist/fonts/yanone-regular.ttf +0 -0
  292. package/dist/fonts/yanone-semibold.ttf +0 -0
@@ -0,0 +1,208 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ var react_1 = require("react");
7
+ var core_1 = require("../core/index.js");
8
+ var localizeValues_1 = __importDefault(require("./utils/localizeValues.js"));
9
+ var resolveDetail_1 = __importDefault(require("./utils/resolveDetail.js"));
10
+ var resolveMinimumFractionDigits_1 = __importDefault(require("./utils/resolveMinimumFractionDigits.js"));
11
+ var resolveOptions_1 = __importDefault(require("./utils/resolveOptions.js"));
12
+ var resolveSelection_1 = __importDefault(require("./utils/resolveSelection.js"));
13
+ function useNumberFormat(_a) {
14
+ var _b = _a === void 0 ? {} : _a, locales = _b.locales, format = _b.format, currency = _b.currency, currencyDisplay = _b.currencyDisplay, unit = _b.unit, unitDisplay = _b.unitDisplay, signDisplay = _b.signDisplay, groupDisplay = _b.groupDisplay, minimumIntegerDigits = _b.minimumIntegerDigits, maximumIntegerDigits = _b.maximumIntegerDigits, minimumFractionDigits = _b.minimumFractionDigits, maximumFractionDigits = _b.maximumFractionDigits,
15
+ // minimumSignificantDigits,
16
+ // maximumSignificantDigits,
17
+ onNumberFormat = _b.onNumberFormat;
18
+ var options = {
19
+ format: format,
20
+ currency: currency,
21
+ currencyDisplay: currencyDisplay,
22
+ unit: unit,
23
+ unitDisplay: unitDisplay,
24
+ signDisplay: signDisplay,
25
+ groupDisplay: groupDisplay,
26
+ minimumIntegerDigits: minimumIntegerDigits,
27
+ maximumIntegerDigits: maximumIntegerDigits,
28
+ minimumFractionDigits: minimumFractionDigits,
29
+ maximumFractionDigits: maximumFractionDigits,
30
+ // minimumSignificantDigits,
31
+ // maximumSignificantDigits,
32
+ };
33
+ var cache = (0, react_1.useRef)(null);
34
+ /**
35
+ *
36
+ * Init
37
+ *
38
+ */
39
+ var init = function (_a) {
40
+ var initialValue = _a.initialValue;
41
+ var _b = (0, resolveOptions_1.default)(locales, options), current = _b.current, resolved = _b.resolved;
42
+ var invalidType = current.maximumIntegerDigits !== undefined && typeof current.maximumIntegerDigits !== 'number';
43
+ var invalidRange = typeof current.maximumIntegerDigits === 'number' && current.maximumIntegerDigits < resolved.minimumIntegerDigits;
44
+ if (invalidType || invalidRange) {
45
+ throw new RangeError('maximumIntegerDigits value is out of range.');
46
+ }
47
+ var cachedProps = { locales: locales, options: options };
48
+ cache.current = { value: initialValue, props: cachedProps, fallbackProps: cachedProps };
49
+ return { value: initialValue };
50
+ };
51
+ /**
52
+ *
53
+ * Tracking
54
+ *
55
+ */
56
+ var tracking = function (_a) {
57
+ var inputType = _a.inputType, previousValue = _a.previousValue, addedValue = _a.addedValue, changeStart = _a.changeStart, changeEnd = _a.changeEnd;
58
+ if (cache.current === null) {
59
+ throw new core_1.SyntheticChangeError('The state has not been initialized.');
60
+ }
61
+ // Предыдущее значение всегда должно соответствовать маскированному значению из кэша. Обратная ситуация может
62
+ // возникнуть при контроле значения, если значение не было изменено после ввода. Для предотвращения подобных
63
+ // ситуаций, нам важно синхронизировать предыдущее значение с кэшированным значением, если они различаются
64
+ if (cache.current.value !== previousValue) {
65
+ cache.current.props = cache.current.fallbackProps;
66
+ }
67
+ else {
68
+ cache.current.fallbackProps = cache.current.props;
69
+ }
70
+ var previousLocalizedValues = (0, localizeValues_1.default)(cache.current.props.locales);
71
+ var localizedValues = (0, localizeValues_1.default)(locales);
72
+ var _b = (0, resolveOptions_1.default)(locales, options), current = _b.current, resolved = _b.resolved;
73
+ // Удаляем неразрешённые символы
74
+ var filter = function (value) {
75
+ var p$1 = "\\-\\".concat(localizedValues.minusSign);
76
+ var p$2 = ".,".concat(localizedValues.decimal);
77
+ var p$3 = "\\d".concat(localizedValues.digits);
78
+ var p$4 = "[^".concat(p$1).concat(p$2).concat(p$3, "]|[").concat(p$2, "](?=.*[").concat(p$2, "])");
79
+ var _value = value.replace(RegExp(p$4, 'g'), '');
80
+ if (localizedValues.signBackwards) {
81
+ return _value.replace(RegExp("[".concat(p$1, "](?=.*[").concat(p$1).concat(p$2).concat(p$3, "])"), 'g'), '');
82
+ }
83
+ var firstMinusSignIndex = _value.search(RegExp("[".concat(p$1, "]")));
84
+ var firstDecimalIndex = _value.search(RegExp("[".concat(p$2, "]")));
85
+ var firstDigitIndex = _value.search(RegExp("[".concat(p$3, "]")));
86
+ return _value.replace(RegExp("[".concat(p$1, "]"), 'g'), function (match, offset) {
87
+ var isMoreMinusSignIndex = firstMinusSignIndex !== -1 && offset > firstMinusSignIndex;
88
+ var isMoreDecimalIndex = firstDecimalIndex !== -1 && offset > firstDecimalIndex;
89
+ var isMoreDigitIndex = firstDigitIndex !== -1 && offset > firstDigitIndex;
90
+ return isMoreMinusSignIndex || isMoreDecimalIndex || isMoreDigitIndex ? '' : match;
91
+ });
92
+ };
93
+ addedValue = filter(addedValue);
94
+ if (inputType === 'insert' && !addedValue) {
95
+ throw new core_1.SyntheticChangeError('The added value does not contain allowed characters.');
96
+ }
97
+ var regExp$1 = RegExp("[^\\".concat(previousLocalizedValues.minusSign).concat(previousLocalizedValues.decimal).concat(previousLocalizedValues.digits, "]"), 'g');
98
+ // Нам важно удалить ненужные символы перед преобразованием в число, так
99
+ // как символ группы и символ десятичного разделителя могут пересекаться
100
+ var beforeChangeValue = previousValue.slice(0, changeStart).replace(regExp$1, '');
101
+ var afterChangeValue = previousValue.slice(changeEnd).replace(regExp$1, '');
102
+ var normalizedValue = beforeChangeValue + addedValue + afterChangeValue;
103
+ // Фильтруем значение для преобразование в число
104
+ normalizedValue = filter(normalizedValue)
105
+ // Нормализуем десятичный разделитель
106
+ .replace(RegExp("[,".concat(localizedValues.decimal, "]"), 'g'), '.')
107
+ // Нормализуем знак минуса
108
+ .replace(RegExp(localizedValues.minusSign, 'g'), '-')
109
+ // Нормализуем цифры
110
+ .replace(RegExp("[".concat(localizedValues.digits, "]"), 'g'), function (localeDigit) {
111
+ var digit = localizedValues.digits.indexOf(localeDigit);
112
+ return digit !== -1 ? digit.toString() : localeDigit;
113
+ });
114
+ // В случае ввода знака минуса нам нужно его удалить если
115
+ // оно присутствует, в противном случае добавить, тем самым
116
+ // создав автоматическую вставку при любой позиции каретки
117
+ {
118
+ var isReflectMinusSign = RegExp("^[\\-\\".concat(localizedValues.minusSign, "]$")).test(addedValue) && changeStart === changeEnd;
119
+ var hasPreviousValueMinusSign = previousValue.includes(previousLocalizedValues.minusSign);
120
+ var hasNormalizedValueMinusSign = normalizedValue.includes('-');
121
+ if (isReflectMinusSign && hasPreviousValueMinusSign && hasNormalizedValueMinusSign) {
122
+ normalizedValue = normalizedValue.replace('-', '');
123
+ }
124
+ if (isReflectMinusSign && !hasPreviousValueMinusSign && !hasNormalizedValueMinusSign) {
125
+ normalizedValue = "-".concat(normalizedValue);
126
+ }
127
+ }
128
+ // Для нормализации значения, ставим минус слева.
129
+ // В случае арабской локали он может находиться справа
130
+ if (normalizedValue.endsWith('-')) {
131
+ normalizedValue = "-".concat(normalizedValue.slice(0, -1));
132
+ }
133
+ // Если изменения происходят в области `minimumFractionDigits`, очищаем дробную часть
134
+ // для замены значения, чтобы заменить "0" на вводимое значение,
135
+ // например, при вводе "1", получим "0.00" -> "0.1" -> "0.10" (не "0.100")
136
+ if (/\..*0$/.test(normalizedValue)) {
137
+ // let previousInteger = '';
138
+ var previousFraction = '';
139
+ var previousFractionIndex = -1;
140
+ for (var i = 0, decimal = false; i < previousValue.length; i++) {
141
+ var isDigit = previousLocalizedValues.digits.includes(previousValue[i]);
142
+ var isDecimal = previousValue[i] === previousLocalizedValues.decimal;
143
+ if (!decimal) {
144
+ if (isDecimal)
145
+ decimal = true;
146
+ // if (isDigit) previousInteger += previousValue[i];
147
+ }
148
+ else if (isDigit) {
149
+ previousFraction += previousValue[i];
150
+ if (previousFractionIndex === -1)
151
+ previousFractionIndex = i;
152
+ }
153
+ }
154
+ if (previousFractionIndex !== -1) {
155
+ var previousMinimumFractionDigits = (0, resolveMinimumFractionDigits_1.default)({
156
+ // integer: previousInteger,
157
+ // fraction: previousFraction,
158
+ resolvedOptions: (0, resolveOptions_1.default)(cache.current.props.locales, cache.current.props.options).resolved,
159
+ });
160
+ // Если изменения происходят в области `minimumFractionDigits`
161
+ var isRange = changeStart >= previousFractionIndex &&
162
+ changeEnd < previousFractionIndex + (previousMinimumFractionDigits || 1);
163
+ if (isRange && previousFraction.length <= (previousMinimumFractionDigits || 1)) {
164
+ normalizedValue = normalizedValue.replace(/0+$/g, '');
165
+ }
166
+ }
167
+ }
168
+ var detail = (0, resolveDetail_1.default)(normalizedValue, {
169
+ inputType: inputType,
170
+ locales: locales,
171
+ localizedValues: localizedValues,
172
+ currentOptions: current,
173
+ resolvedOptions: resolved,
174
+ });
175
+ var selection = (0, resolveSelection_1.default)({
176
+ localizedValues: localizedValues,
177
+ previousLocalizedValues: previousLocalizedValues,
178
+ resolvedOptions: resolved,
179
+ inputType: inputType,
180
+ previousValue: previousValue,
181
+ addedValue: addedValue,
182
+ nextValue: detail.value,
183
+ changeStart: changeStart,
184
+ changeEnd: changeEnd,
185
+ });
186
+ cache.current.value = detail.value;
187
+ cache.current.props = { locales: locales, options: options };
188
+ return {
189
+ value: detail.value,
190
+ selectionStart: selection.start,
191
+ selectionEnd: selection.end,
192
+ __detail: detail,
193
+ };
194
+ };
195
+ /**
196
+ *
197
+ * Use input
198
+ *
199
+ */
200
+ return (0, core_1.useInput)({
201
+ init: init,
202
+ tracking: tracking,
203
+ eventType: 'input-number-format',
204
+ eventHandler: onNumberFormat,
205
+ });
206
+ }
207
+ exports.default = useNumberFormat;
208
+ //# sourceMappingURL=useNumberFormat.js.map
@@ -1,4 +1,4 @@
1
- import type { LocalizedNumberFormatValues } from '../types';
1
+ import type { LocalizedNumberFormatValues } from '../types.js';
2
2
  /**
3
3
  * Возвращает применяемые значения по заданной локали
4
4
  * @param locales
@@ -1,5 +1,5 @@
1
- import type { LocalizedNumberFormatValues, NumberFormatOptions, ResolvedNumberFormatOptions } from '../types';
2
- import type { InputType } from '../../core';
1
+ import type { LocalizedNumberFormatValues, NumberFormatOptions, ResolvedNumberFormatOptions } from '../types.js';
2
+ import type { InputType } from '../../core/index.js';
3
3
  interface Options {
4
4
  inputType: InputType;
5
5
  locales: string | string[] | undefined;
@@ -25,7 +25,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
25
25
  return (mod && mod.__esModule) ? mod : { "default": mod };
26
26
  };
27
27
  Object.defineProperty(exports, "__esModule", { value: true });
28
- var resolveMinimumFractionDigits_1 = __importDefault(require("./resolveMinimumFractionDigits"));
28
+ var resolveMinimumFractionDigits_1 = __importDefault(require("./resolveMinimumFractionDigits.js"));
29
29
  /**
30
30
  *
31
31
  * @param value
@@ -1,4 +1,4 @@
1
- import type { ResolvedNumberFormatOptions } from '../types';
1
+ import type { ResolvedNumberFormatOptions } from '../types.js';
2
2
  interface ResolveMinimumFractionDigitsParam {
3
3
  resolvedOptions: ResolvedNumberFormatOptions;
4
4
  }
@@ -1,4 +1,4 @@
1
- import type { NumberFormatOptions, ResolvedNumberFormatOptions } from '../types';
1
+ import type { NumberFormatOptions, ResolvedNumberFormatOptions } from '../types.js';
2
2
  export default function resolveOptions(locales: string | string[] | undefined, options?: NumberFormatOptions | undefined): {
3
3
  current: NumberFormatOptions;
4
4
  resolved: ResolvedNumberFormatOptions;
@@ -1,5 +1,5 @@
1
- import type { LocalizedNumberFormatValues, ResolvedNumberFormatOptions } from '../types';
2
- import type { InputType } from '../../core';
1
+ import type { LocalizedNumberFormatValues, ResolvedNumberFormatOptions } from '../types.js';
2
+ import type { InputType } from '../../core/index.js';
3
3
  interface ResolveSelectionParam {
4
4
  localizedValues: LocalizedNumberFormatValues;
5
5
  previousLocalizedValues: LocalizedNumberFormatValues;
@@ -1,2 +1,2 @@
1
1
  import { InputProps } from '../../../../../ui/index.js';
2
- export declare function InputMetaImage(props: InputProps): import("react/jsx-runtime").
2
+ export declare function InputMetaImage(props: InputProps): import("react/jsx-runtime").JSX.Element;
@@ -48,4 +48,4 @@ function ResultFile(_a) {
48
48
  var _b = (0, ui_1.useRenderedFile)(__assign(__assign({}, inputProps), { file: file })), Image = _b.Image, fileName = _b.fileName, DeleteFileButton = _b.DeleteFileButton;
49
49
  return ((0, jsx_runtime_1.jsxs)("div", { className: 'result_meta_image', children: [(0, jsx_runtime_1.jsx)(Image, {}), (0, jsx_runtime_1.jsx)("p", { children: fileName }), (0, jsx_runtime_1.jsx)(DeleteFileButton, {})] }));
50
50
  }
51
- //# sourceMappingURL
51
+ //# sourceMappingURL=index.js.map
@@ -64,4 +64,4 @@ var NavLinks = function (_a) {
64
64
  submenu.links.map(function (sublink) { return ((0, jsx_runtime_1.jsx)("li", { children: sublink.url ? ((0, jsx_runtime_1.jsx)("a", { href: sublink.url, children: sublink.titulo })) : ((0, jsx_runtime_1.jsxs)("span", { onClick: function () { return handleSublinkClick(sublink); }, children: [sublink.titulo, (0, jsx_runtime_1.jsx)(icons_1.Icon, { name: 'IconBasicLeftArrow', stroke: 'black' })] })) }, "submenu-link-".concat(sublink.id))); }) })] })] }) }));
65
65
  };
66
66
  exports.default = NavLinks;
67
- //# sou
67
+ //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "infinity-forge",
3
- "version": "3.4.7",
3
+ "version": "3.4.9",
4
4
  "description": "codie Library",
5
5
  "main": "./dist/index",
6
6
  "module": "./dist/index",
@@ -14,7 +14,7 @@
14
14
  "deploy": "npm version patch && npm publish",
15
15
  "next": "next build",
16
16
  "start": "next start -p 3015",
17
- "build": "concurrently --kill-others-on-fail \"tsc -w\" \"tsc-alias -w --resolve-full-paths\" \"npm run build:CSS\" \"npm run fonts\"",
17
+ "build": "tsc && tsc-alias --resolve-full-paths && npm run build:CSS && npm run fonts",
18
18
  "build:CSS": "npm run minify-css && node combine-css.ts && cpx \"src/**/*.css\" dist --watch",
19
19
  "minify-css": "postcss src/**/*.css --use cssnano -d dist --no-map",
20
20
  "fonts": "tsc-alias -p tsconfig.json && mkdir dist\\fonts && for /r src %i in (*.otf, *.ttf) do copy \"%i\" dist\\fonts\\"
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file