@redneckz/wildless-cms-uni-blocks 0.14.69 → 0.14.71
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.14.62.js +3 -1
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +11 -12
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/StepsBlock/StepsBlockContent.d.ts +2 -2
- package/bundle/ui-kit/List/ListContent.d.ts +2 -0
- package/dist/components/BenefitsBlock/BenefitsBlock.js +1 -1
- package/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -3
- package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlock.js +2 -2
- package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlockContent.d.ts +2 -2
- package/dist/ui-kit/BaseTile/BaseTile.js +3 -2
- package/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/dist/ui-kit/List/List.js +2 -2
- package/dist/ui-kit/List/List.js.map +1 -1
- package/dist/ui-kit/List/ListContent.d.ts +2 -0
- package/dist/ui-kit/List/ListItem.js +1 -1
- package/dist/ui-kit/List/ListItem.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.js +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -3
- package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlock.js +2 -2
- package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlockContent.d.ts +2 -2
- package/lib/ui-kit/BaseTile/BaseTile.js +3 -2
- package/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/lib/ui-kit/List/List.js +2 -2
- package/lib/ui-kit/List/List.js.map +1 -1
- package/lib/ui-kit/List/ListContent.d.ts +2 -0
- package/lib/ui-kit/List/ListItem.js +1 -1
- package/lib/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +9 -10
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/StepsBlock/StepsBlockContent.d.ts +2 -2
- package/mobile/bundle/ui-kit/List/ListContent.d.ts +2 -0
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js +1 -1
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -3
- package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
- package/mobile/dist/components/StepsBlock/StepsBlockContent.d.ts +2 -2
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js +3 -2
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/dist/ui-kit/List/List.js +2 -2
- package/mobile/dist/ui-kit/List/List.js.map +1 -1
- package/mobile/dist/ui-kit/List/ListContent.d.ts +2 -0
- package/mobile/dist/ui-kit/List/ListItem.js +1 -1
- package/mobile/dist/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js +1 -1
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -3
- package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
- package/mobile/lib/components/StepsBlock/StepsBlockContent.d.ts +2 -2
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js +3 -2
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/lib/ui-kit/List/List.js +2 -2
- package/mobile/lib/ui-kit/List/List.js.map +1 -1
- package/mobile/lib/ui-kit/List/ListContent.d.ts +2 -0
- package/mobile/lib/ui-kit/List/ListItem.js +1 -1
- package/mobile/lib/ui-kit/List/ListItem.js.map +1 -1
- package/mobile/src/components/BenefitsBlock/BenefitsBlock.tsx +1 -1
- package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCard.tsx +37 -39
- package/mobile/src/components/StepsBlock/StepsBlockContent.ts +3 -6
- package/mobile/src/ui-kit/BaseTile/BaseTile.tsx +3 -1
- package/mobile/src/ui-kit/List/List.tsx +6 -2
- package/mobile/src/ui-kit/List/ListContent.ts +2 -0
- package/mobile/src/ui-kit/List/ListItem.tsx +1 -1
- package/package.json +1 -1
- package/src/components/BenefitsBlock/BenefitsBlock.tsx +1 -1
- package/src/components/CarouselRecommendationCard/CarouselRecommendationCard.tsx +37 -39
- package/src/components/StepsBlock/StepsBlock.tsx +1 -2
- package/src/components/StepsBlock/StepsBlockContent.ts +3 -6
- package/src/ui-kit/BaseTile/BaseTile.tsx +3 -1
- package/src/ui-kit/List/List.tsx +6 -2
- package/src/ui-kit/List/ListContent.ts +2 -0
- package/src/ui-kit/List/ListItem.tsx +1 -1
|
@@ -40,45 +40,43 @@ export const CarouselRecommendationCard = JSX<RecommendationCardProps>(
|
|
|
40
40
|
isImageSecondary = false,
|
|
41
41
|
} = {},
|
|
42
42
|
...rest
|
|
43
|
-
}) =>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
>
|
|
50
|
-
<
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
socialMedia
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
);
|
|
81
|
-
},
|
|
43
|
+
}) => (
|
|
44
|
+
<BlockWrapper
|
|
45
|
+
className={style('relative min-h-28 group-data-gray:bg-main-divider/50', className)}
|
|
46
|
+
defaultPadding="p-0"
|
|
47
|
+
{...rest}
|
|
48
|
+
>
|
|
49
|
+
<LinkWrapper href={href} target={target} className="h-full">
|
|
50
|
+
<BaseTile
|
|
51
|
+
className="h-full"
|
|
52
|
+
defaultPadding="p-2xl"
|
|
53
|
+
padding={padding}
|
|
54
|
+
insetTitle={
|
|
55
|
+
<Headline
|
|
56
|
+
title={title}
|
|
57
|
+
description={description}
|
|
58
|
+
headlineVersion="XS"
|
|
59
|
+
isEmbedded={true}
|
|
60
|
+
align={align}
|
|
61
|
+
/>
|
|
62
|
+
}
|
|
63
|
+
{...leftOrRightImage(isIcon(icon) ? <Img image={icon} /> : null, directionRight)}
|
|
64
|
+
buttons={
|
|
65
|
+
socialMedia.length ? (
|
|
66
|
+
<SocialMedia media={socialMedia} showButtonText={true} version={rest?.version} />
|
|
67
|
+
) : null
|
|
68
|
+
}
|
|
69
|
+
isImageAlwaysOnRight={isImageAlwaysOnRight}
|
|
70
|
+
isImageSecondary={isImageSecondary}
|
|
71
|
+
imageAlign="center"
|
|
72
|
+
>
|
|
73
|
+
<BenefitsList benefits={benefits} />
|
|
74
|
+
<List items={items} isDotted={isDotted} listItemSize="S" />
|
|
75
|
+
{renderAdditionalDescription(additionalDescription, align)}
|
|
76
|
+
</BaseTile>
|
|
77
|
+
</LinkWrapper>
|
|
78
|
+
</BlockWrapper>
|
|
79
|
+
),
|
|
82
80
|
);
|
|
83
81
|
|
|
84
82
|
const renderAdditionalDescription = (additionalDescription?: string, align?: TextAlign) =>
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import { type BlockVersion } from '../../model/BlockVersion';
|
|
2
2
|
import { type BulletsProps } from '../../model/Bullets';
|
|
3
3
|
import { type DefaultListItemType } from '../../model/DefaultListItemType';
|
|
4
|
-
import {
|
|
5
|
-
type DescriptionProps,
|
|
6
|
-
type HeadlineCommonProps,
|
|
7
|
-
type LabelProps,
|
|
8
|
-
} from '../../model/HeadlineType';
|
|
4
|
+
import { type DescriptionProps, type LabelProps, type TitleProps } from '../../model/HeadlineType';
|
|
9
5
|
import { type UniBlockContent } from '../../model/JSXBlock';
|
|
10
6
|
import { type IconProps } from '../../model/Picture';
|
|
11
7
|
import { type RichTextItem } from '../../model/RichTextItem';
|
|
@@ -42,7 +38,8 @@ export type Step = DefaultStep | RichTextStep;
|
|
|
42
38
|
* @title Блок шаги
|
|
43
39
|
*/
|
|
44
40
|
export type StepsBlockContent = UniBlockContent &
|
|
45
|
-
|
|
41
|
+
TitleProps &
|
|
42
|
+
DescriptionProps &
|
|
46
43
|
ButtonsSectionContent & {
|
|
47
44
|
/** @title Линии */
|
|
48
45
|
showLines?: boolean;
|
|
@@ -65,6 +65,8 @@ export const BaseTile = JSX<BaseTileProps>(
|
|
|
65
65
|
'grid gap-3xl',
|
|
66
66
|
rightImage ? '@xl:grid-cols-2' : '',
|
|
67
67
|
leftImage ? '' : 'grow',
|
|
68
|
+
'h-full', //? fix issue https://github.com/redneckz/temp_wcms/issues/1254
|
|
69
|
+
'auto-rows-[max-content_1fr]', //? fix issue https://github.com/redneckz/temp_wcms/issues/1324
|
|
68
70
|
)}
|
|
69
71
|
>
|
|
70
72
|
<div className="grow space-y-lg min-w-fit">
|
|
@@ -107,7 +109,7 @@ const renderImageContainer = (
|
|
|
107
109
|
image ? (
|
|
108
110
|
<div
|
|
109
111
|
className={style(
|
|
110
|
-
'shrink-1/2 justify-self-center',
|
|
112
|
+
'shrink-1/2 justify-self-center mt-auto @xl:mt-0',
|
|
111
113
|
imageAlign && imageAlignmentMap[imageAlign],
|
|
112
114
|
className,
|
|
113
115
|
)}
|
|
@@ -29,7 +29,7 @@ export const LIST_VERSION_STYLE: Record<
|
|
|
29
29
|
};
|
|
30
30
|
|
|
31
31
|
export const List = JSX<ListProps>(
|
|
32
|
-
({ className, isDotted = true, items = [], listItemSize = 'M' }) => {
|
|
32
|
+
({ className, isDotted = true, items = [], listItemSize = 'M', dotClassName = '' }) => {
|
|
33
33
|
const versionStyle = LIST_VERSION_STYLE[listItemSize];
|
|
34
34
|
|
|
35
35
|
return items?.length ? (
|
|
@@ -42,7 +42,11 @@ export const List = JSX<ListProps>(
|
|
|
42
42
|
role="list"
|
|
43
43
|
>
|
|
44
44
|
{items.map((item, i) => (
|
|
45
|
-
<ListItem
|
|
45
|
+
<ListItem
|
|
46
|
+
key={String(i)}
|
|
47
|
+
isDotted={isDotted}
|
|
48
|
+
dotClassName={style(dotClassName || 'bg-primary-text', versionStyle.dotStyle)}
|
|
49
|
+
>
|
|
46
50
|
{item}
|
|
47
51
|
</ListItem>
|
|
48
52
|
))}
|
|
@@ -17,7 +17,7 @@ export const ListItem = JSX<ListItemProps>(({ className, isDotted, dotClassName,
|
|
|
17
17
|
<div className="shrink-0">
|
|
18
18
|
<div
|
|
19
19
|
className={style(
|
|
20
|
-
'align-middle inline-block rounded-full
|
|
20
|
+
'align-middle inline-block rounded-full group-data-secondary:bg-white',
|
|
21
21
|
dotClassName,
|
|
22
22
|
)}
|
|
23
23
|
/>
|
package/package.json
CHANGED
|
@@ -56,7 +56,7 @@ const renderBenefit = (
|
|
|
56
56
|
>
|
|
57
57
|
{description}
|
|
58
58
|
</Text>
|
|
59
|
-
<List
|
|
59
|
+
<List dotClassName="bg-secondary-text" listItemSize="S" items={items} isDotted={isDotted} />
|
|
60
60
|
</div>
|
|
61
61
|
) : null}
|
|
62
62
|
</div>
|
|
@@ -40,45 +40,43 @@ export const CarouselRecommendationCard = JSX<RecommendationCardProps>(
|
|
|
40
40
|
isImageSecondary = false,
|
|
41
41
|
} = {},
|
|
42
42
|
...rest
|
|
43
|
-
}) =>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
>
|
|
50
|
-
<
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
socialMedia
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
);
|
|
81
|
-
},
|
|
43
|
+
}) => (
|
|
44
|
+
<BlockWrapper
|
|
45
|
+
className={style('relative min-h-28 group-data-gray:bg-main-divider/50', className)}
|
|
46
|
+
defaultPadding="p-0"
|
|
47
|
+
{...rest}
|
|
48
|
+
>
|
|
49
|
+
<LinkWrapper href={href} target={target} className="h-full">
|
|
50
|
+
<BaseTile
|
|
51
|
+
className="h-full"
|
|
52
|
+
defaultPadding="p-2xl"
|
|
53
|
+
padding={padding}
|
|
54
|
+
insetTitle={
|
|
55
|
+
<Headline
|
|
56
|
+
title={title}
|
|
57
|
+
description={description}
|
|
58
|
+
headlineVersion="XS"
|
|
59
|
+
isEmbedded={true}
|
|
60
|
+
align={align}
|
|
61
|
+
/>
|
|
62
|
+
}
|
|
63
|
+
{...leftOrRightImage(isIcon(icon) ? <Img image={icon} /> : null, directionRight)}
|
|
64
|
+
buttons={
|
|
65
|
+
socialMedia.length ? (
|
|
66
|
+
<SocialMedia media={socialMedia} showButtonText={true} version={rest?.version} />
|
|
67
|
+
) : null
|
|
68
|
+
}
|
|
69
|
+
isImageAlwaysOnRight={isImageAlwaysOnRight}
|
|
70
|
+
isImageSecondary={isImageSecondary}
|
|
71
|
+
imageAlign="center"
|
|
72
|
+
>
|
|
73
|
+
<BenefitsList benefits={benefits} />
|
|
74
|
+
<List items={items} isDotted={isDotted} listItemSize="S" />
|
|
75
|
+
{renderAdditionalDescription(additionalDescription, align)}
|
|
76
|
+
</BaseTile>
|
|
77
|
+
</LinkWrapper>
|
|
78
|
+
</BlockWrapper>
|
|
79
|
+
),
|
|
82
80
|
);
|
|
83
81
|
|
|
84
82
|
const renderAdditionalDescription = (additionalDescription?: string, align?: TextAlign) =>
|
|
@@ -21,7 +21,6 @@ const getPaddingX = (steps: number) => (steps < 5 ? 'px-24' : 'px-16');
|
|
|
21
21
|
|
|
22
22
|
export const StepsBlock = JSX<StepsBlockProps>(
|
|
23
23
|
({
|
|
24
|
-
align = AlignStyles,
|
|
25
24
|
buttons,
|
|
26
25
|
className = '',
|
|
27
26
|
description,
|
|
@@ -58,7 +57,7 @@ export const StepsBlock = JSX<StepsBlockProps>(
|
|
|
58
57
|
description={description}
|
|
59
58
|
isEmbedded={true}
|
|
60
59
|
className="w-full"
|
|
61
|
-
align={
|
|
60
|
+
align={AlignStyles}
|
|
62
61
|
/>
|
|
63
62
|
{steps?.length ? (
|
|
64
63
|
<div className="box-border space-y-lg">
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import { type BlockVersion } from '../../model/BlockVersion';
|
|
2
2
|
import { type BulletsProps } from '../../model/Bullets';
|
|
3
3
|
import { type DefaultListItemType } from '../../model/DefaultListItemType';
|
|
4
|
-
import {
|
|
5
|
-
type DescriptionProps,
|
|
6
|
-
type HeadlineCommonProps,
|
|
7
|
-
type LabelProps,
|
|
8
|
-
} from '../../model/HeadlineType';
|
|
4
|
+
import { type DescriptionProps, type LabelProps, type TitleProps } from '../../model/HeadlineType';
|
|
9
5
|
import { type UniBlockContent } from '../../model/JSXBlock';
|
|
10
6
|
import { type IconProps } from '../../model/Picture';
|
|
11
7
|
import { type RichTextItem } from '../../model/RichTextItem';
|
|
@@ -42,7 +38,8 @@ export type Step = DefaultStep | RichTextStep;
|
|
|
42
38
|
* @title Блок шаги
|
|
43
39
|
*/
|
|
44
40
|
export type StepsBlockContent = UniBlockContent &
|
|
45
|
-
|
|
41
|
+
TitleProps &
|
|
42
|
+
DescriptionProps &
|
|
46
43
|
ButtonsSectionContent & {
|
|
47
44
|
/** @title Линии */
|
|
48
45
|
showLines?: boolean;
|
|
@@ -65,6 +65,8 @@ export const BaseTile = JSX<BaseTileProps>(
|
|
|
65
65
|
'grid gap-3xl',
|
|
66
66
|
rightImage ? '@xl:grid-cols-2' : '',
|
|
67
67
|
leftImage ? '' : 'grow',
|
|
68
|
+
'h-full', //? fix issue https://github.com/redneckz/temp_wcms/issues/1254
|
|
69
|
+
'auto-rows-[max-content_1fr]', //? fix issue https://github.com/redneckz/temp_wcms/issues/1324
|
|
68
70
|
)}
|
|
69
71
|
>
|
|
70
72
|
<div className="grow space-y-lg min-w-fit">
|
|
@@ -107,7 +109,7 @@ const renderImageContainer = (
|
|
|
107
109
|
image ? (
|
|
108
110
|
<div
|
|
109
111
|
className={style(
|
|
110
|
-
'shrink-1/2 justify-self-center',
|
|
112
|
+
'shrink-1/2 justify-self-center mt-auto @xl:mt-0',
|
|
111
113
|
imageAlign && imageAlignmentMap[imageAlign],
|
|
112
114
|
className,
|
|
113
115
|
)}
|
package/src/ui-kit/List/List.tsx
CHANGED
|
@@ -29,7 +29,7 @@ export const LIST_VERSION_STYLE: Record<
|
|
|
29
29
|
};
|
|
30
30
|
|
|
31
31
|
export const List = JSX<ListProps>(
|
|
32
|
-
({ className, isDotted = true, items = [], listItemSize = 'M' }) => {
|
|
32
|
+
({ className, isDotted = true, items = [], listItemSize = 'M', dotClassName = '' }) => {
|
|
33
33
|
const versionStyle = LIST_VERSION_STYLE[listItemSize];
|
|
34
34
|
|
|
35
35
|
return items?.length ? (
|
|
@@ -42,7 +42,11 @@ export const List = JSX<ListProps>(
|
|
|
42
42
|
role="list"
|
|
43
43
|
>
|
|
44
44
|
{items.map((item, i) => (
|
|
45
|
-
<ListItem
|
|
45
|
+
<ListItem
|
|
46
|
+
key={String(i)}
|
|
47
|
+
isDotted={isDotted}
|
|
48
|
+
dotClassName={style(dotClassName || 'bg-primary-text', versionStyle.dotStyle)}
|
|
49
|
+
>
|
|
46
50
|
{item}
|
|
47
51
|
</ListItem>
|
|
48
52
|
))}
|
|
@@ -17,7 +17,7 @@ export const ListItem = JSX<ListItemProps>(({ className, isDotted, dotClassName,
|
|
|
17
17
|
<div className="shrink-0">
|
|
18
18
|
<div
|
|
19
19
|
className={style(
|
|
20
|
-
'align-middle inline-block rounded-full
|
|
20
|
+
'align-middle inline-block rounded-full group-data-secondary:bg-white',
|
|
21
21
|
dotClassName,
|
|
22
22
|
)}
|
|
23
23
|
/>
|