@gravity-ui/page-constructor 1.11.1 → 1.12.1

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 (127) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/build/cjs/blocks/Banner/schema.d.ts +12 -0
  3. package/build/cjs/blocks/Banner/schema.js +2 -0
  4. package/build/cjs/blocks/CardLayout/schema.d.ts +28 -22
  5. package/build/cjs/blocks/CardLayout/schema.js +1 -5
  6. package/build/cjs/blocks/Companies/schema.d.ts +2 -0
  7. package/build/cjs/blocks/Companies/schema.js +2 -0
  8. package/build/cjs/blocks/ContentLayout/schema.d.ts +6 -0
  9. package/build/cjs/blocks/ExtendedFeatures/schema.d.ts +22 -16
  10. package/build/cjs/blocks/ExtendedFeatures/schema.js +3 -5
  11. package/build/cjs/blocks/Header/schema.d.ts +16 -0
  12. package/build/cjs/blocks/Header/schema.js +5 -0
  13. package/build/cjs/blocks/HeaderSlider/schema.d.ts +9 -23
  14. package/build/cjs/blocks/Icons/schema.d.ts +6 -0
  15. package/build/cjs/blocks/Icons/schema.js +2 -0
  16. package/build/cjs/blocks/Info/schema.d.ts +10 -0
  17. package/build/cjs/blocks/Info/schema.js +2 -0
  18. package/build/cjs/blocks/LinkTable/schema.d.ts +30 -20
  19. package/build/cjs/blocks/LinkTable/schema.js +1 -1
  20. package/build/cjs/blocks/Media/schema.d.ts +62 -53
  21. package/build/cjs/blocks/Media/schema.js +6 -10
  22. package/build/cjs/blocks/Preview/schema.d.ts +2 -0
  23. package/build/cjs/blocks/Preview/schema.js +4 -0
  24. package/build/cjs/blocks/PromoFeaturesBlock/schema.d.ts +20 -14
  25. package/build/cjs/blocks/PromoFeaturesBlock/schema.js +3 -5
  26. package/build/cjs/blocks/Questions/schema.d.ts +5 -0
  27. package/build/cjs/blocks/Questions/schema.js +2 -0
  28. package/build/cjs/blocks/Security/schema.d.ts +2 -0
  29. package/build/cjs/blocks/Security/schema.js +2 -0
  30. package/build/cjs/blocks/Simple/schema.d.ts +3 -0
  31. package/build/cjs/blocks/Simple/schema.js +1 -0
  32. package/build/cjs/blocks/Slider/schema.d.ts +31 -45
  33. package/build/cjs/blocks/Slider/schema.js +2 -5
  34. package/build/cjs/blocks/Table/schema.d.ts +4 -0
  35. package/build/cjs/blocks/Table/schema.js +3 -0
  36. package/build/cjs/blocks/Tabs/schema.d.ts +37 -23
  37. package/build/cjs/blocks/Tabs/schema.js +2 -3
  38. package/build/cjs/components/Author/schema.d.ts +3 -0
  39. package/build/cjs/components/BlockHeader/BlockHeader.css +8 -19
  40. package/build/cjs/components/BlockHeader/BlockHeader.js +4 -3
  41. package/build/cjs/components/Image/schema.d.ts +2 -0
  42. package/build/cjs/components/Image/schema.js +14 -23
  43. package/build/cjs/schema/index.d.ts +2 -0
  44. package/build/cjs/schema/validators/common.d.ts +48 -0
  45. package/build/cjs/schema/validators/common.js +21 -1
  46. package/build/cjs/sub-blocks/BackgroundCard/schema.d.ts +5 -0
  47. package/build/cjs/sub-blocks/BasicCard/schema.d.ts +4 -0
  48. package/build/cjs/sub-blocks/CardWithImage/schema.d.ts +54 -46
  49. package/build/cjs/sub-blocks/CardWithImage/schema.js +7 -6
  50. package/build/cjs/sub-blocks/Content/schema.d.ts +8 -0
  51. package/build/cjs/sub-blocks/Content/schema.js +3 -1
  52. package/build/cjs/sub-blocks/MediaCard/schema.d.ts +1 -0
  53. package/build/cjs/sub-blocks/NewsCard/schema.d.ts +1 -0
  54. package/build/cjs/sub-blocks/NewsCard/schema.js +1 -0
  55. package/build/cjs/sub-blocks/Partner/schema.d.ts +1 -0
  56. package/build/cjs/sub-blocks/Partner/schema.js +1 -0
  57. package/build/cjs/sub-blocks/PriceDetailed/schema.d.ts +1 -0
  58. package/build/cjs/sub-blocks/PriceDetailed/schema.js +8 -0
  59. package/build/cjs/sub-blocks/Quote/schema.d.ts +4 -0
  60. package/build/cjs/sub-blocks/Quote/schema.js +1 -0
  61. package/build/cjs/sub-blocks/TutorialCard/schema.d.ts +2 -0
  62. package/build/cjs/sub-blocks/TutorialCard/schema.js +2 -0
  63. package/build/cjs/text-transform/blocks.js +49 -32
  64. package/build/esm/blocks/Banner/schema.d.ts +12 -0
  65. package/build/esm/blocks/Banner/schema.js +2 -0
  66. package/build/esm/blocks/CardLayout/schema.d.ts +28 -22
  67. package/build/esm/blocks/CardLayout/schema.js +2 -6
  68. package/build/esm/blocks/Companies/schema.d.ts +2 -0
  69. package/build/esm/blocks/Companies/schema.js +2 -0
  70. package/build/esm/blocks/ContentLayout/schema.d.ts +6 -0
  71. package/build/esm/blocks/ExtendedFeatures/schema.d.ts +22 -16
  72. package/build/esm/blocks/ExtendedFeatures/schema.js +4 -6
  73. package/build/esm/blocks/Header/schema.d.ts +16 -0
  74. package/build/esm/blocks/Header/schema.js +5 -0
  75. package/build/esm/blocks/HeaderSlider/schema.d.ts +9 -23
  76. package/build/esm/blocks/Icons/schema.d.ts +6 -0
  77. package/build/esm/blocks/Icons/schema.js +2 -0
  78. package/build/esm/blocks/Info/schema.d.ts +10 -0
  79. package/build/esm/blocks/Info/schema.js +2 -0
  80. package/build/esm/blocks/LinkTable/schema.d.ts +30 -20
  81. package/build/esm/blocks/LinkTable/schema.js +2 -2
  82. package/build/esm/blocks/Media/schema.d.ts +62 -53
  83. package/build/esm/blocks/Media/schema.js +7 -11
  84. package/build/esm/blocks/Preview/schema.d.ts +2 -0
  85. package/build/esm/blocks/Preview/schema.js +4 -0
  86. package/build/esm/blocks/PromoFeaturesBlock/schema.d.ts +20 -14
  87. package/build/esm/blocks/PromoFeaturesBlock/schema.js +4 -6
  88. package/build/esm/blocks/Questions/schema.d.ts +5 -0
  89. package/build/esm/blocks/Questions/schema.js +2 -0
  90. package/build/esm/blocks/Security/schema.d.ts +2 -0
  91. package/build/esm/blocks/Security/schema.js +2 -0
  92. package/build/esm/blocks/Simple/schema.d.ts +3 -0
  93. package/build/esm/blocks/Simple/schema.js +1 -0
  94. package/build/esm/blocks/Slider/schema.d.ts +31 -45
  95. package/build/esm/blocks/Slider/schema.js +3 -6
  96. package/build/esm/blocks/Table/schema.d.ts +4 -0
  97. package/build/esm/blocks/Table/schema.js +3 -0
  98. package/build/esm/blocks/Tabs/schema.d.ts +37 -23
  99. package/build/esm/blocks/Tabs/schema.js +3 -4
  100. package/build/esm/components/Author/schema.d.ts +3 -0
  101. package/build/esm/components/BlockHeader/BlockHeader.css +8 -19
  102. package/build/esm/components/BlockHeader/BlockHeader.js +5 -4
  103. package/build/esm/components/Image/schema.d.ts +2 -0
  104. package/build/esm/components/Image/schema.js +14 -23
  105. package/build/esm/schema/index.d.ts +2 -0
  106. package/build/esm/schema/validators/common.d.ts +48 -0
  107. package/build/esm/schema/validators/common.js +20 -0
  108. package/build/esm/sub-blocks/BackgroundCard/schema.d.ts +5 -0
  109. package/build/esm/sub-blocks/BasicCard/schema.d.ts +4 -0
  110. package/build/esm/sub-blocks/CardWithImage/schema.d.ts +54 -46
  111. package/build/esm/sub-blocks/CardWithImage/schema.js +8 -7
  112. package/build/esm/sub-blocks/Content/schema.d.ts +8 -0
  113. package/build/esm/sub-blocks/Content/schema.js +3 -1
  114. package/build/esm/sub-blocks/MediaCard/schema.d.ts +1 -0
  115. package/build/esm/sub-blocks/NewsCard/schema.d.ts +1 -0
  116. package/build/esm/sub-blocks/NewsCard/schema.js +1 -0
  117. package/build/esm/sub-blocks/Partner/schema.d.ts +1 -0
  118. package/build/esm/sub-blocks/Partner/schema.js +1 -0
  119. package/build/esm/sub-blocks/PriceDetailed/schema.d.ts +1 -0
  120. package/build/esm/sub-blocks/PriceDetailed/schema.js +8 -0
  121. package/build/esm/sub-blocks/Quote/schema.d.ts +4 -0
  122. package/build/esm/sub-blocks/Quote/schema.js +1 -0
  123. package/build/esm/sub-blocks/TutorialCard/schema.d.ts +2 -0
  124. package/build/esm/sub-blocks/TutorialCard/schema.js +2 -0
  125. package/build/esm/text-transform/blocks.js +49 -32
  126. package/package.json +1 -4
  127. package/server/text-transform/blocks.js +49 -32
@@ -22,6 +22,7 @@ export declare const QuestionsBlock: {
22
22
  properties: {
23
23
  text: {
24
24
  type: string;
25
+ contentType: string;
25
26
  };
26
27
  textSize: {
27
28
  type: string;
@@ -36,13 +37,16 @@ export declare const QuestionsBlock: {
36
37
  };
37
38
  } | {
38
39
  type: string;
40
+ contentType: string;
39
41
  })[];
40
42
  };
41
43
  text: {
42
44
  type: string;
45
+ contentType: string;
43
46
  };
44
47
  additionalInfo: {
45
48
  type: string;
49
+ contentType: string;
46
50
  };
47
51
  links: {
48
52
  type: string;
@@ -73,6 +77,7 @@ export declare const QuestionsBlock: {
73
77
  properties: {
74
78
  text: {
75
79
  type: string;
80
+ contentType: string;
76
81
  };
77
82
  url: {
78
83
  type: string;
@@ -13,9 +13,11 @@ export const QuestionsBlock = {
13
13
  properties: {
14
14
  title: {
15
15
  type: 'string',
16
+ contentType: 'text',
16
17
  },
17
18
  text: {
18
19
  type: 'string',
20
+ contentType: 'yfm',
19
21
  },
20
22
  link: LinkProps,
21
23
  listStyle: {
@@ -12,6 +12,7 @@ export declare const SecurityBlock: {
12
12
  };
13
13
  title: {
14
14
  type: string;
15
+ contentType: string;
15
16
  };
16
17
  media: {
17
18
  type: string;
@@ -106,6 +107,7 @@ export declare const SecurityBlock: {
106
107
  };
107
108
  text: {
108
109
  type: string;
110
+ contentType: string;
109
111
  };
110
112
  };
111
113
  };
@@ -10,6 +10,7 @@ export const SecurityBlock = {
10
10
  type: 'string',
11
11
  }, title: {
12
12
  type: 'string',
13
+ contentType: 'text',
13
14
  }, media: Media, points: filteredArray({
14
15
  type: 'object',
15
16
  properties: {
@@ -18,6 +19,7 @@ export const SecurityBlock = {
18
19
  },
19
20
  text: {
20
21
  type: 'string',
22
+ contentType: 'text',
21
23
  },
22
24
  link: _.pick(LinkProps, ['text', 'url']),
23
25
  },
@@ -19,6 +19,7 @@ export declare const SimpleBlock: {
19
19
  properties: {
20
20
  text: {
21
21
  type: string;
22
+ contentType: string;
22
23
  };
23
24
  url: {
24
25
  type: string;
@@ -41,6 +42,7 @@ export declare const SimpleBlock: {
41
42
  properties: {
42
43
  text: {
43
44
  type: string;
45
+ contentType: string;
44
46
  };
45
47
  textSize: {
46
48
  type: string;
@@ -56,6 +58,7 @@ export declare const SimpleBlock: {
56
58
  };
57
59
  description: {
58
60
  type: string;
61
+ contentType: string;
59
62
  };
60
63
  };
61
64
  };
@@ -5,6 +5,7 @@ export const SimpleBlock = {
5
5
  required: ['title', 'description'],
6
6
  properties: Object.assign(Object.assign(Object.assign({ title: TitleProps, description: {
7
7
  type: 'string',
8
+ contentType: 'yfm',
8
9
  } }, BlockBaseProps), AnimatableProps), { children: ChildrenProps }),
9
10
  },
10
11
  };
@@ -5,29 +5,6 @@ export declare const SliderProps: {
5
5
  arrows: {
6
6
  type: string;
7
7
  };
8
- description: {
9
- type: string;
10
- };
11
- title: {
12
- type: string;
13
- additionalProperties: boolean;
14
- required: string[];
15
- properties: {
16
- text: {
17
- type: string;
18
- };
19
- textSize: {
20
- type: string;
21
- enum: string[];
22
- };
23
- url: {
24
- type: string;
25
- };
26
- resetMargin: {
27
- type: string;
28
- };
29
- };
30
- };
31
8
  randomOrder: {
32
9
  type: string;
33
10
  };
@@ -56,6 +33,7 @@ export declare const SliderProps: {
56
33
  properties: {
57
34
  text: {
58
35
  type: string;
36
+ contentType: string;
59
37
  };
60
38
  size: {
61
39
  type: string;
@@ -105,34 +83,40 @@ export declare const SliderBlock: {
105
83
  additionalProperties: boolean;
106
84
  required: never[];
107
85
  properties: {
108
- dots: {
109
- type: string;
86
+ title: {
87
+ oneOf: ({
88
+ type: string;
89
+ additionalProperties: boolean;
90
+ required: string[];
91
+ properties: {
92
+ text: {
93
+ type: string;
94
+ contentType: string;
95
+ };
96
+ textSize: {
97
+ type: string;
98
+ enum: string[];
99
+ };
100
+ url: {
101
+ type: string;
102
+ };
103
+ resetMargin: {
104
+ type: string;
105
+ };
106
+ };
107
+ } | {
108
+ type: string;
109
+ })[];
110
110
  };
111
- arrows: {
111
+ description: {
112
112
  type: string;
113
+ contentType: string;
113
114
  };
114
- description: {
115
+ dots: {
115
116
  type: string;
116
117
  };
117
- title: {
118
+ arrows: {
118
119
  type: string;
119
- additionalProperties: boolean;
120
- required: string[];
121
- properties: {
122
- text: {
123
- type: string;
124
- };
125
- textSize: {
126
- type: string;
127
- enum: string[];
128
- };
129
- url: {
130
- type: string;
131
- };
132
- resetMargin: {
133
- type: string;
134
- };
135
- };
136
120
  };
137
121
  randomOrder: {
138
122
  type: string;
@@ -162,6 +146,7 @@ export declare const SliderBlock: {
162
146
  properties: {
163
147
  text: {
164
148
  type: string;
149
+ contentType: string;
165
150
  };
166
151
  size: {
167
152
  type: string;
@@ -212,6 +197,7 @@ export declare const SliderBlock: {
212
197
  properties: {
213
198
  text: {
214
199
  type: string;
200
+ contentType: string;
215
201
  };
216
202
  url: {
217
203
  type: string;
@@ -1,4 +1,4 @@
1
- import { BlockBaseProps, TitleProps, AnimatableProps, ChildrenCardsProps, sliderSizesObject, textSize, } from '../../schema/validators/common';
1
+ import { BlockBaseProps, AnimatableProps, ChildrenCardsProps, sliderSizesObject, textSize, BlockHeaderProps, } from '../../schema/validators/common';
2
2
  const LoadableProps = {
3
3
  additionalProperties: false,
4
4
  required: ['source'],
@@ -33,6 +33,7 @@ const DisclaimerProps = {
33
33
  properties: {
34
34
  text: {
35
35
  type: 'string',
36
+ contentType: 'text',
36
37
  },
37
38
  size: {
38
39
  type: 'string',
@@ -47,10 +48,6 @@ export const SliderProps = {
47
48
  arrows: {
48
49
  type: 'boolean',
49
50
  },
50
- description: {
51
- type: 'string',
52
- },
53
- title: TitleProps,
54
51
  randomOrder: {
55
52
  type: 'boolean',
56
53
  },
@@ -67,6 +64,6 @@ export const SliderBlock = {
67
64
  'slider-block': {
68
65
  additionalProperties: false,
69
66
  required: [],
70
- properties: Object.assign(Object.assign(Object.assign({}, BlockBaseProps), AnimatableProps), SliderProps),
67
+ properties: Object.assign(Object.assign(Object.assign(Object.assign({}, BlockBaseProps), AnimatableProps), SliderProps), BlockHeaderProps),
71
68
  },
72
69
  };
@@ -5,6 +5,7 @@ export declare const TableBlock: {
5
5
  properties: {
6
6
  title: {
7
7
  type: string;
8
+ contentType: string;
8
9
  };
9
10
  table: {
10
11
  additionalProperties: boolean;
@@ -16,6 +17,7 @@ export declare const TableBlock: {
16
17
  type: string;
17
18
  items: {
18
19
  type: string[];
20
+ contentType: string;
19
21
  };
20
22
  };
21
23
  };
@@ -23,6 +25,7 @@ export declare const TableBlock: {
23
25
  type: string;
24
26
  items: {
25
27
  type: string;
28
+ contentType: string;
26
29
  };
27
30
  };
28
31
  justify: {
@@ -47,6 +50,7 @@ export declare const TableBlock: {
47
50
  properties: {
48
51
  text: {
49
52
  type: string;
53
+ contentType: string;
50
54
  };
51
55
  url: {
52
56
  type: string;
@@ -5,6 +5,7 @@ export const TableBlock = {
5
5
  required: ['title', 'table'],
6
6
  properties: Object.assign(Object.assign({}, BlockBaseProps), { title: {
7
7
  type: 'string',
8
+ contentType: 'text',
8
9
  }, table: {
9
10
  additionalProperties: false,
10
11
  required: ['content'],
@@ -14,12 +15,14 @@ export const TableBlock = {
14
15
  type: 'array',
15
16
  items: {
16
17
  type: ['string', 'number'],
18
+ contentType: 'text',
17
19
  },
18
20
  },
19
21
  }, legend: {
20
22
  type: 'array',
21
23
  items: {
22
24
  type: 'string',
25
+ contentType: 'yfm',
23
26
  },
24
27
  }, justify: {
25
28
  type: 'array',
@@ -8,6 +8,7 @@ export declare const tabsItem: {
8
8
  };
9
9
  caption: {
10
10
  type: string;
11
+ contentType: string;
11
12
  };
12
13
  media: {
13
14
  oneOf: ({
@@ -101,6 +102,7 @@ export declare const tabsItem: {
101
102
  };
102
103
  text: {
103
104
  type: string;
105
+ contentType: string;
104
106
  };
105
107
  };
106
108
  };
@@ -155,6 +157,7 @@ export declare const tabsItem: {
155
157
  properties: {
156
158
  text: {
157
159
  type: string;
160
+ contentType: string;
158
161
  };
159
162
  url: {
160
163
  type: string;
@@ -206,6 +209,7 @@ export declare const tabsItem: {
206
209
  properties: {
207
210
  text: {
208
211
  type: string;
212
+ contentType: string;
209
213
  };
210
214
  textSize: {
211
215
  type: string;
@@ -220,13 +224,16 @@ export declare const tabsItem: {
220
224
  };
221
225
  } | {
222
226
  type: string;
227
+ contentType: string;
223
228
  })[];
224
229
  } | undefined;
225
230
  text?: {
226
231
  type: string;
232
+ contentType: string;
227
233
  } | undefined;
228
234
  additionalInfo?: {
229
235
  type: string;
236
+ contentType: string;
230
237
  } | undefined;
231
238
  size?: {
232
239
  type: string;
@@ -265,29 +272,6 @@ export declare const TabsBlock: {
265
272
  additionalProperties: boolean;
266
273
  required: string[];
267
274
  properties: {
268
- title: {
269
- type: string;
270
- additionalProperties: boolean;
271
- required: string[];
272
- properties: {
273
- text: {
274
- type: string;
275
- };
276
- textSize: {
277
- type: string;
278
- enum: string[];
279
- };
280
- url: {
281
- type: string;
282
- };
283
- resetMargin: {
284
- type: string;
285
- };
286
- };
287
- };
288
- description: {
289
- type: string;
290
- };
291
275
  tabsColSizes: {};
292
276
  direction: {
293
277
  type: string;
@@ -307,6 +291,35 @@ export declare const TabsBlock: {
307
291
  };
308
292
  };
309
293
  };
294
+ title: {
295
+ oneOf: ({
296
+ type: string;
297
+ additionalProperties: boolean;
298
+ required: string[];
299
+ properties: {
300
+ text: {
301
+ type: string;
302
+ contentType: string;
303
+ };
304
+ textSize: {
305
+ type: string;
306
+ enum: string[];
307
+ };
308
+ url: {
309
+ type: string;
310
+ };
311
+ resetMargin: {
312
+ type: string;
313
+ };
314
+ };
315
+ } | {
316
+ type: string;
317
+ })[];
318
+ };
319
+ description: {
320
+ type: string;
321
+ contentType: string;
322
+ };
310
323
  anchor: {
311
324
  type: string;
312
325
  additionalProperties: boolean;
@@ -314,6 +327,7 @@ export declare const TabsBlock: {
314
327
  properties: {
315
328
  text: {
316
329
  type: string;
330
+ contentType: string;
317
331
  };
318
332
  url: {
319
333
  type: string;
@@ -1,5 +1,5 @@
1
1
  import { filteredArray } from '../../schema/validators/utils';
2
- import { LinkProps, withTheme, BlockBaseProps, TitleProps, MediaProps, containerSizesArray, sizeNumber, mediaDirection, } from '../../schema/validators/common';
2
+ import { LinkProps, withTheme, BlockBaseProps, BlockHeaderProps, MediaProps, containerSizesArray, sizeNumber, mediaDirection, } from '../../schema/validators/common';
3
3
  import { ImageProps } from '../../components/Image/schema';
4
4
  import _ from 'lodash';
5
5
  import { ContentBase } from '../../sub-blocks/Content/schema';
@@ -12,6 +12,7 @@ export const tabsItem = {
12
12
  type: 'string',
13
13
  }, caption: {
14
14
  type: 'string',
15
+ contentType: 'text',
15
16
  }, media: withTheme({
16
17
  type: 'object',
17
18
  properties: MediaProps,
@@ -23,9 +24,7 @@ export const TabsBlock = {
23
24
  'tabs-block': {
24
25
  additionalProperties: false,
25
26
  required: ['title', 'items'],
26
- properties: Object.assign(Object.assign({}, BlockBaseProps), { title: TitleProps, description: {
27
- type: 'string',
28
- }, tabsColSizes: containerSizesArray.reduce((acc, size) => (Object.assign(Object.assign({}, acc), { [size]: sizeNumber })), {}), direction: {
27
+ properties: Object.assign(Object.assign(Object.assign({}, BlockBaseProps), BlockHeaderProps), { tabsColSizes: containerSizesArray.reduce((acc, size) => (Object.assign(Object.assign({}, acc), { [size]: sizeNumber })), {}), direction: {
29
28
  type: 'string',
30
29
  enum: mediaDirection,
31
30
  }, centered: { type: 'boolean' }, items: filteredArray(tabsItem) }),
@@ -10,9 +10,11 @@ export declare const author: {
10
10
  properties: {
11
11
  firstName: {
12
12
  type: string;
13
+ contentType: string;
13
14
  };
14
15
  secondName: {
15
16
  type: string;
17
+ contentType: string;
16
18
  };
17
19
  avatar: {
18
20
  type: string;
@@ -20,6 +22,7 @@ export declare const author: {
20
22
  };
21
23
  description: {
22
24
  type: string;
25
+ contentType: string;
23
26
  };
24
27
  };
25
28
  };
@@ -1,27 +1,16 @@
1
1
  /* use this for style redefinitions to awoid problems with
2
2
  unpredictable css rules order in build */
3
- .pc-BlockHeader__description {
4
- font-size: var(--yc-text-body-2-font-size);
5
- line-height: var(--yc-text-body-2-line-height);
6
- margin-top: 16px;
7
- }
8
- .pc-BlockHeader__description_titleSize_s {
9
- margin-top: 8px;
3
+ .pc-block-header__description {
4
+ margin-top: 12px;
10
5
  }
11
- .pc-BlockHeader__description_titleSize_l {
6
+ .pc-block-header__description .yfm {
12
7
  font-size: var(--yc-text-body-3-font-size);
13
8
  line-height: var(--yc-text-body-3-line-height);
14
9
  }
15
- .pc-BlockHeader__description a {
16
- outline: none;
17
- color: var(--yc-color-text-link);
18
- text-decoration: none;
19
- cursor: pointer;
20
- }
21
- .utilityfocus .pc-BlockHeader__description a:focus {
22
- outline: 2px solid #ffdb4d;
10
+ .pc-block-header__description_titleSize_s {
11
+ margin-top: 8px;
23
12
  }
24
- .pc-BlockHeader__description a:hover, .pc-BlockHeader__description a:active {
25
- --pc-text-header-color: var(--yc-color-text-link-hover);
26
- color: var(--yc-color-text-link-hover);
13
+ .pc-block-header__description_titleSize_s .yfm {
14
+ font-size: var(--yc-text-body-2-font-size);
15
+ line-height: var(--yc-text-body-2-line-height);
27
16
  }
@@ -2,9 +2,10 @@ import { __rest } from "tslib";
2
2
  import React from 'react';
3
3
  import { block } from '../../utils';
4
4
  import { Col } from '../../grid';
5
- import { Title, HTML } from '../';
5
+ import { Title } from '../';
6
+ import YFMWrapper from '../YFMWrapper/YFMWrapper';
6
7
  import './BlockHeader.css';
7
- const b = block('BlockHeader');
8
+ const b = block('block-header');
8
9
  const BlockHeader = ({ title, description, className, colSizes = { all: 12, sm: 8 }, }) => {
9
10
  if (!title && !description) {
10
11
  return null;
@@ -13,8 +14,8 @@ const BlockHeader = ({ title, description, className, colSizes = { all: 12, sm:
13
14
  return (React.createElement("div", { className: b(null, className) },
14
15
  text && (React.createElement(Col, { reset: true, sizes: colSizes },
15
16
  React.createElement(Title, Object.assign({ text: text }, titleProps)))),
16
- description && (React.createElement(Col, { reset: true, sizes: { all: 12, sm: 8 } },
17
+ description && (React.createElement(Col, { reset: true, sizes: colSizes },
17
18
  React.createElement("div", { className: b('description', { titleSize: titleProps === null || titleProps === void 0 ? void 0 : titleProps.textSize }) },
18
- React.createElement(HTML, null, description))))));
19
+ React.createElement(YFMWrapper, { content: description, modifiers: { constructor: true } }))))));
19
20
  };
20
21
  export default BlockHeader;
@@ -18,6 +18,7 @@ export declare const ImageDeviceProps: {
18
18
  };
19
19
  alt: {
20
20
  type: string;
21
+ contentType: string;
21
22
  };
22
23
  disableCompress: {
23
24
  type: string;
@@ -35,6 +36,7 @@ export declare const ImageObjectProps: {
35
36
  };
36
37
  alt: {
37
38
  type: string;
39
+ contentType: string;
38
40
  };
39
41
  disableCompress: {
40
42
  type: string;
@@ -1,43 +1,34 @@
1
1
  import { filteredItem } from '../../schema/validators/utils';
2
2
  export const urlPattern = '^((http[s]?|ftp):\\/)?\\/?([^:\\/\\s]+)((\\/\\w+)*\\/)([\\w\\-\\.]+[^#?\\s]+)(.*)?(#[\\w\\-]+)?$';
3
+ const ImageBase = {
4
+ alt: {
5
+ type: 'string',
6
+ contentType: 'text',
7
+ },
8
+ disableCompress: {
9
+ type: 'boolean',
10
+ },
11
+ };
3
12
  export const ImageDeviceProps = {
4
13
  type: 'object',
5
14
  additionalProperties: false,
6
15
  required: ['desktop', 'mobile'],
7
- properties: {
8
- desktop: { type: 'string', pattern: urlPattern },
9
- tablet: {
16
+ properties: Object.assign(Object.assign({}, ImageBase), { desktop: { type: 'string', pattern: urlPattern }, tablet: {
10
17
  type: 'string',
11
18
  pattern: urlPattern,
12
- },
13
- mobile: {
19
+ }, mobile: {
14
20
  type: 'string',
15
21
  pattern: urlPattern,
16
- },
17
- alt: {
18
- type: 'string',
19
- },
20
- disableCompress: {
21
- type: 'boolean',
22
- },
23
- },
22
+ } }),
24
23
  };
25
24
  export const ImageObjectProps = {
26
25
  type: 'object',
27
26
  additionalProperties: false,
28
27
  required: ['src'],
29
- properties: {
30
- src: {
28
+ properties: Object.assign(Object.assign({}, ImageBase), { src: {
31
29
  type: 'string',
32
30
  pattern: urlPattern,
33
- },
34
- alt: {
35
- type: 'string',
36
- },
37
- disableCompress: {
38
- type: 'boolean',
39
- },
40
- },
31
+ } }),
41
32
  };
42
33
  export const ImageProps = {
43
34
  oneOf: [
@@ -43,6 +43,7 @@ export declare function generateDefaultSchema(config?: SchemaCustomConfig): {
43
43
  properties: {
44
44
  title: {
45
45
  type: string;
46
+ contentType: string;
46
47
  };
47
48
  };
48
49
  };
@@ -121,6 +122,7 @@ export declare function generateDefaultSchema(config?: SchemaCustomConfig): {
121
122
  };
122
123
  text: {
123
124
  type: string;
125
+ contentType: string;
124
126
  };
125
127
  };
126
128
  };