@redneckz/wildless-cms-uni-blocks 0.2.86 → 0.2.87
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.
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +511 -446
- package/bundle/bundle.umd.min.js +1 -1
- package/dist/components/Accordion/AccordionBlocks.d.ts +3 -0
- package/dist/components/Accordion/AccordionBlocks.js +6 -0
- package/dist/components/Accordion/AccordionBlocks.js.map +1 -1
- package/dist/components/Accordion/AccordionContent.d.ts +14 -6
- package/dist/components/BaseTile/BaseTile.js +13 -3
- package/dist/components/BaseTile/BaseTile.js.map +1 -1
- package/dist/components/BaseTile/BaseTileProps.d.ts +10 -0
- package/dist/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -1
- package/dist/components/BlockContent.d.ts +3 -1
- package/dist/components/Blocks.d.ts +17 -14
- package/dist/components/Blocks.js +23 -17
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Headline/Headline.d.ts +5 -0
- package/dist/components/Headline/Headline.js +9 -0
- package/dist/components/Headline/Headline.js.map +1 -0
- package/dist/components/Headline/HeadlineContent.d.ts +15 -0
- package/dist/components/Headline/HeadlineContent.js +2 -0
- package/dist/components/Headline/HeadlineContent.js.map +1 -0
- package/dist/components/LinkDocs/LinkDocs.d.ts +5 -0
- package/dist/components/LinkDocs/LinkDocs.js +42 -0
- package/dist/components/LinkDocs/LinkDocs.js.map +1 -0
- package/dist/components/LinkDocs/LinkDocsContent.d.ts +23 -0
- package/dist/components/LinkDocs/LinkDocsContent.js +2 -0
- package/dist/components/LinkDocs/LinkDocsContent.js.map +1 -0
- package/dist/components/MobileBlocks.d.ts +8 -6
- package/dist/components/MobileBlocks.js +10 -6
- package/dist/components/MobileBlocks.js.map +1 -1
- package/dist/components/PictureText/PictureText.d.ts +5 -0
- package/dist/components/PictureText/PictureText.js +14 -0
- package/dist/components/PictureText/PictureText.js.map +1 -0
- package/dist/components/PictureText/PictureTextContent.d.ts +11 -0
- package/dist/components/PictureText/PictureTextContent.js +2 -0
- package/dist/components/PictureText/PictureTextContent.js.map +1 -0
- package/dist/components/ProductGallery/ProductGalleryContent.d.ts +2 -2
- package/dist/ui-kit/Icon/IconProps.d.ts +22 -18
- package/dist/ui-kit/Icon/IconProps.js +20 -18
- package/dist/ui-kit/Icon/IconProps.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/Accordion/Accordion.fixture.d.ts +1 -0
- package/lib/components/Accordion/AccordionBlocks.d.ts +3 -0
- package/lib/components/Accordion/AccordionBlocks.js +6 -0
- package/lib/components/Accordion/AccordionBlocks.js.map +1 -1
- package/lib/components/Accordion/AccordionContent.d.ts +14 -6
- package/lib/components/BaseTile/BaseTile.js +13 -3
- package/lib/components/BaseTile/BaseTile.js.map +1 -1
- package/lib/components/BaseTile/BaseTileProps.d.ts +10 -0
- package/lib/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -1
- package/lib/components/BlockContent.d.ts +3 -1
- package/lib/components/Blocks.d.ts +17 -14
- package/lib/components/Blocks.js +23 -17
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Headline/Headline.d.ts +5 -0
- package/lib/components/Headline/Headline.fixture.d.ts +7 -0
- package/lib/components/Headline/Headline.js +7 -0
- package/lib/components/Headline/Headline.js.map +1 -0
- package/lib/components/Headline/HeadlineContent.d.ts +15 -0
- package/lib/components/Headline/HeadlineContent.js +2 -0
- package/lib/components/Headline/HeadlineContent.js.map +1 -0
- package/lib/components/LinkDocs/LinkDocs.d.ts +5 -0
- package/lib/components/LinkDocs/LinkDocs.fixture.d.ts +12 -0
- package/lib/components/LinkDocs/LinkDocs.js +40 -0
- package/lib/components/LinkDocs/LinkDocs.js.map +1 -0
- package/lib/components/LinkDocs/LinkDocsContent.d.ts +23 -0
- package/lib/components/LinkDocs/LinkDocsContent.js +2 -0
- package/lib/components/LinkDocs/LinkDocsContent.js.map +1 -0
- package/lib/components/MobileBlocks.d.ts +8 -6
- package/lib/components/MobileBlocks.js +10 -6
- package/lib/components/MobileBlocks.js.map +1 -1
- package/lib/components/PictureText/PictureText.d.ts +5 -0
- package/lib/components/PictureText/PictureText.fixture.d.ts +4 -0
- package/lib/components/PictureText/PictureText.js +12 -0
- package/lib/components/PictureText/PictureText.js.map +1 -0
- package/lib/components/PictureText/PictureTextContent.d.ts +11 -0
- package/lib/components/PictureText/PictureTextContent.js +2 -0
- package/lib/components/PictureText/PictureTextContent.js.map +1 -0
- package/lib/components/ProductGallery/ProductGalleryContent.d.ts +2 -2
- package/lib/ui-kit/Icon/IconProps.d.ts +22 -18
- package/lib/ui-kit/Icon/IconProps.js +20 -18
- package/lib/ui-kit/Icon/IconProps.js.map +1 -1
- package/package.json +2 -2
- package/src/components/Accordion/Accordion.fixture.tsx +104 -3
- package/src/components/Accordion/AccordionBlocks.tsx +6 -0
- package/src/components/Accordion/AccordionContent.ts +18 -6
- package/src/components/BaseTile/BaseTile.tsx +19 -5
- package/src/components/BaseTile/BaseTileProps.ts +11 -0
- package/src/components/BenefitsBlock/BenefitsBlockContent.ts +1 -1
- package/src/components/BlockContent.ts +15 -11
- package/src/components/Blocks.ts +23 -17
- package/src/components/ContentPage/ContentPage.page.json +88 -2
- package/src/components/Headline/Headline.example.json +6 -0
- package/src/components/Headline/Headline.fixture.tsx +42 -0
- package/src/components/Headline/Headline.tsx +15 -0
- package/src/components/Headline/HeadlineContent.ts +18 -0
- package/src/components/LinkDocs/LinkDocs.fixture.tsx +51 -0
- package/src/components/LinkDocs/LinkDocs.tsx +81 -0
- package/src/components/LinkDocs/LinkDocsContent.ts +26 -0
- package/src/components/MobileBlocks.ts +10 -6
- package/src/components/PictureText/PictureText.example.json +20 -0
- package/src/components/PictureText/PictureText.fixture.tsx +36 -0
- package/src/components/PictureText/PictureText.tsx +45 -0
- package/src/components/PictureText/PictureTextContent.ts +13 -0
- package/src/components/ProductGallery/ProductGalleryContent.ts +2 -2
- package/src/icons/DiscountShape.svg +7 -0
- package/src/icons/DocIcon.svg +1 -1
- package/src/icons/DocumentText.svg +6 -0
- package/src/ui-kit/Icon/IconProps.ts +4 -0
- package/src/icons/MinusIcon.svg +0 -1
- package/src/icons/PlusIcon.svg +0 -1
package/bundle/bundle.umd.js
CHANGED
|
@@ -185,6 +185,20 @@
|
|
|
185
185
|
};
|
|
186
186
|
}
|
|
187
187
|
|
|
188
|
+
var SizeTableClass;
|
|
189
|
+
(function (SizeTableClass) {
|
|
190
|
+
SizeTableClass["XL"] = "text-title-lg";
|
|
191
|
+
SizeTableClass["L"] = "text-title";
|
|
192
|
+
SizeTableClass["M"] = "text-title-sm";
|
|
193
|
+
SizeTableClass["S"] = "text-title-xs";
|
|
194
|
+
})(SizeTableClass || (SizeTableClass = {}));
|
|
195
|
+
|
|
196
|
+
const Title = JSX(({ size = 'L', className, children, ...rest }) => {
|
|
197
|
+
const Tag = size === 'XL' ? 'h1' : 'h2';
|
|
198
|
+
return (jsx(Tag, { className: getClasses(SizeTableClass[size], className), ...rest, children: children }));
|
|
199
|
+
});
|
|
200
|
+
const getClasses = (...classes) => classes.filter(Boolean).join(' ');
|
|
201
|
+
|
|
188
202
|
const projectSettings = new (class {
|
|
189
203
|
_ = {
|
|
190
204
|
PROD_BRANCH: 'master',
|
|
@@ -224,27 +238,6 @@
|
|
|
224
238
|
return (jsx("img", { className: className, src: href, alt: alt, title: title, ...imgProps, "aria-hidden": "true" }));
|
|
225
239
|
});
|
|
226
240
|
|
|
227
|
-
var SizeTableClass;
|
|
228
|
-
(function (SizeTableClass) {
|
|
229
|
-
SizeTableClass["XL"] = "text-title-lg";
|
|
230
|
-
SizeTableClass["L"] = "text-title";
|
|
231
|
-
SizeTableClass["M"] = "text-title-sm";
|
|
232
|
-
SizeTableClass["S"] = "text-title-xs";
|
|
233
|
-
})(SizeTableClass || (SizeTableClass = {}));
|
|
234
|
-
|
|
235
|
-
const Title = JSX(({ size = 'L', className, children, ...rest }) => {
|
|
236
|
-
const Tag = size === 'XL' ? 'h1' : 'h2';
|
|
237
|
-
return (jsx(Tag, { className: getClasses(SizeTableClass[size], className), ...rest, children: children }));
|
|
238
|
-
});
|
|
239
|
-
const getClasses = (...classes) => classes.filter(Boolean).join(' ');
|
|
240
|
-
|
|
241
|
-
const BenefitsBlock = JSX(({ className, title, benefits }) => {
|
|
242
|
-
return (jsxs("section", { className: `font-sans text-primary-text bg-white p-12 pb-2 flex flex-col items-center ${className || ''}`, children: [title ? jsx(Title, { className: "font-medium m-0 max-w-[47rem] text-center", children: title }) : null, benefits?.length ? (jsx("div", { className: "grid grid-cols-2 gap-5 mt-9", children: benefits.map(renderStep) })) : null] }));
|
|
243
|
-
});
|
|
244
|
-
const renderStep = (benefit, i) => {
|
|
245
|
-
return (jsxs("div", { className: "flex items-center p-10 gap-5 max-w-[580px]", children: [benefit.icon && (jsx(Icon, { className: "h-[70px] w-[70px] min-w-[70px] min-h-[70px]", name: benefit.icon, width: "70", height: "70" })), jsxs("div", { children: [jsx("h3", { className: "font-medium text-xl m-0", children: benefit.label }), benefit.description && (jsx("div", { className: "font-normal text-sm mt-2", children: benefit.description }))] })] }, String(i)));
|
|
246
|
-
};
|
|
247
|
-
|
|
248
241
|
const MOBILE_URL_PATH = '/mobile';
|
|
249
242
|
const isURL = (href) => href?.includes('//');
|
|
250
243
|
const isHrefActive = (href, router, cmp = (href, baseHref) => href === baseHref) => {
|
|
@@ -355,11 +348,21 @@
|
|
|
355
348
|
return colSpanStr ? parseInt(colSpanStr.substring(colSpanPrefix.length), 10) : 12;
|
|
356
349
|
};
|
|
357
350
|
|
|
351
|
+
const alignBlock = {
|
|
352
|
+
left: 'items-start',
|
|
353
|
+
center: 'items-center',
|
|
354
|
+
right: 'items-end',
|
|
355
|
+
};
|
|
356
|
+
const alignText = {
|
|
357
|
+
left: 'text-left',
|
|
358
|
+
center: 'text-center',
|
|
359
|
+
right: 'text-right',
|
|
360
|
+
};
|
|
358
361
|
const TITLE_CLASSES = 'font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px]';
|
|
359
|
-
const BaseTile = JSX(({ className, context, title, titleSize, description, children, buttons, image, items, version = 'primary', }) => {
|
|
362
|
+
const BaseTile = JSX(({ className, context, title, titleSize, description, children, buttons, image, items, version = 'primary', align = 'left', }) => {
|
|
360
363
|
const router = context.useRouter();
|
|
361
364
|
const { handlerDecorator } = context;
|
|
362
|
-
return (jsxs("div", { className: `font-sans flex flex-col grow h-full`, children: [title && (jsx(Title, { size: titleSize || getTitleSizeByClassName(className), className: TITLE_CLASSES, children: title })), jsxs("div", { className: "flex grow justify-between", children: [jsxs("div", { className:
|
|
365
|
+
return (jsxs("div", { className: `font-sans flex flex-col grow h-full ${alignBlock[align]}`, children: [title && (jsx(Title, { size: titleSize || getTitleSizeByClassName(className), className: TITLE_CLASSES, children: title })), jsxs("div", { className: "flex grow justify-between", children: [jsxs("div", { className: `flex flex-col justify-between ${alignBlock[align]}`, children: [jsxs("div", { children: [description ? (jsx("div", { className: `font-normal text-base max-w-[600px] ${alignText[align]}`, children: description })) : null, children, items?.length ? renderItems$1(items, version) : null] }), buttons?.length ? (jsx("div", { className: "flex mt-9 gap-3", children: buttons.map((button, index) => renderButton$1(useLink({ router, handlerDecorator }, button), index)) })) : null] }), image?.src && jsx(Img, { className: "mt-auto ml-7", image: image })] })] }));
|
|
363
366
|
});
|
|
364
367
|
function getTitleSizeByClassName(className = '') {
|
|
365
368
|
const colSpan = getColSpan(className);
|
|
@@ -374,7 +377,7 @@
|
|
|
374
377
|
}
|
|
375
378
|
}
|
|
376
379
|
function renderItems$1(items = [], version) {
|
|
377
|
-
return (jsx("section", { className: "max-w-[600px]", role: "list", children: items.map((_, i) => (jsx(BlockItem, { className: i ? 'mt-2.5' : '', text: _, version: version }, String(i)))) }));
|
|
380
|
+
return (jsx("section", { className: "max-w-[600px] mt-5", role: "list", children: items.map((_, i) => (jsx(BlockItem, { className: i ? 'mt-2.5' : '', text: _, version: version }, String(i)))) }));
|
|
378
381
|
}
|
|
379
382
|
function renderButton$1({ icon, ...button }, i) {
|
|
380
383
|
if (!button?.text)
|
|
@@ -384,179 +387,129 @@
|
|
|
384
387
|
return jsx(Button, { ...button }, String(i));
|
|
385
388
|
}
|
|
386
389
|
|
|
387
|
-
const
|
|
388
|
-
|
|
389
|
-
secondary: 'bg-primary-main text-white',
|
|
390
|
-
};
|
|
391
|
-
const Tile = JSX((props) => {
|
|
392
|
-
const { children, className, version = 'primary' } = props;
|
|
393
|
-
return (jsx("section", { className: `font-sans p-9 min-h-[320px] box-border ${className || ''} ${tileStyleMap[version]} ${getContainerPaddingRight(className)} `, children: jsx(BaseTile, { ...props, children: children }) }));
|
|
390
|
+
const Headline = JSX(({ bgColor = 'bg-white', className, ...props }) => {
|
|
391
|
+
return (jsx("section", { className: `p-10 ${bgColor} ${className || ''} `, children: jsx(BaseTile, { ...props }) }));
|
|
394
392
|
});
|
|
395
|
-
function getContainerPaddingRight(className = '') {
|
|
396
|
-
const colSpan = getColSpan(className);
|
|
397
|
-
if (colSpan <= 6) {
|
|
398
|
-
return 'pr-9';
|
|
399
|
-
}
|
|
400
|
-
else if (colSpan <= 8) {
|
|
401
|
-
return 'pr-[4.75rem]';
|
|
402
|
-
}
|
|
403
|
-
else {
|
|
404
|
-
return 'pr-[9.4rem]';
|
|
405
|
-
}
|
|
406
|
-
}
|
|
407
393
|
|
|
408
|
-
const
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
EUR: 'EuroIcon',
|
|
394
|
+
const titleAlignStyleMap = {
|
|
395
|
+
left: 'text-left',
|
|
396
|
+
center: 'text-center',
|
|
397
|
+
right: 'text-right',
|
|
413
398
|
};
|
|
414
|
-
const
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
const CurrencyTD = JSX(({ className = '', children }) => (jsx("td", { className: `text-left font-normal text-base text-primary-text ${className}`, children: children })));
|
|
430
|
-
async function fetchExchangeRate() {
|
|
431
|
-
const response = await fetch(CBR_EXCHANGE_RATE_URL);
|
|
432
|
-
return await response.json();
|
|
433
|
-
}
|
|
434
|
-
const currencyNumberFormat = new Intl.NumberFormat('ru', { style: 'currency', currency: 'RUB' });
|
|
435
|
-
const formatCurrency = (value) => (value ? currencyNumberFormat.format(value) : '');
|
|
436
|
-
|
|
437
|
-
const SVG = JSX(({ className, viewBox, fill = 'none', width, height, paths, ...commonOptions }) => {
|
|
438
|
-
return (jsx("svg", { xmlns: "http://www.w3.org/2000/svg", className: className, viewBox: viewBox, fill: fill, width: width, height: height, children: paths.map(({ d, fill, ...options }, i) => (jsx("path", { d: d, fill: fill || 'currentColor', ...commonOptions, ...options }, i))) }));
|
|
439
|
-
});
|
|
440
|
-
|
|
441
|
-
const LOGO_PATHS = [
|
|
442
|
-
'm13.72 25.51 4.42-4.33v-2.95l-4.42 4.32v2.96Zm0-10.98 4.42-4.35V7.41l-4.42 4.31v2.8Zm0 3.63 4.42-4.33v-2.78l-4.42 4.32v2.8ZM12.46 7.44l-.6-.56V0h-.66v6.22l-.58-.57V0h-.67v5l-.59-.58V0H8.7v6.56l4.44 4.33V0h-.67v7.44Zm1.26 14.35 4.42-4.33v-2.78L13.72 19v2.8Zm-5.03-.61 4.44 4.33v-2.96l-4.44-4.32v2.95Zm8.79-16.76-.59.58V0h-.66v5.66l-.6.56V0h-.66v6.87l-.58.57V0h-.67v10.9l4.42-4.34V0h-.66v4.42Zm-8.79 5.76 4.44 4.35v-2.8L8.69 7.4v2.77Zm0 3.65 4.44 4.33v-2.8l-4.44-4.3v2.77Zm0 3.63 4.44 4.33V19l-4.44-4.31v2.78Zm26.37 2.29H24.3a2.25 2.25 0 0 0 .36-1.22 2.32 2.32 0 0 0-2.33-2.31 2.32 2.32 0 0 0-2.31 2.31c0 .5.16.96.43 1.34a.74.74 0 0 0-.33.61c0 .26.14.49.33.62a2.32 2.32 0 0 0-.43 1.34 2.31 2.31 0 0 0 2.31 2.31 2.32 2.32 0 0 0 2.33-2.31c0-.45-.13-.87-.36-1.22h8.01v.49h-.8v.68h.8v.7h-.8v1.3h.8v-.58h1.17v.58h.79v-1.3h-.79v-.7h.79v-.68h-.79v-.5h1.58a.56.56 0 0 0 .56-.56v-.34a.57.57 0 0 0-.56-.56Zm-11.53 2.7a1.2 1.2 0 0 1-2.4 0c0-.24.08-.47.2-.66l.34-.56a.97.97 0 0 1-.34-.75c0-.3.13-.56.33-.74l-.32-.56a1.13 1.13 0 0 1-.2-.66 1.2 1.2 0 0 1 2.4 0c0 .49-.56 1.65-.56 1.65v.62c-.01.01.55 1.17.55 1.66ZM4.67 18.34v2.89c0 2.75 1.2 4.53 1.9 5.21l4.58 4.5c1.28 1.25 1.5 1.66 1.79 2.37v-3.2c0-2.84-1.44-3.94-2.19-4.67-1.73-1.68-2.89-2.8-3.82-3.73a8.98 8.98 0 0 1-2.26-3.37Zm6.08 14.24c-1.73-1.7-2.89-2.8-3.82-3.73a10 10 0 0 1-2.25-2.98v2.49a7.87 7.87 0 0 0 1.89 5.24l4.58 4.47c1.28 1.25 1.5 1.85 1.79 2.55v-3.37c0-2.85-1.45-3.95-2.19-4.67Z',
|
|
443
|
-
'M19.88 5.34c-.32 0-.64 0-.96.02V6.7a18.5 18.5 0 1 1 .95 36.94A18.5 18.5 0 0 1 1.35 25.17c0-5.67 2.55-10.73 6.58-14.13V9.32A19.78 19.78 0 0 0 0 25.17C0 36.12 8.9 45 19.88 45a19.85 19.85 0 0 0 19.86-19.83c0-10.95-8.9-19.83-19.87-19.83Z',
|
|
444
|
-
'M33.93 35.53c.3-.41.6-.85.87-1.3v-2.66h-.87v3.96Zm2.54-4.92c.12-.4.24-.78.34-1.16h-2.88v.7h.43c.77-.02 1.63-.03 2.11.46Zm-19.19-1.27h-.78v7.91h.78v-7.9Z',
|
|
445
|
-
'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',
|
|
446
|
-
'M27.66 40.79c.27-.14.55-.28.8-.43v-5.98h-.8v6.4Z',
|
|
447
|
-
];
|
|
448
|
-
const Logo = JSX(({ className, href, children, targetBlank }) => {
|
|
449
|
-
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 || 'Россельхозбанк' })] }));
|
|
450
|
-
});
|
|
451
|
-
|
|
452
|
-
const SearchBar = JSX(({ className, context }) => {
|
|
453
|
-
const { term, setTerm } = context.useSearch();
|
|
454
|
-
return (jsxs("form", { className: `relative ${className || ''}`, children: [jsxs("div", { className: "absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none", children: [jsx("div", { className: "w-[24px] h-[24px]", children: jsx(Icon, { name: "LoupeIcon", width: "24", height: "24" }) }), !term && (jsx("span", { className: "font-sans font-normal text-base text-secondary-text", children: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443" }))] }), jsx("input", { className: "pl-12 w-full font-sans font-normal text-base text-black border border-solid border-main-divider rounded h-full box-border outline-none pr-[6%]", value: term, onChange: (e) => setTerm(e.target.value), type: "text", name: "s" }), term && (jsx("button", { type: "submit", className: "absolute font-sans font-normal text-sm cursor-pointer bg-transparent hover:bg-primary-hover active:bg-primary-active text-primary-main hover:text-white border-none px-5 py-2 rounded top-1 right-1 outline-none", onClick: (e) => {
|
|
455
|
-
e.preventDefault();
|
|
456
|
-
console.log('click');
|
|
457
|
-
}, children: "\u041D\u0430\u0439\u0442\u0438" }))] }));
|
|
458
|
-
});
|
|
459
|
-
|
|
460
|
-
const Contacts = JSX(({ className, items, hasButton, context }) => {
|
|
461
|
-
const router = context.useRouter();
|
|
462
|
-
const { handlerDecorator } = context;
|
|
463
|
-
return (jsxs("div", { className: `flex flex-col ${className || ''}`, children: [items?.length ? items.map(renderContact) : null, hasButton ? (jsx(Button, { version: "primary", className: "my-4", ...useLink({ router, handlerDecorator }, {
|
|
464
|
-
text: 'Обратная связь',
|
|
465
|
-
href: '/',
|
|
466
|
-
target: '_blank',
|
|
467
|
-
}) })) : null] }));
|
|
399
|
+
const titleMarginsStyleMap = {
|
|
400
|
+
double: 'mb-8',
|
|
401
|
+
single: '',
|
|
402
|
+
};
|
|
403
|
+
const linkColumnsModeStyleMap = {
|
|
404
|
+
double: 'gap-x-5 gap-y-[26px] flex-wrap',
|
|
405
|
+
single: 'gap-3.5 flex-col',
|
|
406
|
+
};
|
|
407
|
+
const LinkDocs = JSX(({ className, title, align, documents, icon, columnsMode = 'double' }) => {
|
|
408
|
+
const containerClasses = linkColumnsModeStyleMap[columnsMode];
|
|
409
|
+
return (jsxs("section", { className: `font-sans p-[50px] bg-white ${className}`, children: [title && (jsx(Title, { className: `font-medium m-0 ${titleMarginsStyleMap[columnsMode]} ${titleAlignStyleMap[align ?? 'center']}`, children: title })), jsx("div", { className: `flex ${containerClasses}`, role: "list", children: documents?.length
|
|
410
|
+
? documents.map(({ text, fileSize, ...linkProps }) => (jsxs("a", { className: `group flex items-center text-sm
|
|
411
|
+
text-sm font-sans align-middle items-center text-primary-text no-underline group hover:text-primary-main
|
|
412
|
+
${columnsMode === 'double' ? 'basis-[calc(50%-20px)]' : ''}`, role: "listitem", ...linkProps, children: [icon && jsx(Icon, { className: "mr-3.5", name: icon, width: "24px", height: "24px" }), jsxs("span", { children: [text, jsx("span", { className: "text-secondary-text group-hover:text-primary-main", children: linkProps?.href && formatSuffix(getExtFromHref(linkProps.href), fileSize) })] })] })))
|
|
413
|
+
: null })] }));
|
|
468
414
|
});
|
|
469
|
-
const
|
|
470
|
-
|
|
471
|
-
|
|
415
|
+
const getExtFromHref = (href) => {
|
|
416
|
+
if (!href)
|
|
417
|
+
return '';
|
|
418
|
+
const lastChunk = href.split('.').pop();
|
|
419
|
+
if (!lastChunk || lastChunk.includes('/'))
|
|
420
|
+
return '';
|
|
421
|
+
return lastChunk;
|
|
472
422
|
};
|
|
473
|
-
const
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
return (jsx("a", { className: "font-sans font-medium text-xl text-primary-text no-underline", href: `mailto:${text}`, children: text }));
|
|
479
|
-
default:
|
|
480
|
-
return jsx("span", { children: text });
|
|
481
|
-
}
|
|
423
|
+
const formatSuffix = (ext, fileSize) => {
|
|
424
|
+
const prefix = ext || fileSize ? ',' : '';
|
|
425
|
+
const extension = ext ? ` ${ext}` : '';
|
|
426
|
+
const size = fileSize ? ` (${fileSize})` : '';
|
|
427
|
+
return prefix + extension + size;
|
|
482
428
|
};
|
|
483
|
-
const formatTel = (s) => s.replaceAll(/(\-|\s|\(|\)|\D+)/g, '');
|
|
484
429
|
|
|
485
|
-
const
|
|
486
|
-
|
|
487
|
-
const { handlerDecorator } = context;
|
|
488
|
-
return (jsx("div", { className: `${className || ''}`, children: links?.length ? (jsx("div", { className: "flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider", children: links.map((_, i) => (jsx(HorizontalNavigationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null }));
|
|
430
|
+
const PictureText = JSX(({ className, title, image, benefits }) => {
|
|
431
|
+
return (jsxs("section", { className: `relative font-sans text-primary-text bg-white p-14 ${className}`, children: [jsx(Title, { className: "font-medium m-0 text-center", children: title }), jsxs("div", { className: 'flex justify-center mt-9', children: [image?.src && jsx(Img, { className: "mr-6", image: image }), benefits?.length ? (jsx("div", { className: "flex flex-col", children: benefits.map(renderBenefit$1) })) : null] })] }));
|
|
489
432
|
});
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
function useSitemap(useAsyncData) {
|
|
493
|
-
const { data } = useAsyncData(sitemapURL(), fetchSitemap);
|
|
494
|
-
return data || {};
|
|
433
|
+
function renderBenefit$1(benefit, i) {
|
|
434
|
+
return (jsxs("div", { className: "flex flex-row mb-8", children: [benefit.icon && (jsx(Icon, { className: "w-[48px] h-[48px] bg-main rounded-full box-border p-[12px]", name: benefit.icon, width: "48", height: "48" })), jsxs("div", { className: "flex gap-1 flex-col h-full ml-5 max-w-[490px]", children: [jsx("div", { className: "font-medium text-primary-text text-xl m-0", children: benefit.label }), benefit.description && (jsx("div", { className: "font-normal text-sm text-secondary-text", children: benefit.description }))] })] }, String(i)));
|
|
495
435
|
}
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
436
|
+
|
|
437
|
+
const textBlockStyleMaps = {
|
|
438
|
+
primary: {
|
|
439
|
+
background: 'bg-white',
|
|
440
|
+
icon: 'bg-primary-main text-white',
|
|
441
|
+
title: 'text-primary-text',
|
|
442
|
+
description: 'text-secondary-text',
|
|
443
|
+
},
|
|
444
|
+
secondary: {
|
|
445
|
+
background: 'bg-primary-main',
|
|
446
|
+
icon: 'bg-white text-primary-main',
|
|
447
|
+
title: 'text-white',
|
|
448
|
+
description: 'text-white',
|
|
449
|
+
},
|
|
450
|
+
'secondary-light': {
|
|
451
|
+
background: 'bg-primary-main/10',
|
|
452
|
+
icon: 'bg-primary-main text-white',
|
|
453
|
+
title: 'text-primary-text',
|
|
454
|
+
description: 'text-secondary-text',
|
|
455
|
+
},
|
|
456
|
+
};
|
|
457
|
+
const TextBlock = JSX(({ title, description, blockVersion = 'primary', iconVersion, image, className }) => {
|
|
458
|
+
const textBlockStyleMap = textBlockStyleMaps[blockVersion];
|
|
459
|
+
return (jsxs("section", { className: `font-sans px-9 py-4 flex ${textBlockStyleMap.background} ${className || ''}`, children: [iconVersion && iconVersion === 'small' ? renderIcon(textBlockStyleMap.icon) : null, iconVersion && iconVersion === 'big' ? renderImage(image) : null, jsxs("div", { className: "py-0.5", children: [title && (jsx("div", { className: `font-medium text-base mb-1 ${textBlockStyleMap.title}`, children: title })), description && (jsx("div", { className: `text-sm ${textBlockStyleMap.description}`, children: description }))] })] }));
|
|
460
|
+
});
|
|
461
|
+
function renderIcon(className) {
|
|
462
|
+
return (jsx("div", { className: `pt-1.5 pr-4`, children: jsx("div", { className: `rounded-full h-4 w-4 text-center text-xs ${className}`, children: "i" }) }));
|
|
499
463
|
}
|
|
500
|
-
function
|
|
501
|
-
return
|
|
464
|
+
function renderImage(image) {
|
|
465
|
+
return image?.src ? jsx(Img, { className: "pt-0.5 pr-3", image: image }) : null;
|
|
502
466
|
}
|
|
503
467
|
|
|
504
|
-
const
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
}
|
|
468
|
+
const AccordionBlocks = {
|
|
469
|
+
Headline,
|
|
470
|
+
LinkDocs,
|
|
471
|
+
TextBlock,
|
|
472
|
+
PictureText,
|
|
473
|
+
};
|
|
510
474
|
|
|
511
|
-
const
|
|
512
|
-
const
|
|
513
|
-
const
|
|
514
|
-
const
|
|
515
|
-
|
|
516
|
-
|
|
475
|
+
const AccordionItem = JSX(({ label, blocks, context }) => {
|
|
476
|
+
const [isActive, setIsActive] = context.useState(false);
|
|
477
|
+
const hasContent = blocks?.length;
|
|
478
|
+
const icon = isActive ? 'MinusIcon' : 'PlusIcon';
|
|
479
|
+
const handleToggle = (e) => {
|
|
480
|
+
if (!hasContent)
|
|
481
|
+
return null;
|
|
482
|
+
setIsActive(!isActive);
|
|
483
|
+
const contentBlock = getContentBlock(e);
|
|
484
|
+
contentBlock.style.maxHeight = contentBlock.style.maxHeight
|
|
485
|
+
? null
|
|
486
|
+
: `${contentBlock.scrollHeight}px`;
|
|
517
487
|
};
|
|
518
|
-
return (
|
|
488
|
+
return (jsxs("li", { className: "border-0 border-b border-solid border-main-divider last:border-b-0", children: [jsxs("button", { className: `border-none bg-transparent px-0 py-5 flex justify-between text-left w-full font-sans text-primary-text
|
|
489
|
+
${hasContent ? 'group cursor-pointer' : ''}`, onClick: handleToggle, children: [jsx("span", { className: `m-0 text-xl pr-2.5 font-medium ${hasContent ? 'group-hover:text-primary-main' : ''}`, children: label }), hasContent ? jsx(Icon, { name: icon, width: "24", height: "24" }) : null] }), hasContent ? (jsx("div", { className: `${isActive ? 'pb-5' : ''} text-sm transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0 `, children: blocks?.length ? blocks.map((block, i) => renderBlock(block, i, context)) : null })) : null] }));
|
|
519
490
|
});
|
|
520
|
-
const
|
|
521
|
-
|
|
522
|
-
|
|
491
|
+
const renderBlock = (block, i, context) => {
|
|
492
|
+
if (!block.type || !block.data || !AccordionBlocks.hasOwnProperty(block.type)) {
|
|
493
|
+
return null;
|
|
494
|
+
}
|
|
495
|
+
const AccordionBlock = AccordionBlocks[block.type];
|
|
496
|
+
return (jsx("div", { className: "mb-5 last:mb-0", children: jsx(AccordionBlock, { context: context, ...block.data }) }, `block_${i}`));
|
|
523
497
|
};
|
|
524
|
-
const
|
|
498
|
+
const getContentBlock = (e) => e.target.tagName === 'BUTTON' ? e.target.nextSibling : e.target.parentNode.nextSibling;
|
|
525
499
|
|
|
526
|
-
const
|
|
527
|
-
{
|
|
528
|
-
origins: ['t.me', 'telegram.org'],
|
|
529
|
-
icon: 'TelegramIcon',
|
|
530
|
-
label: 'Телеграм',
|
|
531
|
-
width: '20px',
|
|
532
|
-
height: '16px',
|
|
533
|
-
},
|
|
534
|
-
{ origins: ['vk.com'], icon: 'VKIcon', label: 'ВКонтакте', width: '24px', height: '12px' },
|
|
535
|
-
{ origins: ['ok.ru'], icon: 'OkIcon', label: 'Одноклассники', width: '12px', height: '20px' },
|
|
536
|
-
];
|
|
537
|
-
const SocialMedia = JSX(({ className, media, context }) => {
|
|
538
|
-
const router = context.useRouter();
|
|
539
|
-
const { handlerDecorator } = context;
|
|
540
|
-
return (jsx("div", { className: `flex items-end justify-end gap-2 pt-[30px] pb-7 ${className || ''}`, children: media?.map((_, index) => (jsx(MediaButton, { ...useLink({ router, handlerDecorator }, _) }, String(index)))) }));
|
|
541
|
-
});
|
|
542
|
-
const MediaButton = JSX(({ href }) => {
|
|
543
|
-
const { icon, label, width, height } = ICONS_MAP.find(({ origins }) => origins.some((_) => href?.includes(_))) || {};
|
|
544
|
-
if (!icon)
|
|
545
|
-
return null;
|
|
546
|
-
return (jsx(Button, { rounded: true, href: href, target: "_blank", rel: "noopener noreferrer", "aria-label": label, className: "border-solid border border-main-divider w-9 h-9 flex items-center justify-center hover:fill-primary-main", appendLeft: jsx(Icon, { name: icon, width: width, height: height, asSVG: true }) }));
|
|
500
|
+
const Accordion = JSX(({ title, accordionItems, context, className }) => {
|
|
501
|
+
return (jsxs("section", { className: `p-[50px] font-sans bg-white text-primary-text ${className || ''}`, children: [title ? jsx(Title, { className: "m-0 mb-2.5", children: title }) : null, accordionItems?.length ? (jsx("ul", { className: "list-none m-0 p-0", children: accordionItems.map((item, i) => (jsx(AccordionItem, { ...item, context: context }, `AccordionItem${i}`))) })) : null] }));
|
|
547
502
|
});
|
|
548
503
|
|
|
549
|
-
const
|
|
550
|
-
|
|
551
|
-
const { handlerDecorator } = context;
|
|
552
|
-
return (jsxs("div", { className: `${className || ''}`, children: [jsx("div", { className: "pt-5 pb-[5px]", children: jsx("span", { className: "font-sans font-normal text-xs text-secondary-text", children: `\u00a9\u00A02000-${new Date().getFullYear()}\u00A0АО \u00ABРоссельхозбанк\u00BB Генеральная лицензия Банка России \u2116\u00A03349 от\u00A012.08.2015\u00A0г.` }) }), links?.length ? (jsx("div", { className: "flex justify-start items-start gap-5 pt-[5px]", children: links.map((_, i) => (jsx(TextInformationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null] }));
|
|
504
|
+
const BenefitsBlock = JSX(({ className, title, benefits }) => {
|
|
505
|
+
return (jsxs("section", { className: `font-sans text-primary-text bg-white p-12 pb-2 flex flex-col items-center ${className || ''}`, children: [title ? jsx(Title, { className: "font-medium m-0 max-w-[47rem] text-center", children: title }) : null, benefits?.length ? (jsx("div", { className: "grid grid-cols-2 gap-5 mt-9", children: benefits.map(renderStep) })) : null] }));
|
|
553
506
|
});
|
|
554
|
-
const
|
|
507
|
+
const renderStep = (benefit, i) => {
|
|
508
|
+
return (jsxs("div", { className: "flex items-center p-10 gap-5 max-w-[580px]", children: [benefit.icon && (jsx(Icon, { className: "h-[70px] w-[70px] min-w-[70px] min-h-[70px]", name: benefit.icon, width: "70", height: "70" })), jsxs("div", { children: [jsx("h3", { className: "font-medium text-xl m-0", children: benefit.label }), benefit.description && (jsx("div", { className: "font-normal text-sm mt-2", children: benefit.description }))] })] }, String(i)));
|
|
509
|
+
};
|
|
555
510
|
|
|
556
|
-
const
|
|
557
|
-
|
|
558
|
-
const Footer$1 = JSX(({ className, documents, relatedEnterprises, contacts, socialMedia, topItems, context }) => {
|
|
559
|
-
return (jsxs("footer", { className: `${className} px-9 py-10 bg-white`, children: [jsxs("div", { className: "flex items-stretch gap-32 pb-8 xl:gap-8", children: [jsx(Logo, { className: `${LEFT_COL_WIDTH_FULL_HD} ${LEFT_COL_WIDTH_SMALL_DESKTOP}` }), jsx(SearchBar, { context: context, className: "grow" })] }), jsxs("div", { className: "flex items-stretch gap-32 xl:gap-8", children: [jsx(Contacts, { className: `${LEFT_COL_WIDTH_FULL_HD} shrink-0 overflow-hidden ${LEFT_COL_WIDTH_SMALL_DESKTOP}`, items: contacts, context: context, hasButton: true }), jsx(Sitemap, { className: "pt-[3px]", context: context, items: topItems })] }), jsx(SocialMedia, { media: socialMedia, context: context }), jsx(HorizontalNavigation, { links: relatedEnterprises, context: context }), jsx(TextInformation, { links: documents, context: context })] }));
|
|
511
|
+
const SVG = JSX(({ className, viewBox, fill = 'none', width, height, paths, ...commonOptions }) => {
|
|
512
|
+
return (jsx("svg", { xmlns: "http://www.w3.org/2000/svg", className: className, viewBox: viewBox, fill: fill, width: width, height: height, children: paths.map(({ d, fill, ...options }, i) => (jsx("path", { d: d, fill: fill || 'currentColor', ...commonOptions, ...options }, i))) }));
|
|
560
513
|
});
|
|
561
514
|
|
|
562
515
|
const ARROW_PATHS = [
|
|
@@ -575,222 +528,6 @@
|
|
|
575
528
|
? 'bg-secondary-light text-secondary-text'
|
|
576
529
|
: '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" }) })));
|
|
577
530
|
|
|
578
|
-
const cardStyleMap = {
|
|
579
|
-
normal: 'min-w-[364px] w-[364px]',
|
|
580
|
-
mini: 'min-w-[260px] w-[260px]',
|
|
581
|
-
};
|
|
582
|
-
const cardWidthMap = {
|
|
583
|
-
normal: 380,
|
|
584
|
-
mini: 276,
|
|
585
|
-
};
|
|
586
|
-
const galleryLengthForScrollMap = {
|
|
587
|
-
normal: 3,
|
|
588
|
-
mini: 4,
|
|
589
|
-
};
|
|
590
|
-
const GalleryInner = JSX(({ title, description, context, cards = [], className, version = 'normal' }) => {
|
|
591
|
-
const [activeCardIndex, setActiveCardIndex] = context.useState(0);
|
|
592
|
-
function handleNextClick() {
|
|
593
|
-
setActiveCardIndex(activeCardIndex + 1);
|
|
594
|
-
}
|
|
595
|
-
function handlePrevClick() {
|
|
596
|
-
setActiveCardIndex(activeCardIndex - 1);
|
|
597
|
-
}
|
|
598
|
-
const isGalleryScrollAvailable = cards?.length > galleryLengthForScrollMap[version];
|
|
599
|
-
const showNextButton = isGalleryScrollAvailable &&
|
|
600
|
-
cards?.length - activeCardIndex > galleryLengthForScrollMap[version];
|
|
601
|
-
const showPrevButton = isGalleryScrollAvailable && activeCardIndex > 0;
|
|
602
|
-
return (jsxs("section", { className: `relative font-sans text-primary-text bg-white p-12 overflow-hidden ${className}`, children: [jsxs("div", { className: "flex flex-col items-center mb-8", children: [title ? jsx(Title, { className: "font-medium m-0 text-center", children: title }) : null, description ? (jsx("div", { className: "font-normal text-base max-w-[600px] mt-3", children: description })) : null] }), jsx("div", {
|
|
603
|
-
// Need to place all cards at the center if count of cards less than 4
|
|
604
|
-
className: `flex ${cards?.length <= galleryLengthForScrollMap[version] ? 'justify-center' : ''} duration-1000`,
|
|
605
|
-
// All cards has same width
|
|
606
|
-
style: { transform: `translateX(-${activeCardIndex * cardWidthMap[version]}px)` }, role: "list", children: cards?.map((card, i) => renderCard$1(card, i, version)) }), showPrevButton && (jsx(ArrowButton, { className: "absolute top-1/2 left-8 rotate-180", onClick: handlePrevClick, ariaLabel: "\u041F\u0440\u043E\u043B\u0438\u0441\u0442\u0430\u0442\u044C \u0432\u043B\u0435\u0432\u043E" })), showNextButton && (jsx(ArrowButton, { className: "absolute top-1/2 right-1 z-10", onClick: handleNextClick, ariaLabel: "\u041F\u0440\u043E\u043B\u0438\u0441\u0442\u0430\u0442\u044C \u0432\u043F\u0440\u0430\u0432\u043E" })), jsx("div", { className: "absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white" })] }));
|
|
607
|
-
});
|
|
608
|
-
function renderCard$1(card, i, version) {
|
|
609
|
-
return (jsxs("div", { className: `box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between items-stretch ${cardStyleMap[version]} w-full`, role: "listitem", children: [jsxs("div", { children: [card.image?.src ? (jsx("div", { className: "flex justify-center", children: jsx(Img, { className: "mb-6", image: card.image }) })) : null, card.title ? (jsx("h4", { className: `font-medium text-xl m-0 ${!card.description && !card.items?.length ? 'text-center' : ''}`, children: card.title })) : null, card.description ? (jsx("div", { className: "font-normal text-sm text-secondary-text mt-2", children: card.description })) : null, card.items?.length ? (jsx("section", { className: "max-w-[308px] mt-2", role: "list", children: card.items.map(renderItem) })) : null] }), card.href ? (jsx(Button, { className: "mt-6", text: "\u041F\u043E\u0434\u0440\u043E\u0431\u043D\u0435\u0435", version: "secondary", href: card.href })) : null] }, String(i)));
|
|
610
|
-
}
|
|
611
|
-
function renderItem(item, i) {
|
|
612
|
-
return (jsx(BlockItem, { children: jsx("span", { className: "text-sm text-secondary-text", children: item }) }, String(i)));
|
|
613
|
-
}
|
|
614
|
-
|
|
615
|
-
const Gallery$1 = JSX((props) => jsx(GalleryInner, { ...props, version: "normal" }));
|
|
616
|
-
|
|
617
|
-
const HeaderItem = JSX(({ className, text, href, target, active, onClick, children }) => {
|
|
618
|
-
const textStyle = active ? 'text-primary-main' : 'text-primary-text hover:text-primary-main';
|
|
619
|
-
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] }));
|
|
620
|
-
});
|
|
621
|
-
|
|
622
|
-
const TopItem = JSX(({ className, text, href, target, active, flat, onClick, children, ariaLabel }) => {
|
|
623
|
-
const linkStyle = active ? 'border-primary-main rounded-md' : 'border-transparent';
|
|
624
|
-
const textStyle = active
|
|
625
|
-
? 'text-primary-main'
|
|
626
|
-
: `${flat ? 'text-primary-text' : 'text-secondary-text'} hover:text-primary-main`;
|
|
627
|
-
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 }) }));
|
|
628
|
-
});
|
|
629
|
-
|
|
630
|
-
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 })));
|
|
631
|
-
|
|
632
|
-
const HeaderSecondaryMenu = JSX(({ context, className, defaultLocation = '' }) => {
|
|
633
|
-
const [city, getCity] = context.useGeolocation(defaultLocation);
|
|
634
|
-
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 }) })] }));
|
|
635
|
-
});
|
|
636
|
-
|
|
637
|
-
function isSubItemActive(router) {
|
|
638
|
-
return (subItem) => isHrefActive(subItem.href, router);
|
|
639
|
-
}
|
|
640
|
-
|
|
641
|
-
function isTopItemActive(router) {
|
|
642
|
-
return (topItem) => isHrefActive(topItem.href, router, (topItemHref, baseHref) => baseHref.startsWith(topItemHref));
|
|
643
|
-
}
|
|
644
|
-
|
|
645
|
-
const Header = JSX(({ className, defaultLocation, context, topItems }) => {
|
|
646
|
-
const router = context.useRouter();
|
|
647
|
-
const sitemap = useSitemap(context.useAsyncData);
|
|
648
|
-
const { handlerDecorator } = context;
|
|
649
|
-
const mergedItems = mergeTopItems(sitemap.topItems, topItems);
|
|
650
|
-
const activeTopItem = mergedItems.find(isTopItemActive(router));
|
|
651
|
-
const subItems = activeTopItem?.items;
|
|
652
|
-
const activeSubItem = subItems?.find(isSubItemActive(router));
|
|
653
|
-
const topMenu = mergedItems.map((_, i) => (jsx(TopItem, { active: _ === activeTopItem, ...useLink({ router, handlerDecorator }, _), ariaLabel: _.text }, String(i))));
|
|
654
|
-
const subMenu = subItems?.map((_) => (jsx(HeaderItem, { className: "mr-8", active: _ === activeSubItem, ...useLink({ router, handlerDecorator }, _) }, _.href)));
|
|
655
|
-
return (jsxs("header", { className: `pt-5 pb-8 px-20 bg-white ${className || ''}`, 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 })] }));
|
|
656
|
-
});
|
|
657
|
-
|
|
658
|
-
const MiniGallery = JSX((props) => (jsx(GalleryInner, { ...props, version: "mini" })));
|
|
659
|
-
|
|
660
|
-
const MobileAppTile = JSX(({ className, context, title = 'Мобильное приложение', qr, buttons = [] }) => {
|
|
661
|
-
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" })] }) }));
|
|
662
|
-
});
|
|
663
|
-
|
|
664
|
-
const GOLDEN_RATIO = 1.618;
|
|
665
|
-
const Placeholder = JSX(({ className, context, title }) => {
|
|
666
|
-
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() }) }));
|
|
667
|
-
});
|
|
668
|
-
const renderShimmer = (size = 3) => goldenSequence(100, size)
|
|
669
|
-
.map((_) => Math.floor(_))
|
|
670
|
-
.map(renderShimmerItem);
|
|
671
|
-
const renderShimmerItem = (width = 100, index) => (jsx("div", { style: { width: `${width}%` }, className: "h-4 mt-2 bg-secondary-light" }, String(index)));
|
|
672
|
-
const goldenSequence = (first, size) => [first].concat(size > 0 ? goldenSequence(first / GOLDEN_RATIO, size - 1) : []);
|
|
673
|
-
|
|
674
|
-
const ProductBlockInner = JSX(({ className, context, title, titleSize, description, benefits, buttons, image, items }) => {
|
|
675
|
-
return (jsxs("div", { className: `flex grow justify-between items-stretch ${className || ''}`, children: [jsxs("div", { className: 'flex flex-col', children: [title && (
|
|
676
|
-
/* TODO Why <Title> is duplicated here? */
|
|
677
|
-
jsx(Title, { size: titleSize || 'XL', className: "font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px] text-primary-text", children: title })), jsx(BaseTile, { context: context, description: description, items: items, buttons: buttons, children: benefits?.length ? (jsx("div", { className: "flex gap-6 mt-6 mb-3.5", children: benefits.map(renderBenefit) })) : null })] }), image?.src && jsx(Img, { className: "mt-auto", image: image })] }));
|
|
678
|
-
});
|
|
679
|
-
function renderBenefit(benefit, i) {
|
|
680
|
-
return (jsxs("div", { className: "flex gap-4 items-center", children: [benefit.icon && (jsx(Icon, { className: "w-[50px] h-[50px] min-w-[50px] min-h-[50px] bg-main rounded-full p-[10px] box-border", name: benefit.icon, width: "24", height: "24" })), jsxs("div", { className: "flex gap-1 flex-col h-full", children: [jsx("h4", { className: "font-medium text-primary-text text-xl m-0", children: benefit.label }), benefit.description && (jsx("div", { className: "font-normal text-sm text-secondary-text", children: benefit.description }))] })] }, String(i)));
|
|
681
|
-
}
|
|
682
|
-
|
|
683
|
-
const Breadcrumb = JSX(({ text, href, target, onClick, className, children }) => {
|
|
684
|
-
if (href) {
|
|
685
|
-
return (jsx("a", { className: `no-underline ${className || ''}`, href: href, target: target, onClick: onClick, children: jsx("span", { className: `${className || ''}`, children: text || children }) }));
|
|
686
|
-
}
|
|
687
|
-
else {
|
|
688
|
-
return jsx("span", { className: `${className || ''}`, children: text || children });
|
|
689
|
-
}
|
|
690
|
-
});
|
|
691
|
-
|
|
692
|
-
function joinList(sep) {
|
|
693
|
-
return (list) => list.reduce((acc, el, i) => (acc.length ? acc.concat({ ...sep, key: i }, el) : [el]), []);
|
|
694
|
-
}
|
|
695
|
-
|
|
696
|
-
const ProductBlock$1 = JSX((props) => {
|
|
697
|
-
const { context, className, breadcrumbs } = props;
|
|
698
|
-
const router = context.useRouter();
|
|
699
|
-
const { handlerDecorator } = context;
|
|
700
|
-
return (jsxs("section", { className: `font-sans bg-white pt-10 pl-[50px] pb-[50px] pr-[7.5rem] ${className || ''}`, children: [breadcrumbs?.length ? (jsx("div", { className: "text-xs mb-6", children: joinList(jsx("span", { className: "text-secondary-text mx-2", children: "/" }))(breadcrumbs.map((breadcrumb, i) => (jsx(Breadcrumb, { ...useLink({ router, handlerDecorator }, { className: 'text-secondary-text', ...breadcrumb }) }, String(i))))) })) : null, jsx(ProductBlockInner, { ...props })] }));
|
|
701
|
-
});
|
|
702
|
-
|
|
703
|
-
const ProductGallery = JSX(({ className, context, duration = 0, slides = [] }) => {
|
|
704
|
-
const galleryNav = slides.map((s) => s.nav);
|
|
705
|
-
const galleryBlocks = slides.map((s) => s.productBlock);
|
|
706
|
-
const [activeSlideIndex, setActiveSlideIndex] = context.useState(0);
|
|
707
|
-
return (jsxs("section", { className: `font-sans bg-white overflow-hidden w-100 ${className || ''}`, children: [jsx("div", { className: `flex duration-1000`, style: { transform: `translateX(-${activeSlideIndex}00%)` }, role: "list", children: galleryBlocks.map((_, i) => renderProductBlock(_, i, context)) }), jsx("div", { className: `border-t border-solid border-main-divider flex`, children: galleryNav.map((slide, i) => renderNavButton({
|
|
708
|
-
slide,
|
|
709
|
-
i,
|
|
710
|
-
activeSlideIndex,
|
|
711
|
-
onClick: () => setActiveSlideIndex(i),
|
|
712
|
-
duration,
|
|
713
|
-
})) })] }));
|
|
714
|
-
});
|
|
715
|
-
function renderProductBlock(block, i, context) {
|
|
716
|
-
return (jsx("section", { className: "flex grow-0 shrink-0 basis-full", role: "listitem", children: jsx("div", { className: "p-10 flex grow", children: jsx(ProductBlockInner, { className: "pl-2.5 pt-2.5 pb-1.5 pr-[6.25rem]", context: context, ...block }) }) }, String(i)));
|
|
717
|
-
}
|
|
718
|
-
function renderNavButton({ slide, i, activeSlideIndex, onClick, duration }) {
|
|
719
|
-
const isActiveBtn = i === activeSlideIndex;
|
|
720
|
-
const progressBarClassName = isActiveBtn ? 'animate-slide' : '';
|
|
721
|
-
const btnTitleClassName = isActiveBtn ? 'text-primary-text' : 'text-secondary-text';
|
|
722
|
-
return (jsxs("button", { type: "button", onClick: onClick, className: `group relative overflow-hidden border-0 bg-inherit cursor-pointer text-left px-0 py-4 grow basis-0`, children: [jsxs("div", { className: "border-0 border-r border-solid border-main-divider px-6", children: [jsx("div", { className: `text-sm font-medium group-hover:text-primary-text ${btnTitleClassName}`, children: slide?.title }), jsx("div", { className: "text-xs text-secondary-text", children: slide.desc })] }), jsx("div", { className: `absolute bottom-0 left-0 w-full h-[3px] bg-primary-main -translate-x-full ${progressBarClassName}`, style: { animationDuration: `${duration}s` } })] }, String(i)));
|
|
723
|
-
}
|
|
724
|
-
|
|
725
|
-
const ProductTile = JSX((props) => {
|
|
726
|
-
const { benefits, version } = props;
|
|
727
|
-
return (jsx(Tile, { ...props, children: jsxs("div", { className: "flex mt-5 mb-1", children: [benefits?.length ? (jsx("div", { className: "mr-8", children: benefits.map(renderBenefitDescription) })) : null, benefits?.length ? (jsx("div", { className: "pt-1", children: benefits.map((_, i) => renderBenefitLabel(_, i, version)) })) : null] }) }));
|
|
728
|
-
});
|
|
729
|
-
function renderBenefitLabel(benefit, i, version = 'primary') {
|
|
730
|
-
const labelStyleMap = {
|
|
731
|
-
primary: 'text-secondary-text',
|
|
732
|
-
secondary: 'text-white',
|
|
733
|
-
};
|
|
734
|
-
return (jsx("div", { className: `text-sm ${i ? 'mt-4' : ''} ${labelStyleMap[version]}`, children: benefit.label }, String(i)));
|
|
735
|
-
}
|
|
736
|
-
function renderBenefitDescription(benefit, i) {
|
|
737
|
-
return (jsx("div", { className: `text-xl font-medium ${i ? 'mt-2.5' : ''}`, children: benefit.description }, String(i)));
|
|
738
|
-
}
|
|
739
|
-
|
|
740
|
-
const PromoTile = JSX(({ className, context, title = 'Акции и спецпредложения', date, description, buttons = [], version, }) => {
|
|
741
|
-
return (jsx(Tile, { className: className, context: context, title: title, buttons: buttons, version: version, children: jsxs("div", { children: [date && jsx("div", { className: "text-sm mb-2", children: formatDate(date) }), jsx("div", { className: "text-base", children: description })] }) }));
|
|
742
|
-
});
|
|
743
|
-
function formatDate(date) {
|
|
744
|
-
const dateObj = new Date(date);
|
|
745
|
-
const dateFormat = {
|
|
746
|
-
day: 'numeric',
|
|
747
|
-
month: 'long',
|
|
748
|
-
year: 'numeric',
|
|
749
|
-
};
|
|
750
|
-
return dateObj.toLocaleString('ru-RU', dateFormat).replace('г.', '');
|
|
751
|
-
}
|
|
752
|
-
|
|
753
|
-
const StepsBlock = JSX(({ className, title, steps }) => {
|
|
754
|
-
return (jsxs("section", { className: `font-sans text-primary-text bg-white px-12 py-12 flex flex-col items-center ${className || ''}`, children: [jsx(Title, { className: "font-medium m-0 max-w-[47rem] text-center", children: title }), steps?.length ? (jsxs("div", { children: [jsx("div", { className: "flex mt-9 items-center px-[88px]", children: joinList(jsx("div", { className: "h-0.5 w-full bg-secondary-light" }))(steps.map((step, i) => renderStepIcon(step, i))) }), jsx("div", { className: "flex mt-9 justify-between gap-x-24", children: steps.map(renderStepTitle) })] })) : null] }));
|
|
755
|
-
});
|
|
756
|
-
const renderStepIcon = (step, i) => {
|
|
757
|
-
return (jsx("div", { className: "flex flex-col items-center text-center relative", children: jsx("div", { className: "h-[100px] w-[100px] min-w-[100px] min-h-[100px] bg-secondary-light rounded-full p-[26px] box-border z-10", children: (step.icon && jsx(Icon, { name: step.icon, width: "48", height: "48" })) || (jsx("span", { className: "font-medium text-title-sm text-secondary-text", children: i + 1 })) }) }, String(i)));
|
|
758
|
-
};
|
|
759
|
-
const renderStepTitle = (step, i) => {
|
|
760
|
-
return (jsx("div", { className: "flex flex-col items-center text-center relative w-[276px]", children: jsxs("div", { className: "max-w-min", children: [jsx("h5", { className: "font-medium text-xl m-0 mt-4 whitespace-nowrap px-3", children: step.label }), step.description && (jsx("div", { className: "font-normal text-sm text-secondary-text mt-2", children: step.description }))] }) }, String(i)));
|
|
761
|
-
};
|
|
762
|
-
|
|
763
|
-
const textBlockStyleMaps = {
|
|
764
|
-
primary: {
|
|
765
|
-
background: 'bg-white',
|
|
766
|
-
icon: 'bg-primary-main text-white',
|
|
767
|
-
title: 'text-primary-text',
|
|
768
|
-
description: 'text-secondary-text',
|
|
769
|
-
},
|
|
770
|
-
secondary: {
|
|
771
|
-
background: 'bg-primary-main',
|
|
772
|
-
icon: 'bg-white text-primary-main',
|
|
773
|
-
title: 'text-white',
|
|
774
|
-
description: 'text-white',
|
|
775
|
-
},
|
|
776
|
-
'secondary-light': {
|
|
777
|
-
background: 'bg-primary-main/10',
|
|
778
|
-
icon: 'bg-primary-main text-white',
|
|
779
|
-
title: 'text-primary-text',
|
|
780
|
-
description: 'text-secondary-text',
|
|
781
|
-
},
|
|
782
|
-
};
|
|
783
|
-
const TextBlock = JSX(({ title, description, blockVersion = 'primary', iconVersion, image, className }) => {
|
|
784
|
-
const textBlockStyleMap = textBlockStyleMaps[blockVersion];
|
|
785
|
-
return (jsxs("section", { className: `font-sans px-9 py-4 flex ${textBlockStyleMap.background} ${className || ''}`, children: [iconVersion && iconVersion === 'small' ? renderIcon(textBlockStyleMap.icon) : null, iconVersion && iconVersion === 'big' ? renderImage(image) : null, jsxs("div", { className: "py-0.5", children: [title && (jsx("div", { className: `font-medium text-base mb-1 ${textBlockStyleMap.title}`, children: title })), description && (jsx("div", { className: `text-sm ${textBlockStyleMap.description}`, children: description }))] })] }));
|
|
786
|
-
});
|
|
787
|
-
function renderIcon(className) {
|
|
788
|
-
return (jsx("div", { className: `pt-1.5 pr-4`, children: jsx("div", { className: `rounded-full h-4 w-4 text-center text-xs ${className}`, children: "i" }) }));
|
|
789
|
-
}
|
|
790
|
-
function renderImage(image) {
|
|
791
|
-
return image?.src ? jsx(Img, { className: "pt-0.5 pr-3", image: image }) : null;
|
|
792
|
-
}
|
|
793
|
-
|
|
794
531
|
const TableRowContainer = JSX(({ children }) => (jsx("div", { className: "self-start flex flex-col", role: "row", children: jsx("div", { className: "flex", children: children }) })));
|
|
795
532
|
|
|
796
533
|
const GRADIENT = 'bg-gradient-to-r from-main-gradient-start to-main-gradient-end';
|
|
@@ -835,39 +572,6 @@
|
|
|
835
572
|
return (jsxs("section", { className: `bg-white font-sans py-[50px] pl-[50px] overflow-hidden text-primary-text relative ${className || ''}`, children: [jsx(Title, { className: "font-medium m-0 max-w-[47rem] text-center mb-9 mx-auto", children: title }), jsxs("div", { role: "table", children: [colHeaders?.length ? (jsxs(TableRowContainer, { children: [jsx("div", { className: FIRST_CELL_CLASSES, role: "columnheader", scope: "col" }), jsx(TableCarouselContainer, { activeCardIndex: activeCardIndex, children: colHeaders.map((header, i) => (jsx(HeaderCell, { ...header, link: header.link && useLink({ router, handlerDecorator }, header.link) }, String(i)))) })] })) : null, rowData?.length ? (jsxs("div", { className: "relative", children: [rowData.map((row, i, { length }) => (jsx(TableRow, { row: row, isFirstRow: i === 0, isLastRow: i + 1 === length, activeCardIndex: activeCardIndex, isColoredFirstColumn: isColoredFirstColumn }, String(i)))), isScrollAvailable ? (jsx("div", { children: jsxs("div", { className: "absolute top-7 right-7 z-10", children: [jsx(ArrowButton, { onClick: nextClick, disabled: !showNextButton, ariaLabel: "\u041F\u0440\u043E\u043B\u0438\u0441\u0442\u0430\u0442\u044C \u0432\u043F\u0440\u0430\u0432\u043E" }), jsx(ArrowButton, { className: "mt-4 rotate-180", onClick: prevClick, disabled: !showPrevButton, ariaLabel: "\u041F\u0440\u043E\u043B\u0438\u0441\u0442\u0430\u0442\u044C \u0432\u043B\u0435\u0432\u043E" })] }) })) : null] })) : null] }), isScrollAvailable ? (jsx("div", { className: "absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white" })) : null, visibleRowLength ? (jsx("div", { className: "pr-[50px]", children: jsxs("div", { className: "flex w-full", children: [jsx("div", { className: FIRST_CELL_CLASSES }), jsx("button", { onClick: showToggle, className: "mt-5 flex-1 border-main-stroke border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main", children: jsx("div", { className: "font-sans font-medium text-xs py-[11px]", children: !isShowAllRow ? 'Показать все параметры' : 'Скрыть' }) })] }) })) : null] }));
|
|
836
573
|
});
|
|
837
574
|
|
|
838
|
-
const AccordionBlocks = {
|
|
839
|
-
TextBlock,
|
|
840
|
-
};
|
|
841
|
-
|
|
842
|
-
const AccordionItem = JSX(({ label, blocks, context }) => {
|
|
843
|
-
const [isActive, setIsActive] = context.useState(false);
|
|
844
|
-
const hasContent = blocks?.length;
|
|
845
|
-
const icon = isActive ? 'MinusIcon' : 'PlusIcon';
|
|
846
|
-
const handleToggle = (e) => {
|
|
847
|
-
if (!hasContent)
|
|
848
|
-
return null;
|
|
849
|
-
setIsActive(!isActive);
|
|
850
|
-
const contentBlock = getContentBlock(e);
|
|
851
|
-
contentBlock.style.maxHeight = contentBlock.style.maxHeight
|
|
852
|
-
? null
|
|
853
|
-
: `${contentBlock.scrollHeight}px`;
|
|
854
|
-
};
|
|
855
|
-
return (jsxs("li", { className: "border-0 border-b border-solid border-main-divider last:border-b-0", children: [jsxs("button", { className: `border-none bg-transparent px-0 py-5 flex justify-between text-left w-full font-sans text-primary-text
|
|
856
|
-
${hasContent ? 'group cursor-pointer' : ''}`, onClick: handleToggle, children: [jsx("span", { className: `m-0 text-xl pr-2.5 font-medium ${hasContent ? 'group-hover:text-primary-main' : ''}`, children: label }), hasContent ? jsx(Icon, { name: icon, width: "24", height: "24" }) : null] }), hasContent ? (jsx("div", { className: `${isActive ? 'pb-5' : ''} text-sm transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0 `, children: blocks?.length ? blocks.map((block, i) => renderBlock(block, i, context)) : null })) : null] }));
|
|
857
|
-
});
|
|
858
|
-
const renderBlock = (block, i, context) => {
|
|
859
|
-
if (!block.type || !block.data || !AccordionBlocks.hasOwnProperty(block.type)) {
|
|
860
|
-
return null;
|
|
861
|
-
}
|
|
862
|
-
const AccordionBlock = AccordionBlocks[block.type];
|
|
863
|
-
return (jsx("div", { className: "mb-5 last:mb-0", children: jsx(AccordionBlock, { context: context, ...block.data }) }, `block_${i}`));
|
|
864
|
-
};
|
|
865
|
-
const getContentBlock = (e) => e.target.tagName === 'BUTTON' ? e.target.nextSibling : e.target.parentNode.nextSibling;
|
|
866
|
-
|
|
867
|
-
const Accordion = JSX(({ title, accordionItems, context, className }) => {
|
|
868
|
-
return (jsxs("section", { className: `p-[50px] font-sans bg-white text-primary-text ${className || ''}`, children: [title ? jsx(Title, { className: "m-0 mb-2.5", children: title }) : null, accordionItems?.length ? (jsx("ul", { className: "list-none m-0 p-0", children: accordionItems.map((item, i) => (jsx(AccordionItem, { ...item, context: context }, `AccordionItem${i}`))) })) : null] }));
|
|
869
|
-
});
|
|
870
|
-
|
|
871
575
|
function useCreditCalculatorData(useAsyncData, directoryName) {
|
|
872
576
|
const { data } = useAsyncData(creditCalculatorUrl(directoryName), () => fetchCreditCalculatorData(directoryName));
|
|
873
577
|
return data || {};
|
|
@@ -1010,25 +714,384 @@
|
|
|
1010
714
|
return (jsx("button", { className: "bg-secondary-light rounded-3xl h-10 w-[75px] box-border mr-2 flex items-center justify-center cursor-pointer border-none", onClick: () => handleClick(number), children: jsxs("span", { className: "font-semibold text-sm", children: [number, " ", number === 1 ? 'год' : number > 4 ? 'лет' : 'года'] }) }, String(i)));
|
|
1011
715
|
}
|
|
1012
716
|
|
|
1013
|
-
const
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
717
|
+
const tileStyleMap = {
|
|
718
|
+
primary: 'bg-white text-primary-text',
|
|
719
|
+
secondary: 'bg-primary-main text-white',
|
|
720
|
+
};
|
|
721
|
+
const Tile = JSX((props) => {
|
|
722
|
+
const { children, className, version = 'primary' } = props;
|
|
723
|
+
return (jsx("section", { className: `font-sans p-9 min-h-[320px] box-border ${className || ''} ${tileStyleMap[version]} ${getContainerPaddingRight(className)} `, children: jsx(BaseTile, { ...props, children: children }) }));
|
|
724
|
+
});
|
|
725
|
+
function getContainerPaddingRight(className = '') {
|
|
726
|
+
const colSpan = getColSpan(className);
|
|
727
|
+
if (colSpan <= 6) {
|
|
728
|
+
return 'pr-9';
|
|
729
|
+
}
|
|
730
|
+
else if (colSpan <= 8) {
|
|
731
|
+
return 'pr-[4.75rem]';
|
|
732
|
+
}
|
|
733
|
+
else {
|
|
734
|
+
return 'pr-[9.4rem]';
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
const CBR_EXCHANGE_RATE_URL = 'https://www.cbr-xml-daily.ru/daily_json.js';
|
|
739
|
+
const CURRENCY_CODES = ['USD', 'EUR'];
|
|
740
|
+
const CURRENCY_ICONS_MAP = {
|
|
741
|
+
USD: 'DollarIcon',
|
|
742
|
+
EUR: 'EuroIcon',
|
|
743
|
+
};
|
|
744
|
+
const buttons = [
|
|
745
|
+
{
|
|
746
|
+
text: 'Все показатели',
|
|
747
|
+
href: 'https://cbr.ru/currency_base/daily/',
|
|
748
|
+
version: 'secondary',
|
|
749
|
+
},
|
|
750
|
+
];
|
|
751
|
+
const ExchangeRateTile = JSX(({ className, context, title }) => {
|
|
752
|
+
const { data } = context.useAsyncData(CBR_EXCHANGE_RATE_URL, fetchExchangeRate);
|
|
753
|
+
return (jsx(Tile, { className: className, context: context, title: title || 'Курсы обмена валют', buttons: buttons, children: jsxs("table", { children: [jsx("thead", { children: jsxs("tr", { children: [jsx(CurrencyTH, { children: "\u0412\u0430\u043B\u044E\u0442\u0430" }), jsx(CurrencyTH, { className: "pl-11", children: "\u041A\u0443\u0440\u0441" })] }) }), jsx("tbody", { children: CURRENCY_CODES.map((code) => {
|
|
754
|
+
const value = (data?.Valute || {})[code]?.Value;
|
|
755
|
+
return (jsxs("tr", { children: [jsx(CurrencyTD, { className: "pt-4", children: jsxs("div", { className: "flex items-center", children: [jsx(Icon, { name: CURRENCY_ICONS_MAP[code], width: "24", height: "24" }), jsx("span", { className: "ml-2", children: code })] }) }), jsx(CurrencyTD, { className: "pt-4 pl-11", children: formatCurrency(value) })] }, code));
|
|
756
|
+
}) })] }) }));
|
|
757
|
+
});
|
|
758
|
+
const CurrencyTH = JSX(({ className = '', children }) => (jsx("th", { className: `text-left font-normal text-sm text-secondary-text ${className}`, children: children })));
|
|
759
|
+
const CurrencyTD = JSX(({ className = '', children }) => (jsx("td", { className: `text-left font-normal text-base text-primary-text ${className}`, children: children })));
|
|
760
|
+
async function fetchExchangeRate() {
|
|
761
|
+
const response = await fetch(CBR_EXCHANGE_RATE_URL);
|
|
762
|
+
return await response.json();
|
|
763
|
+
}
|
|
764
|
+
const currencyNumberFormat = new Intl.NumberFormat('ru', { style: 'currency', currency: 'RUB' });
|
|
765
|
+
const formatCurrency = (value) => (value ? currencyNumberFormat.format(value) : '');
|
|
766
|
+
|
|
767
|
+
const LOGO_PATHS = [
|
|
768
|
+
'm13.72 25.51 4.42-4.33v-2.95l-4.42 4.32v2.96Zm0-10.98 4.42-4.35V7.41l-4.42 4.31v2.8Zm0 3.63 4.42-4.33v-2.78l-4.42 4.32v2.8ZM12.46 7.44l-.6-.56V0h-.66v6.22l-.58-.57V0h-.67v5l-.59-.58V0H8.7v6.56l4.44 4.33V0h-.67v7.44Zm1.26 14.35 4.42-4.33v-2.78L13.72 19v2.8Zm-5.03-.61 4.44 4.33v-2.96l-4.44-4.32v2.95Zm8.79-16.76-.59.58V0h-.66v5.66l-.6.56V0h-.66v6.87l-.58.57V0h-.67v10.9l4.42-4.34V0h-.66v4.42Zm-8.79 5.76 4.44 4.35v-2.8L8.69 7.4v2.77Zm0 3.65 4.44 4.33v-2.8l-4.44-4.3v2.77Zm0 3.63 4.44 4.33V19l-4.44-4.31v2.78Zm26.37 2.29H24.3a2.25 2.25 0 0 0 .36-1.22 2.32 2.32 0 0 0-2.33-2.31 2.32 2.32 0 0 0-2.31 2.31c0 .5.16.96.43 1.34a.74.74 0 0 0-.33.61c0 .26.14.49.33.62a2.32 2.32 0 0 0-.43 1.34 2.31 2.31 0 0 0 2.31 2.31 2.32 2.32 0 0 0 2.33-2.31c0-.45-.13-.87-.36-1.22h8.01v.49h-.8v.68h.8v.7h-.8v1.3h.8v-.58h1.17v.58h.79v-1.3h-.79v-.7h.79v-.68h-.79v-.5h1.58a.56.56 0 0 0 .56-.56v-.34a.57.57 0 0 0-.56-.56Zm-11.53 2.7a1.2 1.2 0 0 1-2.4 0c0-.24.08-.47.2-.66l.34-.56a.97.97 0 0 1-.34-.75c0-.3.13-.56.33-.74l-.32-.56a1.13 1.13 0 0 1-.2-.66 1.2 1.2 0 0 1 2.4 0c0 .49-.56 1.65-.56 1.65v.62c-.01.01.55 1.17.55 1.66ZM4.67 18.34v2.89c0 2.75 1.2 4.53 1.9 5.21l4.58 4.5c1.28 1.25 1.5 1.66 1.79 2.37v-3.2c0-2.84-1.44-3.94-2.19-4.67-1.73-1.68-2.89-2.8-3.82-3.73a8.98 8.98 0 0 1-2.26-3.37Zm6.08 14.24c-1.73-1.7-2.89-2.8-3.82-3.73a10 10 0 0 1-2.25-2.98v2.49a7.87 7.87 0 0 0 1.89 5.24l4.58 4.47c1.28 1.25 1.5 1.85 1.79 2.55v-3.37c0-2.85-1.45-3.95-2.19-4.67Z',
|
|
769
|
+
'M19.88 5.34c-.32 0-.64 0-.96.02V6.7a18.5 18.5 0 1 1 .95 36.94A18.5 18.5 0 0 1 1.35 25.17c0-5.67 2.55-10.73 6.58-14.13V9.32A19.78 19.78 0 0 0 0 25.17C0 36.12 8.9 45 19.88 45a19.85 19.85 0 0 0 19.86-19.83c0-10.95-8.9-19.83-19.87-19.83Z',
|
|
770
|
+
'M33.93 35.53c.3-.41.6-.85.87-1.3v-2.66h-.87v3.96Zm2.54-4.92c.12-.4.24-.78.34-1.16h-2.88v.7h.43c.77-.02 1.63-.03 2.11.46Zm-19.19-1.27h-.78v7.91h.78v-7.9Z',
|
|
771
|
+
'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',
|
|
772
|
+
'M27.66 40.79c.27-.14.55-.28.8-.43v-5.98h-.8v6.4Z',
|
|
773
|
+
];
|
|
774
|
+
const Logo = JSX(({ className, href, children, targetBlank }) => {
|
|
775
|
+
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 || 'Россельхозбанк' })] }));
|
|
776
|
+
});
|
|
777
|
+
|
|
778
|
+
const SearchBar = JSX(({ className, context }) => {
|
|
779
|
+
const { term, setTerm } = context.useSearch();
|
|
780
|
+
return (jsxs("form", { className: `relative ${className || ''}`, children: [jsxs("div", { className: "absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none", children: [jsx("div", { className: "w-[24px] h-[24px]", children: jsx(Icon, { name: "LoupeIcon", width: "24", height: "24" }) }), !term && (jsx("span", { className: "font-sans font-normal text-base text-secondary-text", children: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443" }))] }), jsx("input", { className: "pl-12 w-full font-sans font-normal text-base text-black border border-solid border-main-divider rounded h-full box-border outline-none pr-[6%]", value: term, onChange: (e) => setTerm(e.target.value), type: "text", name: "s" }), term && (jsx("button", { type: "submit", className: "absolute font-sans font-normal text-sm cursor-pointer bg-transparent hover:bg-primary-hover active:bg-primary-active text-primary-main hover:text-white border-none px-5 py-2 rounded top-1 right-1 outline-none", onClick: (e) => {
|
|
781
|
+
e.preventDefault();
|
|
782
|
+
console.log('click');
|
|
783
|
+
}, children: "\u041D\u0430\u0439\u0442\u0438" }))] }));
|
|
784
|
+
});
|
|
785
|
+
|
|
786
|
+
const Contacts = JSX(({ className, items, hasButton, context }) => {
|
|
787
|
+
const router = context.useRouter();
|
|
788
|
+
const { handlerDecorator } = context;
|
|
789
|
+
return (jsxs("div", { className: `flex flex-col ${className || ''}`, children: [items?.length ? items.map(renderContact) : null, hasButton ? (jsx(Button, { version: "primary", className: "my-4", ...useLink({ router, handlerDecorator }, {
|
|
790
|
+
text: 'Обратная связь',
|
|
791
|
+
href: '/',
|
|
792
|
+
target: '_blank',
|
|
793
|
+
}) })) : null] }));
|
|
794
|
+
});
|
|
795
|
+
const renderContact = (item, index) => {
|
|
796
|
+
const { type, text, description } = item;
|
|
797
|
+
return (jsxs("div", { className: "mb-4", children: [jsx("div", { children: renderText(type, text) }), jsx("div", { className: "font-sans text-sm text-secondary-text", children: description })] }, String(index)));
|
|
798
|
+
};
|
|
799
|
+
const renderText = (type, text = '') => {
|
|
800
|
+
switch (type) {
|
|
801
|
+
case 'tel':
|
|
802
|
+
return (jsx("a", { className: "font-sans font-medium text-xl text-primary-text no-underline", href: `tel:${formatTel(text)}`, children: text }));
|
|
803
|
+
case 'email':
|
|
804
|
+
return (jsx("a", { className: "font-sans font-medium text-xl text-primary-text no-underline", href: `mailto:${text}`, children: text }));
|
|
805
|
+
default:
|
|
806
|
+
return jsx("span", { children: text });
|
|
807
|
+
}
|
|
808
|
+
};
|
|
809
|
+
const formatTel = (s) => s.replaceAll(/(\-|\s|\(|\)|\D+)/g, '');
|
|
810
|
+
|
|
811
|
+
const HorizontalNavigation = JSX(({ className, links, context }) => {
|
|
812
|
+
const router = context.useRouter();
|
|
813
|
+
const { handlerDecorator } = context;
|
|
814
|
+
return (jsx("div", { className: `${className || ''}`, children: links?.length ? (jsx("div", { className: "flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider", children: links.map((_, i) => (jsx(HorizontalNavigationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null }));
|
|
815
|
+
});
|
|
816
|
+
const HorizontalNavigationLink = JSX(({ className, index, text, href, target, onClick }) => (jsx("a", { className: `font-sans font-normal text-sm text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${className || ''}`, href: href, target: target, onClick: onClick, children: text || `Документ ${index}` })));
|
|
817
|
+
|
|
818
|
+
function useSitemap(useAsyncData) {
|
|
819
|
+
const { data } = useAsyncData(sitemapURL(), fetchSitemap);
|
|
820
|
+
return data || {};
|
|
821
|
+
}
|
|
822
|
+
async function fetchSitemap() {
|
|
823
|
+
const response = await fetch(sitemapURL());
|
|
824
|
+
return await response.json();
|
|
825
|
+
}
|
|
826
|
+
function sitemapURL() {
|
|
827
|
+
return `/wcms-resources/${projectSettings.SITEMAP || 'sitemap'}.json`;
|
|
828
|
+
}
|
|
829
|
+
|
|
830
|
+
const cmp = (a) => (b) => a?.href === b?.href;
|
|
831
|
+
const substitute = (items, substitution) => (items || []).map((_) => substitution?.find(cmp(_)) || _);
|
|
832
|
+
const subtract = (minuend, subtrahend) => (minuend || []).filter((_) => !subtrahend?.find(cmp(_)));
|
|
833
|
+
function mergeTopItems(left, right) {
|
|
834
|
+
return substitute(left, right).concat(subtract(right, left));
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
const Sitemap = JSX(({ className, items, context }) => {
|
|
838
|
+
const sitemap = useSitemap(context.useAsyncData);
|
|
839
|
+
const mergedItems = mergeTopItems(sitemap.topItems, items);
|
|
840
|
+
const linkParams = {
|
|
841
|
+
router: context.useRouter(),
|
|
842
|
+
handlerDecorator: context.handlerDecorator,
|
|
843
|
+
};
|
|
844
|
+
return (jsx("div", { className: `flex items-start justify-start gap-11 xl:gap-5 ${className || ''}`, children: mergedItems?.map((_, i) => renderColumn(_, i, linkParams)) }));
|
|
845
|
+
});
|
|
846
|
+
const renderColumn = (c, index, { router, handlerDecorator }) => {
|
|
847
|
+
const { text, href, items, target } = c;
|
|
848
|
+
return (jsxs("div", { className: "flex flex-col w-[235px] gap-[14px]", children: [jsx("a", { className: "block font-sans font-medium text-base text-primary-text no-underline", href: href, target: target || '_self', children: text || `Раздел ${index}` }), items?.map((_, i) => (jsx(ColumnItem, { ...useLink({ router, handlerDecorator }, _) }, String(i))))] }, String(index)));
|
|
849
|
+
};
|
|
850
|
+
const ColumnItem = JSX(({ text, href, target, index }) => (jsx("a", { className: "block font-sans font-normal text-base text-secondary-text hover:text-primary-main no-underline", href: href, target: target || '_self', children: text || `Раздел ${index}` })));
|
|
851
|
+
|
|
852
|
+
const ICONS_MAP = [
|
|
853
|
+
{
|
|
854
|
+
origins: ['t.me', 'telegram.org'],
|
|
855
|
+
icon: 'TelegramIcon',
|
|
856
|
+
label: 'Телеграм',
|
|
857
|
+
width: '20px',
|
|
858
|
+
height: '16px',
|
|
859
|
+
},
|
|
860
|
+
{ origins: ['vk.com'], icon: 'VKIcon', label: 'ВКонтакте', width: '24px', height: '12px' },
|
|
861
|
+
{ origins: ['ok.ru'], icon: 'OkIcon', label: 'Одноклассники', width: '12px', height: '20px' },
|
|
862
|
+
];
|
|
863
|
+
const SocialMedia = JSX(({ className, media, context }) => {
|
|
864
|
+
const router = context.useRouter();
|
|
865
|
+
const { handlerDecorator } = context;
|
|
866
|
+
return (jsx("div", { className: `flex items-end justify-end gap-2 pt-[30px] pb-7 ${className || ''}`, children: media?.map((_, index) => (jsx(MediaButton, { ...useLink({ router, handlerDecorator }, _) }, String(index)))) }));
|
|
867
|
+
});
|
|
868
|
+
const MediaButton = JSX(({ href }) => {
|
|
869
|
+
const { icon, label, width, height } = ICONS_MAP.find(({ origins }) => origins.some((_) => href?.includes(_))) || {};
|
|
870
|
+
if (!icon)
|
|
871
|
+
return null;
|
|
872
|
+
return (jsx(Button, { rounded: true, href: href, target: "_blank", rel: "noopener noreferrer", "aria-label": label, className: "border-solid border border-main-divider w-9 h-9 flex items-center justify-center hover:fill-primary-main", appendLeft: jsx(Icon, { name: icon, width: width, height: height, asSVG: true }) }));
|
|
873
|
+
});
|
|
874
|
+
|
|
875
|
+
const TextInformation = JSX(({ className, links, context }) => {
|
|
876
|
+
const router = context.useRouter();
|
|
877
|
+
const { handlerDecorator } = context;
|
|
878
|
+
return (jsxs("div", { className: `${className || ''}`, children: [jsx("div", { className: "pt-5 pb-[5px]", children: jsx("span", { className: "font-sans font-normal text-xs text-secondary-text", children: `\u00a9\u00A02000-${new Date().getFullYear()}\u00A0АО \u00ABРоссельхозбанк\u00BB Генеральная лицензия Банка России \u2116\u00A03349 от\u00A012.08.2015\u00A0г.` }) }), links?.length ? (jsx("div", { className: "flex justify-start items-start gap-5 pt-[5px]", children: links.map((_, i) => (jsx(TextInformationLink, { index: i, ...useLink({ router, handlerDecorator }, _) }, String(i)))) })) : null] }));
|
|
879
|
+
});
|
|
880
|
+
const TextInformationLink = JSX(({ className, index, text, href, target, onClick }) => (jsx("a", { className: `font-sans font-normal text-xs text-secondary-text visited:text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${className || ''}`, href: href, target: target, onClick: onClick, children: text || `Документ ${index}` })));
|
|
881
|
+
|
|
882
|
+
const LEFT_COL_WIDTH_FULL_HD = 'w-[280px]';
|
|
883
|
+
const LEFT_COL_WIDTH_SMALL_DESKTOP = 'xl:w-[220px]';
|
|
884
|
+
const Footer$1 = JSX(({ className, documents, relatedEnterprises, contacts, socialMedia, topItems, context }) => {
|
|
885
|
+
return (jsxs("footer", { className: `${className} px-9 py-10 bg-white`, children: [jsxs("div", { className: "flex items-stretch gap-32 pb-8 xl:gap-8", children: [jsx(Logo, { className: `${LEFT_COL_WIDTH_FULL_HD} ${LEFT_COL_WIDTH_SMALL_DESKTOP}` }), jsx(SearchBar, { context: context, className: "grow" })] }), jsxs("div", { className: "flex items-stretch gap-32 xl:gap-8", children: [jsx(Contacts, { className: `${LEFT_COL_WIDTH_FULL_HD} shrink-0 overflow-hidden ${LEFT_COL_WIDTH_SMALL_DESKTOP}`, items: contacts, context: context, hasButton: true }), jsx(Sitemap, { className: "pt-[3px]", context: context, items: topItems })] }), jsx(SocialMedia, { media: socialMedia, context: context }), jsx(HorizontalNavigation, { links: relatedEnterprises, context: context }), jsx(TextInformation, { links: documents, context: context })] }));
|
|
886
|
+
});
|
|
887
|
+
|
|
888
|
+
const cardStyleMap = {
|
|
889
|
+
normal: 'min-w-[364px] w-[364px]',
|
|
890
|
+
mini: 'min-w-[260px] w-[260px]',
|
|
891
|
+
};
|
|
892
|
+
const cardWidthMap = {
|
|
893
|
+
normal: 380,
|
|
894
|
+
mini: 276,
|
|
895
|
+
};
|
|
896
|
+
const galleryLengthForScrollMap = {
|
|
897
|
+
normal: 3,
|
|
898
|
+
mini: 4,
|
|
899
|
+
};
|
|
900
|
+
const GalleryInner = JSX(({ title, description, context, cards = [], className, version = 'normal' }) => {
|
|
901
|
+
const [activeCardIndex, setActiveCardIndex] = context.useState(0);
|
|
902
|
+
function handleNextClick() {
|
|
903
|
+
setActiveCardIndex(activeCardIndex + 1);
|
|
904
|
+
}
|
|
905
|
+
function handlePrevClick() {
|
|
906
|
+
setActiveCardIndex(activeCardIndex - 1);
|
|
907
|
+
}
|
|
908
|
+
const isGalleryScrollAvailable = cards?.length > galleryLengthForScrollMap[version];
|
|
909
|
+
const showNextButton = isGalleryScrollAvailable &&
|
|
910
|
+
cards?.length - activeCardIndex > galleryLengthForScrollMap[version];
|
|
911
|
+
const showPrevButton = isGalleryScrollAvailable && activeCardIndex > 0;
|
|
912
|
+
return (jsxs("section", { className: `relative font-sans text-primary-text bg-white p-12 overflow-hidden ${className}`, children: [jsxs("div", { className: "flex flex-col items-center mb-8", children: [title ? jsx(Title, { className: "font-medium m-0 text-center", children: title }) : null, description ? (jsx("div", { className: "font-normal text-base max-w-[600px] mt-3", children: description })) : null] }), jsx("div", {
|
|
913
|
+
// Need to place all cards at the center if count of cards less than 4
|
|
914
|
+
className: `flex ${cards?.length <= galleryLengthForScrollMap[version] ? 'justify-center' : ''} duration-1000`,
|
|
915
|
+
// All cards has same width
|
|
916
|
+
style: { transform: `translateX(-${activeCardIndex * cardWidthMap[version]}px)` }, role: "list", children: cards?.map((card, i) => renderCard$1(card, i, version)) }), showPrevButton && (jsx(ArrowButton, { className: "absolute top-1/2 left-8 rotate-180", onClick: handlePrevClick, ariaLabel: "\u041F\u0440\u043E\u043B\u0438\u0441\u0442\u0430\u0442\u044C \u0432\u043B\u0435\u0432\u043E" })), showNextButton && (jsx(ArrowButton, { className: "absolute top-1/2 right-1 z-10", onClick: handleNextClick, ariaLabel: "\u041F\u0440\u043E\u043B\u0438\u0441\u0442\u0430\u0442\u044C \u0432\u043F\u0440\u0430\u0432\u043E" })), jsx("div", { className: "absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white" })] }));
|
|
917
|
+
});
|
|
918
|
+
function renderCard$1(card, i, version) {
|
|
919
|
+
return (jsxs("div", { className: `box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between items-stretch ${cardStyleMap[version]} w-full`, role: "listitem", children: [jsxs("div", { children: [card.image?.src ? (jsx("div", { className: "flex justify-center", children: jsx(Img, { className: "mb-6", image: card.image }) })) : null, card.title ? (jsx("h4", { className: `font-medium text-xl m-0 ${!card.description && !card.items?.length ? 'text-center' : ''}`, children: card.title })) : null, card.description ? (jsx("div", { className: "font-normal text-sm text-secondary-text mt-2", children: card.description })) : null, card.items?.length ? (jsx("section", { className: "max-w-[308px] mt-2", role: "list", children: card.items.map(renderItem) })) : null] }), card.href ? (jsx(Button, { className: "mt-6", text: "\u041F\u043E\u0434\u0440\u043E\u0431\u043D\u0435\u0435", version: "secondary", href: card.href })) : null] }, String(i)));
|
|
920
|
+
}
|
|
921
|
+
function renderItem(item, i) {
|
|
922
|
+
return (jsx(BlockItem, { children: jsx("span", { className: "text-sm text-secondary-text", children: item }) }, String(i)));
|
|
923
|
+
}
|
|
924
|
+
|
|
925
|
+
const Gallery$1 = JSX((props) => jsx(GalleryInner, { ...props, version: "normal" }));
|
|
926
|
+
|
|
927
|
+
const HeaderItem = JSX(({ className, text, href, target, active, onClick, children }) => {
|
|
928
|
+
const textStyle = active ? 'text-primary-main' : 'text-primary-text hover:text-primary-main';
|
|
929
|
+
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] }));
|
|
930
|
+
});
|
|
931
|
+
|
|
932
|
+
const TopItem = JSX(({ className, text, href, target, active, flat, onClick, children, ariaLabel }) => {
|
|
933
|
+
const linkStyle = active ? 'border-primary-main rounded-md' : 'border-transparent';
|
|
934
|
+
const textStyle = active
|
|
935
|
+
? 'text-primary-main'
|
|
936
|
+
: `${flat ? 'text-primary-text' : 'text-secondary-text'} hover:text-primary-main`;
|
|
937
|
+
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 }) }));
|
|
938
|
+
});
|
|
939
|
+
|
|
940
|
+
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 })));
|
|
941
|
+
|
|
942
|
+
const HeaderSecondaryMenu = JSX(({ context, className, defaultLocation = '' }) => {
|
|
943
|
+
const [city, getCity] = context.useGeolocation(defaultLocation);
|
|
944
|
+
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 }) })] }));
|
|
945
|
+
});
|
|
946
|
+
|
|
947
|
+
function isSubItemActive(router) {
|
|
948
|
+
return (subItem) => isHrefActive(subItem.href, router);
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
function isTopItemActive(router) {
|
|
952
|
+
return (topItem) => isHrefActive(topItem.href, router, (topItemHref, baseHref) => baseHref.startsWith(topItemHref));
|
|
953
|
+
}
|
|
954
|
+
|
|
955
|
+
const Header = JSX(({ className, defaultLocation, context, topItems }) => {
|
|
956
|
+
const router = context.useRouter();
|
|
957
|
+
const sitemap = useSitemap(context.useAsyncData);
|
|
958
|
+
const { handlerDecorator } = context;
|
|
959
|
+
const mergedItems = mergeTopItems(sitemap.topItems, topItems);
|
|
960
|
+
const activeTopItem = mergedItems.find(isTopItemActive(router));
|
|
961
|
+
const subItems = activeTopItem?.items;
|
|
962
|
+
const activeSubItem = subItems?.find(isSubItemActive(router));
|
|
963
|
+
const topMenu = mergedItems.map((_, i) => (jsx(TopItem, { active: _ === activeTopItem, ...useLink({ router, handlerDecorator }, _), ariaLabel: _.text }, String(i))));
|
|
964
|
+
const subMenu = subItems?.map((_) => (jsx(HeaderItem, { className: "mr-8", active: _ === activeSubItem, ...useLink({ router, handlerDecorator }, _) }, _.href)));
|
|
965
|
+
return (jsxs("header", { className: `pt-5 pb-8 px-20 bg-white ${className || ''}`, 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 })] }));
|
|
966
|
+
});
|
|
967
|
+
|
|
968
|
+
const MiniGallery = JSX((props) => (jsx(GalleryInner, { ...props, version: "mini" })));
|
|
969
|
+
|
|
970
|
+
const MobileAppTile = JSX(({ className, context, title = 'Мобильное приложение', qr, buttons = [] }) => {
|
|
971
|
+
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" })] }) }));
|
|
972
|
+
});
|
|
973
|
+
|
|
974
|
+
const GOLDEN_RATIO = 1.618;
|
|
975
|
+
const Placeholder = JSX(({ className, context, title }) => {
|
|
976
|
+
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() }) }));
|
|
977
|
+
});
|
|
978
|
+
const renderShimmer = (size = 3) => goldenSequence(100, size)
|
|
979
|
+
.map((_) => Math.floor(_))
|
|
980
|
+
.map(renderShimmerItem);
|
|
981
|
+
const renderShimmerItem = (width = 100, index) => (jsx("div", { style: { width: `${width}%` }, className: "h-4 mt-2 bg-secondary-light" }, String(index)));
|
|
982
|
+
const goldenSequence = (first, size) => [first].concat(size > 0 ? goldenSequence(first / GOLDEN_RATIO, size - 1) : []);
|
|
983
|
+
|
|
984
|
+
const ProductBlockInner = JSX(({ className, context, title, titleSize, description, benefits, buttons, image, items }) => {
|
|
985
|
+
return (jsxs("div", { className: `flex grow justify-between items-stretch ${className || ''}`, children: [jsxs("div", { className: 'flex flex-col', children: [title && (
|
|
986
|
+
/* TODO Why <Title> is duplicated here? */
|
|
987
|
+
jsx(Title, { size: titleSize || 'XL', className: "font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px] text-primary-text", children: title })), jsx(BaseTile, { context: context, description: description, items: items, buttons: buttons, children: benefits?.length ? (jsx("div", { className: "flex gap-6 mt-6 mb-3.5", children: benefits.map(renderBenefit) })) : null })] }), image?.src && jsx(Img, { className: "mt-auto", image: image })] }));
|
|
988
|
+
});
|
|
989
|
+
function renderBenefit(benefit, i) {
|
|
990
|
+
return (jsxs("div", { className: "flex gap-4 items-center", children: [benefit.icon && (jsx(Icon, { className: "w-[50px] h-[50px] min-w-[50px] min-h-[50px] bg-main rounded-full p-[10px] box-border", name: benefit.icon, width: "24", height: "24" })), jsxs("div", { className: "flex gap-1 flex-col h-full", children: [jsx("h4", { className: "font-medium text-primary-text text-xl m-0", children: benefit.label }), benefit.description && (jsx("div", { className: "font-normal text-sm text-secondary-text", children: benefit.description }))] })] }, String(i)));
|
|
991
|
+
}
|
|
992
|
+
|
|
993
|
+
const Breadcrumb = JSX(({ text, href, target, onClick, className, children }) => {
|
|
994
|
+
if (href) {
|
|
995
|
+
return (jsx("a", { className: `no-underline ${className || ''}`, href: href, target: target, onClick: onClick, children: jsx("span", { className: `${className || ''}`, children: text || children }) }));
|
|
996
|
+
}
|
|
997
|
+
else {
|
|
998
|
+
return jsx("span", { className: `${className || ''}`, children: text || children });
|
|
999
|
+
}
|
|
1000
|
+
});
|
|
1001
|
+
|
|
1002
|
+
function joinList(sep) {
|
|
1003
|
+
return (list) => list.reduce((acc, el, i) => (acc.length ? acc.concat({ ...sep, key: i }, el) : [el]), []);
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
const ProductBlock$1 = JSX((props) => {
|
|
1007
|
+
const { context, className, breadcrumbs } = props;
|
|
1008
|
+
const router = context.useRouter();
|
|
1009
|
+
const { handlerDecorator } = context;
|
|
1010
|
+
return (jsxs("section", { className: `font-sans bg-white pt-10 pl-[50px] pb-[50px] pr-[7.5rem] ${className || ''}`, children: [breadcrumbs?.length ? (jsx("div", { className: "text-xs mb-6", children: joinList(jsx("span", { className: "text-secondary-text mx-2", children: "/" }))(breadcrumbs.map((breadcrumb, i) => (jsx(Breadcrumb, { ...useLink({ router, handlerDecorator }, { className: 'text-secondary-text', ...breadcrumb }) }, String(i))))) })) : null, jsx(ProductBlockInner, { ...props })] }));
|
|
1011
|
+
});
|
|
1012
|
+
|
|
1013
|
+
const ProductGallery = JSX(({ className, context, duration = 0, slides = [] }) => {
|
|
1014
|
+
const galleryNav = slides.map((s) => s.nav);
|
|
1015
|
+
const galleryBlocks = slides.map((s) => s.productBlock);
|
|
1016
|
+
const [activeSlideIndex, setActiveSlideIndex] = context.useState(0);
|
|
1017
|
+
return (jsxs("section", { className: `font-sans bg-white overflow-hidden w-100 ${className || ''}`, children: [jsx("div", { className: `flex duration-1000`, style: { transform: `translateX(-${activeSlideIndex}00%)` }, role: "list", children: galleryBlocks.map((_, i) => renderProductBlock(_, i, context)) }), jsx("div", { className: `border-t border-solid border-main-divider flex`, children: galleryNav.map((slide, i) => renderNavButton({
|
|
1018
|
+
slide,
|
|
1019
|
+
i,
|
|
1020
|
+
activeSlideIndex,
|
|
1021
|
+
onClick: () => setActiveSlideIndex(i),
|
|
1022
|
+
duration,
|
|
1023
|
+
})) })] }));
|
|
1024
|
+
});
|
|
1025
|
+
function renderProductBlock(block, i, context) {
|
|
1026
|
+
return (jsx("section", { className: "flex grow-0 shrink-0 basis-full", role: "listitem", children: jsx("div", { className: "p-10 flex grow", children: jsx(ProductBlockInner, { className: "pl-2.5 pt-2.5 pb-1.5 pr-[6.25rem]", context: context, ...block }) }) }, String(i)));
|
|
1027
|
+
}
|
|
1028
|
+
function renderNavButton({ slide, i, activeSlideIndex, onClick, duration }) {
|
|
1029
|
+
const isActiveBtn = i === activeSlideIndex;
|
|
1030
|
+
const progressBarClassName = isActiveBtn ? 'animate-slide' : '';
|
|
1031
|
+
const btnTitleClassName = isActiveBtn ? 'text-primary-text' : 'text-secondary-text';
|
|
1032
|
+
return (jsxs("button", { type: "button", onClick: onClick, className: `group relative overflow-hidden border-0 bg-inherit cursor-pointer text-left px-0 py-4 grow basis-0`, children: [jsxs("div", { className: "border-0 border-r border-solid border-main-divider px-6", children: [jsx("div", { className: `text-sm font-medium group-hover:text-primary-text ${btnTitleClassName}`, children: slide?.title }), jsx("div", { className: "text-xs text-secondary-text", children: slide.desc })] }), jsx("div", { className: `absolute bottom-0 left-0 w-full h-[3px] bg-primary-main -translate-x-full ${progressBarClassName}`, style: { animationDuration: `${duration}s` } })] }, String(i)));
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
const ProductTile = JSX((props) => {
|
|
1036
|
+
const { benefits, version } = props;
|
|
1037
|
+
return (jsx(Tile, { ...props, children: jsxs("div", { className: "flex mt-5 mb-1", children: [benefits?.length ? (jsx("div", { className: "mr-8", children: benefits.map(renderBenefitDescription) })) : null, benefits?.length ? (jsx("div", { className: "pt-1", children: benefits.map((_, i) => renderBenefitLabel(_, i, version)) })) : null] }) }));
|
|
1038
|
+
});
|
|
1039
|
+
function renderBenefitLabel(benefit, i, version = 'primary') {
|
|
1040
|
+
const labelStyleMap = {
|
|
1041
|
+
primary: 'text-secondary-text',
|
|
1042
|
+
secondary: 'text-white',
|
|
1043
|
+
};
|
|
1044
|
+
return (jsx("div", { className: `text-sm ${i ? 'mt-4' : ''} ${labelStyleMap[version]}`, children: benefit.label }, String(i)));
|
|
1045
|
+
}
|
|
1046
|
+
function renderBenefitDescription(benefit, i) {
|
|
1047
|
+
return (jsx("div", { className: `text-xl font-medium ${i ? 'mt-2.5' : ''}`, children: benefit.description }, String(i)));
|
|
1048
|
+
}
|
|
1049
|
+
|
|
1050
|
+
const PromoTile = JSX(({ className, context, title = 'Акции и спецпредложения', date, description, buttons = [], version, }) => {
|
|
1051
|
+
return (jsx(Tile, { className: className, context: context, title: title, buttons: buttons, version: version, children: jsxs("div", { children: [date && jsx("div", { className: "text-sm mb-2", children: formatDate(date) }), jsx("div", { className: "text-base", children: description })] }) }));
|
|
1052
|
+
});
|
|
1053
|
+
function formatDate(date) {
|
|
1054
|
+
const dateObj = new Date(date);
|
|
1055
|
+
const dateFormat = {
|
|
1056
|
+
day: 'numeric',
|
|
1057
|
+
month: 'long',
|
|
1058
|
+
year: 'numeric',
|
|
1059
|
+
};
|
|
1060
|
+
return dateObj.toLocaleString('ru-RU', dateFormat).replace('г.', '');
|
|
1061
|
+
}
|
|
1062
|
+
|
|
1063
|
+
const StepsBlock = JSX(({ className, title, steps }) => {
|
|
1064
|
+
return (jsxs("section", { className: `font-sans text-primary-text bg-white px-12 py-12 flex flex-col items-center ${className || ''}`, children: [jsx(Title, { className: "font-medium m-0 max-w-[47rem] text-center", children: title }), steps?.length ? (jsxs("div", { children: [jsx("div", { className: "flex mt-9 items-center px-[88px]", children: joinList(jsx("div", { className: "h-0.5 w-full bg-secondary-light" }))(steps.map((step, i) => renderStepIcon(step, i))) }), jsx("div", { className: "flex mt-9 justify-between gap-x-24", children: steps.map(renderStepTitle) })] })) : null] }));
|
|
1065
|
+
});
|
|
1066
|
+
const renderStepIcon = (step, i) => {
|
|
1067
|
+
return (jsx("div", { className: "flex flex-col items-center text-center relative", children: jsx("div", { className: "h-[100px] w-[100px] min-w-[100px] min-h-[100px] bg-secondary-light rounded-full p-[26px] box-border z-10", children: (step.icon && jsx(Icon, { name: step.icon, width: "48", height: "48" })) || (jsx("span", { className: "font-medium text-title-sm text-secondary-text", children: i + 1 })) }) }, String(i)));
|
|
1068
|
+
};
|
|
1069
|
+
const renderStepTitle = (step, i) => {
|
|
1070
|
+
return (jsx("div", { className: "flex flex-col items-center text-center relative w-[276px]", children: jsxs("div", { className: "max-w-min", children: [jsx("h5", { className: "font-medium text-xl m-0 mt-4 whitespace-nowrap px-3", children: step.label }), step.description && (jsx("div", { className: "font-normal text-sm text-secondary-text mt-2", children: step.description }))] }) }, String(i)));
|
|
1071
|
+
};
|
|
1072
|
+
|
|
1073
|
+
const Blocks = {
|
|
1074
|
+
Accordion,
|
|
1023
1075
|
BenefitsBlock,
|
|
1024
|
-
|
|
1076
|
+
ComparisonTable,
|
|
1077
|
+
CreditCalculator,
|
|
1025
1078
|
ExchangeRateTile,
|
|
1026
|
-
|
|
1079
|
+
Footer: Footer$1,
|
|
1027
1080
|
Gallery: Gallery$1,
|
|
1081
|
+
Header,
|
|
1082
|
+
Headline,
|
|
1083
|
+
LinkDocs,
|
|
1028
1084
|
MiniGallery,
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1085
|
+
MobileAppTile,
|
|
1086
|
+
PictureText,
|
|
1087
|
+
Placeholder,
|
|
1088
|
+
ProductBlock: ProductBlock$1,
|
|
1089
|
+
ProductGallery,
|
|
1090
|
+
ProductTile,
|
|
1091
|
+
PromoTile,
|
|
1092
|
+
StepsBlock,
|
|
1093
|
+
TextBlock,
|
|
1094
|
+
Tile,
|
|
1032
1095
|
};
|
|
1033
1096
|
|
|
1034
1097
|
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() })));
|
|
@@ -1115,16 +1178,18 @@
|
|
|
1115
1178
|
});
|
|
1116
1179
|
|
|
1117
1180
|
const MobileBlocks = {
|
|
1118
|
-
|
|
1181
|
+
ExchangeRateTile,
|
|
1119
1182
|
Footer,
|
|
1183
|
+
Gallery,
|
|
1184
|
+
Header,
|
|
1185
|
+
Headline,
|
|
1186
|
+
MobileAppTile,
|
|
1187
|
+
PictureText,
|
|
1120
1188
|
Placeholder,
|
|
1121
|
-
Tile,
|
|
1122
|
-
ProductTile,
|
|
1123
1189
|
ProductBlock,
|
|
1190
|
+
ProductTile,
|
|
1124
1191
|
TextBlock,
|
|
1125
|
-
|
|
1126
|
-
MobileAppTile,
|
|
1127
|
-
Gallery,
|
|
1192
|
+
Tile,
|
|
1128
1193
|
// TODO StepsBlock,
|
|
1129
1194
|
// TODO BenefitsBlock,
|
|
1130
1195
|
// TODO ProductGallery
|