@redneckz/wildless-cms-uni-blocks 0.14.8 → 0.14.10
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/bundle.umd.js +4 -4
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/Footer/LinkList.d.ts +8 -0
- package/dist/components/ContentPage/ContentPage.js +1 -1
- package/dist/components/ContentPage/ContentPage.js.map +1 -1
- package/dist/components/Footer/Footer.mobile.js +3 -2
- package/dist/components/Footer/Footer.mobile.js.map +1 -1
- package/dist/components/Footer/LinkList.d.ts +8 -0
- package/dist/components/Footer/LinkList.js +16 -0
- package/dist/components/Footer/LinkList.js.map +1 -0
- package/dist/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/dist/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/dist/ui-kit/Icon/Icon.js +1 -1
- package/dist/ui-kit/Icon/Icon.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/ContentPage/ContentPage.js +1 -1
- package/lib/components/ContentPage/ContentPage.js.map +1 -1
- package/lib/components/Footer/Footer.mobile.js +3 -2
- package/lib/components/Footer/Footer.mobile.js.map +1 -1
- package/lib/components/Footer/LinkList.d.ts +8 -0
- package/lib/components/Footer/LinkList.js +14 -0
- package/lib/components/Footer/LinkList.js.map +1 -0
- package/lib/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/lib/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/lib/ui-kit/Icon/Icon.js +1 -1
- package/lib/ui-kit/Icon/Icon.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +14 -13
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/Footer/LinkList.d.ts +8 -0
- package/mobile/dist/components/ContentPage/ContentPage.js +1 -1
- package/mobile/dist/components/ContentPage/ContentPage.js.map +1 -1
- package/mobile/dist/components/Footer/Footer.js +3 -2
- package/mobile/dist/components/Footer/Footer.js.map +1 -1
- package/mobile/dist/components/Footer/LinkList.d.ts +8 -0
- package/mobile/dist/components/Footer/LinkList.js +16 -0
- package/mobile/dist/components/Footer/LinkList.js.map +1 -0
- package/mobile/dist/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/mobile/dist/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/mobile/dist/ui-kit/Icon/Icon.js +1 -1
- package/mobile/dist/ui-kit/Icon/Icon.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/ContentPage/ContentPage.js +1 -1
- package/mobile/lib/components/ContentPage/ContentPage.js.map +1 -1
- package/mobile/lib/components/Footer/Footer.js +3 -2
- package/mobile/lib/components/Footer/Footer.js.map +1 -1
- package/mobile/lib/components/Footer/LinkList.d.ts +8 -0
- package/mobile/lib/components/Footer/LinkList.js +14 -0
- package/mobile/lib/components/Footer/LinkList.js.map +1 -0
- package/mobile/lib/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/mobile/lib/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/mobile/lib/ui-kit/Icon/Icon.js +1 -1
- package/mobile/lib/ui-kit/Icon/Icon.js.map +1 -1
- package/mobile/src/components/ContentPage/ContentPage.tsx +1 -1
- package/mobile/src/components/Footer/Footer.tsx +3 -2
- package/mobile/src/components/Footer/LinkList.tsx +41 -0
- package/mobile/src/ui-kit/BenefitItem/BenefitItem.tsx +1 -1
- package/mobile/src/ui-kit/Icon/Icon.tsx +1 -1
- package/package.json +1 -1
- package/src/components/ContentPage/ContentPage.tsx +1 -1
- package/src/components/Footer/Footer.mobile.tsx +3 -2
- package/src/components/Footer/LinkList.tsx +41 -0
- package/src/ui-kit/BenefitItem/BenefitItem.tsx +1 -1
- package/src/ui-kit/Icon/Icon.tsx +1 -1
- package/bundle/ui-kit/LinkList/LinkList.d.ts +0 -2
- package/bundle/ui-kit/LinkList/LinkListProps.d.ts +0 -5
- package/bundle/ui-kit/LinkList/linkListStyles.d.ts +0 -1
- package/bundle/ui-kit/LinkList/linkListStyles.mobile.d.ts +0 -1
- package/dist/ui-kit/LinkList/LinkList.d.ts +0 -2
- package/dist/ui-kit/LinkList/LinkList.js +0 -12
- package/dist/ui-kit/LinkList/LinkList.js.map +0 -1
- package/dist/ui-kit/LinkList/LinkListProps.d.ts +0 -5
- package/dist/ui-kit/LinkList/LinkListProps.js +0 -2
- package/dist/ui-kit/LinkList/LinkListProps.js.map +0 -1
- package/dist/ui-kit/LinkList/linkListStyles.d.ts +0 -1
- package/dist/ui-kit/LinkList/linkListStyles.js +0 -4
- package/dist/ui-kit/LinkList/linkListStyles.js.map +0 -1
- package/dist/ui-kit/LinkList/linkListStyles.mobile.d.ts +0 -1
- package/dist/ui-kit/LinkList/linkListStyles.mobile.js +0 -4
- package/dist/ui-kit/LinkList/linkListStyles.mobile.js.map +0 -1
- package/lib/ui-kit/LinkList/LinkList.d.ts +0 -2
- package/lib/ui-kit/LinkList/LinkList.fixture.d.ts +0 -8
- package/lib/ui-kit/LinkList/LinkList.js +0 -10
- package/lib/ui-kit/LinkList/LinkList.js.map +0 -1
- package/lib/ui-kit/LinkList/LinkListProps.d.ts +0 -5
- package/lib/ui-kit/LinkList/LinkListProps.js +0 -2
- package/lib/ui-kit/LinkList/LinkListProps.js.map +0 -1
- package/lib/ui-kit/LinkList/linkListStyles.d.ts +0 -1
- package/lib/ui-kit/LinkList/linkListStyles.js +0 -2
- package/lib/ui-kit/LinkList/linkListStyles.js.map +0 -1
- package/lib/ui-kit/LinkList/linkListStyles.mobile.d.ts +0 -1
- package/lib/ui-kit/LinkList/linkListStyles.mobile.js +0 -2
- package/lib/ui-kit/LinkList/linkListStyles.mobile.js.map +0 -1
- package/mobile/bundle/ui-kit/LinkList/LinkList.d.ts +0 -2
- package/mobile/bundle/ui-kit/LinkList/LinkListProps.d.ts +0 -5
- package/mobile/bundle/ui-kit/LinkList/linkListStyles.d.ts +0 -1
- package/mobile/dist/ui-kit/LinkList/LinkList.d.ts +0 -2
- package/mobile/dist/ui-kit/LinkList/LinkList.js +0 -12
- package/mobile/dist/ui-kit/LinkList/LinkList.js.map +0 -1
- package/mobile/dist/ui-kit/LinkList/LinkListProps.d.ts +0 -5
- package/mobile/dist/ui-kit/LinkList/LinkListProps.js +0 -2
- package/mobile/dist/ui-kit/LinkList/LinkListProps.js.map +0 -1
- package/mobile/dist/ui-kit/LinkList/linkListStyles.d.ts +0 -1
- package/mobile/dist/ui-kit/LinkList/linkListStyles.js +0 -4
- package/mobile/dist/ui-kit/LinkList/linkListStyles.js.map +0 -1
- package/mobile/lib/ui-kit/LinkList/LinkList.d.ts +0 -2
- package/mobile/lib/ui-kit/LinkList/LinkList.js +0 -10
- package/mobile/lib/ui-kit/LinkList/LinkList.js.map +0 -1
- package/mobile/lib/ui-kit/LinkList/LinkListProps.d.ts +0 -5
- package/mobile/lib/ui-kit/LinkList/LinkListProps.js +0 -2
- package/mobile/lib/ui-kit/LinkList/LinkListProps.js.map +0 -1
- package/mobile/lib/ui-kit/LinkList/linkListStyles.d.ts +0 -1
- package/mobile/lib/ui-kit/LinkList/linkListStyles.js +0 -2
- package/mobile/lib/ui-kit/LinkList/linkListStyles.js.map +0 -1
- package/mobile/src/ui-kit/LinkList/LinkList.tsx +0 -25
- package/mobile/src/ui-kit/LinkList/LinkListProps.tsx +0 -6
- package/mobile/src/ui-kit/LinkList/linkListStyles.ts +0 -1
- package/src/ui-kit/LinkList/LinkList.fixture.tsx +0 -32
- package/src/ui-kit/LinkList/LinkList.tsx +0 -25
- package/src/ui-kit/LinkList/LinkListProps.tsx +0 -6
- package/src/ui-kit/LinkList/linkListStyles.mobile.ts +0 -1
- package/src/ui-kit/LinkList/linkListStyles.ts +0 -1
|
@@ -797,7 +797,7 @@
|
|
|
797
797
|
if (className?.includes('h-')) {
|
|
798
798
|
return {};
|
|
799
799
|
}
|
|
800
|
-
return { height: isOnlyDigits(height) ? `${height}px` : height };
|
|
800
|
+
return { height: isOnlyDigits(height) ? `${height}px` : height, width: 'auto' };
|
|
801
801
|
};
|
|
802
802
|
const getSvgSize = (width) => (width ? '' : 'w-full h-full');
|
|
803
803
|
const Background = JSX(({ className, children }) => className ? jsx("div", { className: className, children: children }) : children);
|
|
@@ -2685,7 +2685,7 @@
|
|
|
2685
2685
|
'description' in _ ? (jsx("span", { className: _.descriptionClassName, children: renderBenefitDescription(_.description, i) }, String(i))) : null,
|
|
2686
2686
|
]);
|
|
2687
2687
|
|
|
2688
|
-
const BenefitItem = JSX(({ className, benefitsVersion, ..._ }) => (jsxs("div", { className: style('flex gap-m', 'description' in _ && _.description ? 'items-start' : 'items-center', className), children: ['icon' in _ ? renderBenefitIcon(_.icon, benefitsVersion) : null, jsx("div", { children: renderBenefitText(_) })] })));
|
|
2688
|
+
const BenefitItem = JSX(({ className, benefitsVersion, ..._ }) => (jsxs("div", { className: style('flex gap-m min-w-56', 'description' in _ && _.description ? 'items-start' : 'items-center', className), children: ['icon' in _ ? renderBenefitIcon(_.icon, benefitsVersion) : null, jsx("div", { children: renderBenefitText(_) })] })));
|
|
2689
2689
|
|
|
2690
2690
|
const MAX_BENEFITS_LEN_DEVIATION = 16;
|
|
2691
2691
|
const benefitLength = (_) => _.type === 'rte'
|
|
@@ -3021,14 +3021,6 @@
|
|
|
3021
3021
|
|
|
3022
3022
|
const useSitemap = (fallback) => useSWRResource(projectSettings.SITEMAP || 'sitemap', { fallback });
|
|
3023
3023
|
|
|
3024
|
-
const linkListStyles = '';
|
|
3025
|
-
|
|
3026
|
-
const LinkList = JSX(({ className = '', items }) => items?.length ? (jsx("ul", { className: style('flex flex-col', linkListStyles, className), children: items.map(renderLinkListItem) })) : null);
|
|
3027
|
-
const renderLinkListItem = (item, i) => {
|
|
3028
|
-
const { text, ...linkProps } = item;
|
|
3029
|
-
return (jsx("li", { className: "list-none my-xs", children: jsx("a", { className: "hover:text-primary-main font-light", role: "link", ...linkProps, children: text ? text : null }) }, `list_item_${String(i)}`));
|
|
3030
|
-
};
|
|
3031
|
-
|
|
3032
3024
|
const TextWithIcon = JSX(({ textNode, iconNode, tag, onClick, justifyContent = 'between', className, ...rest }) => {
|
|
3033
3025
|
const Tag = tag;
|
|
3034
3026
|
return (jsxs(Tag, { tag: tag, className: style('flex items-center w-full gap-1', justifyContent === 'between' ? 'justify-between' : 'justify-center', className), onClick: onClick, ...rest, children: [textNode ? jsx("div", { children: textNode }) : null, iconNode ? jsx("div", { children: iconNode }) : null] }));
|
|
@@ -3103,6 +3095,15 @@
|
|
|
3103
3095
|
|
|
3104
3096
|
const HorizontalNavigation = JSX(({ title, links, className = '' }) => (jsxs("div", { className: className, children: [jsx(Text, { size: "text-l", font: "font-normal", children: title }), links?.length ? (jsx("div", { className: "flex flex-col gap-lg", children: links.map((_, i) => (jsx(HorizontalNavigationLink, { className: "text-l font-light", index: i, ..._ }, String(i)))) })) : null] })));
|
|
3105
3097
|
|
|
3098
|
+
const LinkList = JSX(({ className = '', items, basePath }) => items?.length ? (jsx("ul", { className: style('flex flex-col', className), children: items.map(renderLinkListItem(basePath)) })) : null);
|
|
3099
|
+
const renderLinkListItem = (basePath) => (item, i) => {
|
|
3100
|
+
const { text, ...linkProps } = item;
|
|
3101
|
+
const isAnotherPortal = projectSettings.BASE_PATH && basePath ? !projectSettings.BASE_PATH.startsWith(basePath) : false;
|
|
3102
|
+
const link = useLink({ isRemote: isAnotherPortal, basePath });
|
|
3103
|
+
const { href, target, onClick } = link(linkProps);
|
|
3104
|
+
return (jsx("li", { className: "list-none my-xs", children: jsx("a", { className: "hover:text-primary-main font-light", role: "link", href: href, target: target || '_self', onClick: onClick, children: text ? text : null }) }, `list_item_${String(i)}`));
|
|
3105
|
+
};
|
|
3106
|
+
|
|
3106
3107
|
const TextInformationLink = JSX(({ className = '', index, ...rest }) => {
|
|
3107
3108
|
const link = useLink({ isRemote: true });
|
|
3108
3109
|
const { href, target, text, onClick } = link(rest);
|
|
@@ -3115,7 +3116,7 @@
|
|
|
3115
3116
|
const fallback = rest.options?.page?.fallback;
|
|
3116
3117
|
const { topItems } = useSitemap(fallback);
|
|
3117
3118
|
const { relatedEnterprises, contacts, socialMedia, mobileApps, horizontalNavigationTitle, documents, } = useSWRResource(projectSettings.FOOTER || 'footer', { fallback });
|
|
3118
|
-
return (jsxs(BlockWrapper, { tag: "footer", className: className, defaultPadding: "p-4xl", ...rest, children: [jsx("div", { className: "mb-lg pb-xs border-b border-main-divider", children: topItems?.map((item, i) => (jsx(RollupItem, { label: item?.text, labelIcon: item?.icon, children: jsx(LinkList, { items: item.items }) }, String(i)))) }), jsx(Contacts, { className: "overflow-hidden", items: contacts }), jsxs("div", { className: "mt-xl", children: [jsx(SocialMedia, { className: "mb-xl", media: socialMedia, stretched: true, children: "\u0421\u043E\u0446\u0441\u0435\u0442\u0438" }), jsx(Text, { size: "text-s", font: "font-light", color: "text-secondary-text", children: "\u041C\u043E\u0431\u0438\u043B\u044C\u043D\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435" }), jsx("div", { className: "mt-xs", children: mobileApps?.map(renderButton) })] }), jsx(HorizontalNavigation, { className: "py-lg border-y border-main-divider", title: horizontalNavigationTitle, links: relatedEnterprises }), jsx(TextInformation, { links: documents })] }));
|
|
3119
|
+
return (jsxs(BlockWrapper, { tag: "footer", className: className, defaultPadding: "p-4xl", ...rest, children: [jsx("div", { className: "mb-lg pb-xs border-b border-main-divider", children: topItems?.map((item, i) => (jsx(RollupItem, { label: item?.text, labelIcon: item?.icon, children: jsx(LinkList, { items: item.items, basePath: appendSlash(item.href) }) }, String(i)))) }), jsx(Contacts, { className: "overflow-hidden", items: contacts }), jsxs("div", { className: "mt-xl", children: [jsx(SocialMedia, { className: "mb-xl", media: socialMedia, stretched: true, children: "\u0421\u043E\u0446\u0441\u0435\u0442\u0438" }), jsx(Text, { size: "text-s", font: "font-light", color: "text-secondary-text", children: "\u041C\u043E\u0431\u0438\u043B\u044C\u043D\u043E\u0435 \u043F\u0440\u0438\u043B\u043E\u0436\u0435\u043D\u0438\u0435" }), jsx("div", { className: "mt-xs", children: mobileApps?.map(renderButton) })] }), jsx(HorizontalNavigation, { className: "py-lg border-y border-main-divider", title: horizontalNavigationTitle, links: relatedEnterprises }), jsx(TextInformation, { links: documents })] }));
|
|
3119
3120
|
});
|
|
3120
3121
|
const renderButton = ({ href = '/', text }, i) => {
|
|
3121
3122
|
const { label } = findIconByHref(href);
|
|
@@ -4902,7 +4903,7 @@
|
|
|
4902
4903
|
parent: data,
|
|
4903
4904
|
};
|
|
4904
4905
|
useBlockRouterProvider();
|
|
4905
|
-
return (jsxs("div", { "data-theme": colorPalette, children: [jsxs("section", { className: style('relative', pageStyle, className), children: [slots?.header ? (jsx("div", { className: "relative z-10 mb-lg shadow-[0_8px_32px_0px_#00000014]", children: renderBlocksList(slots?.header, { ...options, slotName: 'header' }) })) : null, jsxs("div", { className: "container space-y-px @lg:space-y-0 @lg:grid @lg:grid-cols-12 @lg:gap-2xs", children: [renderChildren({ block: data, options, extraProps: { className: 'scroll-mt-12' } }), renderBlocksList(slots?.footer, { ...options, slotName: 'footer' })] }), likeControl ? renderLikeControl() : null] }), jsx(StickyBottomMenu, {}), jsx(DialogManager, {}), jsx(PopupManager, {}), jsx(CookiePopup, { termLink: { href: '/pd-policy#cookie', target: '_blank' }, personalDataPolicyLink: { href: '/pd-policy', target: '_blank' } })] }));
|
|
4906
|
+
return (jsxs("div", { "data-theme": colorPalette, children: [jsxs("section", { className: style('@container relative', pageStyle, className), children: [slots?.header ? (jsx("div", { className: "relative z-10 mb-lg shadow-[0_8px_32px_0px_#00000014]", children: renderBlocksList(slots?.header, { ...options, slotName: 'header' }) })) : null, jsxs("div", { className: "container space-y-px @lg:space-y-0 @lg:grid @lg:grid-cols-12 @lg:gap-2xs", children: [renderChildren({ block: data, options, extraProps: { className: 'scroll-mt-12' } }), renderBlocksList(slots?.footer, { ...options, slotName: 'footer' })] }), likeControl ? renderLikeControl() : null] }), jsx(StickyBottomMenu, {}), jsx(DialogManager, {}), jsx(PopupManager, {}), jsx(CookiePopup, { termLink: { href: '/pd-policy#cookie', target: '_blank' }, personalDataPolicyLink: { href: '/pd-policy', target: '_blank' } })] }));
|
|
4906
4907
|
});
|
|
4907
4908
|
ContentPage.childrenTypes = [];
|
|
4908
4909
|
ContentPage.slots = () => ['header', 'footer', 'StickyBottomMenu'];
|
|
@@ -4912,7 +4913,7 @@
|
|
|
4912
4913
|
|
|
4913
4914
|
const joinList = (sep) => (list) => list.reduce((acc, el, i) => (acc.length ? acc.concat({ ...sep, key: `sep-${i}` }, el) : [el]), []);
|
|
4914
4915
|
|
|
4915
|
-
const packageVersion = "0.14.
|
|
4916
|
+
const packageVersion = "0.14.10";
|
|
4916
4917
|
|
|
4917
4918
|
exports.Blocks = Blocks;
|
|
4918
4919
|
exports.ContentPage = ContentPage;
|