@redneckz/wildless-cms-uni-blocks 0.3.5 → 0.3.8
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 +54 -32
- package/bundle/bundle.umd.min.js +1 -1
- package/dist/components/BaseTile/BaseTile.js +1 -1
- package/dist/components/BaseTile/BaseTile.js.map +1 -1
- package/dist/components/Blocks.d.ts +0 -1
- package/dist/components/Blocks.js +0 -2
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Blocks.mobile.d.ts +1 -1
- package/dist/components/Blocks.mobile.js +2 -2
- package/dist/components/Blocks.mobile.js.map +1 -1
- package/dist/components/ContentPage/ContentPageHead.js +13 -4
- package/dist/components/ContentPage/ContentPageHead.js.map +1 -1
- package/dist/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
- package/dist/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
- package/dist/components/Gallery/GalleryCardInner.js +15 -5
- package/dist/components/Gallery/GalleryCardInner.js.map +1 -1
- package/dist/components/Header/Header.mobile.js +1 -1
- package/dist/components/Header/Header.mobile.js.map +1 -1
- package/dist/components/Header/HeaderBurger.js +1 -1
- package/dist/components/Header/HeaderBurger.js.map +1 -1
- package/dist/components/Header/HeaderTop.js +1 -1
- package/dist/components/Header/HeaderTop.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/dist/components/LinkDocs/LinkDocsListItem.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocsListItem.mobile.js +1 -1
- package/dist/components/LinkDocs/LinkDocsListItem.mobile.js.map +1 -1
- package/dist/components/ProductBlock/ProductBlockInner.js +1 -1
- package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/dist/components/ProductBlock/ProductBlockInner.mobile.js +4 -1
- package/dist/components/ProductBlock/ProductBlockInner.mobile.js.map +1 -1
- package/dist/components/ProductBlock/renderBenefit.mobile.js +1 -1
- package/dist/components/ProductBlock/renderBenefit.mobile.js.map +1 -1
- package/dist/components/ProductGallery/ProductGallery.mobile.js +3 -14
- package/dist/components/ProductGallery/ProductGallery.mobile.js.map +1 -1
- package/dist/components/ProductGallery/ProductGalleryBlock.mobile.js +1 -1
- package/dist/components/StepsBlock/StepsBlock.mobile.js +2 -2
- package/dist/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
- package/dist/components/Tile/Tile.js +5 -1
- package/dist/components/Tile/Tile.js.map +1 -1
- package/dist/types.d.ts +10 -5
- package/dist/ui-kit/BlockItem/BlockItem.js +3 -3
- package/dist/ui-kit/BlockItem/BlockItem.js.map +1 -1
- package/dist/ui-kit/Description/Description.js +1 -1
- package/dist/ui-kit/Heading/Heading.js +1 -1
- package/dist/ui-kit/Heading/Heading.js.map +1 -1
- package/dist/ui-kit/Heading/Heading.mobile.js +1 -1
- package/dist/ui-kit/Heading/Heading.mobile.js.map +1 -1
- package/dist/ui-kit/List/ListItem.js +2 -2
- package/dist/ui-kit/List/ListItem.js.map +1 -1
- package/dist/ui-kit/SwipeListControl/SwipeListControlDots.js +1 -1
- package/dist/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
- package/dist/ui-kit/SwipeListControl/SwipeListControlItem.js +1 -1
- package/dist/ui-kit/SwipeListControl/SwipeListControlItem.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/BaseTile/BaseTile.js +1 -1
- package/lib/components/BaseTile/BaseTile.js.map +1 -1
- package/lib/components/Blocks.d.ts +0 -1
- package/lib/components/Blocks.js +0 -2
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Blocks.mobile.d.ts +1 -1
- package/lib/components/Blocks.mobile.js +2 -2
- package/lib/components/Blocks.mobile.js.map +1 -1
- package/lib/components/ContentPage/ContentPageHead.js +13 -4
- package/lib/components/ContentPage/ContentPageHead.js.map +1 -1
- package/lib/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
- package/lib/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
- package/lib/components/Gallery/GalleryCardInner.js +15 -5
- package/lib/components/Gallery/GalleryCardInner.js.map +1 -1
- package/lib/components/Header/Header.mobile.js +1 -1
- package/lib/components/Header/Header.mobile.js.map +1 -1
- package/lib/components/Header/HeaderBurger.js +1 -1
- package/lib/components/Header/HeaderBurger.js.map +1 -1
- package/lib/components/Header/HeaderTop.js +1 -1
- package/lib/components/Header/HeaderTop.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/lib/components/LinkDocs/LinkDocsListItem.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocsListItem.mobile.js +1 -1
- package/lib/components/LinkDocs/LinkDocsListItem.mobile.js.map +1 -1
- package/lib/components/ProductBlock/ProductBlockInner.js +1 -1
- package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/lib/components/ProductBlock/ProductBlockInner.mobile.js +4 -1
- package/lib/components/ProductBlock/ProductBlockInner.mobile.js.map +1 -1
- package/lib/components/ProductBlock/renderBenefit.mobile.js +1 -1
- package/lib/components/ProductBlock/renderBenefit.mobile.js.map +1 -1
- package/lib/components/ProductGallery/ProductGallery.fixture.mobile.d.ts +1 -0
- package/lib/components/ProductGallery/ProductGallery.mobile.js +4 -15
- package/lib/components/ProductGallery/ProductGallery.mobile.js.map +1 -1
- package/lib/components/ProductGallery/ProductGalleryBlock.mobile.js +1 -1
- package/lib/components/StepsBlock/StepsBlock.mobile.js +2 -2
- package/lib/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
- package/lib/components/Tile/Tile.js +5 -1
- package/lib/components/Tile/Tile.js.map +1 -1
- package/lib/types.d.ts +10 -5
- package/lib/ui-kit/BlockItem/BlockItem.js +3 -3
- package/lib/ui-kit/BlockItem/BlockItem.js.map +1 -1
- package/lib/ui-kit/Description/Description.js +1 -1
- package/lib/ui-kit/Heading/Heading.js +1 -1
- package/lib/ui-kit/Heading/Heading.js.map +1 -1
- package/lib/ui-kit/Heading/Heading.mobile.js +1 -1
- package/lib/ui-kit/Heading/Heading.mobile.js.map +1 -1
- package/lib/ui-kit/List/ListItem.js +2 -2
- package/lib/ui-kit/List/ListItem.js.map +1 -1
- package/lib/ui-kit/SwipeListControl/SwipeListControlDots.js +1 -1
- package/lib/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
- package/lib/ui-kit/SwipeListControl/SwipeListControlItem.js +1 -1
- package/lib/ui-kit/SwipeListControl/SwipeListControlItem.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +73 -59
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/dist/components/BaseTile/BaseTile.js +1 -1
- package/mobile/dist/components/BaseTile/BaseTile.js.map +1 -1
- package/mobile/dist/components/Blocks.d.ts +1 -1
- package/mobile/dist/components/Blocks.js +2 -2
- package/mobile/dist/components/Blocks.js.map +1 -1
- package/mobile/dist/components/ContentPage/ContentPageHead.js +13 -4
- package/mobile/dist/components/ContentPage/ContentPageHead.js.map +1 -1
- package/mobile/dist/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
- package/mobile/dist/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
- package/mobile/dist/components/Gallery/GalleryCardInner.js +15 -5
- package/mobile/dist/components/Gallery/GalleryCardInner.js.map +1 -1
- package/mobile/dist/components/Header/Header.js +1 -1
- package/mobile/dist/components/Header/Header.js.map +1 -1
- package/mobile/dist/components/Header/HeaderBurger.js +1 -1
- package/mobile/dist/components/Header/HeaderBurger.js.map +1 -1
- package/mobile/dist/components/Header/HeaderTop.js +1 -1
- package/mobile/dist/components/Header/HeaderTop.js.map +1 -1
- package/mobile/dist/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/mobile/dist/components/LinkDocs/LinkDocsListItem.js.map +1 -1
- package/mobile/dist/components/ProductBlock/ProductBlockInner.js +4 -1
- package/mobile/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/mobile/dist/components/ProductBlock/renderBenefit.js +1 -1
- package/mobile/dist/components/ProductBlock/renderBenefit.js.map +1 -1
- package/mobile/dist/components/ProductGallery/ProductGallery.js +3 -14
- package/mobile/dist/components/ProductGallery/ProductGallery.js.map +1 -1
- package/mobile/dist/components/ProductGallery/ProductGalleryBlock.js +1 -1
- package/mobile/dist/components/StepsBlock/StepsBlock.js +2 -2
- package/mobile/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/mobile/dist/components/Tile/Tile.js +5 -1
- package/mobile/dist/components/Tile/Tile.js.map +1 -1
- package/mobile/dist/types.d.ts +10 -5
- package/mobile/dist/ui-kit/BlockItem/BlockItem.js +3 -3
- package/mobile/dist/ui-kit/BlockItem/BlockItem.js.map +1 -1
- package/mobile/dist/ui-kit/Description/Description.js +1 -1
- package/mobile/dist/ui-kit/Heading/Heading.js +1 -1
- package/mobile/dist/ui-kit/Heading/Heading.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/dist/ui-kit/SwipeListControl/SwipeListControlDots.js +1 -1
- package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
- package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlItem.js +1 -1
- package/mobile/dist/ui-kit/SwipeListControl/SwipeListControlItem.js.map +1 -1
- package/mobile/lib/components/BaseTile/BaseTile.js +1 -1
- package/mobile/lib/components/BaseTile/BaseTile.js.map +1 -1
- package/mobile/lib/components/Blocks.d.ts +1 -1
- package/mobile/lib/components/Blocks.js +2 -2
- package/mobile/lib/components/Blocks.js.map +1 -1
- package/mobile/lib/components/ContentPage/ContentPageHead.js +13 -4
- package/mobile/lib/components/ContentPage/ContentPageHead.js.map +1 -1
- package/mobile/lib/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
- package/mobile/lib/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
- package/mobile/lib/components/Gallery/GalleryCardInner.js +15 -5
- package/mobile/lib/components/Gallery/GalleryCardInner.js.map +1 -1
- package/mobile/lib/components/Header/Header.js +1 -1
- package/mobile/lib/components/Header/Header.js.map +1 -1
- package/mobile/lib/components/Header/HeaderBurger.js +1 -1
- package/mobile/lib/components/Header/HeaderBurger.js.map +1 -1
- package/mobile/lib/components/Header/HeaderTop.js +1 -1
- package/mobile/lib/components/Header/HeaderTop.js.map +1 -1
- package/mobile/lib/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/mobile/lib/components/LinkDocs/LinkDocsListItem.js.map +1 -1
- package/mobile/lib/components/ProductBlock/ProductBlockInner.js +4 -1
- package/mobile/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/mobile/lib/components/ProductBlock/renderBenefit.js +1 -1
- package/mobile/lib/components/ProductBlock/renderBenefit.js.map +1 -1
- package/mobile/lib/components/ProductGallery/ProductGallery.js +4 -15
- package/mobile/lib/components/ProductGallery/ProductGallery.js.map +1 -1
- package/mobile/lib/components/ProductGallery/ProductGalleryBlock.js +1 -1
- package/mobile/lib/components/StepsBlock/StepsBlock.js +2 -2
- package/mobile/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/mobile/lib/components/Tile/Tile.js +5 -1
- package/mobile/lib/components/Tile/Tile.js.map +1 -1
- package/mobile/lib/types.d.ts +10 -5
- package/mobile/lib/ui-kit/BlockItem/BlockItem.js +3 -3
- package/mobile/lib/ui-kit/BlockItem/BlockItem.js.map +1 -1
- package/mobile/lib/ui-kit/Description/Description.js +1 -1
- package/mobile/lib/ui-kit/Heading/Heading.js +1 -1
- package/mobile/lib/ui-kit/Heading/Heading.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/lib/ui-kit/SwipeListControl/SwipeListControlDots.js +1 -1
- package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlDots.js.map +1 -1
- package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlItem.js +1 -1
- package/mobile/lib/ui-kit/SwipeListControl/SwipeListControlItem.js.map +1 -1
- package/mobile/src/components/BaseTile/BaseTile.tsx +2 -2
- package/mobile/src/components/Blocks.ts +2 -2
- package/mobile/src/components/ContentPage/ContentPage.page.json +17 -4
- package/mobile/src/components/ContentPage/ContentPageHead.tsx +22 -6
- package/mobile/src/components/ExchangeRateTile/ExchangeRateTile.tsx +1 -1
- package/mobile/src/components/Gallery/GalleryCardInner.tsx +23 -15
- package/mobile/src/components/Header/Header.tsx +1 -1
- package/mobile/src/components/Header/HeaderBurger.tsx +2 -2
- package/mobile/src/components/Header/HeaderTop.tsx +6 -2
- package/mobile/src/components/LinkDocs/LinkDocsListItem.tsx +1 -1
- package/mobile/src/components/ProductBlock/ProductBlock.example.json +2 -1
- package/mobile/src/components/ProductBlock/ProductBlockInner.tsx +17 -11
- package/mobile/src/components/ProductBlock/renderBenefit.tsx +2 -2
- package/mobile/src/components/ProductGallery/ProductGallery.tsx +12 -49
- package/mobile/src/components/ProductGallery/ProductGalleryBlock.tsx +1 -1
- package/mobile/src/components/StepsBlock/StepsBlock.tsx +2 -2
- package/mobile/src/components/Tile/Tile.tsx +7 -4
- package/mobile/src/types.ts +10 -5
- package/mobile/src/ui-kit/BlockItem/BlockItem.tsx +4 -4
- package/mobile/src/ui-kit/Description/Description.tsx +1 -1
- package/mobile/src/ui-kit/Heading/Heading.tsx +1 -1
- package/mobile/src/ui-kit/List/ListItem.tsx +3 -3
- package/mobile/src/ui-kit/SwipeListControl/SwipeListControlDots.tsx +1 -1
- package/mobile/src/ui-kit/SwipeListControl/SwipeListControlItem.tsx +5 -1
- package/package.json +1 -1
- package/src/components/BaseTile/BaseTile.tsx +2 -2
- package/src/components/Blocks.mobile.ts +2 -2
- package/src/components/Blocks.ts +0 -2
- package/src/components/ComparisonTable/ComparisonTable.fixture.tsx +0 -1
- package/src/components/ContentPage/ContentPage.page.json +17 -4
- package/src/components/ContentPage/ContentPageHead.tsx +22 -6
- package/src/components/ExchangeRateTile/ExchangeRateTile.tsx +1 -1
- package/src/components/Gallery/Gallery.fixture.mobile.tsx +1 -1
- package/src/components/Gallery/GalleryCardInner.tsx +23 -15
- package/src/components/Header/Header.mobile.tsx +1 -1
- package/src/components/Header/HeaderBurger.tsx +2 -2
- package/src/components/Header/HeaderTop.tsx +6 -2
- package/src/components/LinkDocs/LinkDocsListItem.mobile.tsx +1 -1
- package/src/components/LinkDocs/LinkDocsListItem.tsx +1 -1
- package/src/components/ProductBlock/ProductBlock.example.json +2 -1
- package/src/components/ProductBlock/ProductBlock.fixture.mobile.tsx +2 -2
- package/src/components/ProductBlock/ProductBlockInner.mobile.tsx +17 -11
- package/src/components/ProductBlock/ProductBlockInner.tsx +2 -2
- package/src/components/ProductBlock/renderBenefit.mobile.tsx +2 -2
- package/src/components/ProductGallery/ProductGallery.fixture.mobile.tsx +98 -0
- package/src/components/ProductGallery/ProductGallery.fixture.tsx +2 -2
- package/src/components/ProductGallery/ProductGallery.mobile.tsx +12 -49
- package/src/components/ProductGallery/ProductGalleryBlock.mobile.tsx +1 -1
- package/src/components/StepsBlock/StepsBlock.mobile.tsx +2 -2
- package/src/components/Tile/Tile.tsx +7 -4
- package/src/types.ts +10 -5
- package/src/ui-kit/BlockItem/BlockItem.tsx +4 -4
- package/src/ui-kit/Description/Description.tsx +1 -1
- package/src/ui-kit/Heading/Heading.fixture.mobile.tsx +0 -1
- package/src/ui-kit/Heading/Heading.mobile.tsx +1 -1
- package/src/ui-kit/Heading/Heading.tsx +3 -1
- package/src/ui-kit/List/ListItem.tsx +3 -3
- package/src/ui-kit/SwipeListControl/SwipeListControlDots.tsx +1 -1
- package/src/ui-kit/SwipeListControl/SwipeListControlItem.tsx +5 -1
|
@@ -16,14 +16,14 @@ export function renderBenefit(benefit: Benefit, i: number, version: string) {
|
|
|
16
16
|
<div key={String(i)} className="flex gap-3 items-center mb-2.5 last:mb-0">
|
|
17
17
|
{benefit.icon && (
|
|
18
18
|
<Icon
|
|
19
|
-
className="w-
|
|
19
|
+
className="w-6 h-6 rounded-full box-border"
|
|
20
20
|
name={benefit.icon}
|
|
21
21
|
width="24"
|
|
22
22
|
height="24"
|
|
23
23
|
asSVG
|
|
24
24
|
/>
|
|
25
25
|
)}
|
|
26
|
-
<div className={`font-medium text-m-
|
|
26
|
+
<div className={`font-medium text-m-title-xs m-0 ${benefitTitleStyleMap[version]}`}>
|
|
27
27
|
{benefit.label}
|
|
28
28
|
</div>
|
|
29
29
|
{benefit.description && (
|
|
@@ -26,6 +26,12 @@ const worker: Picture = {
|
|
|
26
26
|
width: 280,
|
|
27
27
|
height: 280,
|
|
28
28
|
},
|
|
29
|
+
sources: [
|
|
30
|
+
{
|
|
31
|
+
src: 'money-2.png 1x, money-2-2x.png 2x',
|
|
32
|
+
format: 'png',
|
|
33
|
+
},
|
|
34
|
+
],
|
|
29
35
|
};
|
|
30
36
|
|
|
31
37
|
const creditCard: Picture = {
|
|
@@ -39,6 +45,98 @@ const creditCard: Picture = {
|
|
|
39
45
|
};
|
|
40
46
|
|
|
41
47
|
export default {
|
|
48
|
+
default: (
|
|
49
|
+
<div className="p-2">
|
|
50
|
+
<div className="container grid grid-cols-12">
|
|
51
|
+
<ProductGallery
|
|
52
|
+
className="col-span-12"
|
|
53
|
+
context={context}
|
|
54
|
+
slides={[
|
|
55
|
+
{
|
|
56
|
+
productBlock: {
|
|
57
|
+
title: 'Акция «Кредит на все, что хочется!»',
|
|
58
|
+
items: [
|
|
59
|
+
'Потребительский кредит по специальной процентной ставке',
|
|
60
|
+
'Получите деньги без залога и поручительства',
|
|
61
|
+
'Кредитный лимит до 5 млн рублей',
|
|
62
|
+
],
|
|
63
|
+
buttons: [
|
|
64
|
+
{
|
|
65
|
+
href: 'https://rshb.ru',
|
|
66
|
+
text: 'Подробнее',
|
|
67
|
+
target: '_blank',
|
|
68
|
+
version: 'primary',
|
|
69
|
+
},
|
|
70
|
+
],
|
|
71
|
+
image: moneyImage,
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
productBlock: {
|
|
76
|
+
title: 'Ставка от 12,5% годовых на срок до 3 лет!',
|
|
77
|
+
items: [
|
|
78
|
+
'Потребительский кредит по специальной процентной ставке',
|
|
79
|
+
'Получите деньги без залога и поручительства',
|
|
80
|
+
'Кредитный лимит до 5 млн рублей',
|
|
81
|
+
],
|
|
82
|
+
buttons: [
|
|
83
|
+
{
|
|
84
|
+
href: 'https://rshb.ru',
|
|
85
|
+
text: 'Подробнее',
|
|
86
|
+
target: '_blank',
|
|
87
|
+
version: 'primary',
|
|
88
|
+
},
|
|
89
|
+
],
|
|
90
|
+
image: worker,
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
nav: {
|
|
95
|
+
title: 'Выгодно покупать',
|
|
96
|
+
desc: 'Дополнительные бонусные баллы за покупки',
|
|
97
|
+
},
|
|
98
|
+
productBlock: {
|
|
99
|
+
title: 'Дополнительные бонусные баллы за покупки!',
|
|
100
|
+
items: [
|
|
101
|
+
'Потребительский кредит по специальной процентной ставке',
|
|
102
|
+
'Получите деньги без залога и поручительства',
|
|
103
|
+
'Кредитный лимит до 5 млн рублей',
|
|
104
|
+
],
|
|
105
|
+
buttons: [
|
|
106
|
+
{
|
|
107
|
+
href: 'https://rshb.ru',
|
|
108
|
+
text: 'Подробнее',
|
|
109
|
+
target: '_blank',
|
|
110
|
+
version: 'primary',
|
|
111
|
+
},
|
|
112
|
+
],
|
|
113
|
+
image: creditCard,
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
productBlock: {
|
|
118
|
+
title: 'Карты Unionpay',
|
|
119
|
+
items: [
|
|
120
|
+
'Потребительский кредит по специальной процентной ставке',
|
|
121
|
+
'Получите деньги без залога и поручительства',
|
|
122
|
+
'Кредитный лимит до 5 млн рублей',
|
|
123
|
+
],
|
|
124
|
+
buttons: [
|
|
125
|
+
{
|
|
126
|
+
href: 'https://rshb.ru',
|
|
127
|
+
text: 'Подробнее',
|
|
128
|
+
target: '_blank',
|
|
129
|
+
version: 'primary',
|
|
130
|
+
},
|
|
131
|
+
],
|
|
132
|
+
image: creditCard,
|
|
133
|
+
},
|
|
134
|
+
},
|
|
135
|
+
]}
|
|
136
|
+
/>
|
|
137
|
+
</div>
|
|
138
|
+
</div>
|
|
139
|
+
),
|
|
42
140
|
primary: (
|
|
43
141
|
<div className="p-2">
|
|
44
142
|
<div className="container grid grid-cols-12">
|
|
@@ -1,58 +1,21 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import type { UniBlockProps } from '../../types';
|
|
3
|
-
import { ProductGalleryBlock } from './ProductGalleryBlock';
|
|
4
3
|
import type { ProductGalleryContent } from './ProductGalleryContent';
|
|
4
|
+
import { SwipeListControl } from '../../ui-kit/SwipeListControl/SwipeListControl';
|
|
5
|
+
import { ProductGalleryBlock } from './ProductGalleryBlock';
|
|
5
6
|
|
|
6
7
|
export interface ProductGalleryProps extends ProductGalleryContent, UniBlockProps {}
|
|
7
8
|
|
|
8
|
-
export const ProductGallery = JSX<ProductGalleryProps>(
|
|
9
|
-
|
|
10
|
-
const galleryBlocks = slides.map((s) => s.productBlock);
|
|
11
|
-
const [activeSlideIndex, setActiveSlideIndex] = context.useState(0);
|
|
12
|
-
|
|
13
|
-
return (
|
|
14
|
-
<section className={`font-sans bg-white overflow-hidden w-100 ${className || ''}`}>
|
|
15
|
-
<div
|
|
16
|
-
className={`flex duration-1000`}
|
|
17
|
-
style={{ transform: `translateX(-${activeSlideIndex}00%)` }}
|
|
18
|
-
role="list"
|
|
19
|
-
>
|
|
20
|
-
{galleryBlocks.map((block, i) => (
|
|
21
|
-
<ProductGalleryBlock key={String(i)} block={block} context={context} />
|
|
22
|
-
))}
|
|
23
|
-
</div>
|
|
24
|
-
|
|
25
|
-
<div className="flex px-4 py-6">
|
|
26
|
-
{slides.map((_, i) =>
|
|
27
|
-
renderNavButton({
|
|
28
|
-
slide: _.productBlock,
|
|
29
|
-
i,
|
|
30
|
-
activeSlideIndex,
|
|
31
|
-
onClick: () => setActiveSlideIndex(i),
|
|
32
|
-
duration,
|
|
33
|
-
}),
|
|
34
|
-
)}
|
|
35
|
-
</div>
|
|
36
|
-
</section>
|
|
37
|
-
);
|
|
38
|
-
},
|
|
39
|
-
);
|
|
9
|
+
export const ProductGallery = JSX<ProductGalleryProps>(({ className, context, slides = [] }) => {
|
|
10
|
+
const galleryBlocks = slides.map((s) => s.productBlock);
|
|
40
11
|
|
|
41
|
-
function renderNavButton({ slide, i, activeSlideIndex, onClick, duration }) {
|
|
42
|
-
const isActiveBtn = i === activeSlideIndex;
|
|
43
|
-
const progressBarClassName = isActiveBtn ? 'animate-slide bg-primary-main' : 'bg-main-divider';
|
|
44
12
|
return (
|
|
45
|
-
<
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
>
|
|
52
|
-
<div
|
|
53
|
-
className={`absolute bottom-0 left-0 w-full h-[3px] ${progressBarClassName}`}
|
|
54
|
-
style={{ animationDuration: `${duration}s`, animationFillMode: 'forwards' }}
|
|
55
|
-
></div>
|
|
56
|
-
</button>
|
|
13
|
+
<section className={`font-sans bg-white overflow-hidden w-100 pb-6 ${className || ''}`}>
|
|
14
|
+
<SwipeListControl context={context}>
|
|
15
|
+
{galleryBlocks.map((block, i) => (
|
|
16
|
+
<ProductGalleryBlock key={String(i)} block={block} context={context} />
|
|
17
|
+
))}
|
|
18
|
+
</SwipeListControl>
|
|
19
|
+
</section>
|
|
57
20
|
);
|
|
58
|
-
}
|
|
21
|
+
});
|
|
@@ -12,7 +12,7 @@ export interface ProductGalleryBlockProps extends UniBlockProps {
|
|
|
12
12
|
export const ProductGalleryBlock = JSX<ProductGalleryBlockProps>(
|
|
13
13
|
({ block, headingType, context }) => {
|
|
14
14
|
return (
|
|
15
|
-
<section className="flex grow-0 shrink-0 basis-full px-4
|
|
15
|
+
<section className="flex grow-0 shrink-0 basis-full px-4 pt-6" role="listitem">
|
|
16
16
|
<div className="flex grow">
|
|
17
17
|
<ProductBlockInner context={context} headingType={headingType || 'h2'} {...block} />
|
|
18
18
|
</div>
|
|
@@ -49,7 +49,7 @@ const renderStepTitle = (params: RenderStepTitleParams) => {
|
|
|
49
49
|
{renderIconArea(step, size, i)}
|
|
50
50
|
{!isLastStep && <div className={`min-h-8 h-full w-[2px] bg-secondary-light ${margin}`} />}
|
|
51
51
|
</div>
|
|
52
|
-
<div className="flex flex-col justify-
|
|
52
|
+
<div className="flex flex-col justify-start relative">
|
|
53
53
|
{step.label && (
|
|
54
54
|
<div className="font-medium text-m-title-xs m-0 text-left">{step.label}</div>
|
|
55
55
|
)}
|
|
@@ -82,7 +82,7 @@ const renderIconArea = (step: Step, size: SizeVersion, i: number) => {
|
|
|
82
82
|
className={`${iconAreaSize} bg-secondary-light rounded-full z-10 mr-3 flex justify-center content-center`}
|
|
83
83
|
>
|
|
84
84
|
<span className={`font-medium text-secondary-text self-center ${iconTextSize}`}>
|
|
85
|
-
{(step.icon && <Icon name={step.icon} width={iconSize} height={iconSize}
|
|
85
|
+
{(step.icon && <Icon name={step.icon} width={iconSize} height={iconSize} />) || i + 1}
|
|
86
86
|
</span>
|
|
87
87
|
</div>
|
|
88
88
|
);
|
|
@@ -49,9 +49,8 @@ export const Tile = JSX<TileProps>((props) => {
|
|
|
49
49
|
<Heading
|
|
50
50
|
headingType={getTileHeadingType(className)}
|
|
51
51
|
title={title}
|
|
52
|
-
className={`whitespace-pre-wrap max-w-[600px] ${
|
|
53
|
-
|
|
54
|
-
}`}
|
|
52
|
+
className={`whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}
|
|
53
|
+
${version === 'primary' ? 'text-primary-text' : ''}`}
|
|
55
54
|
/>
|
|
56
55
|
)
|
|
57
56
|
}
|
|
@@ -64,8 +63,12 @@ export const Tile = JSX<TileProps>((props) => {
|
|
|
64
63
|
>
|
|
65
64
|
{description && <Description className="mt-4 max-w-[600px]" description={description} />}
|
|
66
65
|
{children}
|
|
67
|
-
{items
|
|
66
|
+
{renderList(items, version)}
|
|
68
67
|
</BaseTile>
|
|
69
68
|
</section>
|
|
70
69
|
);
|
|
71
70
|
});
|
|
71
|
+
|
|
72
|
+
function renderList(items, version) {
|
|
73
|
+
return items?.length ? <List items={items} version={version} /> : null;
|
|
74
|
+
}
|
package/src/types.ts
CHANGED
|
@@ -26,12 +26,17 @@ export interface SlotsMap {
|
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
export interface ContentPageMeta {
|
|
29
|
-
title
|
|
30
|
-
slug
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
29
|
+
title?: string;
|
|
30
|
+
slug?: string;
|
|
31
|
+
main?: {
|
|
32
|
+
description?: string;
|
|
33
|
+
keywords?: string[];
|
|
34
|
+
canonical?: string;
|
|
35
|
+
robots?: string[];
|
|
36
|
+
};
|
|
34
37
|
og?: Record<string, string>;
|
|
38
|
+
twitter?: Record<string, string>;
|
|
39
|
+
jsonLd?: string;
|
|
35
40
|
}
|
|
36
41
|
|
|
37
42
|
export interface ContentPageDef extends ContentPageMeta {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import type { BlockItemProps, BlockItemVersion } from './BlockItemProps';
|
|
3
3
|
|
|
4
|
-
const LIST_STYLE_CLASSES = 'rounded-full inline-block mr-3';
|
|
4
|
+
const LIST_STYLE_CLASSES = 'rounded-full inline-block mr-3 mt-2';
|
|
5
5
|
|
|
6
6
|
const TEXT_STYLE_MAP: Record<BlockItemVersion, string> = {
|
|
7
|
-
primary: 'text-
|
|
7
|
+
primary: 'text-secondary-text',
|
|
8
8
|
secondary: 'text-white',
|
|
9
9
|
gray: 'text-secondary-text',
|
|
10
10
|
};
|
|
@@ -18,8 +18,8 @@ const LIST_STYLE_MAP: Record<BlockItemVersion, string> = {
|
|
|
18
18
|
export const BlockItem = JSX<BlockItemProps>(
|
|
19
19
|
({ className = '', isDotted = true, text, children, version = 'primary' }) => {
|
|
20
20
|
return (
|
|
21
|
-
<div className={`font-sans flex items-
|
|
22
|
-
{isDotted && <div className={getListStyle(version)} />}
|
|
21
|
+
<div className={`font-sans flex items-start ${className}`} role="listitem">
|
|
22
|
+
{isDotted && <div className={getListStyle(version)} />}!!!!!
|
|
23
23
|
<span className={TEXT_STYLE_MAP[version]}>{text || children}</span>
|
|
24
24
|
</div>
|
|
25
25
|
);
|
|
@@ -8,5 +8,5 @@ export interface DescriptionProps extends DescriptionContent {
|
|
|
8
8
|
export const Description = JSX<DescriptionProps>((props) => {
|
|
9
9
|
const { className, description } = props;
|
|
10
10
|
|
|
11
|
-
return <div className={`font-normal text-
|
|
11
|
+
return <div className={`font-normal text-m-md ${className || ''}`}>{description}</div>;
|
|
12
12
|
});
|
|
@@ -22,7 +22,7 @@ export const Heading = JSX<HeadingProps>((props) => {
|
|
|
22
22
|
const Tag = headingType;
|
|
23
23
|
|
|
24
24
|
return (
|
|
25
|
-
<Tag className={`font-sans font-medium ${HeadingClass[headingType]} ${className || ''}`}>
|
|
25
|
+
<Tag className={`font-sans font-medium m-0 ${HeadingClass[headingType]} ${className || ''}`}>
|
|
26
26
|
{title}
|
|
27
27
|
</Tag>
|
|
28
28
|
);
|
|
@@ -22,7 +22,9 @@ export const Heading = JSX<HeadingProps>((props) => {
|
|
|
22
22
|
const Tag = headingType;
|
|
23
23
|
|
|
24
24
|
return (
|
|
25
|
-
<Tag
|
|
25
|
+
<Tag
|
|
26
|
+
className={`font-sans font-medium m-0 ${HEADING_STYLE_MAP[headingType]} ${className || ''}`}
|
|
27
|
+
>
|
|
26
28
|
{title}
|
|
27
29
|
</Tag>
|
|
28
30
|
);
|
|
@@ -11,7 +11,7 @@ export interface ListItemProps {
|
|
|
11
11
|
isDotted?: boolean;
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
const LIST_STYLE_CLASSES = 'rounded-full inline-block mr-3';
|
|
14
|
+
const LIST_STYLE_CLASSES = 'rounded-full inline-block mr-3 mt-2';
|
|
15
15
|
|
|
16
16
|
const TEXT_STYLE_MAP: Record<ListItemVersion, string> = {
|
|
17
17
|
primary: 'text-primary-text',
|
|
@@ -28,9 +28,9 @@ const LIST_STYLE_MAP: Record<ListItemVersion, string> = {
|
|
|
28
28
|
export const ListItem = JSX<ListItemProps>(
|
|
29
29
|
({ className = '', isDotted = true, children, version = 'primary' }) => {
|
|
30
30
|
return (
|
|
31
|
-
<div className={`font-sans flex items-
|
|
31
|
+
<div className={`font-sans flex items-start ${className}`} role="listitem">
|
|
32
32
|
{isDotted && <div className={getListStyle(version)} />}
|
|
33
|
-
<span className={TEXT_STYLE_MAP[version]}>{children}</span>
|
|
33
|
+
<span className={`text-m-md ${TEXT_STYLE_MAP[version]}`}>{children}</span>
|
|
34
34
|
</div>
|
|
35
35
|
);
|
|
36
36
|
},
|
|
@@ -15,7 +15,7 @@ export interface SwipeListControlDotsProps {
|
|
|
15
15
|
export const SwipeListControlDots = JSX<SwipeListControlDotsProps>(
|
|
16
16
|
({ children, activeIndex, indexFraction, showDots }) => {
|
|
17
17
|
return showDots && children?.length ? (
|
|
18
|
-
<div className="flex gap-2 mx-auto mt-
|
|
18
|
+
<div className="flex gap-2 mx-auto mt-5 w-fit">
|
|
19
19
|
{children?.map((_, idx) => (
|
|
20
20
|
<div
|
|
21
21
|
key={String(idx)}
|
|
@@ -12,7 +12,11 @@ export interface SwipeListControlItemProps {
|
|
|
12
12
|
export const SwipeListControlItem = JSX<SwipeListControlItemProps>(
|
|
13
13
|
({ className = '', children, ...rest }) => {
|
|
14
14
|
return (
|
|
15
|
-
<div
|
|
15
|
+
<div
|
|
16
|
+
className={`snap-center snap-always min-w-full box-border ${className}`}
|
|
17
|
+
role="listitem"
|
|
18
|
+
{...rest}
|
|
19
|
+
>
|
|
16
20
|
{children}
|
|
17
21
|
</div>
|
|
18
22
|
);
|