@gravity-ui/page-constructor 1.15.0-alpha.9 → 1.15.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.
- package/CHANGELOG.md +46 -0
- package/README.md +5 -75
- package/build/cjs/blocks/Banner/Banner.js +2 -3
- package/build/cjs/blocks/Banner/schema.d.ts +0 -243
- package/build/cjs/blocks/Banner/schema.js +1 -3
- package/build/cjs/blocks/CardLayout/schema.d.ts +0 -6
- package/build/cjs/blocks/ContentLayout/ContentLayout.js +2 -3
- package/build/cjs/blocks/ContentLayout/schema.d.ts +0 -3
- package/build/cjs/blocks/ExtendedFeatures/ExtendedFeatures.d.ts +1 -1
- package/build/cjs/blocks/ExtendedFeatures/ExtendedFeatures.js +2 -3
- package/build/cjs/blocks/ExtendedFeatures/schema.d.ts +0 -3
- package/build/cjs/blocks/Header/Header.js +5 -6
- package/build/cjs/blocks/Header/schema.d.ts +0 -3
- package/build/cjs/blocks/HeaderSlider/schema.d.ts +0 -3
- package/build/cjs/blocks/Icons/schema.d.ts +0 -6
- package/build/cjs/blocks/Info/Info.js +3 -4
- package/build/cjs/blocks/Info/schema.d.ts +0 -3
- package/build/cjs/blocks/Info/schema.js +0 -2
- package/build/cjs/blocks/LinkTable/schema.d.ts +0 -3
- package/build/cjs/blocks/Media/Media.js +2 -3
- package/build/cjs/blocks/Media/MediaContent.js +2 -3
- package/build/cjs/blocks/Media/schema.d.ts +0 -81
- package/build/cjs/blocks/Preview/MediaContent/MediaContent.d.ts +1 -2
- package/build/cjs/blocks/Preview/MediaContent/MediaContent.js +2 -3
- package/build/cjs/blocks/Preview/MediaContent/PreviewMedia.d.ts +0 -1
- package/build/cjs/blocks/Preview/MediaContent/PreviewMedia.js +2 -3
- package/build/cjs/blocks/Preview/Preview.js +2 -3
- package/build/cjs/blocks/Preview/schema.d.ts +0 -3
- package/build/cjs/blocks/Preview/schema.js +1 -3
- package/build/cjs/blocks/PromoFeaturesBlock/PromoFeaturesBlock.js +2 -3
- package/build/cjs/blocks/PromoFeaturesBlock/schema.d.ts +0 -3
- package/build/cjs/blocks/Questions/Questions.js +2 -3
- package/build/cjs/blocks/Questions/schema.d.ts +0 -3
- package/build/cjs/blocks/Security/Security.js +2 -3
- package/build/cjs/blocks/Security/schema.d.ts +0 -3
- package/build/cjs/blocks/Security/schema.js +1 -3
- package/build/cjs/blocks/Share/Share.d.ts +1 -1
- package/build/cjs/blocks/Share/Share.js +2 -10
- package/build/cjs/blocks/Simple/schema.d.ts +0 -3
- package/build/cjs/blocks/Slider/schema.d.ts +0 -3
- package/build/cjs/blocks/Table/schema.d.ts +0 -3
- package/build/cjs/blocks/Tabs/Tabs.d.ts +1 -1
- package/build/cjs/blocks/Tabs/Tabs.js +4 -5
- package/build/cjs/blocks/Tabs/schema.d.ts +0 -3
- package/build/cjs/components/BackLink/BackLink.d.ts +0 -1
- package/build/cjs/components/BackLink/BackLink.js +2 -11
- package/build/cjs/components/BackgroundMedia/BackgroundMedia.js +1 -2
- package/build/cjs/components/Button/Button.d.ts +0 -1
- package/build/cjs/components/Button/Button.js +2 -11
- package/build/cjs/components/ButtonTabs/ButtonTabs.d.ts +0 -1
- package/build/cjs/components/ButtonTabs/ButtonTabs.js +2 -11
- package/build/cjs/components/CardBase/CardBase.d.ts +0 -3
- package/build/cjs/components/CardBase/CardBase.js +1 -10
- package/build/cjs/components/FullscreenImage/FullscreenImage.js +8 -6
- package/build/cjs/components/FullscreenMedia/FullScreenMedia.css +70 -0
- package/build/cjs/components/FullscreenMedia/FullScreenMedia.d.ts +9 -0
- package/build/cjs/components/FullscreenMedia/FullScreenMedia.js +40 -0
- package/build/cjs/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +1 -10
- package/build/cjs/components/Link/Link.js +2 -11
- package/build/cjs/components/Media/Media.js +5 -7
- package/build/cjs/components/Media/Video/Video.js +3 -6
- package/build/cjs/components/MetaInfo/MetaInfo.css +13 -0
- package/build/cjs/components/MetaInfo/MetaInfo.d.ts +6 -0
- package/build/cjs/components/MetaInfo/MetaInfo.js +8 -0
- package/build/cjs/components/MetaInfo/schema.d.ts +8 -0
- package/build/cjs/components/MetaInfo/schema.js +10 -0
- package/build/cjs/components/ReactPlayer/ReactPlayer.js +3 -15
- package/build/cjs/components/VideoBlock/VideoBlock.d.ts +1 -0
- package/build/cjs/components/VideoBlock/VideoBlock.js +6 -10
- package/build/cjs/components/YandexForm/YandexForm.d.ts +0 -3
- package/build/cjs/components/YandexForm/YandexForm.js +2 -19
- package/build/cjs/components/index.d.ts +2 -0
- package/build/cjs/components/index.js +5 -1
- package/build/cjs/constructor-items.d.ts +9 -5
- package/build/cjs/constructor-items.js +4 -0
- package/build/cjs/containers/PageConstructor/PageConstructor.css +1 -0
- package/build/cjs/containers/PageConstructor/Provider.d.ts +0 -2
- package/build/cjs/containers/PageConstructor/Provider.js +1 -3
- package/build/cjs/context/metrikaContext/metrikaContext.d.ts +0 -6
- package/build/cjs/hooks/index.d.ts +0 -1
- package/build/cjs/hooks/index.js +0 -1
- package/build/cjs/hooks/useMetrika.d.ts +0 -6
- package/build/cjs/hooks/useMetrika.js +0 -8
- package/build/cjs/models/common.d.ts +0 -34
- package/build/cjs/models/common.js +1 -10
- package/build/cjs/models/constructor-items/blocks.d.ts +0 -11
- package/build/cjs/models/constructor-items/common.d.ts +2 -27
- package/build/cjs/models/constructor-items/sub-blocks.d.ts +16 -6
- package/build/cjs/models/constructor-items/sub-blocks.js +4 -0
- package/build/cjs/navigation/components/NavigationItem/NavigationItem.js +2 -3
- package/build/cjs/schema/index.js +1 -0
- package/build/cjs/schema/validators/common.d.ts +0 -171
- package/build/cjs/schema/validators/common.js +0 -12
- package/build/cjs/schema/validators/sub-blocks.d.ts +1 -0
- package/build/cjs/schema/validators/sub-blocks.js +1 -0
- package/build/cjs/sub-blocks/BackgroundCard/BackgroundCard.js +2 -3
- package/build/cjs/sub-blocks/BackgroundCard/schema.d.ts +0 -3
- package/build/cjs/sub-blocks/BackgroundCard/schema.js +0 -2
- package/build/cjs/sub-blocks/BannerCard/BannerCard.js +2 -3
- package/build/cjs/sub-blocks/BasicCard/BasicCard.js +2 -3
- package/build/cjs/sub-blocks/CardWithImage/CardWithImage.d.ts +1 -1
- package/build/cjs/sub-blocks/CardWithImage/CardWithImage.js +2 -3
- package/build/cjs/sub-blocks/Content/Content.js +3 -4
- package/build/cjs/sub-blocks/HubspotForm/HubspotForm.css +2 -2
- package/build/cjs/sub-blocks/HubspotForm/index.js +3 -18
- package/build/cjs/sub-blocks/LayoutItem/LayoutItem.css +16 -0
- package/build/cjs/sub-blocks/LayoutItem/LayoutItem.d.ts +3 -0
- package/build/cjs/sub-blocks/LayoutItem/LayoutItem.js +21 -0
- package/build/cjs/sub-blocks/LayoutItem/schema.d.ts +218 -0
- package/build/cjs/sub-blocks/LayoutItem/schema.js +18 -0
- package/build/cjs/sub-blocks/LayoutItem/utils.d.ts +15 -0
- package/build/cjs/sub-blocks/LayoutItem/utils.js +12 -0
- package/build/cjs/sub-blocks/MediaCard/MediaCard.d.ts +1 -1
- package/build/cjs/sub-blocks/MediaCard/MediaCard.js +2 -3
- package/build/cjs/sub-blocks/Quote/Quote.js +2 -9
- package/build/cjs/sub-blocks/Quote/schema.d.ts +0 -3
- package/build/cjs/sub-blocks/Quote/schema.js +1 -3
- package/build/cjs/sub-blocks/index.d.ts +1 -0
- package/build/cjs/sub-blocks/index.js +3 -1
- package/build/cjs/text-transform/blocks.js +17 -0
- package/build/cjs/utils/hubspot.d.ts +2 -1
- package/build/cjs/utils/hubspot.js +5 -1
- package/build/esm/blocks/Banner/Banner.js +2 -3
- package/build/esm/blocks/Banner/schema.d.ts +0 -243
- package/build/esm/blocks/Banner/schema.js +1 -3
- package/build/esm/blocks/CardLayout/schema.d.ts +0 -6
- package/build/esm/blocks/ContentLayout/ContentLayout.js +2 -3
- package/build/esm/blocks/ContentLayout/schema.d.ts +0 -3
- package/build/esm/blocks/ExtendedFeatures/ExtendedFeatures.d.ts +1 -1
- package/build/esm/blocks/ExtendedFeatures/ExtendedFeatures.js +2 -3
- package/build/esm/blocks/ExtendedFeatures/schema.d.ts +0 -3
- package/build/esm/blocks/Header/Header.js +5 -6
- package/build/esm/blocks/Header/schema.d.ts +0 -3
- package/build/esm/blocks/HeaderSlider/schema.d.ts +0 -3
- package/build/esm/blocks/Icons/schema.d.ts +0 -6
- package/build/esm/blocks/Info/Info.js +3 -4
- package/build/esm/blocks/Info/schema.d.ts +0 -3
- package/build/esm/blocks/Info/schema.js +0 -2
- package/build/esm/blocks/LinkTable/schema.d.ts +0 -3
- package/build/esm/blocks/Media/Media.js +2 -3
- package/build/esm/blocks/Media/MediaContent.js +2 -3
- package/build/esm/blocks/Media/schema.d.ts +0 -81
- package/build/esm/blocks/Preview/MediaContent/MediaContent.d.ts +1 -2
- package/build/esm/blocks/Preview/MediaContent/MediaContent.js +2 -3
- package/build/esm/blocks/Preview/MediaContent/PreviewMedia.d.ts +0 -1
- package/build/esm/blocks/Preview/MediaContent/PreviewMedia.js +2 -3
- package/build/esm/blocks/Preview/Preview.js +2 -3
- package/build/esm/blocks/Preview/schema.d.ts +0 -3
- package/build/esm/blocks/Preview/schema.js +1 -3
- package/build/esm/blocks/PromoFeaturesBlock/PromoFeaturesBlock.js +2 -3
- package/build/esm/blocks/PromoFeaturesBlock/schema.d.ts +0 -3
- package/build/esm/blocks/Questions/Questions.js +2 -3
- package/build/esm/blocks/Questions/schema.d.ts +0 -3
- package/build/esm/blocks/Security/Security.js +2 -3
- package/build/esm/blocks/Security/schema.d.ts +0 -3
- package/build/esm/blocks/Security/schema.js +1 -3
- package/build/esm/blocks/Share/Share.d.ts +1 -1
- package/build/esm/blocks/Share/Share.js +3 -11
- package/build/esm/blocks/Simple/schema.d.ts +0 -3
- package/build/esm/blocks/Slider/schema.d.ts +0 -3
- package/build/esm/blocks/Table/schema.d.ts +0 -3
- package/build/esm/blocks/Tabs/Tabs.d.ts +1 -1
- package/build/esm/blocks/Tabs/Tabs.js +4 -5
- package/build/esm/blocks/Tabs/schema.d.ts +0 -3
- package/build/esm/components/BackLink/BackLink.d.ts +0 -1
- package/build/esm/components/BackLink/BackLink.js +2 -11
- package/build/esm/components/BackgroundMedia/BackgroundMedia.js +1 -2
- package/build/esm/components/Button/Button.d.ts +0 -1
- package/build/esm/components/Button/Button.js +2 -11
- package/build/esm/components/ButtonTabs/ButtonTabs.d.ts +0 -1
- package/build/esm/components/ButtonTabs/ButtonTabs.js +2 -11
- package/build/esm/components/CardBase/CardBase.d.ts +0 -3
- package/build/esm/components/CardBase/CardBase.js +1 -10
- package/build/esm/components/FullscreenImage/FullscreenImage.js +9 -7
- package/build/esm/components/FullscreenMedia/FullScreenMedia.css +70 -0
- package/build/esm/components/FullscreenMedia/FullScreenMedia.d.ts +10 -0
- package/build/esm/components/FullscreenMedia/FullScreenMedia.js +38 -0
- package/build/esm/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +1 -10
- package/build/esm/components/Link/Link.js +2 -11
- package/build/esm/components/Media/Media.js +5 -7
- package/build/esm/components/Media/Video/Video.js +3 -6
- package/build/esm/components/MetaInfo/MetaInfo.css +13 -0
- package/build/esm/components/MetaInfo/MetaInfo.d.ts +7 -0
- package/build/esm/components/MetaInfo/MetaInfo.js +6 -0
- package/build/esm/components/MetaInfo/schema.d.ts +8 -0
- package/build/esm/components/MetaInfo/schema.js +8 -0
- package/build/esm/components/ReactPlayer/ReactPlayer.js +4 -16
- package/build/esm/components/VideoBlock/VideoBlock.d.ts +1 -0
- package/build/esm/components/VideoBlock/VideoBlock.js +6 -10
- package/build/esm/components/YandexForm/YandexForm.d.ts +0 -3
- package/build/esm/components/YandexForm/YandexForm.js +2 -19
- package/build/esm/components/index.d.ts +2 -0
- package/build/esm/components/index.js +2 -0
- package/build/esm/constructor-items.d.ts +9 -5
- package/build/esm/constructor-items.js +5 -1
- package/build/esm/containers/PageConstructor/PageConstructor.css +1 -0
- package/build/esm/containers/PageConstructor/Provider.d.ts +0 -2
- package/build/esm/containers/PageConstructor/Provider.js +1 -3
- package/build/esm/context/metrikaContext/metrikaContext.d.ts +0 -6
- package/build/esm/hooks/index.d.ts +0 -1
- package/build/esm/hooks/index.js +0 -1
- package/build/esm/hooks/useMetrika.d.ts +0 -6
- package/build/esm/hooks/useMetrika.js +0 -8
- package/build/esm/models/common.d.ts +0 -34
- package/build/esm/models/common.js +0 -9
- package/build/esm/models/constructor-items/blocks.d.ts +0 -11
- package/build/esm/models/constructor-items/common.d.ts +2 -27
- package/build/esm/models/constructor-items/sub-blocks.d.ts +16 -6
- package/build/esm/models/constructor-items/sub-blocks.js +4 -0
- package/build/esm/navigation/components/NavigationItem/NavigationItem.js +2 -3
- package/build/esm/schema/index.js +1 -0
- package/build/esm/schema/validators/common.d.ts +0 -171
- package/build/esm/schema/validators/common.js +0 -12
- package/build/esm/schema/validators/sub-blocks.d.ts +1 -0
- package/build/esm/schema/validators/sub-blocks.js +1 -0
- package/build/esm/sub-blocks/BackgroundCard/BackgroundCard.js +2 -3
- package/build/esm/sub-blocks/BackgroundCard/schema.d.ts +0 -3
- package/build/esm/sub-blocks/BackgroundCard/schema.js +0 -2
- package/build/esm/sub-blocks/BannerCard/BannerCard.js +2 -3
- package/build/esm/sub-blocks/BasicCard/BasicCard.js +2 -3
- package/build/esm/sub-blocks/CardWithImage/CardWithImage.d.ts +1 -1
- package/build/esm/sub-blocks/CardWithImage/CardWithImage.js +2 -3
- package/build/esm/sub-blocks/Content/Content.js +3 -4
- package/build/esm/sub-blocks/HubspotForm/HubspotForm.css +2 -2
- package/build/esm/sub-blocks/HubspotForm/index.js +4 -19
- package/build/esm/sub-blocks/LayoutItem/LayoutItem.css +16 -0
- package/build/esm/sub-blocks/LayoutItem/LayoutItem.d.ts +4 -0
- package/build/esm/sub-blocks/LayoutItem/LayoutItem.js +20 -0
- package/build/esm/sub-blocks/LayoutItem/schema.d.ts +218 -0
- package/build/esm/sub-blocks/LayoutItem/schema.js +14 -0
- package/build/esm/sub-blocks/LayoutItem/utils.d.ts +15 -0
- package/build/esm/sub-blocks/LayoutItem/utils.js +6 -0
- package/build/esm/sub-blocks/MediaCard/MediaCard.d.ts +1 -1
- package/build/esm/sub-blocks/MediaCard/MediaCard.js +2 -3
- package/build/esm/sub-blocks/Quote/Quote.js +4 -11
- package/build/esm/sub-blocks/Quote/schema.d.ts +0 -3
- package/build/esm/sub-blocks/Quote/schema.js +1 -3
- package/build/esm/sub-blocks/index.d.ts +1 -0
- package/build/esm/sub-blocks/index.js +1 -0
- package/build/esm/text-transform/blocks.js +17 -0
- package/build/esm/utils/hubspot.d.ts +2 -1
- package/build/esm/utils/hubspot.js +5 -1
- package/package.json +4 -5
- package/server/models/common.d.ts +0 -34
- package/server/models/common.js +1 -10
- package/server/models/constructor-items/blocks.d.ts +0 -11
- package/server/models/constructor-items/common.d.ts +2 -27
- package/server/models/constructor-items/sub-blocks.d.ts +16 -6
- package/server/models/constructor-items/sub-blocks.js +4 -0
- package/server/text-transform/blocks.js +17 -0
- package/server/utils/hubspot.d.ts +2 -1
- package/server/utils/hubspot.js +5 -1
- package/styles/root.scss +1 -0
- package/build/cjs/context/analyticsContext/analyticsContext.d.ts +0 -6
- package/build/cjs/context/analyticsContext/analyticsContext.js +0 -6
- package/build/cjs/context/analyticsContext/index.d.ts +0 -1
- package/build/cjs/context/analyticsContext/index.js +0 -4
- package/build/cjs/hooks/useAnalytics.d.ts +0 -2
- package/build/cjs/hooks/useAnalytics.js +0 -23
- package/build/cjs/schema/validators/event.d.ts +0 -37
- package/build/cjs/schema/validators/event.js +0 -38
- package/build/esm/context/analyticsContext/analyticsContext.d.ts +0 -6
- package/build/esm/context/analyticsContext/analyticsContext.js +0 -2
- package/build/esm/context/analyticsContext/index.d.ts +0 -1
- package/build/esm/context/analyticsContext/index.js +0 -1
- package/build/esm/hooks/useAnalytics.d.ts +0 -2
- package/build/esm/hooks/useAnalytics.js +0 -19
- package/build/esm/schema/validators/event.d.ts +0 -37
- package/build/esm/schema/validators/event.js +0 -35
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,51 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.15.1](https://github.com/gravity-ui/page-constructor/compare/v1.15.0...v1.15.1) (2023-02-10)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Bug Fixes
|
|
7
|
+
|
|
8
|
+
* change meta info tag to h4 ([#140](https://github.com/gravity-ui/page-constructor/issues/140)) ([8cd84bd](https://github.com/gravity-ui/page-constructor/commit/8cd84bd5e313b41caf240b1ff155a9698ec9c17a))
|
|
9
|
+
|
|
10
|
+
## [1.15.0](https://github.com/gravity-ui/page-constructor/compare/v1.14.4...v1.15.0) (2023-02-10)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* add handler for submit error in hubspot forms ([#135](https://github.com/gravity-ui/page-constructor/issues/135)) ([5f9b7a8](https://github.com/gravity-ui/page-constructor/commit/5f9b7a89996b0d2237d62ffccbea6d08f19a8d35))
|
|
16
|
+
|
|
17
|
+
## [1.14.4](https://github.com/gravity-ui/page-constructor/compare/v1.14.3...v1.14.4) (2023-02-10)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Bug Fixes
|
|
21
|
+
|
|
22
|
+
* changelog ([#136](https://github.com/gravity-ui/page-constructor/issues/136)) ([a07c738](https://github.com/gravity-ui/page-constructor/commit/a07c738e09898a952e63e1f0712cc9a31076cc1c))
|
|
23
|
+
|
|
24
|
+
## [1.14.3](https://github.com/gravity-ui/page-constructor/compare/v1.14.2...v1.14.3) (2023-02-10)
|
|
25
|
+
|
|
26
|
+
### Features
|
|
27
|
+
|
|
28
|
+
* LayoutItem was added and CardWithImage was deprecated ([#132](https://github.com/gravity-ui/page-constructor/issues/132))([4abebb5](https://github.com/gravity-ui/page-constructor/commit/4abebb573e12d0976d61541e2f33c17f3d25453a))
|
|
29
|
+
|
|
30
|
+
### Bug Fixes
|
|
31
|
+
|
|
32
|
+
* remove unused card types ([#130](https://github.com/gravity-ui/page-constructor/issues/130)) ([22da2fa](https://github.com/gravity-ui/page-constructor/commit/22da2fadd433e12e84cf8afd238c369cff5f2c24))
|
|
33
|
+
|
|
34
|
+
## [1.14.2](https://github.com/gravity-ui/page-constructor/compare/v1.14.1...v1.14.2) (2023-02-02)
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
### Bug Fixes
|
|
38
|
+
|
|
39
|
+
* **HubspotForm:** border-radius ([#128](https://github.com/gravity-ui/page-constructor/issues/128)) ([437344b](https://github.com/gravity-ui/page-constructor/commit/437344b510cbde11bdf6e3a3ceb914fb0818a016))
|
|
40
|
+
|
|
41
|
+
## [1.14.1](https://github.com/gravity-ui/page-constructor/compare/v1.14.0...v1.14.1) (2023-02-01)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
### Bug Fixes
|
|
45
|
+
|
|
46
|
+
* enable addons menu by default ([7772a55](https://github.com/gravity-ui/page-constructor/commit/7772a554950643d7cdbb86a8dedade6f916ae176))
|
|
47
|
+
* **Storybook:** fix links ([#123](https://github.com/gravity-ui/page-constructor/issues/123)) ([10cfe80](https://github.com/gravity-ui/page-constructor/commit/10cfe8054178bd577014dfff83033ff0c0dd9add))
|
|
48
|
+
|
|
3
49
|
## [1.14.0](https://github.com/gravity-ui/page-constructor/compare/v1.13.2...v1.14.0) (2023-01-25)
|
|
4
50
|
|
|
5
51
|
|
package/README.md
CHANGED
|
@@ -43,8 +43,7 @@ interface PageConstructorProviderProps {
|
|
|
43
43
|
isMobile?: boolean; //A flag indicating that the code is executed in mobile mode.
|
|
44
44
|
locale?: LocaleContextProps; //Info about the language and domain (used when generating and formatting links).
|
|
45
45
|
location?: Location; //API of the browser or router history, the page URL.
|
|
46
|
-
|
|
47
|
-
|
|
46
|
+
metrika?: Metrika; //Functions for sending analytics
|
|
48
47
|
ssrConfig?: SSR; //A flag indicating that the code is run on the server size.
|
|
49
48
|
theme?: 'light' | 'dark'; //Theme to render the page with.
|
|
50
49
|
}
|
|
@@ -82,17 +81,10 @@ interface SSR {
|
|
|
82
81
|
isServer?: boolean;
|
|
83
82
|
}
|
|
84
83
|
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
type AnalyticsEvent<T = {}> = T & {
|
|
91
|
-
name: string;
|
|
92
|
-
type?: string;
|
|
93
|
-
counters?: AnalyticsCounters;
|
|
94
|
-
blockName?: string;
|
|
95
|
-
};
|
|
84
|
+
interface Metrika {
|
|
85
|
+
metrika?: any;
|
|
86
|
+
pixel?: any;
|
|
87
|
+
}
|
|
96
88
|
|
|
97
89
|
interface NavigationData {
|
|
98
90
|
logo: NavigationLogo;
|
|
@@ -219,68 +211,6 @@ import {configure, Lang} from '@gravity-ui/page-constructor';
|
|
|
219
211
|
configure({lang: Lang.En});
|
|
220
212
|
```
|
|
221
213
|
|
|
222
|
-
### Analytics
|
|
223
|
-
|
|
224
|
-
#### Init
|
|
225
|
-
|
|
226
|
-
To start use any Analytics it is necessary to pass a handler to the constructor. The handler will receive `default` and `custom` event objects.
|
|
227
|
-
|
|
228
|
-
```ts
|
|
229
|
-
function sendEvents(event: AnalyticsEvent | AnalyticsEvent []) {
|
|
230
|
-
...
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
<PageConstructorProvider
|
|
234
|
-
...
|
|
235
|
-
|
|
236
|
-
analytics={{sendEvents}}
|
|
237
|
-
|
|
238
|
-
...
|
|
239
|
-
/>,
|
|
240
|
-
```
|
|
241
|
-
|
|
242
|
-
An event object has only one required option - `name`. It also has predefined fields, which serve to help manage complex logic. For example, `counter.include` can help to send event in a particular counter if several are used in a project. The handler must be created on a project side.
|
|
243
|
-
|
|
244
|
-
```ts
|
|
245
|
-
type AnalyticsCounters = {
|
|
246
|
-
include?: string[];
|
|
247
|
-
exclude?: string[];
|
|
248
|
-
};
|
|
249
|
-
|
|
250
|
-
type AnalyticsEvent<T = {}> = T & {
|
|
251
|
-
name: string;
|
|
252
|
-
type?: string;
|
|
253
|
-
counters?: AnalyticsCounters;
|
|
254
|
-
blockName?: string;
|
|
255
|
-
};
|
|
256
|
-
```
|
|
257
|
-
|
|
258
|
-
```ts
|
|
259
|
-
const isCounterAllowed = (counter: Counter, counters?: AnalyticsCounters) => {
|
|
260
|
-
if (!counters) {
|
|
261
|
-
return true;
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
if (counters.exclude?.includes(counter)) {
|
|
265
|
-
return false;
|
|
266
|
-
} else if (counters.include?.includes(counter)) {
|
|
267
|
-
return true;
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
return false;
|
|
271
|
-
};
|
|
272
|
-
|
|
273
|
-
if (isCounterAllowed(counterName, counters)) {
|
|
274
|
-
analyticsCounter.reachGoal(counterName, name, parameters);
|
|
275
|
-
}
|
|
276
|
-
```
|
|
277
|
-
|
|
278
|
-
#### Reserved types
|
|
279
|
-
|
|
280
|
-
`default` - fires on every click
|
|
281
|
-
`play` - fires on
|
|
282
|
-
`stop` - fires on
|
|
283
|
-
|
|
284
214
|
## Development
|
|
285
215
|
|
|
286
216
|
```bash
|
|
@@ -4,14 +4,13 @@ exports.BannerBlock = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
6
|
const utils_1 = require("../../utils");
|
|
7
|
-
const models_1 = require("../../models");
|
|
8
7
|
const AnimateBlock_1 = tslib_1.__importDefault(require("../../components/AnimateBlock/AnimateBlock"));
|
|
9
8
|
const sub_blocks_1 = require("../../sub-blocks");
|
|
10
9
|
const b = (0, utils_1.block)('banner-block');
|
|
11
10
|
const BannerBlock = (props) => {
|
|
12
|
-
const { animated
|
|
11
|
+
const { animated } = props, bannerProps = tslib_1.__rest(props, ["animated"]);
|
|
13
12
|
return (react_1.default.createElement(AnimateBlock_1.default, { className: b(), animate: animated },
|
|
14
|
-
react_1.default.createElement(sub_blocks_1.BannerCard, Object.assign({}, bannerProps
|
|
13
|
+
react_1.default.createElement(sub_blocks_1.BannerCard, Object.assign({}, bannerProps))));
|
|
15
14
|
};
|
|
16
15
|
exports.BannerBlock = BannerBlock;
|
|
17
16
|
exports.default = exports.BannerBlock;
|
|
@@ -173,84 +173,6 @@ export declare const BannerCardProps: {
|
|
|
173
173
|
};
|
|
174
174
|
};
|
|
175
175
|
};
|
|
176
|
-
analyticsEvents: {
|
|
177
|
-
anyOf: ({
|
|
178
|
-
type: string;
|
|
179
|
-
additionalProperties: {
|
|
180
|
-
type: string;
|
|
181
|
-
};
|
|
182
|
-
required: string[];
|
|
183
|
-
properties: {
|
|
184
|
-
name: {
|
|
185
|
-
type: string;
|
|
186
|
-
};
|
|
187
|
-
type: {
|
|
188
|
-
type: string;
|
|
189
|
-
};
|
|
190
|
-
counters: {
|
|
191
|
-
type: string;
|
|
192
|
-
additionalProperties: boolean;
|
|
193
|
-
required: never[];
|
|
194
|
-
properties: {
|
|
195
|
-
include: {
|
|
196
|
-
type: string;
|
|
197
|
-
items: {
|
|
198
|
-
type: string;
|
|
199
|
-
};
|
|
200
|
-
};
|
|
201
|
-
exclude: {
|
|
202
|
-
type: string;
|
|
203
|
-
items: {
|
|
204
|
-
type: string;
|
|
205
|
-
};
|
|
206
|
-
};
|
|
207
|
-
};
|
|
208
|
-
};
|
|
209
|
-
blockName: {
|
|
210
|
-
type: string;
|
|
211
|
-
};
|
|
212
|
-
};
|
|
213
|
-
} | {
|
|
214
|
-
type: string;
|
|
215
|
-
items: {
|
|
216
|
-
type: string;
|
|
217
|
-
additionalProperties: {
|
|
218
|
-
type: string;
|
|
219
|
-
};
|
|
220
|
-
required: string[];
|
|
221
|
-
properties: {
|
|
222
|
-
name: {
|
|
223
|
-
type: string;
|
|
224
|
-
};
|
|
225
|
-
type: {
|
|
226
|
-
type: string;
|
|
227
|
-
};
|
|
228
|
-
counters: {
|
|
229
|
-
type: string;
|
|
230
|
-
additionalProperties: boolean;
|
|
231
|
-
required: never[];
|
|
232
|
-
properties: {
|
|
233
|
-
include: {
|
|
234
|
-
type: string;
|
|
235
|
-
items: {
|
|
236
|
-
type: string;
|
|
237
|
-
};
|
|
238
|
-
};
|
|
239
|
-
exclude: {
|
|
240
|
-
type: string;
|
|
241
|
-
items: {
|
|
242
|
-
type: string;
|
|
243
|
-
};
|
|
244
|
-
};
|
|
245
|
-
};
|
|
246
|
-
};
|
|
247
|
-
blockName: {
|
|
248
|
-
type: string;
|
|
249
|
-
};
|
|
250
|
-
};
|
|
251
|
-
};
|
|
252
|
-
})[];
|
|
253
|
-
};
|
|
254
176
|
target: {
|
|
255
177
|
type: string;
|
|
256
178
|
enum: string[];
|
|
@@ -270,9 +192,6 @@ export declare const BannerCardProps: {
|
|
|
270
192
|
required: string[];
|
|
271
193
|
};
|
|
272
194
|
};
|
|
273
|
-
blockName: {
|
|
274
|
-
type: string;
|
|
275
|
-
};
|
|
276
195
|
animated: {
|
|
277
196
|
type: string;
|
|
278
197
|
};
|
|
@@ -456,84 +375,6 @@ export declare const BannerBlock: {
|
|
|
456
375
|
};
|
|
457
376
|
};
|
|
458
377
|
};
|
|
459
|
-
analyticsEvents: {
|
|
460
|
-
anyOf: ({
|
|
461
|
-
type: string;
|
|
462
|
-
additionalProperties: {
|
|
463
|
-
type: string;
|
|
464
|
-
};
|
|
465
|
-
required: string[];
|
|
466
|
-
properties: {
|
|
467
|
-
name: {
|
|
468
|
-
type: string;
|
|
469
|
-
};
|
|
470
|
-
type: {
|
|
471
|
-
type: string;
|
|
472
|
-
};
|
|
473
|
-
counters: {
|
|
474
|
-
type: string;
|
|
475
|
-
additionalProperties: boolean;
|
|
476
|
-
required: never[];
|
|
477
|
-
properties: {
|
|
478
|
-
include: {
|
|
479
|
-
type: string;
|
|
480
|
-
items: {
|
|
481
|
-
type: string;
|
|
482
|
-
};
|
|
483
|
-
};
|
|
484
|
-
exclude: {
|
|
485
|
-
type: string;
|
|
486
|
-
items: {
|
|
487
|
-
type: string;
|
|
488
|
-
};
|
|
489
|
-
};
|
|
490
|
-
};
|
|
491
|
-
};
|
|
492
|
-
blockName: {
|
|
493
|
-
type: string;
|
|
494
|
-
};
|
|
495
|
-
};
|
|
496
|
-
} | {
|
|
497
|
-
type: string;
|
|
498
|
-
items: {
|
|
499
|
-
type: string;
|
|
500
|
-
additionalProperties: {
|
|
501
|
-
type: string;
|
|
502
|
-
};
|
|
503
|
-
required: string[];
|
|
504
|
-
properties: {
|
|
505
|
-
name: {
|
|
506
|
-
type: string;
|
|
507
|
-
};
|
|
508
|
-
type: {
|
|
509
|
-
type: string;
|
|
510
|
-
};
|
|
511
|
-
counters: {
|
|
512
|
-
type: string;
|
|
513
|
-
additionalProperties: boolean;
|
|
514
|
-
required: never[];
|
|
515
|
-
properties: {
|
|
516
|
-
include: {
|
|
517
|
-
type: string;
|
|
518
|
-
items: {
|
|
519
|
-
type: string;
|
|
520
|
-
};
|
|
521
|
-
};
|
|
522
|
-
exclude: {
|
|
523
|
-
type: string;
|
|
524
|
-
items: {
|
|
525
|
-
type: string;
|
|
526
|
-
};
|
|
527
|
-
};
|
|
528
|
-
};
|
|
529
|
-
};
|
|
530
|
-
blockName: {
|
|
531
|
-
type: string;
|
|
532
|
-
};
|
|
533
|
-
};
|
|
534
|
-
};
|
|
535
|
-
})[];
|
|
536
|
-
};
|
|
537
378
|
target: {
|
|
538
379
|
type: string;
|
|
539
380
|
enum: string[];
|
|
@@ -553,9 +394,6 @@ export declare const BannerBlock: {
|
|
|
553
394
|
required: string[];
|
|
554
395
|
};
|
|
555
396
|
};
|
|
556
|
-
blockName: {
|
|
557
|
-
type: string;
|
|
558
|
-
};
|
|
559
397
|
animated: {
|
|
560
398
|
type: string;
|
|
561
399
|
};
|
|
@@ -740,84 +578,6 @@ export declare const BannerCard: {
|
|
|
740
578
|
};
|
|
741
579
|
};
|
|
742
580
|
};
|
|
743
|
-
analyticsEvents: {
|
|
744
|
-
anyOf: ({
|
|
745
|
-
type: string;
|
|
746
|
-
additionalProperties: {
|
|
747
|
-
type: string;
|
|
748
|
-
};
|
|
749
|
-
required: string[];
|
|
750
|
-
properties: {
|
|
751
|
-
name: {
|
|
752
|
-
type: string;
|
|
753
|
-
};
|
|
754
|
-
type: {
|
|
755
|
-
type: string;
|
|
756
|
-
};
|
|
757
|
-
counters: {
|
|
758
|
-
type: string;
|
|
759
|
-
additionalProperties: boolean;
|
|
760
|
-
required: never[];
|
|
761
|
-
properties: {
|
|
762
|
-
include: {
|
|
763
|
-
type: string;
|
|
764
|
-
items: {
|
|
765
|
-
type: string;
|
|
766
|
-
};
|
|
767
|
-
};
|
|
768
|
-
exclude: {
|
|
769
|
-
type: string;
|
|
770
|
-
items: {
|
|
771
|
-
type: string;
|
|
772
|
-
};
|
|
773
|
-
};
|
|
774
|
-
};
|
|
775
|
-
};
|
|
776
|
-
blockName: {
|
|
777
|
-
type: string;
|
|
778
|
-
};
|
|
779
|
-
};
|
|
780
|
-
} | {
|
|
781
|
-
type: string;
|
|
782
|
-
items: {
|
|
783
|
-
type: string;
|
|
784
|
-
additionalProperties: {
|
|
785
|
-
type: string;
|
|
786
|
-
};
|
|
787
|
-
required: string[];
|
|
788
|
-
properties: {
|
|
789
|
-
name: {
|
|
790
|
-
type: string;
|
|
791
|
-
};
|
|
792
|
-
type: {
|
|
793
|
-
type: string;
|
|
794
|
-
};
|
|
795
|
-
counters: {
|
|
796
|
-
type: string;
|
|
797
|
-
additionalProperties: boolean;
|
|
798
|
-
required: never[];
|
|
799
|
-
properties: {
|
|
800
|
-
include: {
|
|
801
|
-
type: string;
|
|
802
|
-
items: {
|
|
803
|
-
type: string;
|
|
804
|
-
};
|
|
805
|
-
};
|
|
806
|
-
exclude: {
|
|
807
|
-
type: string;
|
|
808
|
-
items: {
|
|
809
|
-
type: string;
|
|
810
|
-
};
|
|
811
|
-
};
|
|
812
|
-
};
|
|
813
|
-
};
|
|
814
|
-
blockName: {
|
|
815
|
-
type: string;
|
|
816
|
-
};
|
|
817
|
-
};
|
|
818
|
-
};
|
|
819
|
-
})[];
|
|
820
|
-
};
|
|
821
581
|
target: {
|
|
822
582
|
type: string;
|
|
823
583
|
enum: string[];
|
|
@@ -837,9 +597,6 @@ export declare const BannerCard: {
|
|
|
837
597
|
required: string[];
|
|
838
598
|
};
|
|
839
599
|
};
|
|
840
|
-
blockName: {
|
|
841
|
-
type: string;
|
|
842
|
-
};
|
|
843
600
|
animated: {
|
|
844
601
|
type: string;
|
|
845
602
|
};
|
|
@@ -20,9 +20,7 @@ exports.BannerCardProps = {
|
|
|
20
20
|
}), theme: common_1.ThemeProps, width: {
|
|
21
21
|
type: 'string',
|
|
22
22
|
enum: ['s', 'm', 'l'],
|
|
23
|
-
}, button: common_1.ButtonBlock,
|
|
24
|
-
type: 'string',
|
|
25
|
-
} }),
|
|
23
|
+
}, button: common_1.ButtonBlock }),
|
|
26
24
|
};
|
|
27
25
|
exports.BannerBlock = {
|
|
28
26
|
'banner-block': exports.BannerCardProps,
|
|
@@ -66,9 +66,6 @@ export declare const CardLayoutProps: {
|
|
|
66
66
|
resetPaddings: {
|
|
67
67
|
type: string;
|
|
68
68
|
};
|
|
69
|
-
blockName: {
|
|
70
|
-
type: string;
|
|
71
|
-
};
|
|
72
69
|
type: {};
|
|
73
70
|
when: {};
|
|
74
71
|
};
|
|
@@ -142,9 +139,6 @@ export declare const CardLayoutBlock: {
|
|
|
142
139
|
resetPaddings: {
|
|
143
140
|
type: string;
|
|
144
141
|
};
|
|
145
|
-
blockName: {
|
|
146
|
-
type: string;
|
|
147
|
-
};
|
|
148
142
|
type: {};
|
|
149
143
|
when: {};
|
|
150
144
|
};
|
|
@@ -4,7 +4,6 @@ exports.ContentLayoutBlock = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const react_1 = tslib_1.__importStar(require("react"));
|
|
6
6
|
const utils_1 = require("../../utils");
|
|
7
|
-
const models_1 = require("../../models");
|
|
8
7
|
const sub_blocks_1 = require("../../sub-blocks");
|
|
9
8
|
const components_1 = require("../../components");
|
|
10
9
|
const grid_1 = require("../../grid");
|
|
@@ -32,11 +31,11 @@ function getTextWidth(size) {
|
|
|
32
31
|
}
|
|
33
32
|
const ContentLayoutBlock = (props) => {
|
|
34
33
|
const isMobile = (0, react_1.useContext)(mobileContext_1.MobileContext);
|
|
35
|
-
const { textContent, fileContent, properties: cardLayoutProperties = { size: 'l' }
|
|
34
|
+
const { textContent, fileContent, properties: cardLayoutProperties = { size: 'l' } } = props;
|
|
36
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
|
-
react_1.default.createElement(sub_blocks_1.Content, Object.assign({ className: b('content') }, textContent, { size: size, centered: centered, colSizes: colSizes, theme: theme
|
|
38
|
+
react_1.default.createElement(sub_blocks_1.Content, Object.assign({ className: b('content') }, textContent, { size: size, centered: centered, colSizes: colSizes, theme: theme })),
|
|
40
39
|
fileContent && (react_1.default.createElement(grid_1.Col, { className: b('files', { size, centered }), reset: true, sizes: colSizes }, fileContent.map((file) => (react_1.default.createElement(components_1.FileLink, Object.assign({ className: b('file') }, file, { key: file.href, type: "horizontal", textSize: getFileTextSize(size), theme: theme })))))),
|
|
41
40
|
background && (react_1.default.createElement("div", { className: b('background') },
|
|
42
41
|
react_1.default.createElement(components_1.BackgroundImage, Object.assign({ className: b('background-item') }, background, { hide: isMobile }))))));
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ExtendedFeaturesProps } from '../../models';
|
|
2
|
-
export declare const ExtendedFeaturesBlock: ({ title, description, items, colSizes, animated,
|
|
2
|
+
export declare const ExtendedFeaturesBlock: ({ title, description, items, colSizes, animated, }: ExtendedFeaturesProps) => JSX.Element;
|
|
3
3
|
export default ExtendedFeaturesBlock;
|
|
@@ -4,7 +4,6 @@ exports.ExtendedFeaturesBlock = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const react_1 = tslib_1.__importStar(require("react"));
|
|
6
6
|
const utils_1 = require("../../utils");
|
|
7
|
-
const models_1 = require("../../models");
|
|
8
7
|
const grid_1 = require("../../grid");
|
|
9
8
|
const components_1 = require("../../components/");
|
|
10
9
|
const sub_blocks_1 = require("../../sub-blocks");
|
|
@@ -17,7 +16,7 @@ const DEFAULT_SIZES = {
|
|
|
17
16
|
sm: 6,
|
|
18
17
|
md: 4,
|
|
19
18
|
};
|
|
20
|
-
const ExtendedFeaturesBlock = ({ title, description, items, colSizes = DEFAULT_SIZES, animated,
|
|
19
|
+
const ExtendedFeaturesBlock = ({ title, description, items, colSizes = DEFAULT_SIZES, animated, }) => {
|
|
21
20
|
const { themeValue: theme } = (0, react_1.useContext)(ThemeValueContext_1.ThemeValueContext);
|
|
22
21
|
return (react_1.default.createElement(components_1.AnimateBlock, { className: b(), animate: animated },
|
|
23
22
|
react_1.default.createElement(components_1.BlockHeader, { title: title, description: description, className: b('header') }),
|
|
@@ -35,7 +34,7 @@ const ExtendedFeaturesBlock = ({ title, description, items, colSizes = DEFAULT_S
|
|
|
35
34
|
itemTitle && (react_1.default.createElement("h5", { className: b('item-title') },
|
|
36
35
|
react_1.default.createElement(components_1.HTML, null, itemTitle),
|
|
37
36
|
label && (react_1.default.createElement("div", { className: b('item-label') }, label)))),
|
|
38
|
-
react_1.default.createElement(sub_blocks_1.Content, { text: text, links: itemLinks, size: "s", colSizes: { all: 12, md: 12 }, buttons: buttons, additionalInfo: additionalInfo
|
|
37
|
+
react_1.default.createElement(sub_blocks_1.Content, { text: text, links: itemLinks, size: "s", colSizes: { all: 12, md: 12 }, buttons: buttons, additionalInfo: additionalInfo }))));
|
|
39
38
|
})))));
|
|
40
39
|
};
|
|
41
40
|
exports.ExtendedFeaturesBlock = ExtendedFeaturesBlock;
|
|
@@ -4,7 +4,6 @@ exports.HeaderBlock = void 0;
|
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const react_1 = tslib_1.__importStar(require("react"));
|
|
6
6
|
const utils_1 = require("../../utils");
|
|
7
|
-
const models_1 = require("../../models");
|
|
8
7
|
const components_1 = require("../../components");
|
|
9
8
|
const grid_1 = require("../../grid");
|
|
10
9
|
const utils_2 = require("./utils");
|
|
@@ -14,15 +13,15 @@ const HeaderBreadcrumbs_1 = tslib_1.__importDefault(require("../../components/He
|
|
|
14
13
|
const ThemeValueContext_1 = require("../../context/theme/ThemeValueContext");
|
|
15
14
|
const utils_3 = require("../../components/Media/Image/utils");
|
|
16
15
|
const b = (0, utils_1.block)('header-block');
|
|
17
|
-
const Background = ({ background, isMobile
|
|
16
|
+
const Background = ({ background, isMobile }) => {
|
|
18
17
|
const { url, image, fullWidthMedia, video, color } = background;
|
|
19
18
|
const imageObject = url ? (0, utils_3.getMediaImage)(url) : image;
|
|
20
19
|
const renderMedia = !isMobile || (typeof image === 'object' && 'mobile' in image);
|
|
21
|
-
return (react_1.default.createElement("div", { className: b('background', { media: true, 'full-width-media': fullWidthMedia }), style: { backgroundColor: color } }, renderMedia && (react_1.default.createElement(components_1.Media, Object.assign({}, background, { className: b('background-media'), imageClassName: b('image'), videoClassName: b('video'), isBackground: true, parallax: false, video: isMobile ? undefined : video, image: imageObject
|
|
20
|
+
return (react_1.default.createElement("div", { className: b('background', { media: true, 'full-width-media': fullWidthMedia }), style: { backgroundColor: color } }, renderMedia && (react_1.default.createElement(components_1.Media, Object.assign({}, background, { className: b('background-media'), imageClassName: b('image'), videoClassName: b('video'), isBackground: true, parallax: false, video: isMobile ? undefined : video, image: imageObject })))));
|
|
22
21
|
};
|
|
23
22
|
const FullWidthBackground = ({ background }) => (react_1.default.createElement("div", { className: b('background', { ['full-width']: true }), style: { backgroundColor: background === null || background === void 0 ? void 0 : background.color } }));
|
|
24
23
|
const HeaderBlock = (props) => {
|
|
25
|
-
const { title, overtitle, description, buttons, image, video, width = 'm', imageSize, offset = 'default', background, theme: textTheme = 'light', verticalOffset = 'm', className, breadcrumbs, status, children,
|
|
24
|
+
const { title, overtitle, description, buttons, image, video, width = 'm', imageSize, offset = 'default', background, theme: textTheme = 'light', verticalOffset = 'm', className, breadcrumbs, status, children, } = props;
|
|
26
25
|
const isMobile = (0, react_1.useContext)(mobileContext_1.MobileContext);
|
|
27
26
|
const { themeValue: theme } = (0, react_1.useContext)(ThemeValueContext_1.ThemeValueContext);
|
|
28
27
|
const hasRightSideImage = Boolean(image || video);
|
|
@@ -61,9 +60,9 @@ const HeaderBlock = (props) => {
|
|
|
61
60
|
react_1.default.createElement(YFMWrapper_1.default, { content: description, modifiers: { constructor: true } }))),
|
|
62
61
|
buttons && (react_1.default.createElement("div", { className: b('buttons'), "data-qa": "header-buttons" }, buttons &&
|
|
63
62
|
buttons.map((button, index) => (react_1.default.createElement(components_1.RouterLink, { href: button.url, key: index },
|
|
64
|
-
react_1.default.createElement(components_1.Button, Object.assign({ key: index, className: b('button'), size: "xl" }, button
|
|
63
|
+
react_1.default.createElement(components_1.Button, Object.assign({ key: index, className: b('button'), size: "xl" }, button))))))),
|
|
65
64
|
children))),
|
|
66
|
-
hasRightSideImage && (react_1.default.createElement(components_1.Media, { className: b('media', { [curImageSize]: true }), videoClassName: b('video'), imageClassName: b('image'), video: videoThemed, image: imageThemed
|
|
65
|
+
hasRightSideImage && (react_1.default.createElement(components_1.Media, { className: b('media', { [curImageSize]: true }), videoClassName: b('video'), imageClassName: b('image'), video: videoThemed, image: imageThemed })))))));
|
|
67
66
|
};
|
|
68
67
|
exports.HeaderBlock = HeaderBlock;
|
|
69
68
|
exports.default = exports.HeaderBlock;
|
|
@@ -54,9 +54,6 @@ export declare const IconsProps: {
|
|
|
54
54
|
resetPaddings: {
|
|
55
55
|
type: string;
|
|
56
56
|
};
|
|
57
|
-
blockName: {
|
|
58
|
-
type: string;
|
|
59
|
-
};
|
|
60
57
|
type: {};
|
|
61
58
|
when: {};
|
|
62
59
|
};
|
|
@@ -118,9 +115,6 @@ export declare const IconsBlock: {
|
|
|
118
115
|
resetPaddings: {
|
|
119
116
|
type: string;
|
|
120
117
|
};
|
|
121
|
-
blockName: {
|
|
122
|
-
type: string;
|
|
123
|
-
};
|
|
124
118
|
type: {};
|
|
125
119
|
when: {};
|
|
126
120
|
};
|