@redneckz/wildless-cms-uni-blocks 0.3.34 → 0.3.35

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 (384) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +180 -84
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/cosmos-static/icons/ArrowLeftIcon.svg +1 -0
  5. package/cosmos-static/icons/BurgerIcon.svg +1 -1
  6. package/cosmos-static/icons/Calendar2Icon.svg +1 -1
  7. package/cosmos-static/icons/CalendarCircleIcon.svg +1 -1
  8. package/cosmos-static/icons/CalendarIcon.svg +1 -1
  9. package/cosmos-static/icons/CalendarTickIcon.svg +1 -1
  10. package/cosmos-static/icons/CalendarWhiteIcon.svg +1 -1
  11. package/cosmos-static/icons/CardIcon.svg +1 -1
  12. package/cosmos-static/icons/CardPosIcon.svg +1 -1
  13. package/cosmos-static/icons/CardTickIcon.svg +1 -1
  14. package/cosmos-static/icons/ChartSquareIcon.svg +1 -1
  15. package/cosmos-static/icons/CloseIcon.svg +1 -1
  16. package/cosmos-static/icons/DiscountShapeIcon.svg +1 -1
  17. package/cosmos-static/icons/DocIcon.svg +1 -1
  18. package/cosmos-static/icons/DocumentTextIcon.svg +1 -1
  19. package/cosmos-static/icons/EmptyWalletChangeIcon.svg +1 -1
  20. package/cosmos-static/icons/EmptyWalletIcon.svg +1 -1
  21. package/cosmos-static/icons/GlobalIcon.svg +1 -1
  22. package/cosmos-static/icons/GpsIcon.svg +1 -1
  23. package/cosmos-static/icons/InterestIcon.svg +1 -1
  24. package/cosmos-static/icons/MoneyIcon.svg +1 -1
  25. package/cosmos-static/icons/MonitorMobileIcon.svg +1 -1
  26. package/cosmos-static/icons/PercentageRoundIcon.svg +1 -1
  27. package/cosmos-static/icons/PercentageSquareIcon.svg +1 -1
  28. package/cosmos-static/icons/PersonalCardIcon.svg +1 -1
  29. package/cosmos-static/icons/Profile2UserIcon.svg +1 -1
  30. package/cosmos-static/icons/RoundRubleIcon.svg +1 -1
  31. package/cosmos-static/icons/SafeIcon.svg +1 -1
  32. package/cosmos-static/icons/ShieldTickIcon.svg +1 -1
  33. package/cosmos-static/icons/SmallClockIcon.svg +1 -1
  34. package/cosmos-static/icons/UserTickIcon.svg +1 -1
  35. package/cosmos-static/icons/WalletAdd2Icon.svg +1 -1
  36. package/cosmos-static/icons/WalletAddIcon.svg +1 -1
  37. package/cosmos-static/icons/WalletIcon.svg +1 -1
  38. package/cosmos-static/icons/WalletWithMoneyIcon.svg +1 -1
  39. package/dist/components/Footer/Contacts.js +5 -5
  40. package/dist/components/Footer/Contacts.js.map +1 -1
  41. package/dist/components/Footer/Footer.js +3 -4
  42. package/dist/components/Footer/Footer.js.map +1 -1
  43. package/dist/components/Footer/FooterContent.d.ts +2 -0
  44. package/dist/components/Footer/HorizontalNavigation.js +1 -1
  45. package/dist/components/Footer/HorizontalNavigation.js.map +1 -1
  46. package/dist/components/Footer/MediaButton.js +15 -1
  47. package/dist/components/Footer/MediaButton.js.map +1 -1
  48. package/dist/components/Footer/Sitemap.js +4 -4
  49. package/dist/components/Footer/Sitemap.js.map +1 -1
  50. package/dist/components/Footer/SocialMedia.js +2 -2
  51. package/dist/components/Footer/SocialMedia.js.map +1 -1
  52. package/dist/components/Footer/TextInformation.js +2 -2
  53. package/dist/components/Footer/TextInformation.js.map +1 -1
  54. package/dist/components/Header/Header.js +3 -7
  55. package/dist/components/Header/Header.js.map +1 -1
  56. package/dist/components/Header/HeaderSecondaryMenu.js +3 -3
  57. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  58. package/dist/components/Header/HeaderSubMenu.d.ts +9 -0
  59. package/dist/components/Header/HeaderSubMenu.js +34 -0
  60. package/dist/components/Header/HeaderSubMenu.js.map +1 -0
  61. package/dist/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  62. package/dist/components/Header/HeaderSubMenuObserver.js +32 -0
  63. package/dist/components/Header/HeaderSubMenuObserver.js.map +1 -0
  64. package/dist/components/ProductBlock/ProductBlock.js +2 -1
  65. package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
  66. package/dist/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  67. package/dist/components/ProductBlock/ProductBlockInner.js +5 -5
  68. package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
  69. package/dist/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  70. package/dist/components/ProductBlock/renderBackwardButton.js +18 -0
  71. package/dist/components/ProductBlock/renderBackwardButton.js.map +1 -0
  72. package/dist/components/ProductBlock/renderBenefit.js +2 -2
  73. package/dist/components/ProductBlock/renderBenefit.js.map +1 -1
  74. package/dist/components/Tile/Tile.js +3 -3
  75. package/dist/components/Tile/Tile.js.map +1 -1
  76. package/dist/icons/IconName.d.ts +5 -3
  77. package/dist/icons/IconName.js +3 -1
  78. package/dist/icons/IconName.js.map +1 -1
  79. package/dist/ui-kit/Button/ButtonInner.js +2 -2
  80. package/dist/ui-kit/Button/ButtonInner.js.map +1 -1
  81. package/dist/ui-kit/HeaderItem/HeaderItem.js +2 -2
  82. package/dist/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  83. package/dist/ui-kit/Heading/Heading.js +2 -2
  84. package/dist/ui-kit/Heading/Heading.js.map +1 -1
  85. package/dist/ui-kit/Icon/Icon.js +2 -2
  86. package/dist/ui-kit/Icon/Icon.js.map +1 -1
  87. package/dist/ui-kit/List/List.js +2 -0
  88. package/dist/ui-kit/List/List.js.map +1 -1
  89. package/dist/ui-kit/List/ListItem.js +19 -5
  90. package/dist/ui-kit/List/ListItem.js.map +1 -1
  91. package/dist/ui-kit/List/ListProps.d.ts +1 -1
  92. package/dist/ui-kit/Logo/Logo.js +1 -1
  93. package/dist/ui-kit/Logo/Logo.js.map +1 -1
  94. package/dist/ui-kit/SearchBar/SearchBar.js +1 -1
  95. package/dist/ui-kit/SearchBar/SearchBar.js.map +1 -1
  96. package/dist/ui-kit/TopItem/TopItem.d.ts +1 -0
  97. package/dist/ui-kit/TopItem/TopItem.js +1 -1
  98. package/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  99. package/dist/utils/isSSR.d.ts +1 -0
  100. package/dist/utils/isSSR.js +5 -0
  101. package/dist/utils/isSSR.js.map +1 -0
  102. package/lib/common.css +1 -1
  103. package/lib/components/Footer/Contacts.js +5 -5
  104. package/lib/components/Footer/Contacts.js.map +1 -1
  105. package/lib/components/Footer/Footer.js +3 -4
  106. package/lib/components/Footer/Footer.js.map +1 -1
  107. package/lib/components/Footer/FooterContent.d.ts +2 -0
  108. package/lib/components/Footer/HorizontalNavigation.js +1 -1
  109. package/lib/components/Footer/HorizontalNavigation.js.map +1 -1
  110. package/lib/components/Footer/MediaButton.js +15 -1
  111. package/lib/components/Footer/MediaButton.js.map +1 -1
  112. package/lib/components/Footer/Sitemap.js +4 -4
  113. package/lib/components/Footer/Sitemap.js.map +1 -1
  114. package/lib/components/Footer/SocialMedia.js +3 -3
  115. package/lib/components/Footer/SocialMedia.js.map +1 -1
  116. package/lib/components/Footer/TextInformation.js +2 -2
  117. package/lib/components/Footer/TextInformation.js.map +1 -1
  118. package/lib/components/Header/Header.js +3 -7
  119. package/lib/components/Header/Header.js.map +1 -1
  120. package/lib/components/Header/HeaderSecondaryMenu.js +3 -3
  121. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  122. package/lib/components/Header/HeaderSubMenu.d.ts +9 -0
  123. package/lib/components/Header/HeaderSubMenu.js +32 -0
  124. package/lib/components/Header/HeaderSubMenu.js.map +1 -0
  125. package/lib/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  126. package/lib/components/Header/HeaderSubMenuObserver.js +30 -0
  127. package/lib/components/Header/HeaderSubMenuObserver.js.map +1 -0
  128. package/lib/components/ProductBlock/ProductBlock.fixture.d.ts +1 -0
  129. package/lib/components/ProductBlock/ProductBlock.js +2 -1
  130. package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
  131. package/lib/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  132. package/lib/components/ProductBlock/ProductBlockInner.js +5 -5
  133. package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
  134. package/lib/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  135. package/lib/components/ProductBlock/renderBackwardButton.js +15 -0
  136. package/lib/components/ProductBlock/renderBackwardButton.js.map +1 -0
  137. package/lib/components/ProductBlock/renderBenefit.js +2 -2
  138. package/lib/components/ProductBlock/renderBenefit.js.map +1 -1
  139. package/lib/components/Tile/Tile.js +3 -3
  140. package/lib/components/Tile/Tile.js.map +1 -1
  141. package/lib/icons/IconName.d.ts +5 -3
  142. package/lib/icons/IconName.js +3 -1
  143. package/lib/icons/IconName.js.map +1 -1
  144. package/lib/ui-kit/Button/ButtonInner.js +2 -2
  145. package/lib/ui-kit/Button/ButtonInner.js.map +1 -1
  146. package/lib/ui-kit/HeaderItem/HeaderItem.js +2 -2
  147. package/lib/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  148. package/lib/ui-kit/Heading/Heading.js +2 -2
  149. package/lib/ui-kit/Heading/Heading.js.map +1 -1
  150. package/lib/ui-kit/Icon/Icon.js +2 -2
  151. package/lib/ui-kit/Icon/Icon.js.map +1 -1
  152. package/lib/ui-kit/List/List.js +2 -0
  153. package/lib/ui-kit/List/List.js.map +1 -1
  154. package/lib/ui-kit/List/ListItem.js +19 -5
  155. package/lib/ui-kit/List/ListItem.js.map +1 -1
  156. package/lib/ui-kit/List/ListProps.d.ts +1 -1
  157. package/lib/ui-kit/Logo/Logo.js +1 -1
  158. package/lib/ui-kit/Logo/Logo.js.map +1 -1
  159. package/lib/ui-kit/SearchBar/SearchBar.js +1 -1
  160. package/lib/ui-kit/SearchBar/SearchBar.js.map +1 -1
  161. package/lib/ui-kit/TopItem/TopItem.d.ts +1 -0
  162. package/lib/ui-kit/TopItem/TopItem.js +1 -1
  163. package/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  164. package/lib/utils/isSSR.d.ts +1 -0
  165. package/lib/utils/isSSR.js +2 -0
  166. package/lib/utils/isSSR.js.map +1 -0
  167. package/mobile/bundle/bundle.umd.js +48 -16
  168. package/mobile/bundle/bundle.umd.min.js +1 -1
  169. package/mobile/dist/components/Footer/Contacts.js +5 -5
  170. package/mobile/dist/components/Footer/Contacts.js.map +1 -1
  171. package/mobile/dist/components/Footer/FooterContent.d.ts +2 -0
  172. package/mobile/dist/components/Footer/MediaButton.js +15 -1
  173. package/mobile/dist/components/Footer/MediaButton.js.map +1 -1
  174. package/mobile/dist/components/Footer/Sitemap.js +4 -4
  175. package/mobile/dist/components/Footer/Sitemap.js.map +1 -1
  176. package/mobile/dist/components/Header/HeaderSecondaryMenu.js +3 -3
  177. package/mobile/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  178. package/mobile/dist/components/Header/HeaderSubMenu.d.ts +9 -0
  179. package/mobile/dist/components/Header/HeaderSubMenu.js +34 -0
  180. package/mobile/dist/components/Header/HeaderSubMenu.js.map +1 -0
  181. package/mobile/dist/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  182. package/mobile/dist/components/Header/HeaderSubMenuObserver.js +32 -0
  183. package/mobile/dist/components/Header/HeaderSubMenuObserver.js.map +1 -0
  184. package/mobile/dist/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  185. package/mobile/dist/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  186. package/mobile/dist/components/ProductBlock/renderBackwardButton.js +18 -0
  187. package/mobile/dist/components/ProductBlock/renderBackwardButton.js.map +1 -0
  188. package/mobile/dist/components/Tile/Tile.js +3 -3
  189. package/mobile/dist/components/Tile/Tile.js.map +1 -1
  190. package/mobile/dist/icons/IconName.d.ts +5 -3
  191. package/mobile/dist/icons/IconName.js +3 -1
  192. package/mobile/dist/icons/IconName.js.map +1 -1
  193. package/mobile/dist/ui-kit/Button/ButtonInner.js +2 -2
  194. package/mobile/dist/ui-kit/Button/ButtonInner.js.map +1 -1
  195. package/mobile/dist/ui-kit/Icon/Icon.js +2 -2
  196. package/mobile/dist/ui-kit/Icon/Icon.js.map +1 -1
  197. package/mobile/dist/ui-kit/List/List.js +2 -0
  198. package/mobile/dist/ui-kit/List/List.js.map +1 -1
  199. package/mobile/dist/ui-kit/List/ListItem.js +19 -5
  200. package/mobile/dist/ui-kit/List/ListItem.js.map +1 -1
  201. package/mobile/dist/ui-kit/List/ListProps.d.ts +1 -1
  202. package/mobile/dist/ui-kit/TopItem/TopItem.d.ts +1 -0
  203. package/mobile/dist/ui-kit/TopItem/TopItem.js +1 -1
  204. package/mobile/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  205. package/mobile/dist/utils/isSSR.d.ts +1 -0
  206. package/mobile/dist/utils/isSSR.js +5 -0
  207. package/mobile/dist/utils/isSSR.js.map +1 -0
  208. package/mobile/lib/components/Footer/Contacts.js +5 -5
  209. package/mobile/lib/components/Footer/Contacts.js.map +1 -1
  210. package/mobile/lib/components/Footer/FooterContent.d.ts +2 -0
  211. package/mobile/lib/components/Footer/MediaButton.js +15 -1
  212. package/mobile/lib/components/Footer/MediaButton.js.map +1 -1
  213. package/mobile/lib/components/Footer/Sitemap.js +4 -4
  214. package/mobile/lib/components/Footer/Sitemap.js.map +1 -1
  215. package/mobile/lib/components/Header/HeaderSecondaryMenu.js +3 -3
  216. package/mobile/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  217. package/mobile/lib/components/Header/HeaderSubMenu.d.ts +9 -0
  218. package/mobile/lib/components/Header/HeaderSubMenu.js +32 -0
  219. package/mobile/lib/components/Header/HeaderSubMenu.js.map +1 -0
  220. package/mobile/lib/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  221. package/mobile/lib/components/Header/HeaderSubMenuObserver.js +30 -0
  222. package/mobile/lib/components/Header/HeaderSubMenuObserver.js.map +1 -0
  223. package/mobile/lib/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  224. package/mobile/lib/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  225. package/mobile/lib/components/ProductBlock/renderBackwardButton.js +15 -0
  226. package/mobile/lib/components/ProductBlock/renderBackwardButton.js.map +1 -0
  227. package/mobile/lib/components/Tile/Tile.js +3 -3
  228. package/mobile/lib/components/Tile/Tile.js.map +1 -1
  229. package/mobile/lib/icons/IconName.d.ts +5 -3
  230. package/mobile/lib/icons/IconName.js +3 -1
  231. package/mobile/lib/icons/IconName.js.map +1 -1
  232. package/mobile/lib/ui-kit/Button/ButtonInner.js +2 -2
  233. package/mobile/lib/ui-kit/Button/ButtonInner.js.map +1 -1
  234. package/mobile/lib/ui-kit/Icon/Icon.js +2 -2
  235. package/mobile/lib/ui-kit/Icon/Icon.js.map +1 -1
  236. package/mobile/lib/ui-kit/List/List.js +2 -0
  237. package/mobile/lib/ui-kit/List/List.js.map +1 -1
  238. package/mobile/lib/ui-kit/List/ListItem.js +19 -5
  239. package/mobile/lib/ui-kit/List/ListItem.js.map +1 -1
  240. package/mobile/lib/ui-kit/List/ListProps.d.ts +1 -1
  241. package/mobile/lib/ui-kit/TopItem/TopItem.d.ts +1 -0
  242. package/mobile/lib/ui-kit/TopItem/TopItem.js +1 -1
  243. package/mobile/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  244. package/mobile/lib/utils/isSSR.d.ts +1 -0
  245. package/mobile/lib/utils/isSSR.js +2 -0
  246. package/mobile/lib/utils/isSSR.js.map +1 -0
  247. package/mobile/src/components/ContentPage/ContentPage.page.json +4 -4
  248. package/mobile/src/components/Footer/Contacts.tsx +7 -10
  249. package/mobile/src/components/Footer/FooterContent.ts +3 -0
  250. package/mobile/src/components/Footer/MediaButton.tsx +15 -1
  251. package/mobile/src/components/Footer/Sitemap.tsx +5 -5
  252. package/mobile/src/components/Header/HeaderSecondaryMenu.tsx +4 -7
  253. package/mobile/src/components/Header/HeaderSubMenu.tsx +93 -0
  254. package/mobile/src/components/Header/HeaderSubMenuObserver.ts +44 -0
  255. package/mobile/src/components/ProductBlock/ProductBlockContent.ts +3 -1
  256. package/mobile/src/components/ProductBlock/renderBackwardButton.tsx +34 -0
  257. package/mobile/src/components/Tile/Tile.example.json +1 -1
  258. package/mobile/src/components/Tile/Tile.tsx +12 -3
  259. package/mobile/src/icons/ArrowDownIcon.svg +1 -1
  260. package/mobile/src/icons/ArrowLeftIcon.svg +4 -0
  261. package/mobile/src/icons/BurgerIcon.svg +4 -4
  262. package/mobile/src/icons/Calendar2Icon.svg +1 -1
  263. package/mobile/src/icons/CalendarCircleIcon.svg +4 -1
  264. package/mobile/src/icons/CalendarIcon.svg +1 -1
  265. package/mobile/src/icons/CalendarTickIcon.svg +6 -1
  266. package/mobile/src/icons/CalendarWhiteIcon.svg +2 -2
  267. package/mobile/src/icons/CardIcon.svg +5 -1
  268. package/mobile/src/icons/CardPosIcon.svg +5 -1
  269. package/mobile/src/icons/CardTickIcon.svg +5 -1
  270. package/mobile/src/icons/ChartSquareIcon.svg +6 -1
  271. package/mobile/src/icons/CloseIcon.svg +4 -4
  272. package/mobile/src/icons/DiscountShapeIcon.svg +4 -1
  273. package/mobile/src/icons/DocIcon.svg +1 -1
  274. package/mobile/src/icons/DocumentTextIcon.svg +2 -2
  275. package/mobile/src/icons/EmptyWalletChangeIcon.svg +8 -1
  276. package/mobile/src/icons/EmptyWalletIcon.svg +2 -2
  277. package/mobile/src/icons/GlobalIcon.svg +5 -1
  278. package/mobile/src/icons/GpsIcon.svg +6 -6
  279. package/mobile/src/icons/IconName.ts +4 -4
  280. package/mobile/src/icons/InterestIcon.svg +6 -1
  281. package/mobile/src/icons/MasterCardIcon.svg +5 -1
  282. package/mobile/src/icons/MinusIcon.svg +3 -1
  283. package/mobile/src/icons/MoneyIcon.svg +5 -1
  284. package/mobile/src/icons/MonitorMobileIcon.svg +4 -1
  285. package/mobile/src/icons/PercentageRoundIcon.svg +4 -1
  286. package/mobile/src/icons/PercentageSquareIcon.svg +1 -1
  287. package/mobile/src/icons/PersonalCardIcon.svg +4 -1
  288. package/mobile/src/icons/PlayMarketIcon.svg +3 -1
  289. package/mobile/src/icons/PlusIcon.svg +3 -1
  290. package/mobile/src/icons/Profile2UserIcon.svg +6 -1
  291. package/mobile/src/icons/RoundRubleIcon.svg +5 -1
  292. package/mobile/src/icons/SafeIcon.svg +7 -1
  293. package/mobile/src/icons/ShieldTickIcon.svg +4 -1
  294. package/mobile/src/icons/SmallClockIcon.svg +4 -1
  295. package/mobile/src/icons/UserTickIcon.svg +5 -1
  296. package/mobile/src/icons/WalletAdd2Icon.svg +6 -1
  297. package/mobile/src/icons/WalletAddIcon.svg +7 -1
  298. package/mobile/src/icons/WalletIcon.svg +7 -1
  299. package/mobile/src/icons/WalletWithMoneyIcon.svg +5 -1
  300. package/mobile/src/ui-kit/Button/ButtonInner.tsx +2 -2
  301. package/mobile/src/ui-kit/Icon/Icon.tsx +2 -2
  302. package/mobile/src/ui-kit/List/List.tsx +2 -0
  303. package/mobile/src/ui-kit/List/ListItem.tsx +19 -5
  304. package/mobile/src/ui-kit/List/ListProps.ts +1 -1
  305. package/mobile/src/ui-kit/TopItem/TopItem.tsx +2 -1
  306. package/mobile/src/utils/isSSR.ts +2 -0
  307. package/package.json +1 -1
  308. package/src/components/ContentPage/ContentPage.page.json +4 -4
  309. package/src/components/Footer/Contacts.tsx +7 -10
  310. package/src/components/Footer/Footer.fixture.mobile.tsx +3 -3
  311. package/src/components/Footer/Footer.fixture.tsx +4 -3
  312. package/src/components/Footer/Footer.tsx +15 -13
  313. package/src/components/Footer/FooterContent.ts +3 -0
  314. package/src/components/Footer/HorizontalNavigation.tsx +1 -1
  315. package/src/components/Footer/MediaButton.tsx +15 -1
  316. package/src/components/Footer/Sitemap.tsx +5 -5
  317. package/src/components/Footer/SocialMedia.tsx +8 -5
  318. package/src/components/Footer/TextInformation.tsx +2 -2
  319. package/src/components/Header/Header.tsx +5 -18
  320. package/src/components/Header/HeaderSecondaryMenu.tsx +4 -7
  321. package/src/components/Header/HeaderSubMenu.tsx +93 -0
  322. package/src/components/Header/HeaderSubMenuObserver.ts +44 -0
  323. package/src/components/MobileAppTile/MobileAppTile.fixture.tsx +2 -2
  324. package/src/components/ProductBlock/ProductBlock.fixture.tsx +35 -34
  325. package/src/components/ProductBlock/ProductBlock.tsx +2 -0
  326. package/src/components/ProductBlock/ProductBlockContent.ts +3 -1
  327. package/src/components/ProductBlock/ProductBlockInner.tsx +14 -8
  328. package/src/components/ProductBlock/renderBackwardButton.tsx +34 -0
  329. package/src/components/ProductBlock/renderBenefit.tsx +4 -4
  330. package/src/components/Tile/Tile.example.json +1 -1
  331. package/src/components/Tile/Tile.fixture.tsx +6 -6
  332. package/src/components/Tile/Tile.tsx +12 -3
  333. package/src/icons/ArrowDownIcon.svg +1 -1
  334. package/src/icons/ArrowLeftIcon.svg +4 -0
  335. package/src/icons/BurgerIcon.svg +4 -4
  336. package/src/icons/Calendar2Icon.svg +1 -1
  337. package/src/icons/CalendarCircleIcon.svg +4 -1
  338. package/src/icons/CalendarIcon.svg +1 -1
  339. package/src/icons/CalendarTickIcon.svg +6 -1
  340. package/src/icons/CalendarWhiteIcon.svg +2 -2
  341. package/src/icons/CardIcon.svg +5 -1
  342. package/src/icons/CardPosIcon.svg +5 -1
  343. package/src/icons/CardTickIcon.svg +5 -1
  344. package/src/icons/ChartSquareIcon.svg +6 -1
  345. package/src/icons/CloseIcon.svg +4 -4
  346. package/src/icons/DiscountShapeIcon.svg +4 -1
  347. package/src/icons/DocIcon.svg +1 -1
  348. package/src/icons/DocumentTextIcon.svg +2 -2
  349. package/src/icons/EmptyWalletChangeIcon.svg +8 -1
  350. package/src/icons/EmptyWalletIcon.svg +2 -2
  351. package/src/icons/GlobalIcon.svg +5 -1
  352. package/src/icons/GpsIcon.svg +6 -6
  353. package/src/icons/IconName.ts +5 -2
  354. package/src/icons/InterestIcon.svg +6 -1
  355. package/src/icons/MasterCardIcon.svg +5 -1
  356. package/src/icons/MinusIcon.svg +3 -1
  357. package/src/icons/MoneyIcon.svg +5 -1
  358. package/src/icons/MonitorMobileIcon.svg +4 -1
  359. package/src/icons/PercentageRoundIcon.svg +4 -1
  360. package/src/icons/PercentageSquareIcon.svg +1 -1
  361. package/src/icons/PersonalCardIcon.svg +4 -1
  362. package/src/icons/PlayMarketIcon.svg +3 -1
  363. package/src/icons/PlusIcon.svg +3 -1
  364. package/src/icons/Profile2UserIcon.svg +6 -1
  365. package/src/icons/RoundRubleIcon.svg +5 -1
  366. package/src/icons/SafeIcon.svg +7 -1
  367. package/src/icons/ShieldTickIcon.svg +4 -1
  368. package/src/icons/SmallClockIcon.svg +4 -1
  369. package/src/icons/UserTickIcon.svg +5 -1
  370. package/src/icons/WalletAdd2Icon.svg +6 -1
  371. package/src/icons/WalletAddIcon.svg +7 -1
  372. package/src/icons/WalletIcon.svg +7 -1
  373. package/src/icons/WalletWithMoneyIcon.svg +5 -1
  374. package/src/ui-kit/Button/ButtonInner.tsx +2 -2
  375. package/src/ui-kit/HeaderItem/HeaderItem.tsx +14 -3
  376. package/src/ui-kit/Heading/Heading.tsx +2 -2
  377. package/src/ui-kit/Icon/Icon.tsx +2 -2
  378. package/src/ui-kit/List/List.tsx +2 -0
  379. package/src/ui-kit/List/ListItem.tsx +19 -5
  380. package/src/ui-kit/List/ListProps.ts +1 -1
  381. package/src/ui-kit/Logo/Logo.tsx +1 -1
  382. package/src/ui-kit/SearchBar/SearchBar.tsx +2 -2
  383. package/src/ui-kit/TopItem/TopItem.tsx +2 -1
  384. package/src/utils/isSSR.ts +2 -0
@@ -187,8 +187,8 @@
187
187
  }
188
188
 
189
189
  const HEADING_STYLE_MAP = {
190
- h1: 'text-title-lg tracking-[-0.3px]',
191
- h2: 'text-title',
190
+ h1: 'text-title-xl tracking-[-0.3px]',
191
+ h2: 'text-title-lg',
192
192
  h3: 'text-title-sm',
193
193
  h4: 'text-title-xs',
194
194
  h5: 'text-title-2xs tracking-[0.2px]',
@@ -269,6 +269,7 @@
269
269
  IconMap["ActualBalanceIcon"] = "ActualBalanceIcon";
270
270
  IconMap["AppleIcon"] = "AppleIcon";
271
271
  IconMap["ArrowDownIcon"] = "ArrowDownIcon";
272
+ IconMap["ArrowLeftIcon"] = "ArrowLeftIcon";
272
273
  IconMap["ArrowsRewindRight"] = "ArrowsRewindRight";
273
274
  IconMap["ArrowUpIcon"] = "ArrowUpIcon";
274
275
  IconMap["AtmIcon"] = "AtmIcon";
@@ -346,7 +347,8 @@
346
347
  (function (IconTitleMap) {
347
348
  IconTitleMap["ActualBalanceIcon"] = "\u0414\u0435\u043D\u044C\u0433\u0438";
348
349
  IconTitleMap["AppleIcon"] = "\u041B\u043E\u0433\u043E \u00ABApple\u00BB";
349
- IconTitleMap["ArrowDownIcon"] = "ArrowDownIcon";
350
+ IconTitleMap["ArrowDownIcon"] = "\u0421\u0442\u0440\u0435\u043B\u043A\u0430 '\u0412\u043D\u0438\u0437'";
351
+ IconTitleMap["ArrowLeftIcon"] = "\u0421\u0442\u0440\u0435\u043B\u043A\u0430 '\u0412\u043B\u0435\u0432\u043E'";
350
352
  IconTitleMap["ArrowsRewindRight"] = "ArrowsRewindRight";
351
353
  IconTitleMap["ArrowUpIcon"] = "ArrowUpIcon";
352
354
  IconTitleMap["AtmIcon"] = "\u0411\u0430\u043D\u043A\u043E\u043C\u0430\u0442";
@@ -423,8 +425,8 @@
423
425
 
424
426
  const svgColorsMap = {
425
427
  none: '',
426
- primary: 'text-primary-main',
427
- secondary: 'text-primary-text',
428
+ primary: 'text-white',
429
+ secondary: 'text-white',
428
430
  };
429
431
  const Icon = JSX(({ className = '', name = '', alt = `Иконка ${IconTitleMap[name] || name}`, title = alt, asSVG, color = 'primary', ...imgProps }) => {
430
432
  const href = `${projectSettings.CDN || ''}icons/${name}.svg`;
@@ -597,14 +599,14 @@
597
599
 
598
600
  const ButtonInner = JSX((props) => {
599
601
  const { text, aboveText, appendLeft } = props;
600
- return (jsxs("div", { className: getButtonStyle(props), children: [appendLeft ? appendLeft : null, isWithText(props) ? (jsxs("div", { children: [jsx("div", { className: "text-m-2xs font-light text-left", children: aboveText }), jsx("div", { className: "text-base text-left", children: text })] })) : null] }));
602
+ return (jsxs("div", { className: getButtonStyle(props), children: [appendLeft ? appendLeft : null, isWithText(props) ? (jsxs("div", { children: [jsx("div", { className: "text-m-2xs font-light text-left", children: aboveText }), jsx("div", { className: "text-button-sm text-left", children: text })] })) : null] }));
601
603
  });
602
604
  const getButtonStyle = (props) => {
603
605
  const { version, aboveText, rounded } = props;
604
606
  if (version === 'link') {
605
607
  return '';
606
608
  }
607
- const withTextStyle = `px-8 gap-2 ${aboveText ? 'py-2' : 'py-4'}`;
609
+ const withTextStyle = `px-8 gap-2 ${aboveText ? 'py-2' : 'py-[18px]'}`;
608
610
  return [
609
611
  'flex items-center justify-center',
610
612
  isWithText(props) ? withTextStyle : 'h-12 w-12',
@@ -648,24 +650,40 @@
648
650
  return jsx("div", { className: `font-normal text-base ${className}`, children: description });
649
651
  });
650
652
 
651
- const LIST_STYLE_CLASSES = 'rounded-full inline-block mr-3';
653
+ const LIST_STYLE_CLASSES = {
654
+ primary: 'rounded-full inline-block mr-3 mt-2',
655
+ secondary: 'rounded-full inline-block mr-3 mt-2',
656
+ gray: 'rounded-full inline-block mr-3 mt-2',
657
+ tile: 'rounded-full inline-block mr-4',
658
+ 'tile-white': 'rounded-full inline-block mr-4',
659
+ };
652
660
  const LIST_DOT_STYLE_MAP = {
653
- primary: 'bg-primary-main',
661
+ primary: 'bg-primary-text',
654
662
  secondary: 'bg-white',
655
663
  gray: 'bg-secondary-text',
664
+ tile: 'bg-black',
665
+ 'tile-white': 'bg-white',
656
666
  };
657
667
  const ListItem = JSX(({ className = '', isDotted = true, children, version = 'primary' }) => {
658
- return (jsxs("div", { className: `font-sans flex items-center ${className}`, role: "listitem", children: [isDotted && jsx("div", { className: getListStyle(version) }), jsx("span", { children: children })] }));
668
+ return (jsxs("div", { className: `font-sans flex items-start ${className}`, role: "listitem", children: [isDotted && jsx("div", { className: getListStyle(version) }), jsx("span", { children: children })] }));
659
669
  });
660
670
  const getListStyle = (version) => {
661
- const size = version === 'gray' ? 'w-1.5 h-1.5 min-w-1.5 min-h-1.5' : 'w-2 h-2 min-w-2 min-h-2';
662
- return `${LIST_STYLE_CLASSES} ${LIST_DOT_STYLE_MAP[version]} ${size}`;
671
+ const size = {
672
+ primary: 'w-2 h-2 min-w-2 min-h-2',
673
+ secondary: 'w-2 h-2 min-w-2 min-h-2',
674
+ gray: 'w-1.5 h-1.5 min-w-1.5 min-h-1.5',
675
+ tile: 'w-[7px] h-[7px] min-w-[7px] min-h-[7px]',
676
+ 'tile-white': 'w-[7px] h-[7px] min-w-[7px] min-h-[7px]',
677
+ };
678
+ return `${LIST_STYLE_CLASSES[version]} ${LIST_DOT_STYLE_MAP[version]} ${size[version]}`;
663
679
  };
664
680
 
665
681
  const TEXT_STYLE_MAP = {
666
682
  primary: 'text-primary-text',
667
683
  secondary: 'text-white',
668
684
  gray: 'text-secondary-text',
685
+ tile: 'text-primary-text',
686
+ 'tile-white': 'text-white',
669
687
  };
670
688
  const List = JSX((props) => {
671
689
  const { className = '', itemClassName, isDotted, items, version = 'primary' } = props;
@@ -679,7 +697,7 @@
679
697
  });
680
698
 
681
699
  const benefitIconBgStyleMap = {
682
- primary: 'bg-main',
700
+ primary: 'bg-primary-main',
683
701
  secondary: 'bg-white/30',
684
702
  };
685
703
  const benefitTitleStyleMap = {
@@ -691,20 +709,31 @@
691
709
  secondary: 'text-white',
692
710
  };
693
711
  function renderBenefit(benefit, i, version) {
694
- return (jsxs("div", { className: "flex gap-4 items-center", children: [benefit.icon ? (jsx(Img, { className: `w-[50px] h-[50px] min-w-[50px] min-h-[50px] rounded-full p-[10px] box-border ${benefitIconBgStyleMap[version]}`, image: benefit.icon, width: "24", height: "24", asSVG: true })) : null, jsxs("div", { className: "flex gap-1 flex-col h-full max-w-[149px]", children: [jsx("div", { className: `font-medium text-xl m-0 ${benefitTitleStyleMap[version]}`, children: benefit.label }), benefit.description && (jsx("div", { className: `font-normal text-sm ${benefitDescStyleMap[version]}`, children: benefit.description }))] })] }, String(i)));
712
+ return (jsxs("div", { className: "flex gap-4 items-center", children: [benefit.icon ? (jsx(Img, { className: `w-[50px] h-[50px] min-w-[50px] min-h-[50px] rounded-full p-[10px] box-border text-white ${benefitIconBgStyleMap[version]}`, image: benefit.icon, width: "24", height: "24", asSVG: true })) : null, jsxs("div", { className: "flex gap-0.5 flex-col h-full max-w-[149px]", children: [jsx("div", { className: `font-medium text-xl m-0 ${benefitTitleStyleMap[version]}`, children: benefit.label }), benefit.description && (jsx("div", { className: `font-normal text-m-md ${benefitDescStyleMap[version]}`, children: benefit.description }))] })] }, String(i)));
695
713
  }
696
714
 
697
715
  const ProductBlockInner = JSX(({ className = '', context, title, headingType = 'h2', description, benefits, buttons, image, items, version = 'primary', isDotted = true, textBlockClassName = '', }) => {
698
716
  const textColor = version === 'secondary' ? 'text-white' : 'text-primary-text';
699
- return (jsxs("div", { className: `flex grow justify-between items-stretch ${className}`, children: [jsx("div", { className: `flex flex-col ${textBlockClassName}`, children: jsxs(BaseTile, { context: context, title: getTitle(title, headingType, textColor), buttons: getButtons(context, buttons), children: [description && (jsx(Description, { className: `mt-[18px] max-w-[600px] text-title-new-sm font-light ${textColor}`, description: description })), benefits?.filter((items) => items.label)?.length ? (jsx("div", { className: "flex gap-6 mt-6", children: benefits.map((_, i) => renderBenefit(_, i, version)) })) : null, items?.length ? (jsx(List, { className: "mt-5 text-title-new-sm font-light", items: items, itemClassName: "mb-[10px]", version: version, isDotted: isDotted })) : null] }) }), image?.src && jsx(Img, { className: "mt-auto", image: image })] }));
717
+ return (jsxs("div", { className: `flex grow justify-between items-stretch ${className}`, children: [jsx("div", { className: `flex flex-col ${textBlockClassName}`, children: jsxs(BaseTile, { context: context, title: getTitle(title, headingType), buttons: getButtons(context, buttons), children: [description && (jsx(Description, { className: `mt-4 max-w-[600px] text-md font-light ${textColor}`, description: description })), benefits?.filter((items) => items.label)?.length ? (jsx("div", { className: "flex gap-6 mt-6", children: benefits.map((_, i) => renderBenefit(_, i, version)) })) : null, items?.length ? (jsx(List, { className: "mt-5 text-title-2xs font-light", items: items, itemClassName: "mb-[7px]", version: version, isDotted: isDotted })) : null] }) }), image?.src && jsx(Img, { className: "mt-auto", image: image })] }));
700
718
  });
701
- const getTitle = (title, headingType, textColor) => {
702
- const Tag = headingType;
703
- return (title && jsx(Tag, { className: `font-sans font-medium m-0 text-title-xl ${textColor}`, children: title }));
719
+ const getTitle = (title, headingType) => {
720
+ return (title && (jsx(Heading, { headingType: headingType, title: title, className: "whitespace-pre-wrap max-w-[600px]" })));
704
721
  };
705
722
  const getButtons = (context, buttons) => {
706
- return buttons?.length ? (jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-3" })) : null;
723
+ return buttons?.length ? (jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-4" })) : null;
724
+ };
725
+
726
+ const backwardBgStyleMap = {
727
+ primary: 'bg-primary-main',
728
+ secondary: 'bg-white',
729
+ };
730
+ const backwardIconStyleMap = {
731
+ primary: 'text-white',
732
+ secondary: 'text-primary-text',
707
733
  };
734
+ function renderBackwardButton(text, version, className) {
735
+ return (jsxs("div", { className: `flex items-center ${className}`, children: [jsx(Button, { rounded: true, className: `w-12 h-12 min-h-12 max-h-12 flex items-center justify-center mr-3 ${backwardBgStyleMap[version]}`, children: jsx(Img, { className: `w-4 h-4 min-w-4 min-h-4 rounded-full box-border ${backwardIconStyleMap[version]}`, image: { icon: 'ArrowLeftIcon' }, color: "none", width: "24", height: "24", asSVG: true }) }), text ? jsx("span", { className: "text-m-md", children: text }) : null] }));
736
+ }
708
737
 
709
738
  const productBlockStyleMap$1 = {
710
739
  primary: 'bg-white text-primary-text',
@@ -718,7 +747,7 @@
718
747
  const { context, className = '', breadcrumbs, version = 'primary', anchor = null, ...otherProps } = props;
719
748
  const router = context.useRouter();
720
749
  const { handlerDecorator } = context;
721
- return (jsxs("section", { className: `font-sans pt-10 pl-[50px] pb-[50px] pr-[7.5rem] box-border min-h-[420px] ${productBlockStyleMap$1[version]} ${className}`, id: anchor, children: [breadcrumbs?.length ? (jsx("div", { className: "text-xs mb-6", children: joinList(jsx("span", { className: `mx-2 ${breadcrumbsStyleMap[version]}`, children: "/" }))(breadcrumbs.map((breadcrumb, i) => (jsx(Breadcrumb, { ...useLink({ router, handlerDecorator }, { className: breadcrumbsStyleMap[version], ...breadcrumb }) }, String(i))))) })) : null, jsx(ProductBlockInner, { context: context, version: version, ...otherProps })] }));
750
+ return (jsxs("section", { className: `font-sans pt-10 pl-[50px] pb-[50px] pr-[7.5rem] box-border min-h-[420px] ${productBlockStyleMap$1[version]} ${className}`, id: anchor, children: [renderBackwardButton('Все дебетовые карты', version, 'mb-10'), breadcrumbs?.length ? (jsx("div", { className: "text-xs mb-6", children: joinList(jsx("span", { className: `mx-2 ${breadcrumbsStyleMap[version]}`, children: "/" }))(breadcrumbs.map((breadcrumb, i) => (jsx(Breadcrumb, { ...useLink({ router, handlerDecorator }, { className: breadcrumbsStyleMap[version], ...breadcrumb }) }, String(i))))) })) : null, jsx(ProductBlockInner, { context: context, version: version, ...otherProps })] }));
722
751
  });
723
752
 
724
753
  const textBlockStyleMaps = {
@@ -803,11 +832,11 @@
803
832
  };
804
833
  const Tile = JSX((props) => {
805
834
  const { context, title, description, items, children, buttons, image, className = '', version = 'primary', role, anchor = null, } = props;
806
- return (jsx("section", { className: `overflow-hidden font-sans p-9 box-border ${className} ${tileStyleMap[version]} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `, role: role, id: anchor, children: jsxs(BaseTile, { context: context, title: title && (jsx(Heading, { headingType: getTileHeadingType(className), title: title, className: `whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}
807
- ${version === 'primary' ? 'text-primary-text' : ''}` })), buttons: buttons?.length ? (jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-3" })) : null, image: image?.src && jsx(Img, { className: "mt-auto ml-7", image: image }), children: [description && jsx(Description, { className: "mt-4 max-w-[600px]", description: description }), children, renderList$1(items, version)] }) }));
835
+ return (jsx("section", { className: `overflow-hidden font-sans p-9 pr-3 box-border ${className} ${tileStyleMap[version]} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `, role: role, id: anchor, children: jsxs(BaseTile, { context: context, title: title && (jsx(Heading, { headingType: getTileHeadingType(className), title: title, className: `whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}
836
+ ${version === 'primary' ? 'text-primary-text' : ''}` })), buttons: buttons?.length ? (jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-3" })) : null, image: image?.src && jsx(Img, { className: "mt-auto ml-7", image: image }), children: [description && (jsx(Description, { className: "mt-4 max-w-[600px] text-title-new-sm font-light", description: description })), children, renderList$1(items, version)] }) }));
808
837
  });
809
838
  function renderList$1(items, version) {
810
- return items?.length ? (jsx(List, { items: items, itemClassName: "mt-2.5 first:mt-0", version: version })) : null;
839
+ return items?.length ? (jsx(List, { items: items, itemClassName: "text-title-new-sm font-light mt-2.5 first:mt-0", version: version === 'primary' ? 'tile' : 'tile-white' })) : null;
811
840
  }
812
841
 
813
842
  const productTileStyleMap = {
@@ -1370,21 +1399,21 @@
1370
1399
  transparent: 'text-white',
1371
1400
  };
1372
1401
  const Logo = JSX(({ className, href, children, targetBlank, bgColor = 'bg-white', hideTitle }) => {
1373
- return (jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className || ''}`, href: href || 'https://rshb.ru/', target: targetBlank ? '_blank' : '_self', "aria-label": "\u0420\u043E\u0441\u0441\u0435\u043B\u044C\u0445\u043E\u0437\u0431\u0430\u043D\u043A", children: [jsx(SVG, { className: `${SVG_COLOR[bgColor]} w-10`, viewBox: "0 0 40 45", paths: LOGO_PATHS.map((d) => ({ d })) }), !hideTitle && (jsx("span", { className: `${TEXT_COLOR[bgColor]} text-base font-medium ml-2.5`, children: children || 'Россельхозбанк' }))] }));
1402
+ return (jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className || ''}`, href: href || 'https://rshb.ru/', target: targetBlank ? '_blank' : '_self', "aria-label": "\u0420\u043E\u0441\u0441\u0435\u043B\u044C\u0445\u043E\u0437\u0431\u0430\u043D\u043A", children: [jsx(SVG, { className: `${SVG_COLOR[bgColor]} w-10`, viewBox: "0 0 40 45", paths: LOGO_PATHS.map((d) => ({ d })) }), !hideTitle && (jsx("span", { className: `${TEXT_COLOR[bgColor]} text-m-title-xs font-medium ml-2.5`, children: children || 'Россельхозбанк' }))] }));
1374
1403
  });
1375
1404
 
1376
1405
  const SearchBar = JSX(({ className, context }) => {
1377
1406
  const { term, setTerm } = context.useSearch();
1378
- return (jsxs("form", { className: `relative ${className || ''}`, children: [jsxs("div", { className: "absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none", children: [jsx("div", { className: "w-[24px] h-[24px]", children: jsx(Img, { image: "LoupeIcon", width: "24", height: "24" }) }), !term && (jsx("label", { htmlFor: "search-bar-input", className: "font-sans font-normal text-base text-secondary-text", children: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443" }))] }), jsx("input", { id: "search-bar-input", className: 'h-12 pl-12 w-full peer font-sans font-normal text-base text-black border border-solid rounded h-full box-border outline-none pr-[6%] border-main-divider focus:border-primary-text', value: term, onChange: (e) => setTerm(e.target.value), type: "text", name: "search-bar-input" }), jsx(Button, { version: "primary", text: "\u041D\u0430\u0439\u0442\u0438", className: "invisible peer-focus:visible absolute top-1 right-1", onClick: (e) => {
1407
+ return (jsxs("form", { className: `relative ${className || ''}`, children: [jsxs("div", { className: "absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none", children: [jsx("div", { className: "w-[24px] h-[24px]", children: jsx(Img, { image: "LoupeIcon", width: "24", height: "24" }) }), !term && (jsx("label", { htmlFor: "search-bar-input", className: "font-sans font-light text-base text-secondary-text", children: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443" }))] }), jsx("input", { id: "search-bar-input", className: 'h-12 pl-12 w-full peer font-sans font-light text-base text-black border border-solid rounded h-full box-border outline-none pr-[6%] border-main-divider focus:border-primary-text', value: term, onChange: (e) => setTerm(e.target.value), type: "text", name: "search-bar-input" }), jsx(Button, { version: "primary", text: "\u041D\u0430\u0439\u0442\u0438", className: "invisible peer-focus:visible absolute top-1 right-1", onClick: (e) => {
1379
1408
  e.preventDefault();
1380
1409
  console.log('click');
1381
1410
  }, children: jsx("div", { className: "font-normal text-sm px-9 py-[9px]", children: "\u041D\u0430\u0439\u0442\u0438" }) })] }));
1382
1411
  });
1383
1412
 
1384
- const Contacts = JSX(({ className, items, hasButton, context }) => {
1413
+ const Contacts = JSX(({ className = '', items, hasButton, context }) => {
1385
1414
  const router = context.useRouter();
1386
1415
  const { handlerDecorator } = context;
1387
- return (jsxs("div", { className: `flex flex-col ${className || ''}`, children: [items?.length ? items.map(renderContact) : null, hasButton ? (jsx(Button, { version: "primary", className: "mt-0.5 mb-5", ...useLink({ router, handlerDecorator }, {
1416
+ return (jsxs("div", { className: className, children: [items?.length ? items.map(renderContact) : null, hasButton ? (jsx(Button, { version: "primary", className: "mb-6 w-full", ...useLink({ router, handlerDecorator }, {
1388
1417
  text: 'Обратная связь',
1389
1418
  href: '/',
1390
1419
  target: '_blank',
@@ -1392,14 +1421,14 @@
1392
1421
  });
1393
1422
  const renderContact = (item, index) => {
1394
1423
  const { type, text, description } = item;
1395
- return (jsxs("div", { className: "mb-3.5", children: [jsx("div", { children: renderText(type, text) }), jsx("div", { className: "font-sans text-sm text-secondary-text", children: description })] }, String(index)));
1424
+ return (jsxs("div", { className: "mb-4", children: [jsx("div", { children: renderText(type, text) }), jsx("div", { className: "mt-1 font-sans font-light text-sm text-secondary-text", children: description })] }, String(index)));
1396
1425
  };
1397
1426
  const renderText = (type, text = '') => {
1398
1427
  switch (type) {
1399
1428
  case 'tel':
1400
- return (jsx("a", { className: "font-sans font-medium text-xl text-primary-text no-underline", href: `tel:${formatTel(text)}`, children: text }));
1429
+ return (jsx("a", { className: "font-sans text-xl text-primary-text no-underline", href: `tel:${formatTel(text)}`, children: text }));
1401
1430
  case 'email':
1402
- return (jsx("a", { className: "font-sans font-medium text-xl text-primary-text no-underline", href: `mailto:${text}`, children: text }));
1431
+ return (jsx("a", { className: "font-sans text-xl text-primary-text no-underline", href: `mailto:${text}`, children: text }));
1403
1432
  default:
1404
1433
  return jsx("span", { children: text });
1405
1434
  }
@@ -1411,7 +1440,7 @@
1411
1440
  const { handlerDecorator } = context;
1412
1441
  return (jsx("div", { className: className, children: links?.length ? (jsx("div", { className: "flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider", children: links.map((_, i) => (jsx(HorizontalNavigationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null }));
1413
1442
  });
1414
- const HorizontalNavigationLink = JSX(({ className = '', index, text, href, target, onClick }) => (jsx("a", { className: `font-sans font-normal text-sm text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${className}`, href: href, target: target, onClick: onClick, children: text || `Документ ${index}` })));
1443
+ const HorizontalNavigationLink = JSX(({ className = '', index, text, href, target, onClick }) => (jsx("a", { className: `font-sans font-light text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${className}`, href: href, target: target, onClick: onClick, children: text || `Документ ${index}` })));
1415
1444
 
1416
1445
  const cmp = (a) => (b) => a?.href === b?.href;
1417
1446
  const substitute = (items, substitution) => (items || []).map((_) => substitution?.find(cmp(_)) || _);
@@ -1430,20 +1459,20 @@
1430
1459
  return `/wcms-resources/${projectSettings.SITEMAP || 'sitemap'}.json`;
1431
1460
  }
1432
1461
 
1433
- const Sitemap = JSX(({ className, items, context }) => {
1462
+ const Sitemap = JSX(({ className = '', items, context }) => {
1434
1463
  const sitemap = useSitemap(context.useAsyncData);
1435
1464
  const mergedItems = mergeTopItems(sitemap.topItems, items);
1436
1465
  const linkParams = {
1437
1466
  router: context.useRouter(),
1438
1467
  handlerDecorator: context.handlerDecorator,
1439
1468
  };
1440
- return (jsx("div", { className: `flex items-start justify-start gap-11 xl:gap-5 ${className || ''}`, children: mergedItems?.map((_, i) => renderColumn(_, i, linkParams)) }));
1469
+ return (jsx("div", { className: `flex items-start justify-between gap-11 xl:gap-5 ${className}`, children: mergedItems?.map((_, i) => renderColumn(_, i, linkParams)) }));
1441
1470
  });
1442
1471
  const renderColumn = (c, index, { router, handlerDecorator }) => {
1443
1472
  const { text, href, items, target } = c;
1444
- return (jsxs("div", { className: "flex flex-col gap-[14px]", children: [jsx("a", { className: "block font-sans font-medium text-base text-primary-text no-underline", href: href, target: target || '_self', children: text || `Раздел ${index}` }), items?.map((_, i) => (jsx(ColumnItem, { ...useLink({ router, handlerDecorator }, _), index: i }, String(i))))] }, String(index)));
1473
+ return (jsxs("div", { className: "flex flex-col w-1/5 last:w-1/4 gap-[14px]", children: [jsx("a", { className: "block font-sans leading-5 text-base text-primary-text no-underline", href: href, target: target || '_self', children: text || `Раздел ${index}` }), items?.map((_, i) => (jsx(ColumnItem, { ...useLink({ router, handlerDecorator }, _), index: i }, String(i))))] }, String(index)));
1445
1474
  };
1446
- const ColumnItem = JSX(({ text, href, target, index }) => (jsx("a", { className: "block font-sans font-normal text-base text-secondary-text hover:text-primary-main no-underline", href: href, target: target || '_self', children: text || `Раздел ${index}` })));
1475
+ const ColumnItem = JSX(({ text, href, target, index }) => (jsx("a", { className: "block font-sans font-light text-base text-secondary-text hover:text-primary-main no-underline", href: href, target: target || '_self', children: text || `Раздел ${index}` })));
1447
1476
 
1448
1477
  const ICONS_MAP = [
1449
1478
  {
@@ -1467,34 +1496,47 @@
1467
1496
  width: '12px',
1468
1497
  height: '20px',
1469
1498
  },
1499
+ {
1500
+ origins: ['apps.apple.com'],
1501
+ icon: { icon: 'AppleIcon' },
1502
+ label: 'App Store',
1503
+ width: '20px',
1504
+ height: '22px',
1505
+ },
1506
+ {
1507
+ origins: ['play.google.com'],
1508
+ icon: { icon: 'PlayMarketIcon' },
1509
+ label: 'Google Play',
1510
+ width: '21px',
1511
+ height: '21px',
1512
+ },
1470
1513
  ];
1471
1514
  const MediaButton = JSX(({ href }) => {
1472
1515
  const { icon, width, height, label } = ICONS_MAP.find(({ origins }) => origins.some((_) => href?.includes(_))) || {};
1473
1516
  if (!icon)
1474
1517
  return null;
1475
- return (jsx("a", { className: "flex items-center justify-center border border-solid border-main-divider rounded-full no-underline outline-none w-[40px] h-[40px] box-border hover:text-primary-main", href: href, "aria-label": label, target: "_blank", rel: "noopener noreferrer", children: icon ? (jsx(Img, { image: icon, width: width, height: height, asSVG: true, className: "block", color: "none" })) : null }));
1518
+ return (jsx("a", { className: "flex items-center justify-center border border-solid rounded-md border-main-divider no-underline outline-none w-14 h-14 box-border text-primary-main hover:text-white hover:bg-primary-main hover:border-primary-main", href: href, "aria-label": label, target: "_blank", rel: "noopener noreferrer", children: icon ? (jsx(Img, { image: icon, width: width, height: height, asSVG: true, className: "block", color: "none" })) : null }));
1476
1519
  });
1477
1520
 
1478
- const SocialMedia = JSX(({ className, media, context }) => {
1521
+ const SocialMedia = JSX(({ className = '', media, context, children }) => {
1479
1522
  const router = context.useRouter();
1480
1523
  const { handlerDecorator } = context;
1481
- return (jsx("div", { className: `flex items-end gap-2 pt-[30px] pb-7 ${className || ''}`, children: media?.map((_, index) => (jsx(MediaButton, { ...useLink({ router, handlerDecorator }, _) }, String(index)))) }));
1524
+ return (jsxs("div", { children: [jsx("div", { className: `flex gap-2.5 mb-1.5 ${className}`, children: media?.map((_, index) => (jsx(MediaButton, { ...useLink({ router, handlerDecorator }, _) }, String(index)))) }), jsx("span", { className: "font-light text-sm text-secondary-text", children: children })] }));
1482
1525
  });
1483
1526
 
1484
1527
  const TextInformation = JSX(({ className, links, context }) => {
1485
1528
  const router = context.useRouter();
1486
1529
  const { handlerDecorator } = context;
1487
- return (jsxs("div", { className: `${className || ''}`, children: [jsx("div", { className: "pt-5 pb-[5px]", children: jsx("span", { className: "font-sans font-normal text-xs text-secondary-text", children: `\u00a9\u00A02000-${new Date().getFullYear()}\u00A0АО \u00ABРоссельхозбанк\u00BB Генеральная лицензия Банка России \u2116\u00A03349 от\u00A012.08.2015\u00A0г.` }) }), links?.length ? (jsx("div", { className: "flex justify-start items-start gap-5 pt-[5px]", children: links.map((_, i) => (jsx(TextInformationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null] }));
1530
+ return (jsxs("div", { className: `${className || ''}`, children: [jsx("div", { className: "pt-5 pb-[5px]", children: jsx("span", { className: "font-sans font-light text-xs text-secondary-text", children: `\u00a9\u00A02000-${new Date().getFullYear()}\u00A0АО \u00ABРоссельхозбанк\u00BB Генеральная лицензия Банка России \u2116\u00A03349 от\u00A012.08.2015\u00A0г.` }) }), links?.length ? (jsx("div", { className: "flex justify-start items-start gap-5 pt-[5px]", children: links.map((_, i) => (jsx(TextInformationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null] }));
1488
1531
  });
1489
- const TextInformationLink = JSX(({ className, index, text, href, target, onClick }) => (jsx("a", { className: `font-sans font-normal text-xs text-secondary-text visited:text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${className || ''}`, href: href, target: target, onClick: onClick, children: text || `Документ ${index}` })));
1532
+ const TextInformationLink = JSX(({ className, index, text, href, target, onClick }) => (jsx("a", { className: `font-sans font-light text-xs text-secondary-text visited:text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${className || ''}`, href: href, target: target, onClick: onClick, children: text || `Документ ${index}` })));
1490
1533
 
1491
- const LEFT_COL_WIDTH_FULL_HD = 'w-[280px]';
1492
- const LEFT_COL_WIDTH_SMALL_DESKTOP = 'xl:w-[220px]';
1493
- const Footer = JSX(({ className, documents, relatedEnterprises, contacts, socialMedia, topItems, context, anchor = null, }) => {
1494
- return (jsxs("footer", { className: `px-9 py-10 bg-white ${className || ''}`, id: anchor, children: [jsxs("div", { className: "flex items-stretch gap-[54px] pb-8 xl:gap-8", children: [jsx(Logo, { className: `${LEFT_COL_WIDTH_FULL_HD} ${LEFT_COL_WIDTH_SMALL_DESKTOP}` }), jsx(SearchBar, { context: context, className: "grow" })] }), jsxs("div", { className: "flex items-stretch gap-[54px] xl:gap-8", children: [jsx(Contacts, { className: `${LEFT_COL_WIDTH_FULL_HD} shrink-0 overflow-hidden ${LEFT_COL_WIDTH_SMALL_DESKTOP}`, items: contacts, context: context, hasButton: true }), jsx(Sitemap, { className: "pt-[3px]", context: context, items: topItems })] }), jsx(SocialMedia, { media: socialMedia, context: context }), jsx(HorizontalNavigation, { links: relatedEnterprises, context: context }), jsx(TextInformation, { links: documents, context: context })] }));
1534
+ const LEFT_COL_WIDTH_FULL_HD = 'w-[204px]';
1535
+ const Footer = JSX(({ className, documents, relatedEnterprises, contacts, socialMedia, mobileApps, topItems, context, anchor = null, }) => {
1536
+ return (jsxs("footer", { className: `px-9 pt-9 pb-8 bg-white ${className || ''}`, id: anchor, children: [jsxs("div", { className: "flex items-stretch gap-[54px] pb-[30px] xl:gap-8", children: [jsx(Logo, { className: LEFT_COL_WIDTH_FULL_HD }), jsx(SearchBar, { context: context, className: "grow" })] }), jsxs("div", { className: "flex items-stretch gap-[54px] xl:gap-8", children: [jsxs("div", { className: `${LEFT_COL_WIDTH_FULL_HD} flex flex-col shrink-0 overflow-hidden`, children: [jsx(Contacts, { items: contacts, context: context, hasButton: true }), jsx(SocialMedia, { media: socialMedia, context: context, children: "\u0421\u043E\u0446\u0441\u0435\u0442\u0438" }), jsx(SocialMedia, { className: "mt-6", media: mobileApps, context: context, children: "\u041C\u043E\u0431\u0438\u043B\u044C\u043D\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435" })] }), jsx(Sitemap, { className: "pt-[3px]", context: context, items: topItems })] }), jsx(HorizontalNavigation, { className: "mt-24", links: relatedEnterprises, context: context }), jsx(TextInformation, { links: documents, context: context })] }));
1495
1537
  });
1496
1538
 
1497
- const maxBy = (discriminator) => (list) => list.reduceRight((a, b) => (discriminator(a) > discriminator(b) ? a : b));
1539
+ const checkIsHrefSameOrigin = (href, router) => getOrigin(href) === getOrigin(router.href);
1498
1540
 
1499
1541
  const isHrefActive = (href, router, cmp = (href, baseHref) => baseHref.startsWith(href)) => {
1500
1542
  return cmp(withoutQuery(href), withoutMobilePath(withoutQuery(isURL(href) ? router.href : router.pathname)));
@@ -1502,40 +1544,13 @@
1502
1544
 
1503
1545
  const isSubItemActive = (router) => (subItem) => isHrefActive(subItem.href, router);
1504
1546
 
1505
- const findActiveSubItem = (router) => (items = []) => {
1506
- const possibleActiveSubItems = items?.filter(isSubItemActive(router));
1507
- const activeSubItem = possibleActiveSubItems?.length
1508
- ? maxBy((_) => _.href?.length || 0)(possibleActiveSubItems) // More specific item with max length
1509
- : null;
1510
- return activeSubItem;
1511
- };
1512
-
1513
- const checkIsHrefSameOrigin = (href, router) => getOrigin(href) === getOrigin(router.href);
1514
-
1515
1547
  const isTopItemActive = (router) => (topItem) => topItem.items?.some(isSubItemActive(router)) ||
1516
1548
  isHrefActive(topItem.href, router) ||
1517
1549
  checkIsHrefSameOrigin(topItem.href, router);
1518
1550
 
1519
- const TEXT_CLASSES$2 = 'font-sans font-normal text-base';
1520
- const BORDER_CLASSES = 'absolute left-0 -bottom-3 w-full h-[2px]';
1521
- const HeaderItem = JSX(({ className, text, href, target, active, onClick, children, bgColor = 'bg-white' }) => (jsxs("a", { className: `relative inline-block bg-transparent text-center no-underline ${className || ''}`, href: href, target: target, onClick: onClick, children: [jsx("span", { className: getTextClasses$2(bgColor, active), children: text || children }), active ? jsx("div", { className: getBorderClasses(bgColor, active) }) : null] })));
1522
- const getTextClasses$2 = (bgColor, active) => {
1523
- let classes = 'text-white';
1524
- if (bgColor === 'bg-white') {
1525
- classes = active ? 'text-primary-main' : 'text-primary-text hover:text-primary-main';
1526
- }
1527
- return `${classes} ${TEXT_CLASSES$2}`;
1528
- };
1529
- const getBorderClasses = (bgColor, active) => {
1530
- if (!active) {
1531
- return BORDER_CLASSES;
1532
- }
1533
- return `${bgColor === 'bg-white' ? 'bg-primary-main' : bgColor} ${BORDER_CLASSES}`;
1534
- };
1535
-
1536
- const TEXT_CLASSES$1 = 'font-sans font-normal text-sm';
1551
+ const TEXT_CLASSES$2 = 'font-sans font-light text-sm';
1537
1552
  const LINK_CLASSES$1 = 'inline-block border border-solid bg-transparent text-center no-underline';
1538
- const TopItem = JSX(({ className = '', text, href, target, active, flat, onClick, children, ariaLabel, bgColor = 'bg-white', }) => (jsx("a", { className: `${getLinkClasses$1(bgColor, active, flat)} ${className}`, href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": ariaLabel, children: jsx("span", { className: getTextClasses$1(bgColor, active, flat), children: text || children }) })));
1553
+ const TopItem = JSX(({ className = '', text, href, target, active, flat, onClick, children, ariaLabel, bgColor = 'bg-white', }) => (jsx("a", { className: `${getLinkClasses$1(bgColor, active, flat)} ${className}`, href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": ariaLabel, children: jsx("span", { className: getTextClasses$2(bgColor, active, flat), children: text || children }) })));
1539
1554
  const getLinkClasses$1 = (bgColor, active, flat) => {
1540
1555
  let classes = 'border-transparent';
1541
1556
  if (active) {
@@ -1543,14 +1558,14 @@
1543
1558
  }
1544
1559
  return `${classes} ${LINK_CLASSES$1} ${flat ? '' : 'px-4 py-2'}`;
1545
1560
  };
1546
- const getTextClasses$1 = (bgColor, active, flat) => {
1561
+ const getTextClasses$2 = (bgColor, active, flat) => {
1547
1562
  let classes = 'text-white';
1548
1563
  if (bgColor === 'bg-white') {
1549
1564
  classes = active
1550
1565
  ? 'text-primary-main'
1551
1566
  : `${flat ? 'text-primary-text' : 'text-secondary-text'} hover:text-primary-main`;
1552
1567
  }
1553
- return `${classes} ${TEXT_CLASSES$1}`;
1568
+ return `${classes} ${TEXT_CLASSES$2}`;
1554
1569
  };
1555
1570
 
1556
1571
  const HeaderSecondaryMenuButton = JSX(({ className = '', children, ariaLabel }) => (jsx("button", { type: "button", className: `border-0 p-0 w-[24px] h-[24px] flex items-center bg-inherit cursor-pointer ${className}`, disabled: true, "aria-label": ariaLabel, children: children })));
@@ -1559,34 +1574,115 @@
1559
1574
  'bg-white': 'text-primary-text hover:text-primary-main',
1560
1575
  transparent: 'text-white',
1561
1576
  };
1562
- const DOP_LINKS_COLORS_MAP = {
1577
+ const LINKS_COLORS_MAP = {
1563
1578
  'bg-white': 'text-secondary-light hover:text-secondary-hover',
1564
1579
  transparent: 'text-white',
1565
1580
  };
1566
- const DOP_LINKS_ICON_NAME_MAP = {
1581
+ const LINKS_ICON_NAME_MAP = {
1567
1582
  'bg-white': 'GridIcon',
1568
1583
  transparent: 'GridIconWhite',
1569
1584
  };
1570
1585
  const HeaderSecondaryMenu = JSX(({ context, className, defaultLocation = '', bgColor = 'bg-white' }) => {
1571
1586
  const [city, getCity] = context.useGeolocation(defaultLocation);
1572
- return (jsxs("div", { className: `flex items-center ${className || ''}`, children: [jsx(TopItem, { className: "mr-5", flat: true, href: "#", text: city, ariaLabel: "\u041C\u0435\u0441\u0442\u043E\u043F\u043E\u043B\u043E\u0436\u0435\u043D\u0438\u0435", onClick: getCity, bgColor: bgColor }), jsx(TopItem, { className: "mr-7", flat: true, href: "#", text: "\u041E\u0444\u0438\u0441\u044B \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B", ariaLabel: "\u0421\u043F\u0438\u0441\u043E\u043A \u0432\u0441\u0435\u0445 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u044B\u0445 \u043E\u0444\u0438\u0441\u043E\u0432 \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u043E\u0432", bgColor: bgColor }), jsx(HeaderSecondaryMenuButton, { className: `mr-5 ${COLORS_MAP[bgColor]}`, ariaLabel: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443", children: jsx(Img, { image: "LoupeIcon", className: "h-full", asSVG: true, color: "none" }) }), jsx(HeaderSecondaryMenuButton, { className: `mr-5 ${COLORS_MAP[bgColor]}`, ariaLabel: "\u041F\u0440\u043E\u0444\u0438\u043B\u044C", children: jsx(Img, { image: "ProfileIcon", className: "h-full", asSVG: true, color: "none" }) }), jsx(HeaderSecondaryMenuButton, { className: `${DOP_LINKS_COLORS_MAP[bgColor]} min-w-[32px] min-h-[32px]`, ariaLabel: "\u0414\u043E\u043F\u043E\u043B\u043D\u0438\u0442\u0435\u043B\u044C\u043D\u044B\u0435 \u0441\u0441\u044B\u043B\u043A\u0438", children: jsx(Img, { image: DOP_LINKS_ICON_NAME_MAP[bgColor], className: "h-full", asSVG: true, color: "none" }) })] }));
1587
+ return (jsxs("div", { className: `flex items-center ${className || ''}`, children: [jsx(TopItem, { className: "mr-5", flat: true, href: "#", text: city, ariaLabel: "\u041C\u0435\u0441\u0442\u043E\u043F\u043E\u043B\u043E\u0436\u0435\u043D\u0438\u0435", onClick: getCity, bgColor: bgColor }), jsx(TopItem, { className: "mr-7", flat: true, href: "#", text: "\u041E\u0444\u0438\u0441\u044B \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B", ariaLabel: "\u0421\u043F\u0438\u0441\u043E\u043A \u0432\u0441\u0435\u0445 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u044B\u0445 \u043E\u0444\u0438\u0441\u043E\u0432 \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u043E\u0432", bgColor: bgColor }), jsx(HeaderSecondaryMenuButton, { className: `mr-5 ${COLORS_MAP[bgColor]}`, ariaLabel: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443", children: jsx(Img, { image: "LoupeIcon", className: "h-full", asSVG: true, color: "none" }) }), jsx(HeaderSecondaryMenuButton, { className: `${LINKS_COLORS_MAP[bgColor]} min-w-[32px] min-h-[32px]`, ariaLabel: "\u0414\u043E\u043F\u043E\u043B\u043D\u0438\u0442\u0435\u043B\u044C\u043D\u044B\u0435 \u0441\u0441\u044B\u043B\u043A\u0438", children: jsx(Img, { image: LINKS_ICON_NAME_MAP[bgColor], className: "h-full", asSVG: true, color: "none" }) })] }));
1573
1588
  });
1574
1589
 
1590
+ const maxBy = (discriminator) => (list) => list.reduceRight((a, b) => (discriminator(a) > discriminator(b) ? a : b));
1591
+
1592
+ const findActiveSubItem = (router) => (items = []) => {
1593
+ const possibleActiveSubItems = items?.filter(isSubItemActive(router));
1594
+ const activeSubItem = possibleActiveSubItems?.length
1595
+ ? maxBy((_) => _.href?.length || 0)(possibleActiveSubItems) // More specific item with max length
1596
+ : null;
1597
+ return activeSubItem;
1598
+ };
1599
+
1600
+ const TEXT_CLASSES$1 = 'font-sans font-light text-base';
1601
+ const BORDER_CLASSES = 'absolute left-0 -bottom-3 w-full h-[2px]';
1602
+ const HeaderItem = JSX(({ className = '', text, href, target, active, onClick, children, bgColor = 'bg-white', dataItemName, }) => (jsxs("a", { className: `relative inline-block bg-transparent text-center no-underline ${className}`, href: href, target: target, onClick: onClick, "data-item-name": dataItemName, children: [jsx("span", { className: getTextClasses$1(bgColor, active), children: text || children }), active ? jsx("div", { className: getBorderClasses(bgColor, active) }) : null] })));
1603
+ const getTextClasses$1 = (bgColor, active) => {
1604
+ let classes = 'text-white';
1605
+ if (bgColor === 'bg-white') {
1606
+ classes = active ? 'text-primary-main' : 'text-primary-text hover:text-primary-main';
1607
+ }
1608
+ return `${classes} ${TEXT_CLASSES$1}`;
1609
+ };
1610
+ const getBorderClasses = (bgColor, active) => {
1611
+ if (!active) {
1612
+ return BORDER_CLASSES;
1613
+ }
1614
+ return `${bgColor === 'bg-white' ? 'bg-primary-main' : bgColor} ${BORDER_CLASSES}`;
1615
+ };
1616
+
1617
+ const isSSR = () => !(typeof window !== 'undefined' && window.document && window.document.createElement);
1618
+
1619
+ const headerSubMenuObserver = isSSR()
1620
+ ? undefined
1621
+ : new IntersectionObserver((entries) => {
1622
+ const headerSubMenuButtonElement = window.document.querySelector('[data-header-submenu-visible=toggled]');
1623
+ const headerSubMenuItems = Array.from(window.document.querySelectorAll('[data-item-name=header-submenu]'));
1624
+ const dotsHeaderSubMenuItems = Array.from(window.document.querySelectorAll('[data-item-name=dots-header-submenu]'));
1625
+ const visibilityList = {};
1626
+ entries.forEach((j) => {
1627
+ visibilityList[String(j.target.toString())] = j.isIntersecting;
1628
+ });
1629
+ const isHeaderSubMenuButtonShow = toggleVisibilityInItems(visibilityList, dotsHeaderSubMenuItems, 'hidden');
1630
+ toggleVisibilityInItems(visibilityList, headerSubMenuItems, 'invisible');
1631
+ if (headerSubMenuButtonElement) {
1632
+ isHeaderSubMenuButtonShow
1633
+ ? headerSubMenuButtonElement.classList.remove('hidden')
1634
+ : headerSubMenuButtonElement.classList.add('hidden');
1635
+ }
1636
+ }, { root: window.document, threshold: 1.0 });
1637
+ // TODO: add types
1638
+ const toggleVisibilityInItems = (visibilityList, items, className) => {
1639
+ const isReversed = className !== 'hidden';
1640
+ return items.some((item) => {
1641
+ const key = item.toString();
1642
+ const option = isReversed ? !visibilityList[key] : visibilityList[key];
1643
+ key in visibilityList ? item.classList.toggle(className, option) : null;
1644
+ return isReversed ? item.classList.contains('hidden') : !item.classList.contains('hidden');
1645
+ });
1646
+ };
1647
+
1648
+ const HeaderSubMenu = JSX(({ context, subItems, bgColor }) => {
1649
+ const [subMenuIsShow, setHiddenMenuIsShow] = context.useState(false);
1650
+ const router = context.useRouter();
1651
+ const { handlerDecorator } = context;
1652
+ setTimeout(() => {
1653
+ const headerSubMenu = globalThis.document.querySelectorAll('[data-item-name=header-submenu]');
1654
+ headerSubMenu.forEach((_) => {
1655
+ headerSubMenuObserver?.observe(_);
1656
+ });
1657
+ }, 200);
1658
+ const activeSubItem = findActiveSubItem(router)(subItems);
1659
+ const toggleSubMenu = () => setHiddenMenuIsShow(!subMenuIsShow);
1660
+ const subMenu = subItems?.map((_) => (jsx(HeaderItem, { className: "mr-8", active: _ === activeSubItem, ...useLink({ router, handlerDecorator }, _), dataItemName: "header-submenu", bgColor: bgColor }, _.href)));
1661
+ return (jsxs("nav", { className: "relative mt-5", children: [jsx("div", { className: "overflow-hidden whitespace-nowrap mr-52", children: subMenu }), renderDotsSubMenu({
1662
+ subMenuIsShow,
1663
+ toggleSubMenu,
1664
+ subItems,
1665
+ router,
1666
+ handlerDecorator,
1667
+ })] }));
1668
+ });
1669
+ // TODO: add types
1670
+ const renderDotsSubMenu = ({ subMenuIsShow, toggleSubMenu, subItems, router, handlerDecorator, }) => (jsxs("div", { className: `absolute w-52 -top-4 right-0 pt-4 z-40 ${subMenuIsShow ? 'bg-white rounded-md shadow-blue-gray/24' : ''}`, "data-header-submenu-visible": "toggled", children: [jsx("button", { className: "flex justify-between items-center cursor-pointer h-6 ml-6", onClick: toggleSubMenu, children: Array(3).fill(jsx("div", { className: "w-[3px] h-[3px] rounded bg-black mr-1" })) }), jsx("div", { className: `flex flex-col rounded-md bg-white p-6 pb-2 ${subMenuIsShow ? '' : 'hidden'}`, children: renderDotsSubMenuItems(subItems, router, handlerDecorator) })] }));
1671
+ // TODO: add types
1672
+ const renderDotsSubMenuItems = (subItems, router, handlerDecorator) => subItems?.map((_) => (jsx("a", { ...useLink({ router, handlerDecorator }, _), "data-item-name": "dots-header-submenu", className: "text-base font-light pb-4 hover:text-primary-main", children: _.text }, _.href)));
1673
+
1575
1674
  const BORDER_COLORS = {
1576
1675
  'bg-white': 'bg-main-divider',
1577
1676
  transparent: 'bg-main-divider opacity-30',
1578
1677
  };
1579
- const Header = JSX(({ className, defaultLocation = 'Москва', bgColor = 'bg-white', context, topItems, anchor = null, }) => {
1678
+ const Header = JSX(({ className = '', defaultLocation = 'Москва', bgColor = 'bg-white', context, topItems, anchor = null, }) => {
1580
1679
  const router = context.useRouter();
1581
1680
  const sitemap = useSitemap(context.useAsyncData);
1582
1681
  const { handlerDecorator } = context;
1583
1682
  const mergedItems = mergeTopItems(sitemap.topItems, topItems);
1584
1683
  const activeTopItem = mergedItems.find(isTopItemActive(router));
1585
- const subItems = activeTopItem?.items;
1586
- const activeSubItem = findActiveSubItem(router)(subItems);
1587
1684
  const topMenu = mergedItems.map((_, i) => (jsx(TopItem, { active: _ === activeTopItem, ...useLink({ router, handlerDecorator }, _), ariaLabel: _.text, bgColor: bgColor }, String(i))));
1588
- const subMenu = subItems?.map((_) => (jsx(HeaderItem, { className: "mr-8", active: _ === activeSubItem, ...useLink({ router, handlerDecorator }, _), bgColor: bgColor }, _.href)));
1589
- return (jsx("header", { className: `pt-5 pb-8 px-20 ${bgColor} ${className || ''}`, id: anchor, children: jsxs("div", { className: "container", children: [jsxs("div", { className: "flex items-center", children: [jsx(Logo, { className: "mr-8", bgColor: bgColor }), topMenu, jsx(HeaderSecondaryMenu, { context: context, className: "ml-auto", defaultLocation: defaultLocation, bgColor: bgColor })] }), jsx("div", { className: `mt-5 h-[1px] ${BORDER_COLORS[bgColor]}` }), jsx("nav", { className: "mt-5", children: subMenu })] }) }));
1685
+ return (jsx("header", { className: `pt-6 pb-8 px-20 ${bgColor} ${className}`, id: anchor, children: jsxs("div", { className: "container", children: [jsxs("div", { className: "flex items-center", children: [jsx(Logo, { className: "mr-8", bgColor: bgColor }), topMenu, jsx(HeaderSecondaryMenu, { context: context, className: "ml-auto", defaultLocation: defaultLocation, bgColor: bgColor })] }), jsx("div", { className: `mt-6 h-[1px] ${BORDER_COLORS[bgColor]}` }), jsx(HeaderSubMenu, { context: context, subItems: activeTopItem?.items, bgColor: bgColor })] }) }));
1590
1686
  });
1591
1687
 
1592
1688
  const MobileAppTile = JSX(({ className = '', context, title = 'Мобильное приложение', qr, buttons = [], anchor = null, }) => {