@gravity-ui/blog-constructor 11.0.1 → 11.2.0
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.
- package/build/cjs/blocks/Author/schema.d.ts +14 -3
- package/build/cjs/blocks/Author/schema.js +1 -1
- package/build/cjs/blocks/Author/schema.js.map +1 -1
- package/build/cjs/blocks/Banner/Banner.js +5 -2
- package/build/cjs/blocks/Banner/Banner.js.map +1 -1
- package/build/cjs/blocks/Banner/schema.d.ts +89 -13
- package/build/cjs/blocks/CTA/schema.d.ts +89 -13
- package/build/cjs/blocks/CTA/schema.js +1 -1
- package/build/cjs/blocks/CTA/schema.js.map +1 -1
- package/build/cjs/blocks/ColoredText/ColoredText.js +4 -1
- package/build/cjs/blocks/ColoredText/ColoredText.js.map +1 -1
- package/build/cjs/blocks/ColoredText/schema.d.ts +124 -29
- package/build/cjs/blocks/ColoredText/schema.js +4 -4
- package/build/cjs/blocks/ColoredText/schema.js.map +1 -1
- package/build/cjs/blocks/CompactMedia/schema.d.ts +13 -6
- package/build/cjs/blocks/Feed/schema.d.ts +11 -2
- package/build/cjs/blocks/Form/schema.d.ts +69 -38
- package/build/cjs/blocks/Form/schema.js +5 -22
- package/build/cjs/blocks/Form/schema.js.map +1 -1
- package/build/cjs/blocks/Header/schema.d.ts +164 -73
- package/build/cjs/blocks/Header/schema.js +3 -1
- package/build/cjs/blocks/Header/schema.js.map +1 -1
- package/build/cjs/blocks/Layout/schema.d.ts +11 -2
- package/build/cjs/blocks/Media/schema.d.ts +13 -6
- package/build/cjs/blocks/Meta/schema.d.ts +11 -2
- package/build/cjs/blocks/SideCardList/schema.d.ts +69 -6
- package/build/cjs/blocks/SideCardList/schema.js +16 -19
- package/build/cjs/blocks/SideCardList/schema.js.map +1 -1
- package/build/cjs/blocks/Suggest/schema.d.ts +11 -2
- package/build/cjs/blocks/Take/schema.d.ts +25 -2
- package/build/cjs/blocks/Take/schema.js +2 -2
- package/build/cjs/blocks/Take/schema.js.map +1 -1
- package/build/cjs/blocks/YFM/schema.d.ts +11 -2
- package/build/cjs/constructor/blocksMap.d.ts +9 -9
- package/build/cjs/constructor/blocksMap.js +9 -9
- package/build/cjs/constructor/blocksMap.js.map +1 -1
- package/build/cjs/containers/BlogPostPage/BlogPostPage.css +9 -1
- package/build/cjs/hooks/useExtendedComponentMap.d.ts +9 -9
- package/build/cjs/models/blocks.d.ts +3 -3
- package/build/cjs/models/blocks.js.map +1 -1
- package/build/cjs/schema/blocks.d.ts +4 -2
- package/build/cjs/schema/blocks.js +4 -2
- package/build/cjs/schema/blocks.js.map +1 -1
- package/build/cjs/schema/common.d.ts +4 -0
- package/build/cjs/schema/common.js +8 -10
- package/build/cjs/schema/common.js.map +1 -1
- package/build/cjs/schema/index.d.ts +1044 -299
- package/build/cjs/schema/index.js +5 -3
- package/build/cjs/schema/index.js.map +1 -1
- package/build/cjs/utils/common.d.ts +1 -2
- package/build/esm/blocks/Author/schema.d.ts +14 -3
- package/build/esm/blocks/Author/schema.js +1 -1
- package/build/esm/blocks/Author/schema.js.map +1 -1
- package/build/esm/blocks/Banner/Banner.js +5 -2
- package/build/esm/blocks/Banner/Banner.js.map +1 -1
- package/build/esm/blocks/Banner/schema.d.ts +89 -13
- package/build/esm/blocks/CTA/schema.d.ts +89 -13
- package/build/esm/blocks/CTA/schema.js +1 -1
- package/build/esm/blocks/CTA/schema.js.map +1 -1
- package/build/esm/blocks/ColoredText/ColoredText.js +5 -2
- package/build/esm/blocks/ColoredText/ColoredText.js.map +1 -1
- package/build/esm/blocks/ColoredText/schema.d.ts +124 -29
- package/build/esm/blocks/ColoredText/schema.js +4 -4
- package/build/esm/blocks/ColoredText/schema.js.map +1 -1
- package/build/esm/blocks/CompactMedia/schema.d.ts +13 -6
- package/build/esm/blocks/Feed/schema.d.ts +11 -2
- package/build/esm/blocks/Form/schema.d.ts +69 -38
- package/build/esm/blocks/Form/schema.js +4 -21
- package/build/esm/blocks/Form/schema.js.map +1 -1
- package/build/esm/blocks/Header/schema.d.ts +164 -73
- package/build/esm/blocks/Header/schema.js +3 -1
- package/build/esm/blocks/Header/schema.js.map +1 -1
- package/build/esm/blocks/Layout/schema.d.ts +11 -2
- package/build/esm/blocks/Media/schema.d.ts +13 -6
- package/build/esm/blocks/Meta/schema.d.ts +11 -2
- package/build/esm/blocks/SideCardList/schema.d.ts +69 -6
- package/build/esm/blocks/SideCardList/schema.js +16 -19
- package/build/esm/blocks/SideCardList/schema.js.map +1 -1
- package/build/esm/blocks/Suggest/schema.d.ts +11 -2
- package/build/esm/blocks/Take/schema.d.ts +25 -2
- package/build/esm/blocks/Take/schema.js +3 -3
- package/build/esm/blocks/Take/schema.js.map +1 -1
- package/build/esm/blocks/YFM/schema.d.ts +11 -2
- package/build/esm/constructor/blocksMap.d.ts +9 -9
- package/build/esm/constructor/blocksMap.js +9 -9
- package/build/esm/constructor/blocksMap.js.map +1 -1
- package/build/esm/containers/BlogPostPage/BlogPostPage.css +9 -1
- package/build/esm/hooks/useExtendedComponentMap.d.ts +9 -9
- package/build/esm/models/blocks.d.ts +3 -3
- package/build/esm/models/blocks.js.map +1 -1
- package/build/esm/schema/blocks.d.ts +4 -2
- package/build/esm/schema/blocks.js +4 -2
- package/build/esm/schema/blocks.js.map +1 -1
- package/build/esm/schema/common.d.ts +4 -0
- package/build/esm/schema/common.js +7 -9
- package/build/esm/schema/common.js.map +1 -1
- package/build/esm/schema/index.d.ts +1044 -299
- package/build/esm/schema/index.js +5 -3
- package/build/esm/schema/index.js.map +1 -1
- package/build/esm/utils/common.d.ts +1 -2
- package/package.json +3 -3
- package/server/models/blocks.d.ts +3 -3
- package/styles/storybook/common.scss +6 -0
- package/styles/styles.css +9 -1
- package/styles/yfm.css +9 -1
|
@@ -11,32 +11,51 @@ export declare const ColoredText: {
|
|
|
11
11
|
image: {
|
|
12
12
|
oneOf: ({
|
|
13
13
|
type: string;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
|
-
} | {
|
|
20
|
-
type: string;
|
|
21
|
-
pattern: string;
|
|
14
|
+
additionalProperties: boolean;
|
|
15
|
+
required: import("@gravity-ui/page-constructor").Theme[];
|
|
16
|
+
properties: {};
|
|
22
17
|
optionName: string;
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
type: string;
|
|
26
|
-
items: {
|
|
18
|
+
} | ({
|
|
19
|
+
oneOf: ({
|
|
27
20
|
type: string;
|
|
28
21
|
properties: {
|
|
29
22
|
when: {
|
|
30
23
|
type: string;
|
|
31
24
|
};
|
|
32
25
|
};
|
|
33
|
-
}
|
|
26
|
+
} | {
|
|
27
|
+
optionName: string;
|
|
28
|
+
type: string;
|
|
29
|
+
pattern: string;
|
|
30
|
+
items?: undefined;
|
|
31
|
+
} | {
|
|
32
|
+
type: string;
|
|
33
|
+
items: {
|
|
34
|
+
type: string;
|
|
35
|
+
properties: {
|
|
36
|
+
when: {
|
|
37
|
+
type: string;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
optionName: string;
|
|
42
|
+
})[];
|
|
43
|
+
} & {
|
|
34
44
|
optionName: string;
|
|
35
|
-
|
|
36
|
-
})[];
|
|
45
|
+
}))[];
|
|
37
46
|
};
|
|
38
47
|
color: {
|
|
39
|
-
|
|
48
|
+
oneOf: ({
|
|
49
|
+
type: string;
|
|
50
|
+
additionalProperties: boolean;
|
|
51
|
+
required: import("@gravity-ui/page-constructor").Theme[];
|
|
52
|
+
properties: {};
|
|
53
|
+
optionName: string;
|
|
54
|
+
} | ({
|
|
55
|
+
type: string;
|
|
56
|
+
} & {
|
|
57
|
+
optionName: string;
|
|
58
|
+
}))[];
|
|
40
59
|
};
|
|
41
60
|
altText: {
|
|
42
61
|
type: string;
|
|
@@ -72,6 +91,84 @@ export declare const ColoredText: {
|
|
|
72
91
|
resetMargin: {
|
|
73
92
|
type: string;
|
|
74
93
|
};
|
|
94
|
+
analyticsEvents: {
|
|
95
|
+
anyOf: ({
|
|
96
|
+
type: string;
|
|
97
|
+
additionalProperties: {
|
|
98
|
+
type: string;
|
|
99
|
+
};
|
|
100
|
+
required: string[];
|
|
101
|
+
properties: {
|
|
102
|
+
name: {
|
|
103
|
+
type: string;
|
|
104
|
+
};
|
|
105
|
+
type: {
|
|
106
|
+
type: string;
|
|
107
|
+
};
|
|
108
|
+
counters: {
|
|
109
|
+
type: string;
|
|
110
|
+
additionalProperties: boolean;
|
|
111
|
+
required: never[];
|
|
112
|
+
properties: {
|
|
113
|
+
include: {
|
|
114
|
+
type: string;
|
|
115
|
+
items: {
|
|
116
|
+
type: string;
|
|
117
|
+
};
|
|
118
|
+
};
|
|
119
|
+
exclude: {
|
|
120
|
+
type: string;
|
|
121
|
+
items: {
|
|
122
|
+
type: string;
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
};
|
|
127
|
+
context: {
|
|
128
|
+
type: string;
|
|
129
|
+
};
|
|
130
|
+
};
|
|
131
|
+
} | {
|
|
132
|
+
type: string;
|
|
133
|
+
items: {
|
|
134
|
+
type: string;
|
|
135
|
+
additionalProperties: {
|
|
136
|
+
type: string;
|
|
137
|
+
};
|
|
138
|
+
required: string[];
|
|
139
|
+
properties: {
|
|
140
|
+
name: {
|
|
141
|
+
type: string;
|
|
142
|
+
};
|
|
143
|
+
type: {
|
|
144
|
+
type: string;
|
|
145
|
+
};
|
|
146
|
+
counters: {
|
|
147
|
+
type: string;
|
|
148
|
+
additionalProperties: boolean;
|
|
149
|
+
required: never[];
|
|
150
|
+
properties: {
|
|
151
|
+
include: {
|
|
152
|
+
type: string;
|
|
153
|
+
items: {
|
|
154
|
+
type: string;
|
|
155
|
+
};
|
|
156
|
+
};
|
|
157
|
+
exclude: {
|
|
158
|
+
type: string;
|
|
159
|
+
items: {
|
|
160
|
+
type: string;
|
|
161
|
+
};
|
|
162
|
+
};
|
|
163
|
+
};
|
|
164
|
+
};
|
|
165
|
+
context: {
|
|
166
|
+
type: string;
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
};
|
|
170
|
+
})[];
|
|
171
|
+
};
|
|
75
172
|
};
|
|
76
173
|
contentType?: undefined;
|
|
77
174
|
})[];
|
|
@@ -126,17 +223,6 @@ export declare const ColoredText: {
|
|
|
126
223
|
};
|
|
127
224
|
};
|
|
128
225
|
};
|
|
129
|
-
labels: {
|
|
130
|
-
type: string;
|
|
131
|
-
items: {
|
|
132
|
-
type: string;
|
|
133
|
-
properties: {
|
|
134
|
-
when: {
|
|
135
|
-
type: string;
|
|
136
|
-
};
|
|
137
|
-
};
|
|
138
|
-
};
|
|
139
|
-
};
|
|
140
226
|
controlPosition: {
|
|
141
227
|
type: string;
|
|
142
228
|
enum: string[];
|
|
@@ -177,8 +263,17 @@ export declare const ColoredText: {
|
|
|
177
263
|
};
|
|
178
264
|
};
|
|
179
265
|
visible: {
|
|
180
|
-
|
|
181
|
-
|
|
266
|
+
oneOf: ({
|
|
267
|
+
type: string;
|
|
268
|
+
enum: string[];
|
|
269
|
+
additionalProperties?: undefined;
|
|
270
|
+
properties?: undefined;
|
|
271
|
+
} | {
|
|
272
|
+
type: string;
|
|
273
|
+
additionalProperties: boolean;
|
|
274
|
+
properties: {};
|
|
275
|
+
enum?: undefined;
|
|
276
|
+
})[];
|
|
182
277
|
};
|
|
183
278
|
resetPaddings: {
|
|
184
279
|
type: string;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { validators } from '@gravity-ui/page-constructor';
|
|
2
2
|
import { BlockType } from "../../models/common.js";
|
|
3
3
|
import { BlogBlockBase } from "../../schema/common.js";
|
|
4
|
-
const { subBlocks: { ContentBase }, components: { ImageProps }, common: { BlockBaseProps }, } = validators;
|
|
4
|
+
const { subBlocks: { ContentBase }, components: { ImageProps }, common: { BlockBaseProps, withTheme }, } = validators;
|
|
5
5
|
const BackgroundProps = {
|
|
6
6
|
type: 'object',
|
|
7
7
|
additionalProperties: false,
|
|
8
8
|
properties: {
|
|
9
|
-
image: ImageProps,
|
|
10
|
-
color: {
|
|
9
|
+
image: withTheme(ImageProps),
|
|
10
|
+
color: withTheme({
|
|
11
11
|
type: 'string',
|
|
12
|
-
},
|
|
12
|
+
}),
|
|
13
13
|
altText: {
|
|
14
14
|
type: 'string',
|
|
15
15
|
contentType: 'text',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","sourceRoot":"../../../../src","sources":["blocks/ColoredText/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,8BAA8B,CAAC;AAExD,OAAO,EAAC,SAAS,EAAC,+BAA4B;AAC9C,OAAO,EAAC,aAAa,EAAC,+BAA4B;AAElD,MAAM,EACF,SAAS,EAAE,EAAC,WAAW,EAAC,EACxB,UAAU,EAAE,EAAC,UAAU,EAAC,EACxB,MAAM,EAAE,EAAC,cAAc,EAAC,
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"../../../../src","sources":["blocks/ColoredText/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,8BAA8B,CAAC;AAExD,OAAO,EAAC,SAAS,EAAC,+BAA4B;AAC9C,OAAO,EAAC,aAAa,EAAC,+BAA4B;AAElD,MAAM,EACF,SAAS,EAAE,EAAC,WAAW,EAAC,EACxB,UAAU,EAAE,EAAC,UAAU,EAAC,EACxB,MAAM,EAAE,EAAC,cAAc,EAAE,SAAS,EAAC,GACtC,GAAG,UAAU,CAAC;AAEf,MAAM,eAAe,GAAG;IACpB,IAAI,EAAE,QAAQ;IACd,oBAAoB,EAAE,KAAK;IAC3B,UAAU,EAAE;QACR,KAAK,EAAE,SAAS,CAAC,UAAU,CAAC;QAC5B,KAAK,EAAE,SAAS,CAAC;YACb,IAAI,EAAE,QAAQ;SACjB,CAAC;QACF,OAAO,EAAE;YACL,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,MAAM;SACtB;KACJ;CACJ,CAAC;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG;IACvB,CAAC,SAAS,CAAC,WAAW,CAAC,EAAE;QACrB,IAAI,EAAE,QAAQ;QACd,oBAAoB,EAAE,KAAK;QAC3B,QAAQ,EAAE,CAAC,MAAM,CAAC;QAClB,UAAU,8DACH,cAAc,GACd,aAAa,GACb,WAAW,KACd,UAAU,EAAE,eAAe,GAC9B;KACJ;CACJ,CAAC","sourcesContent":["import {validators} from '@gravity-ui/page-constructor';\n\nimport {BlockType} from '../../models/common';\nimport {BlogBlockBase} from '../../schema/common';\n\nconst {\n subBlocks: {ContentBase},\n components: {ImageProps},\n common: {BlockBaseProps, withTheme},\n} = validators;\n\nconst BackgroundProps = {\n type: 'object',\n additionalProperties: false,\n properties: {\n image: withTheme(ImageProps),\n color: withTheme({\n type: 'string',\n }),\n altText: {\n type: 'string',\n contentType: 'text',\n },\n },\n};\n\nexport const ColoredText = {\n [BlockType.ColoredText]: {\n type: 'object',\n additionalProperties: false,\n required: ['text'],\n properties: {\n ...BlockBaseProps,\n ...BlogBlockBase,\n ...ContentBase,\n background: BackgroundProps,\n },\n },\n};\n"]}
|
|
@@ -14,9 +14,9 @@ export declare const CompactMedia: {
|
|
|
14
14
|
};
|
|
15
15
|
};
|
|
16
16
|
} | {
|
|
17
|
+
optionName: string;
|
|
17
18
|
type: string;
|
|
18
19
|
pattern: string;
|
|
19
|
-
optionName: string;
|
|
20
20
|
items?: undefined;
|
|
21
21
|
} | {
|
|
22
22
|
type: string;
|
|
@@ -29,7 +29,6 @@ export declare const CompactMedia: {
|
|
|
29
29
|
};
|
|
30
30
|
};
|
|
31
31
|
optionName: string;
|
|
32
|
-
pattern?: undefined;
|
|
33
32
|
})[];
|
|
34
33
|
type?: undefined;
|
|
35
34
|
items?: undefined;
|
|
@@ -44,9 +43,9 @@ export declare const CompactMedia: {
|
|
|
44
43
|
};
|
|
45
44
|
};
|
|
46
45
|
} | {
|
|
46
|
+
optionName: string;
|
|
47
47
|
type: string;
|
|
48
48
|
pattern: string;
|
|
49
|
-
optionName: string;
|
|
50
49
|
items?: undefined;
|
|
51
50
|
} | {
|
|
52
51
|
type: string;
|
|
@@ -59,7 +58,6 @@ export declare const CompactMedia: {
|
|
|
59
58
|
};
|
|
60
59
|
};
|
|
61
60
|
optionName: string;
|
|
62
|
-
pattern?: undefined;
|
|
63
61
|
})[];
|
|
64
62
|
};
|
|
65
63
|
optionName: string;
|
|
@@ -105,8 +103,17 @@ export declare const CompactMedia: {
|
|
|
105
103
|
};
|
|
106
104
|
};
|
|
107
105
|
visible: {
|
|
108
|
-
|
|
109
|
-
|
|
106
|
+
oneOf: ({
|
|
107
|
+
type: string;
|
|
108
|
+
enum: string[];
|
|
109
|
+
additionalProperties?: undefined;
|
|
110
|
+
properties?: undefined;
|
|
111
|
+
} | {
|
|
112
|
+
type: string;
|
|
113
|
+
additionalProperties: boolean;
|
|
114
|
+
properties: {};
|
|
115
|
+
enum?: undefined;
|
|
116
|
+
})[];
|
|
110
117
|
};
|
|
111
118
|
resetPaddings: {
|
|
112
119
|
type: string;
|
|
@@ -27,8 +27,17 @@ export declare const Feed: {
|
|
|
27
27
|
};
|
|
28
28
|
};
|
|
29
29
|
visible: {
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
oneOf: ({
|
|
31
|
+
type: string;
|
|
32
|
+
enum: string[];
|
|
33
|
+
additionalProperties?: undefined;
|
|
34
|
+
properties?: undefined;
|
|
35
|
+
} | {
|
|
36
|
+
type: string;
|
|
37
|
+
additionalProperties: boolean;
|
|
38
|
+
properties: {};
|
|
39
|
+
enum?: undefined;
|
|
40
|
+
})[];
|
|
32
41
|
};
|
|
33
42
|
resetPaddings: {
|
|
34
43
|
type: string;
|
|
@@ -1,59 +1,81 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
"blog-
|
|
1
|
+
export declare const Form: {
|
|
2
|
+
"blog-form-block": {
|
|
3
3
|
type: string;
|
|
4
4
|
additionalProperties: boolean;
|
|
5
5
|
properties: {
|
|
6
6
|
formData: {
|
|
7
7
|
oneOf: ({
|
|
8
8
|
type: string;
|
|
9
|
-
|
|
9
|
+
additionalProperties: boolean;
|
|
10
10
|
properties: {
|
|
11
11
|
yandex: {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
12
|
+
oneOf: (({
|
|
13
|
+
type: string;
|
|
14
|
+
required: string[];
|
|
15
|
+
properties: {
|
|
16
|
+
id: {
|
|
17
|
+
type: string;
|
|
18
|
+
};
|
|
19
|
+
containerId: {
|
|
20
|
+
type: string;
|
|
21
|
+
};
|
|
22
|
+
type: {};
|
|
23
|
+
when: {
|
|
24
|
+
type: string;
|
|
25
|
+
};
|
|
24
26
|
};
|
|
25
|
-
}
|
|
27
|
+
} & {
|
|
28
|
+
optionName: string;
|
|
29
|
+
}) | {
|
|
30
|
+
type: string;
|
|
31
|
+
additionalProperties: boolean;
|
|
32
|
+
required: import("@gravity-ui/page-constructor").Theme[];
|
|
33
|
+
properties: {};
|
|
34
|
+
optionName: string;
|
|
35
|
+
})[];
|
|
26
36
|
};
|
|
27
37
|
hubspot?: undefined;
|
|
28
38
|
};
|
|
39
|
+
optionName: string;
|
|
29
40
|
} | {
|
|
30
41
|
type: string;
|
|
31
|
-
|
|
42
|
+
additionalProperties: boolean;
|
|
32
43
|
properties: {
|
|
33
44
|
hubspot: {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
45
|
+
oneOf: (({
|
|
46
|
+
type: string;
|
|
47
|
+
required: string[];
|
|
48
|
+
properties: {
|
|
49
|
+
region: {
|
|
50
|
+
type: string;
|
|
51
|
+
};
|
|
52
|
+
portalId: {
|
|
53
|
+
type: string;
|
|
54
|
+
};
|
|
55
|
+
formId: {
|
|
56
|
+
type: string;
|
|
57
|
+
};
|
|
58
|
+
formInstanceId: {
|
|
59
|
+
type: string;
|
|
60
|
+
};
|
|
61
|
+
type: {};
|
|
62
|
+
when: {
|
|
63
|
+
type: string;
|
|
64
|
+
};
|
|
52
65
|
};
|
|
53
|
-
}
|
|
66
|
+
} & {
|
|
67
|
+
optionName: string;
|
|
68
|
+
}) | {
|
|
69
|
+
type: string;
|
|
70
|
+
additionalProperties: boolean;
|
|
71
|
+
required: import("@gravity-ui/page-constructor").Theme[];
|
|
72
|
+
properties: {};
|
|
73
|
+
optionName: string;
|
|
74
|
+
})[];
|
|
54
75
|
};
|
|
55
76
|
yandex?: undefined;
|
|
56
77
|
};
|
|
78
|
+
optionName: string;
|
|
57
79
|
})[];
|
|
58
80
|
};
|
|
59
81
|
border: {
|
|
@@ -96,8 +118,17 @@ export declare const Media: {
|
|
|
96
118
|
};
|
|
97
119
|
};
|
|
98
120
|
visible: {
|
|
99
|
-
|
|
100
|
-
|
|
121
|
+
oneOf: ({
|
|
122
|
+
type: string;
|
|
123
|
+
enum: string[];
|
|
124
|
+
additionalProperties?: undefined;
|
|
125
|
+
properties?: undefined;
|
|
126
|
+
} | {
|
|
127
|
+
type: string;
|
|
128
|
+
additionalProperties: boolean;
|
|
129
|
+
properties: {};
|
|
130
|
+
enum?: undefined;
|
|
131
|
+
})[];
|
|
101
132
|
};
|
|
102
133
|
resetPaddings: {
|
|
103
134
|
type: string;
|
|
@@ -1,29 +1,12 @@
|
|
|
1
1
|
import { validators } from '@gravity-ui/page-constructor';
|
|
2
2
|
import { BlockType } from "../../models/common.js";
|
|
3
3
|
import { BlogBlockBase } from "../../schema/common.js";
|
|
4
|
-
const { common: { BlockBaseProps },
|
|
5
|
-
export const
|
|
6
|
-
[BlockType.
|
|
4
|
+
const { common: { BlockBaseProps }, blocks: { FormBlock }, } = validators;
|
|
5
|
+
export const Form = {
|
|
6
|
+
[BlockType.Form]: {
|
|
7
7
|
type: 'object',
|
|
8
8
|
additionalProperties: false,
|
|
9
|
-
properties: Object.assign(Object.assign(Object.assign({}, BlockBaseProps), BlogBlockBase), { formData: {
|
|
10
|
-
oneOf: [
|
|
11
|
-
{
|
|
12
|
-
type: 'object',
|
|
13
|
-
optionName: 'yandex',
|
|
14
|
-
properties: {
|
|
15
|
-
yandex: YandexFormProps,
|
|
16
|
-
},
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
type: 'object',
|
|
20
|
-
optionName: 'hubspot',
|
|
21
|
-
properties: {
|
|
22
|
-
hubspot: HubspotFormProps,
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
],
|
|
26
|
-
}, border: {
|
|
9
|
+
properties: Object.assign(Object.assign(Object.assign({}, BlockBaseProps), BlogBlockBase), { formData: FormBlock['form-block'].properties.formData, border: {
|
|
27
10
|
type: 'string',
|
|
28
11
|
enum: ['shadow', 'line', 'none'],
|
|
29
12
|
} }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","sourceRoot":"../../../../src","sources":["blocks/Form/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,8BAA8B,CAAC;AAExD,OAAO,EAAC,SAAS,EAAC,+BAA4B;AAC9C,OAAO,EAAC,aAAa,EAAC,+BAA4B;AAElD,MAAM,EACF,MAAM,EAAE,EAAC,cAAc,EAAC,EACxB,
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"../../../../src","sources":["blocks/Form/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,8BAA8B,CAAC;AAExD,OAAO,EAAC,SAAS,EAAC,+BAA4B;AAC9C,OAAO,EAAC,aAAa,EAAC,+BAA4B;AAElD,MAAM,EACF,MAAM,EAAE,EAAC,cAAc,EAAC,EACxB,MAAM,EAAE,EAAC,SAAS,EAAC,GACtB,GAAG,UAAU,CAAC;AAEf,MAAM,CAAC,MAAM,IAAI,GAAG;IAChB,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE;QACd,IAAI,EAAE,QAAQ;QACd,oBAAoB,EAAE,KAAK;QAC3B,UAAU,gDACH,cAAc,GACd,aAAa,KAChB,QAAQ,EAAE,SAAS,CAAC,YAAY,CAAC,CAAC,UAAU,CAAC,QAAQ,EACrD,MAAM,EAAE;gBACJ,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,CAAC;aACnC,GACJ;KACJ;CACJ,CAAC","sourcesContent":["import {validators} from '@gravity-ui/page-constructor';\n\nimport {BlockType} from '../../models/common';\nimport {BlogBlockBase} from '../../schema/common';\n\nconst {\n common: {BlockBaseProps},\n blocks: {FormBlock},\n} = validators;\n\nexport const Form = {\n [BlockType.Form]: {\n type: 'object',\n additionalProperties: false,\n properties: {\n ...BlockBaseProps,\n ...BlogBlockBase,\n formData: FormBlock['form-block'].properties.formData,\n border: {\n type: 'string',\n enum: ['shadow', 'line', 'none'],\n },\n },\n },\n};\n"]}
|