@gravity-ui/blog-constructor 4.1.1 → 4.1.2

Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [4.1.2](https://github.com/gravity-ui/blog-constructor/compare/v4.1.1...v4.1.2) (2023-06-23)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * semantic markup ([#71](https://github.com/gravity-ui/blog-constructor/issues/71)) ([fb18afd](https://github.com/gravity-ui/blog-constructor/commit/fb18afd3d38d2bdb81b71e83608f54b90874f9e1))
9
+
3
10
  ## [4.1.1](https://github.com/gravity-ui/blog-constructor/compare/v4.1.0...v4.1.1) (2023-06-14)
4
11
 
5
12
 
@@ -16,6 +16,11 @@ export declare const Banner: {
16
16
  };
17
17
  title: {
18
18
  oneOf: ({
19
+ type: string;
20
+ contentType: string;
21
+ optionName: string;
22
+ } | {
23
+ optionName: string;
19
24
  type: string;
20
25
  additionalProperties: boolean;
21
26
  required: string[];
@@ -35,14 +40,13 @@ export declare const Banner: {
35
40
  type: string;
36
41
  };
37
42
  };
38
- } | {
39
- type: string;
40
- contentType: string;
43
+ contentType?: undefined;
41
44
  })[];
42
45
  };
43
46
  text: {
44
47
  type: string;
45
48
  contentType: string;
49
+ inputType: string;
46
50
  };
47
51
  additionalInfo: {
48
52
  type: string;
@@ -13,6 +13,11 @@ export declare const CTA: {
13
13
  properties: {
14
14
  title: {
15
15
  oneOf: ({
16
+ type: string;
17
+ contentType: string;
18
+ optionName: string;
19
+ } | {
20
+ optionName: string;
16
21
  type: string;
17
22
  additionalProperties: boolean;
18
23
  required: string[];
@@ -32,14 +37,13 @@ export declare const CTA: {
32
37
  type: string;
33
38
  };
34
39
  };
35
- } | {
36
- type: string;
37
- contentType: string;
40
+ contentType?: undefined;
38
41
  })[];
39
42
  };
40
43
  text: {
41
44
  type: string;
42
45
  contentType: string;
46
+ inputType: string;
43
47
  };
44
48
  additionalInfo: {
45
49
  type: string;
@@ -19,6 +19,7 @@ export declare const ColoredText: {
19
19
  } | {
20
20
  type: string;
21
21
  pattern: string;
22
+ optionName: string;
22
23
  })[];
23
24
  };
24
25
  color: {
@@ -32,6 +33,11 @@ export declare const ColoredText: {
32
33
  };
33
34
  title: {
34
35
  oneOf: ({
36
+ type: string;
37
+ contentType: string;
38
+ optionName: string;
39
+ } | {
40
+ optionName: string;
35
41
  type: string;
36
42
  additionalProperties: boolean;
37
43
  required: string[];
@@ -51,14 +57,13 @@ export declare const ColoredText: {
51
57
  type: string;
52
58
  };
53
59
  };
54
- } | {
55
- type: string;
56
- contentType: string;
60
+ contentType?: undefined;
57
61
  })[];
58
62
  };
59
63
  text: {
60
64
  type: string;
61
65
  contentType: string;
66
+ inputType: string;
62
67
  };
63
68
  additionalInfo: {
64
69
  type: string;
@@ -14,6 +14,7 @@ export declare const Header: {
14
14
  description: {
15
15
  type: string;
16
16
  contentType: string;
17
+ inputType: string;
17
18
  };
18
19
  width: {
19
20
  type: string;
@@ -35,7 +36,7 @@ export declare const Header: {
35
36
  enum: string[];
36
37
  };
37
38
  image: {
38
- oneOf: ({
39
+ oneOf: (({
39
40
  oneOf: ({
40
41
  type: string;
41
42
  properties: {
@@ -46,16 +47,20 @@ export declare const Header: {
46
47
  } | {
47
48
  type: string;
48
49
  pattern: string;
50
+ optionName: string;
49
51
  })[];
50
- } | {
52
+ } & {
53
+ optionName: string;
54
+ }) | {
51
55
  type: string;
52
56
  additionalProperties: boolean;
53
57
  required: import("@gravity-ui/page-constructor").Theme[];
54
58
  properties: {};
59
+ optionName: string;
55
60
  })[];
56
61
  };
57
62
  video: {
58
- oneOf: ({
63
+ oneOf: (({
59
64
  type: string;
60
65
  additionalProperties: boolean;
61
66
  required: string[];
@@ -67,7 +72,8 @@ export declare const Header: {
67
72
  };
68
73
  };
69
74
  loop: {
70
- anyOf: ({
75
+ oneOf: ({
76
+ optionName: string;
71
77
  type: string;
72
78
  additionalProperties: boolean;
73
79
  required: string[];
@@ -81,6 +87,7 @@ export declare const Header: {
81
87
  };
82
88
  } | {
83
89
  type: string;
90
+ optionName: string;
84
91
  })[];
85
92
  };
86
93
  type: {
@@ -90,13 +97,13 @@ export declare const Header: {
90
97
  muted: {
91
98
  type: string;
92
99
  };
93
- playing: {
100
+ autoplay: {
94
101
  type: string;
95
102
  };
96
103
  elapsedTime: {
97
104
  type: string;
98
105
  };
99
- playIcon: {
106
+ playButton: {
100
107
  type: string;
101
108
  additionalProperties: boolean;
102
109
  properties: {
@@ -119,11 +126,14 @@ export declare const Header: {
119
126
  enum: string[];
120
127
  };
121
128
  };
122
- } | {
129
+ } & {
130
+ optionName: string;
131
+ }) | {
123
132
  type: string;
124
133
  additionalProperties: boolean;
125
134
  required: import("@gravity-ui/page-constructor").Theme[];
126
135
  properties: {};
136
+ optionName: string;
127
137
  })[];
128
138
  };
129
139
  backLink: {
@@ -148,7 +158,7 @@ export declare const Header: {
148
158
  enum: string[];
149
159
  };
150
160
  background: {
151
- oneOf: ({
161
+ oneOf: (({
152
162
  type: string;
153
163
  additionalProperties: boolean;
154
164
  required: never[];
@@ -163,7 +173,8 @@ export declare const Header: {
163
173
  type: string;
164
174
  };
165
175
  image: {
166
- anyOf: ({
176
+ oneOf: ({
177
+ optionName: string;
167
178
  oneOf: ({
168
179
  type: string;
169
180
  properties: {
@@ -174,7 +185,10 @@ export declare const Header: {
174
185
  } | {
175
186
  type: string;
176
187
  pattern: string;
188
+ optionName: string;
177
189
  })[];
190
+ type?: undefined;
191
+ items?: undefined;
178
192
  } | {
179
193
  type: string;
180
194
  items: {
@@ -188,8 +202,10 @@ export declare const Header: {
188
202
  } | {
189
203
  type: string;
190
204
  pattern: string;
205
+ optionName: string;
191
206
  })[];
192
207
  };
208
+ optionName: string;
193
209
  })[];
194
210
  };
195
211
  video: {
@@ -204,7 +220,8 @@ export declare const Header: {
204
220
  };
205
221
  };
206
222
  loop: {
207
- anyOf: ({
223
+ oneOf: ({
224
+ optionName: string;
208
225
  type: string;
209
226
  additionalProperties: boolean;
210
227
  required: string[];
@@ -218,6 +235,7 @@ export declare const Header: {
218
235
  };
219
236
  } | {
220
237
  type: string;
238
+ optionName: string;
221
239
  })[];
222
240
  };
223
241
  type: {
@@ -227,13 +245,13 @@ export declare const Header: {
227
245
  muted: {
228
246
  type: string;
229
247
  };
230
- playing: {
248
+ autoplay: {
231
249
  type: string;
232
250
  };
233
251
  elapsedTime: {
234
252
  type: string;
235
253
  };
236
- playIcon: {
254
+ playButton: {
237
255
  type: string;
238
256
  additionalProperties: boolean;
239
257
  properties: {
@@ -271,6 +289,10 @@ export declare const Header: {
271
289
  };
272
290
  dataLens: {
273
291
  oneOf: ({
292
+ type: string;
293
+ optionName: string;
294
+ } | {
295
+ optionName: string;
274
296
  type: string;
275
297
  additionalProperties: boolean;
276
298
  required: string[];
@@ -283,8 +305,6 @@ export declare const Header: {
283
305
  enum: string[];
284
306
  };
285
307
  };
286
- } | {
287
- type: string;
288
308
  })[];
289
309
  };
290
310
  fullscreen: {
@@ -369,11 +389,14 @@ export declare const Header: {
369
389
  })[];
370
390
  };
371
391
  };
372
- } | {
392
+ } & {
393
+ optionName: string;
394
+ }) | {
373
395
  type: string;
374
396
  additionalProperties: boolean;
375
397
  required: import("@gravity-ui/page-constructor").Theme[];
376
398
  properties: {};
399
+ optionName: string;
377
400
  })[];
378
401
  };
379
402
  theme: {
@@ -11,7 +11,8 @@ export declare const Media: {
11
11
  type: string;
12
12
  };
13
13
  image: {
14
- anyOf: ({
14
+ oneOf: ({
15
+ optionName: string;
15
16
  oneOf: ({
16
17
  type: string;
17
18
  properties: {
@@ -22,7 +23,10 @@ export declare const Media: {
22
23
  } | {
23
24
  type: string;
24
25
  pattern: string;
26
+ optionName: string;
25
27
  })[];
28
+ type?: undefined;
29
+ items?: undefined;
26
30
  } | {
27
31
  type: string;
28
32
  items: {
@@ -36,8 +40,10 @@ export declare const Media: {
36
40
  } | {
37
41
  type: string;
38
42
  pattern: string;
43
+ optionName: string;
39
44
  })[];
40
45
  };
46
+ optionName: string;
41
47
  })[];
42
48
  };
43
49
  video: {
@@ -52,7 +58,8 @@ export declare const Media: {
52
58
  };
53
59
  };
54
60
  loop: {
55
- anyOf: ({
61
+ oneOf: ({
62
+ optionName: string;
56
63
  type: string;
57
64
  additionalProperties: boolean;
58
65
  required: string[];
@@ -66,6 +73,7 @@ export declare const Media: {
66
73
  };
67
74
  } | {
68
75
  type: string;
76
+ optionName: string;
69
77
  })[];
70
78
  };
71
79
  type: {
@@ -75,13 +83,13 @@ export declare const Media: {
75
83
  muted: {
76
84
  type: string;
77
85
  };
78
- playing: {
86
+ autoplay: {
79
87
  type: string;
80
88
  };
81
89
  elapsedTime: {
82
90
  type: string;
83
91
  };
84
- playIcon: {
92
+ playButton: {
85
93
  type: string;
86
94
  additionalProperties: boolean;
87
95
  properties: {
@@ -119,6 +127,10 @@ export declare const Media: {
119
127
  };
120
128
  dataLens: {
121
129
  oneOf: ({
130
+ type: string;
131
+ optionName: string;
132
+ } | {
133
+ optionName: string;
122
134
  type: string;
123
135
  additionalProperties: boolean;
124
136
  required: string[];
@@ -131,8 +143,6 @@ export declare const Media: {
131
143
  enum: string[];
132
144
  };
133
145
  };
134
- } | {
135
- type: string;
136
146
  })[];
137
147
  };
138
148
  fullscreen: {
@@ -54,7 +54,7 @@ const Sharing = ({ theme, metrikaGoal }) => {
54
54
  handleMetrika();
55
55
  }, [handleAnalyticsGlobal, handleMetrika]);
56
56
  return (react_1.default.createElement("div", { className: b('item') },
57
- react_1.default.createElement("span", { className: b('icon') },
57
+ react_1.default.createElement("div", { className: b('icon') },
58
58
  react_1.default.createElement(uikit_1.SharePopover, { url: (0, common_2.getAbsolutePath)(router), className: b('share'), iconClass: b('share-icon'), switcherClassName: b('switcher', { theme }), tooltipClassName: b('popup'), useWebShareApi: isMobile, direction: 'column', buttonTitle: (0, i18n_1.i18)(i18n_1.Keyset.ActionShare), customIcon: ShareArrowUp_1.ShareArrowUp, placement: "bottom", openByHover: false, shareOptions: shareOptions, handleMetrika: handleAnalytics }))));
59
59
  };
60
60
  exports.Sharing = Sharing;
@@ -49,7 +49,7 @@ const LikesContext_1 = require("../../contexts/LikesContext");
49
49
  const BlogPage = ({ content, posts, tags, services, getPosts, metaData, hasLikes = false, toggleLike, navigation, settings, pageCountForShowSupportButtons, isSignedInUser = false, onClickSignIn, }) => {
50
50
  const _a = (0, usePromptSignInProps_1.usePromptSignInProps)(onClickSignIn), { requireSignIn } = _a, promptSignInProps = __rest(_a, ["requireSignIn"]);
51
51
  const likes = (0, react_1.useMemo)(() => ({ toggleLike, hasLikes, isSignedInUser, requireSignIn }), [toggleLike, hasLikes, isSignedInUser, requireSignIn]);
52
- return (react_1.default.createElement("main", null,
52
+ return (react_1.default.createElement(react_1.Fragment, null,
53
53
  react_1.default.createElement(LikesContext_1.LikesContext.Provider, { value: likes },
54
54
  react_1.default.createElement(FeedContext_1.FeedContext.Provider, { value: {
55
55
  posts: posts.posts,
@@ -18,25 +18,24 @@ const BlogPostPage = ({ metaData, suggestedPosts, likes, content, post, settings
18
18
  toggleLikeCallback: likes === null || likes === void 0 ? void 0 : likes.toggleLike,
19
19
  postId: post === null || post === void 0 ? void 0 : post.blogPostId,
20
20
  });
21
- return (react_1.default.createElement("main", null,
22
- react_1.default.createElement(LikesContext_1.LikesContext.Provider, { value: {
23
- toggleLike: likes === null || likes === void 0 ? void 0 : likes.toggleLike,
24
- hasLikes: Boolean(likes),
21
+ return (react_1.default.createElement(LikesContext_1.LikesContext.Provider, { value: {
22
+ toggleLike: likes === null || likes === void 0 ? void 0 : likes.toggleLike,
23
+ hasLikes: Boolean(likes),
24
+ } },
25
+ react_1.default.createElement(PostPageContext_1.PostPageContext.Provider, { value: {
26
+ post,
27
+ suggestedPosts,
28
+ likes: likes
29
+ ? {
30
+ handleUserLike: handleLike,
31
+ hasUserLike,
32
+ likesCount,
33
+ }
34
+ : undefined,
35
+ shareOptions,
25
36
  } },
26
- react_1.default.createElement(PostPageContext_1.PostPageContext.Provider, { value: {
27
- post,
28
- suggestedPosts,
29
- likes: likes
30
- ? {
31
- handleUserLike: handleLike,
32
- hasUserLike,
33
- likesCount,
34
- }
35
- : undefined,
36
- shareOptions,
37
- } },
38
- react_1.default.createElement(page_constructor_1.PageConstructorProvider, Object.assign({}, settings),
39
- metaData ? react_1.default.createElement(MetaWrapper_1.MetaWrapper, Object.assign({}, metaData)) : null,
40
- react_1.default.createElement(page_constructor_1.PageConstructor, { content: content, custom: blocksMap_1.default, navigation: navigation }))))));
37
+ react_1.default.createElement(page_constructor_1.PageConstructorProvider, Object.assign({}, settings),
38
+ metaData ? react_1.default.createElement(MetaWrapper_1.MetaWrapper, Object.assign({}, metaData)) : null,
39
+ react_1.default.createElement(page_constructor_1.PageConstructor, { content: content, custom: blocksMap_1.default, navigation: navigation })))));
41
40
  };
42
41
  exports.BlogPostPage = BlogPostPage;