@redneckz/wildless-cms-uni-blocks 0.14.287 → 0.14.289

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 (283) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +137 -94
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/bundle/components/ApplicationFormCustom/ApplicationFormCustomContent.d.ts +11 -4
  5. package/bundle/components/ApplicationFormCustom/getFormatData.d.ts +2 -3
  6. package/bundle/components/ApplicationFormCustom/getInitialFormState.d.ts +4 -0
  7. package/bundle/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.d.ts +2 -0
  8. package/bundle/components/Header/HeaderSecondaryMenuButton.d.ts +2 -0
  9. package/bundle/components/Header/HeaderSubMenu.d.ts +2 -6
  10. package/bundle/data/SitemapData.d.ts +10 -4
  11. package/bundle/hooks/useAspects/handleAspects.d.ts +10 -0
  12. package/bundle/hooks/useForm.d.ts +4 -4
  13. package/bundle/model/AspectsProps.d.ts +1 -1
  14. package/bundle/model/LogoType.d.ts +4 -1
  15. package/bundle/ui-kit/LinkWrapper/LinkWrapper.d.ts +2 -0
  16. package/dist/components/ApplicationFormCustom/ApplicationFormCustom.js +13 -6
  17. package/dist/components/ApplicationFormCustom/ApplicationFormCustom.js.map +1 -1
  18. package/dist/components/ApplicationFormCustom/ApplicationFormCustomContent.d.ts +11 -4
  19. package/dist/components/ApplicationFormCustom/getFormatData.d.ts +2 -3
  20. package/dist/components/ApplicationFormCustom/getFormatData.js.map +1 -1
  21. package/dist/components/ApplicationFormCustom/getInitialFormState.d.ts +4 -0
  22. package/dist/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  23. package/dist/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js +2 -2
  24. package/dist/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js.map +1 -1
  25. package/dist/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.d.ts +2 -0
  26. package/dist/components/Footer/Footer.mobile.js +1 -1
  27. package/dist/components/Footer/Footer.mobile.js.map +1 -1
  28. package/dist/components/Header/Header.js +1 -1
  29. package/dist/components/Header/Header.js.map +1 -1
  30. package/dist/components/Header/HeaderSecondaryMenu.js +22 -1
  31. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  32. package/dist/components/Header/HeaderSecondaryMenuButton.d.ts +2 -0
  33. package/dist/components/Header/HeaderSecondaryMenuButton.js +3 -2
  34. package/dist/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  35. package/dist/components/Header/HeaderSubMenu.d.ts +2 -6
  36. package/dist/components/Header/HeaderSubMenu.js +1 -1
  37. package/dist/components/Header/HeaderSubMenu.js.map +1 -1
  38. package/dist/components/StickyBottomMenu/BurgerMenuDialog.js +9 -3
  39. package/dist/components/StickyBottomMenu/BurgerMenuDialog.js.map +1 -1
  40. package/dist/data/SitemapData.d.ts +10 -4
  41. package/dist/hooks/useAspects/applyAspects.js +2 -3
  42. package/dist/hooks/useAspects/applyAspects.js.map +1 -1
  43. package/dist/hooks/useAspects/handleAspects.d.ts +10 -0
  44. package/dist/hooks/useAspects/handleAspects.js +10 -0
  45. package/dist/hooks/useAspects/handleAspects.js.map +1 -0
  46. package/dist/hooks/useForm.d.ts +4 -4
  47. package/dist/hooks/useForm.js +4 -4
  48. package/dist/hooks/useForm.js.map +1 -1
  49. package/dist/model/AspectsProps.d.ts +1 -1
  50. package/dist/model/LogoType.d.ts +4 -1
  51. package/dist/ui-kit/HeaderItem/HeaderItem.js +3 -2
  52. package/dist/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  53. package/dist/ui-kit/InputRange/InputRange.js +2 -2
  54. package/dist/ui-kit/InputRange/InputRange.js.map +1 -1
  55. package/dist/ui-kit/InputRange/renderRangeWithTicks.js +2 -2
  56. package/dist/ui-kit/InputRange/renderRangeWithTicks.js.map +1 -1
  57. package/dist/ui-kit/LinkWrapper/LinkWrapper.d.ts +2 -0
  58. package/dist/ui-kit/LinkWrapper/LinkWrapper.js +3 -2
  59. package/dist/ui-kit/LinkWrapper/LinkWrapper.js.map +1 -1
  60. package/dist/ui-kit/LocationDialog/renderRegion.js +13 -1
  61. package/dist/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  62. package/dist/ui-kit/Logo/Logo.js +2 -1
  63. package/dist/ui-kit/Logo/Logo.js.map +1 -1
  64. package/dist/ui-kit/PhoneInput/PhoneInput.js +1 -1
  65. package/dist/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  66. package/dist/ui-kit/TopItem/TopItem.js +3 -2
  67. package/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  68. package/lib/components/ApplicationFormCustom/ApplicationFormCustom.js +14 -7
  69. package/lib/components/ApplicationFormCustom/ApplicationFormCustom.js.map +1 -1
  70. package/lib/components/ApplicationFormCustom/ApplicationFormCustomContent.d.ts +11 -4
  71. package/lib/components/ApplicationFormCustom/getFormatData.d.ts +2 -3
  72. package/lib/components/ApplicationFormCustom/getFormatData.js.map +1 -1
  73. package/lib/components/ApplicationFormCustom/getInitialFormState.d.ts +4 -0
  74. package/lib/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  75. package/lib/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js +2 -2
  76. package/lib/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js.map +1 -1
  77. package/lib/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.d.ts +2 -0
  78. package/lib/components/Footer/Footer.mobile.js +1 -1
  79. package/lib/components/Footer/Footer.mobile.js.map +1 -1
  80. package/lib/components/Header/Header.js +1 -1
  81. package/lib/components/Header/Header.js.map +1 -1
  82. package/lib/components/Header/HeaderSecondaryMenu.js +22 -1
  83. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  84. package/lib/components/Header/HeaderSecondaryMenuButton.d.ts +2 -0
  85. package/lib/components/Header/HeaderSecondaryMenuButton.js +3 -2
  86. package/lib/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  87. package/lib/components/Header/HeaderSubMenu.d.ts +2 -6
  88. package/lib/components/Header/HeaderSubMenu.js +1 -1
  89. package/lib/components/Header/HeaderSubMenu.js.map +1 -1
  90. package/lib/components/StickyBottomMenu/BurgerMenuDialog.js +9 -3
  91. package/lib/components/StickyBottomMenu/BurgerMenuDialog.js.map +1 -1
  92. package/lib/data/SitemapData.d.ts +10 -4
  93. package/lib/hooks/useAspects/applyAspects.js +2 -3
  94. package/lib/hooks/useAspects/applyAspects.js.map +1 -1
  95. package/lib/hooks/useAspects/handleAspects.d.ts +10 -0
  96. package/lib/hooks/useAspects/handleAspects.js +7 -0
  97. package/lib/hooks/useAspects/handleAspects.js.map +1 -0
  98. package/lib/hooks/useForm.d.ts +4 -4
  99. package/lib/hooks/useForm.js +4 -4
  100. package/lib/hooks/useForm.js.map +1 -1
  101. package/lib/model/AspectsProps.d.ts +1 -1
  102. package/lib/model/LogoType.d.ts +4 -1
  103. package/lib/ui-kit/HeaderItem/HeaderItem.js +3 -2
  104. package/lib/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  105. package/lib/ui-kit/InputRange/InputRange.js +2 -2
  106. package/lib/ui-kit/InputRange/InputRange.js.map +1 -1
  107. package/lib/ui-kit/InputRange/renderRangeWithTicks.js +2 -2
  108. package/lib/ui-kit/InputRange/renderRangeWithTicks.js.map +1 -1
  109. package/lib/ui-kit/LinkWrapper/LinkWrapper.d.ts +2 -0
  110. package/lib/ui-kit/LinkWrapper/LinkWrapper.js +3 -2
  111. package/lib/ui-kit/LinkWrapper/LinkWrapper.js.map +1 -1
  112. package/lib/ui-kit/LocationDialog/renderRegion.js +13 -1
  113. package/lib/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  114. package/lib/ui-kit/Logo/Logo.js +2 -1
  115. package/lib/ui-kit/Logo/Logo.js.map +1 -1
  116. package/lib/ui-kit/PhoneInput/PhoneInput.js +1 -1
  117. package/lib/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  118. package/lib/ui-kit/TopItem/TopItem.js +3 -2
  119. package/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  120. package/mobile/bundle/bundle.umd.js +113 -87
  121. package/mobile/bundle/bundle.umd.min.js +1 -1
  122. package/mobile/bundle/components/ApplicationFormCustom/ApplicationFormCustomContent.d.ts +11 -4
  123. package/mobile/bundle/components/ApplicationFormCustom/getFormatData.d.ts +2 -3
  124. package/mobile/bundle/components/ApplicationFormCustom/getInitialFormState.d.ts +4 -0
  125. package/mobile/bundle/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.d.ts +2 -0
  126. package/mobile/bundle/components/Header/HeaderSecondaryMenuButton.d.ts +2 -0
  127. package/mobile/bundle/components/Header/HeaderSubMenu.d.ts +2 -6
  128. package/mobile/bundle/data/SitemapData.d.ts +10 -4
  129. package/mobile/bundle/hooks/useAspects/handleAspects.d.ts +10 -0
  130. package/mobile/bundle/hooks/useForm.d.ts +4 -4
  131. package/mobile/bundle/model/AspectsProps.d.ts +1 -1
  132. package/mobile/bundle/model/LogoType.d.ts +4 -1
  133. package/mobile/bundle/ui-kit/LinkWrapper/LinkWrapper.d.ts +2 -0
  134. package/mobile/dist/components/ApplicationFormCustom/ApplicationFormCustom.js +13 -6
  135. package/mobile/dist/components/ApplicationFormCustom/ApplicationFormCustom.js.map +1 -1
  136. package/mobile/dist/components/ApplicationFormCustom/ApplicationFormCustomContent.d.ts +11 -4
  137. package/mobile/dist/components/ApplicationFormCustom/getFormatData.d.ts +2 -3
  138. package/mobile/dist/components/ApplicationFormCustom/getFormatData.js.map +1 -1
  139. package/mobile/dist/components/ApplicationFormCustom/getInitialFormState.d.ts +4 -0
  140. package/mobile/dist/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  141. package/mobile/dist/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js +2 -2
  142. package/mobile/dist/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js.map +1 -1
  143. package/mobile/dist/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.d.ts +2 -0
  144. package/mobile/dist/components/Footer/Footer.js +1 -1
  145. package/mobile/dist/components/Footer/Footer.js.map +1 -1
  146. package/mobile/dist/components/Header/HeaderSecondaryMenu.js +22 -1
  147. package/mobile/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  148. package/mobile/dist/components/Header/HeaderSecondaryMenuButton.d.ts +2 -0
  149. package/mobile/dist/components/Header/HeaderSecondaryMenuButton.js +3 -2
  150. package/mobile/dist/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  151. package/mobile/dist/components/Header/HeaderSubMenu.d.ts +2 -6
  152. package/mobile/dist/components/Header/HeaderSubMenu.js +1 -1
  153. package/mobile/dist/components/Header/HeaderSubMenu.js.map +1 -1
  154. package/mobile/dist/components/StickyBottomMenu/BurgerMenuDialog.js +9 -3
  155. package/mobile/dist/components/StickyBottomMenu/BurgerMenuDialog.js.map +1 -1
  156. package/mobile/dist/data/SitemapData.d.ts +10 -4
  157. package/mobile/dist/hooks/useAspects/applyAspects.js +2 -3
  158. package/mobile/dist/hooks/useAspects/applyAspects.js.map +1 -1
  159. package/mobile/dist/hooks/useAspects/handleAspects.d.ts +10 -0
  160. package/mobile/dist/hooks/useAspects/handleAspects.js +10 -0
  161. package/mobile/dist/hooks/useAspects/handleAspects.js.map +1 -0
  162. package/mobile/dist/hooks/useForm.d.ts +4 -4
  163. package/mobile/dist/hooks/useForm.js +4 -4
  164. package/mobile/dist/hooks/useForm.js.map +1 -1
  165. package/mobile/dist/model/AspectsProps.d.ts +1 -1
  166. package/mobile/dist/model/LogoType.d.ts +4 -1
  167. package/mobile/dist/ui-kit/InputRange/InputRange.js +2 -2
  168. package/mobile/dist/ui-kit/InputRange/InputRange.js.map +1 -1
  169. package/mobile/dist/ui-kit/InputRange/renderRangeWithTicks.js +2 -2
  170. package/mobile/dist/ui-kit/InputRange/renderRangeWithTicks.js.map +1 -1
  171. package/mobile/dist/ui-kit/LinkWrapper/LinkWrapper.d.ts +2 -0
  172. package/mobile/dist/ui-kit/LinkWrapper/LinkWrapper.js +3 -2
  173. package/mobile/dist/ui-kit/LinkWrapper/LinkWrapper.js.map +1 -1
  174. package/mobile/dist/ui-kit/LocationDialog/renderRegion.js +13 -1
  175. package/mobile/dist/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  176. package/mobile/dist/ui-kit/Logo/Logo.js +2 -1
  177. package/mobile/dist/ui-kit/Logo/Logo.js.map +1 -1
  178. package/mobile/dist/ui-kit/PhoneInput/PhoneInput.js +1 -1
  179. package/mobile/dist/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  180. package/mobile/dist/ui-kit/TopItem/TopItem.js +3 -2
  181. package/mobile/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  182. package/mobile/lib/components/ApplicationFormCustom/ApplicationFormCustom.js +14 -7
  183. package/mobile/lib/components/ApplicationFormCustom/ApplicationFormCustom.js.map +1 -1
  184. package/mobile/lib/components/ApplicationFormCustom/ApplicationFormCustomContent.d.ts +11 -4
  185. package/mobile/lib/components/ApplicationFormCustom/getFormatData.d.ts +2 -3
  186. package/mobile/lib/components/ApplicationFormCustom/getFormatData.js.map +1 -1
  187. package/mobile/lib/components/ApplicationFormCustom/getInitialFormState.d.ts +4 -0
  188. package/mobile/lib/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  189. package/mobile/lib/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js +2 -2
  190. package/mobile/lib/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.js.map +1 -1
  191. package/mobile/lib/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.d.ts +2 -0
  192. package/mobile/lib/components/Footer/Footer.js +1 -1
  193. package/mobile/lib/components/Footer/Footer.js.map +1 -1
  194. package/mobile/lib/components/Header/HeaderSecondaryMenu.js +22 -1
  195. package/mobile/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  196. package/mobile/lib/components/Header/HeaderSecondaryMenuButton.d.ts +2 -0
  197. package/mobile/lib/components/Header/HeaderSecondaryMenuButton.js +3 -2
  198. package/mobile/lib/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  199. package/mobile/lib/components/Header/HeaderSubMenu.d.ts +2 -6
  200. package/mobile/lib/components/Header/HeaderSubMenu.js +1 -1
  201. package/mobile/lib/components/Header/HeaderSubMenu.js.map +1 -1
  202. package/mobile/lib/components/StickyBottomMenu/BurgerMenuDialog.js +9 -3
  203. package/mobile/lib/components/StickyBottomMenu/BurgerMenuDialog.js.map +1 -1
  204. package/mobile/lib/data/SitemapData.d.ts +10 -4
  205. package/mobile/lib/hooks/useAspects/applyAspects.js +2 -3
  206. package/mobile/lib/hooks/useAspects/applyAspects.js.map +1 -1
  207. package/mobile/lib/hooks/useAspects/handleAspects.d.ts +10 -0
  208. package/mobile/lib/hooks/useAspects/handleAspects.js +7 -0
  209. package/mobile/lib/hooks/useAspects/handleAspects.js.map +1 -0
  210. package/mobile/lib/hooks/useForm.d.ts +4 -4
  211. package/mobile/lib/hooks/useForm.js +4 -4
  212. package/mobile/lib/hooks/useForm.js.map +1 -1
  213. package/mobile/lib/model/AspectsProps.d.ts +1 -1
  214. package/mobile/lib/model/LogoType.d.ts +4 -1
  215. package/mobile/lib/ui-kit/InputRange/InputRange.js +2 -2
  216. package/mobile/lib/ui-kit/InputRange/InputRange.js.map +1 -1
  217. package/mobile/lib/ui-kit/InputRange/renderRangeWithTicks.js +2 -2
  218. package/mobile/lib/ui-kit/InputRange/renderRangeWithTicks.js.map +1 -1
  219. package/mobile/lib/ui-kit/LinkWrapper/LinkWrapper.d.ts +2 -0
  220. package/mobile/lib/ui-kit/LinkWrapper/LinkWrapper.js +3 -2
  221. package/mobile/lib/ui-kit/LinkWrapper/LinkWrapper.js.map +1 -1
  222. package/mobile/lib/ui-kit/LocationDialog/renderRegion.js +13 -1
  223. package/mobile/lib/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  224. package/mobile/lib/ui-kit/Logo/Logo.js +2 -1
  225. package/mobile/lib/ui-kit/Logo/Logo.js.map +1 -1
  226. package/mobile/lib/ui-kit/PhoneInput/PhoneInput.js +1 -1
  227. package/mobile/lib/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  228. package/mobile/lib/ui-kit/TopItem/TopItem.js +3 -2
  229. package/mobile/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  230. package/mobile/src/components/ApplicationFormCustom/ApplicationFormCustom.example.json +0 -1
  231. package/mobile/src/components/ApplicationFormCustom/ApplicationFormCustom.tsx +31 -16
  232. package/mobile/src/components/ApplicationFormCustom/ApplicationFormCustomContent.ts +11 -4
  233. package/mobile/src/components/ApplicationFormCustom/getFormatData.tsx +6 -5
  234. package/mobile/src/components/ApplicationFormCustom/getInitialFormState.tsx +4 -0
  235. package/mobile/src/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.tsx +2 -1
  236. package/mobile/src/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.ts +2 -0
  237. package/mobile/src/components/Footer/Footer.tsx +1 -1
  238. package/mobile/src/components/Header/HeaderSecondaryMenu.tsx +26 -2
  239. package/mobile/src/components/Header/HeaderSecondaryMenuButton.tsx +6 -0
  240. package/mobile/src/components/Header/HeaderSubMenu.tsx +3 -6
  241. package/mobile/src/components/StickyBottomMenu/BurgerMenuDialog.tsx +18 -7
  242. package/mobile/src/data/SitemapData.ts +10 -3
  243. package/mobile/src/hooks/useAspects/applyAspects.ts +2 -4
  244. package/mobile/src/hooks/useAspects/handleAspects.ts +18 -0
  245. package/mobile/src/hooks/useForm.ts +12 -6
  246. package/mobile/src/model/AspectsProps.ts +1 -1
  247. package/mobile/src/model/LogoType.ts +2 -1
  248. package/mobile/src/ui-kit/InputRange/InputRange.tsx +2 -2
  249. package/mobile/src/ui-kit/InputRange/renderRangeWithTicks.tsx +2 -2
  250. package/mobile/src/ui-kit/LinkWrapper/LinkWrapper.tsx +6 -1
  251. package/mobile/src/ui-kit/LocationDialog/renderRegion.tsx +14 -0
  252. package/mobile/src/ui-kit/Logo/Logo.tsx +3 -0
  253. package/mobile/src/ui-kit/PhoneInput/PhoneInput.tsx +2 -2
  254. package/mobile/src/ui-kit/TopItem/TopItem.tsx +21 -16
  255. package/package.json +1 -1
  256. package/src/components/ApplicationFormCustom/ApplicationFormCustom.example.json +0 -1
  257. package/src/components/ApplicationFormCustom/ApplicationFormCustom.tsx +31 -16
  258. package/src/components/ApplicationFormCustom/ApplicationFormCustomContent.ts +11 -4
  259. package/src/components/ApplicationFormCustom/getFormatData.tsx +6 -5
  260. package/src/components/ApplicationFormCustom/getInitialFormState.tsx +4 -0
  261. package/src/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.fixture.tsx +8 -0
  262. package/src/components/ApplicationFormGrantSupport/ApplicationFormGrantSupport.tsx +2 -1
  263. package/src/components/ApplicationFormGrantSupport/ApplicationFormGrantSupportContent.ts +2 -0
  264. package/src/components/Footer/Footer.mobile.tsx +1 -1
  265. package/src/components/Header/Header.tsx +1 -1
  266. package/src/components/Header/HeaderSecondaryMenu.tsx +26 -2
  267. package/src/components/Header/HeaderSecondaryMenuButton.tsx +6 -0
  268. package/src/components/Header/HeaderSubMenu.tsx +3 -6
  269. package/src/components/StickyBottomMenu/BurgerMenuDialog.tsx +18 -7
  270. package/src/data/SitemapData.ts +10 -3
  271. package/src/hooks/useAspects/applyAspects.ts +2 -4
  272. package/src/hooks/useAspects/handleAspects.ts +18 -0
  273. package/src/hooks/useForm.ts +12 -6
  274. package/src/model/AspectsProps.ts +1 -1
  275. package/src/model/LogoType.ts +2 -1
  276. package/src/ui-kit/HeaderItem/HeaderItem.tsx +4 -1
  277. package/src/ui-kit/InputRange/InputRange.tsx +2 -2
  278. package/src/ui-kit/InputRange/renderRangeWithTicks.tsx +2 -2
  279. package/src/ui-kit/LinkWrapper/LinkWrapper.tsx +6 -1
  280. package/src/ui-kit/LocationDialog/renderRegion.tsx +14 -0
  281. package/src/ui-kit/Logo/Logo.tsx +3 -0
  282. package/src/ui-kit/PhoneInput/PhoneInput.tsx +2 -2
  283. package/src/ui-kit/TopItem/TopItem.tsx +21 -16
@@ -1,3 +1,4 @@
1
+ import { type AspectsProps } from '../../model/AspectsProps';
1
2
  import { type Target } from '../../model/LinkProps';
2
3
  interface LinkWrapperProps {
3
4
  className?: string;
@@ -5,6 +6,7 @@ interface LinkWrapperProps {
5
6
  target?: Target;
6
7
  isRemote?: boolean;
7
8
  onClick?: () => void;
9
+ data?: AspectsProps;
8
10
  }
9
11
  export declare const LinkWrapper: import("@redneckz/uni-jsx").UNIComponent<LinkWrapperProps, any, any>;
10
12
  export {};
@@ -1,11 +1,12 @@
1
1
  import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
3
  import { useLink } from '../../hooks/useLink.js';
4
+ import { getAspectsAttributes } from '../../utils/dataAttributes.js';
4
5
  import { style } from '../../utils/style.js';
5
- export const LinkWrapper = JSX(({ className = '', href, target, isRemote = false, onClick, children }) => {
6
+ export const LinkWrapper = JSX(({ className = '', href, target, isRemote = false, onClick, data, children }) => {
6
7
  const link = useLink({ isRemote });
7
8
  const linkProps = link({ href, target, onClick });
8
9
  const Tag = href ? 'a' : 'div';
9
- return (_jsx(Tag, { className: style('block', className), ...(href ? linkProps : {}), role: href ? 'link' : 'none', children: children }));
10
+ return (_jsx(Tag, { className: style('block', className), ...(href ? linkProps : {}), role: href ? 'link' : 'none', ...getAspectsAttributes(data), children: children }));
10
11
  });
11
12
  //# sourceMappingURL=LinkWrapper.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LinkWrapper.js","sourceRoot":"","sources":["../../../src/ui-kit/LinkWrapper/LinkWrapper.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;A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Q,EAAE,CAAC,CAAC;IACnC,MAAM,SAAS,GAAG,IAAI,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,CAAC;IAClD,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC;IAE/B,OAAO,CACL,KAAC,GAAG,IACF,SAAS,EAAE,KAAK,CAAC,OAAO,EAAE,SAAS,CAAC,KAChC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,EAC3B,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,KAExB,oBAAoB,CAAC,IAAI,CAAC,YAE7B,QAAQ,GACL,CACP,CAAC;AACJ,CAAC,CACF,CAAC"}
@@ -1,7 +1,19 @@
1
1
  import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { LinkWrapper } from '../LinkWrapper/LinkWrapper.js';
3
3
  import { Text } from '../Text/Text.js';
4
+ const MINDBOX_ASPECT = 'mindboxEvent';
5
+ const MINDBOX_CATEGORY = 'header';
6
+ const MINDBOX_EVENT_REGION_NEW_CLICK = 'headerRegionNewSelect';
4
7
  export const renderRegion = (onChangeLocation) => (region) => region.name ? (_jsx(LinkWrapper, { isRemote: true, href: `/branches/${region.slug}`, className: "mb-xs sm:mb-2xs hover:text-primary-hover", onClick: () => {
5
8
  onChangeLocation && onChangeLocation(region);
6
- }, children: _jsx(Text, { size: "text-l", font: "font-light", children: region.name }) }, String(region.id))) : null;
9
+ }, data: [
10
+ {
11
+ aspectName: MINDBOX_ASPECT,
12
+ params: {
13
+ eventAction: MINDBOX_EVENT_REGION_NEW_CLICK,
14
+ eventCategory: MINDBOX_CATEGORY,
15
+ eventValueText: region.name,
16
+ },
17
+ },
18
+ ], children: _jsx(Text, { size: "text-l", font: "font-light", children: region.name }) }, String(region.id))) : null;
7
19
  //# sourceMappingURL=renderRegion.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"renderRegion.js","sourceRoot":"","sources":["../../../src/ui-kit/LocationDialog/renderRegion.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEpC,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,gBAA2C,EAAE,EAAE,CAAC,CAAC,MAAc,EAAE,EAAE,CAC9F,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,CACZ,KAAC,WAAW,IAEV,QAAQ,QACR,IAAI,EAAE,aAAa,MAAM,CAAC,IAAI,EAAE,EAChC,SAAS,EAAC,0CAA0C,EACpD,OAAO,EAAE,GAAG,EAAE;QACZ,gBAAgB,IAAI,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAC/C,CAAC,YAED,KAAC,IAAI,IAAC,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,YAAY,YAClC,MAAM,CAAC,IAAI,GACP,IAVF,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAWV,CACf,CAAC,CAAC,CAAC,IAAI,CAAC"}
1
+ {"version":3,"file":"renderRegion.js","sourceRoot":"","sources":["../../../src/ui-kit/LocationDialog/renderRegion.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEpC,MAAM,cAAc,GAAG,cAAc,CAAC;AACtC,MAAM,gBAAgB,GAAG,QAAQ,CAAC;AAClC,MAAM,8BAA8B,GAAG,uBAAuB,CAAC;AAE/D,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,gBAA2C,EAAE,EAAE,CAAC,CAAC,MAAc,EAAE,EAAE,CAC9F,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,CACZ,KAAC,WAAW,IAEV,QAAQ,QACR,IAAI,EAAE,aAAa,MAAM,CAAC,IAAI,EAAE,EAChC,SAAS,EAAC,0CAA0C,EACpD,OAAO,EAAE,GAAG,EAAE;QACZ,gBAAgB,IAAI,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAC/C,CAAC,EACD,IAAI,EAAE;QACJ;YACE,UAAU,EAAE,cAAc;YAC1B,MAAM,EAAE;gBACN,WAAW,EAAE,8BAA8B;gBAC3C,aAAa,EAAE,gBAAgB;gBAC/B,cAAc,EAAE,MAAM,CAAC,IAAI;aAC5B;SACF;KACF,YAED,KAAC,IAAI,IAAC,IAAI,EAAC,QAAQ,EAAC,IAAI,EAAC,YAAY,YAClC,MAAM,CAAC,IAAI,GACP,IApBF,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAqBV,CACf,CAAC,CAAC,CAAC,IAAI,CAAC"}
@@ -1,5 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
+ import { getAspectsAttributes } from '../../utils/dataAttributes.js';
3
4
  import { style } from '../../utils/style.js';
4
5
  import { Text } from '../Text/Text.js';
5
6
  import { ICON_SIZE } from './iconSize.js';
@@ -9,7 +10,7 @@ const TEXT_COLOR = {
9
10
  'bg-white': 'text-primary-text',
10
11
  transparent: 'text-white',
11
12
  };
12
- export const Logo = JSX(({ className, href = '/', logo, children, targetBlank, bgColor = 'bg-white', showTitle = true, }) => (_jsxs("a", { className: style('inline-flex items-center font-sans no-underline', className), href: href, target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title ?? 'Россельхозбанк', children: [renderImage(bgColor, logo?.image, ICON_SIZE), showTitle
13
+ export const Logo = JSX(({ className, href = '/', logo, children, targetBlank, bgColor = 'bg-white', showTitle = true, }) => (_jsxs("a", { className: style('inline-flex items-center font-sans no-underline', className), href: href, target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title ?? 'Россельхозбанк', ...getAspectsAttributes(logo?.data), children: [renderImage(bgColor, logo?.image, ICON_SIZE), showTitle
13
14
  ? children ?? (_jsx("div", { className: "ml-s", children: _jsx(Text, { font: "font-medium", color: TEXT_COLOR[bgColor], size: logoTitleSizeStyle, children: logo?.title ?? 'Россельхозбанк' }) }))
14
15
  : null] })));
15
16
  //# sourceMappingURL=Logo.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Logo.js","sourceRoot":"","sources":["../../../src/ui-kit/Logo/Logo.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEpC,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAW5C,MAAM,UAAU,GAAsC;IACpD,UAAU,EAAE,mBAAmB;IAC/B,WAAW,EAAE,YAAY;CAC1B,CAAC;AAEF,MAAM,CAAC,MAAM,IAAI,GAAG,GAAG,CACrB,CAAC,EACC,SAAS,EACT,IAAI,GAAG,GAAG,EACV,IAAI,EACJ,QAAQ,EACR,WAAW,EACX,OAAO,GAAG,UAAU,EACpB,SAAS,GAAG,IAAI,GACjB,EAAE,EAAE,CAAC,CACJ,aACE,SAAS,EAAE,KAAK,CAAC,iDAAiD,EAAE,SAAS,CAAC,EAC9E,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,OAAO,gBAC5B,IAAI,EAAE,KAAK,IAAI,gBAAgB,aAE1C,WAAW,CAAC,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,SAAS,CAAC,EAC5C,SAAS;YACR,CAAC,CAAC,QAAQ,IAAI,CACV,cAAK,SAAS,EAAC,MAAM,YACnB,KAAC,IAAI,IAAC,IAA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S;YACR,CAAC,CAAC,QAAQ,IAAI,CACV,cAAK,SAAS,EAAC,MAAM,YACnB,KAAC,IAAI,IAAC,IAAI,EAAC,aAAa,EAAC,KAAK,EAAE,UAAU,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE,kBAAkB,YAC1E,IAAI,EAAE,KAAK,IAAI,gBAAgB,GAC3B,GACH,CACP;YACH,CAAC,CAAC,IAAI,IACN,CACL,CACF,CAAC"}
@@ -8,6 +8,6 @@ export const PhoneInput = JSX(({ children, onChange, ...inputProps }) => {
8
8
  const handleBlur = useCallback((v) => {
9
9
  v === '+7 (' ? onChange && onChange('') : null;
10
10
  }, []);
11
- return (_jsx(Input, { ...inputProps, onChange: handleChange, onFocus: (e) => handleChange(e?.target?.value || ''), onBlur: (e) => handleBlur(e?.target?.value || ''), children: children }));
11
+ return (_jsx(Input, { ...inputProps, onChange: handleChange, onFocus: (ev) => handleChange(ev?.target?.value || ''), onBlur: (ev) => handleBlur(ev?.target?.value || ''), children: children }));
12
12
  });
13
13
  //# sourceMappingURL=PhoneInput.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PhoneInput.js","sourceRoot":"","sources":["../../../src/ui-kit/PhoneInput/PhoneInput.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAC1D,OAAO,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAEvC,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAElD,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,CAAa,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,UAAU,EAAE,EAAE,EAAE;IAClF,MAAM,YAAY,GAAG,WAAW,CAC9B,CAAC,CAAS,EAAE,EAAE,CAAC,QAAQ,IAAI,QAAQ,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,EACtD,CAAC,QAAQ,C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,CAAC,QAAQ,IAAI,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;IACjD,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACL,KAAC,KAAK,OACA,UAAU,EACd,QAAQ,EAAE,YAAY,EACtB,OAAO,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,YAAY,CAAE,EAAE,EAAE,MAA2B,EAAE,KAAK,IAAI,EAAE,CAAC,EAC5E,MAAM,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,UAAU,CAAE,EAAE,EAAE,MAA2B,EAAE,KAAK,IAAI,EAAE,CAAC,YAExE,QAAQ,GACH,CACT,CAAC;AACJ,CAAC,CAAC,CAAC"}
@@ -1,11 +1,12 @@
1
1
  import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
3
  import { useLink } from '../../hooks/useLink.js';
4
+ import { getAspectsAttributes } from '../../utils/dataAttributes.js';
4
5
  import { style } from '../../utils/style.js';
5
- export const TopItem = JSX(({ className = '', active, flat, children, ...rest }) => {
6
+ export const TopItem = JSX(({ className = '', active, flat, children, data, ...rest }) => {
6
7
  const link = useLink({ isRemote: true });
7
8
  const { href, target, text, onClick } = link(rest);
8
- return (_jsx("a", { className: style(getLinkStyle(active, flat), className), href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": text, children: _jsx("span", { className: getTextStyle(active, flat), children: text || children }) }));
9
+ return (_jsx("a", { className: style(getLinkStyle(active, flat), className), href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": text, ...getAspectsAttributes(data), children: _jsx("span", { className: getTextStyle(active, flat), children: text || children }) }));
9
10
  });
10
11
  const getLinkStyle = (active = false, flat = false) => style('inline-block border border-solid bg-transparent text-center no-underline', active
11
12
  ? 'rounded-md border-primary-main group-data-transparent:border-white'
@@ -1 +1 @@
1
- {"version":3,"file":"TopItem.js","sourceRoot":"","sources":["../../../src/ui-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AK,EAAE,IAAI,GAAG,KAAK,EAAE,EAAE,CACpD,KAAK,CACH,0EAA0E,EAC1E,MAAM;IACJ,CAAC,CAAC,oEAAoE;IACtE,CAAC,CAAC,oBAAoB,EACxB,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,YAAY,CACzB,CAAC;AAEJ,MAAM,YAAY,GAAG,CAAC,MAAM,GAAG,KAAK,EAAE,IAAI,GAAG,KAAK,EAAE,EAAE,CACpD,KAAK,CACH,6BAA6B,EAC7B,MAAM;IACJ,CAAC,CAAC,mBAAmB;IACrB,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,qBAAqB,EAAE,yBAAyB,CAAC,EACxF,mFAAmF,CACpF,CAAC"}
@@ -889,9 +889,76 @@
889
889
  : { secondaryPhoneNumber: formatPhone(secondaryPhone) };
890
890
  };
891
891
 
892
+ const handleAspects = ({ aspectsAttributes, aspects, ev, formData }) => {
893
+ for (const { aspectName, params } of aspectsAttributes) {
894
+ const paramsData = aspectName === 'mindboxEvent' ? { ...params, eventJson: JSON.stringify(formData) } : params;
895
+ aspects[aspectName ?? '']?.(ev, paramsData);
896
+ }
897
+ };
898
+
899
+ const QUERY_STORAGE_KEY = 'rshb-query-params';
900
+ function saveSessionQuery() {
901
+ const result = globalThis.location?.search || globalThis.sessionStorage?.getItem(QUERY_STORAGE_KEY) || '';
902
+ if (result) {
903
+ globalThis.sessionStorage?.setItem(QUERY_STORAGE_KEY, result);
904
+ }
905
+ return result;
906
+ }
907
+
908
+ const adjustSessionQuery = (href) => {
909
+ const sessionQuery = saveSessionQuery();
910
+ if (!isURL(href) || !sessionQuery) {
911
+ return href;
912
+ }
913
+ const url = new URL(href);
914
+ for (const [key, value] of new URLSearchParams(sessionQuery)) {
915
+ url.searchParams.set(key, value);
916
+ }
917
+ return url.toString();
918
+ };
919
+
920
+ const tableFunc = (table) => (input) => {
921
+ const [, output] = table.find(([predicate]) => predicate(input)) || [];
922
+ return output;
923
+ };
924
+
925
+ const forwardQuery = (ev) => {
926
+ const anchor = ev.target?.closest('a');
927
+ if (isURL(anchor?.href) && !anchor?.href?.startsWith(globalThis.location?.origin)) {
928
+ ev.preventDefault();
929
+ ev.stopPropagation();
930
+ const url = adjustSessionQuery(anchor?.href) || anchor?.href;
931
+ if (url) {
932
+ const transition = getTransition(anchor?.target);
933
+ transition?.(url);
934
+ }
935
+ }
936
+ };
937
+ const getTransition = tableFunc([
938
+ [(_) => _ === '_blank', (url) => globalThis.open(url, '_blank')],
939
+ [(_) => _ === '_parent', (url) => globalThis.parent && (globalThis.parent.location.href = url)],
940
+ [
941
+ (_) => _ === '_top',
942
+ (url) => {
943
+ globalThis.top && (globalThis.top.location.href = url);
944
+ },
945
+ ],
946
+ [() => true, (url) => globalThis.location && (globalThis.location.href = url)],
947
+ ]);
948
+
949
+ function useAspects() {
950
+ return useAspects._impl();
951
+ }
952
+ useAspects._impl = () => ({
953
+ forwardQuery,
954
+ });
955
+ useAspects.setup = (impl) => {
956
+ useAspects._impl = impl;
957
+ };
958
+
892
959
  const identity = (_) => _;
893
960
 
894
- const useForm = (initialState, { resetOnSubmit, onSubmit } = {}) => {
961
+ const useForm = (initialState, { resetOnSubmit, onSubmit, } = {}) => {
895
962
  const [formState, setFormState] = useState(initialState);
896
963
  const [isDirtyForm, setDirtyForm] = useState(false);
897
964
  const [dirtyFieldsMap, setDirtyFieldsMap] = useState({});
@@ -920,10 +987,10 @@
920
987
  setDirtyForm(false);
921
988
  setDirtyFieldsMap({});
922
989
  }, [initialState]);
923
- const handleSubmit = useCallback((e) => {
924
- e.preventDefault();
990
+ const handleSubmit = useCallback((ev) => {
991
+ ev.preventDefault();
925
992
  resetOnSubmit ? reset() : setDirtyForm(true);
926
- onSubmit && onSubmit(formState);
993
+ onSubmit && onSubmit(formState, ev);
927
994
  }, [onSubmit, formState]);
928
995
  return [
929
996
  formState,
@@ -1291,7 +1358,7 @@
1291
1358
  const handleBlur = useCallback((v) => {
1292
1359
  v === '+7 (' ? onChange && onChange('') : null;
1293
1360
  }, []);
1294
- return (jsx(Input, { ...inputProps, onChange: handleChange, onFocus: (e) => handleChange(e?.target?.value || ''), onBlur: (e) => handleBlur(e?.target?.value || ''), children: children }));
1361
+ return (jsx(Input, { ...inputProps, onChange: handleChange, onFocus: (ev) => handleChange(ev?.target?.value || ''), onBlur: (ev) => handleBlur(ev?.target?.value || ''), children: children }));
1295
1362
  });
1296
1363
 
1297
1364
  const InputPhoneControl = JSX(({ className, label, value, error, onChange, onBlur, ...rest }) => (jsxs("div", { className: style('shrink-0 w-full', className), children: [jsx(PhoneInput, { "aria-label": label, label: rest?.errors ? `${label}*` : label, valid: Boolean(!error), value: value, onChange: onChange, onBlur: onBlur, placeholder: "+7 (___) ___-__-__" }), renderErrorText(error)] })));
@@ -1508,8 +1575,8 @@
1508
1575
  const inputStyle = {
1509
1576
  backgroundSize: `${percentage.toFixed(2)}% 100%`,
1510
1577
  };
1511
- return (jsxs("div", { children: [list.length ? (jsx("div", { className: "absolute w-full flex justify-between -bottom-[3px] px-m", children: list.map((_, i) => (jsx("div", { className: style('w-2 h-2 rounded-full', rangeValue <= i || disabled ? 'bg-gray' : 'bg-primary-main') }, String(i)))) })) : null, jsx("div", { className: "absolute inset-x-0 -bottom-1 px-m leading-[18px]", children: jsx("input", { className: "box-border w-full m-0 cursor-pointer slider relative z-10", style: inputStyle, type: "range", min: min, max: max, step: step, value: rangeValue, disabled: disabled, onInput: ((e) => {
1512
- const rawValue = parseDecimal(e.target?.value);
1578
+ return (jsxs("div", { children: [list.length ? (jsx("div", { className: "absolute w-full flex justify-between -bottom-[3px] px-m", children: list.map((_, i) => (jsx("div", { className: style('w-2 h-2 rounded-full', rangeValue <= i || disabled ? 'bg-gray' : 'bg-primary-main') }, String(i)))) })) : null, jsx("div", { className: "absolute inset-x-0 -bottom-1 px-m leading-[18px]", children: jsx("input", { className: "box-border w-full m-0 cursor-pointer slider relative z-10", style: inputStyle, type: "range", min: min, max: max, step: step, value: rangeValue, disabled: disabled, onInput: ((ev) => {
1579
+ const rawValue = parseDecimal(ev.target?.value);
1513
1580
  const newValue = list.length ? list[rawValue] : rawValue;
1514
1581
  onChange && onChange(newValue || 0);
1515
1582
  }) }) })] }));
@@ -1524,8 +1591,8 @@
1524
1591
  normalize: (_ = 0) => list.length ? closestValue(list)(_) : clamp(_, min, max),
1525
1592
  format: toLocalNumberFormat(),
1526
1593
  });
1527
- const handleChange = useCallback((e) => {
1528
- onChange && onChange(parseDecimal(e.target?.value));
1594
+ const handleChange = useCallback((ev) => {
1595
+ onChange && onChange(parseDecimal(ev.target?.value));
1529
1596
  }, [onChange]);
1530
1597
  return (jsxs("div", { className: className, children: [jsxs("label", { className: "block relative", children: [title ? (jsx(Text, { size: "text-m", font: "font-light", color: "text-primary-text", children: title })) : null, jsx("input", { className: style('mt-xs font-sans text-h3 w-full h-14', 'border border-solid border-gray rounded-md outline-none', 'pl-m box-border', 'text-primary-text hover:border-primary-hover focus:border-primary-text', DISABLED_INPUT_CLASSES), disabled: disabled, onInput: handleChange, ...normalizedProps }), renderRangeWithTicks({ list, min, max, step, disabled, value, onChange })] }), renderRangeCaption(items)] }));
1531
1598
  });
@@ -1792,19 +1859,23 @@
1792
1859
  const renderContacts = () => (jsxs("div", { className: "space-y-m", children: [jsx(Heading, { headingType: "h6", title: "\u0418\u043B\u0438 \u0441\u0432\u044F\u0436\u0438\u0442\u0435\u0441\u044C \u0441 \u043D\u0430\u043C\u0438 \u0443\u0434\u043E\u0431\u043D\u044B\u043C \u0441\u043F\u043E\u0441\u043E\u0431\u043E\u043C", className: "@xl:text-center" }), jsxs("div", { className: "flex gap-xl", children: [jsxs("a", { className: "flex gap-s items-center text-primary-text no-underline", href: `tel:8 (800) 200-78-70`, "aria-label": "8 (800) 200-78-70", children: [jsx(Img, { image: { icon: 'PhoneIcon' }, width: "24", height: "24" }), jsx("span", { children: "8 (800) 200-78-70" })] }), jsxs("a", { className: "flex gap-s items-center text-primary-text no-underline", "aria-label": "ved@rshb.ru", href: `mailto:ved@rshb.ru`, children: [jsx(Img, { image: { icon: 'MailIcon' }, width: "24", height: "24" }), jsx("span", { children: "ved@rshb.ru" })] })] })] }));
1793
1860
 
1794
1861
  const API = LeadServiceAPI();
1795
- const ApplicationFormCustom = JSX(({ className, title, typeForm = '', sections = [], button, link, endpoint, additionalParams, isContacts, ...rest }) => {
1862
+ const ApplicationFormCustom = JSX(({ className, title, typeForm = '', sections = [], button, link, endpoint, additionalParams, isContacts, data, ...rest }) => {
1796
1863
  const inputs = (sections?.flatMap((_) => _?.inputs) || []);
1797
1864
  const initialFormState = getInitialFormState(inputs, typeForm);
1798
1865
  const [responseType, setResponseType] = useState('');
1799
- const handleSubmit = useCallback(async (data) => {
1800
- const inputsFiltered = getFilteredInputs(inputs, data);
1866
+ const handleSubmit = useCallback(async (formData, ev) => {
1867
+ const inputsFiltered = getFilteredInputs(inputs, formData);
1801
1868
  const feedbackValidator = objectValidator(getObjectValidator(inputsFiltered));
1802
- if (!isValidationSuccess(feedbackValidator(data))) {
1869
+ if (!isValidationSuccess(feedbackValidator(formData))) {
1803
1870
  return 'Fail';
1804
1871
  }
1805
- const formatData = getFormatData({ ...data, ...additionalParams });
1872
+ const formatData = getFormatData({ ...formData, ...additionalParams });
1806
1873
  const status = (await API.send(formatData, endpoint === 'lead')) ? 'OK' : 'Fail';
1807
1874
  setResponseType(status);
1875
+ if (status === 'OK' && data) {
1876
+ const aspects = useAspects();
1877
+ handleAspects({ aspectsAttributes: data, aspects, ev, formData: formatData });
1878
+ }
1808
1879
  return status;
1809
1880
  }, []);
1810
1881
  const [, { field, onSubmit, reset }] = useForm(initialFormState, { onSubmit: handleSubmit });
@@ -1814,8 +1885,9 @@
1814
1885
  reset();
1815
1886
  }
1816
1887
  }, [responseType]);
1817
- return (jsxs(ApplicationFormLayout, { className: style('container space-y-m', className), title: title, responseType: responseType, ...rest, children: [jsxs("form", { onSubmit: onSubmit, children: [sections.map((_, i) => (jsxs("div", { className: style(inputColumnStyles(_.columns), 'grid gap-x-m'), children: [_?.title ? (jsx("div", { className: "@xl:text-center @xl:col-span-2 mb-m", children: jsx(Text, { size: "text-h6", children: _.title }) })) : null, (_?.inputs || [])?.map(getField(field, typeForm))] }, `section-${i}`))), renderAgreementSubmit(fieldName ? field('consentDataProcessing') : undefined, link, button)] }), isContacts ? renderContacts() : null] }));
1888
+ return (jsxs(ApplicationFormLayout, { className: style('container space-y-m', className), title: title, responseType: responseType, ...rest, children: [jsxs("form", { onSubmit: onSubmit, children: [sections.map((_, i) => (jsxs("div", { className: style(inputColumnStyles(_.columns), 'grid gap-x-m'), children: [renderTitle(_.title), (_?.inputs || [])?.map(getField(field, typeForm))] }, `section-${i}`))), renderAgreementSubmit(fieldName ? field('consentDataProcessing') : undefined, link, button)] }), isContacts ? renderContacts() : null] }));
1818
1889
  });
1890
+ const renderTitle = (title) => title ? (jsx("div", { className: "@xl:text-center @xl:col-span-2 mb-m", children: jsx(Text, { size: "text-h6", children: title }) })) : null;
1819
1891
  const inputColumnStyles = (column) => column === 2 ? '@xl:grid-cols-2' : '';
1820
1892
  const getConsentDataProcessing = (inputs) => inputs?.find((_) => _?.name === 'consentDataProcessing');
1821
1893
  const getFilteredInputs = (inputs, data) => inputs
@@ -3193,11 +3265,11 @@
3193
3265
  .map((link, index) => (jsx(CarouselLinkButton, { ...link }, String(index)))) }, String(groupIndex)))) }));
3194
3266
  };
3195
3267
 
3196
- const LinkWrapper = JSX(({ className = '', href, target, isRemote = false, onClick, children }) => {
3268
+ const LinkWrapper = JSX(({ className = '', href, target, isRemote = false, onClick, data, children }) => {
3197
3269
  const link = useLink({ isRemote });
3198
3270
  const linkProps = link({ href, target, onClick });
3199
3271
  const Tag = href ? 'a' : 'div';
3200
- return (jsx(Tag, { className: style('block', className), ...(href ? linkProps : {}), role: href ? 'link' : 'none', children: children }));
3272
+ return (jsx(Tag, { className: style('block', className), ...(href ? linkProps : {}), role: href ? 'link' : 'none', ...getAspectsAttributes(data), children: children }));
3201
3273
  });
3202
3274
 
3203
3275
  const ICONS_MAP = [
@@ -3505,11 +3577,6 @@
3505
3577
  };
3506
3578
  const formatValue = (value) => value.replace(/[^\d.,]/g, '').replace(',', '.');
3507
3579
 
3508
- const tableFunc = (table) => (input) => {
3509
- const [, output] = table.find(([predicate]) => predicate(input)) || [];
3510
- return output;
3511
- };
3512
-
3513
3580
  const callbackCurrencySelect = (props) => tableFunc([
3514
3581
  [
3515
3582
  (_) => _.value !== Currency.RUB && _.oppositeValue !== Currency.RUB,
@@ -3715,7 +3782,7 @@
3715
3782
  return (jsxs(BlockWrapper, { tag: "footer", className: className, defaultPadding: "p-4xl pb-24", ...rest, children: [jsx("div", { className: "mb-lg pb-xs border-b border-main-divider", role: "menu", children: renderTopItems(topItems) }), jsx(Contacts, { className: "overflow-hidden", items: contacts }), jsxs("div", { className: "mt-xl", children: [jsx(SocialMedia, { className: "mb-xl", media: socialMedia, stretched: true, children: "\u0421\u043E\u0446\u0441\u0435\u0442\u0438" }), jsxs("div", { className: "mb-xl", children: [jsx(SocialMedia, { className: "mb-m", media: mobileApps, stretched: true, showButtonText: false }), jsx(Text, { size: "text-s", font: "font-light", color: "text-secondary-text", children: "\u041C\u043E\u0431\u0438\u043B\u044C\u043D\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435" })] })] }), jsx("div", { className: "py-lg border-t border-main-divider", children: jsx(HorizontalNavigationLink, { text: "\u0412\u0435\u0440\u043D\u0443\u0442\u044C\u0441\u044F \u043D\u0430 \u043F\u0440\u0435\u0436\u043D\u044E\u044E \u0432\u0435\u0440\u0441\u0438\u044E \u0441\u0430\u0439\u0442\u0430", className: "text-l font-light max-w-[292px]", href: "https://old.rshb.ru", onClick: handleOnClick }) }), jsx(HorizontalNavigation, { className: "py-lg border-y border-main-divider", title: horizontalNavigationTitle, links: relatedEnterprises }), jsx(TextInformation, { links: documents })] }));
3716
3783
  });
3717
3784
  const renderTopItems = (topItems) => topItems
3718
- ?.filter((_) => _.icon)
3785
+ ?.filter((_) => _.icon?.icon)
3719
3786
  .map((item, i) => (jsx(RollupItem, { foldButtonVersion: "accordion", label: item?.text, labelIcon: item?.icon, role: "menuitem", children: jsx(LinkList, { items: item.items, basePath: appendSlash(item.href) }) }, String(i))));
3720
3787
 
3721
3788
  const ICON_SIZE = { width: '34', height: '34' };
@@ -3741,7 +3808,7 @@
3741
3808
  'bg-white': 'text-primary-text',
3742
3809
  transparent: 'text-white',
3743
3810
  };
3744
- const Logo = JSX(({ className, href = '/', logo, children, targetBlank, bgColor = 'bg-white', showTitle = true, }) => (jsxs("a", { className: style('inline-flex items-center font-sans no-underline', className), href: href, target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title ?? 'Россельхозбанк', children: [renderImage(bgColor, logo?.image, ICON_SIZE), showTitle
3811
+ const Logo = JSX(({ className, href = '/', logo, children, targetBlank, bgColor = 'bg-white', showTitle = true, }) => (jsxs("a", { className: style('inline-flex items-center font-sans no-underline', className), href: href, target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title ?? 'Россельхозбанк', ...getAspectsAttributes(logo?.data), children: [renderImage(bgColor, logo?.image, ICON_SIZE), showTitle
3745
3812
  ? children ?? (jsx("div", { className: "ml-s", children: jsx(Text, { font: "font-medium", color: TEXT_COLOR[bgColor], size: logoTitleSizeStyle, children: logo?.title ?? 'Россельхозбанк' }) }))
3746
3813
  : null] })));
3747
3814
 
@@ -4915,9 +4982,21 @@
4915
4982
  return (jsxs("div", { className: "flex gap-s items-center", children: [icon ? jsx(Img, { pathPrefix: "/wcms-resources/", image: icon }) : null, text ? (jsx("a", { className: "hover:text-primary-hover", href: href, target: target, onClick: onClick, children: jsx(Text, { size: "text-l", font: "font-light", color: "text-primary-text", children: text }) })) : null] }));
4916
4983
  });
4917
4984
 
4985
+ const MINDBOX_ASPECT = 'mindboxEvent';
4986
+ const MINDBOX_CATEGORY = 'header';
4987
+ const MINDBOX_EVENT_REGION_NEW_CLICK = 'headerRegionNewSelect';
4918
4988
  const renderRegion = (onChangeLocation) => (region) => region.name ? (jsx(LinkWrapper, { isRemote: true, href: `/branches/${region.slug}`, className: "mb-xs sm:mb-2xs hover:text-primary-hover", onClick: () => {
4919
4989
  onChangeLocation && onChangeLocation(region);
4920
- }, children: jsx(Text, { size: "text-l", font: "font-light", children: region.name }) }, String(region.id))) : null;
4990
+ }, data: [
4991
+ {
4992
+ aspectName: MINDBOX_ASPECT,
4993
+ params: {
4994
+ eventAction: MINDBOX_EVENT_REGION_NEW_CLICK,
4995
+ eventCategory: MINDBOX_CATEGORY,
4996
+ eventValueText: region.name,
4997
+ },
4998
+ },
4999
+ ], children: jsx(Text, { size: "text-l", font: "font-light", children: region.name }) }, String(region.id))) : null;
4921
5000
 
4922
5001
  const renderRegionGroup = (onChangeLocation) => ([letter, regions]) => (jsxs("div", { className: "break-inside-avoid mb-2xl w-56", children: [jsx("div", { className: "mb-s", children: jsx(Text, { size: "text-h6", children: letter }) }), regions.map(renderRegion(onChangeLocation))] }, letter));
4923
5002
 
@@ -4969,7 +5048,7 @@
4969
5048
  const TopItemMobile = ({ item, isActive, onClick }) => (jsx("div", { className: style('relative rounded-2xl p-2', isActive ? 'bg-primary-main' : 'bg-main-gray'), children: jsx("button", { type: "button", className: "relative", onClick: onClick, children: jsx("span", { className: style('whitespace-nowrap', isActive ? 'text-white' : ''), children: item.text }) }) }));
4970
5049
 
4971
5050
  const BurgerMenuDialog = JSX((props) => {
4972
- const { topItems, defaultLocation, officesLink } = props;
5051
+ const { topItems, defaultLocation, officesAtms } = props;
4973
5052
  const [location] = useLocation(defaultLocation);
4974
5053
  const locationDialog = useLocationDialog(props);
4975
5054
  const [containerRef, scroll] = useSwipeListScroll({
@@ -4979,6 +5058,7 @@
4979
5058
  const [activeTopItemIndex, setActiveTopItemIndex] = useState(activeIndex);
4980
5059
  const activeRoute = useMemo(() => topItems?.[activeTopItemIndex], [topItems, activeTopItemIndex]);
4981
5060
  const activeMenuSubItems = activeRoute?.items || [];
5061
+ const link = useLink();
4982
5062
  useEffect(() => {
4983
5063
  setActiveTopItemIndex(activeIndex);
4984
5064
  }, [activeIndex]);
@@ -4988,10 +5068,13 @@
4988
5068
  }
4989
5069
  }, [activeTopItemIndex, scroll]);
4990
5070
  const handleTopItemClick = useCallback((idx) => setActiveTopItemIndex(idx), []);
4991
- return (jsx(Dialog, { onClick: (e) => e.stopPropagation(), head: jsx("div", { className: "flex items-center", children: jsx(Heading, { as: "h4", title: "\u041C\u0435\u043D\u044E" }) }), children: jsxs("div", { className: "flex flex-col flex-nowrap relative w-full h-auto m-auto bg-white pb-24 box-border rounded-md", children: [jsx("div", { className: "w-full mb-3", children: jsx(SwipeListContainer, { containerRef: containerRef, visibleItemCount: 0, gap: 10, className: "pb-3", children: topItems?.map((item, i) => (jsx(TopItemMobile, { item: item, isActive: activeTopItemIndex === i, onClick: () => handleTopItemClick(i) }, String(i)))) }) }), jsxs("div", { className: "relative grow", children: [renderActiveSubMenu(activeMenuSubItems, activeRoute?.href), renderOfficeLink(officesLink), renderLocation(location, () => locationDialog.open())] })] }) }));
5071
+ return (jsx(Dialog, { onClick: (e) => e.stopPropagation(), head: jsx("div", { className: "flex items-center", children: jsx(Heading, { as: "h4", title: "\u041C\u0435\u043D\u044E" }) }), children: jsxs("div", { className: "flex flex-col flex-nowrap relative w-full h-auto m-auto bg-white pb-24 box-border rounded-md", children: [jsx("div", { className: "w-full mb-3", children: jsx(SwipeListContainer, { containerRef: containerRef, visibleItemCount: 0, gap: 10, className: "pb-3", children: topItems?.map((item, i) => (jsx(TopItemMobile, { item: item, isActive: activeTopItemIndex === i, onClick: () => handleTopItemClick(i) }, String(i)))) }) }), jsxs("div", { className: "relative grow", children: [renderActiveSubMenu(activeMenuSubItems, activeRoute?.href), officesAtms?.href ? renderOfficeLink(link)(officesAtms) : null, renderLocation(location, () => locationDialog.open())] })] }) }));
4992
5072
  });
4993
5073
  const renderActiveSubMenu = (activeMenuSubItems, basePath) => activeMenuSubItems ? (jsx("div", { children: activeMenuSubItems.map((_, i) => (jsx(ActiveSubMenuItem, { item: _, basePath: basePath }, String(i)))) })) : null;
4994
- const renderOfficeLink = (officesLink) => officesLink ? (jsx("div", { className: "mt-3", children: jsxs("a", { className: style('text-primary-text', `p-4 text-h5 font-light flex justify-between cursor-pointer`, 'shadow-main-black', 'rounded-xl'), href: officesLink, rel: "noopener noreferrer", "aria-label": "\u041E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u044F \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B", children: [jsx("span", { children: "\u041E\u0444\u0438\u0441\u044B \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B" }), jsx(Img, { image: { icon: 'ArrowRightIcon', iconVersion: 'color' }, width: "24", height: "24", className: "text-secondary-text opacity-30" })] }) })) : null;
5074
+ const renderOfficeLink = (link) => (officesAtms) => {
5075
+ const { href, target, onClick } = link(officesAtms);
5076
+ return (jsx("div", { className: "mt-3", children: jsxs("a", { className: style('text-primary-text', `p-4 text-h5 font-light flex justify-between cursor-pointer`, 'shadow-main-black', 'rounded-xl'), href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": "\u041E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u044F \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B", ...getAspectsAttributes(officesAtms?.data), children: [jsx("span", { children: "\u041E\u0444\u0438\u0441\u044B \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B" }), jsx(Img, { image: { icon: 'ArrowRightIcon', iconVersion: 'color' }, width: "24", height: "24", className: "text-secondary-text opacity-30" })] }) }));
5077
+ };
4995
5078
  const renderLocation = (location, onClick) => (jsxs("div", { className: style('text-primary-text', `p-4 text-h5 font-light flex justify-between cursor-pointer`, 'shadow-main-black', 'rounded-xl', 'mt-3'), onClick: onClick, children: [jsx("div", { className: "flex flex-col items-start", children: jsxs("span", { children: ["\u0412\u0430\u0448\u0430 \u043B\u043E\u043A\u0430\u0446\u0438\u044F - ", location.name] }) }), jsx(Img, { image: { icon: 'ArrowRightIcon', iconVersion: 'color' }, width: "24", height: "24", className: "text-secondary-text opacity-30" })] }));
4996
5079
 
4997
5080
  const BURGER_MENU_DIALOG_ID = 'burgerMenuDialog';
@@ -5440,22 +5523,11 @@
5440
5523
  VerticalLayout,
5441
5524
  };
5442
5525
 
5443
- const QUERY_STORAGE_KEY = 'rshb-query-params';
5444
- function saveSessionQuery() {
5445
- const result = globalThis.location?.search || globalThis.sessionStorage?.getItem(QUERY_STORAGE_KEY) || '';
5446
- if (result) {
5447
- globalThis.sessionStorage?.setItem(QUERY_STORAGE_KEY, result);
5448
- }
5449
- return result;
5450
- }
5451
-
5452
5526
  const applyAspects = (aspects) => (ev) => {
5453
5527
  const element = ev.target?.closest('[data-aspects]');
5454
5528
  try {
5455
5529
  const aspectsAttributes = JSON.parse(element?.dataset?.aspects ?? '[]');
5456
- for (const { aspectName, params } of aspectsAttributes) {
5457
- aspects[aspectName ?? '']?.(ev, params);
5458
- }
5530
+ handleAspects({ aspectsAttributes, aspects, ev });
5459
5531
  }
5460
5532
  catch (_) {
5461
5533
  // Do nothing
@@ -5464,52 +5536,6 @@
5464
5536
  aspects.forwardQuery?.(ev);
5465
5537
  };
5466
5538
 
5467
- const adjustSessionQuery = (href) => {
5468
- const sessionQuery = saveSessionQuery();
5469
- if (!isURL(href) || !sessionQuery) {
5470
- return href;
5471
- }
5472
- const url = new URL(href);
5473
- for (const [key, value] of new URLSearchParams(sessionQuery)) {
5474
- url.searchParams.set(key, value);
5475
- }
5476
- return url.toString();
5477
- };
5478
-
5479
- const forwardQuery = (ev) => {
5480
- const anchor = ev.target?.closest('a');
5481
- if (isURL(anchor?.href) && !anchor?.href?.startsWith(globalThis.location?.origin)) {
5482
- ev.preventDefault();
5483
- ev.stopPropagation();
5484
- const url = adjustSessionQuery(anchor?.href) || anchor?.href;
5485
- if (url) {
5486
- const transition = getTransition(anchor?.target);
5487
- transition?.(url);
5488
- }
5489
- }
5490
- };
5491
- const getTransition = tableFunc([
5492
- [(_) => _ === '_blank', (url) => globalThis.open(url, '_blank')],
5493
- [(_) => _ === '_parent', (url) => globalThis.parent && (globalThis.parent.location.href = url)],
5494
- [
5495
- (_) => _ === '_top',
5496
- (url) => {
5497
- globalThis.top && (globalThis.top.location.href = url);
5498
- },
5499
- ],
5500
- [() => true, (url) => globalThis.location && (globalThis.location.href = url)],
5501
- ]);
5502
-
5503
- function useAspects() {
5504
- return useAspects._impl();
5505
- }
5506
- useAspects._impl = () => ({
5507
- forwardQuery,
5508
- });
5509
- useAspects.setup = (impl) => {
5510
- useAspects._impl = impl;
5511
- };
5512
-
5513
5539
  const useClickHandler = handlerDecorator(() => {
5514
5540
  useEffect(() => {
5515
5541
  saveSessionQuery(); //? Call first time for save query in sessionStorage
@@ -5625,7 +5651,7 @@
5625
5651
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
5626
5652
  });
5627
5653
 
5628
- const packageVersion = "0.14.286";
5654
+ const packageVersion = "0.14.288";
5629
5655
 
5630
5656
  exports.Blocks = Blocks;
5631
5657
  exports.ContentPage = ContentPage;