@redneckz/wildless-cms-uni-blocks 0.10.0 → 0.10.1
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/bin/migration-scripts/0.9.10.js +30 -0
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +35 -25
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/Footer/FooterContent.d.ts +1 -1
- package/bundle/components/ProductBlock/ProductBlockContent.d.ts +1 -2
- package/bundle/components/ProductBlock/renderBackwardButton.d.ts +1 -1
- package/bundle/components/ProductTile/ProductTileContent.d.ts +1 -1
- package/bundle/components/ProductTile/renderImage.d.ts +1 -1
- package/bundle/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.d.ts +5 -0
- package/bundle/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.d.ts +18 -0
- package/bundle/components/Tile/TileContent.d.ts +2 -0
- package/dist/components/Blocks.js +2 -0
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
- package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/dist/components/Footer/FooterContent.d.ts +1 -1
- package/dist/components/Headline/Headline.js +1 -1
- package/dist/components/Headline/Headline.js.map +1 -1
- package/dist/components/ProductBlock/ProductBlock.js +2 -3
- package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
- package/dist/components/ProductBlock/ProductBlockContent.d.ts +1 -2
- package/dist/components/ProductBlock/ProductBlockInner.js +2 -2
- package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/dist/components/ProductBlock/renderBackwardButton.d.ts +1 -1
- package/dist/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/dist/components/ProductTile/ProductTile.js +4 -2
- package/dist/components/ProductTile/ProductTile.js.map +1 -1
- package/dist/components/ProductTile/ProductTileContent.d.ts +1 -1
- package/dist/components/ProductTile/renderImage.d.ts +1 -1
- package/dist/components/ProductTile/renderImage.js +3 -2
- package/dist/components/ProductTile/renderImage.js.map +1 -1
- package/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.d.ts +5 -0
- package/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js +22 -0
- package/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js.map +1 -0
- package/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.d.ts +18 -0
- package/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js +2 -0
- package/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js.map +1 -0
- package/dist/components/Tile/Tile.js +5 -4
- package/dist/components/Tile/Tile.js.map +1 -1
- package/dist/components/Tile/TileContent.d.ts +2 -0
- package/lib/common.css +1 -1
- package/lib/components/Blocks.js +2 -0
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
- package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/lib/components/Footer/FooterContent.d.ts +1 -1
- package/lib/components/Headline/Headline.js +1 -1
- package/lib/components/Headline/Headline.js.map +1 -1
- package/lib/components/ProductBlock/ProductBlock.fixture.d.ts +0 -1
- package/lib/components/ProductBlock/ProductBlock.js +2 -3
- package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
- package/lib/components/ProductBlock/ProductBlockContent.d.ts +1 -2
- package/lib/components/ProductBlock/ProductBlockInner.js +2 -2
- package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/lib/components/ProductBlock/renderBackwardButton.d.ts +1 -1
- package/lib/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/lib/components/ProductTile/ProductTile.js +4 -2
- package/lib/components/ProductTile/ProductTile.js.map +1 -1
- package/lib/components/ProductTile/ProductTileContent.d.ts +1 -1
- package/lib/components/ProductTile/renderImage.d.ts +1 -1
- package/lib/components/ProductTile/renderImage.js +3 -2
- package/lib/components/ProductTile/renderImage.js.map +1 -1
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.d.ts +5 -0
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.fixture.d.ts +6 -0
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js +20 -0
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js.map +1 -0
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.d.ts +18 -0
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js +2 -0
- package/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js.map +1 -0
- package/lib/components/Tile/Tile.fixture.d.ts +1 -0
- package/lib/components/Tile/Tile.js +5 -4
- package/lib/components/Tile/Tile.js.map +1 -1
- package/lib/components/Tile/TileContent.d.ts +2 -0
- package/mobile/bundle/bundle.umd.js +2 -2
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/Footer/FooterContent.d.ts +1 -1
- package/mobile/bundle/components/ProductBlock/ProductBlockContent.d.ts +1 -2
- package/mobile/bundle/components/ProductBlock/renderBackwardButton.d.ts +1 -1
- package/mobile/bundle/components/ProductTile/ProductTileContent.d.ts +1 -1
- package/mobile/bundle/components/ProductTile/renderImage.d.ts +1 -1
- package/mobile/bundle/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.d.ts +5 -0
- package/mobile/bundle/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.d.ts +18 -0
- package/mobile/bundle/components/Tile/TileContent.d.ts +2 -0
- package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
- package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/mobile/dist/components/Footer/FooterContent.d.ts +1 -1
- package/mobile/dist/components/Headline/Headline.js +1 -1
- package/mobile/dist/components/Headline/Headline.js.map +1 -1
- package/mobile/dist/components/ProductBlock/ProductBlockContent.d.ts +1 -2
- package/mobile/dist/components/ProductBlock/renderBackwardButton.d.ts +1 -1
- package/mobile/dist/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/mobile/dist/components/ProductTile/ProductTile.js +4 -2
- package/mobile/dist/components/ProductTile/ProductTile.js.map +1 -1
- package/mobile/dist/components/ProductTile/ProductTileContent.d.ts +1 -1
- package/mobile/dist/components/ProductTile/renderImage.d.ts +1 -1
- package/mobile/dist/components/ProductTile/renderImage.js +3 -2
- package/mobile/dist/components/ProductTile/renderImage.js.map +1 -1
- package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.d.ts +5 -0
- package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js +22 -0
- package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js.map +1 -0
- package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.d.ts +18 -0
- package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js +2 -0
- package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js.map +1 -0
- package/mobile/dist/components/Tile/Tile.js +5 -4
- package/mobile/dist/components/Tile/Tile.js.map +1 -1
- package/mobile/dist/components/Tile/TileContent.d.ts +2 -0
- package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
- package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/mobile/lib/components/Footer/FooterContent.d.ts +1 -1
- package/mobile/lib/components/Headline/Headline.js +1 -1
- package/mobile/lib/components/Headline/Headline.js.map +1 -1
- package/mobile/lib/components/ProductBlock/ProductBlockContent.d.ts +1 -2
- package/mobile/lib/components/ProductBlock/renderBackwardButton.d.ts +1 -1
- package/mobile/lib/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/mobile/lib/components/ProductTile/ProductTile.js +4 -2
- package/mobile/lib/components/ProductTile/ProductTile.js.map +1 -1
- package/mobile/lib/components/ProductTile/ProductTileContent.d.ts +1 -1
- package/mobile/lib/components/ProductTile/renderImage.d.ts +1 -1
- package/mobile/lib/components/ProductTile/renderImage.js +3 -2
- package/mobile/lib/components/ProductTile/renderImage.js.map +1 -1
- package/mobile/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.d.ts +5 -0
- package/mobile/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js +20 -0
- package/mobile/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.js.map +1 -0
- package/mobile/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.d.ts +18 -0
- package/mobile/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js +2 -0
- package/mobile/lib/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js.map +1 -0
- package/mobile/lib/components/Tile/Tile.js +5 -4
- package/mobile/lib/components/Tile/Tile.js.map +1 -1
- package/mobile/lib/components/Tile/TileContent.d.ts +2 -0
- package/mobile/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +4 -2
- package/mobile/src/components/Footer/FooterContent.ts +1 -1
- package/mobile/src/components/Headline/Headline.tsx +1 -5
- package/mobile/src/components/ProductBlock/ProductBlockContent.ts +0 -2
- package/mobile/src/components/ProductBlock/renderBackwardButton.tsx +1 -1
- package/mobile/src/components/ProductTile/ProductTile.tsx +11 -6
- package/mobile/src/components/ProductTile/ProductTileContent.ts +1 -1
- package/mobile/src/components/ProductTile/renderImage.tsx +3 -2
- package/mobile/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.example.json +10 -0
- package/mobile/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.tsx +82 -0
- package/mobile/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.ui.json +20 -0
- package/mobile/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.ts +22 -0
- package/mobile/src/components/Tile/Tile.example.json +2 -1
- package/mobile/src/components/Tile/Tile.tsx +26 -17
- package/mobile/src/components/Tile/TileContent.ts +2 -0
- package/package.json +2 -2
- package/src/components/Blocks.ts +2 -0
- package/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +4 -2
- package/src/components/Footer/FooterContent.ts +1 -1
- package/src/components/Headline/Headline.tsx +1 -5
- package/src/components/ProductBlock/ProductBlock.fixture.tsx +14 -22
- package/src/components/ProductBlock/ProductBlock.tsx +5 -6
- package/src/components/ProductBlock/ProductBlockContent.ts +0 -2
- package/src/components/ProductBlock/ProductBlockInner.tsx +21 -25
- package/src/components/ProductBlock/renderBackwardButton.tsx +1 -1
- package/src/components/ProductTile/ProductTile.fixture.tsx +6 -2
- package/src/components/ProductTile/ProductTile.tsx +11 -6
- package/src/components/ProductTile/ProductTileContent.ts +1 -1
- package/src/components/ProductTile/renderImage.tsx +3 -2
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.example.json +10 -0
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.fixture.tsx +37 -0
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.tsx +82 -0
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.ui.json +20 -0
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.ts +22 -0
- package/src/components/Tile/Tile.example.json +2 -1
- package/src/components/Tile/Tile.fixture.tsx +5 -0
- package/src/components/Tile/Tile.tsx +26 -17
- package/src/components/Tile/TileContent.ts +2 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2
|
+
exports.RepresentativeOfficeInfo = void 0;
|
|
3
|
+
const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
|
|
4
|
+
const uni_jsx_1 = require("@redneckz/uni-jsx");
|
|
5
|
+
const BlockWrapper_1 = require("../../ui-kit/BlockWrapper");
|
|
6
|
+
const getIconWithVersion_1 = require("../../utils/getIconWithVersion");
|
|
7
|
+
const Heading_1 = require("../../ui-kit/Heading/Heading");
|
|
8
|
+
const Icon_1 = require("../../ui-kit/Icon/Icon");
|
|
9
|
+
const Img_1 = require("../../ui-kit/Img/Img");
|
|
10
|
+
const RichText_1 = require("../../ui-kit/RichText/RichText");
|
|
11
|
+
const Text_1 = require("../../ui-kit/Text/Text");
|
|
12
|
+
const renderButtonsSection_1 = require("../../ui-kit/Button/renderButtonsSection");
|
|
13
|
+
const style_1 = require("../../utils/style");
|
|
14
|
+
exports.RepresentativeOfficeInfo = (0, uni_jsx_1.JSX)(({ address, email, telephone, button, className = '', __html, icon, title, version = 'primary', ...rest }) => ((0, jsx_runtime_1.jsxs)(BlockWrapper_1.BlockWrapper, { className: (0, style_1.style)('box-border text-left p-9', className), version: version, ...rest, children: [(0, jsx_runtime_1.jsxs)("div", { className: "w-full flex justify-between", children: [title ? (0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: "h4", as: "h3", className: "mb-6", title: title }) : null, renderIconBlock(icon)] }), (0, jsx_runtime_1.jsxs)("div", { className: "w-full", children: [__html ? renderDescriptionBlock(__html) : null, renderBlock('Адрес', address, 'GeolocationIcon'), renderBlock('Телефон', telephone, 'PhoneIcon'), renderBlock('E-mail', email, 'MailIcon'), button?.text
|
|
15
|
+
? (0, renderButtonsSection_1.renderButtonsSection)([button], {
|
|
16
|
+
className: 'mb-6',
|
|
17
|
+
})
|
|
18
|
+
: null] })] })));
|
|
19
|
+
const renderIconBlock = (icon) => ((0, jsx_runtime_1.jsxs)("div", { className: "self-end", children: [icon?.src ? (0, jsx_runtime_1.jsx)(Img_1.Img, { image: icon }) : null, icon?.icon ? (0, jsx_runtime_1.jsx)(Img_1.Img, { image: (0, getIconWithVersion_1.getIconWithVersion)(icon), asSVG: true }) : null] }));
|
|
20
|
+
const renderDescriptionBlock = (__html) => ((0, jsx_runtime_1.jsx)("div", { className: "border-b border-main-divider pb-5 my-5", children: (0, jsx_runtime_1.jsx)(RichText_1.RichText, { __html: __html }) }));
|
|
21
|
+
const renderBlock = (blockName, data, iconName) => ((0, jsx_runtime_1.jsxs)("div", { className: "flex mb-4", children: [(0, jsx_runtime_1.jsx)(Icon_1.Icon, { className: "pr-4", iconVersion: "black", name: iconName, width: "24", height: "24", asSVG: true }), (0, jsx_runtime_1.jsxs)("div", { className: "flex flex-col first:pb-1", children: [(0, jsx_runtime_1.jsx)(Text_1.Text, { size: "text-m-light", children: blockName }), data ? ((0, jsx_runtime_1.jsx)(Text_1.Text, { size: "text-h6", color: "text-green", children: data })) : null] })] }));
|
|
22
|
+
//# sourceMappingURL=RepresentativeOfficeInfo.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RepresentativeOfficeInfo.js","sourceRoot":"","sources":["../../../src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAKxC,4DAAyD;AACzD,uEAAoE;AACpE,0DAAuD;AACvD,iDAA8C;AAC9C,8CAA2C;AAC3C,6DAA0D;AAC1D,iDAA8C;AAC9C,mFAAgF;AAChF,6CAA0C;AAM7B,QAAA,wBAAwB,GAAG,IAAA,aAAG,EACzC,CAAC,EACC,OAAO,EACP,KAAK,EACL,SAAS,EACT,MAAM,EACN,SAAS,GAAG,EAAE,EACd,MAAM,EACN,IAAI,EACJ,KAAK,EACL,OAAO,GAAG,SAAS,EACnB,GAAG,IAAI,EACR,EAAE,EAAE,CAAC,CACJ,wBAAC,2BAAY,IACX,SAAS,EAAE,IAAA,aAAK,EAAC,0BAA0B,EAAE,SAAS,CAAC,EACvD,OAAO,EAAE,OAAO,KACZ,IAAI,aAER,iCAAK,SAAS,EAAC,6BAA6B,aACzC,KAAK,CAAC,CAAC,CAAC,uBAAC,iBAAO,IAAC,WAAW,EAAC,IAAI,EAAC,EAAE,EAAC,IAAI,EAAC,SAAS,EAAC,MAAM,EAAC,KAAK,EAAE,KAAK,GAAI,CAAC,CAAC,CAAC,IAAI,EAClF,eAAe,CAAC,IAAI,CAAC,IAClB,EACN,iCAAK,SAAS,EAA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C1F,iCAAK,SAAS,EAAC,0BAA0B,aACvC,uBAAC,WAAI,IAAC,IAAI,EAAC,cAAc,YAAE,SAAS,GAAQ,EAC3C,IAAI,CAAC,CAAC,CAAC,CACN,uBAAC,WAAI,IAAC,IAAI,EAAC,SAAS,EAAC,KAAK,EAAC,YAAY,YACpC,IAAI,GACA,CACR,CAAC,CAAC,CAAC,IAAI,IACJ,IACF,CACP,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
|
|
2
|
+
import type { IconProps } from '../../model/Picture';
|
|
3
|
+
import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
|
|
4
|
+
import type { TitleProps } from '../../model/HeadlineType';
|
|
5
|
+
import type { UniBlockContent } from '../../model/JSXBlock';
|
|
6
|
+
/**
|
|
7
|
+
* @title Блок с информацией о представительстве
|
|
8
|
+
*/
|
|
9
|
+
export declare type RepresentativeOfficeInfoContent = UniBlockContent & TitleProps & RichTextProps & IconProps & {
|
|
10
|
+
/** @title Адрес */
|
|
11
|
+
address?: string;
|
|
12
|
+
/** @title Телефон (факс) */
|
|
13
|
+
telephone?: string;
|
|
14
|
+
/** @title E-mail */
|
|
15
|
+
email?: string;
|
|
16
|
+
/** @title Кнопка */
|
|
17
|
+
button?: ButtonWithIconProps;
|
|
18
|
+
};
|
package/mobile/dist/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RepresentativeOfficeInfoContent.js","sourceRoot":"","sources":["../../../src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.ts"],"names":[],"mappings":""}
|
|
@@ -12,8 +12,9 @@ const Tags_1 = require("../../ui-kit/Tags/Tags");
|
|
|
12
12
|
const BaseTile_1 = require("../BaseTile/BaseTile");
|
|
13
13
|
const getTileMinHeight_1 = require("../BaseTile/getTileMinHeight");
|
|
14
14
|
const getTileRightPadding_1 = require("../BaseTile/getTileRightPadding");
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
const style_1 = require("../../utils/style");
|
|
16
|
+
exports.Tile = (0, uni_jsx_1.JSX)(({ title, headingType = 'h3', __html, items, buttons, image, isDotted = true, listItemSize = 'M', className = '', tags, children, directionRight = true, ...rest }) => ((0, jsx_runtime_1.jsxs)(BlockWrapper_1.BlockWrapper, { className: (0, style_1.style)('flex grow justify-between items-stretch h-full p-9 pr-3 box-border', (0, getTileRightPadding_1.getTileRightPadding)(className), (0, getTileMinHeight_1.getTileMinHeight)(className), className), ...rest, children: [image?.src ? ((0, jsx_runtime_1.jsx)(Img_1.Img, { className: (0, style_1.style)('mt-auto ml-7', directionRight ? 'order-2' : ''), image: image })) : null, (0, jsx_runtime_1.jsx)(BaseTile_1.BaseTile, { title: title ? ((0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: headingType, as: "h2", title: title, className: `whitespace-pre-wrap max-w-[600px]` })) : null, buttons: (0, renderButtonsSection_1.renderButtonsSection)(buttons, {
|
|
17
|
+
className: 'mt-8',
|
|
18
|
+
buttonClassName: 'min-w-[158px]',
|
|
19
|
+
}), children: (0, jsx_runtime_1.jsxs)("div", { children: [__html ? ((0, jsx_runtime_1.jsx)("div", { className: "max-w-[600px] mt-2.5", children: (0, jsx_runtime_1.jsx)(RichText_1.RichText, { __html: __html }) })) : null, children, (0, jsx_runtime_1.jsx)(List_1.List, { className: "mt-2.5", itemClassName: "mb-1.5", items: items, isDotted: isDotted, listItemSize: listItemSize }), tags?.length ? (0, jsx_runtime_1.jsx)(Tags_1.Tags, { tags: tags, className: "mt-5" }) : null] }) })] })));
|
|
19
20
|
//# sourceMappingURL=Tile.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tile.js","sourceRoot":"","sources":["../../../src/components/Tile/Tile.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAExC,4DAAyD;AACzD,m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Z,SAAS,EAAE,mCAAmC,GAC9C,CACH,CAAC,CAAC,CAAC,IAAI,EAEV,OAAO,EAAE,IAAA,2CAAoB,EAAC,OAAO,EAAE;gBACrC,SAAS,EAAE,MAAM;gBACjB,eAAe,EAAE,eAAe;aACjC,CAAC,YAEF,4CACG,MAAM,CAAC,CAAC,CAAC,CACR,gCAAK,SAAS,EAAC,sBAAsB,YACnC,uBAAC,mBAAQ,IAAC,MAAM,EAAE,MAAM,GAAI,GACxB,CACP,CAAC,CAAC,CAAC,IAAI,EACP,QAAQ,EACT,uBAAC,WAAI,IACH,SAAS,EAAC,QAAQ,EAClB,aAAa,EAAC,QAAQ,EACtB,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,QAAQ,EAClB,YAAY,EAAE,YAAY,GAC1B,EACD,IAAI,EAAE,MAAM,CAAC,CAAC,CAAC,uBAAC,WAAI,IAAC,IAAI,EAAE,IAAI,EAAE,SAAS,EAAC,MAAM,GAAG,CAAC,CAAC,CAAC,IAAI,IACxD,GACG,IACE,CAChB,CACF,CAAC"}
|
|
@@ -12,4 +12,6 @@ import type { TagsContent } from '../../ui-kit/Tags/TagsContent';
|
|
|
12
12
|
*/
|
|
13
13
|
export declare type TileContent = UniBlockContent & HeadingCommonProps & RichTextProps & ListContent & ButtonContent & TagsContent & ImageContent & BulletsProps & {
|
|
14
14
|
listItemSize?: ListItemSize;
|
|
15
|
+
/** @title Картинка справа/текст слева */
|
|
16
|
+
directionRight?: boolean;
|
|
15
17
|
};
|
|
@@ -10,6 +10,6 @@ const cardStyleMap = {
|
|
|
10
10
|
black: 'bg-black',
|
|
11
11
|
white: 'bg-white',
|
|
12
12
|
};
|
|
13
|
-
export const CarouselCatalogCard = JSX(({ className = '', title, description, image, price, button, colors, ...rest }) => (_jsxs(BlockWrapper, { className: `border box-border border-gray p-7 min-w-[392px] h-full flex flex-col justify-left ${className}`, ...rest, children: [image?.src ? _jsx(Img, { className: "mb-5 flex justify-center", image: image }) : null, title ? (_jsx(Heading, { headingType: "h6", as: "h4", className: "text-left mb-1.5", title: title })) : null, description ? (_jsx("div", { className: "mb-4", children: _jsx(Paragraph, { size: "text-m", align: "text-left", font: "font-light", children: description }) })) : null, colors?.length ? (_jsxs("div", { className: "flex mb-4 text-
|
|
13
|
+
export const CarouselCatalogCard = JSX(({ className = '', title, description, image, price, button, colors, ...rest }) => (_jsxs(BlockWrapper, { className: `border box-border border-gray p-7 min-w-[392px] h-full flex flex-col justify-left ${className}`, ...rest, children: [image?.src ? _jsx(Img, { className: "mb-5 flex justify-center", image: image }) : null, title ? (_jsx(Heading, { headingType: "h6", as: "h4", className: "text-left mb-1.5", title: title })) : null, description ? (_jsx("div", { className: "mb-4", children: _jsx(Paragraph, { size: "text-m", align: "text-left", font: "font-light", children: description }) })) : null, colors?.length ? (_jsxs("div", { className: "flex mb-4 text-secondary-text", children: [_jsx("div", { className: "mr-1.5", children: _jsx(Text, { size: "text-s", align: "text-left", font: "font-light", children: "\u0414\u043E\u0441\u0442\u0443\u043F\u043D\u044B\u0435 \u0446\u0432\u0435\u0442\u0430:" }) }), colors.map(renderColorOption)] })) : null, price ? (_jsxs(Text, { size: "text-h3", align: "text-left", children: [price, "\u00A0\u20BD"] })) : null, renderButtonsSection([button], { buttonClassName: 'mt-5 w-full' })] })));
|
|
14
14
|
const renderColorOption = (color, i) => (_jsx("div", { role: "figure", className: `w-6 h-6 ml-3 border border-solid border-main-divider rounded-full ${cardStyleMap[color]}` }, String(i)));
|
|
15
15
|
//# sourceMappingURL=CarouselCatalogCard.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CarouselCatalogCard.js","sourceRoot":"","sources":["../../../src/components/CarouselCatalogCard/CarouselCatalogCard.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA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CAAC,CAAC,IAAI,EACP,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC,CAChB,eAAK,SAAS,EAAC,+BAA+B,aAC5C,cAAK,SAAS,EAAC,QAAQ,YACrB,KAAC,IAAI,IAAC,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAC,WAAW,EAAC,IAAI,EAAC,YAAY,uGAEhD,GACH,EACL,MAAM,CAAC,GAAG,CAAC,iBAAiB,CAAC,IAC1B,CACP,CAAC,CAAC,CAAC,IAAI,EACP,KAAK,CAAC,CAAC,CAAC,CACP,MAAC,IAAI,IAAC,IAAI,EAAC,SAAS,EAAC,KAAK,EAAC,WAAW,aACnC,KAAK,oBACD,CACR,CAAC,CAAC,CAAC,IAAI,EACP,oBAAoB,CAAC,CAAC,MAAM,CAAC,EAAE,EAAE,eAAe,EAAE,aAAa,EAAE,CAAC,IACtD,CAChB,CACF,CAAC;AAEF,MAAM,iBAAiB,GAAG,CAAC,KAA0B,EAAE,CAAS,EAAE,EAAE,CAAC,CACnE,cACE,IAAI,EAAC,QAAQ,EAEb,SAAS,EAAE,qEAAqE,YAAY,CAAC,KAAK,CAAC,EAAE,IADhG,MAAM,CAAC,CAAC,CAAC,CAEd,CACH,CAAC"}
|
|
@@ -8,6 +8,6 @@ import { headlineVersionStyles } from './headlineVersionStyles.js';
|
|
|
8
8
|
export const Headline = JSX(({ className, title, description, headlineVersion = 'XL', align = 'text-center', as, isPadding = true, isTheme = false, version = '', ...rest }) => {
|
|
9
9
|
const versionStyle = headlineVersionStyles[headlineVersion];
|
|
10
10
|
const paddingStyle = isPadding ? 'p-12' : '';
|
|
11
|
-
return (_jsxs(BlockWrapper, { className: style('flex flex-col', paddingStyle, versionStyle.wrapper, className), version: version, isTheme: isTheme, ...rest, children: [title ? (_jsx(Heading, { className: style('whitespace-pre-wrap', align), ...versionStyle?.title, as: as || versionStyle?.title.as, title: title })) : null, description ? (_jsx(Paragraph, {
|
|
11
|
+
return (_jsxs(BlockWrapper, { className: style('flex flex-col', paddingStyle, versionStyle.wrapper, className), version: version, isTheme: isTheme, ...rest, children: [title ? (_jsx(Heading, { className: style('whitespace-pre-wrap', align), ...versionStyle?.title, as: as || versionStyle?.title.as, title: title })) : null, description ? (_jsx(Paragraph, { size: versionStyle.descriptionSize, align: align, children: description })) : null] }));
|
|
12
12
|
});
|
|
13
13
|
//# sourceMappingURL=Headline.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Headline.js","sourceRoot":"","sources":["../../../src/components/Headline/Headline.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAE7D,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAIhE,MAAM,CAAC,MAAM,QAAQ,GAAG,GAAG,CACzB,CAAC,EACC,SAAS,EACT,KAAK,EACL,WAAW,EACX,eAAe,GAAG,IAAI,EACtB,KAAK,GAAG,aAAa,EACrB,EAAE,EACF,SAAS,GAAG,IAAI,EAChB,OAAO,GAAG,KAAK,EACf,OAAO,GAAG,EAAE,EACZ,GAAG,IAAI,EACR,EAAE,EAAE;IACH,MAAM,YAAY,GAAG,qBAAqB,CAAC,eAAe,CAAC,CAAC;IAC5D,MAAM,YAAY,GAAG,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;IAE7C,OAAO,CACL,MAAC,YAAY,IACX,SAAS,EAAE,KAAK,CAAC,eAAe,EAAE,YAAY,EAAE,YAAY,CAAC,OAAO,EAAE,SAAS,CAAC,EAChF,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,KACZ,IAAI,aAEP,KAA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AAO,KACZ,IAAI,aAEP,KAAK,CAAC,CAAC,CAAC,CACP,KAAC,OAAO,IACN,SAAS,EAAE,KAAK,CAAC,qBAAqB,EAAE,KAAK,CAAC,KAC1C,YAAY,EAAE,KAAK,EACvB,EAAE,EAAE,EAAE,IAAI,YAAY,EAAE,KAAK,CAAC,EAAE,EAChC,KAAK,EAAE,KAAK,GACZ,CACH,CAAC,CAAC,CAAC,IAAI,EACP,WAAW,CAAC,CAAC,CAAC,CACb,KAAC,SAAS,IAAC,IAAI,EAAE,YAAY,CAAC,eAA2B,EAAE,KAAK,EAAE,KAAK,YACpE,WAAW,GACF,CACb,CAAC,CAAC,CAAC,IAAI,IACK,CAChB,CAAC;AACJ,CAAC,CACF,CAAC"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { BulletsProps } from '../../model/Bullets';
|
|
2
|
-
import type { Footnote } from '../../model/Footnote';
|
|
3
2
|
import type { HeadlineProps } from '../../model/HeadlineType';
|
|
4
3
|
import type { IconVersion } from '../../model/IconVersion';
|
|
5
4
|
import type { UniBlockContent } from '../../model/JSXBlock';
|
|
@@ -9,7 +8,7 @@ import type { BackwardButtonProps, ButtonContent } from '../../ui-kit/Button/But
|
|
|
9
8
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
10
9
|
import type { ListContent } from '../../ui-kit/List/ListContent';
|
|
11
10
|
import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
|
|
12
|
-
export declare type ProductBlockInnerContent = HeadlineProps & RichTextProps & ListContent & ButtonContent &
|
|
11
|
+
export declare type ProductBlockInnerContent = HeadlineProps & RichTextProps & ListContent & ButtonContent & ImageContent & BulletsProps & {
|
|
13
12
|
/**
|
|
14
13
|
* @title Количество преимуществ в строке
|
|
15
14
|
* @enumNames ["2", "3"]
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import type { ButtonVersion } from '../../model/ButtonVersion';
|
|
3
3
|
import type { BackwardButtonProps } from '../../ui-kit/Button/ButtonProps';
|
|
4
|
-
export declare function renderBackwardButton(button: BackwardButtonProps, version: ButtonVersion, className
|
|
4
|
+
export declare function renderBackwardButton(button: BackwardButtonProps, version: ButtonVersion, className?: string): JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"renderBackwardButton.js","sourceRoot":"","sources":["../../../src/components/ProductBlock/renderBackwardButton.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAC;AAEpD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,MAAM,UAAU,oBAAoB,CAClC,MAA2B,EAC3B,OAAsB,EACtB,
|
|
1
|
+
{"version":3,"file":"renderBackwardButton.js","sourceRoot":"","sources":["../../../src/components/ProductBlock/renderBackwardButton.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAC;AAEpD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,MAAM,UAAU,oBAAoB,CAClC,MAA2B,EAC3B,OAAsB,EACtB,SAAkB;IAElB,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM,CAAC;IACtC,MAAM,WAAW,GAAG,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC;IAC9D,MAAM,YAAY,GAAG,MAAM,EAAE,IAAI,IAAI,EAAE,IAAI,EAAE,eAAe,EAAE,CAAC;IAE/D,OAAO,CACL,eAAK,SAAS,EAAE,KAAK,CAAC,mBAAmB,EAAE,SAAS,CAAC,aACnD,KAAC,MAAM,IACL,OAAO,EAAE,OAAO,EAChB,OAAO,QACP,SAAS,EAAC,mEAAmE,EAC7E,SAAS,EAAE,IAAI,EACf,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,YAEd,KAAC,GAAG,IACF,SAAS,EAAC,SAAS,EACnB,KAAK,EAAE,EAAE,GAAG,YAAY,EAAE,WAAW,EAAE,YAAY,CAAC,WAAW,IAAI,WAAW,EAAE,EAChF,KAAK,SACL,GACK,EACR,IAAI,CAAC,CAAC,CAAC,CACN,KAAC,MAAM,IAAC,OAAO,EAAC,MAAM,EAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,IAAI,GAAI,CACnF,CAAC,CAAC,CAAC,IAAI,IACJ,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -8,13 +8,15 @@ import { Headline } from '../Headline/Headline.js';
|
|
|
8
8
|
import { renderAdditionalDescription } from './renderAdditionalDescription.js';
|
|
9
9
|
import { renderBenefit } from './renderBenefit.js';
|
|
10
10
|
import { renderImage } from './renderImage.js';
|
|
11
|
-
export const ProductTile = JSX(({ className = '', title, headlineVersion = 'S', description, additionalDescription, benefits = [], buttons, image,
|
|
11
|
+
export const ProductTile = JSX(({ className = '', title, headlineVersion = 'S', description, additionalDescription, benefits = [], buttons, image, directionRight = true, ...rest }) => (_jsxs(BlockWrapper, { className: style('overflow-hidden p-9 box-border relative min-h-[364px] flex flex-col justify-between', getTileRightPadding(className), className), ...rest, children: [_jsxs("div", { className: style('flex flex-col', directionRight ? '' : 'items-end'), children: [_jsx(Headline, { className: style('!p-0 !bg-transparent z-10', title || description ? 'mb-3.5' : ''), title: title, description: description, headlineVersion: headlineVersion, as: "h2", align: "text-left" }), renderBenefits(benefits, image), renderAdditionalDescription(additionalDescription, image)] }), renderButtonsSection(buttons, {
|
|
12
|
+
className: style('mt-5 text-l', directionRight ? '' : 'justify-end'),
|
|
13
|
+
}), renderImage(image, directionRight)] })));
|
|
12
14
|
function renderBenefits(benefits, image) {
|
|
13
15
|
if (!benefits.length) {
|
|
14
16
|
return null;
|
|
15
17
|
}
|
|
16
18
|
// picture width = 242px. Text can overlay picture 20px deep. Outer paddings_x = 36px. 242-36-20 = 186px
|
|
17
19
|
const benefitsWidth = image?.src ? 'max-w-[calc(100%-186px)]' : '100%';
|
|
18
|
-
return (_jsx("div", { className:
|
|
20
|
+
return (_jsx("div", { className: style('z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline', benefitsWidth), children: benefits.length ? benefits.map(renderBenefit) : null }));
|
|
19
21
|
}
|
|
20
22
|
//# sourceMappingURL=ProductTile.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProductTile.js","sourceRoot":"","sources":["../../../src/components/ProductTile/ProductTile.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AACtE,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,2BAA2B,EAAE,MAAM,+BAA+B,CAAC;AAC5E,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAI5C,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,CAC5B,CAAC,EACC,SAAS,GAAG,EAAE,EACd,KAAK,EACL,eAAe,GAAG,GAAG,EACrB,WAAW,EACX,qBAAqB,EACrB,QAAQ,GAAG,EAAE,EACb,OAAO,EACP,KAAK,EACL,
|
|
1
|
+
{"version":3,"file":"ProductTile.js","sourceRoot":"","sources":["../../../src/components/ProductTile/ProductTile.tsx"],"names":[],"mappings":";AAAA,OA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EAC/B,2BAA2B,CAAC,qBAAqB,EAAE,KAAK,CAAC,IACtD,EACL,oBAAoB,CAAC,OAAO,EAAE;YAC7B,SAAS,EAAE,KAAK,CAAC,aAAa,EAAE,cAAc,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC;SACrE,CAAC,EACD,WAAW,CAAC,KAAK,EAAE,cAAc,CAAC,IACtB,CAChB,CACF,CAAC;AAEF,SAAS,cAAc,CAAC,QAAmB,EAAE,KAAe;IAC1D,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE;QACpB,OAAO,IAAI,CAAC;KACb;IAED,wGAAwG;IACxG,MAAM,aAAa,GAAG,KAAK,EAAE,GAAG,CAAC,CAAC,CAAC,0BAA0B,CAAC,CAAC,CAAC,MAAM,CAAC;IAEvE,OAAO,CACL,cACE,SAAS,EAAE,KAAK,CACd,uFAAuF,EACvF,aAAa,CACd,YAEA,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI,GACjD,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import type { Picture } from '../../model/Picture';
|
|
3
|
-
export declare function renderImage(image?: Picture,
|
|
3
|
+
export declare function renderImage(image?: Picture, directionRight?: boolean): JSX.Element | null;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
|
|
2
2
|
import { Img } from '../../ui-kit/Img/Img.js';
|
|
3
|
-
|
|
3
|
+
import { style } from '../../utils/style.js';
|
|
4
|
+
export function renderImage(image, directionRight) {
|
|
4
5
|
if (!image?.src) {
|
|
5
6
|
return null;
|
|
6
7
|
}
|
|
7
|
-
return (_jsx(Img, { className:
|
|
8
|
+
return (_jsx(Img, { className: style('absolute', directionRight ? 'right-0' : 'left-0', 'bottom-0'), image: image }));
|
|
8
9
|
}
|
|
9
10
|
//# sourceMappingURL=renderImage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"renderImage.js","sourceRoot":"","sources":["../../../src/components/ProductTile/renderImage.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"renderImage.js","sourceRoot":"","sources":["../../../src/components/ProductTile/renderImage.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,MAAM,UAAU,WAAW,CAAC,KAAe,EAAE,cAAwB;IACnE,IAAI,CAAC,KAAK,EAAE,GAAG,EAAE;QACf,OAAO,IAAI,CAAC;KACb;IAED,OAAO,CACL,KAAC,GAAG,IACF,SAAS,EAAE,KAAK,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,EAAE,UAAU,CAAC,EAC/E,KAAK,EAAE,KAAK,GACZ,CACH,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { RepresentativeOfficeInfoContent } from './RepresentativeOfficeInfoContent';
|
|
2
|
+
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
3
|
+
export interface RepresentativeOfficeInfoProps extends RepresentativeOfficeInfoContent, UniBlockProps {
|
|
4
|
+
}
|
|
5
|
+
export declare const RepresentativeOfficeInfo: import("@redneckz/uni-jsx").UNIComponent<RepresentativeOfficeInfoProps, any, any>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
|
|
2
|
+
import { JSX } from '@redneckz/uni-jsx';
|
|
3
|
+
import { BlockWrapper } from '../../ui-kit/BlockWrapper.js';
|
|
4
|
+
import { getIconWithVersion } from '../../utils/getIconWithVersion.js';
|
|
5
|
+
import { Heading } from '../../ui-kit/Heading/Heading.js';
|
|
6
|
+
import { Icon } from '../../ui-kit/Icon/Icon.js';
|
|
7
|
+
import { Img } from '../../ui-kit/Img/Img.js';
|
|
8
|
+
import { RichText } from '../../ui-kit/RichText/RichText.js';
|
|
9
|
+
import { Text } from '../../ui-kit/Text/Text.js';
|
|
10
|
+
import { renderButtonsSection } from '../../ui-kit/Button/renderButtonsSection.js';
|
|
11
|
+
import { style } from '../../utils/style.js';
|
|
12
|
+
export const RepresentativeOfficeInfo = JSX(({ address, email, telephone, button, className = '', __html, icon, title, version = 'primary', ...rest }) => (_jsxs(BlockWrapper, { className: style('box-border text-left p-9', className), version: version, ...rest, children: [_jsxs("div", { className: "w-full flex justify-between", children: [title ? _jsx(Heading, { headingType: "h4", as: "h3", className: "mb-6", title: title }) : null, renderIconBlock(icon)] }), _jsxs("div", { className: "w-full", children: [__html ? renderDescriptionBlock(__html) : null, renderBlock('Адрес', address, 'GeolocationIcon'), renderBlock('Телефон', telephone, 'PhoneIcon'), renderBlock('E-mail', email, 'MailIcon'), button?.text
|
|
13
|
+
? renderButtonsSection([button], {
|
|
14
|
+
className: 'mb-6',
|
|
15
|
+
})
|
|
16
|
+
: null] })] })));
|
|
17
|
+
const renderIconBlock = (icon) => (_jsxs("div", { className: "self-end", children: [icon?.src ? _jsx(Img, { image: icon }) : null, icon?.icon ? _jsx(Img, { image: getIconWithVersion(icon), asSVG: true }) : null] }));
|
|
18
|
+
const renderDescriptionBlock = (__html) => (_jsx("div", { className: "border-b border-main-divider pb-5 my-5", children: _jsx(RichText, { __html: __html }) }));
|
|
19
|
+
const renderBlock = (blockName, data, iconName) => (_jsxs("div", { className: "flex mb-4", children: [_jsx(Icon, { className: "pr-4", iconVersion: "black", name: iconName, width: "24", height: "24", asSVG: true }), _jsxs("div", { className: "flex flex-col first:pb-1", children: [_jsx(Text, { size: "text-m-light", children: blockName }), data ? (_jsx(Text, { size: "text-h6", color: "text-green", children: data })) : null] })] }));
|
|
20
|
+
//# sourceMappingURL=RepresentativeOfficeInfo.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RepresentativeOfficeInfo.js","sourceRoot":"","sources":["../../../src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAKxC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAC9C,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AAC1D,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAC9C,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAM1C,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAG,CACzC,CAAC,EACC,OAAO,EACP,KAAK,EACL,SAAS,EACT,MAAM,EACN,SAAS,GAAG,EAAE,EACd,MAAM,EACN,IAAI,EACJ,KAAK,EACL,OAAO,GAAG,SAAS,EACnB,GAAG,IAAI,EACR,EAAE,EAAE,CAAC,CACJ,MAAC,YAAY,IACX,SAAS,EAAE,KAAK,CAAC,0BAA0B,EAAE,SAAS,CAAC,EACvD,OAAO,EAAE,OAAO,KACZ,IAAI,aAER,eAAK,SAAS,EAAC,6BAA6B,aACzC,KAAK,CAAC,CAAC,CAAC,KAAC,OAAO,IAAC,WAAW,EAAC,IAAI,EAAC,EAAE,EAAC,IAAI,EAAC,SAAS,EAAC,MAAM,EAAC,KAAK,EAAE,KAAK,GAAI,CAA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AAC,IAAI,EAAC,MAAM,EAAC,IAAI,EAAC,KAAK,SAAG,EAC1F,eAAK,SAAS,EAAC,0BAA0B,aACvC,KAAC,IAAI,IAAC,IAAI,EAAC,cAAc,YAAE,SAAS,GAAQ,EAC3C,IAAI,CAAC,CAAC,CAAC,CACN,KAAC,IAAI,IAAC,IAAI,EAAC,SAAS,EAAC,KAAK,EAAC,YAAY,YACpC,IAAI,GACA,CACR,CAAC,CAAC,CAAC,IAAI,IACJ,IACF,CACP,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
|
|
2
|
+
import type { IconProps } from '../../model/Picture';
|
|
3
|
+
import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
|
|
4
|
+
import type { TitleProps } from '../../model/HeadlineType';
|
|
5
|
+
import type { UniBlockContent } from '../../model/JSXBlock';
|
|
6
|
+
/**
|
|
7
|
+
* @title Блок с информацией о представительстве
|
|
8
|
+
*/
|
|
9
|
+
export declare type RepresentativeOfficeInfoContent = UniBlockContent & TitleProps & RichTextProps & IconProps & {
|
|
10
|
+
/** @title Адрес */
|
|
11
|
+
address?: string;
|
|
12
|
+
/** @title Телефон (факс) */
|
|
13
|
+
telephone?: string;
|
|
14
|
+
/** @title E-mail */
|
|
15
|
+
email?: string;
|
|
16
|
+
/** @title Кнопка */
|
|
17
|
+
button?: ButtonWithIconProps;
|
|
18
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RepresentativeOfficeInfoContent.js","sourceRoot":"","sources":["../../../src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfoContent.ts"],"names":[],"mappings":""}
|
|
@@ -10,8 +10,9 @@ import { Tags } from '../../ui-kit/Tags/Tags.js';
|
|
|
10
10
|
import { BaseTile } from '../BaseTile/BaseTile.js';
|
|
11
11
|
import { getTileMinHeight } from '../BaseTile/getTileMinHeight.js';
|
|
12
12
|
import { getTileRightPadding } from '../BaseTile/getTileRightPadding.js';
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
import { style } from '../../utils/style.js';
|
|
14
|
+
export const Tile = JSX(({ title, headingType = 'h3', __html, items, buttons, image, isDotted = true, listItemSize = 'M', className = '', tags, children, directionRight = true, ...rest }) => (_jsxs(BlockWrapper, { className: style('flex grow justify-between items-stretch h-full p-9 pr-3 box-border', getTileRightPadding(className), getTileMinHeight(className), className), ...rest, children: [image?.src ? (_jsx(Img, { className: style('mt-auto ml-7', directionRight ? 'order-2' : ''), image: image })) : null, _jsx(BaseTile, { title: title ? (_jsx(Heading, { headingType: headingType, as: "h2", title: title, className: `whitespace-pre-wrap max-w-[600px]` })) : null, buttons: renderButtonsSection(buttons, {
|
|
15
|
+
className: 'mt-8',
|
|
16
|
+
buttonClassName: 'min-w-[158px]',
|
|
17
|
+
}), children: _jsxs("div", { children: [__html ? (_jsx("div", { className: "max-w-[600px] mt-2.5", children: _jsx(RichText, { __html: __html }) })) : null, children, _jsx(List, { className: "mt-2.5", itemClassName: "mb-1.5", items: items, isDotted: isDotted, listItemSize: listItemSize }), tags?.length ? _jsx(Tags, { tags: tags, className: "mt-5" }) : null] }) })] })));
|
|
17
18
|
//# sourceMappingURL=Tile.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tile.js","sourceRoot":"","sources":["../../../src/components/Tile/Tile.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAC9C,OAAO,EAAE,QAAQ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|
|
12
12
|
*/
|
|
13
13
|
export declare type TileContent = UniBlockContent & HeadingCommonProps & RichTextProps & ListContent & ButtonContent & TagsContent & ImageContent & BulletsProps & {
|
|
14
14
|
listItemSize?: ListItemSize;
|
|
15
|
+
/** @title Картинка справа/текст слева */
|
|
16
|
+
directionRight?: boolean;
|
|
15
17
|
};
|
|
@@ -34,9 +34,11 @@ export const CarouselCatalogCard = JSX<CarouselCatalogCardProps>(
|
|
|
34
34
|
</div>
|
|
35
35
|
) : null}
|
|
36
36
|
{colors?.length ? (
|
|
37
|
-
<div className="flex mb-4 text-
|
|
37
|
+
<div className="flex mb-4 text-secondary-text">
|
|
38
38
|
<div className="mr-1.5">
|
|
39
|
-
<Text
|
|
39
|
+
<Text size="text-s" align="text-left" font="font-light">
|
|
40
|
+
Доступные цвета:
|
|
41
|
+
</Text>
|
|
40
42
|
</div>
|
|
41
43
|
{colors.map(renderColorOption)}
|
|
42
44
|
</div>
|
|
@@ -42,11 +42,7 @@ export const Headline = JSX<HeadlineProps>(
|
|
|
42
42
|
/>
|
|
43
43
|
) : null}
|
|
44
44
|
{description ? (
|
|
45
|
-
<Paragraph
|
|
46
|
-
color="group-data-secondary:text-white/80"
|
|
47
|
-
size={versionStyle.descriptionSize as TextSize}
|
|
48
|
-
align={align}
|
|
49
|
-
>
|
|
45
|
+
<Paragraph size={versionStyle.descriptionSize as TextSize} align={align}>
|
|
50
46
|
{description}
|
|
51
47
|
</Paragraph>
|
|
52
48
|
) : null}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { BulletsProps } from '../../model/Bullets';
|
|
2
|
-
import type { Footnote } from '../../model/Footnote';
|
|
3
2
|
import type { HeadlineProps } from '../../model/HeadlineType';
|
|
4
3
|
import type { IconVersion } from '../../model/IconVersion';
|
|
5
4
|
import type { UniBlockContent } from '../../model/JSXBlock';
|
|
@@ -14,7 +13,6 @@ export type ProductBlockInnerContent = HeadlineProps &
|
|
|
14
13
|
RichTextProps &
|
|
15
14
|
ListContent &
|
|
16
15
|
ButtonContent &
|
|
17
|
-
Footnote &
|
|
18
16
|
ImageContent &
|
|
19
17
|
BulletsProps & {
|
|
20
18
|
/**
|
|
@@ -7,7 +7,7 @@ import { style } from '../../utils/style';
|
|
|
7
7
|
export function renderBackwardButton(
|
|
8
8
|
button: BackwardButtonProps,
|
|
9
9
|
version: ButtonVersion,
|
|
10
|
-
className
|
|
10
|
+
className?: string,
|
|
11
11
|
) {
|
|
12
12
|
const { text, href, target } = button;
|
|
13
13
|
const iconVersion = version === 'primary' ? 'white' : 'black';
|
|
@@ -23,18 +23,18 @@ export const ProductTile = JSX<ProductTileProps>(
|
|
|
23
23
|
benefits = [],
|
|
24
24
|
buttons,
|
|
25
25
|
image,
|
|
26
|
-
|
|
26
|
+
directionRight = true,
|
|
27
27
|
...rest
|
|
28
28
|
}) => (
|
|
29
29
|
<BlockWrapper
|
|
30
30
|
className={style(
|
|
31
|
-
'overflow-hidden p-9 box-border relative min-h-[364px]',
|
|
31
|
+
'overflow-hidden p-9 box-border relative min-h-[364px] flex flex-col justify-between',
|
|
32
32
|
getTileRightPadding(className),
|
|
33
33
|
className,
|
|
34
34
|
)}
|
|
35
35
|
{...rest}
|
|
36
36
|
>
|
|
37
|
-
<div className={style('flex flex-col',
|
|
37
|
+
<div className={style('flex flex-col', directionRight ? '' : 'items-end')}>
|
|
38
38
|
<Headline
|
|
39
39
|
className={style('!p-0 !bg-transparent z-10', title || description ? 'mb-3.5' : '')}
|
|
40
40
|
title={title}
|
|
@@ -45,9 +45,11 @@ export const ProductTile = JSX<ProductTileProps>(
|
|
|
45
45
|
/>
|
|
46
46
|
{renderBenefits(benefits, image)}
|
|
47
47
|
{renderAdditionalDescription(additionalDescription, image)}
|
|
48
|
-
{renderButtonsSection(buttons, { className: 'mt-5 z-10 text-l' })}
|
|
49
48
|
</div>
|
|
50
|
-
{
|
|
49
|
+
{renderButtonsSection(buttons, {
|
|
50
|
+
className: style('mt-5 text-l', directionRight ? '' : 'justify-end'),
|
|
51
|
+
})}
|
|
52
|
+
{renderImage(image, directionRight)}
|
|
51
53
|
</BlockWrapper>
|
|
52
54
|
),
|
|
53
55
|
);
|
|
@@ -62,7 +64,10 @@ function renderBenefits(benefits: Benefit[], image?: Picture) {
|
|
|
62
64
|
|
|
63
65
|
return (
|
|
64
66
|
<div
|
|
65
|
-
className={
|
|
67
|
+
className={style(
|
|
68
|
+
'z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline',
|
|
69
|
+
benefitsWidth,
|
|
70
|
+
)}
|
|
66
71
|
>
|
|
67
72
|
{benefits.length ? benefits.map(renderBenefit) : null}
|
|
68
73
|
</div>
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import type { Picture } from '../../model/Picture';
|
|
2
2
|
import { Img } from '../../ui-kit/Img/Img';
|
|
3
|
+
import { style } from '../../utils/style';
|
|
3
4
|
|
|
4
|
-
export function renderImage(image?: Picture,
|
|
5
|
+
export function renderImage(image?: Picture, directionRight?: boolean) {
|
|
5
6
|
if (!image?.src) {
|
|
6
7
|
return null;
|
|
7
8
|
}
|
|
8
9
|
|
|
9
10
|
return (
|
|
10
11
|
<Img
|
|
11
|
-
className={
|
|
12
|
+
className={style('absolute', directionRight ? 'right-0' : 'left-0', 'bottom-0')}
|
|
12
13
|
image={image}
|
|
13
14
|
/>
|
|
14
15
|
);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Заголовок",
|
|
3
|
+
"__html": "<p>Описание</p>",
|
|
4
|
+
"button": {
|
|
5
|
+
"text": "Информация о регионе",
|
|
6
|
+
"version": "link",
|
|
7
|
+
"icon": { "format": "webp", "size": { "width": 16, "height": 16 } },
|
|
8
|
+
"iconRight": { "format": "webp", "size": { "width": 16, "height": 16 } }
|
|
9
|
+
}
|
|
10
|
+
}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
+
import type { RepresentativeOfficeInfoContent } from './RepresentativeOfficeInfoContent';
|
|
3
|
+
import type { Picture } from '../../model/Picture';
|
|
4
|
+
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
5
|
+
import type { IconName } from '../../icons/IconName';
|
|
6
|
+
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
7
|
+
import { getIconWithVersion } from '../../utils/getIconWithVersion';
|
|
8
|
+
import { Heading } from '../../ui-kit/Heading/Heading';
|
|
9
|
+
import { Icon } from '../../ui-kit/Icon/Icon';
|
|
10
|
+
import { Img } from '../../ui-kit/Img/Img';
|
|
11
|
+
import { RichText } from '../../ui-kit/RichText/RichText';
|
|
12
|
+
import { Text } from '../../ui-kit/Text/Text';
|
|
13
|
+
import { renderButtonsSection } from '../../ui-kit/Button/renderButtonsSection';
|
|
14
|
+
import { style } from '../../utils/style';
|
|
15
|
+
|
|
16
|
+
export interface RepresentativeOfficeInfoProps
|
|
17
|
+
extends RepresentativeOfficeInfoContent,
|
|
18
|
+
UniBlockProps {}
|
|
19
|
+
|
|
20
|
+
export const RepresentativeOfficeInfo = JSX<RepresentativeOfficeInfoProps>(
|
|
21
|
+
({
|
|
22
|
+
address,
|
|
23
|
+
email,
|
|
24
|
+
telephone,
|
|
25
|
+
button,
|
|
26
|
+
className = '',
|
|
27
|
+
__html,
|
|
28
|
+
icon,
|
|
29
|
+
title,
|
|
30
|
+
version = 'primary',
|
|
31
|
+
...rest
|
|
32
|
+
}) => (
|
|
33
|
+
<BlockWrapper
|
|
34
|
+
className={style('box-border text-left p-9', className)}
|
|
35
|
+
version={version}
|
|
36
|
+
{...rest}
|
|
37
|
+
>
|
|
38
|
+
<div className="w-full flex justify-between">
|
|
39
|
+
{title ? <Heading headingType="h4" as="h3" className="mb-6" title={title} /> : null}
|
|
40
|
+
{renderIconBlock(icon)}
|
|
41
|
+
</div>
|
|
42
|
+
<div className="w-full">
|
|
43
|
+
{__html ? renderDescriptionBlock(__html) : null}
|
|
44
|
+
{renderBlock('Адрес', address, 'GeolocationIcon')}
|
|
45
|
+
{renderBlock('Телефон', telephone, 'PhoneIcon')}
|
|
46
|
+
{renderBlock('E-mail', email, 'MailIcon')}
|
|
47
|
+
{button?.text
|
|
48
|
+
? renderButtonsSection([button], {
|
|
49
|
+
className: 'mb-6',
|
|
50
|
+
})
|
|
51
|
+
: null}
|
|
52
|
+
</div>
|
|
53
|
+
</BlockWrapper>
|
|
54
|
+
),
|
|
55
|
+
);
|
|
56
|
+
|
|
57
|
+
const renderIconBlock = (icon?: Picture) => (
|
|
58
|
+
<div className="self-end">
|
|
59
|
+
{icon?.src ? <Img image={icon} /> : null}
|
|
60
|
+
{icon?.icon ? <Img image={getIconWithVersion(icon)} asSVG /> : null}
|
|
61
|
+
</div>
|
|
62
|
+
);
|
|
63
|
+
|
|
64
|
+
const renderDescriptionBlock = (__html?: string) => (
|
|
65
|
+
<div className="border-b border-main-divider pb-5 my-5">
|
|
66
|
+
<RichText __html={__html} />
|
|
67
|
+
</div>
|
|
68
|
+
);
|
|
69
|
+
|
|
70
|
+
const renderBlock = (blockName: string, data?: string, iconName?: IconName | undefined) => (
|
|
71
|
+
<div className="flex mb-4">
|
|
72
|
+
<Icon className="pr-4" iconVersion="black" name={iconName} width="24" height="24" asSVG />
|
|
73
|
+
<div className="flex flex-col first:pb-1">
|
|
74
|
+
<Text size="text-m-light">{blockName}</Text>
|
|
75
|
+
{data ? (
|
|
76
|
+
<Text size="text-h6" color="text-green">
|
|
77
|
+
{data}
|
|
78
|
+
</Text>
|
|
79
|
+
) : null}
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
);
|