@redneckz/wildless-cms-uni-blocks 0.9.2 → 0.9.4

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 (604) hide show
  1. package/bin/migration-scripts/0.5.14.js +6 -0
  2. package/bin/migration-scripts/0.8.17.js +6 -0
  3. package/bin/migration-scripts/0.8.24.js +2 -2
  4. package/bin/migration-scripts/0.8.8.js +6 -0
  5. package/bin/migration-scripts/0.9.1.js +70 -0
  6. package/bin/migration-scripts/{0.8.31.js → 0.9.3.js} +14 -12
  7. package/bundle/EventBus/defaultEventBus.d.ts +3 -2
  8. package/bundle/blocks.schema.json +1 -1
  9. package/bundle/bundle.umd.js +237 -185
  10. package/bundle/bundle.umd.min.js +1 -1
  11. package/bundle/components/ApplicationForm/renderBankOffices.d.ts +1 -1
  12. package/bundle/components/Header/HeaderSecondaryMenu.d.ts +1 -3
  13. package/bundle/components/Header/HeaderSecondaryMenuButton.d.ts +1 -2
  14. package/bundle/components/SafeDepositRental/RegionsAndBranches.d.ts +1 -1
  15. package/bundle/components/SafeDepositRental/SafeBoxCases.d.ts +1 -1
  16. package/bundle/components/SafeDepositRental/SafeDepositRentalFields.d.ts +2 -2
  17. package/bundle/components/SafeDepositRental/SafeDepositRentalForm.d.ts +1 -1
  18. package/bundle/components/SafeDepositRental/SafeDepositRentalTotal.d.ts +1 -1
  19. package/bundle/{hooks → components/SafeDepositRental}/useSafeBoxes.d.ts +0 -0
  20. package/bundle/components/SafeDepositRental/utils.d.ts +1 -1
  21. package/bundle/components/Tabs/TabActivationEvent.d.ts +5 -0
  22. package/bundle/components/Tabs/Tabs.d.ts +1 -5
  23. package/bundle/hooks/useLocation.d.ts +1 -1
  24. package/bundle/services/search/useSearch.d.ts +7 -2
  25. package/bundle/ui-kit/Dialog/Dialog.d.ts +1 -0
  26. package/bundle/ui-kit/Dialog/DialogAction.d.ts +12 -0
  27. package/bundle/ui-kit/Dialog/useDialog.d.ts +4 -0
  28. package/bundle/ui-kit/Dialog/useDialogHandlers.d.ts +6 -0
  29. package/bundle/ui-kit/Dialog/useDialogProps.d.ts +5 -0
  30. package/bundle/ui-kit/LocationDialog/LocationDialog.d.ts +3 -0
  31. package/bundle/ui-kit/LocationDialog/LocationDialogProps.d.ts +13 -0
  32. package/bundle/ui-kit/{Location → LocationDialog}/SearchBar.d.ts +0 -0
  33. package/bundle/ui-kit/SearchBar/SearchBarInner.d.ts +0 -2
  34. package/bundle/ui-kit/SearchDialog/SearchDialog.d.ts +6 -0
  35. package/{lib/ui-kit/SearchBar/SearchBarInput.d.ts → bundle/ui-kit/SearchDialog/SearchInput.d.ts} +2 -2
  36. package/bundle/ui-kit/TopItem/TopItem.d.ts +1 -2
  37. package/bundle/utils/noop.d.ts +1 -0
  38. package/bundle/utils/useDebouncedEffect.d.ts +1 -0
  39. package/dist/EventBus/defaultEventBus.d.ts +3 -2
  40. package/dist/EventBus/defaultEventBus.js.map +1 -1
  41. package/dist/components/ApplicationForm/renderBankOffices.d.ts +1 -1
  42. package/dist/components/Blocks.js +0 -2
  43. package/dist/components/Blocks.js.map +1 -1
  44. package/dist/components/Blocks.mobile.js +1 -3
  45. package/dist/components/Blocks.mobile.js.map +1 -1
  46. package/dist/components/ContentPage/ContentPage.js +8 -7
  47. package/dist/components/ContentPage/ContentPage.js.map +1 -1
  48. package/dist/components/Footer/Footer.js +1 -1
  49. package/dist/components/Footer/Footer.js.map +1 -1
  50. package/dist/components/Footer/Footer.mobile.js +1 -1
  51. package/dist/components/Footer/Footer.mobile.js.map +1 -1
  52. package/dist/components/Header/Header.js +5 -1
  53. package/dist/components/Header/Header.js.map +1 -1
  54. package/dist/components/Header/HeaderSecondaryMenu.d.ts +1 -3
  55. package/dist/components/Header/HeaderSecondaryMenu.js +10 -13
  56. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  57. package/dist/components/Header/HeaderSecondaryMenuButton.d.ts +1 -2
  58. package/dist/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  59. package/dist/components/HorizontalLayout/HorizontalLayout.js +1 -1
  60. package/dist/components/HorizontalLayout/HorizontalLayout.js.map +1 -1
  61. package/dist/components/RollupItem/RollupItem.js +1 -1
  62. package/dist/components/RollupItem/RollupItem.js.map +1 -1
  63. package/dist/components/RollupItem/RollupItem.mobile.js +2 -4
  64. package/dist/components/RollupItem/RollupItem.mobile.js.map +1 -1
  65. package/dist/components/SafeDepositRental/RegionsAndBranches.d.ts +1 -1
  66. package/dist/components/SafeDepositRental/SafeBoxCases.d.ts +1 -1
  67. package/dist/components/SafeDepositRental/SafeDepositRental.js +1 -1
  68. package/dist/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
  69. package/dist/components/SafeDepositRental/SafeDepositRentalFields.d.ts +2 -2
  70. package/dist/components/SafeDepositRental/SafeDepositRentalFields.js.map +1 -1
  71. package/dist/components/SafeDepositRental/SafeDepositRentalForm.d.ts +1 -1
  72. package/dist/components/SafeDepositRental/SafeDepositRentalTotal.d.ts +1 -1
  73. package/dist/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
  74. package/dist/{hooks → components/SafeDepositRental}/useSafeBoxes.d.ts +0 -0
  75. package/dist/{hooks → components/SafeDepositRental}/useSafeBoxes.js +1 -1
  76. package/dist/components/SafeDepositRental/useSafeBoxes.js.map +1 -0
  77. package/dist/components/SafeDepositRental/utils.d.ts +1 -1
  78. package/dist/components/Tabs/TabActivationEvent.d.ts +5 -0
  79. package/dist/components/{Accordion/AccordionContent.js → Tabs/TabActivationEvent.js} +1 -1
  80. package/dist/components/Tabs/TabActivationEvent.js.map +1 -0
  81. package/dist/components/Tabs/Tabs.d.ts +1 -5
  82. package/dist/components/Tabs/Tabs.js.map +1 -1
  83. package/dist/components/VerticalLayout/VerticalLayout.js +1 -3
  84. package/dist/components/VerticalLayout/VerticalLayout.js.map +1 -1
  85. package/dist/hooks/useLink.js +3 -0
  86. package/dist/hooks/useLink.js.map +1 -1
  87. package/dist/hooks/useLocation.d.ts +1 -1
  88. package/dist/hooks/useLocation.js +2 -2
  89. package/dist/hooks/useLocation.js.map +1 -1
  90. package/dist/services/search/useSearch.d.ts +7 -2
  91. package/dist/services/search/useSearch.js +15 -18
  92. package/dist/services/search/useSearch.js.map +1 -1
  93. package/dist/ui-kit/Dialog/Dialog.d.ts +1 -0
  94. package/dist/ui-kit/Dialog/Dialog.js +2 -6
  95. package/dist/ui-kit/Dialog/Dialog.js.map +1 -1
  96. package/dist/ui-kit/Dialog/DialogAction.d.ts +12 -0
  97. package/dist/ui-kit/{Location/LocationProps.js → Dialog/DialogAction.js} +1 -1
  98. package/dist/ui-kit/Dialog/DialogAction.js.map +1 -0
  99. package/dist/ui-kit/Dialog/useDialog.d.ts +4 -0
  100. package/dist/ui-kit/Dialog/useDialog.js +9 -0
  101. package/dist/ui-kit/Dialog/useDialog.js.map +1 -0
  102. package/dist/ui-kit/Dialog/useDialogHandlers.d.ts +6 -0
  103. package/dist/ui-kit/Dialog/useDialogHandlers.js +21 -0
  104. package/dist/ui-kit/Dialog/useDialogHandlers.js.map +1 -0
  105. package/dist/ui-kit/Dialog/useDialogProps.d.ts +5 -0
  106. package/dist/ui-kit/Dialog/useDialogProps.js +37 -0
  107. package/dist/ui-kit/Dialog/useDialogProps.js.map +1 -0
  108. package/dist/ui-kit/LocationDialog/LocationDialog.d.ts +3 -0
  109. package/dist/ui-kit/{Location/Location.js → LocationDialog/LocationDialog.js} +15 -9
  110. package/dist/ui-kit/LocationDialog/LocationDialog.js.map +1 -0
  111. package/dist/ui-kit/LocationDialog/LocationDialogProps.d.ts +13 -0
  112. package/dist/ui-kit/LocationDialog/LocationDialogProps.js +2 -0
  113. package/dist/ui-kit/LocationDialog/LocationDialogProps.js.map +1 -0
  114. package/dist/ui-kit/{Location → LocationDialog}/SearchBar.d.ts +0 -0
  115. package/dist/ui-kit/{Location → LocationDialog}/SearchBar.js +0 -0
  116. package/dist/ui-kit/LocationDialog/SearchBar.js.map +1 -0
  117. package/dist/ui-kit/SearchBar/SearchBarInner.d.ts +0 -2
  118. package/dist/ui-kit/SearchBar/SearchBarInner.js +13 -40
  119. package/dist/ui-kit/SearchBar/SearchBarInner.js.map +1 -1
  120. package/dist/ui-kit/SearchDialog/SearchDialog.d.ts +6 -0
  121. package/dist/ui-kit/SearchDialog/SearchDialog.js +40 -0
  122. package/dist/ui-kit/SearchDialog/SearchDialog.js.map +1 -0
  123. package/dist/ui-kit/{SearchBar/SearchBarInput.d.ts → SearchDialog/SearchInput.d.ts} +2 -2
  124. package/{mobile/dist/ui-kit/SearchBar/SearchBarInput.js → dist/ui-kit/SearchDialog/SearchInput.js} +3 -3
  125. package/dist/ui-kit/SearchDialog/SearchInput.js.map +1 -0
  126. package/dist/ui-kit/TopItem/TopItem.d.ts +1 -2
  127. package/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  128. package/dist/utils/noop.d.ts +1 -0
  129. package/dist/utils/noop.js +7 -0
  130. package/dist/utils/noop.js.map +1 -0
  131. package/dist/utils/useDebouncedEffect.d.ts +1 -0
  132. package/dist/utils/useDebouncedEffect.js +11 -0
  133. package/dist/utils/useDebouncedEffect.js.map +1 -0
  134. package/lib/EventBus/defaultEventBus.d.ts +3 -2
  135. package/lib/EventBus/defaultEventBus.js.map +1 -1
  136. package/lib/common.css +1 -1
  137. package/lib/components/ApplicationForm/renderBankOffices.d.ts +1 -1
  138. package/lib/components/Blocks.js +0 -2
  139. package/lib/components/Blocks.js.map +1 -1
  140. package/lib/components/Blocks.mobile.js +1 -3
  141. package/lib/components/Blocks.mobile.js.map +1 -1
  142. package/lib/components/ContentPage/ContentPage.js +8 -7
  143. package/lib/components/ContentPage/ContentPage.js.map +1 -1
  144. package/lib/components/Footer/Footer.js +1 -1
  145. package/lib/components/Footer/Footer.js.map +1 -1
  146. package/lib/components/Footer/Footer.mobile.js +1 -1
  147. package/lib/components/Footer/Footer.mobile.js.map +1 -1
  148. package/lib/components/Header/Header.js +5 -1
  149. package/lib/components/Header/Header.js.map +1 -1
  150. package/lib/components/Header/HeaderSecondaryMenu.d.ts +1 -3
  151. package/lib/components/Header/HeaderSecondaryMenu.js +10 -13
  152. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  153. package/lib/components/Header/HeaderSecondaryMenuButton.d.ts +1 -2
  154. package/lib/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  155. package/lib/components/HorizontalLayout/HorizontalLayout.js +1 -1
  156. package/lib/components/HorizontalLayout/HorizontalLayout.js.map +1 -1
  157. package/lib/components/RollupItem/RollupItem.js +1 -1
  158. package/lib/components/RollupItem/RollupItem.js.map +1 -1
  159. package/lib/components/RollupItem/RollupItem.mobile.js +2 -4
  160. package/lib/components/RollupItem/RollupItem.mobile.js.map +1 -1
  161. package/lib/components/SafeDepositRental/RegionsAndBranches.d.ts +1 -1
  162. package/lib/components/SafeDepositRental/SafeBoxCases.d.ts +1 -1
  163. package/lib/components/SafeDepositRental/SafeDepositRental.js +1 -1
  164. package/lib/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
  165. package/lib/components/SafeDepositRental/SafeDepositRentalFields.d.ts +2 -2
  166. package/lib/components/SafeDepositRental/SafeDepositRentalFields.js.map +1 -1
  167. package/lib/components/SafeDepositRental/SafeDepositRentalForm.d.ts +1 -1
  168. package/lib/components/SafeDepositRental/SafeDepositRentalTotal.d.ts +1 -1
  169. package/lib/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
  170. package/lib/{hooks → components/SafeDepositRental}/useSafeBoxes.d.ts +0 -0
  171. package/lib/{hooks → components/SafeDepositRental}/useSafeBoxes.js +1 -1
  172. package/lib/components/SafeDepositRental/useSafeBoxes.js.map +1 -0
  173. package/lib/components/SafeDepositRental/utils.d.ts +1 -1
  174. package/lib/components/Tabs/TabActivationEvent.d.ts +5 -0
  175. package/lib/components/Tabs/TabActivationEvent.js +2 -0
  176. package/lib/components/Tabs/TabActivationEvent.js.map +1 -0
  177. package/lib/components/Tabs/Tabs.d.ts +1 -5
  178. package/lib/components/Tabs/Tabs.js.map +1 -1
  179. package/lib/components/VerticalLayout/VerticalLayout.js +1 -3
  180. package/lib/components/VerticalLayout/VerticalLayout.js.map +1 -1
  181. package/lib/hooks/useLink.js +3 -0
  182. package/lib/hooks/useLink.js.map +1 -1
  183. package/lib/hooks/useLocation.d.ts +1 -1
  184. package/lib/hooks/useLocation.js +2 -2
  185. package/lib/hooks/useLocation.js.map +1 -1
  186. package/lib/services/search/useSearch.d.ts +7 -2
  187. package/lib/services/search/useSearch.js +16 -19
  188. package/lib/services/search/useSearch.js.map +1 -1
  189. package/lib/ui-kit/Dialog/Dialog.d.ts +1 -0
  190. package/lib/ui-kit/Dialog/Dialog.js +3 -7
  191. package/lib/ui-kit/Dialog/Dialog.js.map +1 -1
  192. package/lib/ui-kit/Dialog/DialogAction.d.ts +12 -0
  193. package/lib/ui-kit/Dialog/DialogAction.js +2 -0
  194. package/lib/ui-kit/Dialog/DialogAction.js.map +1 -0
  195. package/lib/ui-kit/Dialog/useDialog.d.ts +4 -0
  196. package/lib/ui-kit/Dialog/useDialog.js +6 -0
  197. package/lib/ui-kit/Dialog/useDialog.js.map +1 -0
  198. package/lib/ui-kit/Dialog/useDialogHandlers.d.ts +6 -0
  199. package/lib/ui-kit/Dialog/useDialogHandlers.js +18 -0
  200. package/lib/ui-kit/Dialog/useDialogHandlers.js.map +1 -0
  201. package/lib/ui-kit/Dialog/useDialogProps.d.ts +5 -0
  202. package/lib/ui-kit/Dialog/useDialogProps.js +34 -0
  203. package/lib/ui-kit/Dialog/useDialogProps.js.map +1 -0
  204. package/lib/ui-kit/LocationDialog/LocationDialog.d.ts +3 -0
  205. package/lib/ui-kit/{Location/Location.fixture.d.ts → LocationDialog/LocationDialog.fixture.d.ts} +0 -0
  206. package/lib/ui-kit/{Location/Location.js → LocationDialog/LocationDialog.js} +15 -9
  207. package/lib/ui-kit/LocationDialog/LocationDialog.js.map +1 -0
  208. package/lib/ui-kit/LocationDialog/LocationDialogProps.d.ts +13 -0
  209. package/lib/ui-kit/LocationDialog/LocationDialogProps.js +2 -0
  210. package/lib/ui-kit/LocationDialog/LocationDialogProps.js.map +1 -0
  211. package/lib/ui-kit/{Location → LocationDialog}/SearchBar.d.ts +0 -0
  212. package/lib/ui-kit/{Location → LocationDialog}/SearchBar.js +0 -0
  213. package/lib/ui-kit/LocationDialog/SearchBar.js.map +1 -0
  214. package/lib/ui-kit/SearchBar/SearchBarInner.d.ts +0 -2
  215. package/lib/ui-kit/SearchBar/SearchBarInner.js +14 -41
  216. package/lib/ui-kit/SearchBar/SearchBarInner.js.map +1 -1
  217. package/lib/ui-kit/SearchDialog/SearchDialog.d.ts +6 -0
  218. package/lib/ui-kit/SearchDialog/SearchDialog.js +38 -0
  219. package/lib/ui-kit/SearchDialog/SearchDialog.js.map +1 -0
  220. package/{bundle/ui-kit/SearchBar/SearchBarInput.d.ts → lib/ui-kit/SearchDialog/SearchInput.d.ts} +2 -2
  221. package/lib/ui-kit/{SearchBar/SearchBarInput.js → SearchDialog/SearchInput.js} +2 -2
  222. package/lib/ui-kit/SearchDialog/SearchInput.js.map +1 -0
  223. package/lib/ui-kit/TopItem/TopItem.d.ts +1 -2
  224. package/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  225. package/lib/utils/noop.d.ts +1 -0
  226. package/lib/utils/noop.js +4 -0
  227. package/lib/utils/noop.js.map +1 -0
  228. package/lib/utils/useDebouncedEffect.d.ts +1 -0
  229. package/lib/utils/useDebouncedEffect.js +8 -0
  230. package/lib/utils/useDebouncedEffect.js.map +1 -0
  231. package/mobile/bundle/EventBus/defaultEventBus.d.ts +3 -2
  232. package/mobile/bundle/bundle.umd.js +257 -218
  233. package/mobile/bundle/bundle.umd.min.js +1 -1
  234. package/mobile/bundle/components/ApplicationForm/renderBankOffices.d.ts +1 -1
  235. package/mobile/bundle/components/Header/HeaderSecondaryMenu.d.ts +1 -3
  236. package/mobile/bundle/components/Header/HeaderSecondaryMenuButton.d.ts +1 -2
  237. package/mobile/bundle/components/SafeDepositRental/RegionsAndBranches.d.ts +1 -1
  238. package/mobile/bundle/components/SafeDepositRental/SafeBoxCases.d.ts +1 -1
  239. package/mobile/bundle/components/SafeDepositRental/SafeDepositRentalFields.d.ts +2 -2
  240. package/mobile/bundle/components/SafeDepositRental/SafeDepositRentalForm.d.ts +1 -1
  241. package/mobile/bundle/components/SafeDepositRental/SafeDepositRentalTotal.d.ts +1 -1
  242. package/mobile/bundle/{hooks → components/SafeDepositRental}/useSafeBoxes.d.ts +0 -0
  243. package/mobile/bundle/components/SafeDepositRental/utils.d.ts +1 -1
  244. package/mobile/bundle/components/Tabs/TabActivationEvent.d.ts +5 -0
  245. package/mobile/bundle/components/Tabs/Tabs.d.ts +1 -5
  246. package/mobile/bundle/hooks/useLocation.d.ts +1 -1
  247. package/mobile/bundle/services/search/useSearch.d.ts +7 -2
  248. package/mobile/bundle/ui-kit/Dialog/Dialog.d.ts +1 -0
  249. package/mobile/bundle/ui-kit/Dialog/DialogAction.d.ts +12 -0
  250. package/mobile/bundle/ui-kit/Dialog/useDialog.d.ts +4 -0
  251. package/mobile/bundle/ui-kit/Dialog/useDialogHandlers.d.ts +6 -0
  252. package/mobile/bundle/ui-kit/Dialog/useDialogProps.d.ts +5 -0
  253. package/mobile/bundle/ui-kit/LocationDialog/LocationDialog.d.ts +3 -0
  254. package/mobile/bundle/ui-kit/LocationDialog/LocationDialogProps.d.ts +13 -0
  255. package/mobile/bundle/ui-kit/{Location → LocationDialog}/SearchBar.d.ts +0 -0
  256. package/mobile/bundle/ui-kit/SearchBar/SearchBarInner.d.ts +0 -2
  257. package/mobile/bundle/ui-kit/SearchDialog/SearchDialog.d.ts +6 -0
  258. package/mobile/bundle/ui-kit/{SearchBar/SearchBarInput.d.ts → SearchDialog/SearchInput.d.ts} +2 -2
  259. package/mobile/bundle/ui-kit/TopItem/TopItem.d.ts +1 -2
  260. package/mobile/bundle/utils/noop.d.ts +1 -0
  261. package/mobile/bundle/utils/useDebouncedEffect.d.ts +1 -0
  262. package/mobile/dist/EventBus/defaultEventBus.d.ts +3 -2
  263. package/mobile/dist/EventBus/defaultEventBus.js.map +1 -1
  264. package/mobile/dist/components/ApplicationForm/renderBankOffices.d.ts +1 -1
  265. package/mobile/dist/components/Blocks.js +1 -3
  266. package/mobile/dist/components/Blocks.js.map +1 -1
  267. package/mobile/dist/components/ContentPage/ContentPage.js +8 -7
  268. package/mobile/dist/components/ContentPage/ContentPage.js.map +1 -1
  269. package/mobile/dist/components/Footer/Footer.js +1 -1
  270. package/mobile/dist/components/Footer/Footer.js.map +1 -1
  271. package/mobile/dist/components/Header/HeaderSecondaryMenu.d.ts +1 -3
  272. package/mobile/dist/components/Header/HeaderSecondaryMenu.js +10 -13
  273. package/mobile/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  274. package/mobile/dist/components/Header/HeaderSecondaryMenuButton.d.ts +1 -2
  275. package/mobile/dist/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  276. package/mobile/dist/components/HorizontalLayout/HorizontalLayout.js +1 -1
  277. package/mobile/dist/components/HorizontalLayout/HorizontalLayout.js.map +1 -1
  278. package/mobile/dist/components/RollupItem/RollupItem.js +2 -4
  279. package/mobile/dist/components/RollupItem/RollupItem.js.map +1 -1
  280. package/mobile/dist/components/SafeDepositRental/RegionsAndBranches.d.ts +1 -1
  281. package/mobile/dist/components/SafeDepositRental/SafeBoxCases.d.ts +1 -1
  282. package/mobile/dist/components/SafeDepositRental/SafeDepositRental.js +1 -1
  283. package/mobile/dist/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
  284. package/mobile/dist/components/SafeDepositRental/SafeDepositRentalFields.d.ts +2 -2
  285. package/mobile/dist/components/SafeDepositRental/SafeDepositRentalFields.js.map +1 -1
  286. package/mobile/dist/components/SafeDepositRental/SafeDepositRentalForm.d.ts +1 -1
  287. package/mobile/dist/components/SafeDepositRental/SafeDepositRentalTotal.d.ts +1 -1
  288. package/mobile/dist/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
  289. package/mobile/dist/{hooks → components/SafeDepositRental}/useSafeBoxes.d.ts +0 -0
  290. package/mobile/dist/{hooks → components/SafeDepositRental}/useSafeBoxes.js +1 -1
  291. package/mobile/dist/components/SafeDepositRental/useSafeBoxes.js.map +1 -0
  292. package/mobile/dist/components/SafeDepositRental/utils.d.ts +1 -1
  293. package/mobile/dist/components/Tabs/TabActivationEvent.d.ts +5 -0
  294. package/mobile/dist/components/{Accordion/AccordionContent.js → Tabs/TabActivationEvent.js} +1 -1
  295. package/mobile/dist/components/Tabs/TabActivationEvent.js.map +1 -0
  296. package/mobile/dist/components/Tabs/Tabs.d.ts +1 -5
  297. package/mobile/dist/components/Tabs/Tabs.js.map +1 -1
  298. package/mobile/dist/components/VerticalLayout/VerticalLayout.js +1 -3
  299. package/mobile/dist/components/VerticalLayout/VerticalLayout.js.map +1 -1
  300. package/mobile/dist/hooks/useLink.js +3 -0
  301. package/mobile/dist/hooks/useLink.js.map +1 -1
  302. package/mobile/dist/hooks/useLocation.d.ts +1 -1
  303. package/mobile/dist/hooks/useLocation.js +2 -2
  304. package/mobile/dist/hooks/useLocation.js.map +1 -1
  305. package/mobile/dist/services/search/useSearch.d.ts +7 -2
  306. package/mobile/dist/services/search/useSearch.js +15 -18
  307. package/mobile/dist/services/search/useSearch.js.map +1 -1
  308. package/mobile/dist/ui-kit/Dialog/Dialog.d.ts +1 -0
  309. package/mobile/dist/ui-kit/Dialog/Dialog.js +2 -6
  310. package/mobile/dist/ui-kit/Dialog/Dialog.js.map +1 -1
  311. package/mobile/dist/ui-kit/Dialog/DialogAction.d.ts +12 -0
  312. package/mobile/dist/ui-kit/{Location/LocationProps.js → Dialog/DialogAction.js} +1 -1
  313. package/mobile/dist/ui-kit/Dialog/DialogAction.js.map +1 -0
  314. package/mobile/dist/ui-kit/Dialog/useDialog.d.ts +4 -0
  315. package/mobile/dist/ui-kit/Dialog/useDialog.js +9 -0
  316. package/mobile/dist/ui-kit/Dialog/useDialog.js.map +1 -0
  317. package/mobile/dist/ui-kit/Dialog/useDialogHandlers.d.ts +6 -0
  318. package/mobile/dist/ui-kit/Dialog/useDialogHandlers.js +21 -0
  319. package/mobile/dist/ui-kit/Dialog/useDialogHandlers.js.map +1 -0
  320. package/mobile/dist/ui-kit/Dialog/useDialogProps.d.ts +5 -0
  321. package/mobile/dist/ui-kit/Dialog/useDialogProps.js +37 -0
  322. package/mobile/dist/ui-kit/Dialog/useDialogProps.js.map +1 -0
  323. package/mobile/dist/ui-kit/LocationDialog/LocationDialog.d.ts +3 -0
  324. package/mobile/dist/ui-kit/{Location/Location.js → LocationDialog/LocationDialog.js} +15 -9
  325. package/mobile/dist/ui-kit/LocationDialog/LocationDialog.js.map +1 -0
  326. package/mobile/dist/ui-kit/LocationDialog/LocationDialogProps.d.ts +13 -0
  327. package/mobile/dist/ui-kit/LocationDialog/LocationDialogProps.js +2 -0
  328. package/mobile/dist/ui-kit/LocationDialog/LocationDialogProps.js.map +1 -0
  329. package/mobile/dist/ui-kit/{Location → LocationDialog}/SearchBar.d.ts +0 -0
  330. package/mobile/dist/ui-kit/{Location → LocationDialog}/SearchBar.js +0 -0
  331. package/mobile/dist/ui-kit/LocationDialog/SearchBar.js.map +1 -0
  332. package/mobile/dist/ui-kit/SearchBar/SearchBarInner.d.ts +0 -2
  333. package/mobile/dist/ui-kit/SearchBar/SearchBarInner.js +13 -40
  334. package/mobile/dist/ui-kit/SearchBar/SearchBarInner.js.map +1 -1
  335. package/mobile/dist/ui-kit/SearchDialog/SearchDialog.d.ts +6 -0
  336. package/mobile/dist/ui-kit/SearchDialog/SearchDialog.js +40 -0
  337. package/mobile/dist/ui-kit/SearchDialog/SearchDialog.js.map +1 -0
  338. package/mobile/dist/ui-kit/SearchDialog/SearchInput.d.ts +9 -0
  339. package/{dist/ui-kit/SearchBar/SearchBarInput.js → mobile/dist/ui-kit/SearchDialog/SearchInput.js} +3 -3
  340. package/mobile/dist/ui-kit/SearchDialog/SearchInput.js.map +1 -0
  341. package/mobile/dist/ui-kit/TopItem/TopItem.d.ts +1 -2
  342. package/mobile/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  343. package/mobile/dist/utils/noop.d.ts +1 -0
  344. package/mobile/dist/utils/noop.js +7 -0
  345. package/mobile/dist/utils/noop.js.map +1 -0
  346. package/mobile/dist/utils/useDebouncedEffect.d.ts +1 -0
  347. package/mobile/dist/utils/useDebouncedEffect.js +11 -0
  348. package/mobile/dist/utils/useDebouncedEffect.js.map +1 -0
  349. package/mobile/lib/EventBus/defaultEventBus.d.ts +3 -2
  350. package/mobile/lib/EventBus/defaultEventBus.js.map +1 -1
  351. package/mobile/lib/components/ApplicationForm/renderBankOffices.d.ts +1 -1
  352. package/mobile/lib/components/Blocks.js +1 -3
  353. package/mobile/lib/components/Blocks.js.map +1 -1
  354. package/mobile/lib/components/ContentPage/ContentPage.js +8 -7
  355. package/mobile/lib/components/ContentPage/ContentPage.js.map +1 -1
  356. package/mobile/lib/components/Footer/Footer.js +1 -1
  357. package/mobile/lib/components/Footer/Footer.js.map +1 -1
  358. package/mobile/lib/components/Header/HeaderSecondaryMenu.d.ts +1 -3
  359. package/mobile/lib/components/Header/HeaderSecondaryMenu.js +10 -13
  360. package/mobile/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  361. package/mobile/lib/components/Header/HeaderSecondaryMenuButton.d.ts +1 -2
  362. package/mobile/lib/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  363. package/mobile/lib/components/HorizontalLayout/HorizontalLayout.js +1 -1
  364. package/mobile/lib/components/HorizontalLayout/HorizontalLayout.js.map +1 -1
  365. package/mobile/lib/components/RollupItem/RollupItem.js +2 -4
  366. package/mobile/lib/components/RollupItem/RollupItem.js.map +1 -1
  367. package/mobile/lib/components/SafeDepositRental/RegionsAndBranches.d.ts +1 -1
  368. package/mobile/lib/components/SafeDepositRental/SafeBoxCases.d.ts +1 -1
  369. package/mobile/lib/components/SafeDepositRental/SafeDepositRental.js +1 -1
  370. package/mobile/lib/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
  371. package/mobile/lib/components/SafeDepositRental/SafeDepositRentalFields.d.ts +2 -2
  372. package/mobile/lib/components/SafeDepositRental/SafeDepositRentalFields.js.map +1 -1
  373. package/mobile/lib/components/SafeDepositRental/SafeDepositRentalForm.d.ts +1 -1
  374. package/mobile/lib/components/SafeDepositRental/SafeDepositRentalTotal.d.ts +1 -1
  375. package/mobile/lib/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
  376. package/mobile/lib/{hooks → components/SafeDepositRental}/useSafeBoxes.d.ts +0 -0
  377. package/mobile/lib/{hooks → components/SafeDepositRental}/useSafeBoxes.js +1 -1
  378. package/mobile/lib/components/SafeDepositRental/useSafeBoxes.js.map +1 -0
  379. package/mobile/lib/components/SafeDepositRental/utils.d.ts +1 -1
  380. package/mobile/lib/components/Tabs/TabActivationEvent.d.ts +5 -0
  381. package/mobile/lib/components/Tabs/TabActivationEvent.js +2 -0
  382. package/mobile/lib/components/Tabs/TabActivationEvent.js.map +1 -0
  383. package/mobile/lib/components/Tabs/Tabs.d.ts +1 -5
  384. package/mobile/lib/components/Tabs/Tabs.js.map +1 -1
  385. package/mobile/lib/components/VerticalLayout/VerticalLayout.js +1 -3
  386. package/mobile/lib/components/VerticalLayout/VerticalLayout.js.map +1 -1
  387. package/mobile/lib/hooks/useLink.js +3 -0
  388. package/mobile/lib/hooks/useLink.js.map +1 -1
  389. package/mobile/lib/hooks/useLocation.d.ts +1 -1
  390. package/mobile/lib/hooks/useLocation.js +2 -2
  391. package/mobile/lib/hooks/useLocation.js.map +1 -1
  392. package/mobile/lib/services/search/useSearch.d.ts +7 -2
  393. package/mobile/lib/services/search/useSearch.js +16 -19
  394. package/mobile/lib/services/search/useSearch.js.map +1 -1
  395. package/mobile/lib/ui-kit/Dialog/Dialog.d.ts +1 -0
  396. package/mobile/lib/ui-kit/Dialog/Dialog.js +3 -7
  397. package/mobile/lib/ui-kit/Dialog/Dialog.js.map +1 -1
  398. package/mobile/lib/ui-kit/Dialog/DialogAction.d.ts +12 -0
  399. package/mobile/lib/ui-kit/Dialog/DialogAction.js +2 -0
  400. package/mobile/lib/ui-kit/Dialog/DialogAction.js.map +1 -0
  401. package/mobile/lib/ui-kit/Dialog/useDialog.d.ts +4 -0
  402. package/mobile/lib/ui-kit/Dialog/useDialog.js +6 -0
  403. package/mobile/lib/ui-kit/Dialog/useDialog.js.map +1 -0
  404. package/mobile/lib/ui-kit/Dialog/useDialogHandlers.d.ts +6 -0
  405. package/mobile/lib/ui-kit/Dialog/useDialogHandlers.js +18 -0
  406. package/mobile/lib/ui-kit/Dialog/useDialogHandlers.js.map +1 -0
  407. package/mobile/lib/ui-kit/Dialog/useDialogProps.d.ts +5 -0
  408. package/mobile/lib/ui-kit/Dialog/useDialogProps.js +34 -0
  409. package/mobile/lib/ui-kit/Dialog/useDialogProps.js.map +1 -0
  410. package/mobile/lib/ui-kit/LocationDialog/LocationDialog.d.ts +3 -0
  411. package/mobile/lib/ui-kit/{Location/Location.js → LocationDialog/LocationDialog.js} +15 -9
  412. package/mobile/lib/ui-kit/LocationDialog/LocationDialog.js.map +1 -0
  413. package/mobile/lib/ui-kit/LocationDialog/LocationDialogProps.d.ts +13 -0
  414. package/mobile/lib/ui-kit/LocationDialog/LocationDialogProps.js +2 -0
  415. package/mobile/lib/ui-kit/LocationDialog/LocationDialogProps.js.map +1 -0
  416. package/mobile/lib/ui-kit/{Location → LocationDialog}/SearchBar.d.ts +0 -0
  417. package/mobile/lib/ui-kit/{Location → LocationDialog}/SearchBar.js +0 -0
  418. package/mobile/lib/ui-kit/LocationDialog/SearchBar.js.map +1 -0
  419. package/mobile/lib/ui-kit/SearchBar/SearchBarInner.d.ts +0 -2
  420. package/mobile/lib/ui-kit/SearchBar/SearchBarInner.js +14 -41
  421. package/mobile/lib/ui-kit/SearchBar/SearchBarInner.js.map +1 -1
  422. package/mobile/lib/ui-kit/SearchDialog/SearchDialog.d.ts +6 -0
  423. package/mobile/lib/ui-kit/SearchDialog/SearchDialog.js +38 -0
  424. package/mobile/lib/ui-kit/SearchDialog/SearchDialog.js.map +1 -0
  425. package/mobile/lib/ui-kit/SearchDialog/SearchInput.d.ts +9 -0
  426. package/mobile/lib/ui-kit/{SearchBar/SearchBarInput.js → SearchDialog/SearchInput.js} +2 -2
  427. package/mobile/lib/ui-kit/SearchDialog/SearchInput.js.map +1 -0
  428. package/mobile/lib/ui-kit/TopItem/TopItem.d.ts +1 -2
  429. package/mobile/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  430. package/mobile/lib/utils/noop.d.ts +1 -0
  431. package/mobile/lib/utils/noop.js +4 -0
  432. package/mobile/lib/utils/noop.js.map +1 -0
  433. package/mobile/lib/utils/useDebouncedEffect.d.ts +1 -0
  434. package/mobile/lib/utils/useDebouncedEffect.js +8 -0
  435. package/mobile/lib/utils/useDebouncedEffect.js.map +1 -0
  436. package/mobile/src/EventBus/defaultEventBus.ts +3 -2
  437. package/mobile/src/components/ApplicationForm/renderBankOffices.tsx +1 -1
  438. package/mobile/src/components/Blocks.ts +1 -3
  439. package/mobile/src/components/ContentPage/ContentPage.tsx +15 -12
  440. package/mobile/src/components/Footer/Footer.tsx +1 -1
  441. package/mobile/src/components/Header/HeaderSecondaryMenu.tsx +18 -42
  442. package/mobile/src/components/Header/HeaderSecondaryMenuButton.tsx +1 -2
  443. package/mobile/src/components/HorizontalLayout/HorizontalLayout.tsx +1 -1
  444. package/mobile/src/components/RollupItem/RollupItem.tsx +2 -10
  445. package/mobile/src/components/SafeDepositRental/RegionsAndBranches.tsx +1 -1
  446. package/mobile/src/components/SafeDepositRental/SafeBoxCases.tsx +1 -1
  447. package/mobile/src/components/SafeDepositRental/SafeDepositRental.tsx +1 -1
  448. package/mobile/src/components/SafeDepositRental/SafeDepositRentalFields.tsx +2 -2
  449. package/mobile/src/components/SafeDepositRental/SafeDepositRentalForm.tsx +1 -1
  450. package/mobile/src/components/SafeDepositRental/SafeDepositRentalTotal.tsx +1 -1
  451. package/mobile/src/{hooks → components/SafeDepositRental}/useSafeBoxes.ts +1 -1
  452. package/mobile/src/components/SafeDepositRental/utils.ts +1 -1
  453. package/mobile/src/components/Tabs/TabActivationEvent.ts +6 -0
  454. package/mobile/src/components/Tabs/Tabs.tsx +0 -5
  455. package/mobile/src/components/VerticalLayout/VerticalLayout.tsx +1 -3
  456. package/mobile/src/hooks/useLink.ts +4 -0
  457. package/mobile/src/hooks/useLocation.ts +5 -8
  458. package/mobile/src/services/search/useSearch.ts +26 -23
  459. package/mobile/src/ui-kit/Dialog/Dialog.tsx +6 -14
  460. package/mobile/src/ui-kit/Dialog/DialogAction.ts +14 -0
  461. package/mobile/src/ui-kit/Dialog/useDialog.ts +6 -0
  462. package/mobile/src/ui-kit/Dialog/useDialogHandlers.ts +28 -0
  463. package/mobile/src/ui-kit/Dialog/useDialogProps.ts +45 -0
  464. package/mobile/src/ui-kit/{Location/Location.tsx → LocationDialog/LocationDialog.tsx} +38 -29
  465. package/mobile/src/ui-kit/LocationDialog/LocationDialogProps.ts +20 -0
  466. package/mobile/src/ui-kit/{Location → LocationDialog}/SearchBar.tsx +0 -0
  467. package/mobile/src/ui-kit/SearchBar/SearchBarInner.tsx +17 -85
  468. package/mobile/src/ui-kit/SearchDialog/SearchDialog.tsx +65 -0
  469. package/{src/ui-kit/SearchBar/SearchBarInput.tsx → mobile/src/ui-kit/SearchDialog/SearchInput.tsx} +2 -2
  470. package/mobile/src/ui-kit/TopItem/TopItem.tsx +1 -2
  471. package/mobile/src/utils/noop.ts +3 -0
  472. package/mobile/src/utils/useDebouncedEffect.ts +14 -0
  473. package/package.json +1 -1
  474. package/src/EventBus/defaultEventBus.ts +3 -2
  475. package/src/components/ApplicationForm/renderBankOffices.tsx +1 -1
  476. package/src/components/Blocks.mobile.ts +1 -3
  477. package/src/components/Blocks.ts +0 -2
  478. package/src/components/ContentPage/ContentPage.tsx +15 -12
  479. package/src/components/Footer/Footer.fixture.tsx +17 -0
  480. package/src/components/Footer/Footer.mobile.tsx +1 -1
  481. package/src/components/Footer/Footer.tsx +1 -1
  482. package/src/components/Header/Header.tsx +12 -2
  483. package/src/components/Header/HeaderSecondaryMenu.tsx +18 -42
  484. package/src/components/Header/HeaderSecondaryMenuButton.tsx +1 -2
  485. package/src/components/HorizontalLayout/HorizontalLayout.tsx +1 -1
  486. package/src/components/RollupItem/RollupItem.mobile.tsx +2 -10
  487. package/src/components/RollupItem/RollupItem.tsx +1 -1
  488. package/src/components/SafeDepositRental/RegionsAndBranches.tsx +1 -1
  489. package/src/components/SafeDepositRental/SafeBoxCases.tsx +1 -1
  490. package/src/components/SafeDepositRental/SafeDepositRental.tsx +1 -1
  491. package/src/components/SafeDepositRental/SafeDepositRentalFields.tsx +2 -2
  492. package/src/components/SafeDepositRental/SafeDepositRentalForm.tsx +1 -1
  493. package/src/components/SafeDepositRental/SafeDepositRentalTotal.tsx +1 -1
  494. package/src/{hooks → components/SafeDepositRental}/useSafeBoxes.ts +1 -1
  495. package/src/components/SafeDepositRental/utils.ts +1 -1
  496. package/src/components/Tabs/TabActivationEvent.ts +6 -0
  497. package/src/components/Tabs/Tabs.tsx +0 -5
  498. package/src/components/VerticalLayout/VerticalLayout.tsx +1 -3
  499. package/src/hooks/useLink.ts +4 -0
  500. package/src/hooks/useLocation.ts +5 -8
  501. package/src/services/search/useSearch.ts +26 -23
  502. package/src/ui-kit/Dialog/Dialog.tsx +6 -14
  503. package/src/ui-kit/Dialog/DialogAction.ts +14 -0
  504. package/src/ui-kit/Dialog/useDialog.ts +6 -0
  505. package/src/ui-kit/Dialog/useDialogHandlers.ts +28 -0
  506. package/src/ui-kit/Dialog/useDialogProps.ts +45 -0
  507. package/src/ui-kit/{Location/Location.fixture.tsx → LocationDialog/LocationDialog.fixture.tsx} +3 -5
  508. package/src/ui-kit/{Location/Location.tsx → LocationDialog/LocationDialog.tsx} +38 -29
  509. package/src/ui-kit/LocationDialog/LocationDialogProps.ts +20 -0
  510. package/src/ui-kit/{Location → LocationDialog}/SearchBar.tsx +0 -0
  511. package/src/ui-kit/SearchBar/SearchBarInner.tsx +17 -85
  512. package/src/ui-kit/SearchDialog/SearchDialog.tsx +65 -0
  513. package/{mobile/src/ui-kit/SearchBar/SearchBarInput.tsx → src/ui-kit/SearchDialog/SearchInput.tsx} +2 -2
  514. package/src/ui-kit/TopItem/TopItem.tsx +1 -2
  515. package/src/utils/noop.ts +3 -0
  516. package/src/utils/useDebouncedEffect.ts +14 -0
  517. package/bin/migration-scripts/0.4.5.js +0 -109
  518. package/bin/migration-scripts/0.5.10.js +0 -36
  519. package/bin/migration-scripts/0.6.16.js +0 -90
  520. package/bin/migration-scripts/0.6.34.js +0 -53
  521. package/bundle/components/Accordion/Accordion.d.ts +0 -5
  522. package/bundle/components/Accordion/Accordion.mobile.d.ts +0 -5
  523. package/bundle/components/Accordion/AccordionContent.d.ts +0 -19
  524. package/bundle/ui-kit/Location/Location.d.ts +0 -2
  525. package/bundle/ui-kit/Location/LocationProps.d.ts +0 -16
  526. package/dist/components/Accordion/Accordion.d.ts +0 -5
  527. package/dist/components/Accordion/Accordion.js +0 -12
  528. package/dist/components/Accordion/Accordion.js.map +0 -1
  529. package/dist/components/Accordion/Accordion.mobile.d.ts +0 -5
  530. package/dist/components/Accordion/Accordion.mobile.js +0 -11
  531. package/dist/components/Accordion/Accordion.mobile.js.map +0 -1
  532. package/dist/components/Accordion/AccordionContent.d.ts +0 -19
  533. package/dist/components/Accordion/AccordionContent.js.map +0 -1
  534. package/dist/hooks/useSafeBoxes.js.map +0 -1
  535. package/dist/ui-kit/Location/Location.d.ts +0 -2
  536. package/dist/ui-kit/Location/Location.js.map +0 -1
  537. package/dist/ui-kit/Location/LocationProps.d.ts +0 -16
  538. package/dist/ui-kit/Location/LocationProps.js.map +0 -1
  539. package/dist/ui-kit/Location/SearchBar.js.map +0 -1
  540. package/dist/ui-kit/SearchBar/SearchBarInput.js.map +0 -1
  541. package/lib/components/Accordion/Accordion.d.ts +0 -5
  542. package/lib/components/Accordion/Accordion.fixture.d.ts +0 -7
  543. package/lib/components/Accordion/Accordion.fixture.mobile.d.ts +0 -8
  544. package/lib/components/Accordion/Accordion.js +0 -10
  545. package/lib/components/Accordion/Accordion.js.map +0 -1
  546. package/lib/components/Accordion/Accordion.mobile.d.ts +0 -5
  547. package/lib/components/Accordion/Accordion.mobile.js +0 -9
  548. package/lib/components/Accordion/Accordion.mobile.js.map +0 -1
  549. package/lib/components/Accordion/AccordionContent.d.ts +0 -19
  550. package/lib/components/Accordion/AccordionContent.js +0 -2
  551. package/lib/components/Accordion/AccordionContent.js.map +0 -1
  552. package/lib/hooks/useSafeBoxes.js.map +0 -1
  553. package/lib/ui-kit/Location/Location.d.ts +0 -2
  554. package/lib/ui-kit/Location/Location.js.map +0 -1
  555. package/lib/ui-kit/Location/LocationProps.d.ts +0 -16
  556. package/lib/ui-kit/Location/LocationProps.js +0 -2
  557. package/lib/ui-kit/Location/LocationProps.js.map +0 -1
  558. package/lib/ui-kit/Location/SearchBar.js.map +0 -1
  559. package/lib/ui-kit/SearchBar/SearchBarInput.js.map +0 -1
  560. package/mobile/bundle/components/Accordion/Accordion.d.ts +0 -5
  561. package/mobile/bundle/components/Accordion/AccordionContent.d.ts +0 -19
  562. package/mobile/bundle/ui-kit/Location/Location.d.ts +0 -2
  563. package/mobile/bundle/ui-kit/Location/LocationProps.d.ts +0 -16
  564. package/mobile/dist/components/Accordion/Accordion.d.ts +0 -5
  565. package/mobile/dist/components/Accordion/Accordion.js +0 -11
  566. package/mobile/dist/components/Accordion/Accordion.js.map +0 -1
  567. package/mobile/dist/components/Accordion/AccordionContent.d.ts +0 -19
  568. package/mobile/dist/components/Accordion/AccordionContent.js.map +0 -1
  569. package/mobile/dist/hooks/useSafeBoxes.js.map +0 -1
  570. package/mobile/dist/ui-kit/Location/Location.d.ts +0 -2
  571. package/mobile/dist/ui-kit/Location/Location.js.map +0 -1
  572. package/mobile/dist/ui-kit/Location/LocationProps.d.ts +0 -16
  573. package/mobile/dist/ui-kit/Location/LocationProps.js.map +0 -1
  574. package/mobile/dist/ui-kit/Location/SearchBar.js.map +0 -1
  575. package/mobile/dist/ui-kit/SearchBar/SearchBarInput.d.ts +0 -9
  576. package/mobile/dist/ui-kit/SearchBar/SearchBarInput.js.map +0 -1
  577. package/mobile/lib/components/Accordion/Accordion.d.ts +0 -5
  578. package/mobile/lib/components/Accordion/Accordion.js +0 -9
  579. package/mobile/lib/components/Accordion/Accordion.js.map +0 -1
  580. package/mobile/lib/components/Accordion/AccordionContent.d.ts +0 -19
  581. package/mobile/lib/components/Accordion/AccordionContent.js +0 -2
  582. package/mobile/lib/components/Accordion/AccordionContent.js.map +0 -1
  583. package/mobile/lib/hooks/useSafeBoxes.js.map +0 -1
  584. package/mobile/lib/ui-kit/Location/Location.d.ts +0 -2
  585. package/mobile/lib/ui-kit/Location/Location.js.map +0 -1
  586. package/mobile/lib/ui-kit/Location/LocationProps.d.ts +0 -16
  587. package/mobile/lib/ui-kit/Location/LocationProps.js +0 -2
  588. package/mobile/lib/ui-kit/Location/LocationProps.js.map +0 -1
  589. package/mobile/lib/ui-kit/Location/SearchBar.js.map +0 -1
  590. package/mobile/lib/ui-kit/SearchBar/SearchBarInput.d.ts +0 -9
  591. package/mobile/lib/ui-kit/SearchBar/SearchBarInput.js.map +0 -1
  592. package/mobile/src/components/Accordion/Accordion.example.json +0 -54
  593. package/mobile/src/components/Accordion/Accordion.tsx +0 -27
  594. package/mobile/src/components/Accordion/Accordion.ui.json +0 -1
  595. package/mobile/src/components/Accordion/AccordionContent.ts +0 -22
  596. package/mobile/src/ui-kit/Location/LocationProps.ts +0 -25
  597. package/src/components/Accordion/Accordion.example.json +0 -54
  598. package/src/components/Accordion/Accordion.fixture.mobile.tsx +0 -64
  599. package/src/components/Accordion/Accordion.fixture.tsx +0 -113
  600. package/src/components/Accordion/Accordion.mobile.tsx +0 -27
  601. package/src/components/Accordion/Accordion.tsx +0 -33
  602. package/src/components/Accordion/Accordion.ui.json +0 -1
  603. package/src/components/Accordion/AccordionContent.ts +0 -22
  604. package/src/ui-kit/Location/LocationProps.ts +0 -25
@@ -236,84 +236,41 @@
236
236
  return JSXTmpl;
237
237
  };
238
238
 
239
- const DEFAULT_SLOT_NAME = null;
239
+ const HeadingClass = {
240
+ h0: 'text-m-title',
241
+ h1: 'text-m-title',
242
+ h2: 'text-m-title',
243
+ h3: 'text-h6',
244
+ h4: 'text-m-title-xs',
245
+ h5: 'text-m-title-xs',
246
+ h6: 'text-m-title-xs',
247
+ };
248
+ const Heading = JSX((props) => {
249
+ const { className, headingType = 'h3', title, as: Tag = 'h3' } = props;
250
+ return (jsx(Tag, { className: `font-sans font-medium m-0 ${HeadingClass[headingType]} ${className || ''}`, children: title }));
251
+ });
240
252
 
241
253
  const style = (...atoms) => atoms
242
254
  .flatMap((_) => _)
243
255
  .filter(Boolean)
244
256
  .join(' ');
245
257
 
246
- const defaultBlockDecorator = ({ blockClassName, block, render }) => render({ blockClassName, block });
247
-
248
- const DEFAULT_ANCESTORS = [];
249
- const defaultStyle = 'col-span-12';
250
- function renderBlock(block, options) {
251
- const { key, blockDecorator = defaultBlockDecorator, blocksRegistry = {}, ancestors = DEFAULT_ANCESTORS, className = '', extraProps = {}, } = options;
252
- const { type } = block;
253
- if (!(type && type in blocksRegistry)) {
254
- console.warn(`No block with "${type}" is registered`);
255
- }
256
- const BlockComponent = type && blocksRegistry[type];
257
- return blockDecorator({
258
- blockClassName: style('scroll-mt-12', // TODO scroll-mt-12 ? here?
259
- className, block.style || defaultStyle),
260
- block,
261
- ancestors,
262
- // Adjusted by decorator block and blockClassName
263
- render: ({ block: adjustedBlock, blockClassName: adjustedBlockClassName }) => {
264
- const { content } = adjustedBlock;
265
- return BlockComponent ? (jsx(BlockComponent, { className: adjustedBlockClassName, block: block, options: options, ...content, ...extraProps }, key)) : null;
266
- },
267
- }, key);
268
- }
269
-
270
- const EMPTY_ANCESTORS = [];
271
- const renderBlocksList = (blocks, { key, ancestors = EMPTY_ANCESTORS, slotName = DEFAULT_SLOT_NAME, renderProps = renderBlock, ...options }) => (blocks || []).map((_, j) => renderProps(_, {
272
- ...options,
273
- key: `${key ? key : _.type}-${j}`,
274
- ancestors: options.parent
275
- ? [...(ancestors || EMPTY_ANCESTORS), [options.parent, slotName]]
276
- : ancestors,
277
- }));
278
-
279
- function renderChildren({ children, block, options, renderProps, }) {
280
- if (children) {
258
+ const mapChildren = (mapper) => (children) => {
259
+ if (children === null || children === undefined) {
281
260
  return children;
282
261
  }
283
- return block && options
284
- ? renderBlocksList(block.blocks, { ...options, parent: block, renderProps })
285
- : null;
286
- }
287
-
288
- class EventBus {
289
- subscribers = {};
290
- subjectsStateMap = {};
291
- subscribe(type, listener) {
292
- this.subscribers[type] = (this.subscribers[type] || []).concat(listener);
293
- const latestEvent = this.subjectsStateMap[type];
294
- if (latestEvent) {
295
- listener(latestEvent);
296
- }
297
- return () => {
298
- this.unsubscribe(type, listener);
299
- };
300
- }
301
- unsubscribe(type, listener) {
302
- this.subscribers[type] = this.subscribers[type]?.filter((s) => s !== listener);
303
- }
304
- fire(type, event) {
305
- const isSubjectDeclared = type in this.subjectsStateMap;
306
- if (isSubjectDeclared) {
307
- this.subjectsStateMap[type] = event;
308
- }
309
- this.subscribers[type]?.forEach((s) => s(event));
310
- }
311
- subject(type, event) {
312
- this.subjectsStateMap[type] = event;
313
- }
314
- }
262
+ return Array.isArray(children) ? children.map(mapper) : mapper(children, 0);
263
+ };
315
264
 
316
- const defaultEventBus = new EventBus();
265
+ const HEADER_HEIGHT = 170;
266
+ const FOOTER_HEIGHT = 48;
267
+ const BLOCKS_GAP = 4;
268
+ const PAGE_PADDINGS_X = 20;
269
+ const DEFAULT_HEIGHT = 866;
270
+ const getContainerHeight = (minHeight) => ({
271
+ height: `calc(100vh - ${HEADER_HEIGHT + FOOTER_HEIGHT + BLOCKS_GAP + PAGE_PADDINGS_X}px)`,
272
+ minHeight: `${minHeight || DEFAULT_HEIGHT}px`,
273
+ });
317
274
 
318
275
  const SENSITIVITY_SCALE = 10;
319
276
  function useIntersectionObserver(observerCallback, { sensitivity, rootRef } = {}) {
@@ -339,73 +296,6 @@
339
296
  .concat(1);
340
297
  }
341
298
 
342
- const blockRouterEventBus = new EventBus();
343
-
344
- function useBlockIntersectionObserver(block) {
345
- const observerCallback = useCallback((entries) => {
346
- if (!block || !entries?.length) {
347
- return;
348
- }
349
- const intersection = entries[entries.length - 1];
350
- blockRouterEventBus.fire('intersection', { block, intersection });
351
- }, [block]);
352
- return useIntersectionObserver(observerCallback, { sensitivity: 1 });
353
- }
354
-
355
- const blockStyles = {
356
- primary: 'bg-white text-primary-text',
357
- secondary: 'bg-primary-main text-white',
358
- gray: 'bg-main-divider text-primary-text',
359
- transparent: 'bg-transparent text-primary-text',
360
- '': '',
361
- };
362
- const BlockWrapper = JSX(({ className = '', version = 'primary', block, tag = 'section', role, isTheme = true, extraProps = {}, children, }) => {
363
- const Tag = tag;
364
- const ref = useBlockIntersectionObserver(block);
365
- const [isHidden, setHidden] = useState(false);
366
- useEffect(() => defaultEventBus.subscribe('tab', (event) => {
367
- setHidden(Boolean(event.label && block?.labels?.length && !block.labels.includes(event.label)));
368
- }), [block]);
369
- return (jsx(Tag, { className: style(groupStyle(Boolean(version && isTheme)), blockStyles[version], isHidden ? 'hidden' : '', className), ...(version && isTheme ? { 'data-ver': version } : {}), ...(block?.anchor ? { id: block.anchor, ref } : {}), role: role, ...extraProps, children: children }));
370
- });
371
- const groupStyle = (isGroup) => (isGroup ? 'group' : '');
372
-
373
- const HeadingClass = {
374
- h0: 'text-m-title',
375
- h1: 'text-m-title',
376
- h2: 'text-m-title',
377
- h3: 'text-h6',
378
- h4: 'text-m-title-xs',
379
- h5: 'text-m-title-xs',
380
- h6: 'text-m-title-xs',
381
- };
382
- const Heading = JSX((props) => {
383
- const { className, headingType = 'h3', title, as: Tag = 'h3' } = props;
384
- return (jsx(Tag, { className: `font-sans font-medium m-0 ${HeadingClass[headingType]} ${className || ''}`, children: title }));
385
- });
386
-
387
- const Paragraph = JSX(({ children, ...style }) => (jsx("p", { className: ['font-sans', ...Object.values(style)].join(' '), children: children })));
388
-
389
- const Accordion = JSX(({ title, description, className = '', ...rest }) => (jsxs(BlockWrapper, { className: `py-6 px-4 ${className}`, ...rest, children: [title ? jsx(Heading, { headingType: "h3", className: "mb-2 text-center", title: title }) : null, description ? (jsx("div", { className: "mb-5", children: jsx(Paragraph, { size: "text-m", font: "font-light", align: "text-center", children: description }) })) : null, jsx("div", { className: "list-none m-0 p-0", children: renderChildren(rest) })] })));
390
- Accordion.childrenTypes = ['Accordion'];
391
-
392
- const mapChildren = (mapper) => (children) => {
393
- if (children === null || children === undefined) {
394
- return children;
395
- }
396
- return Array.isArray(children) ? children.map(mapper) : mapper(children, 0);
397
- };
398
-
399
- const HEADER_HEIGHT = 170;
400
- const FOOTER_HEIGHT = 48;
401
- const BLOCKS_GAP = 4;
402
- const PAGE_PADDINGS_X = 20;
403
- const DEFAULT_HEIGHT = 866;
404
- const getContainerHeight = (minHeight) => ({
405
- height: `calc(100vh - ${HEADER_HEIGHT + FOOTER_HEIGHT + BLOCKS_GAP + PAGE_PADDINGS_X}px)`,
406
- minHeight: `${minHeight || DEFAULT_HEIGHT}px`,
407
- });
408
-
409
299
  const SwipeListItem = JSX(({ className = '', style, idx, activeIndex, observerOptions, children, onIntersection }) => {
410
300
  const observerCallback = useCallback((entries) => {
411
301
  if (entries.length && onIntersection) {
@@ -559,6 +449,41 @@
559
449
  return (jsxs("div", { className: style(className, listType === 'vertical-list' ? 'relative h-full' : ''), children: [jsx(SwipeListContainer, { containerRef: containerRef, activeIndex: activeIndex, visibleItemCount: 1, gap: gap, padding: padding, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, listType: listType, minHeight: minHeight, children: children }), showDots ? (jsx(SwipeListControlDots, { containerRef: containerRef, activeIndex: activeIndex, dotCount: itemCount, listType: listType, version: version })) : null] }));
560
450
  });
561
451
 
452
+ class EventBus {
453
+ subscribers = {};
454
+ subjectsStateMap = {};
455
+ subscribe(type, listener) {
456
+ this.subscribers[type] = (this.subscribers[type] || []).concat(listener);
457
+ const latestEvent = this.subjectsStateMap[type];
458
+ if (latestEvent) {
459
+ listener(latestEvent);
460
+ }
461
+ return () => {
462
+ this.unsubscribe(type, listener);
463
+ };
464
+ }
465
+ unsubscribe(type, listener) {
466
+ this.subscribers[type] = this.subscribers[type]?.filter((s) => s !== listener);
467
+ }
468
+ fire(type, event) {
469
+ const isSubjectDeclared = type in this.subjectsStateMap;
470
+ if (isSubjectDeclared) {
471
+ this.subjectsStateMap[type] = event;
472
+ }
473
+ this.subscribers[type]?.forEach((s) => s(event));
474
+ }
475
+ subject(type, event) {
476
+ this.subjectsStateMap[type] = event;
477
+ }
478
+ }
479
+
480
+ const defaultEventBus = new EventBus();
481
+
482
+ const useDialog = (id = '') => ({
483
+ open: (message) => defaultEventBus.fire('dialog', { type: 'open', id, message }),
484
+ close: () => defaultEventBus.fire('dialog', { type: 'close' }),
485
+ });
486
+
562
487
  const dirname = (path) => path?.split('/').slice(0, -1).join('/');
563
488
 
564
489
  const isURL = (href) => Boolean(href?.includes(':'));
@@ -613,6 +538,7 @@
613
538
 
614
539
  function useLink(isRemote = false) {
615
540
  const router = useRouter();
541
+ const { close } = useDialog();
616
542
  return (props) => ({
617
543
  ...props,
618
544
  href: isRemote ? props.href : adjustHref(router)(props.href),
@@ -626,6 +552,7 @@
626
552
  // Default routing
627
553
  return;
628
554
  }
555
+ close();
629
556
  // Client routing
630
557
  ev?.preventDefault();
631
558
  router.push(href);
@@ -888,14 +815,65 @@
888
815
  return data || {};
889
816
  }
890
817
 
891
- function useBool(defaultValue = false) {
892
- const [value, setValue] = useState(defaultValue);
893
- const setTrue = useCallback(() => setValue(true), []);
894
- const setFalse = useCallback(() => setValue(false), []);
895
- const toggle = useCallback(() => setValue((_) => !_), []);
896
- return [value, { setValue, setTrue, setFalse, toggle }];
818
+ const blockRouterEventBus = new EventBus();
819
+
820
+ function useBlockIntersectionObserver(block) {
821
+ const observerCallback = useCallback((entries) => {
822
+ if (!block || !entries?.length) {
823
+ return;
824
+ }
825
+ const intersection = entries[entries.length - 1];
826
+ blockRouterEventBus.fire('intersection', { block, intersection });
827
+ }, [block]);
828
+ return useIntersectionObserver(observerCallback, { sensitivity: 1 });
829
+ }
830
+
831
+ const blockStyles = {
832
+ primary: 'bg-white text-primary-text',
833
+ secondary: 'bg-primary-main text-white',
834
+ gray: 'bg-main-divider text-primary-text',
835
+ transparent: 'bg-transparent text-primary-text',
836
+ '': '',
837
+ };
838
+ const BlockWrapper = JSX(({ className = '', version = 'primary', block, tag = 'section', role, isTheme = true, extraProps = {}, children, }) => {
839
+ const Tag = tag;
840
+ const ref = useBlockIntersectionObserver(block);
841
+ const [isHidden, setHidden] = useState(false);
842
+ useEffect(() => defaultEventBus.subscribe('tab', (event) => {
843
+ setHidden(Boolean(event.label && block?.labels?.length && !block.labels.includes(event.label)));
844
+ }), [block]);
845
+ return (jsx(Tag, { className: style(groupStyle(Boolean(version && isTheme)), blockStyles[version], isHidden ? 'hidden' : '', className), ...(version && isTheme ? { 'data-ver': version } : {}), ...(block?.anchor ? { id: block.anchor, ref } : {}), role: role, ...extraProps, children: children }));
846
+ });
847
+ const groupStyle = (isGroup) => (isGroup ? 'group' : '');
848
+
849
+ const CloseButton = JSX(({ className, onClick }) => (jsx("button", { className: style('visible peer-placeholder-shown:invisible w-6 h-6 p-1 bg-transparent border-none', className), onClick: onClick, title: "\u0417\u0430\u043A\u0440\u044B\u0442\u044C", children: jsx(Img, { image: { icon: 'CloseIcon' }, width: "24", height: "24" }) })));
850
+
851
+ function assertUnreachable(x) {
852
+ throw new Error(x);
897
853
  }
898
854
 
855
+ function useDialogHandlers({ onOpen, onClose } = {}) {
856
+ useEffect(() => defaultEventBus.subscribe('dialog', (action) => {
857
+ switch (action.type) {
858
+ case 'open':
859
+ onOpen && onOpen(action);
860
+ break;
861
+ case 'close':
862
+ onClose && onClose();
863
+ break;
864
+ default:
865
+ assertUnreachable(action);
866
+ }
867
+ }), [onOpen, onClose]);
868
+ }
869
+
870
+ const useDebouncedEffect = (effect, deps, delay = 300) => useEffect(() => {
871
+ const timerId = setTimeout(effect, delay);
872
+ return () => {
873
+ clearTimeout(timerId);
874
+ };
875
+ }, deps);
876
+
899
877
  const compareBy = (indexOf) => (a, b) => indexOf(a) - indexOf(b);
900
878
  const desc = (cmp) => (a, b) => -cmp(a, b);
901
879
 
@@ -1020,37 +998,27 @@
1020
998
  const fillMapWith = (keys, value) => new Map(keys.map((_) => [_, value]));
1021
999
 
1022
1000
  const SEARCH_INDEX_FILENAME = 'search.index.json';
1023
- const useSearch = (basePathList = ['/']) => {
1024
- const [query, setQuery] = useState('');
1025
- const [wasQueryFocused, setWasQueryFocused] = useState(false);
1026
- const handleFocus = useCallback(() => {
1027
- setWasQueryFocused(true);
1028
- }, []);
1029
- const key = useMemo(() => basePathList.map((_) => (wasQueryFocused ? _ : null)), // Load search index on input focus
1030
- [wasQueryFocused, ...basePathList]);
1001
+ const useSearch = ({ basePathList = ['/'], initialQuery = '', wasOpened, }) => {
1002
+ const [query, setQuery] = useState(initialQuery || '');
1003
+ useEffect(() => {
1004
+ if (initialQuery !== undefined && initialQuery !== null) {
1005
+ setQuery(initialQuery);
1006
+ }
1007
+ }, [initialQuery]);
1008
+ const key = useMemo(() => basePathList.map((_) => (wasOpened ? _ : null)), // Load search index on very first search
1009
+ [wasOpened, ...basePathList]);
1031
1010
  const { data } = useAsyncData(key, fetchSearchIndex);
1032
1011
  const [result, setResult] = useState(null);
1033
- useEffect(() => {
1034
- const timerId = setTimeout(() => {
1035
- if (data) {
1036
- setResult(data.map(search(query)));
1037
- }
1038
- }, 300);
1039
- return () => {
1040
- clearTimeout(timerId);
1041
- };
1012
+ useDebouncedEffect(() => {
1013
+ if (data) {
1014
+ setResult(data.map(search(query)));
1015
+ }
1042
1016
  }, [data, query]);
1043
- return [result, { value: query, onChange: setQuery, onFocus: handleFocus }];
1017
+ return [result, { value: query, onChange: setQuery }];
1044
1018
  };
1045
1019
  const fetchSearchIndex = async (...basePathList) => (await Promise.allSettled(basePathList.map((basePath) => fetchJSON(joinPath(basePath, '/', SEARCH_INDEX_FILENAME))))).map((_) => (_.status === 'fulfilled' ? _.value : {}));
1046
1020
 
1047
- const CloseButton = JSX(({ className, onClick }) => (jsx("button", { className: style('visible peer-placeholder-shown:invisible w-6 h-6 p-1 bg-transparent border-none', className), onClick: onClick, title: "\u0417\u0430\u043A\u0440\u044B\u0442\u044C", children: jsx(Img, { image: { icon: 'CloseIcon' }, width: "24", height: "24" }) })));
1048
-
1049
- const Dialog = JSX(({ className, head, children, onClose }) => {
1050
- const handleClose = useCallback((ev) => {
1051
- ev.preventDefault();
1052
- onClose && onClose();
1053
- }, [onClose]);
1021
+ const Dialog = JSX(({ className, isOpened, head, children, onClose }) => {
1054
1022
  useEffect(() => {
1055
1023
  const handleEscape = ({ key }) => {
1056
1024
  if (key === 'Escape') {
@@ -1062,9 +1030,47 @@
1062
1030
  globalThis.document?.removeEventListener('keydown', handleEscape);
1063
1031
  };
1064
1032
  }, [onClose]);
1065
- return (jsx("div", { className: style('fixed inset-0 bg-white text-l-light z-50 overflow-x-hidden overflow-y-scroll no-scrollbar', className), role: "dialog", children: jsxs("div", { className: "relative container pb-12 min-h-full", children: [jsxs("div", { className: "sticky bg-white pt-6 top-0", children: [jsx(CloseButton, { className: "absolute top-3 -right-6", onClick: handleClose }), head] }), children] }) }));
1033
+ return isOpened ? (jsx("div", { className: style('fixed inset-0 bg-white text-l-light z-50 overflow-x-hidden overflow-y-scroll no-scrollbar', className), role: "dialog", children: jsxs("div", { className: "relative container pb-12 min-h-full", children: [jsxs("div", { className: "sticky bg-white pt-6 top-0", children: [jsx(CloseButton, { className: "absolute top-3 -right-6", onClick: onClose }), head] }), children] }) })) : null;
1066
1034
  });
1067
1035
 
1036
+ function useBool(defaultValue = false) {
1037
+ const [value, setValue] = useState(defaultValue);
1038
+ const setTrue = useCallback(() => setValue(true), []);
1039
+ const setFalse = useCallback(() => setValue(false), []);
1040
+ const toggle = useCallback(() => setValue((_) => !_), []);
1041
+ return [value, { setValue, setTrue, setFalse, toggle }];
1042
+ }
1043
+
1044
+ function useDialogProps(id) {
1045
+ const [isOpened, { setTrue: open, setFalse: close }] = useBool();
1046
+ const [params, setParams] = useState({ id });
1047
+ const wasOpened = useRef(isOpened);
1048
+ wasOpened.current ||= isOpened;
1049
+ const handleOpen = useCallback((_) => {
1050
+ if (_.id === id) {
1051
+ setParams(_);
1052
+ open();
1053
+ }
1054
+ else {
1055
+ close();
1056
+ }
1057
+ }, [id]);
1058
+ useDialogHandlers({
1059
+ onOpen: handleOpen,
1060
+ onClose: close,
1061
+ });
1062
+ const handleCloseAsEventSource = useCallback(() => {
1063
+ close();
1064
+ defaultEventBus.fire('dialog', { type: 'close' });
1065
+ }, []);
1066
+ return {
1067
+ ...params,
1068
+ isOpened,
1069
+ wasOpened: wasOpened.current,
1070
+ onClose: handleCloseAsEventSource,
1071
+ };
1072
+ }
1073
+
1068
1074
  const Sitemap = JSX(({ className, topItems }) => {
1069
1075
  const link = useLink(true);
1070
1076
  return (jsx("div", { className: style('flex items-start justify-between', className), children: topItems?.map(link).map(renderColumn) }));
@@ -1080,43 +1086,30 @@
1080
1086
  return (jsx("a", { className: style('text-l-light text-secondary-text hover:text-primary-main no-underline', 'overflow-x-hidden overflow-ellipsis whitespace-nowrap'), href: isAnotherPortal ? joinPath(basePath, href) : href, target: target || '_self', onClick: onClick, children: text || `Раздел ${index}` }));
1081
1087
  });
1082
1088
 
1083
- const SearchBarInput = JSX(({ className, isMobile, value, autoFocus, onChange, onFocus }) => {
1089
+ const SearchInput = JSX(({ className, isMobile, value, autoFocus, onChange, onFocus }) => {
1084
1090
  const handleChange = useCallback((ev) => {
1085
1091
  onChange && onChange(ev.target?.value || '');
1086
1092
  }, [onChange]);
1087
1093
  return (jsxs("div", { className: style('font-sans relative', className), role: "form", children: [jsx("div", { className: "absolute h-full flex items-center pl-4 pointer-events-none", children: jsx(Img, { image: { icon: 'LoupeIcon' }, width: "24", height: "24" }) }), jsx("input", { className: style('h-12 pl-12 w-full text-l text-black outline-none box-border', 'border border-solid rounded-md border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text', isMobile ? '' : 'h-full'), value: value, type: "text", name: "search-bar-input", placeholder: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443", autoFocus: autoFocus, onChange: handleChange, onFocus: onFocus })] }));
1088
1094
  });
1089
1095
 
1090
- const MIN_QUERY_LEN = 3;
1091
- const SearchBarInner = JSX(({ className, isMobile, topItems }) => {
1096
+ const SEARCH_DIALOG_ID = 'search';
1097
+ JSX(({ topItems }) => {
1098
+ const dialogProps = useDialogProps(SEARCH_DIALOG_ID);
1092
1099
  const basePathList = topItems?.map((_) => _.href || '/');
1093
- const [searchResult, searchInputProps] = useSearch(basePathList);
1094
- const { value, onChange, onFocus } = searchInputProps;
1100
+ const [searchResult, searchInputProps] = useSearch({
1101
+ basePathList,
1102
+ initialQuery: dialogProps.message,
1103
+ wasOpened: dialogProps.wasOpened,
1104
+ });
1095
1105
  const searchItems = useMemo(() => combineTopItemsAndSearchResult(topItems)(searchResult), [topItems, searchResult]);
1096
1106
  useEffect(() => printSearchItems(searchItems), [searchItems]); // Temp
1097
- const [isSearchDialogOpen, { setTrue: openSearchDialog, setFalse: hideSearchDialog }] = useBool();
1098
- const handleInitialInputChange = useCallback((_) => {
1099
- onChange(_);
1100
- if (isQueryLongEnough(_)) {
1101
- openSearchDialog();
1102
- }
1103
- }, [onChange, isQueryLongEnough]);
1104
- const handleInitialInputFocus = useCallback(() => {
1105
- onFocus();
1106
- if (isQueryLongEnough(value)) {
1107
- openSearchDialog();
1108
- }
1109
- }, [value, onFocus]);
1110
- return (jsxs("div", { className: className, children: [jsx(SearchBarInput, { isMobile: isMobile, value: value, onChange: handleInitialInputChange, onFocus: handleInitialInputFocus }), isMobile ? (jsx(CloseButton, { className: "absolute top-2 right-3", onClick: (e) => {
1111
- e.preventDefault();
1112
- onChange('');
1113
- } })) : null, isSearchDialogOpen ? (jsx(Dialog, { head: jsx(SearchBarInput, { className: "my-5", isMobile: isMobile, autoFocus: true, ...searchInputProps }), onClose: hideSearchDialog, children: jsx(Sitemap, { topItems: searchItems }) })) : null] }));
1107
+ return (jsx(Dialog, { ...dialogProps, head: jsx(SearchInput, { className: "my-5", autoFocus: true, ...searchInputProps }), children: jsx(Sitemap, { topItems: searchItems }) }));
1114
1108
  });
1115
- const isQueryLongEnough = (_) => _ && _.length >= MIN_QUERY_LEN;
1116
1109
  const combineTopItemsAndSearchResult = (topItems) => (searchResult) => topItems?.length && searchResult?.length
1117
1110
  ? zip(topItems, searchResult).map(([_, portalSearchResult]) => ({
1118
1111
  ..._,
1119
- items: portalSearchResult?.map(({ title, uri }) => ({ text: title, href: uri })),
1112
+ items: portalSearchResult?.map(({ title, uri }) => ({ text: title, href: joinPath('/', uri) })),
1120
1113
  }))
1121
1114
  : [];
1122
1115
  // Temp
@@ -1128,6 +1121,22 @@
1128
1121
  }
1129
1122
  }
1130
1123
 
1124
+ const MIN_QUERY_LEN = 3;
1125
+ const SearchBarInner = JSX(({ className, isMobile }) => {
1126
+ const [value, setValue] = useState('');
1127
+ const resetQueryOnDialogClose = useCallback(() => setValue(''), []);
1128
+ useDialogHandlers({ onClose: resetQueryOnDialogClose });
1129
+ const { open } = useDialog(SEARCH_DIALOG_ID);
1130
+ const handleInitialInputChange = useCallback((_) => {
1131
+ setValue(_);
1132
+ if (isQueryLongEnough(_)) {
1133
+ open(_);
1134
+ }
1135
+ }, []);
1136
+ return (jsxs("div", { className: className, children: [jsx(SearchInput, { isMobile: isMobile, value: value, onChange: handleInitialInputChange }), isMobile ? (jsx(CloseButton, { className: "absolute top-2 right-3", onClick: resetQueryOnDialogClose })) : null] }));
1137
+ });
1138
+ const isQueryLongEnough = (_) => _ && _.length >= MIN_QUERY_LEN;
1139
+
1131
1140
  const SearchBar = JSX((props) => (jsx(SearchBarInner, { ...props, isMobile: true })));
1132
1141
 
1133
1142
  const getIconWithVersion = (icon, version = 'primary') => ({
@@ -1174,13 +1183,48 @@
1174
1183
  return (jsx("div", { className: `col-span-12 rounded-md cursor-pointer p-4 mt-6 mb-6 bg-secondary-light font-sans ${className}`, children: href ? (jsxs("div", { className: "flex", children: [jsx("div", { className: "flex justify-center align-middle rounded-md bg-primary-main w-12 h-12", children: jsx(Logo, { className: "w-8", bgColor: "transparent", showTitle: true }) }), jsxs("a", { href: href, target: "_blank", className: "flex flex-col justify-center pl-3", children: [jsx("div", { className: "text-s font-medium mb-[3px]", children: title }), jsx("div", { className: "text-s text-secondary-text", children: description })] })] })) : null }));
1175
1184
  });
1176
1185
 
1177
- function getParentBlockDef(options) {
1178
- return options?.parent || {};
1186
+ const DEFAULT_SLOT_NAME = null;
1187
+
1188
+ const defaultBlockDecorator = ({ blockClassName, block, render }) => render({ blockClassName, block });
1189
+
1190
+ const DEFAULT_ANCESTORS = [];
1191
+ const defaultStyle = 'col-span-12';
1192
+ function renderBlock(block, options) {
1193
+ const { key, blockDecorator = defaultBlockDecorator, blocksRegistry = {}, ancestors = DEFAULT_ANCESTORS, className = '', extraProps = {}, } = options;
1194
+ const { type } = block;
1195
+ if (!(type && type in blocksRegistry)) {
1196
+ console.warn(`No block with "${type}" is registered`);
1197
+ }
1198
+ const BlockComponent = type && blocksRegistry[type];
1199
+ return blockDecorator({
1200
+ blockClassName: style('scroll-mt-12', // TODO scroll-mt-12 ? here?
1201
+ className, block.style || defaultStyle),
1202
+ block,
1203
+ ancestors,
1204
+ // Adjusted by decorator block and blockClassName
1205
+ render: ({ block: adjustedBlock, blockClassName: adjustedBlockClassName }) => {
1206
+ const { content } = adjustedBlock;
1207
+ return BlockComponent ? (jsx(BlockComponent, { className: adjustedBlockClassName, block: block, options: options, ...content, ...extraProps }, key)) : null;
1208
+ },
1209
+ }, key);
1179
1210
  }
1180
1211
 
1181
- function getParentBlockContent(options, defaultContent) {
1182
- const { content } = getParentBlockDef(options);
1183
- return content || defaultContent;
1212
+ const EMPTY_ANCESTORS = [];
1213
+ const renderBlocksList = (blocks, { key, ancestors = EMPTY_ANCESTORS, slotName = DEFAULT_SLOT_NAME, renderProps = renderBlock, ...options }) => (blocks || []).map((_, j) => renderProps(_, {
1214
+ ...options,
1215
+ key: `${key ? key : _.type}-${j}`,
1216
+ ancestors: options.parent
1217
+ ? [...(ancestors || EMPTY_ANCESTORS), [options.parent, slotName]]
1218
+ : ancestors,
1219
+ }));
1220
+
1221
+ function renderChildren({ children, block, options, renderProps, }) {
1222
+ if (children) {
1223
+ return children;
1224
+ }
1225
+ return block && options
1226
+ ? renderBlocksList(block.blocks, { ...options, parent: block, renderProps })
1227
+ : null;
1184
1228
  }
1185
1229
 
1186
1230
  const DefaultFoldButton = JSX(({ className = '', label, icon, dataTheme = '', disabled = false, onClick }) => {
@@ -1217,11 +1261,10 @@
1217
1261
  const Text = JSX(({ children, ...style }) => (jsx("span", { className: ['font-sans', ...Object.values(style)].join(' '), children: children })));
1218
1262
 
1219
1263
  const RollupItem = JSX(({ className = '', label = 'Развернуть', isExpanded, isFoldButtonOnTop = true, version = 'primary', ...rest }) => {
1220
- const { bordered } = getParentBlockContent(rest.options, {});
1221
- return (jsx(BlockWrapper, { className: style('border-b border-solid border-main-divider w-full', bordered ? 'border p-4 rounded mb-4' : 'border-0 border-b last:border-b-0', className), tag: "div", version: "transparent", ...rest, children: jsx(Foldable, { isFoldButtonOnTop: isFoldButtonOnTop, unfoldedByDefault: isExpanded, renderFoldableSection: ({ isUnfolded }) => (jsx(FoldableSection, { className: "flex flex-wrap group-last:last:pb-0 gap-5 [&>*]:p-0", isUnfolded: isUnfolded, children: renderChildren(rest) })), renderFoldButton: ({ isUnfolded, onToggle }) => renderFoldButton({ version, label, isUnfolded, onToggle }) }) }));
1264
+ return (jsx(BlockWrapper, { className: style('border-b border-solid border-main-divider w-full', className), tag: "div", version: "transparent", ...rest, children: jsx(Foldable, { isFoldButtonOnTop: isFoldButtonOnTop, unfoldedByDefault: isExpanded, renderFoldableSection: ({ isUnfolded }) => (jsx(FoldableSection, { className: "flex flex-wrap group-last:last:pb-0 gap-5 [&>*]:p-0", isUnfolded: isUnfolded, children: renderChildren(rest) })), renderFoldButton: ({ isUnfolded, onToggle }) => renderFoldButton({ version, label, isUnfolded, onToggle }) }) }));
1222
1265
  });
1223
1266
  RollupItem.childrenTypes = {
1224
- exclude: ['RollupItem', 'Accordion', 'OtherProducts'],
1267
+ exclude: ['RollupItem'],
1225
1268
  };
1226
1269
  const renderFoldButton = ({ version, label: defaultLabel, isUnfolded, onToggle, className = '', primaryIcon, }) => {
1227
1270
  const label = defaultLabel || (isUnfolded ? 'Скрыть' : 'Развернуть');
@@ -1325,7 +1368,7 @@
1325
1368
  const fallback = rest.options?.page?.fallback;
1326
1369
  const sitemap = useSWRResource(projectSettings.SITEMAP || 'sitemap', fallback);
1327
1370
  const { documents, relatedEnterprises, contacts, socialMedia, horizontalNavigationTitle } = useSWRResource(projectSettings.FOOTER || 'footer', fallback);
1328
- return (jsxs(BlockWrapper, { tag: "footer", className: `px-4 py-[26px] ${className}`, ...rest, children: [jsx(Contacts, { className: "overflow-hidden", items: contacts, hasButton: true }), jsx("div", { className: "m-0 p-0", children: sitemap.topItems?.map((item, i) => (jsx(RollupItem, { label: item?.text, children: jsx(LinkList, { documents: item.items }) }, String(i)))) }), jsx("div", { children: sitemap?.dispositions?.map(renderSubMenuItem) }), jsx(MobileAppTile, { title: "\u041C\u043E\u0431\u0438\u043B\u044C\u043D\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435", description: "\u0417\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0434\u043B\u044F IOS \u0438 Android", ...rest }), jsx(SearchBar, { className: "grow" }), jsx(SocialMedia, { className: "pb-4", media: socialMedia }), jsx(HorizontalNavigation, { title: horizontalNavigationTitle, links: relatedEnterprises }), jsx(TextInformation, { links: documents })] }));
1371
+ return (jsxs(BlockWrapper, { tag: "footer", className: `px-4 py-[26px] ${className}`, ...rest, children: [jsx(Contacts, { className: "overflow-hidden", items: contacts, hasButton: true }), jsx("div", { className: "m-0 p-0", children: sitemap.topItems?.map((item, i) => (jsx(RollupItem, { label: item?.text, children: jsx(LinkList, { documents: item.items }) }, String(i)))) }), jsx("div", { className: "mt-4", children: sitemap?.dispositions?.map(renderSubMenuItem) }), jsx(MobileAppTile, { title: "\u041C\u043E\u0431\u0438\u043B\u044C\u043D\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435", description: "\u0417\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0434\u043B\u044F IOS \u0438 Android", ...rest }), jsx(SearchBar, { className: "grow" }), jsx(SocialMedia, { className: "pb-4", media: socialMedia }), jsx(HorizontalNavigation, { title: horizontalNavigationTitle, links: relatedEnterprises }), jsx(TextInformation, { links: documents })] }));
1329
1372
  });
1330
1373
  const renderSubMenuItem = (menu, i) => {
1331
1374
  const { icon, href, text } = menu;
@@ -1371,7 +1414,7 @@
1371
1414
  }
1372
1415
 
1373
1416
  const REGION_URL = '/api/v1/region';
1374
- function useLocation(defaultLocation) {
1417
+ function useLocation(defaultLocation = 'Москва') {
1375
1418
  const currentLocation = getLocalStorageLocation();
1376
1419
  const [location, setLocation] = useState(currentLocation?.region ?? { name: defaultLocation });
1377
1420
  const { data } = useCachedAsyncData(REGION_URL, fetchJSONUnsafe);
@@ -1383,7 +1426,7 @@
1383
1426
  const onChangeLocation = useCallback((region) => {
1384
1427
  globalThis.localStorage?.setItem('location', JSON.stringify({ manual: true, region }));
1385
1428
  setLocation(region);
1386
- }, [setLocation]);
1429
+ }, []);
1387
1430
  return [location, onChangeLocation];
1388
1431
  }
1389
1432
  const getLocalStorageLocation = () => {
@@ -1423,6 +1466,8 @@
1423
1466
  return (jsxs(BlockWrapper, { tag: "header", version: version, ...rest, children: [jsxs("div", { className: "container px-4 py-0 box-border", children: [jsx(HeaderTop, { onClick: handleBurgerMenuShow, bgColor: bgColor, logo: logo }), jsx("nav", { className: "flex items-center m-0 p-0 overflow-y-hidden w-full h-12", children: jsx("div", { className: "flex no-scrollbar horizontal-list h-full items-center", children: subItems?.map((_, i) => (jsx(HeaderItem, { className: "mr-8 whitespace-nowrap text-s", active: _ === activeSubItem, ..._ }, String(i)))) }) })] }), burgerMenuShow ? (jsx(HeaderBurger, { onClick: handleBurgerMenuShow, burgerSubMenu: dispositions, defaultLocation: defaultLocation, children: jsx("div", { className: "list-none m-0 p-0", children: topItems?.map((item, i) => (jsx(RollupItem, { label: item.text, children: jsx(LinkList, { documents: item.items }) }, String(i)))) }) })) : null] }));
1424
1467
  });
1425
1468
 
1469
+ const Paragraph = JSX(({ children, ...style }) => (jsx("p", { className: ['font-sans', ...Object.values(style)].join(' '), children: children })));
1470
+
1426
1471
  const headlineVersionStyles = {
1427
1472
  XXL: {
1428
1473
  wrapper: 'gap-[18px]',
@@ -1614,10 +1659,6 @@
1614
1659
  return jsx("div", { className: "md-container", dangerouslySetInnerHTML: { __html } });
1615
1660
  });
1616
1661
 
1617
- function assertUnreachable(x) {
1618
- throw new Error(x);
1619
- }
1620
-
1621
1662
  const checkCanRenderIcon = (icon) => Boolean(icon?.icon || icon?.src);
1622
1663
 
1623
1664
  const STEPS_BLOCK_STYLE = {
@@ -1744,12 +1785,9 @@
1744
1785
  const innerPaddingStyle = isInnerPadding ? '' : '!p-0';
1745
1786
  return (jsx(BlockWrapper, { className: style('flex flex-col [&>*]:max-w-full', isPadding ? 'p-12' : '', gapStyles[gap], align && alignStyle[align], className), version: version, isTheme: isTheme, ...rest, children: renderChildren({ ...rest, options: { ...options, className: innerPaddingStyle } }) }));
1746
1787
  });
1747
- VerticalLayout.childrenTypes = {
1748
- exclude: ['Accordion', 'OtherProducts'],
1749
- };
1788
+ VerticalLayout.childrenTypes = [];
1750
1789
 
1751
1790
  const Blocks = {
1752
- Accordion,
1753
1791
  ComparisonTable,
1754
1792
  Footer,
1755
1793
  Header,
@@ -1758,11 +1796,11 @@
1758
1796
  LinkList,
1759
1797
  MobileAppTile,
1760
1798
  ProductBlock,
1761
- RollupItem,
1762
1799
  StepsBlock,
1763
1800
  TariffsTable,
1764
1801
  TextBlock,
1765
1802
  Placeholder,
1803
+ RollupItem,
1766
1804
  VerticalLayout,
1767
1805
  };
1768
1806
 
@@ -1865,7 +1903,6 @@
1865
1903
  const ContentPage = JSX((props) => {
1866
1904
  const { className = '', blocksRegistry, blockDecorator, data = {} } = props;
1867
1905
  const { style: pageStyle, blocks, slots, likeControl, colorPalette = 'pc' } = data;
1868
- const [overflowStyle, setOverflowStyle] = useState('');
1869
1906
  const options = {
1870
1907
  key: '',
1871
1908
  page: data,
@@ -1874,10 +1911,12 @@
1874
1911
  parent: data,
1875
1912
  };
1876
1913
  useBlockRouterProvider();
1877
- useEffect(() => defaultEventBus.subscribe('setPageOverflowHidden', (isHidden) => {
1878
- setOverflowStyle(isHidden ? 'overflow-hidden h-screen' : '');
1879
- }), []);
1880
- return (jsxs("section", { className: style('relative', pageStyle, className, overflowStyle), "data-theme": colorPalette, children: [slots?.header ? (jsx("div", { className: "mb-5 shadow-[0_8px_32px_0px_#00000014]", children: renderBlocksList(slots?.header, {
1914
+ const [isSomeDialogOpened, { setTrue: setSomeDialogOpened, setFalse: resetSomeDialogOpened }] = useBool();
1915
+ useDialogHandlers({
1916
+ onOpen: setSomeDialogOpened,
1917
+ onClose: resetSomeDialogOpened,
1918
+ });
1919
+ return (jsxs("section", { className: style('relative', pageStyle, className, isSomeDialogOpened ? 'overflow-hidden h-screen' : ''), "data-theme": colorPalette, children: [slots?.header ? (jsx("div", { className: "mb-5 shadow-[0_8px_32px_0px_#00000014]", children: renderBlocksList(slots?.header, {
1881
1920
  ...options,
1882
1921
  slotName: 'header',
1883
1922
  }) })) : null, jsxs("div", { className: "container grid grid-cols-12 gap-1", children: [renderBlocksList(blocks, options), slots?.footer
@@ -1897,7 +1936,7 @@
1897
1936
  return (list) => list.reduce((acc, el, i) => (acc.length ? acc.concat({ ...sep, key: i }, el) : [el]), []);
1898
1937
  }
1899
1938
 
1900
- const packageVersion = "0.9.2";
1939
+ const packageVersion = "0.9.4";
1901
1940
 
1902
1941
  exports.Blocks = Blocks;
1903
1942
  exports.ContentPage = ContentPage;