@redneckz/wildless-cms-uni-blocks 0.8.7 → 0.8.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.
Files changed (101) hide show
  1. package/bundle/blocks.schema.json +1 -1
  2. package/bundle/bundle.umd.js +4 -5
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/bundle/components/ProductTile/ProductTileContent.d.ts +4 -13
  5. package/bundle/components/StepsBlock/StepsBlockContent.d.ts +6 -4
  6. package/bundle/components/TextBlock/TextBlockContent.d.ts +3 -2
  7. package/bundle/model/DefaultListItemType.d.ts +4 -0
  8. package/bundle/model/RichTextItem.d.ts +8 -0
  9. package/bundle/ui-kit/BenefitItem/BenefitItemProps.d.ts +4 -13
  10. package/dist/components/ProductTile/ProductTile.js +1 -2
  11. package/dist/components/ProductTile/ProductTile.js.map +1 -1
  12. package/dist/components/ProductTile/ProductTileContent.d.ts +4 -13
  13. package/dist/components/StepsBlock/StepsBlockContent.d.ts +6 -4
  14. package/dist/components/TextBlock/TextBlock.js +3 -2
  15. package/dist/components/TextBlock/TextBlock.js.map +1 -1
  16. package/dist/components/TextBlock/TextBlockContent.d.ts +3 -2
  17. package/dist/model/DefaultListItemType.d.ts +4 -0
  18. package/dist/model/DefaultListItemType.js +2 -0
  19. package/dist/model/DefaultListItemType.js.map +1 -0
  20. package/dist/model/RichTextItem.d.ts +8 -0
  21. package/dist/model/RichTextItem.js +2 -0
  22. package/dist/model/RichTextItem.js.map +1 -0
  23. package/dist/ui-kit/BenefitItem/BenefitItemProps.d.ts +4 -13
  24. package/lib/components/ProductTile/ProductTile.js +1 -2
  25. package/lib/components/ProductTile/ProductTile.js.map +1 -1
  26. package/lib/components/ProductTile/ProductTileContent.d.ts +4 -13
  27. package/lib/components/StepsBlock/StepsBlockContent.d.ts +6 -4
  28. package/lib/components/TextBlock/TextBlock.js +3 -2
  29. package/lib/components/TextBlock/TextBlock.js.map +1 -1
  30. package/lib/components/TextBlock/TextBlockContent.d.ts +3 -2
  31. package/lib/model/DefaultListItemType.d.ts +4 -0
  32. package/lib/model/DefaultListItemType.js +2 -0
  33. package/lib/model/DefaultListItemType.js.map +1 -0
  34. package/lib/model/RichTextItem.d.ts +8 -0
  35. package/lib/model/RichTextItem.js +2 -0
  36. package/lib/model/RichTextItem.js.map +1 -0
  37. package/lib/ui-kit/BenefitItem/BenefitItemProps.d.ts +4 -13
  38. package/mobile/bundle/bundle.umd.js +1 -1
  39. package/mobile/bundle/bundle.umd.min.js +1 -1
  40. package/mobile/bundle/components/ProductTile/ProductTileContent.d.ts +4 -13
  41. package/mobile/bundle/components/StepsBlock/StepsBlockContent.d.ts +6 -4
  42. package/mobile/bundle/components/TextBlock/TextBlockContent.d.ts +3 -2
  43. package/mobile/bundle/model/DefaultListItemType.d.ts +4 -0
  44. package/mobile/bundle/model/RichTextItem.d.ts +8 -0
  45. package/mobile/bundle/ui-kit/BenefitItem/BenefitItemProps.d.ts +4 -13
  46. package/mobile/dist/components/ProductTile/ProductTile.js +1 -2
  47. package/mobile/dist/components/ProductTile/ProductTile.js.map +1 -1
  48. package/mobile/dist/components/ProductTile/ProductTileContent.d.ts +4 -13
  49. package/mobile/dist/components/StepsBlock/StepsBlockContent.d.ts +6 -4
  50. package/mobile/dist/components/TextBlock/TextBlockContent.d.ts +3 -2
  51. package/mobile/dist/model/DefaultListItemType.d.ts +4 -0
  52. package/mobile/dist/model/DefaultListItemType.js +2 -0
  53. package/mobile/dist/model/DefaultListItemType.js.map +1 -0
  54. package/mobile/dist/model/RichTextItem.d.ts +8 -0
  55. package/mobile/dist/model/RichTextItem.js +2 -0
  56. package/mobile/dist/model/RichTextItem.js.map +1 -0
  57. package/mobile/dist/ui-kit/BenefitItem/BenefitItemProps.d.ts +4 -13
  58. package/mobile/lib/components/ProductTile/ProductTile.js +1 -2
  59. package/mobile/lib/components/ProductTile/ProductTile.js.map +1 -1
  60. package/mobile/lib/components/ProductTile/ProductTileContent.d.ts +4 -13
  61. package/mobile/lib/components/StepsBlock/StepsBlockContent.d.ts +6 -4
  62. package/mobile/lib/components/TextBlock/TextBlockContent.d.ts +3 -2
  63. package/mobile/lib/model/DefaultListItemType.d.ts +4 -0
  64. package/mobile/lib/model/DefaultListItemType.js +2 -0
  65. package/mobile/lib/model/DefaultListItemType.js.map +1 -0
  66. package/mobile/lib/model/RichTextItem.d.ts +8 -0
  67. package/mobile/lib/model/RichTextItem.js +2 -0
  68. package/mobile/lib/model/RichTextItem.js.map +1 -0
  69. package/mobile/lib/ui-kit/BenefitItem/BenefitItemProps.d.ts +4 -13
  70. package/mobile/src/components/ProductTile/ProductTile.tsx +1 -2
  71. package/mobile/src/components/ProductTile/ProductTileContent.ts +4 -15
  72. package/mobile/src/components/StepsBlock/StepsBlockContent.ts +13 -13
  73. package/mobile/src/components/TextBlock/TextBlock.ui.json +7 -1
  74. package/mobile/src/components/TextBlock/TextBlockContent.ts +12 -10
  75. package/mobile/src/model/DefaultListItemType.ts +4 -0
  76. package/mobile/src/model/RichTextItem.ts +9 -0
  77. package/mobile/src/ui-kit/BenefitItem/BenefitItemProps.ts +4 -14
  78. package/package.json +1 -1
  79. package/src/components/ProductTile/ProductTile.tsx +1 -2
  80. package/src/components/ProductTile/ProductTileContent.ts +4 -15
  81. package/src/components/StepsBlock/StepsBlockContent.ts +13 -13
  82. package/src/components/TextBlock/TextBlock.tsx +3 -0
  83. package/src/components/TextBlock/TextBlock.ui.json +7 -1
  84. package/src/components/TextBlock/TextBlockContent.ts +12 -10
  85. package/src/model/DefaultListItemType.ts +4 -0
  86. package/src/model/RichTextItem.ts +9 -0
  87. package/src/ui-kit/BenefitItem/BenefitItemProps.ts +4 -14
  88. package/dist/model/BlurVersion.d.ts +0 -0
  89. package/dist/model/BlurVersion.js +0 -1
  90. package/dist/model/BlurVersion.js.map +0 -1
  91. package/lib/model/BlurVersion.d.ts +0 -0
  92. package/lib/model/BlurVersion.js +0 -1
  93. package/lib/model/BlurVersion.js.map +0 -1
  94. package/mobile/dist/model/BlurVersion.d.ts +0 -0
  95. package/mobile/dist/model/BlurVersion.js +0 -1
  96. package/mobile/dist/model/BlurVersion.js.map +0 -1
  97. package/mobile/lib/model/BlurVersion.d.ts +0 -0
  98. package/mobile/lib/model/BlurVersion.js +0 -1
  99. package/mobile/lib/model/BlurVersion.js.map +0 -1
  100. package/mobile/src/model/BlurVersion.ts +0 -0
  101. package/src/model/BlurVersion.ts +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"ProductTile.js","sourceRoot":"","sources":["../../../src/components/ProductTile/ProductTile.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGxC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAChF,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AACtE,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,2BAA2B,EAAE,MAAM,+BAA+B,CAAC;AAC5E,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAI5C,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,CAC5B,CAAC,EACC,SAAS,GAAG,EAAE,EACd,KAAK,EACL,eAAe,GAAG,GAAG,EACrB,WAAW,EACX,qBAAqB,EACrB,QAAQ,GAAG,EAAE,EACb,OAAO,EACP,KAAK,EACL,kBAAkB,GAAG,IAAI,EACzB,GAAG,IAAI,EACR,EAAE,EAAE,CAAC,CACJ,MAAC,YAAY,IACX,SAAS,EAAE,KAAK,CACd,uDAAuD,EACvD,mBAAmB,CAAC,SAAS,CAAC,EAC9B,SAAS,CACV,KACG,IAAI,aAER,eAAK,SAAS,EAAE,KAAK,CAAC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KAAK,EAAE,kBAAkB,CAAC,IAC1B,CAChB,CACF,CAAC;AAEF,SAAS,cAAc,CAAC,QAAmB,EAAE,KAAe;IAC1D,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE;QACpB,OAAO,IAAI,CAAC;KACb;IAED,wGAAwG;IACxG,MAAM,aAAa,GAAG,KAAK,EAAE,GAAG,CAAC,CAAC,CAAC,0BAA0B,CAAC,CAAC,CAAC,MAAM,CAAC;IAEvE,OAAO,CACL,cACE,SAAS,EAAE,yFAAyF,aAAa,EAAE,YAElH,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI,GACjD,CACP,CAAC;AACJ,CAAC"}
@@ -1,29 +1,20 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, HeadlineProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { Picture } from '../../model/Picture';
5
+ import type { RichTextItem } from '../../model/RichTextItem';
4
6
  import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
5
- import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
6
7
  /**
7
8
  * @title Стандартный
8
9
  */
9
- declare type TextBenefit = DescriptionProps & LabelProps & {
10
- /** @default default */
11
- type: 'default';
12
- };
13
- /**
14
- * @title Форматированный текст
15
- */
16
- declare type RichText = RichTextProps & {
17
- /** @default rte */
18
- type: 'rte';
19
- };
10
+ declare type TextBenefit = DescriptionProps & LabelProps & DefaultListItemType;
20
11
  /**
21
12
  * @title Преимущество
22
13
  * @default{
23
14
  * "type": "default"
24
15
  * }
25
16
  */
26
- export declare type Benefit = TextBenefit | RichText;
17
+ export declare type Benefit = TextBenefit | RichTextItem;
27
18
  /**
28
19
  * @title Продуктовая плитка
29
20
  */
@@ -3,10 +3,7 @@ import type { DescriptionProps, HeadlineCommonProps, LabelProps } from '../../mo
3
3
  import type { IconProps } from '../../model/Picture';
4
4
  import type { SizeVersion } from '../../model/SizeVersion';
5
5
  import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
6
- /**
7
- * @title Шаг
8
- */
9
- export declare type Step = DescriptionProps & LabelProps & IconProps & {
6
+ declare type StepCommonProps = IconProps & {
10
7
  /** @title Кнопка */
11
8
  button?: ButtonWithIconProps;
12
9
  /**
@@ -17,6 +14,10 @@ export declare type Step = DescriptionProps & LabelProps & IconProps & {
17
14
  /** @title Список */
18
15
  items?: string[];
19
16
  };
17
+ /**
18
+ * @title Шаг
19
+ */
20
+ export declare type Step = DescriptionProps & LabelProps & StepCommonProps;
20
21
  /**
21
22
  * @title Блок шаги
22
23
  */
@@ -41,3 +42,4 @@ export declare type StepsBlockContent = HeadlineCommonProps & {
41
42
  size?: SizeVersion;
42
43
  version?: BlockVersion;
43
44
  };
45
+ export {};
@@ -1,5 +1,6 @@
1
- import type { Picture } from '../../model/Picture';
2
1
  import type { HeadlineCommonProps } from '../../model/HeadlineType';
2
+ import type { Picture } from '../../model/Picture';
3
+ import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
3
4
  /**
4
5
  * @title Цвет блока
5
6
  * @enumNames ["Основная", "Второстепенная", "Второстепенная прозрачная"]
@@ -13,7 +14,7 @@ export declare type TextBlockIconVersion = 'none' | 'small' | 'big';
13
14
  /**
14
15
  * @title Текстовый блок
15
16
  */
16
- export declare type TextBlockContent = HeadlineCommonProps & {
17
+ export declare type TextBlockContent = HeadlineCommonProps & RichTextProps & {
17
18
  iconVersion?: TextBlockIconVersion;
18
19
  image?: Picture;
19
20
  blockVersion?: TextBlockVersion;
@@ -0,0 +1,4 @@
1
+ export interface DefaultListItemType {
2
+ /** @default default */
3
+ type: 'default';
4
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=DefaultListItemType.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DefaultListItemType.js","sourceRoot":"","sources":["../../src/model/DefaultListItemType.ts"],"names":[],"mappings":""}
@@ -0,0 +1,8 @@
1
+ import type { RichTextProps } from '../ui-kit/RichText/RichTextProps';
2
+ /**
3
+ * @title Форматированный текст
4
+ */
5
+ export interface RichTextItem extends RichTextProps {
6
+ /** @default rte */
7
+ type: 'rte';
8
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=RichTextItem.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RichTextItem.js","sourceRoot":"","sources":["../../src/model/RichTextItem.ts"],"names":[],"mappings":""}
@@ -1,8 +1,9 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { IconVersion } from '../../model/IconVersion';
4
5
  import type { IconProps } from '../../model/Picture';
5
- import { RichTextProps } from '../RichText/RichTextProps';
6
+ import type { RichTextItem } from '../../model/RichTextItem';
6
7
  export interface BenefitItemCommonProps {
7
8
  /** @hidden */
8
9
  benefitsVersion?: IconVersion;
@@ -15,24 +16,14 @@ export declare type BenefitItemProps = DescriptionProps & LabelProps & IconProps
15
16
  /**
16
17
  * @title Стандартный бенефит
17
18
  */
18
- declare type DefaultBenefit = BenefitItemProps & {
19
- /** @default default */
20
- type: 'default';
21
- };
22
- /**
23
- * @title Форматированный текст
24
- */
25
- declare type RichText = RichTextProps & {
26
- /** @default rte */
27
- type: 'rte';
28
- };
19
+ declare type DefaultBenefit = BenefitItemProps & DefaultListItemType;
29
20
  /**
30
21
  * @title Преимущество
31
22
  * @default{
32
23
  * "type": "default"
33
24
  * }
34
25
  */
35
- export declare type ComplexBenefitProps = DefaultBenefit | RichText;
26
+ export declare type ComplexBenefitProps = DefaultBenefit | RichTextItem;
36
27
  /**
37
28
  * @title Преимущество
38
29
  */
@@ -62,8 +62,7 @@ function renderBenefits(benefits: Benefit[], image?: Picture) {
62
62
 
63
63
  return (
64
64
  <div
65
- className={`z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline
66
- ${benefitsWidth}`}
65
+ className={`z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline ${benefitsWidth}`}
67
66
  >
68
67
  {benefits.length ? benefits.map(renderBenefit) : null}
69
68
  </div>
@@ -1,25 +1,14 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, HeadlineProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { Picture } from '../../model/Picture';
5
+ import type { RichTextItem } from '../../model/RichTextItem';
4
6
  import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
5
- import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
6
7
 
7
8
  /**
8
9
  * @title Стандартный
9
10
  */
10
- type TextBenefit = DescriptionProps &
11
- LabelProps & {
12
- /** @default default */
13
- type: 'default';
14
- };
15
-
16
- /**
17
- * @title Форматированный текст
18
- */
19
- type RichText = RichTextProps & {
20
- /** @default rte */
21
- type: 'rte';
22
- };
11
+ type TextBenefit = DescriptionProps & LabelProps & DefaultListItemType;
23
12
 
24
13
  /**
25
14
  * @title Преимущество
@@ -27,7 +16,7 @@ type RichText = RichTextProps & {
27
16
  * "type": "default"
28
17
  * }
29
18
  */
30
- export type Benefit = TextBenefit | RichText;
19
+ export type Benefit = TextBenefit | RichTextItem;
31
20
 
32
21
  /**
33
22
  * @title Продуктовая плитка
@@ -4,22 +4,22 @@ import type { IconProps } from '../../model/Picture';
4
4
  import type { SizeVersion } from '../../model/SizeVersion';
5
5
  import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
6
6
 
7
+ type StepCommonProps = IconProps & {
8
+ /** @title Кнопка */
9
+ button?: ButtonWithIconProps;
10
+ /**
11
+ * @title Буллиты
12
+ * @default true
13
+ */
14
+ isDotted?: boolean;
15
+ /** @title Список */
16
+ items?: string[];
17
+ };
18
+
7
19
  /**
8
20
  * @title Шаг
9
21
  */
10
- export type Step = DescriptionProps &
11
- LabelProps &
12
- IconProps & {
13
- /** @title Кнопка */
14
- button?: ButtonWithIconProps;
15
- /**
16
- * @title Буллиты
17
- * @default true
18
- */
19
- isDotted?: boolean;
20
- /** @title Список */
21
- items?: string[];
22
- };
22
+ export type Step = DescriptionProps & LabelProps & StepCommonProps;
23
23
 
24
24
  /**
25
25
  * @title Блок шаги
@@ -1 +1,7 @@
1
- {}
1
+ {
2
+ "content": {
3
+ "__html": {
4
+ "ui:widget": "html"
5
+ }
6
+ }
7
+ }
@@ -1,5 +1,6 @@
1
- import type { Picture } from '../../model/Picture';
2
1
  import type { HeadlineCommonProps } from '../../model/HeadlineType';
2
+ import type { Picture } from '../../model/Picture';
3
+ import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
3
4
 
4
5
  /**
5
6
  * @title Цвет блока
@@ -16,12 +17,13 @@ export type TextBlockIconVersion = 'none' | 'small' | 'big';
16
17
  /**
17
18
  * @title Текстовый блок
18
19
  */
19
- export type TextBlockContent = HeadlineCommonProps & {
20
- iconVersion?: TextBlockIconVersion;
21
- image?: Picture;
22
- blockVersion?: TextBlockVersion;
23
- /** @title Буллиты */ // TODO: mobile prop
24
- isDotted?: boolean;
25
- /** @title Список (моб.) */ // TODO: mobile prop
26
- items?: string[];
27
- };
20
+ export type TextBlockContent = HeadlineCommonProps &
21
+ RichTextProps & {
22
+ iconVersion?: TextBlockIconVersion;
23
+ image?: Picture;
24
+ blockVersion?: TextBlockVersion;
25
+ /** @title Буллиты */ // TODO: mobile prop
26
+ isDotted?: boolean;
27
+ /** @title Список (моб.) */ // TODO: mobile prop
28
+ items?: string[];
29
+ };
@@ -0,0 +1,4 @@
1
+ export interface DefaultListItemType {
2
+ /** @default default */
3
+ type: 'default';
4
+ }
@@ -0,0 +1,9 @@
1
+ import type { RichTextProps } from '../ui-kit/RichText/RichTextProps';
2
+
3
+ /**
4
+ * @title Форматированный текст
5
+ */
6
+ export interface RichTextItem extends RichTextProps {
7
+ /** @default rte */
8
+ type: 'rte';
9
+ }
@@ -1,8 +1,9 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { IconVersion } from '../../model/IconVersion';
4
5
  import type { IconProps } from '../../model/Picture';
5
- import { RichTextProps } from '../RichText/RichTextProps';
6
+ import type { RichTextItem } from '../../model/RichTextItem';
6
7
 
7
8
  export interface BenefitItemCommonProps {
8
9
  /** @hidden */
@@ -18,18 +19,7 @@ export type BenefitItemProps = DescriptionProps & LabelProps & IconProps;
18
19
  /**
19
20
  * @title Стандартный бенефит
20
21
  */
21
- type DefaultBenefit = BenefitItemProps & {
22
- /** @default default */
23
- type: 'default';
24
- };
25
-
26
- /**
27
- * @title Форматированный текст
28
- */
29
- type RichText = RichTextProps & {
30
- /** @default rte */
31
- type: 'rte';
32
- };
22
+ type DefaultBenefit = BenefitItemProps & DefaultListItemType;
33
23
 
34
24
  /**
35
25
  * @title Преимущество
@@ -37,7 +27,7 @@ type RichText = RichTextProps & {
37
27
  * "type": "default"
38
28
  * }
39
29
  */
40
- export type ComplexBenefitProps = DefaultBenefit | RichText;
30
+ export type ComplexBenefitProps = DefaultBenefit | RichTextItem;
41
31
 
42
32
  /**
43
33
  * @title Преимущество
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redneckz/wildless-cms-uni-blocks",
3
- "version": "0.8.7",
3
+ "version": "0.8.8",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "author": "ЦК",
@@ -62,8 +62,7 @@ function renderBenefits(benefits: Benefit[], image?: Picture) {
62
62
 
63
63
  return (
64
64
  <div
65
- className={`z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline
66
- ${benefitsWidth}`}
65
+ className={`z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline ${benefitsWidth}`}
67
66
  >
68
67
  {benefits.length ? benefits.map(renderBenefit) : null}
69
68
  </div>
@@ -1,25 +1,14 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, HeadlineProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { Picture } from '../../model/Picture';
5
+ import type { RichTextItem } from '../../model/RichTextItem';
4
6
  import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
5
- import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
6
7
 
7
8
  /**
8
9
  * @title Стандартный
9
10
  */
10
- type TextBenefit = DescriptionProps &
11
- LabelProps & {
12
- /** @default default */
13
- type: 'default';
14
- };
15
-
16
- /**
17
- * @title Форматированный текст
18
- */
19
- type RichText = RichTextProps & {
20
- /** @default rte */
21
- type: 'rte';
22
- };
11
+ type TextBenefit = DescriptionProps & LabelProps & DefaultListItemType;
23
12
 
24
13
  /**
25
14
  * @title Преимущество
@@ -27,7 +16,7 @@ type RichText = RichTextProps & {
27
16
  * "type": "default"
28
17
  * }
29
18
  */
30
- export type Benefit = TextBenefit | RichText;
19
+ export type Benefit = TextBenefit | RichTextItem;
31
20
 
32
21
  /**
33
22
  * @title Продуктовая плитка
@@ -4,22 +4,22 @@ import type { IconProps } from '../../model/Picture';
4
4
  import type { SizeVersion } from '../../model/SizeVersion';
5
5
  import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
6
6
 
7
+ type StepCommonProps = IconProps & {
8
+ /** @title Кнопка */
9
+ button?: ButtonWithIconProps;
10
+ /**
11
+ * @title Буллиты
12
+ * @default true
13
+ */
14
+ isDotted?: boolean;
15
+ /** @title Список */
16
+ items?: string[];
17
+ };
18
+
7
19
  /**
8
20
  * @title Шаг
9
21
  */
10
- export type Step = DescriptionProps &
11
- LabelProps &
12
- IconProps & {
13
- /** @title Кнопка */
14
- button?: ButtonWithIconProps;
15
- /**
16
- * @title Буллиты
17
- * @default true
18
- */
19
- isDotted?: boolean;
20
- /** @title Список */
21
- items?: string[];
22
- };
22
+ export type Step = DescriptionProps & LabelProps & StepCommonProps;
23
23
 
24
24
  /**
25
25
  * @title Блок шаги
@@ -4,6 +4,7 @@ import type { Picture } from '../../model/Picture';
4
4
  import { BlockWrapper } from '../../ui-kit/BlockWrapper';
5
5
  import { Img } from '../../ui-kit/Img/Img';
6
6
  import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
7
+ import { RichText } from '../../ui-kit/RichText/RichText';
7
8
  import { Text } from '../../ui-kit/Text/Text';
8
9
  import type { TextBlockContent, TextBlockVersion } from './TextBlockContent';
9
10
 
@@ -23,6 +24,7 @@ export const TextBlock = JSX<TextBlockProps>(
23
24
  blockVersion = 'primary',
24
25
  iconVersion,
25
26
  image,
27
+ __html,
26
28
  ...rest
27
29
  }) => {
28
30
  const isSecondaryBlock = blockVersion === 'secondary';
@@ -41,6 +43,7 @@ export const TextBlock = JSX<TextBlockProps>(
41
43
  {description ? (
42
44
  <div className="mt-1">{renderDescription(description, isSecondaryBlock)}</div>
43
45
  ) : null}
46
+ {__html ? <RichText __html={__html} /> : null}
44
47
  </div>
45
48
  </BlockWrapper>
46
49
  );
@@ -1 +1,7 @@
1
- {}
1
+ {
2
+ "content": {
3
+ "__html": {
4
+ "ui:widget": "html"
5
+ }
6
+ }
7
+ }
@@ -1,5 +1,6 @@
1
- import type { Picture } from '../../model/Picture';
2
1
  import type { HeadlineCommonProps } from '../../model/HeadlineType';
2
+ import type { Picture } from '../../model/Picture';
3
+ import type { RichTextProps } from '../../ui-kit/RichText/RichTextProps';
3
4
 
4
5
  /**
5
6
  * @title Цвет блока
@@ -16,12 +17,13 @@ export type TextBlockIconVersion = 'none' | 'small' | 'big';
16
17
  /**
17
18
  * @title Текстовый блок
18
19
  */
19
- export type TextBlockContent = HeadlineCommonProps & {
20
- iconVersion?: TextBlockIconVersion;
21
- image?: Picture;
22
- blockVersion?: TextBlockVersion;
23
- /** @title Буллиты */ // TODO: mobile prop
24
- isDotted?: boolean;
25
- /** @title Список (моб.) */ // TODO: mobile prop
26
- items?: string[];
27
- };
20
+ export type TextBlockContent = HeadlineCommonProps &
21
+ RichTextProps & {
22
+ iconVersion?: TextBlockIconVersion;
23
+ image?: Picture;
24
+ blockVersion?: TextBlockVersion;
25
+ /** @title Буллиты */ // TODO: mobile prop
26
+ isDotted?: boolean;
27
+ /** @title Список (моб.) */ // TODO: mobile prop
28
+ items?: string[];
29
+ };
@@ -0,0 +1,4 @@
1
+ export interface DefaultListItemType {
2
+ /** @default default */
3
+ type: 'default';
4
+ }
@@ -0,0 +1,9 @@
1
+ import type { RichTextProps } from '../ui-kit/RichText/RichTextProps';
2
+
3
+ /**
4
+ * @title Форматированный текст
5
+ */
6
+ export interface RichTextItem extends RichTextProps {
7
+ /** @default rte */
8
+ type: 'rte';
9
+ }
@@ -1,8 +1,9 @@
1
1
  import type { BlockVersion } from '../../model/BlockVersion';
2
+ import type { DefaultListItemType } from '../../model/DefaultListItemType';
2
3
  import type { DescriptionProps, LabelProps } from '../../model/HeadlineType';
3
4
  import type { IconVersion } from '../../model/IconVersion';
4
5
  import type { IconProps } from '../../model/Picture';
5
- import { RichTextProps } from '../RichText/RichTextProps';
6
+ import type { RichTextItem } from '../../model/RichTextItem';
6
7
 
7
8
  export interface BenefitItemCommonProps {
8
9
  /** @hidden */
@@ -18,18 +19,7 @@ export type BenefitItemProps = DescriptionProps & LabelProps & IconProps;
18
19
  /**
19
20
  * @title Стандартный бенефит
20
21
  */
21
- type DefaultBenefit = BenefitItemProps & {
22
- /** @default default */
23
- type: 'default';
24
- };
25
-
26
- /**
27
- * @title Форматированный текст
28
- */
29
- type RichText = RichTextProps & {
30
- /** @default rte */
31
- type: 'rte';
32
- };
22
+ type DefaultBenefit = BenefitItemProps & DefaultListItemType;
33
23
 
34
24
  /**
35
25
  * @title Преимущество
@@ -37,7 +27,7 @@ type RichText = RichTextProps & {
37
27
  * "type": "default"
38
28
  * }
39
29
  */
40
- export type ComplexBenefitProps = DefaultBenefit | RichText;
30
+ export type ComplexBenefitProps = DefaultBenefit | RichTextItem;
41
31
 
42
32
  /**
43
33
  * @title Преимущество
File without changes
@@ -1 +0,0 @@
1
- //# sourceMappingURL=BlurVersion.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BlurVersion.js","sourceRoot":"","sources":["../../src/model/BlurVersion.ts"],"names":[],"mappings":""}
File without changes
@@ -1 +0,0 @@
1
- //# sourceMappingURL=BlurVersion.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BlurVersion.js","sourceRoot":"","sources":["../../src/model/BlurVersion.ts"],"names":[],"mappings":""}
File without changes
@@ -1 +0,0 @@
1
- //# sourceMappingURL=BlurVersion.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BlurVersion.js","sourceRoot":"","sources":["../../src/model/BlurVersion.ts"],"names":[],"mappings":""}
File without changes
@@ -1 +0,0 @@
1
- //# sourceMappingURL=BlurVersion.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BlurVersion.js","sourceRoot":"","sources":["../../src/model/BlurVersion.ts"],"names":[],"mappings":""}
File without changes
File without changes