@redneckz/wildless-cms-uni-blocks 0.14.301 → 0.14.303

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 (201) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +34 -52
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/bundle/components/Footer/FooterLink.d.ts +1 -0
  5. package/bundle/data/FooterData.d.ts +4 -0
  6. package/bundle/data/SitemapData.d.ts +8 -2
  7. package/bundle/hooks/useAspects/aspects/getAspectsWithInclude.d.ts +2 -0
  8. package/bundle/model/LogoType.d.ts +7 -2
  9. package/bundle/ui-kit/LocationDialog/renderRegion.d.ts +2 -1
  10. package/bundle/ui-kit/LocationDialog/renderRegionGroup.d.ts +2 -1
  11. package/bundle/ui-kit/Logo/Logo.d.ts +2 -0
  12. package/dist/components/Footer/Contacts.js +2 -3
  13. package/dist/components/Footer/Contacts.js.map +1 -1
  14. package/dist/components/Footer/Footer.js +4 -2
  15. package/dist/components/Footer/Footer.js.map +1 -1
  16. package/dist/components/Footer/Footer.mobile.js +3 -3
  17. package/dist/components/Footer/Footer.mobile.js.map +1 -1
  18. package/dist/components/Footer/FooterLink.d.ts +1 -0
  19. package/dist/components/Footer/HorizontalNavigation.js +1 -1
  20. package/dist/components/Footer/HorizontalNavigation.js.map +1 -1
  21. package/dist/components/Footer/SocialMedia.js +5 -1
  22. package/dist/components/Footer/SocialMedia.js.map +1 -1
  23. package/dist/components/Footer/TextInformation.js +1 -1
  24. package/dist/components/Footer/TextInformation.js.map +1 -1
  25. package/dist/components/Header/Header.js +3 -1
  26. package/dist/components/Header/Header.js.map +1 -1
  27. package/dist/components/Header/HeaderSecondaryMenu.js +2 -22
  28. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  29. package/dist/data/FooterData.d.ts +4 -0
  30. package/dist/data/SitemapData.d.ts +8 -2
  31. package/dist/hooks/useAspects/aspects/getAspectsWithInclude.d.ts +2 -0
  32. package/dist/hooks/useAspects/aspects/getAspectsWithInclude.js +8 -0
  33. package/dist/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -0
  34. package/dist/model/LogoType.d.ts +7 -2
  35. package/dist/ui-kit/LocationDialog/LocationDialog.js +1 -1
  36. package/dist/ui-kit/LocationDialog/LocationDialog.js.map +1 -1
  37. package/dist/ui-kit/LocationDialog/renderRegion.d.ts +2 -1
  38. package/dist/ui-kit/LocationDialog/renderRegion.js +6 -15
  39. package/dist/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  40. package/dist/ui-kit/LocationDialog/renderRegionGroup.d.ts +2 -1
  41. package/dist/ui-kit/LocationDialog/renderRegionGroup.js +1 -1
  42. package/dist/ui-kit/LocationDialog/renderRegionGroup.js.map +1 -1
  43. package/dist/ui-kit/Logo/Logo.d.ts +2 -0
  44. package/dist/ui-kit/Logo/Logo.js +1 -1
  45. package/dist/ui-kit/Logo/Logo.js.map +1 -1
  46. package/dist/ui-kit/SearchBar/SearchBar.js +2 -2
  47. package/dist/ui-kit/SearchBar/SearchBar.js.map +1 -1
  48. package/dist/ui-kit/Sitemap/Sitemap.js +1 -1
  49. package/dist/ui-kit/Sitemap/Sitemap.js.map +1 -1
  50. package/lib/common.css +1 -1
  51. package/lib/components/Footer/Contacts.js +2 -3
  52. package/lib/components/Footer/Contacts.js.map +1 -1
  53. package/lib/components/Footer/Footer.js +4 -2
  54. package/lib/components/Footer/Footer.js.map +1 -1
  55. package/lib/components/Footer/Footer.mobile.js +3 -3
  56. package/lib/components/Footer/Footer.mobile.js.map +1 -1
  57. package/lib/components/Footer/FooterLink.d.ts +1 -0
  58. package/lib/components/Footer/HorizontalNavigation.js +1 -1
  59. package/lib/components/Footer/HorizontalNavigation.js.map +1 -1
  60. package/lib/components/Footer/SocialMedia.js +5 -1
  61. package/lib/components/Footer/SocialMedia.js.map +1 -1
  62. package/lib/components/Footer/TextInformation.js +1 -1
  63. package/lib/components/Footer/TextInformation.js.map +1 -1
  64. package/lib/components/Header/Header.js +3 -1
  65. package/lib/components/Header/Header.js.map +1 -1
  66. package/lib/components/Header/HeaderSecondaryMenu.js +2 -22
  67. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  68. package/lib/data/FooterData.d.ts +4 -0
  69. package/lib/data/SitemapData.d.ts +8 -2
  70. package/lib/hooks/useAspects/aspects/getAspectsWithInclude.d.ts +2 -0
  71. package/lib/hooks/useAspects/aspects/getAspectsWithInclude.js +5 -0
  72. package/lib/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -0
  73. package/lib/model/LogoType.d.ts +7 -2
  74. package/lib/ui-kit/LocationDialog/LocationDialog.js +1 -1
  75. package/lib/ui-kit/LocationDialog/LocationDialog.js.map +1 -1
  76. package/lib/ui-kit/LocationDialog/renderRegion.d.ts +2 -1
  77. package/lib/ui-kit/LocationDialog/renderRegion.js +6 -15
  78. package/lib/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  79. package/lib/ui-kit/LocationDialog/renderRegionGroup.d.ts +2 -1
  80. package/lib/ui-kit/LocationDialog/renderRegionGroup.js +1 -1
  81. package/lib/ui-kit/LocationDialog/renderRegionGroup.js.map +1 -1
  82. package/lib/ui-kit/Logo/Logo.d.ts +2 -0
  83. package/lib/ui-kit/Logo/Logo.js +1 -1
  84. package/lib/ui-kit/Logo/Logo.js.map +1 -1
  85. package/lib/ui-kit/SearchBar/SearchBar.js +2 -2
  86. package/lib/ui-kit/SearchBar/SearchBar.js.map +1 -1
  87. package/lib/ui-kit/Sitemap/Sitemap.js +1 -1
  88. package/lib/ui-kit/Sitemap/Sitemap.js.map +1 -1
  89. package/mobile/bundle/bundle.umd.js +24 -25
  90. package/mobile/bundle/bundle.umd.min.js +1 -1
  91. package/mobile/bundle/components/Footer/FooterLink.d.ts +1 -0
  92. package/mobile/bundle/data/FooterData.d.ts +4 -0
  93. package/mobile/bundle/data/SitemapData.d.ts +8 -2
  94. package/mobile/bundle/hooks/useAspects/aspects/getAspectsWithInclude.d.ts +2 -0
  95. package/mobile/bundle/model/LogoType.d.ts +7 -2
  96. package/mobile/bundle/ui-kit/LocationDialog/renderRegion.d.ts +2 -1
  97. package/mobile/bundle/ui-kit/LocationDialog/renderRegionGroup.d.ts +2 -1
  98. package/mobile/bundle/ui-kit/Logo/Logo.d.ts +2 -0
  99. package/mobile/dist/components/Footer/Contacts.js +2 -3
  100. package/mobile/dist/components/Footer/Contacts.js.map +1 -1
  101. package/mobile/dist/components/Footer/Footer.js +3 -3
  102. package/mobile/dist/components/Footer/Footer.js.map +1 -1
  103. package/mobile/dist/components/Footer/FooterLink.d.ts +1 -0
  104. package/mobile/dist/components/Footer/SocialMedia.js +5 -1
  105. package/mobile/dist/components/Footer/SocialMedia.js.map +1 -1
  106. package/mobile/dist/components/Footer/TextInformation.js +1 -1
  107. package/mobile/dist/components/Footer/TextInformation.js.map +1 -1
  108. package/mobile/dist/components/Header/HeaderSecondaryMenu.js +2 -22
  109. package/mobile/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  110. package/mobile/dist/data/FooterData.d.ts +4 -0
  111. package/mobile/dist/data/SitemapData.d.ts +8 -2
  112. package/mobile/dist/hooks/useAspects/aspects/getAspectsWithInclude.d.ts +2 -0
  113. package/mobile/dist/hooks/useAspects/aspects/getAspectsWithInclude.js +8 -0
  114. package/mobile/dist/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -0
  115. package/mobile/dist/model/LogoType.d.ts +7 -2
  116. package/mobile/dist/ui-kit/LocationDialog/LocationDialog.js +1 -1
  117. package/mobile/dist/ui-kit/LocationDialog/LocationDialog.js.map +1 -1
  118. package/mobile/dist/ui-kit/LocationDialog/renderRegion.d.ts +2 -1
  119. package/mobile/dist/ui-kit/LocationDialog/renderRegion.js +6 -15
  120. package/mobile/dist/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  121. package/mobile/dist/ui-kit/LocationDialog/renderRegionGroup.d.ts +2 -1
  122. package/mobile/dist/ui-kit/LocationDialog/renderRegionGroup.js +1 -1
  123. package/mobile/dist/ui-kit/LocationDialog/renderRegionGroup.js.map +1 -1
  124. package/mobile/dist/ui-kit/Logo/Logo.d.ts +2 -0
  125. package/mobile/dist/ui-kit/Logo/Logo.js +1 -1
  126. package/mobile/dist/ui-kit/Logo/Logo.js.map +1 -1
  127. package/mobile/dist/ui-kit/SearchBar/SearchBar.js +2 -2
  128. package/mobile/dist/ui-kit/SearchBar/SearchBar.js.map +1 -1
  129. package/mobile/dist/ui-kit/Sitemap/Sitemap.js +1 -1
  130. package/mobile/dist/ui-kit/Sitemap/Sitemap.js.map +1 -1
  131. package/mobile/lib/common.css +1 -1
  132. package/mobile/lib/components/Footer/Contacts.js +2 -3
  133. package/mobile/lib/components/Footer/Contacts.js.map +1 -1
  134. package/mobile/lib/components/Footer/Footer.js +3 -3
  135. package/mobile/lib/components/Footer/Footer.js.map +1 -1
  136. package/mobile/lib/components/Footer/FooterLink.d.ts +1 -0
  137. package/mobile/lib/components/Footer/SocialMedia.js +5 -1
  138. package/mobile/lib/components/Footer/SocialMedia.js.map +1 -1
  139. package/mobile/lib/components/Footer/TextInformation.js +1 -1
  140. package/mobile/lib/components/Footer/TextInformation.js.map +1 -1
  141. package/mobile/lib/components/Header/HeaderSecondaryMenu.js +2 -22
  142. package/mobile/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  143. package/mobile/lib/data/FooterData.d.ts +4 -0
  144. package/mobile/lib/data/SitemapData.d.ts +8 -2
  145. package/mobile/lib/hooks/useAspects/aspects/getAspectsWithInclude.d.ts +2 -0
  146. package/mobile/lib/hooks/useAspects/aspects/getAspectsWithInclude.js +5 -0
  147. package/mobile/lib/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -0
  148. package/mobile/lib/model/LogoType.d.ts +7 -2
  149. package/mobile/lib/ui-kit/LocationDialog/LocationDialog.js +1 -1
  150. package/mobile/lib/ui-kit/LocationDialog/LocationDialog.js.map +1 -1
  151. package/mobile/lib/ui-kit/LocationDialog/renderRegion.d.ts +2 -1
  152. package/mobile/lib/ui-kit/LocationDialog/renderRegion.js +6 -15
  153. package/mobile/lib/ui-kit/LocationDialog/renderRegion.js.map +1 -1
  154. package/mobile/lib/ui-kit/LocationDialog/renderRegionGroup.d.ts +2 -1
  155. package/mobile/lib/ui-kit/LocationDialog/renderRegionGroup.js +1 -1
  156. package/mobile/lib/ui-kit/LocationDialog/renderRegionGroup.js.map +1 -1
  157. package/mobile/lib/ui-kit/Logo/Logo.d.ts +2 -0
  158. package/mobile/lib/ui-kit/Logo/Logo.js +1 -1
  159. package/mobile/lib/ui-kit/Logo/Logo.js.map +1 -1
  160. package/mobile/lib/ui-kit/SearchBar/SearchBar.js +2 -2
  161. package/mobile/lib/ui-kit/SearchBar/SearchBar.js.map +1 -1
  162. package/mobile/lib/ui-kit/Sitemap/Sitemap.js +1 -1
  163. package/mobile/lib/ui-kit/Sitemap/Sitemap.js.map +1 -1
  164. package/mobile/src/components/ApplicationForm/ApplicationForm.ui.json +7 -0
  165. package/mobile/src/components/Footer/Contacts.tsx +4 -15
  166. package/mobile/src/components/Footer/Footer.tsx +6 -5
  167. package/mobile/src/components/Footer/FooterLink.ts +1 -0
  168. package/mobile/src/components/Footer/SocialMedia.tsx +7 -1
  169. package/mobile/src/components/Footer/TextInformation.tsx +2 -2
  170. package/mobile/src/components/Header/HeaderSecondaryMenu.tsx +3 -24
  171. package/mobile/src/data/FooterData.ts +4 -0
  172. package/mobile/src/data/SitemapData.ts +6 -2
  173. package/mobile/src/hooks/useAspects/aspects/getAspectsWithInclude.tsx +8 -0
  174. package/mobile/src/model/LogoType.ts +8 -2
  175. package/mobile/src/ui-kit/LocationDialog/LocationDialog.tsx +4 -2
  176. package/mobile/src/ui-kit/LocationDialog/renderRegion.tsx +22 -30
  177. package/mobile/src/ui-kit/LocationDialog/renderRegionGroup.tsx +3 -2
  178. package/mobile/src/ui-kit/Logo/Logo.tsx +4 -1
  179. package/mobile/src/ui-kit/SearchBar/SearchBar.tsx +6 -2
  180. package/mobile/src/ui-kit/Sitemap/Sitemap.tsx +1 -1
  181. package/package.json +1 -1
  182. package/src/components/ApplicationForm/ApplicationForm.ui.json +7 -0
  183. package/src/components/Footer/Contacts.tsx +4 -15
  184. package/src/components/Footer/Footer.mobile.tsx +6 -5
  185. package/src/components/Footer/Footer.tsx +35 -14
  186. package/src/components/Footer/FooterLink.ts +1 -0
  187. package/src/components/Footer/HorizontalNavigation.tsx +1 -1
  188. package/src/components/Footer/SocialMedia.tsx +7 -1
  189. package/src/components/Footer/TextInformation.tsx +2 -2
  190. package/src/components/Header/Header.tsx +10 -7
  191. package/src/components/Header/HeaderSecondaryMenu.tsx +3 -24
  192. package/src/data/FooterData.ts +4 -0
  193. package/src/data/SitemapData.ts +6 -2
  194. package/src/hooks/useAspects/aspects/getAspectsWithInclude.tsx +8 -0
  195. package/src/model/LogoType.ts +8 -2
  196. package/src/ui-kit/LocationDialog/LocationDialog.tsx +4 -2
  197. package/src/ui-kit/LocationDialog/renderRegion.tsx +22 -30
  198. package/src/ui-kit/LocationDialog/renderRegionGroup.tsx +3 -2
  199. package/src/ui-kit/Logo/Logo.tsx +4 -1
  200. package/src/ui-kit/SearchBar/SearchBar.tsx +6 -2
  201. package/src/ui-kit/Sitemap/Sitemap.tsx +1 -1
@@ -1,3 +1,4 @@
1
+ import { type AspectsDef } from '../../model/AspectsProps';
1
2
  import { type LogoType } from '../../model/LogoType';
2
3
  export interface LogoProps {
3
4
  className: string;
@@ -6,5 +7,6 @@ export interface LogoProps {
6
7
  bgColor?: string;
7
8
  showTitle?: boolean;
8
9
  logo?: LogoType;
10
+ data?: AspectsDef[];
9
11
  }
10
12
  export declare const Logo: import("@redneckz/uni-jsx").UNIComponent<Partial<LogoProps>, any, any>;
@@ -10,7 +10,7 @@ const TEXT_COLOR = {
10
10
  'bg-white': 'text-primary-text',
11
11
  transparent: 'text-white',
12
12
  };
13
- export const Logo = JSX(({ className, href = '/', logo, children, targetBlank, bgColor = 'bg-white', showTitle = true, }) => (_jsxs("a", { className: style('inline-flex items-center font-sans no-underline', className), href: href, target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title ?? 'Россельхозбанк', ...getAspectsAttributes(logo?.data), children: [renderImage(bgColor, logo?.image, ICON_SIZE), showTitle
13
+ export const Logo = JSX(({ className, href = '/', logo, children, targetBlank, bgColor = 'bg-white', showTitle = true, data, }) => (_jsxs("a", { className: style('inline-flex items-center font-sans no-underline', className), href: href, target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title ?? 'Россельхозбанк', ...getAspectsAttributes(data), children: [renderImage(bgColor, logo?.image, ICON_SIZE), showTitle
14
14
  ? children ?? (_jsx("div", { className: "ml-s", children: _jsx(Text, { font: "font-medium", color: TEXT_COLOR[bgColor], size: logoTitleSizeStyle, children: logo?.title ?? 'Россельхозбанк' }) }))
15
15
  : null] })));
16
16
  //# sourceMappingURL=Logo.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Logo.js","sourceRoot":"","sources":["../../../src/ui-kit/Logo/Logo.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEpC,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAW5C,MAAM,UAAU,GAAsC;IACpD,UAAU,EAAE,mBAAmB;IAC/B,WAAW,EAAE,YAAY;CAC1B,CAAC;AAEF,MAAM,CAAC,MAAM,IAAI,GAAG,GAAG,CACrB,CAAC,EACC,SAAS,EACT,IAAI,GAAG,GAAG,EACV,IAAI,EACJ,QAAQ,EACR,WAAW,EACX,OAAO,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rB,CAAC,EACC,SAAS,EACT,IAAI,GAAG,GAAG,EACV,IAAI,EACJ,QAAQ,EACR,WAAW,EACX,OAAO,GAAG,UAAU,EACpB,SAAS,GAAG,IAAI,EAChB,IAAI,GACL,EAAE,EAAE,CAAC,CACJ,aACE,SAAS,EAAE,KAAK,CAAC,iDAAiD,EAAE,SAAS,CAAC,EAC9E,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,OAAO,gBAC5B,IAAI,EAAE,KAAK,IAAI,gBAAgB,KAEvC,oBAAoB,CAAC,IAAI,CAAC,aAE7B,WAAW,CAAC,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,SAAS,CAAC,EAC5C,SAAS;YACR,CAAC,CAAC,QAAQ,IAAI,CACV,cAAK,SAAS,EAAC,MAAM,YACnB,KAAC,IAAI,IAAC,IAAI,EAAC,aAAa,EAAC,KAAK,EAAE,UAAU,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE,kBAAkB,YAC1E,IAAI,EAAE,KAAK,IAAI,gBAAgB,GAC3B,GACH,CACP;YACH,CAAC,CAAC,IAAI,IACN,CACL,CACF,CAAC"}
@@ -6,7 +6,7 @@ import { CloseButton } from '../DialogManager/CloseButton.js';
6
6
  import { SearchInput } from '../SearchDialog/SearchInput.js';
7
7
  import { useSearchDialog } from '../SearchDialog/useSearchDialog.js';
8
8
  const MIN_QUERY_LEN = 3;
9
- export const SearchBar = JSX(({ className, ...rest }) => {
9
+ export const SearchBar = JSX(({ className, search, ...rest }) => {
10
10
  const [value, setValue] = useState('');
11
11
  const resetQueryOnDialogClose = useCallback(() => setValue(''), []);
12
12
  const searchDialog = useSearchDialog(rest);
@@ -16,7 +16,7 @@ export const SearchBar = JSX(({ className, ...rest }) => {
16
16
  searchDialog.open({ initialQuery: _ }, { onClose: resetQueryOnDialogClose });
17
17
  }
18
18
  }, [resetQueryOnDialogClose, searchDialog]);
19
- return (_jsxs("div", { className: style('relative', className), role: "search", children: [_jsx(SearchInput, { value: value, onChange: handleInitialInputChange }), _jsx(CloseButton, { className: "absolute top-0 right-0 sm:hidden", onClose: resetQueryOnDialogClose })] }));
19
+ return (_jsxs("div", { className: style('relative', className), role: "search", children: [_jsx(SearchInput, { value: value, placeholder: search?.placeholder, onChange: handleInitialInputChange }), _jsx(CloseButton, { className: "absolute top-0 right-0 sm:hidden", onClose: resetQueryOnDialogClose })] }));
20
20
  });
21
21
  const isQueryLongEnough = (_) => _ && _.length >= MIN_QUERY_LEN;
22
22
  //# sourceMappingURL=SearchBar.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchBar.js","sourceRoot":"","sources":["../../../src/ui-kit/SearchBar/SearchBar.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAEpE,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAMlE,MAAM,aAAa,GAAG,CAAC,CAAC;AAExB,MAAM,CAAC,MAAM,SAAS,GAAG,GAAG,CAAiB,CAAC,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE;IACtE,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC;IAEvC,MAAM,uBAAuB,GAAG,WAAW,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;IACpE,MAAM,YAAY,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;IAE3C,MAAM,wBAAwB,GAAG,WAAW,CAC1C,CAAC,CAAS,EAA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C9E,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC;IAEvC,MAAM,uBAAuB,GAAG,WAAW,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;IACpE,MAAM,YAAY,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;IAE3C,MAAM,wBAAwB,GAAG,WAAW,CAC1C,CAAC,CAAS,EAAE,EAAE;QACZ,QAAQ,CAAC,CAAC,CAAC,CAAC;QACZ,IAAI,iBAAiB,CAAC,CAAC,CAAC,EAAE;YACxB,YAAY,CAAC,IAAI,CAAC,EAAE,YAAY,EAAE,CAAC,EAAE,EAAE,EAAE,OAAO,EAAE,uBAAuB,EAAE,CAAC,CAAC;SAC9E;IACH,CAAC,EACD,CAAC,uBAAuB,EAAE,YAAY,CAAC,CACxC,CAAC;IAEF,OAAO,CACL,eAAK,SAAS,EAAE,KAAK,CAAC,UAAU,EAAE,SAAS,CAAC,EAAE,IAAI,EAAC,QAAQ,aACzD,KAAC,WAAW,IACV,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,MAAM,EAAE,WAAW,EAChC,QAAQ,EAAE,wBAAwB,GAClC,EACF,KAAC,WAAW,IAAC,SAAS,EAAC,kCAAkC,EAAC,OAAO,EAAE,uBAAuB,GAAI,IAC1F,CACP,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,iBAAiB,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,IAAI,aAAa,CAAC"}
@@ -12,7 +12,7 @@ export const Sitemap = JSX(({ className, topItems }) => {
12
12
  const renderColumn = (menuItem, index) => {
13
13
  const { text, items = [], href, target, onClick } = menuItem;
14
14
  const visibleSubItems = items.filter(isVisibleItem);
15
- return (_jsxs("div", { className: "flex flex-col gap-s w-1/4", children: [_jsx("a", { className: "leading-5 text-l text-primary-text hover:text-primary-main no-underline", href: href, target: target || '_self', onClick: onClick, children: text || `Раздел ${index}` }), visibleSubItems.map((_, i) => (_jsx(ColumnItem, { ..._, basePath: appendSlash(href), index: i }, String(i))))] }, String(index)));
15
+ return (_jsxs("div", { className: "flex flex-col gap-s @sm:w-full @md:w-1/4", children: [_jsx("a", { className: "leading-5 text-l text-primary-text hover:text-primary-main no-underline", href: href, target: target || '_self', onClick: onClick, children: text || `Раздел ${index}` }), visibleSubItems.map((_, i) => (_jsx(ColumnItem, { ..._, basePath: appendSlash(href), index: i }, String(i))))] }, String(index)));
16
16
  };
17
17
  const ColumnItem = JSX(({ text, index, basePath, ...rest }) => {
18
18
  const isAnotherPortal = projectSettings.BASE_PATH && basePath ? !projectSettings.BASE_PATH.startsWith(basePath) : false;
@@ -1 +1 @@
1
- {"version":3,"file":"Sitemap.js","sourceRoot":"","sources":["../../../src/ui-kit/Sitemap/Sitemap.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,MAAM,gBAAgB,GAAG,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;AAO3C,MAAM,CAAC,MAAM,OAAO,GAAG,GAAG,CAAe,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,EAAE;IACnE,MAAM,IAAI,GAAG,OAAO,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;IAEzC,OAAO,CACL,cAAK,SAAS,EAAE,KAAK,CAAC,kCAAkC,EAAE,SAAS,CAAC,YACjE,QAAQ,EAAE,MAAM,CAAC,aAAa,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,GAAG,CAA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E,EAC5E,uDAAuD,CACxD,EACD,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,IAAI,OAAO,EACzB,OAAO,EAAE,OAAO,YAEf,IAAI,IAAI,UAAU,KAAK,EAAE,GACxB,CACL,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,aAAa,GAAG,CAAC,CAAmB,EAAE,EAAE,CAC5C,CAAC,CAAC,CAAC,WAAW,IAAI,gBAAgB,CAAC,QAAQ,CAAC,CAAC,CAAC,WAAW,CAAC,WAAW,EAAE,CAAC,CAAC"}
@@ -7,6 +7,13 @@
7
7
  "sourceBookPath": "/wcms-resources/products"
8
8
  }
9
9
  }
10
+ },
11
+ "data": {
12
+ "items": {
13
+ "aspectName": {
14
+ "ui:widget": "hidden"
15
+ }
16
+ }
10
17
  }
11
18
  }
12
19
  }
@@ -1,6 +1,5 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import { type ContactGroup, type ContactInfo } from '../../data/FooterData';
3
- import { LinkButton } from '../../ui-kit/LinkButton/LinkButton';
4
3
  import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
5
4
  import { Text } from '../../ui-kit/Text/Text';
6
5
 
@@ -9,22 +8,12 @@ export interface ContactsProps {
9
8
  items?: ContactGroup[];
10
9
  }
11
10
 
12
- export const Contacts = JSX<ContactsProps>(({ className = '', items }) => (
13
- <div className={className}>
14
- {items?.length ? items.map(renderContactsGroup) : null}
15
- <LinkButton
16
- version="primary"
17
- className="w-full"
18
- href="https://www.rshb.ru/natural/feedback/question"
19
- target="_blank"
20
- ariaLabel="Обратная связь"
21
- text="Обратная связь"
22
- />
23
- </div>
24
- ));
11
+ export const Contacts = JSX<ContactsProps>(({ className = '', items = [] }) =>
12
+ items?.length ? <div className={className}>{items.map(renderContactsGroup)}</div> : null,
13
+ );
25
14
 
26
15
  const renderContactsGroup = (item: ContactGroup, i: number) => (
27
- <div className="mb-m space-y-m" key={String(i)}>
16
+ <div className="space-y-m" key={String(i)}>
28
17
  <div>
29
18
  <Text size="text-l" font="font-medium">
30
19
  {item?.title}
@@ -1,7 +1,7 @@
1
1
  import { useCallback } from '@redneckz/uni-jsx/lib/hooks';
2
2
  import { type TopMenuItemProps } from '../../data/SitemapData';
3
3
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
4
- import { Text } from '../../ui-kit/Text/Text';
4
+ import { LinkButton } from '../../ui-kit/LinkButton/LinkButton';
5
5
  import { UniBlock } from '../../UniBlock/UniBlock';
6
6
  import { appendSlash } from '../../utils/appendSlash';
7
7
  import { mapCookie } from '../../utils/mapCookie';
@@ -24,6 +24,8 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
24
24
  mobileApps,
25
25
  horizontalNavigationTitle,
26
26
  documents,
27
+ feedbackButton,
28
+ license,
27
29
  } = footer || {};
28
30
 
29
31
  const handleOnClick = useCallback(() => {
@@ -37,6 +39,7 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
37
39
  {renderTopItems(topItems)}
38
40
  </div>
39
41
  <Contacts className="overflow-hidden" items={contacts} />
42
+ {feedbackButton ? <LinkButton className="w-full mt-xs" {...feedbackButton} /> : null}
40
43
  <div className="mt-xl">
41
44
  <SocialMedia className="mb-xl" media={socialMedia} stretched={true}>
42
45
  Соцсети
@@ -48,9 +51,7 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
48
51
  stretched={true}
49
52
  showButtonText={false}
50
53
  />
51
- <Text size="text-s" font="font-light" color="text-secondary-text">
52
- Мобильное приложение
53
- </Text>
54
+ Мобильное приложение
54
55
  </div>
55
56
  </div>
56
57
  <div className="py-lg border-t border-main-divider">
@@ -66,7 +67,7 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
66
67
  title={horizontalNavigationTitle}
67
68
  links={relatedEnterprises}
68
69
  />
69
- <TextInformation links={documents} />
70
+ <TextInformation links={documents} license={license} />
70
71
  </BlockWrapper>
71
72
  );
72
73
  });
@@ -3,4 +3,5 @@ import { type LinkProps } from '../../model/LinkProps';
3
3
  export interface FooterLink {
4
4
  className?: string;
5
5
  links?: LinkProps[];
6
+ license?: string;
6
7
  }
@@ -18,6 +18,10 @@ export interface SocialMediaProps {
18
18
 
19
19
  export const SocialMedia = JSX<SocialMediaProps>(
20
20
  ({ className = '', media, showButtonText, stretched, version = 'white', children }) => {
21
+ if (!media?.length) {
22
+ return null;
23
+ }
24
+
21
25
  const [hasText, setHasText] = useState<boolean | undefined>();
22
26
  const buttons: LinkButtonContent[] | undefined = media?.map((_) => {
23
27
  const { href, icon, text } = _;
@@ -40,7 +44,7 @@ export const SocialMedia = JSX<SocialMediaProps>(
40
44
  const buttonClassName = style(
41
45
  'border border-solid hover:border-transparent group-data-primary:border-main-divider border-main-divider group-data-gray:border-green group/media',
42
46
  showButtonText && hasText ? '' : 'basis-auto',
43
- stretched ? 'flex-1 justify-center' : '',
47
+ getStretchedStyle(stretched),
44
48
  );
45
49
 
46
50
  return (
@@ -60,3 +64,5 @@ export const SocialMedia = JSX<SocialMediaProps>(
60
64
  );
61
65
  },
62
66
  );
67
+
68
+ const getStretchedStyle = (stretched?: boolean) => (stretched ? 'flex-1 justify-center' : '');
@@ -4,11 +4,11 @@ import { style } from '../../utils/style';
4
4
  import { type FooterLink } from './FooterLink';
5
5
  import { TextInformationLink } from './TextInformationLink';
6
6
 
7
- export const TextInformation = JSX<FooterLink>(({ className = '', links }) => (
7
+ export const TextInformation = JSX<FooterLink>(({ className = '', links, license }) => (
8
8
  <div className={style('@container', className)}>
9
9
  <div className="pt-lg">
10
10
  <Text size="text-xs" font="font-light" color="text-secondary-text">
11
- {`\u00a9\u00A02000-${new Date().getFullYear()}\u00A0АО \u00ABРоссельхозбанк\u00BB Генеральная лицензия Банка России \u2116\u00A03349 от\u00A012.08.2015\u00A0г.`}
11
+ {`\u00a9\u00A02000-${new Date().getFullYear()}\u00A0${license}`}
12
12
  </Text>
13
13
  </div>
14
14
  {links?.length ? (
@@ -1,6 +1,7 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import { useCallback } from '@redneckz/uni-jsx/lib/hooks';
3
3
  import { type SitemapData } from '../../data/SitemapData';
4
+ import { getAspectsWithInclude } from '../../hooks/useAspects/aspects/getAspectsWithInclude';
4
5
  import { useLocation } from '../../hooks/useLocation';
5
6
  import { type BlockVersion } from '../../model/BlockVersion';
6
7
  import { type IconVersion } from '../../model/IconVersion';
@@ -10,11 +11,6 @@ import { TopItem } from '../../ui-kit/TopItem/TopItem';
10
11
  import { style } from '../../utils/style';
11
12
  import { HeaderSecondaryMenuButton } from './HeaderSecondaryMenuButton';
12
13
 
13
- const MINDBOX_ASPECT = 'mindboxEvent';
14
- const MINDBOX_CATEGORY = 'header';
15
- const MINDBOX_EVENT_REGION_CLICK = 'headerRegionClick';
16
- const MINDBOX_EVENT_SEARCH_CLICK = 'headerSearchClick';
17
-
18
14
  interface HeaderSecondaryMenuContent extends SitemapData {
19
15
  version?: BlockVersion;
20
16
  }
@@ -42,16 +38,7 @@ export const HeaderSecondaryMenu = JSX<HeaderSecondaryMenuProps>(
42
38
  flat={true}
43
39
  href="#"
44
40
  text={currentLocation?.name}
45
- data={[
46
- {
47
- aspectName: MINDBOX_ASPECT,
48
- params: {
49
- eventAction: MINDBOX_EVENT_REGION_CLICK,
50
- eventCategory: MINDBOX_CATEGORY,
51
- eventValueText: currentLocation?.name ?? '',
52
- },
53
- },
54
- ]}
41
+ data={getAspectsWithInclude(rest?.branches?.dataClick, currentLocation?.name ?? '')}
55
42
  onClick={openLocationDialog}
56
43
  />
57
44
  ) : null}
@@ -60,15 +47,7 @@ export const HeaderSecondaryMenu = JSX<HeaderSecondaryMenuProps>(
60
47
  image={{ icon: 'LoupeIcon', iconVersion }}
61
48
  ariaLabel="Поиск"
62
49
  onClick={openSearchDialog}
63
- data={[
64
- {
65
- aspectName: MINDBOX_ASPECT,
66
- params: {
67
- eventAction: MINDBOX_EVENT_SEARCH_CLICK,
68
- eventCategory: MINDBOX_CATEGORY,
69
- },
70
- },
71
- ]}
50
+ data={rest?.search?.data}
72
51
  />
73
52
  </div>
74
53
  );
@@ -34,5 +34,9 @@ export interface FooterData {
34
34
  contacts?: ContactGroup[];
35
35
  socialMedia?: LinkButtonContent[];
36
36
  mobileApps?: LinkButtonContent[];
37
+ feedbackButton?: LinkButtonContent;
38
+ otherLinks?: LinkProps[];
39
+ isOldVersionButton?: boolean;
40
+ license?: string;
37
41
  horizontalNavigationTitle?: string; // TODO: для мобильной версии
38
42
  }
@@ -1,4 +1,4 @@
1
- import { type AspectsDef } from '../model/AspectsProps';
1
+ import { type AspectsDef, type AspectsProps } from '../model/AspectsProps';
2
2
  import { type LinkProps } from '../model/LinkProps';
3
3
  import { type LogoType } from '../model/LogoType';
4
4
  import { type IconProps, type Picture } from '../model/Picture';
@@ -6,7 +6,6 @@ import { type IconProps, type Picture } from '../model/Picture';
6
6
  export interface SitemapLinkProps extends LinkProps {
7
7
  displayArea?: string;
8
8
  dataHeader?: AspectsDef[];
9
- dataFooter?: AspectsDef[];
10
9
  }
11
10
 
12
11
  /**
@@ -47,6 +46,10 @@ export type BranchesSitemap = {
47
46
  default?: string;
48
47
  /** @title Отображать выбор филиалов */
49
48
  visible?: boolean;
49
+ /** @title Дополнительные атрибуты для слика по региону*/
50
+ dataClick?: AspectsDef[];
51
+ /** @title Дополнительные атрибуты для выбора региона*/
52
+ dataSelect?: AspectsDef[];
50
53
  };
51
54
 
52
55
  export interface SitemapData {
@@ -56,4 +59,5 @@ export interface SitemapData {
56
59
  foreignOffices?: ForeignOfficeProps[];
57
60
  branches?: BranchesSitemap;
58
61
  officesAtms?: LinkProps;
62
+ search?: AspectsProps & { placeholder: string };
59
63
  }
@@ -0,0 +1,8 @@
1
+ import { type AspectsDef } from '../../../model/AspectsProps';
2
+ import { type AspectsAttribute } from '../useAspects';
3
+
4
+ export const getAspectsWithInclude = (data?: AspectsDef[], include?: string): AspectsDef[] =>
5
+ data?.map(({ aspectName, params }: AspectsAttribute) => ({
6
+ aspectName,
7
+ params: aspectName === 'mindboxEvent' ? { ...params, eventValueText: include } : params,
8
+ })) as AspectsDef[];
@@ -1,8 +1,14 @@
1
1
  import { type ImageContent } from '../ui-kit/Img/ImgProps';
2
- import { type AspectsProps } from './AspectsProps';
2
+ import { type AspectsDef } from './AspectsProps';
3
3
  import { type TitleProps } from './HeadlineType';
4
4
 
5
5
  /**
6
6
  * @title Логотип
7
7
  */
8
- export type LogoType = ImageContent & TitleProps & AspectsProps;
8
+ export type LogoType = ImageContent &
9
+ TitleProps & {
10
+ /** @title Дополнительные атрибуты для шапки */
11
+ dataHeader?: AspectsDef[];
12
+ /** @title Дополнительные атрибуты для подвала */
13
+ dataFooter?: AspectsDef[];
14
+ };
@@ -72,11 +72,13 @@ export const LocationDialog = JSX<LocationDialogProps>(({ foreignOffices, branch
72
72
  ({ name }) =>
73
73
  name && jaroWinklerDistance(name.toLowerCase())(query.toLowerCase()) >= 0.8,
74
74
  )
75
- .map(renderRegion(handleChangeLocation))}
75
+ .map(renderRegion(branches?.dataSelect, handleChangeLocation))}
76
76
  </div>
77
77
  ) : (
78
78
  <div className="columns-1 sm:columns-5">
79
- {Array.from(regionsGroupByLetter.entries()).map(renderRegionGroup(handleChangeLocation))}
79
+ {Array.from(regionsGroupByLetter.entries()).map(
80
+ renderRegionGroup(handleChangeLocation, branches?.dataSelect),
81
+ )}
80
82
  </div>
81
83
  )}
82
84
  {renderForeignOffices(foreignOffices)}
@@ -1,34 +1,26 @@
1
+ import { getAspectsWithInclude } from '../../hooks/useAspects/aspects/getAspectsWithInclude';
1
2
  import { type Region } from '../../hooks/useRegions';
3
+ import { type AspectsDef } from '../../model/AspectsProps';
2
4
  import { LinkWrapper } from '../LinkWrapper/LinkWrapper';
3
5
  import { Text } from '../Text/Text';
4
6
 
5
- const MINDBOX_ASPECT = 'mindboxEvent';
6
- const MINDBOX_CATEGORY = 'header';
7
- const MINDBOX_EVENT_REGION_NEW_CLICK = 'headerRegionNewSelect';
8
-
9
- export const renderRegion = (onChangeLocation?: (region: Region) => void) => (region: Region) =>
10
- region.name ? (
11
- <LinkWrapper
12
- key={String(region.id)}
13
- isRemote
14
- href={`/branches/${region.slug}`}
15
- className="mb-xs sm:mb-2xs hover:text-primary-hover"
16
- onClick={() => {
17
- onChangeLocation && onChangeLocation(region);
18
- }}
19
- data={[
20
- {
21
- aspectName: MINDBOX_ASPECT,
22
- params: {
23
- eventAction: MINDBOX_EVENT_REGION_NEW_CLICK,
24
- eventCategory: MINDBOX_CATEGORY,
25
- eventValueText: region.name,
26
- },
27
- },
28
- ]}
29
- >
30
- <Text size="text-l" font="font-light">
31
- {region.name}
32
- </Text>
33
- </LinkWrapper>
34
- ) : null;
7
+ export const renderRegion =
8
+ (data: AspectsDef[] | undefined, onChangeLocation?: (region: Region) => void) =>
9
+ (region: Region) => {
10
+ return region.name ? (
11
+ <LinkWrapper
12
+ key={String(region.id)}
13
+ isRemote
14
+ href={`/branches/${region.slug}`}
15
+ className="mb-xs sm:mb-2xs hover:text-primary-hover"
16
+ onClick={() => {
17
+ onChangeLocation && onChangeLocation(region);
18
+ }}
19
+ data={getAspectsWithInclude(data, region.name)}
20
+ >
21
+ <Text size="text-l" font="font-light">
22
+ {region.name}
23
+ </Text>
24
+ </LinkWrapper>
25
+ ) : null;
26
+ };
@@ -1,15 +1,16 @@
1
1
  import { type Region } from '../../hooks/useRegions';
2
+ import { type AspectsDef } from '../../model/AspectsProps';
2
3
  import { Text } from '../Text/Text';
3
4
  import { renderRegion } from './renderRegion';
4
5
 
5
6
  export const renderRegionGroup =
6
- (onChangeLocation?: (region: Region) => void) =>
7
+ (onChangeLocation?: (region: Region) => void, data?: AspectsDef[]) =>
7
8
  ([letter, regions]: [string, Region[]]) =>
8
9
  (
9
10
  <div key={letter} className="break-inside-avoid mb-2xl w-56">
10
11
  <div className="mb-s">
11
12
  <Text size="text-h6">{letter}</Text>
12
13
  </div>
13
- {regions.map(renderRegion(onChangeLocation))}
14
+ {regions.map(renderRegion(data, onChangeLocation))}
14
15
  </div>
15
16
  );
@@ -1,4 +1,5 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
+ import { type AspectsDef } from '../../model/AspectsProps';
2
3
  import { type BgColorVersion } from '../../model/BgColorVersion';
3
4
  import { type LogoType } from '../../model/LogoType';
4
5
  import { getAspectsAttributes } from '../../utils/dataAttributes';
@@ -16,6 +17,7 @@ export interface LogoProps {
16
17
  bgColor?: string;
17
18
  showTitle?: boolean;
18
19
  logo?: LogoType;
20
+ data?: AspectsDef[];
19
21
  }
20
22
 
21
23
  const TEXT_COLOR: Record<BgColorVersion, TextColor> = {
@@ -32,6 +34,7 @@ export const Logo = JSX<Partial<LogoProps>>(
32
34
  targetBlank,
33
35
  bgColor = 'bg-white',
34
36
  showTitle = true,
37
+ data,
35
38
  }) => (
36
39
  <a
37
40
  className={style('inline-flex items-center font-sans no-underline', className)}
@@ -39,7 +42,7 @@ export const Logo = JSX<Partial<LogoProps>>(
39
42
  target={targetBlank ? '_blank' : '_self'}
40
43
  aria-label={logo?.title ?? 'Россельхозбанк'}
41
44
  // eslint-disable-next-line react/jsx-props-no-spreading
42
- {...getAspectsAttributes(logo?.data)}
45
+ {...getAspectsAttributes(data)}
43
46
  >
44
47
  {renderImage(bgColor, logo?.image, ICON_SIZE)}
45
48
  {showTitle
@@ -12,7 +12,7 @@ interface SearchBarProps extends SitemapData {
12
12
 
13
13
  const MIN_QUERY_LEN = 3;
14
14
 
15
- export const SearchBar = JSX<SearchBarProps>(({ className, ...rest }) => {
15
+ export const SearchBar = JSX<SearchBarProps>(({ className, search, ...rest }) => {
16
16
  const [value, setValue] = useState('');
17
17
 
18
18
  const resetQueryOnDialogClose = useCallback(() => setValue(''), []);
@@ -30,7 +30,11 @@ export const SearchBar = JSX<SearchBarProps>(({ className, ...rest }) => {
30
30
 
31
31
  return (
32
32
  <div className={style('relative', className)} role="search">
33
- <SearchInput value={value} onChange={handleInitialInputChange} />
33
+ <SearchInput
34
+ value={value}
35
+ placeholder={search?.placeholder}
36
+ onChange={handleInitialInputChange}
37
+ />
34
38
  <CloseButton className="absolute top-0 right-0 sm:hidden" onClose={resetQueryOnDialogClose} />
35
39
  </div>
36
40
  );
@@ -29,7 +29,7 @@ const renderColumn = (menuItem: TopMenuItemProps & { onClick: () => void }, inde
29
29
  const visibleSubItems = items.filter(isVisibleItem);
30
30
 
31
31
  return (
32
- <div key={String(index)} className="flex flex-col gap-s w-1/4">
32
+ <div key={String(index)} className="flex flex-col gap-s @sm:w-full @md:w-1/4">
33
33
  <a
34
34
  className="leading-5 text-l text-primary-text hover:text-primary-main no-underline"
35
35
  href={href}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redneckz/wildless-cms-uni-blocks",
3
- "version": "0.14.301",
3
+ "version": "0.14.303",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "author": "ЦК",
@@ -7,6 +7,13 @@
7
7
  "sourceBookPath": "/wcms-resources/products"
8
8
  }
9
9
  }
10
+ },
11
+ "data": {
12
+ "items": {
13
+ "aspectName": {
14
+ "ui:widget": "hidden"
15
+ }
16
+ }
10
17
  }
11
18
  }
12
19
  }
@@ -1,6 +1,5 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import { type ContactGroup, type ContactInfo } from '../../data/FooterData';
3
- import { LinkButton } from '../../ui-kit/LinkButton/LinkButton';
4
3
  import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
5
4
  import { Text } from '../../ui-kit/Text/Text';
6
5
 
@@ -9,22 +8,12 @@ export interface ContactsProps {
9
8
  items?: ContactGroup[];
10
9
  }
11
10
 
12
- export const Contacts = JSX<ContactsProps>(({ className = '', items }) => (
13
- <div className={className}>
14
- {items?.length ? items.map(renderContactsGroup) : null}
15
- <LinkButton
16
- version="primary"
17
- className="w-full"
18
- href="https://www.rshb.ru/natural/feedback/question"
19
- target="_blank"
20
- ariaLabel="Обратная связь"
21
- text="Обратная связь"
22
- />
23
- </div>
24
- ));
11
+ export const Contacts = JSX<ContactsProps>(({ className = '', items = [] }) =>
12
+ items?.length ? <div className={className}>{items.map(renderContactsGroup)}</div> : null,
13
+ );
25
14
 
26
15
  const renderContactsGroup = (item: ContactGroup, i: number) => (
27
- <div className="mb-m space-y-m" key={String(i)}>
16
+ <div className="space-y-m" key={String(i)}>
28
17
  <div>
29
18
  <Text size="text-l" font="font-medium">
30
19
  {item?.title}
@@ -1,7 +1,7 @@
1
1
  import { useCallback } from '@redneckz/uni-jsx/lib/hooks';
2
2
  import { type TopMenuItemProps } from '../../data/SitemapData';
3
3
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
4
- import { Text } from '../../ui-kit/Text/Text';
4
+ import { LinkButton } from '../../ui-kit/LinkButton/LinkButton';
5
5
  import { UniBlock } from '../../UniBlock/UniBlock';
6
6
  import { appendSlash } from '../../utils/appendSlash';
7
7
  import { mapCookie } from '../../utils/mapCookie';
@@ -24,6 +24,8 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
24
24
  mobileApps,
25
25
  horizontalNavigationTitle,
26
26
  documents,
27
+ feedbackButton,
28
+ license,
27
29
  } = footer || {};
28
30
 
29
31
  const handleOnClick = useCallback(() => {
@@ -37,6 +39,7 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
37
39
  {renderTopItems(topItems)}
38
40
  </div>
39
41
  <Contacts className="overflow-hidden" items={contacts} />
42
+ {feedbackButton ? <LinkButton className="w-full mt-xs" {...feedbackButton} /> : null}
40
43
  <div className="mt-xl">
41
44
  <SocialMedia className="mb-xl" media={socialMedia} stretched={true}>
42
45
  Соцсети
@@ -48,9 +51,7 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
48
51
  stretched={true}
49
52
  showButtonText={false}
50
53
  />
51
- <Text size="text-s" font="font-light" color="text-secondary-text">
52
- Мобильное приложение
53
- </Text>
54
+ Мобильное приложение
54
55
  </div>
55
56
  </div>
56
57
  <div className="py-lg border-t border-main-divider">
@@ -66,7 +67,7 @@ export const Footer = UniBlock<FooterProps>(({ className, footer, ...rest }) =>
66
67
  title={horizontalNavigationTitle}
67
68
  links={relatedEnterprises}
68
69
  />
69
- <TextInformation links={documents} />
70
+ <TextInformation links={documents} license={license} />
70
71
  </BlockWrapper>
71
72
  );
72
73
  });