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

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 (620) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +301 -158
  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/Blocks.js +1 -1
  40. package/dist/components/Blocks.js.map +1 -1
  41. package/dist/components/ComparisonTable/HeaderCell.js +1 -1
  42. package/dist/components/ComparisonTable/HeaderCell.js.map +1 -1
  43. package/dist/components/ComparisonTable/TableCell.js +1 -1
  44. package/dist/components/ContentPage/ContentPage.js +13 -3
  45. package/dist/components/ContentPage/ContentPage.js.map +1 -1
  46. package/dist/components/CreditCalculator/renderButton.js +8 -1
  47. package/dist/components/CreditCalculator/renderButton.js.map +1 -1
  48. package/dist/components/Footer/Contacts.js +5 -5
  49. package/dist/components/Footer/Contacts.js.map +1 -1
  50. package/dist/components/Footer/Footer.js +3 -4
  51. package/dist/components/Footer/Footer.js.map +1 -1
  52. package/dist/components/Footer/FooterContent.d.ts +2 -0
  53. package/dist/components/Footer/HorizontalNavigation.js +1 -1
  54. package/dist/components/Footer/HorizontalNavigation.js.map +1 -1
  55. package/dist/components/Footer/MediaButton.js +15 -1
  56. package/dist/components/Footer/MediaButton.js.map +1 -1
  57. package/dist/components/Footer/Sitemap.js +4 -4
  58. package/dist/components/Footer/Sitemap.js.map +1 -1
  59. package/dist/components/Footer/SocialMedia.js +2 -2
  60. package/dist/components/Footer/SocialMedia.js.map +1 -1
  61. package/dist/components/Footer/TextInformation.js +2 -2
  62. package/dist/components/Footer/TextInformation.js.map +1 -1
  63. package/dist/components/Gallery/GalleryCardInner.js +5 -6
  64. package/dist/components/Gallery/GalleryCardInner.js.map +1 -1
  65. package/dist/components/Gallery/GalleryContainer.js +2 -2
  66. package/dist/components/Gallery/GalleryContainer.js.map +1 -1
  67. package/dist/components/Gallery/GalleryInner.js +1 -1
  68. package/dist/components/Header/Header.js +4 -8
  69. package/dist/components/Header/Header.js.map +1 -1
  70. package/dist/components/Header/HeaderSecondaryMenu.js +3 -3
  71. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  72. package/dist/components/Header/HeaderSubMenu.d.ts +9 -0
  73. package/dist/components/Header/HeaderSubMenu.js +37 -0
  74. package/dist/components/Header/HeaderSubMenu.js.map +1 -0
  75. package/dist/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  76. package/dist/components/Header/HeaderSubMenuObserver.js +33 -0
  77. package/dist/components/Header/HeaderSubMenuObserver.js.map +1 -0
  78. package/dist/components/LinkDocs/LinkDocsList.d.ts +1 -1
  79. package/dist/components/LinkDocs/LinkDocsList.js +1 -1
  80. package/dist/components/LinkDocs/LinkDocsList.js.map +1 -1
  81. package/dist/components/LinkDocs/LinkDocsListItem.js +1 -1
  82. package/dist/components/LinkDocs/LinkDocsListItem.js.map +1 -1
  83. package/dist/components/NavigatorTabs/NavigatorTabItem.js +4 -4
  84. package/dist/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
  85. package/dist/components/NavigatorTabs/NavigatorTabs.d.ts +1 -1
  86. package/dist/components/NavigatorTabs/NavigatorTabs.js +11 -6
  87. package/dist/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
  88. package/dist/components/NavigatorTabs/NavigatorTabsContent.d.ts +3 -1
  89. package/dist/components/ProductBlock/ProductBlock.js +2 -1
  90. package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
  91. package/dist/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  92. package/dist/components/ProductBlock/ProductBlockInner.js +5 -5
  93. package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
  94. package/dist/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  95. package/dist/components/ProductBlock/renderBackwardButton.js +18 -0
  96. package/dist/components/ProductBlock/renderBackwardButton.js.map +1 -0
  97. package/dist/components/ProductBlock/renderBenefit.js +2 -2
  98. package/dist/components/ProductBlock/renderBenefit.js.map +1 -1
  99. package/dist/components/Recommendation/RecommendationCard.js +2 -1
  100. package/dist/components/Recommendation/RecommendationCard.js.map +1 -1
  101. package/dist/components/Recommendation/RecommendationContent.d.ts +4 -0
  102. package/dist/components/StepsBlock/StepsBlock.js +6 -5
  103. package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
  104. package/dist/components/StepsBlock/StepsBlockContent.d.ts +3 -0
  105. package/dist/components/TariffsTable/TariffsTableCell.js +2 -1
  106. package/dist/components/TariffsTable/TariffsTableCell.js.map +1 -1
  107. package/dist/components/TariffsTable/TariffsTableTileCell.js +2 -1
  108. package/dist/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
  109. package/dist/components/TariffsTable/utils/getButtonAriaLabel.d.ts +2 -0
  110. package/dist/components/TariffsTable/utils/getButtonAriaLabel.js +6 -0
  111. package/dist/components/TariffsTable/utils/getButtonAriaLabel.js.map +1 -0
  112. package/dist/components/Tile/Tile.js +3 -3
  113. package/dist/components/Tile/Tile.js.map +1 -1
  114. package/dist/hooks/useLink.d.ts +1 -1
  115. package/dist/hooks/useLink.js +1 -1
  116. package/dist/hooks/useLink.js.map +1 -1
  117. package/dist/icons/IconName.d.ts +5 -3
  118. package/dist/icons/IconName.js +3 -1
  119. package/dist/icons/IconName.js.map +1 -1
  120. package/dist/ui-kit/Button/Button.js +6 -1
  121. package/dist/ui-kit/Button/Button.js.map +1 -1
  122. package/dist/ui-kit/Button/ButtonInner.js +2 -2
  123. package/dist/ui-kit/Button/ButtonInner.js.map +1 -1
  124. package/dist/ui-kit/HeaderItem/HeaderItem.js +2 -2
  125. package/dist/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  126. package/dist/ui-kit/Heading/Heading.d.ts +2 -1
  127. package/dist/ui-kit/Heading/Heading.js +3 -3
  128. package/dist/ui-kit/Heading/Heading.js.map +1 -1
  129. package/dist/ui-kit/Heading/Heading.mobile.d.ts +2 -1
  130. package/dist/ui-kit/Heading/Heading.mobile.js +2 -2
  131. package/dist/ui-kit/Heading/Heading.mobile.js.map +1 -1
  132. package/dist/ui-kit/Icon/Icon.js +2 -2
  133. package/dist/ui-kit/Icon/Icon.js.map +1 -1
  134. package/dist/ui-kit/List/List.js +2 -0
  135. package/dist/ui-kit/List/List.js.map +1 -1
  136. package/dist/ui-kit/List/ListItem.js +19 -5
  137. package/dist/ui-kit/List/ListItem.js.map +1 -1
  138. package/dist/ui-kit/List/ListProps.d.ts +1 -1
  139. package/dist/ui-kit/Logo/Logo.js +1 -1
  140. package/dist/ui-kit/Logo/Logo.js.map +1 -1
  141. package/dist/ui-kit/SearchBar/SearchBar.js +1 -1
  142. package/dist/ui-kit/SearchBar/SearchBar.js.map +1 -1
  143. package/dist/ui-kit/TopItem/TopItem.d.ts +1 -0
  144. package/dist/ui-kit/TopItem/TopItem.js +1 -1
  145. package/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  146. package/dist/utils/changeHashOnScroll.d.ts +2 -0
  147. package/dist/utils/changeHashOnScroll.js +16 -0
  148. package/dist/utils/changeHashOnScroll.js.map +1 -0
  149. package/dist/utils/isSSR.d.ts +1 -0
  150. package/dist/utils/isSSR.js +5 -0
  151. package/dist/utils/isSSR.js.map +1 -0
  152. package/dist/utils/tableFunc.d.ts +2 -0
  153. package/dist/utils/tableFunc.js +8 -0
  154. package/dist/utils/tableFunc.js.map +1 -0
  155. package/lib/common.css +1 -1
  156. package/lib/components/Blocks.js +1 -1
  157. package/lib/components/Blocks.js.map +1 -1
  158. package/lib/components/ComparisonTable/HeaderCell.js +1 -1
  159. package/lib/components/ComparisonTable/HeaderCell.js.map +1 -1
  160. package/lib/components/ComparisonTable/TableCell.js +1 -1
  161. package/lib/components/ContentPage/ContentPage.js +13 -3
  162. package/lib/components/ContentPage/ContentPage.js.map +1 -1
  163. package/lib/components/CreditCalculator/renderButton.js +8 -1
  164. package/lib/components/CreditCalculator/renderButton.js.map +1 -1
  165. package/lib/components/Footer/Contacts.js +5 -5
  166. package/lib/components/Footer/Contacts.js.map +1 -1
  167. package/lib/components/Footer/Footer.js +3 -4
  168. package/lib/components/Footer/Footer.js.map +1 -1
  169. package/lib/components/Footer/FooterContent.d.ts +2 -0
  170. package/lib/components/Footer/HorizontalNavigation.js +1 -1
  171. package/lib/components/Footer/HorizontalNavigation.js.map +1 -1
  172. package/lib/components/Footer/MediaButton.js +15 -1
  173. package/lib/components/Footer/MediaButton.js.map +1 -1
  174. package/lib/components/Footer/Sitemap.js +4 -4
  175. package/lib/components/Footer/Sitemap.js.map +1 -1
  176. package/lib/components/Footer/SocialMedia.js +3 -3
  177. package/lib/components/Footer/SocialMedia.js.map +1 -1
  178. package/lib/components/Footer/TextInformation.js +2 -2
  179. package/lib/components/Footer/TextInformation.js.map +1 -1
  180. package/lib/components/Gallery/GalleryCardInner.js +5 -6
  181. package/lib/components/Gallery/GalleryCardInner.js.map +1 -1
  182. package/lib/components/Gallery/GalleryContainer.js +2 -2
  183. package/lib/components/Gallery/GalleryContainer.js.map +1 -1
  184. package/lib/components/Gallery/GalleryInner.js +1 -1
  185. package/lib/components/Header/Header.js +4 -8
  186. package/lib/components/Header/Header.js.map +1 -1
  187. package/lib/components/Header/HeaderSecondaryMenu.js +3 -3
  188. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  189. package/lib/components/Header/HeaderSubMenu.d.ts +9 -0
  190. package/lib/components/Header/HeaderSubMenu.js +35 -0
  191. package/lib/components/Header/HeaderSubMenu.js.map +1 -0
  192. package/lib/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  193. package/lib/components/Header/HeaderSubMenuObserver.js +31 -0
  194. package/lib/components/Header/HeaderSubMenuObserver.js.map +1 -0
  195. package/lib/components/LinkDocs/LinkDocsList.d.ts +1 -1
  196. package/lib/components/LinkDocs/LinkDocsList.js +1 -1
  197. package/lib/components/LinkDocs/LinkDocsList.js.map +1 -1
  198. package/lib/components/LinkDocs/LinkDocsListItem.js +1 -1
  199. package/lib/components/LinkDocs/LinkDocsListItem.js.map +1 -1
  200. package/lib/components/NavigatorTabs/NavigatorTabItem.js +4 -4
  201. package/lib/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
  202. package/lib/components/NavigatorTabs/NavigatorTabs.d.ts +1 -1
  203. package/lib/components/NavigatorTabs/NavigatorTabs.js +12 -7
  204. package/lib/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
  205. package/lib/components/NavigatorTabs/NavigatorTabsContent.d.ts +3 -1
  206. package/lib/components/ProductBlock/ProductBlock.fixture.d.ts +1 -0
  207. package/lib/components/ProductBlock/ProductBlock.js +2 -1
  208. package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
  209. package/lib/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  210. package/lib/components/ProductBlock/ProductBlockInner.js +5 -5
  211. package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
  212. package/lib/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  213. package/lib/components/ProductBlock/renderBackwardButton.js +15 -0
  214. package/lib/components/ProductBlock/renderBackwardButton.js.map +1 -0
  215. package/lib/components/ProductBlock/renderBenefit.js +2 -2
  216. package/lib/components/ProductBlock/renderBenefit.js.map +1 -1
  217. package/lib/components/Recommendation/RecommendationCard.js +2 -1
  218. package/lib/components/Recommendation/RecommendationCard.js.map +1 -1
  219. package/lib/components/Recommendation/RecommendationContent.d.ts +4 -0
  220. package/lib/components/StepsBlock/StepsBlock.fixture.d.ts +2 -0
  221. package/lib/components/StepsBlock/StepsBlock.js +6 -5
  222. package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
  223. package/lib/components/StepsBlock/StepsBlockContent.d.ts +3 -0
  224. package/lib/components/TariffsTable/TariffsTableCell.js +2 -1
  225. package/lib/components/TariffsTable/TariffsTableCell.js.map +1 -1
  226. package/lib/components/TariffsTable/TariffsTableTileCell.js +2 -1
  227. package/lib/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
  228. package/lib/components/TariffsTable/utils/getButtonAriaLabel.d.ts +2 -0
  229. package/lib/components/TariffsTable/utils/getButtonAriaLabel.js +3 -0
  230. package/lib/components/TariffsTable/utils/getButtonAriaLabel.js.map +1 -0
  231. package/lib/components/Tile/Tile.js +3 -3
  232. package/lib/components/Tile/Tile.js.map +1 -1
  233. package/lib/hooks/useLink.d.ts +1 -1
  234. package/lib/hooks/useLink.js +1 -1
  235. package/lib/hooks/useLink.js.map +1 -1
  236. package/lib/icons/IconName.d.ts +5 -3
  237. package/lib/icons/IconName.js +3 -1
  238. package/lib/icons/IconName.js.map +1 -1
  239. package/lib/ui-kit/Button/Button.js +6 -1
  240. package/lib/ui-kit/Button/Button.js.map +1 -1
  241. package/lib/ui-kit/Button/ButtonInner.js +2 -2
  242. package/lib/ui-kit/Button/ButtonInner.js.map +1 -1
  243. package/lib/ui-kit/HeaderItem/HeaderItem.js +2 -2
  244. package/lib/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  245. package/lib/ui-kit/Heading/Heading.d.ts +2 -1
  246. package/lib/ui-kit/Heading/Heading.js +3 -3
  247. package/lib/ui-kit/Heading/Heading.js.map +1 -1
  248. package/lib/ui-kit/Heading/Heading.mobile.d.ts +2 -1
  249. package/lib/ui-kit/Heading/Heading.mobile.js +2 -2
  250. package/lib/ui-kit/Heading/Heading.mobile.js.map +1 -1
  251. package/lib/ui-kit/Icon/Icon.js +2 -2
  252. package/lib/ui-kit/Icon/Icon.js.map +1 -1
  253. package/lib/ui-kit/List/List.js +2 -0
  254. package/lib/ui-kit/List/List.js.map +1 -1
  255. package/lib/ui-kit/List/ListItem.js +19 -5
  256. package/lib/ui-kit/List/ListItem.js.map +1 -1
  257. package/lib/ui-kit/List/ListProps.d.ts +1 -1
  258. package/lib/ui-kit/Logo/Logo.js +1 -1
  259. package/lib/ui-kit/Logo/Logo.js.map +1 -1
  260. package/lib/ui-kit/SearchBar/SearchBar.js +1 -1
  261. package/lib/ui-kit/SearchBar/SearchBar.js.map +1 -1
  262. package/lib/ui-kit/TopItem/TopItem.d.ts +1 -0
  263. package/lib/ui-kit/TopItem/TopItem.js +1 -1
  264. package/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  265. package/lib/utils/changeHashOnScroll.d.ts +2 -0
  266. package/lib/utils/changeHashOnScroll.js +13 -0
  267. package/lib/utils/changeHashOnScroll.js.map +1 -0
  268. package/lib/utils/isSSR.d.ts +1 -0
  269. package/lib/utils/isSSR.js +2 -0
  270. package/lib/utils/isSSR.js.map +1 -0
  271. package/lib/utils/tableFunc.d.ts +2 -0
  272. package/lib/utils/tableFunc.js +5 -0
  273. package/lib/utils/tableFunc.js.map +1 -0
  274. package/mobile/bundle/bundle.umd.js +80 -23
  275. package/mobile/bundle/bundle.umd.min.js +1 -1
  276. package/mobile/dist/components/ContentPage/ContentPage.js +13 -3
  277. package/mobile/dist/components/ContentPage/ContentPage.js.map +1 -1
  278. package/mobile/dist/components/CreditCalculator/renderButton.js +8 -1
  279. package/mobile/dist/components/CreditCalculator/renderButton.js.map +1 -1
  280. package/mobile/dist/components/Footer/Contacts.js +5 -5
  281. package/mobile/dist/components/Footer/Contacts.js.map +1 -1
  282. package/mobile/dist/components/Footer/FooterContent.d.ts +2 -0
  283. package/mobile/dist/components/Footer/MediaButton.js +15 -1
  284. package/mobile/dist/components/Footer/MediaButton.js.map +1 -1
  285. package/mobile/dist/components/Footer/Sitemap.js +4 -4
  286. package/mobile/dist/components/Footer/Sitemap.js.map +1 -1
  287. package/mobile/dist/components/Gallery/GalleryCardInner.js +5 -6
  288. package/mobile/dist/components/Gallery/GalleryCardInner.js.map +1 -1
  289. package/mobile/dist/components/Gallery/GalleryContainer.js +2 -2
  290. package/mobile/dist/components/Gallery/GalleryContainer.js.map +1 -1
  291. package/mobile/dist/components/Gallery/GalleryInner.js +1 -1
  292. package/mobile/dist/components/Header/HeaderSecondaryMenu.js +3 -3
  293. package/mobile/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  294. package/mobile/dist/components/Header/HeaderSubMenu.d.ts +9 -0
  295. package/mobile/dist/components/Header/HeaderSubMenu.js +37 -0
  296. package/mobile/dist/components/Header/HeaderSubMenu.js.map +1 -0
  297. package/mobile/dist/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  298. package/mobile/dist/components/Header/HeaderSubMenuObserver.js +33 -0
  299. package/mobile/dist/components/Header/HeaderSubMenuObserver.js.map +1 -0
  300. package/mobile/dist/components/LinkDocs/LinkDocsList.d.ts +1 -1
  301. package/mobile/dist/components/LinkDocs/LinkDocsList.js +1 -1
  302. package/mobile/dist/components/LinkDocs/LinkDocsList.js.map +1 -1
  303. package/mobile/dist/components/NavigatorTabs/NavigatorTabItem.js +4 -4
  304. package/mobile/dist/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
  305. package/mobile/dist/components/NavigatorTabs/NavigatorTabs.d.ts +1 -1
  306. package/mobile/dist/components/NavigatorTabs/NavigatorTabs.js +11 -6
  307. package/mobile/dist/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
  308. package/mobile/dist/components/NavigatorTabs/NavigatorTabsContent.d.ts +3 -1
  309. package/mobile/dist/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  310. package/mobile/dist/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  311. package/mobile/dist/components/ProductBlock/renderBackwardButton.js +18 -0
  312. package/mobile/dist/components/ProductBlock/renderBackwardButton.js.map +1 -0
  313. package/mobile/dist/components/Recommendation/RecommendationCard.js +2 -1
  314. package/mobile/dist/components/Recommendation/RecommendationCard.js.map +1 -1
  315. package/mobile/dist/components/Recommendation/RecommendationContent.d.ts +4 -0
  316. package/mobile/dist/components/StepsBlock/StepsBlockContent.d.ts +3 -0
  317. package/mobile/dist/components/TariffsTable/TariffsTableCell.js +2 -1
  318. package/mobile/dist/components/TariffsTable/TariffsTableCell.js.map +1 -1
  319. package/mobile/dist/components/TariffsTable/TariffsTableTileCell.js +2 -1
  320. package/mobile/dist/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
  321. package/mobile/dist/components/TariffsTable/utils/getButtonAriaLabel.d.ts +2 -0
  322. package/mobile/dist/components/TariffsTable/utils/getButtonAriaLabel.js +6 -0
  323. package/mobile/dist/components/TariffsTable/utils/getButtonAriaLabel.js.map +1 -0
  324. package/mobile/dist/components/Tile/Tile.js +3 -3
  325. package/mobile/dist/components/Tile/Tile.js.map +1 -1
  326. package/mobile/dist/hooks/useLink.d.ts +1 -1
  327. package/mobile/dist/hooks/useLink.js +1 -1
  328. package/mobile/dist/hooks/useLink.js.map +1 -1
  329. package/mobile/dist/icons/IconName.d.ts +5 -3
  330. package/mobile/dist/icons/IconName.js +3 -1
  331. package/mobile/dist/icons/IconName.js.map +1 -1
  332. package/mobile/dist/ui-kit/Button/ButtonInner.js +2 -2
  333. package/mobile/dist/ui-kit/Button/ButtonInner.js.map +1 -1
  334. package/mobile/dist/ui-kit/Heading/Heading.d.ts +2 -1
  335. package/mobile/dist/ui-kit/Heading/Heading.js +2 -2
  336. package/mobile/dist/ui-kit/Heading/Heading.js.map +1 -1
  337. package/mobile/dist/ui-kit/Icon/Icon.js +2 -2
  338. package/mobile/dist/ui-kit/Icon/Icon.js.map +1 -1
  339. package/mobile/dist/ui-kit/List/List.js +2 -0
  340. package/mobile/dist/ui-kit/List/List.js.map +1 -1
  341. package/mobile/dist/ui-kit/List/ListItem.js +19 -5
  342. package/mobile/dist/ui-kit/List/ListItem.js.map +1 -1
  343. package/mobile/dist/ui-kit/List/ListProps.d.ts +1 -1
  344. package/mobile/dist/ui-kit/TopItem/TopItem.d.ts +1 -0
  345. package/mobile/dist/ui-kit/TopItem/TopItem.js +1 -1
  346. package/mobile/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  347. package/mobile/dist/utils/changeHashOnScroll.d.ts +2 -0
  348. package/mobile/dist/utils/changeHashOnScroll.js +16 -0
  349. package/mobile/dist/utils/changeHashOnScroll.js.map +1 -0
  350. package/mobile/dist/utils/isSSR.d.ts +1 -0
  351. package/mobile/dist/utils/isSSR.js +5 -0
  352. package/mobile/dist/utils/isSSR.js.map +1 -0
  353. package/mobile/dist/utils/tableFunc.d.ts +2 -0
  354. package/mobile/dist/utils/tableFunc.js +8 -0
  355. package/mobile/dist/utils/tableFunc.js.map +1 -0
  356. package/mobile/lib/components/ContentPage/ContentPage.js +13 -3
  357. package/mobile/lib/components/ContentPage/ContentPage.js.map +1 -1
  358. package/mobile/lib/components/CreditCalculator/renderButton.js +8 -1
  359. package/mobile/lib/components/CreditCalculator/renderButton.js.map +1 -1
  360. package/mobile/lib/components/Footer/Contacts.js +5 -5
  361. package/mobile/lib/components/Footer/Contacts.js.map +1 -1
  362. package/mobile/lib/components/Footer/FooterContent.d.ts +2 -0
  363. package/mobile/lib/components/Footer/MediaButton.js +15 -1
  364. package/mobile/lib/components/Footer/MediaButton.js.map +1 -1
  365. package/mobile/lib/components/Footer/Sitemap.js +4 -4
  366. package/mobile/lib/components/Footer/Sitemap.js.map +1 -1
  367. package/mobile/lib/components/Gallery/GalleryCardInner.js +5 -6
  368. package/mobile/lib/components/Gallery/GalleryCardInner.js.map +1 -1
  369. package/mobile/lib/components/Gallery/GalleryContainer.js +2 -2
  370. package/mobile/lib/components/Gallery/GalleryContainer.js.map +1 -1
  371. package/mobile/lib/components/Gallery/GalleryInner.js +1 -1
  372. package/mobile/lib/components/Header/HeaderSecondaryMenu.js +3 -3
  373. package/mobile/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  374. package/mobile/lib/components/Header/HeaderSubMenu.d.ts +9 -0
  375. package/mobile/lib/components/Header/HeaderSubMenu.js +35 -0
  376. package/mobile/lib/components/Header/HeaderSubMenu.js.map +1 -0
  377. package/mobile/lib/components/Header/HeaderSubMenuObserver.d.ts +1 -0
  378. package/mobile/lib/components/Header/HeaderSubMenuObserver.js +31 -0
  379. package/mobile/lib/components/Header/HeaderSubMenuObserver.js.map +1 -0
  380. package/mobile/lib/components/LinkDocs/LinkDocsList.d.ts +1 -1
  381. package/mobile/lib/components/LinkDocs/LinkDocsList.js +1 -1
  382. package/mobile/lib/components/LinkDocs/LinkDocsList.js.map +1 -1
  383. package/mobile/lib/components/NavigatorTabs/NavigatorTabItem.js +4 -4
  384. package/mobile/lib/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
  385. package/mobile/lib/components/NavigatorTabs/NavigatorTabs.d.ts +1 -1
  386. package/mobile/lib/components/NavigatorTabs/NavigatorTabs.js +12 -7
  387. package/mobile/lib/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
  388. package/mobile/lib/components/NavigatorTabs/NavigatorTabsContent.d.ts +3 -1
  389. package/mobile/lib/components/ProductBlock/ProductBlockContent.d.ts +3 -1
  390. package/mobile/lib/components/ProductBlock/renderBackwardButton.d.ts +2 -0
  391. package/mobile/lib/components/ProductBlock/renderBackwardButton.js +15 -0
  392. package/mobile/lib/components/ProductBlock/renderBackwardButton.js.map +1 -0
  393. package/mobile/lib/components/Recommendation/RecommendationCard.js +2 -1
  394. package/mobile/lib/components/Recommendation/RecommendationCard.js.map +1 -1
  395. package/mobile/lib/components/Recommendation/RecommendationContent.d.ts +4 -0
  396. package/mobile/lib/components/StepsBlock/StepsBlockContent.d.ts +3 -0
  397. package/mobile/lib/components/TariffsTable/TariffsTableCell.js +2 -1
  398. package/mobile/lib/components/TariffsTable/TariffsTableCell.js.map +1 -1
  399. package/mobile/lib/components/TariffsTable/TariffsTableTileCell.js +2 -1
  400. package/mobile/lib/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
  401. package/mobile/lib/components/TariffsTable/utils/getButtonAriaLabel.d.ts +2 -0
  402. package/mobile/lib/components/TariffsTable/utils/getButtonAriaLabel.js +3 -0
  403. package/mobile/lib/components/TariffsTable/utils/getButtonAriaLabel.js.map +1 -0
  404. package/mobile/lib/components/Tile/Tile.js +3 -3
  405. package/mobile/lib/components/Tile/Tile.js.map +1 -1
  406. package/mobile/lib/hooks/useLink.d.ts +1 -1
  407. package/mobile/lib/hooks/useLink.js +1 -1
  408. package/mobile/lib/hooks/useLink.js.map +1 -1
  409. package/mobile/lib/icons/IconName.d.ts +5 -3
  410. package/mobile/lib/icons/IconName.js +3 -1
  411. package/mobile/lib/icons/IconName.js.map +1 -1
  412. package/mobile/lib/ui-kit/Button/ButtonInner.js +2 -2
  413. package/mobile/lib/ui-kit/Button/ButtonInner.js.map +1 -1
  414. package/mobile/lib/ui-kit/Heading/Heading.d.ts +2 -1
  415. package/mobile/lib/ui-kit/Heading/Heading.js +2 -2
  416. package/mobile/lib/ui-kit/Heading/Heading.js.map +1 -1
  417. package/mobile/lib/ui-kit/Icon/Icon.js +2 -2
  418. package/mobile/lib/ui-kit/Icon/Icon.js.map +1 -1
  419. package/mobile/lib/ui-kit/List/List.js +2 -0
  420. package/mobile/lib/ui-kit/List/List.js.map +1 -1
  421. package/mobile/lib/ui-kit/List/ListItem.js +19 -5
  422. package/mobile/lib/ui-kit/List/ListItem.js.map +1 -1
  423. package/mobile/lib/ui-kit/List/ListProps.d.ts +1 -1
  424. package/mobile/lib/ui-kit/TopItem/TopItem.d.ts +1 -0
  425. package/mobile/lib/ui-kit/TopItem/TopItem.js +1 -1
  426. package/mobile/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  427. package/mobile/lib/utils/changeHashOnScroll.d.ts +2 -0
  428. package/mobile/lib/utils/changeHashOnScroll.js +13 -0
  429. package/mobile/lib/utils/changeHashOnScroll.js.map +1 -0
  430. package/mobile/lib/utils/isSSR.d.ts +1 -0
  431. package/mobile/lib/utils/isSSR.js +2 -0
  432. package/mobile/lib/utils/isSSR.js.map +1 -0
  433. package/mobile/lib/utils/tableFunc.d.ts +2 -0
  434. package/mobile/lib/utils/tableFunc.js +5 -0
  435. package/mobile/lib/utils/tableFunc.js.map +1 -0
  436. package/mobile/src/components/ContentPage/ContentPage.page.json +98 -238
  437. package/mobile/src/components/ContentPage/ContentPage.tsx +18 -2
  438. package/mobile/src/components/CreditCalculator/renderButton.tsx +11 -1
  439. package/mobile/src/components/Footer/Contacts.tsx +7 -10
  440. package/mobile/src/components/Footer/FooterContent.ts +2 -0
  441. package/mobile/src/components/Footer/MediaButton.tsx +15 -1
  442. package/mobile/src/components/Footer/Sitemap.tsx +5 -5
  443. package/mobile/src/components/Gallery/GalleryCardInner.tsx +6 -7
  444. package/mobile/src/components/Gallery/GalleryContainer.tsx +2 -2
  445. package/mobile/src/components/Gallery/GalleryInner.tsx +1 -1
  446. package/mobile/src/components/Header/HeaderSecondaryMenu.tsx +4 -7
  447. package/mobile/src/components/Header/HeaderSubMenu.tsx +103 -0
  448. package/mobile/src/components/Header/HeaderSubMenuObserver.ts +46 -0
  449. package/mobile/src/components/LinkDocs/LinkDocsList.tsx +3 -3
  450. package/mobile/src/components/NavigatorTabs/NavigatorTabItem.tsx +7 -5
  451. package/mobile/src/components/NavigatorTabs/NavigatorTabs.example.json +3 -3
  452. package/mobile/src/components/NavigatorTabs/NavigatorTabs.tsx +17 -9
  453. package/mobile/src/components/NavigatorTabs/NavigatorTabsContent.ts +3 -1
  454. package/mobile/src/components/ProductBlock/ProductBlockContent.ts +3 -1
  455. package/mobile/src/components/ProductBlock/renderBackwardButton.tsx +35 -0
  456. package/mobile/src/components/Recommendation/RecommendationCard.tsx +2 -1
  457. package/mobile/src/components/Recommendation/RecommendationContent.ts +4 -0
  458. package/mobile/src/components/StepsBlock/StepsBlockContent.ts +3 -0
  459. package/mobile/src/components/TariffsTable/TariffsTableCell.tsx +2 -0
  460. package/mobile/src/components/TariffsTable/TariffsTableTileCell.tsx +2 -0
  461. package/mobile/src/components/TariffsTable/utils/getButtonAriaLabel.ts +5 -0
  462. package/mobile/src/components/Tile/Tile.example.json +1 -1
  463. package/mobile/src/components/Tile/Tile.tsx +13 -3
  464. package/mobile/src/hooks/useLink.ts +1 -1
  465. package/mobile/src/icons/ArrowDownIcon.svg +1 -1
  466. package/mobile/src/icons/ArrowLeftIcon.svg +4 -0
  467. package/mobile/src/icons/BurgerIcon.svg +4 -4
  468. package/mobile/src/icons/Calendar2Icon.svg +1 -1
  469. package/mobile/src/icons/CalendarCircleIcon.svg +4 -1
  470. package/mobile/src/icons/CalendarIcon.svg +1 -1
  471. package/mobile/src/icons/CalendarTickIcon.svg +6 -1
  472. package/mobile/src/icons/CalendarWhiteIcon.svg +2 -2
  473. package/mobile/src/icons/CardIcon.svg +5 -1
  474. package/mobile/src/icons/CardPosIcon.svg +5 -1
  475. package/mobile/src/icons/CardTickIcon.svg +5 -1
  476. package/mobile/src/icons/ChartSquareIcon.svg +6 -1
  477. package/mobile/src/icons/CloseIcon.svg +4 -4
  478. package/mobile/src/icons/DiscountShapeIcon.svg +4 -1
  479. package/mobile/src/icons/DocIcon.svg +1 -1
  480. package/mobile/src/icons/DocumentTextIcon.svg +2 -2
  481. package/mobile/src/icons/EmptyWalletChangeIcon.svg +8 -1
  482. package/mobile/src/icons/EmptyWalletIcon.svg +2 -2
  483. package/mobile/src/icons/GlobalIcon.svg +5 -1
  484. package/mobile/src/icons/GpsIcon.svg +6 -6
  485. package/mobile/src/icons/IconName.ts +4 -4
  486. package/mobile/src/icons/InterestIcon.svg +6 -1
  487. package/mobile/src/icons/MasterCardIcon.svg +5 -1
  488. package/mobile/src/icons/MinusIcon.svg +3 -1
  489. package/mobile/src/icons/MoneyIcon.svg +5 -1
  490. package/mobile/src/icons/MonitorMobileIcon.svg +4 -1
  491. package/mobile/src/icons/PercentageRoundIcon.svg +4 -1
  492. package/mobile/src/icons/PercentageSquareIcon.svg +1 -1
  493. package/mobile/src/icons/PersonalCardIcon.svg +4 -1
  494. package/mobile/src/icons/PlayMarketIcon.svg +3 -1
  495. package/mobile/src/icons/PlusIcon.svg +3 -1
  496. package/mobile/src/icons/Profile2UserIcon.svg +6 -1
  497. package/mobile/src/icons/RoundRubleIcon.svg +5 -1
  498. package/mobile/src/icons/SafeIcon.svg +7 -1
  499. package/mobile/src/icons/ShieldTickIcon.svg +4 -1
  500. package/mobile/src/icons/SmallClockIcon.svg +4 -1
  501. package/mobile/src/icons/UserTickIcon.svg +5 -1
  502. package/mobile/src/icons/WalletAdd2Icon.svg +6 -1
  503. package/mobile/src/icons/WalletAddIcon.svg +7 -1
  504. package/mobile/src/icons/WalletIcon.svg +7 -1
  505. package/mobile/src/icons/WalletWithMoneyIcon.svg +5 -1
  506. package/mobile/src/ui-kit/Button/ButtonInner.tsx +2 -2
  507. package/mobile/src/ui-kit/Heading/Heading.tsx +5 -2
  508. package/mobile/src/ui-kit/Icon/Icon.tsx +2 -2
  509. package/mobile/src/ui-kit/List/List.tsx +2 -0
  510. package/mobile/src/ui-kit/List/ListItem.tsx +19 -5
  511. package/mobile/src/ui-kit/List/ListProps.ts +1 -1
  512. package/mobile/src/ui-kit/TopItem/TopItem.tsx +2 -1
  513. package/mobile/src/utils/changeHashOnScroll.ts +15 -0
  514. package/mobile/src/utils/isSSR.ts +2 -0
  515. package/mobile/src/utils/tableFunc.ts +8 -0
  516. package/package.json +1 -1
  517. package/src/components/Blocks.ts +1 -1
  518. package/src/components/ComparisonTable/HeaderCell.tsx +1 -1
  519. package/src/components/ComparisonTable/TableCell.tsx +1 -1
  520. package/src/components/ContentPage/ContentPage.page.json +98 -238
  521. package/src/components/ContentPage/ContentPage.tsx +18 -2
  522. package/src/components/CreditCalculator/renderButton.tsx +11 -1
  523. package/src/components/Footer/Contacts.tsx +7 -10
  524. package/src/components/Footer/Footer.fixture.mobile.tsx +3 -3
  525. package/src/components/Footer/Footer.fixture.tsx +4 -3
  526. package/src/components/Footer/Footer.tsx +15 -13
  527. package/src/components/Footer/FooterContent.ts +2 -0
  528. package/src/components/Footer/HorizontalNavigation.tsx +1 -1
  529. package/src/components/Footer/MediaButton.tsx +15 -1
  530. package/src/components/Footer/Sitemap.tsx +5 -5
  531. package/src/components/Footer/SocialMedia.tsx +8 -5
  532. package/src/components/Footer/TextInformation.tsx +2 -2
  533. package/src/components/Gallery/GalleryCardInner.tsx +6 -7
  534. package/src/components/Gallery/GalleryContainer.tsx +2 -2
  535. package/src/components/Gallery/GalleryInner.tsx +1 -1
  536. package/src/components/Header/Header.tsx +6 -19
  537. package/src/components/Header/HeaderSecondaryMenu.tsx +4 -7
  538. package/src/components/Header/HeaderSubMenu.tsx +103 -0
  539. package/src/components/Header/HeaderSubMenuObserver.ts +46 -0
  540. package/src/components/LinkDocs/LinkDocsList.tsx +3 -3
  541. package/src/components/LinkDocs/LinkDocsListItem.tsx +3 -3
  542. package/src/components/MobileAppTile/MobileAppTile.fixture.tsx +2 -2
  543. package/src/components/NavigatorTabs/NavigatorTabItem.tsx +7 -5
  544. package/src/components/NavigatorTabs/NavigatorTabs.example.json +3 -3
  545. package/src/components/NavigatorTabs/NavigatorTabs.tsx +17 -9
  546. package/src/components/NavigatorTabs/NavigatorTabsContent.ts +3 -1
  547. package/src/components/ProductBlock/ProductBlock.fixture.tsx +35 -34
  548. package/src/components/ProductBlock/ProductBlock.tsx +2 -0
  549. package/src/components/ProductBlock/ProductBlockContent.ts +3 -1
  550. package/src/components/ProductBlock/ProductBlockInner.tsx +14 -8
  551. package/src/components/ProductBlock/renderBackwardButton.tsx +35 -0
  552. package/src/components/ProductBlock/renderBenefit.tsx +4 -4
  553. package/src/components/Recommendation/RecommendationCard.tsx +2 -1
  554. package/src/components/Recommendation/RecommendationContent.ts +4 -0
  555. package/src/components/StepsBlock/StepsBlock.fixture.tsx +59 -0
  556. package/src/components/StepsBlock/StepsBlock.tsx +34 -11
  557. package/src/components/StepsBlock/StepsBlockContent.ts +3 -0
  558. package/src/components/TariffsTable/TariffsTableCell.tsx +2 -0
  559. package/src/components/TariffsTable/TariffsTableTileCell.tsx +2 -0
  560. package/src/components/TariffsTable/utils/getButtonAriaLabel.ts +5 -0
  561. package/src/components/Tile/Tile.example.json +1 -1
  562. package/src/components/Tile/Tile.fixture.tsx +6 -6
  563. package/src/components/Tile/Tile.tsx +13 -3
  564. package/src/hooks/useLink.ts +1 -1
  565. package/src/icons/ArrowDownIcon.svg +1 -1
  566. package/src/icons/ArrowLeftIcon.svg +4 -0
  567. package/src/icons/BurgerIcon.svg +4 -4
  568. package/src/icons/Calendar2Icon.svg +1 -1
  569. package/src/icons/CalendarCircleIcon.svg +4 -1
  570. package/src/icons/CalendarIcon.svg +1 -1
  571. package/src/icons/CalendarTickIcon.svg +6 -1
  572. package/src/icons/CalendarWhiteIcon.svg +2 -2
  573. package/src/icons/CardIcon.svg +5 -1
  574. package/src/icons/CardPosIcon.svg +5 -1
  575. package/src/icons/CardTickIcon.svg +5 -1
  576. package/src/icons/ChartSquareIcon.svg +6 -1
  577. package/src/icons/CloseIcon.svg +4 -4
  578. package/src/icons/DiscountShapeIcon.svg +4 -1
  579. package/src/icons/DocIcon.svg +1 -1
  580. package/src/icons/DocumentTextIcon.svg +2 -2
  581. package/src/icons/EmptyWalletChangeIcon.svg +8 -1
  582. package/src/icons/EmptyWalletIcon.svg +2 -2
  583. package/src/icons/GlobalIcon.svg +5 -1
  584. package/src/icons/GpsIcon.svg +6 -6
  585. package/src/icons/IconName.ts +5 -2
  586. package/src/icons/InterestIcon.svg +6 -1
  587. package/src/icons/MasterCardIcon.svg +5 -1
  588. package/src/icons/MinusIcon.svg +3 -1
  589. package/src/icons/MoneyIcon.svg +5 -1
  590. package/src/icons/MonitorMobileIcon.svg +4 -1
  591. package/src/icons/PercentageRoundIcon.svg +4 -1
  592. package/src/icons/PercentageSquareIcon.svg +1 -1
  593. package/src/icons/PersonalCardIcon.svg +4 -1
  594. package/src/icons/PlayMarketIcon.svg +3 -1
  595. package/src/icons/PlusIcon.svg +3 -1
  596. package/src/icons/Profile2UserIcon.svg +6 -1
  597. package/src/icons/RoundRubleIcon.svg +5 -1
  598. package/src/icons/SafeIcon.svg +7 -1
  599. package/src/icons/ShieldTickIcon.svg +4 -1
  600. package/src/icons/SmallClockIcon.svg +4 -1
  601. package/src/icons/UserTickIcon.svg +5 -1
  602. package/src/icons/WalletAdd2Icon.svg +6 -1
  603. package/src/icons/WalletAddIcon.svg +7 -1
  604. package/src/icons/WalletIcon.svg +7 -1
  605. package/src/icons/WalletWithMoneyIcon.svg +5 -1
  606. package/src/ui-kit/Button/Button.tsx +20 -15
  607. package/src/ui-kit/Button/ButtonInner.tsx +2 -2
  608. package/src/ui-kit/HeaderItem/HeaderItem.tsx +14 -3
  609. package/src/ui-kit/Heading/Heading.mobile.tsx +5 -2
  610. package/src/ui-kit/Heading/Heading.tsx +6 -3
  611. package/src/ui-kit/Icon/Icon.tsx +2 -2
  612. package/src/ui-kit/List/List.tsx +2 -0
  613. package/src/ui-kit/List/ListItem.tsx +19 -5
  614. package/src/ui-kit/List/ListProps.ts +1 -1
  615. package/src/ui-kit/Logo/Logo.tsx +1 -1
  616. package/src/ui-kit/SearchBar/SearchBar.tsx +2 -2
  617. package/src/ui-kit/TopItem/TopItem.tsx +2 -1
  618. package/src/utils/changeHashOnScroll.ts +15 -0
  619. package/src/utils/isSSR.ts +2 -0
  620. package/src/utils/tableFunc.ts +8 -0
@@ -1,5 +1,7 @@
1
1
  import { JSX, PropsWithChildren } from '@redneckz/uni-jsx';
2
2
  import type { BlockDef, ContentPageDef, UniBlockProps } from '../../types';
3
+ import { changeHashOnScroll } from '../../utils/changeHashOnScroll';
4
+ import { isSSR } from '../../utils/isSSR';
3
5
  import type { BlockContent } from '../BlockContent';
4
6
  import { LikeControl } from '../LikeControl/LikeControl';
5
7
  import { Placeholder } from '../Placeholder/Placeholder';
@@ -36,22 +38,34 @@ export interface RenderBlockFunc {
36
38
  context: ContentPageContext;
37
39
  }
38
40
 
41
+ const isClient = !isSSR();
42
+
39
43
  const defaultBlockDecorator: BlockDecorator = ({ blockClassName, block, render }) =>
40
44
  render({ blockClassName, block });
41
45
 
42
46
  export const ContentPage = JSX<ContentPageProps>(
43
47
  ({
44
- className,
48
+ className = '',
45
49
  context,
46
50
  blocksRegistry,
47
51
  data: { style: pageStyle, blocks, slots = {}, likeControl, colorPalette = 'pc' },
48
52
  blockDecorator = defaultBlockDecorator,
49
53
  }) => {
50
54
  const { header } = slots;
55
+ const router = context.useRouter();
56
+
57
+ // listener is for NavigatorTabs
58
+ isClient &&
59
+ globalThis.addEventListener('load', () => {
60
+ const sectionsWithAnchors = globalThis.document.querySelectorAll('section[id]');
61
+ globalThis.document.addEventListener('scroll', () =>
62
+ changeHashOnScroll(router, sectionsWithAnchors),
63
+ );
64
+ });
51
65
 
52
66
  return (
53
67
  <section
54
- className={`relative ${style2className(pageStyle)} ${className || ''}`}
68
+ className={`relative ${style2className(pageStyle)} ${className}`}
55
69
  data-theme={colorPalette}
56
70
  >
57
71
  {header?.blocks?.length ? (
@@ -73,6 +87,7 @@ export const ContentPage = JSX<ContentPageProps>(
73
87
  {likeControl && (
74
88
  <div className="flex items-end absolute bottom-0 right-0 h-full pointer-events-none">
75
89
  <LikeControl
90
+ key="LikeControl"
76
91
  className="rounded-tl-lg sticky bottom-0 pointer-events-auto"
77
92
  context={context}
78
93
  />
@@ -100,6 +115,7 @@ function renderBlock(
100
115
  const { version, content, anchor } = props.block;
101
116
  return (
102
117
  <BlockComponent
118
+ key={`${type}-${i}`}
103
119
  className={props.blockClassName}
104
120
  version={version}
105
121
  context={context}
@@ -1,4 +1,14 @@
1
+ import { tableFunc } from '../../utils/tableFunc';
2
+
3
+ const func = tableFunc<number, string>([
4
+ [(_) => _ === 1, 'год'],
5
+ [(_) => _ <= 4, 'года'],
6
+ [() => true, 'лет'],
7
+ ]);
8
+
1
9
  export function renderButton(number: number, i: number, handleClick: (number: number) => void) {
10
+ const string = func(number);
11
+
2
12
  return (
3
13
  <button
4
14
  key={String(i)}
@@ -6,7 +16,7 @@ export function renderButton(number: number, i: number, handleClick: (number: nu
6
16
  onClick={() => handleClick(number)}
7
17
  >
8
18
  <span className="font-semibold text-sm">
9
- {number} {number === 1 ? 'год' : number > 4 ? 'лет' : 'года'}
19
+ {number} {string}
10
20
  </span>
11
21
  </button>
12
22
  );
@@ -9,17 +9,17 @@ export interface ContactsProps extends UniBlockProps {
9
9
  hasButton?: boolean;
10
10
  }
11
11
 
12
- export const Contacts = JSX<ContactsProps>(({ className, items, hasButton, context }) => {
12
+ export const Contacts = JSX<ContactsProps>(({ className = '', items, hasButton, context }) => {
13
13
  const router = context.useRouter();
14
14
  const { handlerDecorator } = context;
15
15
 
16
16
  return (
17
- <div className={`flex flex-col ${className || ''}`}>
17
+ <div className={className}>
18
18
  {items?.length ? items.map(renderContact) : null}
19
19
  {hasButton ? (
20
20
  <Button
21
21
  version="primary"
22
- className="mt-0.5 mb-5"
22
+ className="mb-6 w-full"
23
23
  {...useLink(
24
24
  { router, handlerDecorator },
25
25
  {
@@ -38,9 +38,9 @@ const renderContact = (item: ContactInfo, index: number) => {
38
38
  const { type, text, description } = item;
39
39
 
40
40
  return (
41
- <div className="mb-3.5" key={String(index)}>
41
+ <div className="mb-4" key={String(index)}>
42
42
  <div>{renderText(type, text)}</div>
43
- <div className="font-sans text-sm text-secondary-text">{description}</div>
43
+ <div className="mt-1 font-sans font-light text-sm text-secondary-text">{description}</div>
44
44
  </div>
45
45
  );
46
46
  };
@@ -50,7 +50,7 @@ const renderText = (type: ContactInfo['type'], text = '') => {
50
50
  case 'tel':
51
51
  return (
52
52
  <a
53
- className="font-sans font-medium text-xl text-primary-text no-underline"
53
+ className="font-sans text-xl text-primary-text no-underline"
54
54
  href={`tel:${formatTel(text)}`}
55
55
  >
56
56
  {text}
@@ -58,10 +58,7 @@ const renderText = (type: ContactInfo['type'], text = '') => {
58
58
  );
59
59
  case 'email':
60
60
  return (
61
- <a
62
- className="font-sans font-medium text-xl text-primary-text no-underline"
63
- href={`mailto:${text}`}
64
- >
61
+ <a className="font-sans text-xl text-primary-text no-underline" href={`mailto:${text}`}>
65
62
  {text}
66
63
  </a>
67
64
  );
@@ -48,6 +48,8 @@ export interface FooterContent extends SitemapProps {
48
48
  contacts?: ContactInfo[];
49
49
  /** @title Социальные сети */
50
50
  socialMedia?: SocialMedia[];
51
+ /** @title Мобильные приложения */
52
+ mobileApps?: SocialMedia[];
51
53
  /** @title Заголовок для меню */
52
54
  horizontalNavigationTitle?: string; // TODO: для мобильной версии
53
55
  /** @title Подменю */
@@ -30,6 +30,20 @@ const ICONS_MAP: Array<{
30
30
  width: '12px',
31
31
  height: '20px',
32
32
  },
33
+ {
34
+ origins: ['apps.apple.com'],
35
+ icon: { icon: 'AppleIcon' },
36
+ label: 'App Store',
37
+ width: '20px',
38
+ height: '22px',
39
+ },
40
+ {
41
+ origins: ['play.google.com'],
42
+ icon: { icon: 'PlayMarketIcon' },
43
+ label: 'Google Play',
44
+ width: '21px',
45
+ height: '21px',
46
+ },
33
47
  ];
34
48
 
35
49
  interface MediaButtonProps {
@@ -44,7 +58,7 @@ export const MediaButton = JSX<MediaButtonProps>(({ href }) => {
44
58
 
45
59
  return (
46
60
  <a
47
- 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"
61
+ 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"
48
62
  href={href}
49
63
  aria-label={label}
50
64
  target="_blank"
@@ -10,7 +10,7 @@ export interface SitemapProps extends UniBlockProps {
10
10
  items?: TopMenuItem[];
11
11
  }
12
12
 
13
- export const Sitemap = JSX<SitemapProps>(({ className, items, context }) => {
13
+ export const Sitemap = JSX<SitemapProps>(({ className = '', items, context }) => {
14
14
  const sitemap = useSitemap(context.useAsyncData);
15
15
  const mergedItems = mergeTopItems(sitemap.topItems, items);
16
16
  const linkParams = {
@@ -19,7 +19,7 @@ export const Sitemap = JSX<SitemapProps>(({ className, items, context }) => {
19
19
  };
20
20
 
21
21
  return (
22
- <div className={`flex items-start justify-start gap-11 xl:gap-5 ${className || ''}`}>
22
+ <div className={`flex items-start justify-between gap-11 xl:gap-5 ${className}`}>
23
23
  {mergedItems?.map((_, i) => renderColumn(_, i, linkParams))}
24
24
  </div>
25
25
  );
@@ -29,9 +29,9 @@ const renderColumn = (c: TopMenuItem, index: number, { router, handlerDecorator
29
29
  const { text, href, items, target } = c;
30
30
 
31
31
  return (
32
- <div key={String(index)} className="flex flex-col gap-[14px]">
32
+ <div key={String(index)} className="flex flex-col w-1/5 last:w-1/4 gap-[14px]">
33
33
  <a
34
- className="block font-sans font-medium text-base text-primary-text no-underline"
34
+ className="block font-sans leading-5 text-base text-primary-text no-underline"
35
35
  href={href}
36
36
  target={target || '_self'}
37
37
  >
@@ -50,7 +50,7 @@ interface ColumnItemProps extends LinkProps {
50
50
 
51
51
  const ColumnItem = JSX<ColumnItemProps>(({ text, href, target, index }) => (
52
52
  <a
53
- className="block font-sans font-normal text-base text-secondary-text hover:text-primary-main no-underline"
53
+ className="block font-sans font-light text-base text-secondary-text hover:text-primary-main no-underline"
54
54
  href={href}
55
55
  target={target || '_self'}
56
56
  >
@@ -7,9 +7,9 @@ import type { GalleryCard, GalleryItem } from './GalleryContent';
7
7
 
8
8
  export const GalleryCardInner = JSX<GalleryCard>(
9
9
  ({ title, description, image, items, button, version }) => {
10
- const titleStyleClasses = getTitleStyle(version, description, items);
10
+ const titleStyleClasses = getTitleStyle(version);
11
11
  return (
12
- <div className="h-full flex flex-col justify-between">
12
+ <div className="h-full flex flex-col justify-between text-center">
13
13
  <div>
14
14
  {image?.src ? (
15
15
  <div className="flex justify-center">
@@ -18,7 +18,7 @@ export const GalleryCardInner = JSX<GalleryCard>(
18
18
  ) : null}
19
19
  {title ? renderCardTitle(title, titleStyleClasses) : null}
20
20
  {description ? (
21
- <div className={`font-normal text-sm ${title ? 'mt-2' : ''}`}>{description}</div>
21
+ <div className={`font-light text-m-md-new ${title ? 'mt-2' : ''}`}>{description}</div>
22
22
  ) : null}
23
23
  {items?.length ? renderItems(items, version) : null}
24
24
  </div>
@@ -39,7 +39,7 @@ function renderButton(button) {
39
39
  }
40
40
 
41
41
  function renderCardTitle(title: string, className: string) {
42
- return <div className={`font-medium text-xl m-0 ${className}`}>{title}</div>;
42
+ return <div className={`text-xl m-0 ${className}`}>{title}</div>;
43
43
  }
44
44
 
45
45
  function renderItems(items: GalleryItem[], version: BlockVersion = 'primary') {
@@ -55,9 +55,8 @@ function renderItems(items: GalleryItem[], version: BlockVersion = 'primary') {
55
55
  );
56
56
  }
57
57
 
58
- function getTitleStyle(version, description, items) {
59
- return `font-medium text-xl m-0
58
+ function getTitleStyle(version) {
59
+ return `text-xl m-0
60
60
  ${version !== 'secondary' ? 'text-primary-text' : ''}
61
- ${!description && !items?.length ? 'text-center' : ''}
62
61
  `;
63
62
  }
@@ -25,7 +25,7 @@ export const GalleryContainer = JSX<GalleryContainerProps>(
25
25
  <div className="flex flex-col items-center mb-8">
26
26
  {title ? <Heading headingType="h2" className="text-center" title={title} /> : null}
27
27
  {description ? (
28
- <div className="font-normal text-base max-w-[600px] mt-2.5">{description}</div>
28
+ <div className="font-light text-md max-w-[600px] mt-2.5">{description}</div>
29
29
  ) : null}
30
30
  </div>
31
31
  <div
@@ -45,7 +45,7 @@ export const GalleryContainer = JSX<GalleryContainerProps>(
45
45
  function renderCard({ card, version }: GalleryCardData, i: number) {
46
46
  return (
47
47
  <section
48
- className={`box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between
48
+ className={`box-border border-solid border border-main-stroke p-6 mx-2 flex flex-col justify-between
49
49
  items-stretch ${cardStyleMap[version]} ${
50
50
  cardVersionMap[card.version ?? 'primary']
51
51
  } w-full col-span-4`}
@@ -27,7 +27,7 @@ export const GalleryInner = JSX<GalleryInnerProps>(
27
27
 
28
28
  return (
29
29
  <section
30
- className={`relative font-sans text-primary-text bg-white p-[50px] overflow-hidden ${className}`}
30
+ className={`relative font-sans text-primary-text bg-white p-[42px] overflow-hidden ${className}`}
31
31
  id={anchor}
32
32
  >
33
33
  <GalleryContainer
@@ -17,11 +17,11 @@ const COLORS_MAP: Record<BgColorVersion, string> = {
17
17
  'bg-white': 'text-primary-text hover:text-primary-main',
18
18
  transparent: 'text-white',
19
19
  };
20
- const DOP_LINKS_COLORS_MAP: Record<BgColorVersion, string> = {
20
+ const LINKS_COLORS_MAP: Record<BgColorVersion, string> = {
21
21
  'bg-white': 'text-secondary-light hover:text-secondary-hover',
22
22
  transparent: 'text-white',
23
23
  };
24
- const DOP_LINKS_ICON_NAME_MAP: Record<BgColorVersion, IconName> = {
24
+ const LINKS_ICON_NAME_MAP: Record<BgColorVersion, IconName> = {
25
25
  'bg-white': 'GridIcon',
26
26
  transparent: 'GridIconWhite',
27
27
  };
@@ -54,14 +54,11 @@ export const HeaderSecondaryMenu = JSX<HeaderSecondaryMenuProps>(
54
54
  >
55
55
  <Img image="LoupeIcon" className="h-full" asSVG color="none" />
56
56
  </HeaderSecondaryMenuButton>
57
- <HeaderSecondaryMenuButton className={`mr-5 ${COLORS_MAP[bgColor]}`} ariaLabel="Профиль">
58
- <Img image="ProfileIcon" className="h-full" asSVG color="none" />
59
- </HeaderSecondaryMenuButton>
60
57
  <HeaderSecondaryMenuButton
61
- className={`${DOP_LINKS_COLORS_MAP[bgColor]} min-w-[32px] min-h-[32px]`}
58
+ className={`${LINKS_COLORS_MAP[bgColor]} min-w-[32px] min-h-[32px]`}
62
59
  ariaLabel="Дополнительные ссылки"
63
60
  >
64
- <Img image={DOP_LINKS_ICON_NAME_MAP[bgColor]} className="h-full" asSVG color="none" />
61
+ <Img image={LINKS_ICON_NAME_MAP[bgColor]} className="h-full" asSVG color="none" />
65
62
  </HeaderSecondaryMenuButton>
66
63
  </div>
67
64
  );
@@ -0,0 +1,103 @@
1
+ import { JSX } from '@redneckz/uni-jsx';
2
+ import { useLink } from '../../hooks/useLink';
3
+ import type { BgColorVersion } from '../../model/BgColorVersion';
4
+ import type { LinkProps } from '../../model/LinkProps';
5
+ import { findActiveSubItem } from '../../services/sitemap/findActiveSubItem';
6
+ import { HeaderItem } from '../../ui-kit/HeaderItem/HeaderItem';
7
+ import type { ContentPageContext } from '../ContentPage/ContentPageContext';
8
+ import { headerSubMenuObserver } from './HeaderSubMenuObserver';
9
+
10
+ export interface HeaderSubMenuProps {
11
+ context: ContentPageContext;
12
+ subItems?: LinkProps[];
13
+ bgColor?: BgColorVersion;
14
+ }
15
+
16
+ export const HeaderSubMenu = JSX<HeaderSubMenuProps>(({ context, subItems, bgColor }) => {
17
+ const [subMenuIsShow, setHiddenMenuIsShow] = context.useState(false);
18
+ const router = context.useRouter();
19
+ const { handlerDecorator } = context;
20
+
21
+ setTimeout(() => {
22
+ const headerSubMenu = globalThis.document.querySelectorAll('[data-item-name=header-submenu]');
23
+ headerSubMenu.forEach((_) => {
24
+ headerSubMenuObserver?.observe(_);
25
+ });
26
+ }, 200);
27
+
28
+ const activeSubItem = findActiveSubItem(router)(subItems);
29
+ const toggleSubMenu = () => setHiddenMenuIsShow(!subMenuIsShow);
30
+
31
+ const subMenu = subItems?.map((_) => (
32
+ <HeaderItem
33
+ key={_.href}
34
+ className="mr-8"
35
+ active={_ === activeSubItem}
36
+ {...useLink({ router, handlerDecorator }, _)}
37
+ dataItemName="header-submenu"
38
+ bgColor={bgColor}
39
+ />
40
+ ));
41
+
42
+ return (
43
+ <nav className="relative mt-5">
44
+ <div className="overflow-hidden whitespace-nowrap mr-52">{subMenu}</div>
45
+ {renderDotsSubMenu({
46
+ subMenuIsShow,
47
+ toggleSubMenu,
48
+ subItems,
49
+ router,
50
+ handlerDecorator,
51
+ })}
52
+ </nav>
53
+ );
54
+ });
55
+
56
+ // TODO: add types
57
+ const renderDotsSubMenu = ({
58
+ subMenuIsShow,
59
+ toggleSubMenu,
60
+ subItems,
61
+ router,
62
+ handlerDecorator,
63
+ }) => (
64
+ <div
65
+ className={`absolute w-52 -top-4 right-0 pt-4 z-40 ${
66
+ subMenuIsShow ? 'bg-white rounded-md shadow-blue-gray/24' : ''
67
+ }`}
68
+ data-header-submenu-visible="toggled"
69
+ >
70
+ <button
71
+ className="flex justify-between items-center cursor-pointer h-6 ml-6"
72
+ onClick={toggleSubMenu}
73
+ aria-label={`${subMenuIsShow ? 'Скрыть другие разделы' : 'Показать другие разделы'}`}
74
+ >
75
+ {Array(3)
76
+ .fill(0)
77
+ .map((_, i) => renderDot(i))}
78
+ </button>
79
+ <div
80
+ className={`flex flex-col rounded-md bg-white p-6 pb-2 ${subMenuIsShow ? '' : 'hidden'}`}
81
+ aria-hidden={!subMenuIsShow}
82
+ >
83
+ {renderDotsSubMenuItems(subItems, router, handlerDecorator)}
84
+ </div>
85
+ </div>
86
+ );
87
+
88
+ // TODO: add types
89
+ const renderDotsSubMenuItems = (subItems, router, handlerDecorator) =>
90
+ subItems?.map((_) => (
91
+ <a
92
+ key={_.href}
93
+ {...useLink({ router, handlerDecorator }, _)}
94
+ data-item-name="dots-header-submenu"
95
+ className="text-base font-light pb-4 hover:text-primary-main"
96
+ >
97
+ {_.text}
98
+ </a>
99
+ ));
100
+
101
+ const renderDot = (i: number) => (
102
+ <div key={String(i)} className="w-[3px] h-[3px] rounded bg-black mr-1" />
103
+ );
@@ -0,0 +1,46 @@
1
+ import { isSSR } from '../../utils/isSSR';
2
+
3
+ const isClient = !isSSR();
4
+
5
+ export const headerSubMenuObserver = isClient
6
+ ? new IntersectionObserver(
7
+ (entries) => {
8
+ const headerSubMenuButtonElement = window.document.querySelector(
9
+ '[data-header-submenu-visible=toggled]',
10
+ );
11
+ const headerSubMenuItems = Array.from(
12
+ window.document.querySelectorAll('[data-item-name=header-submenu]'),
13
+ );
14
+ const dotsHeaderSubMenuItems = Array.from(
15
+ window.document.querySelectorAll('[data-item-name=dots-header-submenu]'),
16
+ );
17
+ const visibilityList = {};
18
+ entries.forEach((j) => {
19
+ visibilityList[String(j.target.toString())] = j.isIntersecting;
20
+ });
21
+ const isHeaderSubMenuButtonShow = toggleVisibilityInItems(
22
+ visibilityList,
23
+ dotsHeaderSubMenuItems,
24
+ 'hidden',
25
+ );
26
+ toggleVisibilityInItems(visibilityList, headerSubMenuItems, 'invisible');
27
+ if (headerSubMenuButtonElement) {
28
+ isHeaderSubMenuButtonShow
29
+ ? headerSubMenuButtonElement.classList.remove('hidden')
30
+ : headerSubMenuButtonElement.classList.add('hidden');
31
+ }
32
+ },
33
+ { root: window.document, threshold: 1.0 },
34
+ )
35
+ : undefined;
36
+
37
+ // TODO: add types
38
+ const toggleVisibilityInItems = (visibilityList, items, className) => {
39
+ const isReversed = className !== 'hidden';
40
+ return items.some((item) => {
41
+ const key = item.toString();
42
+ const option = isReversed ? !visibilityList[key] : visibilityList[key];
43
+ key in visibilityList ? item.classList.toggle(className, option) : null;
44
+ return isReversed ? item.classList.contains('hidden') : !item.classList.contains('hidden');
45
+ });
46
+ };
@@ -1,7 +1,7 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
- import { LinkDocsListItem } from './LinkDocsListItem';
3
- import type { LinkColumnsMode, LinkDocsItem } from './LinkDocsContent';
4
2
  import type { Picture } from '../../model/Picture';
3
+ import type { LinkColumnsMode, LinkDocsItem } from './LinkDocsContent';
4
+ import { LinkDocsListItem } from './LinkDocsListItem';
5
5
 
6
6
  export interface LinkDocsListProps {
7
7
  className?: string;
@@ -21,7 +21,7 @@ export const LinkDocsList = JSX<LinkDocsListProps>(
21
21
  role="listitem"
22
22
  >
23
23
  <LinkDocsListItem
24
- className="group flex text-sm align-middle h-fit w-fit text-primary-text no-underline hover:text-primary-main"
24
+ className="group flex align-middle h-fit w-fit text-primary-text no-underline hover:text-primary-main"
25
25
  doc={doc}
26
26
  icon={icon}
27
27
  />
@@ -8,22 +8,24 @@ export interface NavigatorTabItemProps extends NavigatorTab {
8
8
  }
9
9
 
10
10
  const TEXT_CLASSES = 'font-sans font-normal text-sm';
11
- const LINK_CLASSES = 'flex-1 flex items-center justify-center';
11
+ const LINK_CLASSES = 'flex-1 flex items-center justify-center cursor-pointer';
12
12
 
13
13
  export const NavigatorTabItem = JSX<NavigatorTabItemProps>(
14
- ({ className = '', label, active, children, onClick, anchor }) => (
15
- <a className={getLinkClasses(className, active)} href={`#${anchor}`} onClick={onClick}>
14
+ ({ className = '', label, active, children, onClick, href, target = '_self' }) => (
15
+ <a className={getLinkClasses(className, active)} target={target} href={href} onClick={onClick}>
16
16
  <span className={getTextClasses(active)}>{label || children}</span>
17
17
  </a>
18
18
  ),
19
19
  );
20
20
 
21
21
  const getLinkClasses = (className: string, active?: boolean) => {
22
- const classes = active ? 'bg-primary-main' : 'bg-white';
22
+ const classes = active ? 'bg-primary-main' : 'group bg-white';
23
+
23
24
  return `${classes} ${LINK_CLASSES} ${className}`;
24
25
  };
25
26
 
26
27
  const getTextClasses = (active?: boolean) => {
27
- const classes = active ? 'text-white' : 'text-secondary-text hover:text-primary-main';
28
+ const classes = active ? 'text-white' : 'text-secondary-text group-hover:text-primary-main ';
29
+
28
30
  return `${classes} ${TEXT_CLASSES}`;
29
31
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "navigatorTabs": [
3
- { "label": "Tab1", "anchor": "tab1" },
4
- { "label": "Tab2", "anchor": "tab2" },
5
- { "label": "Tab3", "anchor": "tab3" }
3
+ { "label": "Tab1", "href": "#tab1" },
4
+ { "label": "Tab2", "href": "#tab2" },
5
+ { "label": "Link", "href": "https://rshb.ru", "target": "_blank" }
6
6
  ]
7
7
  }
@@ -1,36 +1,44 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import type { UniBlockProps } from '../../types';
3
- import { getHash } from '../../utils/url';
3
+ import { getHash, isURL } from '../../utils/url';
4
4
  import type { Router } from '../ContentPage/ContentPageContext';
5
5
  import { NavigatorTabItem } from './NavigatorTabItem';
6
6
  import type { NavigatorTab, NavigatorTabsContent } from './NavigatorTabsContent';
7
7
 
8
- export interface TabsBlockProps extends NavigatorTabsContent, UniBlockProps {}
8
+ export interface TabsBlockProps extends UniBlockProps, NavigatorTabsContent {}
9
9
 
10
10
  export const NavigatorTabs = JSX<TabsBlockProps>(
11
11
  ({ className = '', navigatorTabs, context, anchor = null }) => {
12
12
  const router = context.useRouter();
13
- const hash = getHash(router.href);
13
+ const href = globalThis.location.href;
14
+
14
15
  return (
15
16
  <section
16
17
  className={`sticky top-0 z-20 box-border flex gap-x-1 h-12 ${className}`}
17
18
  id={anchor}
18
19
  >
19
- {navigatorTabs ? navigatorTabs.map(renderTab(hash, router)) : null}
20
+ {navigatorTabs ? navigatorTabs.map(renderTab(href, router)) : null}
20
21
  </section>
21
22
  );
22
23
  },
23
24
  );
24
25
 
25
- const renderTab = (hash?: string, router?: Router) => (tab: NavigatorTab, i: number) => {
26
- const anchorHash = `#${tab.anchor}`;
27
- const active = hash ? anchorHash === hash : i === 0;
26
+ const renderTab = (href?: string, router?: Router) => (tab: NavigatorTab, i: number) => {
27
+ const hash = getHash(href);
28
+ const active = hash ? tab.href === hash : i === 0;
29
+
28
30
  return (
29
31
  <NavigatorTabItem
30
- key={tab.anchor}
32
+ key={tab.href}
31
33
  active={active}
32
- onClick={() => router?.replace(anchorHash)}
34
+ onClick={() => handleRoute(router, tab.href)}
33
35
  {...tab}
34
36
  />
35
37
  );
36
38
  };
39
+
40
+ const handleRoute = (router?: Router, href?: string) => {
41
+ if (isURL(href)) return; // if href if full URL - move to HTML href action, do not touch router
42
+
43
+ router?.replace(href || '');
44
+ };
@@ -5,7 +5,9 @@ export interface NavigatorTab {
5
5
  /** @title Название */
6
6
  label?: string;
7
7
  /** @title Якорь */
8
- anchor?: string;
8
+ href?: string;
9
+ /** @title Таргет (target) */
10
+ target?: string;
9
11
  }
10
12
 
11
13
  /**
@@ -1,6 +1,6 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
2
  import type { LinkProps } from '../../model/LinkProps';
3
- import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
3
+ import type { ButtonContent, ButtonProps } from '../../ui-kit/Button/ButtonProps';
4
4
  import type { DescriptionContent } from '../../ui-kit/Description/DescriptionContent';
5
5
  import type { HeadingContent, HeadingTypeContent } from '../../ui-kit/Heading/HeadingContent';
6
6
  import type { ImageContent } from '../../ui-kit/Img/ImgProps';
@@ -32,6 +32,8 @@ export type ProductBlockInnerContent = HeadingContent &
32
32
  * @hidden
33
33
  */
34
34
  textBlockClassName?: string;
35
+ /** @title Текст кнопки возврата */
36
+ backwardButton?: ButtonProps;
35
37
  };
36
38
 
37
39
  /**
@@ -0,0 +1,35 @@
1
+ import { Img } from '../../ui-kit/Img/Img';
2
+ import { Button } from '../../ui-kit/Button/Button';
3
+ import type { BlockVersion } from '../../model/BlockVersion';
4
+
5
+ const backwardBgStyleMap: Record<BlockVersion, string> = {
6
+ primary: 'bg-primary-main',
7
+ secondary: 'bg-white',
8
+ };
9
+
10
+ const backwardIconStyleMap: Record<BlockVersion, string> = {
11
+ primary: 'text-white',
12
+ secondary: 'text-primary-text',
13
+ };
14
+
15
+ export function renderBackwardButton(text: string, version: BlockVersion, className: string) {
16
+ return (
17
+ <div className={`flex items-center ${className}`}>
18
+ <Button
19
+ rounded
20
+ className={`w-12 h-12 min-h-12 max-h-12 flex items-center justify-center mr-3 ${backwardBgStyleMap[version]}`}
21
+ ariaLabel={text}
22
+ >
23
+ <Img
24
+ className={`w-4 h-4 min-w-4 min-h-4 rounded-full box-border ${backwardIconStyleMap[version]}`}
25
+ image={{ icon: 'ArrowLeftIcon' }}
26
+ color="none"
27
+ width="24"
28
+ height="24"
29
+ asSVG
30
+ />
31
+ </Button>
32
+ {text ? <span className="text-m-md">{text}</span> : null}
33
+ </div>
34
+ );
35
+ }