@gravity-ui/page-constructor 3.4.0 → 3.5.0-alpha.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.
Files changed (270) hide show
  1. package/CHANGELOG.md +0 -27
  2. package/README.md +0 -2
  3. package/build/cjs/blocks/Banner/schema.d.ts +21 -63
  4. package/build/cjs/blocks/CardLayout/schema.d.ts +4 -10
  5. package/build/cjs/blocks/Companies/schema.d.ts +2 -5
  6. package/build/cjs/blocks/ContentLayout/ContentLayout.js +2 -3
  7. package/build/cjs/blocks/ContentLayout/schema.d.ts +61 -107
  8. package/build/cjs/blocks/ContentLayout/schema.js +18 -23
  9. package/build/cjs/blocks/ExtendedFeatures/schema.d.ts +4 -31
  10. package/build/cjs/blocks/ExtendedFeatures/schema.js +3 -2
  11. package/build/cjs/blocks/FilterBlock/schema.d.ts +5 -13
  12. package/build/cjs/blocks/FilterBlock/schema.js +2 -13
  13. package/build/cjs/blocks/Header/Header.css +7 -6
  14. package/build/cjs/blocks/Header/schema.d.ts +36 -92
  15. package/build/cjs/blocks/Header/schema.js +0 -1
  16. package/build/cjs/blocks/HeaderSlider/schema.d.ts +53 -48
  17. package/build/cjs/blocks/HeaderSlider/schema.js +1 -3
  18. package/build/cjs/blocks/Icons/schema.d.ts +1 -3
  19. package/build/cjs/blocks/Icons/schema.js +1 -2
  20. package/build/cjs/blocks/Info/schema.d.ts +8 -19
  21. package/build/cjs/blocks/Map/schema.d.ts +6 -17
  22. package/build/cjs/blocks/Media/schema.d.ts +152 -204
  23. package/build/cjs/blocks/Media/schema.js +1 -1
  24. package/build/cjs/blocks/PromoFeaturesBlock/schema.d.ts +8 -22
  25. package/build/cjs/blocks/PromoFeaturesBlock/schema.js +0 -1
  26. package/build/cjs/blocks/Questions/schema.d.ts +3 -7
  27. package/build/cjs/blocks/Slider/schema.d.ts +18 -13
  28. package/build/cjs/blocks/Slider/schema.js +5 -4
  29. package/build/cjs/blocks/Table/schema.d.ts +2 -5
  30. package/build/cjs/blocks/Table/schema.js +2 -12
  31. package/build/cjs/blocks/Tabs/schema.d.ts +16 -43
  32. package/build/cjs/components/BlockBase/BlockBase.js +2 -2
  33. package/build/cjs/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +1 -1
  34. package/build/cjs/components/Image/schema.d.ts +0 -1
  35. package/build/cjs/components/Image/schema.js +2 -3
  36. package/build/cjs/containers/PageConstructor/components/ConstructorBlock/ConstructorBlock.js +1 -1
  37. package/build/cjs/containers/PageConstructor/components/ConstructorItem/ConstructorItem.js +1 -1
  38. package/build/cjs/customization/BlockDecoration.d.ts +1 -1
  39. package/build/cjs/customization/BlockDecoration.js +6 -5
  40. package/build/cjs/editor/{components → Components}/AddBlock/AddBlock.css +1 -1
  41. package/build/cjs/editor/Components/AddBlock/AddBlock.d.ts +7 -0
  42. package/build/cjs/editor/{components → Components}/AddBlock/AddBlock.js +2 -2
  43. package/build/cjs/editor/Components/EditBlock/EditBlock.d.ts +4 -0
  44. package/build/cjs/editor/Components/EditBlock/EditBlock.js +32 -0
  45. package/build/cjs/editor/Containers/Editor.d.ts +2 -0
  46. package/build/cjs/editor/Containers/Editor.js +24 -0
  47. package/build/cjs/editor/index.d.ts +1 -1
  48. package/build/cjs/editor/index.js +1 -1
  49. package/build/cjs/editor/store/index.d.ts +11 -10
  50. package/build/cjs/editor/store/index.js +15 -66
  51. package/build/cjs/editor/store/reducer.d.ts +9 -24
  52. package/build/cjs/editor/store/reducer.js +31 -17
  53. package/build/cjs/editor/store/utils.d.ts +0 -1
  54. package/build/cjs/editor/store/utils.js +1 -3
  55. package/build/cjs/editor/types/index.d.ts +9 -15
  56. package/build/cjs/editor/types/index.js +0 -6
  57. package/build/cjs/editor/utils/index.d.ts +3 -4
  58. package/build/cjs/editor/utils/index.js +4 -6
  59. package/build/cjs/grid/Col/Col.d.ts +1 -1
  60. package/build/cjs/models/constructor-items/blocks.d.ts +8 -13
  61. package/build/cjs/models/constructor.d.ts +2 -2
  62. package/build/cjs/models/customization.d.ts +8 -3
  63. package/build/cjs/models/navigation.d.ts +0 -1
  64. package/build/cjs/navigation/components/Header/Header.css +0 -2
  65. package/build/cjs/navigation/components/Header/Header.js +4 -15
  66. package/build/cjs/navigation/schema.d.ts +0 -1
  67. package/build/cjs/schema/index.d.ts +228 -9
  68. package/build/cjs/schema/index.js +46 -8
  69. package/build/cjs/schema/validators/common.d.ts +27 -71
  70. package/build/cjs/schema/validators/common.js +17 -50
  71. package/build/cjs/sub-blocks/BackgroundCard/schema.d.ts +5 -12
  72. package/build/cjs/sub-blocks/BasicCard/schema.d.ts +3 -8
  73. package/build/cjs/sub-blocks/Content/schema.d.ts +6 -14
  74. package/build/cjs/sub-blocks/Content/schema.js +1 -9
  75. package/build/cjs/sub-blocks/LayoutItem/schema.d.ts +9 -23
  76. package/build/cjs/sub-blocks/MediaCard/schema.d.ts +6 -16
  77. package/build/cjs/sub-blocks/PriceDetailed/schema.d.ts +0 -1
  78. package/build/cjs/sub-blocks/PriceDetailed/schema.js +1 -5
  79. package/build/cjs/sub-blocks/Quote/schema.d.ts +2 -6
  80. package/build/cjs/text-transform/utils.js +6 -1
  81. package/build/esm/blocks/Banner/schema.d.ts +21 -63
  82. package/build/esm/blocks/CardLayout/schema.d.ts +4 -10
  83. package/build/esm/blocks/Companies/schema.d.ts +2 -5
  84. package/build/esm/blocks/ContentLayout/ContentLayout.js +2 -3
  85. package/build/esm/blocks/ContentLayout/schema.d.ts +61 -107
  86. package/build/esm/blocks/ContentLayout/schema.js +18 -23
  87. package/build/esm/blocks/ExtendedFeatures/schema.d.ts +4 -31
  88. package/build/esm/blocks/ExtendedFeatures/schema.js +4 -3
  89. package/build/esm/blocks/FilterBlock/schema.d.ts +5 -13
  90. package/build/esm/blocks/FilterBlock/schema.js +2 -13
  91. package/build/esm/blocks/Header/Header.css +7 -6
  92. package/build/esm/blocks/Header/schema.d.ts +36 -92
  93. package/build/esm/blocks/Header/schema.js +0 -1
  94. package/build/esm/blocks/HeaderSlider/schema.d.ts +53 -48
  95. package/build/esm/blocks/HeaderSlider/schema.js +1 -2
  96. package/build/esm/blocks/Icons/schema.d.ts +1 -3
  97. package/build/esm/blocks/Icons/schema.js +1 -2
  98. package/build/esm/blocks/Info/schema.d.ts +8 -19
  99. package/build/esm/blocks/Map/schema.d.ts +6 -17
  100. package/build/esm/blocks/Media/schema.d.ts +152 -204
  101. package/build/esm/blocks/Media/schema.js +2 -2
  102. package/build/esm/blocks/PromoFeaturesBlock/schema.d.ts +8 -22
  103. package/build/esm/blocks/PromoFeaturesBlock/schema.js +0 -1
  104. package/build/esm/blocks/Questions/schema.d.ts +3 -7
  105. package/build/esm/blocks/Slider/schema.d.ts +18 -13
  106. package/build/esm/blocks/Slider/schema.js +5 -4
  107. package/build/esm/blocks/Table/schema.d.ts +2 -5
  108. package/build/esm/blocks/Table/schema.js +2 -12
  109. package/build/esm/blocks/Tabs/schema.d.ts +16 -43
  110. package/build/esm/components/BlockBase/BlockBase.js +2 -2
  111. package/build/esm/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +1 -1
  112. package/build/esm/components/Image/schema.d.ts +0 -1
  113. package/build/esm/components/Image/schema.js +2 -3
  114. package/build/esm/containers/PageConstructor/components/ConstructorBlock/ConstructorBlock.js +1 -1
  115. package/build/esm/containers/PageConstructor/components/ConstructorItem/ConstructorItem.js +1 -1
  116. package/build/esm/customization/BlockDecoration.d.ts +1 -1
  117. package/build/esm/customization/BlockDecoration.js +6 -6
  118. package/build/esm/editor/{components → Components}/AddBlock/AddBlock.css +1 -1
  119. package/build/esm/editor/Components/AddBlock/AddBlock.d.ts +8 -0
  120. package/build/esm/editor/{components → Components}/AddBlock/AddBlock.js +2 -2
  121. package/build/esm/editor/Components/EditBlock/EditBlock.d.ts +5 -0
  122. package/build/esm/editor/Components/EditBlock/EditBlock.js +30 -0
  123. package/build/esm/editor/Containers/Editor.d.ts +2 -0
  124. package/build/esm/editor/Containers/Editor.js +20 -0
  125. package/build/esm/editor/index.d.ts +1 -1
  126. package/build/esm/editor/index.js +1 -1
  127. package/build/esm/editor/store/index.d.ts +11 -10
  128. package/build/esm/editor/store/index.js +17 -68
  129. package/build/esm/editor/store/reducer.d.ts +9 -24
  130. package/build/esm/editor/store/reducer.js +29 -15
  131. package/build/esm/editor/store/utils.d.ts +0 -1
  132. package/build/esm/editor/store/utils.js +0 -1
  133. package/build/esm/editor/types/index.d.ts +9 -15
  134. package/build/esm/editor/types/index.js +1 -5
  135. package/build/esm/editor/utils/index.d.ts +3 -4
  136. package/build/esm/editor/utils/index.js +3 -4
  137. package/build/esm/grid/Col/Col.d.ts +1 -1
  138. package/build/esm/models/constructor-items/blocks.d.ts +8 -13
  139. package/build/esm/models/constructor.d.ts +2 -2
  140. package/build/esm/models/customization.d.ts +8 -3
  141. package/build/esm/models/navigation.d.ts +0 -1
  142. package/build/esm/navigation/components/Header/Header.css +0 -2
  143. package/build/esm/navigation/components/Header/Header.js +5 -16
  144. package/build/esm/navigation/schema.d.ts +0 -1
  145. package/build/esm/schema/index.d.ts +228 -9
  146. package/build/esm/schema/index.js +42 -4
  147. package/build/esm/schema/validators/common.d.ts +27 -71
  148. package/build/esm/schema/validators/common.js +16 -49
  149. package/build/esm/sub-blocks/BackgroundCard/schema.d.ts +5 -12
  150. package/build/esm/sub-blocks/BasicCard/schema.d.ts +3 -8
  151. package/build/esm/sub-blocks/Content/schema.d.ts +6 -14
  152. package/build/esm/sub-blocks/Content/schema.js +1 -9
  153. package/build/esm/sub-blocks/LayoutItem/schema.d.ts +9 -23
  154. package/build/esm/sub-blocks/MediaCard/schema.d.ts +6 -16
  155. package/build/esm/sub-blocks/PriceDetailed/schema.d.ts +0 -1
  156. package/build/esm/sub-blocks/PriceDetailed/schema.js +1 -5
  157. package/build/esm/sub-blocks/Quote/schema.d.ts +2 -6
  158. package/build/esm/text-transform/utils.js +6 -1
  159. package/package.json +4 -5
  160. package/server/models/constructor-items/blocks.d.ts +8 -13
  161. package/server/models/constructor.d.ts +2 -2
  162. package/server/models/customization.d.ts +8 -3
  163. package/server/models/navigation.d.ts +0 -1
  164. package/server/text-transform/utils.js +6 -1
  165. package/build/cjs/editor/components/AddBlock/AddBlock.d.ts +0 -7
  166. package/build/cjs/editor/components/BlockForm/BlockForm.d.ts +0 -12
  167. package/build/cjs/editor/components/BlockForm/BlockForm.js +0 -33
  168. package/build/cjs/editor/components/ControlPanel/ControlPanel.css +0 -26
  169. package/build/cjs/editor/components/ControlPanel/ControlPanel.d.ts +0 -8
  170. package/build/cjs/editor/components/ControlPanel/ControlPanel.js +0 -24
  171. package/build/cjs/editor/components/ControlPanel/i18n/en.json +0 -3
  172. package/build/cjs/editor/components/ControlPanel/i18n/index.d.ts +0 -2
  173. package/build/cjs/editor/components/ControlPanel/i18n/index.js +0 -8
  174. package/build/cjs/editor/components/ControlPanel/i18n/ru.json +0 -3
  175. package/build/cjs/editor/components/EditBlock/EditBlock.d.ts +0 -13
  176. package/build/cjs/editor/components/EditBlock/EditBlock.js +0 -44
  177. package/build/cjs/editor/components/ErrorBoundary/ErrorBoundary.css +0 -27
  178. package/build/cjs/editor/components/ErrorBoundary/ErrorBoundary.d.ts +0 -13
  179. package/build/cjs/editor/components/ErrorBoundary/ErrorBoundary.js +0 -35
  180. package/build/cjs/editor/components/ErrorBoundary/i18n/en.json +0 -4
  181. package/build/cjs/editor/components/ErrorBoundary/i18n/index.d.ts +0 -2
  182. package/build/cjs/editor/components/ErrorBoundary/i18n/index.js +0 -8
  183. package/build/cjs/editor/components/ErrorBoundary/i18n/ru.json +0 -4
  184. package/build/cjs/editor/components/Layout/Layout.css +0 -36
  185. package/build/cjs/editor/components/Layout/Layout.d.ts +0 -16
  186. package/build/cjs/editor/components/Layout/Layout.js +0 -34
  187. package/build/cjs/editor/components/PagePropsForm/PagePropsForm.d.ts +0 -10
  188. package/build/cjs/editor/components/PagePropsForm/PagePropsForm.js +0 -17
  189. package/build/cjs/editor/containers/Editor/Editor.d.ts +0 -2
  190. package/build/cjs/editor/containers/Editor/Editor.js +0 -40
  191. package/build/cjs/editor/containers/Form/Form.css +0 -94
  192. package/build/cjs/editor/containers/Form/Form.d.ts +0 -11
  193. package/build/cjs/editor/containers/Form/Form.js +0 -47
  194. package/build/cjs/editor/containers/Form/dynamic-form-custom.css +0 -0
  195. package/build/cjs/editor/dynamic-forms-custom/components/OneOfCustom/OneOfCustom.css +0 -27
  196. package/build/cjs/editor/dynamic-forms-custom/components/OneOfCustom/OneOfCustom.d.ts +0 -19
  197. package/build/cjs/editor/dynamic-forms-custom/components/OneOfCustom/OneOfCustom.js +0 -72
  198. package/build/cjs/editor/dynamic-forms-custom/config.d.ts +0 -2
  199. package/build/cjs/editor/dynamic-forms-custom/config.js +0 -13
  200. package/build/cjs/editor/dynamic-forms-custom/hooks/useOneOf.d.ts +0 -12
  201. package/build/cjs/editor/dynamic-forms-custom/hooks/useOneOf.js +0 -75
  202. package/build/cjs/editor/dynamic-forms-custom/parser/detect.d.ts +0 -9
  203. package/build/cjs/editor/dynamic-forms-custom/parser/detect.js +0 -36
  204. package/build/cjs/editor/dynamic-forms-custom/parser/index.d.ts +0 -28
  205. package/build/cjs/editor/dynamic-forms-custom/parser/index.js +0 -188
  206. package/build/cjs/editor/dynamic-forms-custom/parser/types.d.ts +0 -29
  207. package/build/cjs/editor/dynamic-forms-custom/parser/types.js +0 -2
  208. package/build/cjs/editor/dynamic-forms-custom/parser/views.d.ts +0 -37
  209. package/build/cjs/editor/dynamic-forms-custom/parser/views.js +0 -46
  210. package/build/cjs/editor/hooks/useFormSpec.d.ts +0 -2
  211. package/build/cjs/editor/hooks/useFormSpec.js +0 -13
  212. package/build/cjs/editor/hooks/usePreviousValue.d.ts +0 -1
  213. package/build/cjs/editor/hooks/usePreviousValue.js +0 -11
  214. package/build/cjs/editor/styles/root.css +0 -5
  215. package/build/cjs/schema/constants.d.ts +0 -908
  216. package/build/cjs/schema/constants.js +0 -42
  217. package/build/esm/editor/components/AddBlock/AddBlock.d.ts +0 -8
  218. package/build/esm/editor/components/BlockForm/BlockForm.d.ts +0 -12
  219. package/build/esm/editor/components/BlockForm/BlockForm.js +0 -30
  220. package/build/esm/editor/components/ControlPanel/ControlPanel.css +0 -26
  221. package/build/esm/editor/components/ControlPanel/ControlPanel.d.ts +0 -9
  222. package/build/esm/editor/components/ControlPanel/ControlPanel.js +0 -22
  223. package/build/esm/editor/components/ControlPanel/i18n/en.json +0 -3
  224. package/build/esm/editor/components/ControlPanel/i18n/index.d.ts +0 -2
  225. package/build/esm/editor/components/ControlPanel/i18n/index.js +0 -5
  226. package/build/esm/editor/components/ControlPanel/i18n/ru.json +0 -3
  227. package/build/esm/editor/components/EditBlock/EditBlock.d.ts +0 -14
  228. package/build/esm/editor/components/EditBlock/EditBlock.js +0 -41
  229. package/build/esm/editor/components/ErrorBoundary/ErrorBoundary.css +0 -27
  230. package/build/esm/editor/components/ErrorBoundary/ErrorBoundary.d.ts +0 -14
  231. package/build/esm/editor/components/ErrorBoundary/ErrorBoundary.js +0 -31
  232. package/build/esm/editor/components/ErrorBoundary/i18n/en.json +0 -4
  233. package/build/esm/editor/components/ErrorBoundary/i18n/index.d.ts +0 -2
  234. package/build/esm/editor/components/ErrorBoundary/i18n/index.js +0 -5
  235. package/build/esm/editor/components/ErrorBoundary/i18n/ru.json +0 -4
  236. package/build/esm/editor/components/Layout/Layout.css +0 -36
  237. package/build/esm/editor/components/Layout/Layout.d.ts +0 -17
  238. package/build/esm/editor/components/Layout/Layout.js +0 -32
  239. package/build/esm/editor/components/PagePropsForm/PagePropsForm.d.ts +0 -10
  240. package/build/esm/editor/components/PagePropsForm/PagePropsForm.js +0 -13
  241. package/build/esm/editor/containers/Editor/Editor.d.ts +0 -2
  242. package/build/esm/editor/containers/Editor/Editor.js +0 -36
  243. package/build/esm/editor/containers/Form/Form.css +0 -94
  244. package/build/esm/editor/containers/Form/Form.d.ts +0 -12
  245. package/build/esm/editor/containers/Form/Form.js +0 -45
  246. package/build/esm/editor/containers/Form/dynamic-form-custom.css +0 -0
  247. package/build/esm/editor/dynamic-forms-custom/components/OneOfCustom/OneOfCustom.css +0 -27
  248. package/build/esm/editor/dynamic-forms-custom/components/OneOfCustom/OneOfCustom.d.ts +0 -20
  249. package/build/esm/editor/dynamic-forms-custom/components/OneOfCustom/OneOfCustom.js +0 -68
  250. package/build/esm/editor/dynamic-forms-custom/config.d.ts +0 -2
  251. package/build/esm/editor/dynamic-forms-custom/config.js +0 -9
  252. package/build/esm/editor/dynamic-forms-custom/hooks/useOneOf.d.ts +0 -12
  253. package/build/esm/editor/dynamic-forms-custom/hooks/useOneOf.js +0 -69
  254. package/build/esm/editor/dynamic-forms-custom/parser/detect.d.ts +0 -9
  255. package/build/esm/editor/dynamic-forms-custom/parser/detect.js +0 -32
  256. package/build/esm/editor/dynamic-forms-custom/parser/index.d.ts +0 -28
  257. package/build/esm/editor/dynamic-forms-custom/parser/index.js +0 -186
  258. package/build/esm/editor/dynamic-forms-custom/parser/types.d.ts +0 -29
  259. package/build/esm/editor/dynamic-forms-custom/parser/types.js +0 -1
  260. package/build/esm/editor/dynamic-forms-custom/parser/views.d.ts +0 -37
  261. package/build/esm/editor/dynamic-forms-custom/parser/views.js +0 -39
  262. package/build/esm/editor/hooks/useFormSpec.d.ts +0 -2
  263. package/build/esm/editor/hooks/useFormSpec.js +0 -9
  264. package/build/esm/editor/hooks/usePreviousValue.d.ts +0 -1
  265. package/build/esm/editor/hooks/usePreviousValue.js +0 -8
  266. package/build/esm/editor/styles/root.css +0 -5
  267. package/build/esm/schema/constants.d.ts +0 -908
  268. package/build/esm/schema/constants.js +0 -39
  269. /package/build/cjs/editor/{components → Components}/EditBlock/EditBlock.css +0 -0
  270. /package/build/esm/editor/{components → Components}/EditBlock/EditBlock.css +0 -0
package/CHANGELOG.md CHANGED
@@ -1,32 +1,5 @@
1
1
  # Changelog
2
2
 
3
- ## [3.4.0](https://github.com/gravity-ui/page-constructor/compare/v3.3.0...v3.4.0) (2023-06-16)
4
-
5
-
6
- ### Features
7
-
8
- * add editor mode switch ([#404](https://github.com/gravity-ui/page-constructor/issues/404)) ([118a369](https://github.com/gravity-ui/page-constructor/commit/118a3694459479c240ca9829c6194c1185cad4a4))
9
-
10
- ## [3.3.0](https://github.com/gravity-ui/page-constructor/compare/v3.2.0...v3.3.0) (2023-06-14)
11
-
12
-
13
- ### Features
14
-
15
- * add editor forms ([#393](https://github.com/gravity-ui/page-constructor/issues/393)) ([94fd2b2](https://github.com/gravity-ui/page-constructor/commit/94fd2b2f0f5a93d7e775be5c758a62aeecd56e8e))
16
-
17
-
18
- ### Bug Fixes
19
-
20
- * **Video:** fix schema validator ([#395](https://github.com/gravity-ui/page-constructor/issues/395)) ([0571d27](https://github.com/gravity-ui/page-constructor/commit/0571d277d902c59e546647d42c0620f8a4feb827))
21
-
22
- ## [3.2.0](https://github.com/gravity-ui/page-constructor/compare/v3.1.2...v3.2.0) (2023-06-13)
23
-
24
-
25
- ### Features
26
-
27
- * update header offset, remove unnecessary margins ([#369](https://github.com/gravity-ui/page-constructor/issues/369)) ([7757ec1](https://github.com/gravity-ui/page-constructor/commit/7757ec1b80b20b79c693b28cd3c47a7a44a2987f))
28
- * remove navigation's border by default if scroll top = 0. If you want this border by default, use prop `withBorder: true` im navigation config
29
-
30
3
  ## [3.1.2](https://github.com/gravity-ui/page-constructor/compare/v3.1.1...v3.1.2) (2023-06-07)
31
4
 
32
5
 
package/README.md CHANGED
@@ -184,8 +184,6 @@ Sub-blocks are components that can be used in the block `children` property. In
184
184
 
185
185
  6. In the block directory, add the `README.md` file with a description of input parameters.
186
186
  7. In the block directory add storybook demo in `__stories__` folder. All demo content for story should be placed in `data.json` at story dir. The generic `Story` must accept the type of block props, otherwise incorrect block props will be displayed in Storybook.
187
- 8. Add block data template to `src/editor/data/templates/` folder, file name should match block type
188
- 9. (optional) Add block preview icon to `src/editor/data/previews/` folder, file name should match block type
189
187
 
190
188
  ### Themes
191
189
 
@@ -11,32 +11,26 @@ export declare const BannerCardProps: {
11
11
  contentType: string;
12
12
  };
13
13
  image: {
14
- oneOf: (({
14
+ oneOf: ({
15
15
  type: string;
16
- } & {
17
- optionName: string;
18
- }) | {
16
+ } | {
19
17
  type: string;
20
18
  additionalProperties: boolean;
21
19
  required: import("../..").Theme[];
22
20
  properties: {};
23
- optionName: string;
24
21
  })[];
25
22
  };
26
23
  disableCompress: {
27
24
  type: string;
28
25
  };
29
26
  color: {
30
- oneOf: (({
27
+ oneOf: ({
31
28
  type: string;
32
- } & {
33
- optionName: string;
34
- }) | {
29
+ } | {
35
30
  type: string;
36
31
  additionalProperties: boolean;
37
32
  required: import("../..").Theme[];
38
33
  properties: {};
39
- optionName: string;
40
34
  })[];
41
35
  };
42
36
  theme: {
@@ -70,9 +64,8 @@ export declare const BannerCardProps: {
70
64
  enum: string[];
71
65
  };
72
66
  img: {
73
- oneOf: ({
67
+ anyOf: ({
74
68
  type: string;
75
- optionName: string;
76
69
  additionalProperties?: undefined;
77
70
  required?: undefined;
78
71
  properties?: undefined;
@@ -93,13 +86,11 @@ export declare const BannerCardProps: {
93
86
  contentType: string;
94
87
  };
95
88
  };
96
- optionName: string;
97
89
  })[];
98
90
  };
99
91
  metrikaGoals: {
100
- oneOf: ({
92
+ anyOf: ({
101
93
  type: string;
102
- optionName: string;
103
94
  items?: undefined;
104
95
  } | {
105
96
  type: string;
@@ -109,7 +100,6 @@ export declare const BannerCardProps: {
109
100
  required?: undefined;
110
101
  properties?: undefined;
111
102
  };
112
- optionName: string;
113
103
  } | {
114
104
  type: string;
115
105
  items: {
@@ -125,7 +115,6 @@ export declare const BannerCardProps: {
125
115
  };
126
116
  };
127
117
  };
128
- optionName: string;
129
118
  })[];
130
119
  };
131
120
  pixelEvents: {
@@ -185,8 +174,7 @@ export declare const BannerCardProps: {
185
174
  };
186
175
  };
187
176
  analyticsEvents: {
188
- oneOf: ({
189
- optionName: string;
177
+ anyOf: ({
190
178
  type: string;
191
179
  additionalProperties: {
192
180
  type: string;
@@ -222,7 +210,6 @@ export declare const BannerCardProps: {
222
210
  type: string;
223
211
  };
224
212
  };
225
- items?: undefined;
226
213
  } | {
227
214
  type: string;
228
215
  items: {
@@ -262,7 +249,6 @@ export declare const BannerCardProps: {
262
249
  };
263
250
  };
264
251
  };
265
- optionName: string;
266
252
  })[];
267
253
  };
268
254
  target: {
@@ -305,32 +291,26 @@ export declare const BannerBlock: {
305
291
  contentType: string;
306
292
  };
307
293
  image: {
308
- oneOf: (({
294
+ oneOf: ({
309
295
  type: string;
310
- } & {
311
- optionName: string;
312
- }) | {
296
+ } | {
313
297
  type: string;
314
298
  additionalProperties: boolean;
315
299
  required: import("../..").Theme[];
316
300
  properties: {};
317
- optionName: string;
318
301
  })[];
319
302
  };
320
303
  disableCompress: {
321
304
  type: string;
322
305
  };
323
306
  color: {
324
- oneOf: (({
307
+ oneOf: ({
325
308
  type: string;
326
- } & {
327
- optionName: string;
328
- }) | {
309
+ } | {
329
310
  type: string;
330
311
  additionalProperties: boolean;
331
312
  required: import("../..").Theme[];
332
313
  properties: {};
333
- optionName: string;
334
314
  })[];
335
315
  };
336
316
  theme: {
@@ -364,9 +344,8 @@ export declare const BannerBlock: {
364
344
  enum: string[];
365
345
  };
366
346
  img: {
367
- oneOf: ({
347
+ anyOf: ({
368
348
  type: string;
369
- optionName: string;
370
349
  additionalProperties?: undefined;
371
350
  required?: undefined;
372
351
  properties?: undefined;
@@ -387,13 +366,11 @@ export declare const BannerBlock: {
387
366
  contentType: string;
388
367
  };
389
368
  };
390
- optionName: string;
391
369
  })[];
392
370
  };
393
371
  metrikaGoals: {
394
- oneOf: ({
372
+ anyOf: ({
395
373
  type: string;
396
- optionName: string;
397
374
  items?: undefined;
398
375
  } | {
399
376
  type: string;
@@ -403,7 +380,6 @@ export declare const BannerBlock: {
403
380
  required?: undefined;
404
381
  properties?: undefined;
405
382
  };
406
- optionName: string;
407
383
  } | {
408
384
  type: string;
409
385
  items: {
@@ -419,7 +395,6 @@ export declare const BannerBlock: {
419
395
  };
420
396
  };
421
397
  };
422
- optionName: string;
423
398
  })[];
424
399
  };
425
400
  pixelEvents: {
@@ -479,8 +454,7 @@ export declare const BannerBlock: {
479
454
  };
480
455
  };
481
456
  analyticsEvents: {
482
- oneOf: ({
483
- optionName: string;
457
+ anyOf: ({
484
458
  type: string;
485
459
  additionalProperties: {
486
460
  type: string;
@@ -516,7 +490,6 @@ export declare const BannerBlock: {
516
490
  type: string;
517
491
  };
518
492
  };
519
- items?: undefined;
520
493
  } | {
521
494
  type: string;
522
495
  items: {
@@ -556,7 +529,6 @@ export declare const BannerBlock: {
556
529
  };
557
530
  };
558
531
  };
559
- optionName: string;
560
532
  })[];
561
533
  };
562
534
  target: {
@@ -600,32 +572,26 @@ export declare const BannerCard: {
600
572
  contentType: string;
601
573
  };
602
574
  image: {
603
- oneOf: (({
575
+ oneOf: ({
604
576
  type: string;
605
- } & {
606
- optionName: string;
607
- }) | {
577
+ } | {
608
578
  type: string;
609
579
  additionalProperties: boolean;
610
580
  required: import("../..").Theme[];
611
581
  properties: {};
612
- optionName: string;
613
582
  })[];
614
583
  };
615
584
  disableCompress: {
616
585
  type: string;
617
586
  };
618
587
  color: {
619
- oneOf: (({
588
+ oneOf: ({
620
589
  type: string;
621
- } & {
622
- optionName: string;
623
- }) | {
590
+ } | {
624
591
  type: string;
625
592
  additionalProperties: boolean;
626
593
  required: import("../..").Theme[];
627
594
  properties: {};
628
- optionName: string;
629
595
  })[];
630
596
  };
631
597
  theme: {
@@ -659,9 +625,8 @@ export declare const BannerCard: {
659
625
  enum: string[];
660
626
  };
661
627
  img: {
662
- oneOf: ({
628
+ anyOf: ({
663
629
  type: string;
664
- optionName: string;
665
630
  additionalProperties?: undefined;
666
631
  required?: undefined;
667
632
  properties?: undefined;
@@ -682,13 +647,11 @@ export declare const BannerCard: {
682
647
  contentType: string;
683
648
  };
684
649
  };
685
- optionName: string;
686
650
  })[];
687
651
  };
688
652
  metrikaGoals: {
689
- oneOf: ({
653
+ anyOf: ({
690
654
  type: string;
691
- optionName: string;
692
655
  items?: undefined;
693
656
  } | {
694
657
  type: string;
@@ -698,7 +661,6 @@ export declare const BannerCard: {
698
661
  required?: undefined;
699
662
  properties?: undefined;
700
663
  };
701
- optionName: string;
702
664
  } | {
703
665
  type: string;
704
666
  items: {
@@ -714,7 +676,6 @@ export declare const BannerCard: {
714
676
  };
715
677
  };
716
678
  };
717
- optionName: string;
718
679
  })[];
719
680
  };
720
681
  pixelEvents: {
@@ -774,8 +735,7 @@ export declare const BannerCard: {
774
735
  };
775
736
  };
776
737
  analyticsEvents: {
777
- oneOf: ({
778
- optionName: string;
738
+ anyOf: ({
779
739
  type: string;
780
740
  additionalProperties: {
781
741
  type: string;
@@ -811,7 +771,6 @@ export declare const BannerCard: {
811
771
  type: string;
812
772
  };
813
773
  };
814
- items?: undefined;
815
774
  } | {
816
775
  type: string;
817
776
  items: {
@@ -851,7 +810,6 @@ export declare const BannerCard: {
851
810
  };
852
811
  };
853
812
  };
854
- optionName: string;
855
813
  })[];
856
814
  };
857
815
  target: {
@@ -15,10 +15,6 @@ export declare const CardLayoutProps: {
15
15
  };
16
16
  title: {
17
17
  oneOf: ({
18
- type: string;
19
- optionName: string;
20
- } | {
21
- optionName: string;
22
18
  type: string;
23
19
  additionalProperties: boolean;
24
20
  required: string[];
@@ -38,12 +34,13 @@ export declare const CardLayoutProps: {
38
34
  type: string;
39
35
  };
40
36
  };
37
+ } | {
38
+ type: string;
41
39
  })[];
42
40
  };
43
41
  description: {
44
42
  type: string;
45
43
  contentType: string;
46
- inputType: string;
47
44
  };
48
45
  animated: {
49
46
  type: string;
@@ -94,10 +91,6 @@ export declare const CardLayoutBlock: {
94
91
  };
95
92
  title: {
96
93
  oneOf: ({
97
- type: string;
98
- optionName: string;
99
- } | {
100
- optionName: string;
101
94
  type: string;
102
95
  additionalProperties: boolean;
103
96
  required: string[];
@@ -117,12 +110,13 @@ export declare const CardLayoutBlock: {
117
110
  type: string;
118
111
  };
119
112
  };
113
+ } | {
114
+ type: string;
120
115
  })[];
121
116
  };
122
117
  description: {
123
118
  type: string;
124
119
  contentType: string;
125
- inputType: string;
126
120
  };
127
121
  animated: {
128
122
  type: string;
@@ -8,7 +8,7 @@ export declare const CompaniesBlock: {
8
8
  contentType: string;
9
9
  };
10
10
  images: {
11
- oneOf: (({
11
+ oneOf: ({
12
12
  type: string;
13
13
  required: string[];
14
14
  properties: {
@@ -26,14 +26,11 @@ export declare const CompaniesBlock: {
26
26
  contentType: string;
27
27
  };
28
28
  };
29
- } & {
30
- optionName: string;
31
- }) | {
29
+ } | {
32
30
  type: string;
33
31
  additionalProperties: boolean;
34
32
  required: import("../..").Theme[];
35
33
  properties: {};
36
- optionName: string;
37
34
  })[];
38
35
  };
39
36
  animated: {
@@ -31,9 +31,8 @@ function getTextWidth(size) {
31
31
  }
32
32
  const ContentLayoutBlock = (props) => {
33
33
  const isMobile = (0, react_1.useContext)(mobileContext_1.MobileContext);
34
- const { textContent, fileContent } = props;
35
- const propsSource = props.properties || props;
36
- const { size = 'l', background, centered, theme = 'default', textWidth = 'm' } = propsSource;
34
+ const { textContent, fileContent, properties: cardLayoutProperties = { size: 'l' } } = props;
35
+ const { size = 'l', background, centered, theme = 'default', textWidth = 'm', } = cardLayoutProperties;
37
36
  const colSizes = (0, react_1.useMemo)(() => getTextWidth(textWidth), [textWidth]);
38
37
  return (react_1.default.createElement("div", { className: b({ size, background: Boolean(background) }) },
39
38
  react_1.default.createElement(sub_blocks_1.Content, Object.assign({ className: b('content') }, textContent, { size: size, centered: centered, colSizes: colSizes, theme: theme })),
@@ -2,120 +2,79 @@ export declare const ContentLayoutBlock: {
2
2
  'content-layout-block': {
3
3
  additionalProperties: boolean;
4
4
  properties: {
5
- size: {
6
- type: string;
7
- enum: string[];
8
- };
9
- background: {
10
- type: string;
11
- additionalProperties: boolean;
12
- required: string[];
13
- properties: {
14
- src: {
15
- type: string; /**
16
- * @deprecated Use params on top level instead
17
- */
18
- pattern: string;
19
- };
20
- alt: {
21
- type: string;
22
- contentType: string;
23
- };
24
- disableCompress: {
25
- type: string;
26
- };
27
- };
28
- };
29
- centered: {
30
- type: string;
31
- };
32
- theme: {
33
- type: string;
34
- enum: string[];
35
- };
36
- textWidth: {
37
- type: string;
38
- enum: string[];
39
- };
40
5
  textContent: {
41
- additionalProperties: boolean;
42
- properties: {
43
- colSizes: {};
44
- centered: {
45
- type: string;
46
- };
47
- title: {
48
- oneOf: ({
6
+ content: {
7
+ additionalProperties: boolean;
8
+ properties: {
9
+ colSizes: {};
10
+ centered: {
11
+ type: string;
12
+ };
13
+ title: {
14
+ oneOf: ({
15
+ type: string;
16
+ additionalProperties: boolean;
17
+ required: string[];
18
+ properties: {
19
+ text: {
20
+ type: string;
21
+ contentType: string;
22
+ };
23
+ textSize: {
24
+ type: string;
25
+ enum: string[];
26
+ };
27
+ url: {
28
+ type: string;
29
+ };
30
+ resetMargin: {
31
+ type: string;
32
+ };
33
+ };
34
+ } | {
35
+ type: string;
36
+ contentType: string;
37
+ })[];
38
+ };
39
+ text: {
49
40
  type: string;
50
41
  contentType: string;
51
- optionName: string;
52
- } | {
53
- optionName: string;
42
+ };
43
+ additionalInfo: {
54
44
  type: string;
55
- additionalProperties: boolean;
56
- required: string[];
57
- properties: {
58
- text: {
59
- type: string;
60
- contentType: string;
61
- };
62
- textSize: {
63
- type: string;
64
- enum: string[];
65
- };
66
- url: {
67
- type: string;
68
- };
69
- resetMargin: {
70
- type: string;
71
- };
72
- };
73
- contentType?: undefined;
74
- })[];
75
- };
76
- text: {
77
- type: string;
78
- contentType: string;
79
- inputType: string;
80
- };
81
- additionalInfo: {
82
- type: string;
83
- contentType: string;
84
- };
85
- size: {
86
- type: string;
87
- enum: string[];
88
- };
89
- links: {
90
- type: string;
91
- items: {
45
+ contentType: string;
46
+ };
47
+ size: {
92
48
  type: string;
93
- properties: {
94
- when: {
95
- type: string;
49
+ enum: string[];
50
+ };
51
+ links: {
52
+ type: string;
53
+ items: {
54
+ type: string;
55
+ properties: {
56
+ when: {
57
+ type: string;
58
+ };
96
59
  };
97
60
  };
98
61
  };
99
- };
100
- buttons: {
101
- type: string;
102
- items: {
62
+ buttons: {
103
63
  type: string;
104
- properties: {
105
- when: {
106
- type: string;
64
+ items: {
65
+ type: string;
66
+ properties: {
67
+ when: {
68
+ type: string;
69
+ };
107
70
  };
108
71
  };
109
72
  };
73
+ theme: {
74
+ type: string;
75
+ enum: string[];
76
+ };
110
77
  };
111
- theme: {
112
- type: string;
113
- enum: string[]; /**
114
- * @deprecated Use params on top level instead
115
- */
116
- }; /**
117
- * @deprecated Use params on top level instead
118
- */
119
78
  };
120
79
  };
121
80
  fileContent: {
@@ -129,9 +88,6 @@ export declare const ContentLayoutBlock: {
129
88
  };
130
89
  };
131
90
  };
132
- /**
133
- * @deprecated Use params on top level instead
134
- */
135
91
  properties: {
136
92
  size: {
137
93
  type: string;
@@ -143,9 +99,7 @@ export declare const ContentLayoutBlock: {
143
99
  required: string[];
144
100
  properties: {
145
101
  src: {
146
- type: string; /**
147
- * @deprecated Use params on top level instead
148
- */
102
+ type: string;
149
103
  pattern: string;
150
104
  };
151
105
  alt: {