@m4l/components 0.1.42 → 0.1.45

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 (251) hide show
  1. package/@types/types.d.ts +117 -0
  2. package/components/CmpDisenoTest/index.d.ts +4 -0
  3. package/components/CmpDisenoTest/types.d.ts +20 -0
  4. package/components/CommonActions/components/ActionCancel/{index.9230c57b.js → index.a81752ef.js} +1 -1
  5. package/components/CommonActions/components/ActionFormCancel/{index.ab514bd9.js → index.7870abce.js} +25 -9
  6. package/components/CommonActions/components/ActionIntro/{index.a0a341c7.js → index.d567aebb.js} +1 -1
  7. package/components/CommonActions/components/Actions/{index.d3e1f36e.js → index.a5f70d5d.js} +19 -8
  8. package/components/DataGrid/formatters/columnConcatenatedValueFormatter/index.d.ts +3 -0
  9. package/components/DataGrid/formatters/columnConcatenatedValueFormatter/types.d.ts +6 -0
  10. package/components/DataGrid/formatters/index.d.ts +1 -0
  11. package/components/DataGrid/{index.67260455.js → index.8333ea44.js} +42 -15
  12. package/components/DynamicFilter/contexts/BaseContext/types.d.ts +3 -0
  13. package/components/DynamicFilter/{index.071aa795.js → index.93dfa3e0.js} +208 -110
  14. package/components/DynamicFilter/index.d.ts +4 -1
  15. package/components/DynamicFilter/styles.d.ts +4 -6
  16. package/components/DynamicFilter/subcomponents/PopupEditFilter/styles.d.ts +7 -0
  17. package/components/DynamicFilter/types.d.ts +4 -0
  18. package/components/DynamicFilter/utils/Clases/index.d.ts +20 -0
  19. package/components/DynamicFilter/utils/Clases/types.d.ts +17 -0
  20. package/components/ErrorLabel/index.73f9362c.js +65 -0
  21. package/components/ErrorLabel/index.d.ts +8 -1
  22. package/components/ErrorLabel/styles.d.ts +1 -1
  23. package/components/ErrorLabel/types.d.ts +2 -1
  24. package/components/ErrorLabel/utils/Clases/index.d.ts +6 -0
  25. package/components/ErrorLabel/utils/Clases/types.d.ts +3 -0
  26. package/components/Icon/Icon.d.ts +8 -0
  27. package/components/Icon/classes/constants.d.ts +1 -0
  28. package/components/Icon/classes/index.d.ts +9 -0
  29. package/components/Icon/classes/types.d.ts +17 -0
  30. package/components/Icon/index.d.ts +2 -3
  31. package/components/Icon/{index.8d754623.js → index.f6e8d810.js} +58 -11
  32. package/components/Icon/styles.d.ts +1 -1
  33. package/components/Icon/types.d.ts +5 -0
  34. package/components/Image/Image.d.ts +9 -0
  35. package/components/Image/{index.93d5f37f.js → index.aa24e982.js} +107 -43
  36. package/components/Image/index.d.ts +2 -4
  37. package/components/Image/styles.d.ts +2 -2
  38. package/components/Image/subcomponents/LazyLoadComponent/index.d.ts +5 -0
  39. package/components/Image/subcomponents/LazyLoadComponent/styles.d.ts +2 -0
  40. package/components/Image/types.d.ts +17 -1
  41. package/components/Image/utils/classes/constant.d.ts +1 -0
  42. package/components/Image/utils/classes/index.d.ts +12 -0
  43. package/components/Image/utils/classes/types.d.ts +9 -0
  44. package/components/LanguagePopover/LanguagePopover.d.ts +8 -0
  45. package/components/LanguagePopover/classes/constants.d.ts +1 -0
  46. package/components/LanguagePopover/classes/index.d.ts +9 -0
  47. package/components/LanguagePopover/classes/types.d.ts +7 -0
  48. package/components/LanguagePopover/{index.cbc4b282.js → index.26b694ef.js} +57 -16
  49. package/components/LanguagePopover/index.d.ts +2 -2
  50. package/components/LanguagePopover/styles.d.ts +1 -0
  51. package/components/LanguagePopover/types.d.ts +9 -0
  52. package/components/ModalDialog/{index.a684827f.js → index.c72a6e31.js} +5 -5
  53. package/components/NoItemSelected/{index.46d2f632.js → index.9636ec8a.js} +1 -1
  54. package/components/NoItemSelected/styles.d.ts +1 -1
  55. package/components/ObjectLogs/{index.4a859658.js → index.239e5877.js} +22 -11
  56. package/components/PaperForm/{index.c5948756.js → index.0114aa9b.js} +1 -1
  57. package/components/Period/{index.abe445bd.js → index.10dc7de1.js} +20 -9
  58. package/components/Resizeable/{index.c96c0f09.js → index.8a442a8b.js} +1 -1
  59. package/components/areas/components/Area/types.d.ts +24 -12
  60. package/components/areas/components/AreasAdmin/{index.6794b22f.js → index.01739b1f.js} +24 -15
  61. package/components/areas/components/AreasContainer/{index.a2f8899b.js → index.41fb511e.js} +9 -10
  62. package/components/areas/components/GridLayout/{index.b9c1e846.js → index.d11ecdd8.js} +28 -18
  63. package/components/areas/components/Window/{index.252fbf4e.js → index.61f87e9d.js} +105 -85
  64. package/components/areas/components/Window/styles.d.ts +5 -2
  65. package/components/areas/components/Window/subcomponents/InnerForHooks/index.d.ts +4 -0
  66. package/components/areas/components/Window/subcomponents/InnerForHooks/styles.d.ts +2 -0
  67. package/components/areas/components/Window/subcomponents/{Component → InnerForHooks/subcomponents/Component}/index.d.ts +4 -3
  68. package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/index.d.ts +1 -1
  69. package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/index.d.ts +1 -1
  70. package/components/areas/components/Window/subcomponents/InnerForHooks/subcomponents/MicroFrontend/types.d.ts +8 -0
  71. package/components/areas/components/WindowPopUp/index.d.ts +2 -1
  72. package/components/areas/components/WindowPopUp/index.f5fa6cce.js +117 -0
  73. package/components/areas/components/index.d.ts +2 -1
  74. package/components/areas/components/{index.7d6cd649.js → index.e9971ebf.js} +18 -13
  75. package/components/areas/contexts/AreaContext/helper.d.ts +12 -0
  76. package/components/areas/contexts/AreaContext/index.cb686ae0.js +392 -0
  77. package/components/areas/contexts/AreaContext/index.d.ts +2 -2
  78. package/components/areas/contexts/AreaContext/store.d.ts +49 -0
  79. package/components/areas/contexts/AreaContext/types.d.ts +8 -16
  80. package/components/areas/contexts/AreasContext/index.1b624579.js +204 -0
  81. package/components/areas/contexts/AreasContext/index.d.ts +10 -2
  82. package/components/areas/contexts/AreasContext/store.d.ts +38 -0
  83. package/components/areas/contexts/AreasContext/types.d.ts +1 -13
  84. package/components/areas/contexts/DynamicMFParmsContext/index.c19cb8cc.js +43 -0
  85. package/components/areas/contexts/DynamicMFParmsContext/index.d.ts +13 -4
  86. package/components/areas/contexts/DynamicMFParmsContext/store.d.ts +20 -0
  87. package/components/areas/contexts/DynamicMFParmsContext/types.d.ts +4 -16
  88. package/components/areas/contexts/WindowContext/helper.d.ts +1 -0
  89. package/components/areas/contexts/WindowContext/index.d.ts +13 -0
  90. package/components/areas/contexts/WindowContext/store.d.ts +31 -0
  91. package/components/areas/contexts/WindowContext/types.d.ts +5 -0
  92. package/components/areas/contexts/WindowToolsMFContext/index.d.ts +6 -0
  93. package/components/areas/contexts/WindowToolsMFContext/types.d.ts +21 -0
  94. package/components/areas/contexts/index.9c342ce6.js +203 -0
  95. package/components/areas/contexts/index.d.ts +4 -1
  96. package/components/areas/hooks/index.4e59c40f.js +27 -0
  97. package/components/areas/hooks/index.d.ts +2 -0
  98. package/components/areas/hooks/useArea/index.d.ts +2 -0
  99. package/components/areas/hooks/useArea/index.df7c7169.js +20 -0
  100. package/components/areas/hooks/useAreas/index.d.ts +11 -1
  101. package/components/areas/hooks/useDynamicMFParameters/index.041a666b.js +14 -0
  102. package/components/areas/hooks/useDynamicMFParameters/index.d.ts +11 -1
  103. package/components/areas/hooks/useWindow/index.d.ts +11 -0
  104. package/components/areas/hooks/useWindowToolsMF/index.d.ts +1 -0
  105. package/components/areas/index.7b430c19.js +21 -0
  106. package/components/areas/index.d.ts +1 -0
  107. package/components/formatters/BooleanFormatter/{index.3a9b16c8.js → index.b3fb8a75.js} +1 -1
  108. package/components/formatters/ConcatenatedFormatter/index.d.ts +8 -0
  109. package/components/formatters/ConcatenatedFormatter/types.d.ts +11 -0
  110. package/components/formatters/PeriodFormatter/index.d.ts +8 -0
  111. package/components/formatters/PeriodFormatter/types.d.ts +13 -0
  112. package/components/formatters/dictionary.d.ts +9 -0
  113. package/components/formatters/index.0368bab3.js +127 -0
  114. package/components/formatters/index.d.ts +2 -0
  115. package/components/hook-form/RHFAutocomplete/{index.de93fe01.js → index.74add0d0.js} +1 -1
  116. package/components/hook-form/RHFAutocompleteAsync/{index.ca696cce.js → index.0aa3c224.js} +1 -1
  117. package/components/hook-form/RHFCheckbox/RHFCheckbox.d.ts +8 -0
  118. package/components/hook-form/RHFCheckbox/classes/index.d.ts +7 -0
  119. package/components/hook-form/RHFCheckbox/classes/types.d.ts +5 -0
  120. package/components/hook-form/RHFCheckbox/index.ebfe1e3c.js +110 -0
  121. package/components/hook-form/RHFCheckbox/styles.d.ts +14 -0
  122. package/components/hook-form/RHFCheckbox/subcomponents/Skeleton/index.d.ts +2 -1
  123. package/components/hook-form/RHFCheckbox/subcomponents/Skeleton/types.d.ts +3 -0
  124. package/components/hook-form/RHFPeriod/{index.3772295b.js → index.10c4501a.js} +2 -2
  125. package/components/hook-form/RHFTextField/RHFTextField.d.ts +8 -0
  126. package/components/hook-form/RHFTextField/classes/constants.d.ts +1 -0
  127. package/components/hook-form/RHFTextField/classes/index.d.ts +7 -0
  128. package/components/hook-form/RHFTextField/classes/types.d.ts +10 -0
  129. package/components/hook-form/RHFTextField/index.57f138f7.js +219 -0
  130. package/components/hook-form/RHFTextField/index.d.ts +2 -3
  131. package/components/hook-form/RHFTextField/styles.d.ts +3 -0
  132. package/components/hook-form/RHFTextField/subcomponents/Skeleton/types.d.ts +6 -1
  133. package/components/hook-form/RHFTextField/types.d.ts +0 -1
  134. package/components/hook-form/RHFTextFieldPassword/RHFTextFieldPassword.d.ts +9 -0
  135. package/components/hook-form/RHFTextFieldPassword/classes/index.d.ts +6 -0
  136. package/components/hook-form/RHFTextFieldPassword/classes/types.d.ts +4 -0
  137. package/components/hook-form/RHFTextFieldPassword/index.d.ts +2 -3
  138. package/components/hook-form/RHFTextFieldPassword/styles.d.ts +2 -0
  139. package/components/hook-form/RHFUpload/{index.d5cc7c13.js → index.7fdff30f.js} +1 -1
  140. package/components/hook-form/index.d.ts +3 -3
  141. package/components/index.d.ts +3 -2
  142. package/components/modal/{WindowBase.04439b8e.js → WindowBase.bed2458c.js} +3 -4
  143. package/components/modal/{WindowConfirm.0b8a6818.js → WindowConfirm.bde6242f.js} +22 -11
  144. package/components/modal/index.cb75ce72.js +29 -0
  145. package/components/mui_extended/Accordion/{index.a541c71c.js → index.1d513477.js} +2 -2
  146. package/components/mui_extended/Button/Button.d.ts +8 -0
  147. package/components/mui_extended/Button/classes/constants.d.ts +1 -0
  148. package/components/mui_extended/Button/classes/index.d.ts +7 -0
  149. package/components/mui_extended/Button/classes/types.d.ts +5 -0
  150. package/components/mui_extended/Button/index.8406ed5b.js +150 -0
  151. package/components/mui_extended/Button/index.d.ts +2 -3
  152. package/components/mui_extended/Button/styles.d.ts +13 -0
  153. package/components/mui_extended/IconButton/IconButton.d.ts +9 -0
  154. package/components/mui_extended/IconButton/classes/constants.d.ts +1 -0
  155. package/components/mui_extended/IconButton/classes/index.d.ts +7 -0
  156. package/components/mui_extended/IconButton/classes/types.d.ts +5 -0
  157. package/components/mui_extended/IconButton/index.1318a283.js +100 -0
  158. package/components/mui_extended/IconButton/index.d.ts +2 -4
  159. package/components/mui_extended/IconButton/styles.d.ts +2 -0
  160. package/components/mui_extended/IconButton/subcomponents/SkeletonIconButton/index.d.ts +2 -1
  161. package/components/mui_extended/IconButton/subcomponents/SkeletonIconButton/types.d.ts +3 -0
  162. package/components/mui_extended/ImageButton/ImageButton.d.ts +6 -0
  163. package/components/mui_extended/ImageButton/styles.d.ts +2 -0
  164. package/components/mui_extended/ImageButton/types.d.ts +0 -2
  165. package/components/mui_extended/ImageButton/utils/Clases/constants.d.ts +1 -0
  166. package/components/mui_extended/ImageButton/utils/Clases/index.d.ts +6 -0
  167. package/components/mui_extended/ImageButton/utils/Clases/types.d.ts +3 -0
  168. package/components/mui_extended/MenuActions/{index.ee17bddd.js → index.1261168c.js} +2 -2
  169. package/components/mui_extended/Pager/{index.74d3f5fc.js → index.80ccec47.js} +1 -1
  170. package/components/mui_extended/Popover/Popover.d.ts +9 -0
  171. package/components/mui_extended/Popover/classes/index.d.ts +8 -0
  172. package/components/mui_extended/Popover/classes/types.d.ts +17 -0
  173. package/components/mui_extended/Popover/{index.53c77d23.js → index.58c49cc0.js} +55 -13
  174. package/components/mui_extended/Popover/styles.d.ts +1 -0
  175. package/components/mui_extended/Popover/subcomponts/ArrowIcon/index.d.ts +3 -0
  176. package/components/mui_extended/Popover/types.d.ts +1 -1
  177. package/components/mui_extended/Typography/index.be3a279a.js +63 -0
  178. package/components/mui_extended/Typography/index.d.ts +3 -0
  179. package/components/mui_extended/Typography/styles.d.ts +2 -0
  180. package/components/mui_extended/Typography/utils/Clases/index.d.ts +6 -0
  181. package/components/mui_extended/Typography/utils/Clases/types.d.ts +3 -0
  182. package/components/mui_extended/index.3106c913.js +19 -0
  183. package/components/mui_extended/index.d.ts +5 -4
  184. package/contexts/ModalContext/{index.b90eec94.js → index.c8212291.js} +1 -1
  185. package/contexts/RHFormContext/{index.d88e6e27.js → index.828b60ad.js} +1 -1
  186. package/contexts/index.d.ts +1 -1
  187. package/hooks/index.d.ts +0 -1
  188. package/hooks/useFormAddEdit/{index.d4845f1a.js → index.15de3ba8.js} +5 -0
  189. package/hooks/useModal/{index.d14edee3.js → index.19172e70.js} +1 -1
  190. package/index.js +165 -109
  191. package/package.json +13 -8
  192. package/{react-draggable.84d6b038.js → react-draggable.0eef011c.js} +1 -1
  193. package/{react-resizable.1d00271d.js → react-resizable.bb58c8fc.js} +103 -67
  194. package/utils/{index.899eb67b.js → index.e882b264.js} +26 -18
  195. package/vite-env.d.ts +2 -1
  196. package/components/DynamicFilter/components/PopupEditFilter/styles.d.ts +0 -6
  197. package/components/ErrorLabel/index.c8615f16.js +0 -20
  198. package/components/areas/components/Window/contexts/WindowContext/index.d.ts +0 -5
  199. package/components/areas/components/Window/contexts/WindowContext/types.d.ts +0 -13
  200. package/components/areas/components/Window/hooks/useWindow/index.d.ts +0 -1
  201. package/components/areas/components/WindowPopUp/index.214cf099.js +0 -120
  202. package/components/areas/components/WindowPopUp/styles.d.ts +0 -2
  203. package/components/areas/contexts/AreaContext/index.4894cf23.js +0 -286
  204. package/components/areas/contexts/AreasContext/index.cd8e4bee.js +0 -158
  205. package/components/areas/contexts/DynamicMFParmsContext/index.668bc2e2.js +0 -17
  206. package/components/areas/contexts/index.f9196fb2.js +0 -1
  207. package/components/areas/hooks/useArea/index.9b85ce24.js +0 -19
  208. package/components/areas/hooks/useDynamicMFParameters/index.e6a44ae3.js +0 -11
  209. package/components/areas/index.d1bf612c.js +0 -16
  210. package/components/formatters/dicctionary.d.ts +0 -3
  211. package/components/formatters/index.0b5f95d0.js +0 -21
  212. package/components/hook-form/RHFCheckbox/index.6dcec9e2.js +0 -68
  213. package/components/hook-form/RHFCheckbox/index.d.ts +0 -4
  214. package/components/hook-form/RHFTextField/index.b17d68f4.js +0 -146
  215. package/components/modal/index.8387e90e.js +0 -18
  216. package/components/mui_extended/Button/index.86a155a2.js +0 -101
  217. package/components/mui_extended/IconButton/index.82f16572.js +0 -63
  218. package/components/mui_extended/ImageButton/index.d.ts +0 -3
  219. package/components/mui_extended/Popover/index.d.ts +0 -4
  220. package/components/mui_extended/Typography/index.e5494696.js +0 -35
  221. package/components/mui_extended/index.85dfadf1.js +0 -16
  222. /package/components/DynamicFilter/{components → subcomponents}/ApplyedFilters/components/ApplyedFilter/index.d.ts +0 -0
  223. /package/components/DynamicFilter/{components → subcomponents}/ApplyedFilters/components/ApplyedFilter/styles.d.ts +0 -0
  224. /package/components/DynamicFilter/{components → subcomponents}/ApplyedFilters/index.d.ts +0 -0
  225. /package/components/DynamicFilter/{components → subcomponents}/ApplyedFilters/styles.d.ts +0 -0
  226. /package/components/DynamicFilter/{components → subcomponents}/ClearFilters/index.d.ts +0 -0
  227. /package/components/DynamicFilter/{components → subcomponents}/ClearFilters/styles.d.ts +0 -0
  228. /package/components/DynamicFilter/{components → subcomponents}/FilterButton/index.d.ts +0 -0
  229. /package/components/DynamicFilter/{components → subcomponents}/FilterButton/styles.d.ts +0 -0
  230. /package/components/DynamicFilter/{components → subcomponents}/InputFilter/index.d.ts +0 -0
  231. /package/components/DynamicFilter/{components → subcomponents}/InputFilter/styles.d.ts +0 -0
  232. /package/components/DynamicFilter/{components → subcomponents}/PopupEditFilter/index.d.ts +0 -0
  233. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/BooleanFilter/index.d.ts +0 -0
  234. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/BooleanFilter/styles.d.ts +0 -0
  235. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/DateTimeFilter/index.d.ts +0 -0
  236. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/DateTimeFilter/styles.d.ts +0 -0
  237. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/NumberFilter/index.d.ts +0 -0
  238. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/NumberFilter/styles.d.ts +0 -0
  239. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/StringFilter/index.d.ts +0 -0
  240. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/StringFilter/styles.d.ts +0 -0
  241. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/factory.d.ts +0 -0
  242. /package/components/DynamicFilter/{components → subcomponents}/fieldstypes/validations.d.ts +0 -0
  243. /package/components/areas/components/Window/subcomponents/{Header → InnerForHooks/subcomponents/Header}/index.d.ts +0 -0
  244. /package/components/areas/components/Window/subcomponents/{Header → InnerForHooks/subcomponents/Header}/skeleton.d.ts +0 -0
  245. /package/components/areas/components/Window/subcomponents/{Header → InnerForHooks/subcomponents/Header}/styles.d.ts +0 -0
  246. /package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/subcomponents/LoadingMF/index.d.ts +0 -0
  247. /package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/subcomponents/LoadingMF/styles.d.ts +0 -0
  248. /package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/subcomponents/LoadingMF/subcomponents/NotFound/index.d.ts +0 -0
  249. /package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/subcomponents/LoadingMF/subcomponents/NotFound/styles.d.ts +0 -0
  250. /package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/subcomponents/LoadingMF/subcomponents/NotFound/types.d.ts +0 -0
  251. /package/components/areas/components/Window/subcomponents/{MicroFrontend → InnerForHooks/subcomponents/MicroFrontend}/subcomponents/MFLoader/subcomponents/LoadingMF/types.d.ts +0 -0
@@ -1,5 +1,13 @@
1
1
  /// <reference types="react" />
2
- import { AreasContextProps, AreasProviderProps } from './types';
3
- declare const AreasContext: import("react").Context<AreasContextProps | null>;
2
+ import { AreasProviderProps } from './types';
3
+ declare const AreasContext: import("react").Context<(Omit<Omit<import("zustand").StoreApi<import("./store").AreasStateWithActions>, "setState"> & {
4
+ setState<A extends string | {
5
+ type: unknown;
6
+ }>(partial: import("./store").AreasStateWithActions | Partial<import("./store").AreasStateWithActions> | ((state: import("./store").AreasStateWithActions) => import("./store").AreasStateWithActions | Partial<import("./store").AreasStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
7
+ }, "setState"> & {
8
+ setState(nextStateOrUpdater: import("./store").AreasStateWithActions | Partial<import("./store").AreasStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<import("./store").AreasStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
9
+ type: unknown;
10
+ } | undefined): void;
11
+ }) | null>;
4
12
  declare function AreasProvider(props: AreasProviderProps): JSX.Element;
5
13
  export { AreasProvider, AreasContext };
@@ -0,0 +1,38 @@
1
+ import { AreaProviderRef } from '../AreaContext/types';
2
+ import { AreaType } from '../../components/Area/types';
3
+ import { GetLabelType, NetworkProps } from '@m4l/core';
4
+ import { WritableDraft } from 'immer/dist/internal';
5
+ export declare type AreasStatus = 'init' | 'loading' | 'loaded' | 'error';
6
+ export interface AreasState {
7
+ networkOperation: (props: NetworkProps) => Promise<any>;
8
+ getLabel: GetLabelType;
9
+ loadAreasFromNetwork: boolean;
10
+ currentArea: string;
11
+ status: AreasStatus;
12
+ areas: AreaType[];
13
+ }
14
+ export interface AreasStateWithActions extends AreasState {
15
+ actions: {
16
+ addArea: () => string;
17
+ deleteArea: (areaId: string) => void;
18
+ selectArea: (newAreaId: string) => void;
19
+ };
20
+ internalActions: {
21
+ setHandlerGetLabel: (newHandler: GetLabelType) => void;
22
+ loadFromApi: () => void;
23
+ setAreaRef: (areaId: string, ref: AreaProviderRef) => void;
24
+ };
25
+ }
26
+ declare type DefaultStoreProps = Omit<AreasState, 'currentArea'>;
27
+ declare type InitialStoreProps = Pick<AreasState, 'networkOperation' | 'loadAreasFromNetwork' | 'getLabel'> & Partial<DefaultStoreProps>;
28
+ export declare const createAreasStore: (initProps: InitialStoreProps) => Omit<Omit<import("zustand").StoreApi<AreasStateWithActions>, "setState"> & {
29
+ setState<A extends string | {
30
+ type: unknown;
31
+ }>(partial: AreasStateWithActions | Partial<AreasStateWithActions> | ((state: AreasStateWithActions) => AreasStateWithActions | Partial<AreasStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
32
+ }, "setState"> & {
33
+ setState(nextStateOrUpdater: AreasStateWithActions | Partial<AreasStateWithActions> | ((state: WritableDraft<AreasStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
34
+ type: unknown;
35
+ } | undefined): void;
36
+ };
37
+ export declare type AreasStore = ReturnType<typeof createAreasStore>;
38
+ export {};
@@ -1,18 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
- import { AreaType } from '../../components/Area/types';
3
- import { AreaProviderRef } from '../AreaContext/types';
4
- export declare type AreasStatus = 'init' | 'loading' | 'loaded' | 'error';
5
2
  export interface AreasProviderProps {
6
3
  children: ReactNode;
7
- activeAreasNetwork: boolean;
4
+ loadAreasFromNetwork: boolean;
8
5
  onLoad?: () => void;
9
6
  }
10
- export interface AreasContextProps extends Omit<AreasProviderProps, 'children' | 'onLoad'> {
11
- currentArea: string;
12
- status: AreasStatus;
13
- addArea: () => string;
14
- deleteArea: (areaId: string) => void;
15
- selectArea: (newAreaId: string) => void;
16
- areas: AreaType[];
17
- setAreaRef: (areaId: string, ref: AreaProviderRef) => void;
18
- }
@@ -0,0 +1,43 @@
1
+ import { createStore } from "zustand";
2
+ import { devtools } from "zustand/middleware";
3
+ import { immer } from "zustand/middleware/immer";
4
+ import React__default, { createContext } from "react";
5
+ import { jsx } from "react/jsx-runtime";
6
+ const createDynamicMFStore = (initProps) => {
7
+ const startProps = {
8
+ ...initProps
9
+ };
10
+ return createStore(
11
+ devtools(
12
+ immer((set, _get) => ({
13
+ ...startProps,
14
+ actions: {
15
+ changeData: (newDynamicMFState) => {
16
+ set((state) => {
17
+ state.dynamicMFParameters = newDynamicMFState;
18
+ });
19
+ }
20
+ }
21
+ })),
22
+ { name: `dyamic store ${initProps.windowId}` }
23
+ )
24
+ );
25
+ };
26
+ const DynamicMFParmsContext = createContext(null);
27
+ function DynamicMFParmsProvider(props) {
28
+ const {
29
+ children,
30
+ store
31
+ } = props;
32
+ return /* @__PURE__ */ jsx(DynamicMFParmsContext.Provider, {
33
+ value: store,
34
+ children
35
+ });
36
+ }
37
+ const MemonizedDynamicMFParmsProvider = React__default.memo(DynamicMFParmsProvider);
38
+ export {
39
+ DynamicMFParmsProvider as D,
40
+ MemonizedDynamicMFParmsProvider as M,
41
+ DynamicMFParmsContext as a,
42
+ createDynamicMFStore as c
43
+ };
@@ -1,5 +1,14 @@
1
- /// <reference types="react" />
2
- import { DynamicMFParmsContextProps, DynamicMFParmsProviderProps } from './types';
3
- declare const DynamicMFParmsContext: import("react").Context<DynamicMFParmsContextProps | null>;
1
+ import React from 'react';
2
+ import { DynamicMFParmsProviderProps } from './types';
3
+ declare const DynamicMFParmsContext: React.Context<(Omit<Omit<import("zustand").StoreApi<import("./store").DynamicMFStateWithActions>, "setState"> & {
4
+ setState<A extends string | {
5
+ type: unknown;
6
+ }>(partial: import("./store").DynamicMFStateWithActions | Partial<import("./store").DynamicMFStateWithActions> | ((state: import("./store").DynamicMFStateWithActions) => import("./store").DynamicMFStateWithActions | Partial<import("./store").DynamicMFStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
7
+ }, "setState"> & {
8
+ setState(nextStateOrUpdater: import("./store").DynamicMFStateWithActions | Partial<import("./store").DynamicMFStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<import("./store").DynamicMFStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
9
+ type: unknown;
10
+ } | undefined): void;
11
+ }) | null>;
4
12
  declare function DynamicMFParmsProvider(props: DynamicMFParmsProviderProps): JSX.Element;
5
- export { DynamicMFParmsProvider, DynamicMFParmsContext };
13
+ declare const MemonizedDynamicMFParmsProvider: React.MemoExoticComponent<typeof DynamicMFParmsProvider>;
14
+ export { DynamicMFParmsProvider, DynamicMFParmsContext, MemonizedDynamicMFParmsProvider };
@@ -0,0 +1,20 @@
1
+ import { DynamicMFParameters } from '..';
2
+ export interface DynamicMFState {
3
+ dynamicMFParameters: DynamicMFParameters;
4
+ windowId: string;
5
+ }
6
+ export interface DynamicMFStateWithActions extends DynamicMFState {
7
+ actions: {
8
+ changeData: (newDynamicMFState: DynamicMFParameters) => void;
9
+ };
10
+ }
11
+ export declare const createDynamicMFStore: (initProps: DynamicMFState) => Omit<Omit<import("zustand").StoreApi<DynamicMFStateWithActions>, "setState"> & {
12
+ setState<A extends string | {
13
+ type: unknown;
14
+ }>(partial: DynamicMFStateWithActions | Partial<DynamicMFStateWithActions> | ((state: DynamicMFStateWithActions) => DynamicMFStateWithActions | Partial<DynamicMFStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
15
+ }, "setState"> & {
16
+ setState(nextStateOrUpdater: DynamicMFStateWithActions | Partial<DynamicMFStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<DynamicMFStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
17
+ type: unknown;
18
+ } | undefined): void;
19
+ };
20
+ export declare type DynamicMFStore = ReturnType<typeof createDynamicMFStore>;
@@ -1,19 +1,7 @@
1
1
  import { ReactNode } from 'react';
2
- import { MenuAction } from '../../../mui_extended';
3
- export declare type WindowActionType = 'main' | 'allways' | 'normal';
4
- export interface ModuleAction extends MenuAction {
5
- visibility: WindowActionType;
6
- tag?: any;
7
- className?: string;
8
- }
9
- export declare type IsolationDynamicMFParameters = Record<string, any>;
10
- export interface DynamicMFParameters extends IsolationDynamicMFParameters {
11
- setModuleActions: (newActions: ModuleAction[]) => void;
12
- }
13
- export interface DynamicMFParameters extends IsolationDynamicMFParameters {
14
- setModuleActions: (newActions: ModuleAction[]) => void;
15
- }
16
- export interface DynamicMFParmsProviderProps extends DynamicMFParameters {
2
+ import { DynamicMFStore } from './store';
3
+ export declare type DynamicMFParameters = Record<string, any>;
4
+ export interface DynamicMFParmsProviderProps {
5
+ store: DynamicMFStore;
17
6
  children: ReactNode;
18
7
  }
19
- export declare type DynamicMFParmsContextProps = Omit<DynamicMFParmsProviderProps, 'children'>;
@@ -0,0 +1 @@
1
+ export declare function getCookiesContainer(data: any, containerId: string): Record<string, any>;
@@ -0,0 +1,13 @@
1
+ /// <reference types="react" />
2
+ import { WindowProviderProps } from './types';
3
+ declare const WindowContext: import("react").Context<(Omit<Omit<import("zustand").StoreApi<import("./store").WindowStateWithActions>, "setState"> & {
4
+ setState<A extends string | {
5
+ type: unknown;
6
+ }>(partial: import("./store").WindowStateWithActions | Partial<import("./store").WindowStateWithActions> | ((state: import("./store").WindowStateWithActions) => import("./store").WindowStateWithActions | Partial<import("./store").WindowStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
7
+ }, "setState"> & {
8
+ setState(nextStateOrUpdater: import("./store").WindowStateWithActions | Partial<import("./store").WindowStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<import("./store").WindowStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
9
+ type: unknown;
10
+ } | undefined): void;
11
+ }) | null>;
12
+ declare function WindowMFProvider(props: WindowProviderProps): JSX.Element;
13
+ export { WindowMFProvider, WindowContext };
@@ -0,0 +1,31 @@
1
+ import { ModuleAction, WindowToolsMF } from '..';
2
+ import { Cookies, WindowBaseProps } from '../../components/Area/types';
3
+ import { NetworkProps } from '@m4l/core';
4
+ import { DynamicMFStore } from '../DynamicMFParmsContext/store';
5
+ export declare type WindowStatus = 'init' | 'loaded' | 'error';
6
+ export interface WindowState extends WindowBaseProps {
7
+ status: WindowStatus;
8
+ dynamicMFStore: DynamicMFStore;
9
+ moduleActions: ModuleAction[];
10
+ networkOperation: (props: NetworkProps) => Promise<any>;
11
+ cookies: Cookies;
12
+ }
13
+ export interface WindowStateWithActions extends WindowState {
14
+ actions: WindowToolsMF;
15
+ internalActions: {
16
+ loadCookiesFromApi: () => void;
17
+ saveModuleCookies: () => void;
18
+ };
19
+ }
20
+ declare type InitialStoreProps = Omit<WindowState, 'moduleActions' | 'cookies' | 'status'>;
21
+ export declare const createWindowStore: (initProps: InitialStoreProps) => Omit<Omit<import("zustand").StoreApi<WindowStateWithActions>, "setState"> & {
22
+ setState<A extends string | {
23
+ type: unknown;
24
+ }>(partial: WindowStateWithActions | Partial<WindowStateWithActions> | ((state: WindowStateWithActions) => WindowStateWithActions | Partial<WindowStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
25
+ }, "setState"> & {
26
+ setState(nextStateOrUpdater: WindowStateWithActions | Partial<WindowStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<WindowStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
27
+ type: unknown;
28
+ } | undefined): void;
29
+ };
30
+ export declare type WindowStore = ReturnType<typeof createWindowStore>;
31
+ export {};
@@ -0,0 +1,5 @@
1
+ import { ReactNode } from 'react';
2
+ import { WindowBaseProps } from '../../components/Area/types';
3
+ export interface WindowProviderProps extends WindowBaseProps {
4
+ children: ReactNode;
5
+ }
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import { WindowToolsMFContextProps, WindowToolsMFProviderProps } from './types';
3
+ declare const WindowToolsMFContext: React.Context<WindowToolsMFContextProps | null>;
4
+ declare function WindowToolsMFProvider(props: WindowToolsMFProviderProps): JSX.Element;
5
+ declare const MemonizedWindowToolsMFContext: React.MemoExoticComponent<typeof WindowToolsMFProvider>;
6
+ export { WindowToolsMFProvider, WindowToolsMFContext, MemonizedWindowToolsMFContext };
@@ -0,0 +1,21 @@
1
+ import { ReactNode } from 'react';
2
+ import { MenuAction } from '../../../mui_extended';
3
+ import { CookieType } from '../../components/Area/types';
4
+ export declare type WindowActionType = 'main' | 'allways' | 'normal';
5
+ export interface ModuleAction extends MenuAction {
6
+ visibility: WindowActionType;
7
+ tag?: any;
8
+ className?: string;
9
+ }
10
+ export interface WindowToolsMF {
11
+ getCookie: (id: string) => Record<string, any> | undefined;
12
+ getWindowId: () => string;
13
+ getCookies: (type: CookieType) => Record<string, any>;
14
+ setActions: (newActions: ModuleAction[]) => void;
15
+ setCookie: (id: string, type: CookieType, cookie: Record<string, any>) => void;
16
+ close: () => void;
17
+ }
18
+ export interface WindowToolsMFProviderProps extends WindowToolsMF {
19
+ children: ReactNode;
20
+ }
21
+ export declare type WindowToolsMFContextProps = Omit<WindowToolsMFProviderProps, 'children'>;
@@ -0,0 +1,203 @@
1
+ import { useNetwork } from "@m4l/core";
2
+ import React__default, { createContext, useRef, useEffect } from "react";
3
+ import { c as createDynamicMFStore } from "./DynamicMFParmsContext/index.c19cb8cc.js";
4
+ import { createStore } from "zustand";
5
+ import { devtools } from "zustand/middleware";
6
+ import { immer } from "zustand/middleware/immer";
7
+ import cloneDeep from "lodash.clonedeep";
8
+ import { jsx } from "react/jsx-runtime";
9
+ import "./AreasContext/index.1b624579.js";
10
+ function getCookiesContainer(data, containerId) {
11
+ const cookies = {};
12
+ try {
13
+ if (Array.isArray(data)) {
14
+ for (let i = 0; i < data.length; i++) {
15
+ if (data[i]?.container_id === containerId && data[i]?.id) {
16
+ cookies[data[i]?.id] = JSON.parse(data[i].value);
17
+ }
18
+ }
19
+ }
20
+ } catch (error) {
21
+ }
22
+ return cookies;
23
+ }
24
+ const createWindowStore = (initProps) => {
25
+ const startProps = {
26
+ status: "init",
27
+ moduleActions: [],
28
+ cookies: initProps.devCookies || { moduleCookies: {}, windowCookies: {} },
29
+ ...initProps
30
+ };
31
+ delete startProps.devCookies;
32
+ return createStore(
33
+ devtools(
34
+ immer((set, get) => ({
35
+ ...startProps,
36
+ actions: {
37
+ setActions: (newActions) => {
38
+ set((state) => {
39
+ state.moduleActions = cloneDeep(newActions);
40
+ });
41
+ },
42
+ close: () => {
43
+ const onClose = get().onClose;
44
+ if (onClose) {
45
+ onClose(get().windowId);
46
+ }
47
+ },
48
+ getWindowId: () => {
49
+ return get().windowId;
50
+ },
51
+ getCookie: (id) => {
52
+ return get().cookies.windowCookies[id] || get().cookies.moduleCookies[id];
53
+ },
54
+ getCookies: (type) => {
55
+ if (type === "window") {
56
+ return get().cookies.windowCookies;
57
+ } else {
58
+ return get().cookies.moduleCookies;
59
+ }
60
+ },
61
+ setCookie: (id, type, cookie) => {
62
+ get().networkOperation({
63
+ method: "PUT",
64
+ endPoint: `cookies/${type === "module" ? get().moduleId : get().windowId}/${id}`,
65
+ data: {
66
+ value: JSON.stringify(cookie)
67
+ },
68
+ toastSuccess: false,
69
+ toastError: false
70
+ });
71
+ set((state) => {
72
+ if (type === "window") {
73
+ state.cookies.windowCookies[id] = cookie;
74
+ } else {
75
+ state.cookies.moduleCookies[id] = cookie;
76
+ }
77
+ });
78
+ }
79
+ },
80
+ internalActions: {
81
+ loadCookiesFromApi: () => {
82
+ console.log("loadCookiesFromApi start");
83
+ if (get().status === "init") {
84
+ get().networkOperation({
85
+ method: "GET",
86
+ endPoint: `cookies`,
87
+ parms: {
88
+ f: [
89
+ { n: "container_id", o: "e", o1: get().windowId },
90
+ { n: "container_id", o: "e", o1: get().moduleId }
91
+ ]
92
+ },
93
+ toastSuccess: false,
94
+ toastError: false
95
+ }).then((response) => {
96
+ set((state) => {
97
+ state.cookies.moduleCookies = getCookiesContainer(
98
+ response.data,
99
+ state.moduleId
100
+ );
101
+ state.cookies.windowCookies = getCookiesContainer(
102
+ response.data,
103
+ state.windowId
104
+ );
105
+ console.log(
106
+ "loadCookiesFromApi end",
107
+ state.cookies.moduleCookies
108
+ );
109
+ state.status = "loaded";
110
+ });
111
+ }).catch((_response) => {
112
+ set((state) => {
113
+ state.status = "loaded";
114
+ });
115
+ });
116
+ }
117
+ },
118
+ saveModuleCookies: () => {
119
+ console.log("saveModuleCookies end", get().cookies.moduleCookies);
120
+ for (const key in get().cookies.windowCookies) {
121
+ const cookie = get().cookies.windowCookies[key];
122
+ get().networkOperation({
123
+ method: "PUT",
124
+ endPoint: `cookies/${get().moduleId}/${key}`,
125
+ data: {
126
+ value: JSON.stringify(cookie)
127
+ },
128
+ toastSuccess: false,
129
+ toastError: false
130
+ });
131
+ }
132
+ }
133
+ }
134
+ })),
135
+ { name: `window store ${initProps.windowId}` }
136
+ )
137
+ );
138
+ };
139
+ const WindowContext = createContext(null);
140
+ function WindowMFProvider(props) {
141
+ const {
142
+ children,
143
+ ...other
144
+ } = props;
145
+ const {
146
+ networkOperation
147
+ } = useNetwork();
148
+ const windowStoreRef = useRef();
149
+ const dynamicMFStoreRef = useRef();
150
+ if (!dynamicMFStoreRef.current) {
151
+ dynamicMFStoreRef.current = createDynamicMFStore({
152
+ dynamicMFParameters: props.dynamicParams,
153
+ windowId: props.windowId
154
+ });
155
+ }
156
+ if (!windowStoreRef.current) {
157
+ windowStoreRef.current = createWindowStore({
158
+ ...other,
159
+ dynamicMFStore: dynamicMFStoreRef.current,
160
+ networkOperation
161
+ });
162
+ }
163
+ useEffect(() => {
164
+ windowStoreRef.current?.getState().internalActions.loadCookiesFromApi();
165
+ }, []);
166
+ useEffect(() => {
167
+ if (windowStoreRef.current?.getState().status === "loaded") {
168
+ console.log("useEffect Reemplazo de ventan");
169
+ dynamicMFStoreRef.current?.getState().actions.changeData(props.dynamicParams);
170
+ }
171
+ }, [props.dynamicParams]);
172
+ console.log("Render WindowProvider");
173
+ return /* @__PURE__ */ jsx(WindowContext.Provider, {
174
+ value: windowStoreRef.current,
175
+ children
176
+ });
177
+ }
178
+ const WindowToolsMFContext = createContext(null);
179
+ function WindowToolsMFProvider(props) {
180
+ const {
181
+ children,
182
+ setActions,
183
+ ...other
184
+ } = props;
185
+ useEffect(() => {
186
+ console.log("useEffect {DynamicMFParmsProvider}", other);
187
+ }, []);
188
+ console.log("Render WindowToolsMFProvider", other);
189
+ return /* @__PURE__ */ jsx(WindowToolsMFContext.Provider, {
190
+ value: {
191
+ setActions,
192
+ ...other
193
+ },
194
+ children
195
+ });
196
+ }
197
+ React__default.memo(WindowToolsMFProvider);
198
+ export {
199
+ WindowToolsMFProvider as W,
200
+ WindowMFProvider as a,
201
+ WindowContext as b,
202
+ WindowToolsMFContext as c
203
+ };
@@ -1,2 +1,5 @@
1
1
  export * from './AreasContext';
2
- export type { DynamicMFParameters, IsolationDynamicMFParameters, ModuleAction, } from './DynamicMFParmsContext/types';
2
+ export type { DynamicMFParameters } from './DynamicMFParmsContext/types';
3
+ export type { DynamicMFStore } from './DynamicMFParmsContext/store';
4
+ export { WindowToolsMFProvider, WindowToolsMFContext } from './WindowToolsMFContext';
5
+ export type { WindowToolsMF, ModuleAction } from './WindowToolsMFContext/types';
@@ -0,0 +1,27 @@
1
+ import { useContext } from "react";
2
+ import { useStore } from "zustand";
3
+ import { b as WindowContext, c as WindowToolsMFContext } from "../contexts/index.9c342ce6.js";
4
+ import "../contexts/DynamicMFParmsContext/index.c19cb8cc.js";
5
+ const useWindow = () => {
6
+ const context = useContext(WindowContext);
7
+ if (!context)
8
+ throw new Error("useWindow context must be use inside WindowContext");
9
+ return context;
10
+ };
11
+ function useWindowStore(selector, equalityFn) {
12
+ const store = useContext(WindowContext);
13
+ if (!store)
14
+ throw new Error("useWindow context must be use inside WindowContext");
15
+ return useStore(store, selector, equalityFn);
16
+ }
17
+ const useWindowToolsMF = () => {
18
+ const context = useContext(WindowToolsMFContext);
19
+ if (!context)
20
+ throw new Error("useWindowToolsMF context must be use inside WindowToolsMFContext");
21
+ return context;
22
+ };
23
+ export {
24
+ useWindow as a,
25
+ useWindowStore as b,
26
+ useWindowToolsMF as u
27
+ };
@@ -0,0 +1,2 @@
1
+ export { useDynamicMFParametersStore } from './useDynamicMFParameters';
2
+ export { useWindowToolsMF } from './useWindowToolsMF';
@@ -1 +1,3 @@
1
+ import { AreaStateWithActions } from '../../contexts/AreaContext/store';
1
2
  export declare const useArea: () => import("../../contexts/AreaContext/types").AreaContextProps;
3
+ export declare function useAreaStore<T>(selector: (state: AreaStateWithActions) => T, equalityFn?: (left: T, right: T) => boolean): T;
@@ -0,0 +1,20 @@
1
+ import { useContext } from "react";
2
+ import { useStore } from "zustand";
3
+ import { a as AreaContext } from "../../contexts/AreaContext/index.cb686ae0.js";
4
+ import { A as AreasContext } from "../../contexts/AreasContext/index.1b624579.js";
5
+ function useAreaStore(selector, equalityFn) {
6
+ const context = useContext(AreaContext);
7
+ if (!context)
8
+ throw new Error("useAreaStore context must be use inside AreaContext");
9
+ return useStore(context.store, selector, equalityFn);
10
+ }
11
+ function useAreasStore(selector, equalityFn) {
12
+ const context = useContext(AreasContext);
13
+ if (!context)
14
+ throw new Error("useAreasStore context must be use inside AreasContext");
15
+ return useStore(context, selector, equalityFn);
16
+ }
17
+ export {
18
+ useAreaStore as a,
19
+ useAreasStore as u
20
+ };
@@ -1,2 +1,12 @@
1
- export declare function useAreas(): import("../../contexts/AreasContext/types").AreasContextProps;
1
+ import { AreasStateWithActions } from '../../contexts/AreasContext/store';
2
+ export declare function useAreas(): Omit<Omit<import("zustand").StoreApi<AreasStateWithActions>, "setState"> & {
3
+ setState<A extends string | {
4
+ type: unknown;
5
+ }>(partial: AreasStateWithActions | Partial<AreasStateWithActions> | ((state: AreasStateWithActions) => AreasStateWithActions | Partial<AreasStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
6
+ }, "setState"> & {
7
+ setState(nextStateOrUpdater: AreasStateWithActions | Partial<AreasStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<AreasStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
8
+ type: unknown;
9
+ } | undefined): void;
10
+ };
11
+ export declare function useAreasStore<T>(selector: (state: AreasStateWithActions) => T, equalityFn?: (left: T, right: T) => boolean): T;
2
12
  export default useAreas;
@@ -0,0 +1,14 @@
1
+ import { useContext } from "react";
2
+ import { useStore } from "zustand";
3
+ import { a as DynamicMFParmsContext } from "../../contexts/DynamicMFParmsContext/index.c19cb8cc.js";
4
+ function useDynamicMFParametersStore(selector, equalityFn) {
5
+ const store = useContext(DynamicMFParmsContext);
6
+ if (!store)
7
+ throw new Error(
8
+ "useDynamicMFParametersStore context must be use inside DynamicMFParmsContext"
9
+ );
10
+ return useStore(store, selector, equalityFn);
11
+ }
12
+ export {
13
+ useDynamicMFParametersStore as u
14
+ };
@@ -1 +1,11 @@
1
- export declare const useDynamicMFParameters: () => import("../../contexts/DynamicMFParmsContext/types").DynamicMFParmsContextProps;
1
+ import { DynamicMFState } from '../../contexts/DynamicMFParmsContext/store';
2
+ export declare const useDynamicMFParameters: () => Omit<Omit<import("zustand").StoreApi<import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions>, "setState"> & {
3
+ setState<A extends string | {
4
+ type: unknown;
5
+ }>(partial: import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions | Partial<import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions> | ((state: import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions) => import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions | Partial<import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
6
+ }, "setState"> & {
7
+ setState(nextStateOrUpdater: import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions | Partial<import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<import("../../contexts/DynamicMFParmsContext/store").DynamicMFStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
8
+ type: unknown;
9
+ } | undefined): void;
10
+ };
11
+ export declare function useDynamicMFParametersStore<T>(selector: (state: DynamicMFState) => T, equalityFn?: (left: T, right: T) => boolean): T;
@@ -0,0 +1,11 @@
1
+ import { WindowStateWithActions } from '../../contexts/WindowContext/store';
2
+ export declare const useWindow: () => Omit<Omit<import("zustand").StoreApi<WindowStateWithActions>, "setState"> & {
3
+ setState<A extends string | {
4
+ type: unknown;
5
+ }>(partial: WindowStateWithActions | Partial<WindowStateWithActions> | ((state: WindowStateWithActions) => WindowStateWithActions | Partial<WindowStateWithActions>), replace?: boolean | undefined, action?: A | undefined): void;
6
+ }, "setState"> & {
7
+ setState(nextStateOrUpdater: WindowStateWithActions | Partial<WindowStateWithActions> | ((state: import("immer/dist/internal").WritableDraft<WindowStateWithActions>) => void), shouldReplace?: boolean | undefined, action?: string | {
8
+ type: unknown;
9
+ } | undefined): void;
10
+ };
11
+ export declare function useWindowStore<T>(selector: (state: WindowStateWithActions) => T, equalityFn?: (left: T, right: T) => boolean): T;
@@ -0,0 +1 @@
1
+ export declare const useWindowToolsMF: () => import("../../contexts/WindowToolsMFContext/types").WindowToolsMFContextProps;
@@ -0,0 +1,21 @@
1
+ import "./components/index.e9971ebf.js";
2
+ import "./components/AreasAdmin/index.01739b1f.js";
3
+ import "react";
4
+ import "@m4l/core";
5
+ import "@mui/material";
6
+ import "../Icon/index.f6e8d810.js";
7
+ import "@mui/material/styles";
8
+ import "react/jsx-runtime";
9
+ import "../mui_extended/IconButton/index.1318a283.js";
10
+ import "zustand";
11
+ import "./contexts/AreasContext/index.1b624579.js";
12
+ import "zustand/shallow";
13
+ import "./components/AreasContainer/index.41fb511e.js";
14
+ import "react-grid-layout/css/styles.css";
15
+ import "../../react-resizable.bb58c8fc.js";
16
+ import "./contexts/index.9c342ce6.js";
17
+ import "./contexts/DynamicMFParmsContext/index.c19cb8cc.js";
18
+ const LABEL_NEW_AREA = "label_new_area";
19
+ export {
20
+ LABEL_NEW_AREA as L
21
+ };
@@ -1,2 +1,3 @@
1
1
  export * from './components';
2
2
  export * from './contexts';
3
+ export * from './hooks';
@@ -1,6 +1,6 @@
1
1
  import { useMemo } from "react";
2
2
  import { useModuleDictionary, useEnvironment } from "@m4l/core";
3
- import { I as Icon } from "../../Icon/index.8d754623.js";
3
+ import { I as Icon } from "../../Icon/index.f6e8d810.js";
4
4
  import { W as WrapperComponent } from "../../WrapperComponent/index.5e872594.js";
5
5
  import { jsx } from "react/jsx-runtime";
6
6
  function BooleanFormatter(props) {