@redneckz/wildless-cms-uni-blocks 0.8.8 → 0.8.10

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 (404) hide show
  1. package/bin/migration-scripts/0.8.10.js +31 -0
  2. package/bundle/EventBus/EventBus.d.ts +1 -4
  3. package/bundle/EventBus/defaultEventBus.d.ts +7 -0
  4. package/bundle/blocks.schema.json +1 -1
  5. package/bundle/bundle.umd.js +112 -113
  6. package/bundle/bundle.umd.min.js +1 -1
  7. package/bundle/components/ButtonBlock/ButtonBlockContent.d.ts +5 -1
  8. package/bundle/components/Calculator/rangeHelpers.d.ts +4 -0
  9. package/bundle/components/StepsBlock/StepsBlockContent.d.ts +11 -1
  10. package/bundle/components/StepsBlock/checkCanRenderIcon.d.ts +2 -0
  11. package/{dist/components/StepsBlock/renderStepContent.d.ts → bundle/components/StepsBlock/renderStep.d.ts} +5 -5
  12. package/bundle/components/Tile/TileContent.d.ts +2 -2
  13. package/bundle/hooks/useRouter.d.ts +6 -2
  14. package/bundle/services/BlockRouter/BlockRouter.d.ts +3 -22
  15. package/bundle/services/BlockRouter/blockRouterEventBus.d.ts +11 -0
  16. package/bundle/services/BlockRouter/useBlockIntersectionObserver.d.ts +1 -2
  17. package/bundle/services/BlockRouter/useBlockRouterProvider.d.ts +1 -2
  18. package/dist/EventBus/EventBus.d.ts +1 -4
  19. package/dist/EventBus/EventBus.js +0 -1
  20. package/dist/EventBus/EventBus.js.map +1 -1
  21. package/dist/EventBus/defaultEventBus.d.ts +7 -0
  22. package/dist/EventBus/defaultEventBus.js +5 -0
  23. package/dist/EventBus/defaultEventBus.js.map +1 -0
  24. package/dist/components/ButtonBlock/ButtonBlock.js +2 -1
  25. package/dist/components/ButtonBlock/ButtonBlock.js.map +1 -1
  26. package/dist/components/ButtonBlock/ButtonBlockContent.d.ts +5 -1
  27. package/dist/components/Calculator/Rate.js +1 -1
  28. package/dist/components/Calculator/Rate.js.map +1 -1
  29. package/dist/components/Calculator/constants.js +2 -2
  30. package/dist/components/Calculator/constants.js.map +1 -1
  31. package/dist/components/Calculator/rangeHelpers.d.ts +4 -0
  32. package/dist/components/Calculator/rangeHelpers.js +12 -0
  33. package/dist/components/Calculator/rangeHelpers.js.map +1 -0
  34. package/dist/components/Calculator/useBusinessDepositCalculatorParams.js +10 -3
  35. package/dist/components/Calculator/useBusinessDepositCalculatorParams.js.map +1 -1
  36. package/dist/components/Calculator/useCreditCalculatorParams.js +8 -2
  37. package/dist/components/Calculator/useCreditCalculatorParams.js.map +1 -1
  38. package/dist/components/Calculator/useDepositCalculatorParams.js +14 -4
  39. package/dist/components/Calculator/useDepositCalculatorParams.js.map +1 -1
  40. package/dist/components/Carousel/Carousel.js +6 -4
  41. package/dist/components/Carousel/Carousel.js.map +1 -1
  42. package/dist/components/PictureText/renderBenefit.js +1 -0
  43. package/dist/components/PictureText/renderBenefit.js.map +1 -1
  44. package/dist/components/ProductTile/renderBenefit.js +1 -0
  45. package/dist/components/ProductTile/renderBenefit.js.map +1 -1
  46. package/dist/components/StepsBlock/StepsBlock.js +7 -13
  47. package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
  48. package/dist/components/StepsBlock/StepsBlock.mobile.js +24 -4
  49. package/dist/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
  50. package/dist/components/StepsBlock/StepsBlockContent.d.ts +11 -1
  51. package/dist/components/StepsBlock/checkCanRenderIcon.d.ts +2 -0
  52. package/dist/components/StepsBlock/checkCanRenderIcon.js +5 -0
  53. package/dist/components/StepsBlock/checkCanRenderIcon.js.map +1 -0
  54. package/{bundle/components/StepsBlock/renderStepContent.d.ts → dist/components/StepsBlock/renderStep.d.ts} +5 -5
  55. package/dist/components/StepsBlock/renderStep.js +34 -0
  56. package/dist/components/StepsBlock/renderStep.js.map +1 -0
  57. package/dist/components/Tabs/Tabs.js +4 -4
  58. package/dist/components/Tabs/Tabs.js.map +1 -1
  59. package/dist/components/Tile/Tile.js +3 -3
  60. package/dist/components/Tile/Tile.js.map +1 -1
  61. package/dist/components/Tile/TileContent.d.ts +2 -2
  62. package/dist/hooks/useLink.js +2 -3
  63. package/dist/hooks/useLink.js.map +1 -1
  64. package/dist/hooks/useRouter.d.ts +6 -2
  65. package/dist/hooks/useRouter.js.map +1 -1
  66. package/dist/services/BlockRouter/BlockRouter.d.ts +3 -22
  67. package/dist/services/BlockRouter/BlockRouter.js +11 -30
  68. package/dist/services/BlockRouter/BlockRouter.js.map +1 -1
  69. package/dist/services/BlockRouter/blockRouterEventBus.d.ts +11 -0
  70. package/dist/services/BlockRouter/blockRouterEventBus.js +5 -0
  71. package/dist/services/BlockRouter/blockRouterEventBus.js.map +1 -0
  72. package/dist/services/BlockRouter/useBlockIntersectionObserver.d.ts +1 -2
  73. package/dist/services/BlockRouter/useBlockIntersectionObserver.js +5 -16
  74. package/dist/services/BlockRouter/useBlockIntersectionObserver.js.map +1 -1
  75. package/dist/services/BlockRouter/useBlockRouterProvider.d.ts +1 -2
  76. package/dist/services/BlockRouter/useBlockRouterProvider.js +11 -12
  77. package/dist/services/BlockRouter/useBlockRouterProvider.js.map +1 -1
  78. package/dist/ui-kit/BlockWrapper.js +2 -2
  79. package/dist/ui-kit/BlockWrapper.js.map +1 -1
  80. package/lib/EventBus/EventBus.d.ts +1 -4
  81. package/lib/EventBus/EventBus.js +0 -1
  82. package/lib/EventBus/EventBus.js.map +1 -1
  83. package/lib/EventBus/defaultEventBus.d.ts +7 -0
  84. package/lib/EventBus/defaultEventBus.js +3 -0
  85. package/lib/EventBus/defaultEventBus.js.map +1 -0
  86. package/lib/common.css +1 -1
  87. package/lib/components/ButtonBlock/ButtonBlock.js +2 -1
  88. package/lib/components/ButtonBlock/ButtonBlock.js.map +1 -1
  89. package/lib/components/ButtonBlock/ButtonBlockContent.d.ts +5 -1
  90. package/lib/components/Calculator/Rate.js +1 -1
  91. package/lib/components/Calculator/Rate.js.map +1 -1
  92. package/lib/components/Calculator/constants.js +2 -2
  93. package/lib/components/Calculator/constants.js.map +1 -1
  94. package/lib/components/Calculator/rangeHelpers.d.ts +4 -0
  95. package/lib/components/Calculator/rangeHelpers.js +8 -0
  96. package/lib/components/Calculator/rangeHelpers.js.map +1 -0
  97. package/lib/components/Calculator/useBusinessDepositCalculatorParams.js +10 -3
  98. package/lib/components/Calculator/useBusinessDepositCalculatorParams.js.map +1 -1
  99. package/lib/components/Calculator/useCreditCalculatorParams.js +8 -2
  100. package/lib/components/Calculator/useCreditCalculatorParams.js.map +1 -1
  101. package/lib/components/Calculator/useDepositCalculatorParams.js +14 -4
  102. package/lib/components/Calculator/useDepositCalculatorParams.js.map +1 -1
  103. package/lib/components/Carousel/Carousel.js +6 -4
  104. package/lib/components/Carousel/Carousel.js.map +1 -1
  105. package/lib/components/PictureText/renderBenefit.js +1 -0
  106. package/lib/components/PictureText/renderBenefit.js.map +1 -1
  107. package/lib/components/ProductTile/renderBenefit.js +1 -0
  108. package/lib/components/ProductTile/renderBenefit.js.map +1 -1
  109. package/lib/components/StepsBlock/StepsBlock.js +7 -13
  110. package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
  111. package/lib/components/StepsBlock/StepsBlock.mobile.js +24 -4
  112. package/lib/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
  113. package/lib/components/StepsBlock/StepsBlockContent.d.ts +11 -1
  114. package/lib/components/StepsBlock/checkCanRenderIcon.d.ts +2 -0
  115. package/lib/components/StepsBlock/checkCanRenderIcon.js +2 -0
  116. package/lib/components/StepsBlock/checkCanRenderIcon.js.map +1 -0
  117. package/{mobile/bundle/components/StepsBlock/renderStepContent.d.ts → lib/components/StepsBlock/renderStep.d.ts} +5 -5
  118. package/lib/components/StepsBlock/renderStep.js +31 -0
  119. package/lib/components/StepsBlock/renderStep.js.map +1 -0
  120. package/lib/components/Tabs/Tabs.js +4 -4
  121. package/lib/components/Tabs/Tabs.js.map +1 -1
  122. package/lib/components/Tile/Tile.js +3 -3
  123. package/lib/components/Tile/Tile.js.map +1 -1
  124. package/lib/components/Tile/TileContent.d.ts +2 -2
  125. package/lib/hooks/useLink.js +2 -3
  126. package/lib/hooks/useLink.js.map +1 -1
  127. package/lib/hooks/useRouter.d.ts +6 -2
  128. package/lib/hooks/useRouter.js.map +1 -1
  129. package/lib/services/BlockRouter/BlockRouter.d.ts +3 -22
  130. package/lib/services/BlockRouter/BlockRouter.js +8 -28
  131. package/lib/services/BlockRouter/BlockRouter.js.map +1 -1
  132. package/lib/services/BlockRouter/blockRouterEventBus.d.ts +11 -0
  133. package/lib/services/BlockRouter/blockRouterEventBus.js +3 -0
  134. package/lib/services/BlockRouter/blockRouterEventBus.js.map +1 -0
  135. package/lib/services/BlockRouter/useBlockIntersectionObserver.d.ts +1 -2
  136. package/lib/services/BlockRouter/useBlockIntersectionObserver.js +6 -17
  137. package/lib/services/BlockRouter/useBlockIntersectionObserver.js.map +1 -1
  138. package/lib/services/BlockRouter/useBlockRouterProvider.d.ts +1 -2
  139. package/lib/services/BlockRouter/useBlockRouterProvider.js +12 -13
  140. package/lib/services/BlockRouter/useBlockRouterProvider.js.map +1 -1
  141. package/lib/ui-kit/BlockWrapper.js +2 -2
  142. package/lib/ui-kit/BlockWrapper.js.map +1 -1
  143. package/mobile/bundle/EventBus/EventBus.d.ts +1 -4
  144. package/mobile/bundle/EventBus/defaultEventBus.d.ts +7 -0
  145. package/mobile/bundle/bundle.umd.js +58 -66
  146. package/mobile/bundle/bundle.umd.min.js +1 -1
  147. package/mobile/bundle/components/ButtonBlock/ButtonBlockContent.d.ts +5 -1
  148. package/mobile/bundle/components/Calculator/rangeHelpers.d.ts +4 -0
  149. package/mobile/bundle/components/StepsBlock/StepsBlockContent.d.ts +11 -1
  150. package/mobile/bundle/components/StepsBlock/checkCanRenderIcon.d.ts +2 -0
  151. package/{lib/components/StepsBlock/renderStepContent.d.ts → mobile/bundle/components/StepsBlock/renderStep.d.ts} +5 -5
  152. package/mobile/bundle/components/Tile/TileContent.d.ts +2 -2
  153. package/mobile/bundle/hooks/useRouter.d.ts +6 -2
  154. package/mobile/bundle/services/BlockRouter/BlockRouter.d.ts +3 -22
  155. package/mobile/bundle/services/BlockRouter/blockRouterEventBus.d.ts +11 -0
  156. package/mobile/bundle/services/BlockRouter/useBlockIntersectionObserver.d.ts +1 -2
  157. package/mobile/bundle/services/BlockRouter/useBlockRouterProvider.d.ts +1 -2
  158. package/mobile/dist/EventBus/EventBus.d.ts +1 -4
  159. package/mobile/dist/EventBus/EventBus.js +0 -1
  160. package/mobile/dist/EventBus/EventBus.js.map +1 -1
  161. package/mobile/dist/EventBus/defaultEventBus.d.ts +7 -0
  162. package/mobile/dist/EventBus/defaultEventBus.js +5 -0
  163. package/mobile/dist/EventBus/defaultEventBus.js.map +1 -0
  164. package/mobile/dist/components/ButtonBlock/ButtonBlock.js +2 -1
  165. package/mobile/dist/components/ButtonBlock/ButtonBlock.js.map +1 -1
  166. package/mobile/dist/components/ButtonBlock/ButtonBlockContent.d.ts +5 -1
  167. package/mobile/dist/components/Calculator/Rate.js +1 -1
  168. package/mobile/dist/components/Calculator/Rate.js.map +1 -1
  169. package/mobile/dist/components/Calculator/constants.js +2 -2
  170. package/mobile/dist/components/Calculator/constants.js.map +1 -1
  171. package/mobile/dist/components/Calculator/rangeHelpers.d.ts +4 -0
  172. package/mobile/dist/components/Calculator/rangeHelpers.js +12 -0
  173. package/mobile/dist/components/Calculator/rangeHelpers.js.map +1 -0
  174. package/mobile/dist/components/Calculator/useBusinessDepositCalculatorParams.js +10 -3
  175. package/mobile/dist/components/Calculator/useBusinessDepositCalculatorParams.js.map +1 -1
  176. package/mobile/dist/components/Calculator/useCreditCalculatorParams.js +8 -2
  177. package/mobile/dist/components/Calculator/useCreditCalculatorParams.js.map +1 -1
  178. package/mobile/dist/components/Calculator/useDepositCalculatorParams.js +14 -4
  179. package/mobile/dist/components/Calculator/useDepositCalculatorParams.js.map +1 -1
  180. package/mobile/dist/components/Carousel/Carousel.js +6 -4
  181. package/mobile/dist/components/Carousel/Carousel.js.map +1 -1
  182. package/mobile/dist/components/PictureText/renderBenefit.js +1 -0
  183. package/mobile/dist/components/PictureText/renderBenefit.js.map +1 -1
  184. package/mobile/dist/components/ProductTile/renderBenefit.js +1 -0
  185. package/mobile/dist/components/ProductTile/renderBenefit.js.map +1 -1
  186. package/mobile/dist/components/StepsBlock/StepsBlock.js +24 -4
  187. package/mobile/dist/components/StepsBlock/StepsBlock.js.map +1 -1
  188. package/mobile/dist/components/StepsBlock/StepsBlockContent.d.ts +11 -1
  189. package/mobile/dist/components/StepsBlock/checkCanRenderIcon.d.ts +2 -0
  190. package/mobile/dist/components/StepsBlock/checkCanRenderIcon.js +5 -0
  191. package/mobile/dist/components/StepsBlock/checkCanRenderIcon.js.map +1 -0
  192. package/mobile/dist/components/StepsBlock/renderStep.d.ts +11 -0
  193. package/mobile/dist/components/StepsBlock/renderStep.js +34 -0
  194. package/mobile/dist/components/StepsBlock/renderStep.js.map +1 -0
  195. package/mobile/dist/components/Tabs/Tabs.js +4 -4
  196. package/mobile/dist/components/Tabs/Tabs.js.map +1 -1
  197. package/mobile/dist/components/Tile/Tile.js +3 -3
  198. package/mobile/dist/components/Tile/Tile.js.map +1 -1
  199. package/mobile/dist/components/Tile/TileContent.d.ts +2 -2
  200. package/mobile/dist/hooks/useLink.js +2 -3
  201. package/mobile/dist/hooks/useLink.js.map +1 -1
  202. package/mobile/dist/hooks/useRouter.d.ts +6 -2
  203. package/mobile/dist/hooks/useRouter.js.map +1 -1
  204. package/mobile/dist/services/BlockRouter/BlockRouter.d.ts +3 -22
  205. package/mobile/dist/services/BlockRouter/BlockRouter.js +11 -30
  206. package/mobile/dist/services/BlockRouter/BlockRouter.js.map +1 -1
  207. package/mobile/dist/services/BlockRouter/blockRouterEventBus.d.ts +11 -0
  208. package/mobile/dist/services/BlockRouter/blockRouterEventBus.js +5 -0
  209. package/mobile/dist/services/BlockRouter/blockRouterEventBus.js.map +1 -0
  210. package/mobile/dist/services/BlockRouter/useBlockIntersectionObserver.d.ts +1 -2
  211. package/mobile/dist/services/BlockRouter/useBlockIntersectionObserver.js +5 -16
  212. package/mobile/dist/services/BlockRouter/useBlockIntersectionObserver.js.map +1 -1
  213. package/mobile/dist/services/BlockRouter/useBlockRouterProvider.d.ts +1 -2
  214. package/mobile/dist/services/BlockRouter/useBlockRouterProvider.js +11 -12
  215. package/mobile/dist/services/BlockRouter/useBlockRouterProvider.js.map +1 -1
  216. package/mobile/dist/ui-kit/BlockWrapper.js +2 -2
  217. package/mobile/dist/ui-kit/BlockWrapper.js.map +1 -1
  218. package/mobile/lib/EventBus/EventBus.d.ts +1 -4
  219. package/mobile/lib/EventBus/EventBus.js +0 -1
  220. package/mobile/lib/EventBus/EventBus.js.map +1 -1
  221. package/mobile/lib/EventBus/defaultEventBus.d.ts +7 -0
  222. package/mobile/lib/EventBus/defaultEventBus.js +3 -0
  223. package/mobile/lib/EventBus/defaultEventBus.js.map +1 -0
  224. package/mobile/lib/components/ButtonBlock/ButtonBlock.js +2 -1
  225. package/mobile/lib/components/ButtonBlock/ButtonBlock.js.map +1 -1
  226. package/mobile/lib/components/ButtonBlock/ButtonBlockContent.d.ts +5 -1
  227. package/mobile/lib/components/Calculator/Rate.js +1 -1
  228. package/mobile/lib/components/Calculator/Rate.js.map +1 -1
  229. package/mobile/lib/components/Calculator/constants.js +2 -2
  230. package/mobile/lib/components/Calculator/constants.js.map +1 -1
  231. package/mobile/lib/components/Calculator/rangeHelpers.d.ts +4 -0
  232. package/mobile/lib/components/Calculator/rangeHelpers.js +8 -0
  233. package/mobile/lib/components/Calculator/rangeHelpers.js.map +1 -0
  234. package/mobile/lib/components/Calculator/useBusinessDepositCalculatorParams.js +10 -3
  235. package/mobile/lib/components/Calculator/useBusinessDepositCalculatorParams.js.map +1 -1
  236. package/mobile/lib/components/Calculator/useCreditCalculatorParams.js +8 -2
  237. package/mobile/lib/components/Calculator/useCreditCalculatorParams.js.map +1 -1
  238. package/mobile/lib/components/Calculator/useDepositCalculatorParams.js +14 -4
  239. package/mobile/lib/components/Calculator/useDepositCalculatorParams.js.map +1 -1
  240. package/mobile/lib/components/Carousel/Carousel.js +6 -4
  241. package/mobile/lib/components/Carousel/Carousel.js.map +1 -1
  242. package/mobile/lib/components/PictureText/renderBenefit.js +1 -0
  243. package/mobile/lib/components/PictureText/renderBenefit.js.map +1 -1
  244. package/mobile/lib/components/ProductTile/renderBenefit.js +1 -0
  245. package/mobile/lib/components/ProductTile/renderBenefit.js.map +1 -1
  246. package/mobile/lib/components/StepsBlock/StepsBlock.js +24 -4
  247. package/mobile/lib/components/StepsBlock/StepsBlock.js.map +1 -1
  248. package/mobile/lib/components/StepsBlock/StepsBlockContent.d.ts +11 -1
  249. package/mobile/lib/components/StepsBlock/checkCanRenderIcon.d.ts +2 -0
  250. package/mobile/lib/components/StepsBlock/checkCanRenderIcon.js +2 -0
  251. package/mobile/lib/components/StepsBlock/checkCanRenderIcon.js.map +1 -0
  252. package/mobile/lib/components/StepsBlock/renderStep.d.ts +11 -0
  253. package/mobile/lib/components/StepsBlock/renderStep.js +31 -0
  254. package/mobile/lib/components/StepsBlock/renderStep.js.map +1 -0
  255. package/mobile/lib/components/Tabs/Tabs.js +4 -4
  256. package/mobile/lib/components/Tabs/Tabs.js.map +1 -1
  257. package/mobile/lib/components/Tile/Tile.js +3 -3
  258. package/mobile/lib/components/Tile/Tile.js.map +1 -1
  259. package/mobile/lib/components/Tile/TileContent.d.ts +2 -2
  260. package/mobile/lib/hooks/useLink.js +2 -3
  261. package/mobile/lib/hooks/useLink.js.map +1 -1
  262. package/mobile/lib/hooks/useRouter.d.ts +6 -2
  263. package/mobile/lib/hooks/useRouter.js.map +1 -1
  264. package/mobile/lib/services/BlockRouter/BlockRouter.d.ts +3 -22
  265. package/mobile/lib/services/BlockRouter/BlockRouter.js +8 -28
  266. package/mobile/lib/services/BlockRouter/BlockRouter.js.map +1 -1
  267. package/mobile/lib/services/BlockRouter/blockRouterEventBus.d.ts +11 -0
  268. package/mobile/lib/services/BlockRouter/blockRouterEventBus.js +3 -0
  269. package/mobile/lib/services/BlockRouter/blockRouterEventBus.js.map +1 -0
  270. package/mobile/lib/services/BlockRouter/useBlockIntersectionObserver.d.ts +1 -2
  271. package/mobile/lib/services/BlockRouter/useBlockIntersectionObserver.js +6 -17
  272. package/mobile/lib/services/BlockRouter/useBlockIntersectionObserver.js.map +1 -1
  273. package/mobile/lib/services/BlockRouter/useBlockRouterProvider.d.ts +1 -2
  274. package/mobile/lib/services/BlockRouter/useBlockRouterProvider.js +12 -13
  275. package/mobile/lib/services/BlockRouter/useBlockRouterProvider.js.map +1 -1
  276. package/mobile/lib/ui-kit/BlockWrapper.js +2 -2
  277. package/mobile/lib/ui-kit/BlockWrapper.js.map +1 -1
  278. package/mobile/src/EventBus/EventBus.ts +1 -7
  279. package/mobile/src/EventBus/defaultEventBus.ts +8 -0
  280. package/mobile/src/components/ButtonBlock/ButtonBlock.example.json +2 -2
  281. package/mobile/src/components/ButtonBlock/ButtonBlock.tsx +5 -2
  282. package/mobile/src/components/ButtonBlock/ButtonBlockContent.ts +5 -1
  283. package/mobile/src/components/Calculator/Rate.tsx +1 -1
  284. package/mobile/src/components/Calculator/constants.ts +2 -2
  285. package/mobile/src/components/Calculator/rangeHelpers.ts +24 -0
  286. package/mobile/src/components/Calculator/useBusinessDepositCalculatorParams.ts +15 -3
  287. package/mobile/src/components/Calculator/useCreditCalculatorParams.ts +8 -2
  288. package/mobile/src/components/Calculator/useDepositCalculatorParams.ts +18 -4
  289. package/mobile/src/components/Carousel/Carousel.tsx +6 -4
  290. package/mobile/src/components/PictureText/renderBenefit.tsx +1 -0
  291. package/mobile/src/components/ProductTile/renderBenefit.tsx +1 -0
  292. package/mobile/src/components/StepsBlock/StepsBlock.tsx +29 -5
  293. package/mobile/src/components/StepsBlock/StepsBlock.ui.json +6 -0
  294. package/mobile/src/components/StepsBlock/StepsBlockContent.ts +13 -1
  295. package/mobile/src/components/StepsBlock/checkCanRenderIcon.ts +3 -0
  296. package/mobile/src/components/StepsBlock/renderStep.tsx +83 -0
  297. package/mobile/src/components/Tabs/Tabs.tsx +4 -4
  298. package/mobile/src/components/Tile/Tile.example.json +1 -1
  299. package/mobile/src/components/Tile/Tile.tsx +4 -4
  300. package/mobile/src/components/Tile/Tile.ui.json +7 -1
  301. package/mobile/src/components/Tile/TileContent.ts +2 -2
  302. package/mobile/src/hooks/useLink.ts +2 -3
  303. package/mobile/src/hooks/useRouter.ts +6 -2
  304. package/mobile/src/services/BlockRouter/BlockRouter.ts +8 -47
  305. package/mobile/src/services/BlockRouter/blockRouterEventBus.ts +13 -0
  306. package/mobile/src/services/BlockRouter/useBlockIntersectionObserver.ts +6 -23
  307. package/mobile/src/services/BlockRouter/useBlockRouterProvider.ts +13 -19
  308. package/mobile/src/ui-kit/BlockWrapper.tsx +2 -2
  309. package/package.json +1 -1
  310. package/src/EventBus/EventBus.ts +1 -7
  311. package/src/EventBus/defaultEventBus.ts +8 -0
  312. package/src/components/ButtonBlock/ButtonBlock.example.json +2 -2
  313. package/src/components/ButtonBlock/ButtonBlock.tsx +5 -2
  314. package/src/components/ButtonBlock/ButtonBlockContent.ts +5 -1
  315. package/src/components/Calculator/Rate.tsx +1 -1
  316. package/src/components/Calculator/constants.ts +2 -2
  317. package/src/components/Calculator/rangeHelpers.ts +24 -0
  318. package/src/components/Calculator/useBusinessDepositCalculatorParams.ts +15 -3
  319. package/src/components/Calculator/useCreditCalculatorParams.ts +8 -2
  320. package/src/components/Calculator/useDepositCalculatorParams.ts +18 -4
  321. package/src/components/Carousel/Carousel.tsx +6 -4
  322. package/src/components/PictureText/renderBenefit.tsx +1 -0
  323. package/src/components/ProductTile/renderBenefit.tsx +1 -0
  324. package/src/components/StepsBlock/StepsBlock.fixture.mobile.tsx +19 -1
  325. package/src/components/StepsBlock/StepsBlock.fixture.tsx +10 -3
  326. package/src/components/StepsBlock/StepsBlock.mobile.tsx +29 -5
  327. package/src/components/StepsBlock/StepsBlock.tsx +28 -16
  328. package/src/components/StepsBlock/StepsBlock.ui.json +6 -0
  329. package/src/components/StepsBlock/StepsBlockContent.ts +13 -1
  330. package/src/components/StepsBlock/checkCanRenderIcon.ts +3 -0
  331. package/src/components/StepsBlock/renderStep.tsx +83 -0
  332. package/src/components/Tabs/Tabs.tsx +4 -4
  333. package/src/components/Tile/Tile.example.json +1 -1
  334. package/src/components/Tile/Tile.fixture.tsx +2 -2
  335. package/src/components/Tile/Tile.tsx +4 -4
  336. package/src/components/Tile/Tile.ui.json +7 -1
  337. package/src/components/Tile/TileContent.ts +2 -2
  338. package/src/hooks/useLink.ts +2 -3
  339. package/src/hooks/useRouter.ts +6 -2
  340. package/src/services/BlockRouter/BlockRouter.ts +8 -47
  341. package/src/services/BlockRouter/blockRouterEventBus.ts +13 -0
  342. package/src/services/BlockRouter/useBlockIntersectionObserver.ts +6 -23
  343. package/src/services/BlockRouter/useBlockRouterProvider.ts +13 -19
  344. package/src/ui-kit/BlockWrapper.tsx +2 -2
  345. package/bundle/EventBus/EventMap.d.ts +0 -4
  346. package/bundle/services/BlockRouter/useBlockRouter.d.ts +0 -2
  347. package/bundle/utils/checkIsIconRenderable.d.ts +0 -2
  348. package/dist/EventBus/EventMap.d.ts +0 -4
  349. package/dist/EventBus/EventMap.js +0 -2
  350. package/dist/EventBus/EventMap.js.map +0 -1
  351. package/dist/components/StepsBlock/renderStepContent.js +0 -19
  352. package/dist/components/StepsBlock/renderStepContent.js.map +0 -1
  353. package/dist/services/BlockRouter/useBlockRouter.d.ts +0 -2
  354. package/dist/services/BlockRouter/useBlockRouter.js +0 -8
  355. package/dist/services/BlockRouter/useBlockRouter.js.map +0 -1
  356. package/dist/utils/checkIsIconRenderable.d.ts +0 -2
  357. package/dist/utils/checkIsIconRenderable.js +0 -5
  358. package/dist/utils/checkIsIconRenderable.js.map +0 -1
  359. package/lib/EventBus/EventMap.d.ts +0 -4
  360. package/lib/EventBus/EventMap.js +0 -2
  361. package/lib/EventBus/EventMap.js.map +0 -1
  362. package/lib/components/StepsBlock/renderStepContent.js +0 -16
  363. package/lib/components/StepsBlock/renderStepContent.js.map +0 -1
  364. package/lib/services/BlockRouter/useBlockRouter.d.ts +0 -2
  365. package/lib/services/BlockRouter/useBlockRouter.js +0 -5
  366. package/lib/services/BlockRouter/useBlockRouter.js.map +0 -1
  367. package/lib/utils/checkIsIconRenderable.d.ts +0 -2
  368. package/lib/utils/checkIsIconRenderable.js +0 -2
  369. package/lib/utils/checkIsIconRenderable.js.map +0 -1
  370. package/mobile/bundle/EventBus/EventMap.d.ts +0 -4
  371. package/mobile/bundle/services/BlockRouter/useBlockRouter.d.ts +0 -2
  372. package/mobile/bundle/utils/checkIsIconRenderable.d.ts +0 -2
  373. package/mobile/dist/EventBus/EventMap.d.ts +0 -4
  374. package/mobile/dist/EventBus/EventMap.js +0 -2
  375. package/mobile/dist/EventBus/EventMap.js.map +0 -1
  376. package/mobile/dist/components/StepsBlock/renderStepContent.d.ts +0 -11
  377. package/mobile/dist/components/StepsBlock/renderStepContent.js +0 -19
  378. package/mobile/dist/components/StepsBlock/renderStepContent.js.map +0 -1
  379. package/mobile/dist/services/BlockRouter/useBlockRouter.d.ts +0 -2
  380. package/mobile/dist/services/BlockRouter/useBlockRouter.js +0 -8
  381. package/mobile/dist/services/BlockRouter/useBlockRouter.js.map +0 -1
  382. package/mobile/dist/utils/checkIsIconRenderable.d.ts +0 -2
  383. package/mobile/dist/utils/checkIsIconRenderable.js +0 -5
  384. package/mobile/dist/utils/checkIsIconRenderable.js.map +0 -1
  385. package/mobile/lib/EventBus/EventMap.d.ts +0 -4
  386. package/mobile/lib/EventBus/EventMap.js +0 -2
  387. package/mobile/lib/EventBus/EventMap.js.map +0 -1
  388. package/mobile/lib/components/StepsBlock/renderStepContent.d.ts +0 -11
  389. package/mobile/lib/components/StepsBlock/renderStepContent.js +0 -16
  390. package/mobile/lib/components/StepsBlock/renderStepContent.js.map +0 -1
  391. package/mobile/lib/services/BlockRouter/useBlockRouter.d.ts +0 -2
  392. package/mobile/lib/services/BlockRouter/useBlockRouter.js +0 -5
  393. package/mobile/lib/services/BlockRouter/useBlockRouter.js.map +0 -1
  394. package/mobile/lib/utils/checkIsIconRenderable.d.ts +0 -2
  395. package/mobile/lib/utils/checkIsIconRenderable.js +0 -2
  396. package/mobile/lib/utils/checkIsIconRenderable.js.map +0 -1
  397. package/mobile/src/EventBus/EventMap.ts +0 -5
  398. package/mobile/src/components/StepsBlock/renderStepContent.tsx +0 -83
  399. package/mobile/src/services/BlockRouter/useBlockRouter.ts +0 -5
  400. package/mobile/src/utils/checkIsIconRenderable.tsx +0 -3
  401. package/src/EventBus/EventMap.ts +0 -5
  402. package/src/components/StepsBlock/renderStepContent.tsx +0 -83
  403. package/src/services/BlockRouter/useBlockRouter.ts +0 -5
  404. package/src/utils/checkIsIconRenderable.tsx +0 -3
@@ -3,6 +3,10 @@ import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
3
3
  * @title Блок Кнопка
4
4
  */
5
5
  export interface ButtonBlockContent {
6
- /** @title Кнопка */
6
+ /**
7
+ * @title Кнопка
8
+ * @default {"icon": {"format": "webp", "size": { "width": 24, "height": 24 }},
9
+ * "iconRight": {"format": "webp", "size": { "width": 24, "height": 24 }}}
10
+ */
7
11
  button?: ButtonWithIconProps;
8
12
  }
@@ -0,0 +1,4 @@
1
+ export declare const getRangeByKeys: <MinKey extends string, MaxKey extends string, T extends Record<MinKey | MaxKey, number>>([minKey, maxKey]: [MinKey, MaxKey], rows?: T[]) => {
2
+ [x: string]: unknown;
3
+ };
4
+ export declare const checkRangeByKeys: <MinKey extends string, MaxKey extends string, T extends Record<MinKey | MaxKey, number>>(value: number, [minKey, maxKey]: [MinKey, MaxKey], sourceBookRow: T) => boolean;
@@ -1,6 +1,8 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, HeadlineCommonProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { IconProps } from '../../model/Picture';
5
+ import type { RichTextItem } from '../../model/RichTextItem';
4
6
  import type { SizeVersion } from '../../model/SizeVersion';
5
7
  import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
6
8
  declare type StepCommonProps = IconProps & {
@@ -14,10 +16,18 @@ declare type StepCommonProps = IconProps & {
14
16
  /** @title Список */
15
17
  items?: string[];
16
18
  };
19
+ /**
20
+ * @title Стандартный
21
+ */
22
+ export declare type DefaultStep = DescriptionProps & LabelProps & StepCommonProps & DefaultListItemType;
23
+ /**
24
+ * @title Форматированный текст
25
+ */
26
+ declare type RichTextStep = RichTextItem & IconProps;
17
27
  /**
18
28
  * @title Шаг
19
29
  */
20
- export declare type Step = DescriptionProps & LabelProps & StepCommonProps;
30
+ export declare type Step = DefaultStep | RichTextStep;
21
31
  /**
22
32
  * @title Блок шаги
23
33
  */
@@ -0,0 +1,2 @@
1
+ import type { Picture } from '../../model/Picture';
2
+ export declare const checkCanRenderIcon: (icon?: Picture) => boolean;
@@ -2,10 +2,10 @@ import type { BlockVersion } from '../../model/BlockVersion';
2
2
  import type { VNode } from '../../model/VNode';
3
3
  import type { Step } from './StepsBlockContent';
4
4
  import type { StyleType } from './StepsBlockStyleMaps';
5
- export declare const renderStepContent: ({ styleMap, isMainButton, version, }: {
5
+ interface RenderStepProps {
6
6
  styleMap: StyleType;
7
7
  isMainButton: boolean;
8
- version?: BlockVersion | undefined;
9
- }) => (step: Step, i: number, { length }: {
10
- length: number;
11
- }) => VNode;
8
+ version?: BlockVersion;
9
+ }
10
+ export declare const renderStep: (props: RenderStepProps) => (step: Step, i: number, arr: Step[]) => VNode;
11
+ export {};
@@ -1,15 +1,15 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
- import type { DescriptionProps } from '../../model/HeadlineType';
3
2
  import type { Picture } from '../../model/Picture';
4
3
  import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
5
4
  import type { HeadingCommonProps } from '../../ui-kit/Heading/HeadingProps';
6
5
  import type { ListContent } from '../../ui-kit/List/ListContent';
7
6
  import type { ListItemSize } from '../../ui-kit/List/ListProps';
7
+ import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
8
8
  import type { TagsContent } from '../../ui-kit/Tags/TagsContent';
9
9
  /**
10
10
  * @title Плитка
11
11
  */
12
- export declare type TileContent = HeadingCommonProps & DescriptionProps & ListContent & ButtonContent & TagsContent & {
12
+ export declare type TileContent = HeadingCommonProps & RichTextProps & ListContent & ButtonContent & TagsContent & {
13
13
  /**
14
14
  * @default {
15
15
  * "format": "webp",
@@ -1,13 +1,17 @@
1
+ interface RouterOptions {
2
+ scroll?: boolean;
3
+ }
1
4
  export interface Router {
2
5
  pathname: string;
3
6
  query: Record<string, string | string[] | undefined>;
4
7
  href?: string;
5
8
  basePath?: string;
6
- push: (url: string) => void;
7
- replace: (url: string) => void;
9
+ push: (url: string, as?: string, options?: RouterOptions) => void;
10
+ replace: (url: string, as?: string, options?: RouterOptions) => void;
8
11
  }
9
12
  export declare function useRouter(): Router;
10
13
  export declare namespace useRouter {
11
14
  var _impl: () => Router;
12
15
  var setup: (impl: () => Router) => void;
13
16
  }
17
+ export {};
@@ -1,23 +1,4 @@
1
- import { EventBus } from '../../EventBus/EventBus';
1
+ import type { Router } from '../../hooks/useRouter';
2
2
  import type { BlockDef } from '../../model/ContentPageDef';
3
- export interface GotoAnchorEvent {
4
- anchor: string;
5
- }
6
- export interface BlockIntersectionEvent {
7
- block: BlockDef;
8
- intersection: IntersectionObserverEntry;
9
- }
10
- interface EventMap {
11
- goto: GotoAnchorEvent;
12
- intersection: BlockIntersectionEvent;
13
- }
14
- export declare class BlockRouter {
15
- static readonly inst: BlockRouter;
16
- readonly eventBus: EventBus<EventMap>;
17
- constructor();
18
- goto(rawAnchor?: string): void;
19
- push(rawAnchor: string): void;
20
- replace(rawAnchor: string): void;
21
- reset(): void;
22
- }
23
- export {};
3
+ export declare function gotoBlock(router: Router, anchor?: string): void;
4
+ export declare function trackBlock(router: Router, block?: BlockDef): void;
@@ -0,0 +1,11 @@
1
+ import { EventBus } from '../../EventBus/EventBus';
2
+ import type { BlockDef } from '../../model/ContentPageDef';
3
+ export interface BlockIntersectionEvent {
4
+ block: BlockDef;
5
+ intersection: IntersectionObserverEntry;
6
+ }
7
+ interface EventMap {
8
+ intersection: BlockIntersectionEvent;
9
+ }
10
+ export declare const blockRouterEventBus: EventBus<EventMap>;
11
+ export {};
@@ -1,5 +1,4 @@
1
1
  import type { BlockDef } from '../../model/ContentPageDef';
2
- import { BlockRouter } from './BlockRouter';
3
- export declare function useBlockIntersectionObserver(block?: BlockDef, router?: BlockRouter): {
2
+ export declare function useBlockIntersectionObserver(block?: BlockDef): {
4
3
  current: Element | null;
5
4
  };
@@ -1,2 +1 @@
1
- import { BlockRouter } from './BlockRouter';
2
- export declare function useBlockRouterProvider(router?: BlockRouter, scrollTarget?: EventTarget): void;
1
+ export declare function useBlockRouterProvider(scrollTarget?: EventTarget): void;
@@ -1,7 +1,4 @@
1
- import type { EventMap } from './EventMap';
2
- export declare type BaseEventMap = Record<string, any>;
3
- export declare class EventBus<EM extends BaseEventMap> {
4
- static readonly inst: EventBus<EventMap>;
1
+ export declare class EventBus<EM extends Record<string, any>> {
5
2
  private subscribers;
6
3
  private subjectsStateMap;
7
4
  subscribe<K extends keyof EM>(type: K, listener: (event: EM[K]) => void): () => void;
@@ -1,7 +1,6 @@
1
1
  Object.defineProperty(exports, "__esModule", { value: true });
2
2
  exports.EventBus = void 0;
3
3
  class EventBus {
4
- static inst = new EventBus();
5
4
  subscribers = {};
6
5
  subjectsStateMap = {};
7
6
  subscribe(type, listener) {
@@ -1 +1 @@
1
- {"version":3,"file":"EventBus.js","sourceRoot":"","sources":["../../src/EventBus/EventBus.ts"],"names":[],"mappings":";;AAIA,MAAa,QAAQ;IACZ,MAAM,CAAU,IAAI,GAAG,IAAI,QAAQ,EAAY,CAAC;IAE/C,WAAW,GAAiE,EAAE,CAAC;IAC/E,gBAAgB,GAAgB,EAAE,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 import { EventBus } from './EventBus';
3
+ interface GlobalEventMap {
4
+ tab: TabActivationEvent;
5
+ }
6
+ export declare const defaultEventBus: EventBus<GlobalEventMap>;
7
+ export {};
@@ -0,0 +1,5 @@
1
+ Object.defineProperty(exports, "__esModule", { value: true });
2
+ exports.defaultEventBus = void 0;
3
+ const EventBus_1 = require("./EventBus");
4
+ exports.defaultEventBus = new EventBus_1.EventBus();
5
+ //# sourceMappingURL=defaultEventBus.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"defaultEventBus.js","sourceRoot":"","sources":["../../src/EventBus/defaultEventBus.ts"],"names":[],"mappings":";;AACA,yCAAsC;AAMzB,QAAA,eAAe,GAAG,IAAI,mBAAQ,EAAkB,CAAC"}
@@ -4,5 +4,6 @@ const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
4
4
  const uni_jsx_1 = require("@redneckz/uni-jsx");
5
5
  const BlockWrapper_1 = require("../../ui-kit/BlockWrapper");
6
6
  const renderButtonsSection_1 = require("../../ui-kit/Button/renderButtonsSection");
7
- exports.ButtonBlock = (0, uni_jsx_1.JSX)(({ button, ...rest }) => ((0, jsx_runtime_1.jsx)(BlockWrapper_1.BlockWrapper, { ...rest, children: (0, renderButtonsSection_1.renderButtonsSection)([button]) })));
7
+ const style_1 = require("../../utils/style");
8
+ exports.ButtonBlock = (0, uni_jsx_1.JSX)(({ button, className, ...rest }) => ((0, jsx_runtime_1.jsx)(BlockWrapper_1.BlockWrapper, { className: (0, style_1.style)('!bg-transparent', className), ...rest, children: (0, renderButtonsSection_1.renderButtonsSection)([button]) })));
8
9
  //# sourceMappingURL=ButtonBlock.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ButtonBlock.js","sourceRoot":"","sources":["../../../src/components/ButtonBlock/ButtonBlock.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAExC,4DAAyD;AACzD,mFAAgF;AAKnE,QAAA,WAAW,GAAG,IAAA,aAAG,EAAmB,CAAC,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CACxE,uBAAC,2BAAY,OAAK,IAAI,YAAG,IAAA,2CAAoB,EAAC,CAAC,MAAM,CAAC,CAAC,GAAgB,CACxE,CAAC,CAAC"}
1
+ {"version":3,"file":"ButtonBlock.js","sourceRoot":"","sources":["../../../src/components/ButtonBlock/ButtonBlock.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAExC,4DAAyD;AACzD,mFAAgF;AAChF,6CAA0C;AAK7B,QAAA,WAAW,GAAG,IAAA,aAAG,EAAmB,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CACnF,uBAAC,2BAAY,IAAC,SAAS,EAAE,IAAA,aAAK,EAAC,iBAAiB,EAAE,SAAS,CAAC,KAAM,IAAI,YACnE,IAAA,2CAAoB,EAAC,CAAC,MAAM,CAAC,CAAC,GAClB,CAChB,CAAC,CAAC"}
@@ -3,6 +3,10 @@ import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
3
3
  * @title Блок Кнопка
4
4
  */
5
5
  export interface ButtonBlockContent {
6
- /** @title Кнопка */
6
+ /**
7
+ * @title Кнопка
8
+ * @default {"icon": {"format": "webp", "size": { "width": 24, "height": 24 }},
9
+ * "iconRight": {"format": "webp", "size": { "width": 24, "height": 24 }}}
10
+ */
7
11
  button?: ButtonWithIconProps;
8
12
  }
@@ -4,5 +4,5 @@ const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
4
4
  const uni_jsx_1 = require("@redneckz/uni-jsx");
5
5
  const Text_1 = require("../../ui-kit/Text/Text");
6
6
  const style_1 = require("../../utils/style");
7
- exports.Rate = (0, uni_jsx_1.JSX)(({ rate, title = 'Ставка', unit, depositeName, isShowDepositeName, rateBlockClassName }) => ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(Text_1.Text, { size: "text-l-light", color: "text-secondary-text", children: title }), (0, jsx_runtime_1.jsxs)("div", { className: "relative", children: [(0, jsx_runtime_1.jsxs)("div", { className: "flex justify-start", children: [(0, jsx_runtime_1.jsx)("span", { className: (0, style_1.style)('block gradient-color-text font-mohave text-title-huge pr-6 -mt-4', rateBlockClassName), children: String(rate).replace('.', ',') }), unit ? ((0, jsx_runtime_1.jsx)("span", { className: "gradient-color-text text-[65px] leading-[75px]", children: unit })) : ('')] }), depositeName && isShowDepositeName ? ((0, jsx_runtime_1.jsx)("div", { className: "absolute bottom-7 w-full text-center whitespace-nowrap", children: depositeName })) : null] })] })));
7
+ exports.Rate = (0, uni_jsx_1.JSX)(({ rate, title = 'Ставка', unit, depositeName, isShowDepositeName, rateBlockClassName }) => ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(Text_1.Text, { size: "text-l-light", color: "text-secondary-text", children: title }), (0, jsx_runtime_1.jsxs)("div", { className: "relative", children: [(0, jsx_runtime_1.jsxs)("div", { className: "flex justify-start", children: [(0, jsx_runtime_1.jsx)("span", { className: (0, style_1.style)('block gradient-color-text font-mohave text-title-huge pr-6 -mt-4', rateBlockClassName), children: String(rate.toFixed(2)).replace('.', ',') }), unit ? ((0, jsx_runtime_1.jsx)("span", { className: "gradient-color-text text-[65px] leading-[75px]", children: unit })) : ('')] }), depositeName && isShowDepositeName ? ((0, jsx_runtime_1.jsx)("div", { className: "absolute bottom-7 w-full text-center whitespace-nowrap", children: depositeName })) : null] })] })));
8
8
  //# sourceMappingURL=Rate.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Rate.js","sourceRoot":"","sources":["../../../src/components/Calculator/Rate.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AACxC,iDAA8C;AAC9C,6CAA0C;AAW7B,QAAA,IAAI,GAAG,IAAA,aAAG,EACrB,CAAC,EAAE,IAAI,EAAE,KAAK,GAAG,QAAQ,EAAE,IAAI,EAAE,YAAY,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,EAAE,EAAE,CAAC,CAC1F,4CACE,uBAAC,WAAI,IAAC,IAAI,EAAC,cAAc,EAAC,KAAK,EAAC,qBAAqB,YAClD,KAAK,GACD,EACP,iCAAK,SAAS,EAAC,UAAU,aACvB,iCAAK,SAAS,EAAC,oBAAoB,aACjC,iCACE,SAAS,EAAE,IAAA,aAAK,EACd,kEAAkE,EAClE,kBAAkB,CACnB,YAEA,MAAM,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,GAC1B,EACN,IAAI,CAAC,CAAC,CAAC,CACN,iCAAM,SAAS,EAAC,gDAAgD,YAAE,IAAI,GAAQ,CAC/E,CAAC,CAAC,CAAC,CACF,EAAE,CACH,IACG,EACL,YAAY,IAAI,kBAAkB,CAAC,CAAC,CAAC,CACpC,gCAAK,SAAS,EAAC,wDAAwD,YACpE,YAAY,GACT,CACP,CAAC,CAAC,CAAC,IAAI,IACJ,IACF,CACP,CACF,CAAC"}
1
+ {"version":3,"file":"Rate.js","sourceRoot":"","sources":["../../../src/components/Calculator/Rate.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AACxC,iDAA8C;AAC9C,6CAA0C;AAW7B,QAAA,IAAI,GAAG,IAAA,aAAG,EACrB,CAAC,EAAE,IAAI,EAAE,KAAK,GAAG,QAAQ,EAAE,IAAI,EAAE,YAAY,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,EAAE,EAAE,CAAC,CAC1F,4CACE,uBAAC,WAAI,IAAC,IAAI,EAAC,cAAc,EAAC,KAAK,EAAC,qBAAqB,YAClD,KAAK,GACD,EACP,iCAAK,SAAS,EAAC,UAAU,aACvB,iCAAK,SAAS,EAAC,oBAAoB,aACjC,iCACE,SAAS,EAAE,IAAA,aAAK,EACd,kEAAkE,EAClE,kBAAkB,CACnB,YAEA,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,GACrC,EACN,IAAI,CAAC,CAAC,CAAC,CACN,iCAAM,SAAS,EAAC,gDAAgD,YAAE,IAAI,GAAQ,CAC/E,CAAC,CAAC,CAAC,CACF,EAAE,CACH,IACG,EACL,YAAY,IAAI,kBAAkB,CAAC,CAAC,CAAC,CACpC,gCAAK,SAAS,EAAC,wDAAwD,YACpE,YAAY,GACT,CACP,CAAC,CAAC,CAAC,IAAI,IACJ,IACF,CACP,CACF,CAAC"}
@@ -46,7 +46,7 @@ exports.DEFAULT_DEPOSIT_CALCULATOR_PARAMS = {
46
46
  maxSum: 5000000,
47
47
  minMonths: 2,
48
48
  maxMonths: 120,
49
- rate: 5.9,
49
+ rate: 7,
50
50
  isMonthlyInterestPayment: true,
51
51
  };
52
52
  exports.DEFAULT_BUSINESS_DEPOSIT_CALCULATOR_PARAMS = {
@@ -54,7 +54,7 @@ exports.DEFAULT_BUSINESS_DEPOSIT_CALCULATOR_PARAMS = {
54
54
  maxSum: 500000,
55
55
  minDays: exports.BUSINESS_MIN_DAYS,
56
56
  maxDays: exports.BUSINESS_MAX_DAYS,
57
- rate: 5.9,
57
+ rate: 6.6,
58
58
  isMonthlyInterestPayment: true,
59
59
  isReplenished: false,
60
60
  isPartialWithdrawal: false,
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/components/Calculator/constants.ts"],"names":[],"mappings":";;AAKa,QAAA,eAAe,GAAG,KAAK,CAAC;AACxB,QAAA,eAAe,GAAG,OAAO,CAAC;AAC1B,QAAA,WAAW,GAAG,CAAC,uBAAe,GAAG,uBAAe,CAAC,GAAG,CAAC,CAAC;AACtD,QAAA,kBAAkB,GAAG,EAAE,CAAC;AACxB,QAAA,kBAAkB,GAAG,EAAE,CAAC;AACxB,QAAA,cAAc,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,0BAAkB,GAAG,0BAAkB,CAAC,GAAG,CAAC,CAAC,CAAC;AAC3E,QAAA,oBAAoB,GAAG,MAAM,CAAC;AAC9B,QAAA,iBAAiB,GAAG,CAAC,CAAC;A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+ export declare const getRangeByKeys: <MinKey extends string, MaxKey extends string, T extends Record<MinKey | MaxKey, number>>([minKey, maxKey]: [MinKey, MaxKey], rows?: T[]) => {
2
+ [x: string]: unknown;
3
+ };
4
+ export declare const checkRangeByKeys: <MinKey extends string, MaxKey extends string, T extends Record<MinKey | MaxKey, number>>(value: number, [minKey, maxKey]: [MinKey, MaxKey], sourceBookRow: T) => boolean;
@@ -0,0 +1,12 @@
1
+ Object.defineProperty(exports, "__esModule", { value: true });
2
+ exports.checkRangeByKeys = exports.getRangeByKeys = void 0;
3
+ const maxBy_1 = require("../../utils/maxBy");
4
+ const minBy_1 = require("../../utils/minBy");
5
+ const getRangeByKeys = ([minKey, maxKey], rows = []) => ({
6
+ [minKey]: rows.length ? (0, minBy_1.minBy)()(rows.map((row) => row[minKey])) : 0,
7
+ [maxKey]: rows.length ? (0, maxBy_1.maxBy)()(rows.map((row) => row[maxKey])) : 0,
8
+ });
9
+ exports.getRangeByKeys = getRangeByKeys;
10
+ const checkRangeByKeys = (value, [minKey, maxKey], sourceBookRow) => value >= sourceBookRow[minKey] && value < sourceBookRow[maxKey];
11
+ exports.checkRangeByKeys = checkRangeByKeys;
12
+ //# sourceMappingURL=rangeHelpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rangeHelpers.js","sourceRoot":"","sources":["../../../src/components/Calculator/rangeHelpers.ts"],"names":[],"mappings":";;AAAA,6CAA0C;AAC1C,6CAA0C;AAEnC,MAAM,cAAc,GAAG,CAK5B,CAAC,MAAM,EAAE,MAAM,CAAmB,EAClC,OAAY,EAAE,EACd,EAAE,CAAC,CAAC;IACJ,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAA,aAAK,GAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACnE,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAA,aAAK,GAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CACpE,CAAC,CAAC;AAVU,QAAA,cAAc,kBAUxB;AAEI,MAAM,gBAAgB,GAAG,CAK9B,KAAa,EACb,CAAC,MAAM,EAAE,MAAM,CAAmB,EAClC,aAAgB,EACP,EAAE,CAAC,KAAK,IAAI,aAAa,CAAC,MAAM,CAAC,IAAI,KAAK,GAAG,aAAa,CAAC,MAAM,CAAC,CAAC;AARjE,QAAA,gBAAgB,oBAQiD"}
@@ -1,6 +1,7 @@
1
1
  Object.defineProperty(exports, "__esModule", { value: true });
2
2
  exports.useBusinessDepositCalculatorParams = void 0;
3
3
  const constants_1 = require("./constants");
4
+ const rangeHelpers_1 = require("./rangeHelpers");
4
5
  const useCalculatorParams_1 = require("./useCalculatorParams");
5
6
  const useBusinessDepositCalculatorParams = (userInputParams, sourceBookDir) => {
6
7
  const { daysValue, moneyValue, isPartialWithdrawal, isReplenished, isSmallBusiness, isMonthlyInterestPayment, } = userInputParams;
@@ -18,15 +19,18 @@ const useBusinessDepositCalculatorParams = (userInputParams, sourceBookDir) => {
18
19
  const businessDepositCalculatorSourceBookParams = data?.rows?.find((_) => {
19
20
  return (isMonthlyInterestPayment === _.isMonthlyInterestPayment &&
20
21
  isSmallBusiness === _.isSmallBusiness &&
21
- (isOperatingDeposit
22
- ? _.isReplenished && _.isPartialWithdrawal
23
- : !_.isReplenished && !_.isPartialWithdrawal));
22
+ checkIsOperatingDeposit(isOperatingDeposit, _) &&
23
+ (0, rangeHelpers_1.checkRangeByKeys)(moneyValue, ['minSum', 'maxSum'], _) &&
24
+ (0, rangeHelpers_1.checkRangeByKeys)(daysValue, ['minDays', 'maxDays'], _));
24
25
  }) || constants_1.DEFAULT_BUSINESS_DEPOSIT_CALCULATOR_PARAMS;
25
26
  const { rate } = businessDepositCalculatorSourceBookParams;
26
27
  const income = getDepositIncome(rate, userInputParams);
27
28
  const finalSum = moneyValue + income;
29
+ const sourceBookRows = data?.rows || [constants_1.DEFAULT_BUSINESS_DEPOSIT_CALCULATOR_PARAMS];
28
30
  return {
29
31
  ...businessDepositCalculatorSourceBookParams,
32
+ ...(0, rangeHelpers_1.getRangeByKeys)(['minSum', 'maxSum'], sourceBookRows),
33
+ ...(0, rangeHelpers_1.getRangeByKeys)(['minDays', 'maxDays'], sourceBookRows),
30
34
  ...userInputParams,
31
35
  isDisabledOperatingDeposit,
32
36
  income,
@@ -34,6 +38,9 @@ const useBusinessDepositCalculatorParams = (userInputParams, sourceBookDir) => {
34
38
  };
35
39
  };
36
40
  exports.useBusinessDepositCalculatorParams = useBusinessDepositCalculatorParams;
41
+ const checkIsOperatingDeposit = (isOperatingDeposit, sourceBookRow) => isOperatingDeposit
42
+ ? sourceBookRow.isReplenished && sourceBookRow.isPartialWithdrawal
43
+ : !sourceBookRow.isReplenished && !sourceBookRow.isPartialWithdrawal;
37
44
  const getDepositIncome = (rate, userInputParams) => {
38
45
  const { isMonthlyInterestPayment, moneyValue, daysValue } = userInputParams;
39
46
  /*
@@ -1 +1 @@
1
- {"version":3,"file":"useBusinessDepositCalculatorParams.js","sourceRoot":"","sources":["../../../src/components/Calculator/useBusinessDepositCalculatorParams.ts"],"names":[],"mappings":";;AAAA,2CAMqB;AACrB,+DAA4D;AAkCrD,MAAM,kCAAkC,GAAG,CAChD,eAAyD,EACzD,aAAsB,EACW,EAAE;IACnC,MAAM,EACJ,SAAS,EACT,UAAU,EACV,mBAAmB,EACnB,aAAa,EACb,eAAe,EACf,wBAAwB,GACzB,GAAG,eAAe,CAAC;IACpB,MAAM,IAAI,GAAG,IAAA,yCAAmB,EAC9B,aAAa,IAAI,6CAAiC,CACnD,CAAC;IAEF,MAAM,kBAAkB,GAAG,aAAa,IAAI,mBAAmB,CAAC;IAChE,MAAM,0BAA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EAAE,CAAC,GAAG,UAAU,CAAC,CAAC;KAC7F;SAAM;QACL,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,UAAU,GAAG,IAAI,GAAG,SAAS,CAAC,GAAG,GAAG,GAAG,GAAG,CAAC,CAAC;KAChE;AACH,CAAC,CAAC"}
1
+ {"version":3,"file":"useBusinessDepositCalculatorParams.js","sourceRoot":"","sources":["../../../src/components/Calculator/useBusinessDepositCalculatorParams.ts"],"names":[],"mappings":";;AAAA,2CAMqB;AACrB,iDAAkE;AAClE,+DAA4D;AAkCrD,MAAM,kCAAkC,GAAG,CAChD,eAAyD,EACzD,aAAsB,EACW,EAAE;IACnC,MAAM,EACJ,SAAS,EACT,UAAU,EACV,mBAAmB,EACnB,aAAa,EACb,eAAe,EACf,wBAAwB,GACzB,GAAG,eAAe,CAAC;IACpB,MAAM,IAAI,GAAG,IAAA,yCAAmB,EAC9B,aAAa,IAAI,6CAAiC,CACnD,CAAC;IAEF,MAAM,kBAAkB,GAAG,aAAa,IAAI,mBAAmB,CAAC;IAChE,MAAM,0BAA0B,GAC9B,SAAS,GAAG,uCAA2B,IAAI,SAAS,GAAG,uCAA2B,CAAC;IAErF,IAAI,SAAS,IAAI,kCAAsB,EAAE;QACvC,OAAO;YACL,GAAG,sDAA0C;YAC7C,GAAG,eAAe;YAClB,0BAA0B;YAC1B,IAAI,EAAE,CAAC;SACR,CAAC;KACH;IACD,MAAM,yCAAyC,GAC7C,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE;QACrB,OAAO,CACL,wBAAwB,KAAK,CAAC,CAAC,wBAAwB;YACvD,eAAe,KAAK,CAAC,CAAC,eAAe;YACrC,uBAAuB,CAAC,kBAAkB,EAAE,CAAC,CAAC;YAC9C,IAAA,+BAAgB,EAAC,UAAU,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE,CAAC,CAAC;YACrD,IAAA,+BAAgB,EAAC,SAAS,EAAE,CAAC,SAAS,E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,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,UAAU,GAAG,IAAI,GAAG,SAAS,CAAC,GAAG,GAAG,GAAG,GAAG,CAAC,CAAC;KAChE;AACH,CAAC,CAAC"}
@@ -2,20 +2,26 @@ Object.defineProperty(exports, "__esModule", { value: true });
2
2
  exports.useCreditCalculatorParams = void 0;
3
3
  const constants_1 = require("./constants");
4
4
  const getMonthlyPayment_1 = require("./getMonthlyPayment");
5
+ const rangeHelpers_1 = require("./rangeHelpers");
5
6
  const useCalculatorParams_1 = require("./useCalculatorParams");
6
7
  const useCreditCalculatorParams = (userInputParams, sourceBookDir) => {
7
- const { isInsurance, isSalaryClient, isStateEmployee, moneyValue } = userInputParams;
8
+ const { isInsurance, isSalaryClient, isStateEmployee, moneyValue, monthsValue } = userInputParams;
8
9
  const data = (0, useCalculatorParams_1.useCalculatorParams)(sourceBookDir || constants_1.CREDIT_CALC_DEFAULT_DIR);
9
10
  const creditCalculatorSourceBookParams = data?.rows?.find((_) => {
10
11
  return (isInsurance === _.isInsurance &&
11
12
  isSalaryClient === _.isSalaryClient &&
12
- isStateEmployee === _.isStateEmployee);
13
+ isStateEmployee === _.isStateEmployee &&
14
+ (0, rangeHelpers_1.checkRangeByKeys)(moneyValue, ['minSum', 'maxSum'], _) &&
15
+ (0, rangeHelpers_1.checkRangeByKeys)(monthsValue, ['minMonths', 'maxMonths'], _));
13
16
  }) || constants_1.DEFAULT_CREDIT_CALCULATOR_PARAMS;
14
17
  const { rateBottomRange, rateTopRange, sumBorder } = creditCalculatorSourceBookParams;
15
18
  const finalRate = moneyValue <= sumBorder ? rateBottomRange : rateTopRange;
16
19
  const monthlyPayment = (0, getMonthlyPayment_1.getMonthlyPayment)(finalRate, userInputParams);
20
+ const sourceBookRows = data?.rows || [constants_1.DEFAULT_CREDIT_CALCULATOR_PARAMS];
17
21
  return {
18
22
  ...creditCalculatorSourceBookParams,
23
+ ...(0, rangeHelpers_1.getRangeByKeys)(['minSum', 'maxSum'], sourceBookRows),
24
+ ...(0, rangeHelpers_1.getRangeByKeys)(['minMonths', 'maxMonths'], sourceBookRows),
19
25
  ...userInputParams,
20
26
  finalRate,
21
27
  monthlyPayment,
@@ -1 +1 @@
1
- {"version":3,"file":"useCreditCalculatorParams.js","sourceRoot":"","sources":["../../../src/components/Calculator/useCreditCalculatorParams.ts"],"names":[],"mappings":";;AAAA,2CAAwF;AACxF,2DAAwD;AACxD,+DAA4D;AAkCrD,MAAM,yBAAyB,GAAG,CACvC,eAAgD,EAChD,aAAsB,EACE,EAAE;IAC1B,MAAM,EAAE,WAAW,EAAE,cAAc,EAAE,eAAe,EAAE,UAAU,EAAE,GAAG,eAAe,CAAC;IAErF,MAAM,IAAI,GAAG,IAAA,yCAAmB,EAAuB,aAAa,IAAI,mCAAuB,CAAC,CAAC;IACjG,MAAM,gCAAgC,GACpC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE;QACrB,OAAO,CACL,WAAW,KAAK,CAAC,CAAC,WAAW;YAC7B,cAAc,KAAK,CAAC,CAAC,cAAc;YACnC,eAAe,KAAK,CAAC,CAAC,eAAe,CACtC,CAAC;IACJ,CAAC,CAAC,IAAI,4CAAgC,CAAC;IAEzC,MAAM,EAAE,eAAe,EAAE,YAAY,EAAE,SAAS,EAAE,GAAG,gCAAgC,CAAC;IACtF,MAAM,SAAS,GAAG,UAAU,IAAI,SAAS,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,YAAY,CAAC;IAC3E,MAAM,cAAc,GAAG,IAAA,qCAAiB,EAAC,SAAS,EAAE,eAAe,CAAC,CAAC;IAErE,OAAO;QACL,GAAG,gCAAgC;QACnC,GAAG,eAAe;QAClB,SAAS;QACT,cAAc;KACf,CAAC;AACJ,CAAC,CAAC;AA1BW,QAAA,yBAAyB,6BA0BpC"}
1
+ {"version":3,"file":"useCreditCalculatorParams.js","sourceRoot":"","sources":["../../../src/components/Calculator/useCreditCalculatorParams.ts"],"names":[],"m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AAC,EAAE,cAAc,CAAC;QAC7D,GAAG,eAAe;QAClB,SAAS;QACT,cAAc;KACf,CAAC;AACJ,CAAC,CAAC;AA/BW,QAAA,yBAAyB,6BA+BpC"}
@@ -1,16 +1,26 @@
1
1
  Object.defineProperty(exports, "__esModule", { value: true });
2
2
  exports.useDepositCalculatorParams = void 0;
3
3
  const constants_1 = require("./constants");
4
+ const rangeHelpers_1 = require("./rangeHelpers");
4
5
  const useCalculatorParams_1 = require("./useCalculatorParams");
5
6
  const useDepositCalculatorParams = (userInputParams, sourceBookDir) => {
6
- const { isMonthlyInterestPayment, moneyValue } = userInputParams;
7
+ const { isMonthlyInterestPayment, moneyValue, monthsValue } = userInputParams;
7
8
  const data = (0, useCalculatorParams_1.useCalculatorParams)(sourceBookDir || constants_1.DEPOSIT_CALC_DEFAULT_DIR);
8
- const depositCalculatorSourceBookParams = data?.rows?.find((_) => isMonthlyInterestPayment === _.isMonthlyInterestPayment) ||
9
- constants_1.DEFAULT_DEPOSIT_CALCULATOR_PARAMS;
9
+ const depositCalculatorSourceBookParams = data?.rows?.find((_) => isMonthlyInterestPayment === _.isMonthlyInterestPayment &&
10
+ (0, rangeHelpers_1.checkRangeByKeys)(moneyValue, ['minSum', 'maxSum'], _) &&
11
+ (0, rangeHelpers_1.checkRangeByKeys)(monthsValue, ['minMonths', 'maxMonths'], _)) || constants_1.DEFAULT_DEPOSIT_CALCULATOR_PARAMS;
10
12
  const { rate } = depositCalculatorSourceBookParams;
11
13
  const income = getDepositIncome(rate, userInputParams);
12
14
  const finalSum = moneyValue + income;
13
- return { ...depositCalculatorSourceBookParams, ...userInputParams, income, finalSum };
15
+ const sourceBookRows = data?.rows || [constants_1.DEFAULT_DEPOSIT_CALCULATOR_PARAMS];
16
+ return {
17
+ ...depositCalculatorSourceBookParams,
18
+ ...(0, rangeHelpers_1.getRangeByKeys)(['minSum', 'maxSum'], sourceBookRows),
19
+ ...(0, rangeHelpers_1.getRangeByKeys)(['minMonths', 'maxMonths'], sourceBookRows),
20
+ ...userInputParams,
21
+ income,
22
+ finalSum,
23
+ };
14
24
  };
15
25
  exports.useDepositCalculatorParams = useDepositCalculatorParams;
16
26
  const getDepositIncome = (rate, userInputParams) => {
@@ -1 +1 @@
1
- {"version":3,"file":"useDepositCalculatorParams.js","sourceRoot":"","sources":["../../../src/components/Calculator/useDepositCalculatorParams.ts"],"names":[],"mappings":";;AAAA,2CAA0F;AAC1F,+DAA4D;AA6BrD,MAAM,0BAA0B,GAAG,CACxC,eAAiD,EACjD,aAAsB,EACG,EAAE;IAC3B,MAAM,EAAE,wBAAwB,EAAE,UAAU,EAAE,GAAG,eAAe,CAAC;IAEjE,MAAM,IAAI,GAAG,IAAA,yCAAmB,EAC9B,aAAa,IAAI,oCAAwB,CAC1C,CAAC;IAEF,MAAM,iCAAiC,GACrC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,wBAAwB,KAAK,CAAC,CAAC,wBAAwB,CAAC;QAChF,6CAAiC,CAAC;IAEpC,MAAM,EAAE,IAAI,EAAE,GAAG,iCAAiC,CAAC;IAEnD,MAAM,MAAM,GAAG,gBAAgB,CAAC,IAAI,EAAE,eAAe,CAAC,CAAC;IACvD,MAAM,QAAQ,GAAG,UAAU,GAAG,MAAM,CAAC;IAErC,OAAO,EAAE,GAAG,iCAAiC,EAAE,GAAG,eAAe,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;AACxF,CAAC,CAAC;AApBW,QAAA,0BAA0B,8BAoBrC;AAEF,MAAM,gBAAgB,GAAG,CAAC,IAAY,EAAE,eAAiD,EAAE,EAAE;IAC3F,MAAM,EAAE,wBAAwB,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,eAAe,CAAC;IAE9E,IAAI,wBAAwB,EAAE;QAC5B,OAAO,IAAI,CAAC,KAAK,CAAC,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,GAAG,IAAI,CAAC,GAAG,IAAI,EAAE,WAAW,CAAC,GAAG,UAAU,CAAC,CAAC;KAC1F;SAAM;QACL;;UAEE;QACF,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,UAAU,GAAG,IAAI,GAAG,EAAE,GAAG,WAAW,CAAC,GAAG,GAAG,GAAG,GAAG,CAAC,CAAC;KACvE;AACH,CAAC,CAAC"}
1
+ {"version":3,"file":"useDepositCalculatorParams.js","sourceRoot":"","sources":["../../../src/components/Calculator/useDepositCalculatorParams.ts"],"names":[],"mappings":";;AAAA,2CAA0F;AAC1F,iDAAkE;AAClE,+DAA4D;AA8BrD,MAAM,0BAA0B,GAAG,CACxC,eAAiD,EACjD,aAAsB,EACG,EAAE;IAC3B,MAAM,EAAE,wBAAwB,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,eAAe,CAAC;IAE9E,MAAM,IAAI,GAAG,IAAA,yCAAmB,EAC9B,aAAa,IAAI,oCAAwB,CAC1C,CAAC;IAEF,MAAM,iCAAiC,GACrC,IAAI,EAAE,IAAI,EAAE,IAAI,CACd,CAAC,CAAC,EAAE,EAAE,CACJ,wBAAwB,KAAK,CAAC,CAAC,wBAAwB;QACvD,IAAA,+BAAgB,EAAC,UAAU,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE,CAAC,CAAC;QACrD,IAAA,+BAAgB,EAAC,WAAW,EAAE,CAAC,WAAW,EAAE,WAAW,CAAC,EAAE,CAAC,CAAC,CAC/D,IAAI,6CAAiC,CAAC;IAEzC,MAAM,EAAE,IAAI,EAAE,GAAG,iCAAiC,CAAC;IAEnD,MAAM,MAAM,GAAG,gBAAgB,CAAC,IAAI,EAAE,eAAe,CAAC,CAAC;IACvD,MAAM,QAAQ,GAAG,UAAU,GAAG,MAAM,CAAC;IACrC,MAAM,cAAc,GAAG,IAAI,EAAE,IAAI,IAAI,CAAC,6CAAiC,CAAC,CAAC;IAEzE,OAAO;QACL,GAAG,iCAAiC;QACpC,GAAG,IAAA,6BAAc,EAAC,CAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE,cAAc,CAAC;QACvD,GAAG,IAAA,6BAAc,EAAC,CAAC,WAAW,EAAE,WAAW,CAAC,EAAE,cAAc,CAAC;QAC7D,GAAG,eAAe;QAClB,MAAM;QACN,QAAQ;KACT,CAAC;AACJ,CAAC,CAAC;AAhCW,QAAA,0BAA0B,8BAgCrC;AAEF,MAAM,gBAAgB,GAAG,CAAC,IAAY,EAAE,eAAiD,EAAE,EAAE;IAC3F,MAAM,EAAE,wBAAwB,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,eAAe,CAAC;IAE9E,IAAI,wBAAwB,EAAE;QAC5B,OAAO,IAAI,CAAC,KAAK,CAAC,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,GAAG,IAAI,CAAC,GAAG,IAAI,EAAE,WAAW,CAAC,GAAG,UAAU,CAAC,CAAC;KAC1F;SAAM;QACL;;UAEE;QACF,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,UAAU,GAAG,IAAI,GAAG,EAAE,GAAG,WAAW,CAAC,GAAG,GAAG,GAAG,GAAG,CAAC,CAAC;KACvE;AACH,CAAC,CAAC"}
@@ -21,10 +21,12 @@ exports.Carousel = (0, uni_jsx_1.JSX)(({ className = '', itemCount, visibleItemC
21
21
  isCyclic,
22
22
  });
23
23
  const isBankHistoryCarousel = childBlocks && childBlocks[0]?.type === 'CarouselBankHistoryCard';
24
- return ((0, jsx_runtime_1.jsx)(BlockWrapper_1.BlockWrapper, { className: (0, style_1.style)(getPaddingStyle(isPadding), className), ...rest, children: (0, jsx_runtime_1.jsxs)("div", { className: "relative max-w-full", children: [(0, jsx_runtime_1.jsx)(SwipeListContainer_1.SwipeListContainer, { containerRef: containerRef, visibleItemCount: visibleItemCount, snapAlign: "snap-start", gap: ITEMS_GAP, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, children: (0, renderChildren_1.renderChildren)({
25
- ...rest,
26
- block: { ...rest.block, blocks: buildBlocks(childBlocks, activeIndex) },
27
- }) }), (0, jsx_runtime_1.jsx)(CarouselScrollButtons_1.CarouselScrollButtons, { scroll: scroll, isBlur: isBlur, arrowsPadded: arrowsPadded, onScrollLeft: decreaseActiveIndex, onScrollRight: increaseActiveIndex, hasEdgeBlocks: isBankHistoryCarousel, activeIndex: activeIndex, itemCount: count })] }) }));
24
+ return ((0, jsx_runtime_1.jsx)(BlockWrapper_1.BlockWrapper, { className: (0, style_1.style)(getPaddingStyle(isPadding), className), ...rest, children: (0, jsx_runtime_1.jsxs)("div", { className: "relative max-w-full", children: [(0, jsx_runtime_1.jsx)(SwipeListContainer_1.SwipeListContainer, { containerRef: containerRef, visibleItemCount: visibleItemCount, snapAlign: "snap-start", gap: ITEMS_GAP, onVisibleIndicesChange: scroll.handleVisibleIndicesChange, children: isBankHistoryCarousel
25
+ ? (0, renderChildren_1.renderChildren)({
26
+ ...rest,
27
+ block: { ...rest.block, blocks: buildBlocks(childBlocks, activeIndex) },
28
+ })
29
+ : (0, renderChildren_1.renderChildren)(rest) }), (0, jsx_runtime_1.jsx)(CarouselScrollButtons_1.CarouselScrollButtons, { scroll: scroll, isBlur: isBlur, arrowsPadded: arrowsPadded, onScrollLeft: decreaseActiveIndex, onScrollRight: increaseActiveIndex, hasEdgeBlocks: isBankHistoryCarousel, activeIndex: activeIndex, itemCount: count })] }) }));
28
30
  });
29
31
  exports.Carousel.childrenTypes = [
30
32
  'CarouselCard',
@@ -1 +1 @@
1
- {"version":3,"file":"Carousel.js","sourceRoot":"","sources":["../../../src/components/Carousel/Carousel.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AACxC,uDAAoE;AACpE,uEAAoE;AAGpE,4DAAyD;AACzD,yFAAsF;AACtF,yFAAsF;AACtF,6CAA0C;AAE1C,mEAAgE;AAMhE,MAAM,SAAS,GAAG,CAAC,CAAC;AAEP,QAAA,QAAQ,GAA4B,IAAA,aAAG,EAClD,CAAC,EACC,SAAS,GAAG,EAAE,EACd,SAAS,EACT,gBAAgB,EA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CAAC,CAAC,CAAC,EAAE,IAAI,KAAK,yBAAyB;QAC5D,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE;YAClB,OAAO;gBACL,GAAG,CAAC;gBACJ,OAAO,EAAE;oBACP,GAAG,CAAC,CAAC,OAAO;oBACZ,WAAW,EAAE,CAAC;oBACd,QAAQ,EAAE,WAAW,KAAK,CAAC;oBAC3B,YAAY,EAAE,MAAM,CAAC,MAAM;iBAC5B;aACF,CAAC;QACJ,CAAC,CAAC;QACJ,CAAC,CAAC,MAAM,CAAC;AACb,CAAC,CAAC;AAEF,MAAM,eAAe,GAAG,CAAC,SAAkB,EAAU,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC"}
@@ -4,6 +4,7 @@ const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
4
4
  const BenefitItem_1 = require("../../ui-kit/BenefitItem/BenefitItem");
5
5
  const RichText_1 = require("../../ui-kit/RichText/RichText");
6
6
  const assertUnreachable_1 = require("../../utils/assertUnreachable");
7
+ // TODO: Create universal function for this case
7
8
  const renderBenefit =
8
9
  // Linter doesn't understand that switch processes all cases
9
10
  // eslint-disable-next-line consistent-return
@@ -1 +1 @@
1
- {"version":3,"file":"renderBenefit.js","sourceRoot":"","sources":["../../../src/components/PictureText/renderBenefit.tsx"],"names":[],"mappings":";;;AACA,sEAAmE;AAEnE,6DAA0D;AAC1D,qEAAkE;AAE3D,MAAM,aAAa;AACxB,4DAA4D;AAC5D,6CAA6C;AAC7C,CAAC,OAAqB,EAAE,EAAE,CAAC,CAAC,OAA4B,EAAE,CAAS,EAAE,EAAE;IACrE,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IAEzB,IAAI,CAAC,CAAC,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,KAAK,CAAC,EAAE;QAC3C,OAAO,IAAI,CAAC;KACb;I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ACE,IAAA,qCAAiB,EAAC,OAAO,CAAC,CAAC;KAC9B;AACH,CAAC,CAAC;AA1BS,QAAA,aAAa,iBA0BtB"}
@@ -4,6 +4,7 @@ const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
4
4
  const RichText_1 = require("../../ui-kit/RichText/RichText");
5
5
  const Text_1 = require("../../ui-kit/Text/Text");
6
6
  const assertUnreachable_1 = require("../../utils/assertUnreachable");
7
+ // TODO: Create universal function for this case
7
8
  const renderBenefit =
8
9
  // Linter doesn't understand that switch processes all cases
9
10
  // eslint-disable-next-line consistent-return
@@ -1 +1 @@
1
- {"version":3,"file":"renderBenefit.js","sourceRoot":"","sources":["../../../src/components/ProductTile/renderBenefit.tsx"],"names":[],"mappings":";;;AAAA,6DAA0D;AAC1D,iDAA8C;AAC9C,qEAAkE;AAG3D,MAAM,aAAa;AACxB,4DAA4D;AAC5D,6CAA6C;AAC7C,CAAC,OAAgB,EAAE,CAAS,EAAE,EAAE;IAC9B,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IAEzB,IAAI,CAAC,CAAC,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,KAAK,CAAC,EAAE;QAC3C,OAAO,IAAI,CAAC;KACb;IAED,QAAQ,IAAI,EAAE;QACZ,KAAK,SAAS;YACZ,OAAO;gBACL,uBAAC,WAAI,IAAoB,IAAI,EAAC,SAAS,YACpC,OAAO,CAAC,KAAK,IADL,SAAS,CAAC,EAAE,CAEhB;gBACP,uBAAC,WAAI,IAEH,IAAI,EAAC,QAAQ,EACb,IAAI,EAAC,YAAY,EACjB,KAAK,EAAC,wCAAwC,YAE7C,OAAO,CAAC,WAAW,IALf,QAAQ,CAAC,EAAE,CAMX;aACR,CAAC;QACJ,KAAK,KAAK;YACR,OAAO,CACL,gCAAK,SAAS,EAAC,YAAY,YACzB,uBAAC,mBAAQ,IAAC,MAAM,EAAE,OAAO,CAAC,MAAM,GAAI,GAChC,CACP,CAAC;QACJ;YACE,IAAA,qCAAiB,EAAC,OAAO,CAAC,CAAC;KAC9B;AACH,CAAC,CAAC;AAlCS,QAAA,aAAa,iBAkCtB"}
1
+ {"version":3,"file":"renderBenefit.js","sourceRoot":"","sources":["../../../src/components/ProductTile/renderBenefit.tsx"],"names":[],"mappings":";;;AAAA,6DAA0D;AAC1D,iDAA8C;AAC9C,qEAAkE;AAGlE,gDAAgD;AACzC,MAAM,aAAa;AACxB,4DAA4D;AAC5D,6CAA6C;AAC7C,CAAC,OAAgB,EAAE,CAAS,EAAE,EAAE;IAC9B,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IAEzB,IAAI,CAAC,CAAC,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,KAAK,CAAC,EAAE;QAC3C,OAAO,IAAI,CAAC;KACb;IAED,QAAQ,IAAI,EAAE;QACZ,KAAK,SAAS;YACZ,OAAO;gBACL,uBAAC,WAAI,IAAoB,IAAI,EAAC,SAAS,YACpC,OAAO,CAAC,KAAK,IADL,SAAS,CAAC,EAAE,CAEhB;gBACP,uBAAC,WAAI,IAEH,IAAI,EAAC,QAAQ,EACb,IAAI,EAAC,YAAY,EACjB,KAAK,EAAC,wCAAwC,YAE7C,OAAO,CAAC,WAAW,IALf,QAAQ,CAAC,EAAE,CAMX;aACR,CAAC;QACJ,KAAK,KAAK;YACR,OAAO,CACL,gCAAK,SAAS,EAAC,YAAY,YACzB,uBAAC,mBAAQ,IAAC,MAAM,EAAE,OAAO,CAAC,MAAM,GAAI,GAChC,CACP,CAAC;QACJ;YACE,IAAA,qCAAiB,EAAC,OAAO,CAAC,CAAC;KAC9B;AACH,CAAC,CAAC;AAlCS,QAAA,aAAa,iBAkCtB"}
@@ -6,26 +6,20 @@ const BlockWrapper_1 = require("../../ui-kit/BlockWrapper");
6
6
  const Button_1 = require("../../ui-kit/Button/Button");
7
7
  const Heading_1 = require("../../ui-kit/Heading/Heading");
8
8
  const Img_1 = require("../../ui-kit/Img/Img");
9
- const checkIsIconRenderable_1 = require("../../utils/checkIsIconRenderable");
10
9
  const getIconWithVersion_1 = require("../../utils/getIconWithVersion");
11
10
  const joinList_1 = require("../../utils/joinList");
12
- const renderStepContent_1 = require("./renderStepContent");
11
+ const style_1 = require("../../utils/style");
12
+ const checkCanRenderIcon_1 = require("./checkCanRenderIcon");
13
+ const renderStep_1 = require("./renderStep");
13
14
  const StepsBlockStyleMaps_1 = require("./StepsBlockStyleMaps");
14
15
  const getLineOpacity = (showLines) => (showLines ? '' : 'opacity-0');
15
16
  const getPaddingX = (steps) => (steps < 5 ? 'px-[88px]' : 'px-[55px]');
16
- exports.StepsBlock = (0, uni_jsx_1.JSX)(({ className = '', showLines = true, steps = [], button, version = 'primary', ...rest }) => {
17
- const { title } = rest;
18
- const styleMap = StepsBlockStyleMaps_1.STEPS_BLOCK_STYLE_MAPS[version];
17
+ exports.StepsBlock = (0, uni_jsx_1.JSX)(({ className = '', showLines = true, steps = [], button, version = 'primary', title, ...rest }) => {
19
18
  const shortGaps = steps.length > 3;
19
+ const styleMap = StepsBlockStyleMaps_1.STEPS_BLOCK_STYLE_MAPS[version];
20
20
  const lineOpacity = getLineOpacity(showLines);
21
- const titleMargin = title ? 'mt-9' : '';
22
21
  const paddingX = getPaddingX(steps.length);
23
- return ((0, jsx_runtime_1.jsxs)(BlockWrapper_1.BlockWrapper, { className: [
24
- 'box-border py-12',
25
- shortGaps ? 'px-20' : 'px-[70px]',
26
- 'flex flex-col items-center overflow-hidden',
27
- className,
28
- ].join(' '), version: version, ...rest, children: [title ? ((0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: "h3", className: "max-w-[752px] text-center", title: title })) : null, steps?.length ? ((0, jsx_runtime_1.jsxs)("div", { className: `box-border ${titleMargin}`, children: [(0, jsx_runtime_1.jsx)("div", { className: `flex items-center ${paddingX}`, children: (0, joinList_1.joinList)((0, jsx_runtime_1.jsx)("div", { className: `h-0.5 w-full bg-secondary-light ${lineOpacity}` }))(steps.map(renderStepIcon(styleMap, version))) }), (0, jsx_runtime_1.jsx)("div", { className: `flex justify-between mt-4 ${shortGaps ? 'gap-x-3' : 'gap-x-[101px]'}`, children: steps.map((0, renderStepContent_1.renderStepContent)({ styleMap, isMainButton: Boolean(button?.text), version })) })] })) : null, button?.text ? (0, jsx_runtime_1.jsx)(Button_1.Button, { className: "mt-8 min-w-60", version: "primary", ...button }) : null] }));
22
+ return ((0, jsx_runtime_1.jsxs)(BlockWrapper_1.BlockWrapper, { className: (0, style_1.style)('box-border py-12', shortGaps ? 'px-20' : 'px-[70px]', 'flex flex-col items-center overflow-hidden', className), version: version, ...rest, children: [title ? ((0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: "h3", className: "max-w-[752px] text-center mb-9", title: title })) : null, steps?.length ? ((0, jsx_runtime_1.jsxs)("div", { className: "box-border", children: [(0, jsx_runtime_1.jsx)("div", { className: (0, style_1.style)('flex items-center', paddingX), children: (0, joinList_1.joinList)((0, jsx_runtime_1.jsx)("div", { className: (0, style_1.style)('h-0.5 w-full bg-secondary-light', lineOpacity) }))(steps.map(renderStepIcon(styleMap, version))) }), (0, jsx_runtime_1.jsx)("div", { className: (0, style_1.style)('flex justify-between mt-4', shortGaps ? 'gap-x-3' : 'gap-x-[101px]'), children: steps.map((0, renderStep_1.renderStep)({ styleMap, isMainButton: Boolean(button?.text), version })) })] })) : null, button?.text ? (0, jsx_runtime_1.jsx)(Button_1.Button, { className: "mt-8 min-w-60", version: "primary", ...button }) : null] }));
29
23
  });
30
- const renderStepIcon = (styleMap, version) => ({ icon }, i) => ((0, jsx_runtime_1.jsx)("div", { className: "flex flex-col items-center text-center", children: (0, jsx_runtime_1.jsx)("div", { className: `h-[100px] w-[100px] min-w-[100px] min-h-[100px] rounded-full p-[26px] box-border z-10 flex justify-center items-center ${styleMap.iconBackground}`, children: (0, checkIsIconRenderable_1.checkIsIconRenderable)(icon) ? ((0, jsx_runtime_1.jsx)(Img_1.Img, { image: (0, getIconWithVersion_1.getIconWithVersion)(icon || {}, version), width: "48", height: "48", asSVG: true })) : ((0, jsx_runtime_1.jsx)("span", { className: `text-h4 ${styleMap.iconText}`, children: i + 1 })) }) }, String(i)));
24
+ const renderStepIcon = (styleMap, version) => ({ icon }, i) => ((0, jsx_runtime_1.jsx)("div", { className: "flex flex-col items-center text-center", children: (0, jsx_runtime_1.jsx)("div", { className: `h-[100px] w-[100px] min-w-[100px] min-h-[100px] rounded-full p-[26px] box-border z-10 flex justify-center items-center ${styleMap.iconBackground}`, children: (0, checkCanRenderIcon_1.checkCanRenderIcon)(icon) ? ((0, jsx_runtime_1.jsx)(Img_1.Img, { image: (0, getIconWithVersion_1.getIconWithVersion)(icon || {}, version), width: "48", height: "48", asSVG: true })) : ((0, jsx_runtime_1.jsx)("span", { className: `text-h4 ${styleMap.iconText}`, children: i + 1 })) }) }, String(i)));
31
25
  //# sourceMappingURL=StepsBlock.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"StepsBlock.js","sourceRoot":"","sources":["../../../src/components/StepsBlock/StepsBlock.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAGxC,4DAAyD;AACzD,uDAAoD;AACpD,0DAAuD;AACvD,8CAA2C;AAC3C,6EAA0E;AAC1E,uEAAoE;AACpE,mDAAgD;AAChD,2DAAwD;AAGxD,+DAA+D;AAI/D,MAAM,cAAc,GAAG,CAAC,SAAkB,EAAE,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC;AAE9E,MAAM,WAAW,GAAG,CAAC,KAAa,EAAE,EAAE,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC;AAElE,QAAA,UAAU,GAAG,IAAA,aAAG,EAC3B,CAAC,EAAE,SAAS,GAAG,EAAE,EAAE,SAAS,GAAG,IAAI,EAAE,KAAK,GAAG,EAAE,EAAE,MAAM,EAAE,OAAO,GAAG,SAAS,EAAE,GA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