@redneckz/wildless-cms-uni-blocks 0.3.45 → 0.3.48
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 +63 -67
- package/bundle/bundle.umd.min.js +1 -1
- package/dist/components/Accordion/AccordionItem.js +2 -2
- package/dist/components/Accordion/AccordionItem.js.map +1 -1
- package/dist/components/Bonus/Bonus.js +1 -1
- package/dist/components/Bonus/Bonus.js.map +1 -1
- package/dist/components/GracePeriod/GracePeriodContent.d.ts +1 -0
- package/dist/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/dist/components/LinkDocs/LinkDocsListItem.js.map +1 -1
- package/dist/components/NavigatorTabs/NavigatorTabItem.d.ts +2 -2
- package/dist/components/NavigatorTabs/NavigatorTabItem.js +1 -1
- package/dist/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
- package/dist/components/NavigatorTabs/NavigatorTabs.js +6 -9
- package/dist/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
- package/dist/components/NavigatorTabs/NavigatorTabsContent.d.ts +2 -12
- package/dist/components/ProductBlock/ProductBlock.js +1 -1
- package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
- package/dist/components/ProductBlock/renderBackwardButton.js +1 -1
- package/dist/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/dist/components/ProductBlock/renderBenefit.js +1 -1
- package/dist/components/ProductBlock/renderBenefit.js.map +1 -1
- package/dist/components/ProductTile/ProductTile.js +2 -3
- package/dist/components/ProductTile/ProductTile.js.map +1 -1
- package/dist/components/ProductTile/ProductTileContent.d.ts +2 -2
- package/dist/components/StepsBlock/StepsBlock.js +1 -1
- package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/dist/components/Tile/Tile.js +4 -5
- package/dist/components/Tile/Tile.js.map +1 -1
- package/dist/components/Tile/TileContent.d.ts +2 -2
- package/dist/types.d.ts +5 -1
- package/dist/ui-kit/Button/ButtonInner.js +1 -1
- package/dist/ui-kit/Button/ButtonInner.js.map +1 -1
- package/dist/ui-kit/List/ListItem.js +2 -2
- package/dist/ui-kit/List/ListItem.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/Accordion/AccordionItem.js +2 -2
- package/lib/components/Accordion/AccordionItem.js.map +1 -1
- package/lib/components/BaseTile/getTileHeadingType.d.ts +1 -1
- package/lib/components/Bonus/Bonus.js +1 -1
- package/lib/components/Bonus/Bonus.js.map +1 -1
- package/lib/components/GracePeriod/GracePeriodContent.d.ts +1 -0
- package/lib/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/lib/components/LinkDocs/LinkDocsListItem.js.map +1 -1
- package/lib/components/NavigatorTabs/NavigatorTabItem.d.ts +2 -2
- package/lib/components/NavigatorTabs/NavigatorTabItem.js +1 -1
- package/lib/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
- package/lib/components/NavigatorTabs/NavigatorTabs.js +7 -10
- package/lib/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
- package/lib/components/NavigatorTabs/NavigatorTabsContent.d.ts +2 -12
- package/lib/components/ProductBlock/ProductBlock.js +1 -1
- package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
- package/lib/components/ProductBlock/renderBackwardButton.js +1 -1
- package/lib/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/lib/components/ProductBlock/renderBenefit.js +1 -1
- package/lib/components/ProductBlock/renderBenefit.js.map +1 -1
- package/lib/components/ProductTile/ProductTile.js +2 -3
- package/lib/components/ProductTile/ProductTile.js.map +1 -1
- package/lib/components/ProductTile/ProductTileContent.d.ts +2 -2
- package/lib/components/StepsBlock/StepsBlock.js +1 -1
- package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/lib/components/Tile/Tile.js +4 -5
- package/lib/components/Tile/Tile.js.map +1 -1
- package/lib/components/Tile/TileContent.d.ts +2 -2
- package/lib/types.d.ts +5 -1
- package/lib/ui-kit/Button/ButtonInner.js +1 -1
- package/lib/ui-kit/Button/ButtonInner.js.map +1 -1
- package/lib/ui-kit/List/List.fixture.d.ts +4 -0
- package/lib/ui-kit/List/ListItem.js +2 -2
- package/lib/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +3 -3
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/dist/components/Bonus/Bonus.js +1 -1
- package/mobile/dist/components/Bonus/Bonus.js.map +1 -1
- package/mobile/dist/components/GracePeriod/GracePeriodContent.d.ts +1 -0
- package/mobile/dist/components/NavigatorTabs/NavigatorTabItem.d.ts +2 -2
- package/mobile/dist/components/NavigatorTabs/NavigatorTabItem.js +1 -1
- package/mobile/dist/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
- package/mobile/dist/components/NavigatorTabs/NavigatorTabs.js +6 -9
- package/mobile/dist/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
- package/mobile/dist/components/NavigatorTabs/NavigatorTabsContent.d.ts +2 -12
- package/mobile/dist/components/ProductBlock/renderBackwardButton.js +1 -1
- package/mobile/dist/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/mobile/dist/components/ProductTile/ProductTile.js +2 -3
- package/mobile/dist/components/ProductTile/ProductTile.js.map +1 -1
- package/mobile/dist/components/ProductTile/ProductTileContent.d.ts +2 -2
- package/mobile/dist/components/Tile/Tile.js +4 -5
- package/mobile/dist/components/Tile/Tile.js.map +1 -1
- package/mobile/dist/components/Tile/TileContent.d.ts +2 -2
- package/mobile/dist/types.d.ts +5 -1
- package/mobile/dist/ui-kit/Button/ButtonInner.js +1 -1
- package/mobile/dist/ui-kit/Button/ButtonInner.js.map +1 -1
- package/mobile/dist/ui-kit/List/ListItem.js +2 -2
- package/mobile/dist/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/lib/components/Bonus/Bonus.js +1 -1
- package/mobile/lib/components/Bonus/Bonus.js.map +1 -1
- package/mobile/lib/components/GracePeriod/GracePeriodContent.d.ts +1 -0
- package/mobile/lib/components/NavigatorTabs/NavigatorTabItem.d.ts +2 -2
- package/mobile/lib/components/NavigatorTabs/NavigatorTabItem.js +1 -1
- package/mobile/lib/components/NavigatorTabs/NavigatorTabItem.js.map +1 -1
- package/mobile/lib/components/NavigatorTabs/NavigatorTabs.js +7 -10
- package/mobile/lib/components/NavigatorTabs/NavigatorTabs.js.map +1 -1
- package/mobile/lib/components/NavigatorTabs/NavigatorTabsContent.d.ts +2 -12
- package/mobile/lib/components/ProductBlock/renderBackwardButton.js +1 -1
- package/mobile/lib/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/mobile/lib/components/ProductTile/ProductTile.js +2 -3
- package/mobile/lib/components/ProductTile/ProductTile.js.map +1 -1
- package/mobile/lib/components/ProductTile/ProductTileContent.d.ts +2 -2
- package/mobile/lib/components/Tile/Tile.js +4 -5
- package/mobile/lib/components/Tile/Tile.js.map +1 -1
- package/mobile/lib/components/Tile/TileContent.d.ts +2 -2
- package/mobile/lib/types.d.ts +5 -1
- package/mobile/lib/ui-kit/Button/ButtonInner.js +1 -1
- package/mobile/lib/ui-kit/Button/ButtonInner.js.map +1 -1
- package/mobile/lib/ui-kit/List/ListItem.js +2 -2
- package/mobile/lib/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/src/components/Bonus/Bonus.tsx +1 -1
- package/mobile/src/components/ContentPage/ContentPage.page.json +6 -6
- package/mobile/src/components/GracePeriod/GracePeriodContent.ts +1 -0
- package/mobile/src/components/NavigatorTabs/NavigatorTabItem.tsx +4 -4
- package/mobile/src/components/NavigatorTabs/NavigatorTabs.example.json +3 -3
- package/mobile/src/components/NavigatorTabs/NavigatorTabs.tsx +11 -14
- package/mobile/src/components/NavigatorTabs/NavigatorTabsContent.ts +2 -12
- package/mobile/src/components/ProductBlock/renderBackwardButton.tsx +1 -0
- package/mobile/src/components/ProductTile/ProductTile.example.json +1 -0
- package/mobile/src/components/ProductTile/ProductTile.tsx +3 -2
- package/mobile/src/components/ProductTile/ProductTileContent.ts +2 -1
- package/mobile/src/components/Tile/Tile.example.json +1 -0
- package/mobile/src/components/Tile/Tile.tsx +4 -4
- package/mobile/src/components/Tile/TileContent.ts +2 -1
- package/mobile/src/types.ts +5 -1
- package/mobile/src/ui-kit/Button/ButtonInner.tsx +1 -1
- package/mobile/src/ui-kit/List/ListItem.tsx +2 -2
- package/package.json +1 -1
- package/src/components/Accordion/AccordionItem.tsx +4 -2
- package/src/components/Bonus/Bonus.tsx +1 -1
- package/src/components/ContentPage/ContentPage.page.json +6 -6
- package/src/components/GracePeriod/GracePeriodContent.ts +1 -0
- package/src/components/LinkDocs/LinkDocsListItem.tsx +1 -1
- package/src/components/NavigatorTabs/NavigatorTabItem.tsx +4 -4
- package/src/components/NavigatorTabs/NavigatorTabs.example.json +3 -3
- package/src/components/NavigatorTabs/NavigatorTabs.fixture.tsx +6 -1
- package/src/components/NavigatorTabs/NavigatorTabs.tsx +11 -14
- package/src/components/NavigatorTabs/NavigatorTabsContent.ts +2 -12
- package/src/components/ProductBlock/ProductBlock.tsx +1 -1
- package/src/components/ProductBlock/renderBackwardButton.tsx +1 -0
- package/src/components/ProductBlock/renderBenefit.tsx +1 -1
- package/src/components/ProductTile/ProductTile.example.json +1 -0
- package/src/components/ProductTile/ProductTile.fixture.tsx +7 -2
- package/src/components/ProductTile/ProductTile.tsx +3 -2
- package/src/components/ProductTile/ProductTileContent.ts +2 -1
- package/src/components/StepsBlock/StepsBlock.tsx +1 -1
- package/src/components/Tile/Tile.example.json +1 -0
- package/src/components/Tile/Tile.fixture.tsx +6 -1
- package/src/components/Tile/Tile.tsx +4 -4
- package/src/components/Tile/TileContent.ts +2 -1
- package/src/types.ts +5 -1
- package/src/ui-kit/Button/ButtonInner.tsx +1 -1
- package/src/ui-kit/List/List.fixture.tsx +20 -0
- package/src/ui-kit/List/ListItem.tsx +2 -2
package/mobile/dist/types.d.ts
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import type { BlockContent } from './components/BlockContent';
|
|
2
2
|
import type { ContentPageContext } from './components/ContentPage/ContentPageContext';
|
|
3
3
|
import type { BlockVersion } from './model/BlockVersion';
|
|
4
|
-
|
|
4
|
+
/**
|
|
5
|
+
* @title Цветовая палитра
|
|
6
|
+
* @enumNames ["", "Частным клиентам", "Бизнес клиентам", "Экосистема Своё"]
|
|
7
|
+
*/
|
|
8
|
+
export declare type ColorPalette = '' | 'pc' | 'bc' | 'eo';
|
|
5
9
|
export interface BaseBlockDef {
|
|
6
10
|
type?: string;
|
|
7
11
|
style?: string[];
|
|
@@ -4,7 +4,7 @@ const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
|
|
|
4
4
|
const uni_jsx_1 = require("@redneckz/uni-jsx");
|
|
5
5
|
exports.ButtonInner = (0, uni_jsx_1.JSX)((props) => {
|
|
6
6
|
const { text, aboveText, appendLeft } = props;
|
|
7
|
-
return ((0, jsx_runtime_1.jsxs)("div", { className: getButtonStyle(props), children: [appendLeft ? appendLeft : null, isWithText(props) ? ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)("div", { className: "text-m-2xs font-light text-left", children: aboveText }), (0, jsx_runtime_1.jsx)("div", { className: "text-button
|
|
7
|
+
return ((0, jsx_runtime_1.jsxs)("div", { className: getButtonStyle(props), children: [appendLeft ? appendLeft : null, isWithText(props) ? ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)("div", { className: "text-m-2xs font-light text-left", children: aboveText }), (0, jsx_runtime_1.jsx)("div", { className: "text-button text-left", children: text })] })) : null] }));
|
|
8
8
|
});
|
|
9
9
|
const getButtonStyle = (props) => {
|
|
10
10
|
const { version, aboveText, rounded } = props;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonInner.js","sourceRoot":"","sources":["../../../src/ui-kit/Button/ButtonInner.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAQ3B,QAAA,WAAW,GAAG,IAAA,aAAG,EAAmB,CAAC,KAAK,EAAE,EA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OAAO;QACL,kCAAkC;QAClC,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,WAAW;QAC/C,OAAO,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,EAAE;KAC9B,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACd,CAAC,CAAC;AAEF,MAAM,UAAU,GAAG,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAoB,EAAE,EAAE,CACvE,OAAO,CAAC,IAAI,IAAI,SAAS,IAAI,CAAC,UAAU,CAAC,CAAC"}
|
|
@@ -6,8 +6,8 @@ const LIST_STYLE_CLASSES = {
|
|
|
6
6
|
primary: 'rounded-full inline-block mr-3 mt-2',
|
|
7
7
|
secondary: 'rounded-full inline-block mr-3 mt-2',
|
|
8
8
|
gray: 'rounded-full inline-block mr-3 mt-2',
|
|
9
|
-
tile: 'rounded-full inline-block mr-4',
|
|
10
|
-
'tile-white': 'rounded-full inline-block mr-4',
|
|
9
|
+
tile: 'rounded-full inline-block mr-4 mt-3',
|
|
10
|
+
'tile-white': 'rounded-full inline-block mr-4 mt-3',
|
|
11
11
|
};
|
|
12
12
|
const LIST_DOT_STYLE_MAP = {
|
|
13
13
|
primary: 'bg-primary-text',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListItem.js","sourceRoot":"","sources":["../../../src/ui-kit/List/ListItem.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAaxC,MAAM,kBAAkB,GAAG;IACzB,OAAO,EAAE,qCAAqC;IAC9C,SAAS,EAAE,qCAAqC;IAChD,IAAI,EAAE,qCAAqC;IAC3C,IAAI,EAAE,
|
|
1
|
+
{"version":3,"file":"ListItem.js","sourceRoot":"","sources":["../../../src/ui-kit/List/ListItem.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAaxC,MAAM,kBAAkB,GAAG;IACzB,OAAO,EAAE,qCAAqC;IAC9C,SAAS,EAAE,qCAAqC;IAChD,IAAI,EAAE,qCAAqC;IAC3C,IAAI,EAAE,qCAAqC;IAC3C,YAAY,EAAE,qCAAqC;CACpD,CAAC;AAEF,MAAM,kBAAkB,GAAoC;IAC1D,OAAO,EAAE,iBAAiB;IAC1B,SAAS,EAAE,UAAU;IACrB,IAAI,EAAE,mBAAmB;IACzB,IAAI,EAAE,UAAU;IAChB,YAAY,EAAE,UAAU;CACzB,CAAC;AAEW,QAAA,QAAQ,GAAG,IAAA,aAAG,EACzB,CAAC,EAAE,SAAS,GAAG,EAAE,EAAE,QAAQ,GAAG,IAAI,EAAE,QAAQ,EAAE,OAAO,GAAG,SAAS,EAAE,EAAE,EAAE;IACrE,OAAO,CACL,iCAAK,SAAS,EAAE,8BAA8B,SAAS,EAAE,EAAE,IAAI,EAAC,UAAU,aACvE,QAAQ,IAAI,gCAAK,SAAS,EAAE,YAAY,CAAC,OAAO,CAAC,GAAI,EACtD,2CAAO,QAAQ,GAAQ,IACnB,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,MAAM,YAAY,GAAG,CAAC,OAAwB,EAAE,EAAE;IAChD,MAAM,IAAI,GAAG;QACX,OAAO,EAAE,yBAAyB;QAClC,SAAS,EAAE,yBAAyB;QACpC,IAAI,EAAE,iCAAiC;QACvC,IAAI,EAAE,yCAAyC;QAC/C,YAAY,EAAE,yCAAyC;KACxD,CAAC;IACF,OAAO,GAAG,kBAAkB,CAAC,OAAO,CAAC,IAAI,kBAAkB,CAAC,OAAO,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC;AAC1F,CAAC,CAAC"}
|
|
@@ -5,7 +5,7 @@ export const Bonus = JSX((props) => {
|
|
|
5
5
|
const { className = '', title, description, bonusItems, anchor = null } = props;
|
|
6
6
|
return (_jsx("section", { className: `bg-white p-12 ${className}`, id: anchor, children: _jsxs("div", { className: "container", children: [title ? _jsx(Heading, { headingType: "h2", className: "text-center", title: title }) : null, description ? (_jsx("div", { className: "text-md font-light text-center mt-2", children: description })) : null, _jsx("div", { className: "flex flex-wrap w-full mt-9", children: bonusItems
|
|
7
7
|
? bonusItems.map((_, i) => {
|
|
8
|
-
return (_jsx("div", { className: "flex-grow w-[49%] border border-gray pl-9 pt-9 pr-6 pb-6 mb-4 mx-2 even:mr-0 odd:ml-0 last:odd:w-full last:odd:mx-0", children: _jsxs("div", { className: "flex justify-between w-full", children: [_jsxs("div", { className: "mr-4", children: [_jsx("div", { className: "text-title-sm", children: _.name }), _jsx("div", { className: "text-md font-light mt-3 max-w-[488px]", children: _.description })] }), _.bonusCount ? (_jsxs("div", { className: "relative -bottom-3 h-auto flex items-end mt-14 shrink-0", children: [_jsx("span", { className: "font-
|
|
8
|
+
return (_jsx("div", { className: "flex-grow w-[49%] border border-gray pl-9 pt-9 pr-6 pb-6 mb-4 mx-2 even:mr-0 odd:ml-0 last:odd:w-full last:odd:mx-0", children: _jsxs("div", { className: "flex justify-between w-full", children: [_jsxs("div", { className: "mr-4", children: [_jsx("div", { className: "text-title-sm", children: _.name }), _jsx("div", { className: "text-md font-light mt-3 max-w-[488px]", children: _.description })] }), _.bonusCount ? (_jsxs("div", { className: "relative -bottom-3 h-auto flex items-end mt-14 shrink-0", children: [_jsx("span", { className: "font-mohave -tracking-wider text-title-extra bg-clip-text text-transparent bg-green-to-yellow -mb-7", children: _.bonusCount }), _jsx("span", { className: "text-[44px] bg-clip-text text-transparent bg-green-to-yellow", children: _.bonusName })] })) : null] }) }, String(i)));
|
|
9
9
|
})
|
|
10
10
|
: null })] }) }));
|
|
11
11
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Bonus.js","sourceRoot":"","sources":["../../../src/components/Bonus/Bonus.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AAIvD,MAAM,CAAC,MAAM,KAAK,GAAG,GAAG,CAAa,CAAC,KAAK,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,5 +1,5 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
export interface NavigatorTabItemProps extends
|
|
1
|
+
import type { LinkProps } from '../../model/LinkProps';
|
|
2
|
+
export interface NavigatorTabItemProps extends LinkProps {
|
|
3
3
|
active?: boolean;
|
|
4
4
|
className?: string;
|
|
5
5
|
onClick?: (ev: MouseEvent) => void;
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
|
|
|
2
2
|
import { JSX } from '@redneckz/uni-jsx';
|
|
3
3
|
const TEXT_CLASSES = 'font-sans font-normal text-sm';
|
|
4
4
|
const LINK_CLASSES = 'flex-1 flex items-center justify-center cursor-pointer';
|
|
5
|
-
export const NavigatorTabItem = JSX(({ className = '',
|
|
5
|
+
export const NavigatorTabItem = JSX(({ className = '', text, active, children, onClick, href, target = '_self' }) => (_jsx("a", { className: getLinkClasses(className, active), target: target, href: href, onClick: onClick, children: _jsx("span", { className: getTextClasses(active), children: text || children }) })));
|
|
6
6
|
const getLinkClasses = (className, active) => {
|
|
7
7
|
const classes = active ? 'bg-primary-main' : 'group bg-white';
|
|
8
8
|
return `${classes} ${LINK_CLASSES} ${className}`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NavigatorTabItem.js","sourceRoot":"","sources":["../../../src/components/NavigatorTabs/NavigatorTabItem.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AASxC,MAAM,YAAY,GAAG,+BAA+B,CAAC;AACrD,MAAM,YAAY,GAAG,wDAAwD,CAAC;AAE9E,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,CACjC,CAAC,EAAE,SAAS,GAAG,EAAE,EAAE,
|
|
1
|
+
{"version":3,"file":"NavigatorTabItem.js","sourceRoot":"","sources":["../../../src/components/NavigatorTabs/NavigatorTabItem.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AASxC,MAAM,YAAY,GAAG,+BAA+B,CAAC;AACrD,MAAM,YAAY,GAAG,wDAAwD,CAAC;AAE9E,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,CACjC,CAAC,EAAE,SAAS,GAAG,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,EAAE,EAAE,EAAE,CAAC,CAC/E,YAAG,SAAS,EAAE,cAAc,CAAC,SAAS,EAAE,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,YAC3F,eAAM,SAAS,EAAE,cAAc,CAAC,MAAM,CAAC,YAAG,IAAI,IAAI,QAAQ,GAAQ,GAChE,CACL,CACF,CAAC;AAEF,MAAM,cAAc,GAAG,CAAC,SAAiB,EAAE,MAAgB,EAAE,EAAE;IAC7D,MAAM,OAAO,GAAG,MAAM,CAAC,CAAC,CAAC,iBAAiB,CAAC,CAAC,CAAC,gBAAgB,CAAC;IAE9D,OAAO,GAAG,OAAO,IAAI,YAAY,IAAI,SAAS,EAAE,CAAC;AACnD,CAAC,CAAC;AAEF,MAAM,cAAc,GAAG,CAAC,MAAgB,EAAE,EAAE;IAC1C,MAAM,OAAO,GAAG,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,oDAAoD,CAAC;IAE7F,OAAO,GAAG,OAAO,IAAI,YAAY,EAAE,CAAC;AACtC,CAAC,CAAC"}
|
|
@@ -1,20 +1,17 @@
|
|
|
1
1
|
import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
|
|
2
2
|
import { JSX } from '@redneckz/uni-jsx';
|
|
3
|
-
import {
|
|
3
|
+
import { useLink } from '../../hooks/useLink.js';
|
|
4
|
+
import { getHash } from '../../utils/url.js';
|
|
4
5
|
import { NavigatorTabItem } from './NavigatorTabItem.js';
|
|
5
6
|
export const NavigatorTabs = JSX(({ className = '', navigatorTabs, context, anchor = null }) => {
|
|
6
|
-
const router = context.useRouter();
|
|
7
7
|
const href = globalThis.location?.href; // TODO: remove globalThis, use href from router
|
|
8
|
-
return (_jsx("section", { className: `sticky top-0 z-20 box-border flex gap-x-1 h-12 ${className}`, id: anchor, children: navigatorTabs ? navigatorTabs.map(renderTab(
|
|
8
|
+
return (_jsx("section", { className: `sticky top-0 z-20 box-border flex gap-x-1 h-12 ${className}`, id: anchor, children: navigatorTabs ? navigatorTabs.map(renderTab(context, href)) : null }));
|
|
9
9
|
});
|
|
10
|
-
const renderTab = (
|
|
10
|
+
const renderTab = (context, href) => (tab, i) => {
|
|
11
|
+
const { useRouter, handlerDecorator } = context;
|
|
12
|
+
const router = useRouter();
|
|
11
13
|
const hash = getHash(href);
|
|
12
14
|
const active = hash ? tab.href === hash : i === 0;
|
|
13
|
-
return (_jsx(NavigatorTabItem, { active: active,
|
|
14
|
-
};
|
|
15
|
-
const handleRoute = (router, href) => {
|
|
16
|
-
if (isURL(href))
|
|
17
|
-
return; // if href if full URL - move to HTML href action, do not touch router
|
|
18
|
-
router?.replace(href || '');
|
|
15
|
+
return (_jsx(NavigatorTabItem, { active: active, ...useLink({ router, handlerDecorator }, tab) }, tab.href));
|
|
19
16
|
};
|
|
20
17
|
//# sourceMappingURL=NavigatorTabs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NavigatorTabs.js","sourceRoot":"","sources":["../../../src/components/NavigatorTabs/NavigatorTabs.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"NavigatorTabs.js","sourceRoot":"","sources":["../../../src/components/NavigatorTabs/NavigatorTabs.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAG9C,OAAO,EAAE,OAAO,EAAE,MA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|
6
|
-
label?: string;
|
|
7
|
-
/** @title Якорь */
|
|
8
|
-
href?: string;
|
|
9
|
-
/** @title Таргет (target) */
|
|
10
|
-
target?: string;
|
|
11
|
-
}
|
|
1
|
+
import type { LinkProps } from '../../model/LinkProps';
|
|
12
2
|
/**
|
|
13
3
|
* @title Блок табов
|
|
14
4
|
*/
|
|
@@ -17,5 +7,5 @@ export interface NavigatorTabsContent {
|
|
|
17
7
|
* @title Список табов
|
|
18
8
|
* @minItems 3
|
|
19
9
|
*/
|
|
20
|
-
navigatorTabs?:
|
|
10
|
+
navigatorTabs?: LinkProps[];
|
|
21
11
|
}
|
|
@@ -2,6 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
|
|
|
2
2
|
import { Button } from '../../ui-kit/Button/Button.js';
|
|
3
3
|
import { Img } from '../../ui-kit/Img/Img.js';
|
|
4
4
|
export function renderBackwardButton(button, version, className) {
|
|
5
|
-
return (_jsxs("div", { className: `flex items-center ${className}`, children: [_jsx(Button, { version: version, rounded: true, className: "w-12 h-12 min-h-12 min-w-12 flex items-center justify-center mr-3", ariaLabel: button?.text, children: _jsx(Img, { className: "w-4 h-4", image: button?.icon || { icon: 'ArrowLeftIcon' }, asSVG: true }) }), button?.text ? _jsx("span", { className: "text-m-md font-light", children: button.text }) : null] }));
|
|
5
|
+
return (_jsxs("div", { className: `flex items-center ${className}`, children: [_jsx(Button, { version: version, rounded: true, className: "w-12 h-12 min-h-12 min-w-12 flex items-center justify-center mr-3", ariaLabel: button?.text, href: button?.href, children: _jsx(Img, { className: "w-4 h-4", image: button?.icon || { icon: 'ArrowLeftIcon' }, asSVG: true }) }), button?.text ? _jsx("span", { className: "text-m-md font-light", children: button.text }) : null] }));
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=renderBackwardButton.js.map
|
|
@@ -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;AAE3C,MAAM,UAAU,oBAAoB,CAClC,MAA2B,EAC3B,OAAqB,EACrB,SAAiB;IAEjB,OAAO,CACL,eAAK,SAAS,EAAE,qBAAqB,SAAS,EAAE,aAC9C,KAAC,MAAM,IACL,OAAO,EAAE,OAAO,EAChB,OAAO,QACP,SAAS,EAAC,mEAAmE,EAC7E,SAAS,EAAE,MAAM,EAAE,IAAI,
|
|
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;AAE3C,MAAM,UAAU,oBAAoB,CAClC,MAA2B,EAC3B,OAAqB,EACrB,SAAiB;IAEjB,OAAO,CACL,eAAK,SAAS,EAAE,qBAAqB,SAAS,EAAE,aAC9C,KAAC,MAAM,IACL,OAAO,EAAE,OAAO,EAChB,OAAO,QACP,SAAS,EAAC,mEAAmE,EAC7E,SAAS,EAAE,MAAM,EAAE,IAAI,EACvB,IAAI,EAAE,MAAM,EAAE,IAAI,YAElB,KAAC,GAAG,IAAC,SAAS,EAAC,SAAS,EAAC,KAAK,EAAE,MAAM,EAAE,IAAI,IAAI,EAAE,IAAI,EAAE,eAAe,EAAE,EAAE,KAAK,SAAG,GAC5E,EACR,MAAM,EAAE,IAAI,CAAC,CAAC,CAAC,eAAM,SAAS,EAAC,sBAAsB,YAAE,MAAM,CAAC,IAAI,GAAQ,CAAC,CAAC,CAAC,IAAI,IAC9E,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -5,15 +5,14 @@ import { Description } from '../../ui-kit/Description/Description.js';
|
|
|
5
5
|
import { Heading } from '../../ui-kit/Heading/Heading.js';
|
|
6
6
|
import { Img } from '../../ui-kit/Img/Img.js';
|
|
7
7
|
import { BaseTile } from '../BaseTile/BaseTile.js';
|
|
8
|
-
import { getTileHeadingType } from '../BaseTile/getTileHeadingType.js';
|
|
9
8
|
import { getTileMinHeight } from '../BaseTile/getTileMinHeight.js';
|
|
10
9
|
import { getTileRightPadding } from '../BaseTile/getTileRightPadding.js';
|
|
11
10
|
const productTileStyleMap = {
|
|
12
11
|
primary: 'bg-white text-primary-text',
|
|
13
12
|
secondary: 'bg-primary-main text-white',
|
|
14
13
|
};
|
|
15
|
-
export const ProductTile = JSX(({ context, className = '', title, description, benefits, buttons, image, version = 'primary', anchor = null, }) => {
|
|
16
|
-
return (_jsx("section", { className: `bg-white overflow-hidden text-primary-text font-sans p-9 box-border ${className} ${productTileStyleMap[version]} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `, id: anchor, children: _jsxs(BaseTile, { context: context, title: title && (_jsx(Heading, { headingType:
|
|
14
|
+
export const ProductTile = JSX(({ context, className = '', title, headingType = 'h3', description, benefits, buttons, image, version = 'primary', anchor = null, }) => {
|
|
15
|
+
return (_jsx("section", { className: `bg-white overflow-hidden text-primary-text font-sans p-9 box-border ${className} ${productTileStyleMap[version]} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `, id: anchor, children: _jsxs(BaseTile, { context: context, title: title && (_jsx(Heading, { headingType: headingType, as: "h3", title: title, className: `whitespace-pre-wrap max-w-[600px]` })), buttons: buttons?.length ? (_jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-3" })) : null, image: image?.src && _jsx(Img, { className: "mt-auto ml-7", image: image }), children: [description && _jsx(Description, { className: "mt-4 max-w-[600px]", description: description }), _jsxs("div", { className: "flex mt-5 mb-1", children: [benefits?.length ? (_jsx("div", { className: "mr-8", children: benefits.map(renderBenefitLabel) })) : null, benefits?.length ? (_jsx("div", { className: "pt-1", children: benefits.map((_, i) => renderBenefitDescription(_, i, version)) })) : null] })] }) }));
|
|
17
16
|
});
|
|
18
17
|
function renderBenefitLabel(benefit, i) {
|
|
19
18
|
return (_jsx("div", { className: `text-xl font-medium ${i ? 'mt-2.5' : ''}`, children: benefit.label }, String(i)));
|
|
@@ -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,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,
|
|
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,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AAMtE,MAAM,mBAAmB,GAAiC;IACxD,OAAO,EAAE,4BAA4B;IACrC,SAAS,EAAE,4BAA4B;CACxC,CAAC;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,CAC5B,CAAC,EACC,O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CAAC,EAAE,EAAE,CAAC,wBAAwB,CAAC,CAAC,EAAE,CAAC,EAAE,OAAO,CAAC,CAAC,GAC5D,CACP,CAAC,CAAC,CAAC,IAAI,IACJ,IACG,GACH,CACX,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,SAAS,kBAAkB,CAAC,OAAgB,EAAE,CAAS;IACrD,OAAO,CACL,cAAqB,SAAS,EAAE,uBAAuB,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,YACvE,OAAO,CAAC,KAAK,IADN,MAAM,CAAC,CAAC,CAAC,CAEb,CACP,CAAC;AACJ,CAAC;AAED,SAAS,wBAAwB,CAAC,OAAgB,EAAE,CAAS,EAAE,OAAO,GAAG,SAAS;IAChF,MAAM,aAAa,GAAiC;QAClD,OAAO,EAAE,qBAAqB;QAC9B,SAAS,EAAE,YAAY;KACxB,CAAC;IACF,OAAO,CACL,cAAqB,SAAS,EAAE,WAAW,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,IAAI,aAAa,CAAC,OAAO,CAAC,EAAE,YACnF,OAAO,CAAC,WAAW,IADZ,MAAM,CAAC,CAAC,CAAC,CAEb,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
2
|
import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
|
|
3
3
|
import type { DescriptionContent } from '../../ui-kit/Description/DescriptionContent';
|
|
4
|
-
import type { HeadingContent } from '../../ui-kit/Heading/HeadingContent';
|
|
4
|
+
import type { HeadingContent, HeadingTypeContent } from '../../ui-kit/Heading/HeadingContent';
|
|
5
5
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
6
6
|
import type { TextBenefit } from '../BenefitsBlock/BenefitsBlockContent';
|
|
7
7
|
/**
|
|
8
8
|
* @title Продуктовая плитка
|
|
9
9
|
*/
|
|
10
|
-
export declare type ProductTileContent = HeadingContent & DescriptionContent & ButtonContent & ImageContent & {
|
|
10
|
+
export declare type ProductTileContent = HeadingContent & HeadingTypeContent & DescriptionContent & ButtonContent & ImageContent & {
|
|
11
11
|
version?: BlockVersion;
|
|
12
12
|
/**
|
|
13
13
|
* @title Преимущества
|
|
@@ -6,7 +6,6 @@ import { Heading } from '../../ui-kit/Heading/Heading.js';
|
|
|
6
6
|
import { Img } from '../../ui-kit/Img/Img.js';
|
|
7
7
|
import { List } from '../../ui-kit/List/List.js';
|
|
8
8
|
import { BaseTile } from '../BaseTile/BaseTile.js';
|
|
9
|
-
import { getTileHeadingType } from '../BaseTile/getTileHeadingType.js';
|
|
10
9
|
import { getTileMinHeight } from '../BaseTile/getTileMinHeight.js';
|
|
11
10
|
import { getTileRightPadding } from '../BaseTile/getTileRightPadding.js';
|
|
12
11
|
const tileStyleMap = {
|
|
@@ -14,11 +13,11 @@ const tileStyleMap = {
|
|
|
14
13
|
secondary: 'bg-primary-main text-white',
|
|
15
14
|
};
|
|
16
15
|
export const Tile = JSX((props) => {
|
|
17
|
-
const { context, title, description, items, children, buttons, image, className = '', version = 'primary', role, anchor = null, } = props;
|
|
18
|
-
return (_jsx("section", { className: `overflow-hidden font-sans p-9 pr-3 box-border ${className} ${tileStyleMap[version]} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `, role: role, id: anchor, children: _jsxs(BaseTile, { context: context, title: title && (_jsx(Heading, { headingType:
|
|
19
|
-
${version === 'primary' ? 'text-primary-text' : ''}` })), buttons: buttons?.length ? (_jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-3" })) : null, image: image?.src && _jsx(Img, { className: "mt-auto ml-7", image: image }), children: [description && (_jsx(Description, { className: "
|
|
16
|
+
const { context, title, headingType = 'h3', description, items, children, buttons, image, className = '', version = 'primary', role, anchor = null, } = props;
|
|
17
|
+
return (_jsx("section", { className: `overflow-hidden font-sans p-9 pr-3 box-border ${className} ${tileStyleMap[version]} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `, role: role, id: anchor, children: _jsxs(BaseTile, { context: context, title: title && (_jsx(Heading, { headingType: headingType, as: "h3", title: title, className: `whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}
|
|
18
|
+
${version === 'primary' ? 'text-primary-text' : ''}` })), buttons: buttons?.length ? (_jsx(ButtonSection, { context: context, buttons: buttons, className: "flex mt-9 gap-3" })) : null, image: image?.src && _jsx(Img, { className: "mt-auto ml-7", image: image }), children: [description && (_jsx(Description, { className: "max-w-[600px] text-title-new-sm font-light", description: description })), children, renderList(items, version)] }) }));
|
|
20
19
|
});
|
|
21
20
|
function renderList(items, version) {
|
|
22
|
-
return items?.length ? (_jsx(List, { items: items, itemClassName: "text-title-
|
|
21
|
+
return items?.length ? (_jsx(List, { items: items, itemClassName: "text-title-2xs font-light mt-2", version: version === 'primary' ? 'tile' : 'tile-white' })) : null;
|
|
23
22
|
}
|
|
24
23
|
//# 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;AAGxC,OAAO,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,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,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"Tile.js","sourceRoot":"","sources":["../../../src/components/Tile/Tile.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,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,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,EAAE,EAAE,GACpD,CACH,EAEH,OAAO,EACL,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC,CAChB,KAAC,aAAa,IAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,SAAS,EAAC,iBAAiB,GAAG,CAClF,CAAC,CAAC,CAAC,IAAI,EAEV,KAAK,EAAE,KAAK,EAAE,GAAG,IAAI,KAAC,GAAG,IAAC,SAAS,EAAC,cAAc,EAAC,KAAK,EAAE,KAAK,GAAI,aAElE,WAAW,IAAI,CACd,KAAC,WAAW,IACV,SAAS,EAAC,4CAA4C,EACtD,WAAW,EAAE,WAAW,GACxB,CACH,EACA,QAAQ,EACR,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,IAClB,GACH,CACX,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,SAAS,UAAU,CAAC,KAAK,EAAE,OAAO;IAChC,OAAO,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,CACrB,KAAC,IAAI,IACH,KAAK,EAAE,KAAK,EACZ,aAAa,EAAC,gCAAgC,EAC9C,OAAO,EAAE,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,YAAY,GACtD,CACH,CAAC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
2
|
import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
|
|
3
3
|
import type { DescriptionContent } from '../../ui-kit/Description/DescriptionContent';
|
|
4
|
-
import type { HeadingContent } from '../../ui-kit/Heading/HeadingContent';
|
|
4
|
+
import type { HeadingContent, HeadingTypeContent } from '../../ui-kit/Heading/HeadingContent';
|
|
5
5
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
6
6
|
import type { ListContent } from '../../ui-kit/List/ListContent';
|
|
7
7
|
/**
|
|
8
8
|
* @title Плитка
|
|
9
9
|
*/
|
|
10
|
-
export declare type TileContent = HeadingContent & DescriptionContent & ListContent & ButtonContent & ImageContent & {
|
|
10
|
+
export declare type TileContent = HeadingContent & HeadingTypeContent & DescriptionContent & ListContent & ButtonContent & ImageContent & {
|
|
11
11
|
version?: BlockVersion;
|
|
12
12
|
};
|
package/mobile/lib/types.d.ts
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import type { BlockContent } from './components/BlockContent';
|
|
2
2
|
import type { ContentPageContext } from './components/ContentPage/ContentPageContext';
|
|
3
3
|
import type { BlockVersion } from './model/BlockVersion';
|
|
4
|
-
|
|
4
|
+
/**
|
|
5
|
+
* @title Цветовая палитра
|
|
6
|
+
* @enumNames ["", "Частным клиентам", "Бизнес клиентам", "Экосистема Своё"]
|
|
7
|
+
*/
|
|
8
|
+
export declare type ColorPalette = '' | 'pc' | 'bc' | 'eo';
|
|
5
9
|
export interface BaseBlockDef {
|
|
6
10
|
type?: string;
|
|
7
11
|
style?: string[];
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
|
|
|
2
2
|
import { JSX } from '@redneckz/uni-jsx';
|
|
3
3
|
export const ButtonInner = JSX((props) => {
|
|
4
4
|
const { text, aboveText, appendLeft } = props;
|
|
5
|
-
return (_jsxs("div", { className: getButtonStyle(props), children: [appendLeft ? appendLeft : null, isWithText(props) ? (_jsxs("div", { children: [_jsx("div", { className: "text-m-2xs font-light text-left", children: aboveText }), _jsx("div", { className: "text-button
|
|
5
|
+
return (_jsxs("div", { className: getButtonStyle(props), children: [appendLeft ? appendLeft : null, isWithText(props) ? (_jsxs("div", { children: [_jsx("div", { className: "text-m-2xs font-light text-left", children: aboveText }), _jsx("div", { className: "text-button text-left", children: text })] })) : null] }));
|
|
6
6
|
});
|
|
7
7
|
const getButtonStyle = (props) => {
|
|
8
8
|
const { version, aboveText, rounded } = props;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonInner.js","sourceRoot":"","sources":["../../../src/ui-kit/Button/ButtonInner.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAQxC,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,CAAmB,CAAC,KAAK,EAAE,EAAE;IACzD,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,GAAG,KAAK,CAAC;IAC9C,OAAO,CACL,eAAK,SAAS,EAAE,cAAc,CAAC,KAAK,CAAC,aAClC,UAAU,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,EAC9B,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CACnB,0BACE,cAAK,SAAS,EAAC,iCAAiC,YAAE,SAAS,GAAO,EAClE,cAAK,SAAS,EAAC,
|
|
1
|
+
{"version":3,"file":"ButtonInner.js","sourceRoot":"","sources":["../../../src/ui-kit/Button/ButtonInner.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAQxC,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,CAAmB,CAAC,KAAK,EAAE,EAAE;IACzD,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,GAAG,KAAK,CAAC;IAC9C,OAAO,CACL,eAAK,SAAS,EAAE,cAAc,CAAC,KAAK,CAAC,aAClC,UAAU,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,EAC9B,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CACnB,0BACE,cAAK,SAAS,EAAC,iCAAiC,YAAE,SAAS,GAAO,EAClE,cAAK,SAAS,EAAC,uBAAuB,YAAE,IAAI,GAAO,IAC/C,CACP,CAAC,CAAC,CAAC,IAAI,IACJ,CACP,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,cAAc,GAAG,CAAC,KAAuB,EAAE,EAAE;IACjD,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,GAAG,KAAK,CAAC;IAE9C,IAAI,OAAO,KAAK,MAAM,EAAE;QACtB,OAAO,EAAE,CAAC;KACX;IAED,MAAM,aAAa,GAAG,cAAc,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;IAEvE,OAAO;QACL,kCAAkC;QAClC,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,WAAW;QAC/C,OAAO,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,EAAE;KAC9B,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACd,CAAC,CAAC;AAEF,MAAM,UAAU,GAAG,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAoB,EAAE,EAAE,CACvE,OAAO,CAAC,IAAI,IAAI,SAAS,IAAI,CAAC,UAAU,CAAC,CAAC"}
|
|
@@ -4,8 +4,8 @@ const LIST_STYLE_CLASSES = {
|
|
|
4
4
|
primary: 'rounded-full inline-block mr-3 mt-2',
|
|
5
5
|
secondary: 'rounded-full inline-block mr-3 mt-2',
|
|
6
6
|
gray: 'rounded-full inline-block mr-3 mt-2',
|
|
7
|
-
tile: 'rounded-full inline-block mr-4',
|
|
8
|
-
'tile-white': 'rounded-full inline-block mr-4',
|
|
7
|
+
tile: 'rounded-full inline-block mr-4 mt-3',
|
|
8
|
+
'tile-white': 'rounded-full inline-block mr-4 mt-3',
|
|
9
9
|
};
|
|
10
10
|
const LIST_DOT_STYLE_MAP = {
|
|
11
11
|
primary: 'bg-primary-text',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListItem.js","sourceRoot":"","sources":["../../../src/ui-kit/List/ListItem.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC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AC,OAAO,CAAC,IAAI,kBAAkB,CAAC,OAAO,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC;AAC1F,CAAC,CAAC"}
|
|
@@ -30,7 +30,7 @@ export const Bonus = JSX<BonusProps>((props) => {
|
|
|
30
30
|
</div>
|
|
31
31
|
{_.bonusCount ? (
|
|
32
32
|
<div className="relative -bottom-3 h-auto flex items-end mt-14 shrink-0">
|
|
33
|
-
<span className="font-
|
|
33
|
+
<span className="font-mohave -tracking-wider text-title-extra bg-clip-text text-transparent bg-green-to-yellow -mb-7">
|
|
34
34
|
{_.bonusCount}
|
|
35
35
|
</span>
|
|
36
36
|
<span className="text-[44px] bg-clip-text text-transparent bg-green-to-yellow">
|
|
@@ -553,27 +553,27 @@
|
|
|
553
553
|
"content": {
|
|
554
554
|
"navigatorTabs": [
|
|
555
555
|
{
|
|
556
|
-
"
|
|
556
|
+
"text": "Калькулятор",
|
|
557
557
|
"href": "#calculator"
|
|
558
558
|
},
|
|
559
559
|
{
|
|
560
|
-
"
|
|
560
|
+
"text": "Преимущества",
|
|
561
561
|
"href": "#advantages"
|
|
562
562
|
},
|
|
563
563
|
{
|
|
564
|
-
"
|
|
564
|
+
"text": "Как оформить",
|
|
565
565
|
"href": "#howToApply"
|
|
566
566
|
},
|
|
567
567
|
{
|
|
568
|
-
"
|
|
568
|
+
"text": "Тарифы",
|
|
569
569
|
"href": "#tariffs"
|
|
570
570
|
},
|
|
571
571
|
{
|
|
572
|
-
"
|
|
572
|
+
"text": "Документы",
|
|
573
573
|
"href": "#documents"
|
|
574
574
|
},
|
|
575
575
|
{
|
|
576
|
-
"
|
|
576
|
+
"text": "Урожай",
|
|
577
577
|
"href": "https://rshb.ru/",
|
|
578
578
|
"target": "_blank"
|
|
579
579
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
-
import type {
|
|
2
|
+
import type { LinkProps } from '../../model/LinkProps';
|
|
3
3
|
|
|
4
|
-
export interface NavigatorTabItemProps extends
|
|
4
|
+
export interface NavigatorTabItemProps extends LinkProps {
|
|
5
5
|
active?: boolean;
|
|
6
6
|
className?: string;
|
|
7
7
|
onClick?: (ev: MouseEvent) => void;
|
|
@@ -11,9 +11,9 @@ const TEXT_CLASSES = 'font-sans font-normal text-sm';
|
|
|
11
11
|
const LINK_CLASSES = 'flex-1 flex items-center justify-center cursor-pointer';
|
|
12
12
|
|
|
13
13
|
export const NavigatorTabItem = JSX<NavigatorTabItemProps>(
|
|
14
|
-
({ className = '',
|
|
14
|
+
({ className = '', text, active, children, onClick, href, target = '_self' }) => (
|
|
15
15
|
<a className={getLinkClasses(className, active)} target={target} href={href} onClick={onClick}>
|
|
16
|
-
<span className={getTextClasses(active)}>{
|
|
16
|
+
<span className={getTextClasses(active)}>{text || children}</span>
|
|
17
17
|
</a>
|
|
18
18
|
),
|
|
19
19
|
);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"navigatorTabs": [
|
|
3
|
-
{ "
|
|
4
|
-
{ "
|
|
5
|
-
{ "
|
|
3
|
+
{ "text": "Таб 1", "href": "#tab1", "target": "_self" },
|
|
4
|
+
{ "text": "Таб 2", "href": "#tab2", "target": "_self" },
|
|
5
|
+
{ "text": "Ссылка", "href": "https://rshb.ru", "target": "_blank" }
|
|
6
6
|
]
|
|
7
7
|
}
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
+
import { useLink } from '../../hooks/useLink';
|
|
3
|
+
import { LinkProps } from '../../model/LinkProps';
|
|
2
4
|
import type { UniBlockProps } from '../../types';
|
|
3
|
-
import { getHash
|
|
4
|
-
import type {
|
|
5
|
+
import { getHash } from '../../utils/url';
|
|
6
|
+
import type { ContentPageContext } from '../ContentPage/ContentPageContext';
|
|
5
7
|
import { NavigatorTabItem } from './NavigatorTabItem';
|
|
6
|
-
import type {
|
|
8
|
+
import type { NavigatorTabsContent } from './NavigatorTabsContent';
|
|
7
9
|
|
|
8
10
|
export interface TabsBlockProps extends UniBlockProps, NavigatorTabsContent {}
|
|
9
11
|
|
|
10
12
|
export const NavigatorTabs = JSX<TabsBlockProps>(
|
|
11
13
|
({ className = '', navigatorTabs, context, anchor = null }) => {
|
|
12
|
-
const router = context.useRouter();
|
|
13
14
|
const href = globalThis.location?.href; // TODO: remove globalThis, use href from router
|
|
14
15
|
|
|
15
16
|
return (
|
|
@@ -17,13 +18,16 @@ export const NavigatorTabs = JSX<TabsBlockProps>(
|
|
|
17
18
|
className={`sticky top-0 z-20 box-border flex gap-x-1 h-12 ${className}`}
|
|
18
19
|
id={anchor}
|
|
19
20
|
>
|
|
20
|
-
{navigatorTabs ? navigatorTabs.map(renderTab(
|
|
21
|
+
{navigatorTabs ? navigatorTabs.map(renderTab(context, href)) : null}
|
|
21
22
|
</section>
|
|
22
23
|
);
|
|
23
24
|
},
|
|
24
25
|
);
|
|
25
26
|
|
|
26
|
-
const renderTab = (
|
|
27
|
+
const renderTab = (context: ContentPageContext, href?: string) => (tab: LinkProps, i: number) => {
|
|
28
|
+
const { useRouter, handlerDecorator } = context;
|
|
29
|
+
const router = useRouter();
|
|
30
|
+
|
|
27
31
|
const hash = getHash(href);
|
|
28
32
|
const active = hash ? tab.href === hash : i === 0;
|
|
29
33
|
|
|
@@ -31,14 +35,7 @@ const renderTab = (href?: string, router?: Router) => (tab: NavigatorTab, i: num
|
|
|
31
35
|
<NavigatorTabItem
|
|
32
36
|
key={tab.href}
|
|
33
37
|
active={active}
|
|
34
|
-
|
|
35
|
-
{...tab}
|
|
38
|
+
{...useLink({ router, handlerDecorator }, tab)}
|
|
36
39
|
/>
|
|
37
40
|
);
|
|
38
41
|
};
|
|
39
|
-
|
|
40
|
-
const handleRoute = (router?: Router, href?: string) => {
|
|
41
|
-
if (isURL(href)) return; // if href if full URL - move to HTML href action, do not touch router
|
|
42
|
-
|
|
43
|
-
router?.replace(href || '');
|
|
44
|
-
};
|
|
@@ -1,14 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
* @title Таб
|
|
3
|
-
*/
|
|
4
|
-
export interface NavigatorTab {
|
|
5
|
-
/** @title Название */
|
|
6
|
-
label?: string;
|
|
7
|
-
/** @title Якорь */
|
|
8
|
-
href?: string;
|
|
9
|
-
/** @title Таргет (target) */
|
|
10
|
-
target?: string;
|
|
11
|
-
}
|
|
1
|
+
import type { LinkProps } from '../../model/LinkProps';
|
|
12
2
|
|
|
13
3
|
/**
|
|
14
4
|
* @title Блок табов
|
|
@@ -18,5 +8,5 @@ export interface NavigatorTabsContent {
|
|
|
18
8
|
* @title Список табов
|
|
19
9
|
* @minItems 3
|
|
20
10
|
*/
|
|
21
|
-
navigatorTabs?:
|
|
11
|
+
navigatorTabs?: LinkProps[];
|
|
22
12
|
}
|
|
@@ -15,6 +15,7 @@ export function renderBackwardButton(
|
|
|
15
15
|
rounded
|
|
16
16
|
className="w-12 h-12 min-h-12 min-w-12 flex items-center justify-center mr-3"
|
|
17
17
|
ariaLabel={button?.text}
|
|
18
|
+
href={button?.href}
|
|
18
19
|
>
|
|
19
20
|
<Img className="w-4 h-4" image={button?.icon || { icon: 'ArrowLeftIcon' }} asSVG />
|
|
20
21
|
</Button>
|
|
@@ -6,7 +6,6 @@ import { Description } from '../../ui-kit/Description/Description';
|
|
|
6
6
|
import { Heading } from '../../ui-kit/Heading/Heading';
|
|
7
7
|
import { Img } from '../../ui-kit/Img/Img';
|
|
8
8
|
import { BaseTile } from '../BaseTile/BaseTile';
|
|
9
|
-
import { getTileHeadingType } from '../BaseTile/getTileHeadingType';
|
|
10
9
|
import { getTileMinHeight } from '../BaseTile/getTileMinHeight';
|
|
11
10
|
import { getTileRightPadding } from '../BaseTile/getTileRightPadding';
|
|
12
11
|
import type { Benefit } from '../BenefitsBlock/BenefitsBlockContent';
|
|
@@ -24,6 +23,7 @@ export const ProductTile = JSX<ProductTileProps>(
|
|
|
24
23
|
context,
|
|
25
24
|
className = '',
|
|
26
25
|
title,
|
|
26
|
+
headingType = 'h3',
|
|
27
27
|
description,
|
|
28
28
|
benefits,
|
|
29
29
|
buttons,
|
|
@@ -43,7 +43,8 @@ export const ProductTile = JSX<ProductTileProps>(
|
|
|
43
43
|
title={
|
|
44
44
|
title && (
|
|
45
45
|
<Heading
|
|
46
|
-
headingType={
|
|
46
|
+
headingType={headingType}
|
|
47
|
+
as="h3"
|
|
47
48
|
title={title}
|
|
48
49
|
className={`whitespace-pre-wrap max-w-[600px]`}
|
|
49
50
|
/>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
2
|
import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
|
|
3
3
|
import type { DescriptionContent } from '../../ui-kit/Description/DescriptionContent';
|
|
4
|
-
import type { HeadingContent } from '../../ui-kit/Heading/HeadingContent';
|
|
4
|
+
import type { HeadingContent, HeadingTypeContent } from '../../ui-kit/Heading/HeadingContent';
|
|
5
5
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
6
6
|
import type { TextBenefit } from '../BenefitsBlock/BenefitsBlockContent';
|
|
7
7
|
|
|
@@ -9,6 +9,7 @@ import type { TextBenefit } from '../BenefitsBlock/BenefitsBlockContent';
|
|
|
9
9
|
* @title Продуктовая плитка
|
|
10
10
|
*/
|
|
11
11
|
export type ProductTileContent = HeadingContent &
|
|
12
|
+
HeadingTypeContent &
|
|
12
13
|
DescriptionContent &
|
|
13
14
|
ButtonContent &
|
|
14
15
|
ImageContent & {
|