@redneckz/wildless-cms-uni-blocks 0.14.55 → 0.14.57

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.
Files changed (70) hide show
  1. package/bin/migration-scripts/0.14.56.js +33 -0
  2. package/bundle/bundle.umd.js +11 -8
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
  5. package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  6. package/dist/components/CarouselLinks/CarouselLinks.js +1 -1
  7. package/dist/components/CarouselLinks/CarouselLinks.js.map +1 -1
  8. package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -1
  9. package/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
  10. package/dist/components/Footer/Footer.mobile.js +1 -1
  11. package/dist/components/Footer/Footer.mobile.js.map +1 -1
  12. package/dist/components/RollupItem/RollupItem.js +3 -1
  13. package/dist/components/RollupItem/RollupItem.js.map +1 -1
  14. package/dist/ui-kit/BaseProductTile/BaseProductTile.js +4 -3
  15. package/dist/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  16. package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
  17. package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  18. package/lib/components/CarouselLinks/CarouselLinks.js +1 -1
  19. package/lib/components/CarouselLinks/CarouselLinks.js.map +1 -1
  20. package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -1
  21. package/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
  22. package/lib/components/Footer/Footer.mobile.js +1 -1
  23. package/lib/components/Footer/Footer.mobile.js.map +1 -1
  24. package/lib/components/RollupItem/RollupItem.js +3 -1
  25. package/lib/components/RollupItem/RollupItem.js.map +1 -1
  26. package/lib/ui-kit/BaseProductTile/BaseProductTile.js +4 -3
  27. package/lib/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  28. package/mobile/bundle/bundle.umd.js +12 -9
  29. package/mobile/bundle/bundle.umd.min.js +1 -1
  30. package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
  31. package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  32. package/mobile/dist/components/CarouselLinks/CarouselLinks.js +1 -1
  33. package/mobile/dist/components/CarouselLinks/CarouselLinks.js.map +1 -1
  34. package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -1
  35. package/mobile/dist/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
  36. package/mobile/dist/components/Footer/Footer.js +1 -1
  37. package/mobile/dist/components/Footer/Footer.js.map +1 -1
  38. package/mobile/dist/components/RollupItem/RollupItem.js +3 -1
  39. package/mobile/dist/components/RollupItem/RollupItem.js.map +1 -1
  40. package/mobile/dist/ui-kit/BaseProductTile/BaseProductTile.js +4 -3
  41. package/mobile/dist/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  42. package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +1 -1
  43. package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  44. package/mobile/lib/components/CarouselLinks/CarouselLinks.js +1 -1
  45. package/mobile/lib/components/CarouselLinks/CarouselLinks.js.map +1 -1
  46. package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js +1 -1
  47. package/mobile/lib/components/CarouselRecommendationCard/CarouselRecommendationCard.js.map +1 -1
  48. package/mobile/lib/components/Footer/Footer.js +1 -1
  49. package/mobile/lib/components/Footer/Footer.js.map +1 -1
  50. package/mobile/lib/components/RollupItem/RollupItem.js +3 -1
  51. package/mobile/lib/components/RollupItem/RollupItem.js.map +1 -1
  52. package/mobile/lib/ui-kit/BaseProductTile/BaseProductTile.js +4 -3
  53. package/mobile/lib/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  54. package/mobile/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +7 -9
  55. package/mobile/src/components/CarouselLinks/CarouselLinks.tsx +6 -8
  56. package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCard.tsx +7 -9
  57. package/mobile/src/components/Footer/Footer.tsx +6 -1
  58. package/mobile/src/components/RollupItem/RollupItem.tsx +3 -1
  59. package/mobile/src/ui-kit/BaseProductTile/BaseProductTile.tsx +10 -21
  60. package/package.json +1 -1
  61. package/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +7 -9
  62. package/src/components/CarouselLinks/CarouselLinks.tsx +6 -8
  63. package/src/components/CarouselRecommendationCard/CarouselRecommendationCard.tsx +7 -9
  64. package/src/components/Footer/Footer.mobile.tsx +6 -1
  65. package/src/components/RollupItem/RollupItem.fixture.mobile.tsx +7 -2
  66. package/src/components/RollupItem/RollupItem.fixture.tsx +1 -0
  67. package/src/components/RollupItem/RollupItem.tsx +3 -1
  68. package/src/components/VerticalLayout/VerticalLayout.fixture.mobile.tsx +4 -0
  69. package/src/components/VerticalLayout/VerticalLayout.fixture.tsx +3 -2
  70. package/src/ui-kit/BaseProductTile/BaseProductTile.tsx +10 -21
@@ -54,15 +54,13 @@ export const CarouselRecommendationCard = JSX<RecommendationCardProps>(
54
54
  defaultPadding="p-2xl"
55
55
  padding={padding}
56
56
  insetTitle={
57
- title ? (
58
- <Headline
59
- title={title}
60
- description={description}
61
- headlineVersion="XS"
62
- isEmbedded={true}
63
- align={align}
64
- />
65
- ) : null
57
+ <Headline
58
+ title={title}
59
+ description={description}
60
+ headlineVersion="XS"
61
+ isEmbedded={true}
62
+ align={align}
63
+ />
66
64
  }
67
65
  {...leftOrRightImage(isIcon(icon) ? <Img image={icon} /> : null, directionRight)}
68
66
  buttons={
@@ -35,7 +35,12 @@ export const Footer = JSX<FooterProps>(({ className, ...rest }) => {
35
35
  <BlockWrapper tag="footer" className={className} defaultPadding="p-4xl pb-24" {...rest}>
36
36
  <div className="mb-lg pb-xs border-b border-main-divider">
37
37
  {topItems?.map((item, i) => (
38
- <RollupItem key={String(i)} label={item?.text} labelIcon={item?.icon}>
38
+ <RollupItem
39
+ key={String(i)}
40
+ foldButtonVersion="accordion"
41
+ label={item?.text}
42
+ labelIcon={item?.icon}
43
+ >
39
44
  <LinkList items={item.items} basePath={appendSlash(item.href)} />
40
45
  </RollupItem>
41
46
  ))}
@@ -34,9 +34,13 @@ export default {
34
34
  labelIcon={labelIcon}
35
35
  labelIconBgVersion="primary"
36
36
  options={options}
37
- foldButtonVersion="default"
38
37
  />
39
- <RollupItem {...ROLLUP_ITEM.content} block={ROLLUP_ITEM} options={options} />
38
+ <RollupItem
39
+ foldButtonVersion="accordion"
40
+ {...ROLLUP_ITEM.content}
41
+ block={ROLLUP_ITEM}
42
+ options={options}
43
+ />
40
44
  </div>
41
45
  ),
42
46
  labelIcon: (
@@ -44,6 +48,7 @@ export default {
44
48
  <RollupItem
45
49
  block={ROLLUP_ITEM}
46
50
  isExpanded={true}
51
+ foldButtonVersion="accordion"
47
52
  label="RollupItem label 1"
48
53
  labelIcon={labelIcon}
49
54
  labelIconBgVersion="primary"
@@ -29,6 +29,7 @@ export default {
29
29
  accordion: (
30
30
  <RollupItem
31
31
  label="Rollup button 2"
32
+ foldButtonVersion="accordion"
32
33
  isExpanded={true}
33
34
  block={{
34
35
  type: 'RollupItem',
@@ -28,7 +28,9 @@ export const RollupItem: JSXBlock<RollupItemProps> = JSX<RollupItemProps>(
28
28
  label = 'Развернуть',
29
29
  labelIcon,
30
30
  labelIconBgVersion,
31
- foldButtonVersion = 'accordion',
31
+ foldButtonVersion = 'default',
32
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
33
+ version,
32
34
  ...rest
33
35
  }) => (
34
36
  <BlockWrapper
@@ -110,6 +110,7 @@ export default {
110
110
  type: 'RollupItem',
111
111
  content: {
112
112
  label: 'Rollup button 1',
113
+ foldButtonVersion: 'accordion',
113
114
  },
114
115
  blocks: [
115
116
  { type: 'TextBlock', content: TEXT_BLOCK },
@@ -120,6 +121,7 @@ export default {
120
121
  type: 'RollupItem',
121
122
  content: {
122
123
  label: 'Rollup button 2',
124
+ foldButtonVersion: 'accordion',
123
125
  isExpanded: true,
124
126
  },
125
127
  blocks: [{ type: 'LinkDocs', content: linkDocsExample }],
@@ -128,6 +130,7 @@ export default {
128
130
  type: 'RollupItem',
129
131
  content: {
130
132
  label: 'Rollup button 2',
133
+ foldButtonVersion: 'accordion',
131
134
  isExpanded: true,
132
135
  },
133
136
  blocks: [{ type: 'LinkDocs', content: linkDocsExample }],
@@ -138,6 +141,7 @@ export default {
138
141
  content: {
139
142
  label: 'Rollup button 3 RichText',
140
143
  labelIcon: { icon: 'BriefcaseIcon' },
144
+ foldButtonVersion: 'accordion',
141
145
  isExpanded: true,
142
146
  },
143
147
  blocks: [
@@ -150,7 +150,6 @@ export default {
150
150
  type: 'RollupItem',
151
151
  content: {
152
152
  label: 'Rollup button 1 with TEXT_BLOCK',
153
- foldButtonVersion: 'default',
154
153
  isFoldButtonOnTop: false,
155
154
  isExpanded: true,
156
155
  },
@@ -163,7 +162,6 @@ export default {
163
162
  type: 'RollupItem',
164
163
  content: {
165
164
  label: 'Rollup button 2 with TEXT_BLOCK',
166
- foldButtonVersion: 'default',
167
165
  isFoldButtonOnTop: false,
168
166
  isExpanded: true,
169
167
  },
@@ -191,6 +189,7 @@ export default {
191
189
  type: 'RollupItem',
192
190
  content: {
193
191
  label: 'Rollup button 1',
192
+ foldButtonVersion: 'accordion',
194
193
  },
195
194
  blocks: [
196
195
  { type: 'TextBlock', content: TEXT_BLOCK },
@@ -201,6 +200,7 @@ export default {
201
200
  type: 'RollupItem',
202
201
  content: {
203
202
  label: 'Rollup button 2',
203
+ foldButtonVersion: 'accordion',
204
204
  isExpanded: true,
205
205
  },
206
206
  blocks: [{ type: 'LinkDocs', content: linkDocsExample }],
@@ -209,6 +209,7 @@ export default {
209
209
  type: 'RollupItem',
210
210
  content: {
211
211
  label: 'Rollup button 3 RichText',
212
+ foldButtonVersion: 'accordion',
212
213
  isExpanded: true,
213
214
  },
214
215
  blocks: [
@@ -1,6 +1,5 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import { Headline } from '../../components/Headline/Headline';
3
- import { type HeadlineVersion } from '../../model/HeadlineType';
4
3
  import { type UniBlockProps } from '../../model/JSXBlock';
5
4
  import { type VNode } from '../../model/VNode';
6
5
  import { BaseTile } from '../BaseTile/BaseTile';
@@ -11,7 +10,6 @@ import { List } from '../List/List';
11
10
  import { PriceList } from '../PriceList/PriceList';
12
11
  import { RichText } from '../RichText/RichText';
13
12
  import { Tags } from '../Tags/Tags';
14
- import { type TextAlign } from '../Text/TextProps';
15
13
  import { type BaseProductTileContent } from './BaseProductTileContent';
16
14
 
17
15
  interface BaseProductTileProps extends UniBlockProps, BaseProductTileContent {
@@ -19,6 +17,7 @@ interface BaseProductTileProps extends UniBlockProps, BaseProductTileContent {
19
17
  }
20
18
 
21
19
  export const BaseProductTile = JSX<BaseProductTileProps>(
20
+ // eslint-disable-next-line max-lines-per-function
22
21
  ({
23
22
  className,
24
23
  padding,
@@ -50,7 +49,15 @@ export const BaseProductTile = JSX<BaseProductTileProps>(
50
49
  ...rest
51
50
  }) => {
52
51
  const img = image?.src ? <Img image={image} /> : null;
53
- const headline = renderHeadline({ title, description, headlineVersion, align });
52
+ const headline = (
53
+ <Headline
54
+ title={title}
55
+ description={description}
56
+ headlineVersion={headlineVersion}
57
+ align={align}
58
+ isEmbedded={true}
59
+ />
60
+ );
54
61
  const filteredBenefits = benefits?.filter(
55
62
  (_) => _?.type === 'rte' || 'label' in _ || 'description' in _,
56
63
  );
@@ -94,21 +101,3 @@ export const leftOrRightImage = (img: VNode, directionRight: boolean) =>
94
101
  directionRight ? { rightImage: img } : { leftImage: img };
95
102
 
96
103
  const renderTags = (tags: string[]) => (tags?.length ? <Tags tags={tags} /> : null);
97
-
98
- interface RenderHeadline {
99
- title?: string;
100
- description?: string;
101
- headlineVersion?: HeadlineVersion;
102
- align?: TextAlign;
103
- }
104
-
105
- const renderHeadline = ({ title, description, headlineVersion, align }: RenderHeadline) =>
106
- title || description ? (
107
- <Headline
108
- title={title}
109
- description={description}
110
- headlineVersion={headlineVersion}
111
- align={align}
112
- isEmbedded={true}
113
- />
114
- ) : null;