@redneckz/wildless-cms-uni-blocks 0.8.21 → 0.8.22
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 +14 -43
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/StepsBlock/StepsBlock.d.ts +1 -1
- package/bundle/components/StepsBlock/StepsBlockContent.d.ts +2 -1
- package/bundle/components/StepsBlock/StepsBlockStyleMaps.d.ts +1 -2
- package/dist/components/StepsBlock/StepsBlock.d.ts +1 -1
- package/dist/components/StepsBlock/StepsBlock.js +11 -8
- package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlock.mobile.js +2 -6
- package/dist/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlockContent.d.ts +2 -1
- package/dist/components/StepsBlock/StepsBlockStyleMaps.d.ts +1 -2
- package/dist/components/StepsBlock/StepsBlockStyleMaps.js +7 -39
- package/dist/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/StepsBlock/StepsBlock.d.ts +1 -1
- package/lib/components/StepsBlock/StepsBlock.js +12 -9
- package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlock.mobile.js +3 -7
- package/lib/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlockContent.d.ts +2 -1
- package/lib/components/StepsBlock/StepsBlockStyleMaps.d.ts +1 -2
- package/lib/components/StepsBlock/StepsBlockStyleMaps.js +6 -38
- package/lib/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +9 -45
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/StepsBlock/StepsBlockContent.d.ts +2 -1
- package/mobile/bundle/components/StepsBlock/StepsBlockStyleMaps.d.ts +1 -2
- package/mobile/dist/components/StepsBlock/StepsBlock.js +2 -6
- package/mobile/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/mobile/dist/components/StepsBlock/StepsBlockContent.d.ts +2 -1
- package/mobile/dist/components/StepsBlock/StepsBlockStyleMaps.d.ts +1 -2
- package/mobile/dist/components/StepsBlock/StepsBlockStyleMaps.js +7 -39
- package/mobile/dist/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/mobile/lib/components/StepsBlock/StepsBlock.js +3 -7
- package/mobile/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/mobile/lib/components/StepsBlock/StepsBlockContent.d.ts +2 -1
- package/mobile/lib/components/StepsBlock/StepsBlockStyleMaps.d.ts +1 -2
- package/mobile/lib/components/StepsBlock/StepsBlockStyleMaps.js +6 -38
- package/mobile/lib/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/mobile/src/components/Catalog/Catalog.ui.json +1 -0
- package/mobile/src/components/Gallery/Gallery.ui.json +1 -0
- package/mobile/src/components/MiniGallery/MiniGallery.ui.json +1 -0
- package/mobile/src/components/StepsBlock/StepsBlock.example.json +3 -1
- package/mobile/src/components/StepsBlock/StepsBlock.tsx +23 -27
- package/mobile/src/components/StepsBlock/StepsBlockContent.ts +2 -1
- package/mobile/src/components/StepsBlock/StepsBlockStyleMaps.ts +6 -40
- package/package.json +1 -1
- package/src/components/Catalog/Catalog.ui.json +1 -0
- package/src/components/Gallery/Gallery.ui.json +1 -0
- package/src/components/MiniGallery/MiniGallery.ui.json +1 -0
- package/src/components/StepsBlock/StepsBlock.example.json +3 -1
- package/src/components/StepsBlock/StepsBlock.fixture.tsx +4 -0
- package/src/components/StepsBlock/StepsBlock.mobile.tsx +23 -27
- package/src/components/StepsBlock/StepsBlock.tsx +34 -27
- package/src/components/StepsBlock/StepsBlockContent.ts +2 -1
- package/src/components/StepsBlock/StepsBlockStyleMaps.ts +6 -40
package/bundle/bundle.umd.js
CHANGED
|
@@ -3916,56 +3916,27 @@
|
|
|
3916
3916
|
};
|
|
3917
3917
|
const getContainerWidth = (length) => (length < 5 ? 'w-[276px]' : 'w-[210px]');
|
|
3918
3918
|
|
|
3919
|
-
const
|
|
3920
|
-
primary:
|
|
3921
|
-
|
|
3922
|
-
|
|
3923
|
-
|
|
3924
|
-
|
|
3925
|
-
dot: 'bg-secondary-text',
|
|
3926
|
-
},
|
|
3927
|
-
secondary: {
|
|
3928
|
-
description: '!text-white/80 text-l-light',
|
|
3929
|
-
iconText: 'text-white',
|
|
3930
|
-
iconBackground: 'bg-white/30',
|
|
3931
|
-
iconConnector: 'bg-white',
|
|
3932
|
-
dot: 'bg-white/80',
|
|
3933
|
-
},
|
|
3934
|
-
gray: {
|
|
3935
|
-
// TODO Replace this Map with group-data-*
|
|
3936
|
-
description: '!text-white/80 text-l-light',
|
|
3937
|
-
iconText: 'text-white',
|
|
3938
|
-
iconBackground: 'bg-white/30',
|
|
3939
|
-
iconConnector: 'bg-white',
|
|
3940
|
-
dot: 'bg-white/80',
|
|
3941
|
-
},
|
|
3942
|
-
transparent: {
|
|
3943
|
-
description: '!text-white/80 text-l-light',
|
|
3944
|
-
iconText: 'text-white',
|
|
3945
|
-
iconBackground: 'bg-white/30',
|
|
3946
|
-
iconConnector: 'bg-white',
|
|
3947
|
-
dot: 'bg-white/80',
|
|
3948
|
-
},
|
|
3949
|
-
'': {
|
|
3950
|
-
// TODO Replace this Map with group-data-*
|
|
3951
|
-
description: '!text-white/80 text-l-light',
|
|
3952
|
-
iconText: 'text-white',
|
|
3953
|
-
iconBackground: 'bg-white/30',
|
|
3954
|
-
iconConnector: 'bg-white',
|
|
3955
|
-
dot: 'bg-white/80',
|
|
3956
|
-
},
|
|
3919
|
+
const STEPS_BLOCK_STYLE = {
|
|
3920
|
+
description: 'text-white/80 text-l-light group-data-primary:text-secondary-text',
|
|
3921
|
+
iconText: 'text-white group-data-primary:text-secondary-text',
|
|
3922
|
+
iconBackground: 'bg-white/30 group-data-primary:bg-main-divider',
|
|
3923
|
+
iconConnector: 'bg-white group-data-primary:bg-secondary-light',
|
|
3924
|
+
dot: 'bg-white/80 group-data-primary:bg-secondary-text',
|
|
3957
3925
|
};
|
|
3958
3926
|
|
|
3959
3927
|
const getLineOpacity = (showLines) => (showLines ? '' : 'opacity-0');
|
|
3960
3928
|
const getPaddingX = (steps) => (steps < 5 ? 'px-[88px]' : 'px-[55px]');
|
|
3961
|
-
const StepsBlock = JSX(({ className = '', showLines = true, steps = [], button, version = 'primary', title, ...rest }) => {
|
|
3929
|
+
const StepsBlock = JSX(({ className = '', showLines = true, steps = [], button, size = 'normal', version = 'primary', stepVersion = 'gray', title, ...rest }) => {
|
|
3962
3930
|
const shortGaps = steps.length > 3;
|
|
3963
|
-
const styleMap =
|
|
3931
|
+
const styleMap = STEPS_BLOCK_STYLE;
|
|
3964
3932
|
const lineOpacity = getLineOpacity(showLines);
|
|
3965
3933
|
const paddingX = getPaddingX(steps.length);
|
|
3966
|
-
return (jsxs(BlockWrapper, { className: style('box-border py-12', shortGaps ? 'px-20' : 'px-[70px]', 'flex flex-col items-center overflow-hidden', className), version: version, ...rest, children: [title ? (jsx(Heading, { headingType: "
|
|
3934
|
+
return (jsxs(BlockWrapper, { className: style('box-border py-12', shortGaps ? 'px-20' : 'px-[70px]', 'flex flex-col items-center overflow-hidden', className), version: version, ...rest, children: [title ? (jsx(Heading, { headingType: "h4", className: "max-w-[752px] text-center mb-9", title: title })) : null, steps?.length ? (jsxs("div", { className: "box-border", children: [jsx("div", { className: style('flex items-center', paddingX), children: joinList(jsx("div", { className: style('h-0.5 w-full bg-secondary-light flex-1', lineOpacity) }))(steps.map(renderStepIcon(styleMap, size, stepVersion))) }), jsx("div", { className: style('flex justify-between mt-4', shortGaps ? 'gap-x-3' : 'gap-x-[101px]'), children: steps.map(renderStep({ styleMap, isMainButton: Boolean(button?.text), version })) })] })) : null, button?.text ? renderButtonsSection([button], { className: 'mt-8 min-w-60' }) : null] }));
|
|
3967
3935
|
});
|
|
3968
|
-
const renderStepIcon = (styleMap,
|
|
3936
|
+
const renderStepIcon = (styleMap, size, stepVersion) => ({ icon }, i) => {
|
|
3937
|
+
const styleStepIconSize = size === 'normal' ? 'h-[100px] w-[100px]' : 'h-[63px] w-[63px]';
|
|
3938
|
+
return (jsx(BlockWrapper, { className: `${styleStepIconSize} flex justify-center items-center text-center rounded-full p-[26px] box-border z-10`, version: stepVersion, children: checkCanRenderIcon(icon) ? (jsx(ImgInner, { image: getIconWithVersion(icon || {}, stepVersion), width: "48", height: "48", asSVG: true })) : (jsx("span", { className: `text-h4 group-data-transparent:${styleMap.iconText} text-primary-text`, children: i + 1 })) }, String(i)));
|
|
3939
|
+
};
|
|
3969
3940
|
|
|
3970
3941
|
const containerStyles = {
|
|
3971
3942
|
'horizontal-list': 'mx-auto mt-5 w-fit',
|
|
@@ -4570,7 +4541,7 @@
|
|
|
4570
4541
|
return (jsx("div", { className: "flex items-end absolute bottom-0 right-0 h-full pointer-events-none", children: jsx(LikeControl, { className: "rounded-tl-lg sticky bottom-0 pointer-events-auto" }) }));
|
|
4571
4542
|
}
|
|
4572
4543
|
|
|
4573
|
-
const packageVersion = "0.8.
|
|
4544
|
+
const packageVersion = "0.8.22";
|
|
4574
4545
|
|
|
4575
4546
|
exports.Blocks = Blocks;
|
|
4576
4547
|
exports.ContentPage = ContentPage;
|