@redneckz/wildless-cms-uni-blocks 0.2.101 → 0.2.103

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 (229) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +121 -58
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/dist/components/BlockContent.d.ts +3 -2
  5. package/dist/components/Blocks.d.ts +1 -0
  6. package/dist/components/Blocks.js +2 -0
  7. package/dist/components/Blocks.js.map +1 -1
  8. package/dist/components/Footer/FooterContent.d.ts +1 -1
  9. package/dist/components/Footer/Sitemap.d.ts +1 -1
  10. package/dist/components/Footer/Sitemap.js +2 -2
  11. package/dist/components/Footer/Sitemap.js.map +1 -1
  12. package/dist/components/Header/Header.js +13 -9
  13. package/dist/components/Header/Header.js.map +1 -1
  14. package/dist/components/Header/HeaderContent.d.ts +8 -1
  15. package/dist/components/Header/HeaderSecondaryMenu.d.ts +2 -1
  16. package/dist/components/Header/HeaderSecondaryMenu.js +14 -2
  17. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  18. package/dist/components/Header/HeaderSecondaryMenuButton.js +1 -1
  19. package/dist/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  20. package/dist/components/Headline/HeadlineContent.d.ts +2 -9
  21. package/dist/components/MobileBlocks.d.ts +1 -0
  22. package/dist/components/MobileBlocks.js +2 -0
  23. package/dist/components/MobileBlocks.js.map +1 -1
  24. package/dist/components/Navigation/Navigation.d.ts +5 -0
  25. package/dist/components/Navigation/Navigation.js +16 -0
  26. package/dist/components/Navigation/Navigation.js.map +1 -0
  27. package/dist/components/Navigation/NavigationContent.d.ts +10 -0
  28. package/dist/components/Navigation/NavigationContent.js +2 -0
  29. package/dist/components/Navigation/NavigationContent.js.map +1 -0
  30. package/dist/components/Navigation/NavigationItem.d.ts +4 -0
  31. package/dist/components/Navigation/NavigationItem.js +6 -0
  32. package/dist/components/Navigation/NavigationItem.js.map +1 -0
  33. package/dist/hooks/useLink.js +2 -1
  34. package/dist/hooks/useLink.js.map +1 -1
  35. package/dist/index.d.ts +1 -1
  36. package/dist/index.js.map +1 -1
  37. package/dist/model/BgColorVersion.d.ts +8 -0
  38. package/dist/model/BgColorVersion.js +2 -0
  39. package/dist/model/BgColorVersion.js.map +1 -0
  40. package/dist/services/sitemap/SitemapProps.d.ts +13 -0
  41. package/dist/services/sitemap/SitemapProps.js +2 -0
  42. package/dist/services/sitemap/SitemapProps.js.map +1 -0
  43. package/dist/services/sitemap/findActiveSubItem.d.ts +3 -0
  44. package/dist/services/sitemap/findActiveSubItem.js +13 -0
  45. package/dist/services/sitemap/findActiveSubItem.js.map +1 -0
  46. package/dist/services/sitemap/isHrefActive.d.ts +4 -0
  47. package/dist/services/sitemap/isHrefActive.js +9 -0
  48. package/dist/services/sitemap/isHrefActive.js.map +1 -0
  49. package/dist/services/sitemap/isSubItemActive.d.ts +3 -0
  50. package/dist/services/sitemap/isSubItemActive.js +6 -0
  51. package/dist/services/sitemap/isSubItemActive.js.map +1 -0
  52. package/dist/services/sitemap/isTopItemActive.d.ts +3 -0
  53. package/dist/services/sitemap/isTopItemActive.js +7 -0
  54. package/dist/services/sitemap/isTopItemActive.js.map +1 -0
  55. package/dist/services/sitemap/mergeTopItems.d.ts +2 -0
  56. package/dist/{mergeTopItems.js → services/sitemap/mergeTopItems.js} +1 -3
  57. package/dist/services/sitemap/mergeTopItems.js.map +1 -0
  58. package/dist/services/sitemap/useSitemap.d.ts +3 -0
  59. package/dist/{hooks → services/sitemap}/useSitemap.js +1 -1
  60. package/dist/services/sitemap/useSitemap.js.map +1 -0
  61. package/dist/ui-kit/HeaderItem/HeaderItem.js +16 -4
  62. package/dist/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  63. package/dist/ui-kit/Icon/IconProps.d.ts +39 -37
  64. package/dist/ui-kit/Icon/IconProps.js +37 -36
  65. package/dist/ui-kit/Icon/IconProps.js.map +1 -1
  66. package/dist/ui-kit/Logo/Logo.d.ts +1 -0
  67. package/dist/ui-kit/Logo/Logo.js +10 -2
  68. package/dist/ui-kit/Logo/Logo.js.map +1 -1
  69. package/dist/ui-kit/TopItem/TopItem.d.ts +2 -0
  70. package/dist/ui-kit/TopItem/TopItem.js +19 -7
  71. package/dist/ui-kit/TopItem/TopItem.js.map +1 -1
  72. package/dist/utils/adjustHref.d.ts +4 -0
  73. package/dist/utils/adjustHref.js +21 -0
  74. package/dist/utils/adjustHref.js.map +1 -0
  75. package/dist/utils/maxBy.d.ts +2 -0
  76. package/dist/utils/maxBy.js +7 -0
  77. package/dist/utils/maxBy.js.map +1 -0
  78. package/dist/utils/url.d.ts +0 -13
  79. package/dist/utils/url.js +2 -26
  80. package/dist/utils/url.js.map +1 -1
  81. package/dist/utils/withoutMobilePath.d.ts +2 -0
  82. package/dist/utils/withoutMobilePath.js +6 -0
  83. package/dist/utils/withoutMobilePath.js.map +1 -0
  84. package/lib/common.css +1 -1
  85. package/lib/components/BlockContent.d.ts +3 -2
  86. package/lib/components/Blocks.d.ts +1 -0
  87. package/lib/components/Blocks.js +2 -0
  88. package/lib/components/Blocks.js.map +1 -1
  89. package/lib/components/Footer/FooterContent.d.ts +1 -1
  90. package/lib/components/Footer/Sitemap.d.ts +1 -1
  91. package/lib/components/Footer/Sitemap.js +2 -2
  92. package/lib/components/Footer/Sitemap.js.map +1 -1
  93. package/lib/components/Header/Header.fixture.d.ts +4 -1
  94. package/lib/components/Header/Header.js +13 -9
  95. package/lib/components/Header/Header.js.map +1 -1
  96. package/lib/components/Header/HeaderContent.d.ts +8 -1
  97. package/lib/components/Header/HeaderSecondaryMenu.d.ts +2 -1
  98. package/lib/components/Header/HeaderSecondaryMenu.js +14 -2
  99. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  100. package/lib/components/Header/HeaderSecondaryMenuButton.js +1 -1
  101. package/lib/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  102. package/lib/components/Headline/HeadlineContent.d.ts +2 -9
  103. package/lib/components/MobileBlocks.d.ts +1 -0
  104. package/lib/components/MobileBlocks.js +2 -0
  105. package/lib/components/MobileBlocks.js.map +1 -1
  106. package/lib/components/Navigation/Navigation.d.ts +5 -0
  107. package/lib/components/Navigation/Navigation.fixture.d.ts +2 -0
  108. package/lib/components/Navigation/Navigation.js +14 -0
  109. package/lib/components/Navigation/Navigation.js.map +1 -0
  110. package/lib/components/Navigation/NavigationContent.d.ts +10 -0
  111. package/lib/components/Navigation/NavigationContent.js +2 -0
  112. package/lib/components/Navigation/NavigationContent.js.map +1 -0
  113. package/lib/components/Navigation/NavigationItem.d.ts +4 -0
  114. package/lib/components/Navigation/NavigationItem.js +4 -0
  115. package/lib/components/Navigation/NavigationItem.js.map +1 -0
  116. package/lib/hooks/useLink.js +2 -1
  117. package/lib/hooks/useLink.js.map +1 -1
  118. package/lib/index.d.ts +1 -1
  119. package/lib/index.js.map +1 -1
  120. package/lib/model/BgColorVersion.d.ts +8 -0
  121. package/lib/model/BgColorVersion.js +2 -0
  122. package/lib/model/BgColorVersion.js.map +1 -0
  123. package/lib/services/sitemap/SitemapProps.d.ts +13 -0
  124. package/lib/services/sitemap/SitemapProps.js +2 -0
  125. package/lib/services/sitemap/SitemapProps.js.map +1 -0
  126. package/lib/services/sitemap/findActiveSubItem.d.ts +3 -0
  127. package/lib/services/sitemap/findActiveSubItem.js +10 -0
  128. package/lib/services/sitemap/findActiveSubItem.js.map +1 -0
  129. package/lib/services/sitemap/isHrefActive.d.ts +4 -0
  130. package/lib/services/sitemap/isHrefActive.js +6 -0
  131. package/lib/services/sitemap/isHrefActive.js.map +1 -0
  132. package/lib/services/sitemap/isSubItemActive.d.ts +3 -0
  133. package/lib/services/sitemap/isSubItemActive.js +3 -0
  134. package/lib/services/sitemap/isSubItemActive.js.map +1 -0
  135. package/lib/services/sitemap/isTopItemActive.d.ts +3 -0
  136. package/lib/services/sitemap/isTopItemActive.js +4 -0
  137. package/lib/services/sitemap/isTopItemActive.js.map +1 -0
  138. package/lib/services/sitemap/mergeTopItems.d.ts +2 -0
  139. package/lib/{mergeTopItems.js → services/sitemap/mergeTopItems.js} +1 -3
  140. package/lib/services/sitemap/mergeTopItems.js.map +1 -0
  141. package/lib/services/sitemap/useSitemap.d.ts +3 -0
  142. package/lib/{hooks → services/sitemap}/useSitemap.js +1 -1
  143. package/lib/services/sitemap/useSitemap.js.map +1 -0
  144. package/lib/ui-kit/HeaderItem/HeaderItem.js +16 -4
  145. package/lib/ui-kit/HeaderItem/HeaderItem.js.map +1 -1
  146. package/lib/ui-kit/Icon/IconProps.d.ts +39 -37
  147. package/lib/ui-kit/Icon/IconProps.js +37 -36
  148. package/lib/ui-kit/Icon/IconProps.js.map +1 -1
  149. package/lib/ui-kit/Logo/Logo.d.ts +1 -0
  150. package/lib/ui-kit/Logo/Logo.js +10 -2
  151. package/lib/ui-kit/Logo/Logo.js.map +1 -1
  152. package/lib/ui-kit/TopItem/TopItem.d.ts +2 -0
  153. package/lib/ui-kit/TopItem/TopItem.js +19 -7
  154. package/lib/ui-kit/TopItem/TopItem.js.map +1 -1
  155. package/lib/utils/adjustHref.d.ts +4 -0
  156. package/lib/utils/adjustHref.js +18 -0
  157. package/lib/utils/adjustHref.js.map +1 -0
  158. package/lib/utils/maxBy.d.ts +2 -0
  159. package/lib/utils/maxBy.js +3 -0
  160. package/lib/utils/maxBy.js.map +1 -0
  161. package/lib/utils/url.d.ts +0 -13
  162. package/lib/utils/url.js +1 -21
  163. package/lib/utils/url.js.map +1 -1
  164. package/lib/utils/withoutMobilePath.d.ts +2 -0
  165. package/lib/utils/withoutMobilePath.js +3 -0
  166. package/lib/utils/withoutMobilePath.js.map +1 -0
  167. package/package.json +4 -2
  168. package/src/components/BlockContent.ts +4 -2
  169. package/src/components/Blocks.ts +2 -0
  170. package/src/components/ContentPage/ContentPage.page.json +26 -13
  171. package/src/components/Footer/FooterContent.ts +1 -1
  172. package/src/components/Footer/Sitemap.tsx +4 -3
  173. package/src/components/Header/Header.fixture.tsx +4 -18
  174. package/src/components/Header/Header.tsx +56 -45
  175. package/src/components/Header/HeaderContent.ts +8 -1
  176. package/src/components/Header/HeaderSecondaryMenu.tsx +25 -12
  177. package/src/components/Header/HeaderSecondaryMenuButton.tsx +2 -4
  178. package/src/components/Headline/HeadlineContent.ts +2 -10
  179. package/src/components/MobileBlocks.ts +2 -0
  180. package/src/components/Navigation/Navigation.fixture.tsx +28 -0
  181. package/src/components/Navigation/Navigation.tsx +39 -0
  182. package/src/components/Navigation/NavigationContent.ts +11 -0
  183. package/src/components/Navigation/NavigationItem.tsx +17 -0
  184. package/src/hooks/useLink.ts +2 -1
  185. package/src/icons/GridIcon.svg +1 -1
  186. package/src/icons/GridIconWhite.svg +4 -0
  187. package/src/index.ts +1 -1
  188. package/src/model/BgColorVersion.ts +8 -0
  189. package/src/services/sitemap/SitemapProps.ts +15 -0
  190. package/src/services/sitemap/findActiveSubItem.ts +14 -0
  191. package/src/services/sitemap/isHrefActive.ts +13 -0
  192. package/src/services/sitemap/isSubItemActive.ts +8 -0
  193. package/src/services/sitemap/isTopItemActive.ts +9 -0
  194. package/src/{mergeTopItems.spec.ts → services/sitemap/mergeTopItems.spec.ts} +0 -0
  195. package/src/{mergeTopItems.ts → services/sitemap/mergeTopItems.ts} +3 -4
  196. package/src/{hooks → services/sitemap}/useSitemap.ts +3 -3
  197. package/src/ui-kit/HeaderItem/HeaderItem.tsx +32 -18
  198. package/src/ui-kit/Icon/IconProps.ts +3 -1
  199. package/src/ui-kit/Logo/Logo.tsx +30 -18
  200. package/src/ui-kit/TopItem/TopItem.tsx +46 -19
  201. package/src/utils/adjustHref.spec.ts +25 -0
  202. package/src/utils/adjustHref.ts +24 -0
  203. package/src/utils/maxBy.spec.ts +11 -0
  204. package/src/utils/maxBy.ts +7 -0
  205. package/src/utils/url.spec.ts +1 -37
  206. package/src/utils/url.ts +2 -39
  207. package/src/utils/withoutMobilePath.ts +3 -0
  208. package/dist/components/Header/isSubItemActive.d.ts +0 -3
  209. package/dist/components/Header/isSubItemActive.js +0 -8
  210. package/dist/components/Header/isSubItemActive.js.map +0 -1
  211. package/dist/components/Header/isTopItemActive.d.ts +0 -3
  212. package/dist/components/Header/isTopItemActive.js +0 -8
  213. package/dist/components/Header/isTopItemActive.js.map +0 -1
  214. package/dist/hooks/useSitemap.d.ts +0 -3
  215. package/dist/hooks/useSitemap.js.map +0 -1
  216. package/dist/mergeTopItems.d.ts +0 -2
  217. package/dist/mergeTopItems.js.map +0 -1
  218. package/lib/components/Header/isSubItemActive.d.ts +0 -3
  219. package/lib/components/Header/isSubItemActive.js +0 -5
  220. package/lib/components/Header/isSubItemActive.js.map +0 -1
  221. package/lib/components/Header/isTopItemActive.d.ts +0 -3
  222. package/lib/components/Header/isTopItemActive.js +0 -5
  223. package/lib/components/Header/isTopItemActive.js.map +0 -1
  224. package/lib/hooks/useSitemap.d.ts +0 -3
  225. package/lib/hooks/useSitemap.js.map +0 -1
  226. package/lib/mergeTopItems.d.ts +0 -2
  227. package/lib/mergeTopItems.js.map +0 -1
  228. package/src/components/Header/isSubItemActive.ts +0 -7
  229. package/src/components/Header/isTopItemActive.ts +0 -8
@@ -1 +1 @@
1
- {"$schema":"http://json-schema.org/draft-07/schema#","definitions":{"HeadlineBgColor":{"type":"string","enum":["transparent","bg-white"],"title":"Цвет фона","enumNames":["Прозрачный","Белый"]},"HeadlineContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"bgColor":{"$ref":"#/definitions/HeadlineBgColor"}},"title":"Заголовок"},"TitleSize":{"type":"string","enum":["XL","L","M","S"]},"AlignType":{"type":"string","enum":["left","center","right"],"title":"Выравнивание","enumNames":["По левому краю","По центру","По правому краю"]},"LinkColumnsMode":{"type":"string","enum":["single","double"],"title":"Режим отображения списка"},"LinkDocsItem":{"type":"object","properties":{"text":{"type":"string","title":"Текст"},"fileSize":{"type":"string","title":"размер файла"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"title":"Элемент списка"},"LinkProps":{"type":"object","properties":{"text":{"type":"string","title":"Текст"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"title":"Ссылка","required":["text","href"]},"Target":{"type":"string","enum":["","_self","_blank","_parent","_top"],"title":"Таргет (target)","enumNames":["","self (текущее окно или фрейм)","blank (новое окно)","parent (фрейм-родитель)","top (текущее окно)"]},"LinkDocsContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"align":{"$ref":"#/definitions/AlignType"},"columnsMode":{"$ref":"#/definitions/LinkColumnsMode","title":"Отображение списка"},"icon":{"$ref":"#/definitions/IconName","title":"Название иконки"},"documents":{"type":"array","items":{"$ref":"#/definitions/LinkDocsItem"},"title":"Список"}},"title":"Список документов"},"IconName":{"type":"string","enum":["ActualBalanceIcon","AppleIcon","Calendar2Icon","CalendarCircleIcon","CalendarIcon","CalendarTickIcon","CalendarWhiteIcon","CardWithGemIcon","ChartSquareIcon","CardIcon","CardPosIcon","CardTickIcon","ClockIcon","ComfortableCompIcon","CreditCardsIcon","DiscountShapeIcon","DocIcon","DocumentTextIcon","DollarIcon","EarthIcon","EmptyWalletChangeIcon","EmptyWalletIcon","EmptyWalletWhiteIcon","EuroIcon","GlassIcon","GlobalIcon","GridIcon","InterestGrowthIcon","InterestIcon","JCBIcon","LoupeIcon","MasterCardIcon","MinusIcon","MirIcon","MoneyIcon","MoneyInsuranceIcon","MonitorMobileIcon","NewDocIcon","OfficeIcon","OkIcon","PassSendIcon","PercentageRoundIcon","PercentageSquareIcon","PercentageSquareWhiteIcon","PersonalCardIcon","PlayMarketIcon","PlusIcon","Profile2UserIcon","ProfileIcon","RoundRubleIcon","SafeIcon","ShieldTickIcon","SignDocsIcon","SmallClockIcon","TelegramIcon","UnionPayIcon","UserTickIcon","VisaIcon","VKIcon","WalletAdd","WalletAdd2","WalletIcon","WalletWithMoneyIcon"],"title":"Иконка","enumNames":["Деньги","Лого «Apple»","Календарь 2","Скруглённый календарь","Календарь","Календарь с галочкой","Календарь белый","Карта с драгоценностями","Деньги внутри кошелька","Кред. карта","Кред. карта под наклоном","Кред. карта с галочкой","Часы","Кресло","Скидка","Кредитные карты","Огромная скидка","Документ","Документ с текстом","Доллар","Пустой кошелёк с возвратом","Пустой кошелёк","Пустой кошелёк белый","Евро","Зеркало","Глобус","Сетка","Диаграмма роста","Скидка","JCB","Лупа","MasterCard","Минус","МИР","Деньги","Денежное страхование","Монитор и мобильный","Новый документ","Офис","Лого «Одноклассники»","Бизнес","Проценты (круг.)","Проценты","Проценты белые","Персональная карта","Лого «PlayMarket»","Плюс","Профиль, 2 персоны","Профиль","Рубль (круг.)","Сейф","Безопасность","Подписанные документы","Маленькие часы","Лого «Telegram»","UnionPay","Пользователь","Visa","Лого «VK»","Пополнение карты","Кошелёк с плюсом","Кошелёк","Кошелёк с деньгами"]},"Benefit":{"type":"object","properties":{"label":{"type":"string","title":"Название"},"description":{"type":"string","title":"Описание"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Преимущество"},"BenefitsBlockContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Список преимуществ","maxItems":6}},"title":"Блок преимущества"},"PictureTextContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Список преимуществ"}},"title":"Картинка с текстом"},"Picture":{"type":"object","properties":{"src":{"type":"string","title":"Картинка"},"format":{"type":"string","enum":["jpeg","jpg","png","gif","webp","heif","avif"],"title":"Формат"},"size":{"type":"object","properties":{"width":{"type":"number","title":"Ширина"},"height":{"type":"number","title":"Высота"}},"title":"Размер изображения"},"alt":{"type":"string","title":"Альтернативный текст (alt)"},"sources":{"type":"array","items":{"$ref":"#/definitions/ImgSource"},"title":"Другие форматы"},"title":{"type":"string","title":"Текст подсказки (title)"}},"required":["src"],"title":"Изображение"},"Img":{"type":"object","properties":{"src":{"type":"string","title":"Картинка"},"alt":{"type":"string","title":"Альтернативный текст (alt)"},"title":{"type":"string","title":"Текст подсказки (title)"}},"required":["src"]},"ImgSource":{"type":"object","properties":{"src":{"type":"string","title":"Картинка"},"format":{"type":"string","enum":["jpeg","jpg","png","gif","webp","heif","avif"],"title":"Формат"},"size":{"type":"object","properties":{"width":{"type":"number","title":"Ширина"},"height":{"type":"number","title":"Высота"}},"title":"Размер изображения"}},"required":["src"]},"TextBlockVersion":{"type":"string","enum":["primary","secondary","secondary-light"],"title":"Цвет плитки","enumNames":["Основная","Второстепенная","Второстепенная прозрачная"]},"TextBlockIconVersion":{"type":"string","enum":["none","small","big"],"title":"Размер иконки","enumNames":["Нет","Маленькая","Большая"]},"TextBlockContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"iconVersion":{"$ref":"#/definitions/TextBlockIconVersion"},"blockVersion":{"$ref":"#/definitions/TextBlockVersion"}},"title":"Текстовый блок"},"AccordionTypeBlock":{"type":"string","enum":["Headline","LinkDocs","TextBlock","PictureText"],"title":"Тип блока"},"HeadlineAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"Headline"},"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"bgColor":{"$ref":"#/definitions/HeadlineBgColor"}},"required":["accordionBlockType"],"title":"Заголовок"},"LinkDocsAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"LinkDocs"},"title":{"type":"string","title":"Заголовок"},"align":{"$ref":"#/definitions/AlignType"},"columnsMode":{"$ref":"#/definitions/LinkColumnsMode","title":"Отображение списка"},"icon":{"$ref":"#/definitions/IconName","title":"Название иконки"},"documents":{"type":"array","items":{"$ref":"#/definitions/LinkDocsItem"},"title":"Список"}},"required":["accordionBlockType"],"title":"Список документов"},"TextBlockAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"TextBlock"},"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"iconVersion":{"$ref":"#/definitions/TextBlockIconVersion"},"blockVersion":{"$ref":"#/definitions/TextBlockVersion"}},"required":["accordionBlockType"],"title":"Текстовый блок"},"PictureTextAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"PictureText"},"title":{"type":"string","title":"Заголовок"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Список преимуществ"}},"required":["accordionBlockType"],"title":"Картинка с текстом"},"EmptyOption":{"type":"null","title":"Выберите блок"},"AccordionBlockProps":{"anyOf":[{"$ref":"#/definitions/EmptyOption"},{"$ref":"#/definitions/HeadlineAccordionBlock"},{"$ref":"#/definitions/LinkDocsAccordionBlock"},{"$ref":"#/definitions/TextBlockAccordionBlock"},{"$ref":"#/definitions/PictureTextAccordionBlock"}],"title":"Содержимое аккордеона"},"AccordionItemCommonProps":{"type":"object","properties":{"label":{"type":"string","title":"Название","default":"Список"},"blocks":{"type":"array","items":{"$ref":"#/definitions/AccordionBlockProps"},"title":"Блоки"}},"title":"Элемент списка"},"AccordionContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"accordionItems":{"type":"array","items":{"$ref":"#/definitions/AccordionItemCommonProps"},"title":"Список"}},"title":"Аккордеон"},"CellData":{"type":"object","properties":{"label":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"}},"title":"Ячейка"},"ColumnHeader":{"type":"object","properties":{"link":{"$ref":"#/definitions/LinkProps"},"title":{"type":"string","title":"Заголовок"},"image":{"$ref":"#/definitions/Picture"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Шапка колонки"},"Column":{"type":"object","properties":{"header":{"$ref":"#/definitions/ColumnHeader"},"data":{"type":"array","items":{"type":"array","items":{"$ref":"#/definitions/CellData"}},"title":"Данные"}},"title":"Продукт"},"RowHeader":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"}},"title":"Параметр"},"ComparisonTableContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"rowHeaders":{"type":"array","items":{"$ref":"#/definitions/RowHeader"},"title":"Параметры"},"columns":{"type":"array","items":{"$ref":"#/definitions/Column"},"title":"Продукты"},"isColoredFirstColumn":{"type":"boolean","title":"Закрасить первую колонку"},"visibleRowLength":{"type":"number","title":"Отображать заданное количество строк"}},"title":"Сравнительная таблица"},"ExchangeRateTileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"}},"title":"Курсы валют"},"ContactType":{"type":"string","enum":["tel","email"],"title":"Тип контакта","enumNames":["Телефон","Почта"]},"ContactInfo":{"type":"object","properties":{"type":{"$ref":"#/definitions/ContactType"},"description":{"type":"string","title":"Описание"},"text":{"type":"string","title":"Текст"}},"title":"Контакт"},"SocialMedia":{"type":"object","properties":{"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"required":["href"]},"FooterContent":{"type":"object","properties":{"topItems":{"type":"array","items":{"$ref":"#/definitions/TopMenuItem"},"title":"Дополнительное меню"},"relatedEnterprises":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Другие предприятия"},"contacts":{"type":"array","items":{"$ref":"#/definitions/ContactInfo"},"title":"Контакты"},"socialMedia":{"type":"array","items":{"$ref":"#/definitions/SocialMedia"},"title":"Социальные сети"},"documents":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Обязательные документы"}},"title":"Подвал","required":["topItems"]},"SitemapProps":{"type":"object","properties":{"topItems":{"type":"array","items":{"$ref":"#/definitions/TopMenuItem"},"title":"Дополнительное меню"}}},"TopMenuItem":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Ссылки"},"text":{"type":"string","title":"Текст"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"title":"Меню","required":["text","href"]},"GalleryCard":{"type":"object","properties":{"button":{"$ref":"#/definitions/BaseTileIconButton","title":"Ссылка"},"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список","minItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Карточка"},"BaseTileIconButton":{"type":"object","properties":{"rounded":{"type":"boolean","title":"Закругленные углы"},"version":{"$ref":"#/definitions/ButtonVersion"},"aboveText":{"type":"string","title":"Верхний текст"},"icon":{"$ref":"#/definitions/IconName"},"text":{"type":"string","title":"Текст","default":"Кнопка"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}}},"ButtonWithIconProps":{"type":"object","properties":{"rounded":{"type":"boolean","title":"Закругленные углы"},"version":{"$ref":"#/definitions/ButtonVersion"},"aboveText":{"type":"string","title":"Верхний текст"},"text":{"type":"string","title":"Текст","default":"Кнопка"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}}},"ButtonProps":{"type":"object","properties":{"version":{"$ref":"#/definitions/ButtonVersion"},"text":{"type":"string","title":"Текст","default":"Кнопка"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}}},"ButtonVersion":{"type":"string","enum":["primary","secondary"],"title":"Цвет кнопки","default":"primary","enumNames":["Основная","Второстепенная"]},"BlockVersion":{"type":"string","enum":["primary","secondary"],"title":"Цвет плитки","enumNames":["Основная","Второстепенная"]},"GalleryContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"cards":{"type":"array","items":{"$ref":"#/definitions/GalleryCard"},"title":"Карточки"}},"title":"Галерея"},"HeaderContent":{"type":"object","properties":{"topItems":{"type":"array","items":{"$ref":"#/definitions/TopMenuItem"},"title":"Дополнительное меню"},"defaultLocation":{"type":"string","title":"Город по-умолчанию","default":"Москва"}},"title":"Шапка","required":["defaultLocation","topItems"]},"QRCode":{"type":"object","properties":{"src":{"type":"string","title":"QR код"},"href":{"type":"string","title":"Ссылка"}},"title":"QR код"},"MobileAppTileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"qr":{"$ref":"#/definitions/QRCode"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4}},"title":"Мобильное приложение"},"ProductBlockInnerCommonProps":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Преимущества","minItems":2,"maxItems":3},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}}},"ProductBlockContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"breadcrumbs":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Хлебные крошки"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Преимущества","minItems":2,"maxItems":3},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Продуктовый блок"},"ProductSlide":{"type":"object","properties":{"nav":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"desc":{"type":"string","title":"Описание"}},"required":["title","desc"],"title":"Кнопка под слайдом"},"productBlock":{"$ref":"#/definitions/ProductBlockInnerCommonProps","title":"Содержимое слайда"}},"required":["nav","productBlock"],"title":"Слайд"},"ProductGalleryContent":{"type":"object","properties":{"slides":{"type":"array","items":{"$ref":"#/definitions/ProductSlide"},"title":"Слайды"}},"title":"Продуктовая галерея"},"ProductTileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string","title":"Название"},"description":{"type":"string","title":"Описание"}}},"title":"Преимущества"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Продуктовая плитка"},"PromoTileContent":{"type":"object","properties":{"date":{"type":"string","title":"Дата публикации"},"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Акции"},"BaseTileCommonProps":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Плитка"},"Step":{"type":"object","properties":{"label":{"type":"string","title":"Название"},"description":{"type":"string","title":"Описание"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Шаг"},"StepsBlockContent":{"type":"object","properties":{"showLines":{"type":"boolean","title":"Линии"},"title":{"type":"string","title":"Заголовок"},"steps":{"type":"array","items":{"$ref":"#/definitions/Step"},"title":"Шаги","minItems":2,"maxItems":3}},"title":"Блок шаги"},"TileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Плитка"},"TariffsTableRowData":{"type":"object","properties":{"header":{"$ref":"#/definitions/TariffsTableRowHeader"},"data":{"type":"array","items":{"type":"array","items":{"$ref":"#/definitions/TariffsTableCellData"}}}},"required":["header","data"],"title":"Ряд"},"TariffsTableRowHeader":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Параметр"},"TariffsTableCellData":{"type":"object","properties":{"label":{"type":"string","title":"Заголовок"},"list":{"$ref":"#/definitions/TariffsTableList"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки"}},"title":"Ячейка"},"TariffsTableList":{"type":"object","properties":{"items":{"type":"array","items":{"type":"string"},"title":"Элементы списка"}},"title":"Список"},"TariffsTableColumn":{"type":"object","properties":{"data":{"type":"array","items":{"type":"array","items":{"$ref":"#/definitions/TariffsTableCellData"}},"title":"Данные"}},"title":"Колонка"},"TariffsTableContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"rowHeaders":{"type":"array","items":{"$ref":"#/definitions/TariffsTableRowHeader"},"title":"Параметры"},"columns":{"type":"array","items":{"$ref":"#/definitions/TariffsTableColumn"},"title":"Колонки"}},"title":"Таблица тарифов"},"CalculatorParams":{"type":"object","properties":{"isAnnuity":{"type":"boolean"},"minSum":{"type":"number"},"maxSum":{"type":"number"},"minMonths":{"type":"number"},"maxMonths":{"type":"number"},"rateWithInsurance":{"type":"number"},"rateWithoutInsurance":{"type":"number"}}},"CreditCalculatorData":{"type":"object","properties":{"rows":{"type":"array","items":{"$ref":"#/definitions/CalculatorParams"}}}},"CreditCalculatorContent":{"type":"object","properties":{"directoryName":{"type":"string","title":"Справочник"}},"title":"Кредитный калькулятор"},"MiniGalleryContent":{"$ref":"#/definitions/GalleryContent","title":"Мини-галерея"}}}
1
+ {"$schema":"http://json-schema.org/draft-07/schema#","definitions":{"HeadlineContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"bgColor":{"$ref":"#/definitions/BgColorVersion"}},"title":"Заголовок"},"TitleSize":{"type":"string","enum":["XL","L","M","S"]},"AlignType":{"type":"string","enum":["left","center","right"],"title":"Выравнивание","enumNames":["По левому краю","По центру","По правому краю"]},"BgColorVersion":{"type":"string","enum":["transparent","bg-white"],"title":"Цвет фона","enumNames":["Прозрачный","Белый"]},"LinkColumnsMode":{"type":"string","enum":["single","double"],"title":"Режим отображения списка"},"LinkDocsItem":{"type":"object","properties":{"text":{"type":"string","title":"Текст"},"fileSize":{"type":"string","title":"размер файла"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"title":"Элемент списка"},"LinkProps":{"type":"object","properties":{"text":{"type":"string","title":"Текст"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"title":"Ссылка","required":["text","href"]},"Target":{"type":"string","enum":["","_self","_blank","_parent","_top"],"title":"Таргет (target)","enumNames":["","self (текущее окно или фрейм)","blank (новое окно)","parent (фрейм-родитель)","top (текущее окно)"]},"LinkDocsContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"align":{"$ref":"#/definitions/AlignType"},"columnsMode":{"$ref":"#/definitions/LinkColumnsMode","title":"Отображение списка"},"icon":{"$ref":"#/definitions/IconName","title":"Название иконки"},"documents":{"type":"array","items":{"$ref":"#/definitions/LinkDocsItem"},"title":"Список"}},"title":"Список документов"},"IconName":{"type":"string","enum":["ActualBalanceIcon","AppleIcon","Calendar2Icon","CalendarCircleIcon","CalendarIcon","CalendarTickIcon","CalendarWhiteIcon","CardWithGemIcon","ChartSquareIcon","CardIcon","CardPosIcon","CardTickIcon","ClockIcon","ComfortableCompIcon","CreditCardsIcon","DiscountShapeIcon","DocIcon","DocumentTextIcon","DollarIcon","EarthIcon","EmptyWalletChangeIcon","EmptyWalletIcon","EmptyWalletWhiteIcon","EuroIcon","GlassIcon","GlobalIcon","GridIcon","GridIconWhite","InterestGrowthIcon","InterestIcon","JCBIcon","LoupeIcon","MasterCardIcon","MinusIcon","MirIcon","MoneyIcon","MoneyInsuranceIcon","MonitorMobileIcon","NewDocIcon","OfficeIcon","OkIcon","PassSendIcon","PercentageRoundIcon","PercentageSquareIcon","PercentageSquareWhiteIcon","PersonalCardIcon","PlayMarketIcon","PlusIcon","Profile2UserIcon","ProfileIcon","RoundRubleIcon","SafeIcon","ShieldTickIcon","SignDocsIcon","SmallClockIcon","TelegramIcon","UnionPayIcon","UserTickIcon","VisaIcon","VKIcon","WalletAdd","WalletAdd2","WalletIcon","WalletWithMoneyIcon"],"title":"Иконка","enumNames":["Деньги","Лого «Apple»","Календарь 2","Скруглённый календарь","Календарь","Календарь с галочкой","Календарь белый","Карта с драгоценностями","Деньги внутри кошелька","Кред. карта","Кред. карта под наклоном","Кред. карта с галочкой","Часы","Кресло","Скидка","Кредитные карты","Огромная скидка","Документ","Документ с текстом","Доллар","Пустой кошелёк с возвратом","Пустой кошелёк","Пустой кошелёк (белый)","Евро","Зеркало","Глобус","Сетка","Сетка (белая)","Диаграмма роста","Скидка","JCB","Лупа","MasterCard","Минус","МИР","Деньги","Денежное страхование","Монитор и мобильный","Новый документ","Офис","Лого «Одноклассники»","Бизнес","Проценты (круг.)","Проценты","Проценты белые","Персональная карта","Лого «PlayMarket»","Плюс","Профиль, 2 персоны","Профиль","Рубль (круг.)","Сейф","Безопасность","Подписанные документы","Маленькие часы","Лого «Telegram»","UnionPay","Пользователь","Visa","Лого «VK»","Пополнение карты","Кошелёк с плюсом","Кошелёк","Кошелёк с деньгами"]},"Benefit":{"type":"object","properties":{"label":{"type":"string","title":"Название"},"description":{"type":"string","title":"Описание"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Преимущество"},"BenefitsBlockContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Список преимуществ","maxItems":6}},"title":"Блок преимущества"},"PictureTextContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Список преимуществ"}},"title":"Картинка с текстом"},"Picture":{"type":"object","properties":{"src":{"type":"string","title":"Картинка"},"format":{"type":"string","enum":["jpeg","jpg","png","gif","webp","heif","avif"],"title":"Формат"},"size":{"type":"object","properties":{"width":{"type":"number","title":"Ширина"},"height":{"type":"number","title":"Высота"}},"title":"Размер изображения"},"alt":{"type":"string","title":"Альтернативный текст (alt)"},"sources":{"type":"array","items":{"$ref":"#/definitions/ImgSource"},"title":"Другие форматы"},"title":{"type":"string","title":"Текст подсказки (title)"}},"required":["src"],"title":"Изображение"},"Img":{"type":"object","properties":{"src":{"type":"string","title":"Картинка"},"alt":{"type":"string","title":"Альтернативный текст (alt)"},"title":{"type":"string","title":"Текст подсказки (title)"}},"required":["src"]},"ImgSource":{"type":"object","properties":{"src":{"type":"string","title":"Картинка"},"format":{"type":"string","enum":["jpeg","jpg","png","gif","webp","heif","avif"],"title":"Формат"},"size":{"type":"object","properties":{"width":{"type":"number","title":"Ширина"},"height":{"type":"number","title":"Высота"}},"title":"Размер изображения"}},"required":["src"]},"TextBlockVersion":{"type":"string","enum":["primary","secondary","secondary-light"],"title":"Цвет плитки","enumNames":["Основная","Второстепенная","Второстепенная прозрачная"]},"TextBlockIconVersion":{"type":"string","enum":["none","small","big"],"title":"Размер иконки","enumNames":["Нет","Маленькая","Большая"]},"TextBlockContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"iconVersion":{"$ref":"#/definitions/TextBlockIconVersion"},"blockVersion":{"$ref":"#/definitions/TextBlockVersion"}},"title":"Текстовый блок"},"AccordionTypeBlock":{"type":"string","enum":["Headline","LinkDocs","TextBlock","PictureText"],"title":"Тип блока"},"HeadlineAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"Headline"},"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"bgColor":{"$ref":"#/definitions/BgColorVersion"}},"required":["accordionBlockType"],"title":"Заголовок"},"LinkDocsAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"LinkDocs"},"title":{"type":"string","title":"Заголовок"},"align":{"$ref":"#/definitions/AlignType"},"columnsMode":{"$ref":"#/definitions/LinkColumnsMode","title":"Отображение списка"},"icon":{"$ref":"#/definitions/IconName","title":"Название иконки"},"documents":{"type":"array","items":{"$ref":"#/definitions/LinkDocsItem"},"title":"Список"}},"required":["accordionBlockType"],"title":"Список документов"},"TextBlockAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"TextBlock"},"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"iconVersion":{"$ref":"#/definitions/TextBlockIconVersion"},"blockVersion":{"$ref":"#/definitions/TextBlockVersion"}},"required":["accordionBlockType"],"title":"Текстовый блок"},"PictureTextAccordionBlock":{"type":"object","properties":{"accordionBlockType":{"$ref":"#/definitions/AccordionTypeBlock","default":"PictureText"},"title":{"type":"string","title":"Заголовок"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Список преимуществ"}},"required":["accordionBlockType"],"title":"Картинка с текстом"},"EmptyOption":{"type":"null","title":"Выберите блок"},"AccordionBlockProps":{"anyOf":[{"$ref":"#/definitions/EmptyOption"},{"$ref":"#/definitions/HeadlineAccordionBlock"},{"$ref":"#/definitions/LinkDocsAccordionBlock"},{"$ref":"#/definitions/TextBlockAccordionBlock"},{"$ref":"#/definitions/PictureTextAccordionBlock"}],"title":"Содержимое аккордеона"},"AccordionItemCommonProps":{"type":"object","properties":{"label":{"type":"string","title":"Название","default":"Список"},"blocks":{"type":"array","items":{"$ref":"#/definitions/AccordionBlockProps"},"title":"Блоки"}},"title":"Элемент списка"},"AccordionContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"accordionItems":{"type":"array","items":{"$ref":"#/definitions/AccordionItemCommonProps"},"title":"Список"}},"title":"Аккордеон"},"CellData":{"type":"object","properties":{"label":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"}},"title":"Ячейка"},"ColumnHeader":{"type":"object","properties":{"link":{"$ref":"#/definitions/LinkProps"},"title":{"type":"string","title":"Заголовок"},"image":{"$ref":"#/definitions/Picture"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Шапка колонки"},"Column":{"type":"object","properties":{"header":{"$ref":"#/definitions/ColumnHeader"},"data":{"type":"array","items":{"type":"array","items":{"$ref":"#/definitions/CellData"}},"title":"Данные"}},"title":"Продукт"},"RowHeader":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"}},"title":"Параметр"},"ComparisonTableContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"rowHeaders":{"type":"array","items":{"$ref":"#/definitions/RowHeader"},"title":"Параметры"},"columns":{"type":"array","items":{"$ref":"#/definitions/Column"},"title":"Продукты"},"isColoredFirstColumn":{"type":"boolean","title":"Закрасить первую колонку"},"visibleRowLength":{"type":"number","title":"Отображать заданное количество строк"}},"title":"Сравнительная таблица"},"ExchangeRateTileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"}},"title":"Курсы валют"},"ContactType":{"type":"string","enum":["tel","email"],"title":"Тип контакта","enumNames":["Телефон","Почта"]},"ContactInfo":{"type":"object","properties":{"type":{"$ref":"#/definitions/ContactType"},"description":{"type":"string","title":"Описание"},"text":{"type":"string","title":"Текст"}},"title":"Контакт"},"SocialMedia":{"type":"object","properties":{"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"required":["href"]},"FooterContent":{"type":"object","properties":{"topItems":{"type":"array","items":{"$ref":"#/definitions/TopMenuItem"},"title":"Дополнительное меню"},"relatedEnterprises":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Другие предприятия"},"contacts":{"type":"array","items":{"$ref":"#/definitions/ContactInfo"},"title":"Контакты"},"socialMedia":{"type":"array","items":{"$ref":"#/definitions/SocialMedia"},"title":"Социальные сети"},"documents":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Обязательные документы"}},"title":"Подвал","required":["topItems"]},"SitemapProps":{"type":"object","properties":{"topItems":{"type":"array","items":{"$ref":"#/definitions/TopMenuItem"},"title":"Дополнительное меню"}}},"TopMenuItem":{"type":"object","properties":{"text":{"type":"string","title":"Текст"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}},"title":"Ссылка","required":["text","href"]},"GalleryCard":{"type":"object","properties":{"button":{"$ref":"#/definitions/BaseTileIconButton","title":"Ссылка"},"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список","minItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Карточка"},"BaseTileIconButton":{"type":"object","properties":{"rounded":{"type":"boolean","title":"Закругленные углы"},"version":{"$ref":"#/definitions/ButtonVersion"},"aboveText":{"type":"string","title":"Верхний текст"},"icon":{"$ref":"#/definitions/IconName"},"text":{"type":"string","title":"Текст","default":"Кнопка"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}}},"ButtonWithIconProps":{"type":"object","properties":{"rounded":{"type":"boolean","title":"Закругленные углы"},"version":{"$ref":"#/definitions/ButtonVersion"},"aboveText":{"type":"string","title":"Верхний текст"},"text":{"type":"string","title":"Текст","default":"Кнопка"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}}},"ButtonProps":{"type":"object","properties":{"version":{"$ref":"#/definitions/ButtonVersion"},"text":{"type":"string","title":"Текст","default":"Кнопка"},"href":{"type":"string","title":"URL (href)"},"target":{"$ref":"#/definitions/Target"}}},"ButtonVersion":{"type":"string","enum":["primary","secondary"],"title":"Цвет кнопки","default":"primary","enumNames":["Основная","Второстепенная"]},"BlockVersion":{"type":"string","enum":["primary","secondary"],"title":"Цвет плитки","enumNames":["Основная","Второстепенная"]},"GalleryContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"cards":{"type":"array","items":{"$ref":"#/definitions/GalleryCard"},"title":"Карточки"}},"title":"Галерея"},"HeaderContent":{"type":"object","properties":{"topItems":{"type":"array","items":{"$ref":"#/definitions/TopMenuItem"},"title":"Дополнительное меню"},"defaultLocation":{"type":"string","title":"Город по-умолчанию","default":"Москва"}},"title":"Шапка","required":["defaultLocation","topItems"]},"QRCode":{"type":"object","properties":{"src":{"type":"string","title":"QR код"},"href":{"type":"string","title":"Ссылка"}},"title":"QR код"},"MobileAppTileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"qr":{"$ref":"#/definitions/QRCode"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4}},"title":"Мобильное приложение"},"NavigationContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"buttons":{"type":"array","items":{"$ref":"#/definitions/ButtonProps"},"title":"Список ссылок"}},"title":"Навигация"},"ProductBlockInnerCommonProps":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Преимущества","minItems":2,"maxItems":3},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}}},"ProductBlockContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"breadcrumbs":{"type":"array","items":{"$ref":"#/definitions/LinkProps"},"title":"Хлебные крошки"},"benefits":{"type":"array","items":{"$ref":"#/definitions/Benefit"},"title":"Преимущества","minItems":2,"maxItems":3},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Продуктовый блок"},"ProductSlide":{"type":"object","properties":{"nav":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"desc":{"type":"string","title":"Описание"}},"required":["title","desc"],"title":"Кнопка под слайдом"},"productBlock":{"$ref":"#/definitions/ProductBlockInnerCommonProps","title":"Содержимое слайда"}},"required":["nav","productBlock"],"title":"Слайд"},"ProductGalleryContent":{"type":"object","properties":{"slides":{"type":"array","items":{"$ref":"#/definitions/ProductSlide"},"title":"Слайды"}},"title":"Продуктовая галерея"},"ProductTileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"benefits":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string","title":"Название"},"description":{"type":"string","title":"Описание"}}},"title":"Преимущества"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Продуктовая плитка"},"PromoTileContent":{"type":"object","properties":{"date":{"type":"string","title":"Дата публикации"},"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Акции"},"BaseTileCommonProps":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"align":{"$ref":"#/definitions/AlignType"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Плитка"},"Step":{"type":"object","properties":{"label":{"type":"string","title":"Название"},"description":{"type":"string","title":"Описание"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Шаг"},"StepsBlockContent":{"type":"object","properties":{"showLines":{"type":"boolean","title":"Линии"},"title":{"type":"string","title":"Заголовок"},"steps":{"type":"array","items":{"$ref":"#/definitions/Step"},"title":"Шаги","minItems":2,"maxItems":3}},"title":"Блок шаги"},"TariffsTableRowData":{"type":"object","properties":{"header":{"$ref":"#/definitions/TariffsTableRowHeader"},"data":{"type":"array","items":{"type":"array","items":{"$ref":"#/definitions/TariffsTableCellData"}}}},"required":["header","data"],"title":"Ряд"},"TariffsTableRowHeader":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"icon":{"$ref":"#/definitions/IconName"}},"title":"Параметр"},"TariffsTableCellData":{"type":"object","properties":{"label":{"type":"string","title":"Заголовок"},"list":{"$ref":"#/definitions/TariffsTableList"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки"}},"title":"Ячейка"},"TariffsTableList":{"type":"object","properties":{"items":{"type":"array","items":{"type":"string"},"title":"Элементы списка"}},"title":"Список"},"TariffsTableColumn":{"type":"object","properties":{"data":{"type":"array","items":{"type":"array","items":{"$ref":"#/definitions/TariffsTableCellData"}},"title":"Данные"}},"title":"Колонка"},"TariffsTableContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"rowHeaders":{"type":"array","items":{"$ref":"#/definitions/TariffsTableRowHeader"},"title":"Параметры"},"columns":{"type":"array","items":{"$ref":"#/definitions/TariffsTableColumn"},"title":"Колонки"}},"title":"Таблица тарифов"},"TileContent":{"type":"object","properties":{"title":{"type":"string","title":"Заголовок"},"titleSize":{"$ref":"#/definitions/TitleSize","title":"Размер заголовка","default":"M"},"description":{"type":"string","title":"Описание"},"image":{"$ref":"#/definitions/Picture"},"items":{"type":"array","items":{"type":"string"},"title":"Список"},"buttons":{"type":"array","items":{"$ref":"#/definitions/BaseTileIconButton"},"title":"Кнопки","maxItems":4},"version":{"$ref":"#/definitions/BlockVersion"}},"title":"Плитка"},"CalculatorParams":{"type":"object","properties":{"isAnnuity":{"type":"boolean"},"minSum":{"type":"number"},"maxSum":{"type":"number"},"minMonths":{"type":"number"},"maxMonths":{"type":"number"},"rateWithInsurance":{"type":"number"},"rateWithoutInsurance":{"type":"number"}}},"CreditCalculatorData":{"type":"object","properties":{"rows":{"type":"array","items":{"$ref":"#/definitions/CalculatorParams"}}}},"CreditCalculatorContent":{"type":"object","properties":{"directoryName":{"type":"string","title":"Справочник"}},"title":"Кредитный калькулятор"},"MiniGalleryContent":{"$ref":"#/definitions/GalleryContent","title":"Мини-галерея"}}}
@@ -390,15 +390,10 @@
390
390
  return { nextClick, prevClick, isScrollAvailable, showNextButton, showPrevButton };
391
391
  };
392
392
 
393
- const MOBILE_URL_PATH = '/mobile';
394
393
  const isURL = (href) => href?.includes('//');
395
- const isHrefActive = (href, router, cmp = (href, baseHref) => href === baseHref) => {
396
- return cmp(withoutQuery(href), withoutMobilePath(withoutQuery(isURL(href) ? router.href : router.pathname)));
397
- };
398
394
  const withoutQuery = (href) => (href || '').replace(/\/?\?.*/, '');
399
- const withoutMobilePath = (href) => (href || '').replace(MOBILE_URL_PATH, '');
400
395
  const getOrigin = (href) => {
401
- if (!isURL(href)) {
396
+ if (!href || !isURL(href)) {
402
397
  return undefined;
403
398
  }
404
399
  const url = href;
@@ -407,11 +402,22 @@
407
402
  const endOfOrigin = url.indexOf('/', endOfProto + protoSeparator.length);
408
403
  return endOfOrigin !== -1 ? url.substring(0, endOfOrigin) : url;
409
404
  };
405
+
406
+ var url = /*#__PURE__*/Object.freeze({
407
+ __proto__: null,
408
+ isURL: isURL,
409
+ withoutQuery: withoutQuery,
410
+ getOrigin: getOrigin
411
+ });
412
+
413
+ const MOBILE_URL_PATH = '/mobile';
414
+ const withoutMobilePath = (href) => (href || '').replace(MOBILE_URL_PATH, '');
415
+
410
416
  const adjustHref = (href, router) => {
411
417
  if (!href) {
412
418
  return href;
413
419
  }
414
- const relativeHref = toRelativeHref(href, router);
420
+ const relativeHref = toRelativeHref(href, router) || '';
415
421
  const isMobilePage = router?.pathname.startsWith(MOBILE_URL_PATH);
416
422
  return isMobilePage && !isURL(relativeHref) ? `${MOBILE_URL_PATH}${relativeHref}` : relativeHref;
417
423
  };
@@ -423,18 +429,6 @@
423
429
  return origin ? href.replace(origin, '') || '/' : href;
424
430
  };
425
431
 
426
- var url = /*#__PURE__*/Object.freeze({
427
- __proto__: null,
428
- MOBILE_URL_PATH: MOBILE_URL_PATH,
429
- isURL: isURL,
430
- isHrefActive: isHrefActive,
431
- withoutQuery: withoutQuery,
432
- withoutMobilePath: withoutMobilePath,
433
- getOrigin: getOrigin,
434
- adjustHref: adjustHref,
435
- toRelativeHref: toRelativeHref
436
- });
437
-
438
432
  const defaultHandlerDecorator = (handler) => handler;
439
433
  function useLink({ router, handlerDecorator = defaultHandlerDecorator, }, link) {
440
434
  const href = adjustHref(link.href, router);
@@ -496,13 +490,13 @@
496
490
  : 'bg-white text-primary-text hover:text-primary-main'} ${className || ''}`, disabled: disabled, ...rest, children: jsx(SVG, { paths: ARROW_PATHS, viewBox: "0 0 16 16", fill: "none", width: "16", height: "16" }) })));
497
491
 
498
492
  const GRADIENT = 'bg-gradient-to-r from-main-gradient-start to-main-gradient-end';
499
- const BORDER_CLASSES = 'border-main-stroke border-solid border';
493
+ const BORDER_CLASSES$1 = 'border-main-stroke border-solid border';
500
494
  const DIVIDER_CLASSES$1 = 'border-main-divider border border-t-0 border-x-0';
501
495
  const FIRST_CELL_CLASSES$1 = 'w-[200px] mr-6';
502
496
  const COLS_LENGTH_FOR_SCROLL$1 = 2;
503
497
  const COLUMN_WIDTH$1 = 4 * 80 + 4 * 4; // w-80 + gap-4 = 336px
504
498
 
505
- const HeaderCell = JSX(({ icon, image, title, link }) => (jsxs("div", { className: `w-80 box-border flex flex-col items-center rounded-t-md border-b-0 px-7 pt-7 pb-[46px] ${BORDER_CLASSES} ${GRADIENT}`, role: "columnheader", scope: "col", children: [icon && !image?.src && (jsx(Icon, { className: "h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4", name: icon, width: "63", height: "63" })), image?.src && jsx(Img, { className: "mb-[18px]", image: image }), title && (jsx(Title, { size: "S", className: "font-medium m-0 text-center text-white", children: title })), link?.text && (jsx("div", { className: "mt-auto w-full", children: jsx(Button, { href: link.href, target: link.target, className: "mt-4 w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active", children: jsx("div", { className: "font-medium text-xs py-[11px]", children: link.text }) }) }))] })));
499
+ const HeaderCell = JSX(({ icon, image, title, link }) => (jsxs("div", { className: `w-80 box-border flex flex-col items-center rounded-t-md border-b-0 px-7 pt-7 pb-[46px] ${BORDER_CLASSES$1} ${GRADIENT}`, role: "columnheader", scope: "col", children: [icon && !image?.src && (jsx(Icon, { className: "h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4", name: icon, width: "63", height: "63" })), image?.src && jsx(Img, { className: "mb-[18px]", image: image }), title && (jsx(Title, { size: "S", className: "font-medium m-0 text-center text-white", children: title })), link?.text && (jsx("div", { className: "mt-auto w-full", children: jsx(Button, { href: link.href, target: link.target, className: "mt-4 w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active", children: jsx("div", { className: "font-medium text-xs py-[11px]", children: link.text }) }) }))] })));
506
500
 
507
501
  const carouselContainerClassesMap = {
508
502
  comparison: 'flex gap-4 duration-1000',
@@ -511,7 +505,7 @@
511
505
  const TableCarouselContainer = JSX(({ children, activeCardIndex, columnWidth, version = 'comparison' }) => (jsx("div", { className: "flex flex-1 overflow-hidden", children: jsx("div", { className: carouselContainerClassesMap[version], style: { transform: `translateX(-${activeCardIndex * columnWidth}px)` }, children: children }) })));
512
506
 
513
507
  const TableCell = JSX(({ cell, isFirstRow, isLastRow, isFillGradient }) => {
514
- const cellWrapperClasses = `w-80 box-border flex flex-col ${BORDER_CLASSES} ${!isLastRow ? 'border-y-0' : 'border-t-0 rounded-b-md'} ${isFillGradient ? GRADIENT : ''}`;
508
+ const cellWrapperClasses = `w-80 box-border flex flex-col ${BORDER_CLASSES$1} ${!isLastRow ? 'border-y-0' : 'border-t-0 rounded-b-md'} ${isFillGradient ? GRADIENT : ''}`;
515
509
  const cellClasses = `mx-7 h-full ${DIVIDER_CLASSES$1} ${isFillGradient && isFirstRow ? 'border-t' : ''} ${!isLastRow ? 'border-solid' : ''}`;
516
510
  return (jsx("div", { className: cellWrapperClasses, role: "cell", children: jsx("div", { className: cellClasses, children: cell.map((item, i) => renderCellInner$1(item, i, isFillGradient)) }) }));
517
511
  });
@@ -801,8 +795,16 @@
801
795
  'M14.7 27.83h2.58c.67 0 1.14.14 1.4.4.27.25.4.72.4 1.38v7.4c0 .66-.12 1.12-.4 1.38-.4.41-1.16.41-1.78.41l-.4-.01v3.5l.78.14v-2.88c1.2 0 1.97-.4 2.34-1.22v4.29h.26l.5-.01V29.74c0-.68.13-1.16.4-1.43.25-.27.72-.4 1.37-.4.67 0 1.65-.1 2.16.4.26.27.38.76.38 1.43v3.8h-1.77v-4.06h-.77v12.99c.26-.03.5-.07.77-.12V34.3h1.77v7.64c.36-.1.72-.21 1.08-.34v-7c0-.8.19-1.4 1-1.67l-.9-4.87h1.8l.3 5.31h.22l.3-5.31h1.88l-1.01 4.87c.84.3 1.01.81 1.01 1.66v4.53a16.63 16.63 0 0 0 1.5-1.27v-9.83h5.25l.1-.72H24.93l.17.89c-.38-.72-1.12-1.08-2.2-1.08h-.77c-1.3 0-2.1.52-2.4 1.55-.27-1.08-1.1-1.62-2.46-1.62h-3.36v14.52c.26.09.52.18.78.25V27.84Zm16.29 5.58-.85-.8.85-4.37v5.17Z',
802
796
  'M27.66 40.79c.27-.14.55-.28.8-.43v-5.98h-.8v6.4Z',
803
797
  ];
804
- const Logo = JSX(({ className, href, children, targetBlank }) => {
805
- return (jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className || ''}`, href: href || 'https://rshb.ru/', target: targetBlank ? '_blank' : '_self', children: [jsx(SVG, { className: "text-primary-main w-10", viewBox: "0 0 40 45", paths: LOGO_PATHS.map((d) => ({ d })) }), jsx("span", { className: "text-black text-base font-medium ml-2.5", children: children || 'Россельхозбанк' })] }));
798
+ const SVG_COLOR = {
799
+ 'bg-white': 'text-primary-main',
800
+ transparent: 'text-white',
801
+ };
802
+ const TEXT_COLOR = {
803
+ 'bg-white': 'text-black',
804
+ transparent: 'text-white',
805
+ };
806
+ const Logo = JSX(({ className, href, children, targetBlank, bgColor = 'bg-white' }) => {
807
+ return (jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className || ''}`, href: href || 'https://rshb.ru/', target: targetBlank ? '_blank' : '_self', children: [jsx(SVG, { className: `${SVG_COLOR[bgColor]} w-10`, viewBox: "0 0 40 45", paths: LOGO_PATHS.map((d) => ({ d })) }), jsx("span", { className: `${TEXT_COLOR[bgColor]} text-base font-medium ml-2.5`, children: children || 'Россельхозбанк' })] }));
806
808
  });
807
809
 
808
810
  const SearchBar = JSX(({ className, context }) => {
@@ -846,6 +848,11 @@
846
848
  });
847
849
  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}` })));
848
850
 
851
+ const cmp = (a) => (b) => a?.href === b?.href;
852
+ const substitute = (items, substitution) => (items || []).map((_) => substitution?.find(cmp(_)) || _);
853
+ const subtract = (minuend, subtrahend) => (minuend || []).filter((_) => !subtrahend?.find(cmp(_)));
854
+ const mergeTopItems = (left, right) => substitute(left, right).concat(subtract(right, left));
855
+
849
856
  function useSitemap(useAsyncData) {
850
857
  const { data } = useAsyncData(sitemapURL(), fetchSitemap);
851
858
  return data || {};
@@ -858,13 +865,6 @@
858
865
  return `/wcms-resources/${projectSettings.SITEMAP || 'sitemap'}.json`;
859
866
  }
860
867
 
861
- const cmp = (a) => (b) => a?.href === b?.href;
862
- const substitute = (items, substitution) => (items || []).map((_) => substitution?.find(cmp(_)) || _);
863
- const subtract = (minuend, subtrahend) => (minuend || []).filter((_) => !subtrahend?.find(cmp(_)));
864
- function mergeTopItems(left, right) {
865
- return substitute(left, right).concat(subtract(right, left));
866
- }
867
-
868
868
  const Sitemap = JSX(({ className, items, context }) => {
869
869
  const sitemap = useSitemap(context.useAsyncData);
870
870
  const mergedItems = mergeTopItems(sitemap.topItems, items);
@@ -965,45 +965,95 @@
965
965
 
966
966
  const Gallery$1 = JSX((props) => jsx(GalleryInner, { ...props, version: "normal" }));
967
967
 
968
- const HeaderItem = JSX(({ className, text, href, target, active, onClick, children }) => {
969
- const textStyle = active ? 'text-primary-main' : 'text-primary-text hover:text-primary-main';
970
- return (jsxs("a", { className: `relative inline-block bg-transparent text-center no-underline ${className || ''}`, href: href, target: target, onClick: onClick, children: [jsx("span", { className: `font-sans font-normal text-base ${textStyle}`, children: text || children }), active ? (jsx("div", { className: "absolute left-0 -bottom-2 w-full h-[2px] bg-primary-main" })) : null] }));
971
- });
968
+ const maxBy = (discriminator) => (list) => list.reduceRight((a, b) => (discriminator(a) > discriminator(b) ? a : b));
972
969
 
973
- const TopItem = JSX(({ className, text, href, target, active, flat, onClick, children, ariaLabel }) => {
974
- const linkStyle = active ? 'border-primary-main rounded-md' : 'border-transparent';
975
- const textStyle = active
976
- ? 'text-primary-main'
977
- : `${flat ? 'text-primary-text' : 'text-secondary-text'} hover:text-primary-main`;
978
- return (jsx("a", { className: `inline-block border border-solid bg-transparent text-center no-underline ${flat ? '' : 'px-4 py-2'} ${linkStyle} ${className || ''}`, href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": ariaLabel, children: jsx("span", { className: `font-sans font-normal text-sm ${textStyle}`, children: text || children }) }));
979
- });
970
+ const isHrefActive = (href, router, cmp = (href, baseHref) => baseHref.startsWith(href)) => {
971
+ return cmp(withoutQuery(href), withoutMobilePath(withoutQuery(isURL(href) ? router.href : router.pathname)));
972
+ };
980
973
 
981
- 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 })));
974
+ const isSubItemActive = (router) => (subItem) => isHrefActive(subItem.href, router);
982
975
 
983
- const HeaderSecondaryMenu = JSX(({ context, className, defaultLocation = '' }) => {
984
- const [city, getCity] = context.useGeolocation(defaultLocation);
985
- 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 }), 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" }), jsx(HeaderSecondaryMenuButton, { className: "mr-5 text-primary-text hover:text-primary-main", ariaLabel: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443", children: jsx(Icon, { name: "LoupeIcon", "aria-hidden": "true", className: "h-full", asSVG: true }) }), jsx(HeaderSecondaryMenuButton, { className: "mr-5 text-primary-text hover:text-primary-main", ariaLabel: "\u041F\u0440\u043E\u0444\u0438\u043B\u044C", children: jsx(Icon, { name: "ProfileIcon", "aria-hidden": "true", className: "h-full", asSVG: true }) }), jsx(HeaderSecondaryMenuButton, { className: "min-w-[32px] min-h-[32px] fill-secondary-light hover:fill-secondary-hover", ariaLabel: "\u0414\u043E\u043F\u043E\u043B\u043D\u0438\u0442\u0435\u043B\u044C\u043D\u044B\u0435 \u0441\u0441\u044B\u043B\u043A\u0438", children: jsx(Icon, { name: "GridIcon", "aria-hidden": "true", className: "h-full", asSVG: true }) })] }));
986
- });
976
+ const findActiveSubItem = (router) => (items = []) => {
977
+ const possibleActiveSubItems = items?.filter(isSubItemActive(router));
978
+ const activeSubItem = possibleActiveSubItems?.length
979
+ ? maxBy((_) => _.href?.length || 0)(possibleActiveSubItems) // More specific item with max length
980
+ : null;
981
+ return activeSubItem;
982
+ };
987
983
 
988
- function isSubItemActive(router) {
989
- return (subItem) => isHrefActive(subItem.href, router);
990
- }
984
+ const isTopItemActive = (router) => (topItem) => topItem.items?.some(isSubItemActive(router)) || isHrefActive(topItem.href, router);
991
985
 
992
- function isTopItemActive(router) {
993
- return (topItem) => isHrefActive(topItem.href, router, (topItemHref, baseHref) => baseHref.startsWith(topItemHref));
994
- }
986
+ const TEXT_CLASSES$1 = 'font-sans font-normal text-base';
987
+ const BORDER_CLASSES = 'absolute left-0 -bottom-2 w-full h-[2px]';
988
+ 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$1(bgColor, active), children: text || children }), active ? jsx("div", { className: getBorderClasses(bgColor, active) }) : null] })));
989
+ const getTextClasses$1 = (bgColor, active) => {
990
+ let classes = 'text-white';
991
+ if (bgColor === 'bg-white') {
992
+ classes = active ? 'text-primary-main' : 'text-primary-text hover:text-primary-main';
993
+ }
994
+ return `${classes} ${TEXT_CLASSES$1}`;
995
+ };
996
+ const getBorderClasses = (bgColor, active) => {
997
+ if (!active) {
998
+ return BORDER_CLASSES;
999
+ }
1000
+ return `${bgColor === 'bg-white' ? bgColor : 'bg-primary-main'} ${BORDER_CLASSES}`;
1001
+ };
995
1002
 
996
- const Header = JSX(({ className, defaultLocation, context, topItems }) => {
1003
+ const TEXT_CLASSES = 'font-sans font-normal text-sm';
1004
+ const LINK_CLASSES = 'inline-block border border-solid bg-transparent text-center no-underline';
1005
+ const TopItem = JSX(({ className = '', text, href, target, active, flat, onClick, children, ariaLabel, bgColor = 'bg-white', }) => (jsx("a", { className: `${getLinkClasses(bgColor, active, flat)} ${className}`, href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": ariaLabel, children: jsx("span", { className: getTextClasses(bgColor, active, flat), children: text || children }) })));
1006
+ const getLinkClasses = (bgColor, active, flat) => {
1007
+ let classes = 'border-transparent';
1008
+ if (active) {
1009
+ classes = `rounded-md ${bgColor === 'bg-white' ? 'border-primary-main' : 'border-white'}`;
1010
+ }
1011
+ return `${classes} ${LINK_CLASSES} ${flat ? '' : 'px-4 py-2'}`;
1012
+ };
1013
+ const getTextClasses = (bgColor, active, flat) => {
1014
+ let classes = 'text-white';
1015
+ if (bgColor === 'bg-white') {
1016
+ classes = active
1017
+ ? 'text-primary-main'
1018
+ : `${flat ? 'text-primary-text' : 'text-secondary-text'} hover:text-primary-main`;
1019
+ }
1020
+ return `${classes} ${TEXT_CLASSES}`;
1021
+ };
1022
+
1023
+ 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 })));
1024
+
1025
+ const COLORS_MAP = {
1026
+ 'bg-white': 'text-primary-text hover:text-primary-main',
1027
+ transparent: 'text-white',
1028
+ };
1029
+ const DOP_LINKS_COLORS_MAP = {
1030
+ 'bg-white': 'text-secondary-light hover:text-secondary-hover',
1031
+ transparent: 'text-white',
1032
+ };
1033
+ const DOP_LINKS_ICON_NAME_MAP = {
1034
+ 'bg-white': 'GridIcon',
1035
+ transparent: 'GridIconWhite',
1036
+ };
1037
+ const HeaderSecondaryMenu = JSX(({ context, className, defaultLocation = '', bgColor = 'bg-white' }) => {
1038
+ const [city, getCity] = context.useGeolocation(defaultLocation);
1039
+ 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(Icon, { name: "LoupeIcon", className: "h-full", asSVG: true }) }), jsx(HeaderSecondaryMenuButton, { className: `mr-5 ${COLORS_MAP[bgColor]}`, ariaLabel: "\u041F\u0440\u043E\u0444\u0438\u043B\u044C", children: jsx(Icon, { name: "ProfileIcon", className: "h-full", asSVG: true }) }), 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(Icon, { name: DOP_LINKS_ICON_NAME_MAP[bgColor], className: "h-full", asSVG: true }) })] }));
1040
+ });
1041
+
1042
+ const BORDER_COLORS = {
1043
+ 'bg-white': 'bg-main-divider',
1044
+ transparent: 'bg-main-divider opacity-30',
1045
+ };
1046
+ const Header = JSX(({ className, defaultLocation, bgColor = 'bg-white', context, topItems }) => {
997
1047
  const router = context.useRouter();
998
1048
  const sitemap = useSitemap(context.useAsyncData);
999
1049
  const { handlerDecorator } = context;
1000
1050
  const mergedItems = mergeTopItems(sitemap.topItems, topItems);
1001
1051
  const activeTopItem = mergedItems.find(isTopItemActive(router));
1002
1052
  const subItems = activeTopItem?.items;
1003
- const activeSubItem = subItems?.find(isSubItemActive(router));
1004
- const topMenu = mergedItems.map((_, i) => (jsx(TopItem, { active: _ === activeTopItem, ...useLink({ router, handlerDecorator }, _), ariaLabel: _.text }, String(i))));
1005
- const subMenu = subItems?.map((_) => (jsx(HeaderItem, { className: "mr-8", active: _ === activeSubItem, ...useLink({ router, handlerDecorator }, _) }, _.href)));
1006
- return (jsx("header", { className: `pt-5 pb-8 px-20 bg-white ${className || ''}`, children: jsxs("div", { className: "container", children: [jsxs("div", { className: "flex items-center", children: [jsx(Logo, { className: "mr-8" }), topMenu, jsx(HeaderSecondaryMenu, { context: context, className: "ml-auto", defaultLocation: defaultLocation })] }), jsx("div", { className: "mt-5 h-[1px] bg-main-divider" }), jsx("nav", { className: "mt-5", children: subMenu })] }) }));
1053
+ const activeSubItem = findActiveSubItem(router)(subItems);
1054
+ const topMenu = mergedItems.map((_, i) => (jsx(TopItem, { active: _ === activeTopItem, ...useLink({ router, handlerDecorator }, _), ariaLabel: _.text, bgColor: bgColor }, String(i))));
1055
+ const subMenu = subItems?.map((_) => (jsx(HeaderItem, { className: "mr-8", active: _ === activeSubItem, ...useLink({ router, handlerDecorator }, _), bgColor: bgColor }, _.href)));
1056
+ return (jsx("header", { className: `pt-5 pb-8 px-20 ${bgColor} ${className || ''}`, 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 })] }) }));
1007
1057
  });
1008
1058
 
1009
1059
  const MiniGallery = JSX((props) => (jsx(GalleryInner, { ...props, version: "mini" })));
@@ -1012,6 +1062,17 @@
1012
1062
  return (jsx(Tile, { className: className, context: context, title: title, buttons: buttons, children: jsxs("div", { className: "flex items-center", children: [qr?.src && qr?.href && (jsx("a", { href: qr.href, target: "_blank", children: jsx("img", { src: qr.src, alt: title, title: title, width: "164", height: "164", className: "w-[90px] h-[90px] min-w-[90px] min-h-[90px] bg-secondary-light" }) })), jsx("span", { className: "font-normal text-sm text-secondary-text ml-4", children: "\u041D\u0430\u0432\u0435\u0434\u0438\u0442\u0435 \u043A\u0430\u043C\u0435\u0440\u0443 \u0442\u0435\u043B\u0435\u0444\u043E\u043D\u0430 \u043D\u0430 QR-\u043A\u043E\u0434 \u0438 \u0441\u043A\u0430\u0447\u0430\u0439\u0442\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435" })] }) }));
1013
1063
  });
1014
1064
 
1065
+ const NavigationItem = JSX(({ className, text, onClick, href, target, isActive }) => (jsx("a", { className: `bg-inherit no-underline px-4 py-2.5 cursor-pointer rounded text-sm border border-solid hover:text-primary-main ${className || ''} ${isActive ? 'border-primary-main text-primary-main' : 'border-white text-secondary-text'}`, onClick: onClick, href: href, target: target, children: text })));
1066
+
1067
+ const Navigation = JSX(({ className, context, title, buttons }) => {
1068
+ const router = context.useRouter();
1069
+ const { handlerDecorator } = context;
1070
+ const activeButton = findActiveSubItem(router)(buttons);
1071
+ return (jsxs("section", { className: `font-sans text-primary-text rounded-[40px] flex items-center justify-between ${className || ''}`, children: [jsx("h2", { className: "font-medium text-xl m-0", children: title }), buttons?.length ? (jsx("div", { className: "flex rounded-md overflow-hidden bg-white", children: buttons
1072
+ .filter(({ text }) => text)
1073
+ .map((button, i) => (jsx(NavigationItem, { className: "first:rounded-tl-md first:rounded-bl-md last:rounded-tr-md last:rounded-br-md", isActive: button === activeButton, ...useLink({ router, handlerDecorator }, button) }, String(i)))) })) : null] }));
1074
+ });
1075
+
1015
1076
  const GOLDEN_RATIO = 1.618;
1016
1077
  const Placeholder = JSX(({ className, context, title }) => {
1017
1078
  return (jsx(Tile, { className: className, context: context, title: title, description: "\u0411\u043B\u043E\u043A \u0432 \u0440\u0430\u0437\u0440\u0430\u0431\u043E\u0442\u043A\u0435...", children: jsx("figure", { className: "m-0 min-w-[600px]", children: renderShimmer() }) }));
@@ -1186,6 +1247,7 @@
1186
1247
  TariffsTable,
1187
1248
  TextBlock,
1188
1249
  Tile,
1250
+ Navigation,
1189
1251
  };
1190
1252
 
1191
1253
  const LikeButton = JSX(({ className, onClick, ariaLabel }) => (jsx("button", { type: "button", className: `border-0 w-[36px] bg-inherit cursor-pointer ${className || ''}`, onClick: onClick, "aria-label": ariaLabel, children: renderLikeIcon() })));
@@ -1300,6 +1362,7 @@
1300
1362
  ProductTile,
1301
1363
  TextBlock,
1302
1364
  Tile,
1365
+ Navigation,
1303
1366
  };
1304
1367
 
1305
1368
  exports.Blocks = Blocks;