@redneckz/wildless-cms-uni-blocks 0.14.311 → 0.14.313

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 (80) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +12 -12
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/bundle/components/CarouselCard/constants.d.ts +0 -1
  5. package/bundle/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +2 -1
  6. package/bundle/ui-kit/RichText/RichTextProps.d.ts +1 -1
  7. package/dist/components/CarouselCard/constants.d.ts +0 -1
  8. package/dist/components/CarouselCard/constants.js +1 -5
  9. package/dist/components/CarouselCard/constants.js.map +1 -1
  10. package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +5 -4
  11. package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  12. package/dist/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +2 -1
  13. package/dist/components/GrantSupport/GrantSupport.js +2 -1
  14. package/dist/components/GrantSupport/GrantSupport.js.map +1 -1
  15. package/dist/hooks/useAspects/aspects/getAspectsWithInclude.js +1 -1
  16. package/dist/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -1
  17. package/dist/ui-kit/BaseProductTile/BaseProductTile.js +1 -1
  18. package/dist/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  19. package/dist/ui-kit/RichText/RichTextProps.d.ts +1 -1
  20. package/lib/common.css +1 -1
  21. package/lib/components/CarouselCard/constants.d.ts +0 -1
  22. package/lib/components/CarouselCard/constants.js +0 -4
  23. package/lib/components/CarouselCard/constants.js.map +1 -1
  24. package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +5 -4
  25. package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  26. package/lib/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +2 -1
  27. package/lib/components/GrantSupport/GrantSupport.js +2 -1
  28. package/lib/components/GrantSupport/GrantSupport.js.map +1 -1
  29. package/lib/hooks/useAspects/aspects/getAspectsWithInclude.js +1 -1
  30. package/lib/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -1
  31. package/lib/ui-kit/BaseProductTile/BaseProductTile.js +1 -1
  32. package/lib/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  33. package/lib/ui-kit/RichText/RichTextProps.d.ts +1 -1
  34. package/mobile/bundle/bundle.umd.js +7 -7
  35. package/mobile/bundle/bundle.umd.min.js +1 -1
  36. package/mobile/bundle/components/CarouselCard/constants.d.ts +0 -1
  37. package/mobile/bundle/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +2 -1
  38. package/mobile/bundle/ui-kit/RichText/RichTextProps.d.ts +1 -1
  39. package/mobile/dist/components/CarouselCard/constants.d.ts +0 -1
  40. package/mobile/dist/components/CarouselCard/constants.js +1 -5
  41. package/mobile/dist/components/CarouselCard/constants.js.map +1 -1
  42. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +5 -4
  43. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  44. package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +2 -1
  45. package/mobile/dist/components/GrantSupport/GrantSupport.js +2 -1
  46. package/mobile/dist/components/GrantSupport/GrantSupport.js.map +1 -1
  47. package/mobile/dist/hooks/useAspects/aspects/getAspectsWithInclude.js +1 -1
  48. package/mobile/dist/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -1
  49. package/mobile/dist/ui-kit/BaseProductTile/BaseProductTile.js +1 -1
  50. package/mobile/dist/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  51. package/mobile/dist/ui-kit/RichText/RichTextProps.d.ts +1 -1
  52. package/mobile/lib/common.css +1 -1
  53. package/mobile/lib/components/CarouselCard/constants.d.ts +0 -1
  54. package/mobile/lib/components/CarouselCard/constants.js +0 -4
  55. package/mobile/lib/components/CarouselCard/constants.js.map +1 -1
  56. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +5 -4
  57. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
  58. package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCardContent.d.ts +2 -1
  59. package/mobile/lib/components/GrantSupport/GrantSupport.js +2 -1
  60. package/mobile/lib/components/GrantSupport/GrantSupport.js.map +1 -1
  61. package/mobile/lib/hooks/useAspects/aspects/getAspectsWithInclude.js +1 -1
  62. package/mobile/lib/hooks/useAspects/aspects/getAspectsWithInclude.js.map +1 -1
  63. package/mobile/lib/ui-kit/BaseProductTile/BaseProductTile.js +1 -1
  64. package/mobile/lib/ui-kit/BaseProductTile/BaseProductTile.js.map +1 -1
  65. package/mobile/lib/ui-kit/RichText/RichTextProps.d.ts +1 -1
  66. package/mobile/src/components/CarouselCard/constants.ts +0 -5
  67. package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +7 -2
  68. package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCardContent.ts +3 -1
  69. package/mobile/src/components/GrantSupport/GrantSupport.tsx +2 -1
  70. package/mobile/src/hooks/useAspects/aspects/getAspectsWithInclude.tsx +1 -1
  71. package/mobile/src/ui-kit/BaseProductTile/BaseProductTile.tsx +5 -1
  72. package/mobile/src/ui-kit/RichText/RichTextProps.ts +1 -1
  73. package/package.json +2 -2
  74. package/src/components/CarouselCard/constants.ts +0 -5
  75. package/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +7 -2
  76. package/src/components/CarouselTariffsCard/CarouselTariffsCardContent.ts +3 -1
  77. package/src/components/GrantSupport/GrantSupport.tsx +2 -1
  78. package/src/hooks/useAspects/aspects/getAspectsWithInclude.tsx +1 -1
  79. package/src/ui-kit/BaseProductTile/BaseProductTile.tsx +5 -1
  80. package/src/ui-kit/RichText/RichTextProps.ts +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"BaseProductTile.js","sourceRoot":"","sources":["../../../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;AACJ,CAAC,CACF,CAAC;AAEF,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,GAAU,EAAE,cAAuB,EAAE,EAAE,CACtE,cAAc,CAAC,CAAC,CAAC,EAAE,UAAU,EAAE,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,GAAG,EAAE,CAAC;AAE5D,MAAM,UAAU,GAAG,CAAC,IAAc,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC,CAAC,KAAC,IAAI,IAAC,IAAI,EAAE,IAAI,GAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC"}
@@ -2,7 +2,7 @@ declare type HTML = string;
2
2
  /**
3
3
  * @title Стиль форматированного текста
4
4
  * @default "primary"
5
- * @enumNames ["Основсной", "Второстепенный"]
5
+ * @enumNames ["Основной", "Второстепенный"]
6
6
  */
7
7
  export declare type RichVersion = '' | 'secondary';
8
8
  export interface RichTextProps {
@@ -4,8 +4,3 @@ export const cardStyleMap: Record<SizeVersion, string> = {
4
4
  normal: 'min-w-full justify-center items-center m-2xl col-span-12',
5
5
  small: 'min-w-auto justify-center items-center m-4xl col-span-4',
6
6
  };
7
-
8
- export const cardWidthMap: Record<SizeVersion, string> = {
9
- normal: 'w-[1007px]',
10
- small: 'w-[350px]',
11
- };
@@ -1,6 +1,7 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import { useEffect, useState } from '@redneckz/uni-jsx/lib/hooks';
3
3
  import { defaultEventBus } from '../../EventBus/defaultEventBus';
4
+ import { type AspectsDef } from '../../model/AspectsProps';
4
5
  import { type Slot } from '../../model/ContentPageDef';
5
6
  import { type VNode } from '../../model/VNode';
6
7
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
@@ -11,6 +12,7 @@ import { Icon } from '../../ui-kit/Icon/Icon';
11
12
  import { Img } from '../../ui-kit/Img/Img';
12
13
  import { LinkButton } from '../../ui-kit/LinkButton/LinkButton';
13
14
  import { type UniBlockProps } from '../../UniBlock/UniBlockProps';
15
+ import { getAspectsAttributes } from '../../utils/dataAttributes';
14
16
  import { isIcon } from '../../utils/isIcon';
15
17
  import { style } from '../../utils/style';
16
18
  import { type CarouselTariffsCardContent } from './CarouselTariffsCardContent';
@@ -30,6 +32,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
30
32
  visibleCellsCount = 1,
31
33
  cardCells = [],
32
34
  options,
35
+ data,
33
36
  ...rest
34
37
  }) => {
35
38
  const cellsNode = cardCells.map(renderCardInfo);
@@ -70,7 +73,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
70
73
  </div>
71
74
  )}
72
75
  renderFoldButton={
73
- cardCells.length > 1 ? renderFoldButton(isVisible, options?.parent) : null
76
+ cardCells.length > 1 ? renderFoldButton(isVisible, options?.parent, data) : null
74
77
  }
75
78
  />
76
79
  ) : (
@@ -81,7 +84,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
81
84
  },
82
85
  );
83
86
 
84
- const renderFoldButton = (isUnfolded?: boolean, parent?: Slot) => (): VNode =>
87
+ const renderFoldButton = (isUnfolded?: boolean, parent?: Slot, data?: AspectsDef[]) => (): VNode =>
85
88
  (
86
89
  <button
87
90
  className="w-full cursor-pointer text-primary-main pt-lg flex justify-between items-center"
@@ -91,6 +94,8 @@ const renderFoldButton = (isUnfolded?: boolean, parent?: Slot) => (): VNode =>
91
94
  }
92
95
  }}
93
96
  type="button"
97
+ // eslint-disable-next-line react/jsx-props-no-spreading
98
+ {...(isUnfolded ? getAspectsAttributes(data) : {})}
94
99
  >
95
100
  <div>{isUnfolded ? 'Скрыть' : 'Подробнее о тарифе'}</div>
96
101
  <Icon
@@ -1,3 +1,4 @@
1
+ import { type AspectsProps } from '../../model/AspectsProps';
1
2
  import {
2
3
  type AlignProps,
3
4
  type HeadlineCommonProps,
@@ -17,7 +18,8 @@ export type TariffsCardCellProps = HeadlineCommonProps & {
17
18
  export type CarouselTariffsCardContent = UniBlockContent &
18
19
  TitleProps &
19
20
  IconProps &
20
- AlignProps & {
21
+ AlignProps &
22
+ AspectsProps & {
21
23
  /** @title Выделить карточку */
22
24
  isHighlighting?: boolean;
23
25
  /** @title Кнопка */
@@ -1,4 +1,5 @@
1
1
  import { useState } from '@redneckz/uni-jsx/lib/hooks';
2
+ import { getAspectsWithInclude } from '../../hooks/useAspects/aspects/getAspectsWithInclude';
2
3
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
3
4
  import { Heading } from '../../ui-kit/Heading/Heading';
4
5
  import { getRegularButtonClasses } from '../../ui-kit/LinkButton/getRegularButtonClasses';
@@ -43,7 +44,7 @@ export const GrantSupport = UniBlock<GrantSupportProps>(
43
44
  href={regionHref}
44
45
  target="_blank"
45
46
  className={style('p-m w-full @xl:w-auto', buttonStyle)}
46
- data={data}
47
+ data={getAspectsWithInclude(data, region?.key)}
47
48
  >
48
49
  {buttonText}
49
50
  </LinkButton>
@@ -4,5 +4,5 @@ import { type AspectsAttribute } from '../useAspects';
4
4
  export const getAspectsWithInclude = (data?: AspectsDef[], include?: string): AspectsDef[] =>
5
5
  data?.map(({ aspectName, params }: AspectsAttribute) => ({
6
6
  aspectName,
7
- params: aspectName === 'mindboxEvent' ? { ...params, eventValueText: include } : params,
7
+ params: aspectName === 'mindboxEvent' ? { ...params, eventJson: include } : params,
8
8
  })) as AspectsDef[];
@@ -94,7 +94,11 @@ export const BaseProductTile = JSX<BaseProductTileProps>(
94
94
  benefits={filteredBenefits}
95
95
  />
96
96
  ) : null}
97
- {__html ? <RichText __html={__html} /> : null}
97
+ {__html ? (
98
+ <div className="min-w-max @sm:min-w-fit">
99
+ <RichText __html={__html} />
100
+ </div>
101
+ ) : null}
98
102
  {items?.length ? (
99
103
  <List items={items} isDotted={isDotted} listItemSize={LIST_SIZE[headlineVersion]} />
100
104
  ) : null}
@@ -3,7 +3,7 @@ type HTML = string;
3
3
  /**
4
4
  * @title Стиль форматированного текста
5
5
  * @default "primary"
6
- * @enumNames ["Основсной", "Второстепенный"]
6
+ * @enumNames ["Основной", "Второстепенный"]
7
7
  */
8
8
  export type RichVersion = '' | 'secondary';
9
9
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redneckz/wildless-cms-uni-blocks",
3
- "version": "0.14.311",
3
+ "version": "0.14.313",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "author": "ЦК",
@@ -209,7 +209,7 @@
209
209
  "path": "lib/common.css"
210
210
  },
211
211
  {
212
- "limit": "65 kB",
212
+ "limit": "66 kB",
213
213
  "path": "bundle/bundle.umd.min.js"
214
214
  }
215
215
  ],
@@ -4,8 +4,3 @@ export const cardStyleMap: Record<SizeVersion, string> = {
4
4
  normal: 'min-w-full justify-center items-center m-2xl col-span-12',
5
5
  small: 'min-w-auto justify-center items-center m-4xl col-span-4',
6
6
  };
7
-
8
- export const cardWidthMap: Record<SizeVersion, string> = {
9
- normal: 'w-[1007px]',
10
- small: 'w-[350px]',
11
- };
@@ -1,6 +1,7 @@
1
1
  import { JSX } from '@redneckz/uni-jsx';
2
2
  import { useEffect, useState } from '@redneckz/uni-jsx/lib/hooks';
3
3
  import { defaultEventBus } from '../../EventBus/defaultEventBus';
4
+ import { type AspectsDef } from '../../model/AspectsProps';
4
5
  import { type Slot } from '../../model/ContentPageDef';
5
6
  import { type VNode } from '../../model/VNode';
6
7
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
@@ -11,6 +12,7 @@ import { Icon } from '../../ui-kit/Icon/Icon';
11
12
  import { Img } from '../../ui-kit/Img/Img';
12
13
  import { LinkButton } from '../../ui-kit/LinkButton/LinkButton';
13
14
  import { type UniBlockProps } from '../../UniBlock/UniBlockProps';
15
+ import { getAspectsAttributes } from '../../utils/dataAttributes';
14
16
  import { isIcon } from '../../utils/isIcon';
15
17
  import { style } from '../../utils/style';
16
18
  import { type CarouselTariffsCardContent } from './CarouselTariffsCardContent';
@@ -30,6 +32,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
30
32
  visibleCellsCount = 1,
31
33
  cardCells = [],
32
34
  options,
35
+ data,
33
36
  ...rest
34
37
  }) => {
35
38
  const cellsNode = cardCells.map(renderCardInfo);
@@ -70,7 +73,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
70
73
  </div>
71
74
  )}
72
75
  renderFoldButton={
73
- cardCells.length > 1 ? renderFoldButton(isVisible, options?.parent) : null
76
+ cardCells.length > 1 ? renderFoldButton(isVisible, options?.parent, data) : null
74
77
  }
75
78
  />
76
79
  ) : (
@@ -81,7 +84,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
81
84
  },
82
85
  );
83
86
 
84
- const renderFoldButton = (isUnfolded?: boolean, parent?: Slot) => (): VNode =>
87
+ const renderFoldButton = (isUnfolded?: boolean, parent?: Slot, data?: AspectsDef[]) => (): VNode =>
85
88
  (
86
89
  <button
87
90
  className="w-full cursor-pointer text-primary-main pt-lg flex justify-between items-center"
@@ -91,6 +94,8 @@ const renderFoldButton = (isUnfolded?: boolean, parent?: Slot) => (): VNode =>
91
94
  }
92
95
  }}
93
96
  type="button"
97
+ // eslint-disable-next-line react/jsx-props-no-spreading
98
+ {...(isUnfolded ? getAspectsAttributes(data) : {})}
94
99
  >
95
100
  <div>{isUnfolded ? 'Скрыть' : 'Подробнее о тарифе'}</div>
96
101
  <Icon
@@ -1,3 +1,4 @@
1
+ import { type AspectsProps } from '../../model/AspectsProps';
1
2
  import {
2
3
  type AlignProps,
3
4
  type HeadlineCommonProps,
@@ -17,7 +18,8 @@ export type TariffsCardCellProps = HeadlineCommonProps & {
17
18
  export type CarouselTariffsCardContent = UniBlockContent &
18
19
  TitleProps &
19
20
  IconProps &
20
- AlignProps & {
21
+ AlignProps &
22
+ AspectsProps & {
21
23
  /** @title Выделить карточку */
22
24
  isHighlighting?: boolean;
23
25
  /** @title Кнопка */
@@ -1,4 +1,5 @@
1
1
  import { useState } from '@redneckz/uni-jsx/lib/hooks';
2
+ import { getAspectsWithInclude } from '../../hooks/useAspects/aspects/getAspectsWithInclude';
2
3
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
3
4
  import { Heading } from '../../ui-kit/Heading/Heading';
4
5
  import { getRegularButtonClasses } from '../../ui-kit/LinkButton/getRegularButtonClasses';
@@ -43,7 +44,7 @@ export const GrantSupport = UniBlock<GrantSupportProps>(
43
44
  href={regionHref}
44
45
  target="_blank"
45
46
  className={style('p-m w-full @xl:w-auto', buttonStyle)}
46
- data={data}
47
+ data={getAspectsWithInclude(data, region?.key)}
47
48
  >
48
49
  {buttonText}
49
50
  </LinkButton>
@@ -4,5 +4,5 @@ import { type AspectsAttribute } from '../useAspects';
4
4
  export const getAspectsWithInclude = (data?: AspectsDef[], include?: string): AspectsDef[] =>
5
5
  data?.map(({ aspectName, params }: AspectsAttribute) => ({
6
6
  aspectName,
7
- params: aspectName === 'mindboxEvent' ? { ...params, eventValueText: include } : params,
7
+ params: aspectName === 'mindboxEvent' ? { ...params, eventJson: include } : params,
8
8
  })) as AspectsDef[];
@@ -94,7 +94,11 @@ export const BaseProductTile = JSX<BaseProductTileProps>(
94
94
  benefits={filteredBenefits}
95
95
  />
96
96
  ) : null}
97
- {__html ? <RichText __html={__html} /> : null}
97
+ {__html ? (
98
+ <div className="min-w-max @sm:min-w-fit">
99
+ <RichText __html={__html} />
100
+ </div>
101
+ ) : null}
98
102
  {items?.length ? (
99
103
  <List items={items} isDotted={isDotted} listItemSize={LIST_SIZE[headlineVersion]} />
100
104
  ) : null}
@@ -3,7 +3,7 @@ type HTML = string;
3
3
  /**
4
4
  * @title Стиль форматированного текста
5
5
  * @default "primary"
6
- * @enumNames ["Основсной", "Второстепенный"]
6
+ * @enumNames ["Основной", "Второстепенный"]
7
7
  */
8
8
  export type RichVersion = '' | 'secondary';
9
9