@gravity-ui/page-constructor 5.14.3 → 5.14.4-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.
- package/build/cjs/blocks/Banner/Banner.js +3 -1
- package/build/cjs/blocks/Banner/index.d.ts +3 -0
- package/build/cjs/blocks/Banner/index.js +22 -0
- package/build/cjs/blocks/CardLayout/CardLayout.css +1 -0
- package/build/cjs/blocks/CardLayout/CardLayout.js +11 -6
- package/build/cjs/blocks/CardLayout/index.d.ts +5 -0
- package/build/cjs/blocks/CardLayout/index.js +166 -0
- package/build/cjs/blocks/Companies/Companies.js +6 -4
- package/build/cjs/blocks/Companies/index.d.ts +3 -0
- package/build/cjs/blocks/Companies/index.js +18 -0
- package/build/cjs/blocks/ContentLayout/ContentLayout.js +6 -5
- package/build/cjs/blocks/ContentLayout/index.d.ts +11 -0
- package/build/cjs/blocks/ContentLayout/index.js +17 -0
- package/build/cjs/blocks/ContentLayout/schema.d.ts +1 -0
- package/build/cjs/blocks/ExtendedFeatures/ExtendedFeatures.js +22 -20
- package/build/cjs/blocks/ExtendedFeatures/index.d.ts +12 -0
- package/build/cjs/blocks/ExtendedFeatures/index.js +18 -0
- package/build/cjs/blocks/ExtendedFeatures/schema.d.ts +1 -0
- package/build/cjs/blocks/ExtendedFeatures/schema.js +1 -0
- package/build/cjs/blocks/FilterBlock/FilterBlock.js +11 -10
- package/build/cjs/blocks/FilterBlock/index.d.ts +11 -0
- package/build/cjs/blocks/FilterBlock/index.js +17 -0
- package/build/cjs/blocks/Form/index.d.ts +12 -0
- package/build/cjs/blocks/Form/index.js +18 -0
- package/build/cjs/blocks/Header/dynamic-form.d.ts +2 -0
- package/build/cjs/blocks/Header/dynamic-form.js +730 -0
- package/build/cjs/blocks/Header/index.d.ts +8 -0
- package/build/cjs/blocks/Header/index.js +14 -0
- package/build/cjs/blocks/HeaderSlider/HeaderSlider.js +3 -2
- package/build/cjs/blocks/HeaderSlider/index.d.ts +31 -0
- package/build/cjs/blocks/HeaderSlider/index.js +38 -0
- package/build/cjs/blocks/Icons/Icons.js +9 -6
- package/build/cjs/blocks/Icons/index.d.ts +13 -0
- package/build/cjs/blocks/Icons/index.js +19 -0
- package/build/cjs/blocks/Info/index.d.ts +21 -0
- package/build/cjs/blocks/Info/index.js +41 -0
- package/build/cjs/blocks/Map/index.d.ts +11 -0
- package/build/cjs/blocks/Map/index.js +17 -0
- package/build/cjs/blocks/Media/index.d.ts +14 -0
- package/build/cjs/blocks/Media/index.js +20 -0
- package/build/cjs/blocks/PromoFeaturesBlock/PromoFeaturesBlock.js +19 -16
- package/build/cjs/blocks/PromoFeaturesBlock/index.d.ts +12 -0
- package/build/cjs/blocks/PromoFeaturesBlock/index.js +18 -0
- package/build/cjs/blocks/Questions/Questions.js +12 -10
- package/build/cjs/blocks/Questions/index.d.ts +29 -0
- package/build/cjs/blocks/Questions/index.js +47 -0
- package/build/cjs/blocks/Share/Share.js +11 -10
- package/build/cjs/blocks/Share/index.d.ts +12 -0
- package/build/cjs/blocks/Share/index.js +18 -0
- package/build/cjs/blocks/Slider/Slider.js +22 -17
- package/build/cjs/blocks/Slider/dynamic-form.d.ts +3 -0
- package/build/cjs/blocks/Slider/dynamic-form.js +225 -0
- package/build/cjs/blocks/Slider/index.d.ts +8 -0
- package/build/cjs/blocks/Slider/index.js +14 -0
- package/build/cjs/blocks/Table/index.d.ts +8 -0
- package/build/cjs/blocks/Table/index.js +14 -0
- package/build/cjs/blocks/Table/schema.d.ts +1 -0
- package/build/cjs/blocks/Table/schema.js +1 -0
- package/build/cjs/blocks/Tabs/Tabs.js +9 -8
- package/build/cjs/blocks/Tabs/index.d.ts +16 -0
- package/build/cjs/blocks/Tabs/index.js +29 -0
- package/build/cjs/blocks/TestEditorBlock/TestEditorBlock.d.ts +5 -0
- package/build/cjs/blocks/TestEditorBlock/TestEditorBlock.js +12 -0
- package/build/cjs/blocks/TestEditorBlock/form.d.ts +3 -0
- package/build/cjs/blocks/TestEditorBlock/form.js +80 -0
- package/build/cjs/blocks/TestEditorBlock/index.d.ts +11 -0
- package/build/cjs/blocks/TestEditorBlock/index.js +17 -0
- package/build/cjs/components/BlockBase/BlockBase.css +8 -16
- package/build/cjs/components/Image/dynamic-form.d.ts +2 -0
- package/build/cjs/components/Image/dynamic-form.js +84 -0
- package/build/cjs/components/editor/ChildrenWrap/ChildrenWrap.css +5 -0
- package/build/cjs/components/editor/ChildrenWrap/ChildrenWrap.d.ts +6 -0
- package/build/cjs/components/editor/ChildrenWrap/ChildrenWrap.js +15 -0
- package/build/cjs/components/editor/ItemWrap/ItemWrap.css +9 -0
- package/build/cjs/components/editor/ItemWrap/ItemWrap.d.ts +6 -0
- package/build/cjs/components/editor/ItemWrap/ItemWrap.js +15 -0
- package/build/cjs/constructor-items.d.ts +18 -6
- package/build/cjs/constructor-items.js +67 -1
- package/build/cjs/containers/PageConstructor/PageConstructor.js +16 -13
- package/build/cjs/containers/PageConstructor/Provider.js +4 -0
- package/build/cjs/containers/PageConstructor/components/ConstructorBlock/ConstructorBlock.css +10 -6
- package/build/cjs/containers/PageConstructor/components/ConstructorBlock/ConstructorBlock.js +5 -2
- package/build/cjs/containers/PageConstructor/components/ConstructorBlock/hooks/useEditorBlockMouseEvents.d.ts +8 -0
- package/build/cjs/containers/PageConstructor/components/ConstructorBlock/hooks/useEditorBlockMouseEvents.js +109 -0
- package/build/cjs/containers/PageConstructor/components/ConstructorBlocks/ConstructorBlocks.js +7 -6
- package/build/cjs/containers/PageConstructor/components/ConstructorItem/ConstructorItem.d.ts +1 -1
- package/build/cjs/containers/PageConstructor/components/ConstructorItem/ConstructorItem.js +1 -1
- package/build/cjs/containers/PageConstructor/components/ConstructorLoadable/ConstructorLoadable.js +1 -1
- package/build/cjs/containers/PageConstructor/components/ConstructorRow/ConstructorRow.js +1 -3
- package/build/cjs/context/blockIdContext/blockIdContext.d.ts +2 -2
- package/build/cjs/context/blockIdContext/blockIdContext.js +1 -1
- package/build/cjs/context/editorContext/editorContext.d.ts +13 -0
- package/build/cjs/context/editorContext/editorContext.js +10 -0
- package/build/cjs/context/editorContext/editorProvider.d.ts +2 -0
- package/build/cjs/context/editorContext/editorProvider.js +20 -0
- package/build/cjs/context/editorContext/hooks/useEditorStore.d.ts +2 -0
- package/build/cjs/context/editorContext/hooks/useEditorStore.js +15 -0
- package/build/cjs/context/editorContext/index.d.ts +4 -0
- package/build/cjs/context/editorContext/index.js +7 -0
- package/build/cjs/context/editorContext/store.d.ts +24 -0
- package/build/cjs/context/editorContext/store.js +39 -0
- package/build/cjs/context/messagesContext/hooks/useMessageObserver.d.ts +4 -0
- package/build/cjs/context/messagesContext/hooks/useMessageObserver.js +16 -0
- package/build/cjs/context/messagesContext/hooks/useMessageSender.d.ts +2 -0
- package/build/cjs/context/messagesContext/hooks/useMessageSender.js +11 -0
- package/build/cjs/context/messagesContext/hooks/useMessagesStore.d.ts +2 -0
- package/build/cjs/context/messagesContext/hooks/useMessagesStore.js +15 -0
- package/build/cjs/context/messagesContext/index.d.ts +5 -0
- package/build/cjs/context/messagesContext/index.js +8 -0
- package/build/cjs/context/messagesContext/messagesContext.d.ts +14 -0
- package/build/cjs/context/messagesContext/messagesContext.js +12 -0
- package/build/cjs/context/messagesContext/messagesProvider.d.ts +2 -0
- package/build/cjs/context/messagesContext/messagesProvider.js +73 -0
- package/build/cjs/context/messagesContext/store.d.ts +25 -0
- package/build/cjs/context/messagesContext/store.js +17 -0
- package/build/cjs/context/messagesContext/types.d.ts +14 -0
- package/build/cjs/context/messagesContext/types.js +2 -0
- package/build/cjs/grid/Col/Col.d.ts +1 -1
- package/build/cjs/grid/Grid/Grid.css +2 -6
- package/build/cjs/hooks/useAnalytics.js +1 -1
- package/build/cjs/hooks/useEditorInitialize.d.ts +7 -0
- package/build/cjs/hooks/useEditorInitialize.js +90 -0
- package/build/cjs/models/constructor-items/blocks.d.ts +2 -1
- package/build/cjs/models/constructor-items/blocks.js +1 -0
- package/build/cjs/models/constructor-items/sub-blocks.d.ts +1 -1
- package/build/cjs/navigation/components/NavigationItem/NavigationItem.js +4 -1
- package/build/cjs/navigation/components/NavigationItem/components/NavigationButton/NavigationButton.js +4 -1
- package/build/cjs/navigation/containers/Layout/Layout.css +0 -1
- package/build/cjs/schema/constants.d.ts +1 -1
- package/build/cjs/schema/constants.js +2 -1
- package/build/cjs/schema/index.d.ts +227 -0
- package/build/cjs/schema/index.js +7 -3
- package/build/cjs/sub-blocks/BackgroundCard/dynamic-form.d.ts +2 -0
- package/build/cjs/sub-blocks/BackgroundCard/dynamic-form.js +81 -0
- package/build/cjs/sub-blocks/BackgroundCard/index.d.ts +3 -0
- package/build/cjs/sub-blocks/BackgroundCard/index.js +19 -0
- package/build/cjs/sub-blocks/BannerCard/BannerCard.js +4 -3
- package/build/cjs/sub-blocks/BannerCard/index.d.ts +3 -0
- package/build/cjs/sub-blocks/BannerCard/index.js +22 -0
- package/build/cjs/sub-blocks/BasicCard/index.d.ts +3 -0
- package/build/cjs/sub-blocks/BasicCard/index.js +18 -0
- package/build/cjs/sub-blocks/Content/index.d.ts +3 -0
- package/build/cjs/sub-blocks/Content/index.js +18 -0
- package/build/cjs/sub-blocks/Content/schema.d.ts +1 -0
- package/build/cjs/sub-blocks/Content/schema.js +1 -0
- package/build/cjs/sub-blocks/Divider/index.d.ts +3 -0
- package/build/cjs/sub-blocks/Divider/index.js +15 -0
- package/build/cjs/sub-blocks/ImageCard/ImageCard.js +2 -2
- package/build/cjs/sub-blocks/ImageCard/index.d.ts +3 -0
- package/build/cjs/sub-blocks/ImageCard/index.js +18 -0
- package/build/cjs/sub-blocks/LayoutItem/LayoutItem.js +1 -1
- package/build/cjs/sub-blocks/LayoutItem/form.d.ts +8 -0
- package/build/cjs/sub-blocks/LayoutItem/form.js +14 -0
- package/build/cjs/sub-blocks/LayoutItem/index.d.ts +3 -0
- package/build/cjs/sub-blocks/LayoutItem/index.js +20 -0
- package/build/cjs/sub-blocks/LayoutItem/schema.d.ts +254 -246
- package/build/cjs/sub-blocks/LayoutItem/schema.js +7 -3
- package/build/cjs/sub-blocks/MediaCard/index.d.ts +3 -0
- package/build/cjs/sub-blocks/MediaCard/index.js +20 -0
- package/build/cjs/sub-blocks/PriceCard/index.d.ts +3 -0
- package/build/cjs/sub-blocks/PriceCard/index.js +31 -0
- package/build/cjs/sub-blocks/PriceDetailed/PriceDetailed.js +1 -1
- package/build/cjs/sub-blocks/PriceDetailed/index.d.ts +4 -0
- package/build/cjs/sub-blocks/PriceDetailed/index.js +33 -0
- package/build/cjs/sub-blocks/Quote/index.d.ts +3 -0
- package/build/cjs/sub-blocks/Quote/index.js +21 -0
- package/build/cjs/types/actions/codes.d.ts +16 -0
- package/build/cjs/types/actions/codes.js +26 -0
- package/build/cjs/types/actions/index.d.ts +20 -0
- package/build/cjs/types/actions/index.js +10 -0
- package/build/cjs/types/actions/initial.d.ts +23 -0
- package/build/cjs/types/actions/initial.js +2 -0
- package/build/cjs/types/actions/insert.d.ts +19 -0
- package/build/cjs/types/actions/insert.js +2 -0
- package/build/cjs/types/actions/other.d.ts +16 -0
- package/build/cjs/types/actions/other.js +2 -0
- package/build/cjs/types/actions/overlay.d.ts +16 -0
- package/build/cjs/types/actions/overlay.js +2 -0
- package/build/cjs/types/actions/reorder.d.ts +17 -0
- package/build/cjs/types/actions/reorder.js +2 -0
- package/build/cjs/types/actions/select.d.ts +16 -0
- package/build/cjs/types/actions/select.js +2 -0
- package/build/cjs/types/dynamic-form.d.ts +92 -0
- package/build/cjs/types/dynamic-form.js +2 -0
- package/build/cjs/types/index.d.ts +14 -0
- package/build/cjs/types/index.js +2 -0
- package/build/cjs/utils/editor.d.ts +2 -0
- package/build/cjs/utils/editor.js +24 -0
- package/build/cjs/utils/form-generator.d.ts +9 -0
- package/build/cjs/utils/form-generator.js +126 -0
- package/build/cjs/utils/store.d.ts +16 -0
- package/build/cjs/utils/store.js +9 -0
- package/build/esm/blocks/Banner/Banner.js +3 -1
- package/build/esm/blocks/Banner/index.d.ts +3 -0
- package/build/esm/blocks/Banner/index.js +19 -0
- package/build/esm/blocks/CardLayout/CardLayout.css +1 -0
- package/build/esm/blocks/CardLayout/CardLayout.js +12 -7
- package/build/esm/blocks/CardLayout/index.d.ts +5 -0
- package/build/esm/blocks/CardLayout/index.js +162 -0
- package/build/esm/blocks/Companies/Companies.js +6 -4
- package/build/esm/blocks/Companies/index.d.ts +3 -0
- package/build/esm/blocks/Companies/index.js +15 -0
- package/build/esm/blocks/ContentLayout/ContentLayout.js +7 -6
- package/build/esm/blocks/ContentLayout/index.d.ts +11 -0
- package/build/esm/blocks/ContentLayout/index.js +14 -0
- package/build/esm/blocks/ContentLayout/schema.d.ts +1 -0
- package/build/esm/blocks/ExtendedFeatures/ExtendedFeatures.js +23 -21
- package/build/esm/blocks/ExtendedFeatures/index.d.ts +12 -0
- package/build/esm/blocks/ExtendedFeatures/index.js +15 -0
- package/build/esm/blocks/ExtendedFeatures/schema.d.ts +1 -0
- package/build/esm/blocks/ExtendedFeatures/schema.js +1 -0
- package/build/esm/blocks/FilterBlock/FilterBlock.js +12 -11
- package/build/esm/blocks/FilterBlock/index.d.ts +11 -0
- package/build/esm/blocks/FilterBlock/index.js +14 -0
- package/build/esm/blocks/Form/index.d.ts +12 -0
- package/build/esm/blocks/Form/index.js +15 -0
- package/build/esm/blocks/Header/dynamic-form.d.ts +2 -0
- package/build/esm/blocks/Header/dynamic-form.js +727 -0
- package/build/esm/blocks/Header/index.d.ts +8 -0
- package/build/esm/blocks/Header/index.js +11 -0
- package/build/esm/blocks/HeaderSlider/HeaderSlider.js +3 -2
- package/build/esm/blocks/HeaderSlider/index.d.ts +31 -0
- package/build/esm/blocks/HeaderSlider/index.js +35 -0
- package/build/esm/blocks/Icons/Icons.js +9 -6
- package/build/esm/blocks/Icons/index.d.ts +13 -0
- package/build/esm/blocks/Icons/index.js +16 -0
- package/build/esm/blocks/Info/index.d.ts +21 -0
- package/build/esm/blocks/Info/index.js +38 -0
- package/build/esm/blocks/Map/index.d.ts +11 -0
- package/build/esm/blocks/Map/index.js +14 -0
- package/build/esm/blocks/Media/index.d.ts +14 -0
- package/build/esm/blocks/Media/index.js +17 -0
- package/build/esm/blocks/PromoFeaturesBlock/PromoFeaturesBlock.js +19 -16
- package/build/esm/blocks/PromoFeaturesBlock/index.d.ts +12 -0
- package/build/esm/blocks/PromoFeaturesBlock/index.js +15 -0
- package/build/esm/blocks/Questions/Questions.js +13 -11
- package/build/esm/blocks/Questions/index.d.ts +29 -0
- package/build/esm/blocks/Questions/index.js +44 -0
- package/build/esm/blocks/Share/Share.js +11 -10
- package/build/esm/blocks/Share/index.d.ts +12 -0
- package/build/esm/blocks/Share/index.js +15 -0
- package/build/esm/blocks/Slider/Slider.js +22 -17
- package/build/esm/blocks/Slider/dynamic-form.d.ts +3 -0
- package/build/esm/blocks/Slider/dynamic-form.js +222 -0
- package/build/esm/blocks/Slider/index.d.ts +8 -0
- package/build/esm/blocks/Slider/index.js +11 -0
- package/build/esm/blocks/Table/index.d.ts +8 -0
- package/build/esm/blocks/Table/index.js +11 -0
- package/build/esm/blocks/Table/schema.d.ts +1 -0
- package/build/esm/blocks/Table/schema.js +1 -0
- package/build/esm/blocks/Tabs/Tabs.js +10 -9
- package/build/esm/blocks/Tabs/index.d.ts +16 -0
- package/build/esm/blocks/Tabs/index.js +26 -0
- package/build/esm/blocks/TestEditorBlock/TestEditorBlock.d.ts +5 -0
- package/build/esm/blocks/TestEditorBlock/TestEditorBlock.js +7 -0
- package/build/esm/blocks/TestEditorBlock/form.d.ts +3 -0
- package/build/esm/blocks/TestEditorBlock/form.js +78 -0
- package/build/esm/blocks/TestEditorBlock/index.d.ts +11 -0
- package/build/esm/blocks/TestEditorBlock/index.js +13 -0
- package/build/esm/components/BlockBase/BlockBase.css +8 -16
- package/build/esm/components/Image/dynamic-form.d.ts +2 -0
- package/build/esm/components/Image/dynamic-form.js +80 -0
- package/build/esm/components/editor/ChildrenWrap/ChildrenWrap.css +5 -0
- package/build/esm/components/editor/ChildrenWrap/ChildrenWrap.d.ts +7 -0
- package/build/esm/components/editor/ChildrenWrap/ChildrenWrap.js +13 -0
- package/build/esm/components/editor/ItemWrap/ItemWrap.css +9 -0
- package/build/esm/components/editor/ItemWrap/ItemWrap.d.ts +7 -0
- package/build/esm/components/editor/ItemWrap/ItemWrap.js +13 -0
- package/build/esm/constructor-items.d.ts +18 -6
- package/build/esm/constructor-items.js +66 -0
- package/build/esm/containers/PageConstructor/PageConstructor.js +19 -16
- package/build/esm/containers/PageConstructor/Provider.js +4 -0
- package/build/esm/containers/PageConstructor/components/ConstructorBlock/ConstructorBlock.css +10 -6
- package/build/esm/containers/PageConstructor/components/ConstructorBlock/ConstructorBlock.js +5 -2
- package/build/esm/containers/PageConstructor/components/ConstructorBlock/hooks/useEditorBlockMouseEvents.d.ts +8 -0
- package/build/esm/containers/PageConstructor/components/ConstructorBlock/hooks/useEditorBlockMouseEvents.js +107 -0
- package/build/esm/containers/PageConstructor/components/ConstructorBlocks/ConstructorBlocks.js +7 -6
- package/build/esm/containers/PageConstructor/components/ConstructorItem/ConstructorItem.d.ts +1 -1
- package/build/esm/containers/PageConstructor/components/ConstructorItem/ConstructorItem.js +1 -1
- package/build/esm/containers/PageConstructor/components/ConstructorLoadable/ConstructorLoadable.js +1 -1
- package/build/esm/containers/PageConstructor/components/ConstructorRow/ConstructorRow.js +1 -3
- package/build/esm/context/blockIdContext/blockIdContext.d.ts +2 -2
- package/build/esm/context/blockIdContext/blockIdContext.js +1 -1
- package/build/esm/context/editorContext/editorContext.d.ts +13 -0
- package/build/esm/context/editorContext/editorContext.js +6 -0
- package/build/esm/context/editorContext/editorProvider.d.ts +2 -0
- package/build/esm/context/editorContext/editorProvider.js +15 -0
- package/build/esm/context/editorContext/hooks/useEditorStore.d.ts +2 -0
- package/build/esm/context/editorContext/hooks/useEditorStore.js +11 -0
- package/build/esm/context/editorContext/index.d.ts +4 -0
- package/build/esm/context/editorContext/index.js +4 -0
- package/build/esm/context/editorContext/store.d.ts +24 -0
- package/build/esm/context/editorContext/store.js +36 -0
- package/build/esm/context/messagesContext/hooks/useMessageObserver.d.ts +4 -0
- package/build/esm/context/messagesContext/hooks/useMessageObserver.js +12 -0
- package/build/esm/context/messagesContext/hooks/useMessageSender.d.ts +2 -0
- package/build/esm/context/messagesContext/hooks/useMessageSender.js +7 -0
- package/build/esm/context/messagesContext/hooks/useMessagesStore.d.ts +2 -0
- package/build/esm/context/messagesContext/hooks/useMessagesStore.js +11 -0
- package/build/esm/context/messagesContext/index.d.ts +5 -0
- package/build/esm/context/messagesContext/index.js +5 -0
- package/build/esm/context/messagesContext/messagesContext.d.ts +14 -0
- package/build/esm/context/messagesContext/messagesContext.js +8 -0
- package/build/esm/context/messagesContext/messagesProvider.d.ts +2 -0
- package/build/esm/context/messagesContext/messagesProvider.js +68 -0
- package/build/esm/context/messagesContext/store.d.ts +25 -0
- package/build/esm/context/messagesContext/store.js +14 -0
- package/build/esm/context/messagesContext/types.d.ts +14 -0
- package/build/esm/context/messagesContext/types.js +1 -0
- package/build/esm/grid/Col/Col.d.ts +1 -1
- package/build/esm/grid/Grid/Grid.css +2 -6
- package/build/esm/hooks/useAnalytics.js +1 -1
- package/build/esm/hooks/useEditorInitialize.d.ts +7 -0
- package/build/esm/hooks/useEditorInitialize.js +87 -0
- package/build/esm/models/constructor-items/blocks.d.ts +2 -1
- package/build/esm/models/constructor-items/blocks.js +1 -0
- package/build/esm/models/constructor-items/sub-blocks.d.ts +1 -1
- package/build/esm/navigation/components/NavigationItem/NavigationItem.js +4 -1
- package/build/esm/navigation/components/NavigationItem/components/NavigationButton/NavigationButton.js +4 -1
- package/build/esm/navigation/containers/Layout/Layout.css +0 -1
- package/build/esm/schema/constants.d.ts +1 -1
- package/build/esm/schema/constants.js +2 -1
- package/build/esm/schema/index.d.ts +227 -0
- package/build/esm/schema/index.js +6 -2
- package/build/esm/sub-blocks/BackgroundCard/dynamic-form.d.ts +2 -0
- package/build/esm/sub-blocks/BackgroundCard/dynamic-form.js +78 -0
- package/build/esm/sub-blocks/BackgroundCard/index.d.ts +3 -0
- package/build/esm/sub-blocks/BackgroundCard/index.js +16 -0
- package/build/esm/sub-blocks/BannerCard/BannerCard.js +4 -3
- package/build/esm/sub-blocks/BannerCard/index.d.ts +3 -0
- package/build/esm/sub-blocks/BannerCard/index.js +19 -0
- package/build/esm/sub-blocks/BasicCard/index.d.ts +3 -0
- package/build/esm/sub-blocks/BasicCard/index.js +15 -0
- package/build/esm/sub-blocks/Content/index.d.ts +3 -0
- package/build/esm/sub-blocks/Content/index.js +15 -0
- package/build/esm/sub-blocks/Content/schema.d.ts +1 -0
- package/build/esm/sub-blocks/Content/schema.js +1 -0
- package/build/esm/sub-blocks/Divider/index.d.ts +3 -0
- package/build/esm/sub-blocks/Divider/index.js +12 -0
- package/build/esm/sub-blocks/ImageCard/ImageCard.js +2 -2
- package/build/esm/sub-blocks/ImageCard/index.d.ts +3 -0
- package/build/esm/sub-blocks/ImageCard/index.js +15 -0
- package/build/esm/sub-blocks/LayoutItem/LayoutItem.js +1 -1
- package/build/esm/sub-blocks/LayoutItem/form.d.ts +8 -0
- package/build/esm/sub-blocks/LayoutItem/form.js +11 -0
- package/build/esm/sub-blocks/LayoutItem/index.d.ts +3 -0
- package/build/esm/sub-blocks/LayoutItem/index.js +17 -0
- package/build/esm/sub-blocks/LayoutItem/schema.d.ts +254 -246
- package/build/esm/sub-blocks/LayoutItem/schema.js +6 -2
- package/build/esm/sub-blocks/MediaCard/index.d.ts +3 -0
- package/build/esm/sub-blocks/MediaCard/index.js +17 -0
- package/build/esm/sub-blocks/PriceCard/index.d.ts +3 -0
- package/build/esm/sub-blocks/PriceCard/index.js +28 -0
- package/build/esm/sub-blocks/PriceDetailed/PriceDetailed.js +1 -1
- package/build/esm/sub-blocks/PriceDetailed/index.d.ts +4 -0
- package/build/esm/sub-blocks/PriceDetailed/index.js +30 -0
- package/build/esm/sub-blocks/Quote/index.d.ts +3 -0
- package/build/esm/sub-blocks/Quote/index.js +18 -0
- package/build/esm/types/actions/codes.d.ts +16 -0
- package/build/esm/types/actions/codes.js +23 -0
- package/build/esm/types/actions/index.d.ts +20 -0
- package/build/esm/types/actions/index.js +7 -0
- package/build/esm/types/actions/initial.d.ts +23 -0
- package/build/esm/types/actions/initial.js +1 -0
- package/build/esm/types/actions/insert.d.ts +19 -0
- package/build/esm/types/actions/insert.js +1 -0
- package/build/esm/types/actions/other.d.ts +16 -0
- package/build/esm/types/actions/other.js +1 -0
- package/build/esm/types/actions/overlay.d.ts +16 -0
- package/build/esm/types/actions/overlay.js +1 -0
- package/build/esm/types/actions/reorder.d.ts +17 -0
- package/build/esm/types/actions/reorder.js +1 -0
- package/build/esm/types/actions/select.d.ts +16 -0
- package/build/esm/types/actions/select.js +1 -0
- package/build/esm/types/dynamic-form.d.ts +92 -0
- package/build/esm/types/dynamic-form.js +1 -0
- package/build/esm/types/index.d.ts +14 -0
- package/build/esm/types/index.js +1 -0
- package/build/esm/utils/editor.d.ts +2 -0
- package/build/esm/utils/editor.js +20 -0
- package/build/esm/utils/form-generator.d.ts +9 -0
- package/build/esm/utils/form-generator.js +121 -0
- package/build/esm/utils/store.d.ts +16 -0
- package/build/esm/utils/store.js +5 -0
- package/package.json +5 -2
- package/server/models/constructor-items/blocks.d.ts +2 -1
- package/server/models/constructor-items/blocks.js +1 -0
- package/server/models/constructor-items/sub-blocks.d.ts +1 -1
- package/styles/mixins.scss +9 -9
- package/widget/index.js +1 -1
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
declare const HeaderBlockConfig: {
|
|
2
|
+
component: (props: import("../..").WithChildren<import("../..").HeaderBlockProps & import("../..").ClassNameProps>) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
};
|
|
7
|
+
};
|
|
8
|
+
export default HeaderBlockConfig;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Header_1 = tslib_1.__importDefault(require("./Header"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const HeaderBlockConfig = {
|
|
8
|
+
component: Header_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Header Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.HeaderBlock['header-block']),
|
|
12
|
+
},
|
|
13
|
+
};
|
|
14
|
+
exports.default = HeaderBlockConfig;
|
|
@@ -14,8 +14,9 @@ const HeaderSliderBlock = (_a) => {
|
|
|
14
14
|
const isMobile = (0, react_1.useContext)(mobileContext_1.MobileContext);
|
|
15
15
|
const showArrows = isMobile ? false : arrows;
|
|
16
16
|
return (react_1.default.createElement("div", { className: b('wrapper'), "data-qa": "header-slider" },
|
|
17
|
-
react_1.default.createElement(index_1.SliderBlock, Object.assign({}, props, { arrows: showArrows, slidesToShow: 1, type: models_1.SliderType.HeaderCard, animated: false, blockClassName: b(), arrowSize: 20 }), items
|
|
18
|
-
react_1.default.createElement(
|
|
17
|
+
react_1.default.createElement(index_1.SliderBlock, Object.assign({}, props, { arrows: showArrows, slidesToShow: 1, type: models_1.SliderType.HeaderCard, animated: false, blockClassName: b(), arrowSize: 20 }), items &&
|
|
18
|
+
items.map((item, index) => (react_1.default.createElement("div", { key: index, className: b('item'), "data-qa": `header-slider-item-${index + 1}` },
|
|
19
|
+
react_1.default.createElement(Header_1.default, Object.assign({}, item, { className: b('item-content') }))))))));
|
|
19
20
|
};
|
|
20
21
|
exports.HeaderSliderBlock = HeaderSliderBlock;
|
|
21
22
|
exports.default = exports.HeaderSliderBlock;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
declare const HeaderSliderBlockConfig: {
|
|
2
|
+
component: ({ items, arrows, ...props }: import("../..").HeaderSliderBlockProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
type: string;
|
|
8
|
+
items: ({
|
|
9
|
+
title: string;
|
|
10
|
+
overtitle: string;
|
|
11
|
+
description: string;
|
|
12
|
+
image?: undefined;
|
|
13
|
+
mediaView?: undefined;
|
|
14
|
+
width?: undefined;
|
|
15
|
+
buttons?: undefined;
|
|
16
|
+
} | {
|
|
17
|
+
image: string;
|
|
18
|
+
mediaView: string;
|
|
19
|
+
title: string;
|
|
20
|
+
overtitle: string;
|
|
21
|
+
description: string;
|
|
22
|
+
width: string;
|
|
23
|
+
buttons: {
|
|
24
|
+
text: string;
|
|
25
|
+
theme: string;
|
|
26
|
+
}[];
|
|
27
|
+
})[];
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
export default HeaderSliderBlockConfig;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const HeaderSlider_1 = tslib_1.__importDefault(require("./HeaderSlider"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const HeaderSliderBlockConfig = {
|
|
8
|
+
component: HeaderSlider_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Header Slider Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.HeaderSliderBlock['header-slider-block']),
|
|
12
|
+
default: {
|
|
13
|
+
type: 'header-slider-block',
|
|
14
|
+
items: [
|
|
15
|
+
{
|
|
16
|
+
title: 'Header Slide 1',
|
|
17
|
+
overtitle: 'Header Slider Block presents',
|
|
18
|
+
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.',
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
image: 'https://storage.yandexcloud.net/cloud-www-assets/constructor/storybook/images/header-bg-video_light.png',
|
|
22
|
+
mediaView: 'fit',
|
|
23
|
+
title: 'Header Slide 2',
|
|
24
|
+
overtitle: 'Header Slider Block presents',
|
|
25
|
+
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.',
|
|
26
|
+
width: 'm',
|
|
27
|
+
buttons: [
|
|
28
|
+
{
|
|
29
|
+
text: 'Button',
|
|
30
|
+
theme: 'action',
|
|
31
|
+
},
|
|
32
|
+
],
|
|
33
|
+
},
|
|
34
|
+
],
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
};
|
|
38
|
+
exports.default = HeaderSliderBlockConfig;
|
|
@@ -4,6 +4,7 @@ const tslib_1 = require("tslib");
|
|
|
4
4
|
const react_1 = tslib_1.__importStar(require("react"));
|
|
5
5
|
const components_1 = require("../../components");
|
|
6
6
|
const locationContext_1 = require("../../context/locationContext");
|
|
7
|
+
const grid_1 = require("../../grid");
|
|
7
8
|
const hooks_1 = require("../../hooks");
|
|
8
9
|
const utils_1 = require("../../utils");
|
|
9
10
|
const b = (0, utils_1.block)('icons-block');
|
|
@@ -17,11 +18,13 @@ const Icons = ({ title, description, size = 's', colSizes = { all: 12 }, items }
|
|
|
17
18
|
handleAnalytics(analyticsEvents, { url });
|
|
18
19
|
}, [handleAnalytics]);
|
|
19
20
|
return (react_1.default.createElement("div", { className: b({ size }) },
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
21
|
+
react_1.default.createElement(grid_1.Grid, null,
|
|
22
|
+
(title || description) && (react_1.default.createElement(components_1.Title, { className: b('header'), title: title, subtitle: description, colSizes: colSizes })),
|
|
23
|
+
items &&
|
|
24
|
+
items.map((item) => {
|
|
25
|
+
const itemContent = getItemContent(item);
|
|
26
|
+
const { url, text } = item;
|
|
27
|
+
return url ? (react_1.default.createElement("a", Object.assign({ className: b('item'), key: url, href: url, "aria-label": text, title: text }, (0, utils_1.getLinkProps)(url, hostname), { onClick: () => onClick(item) }), itemContent)) : (react_1.default.createElement("div", { className: b('item'), key: text }, itemContent));
|
|
28
|
+
}))));
|
|
26
29
|
};
|
|
27
30
|
exports.default = Icons;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare const IconsBlockConfig: {
|
|
2
|
+
component: ({ title, description, size, colSizes, items }: import("../..").IconsBlockProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
type: string;
|
|
8
|
+
title: string;
|
|
9
|
+
description: string;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export default IconsBlockConfig;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Icons_1 = tslib_1.__importDefault(require("./Icons"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const IconsBlockConfig = {
|
|
8
|
+
component: Icons_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Icons Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.IconsProps),
|
|
12
|
+
default: {
|
|
13
|
+
type: 'icons-block',
|
|
14
|
+
title: 'Icons Block',
|
|
15
|
+
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.',
|
|
16
|
+
},
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
exports.default = IconsBlockConfig;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
declare const InfoBlockConfig: {
|
|
2
|
+
component: (props: import("../..").InfoBlockProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
type: string;
|
|
8
|
+
title: string;
|
|
9
|
+
backgroundColor: string;
|
|
10
|
+
sectionsTitle: string;
|
|
11
|
+
links: {
|
|
12
|
+
text: string;
|
|
13
|
+
}[];
|
|
14
|
+
buttons: {
|
|
15
|
+
text: string;
|
|
16
|
+
theme: string;
|
|
17
|
+
}[];
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
export default InfoBlockConfig;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Info_1 = tslib_1.__importDefault(require("./Info"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const InfoBlockConfig = {
|
|
8
|
+
component: Info_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Info Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.InfoBlock['info-block']),
|
|
12
|
+
default: {
|
|
13
|
+
type: 'info-block',
|
|
14
|
+
title: 'Info Block',
|
|
15
|
+
backgroundColor: '#1c1c1c',
|
|
16
|
+
sectionsTitle: 'Other links',
|
|
17
|
+
links: [
|
|
18
|
+
{
|
|
19
|
+
text: 'Link 1',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
text: 'Link 2',
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
text: 'Link 3',
|
|
26
|
+
},
|
|
27
|
+
],
|
|
28
|
+
buttons: [
|
|
29
|
+
{
|
|
30
|
+
text: 'Read more',
|
|
31
|
+
theme: 'outlined-contrast',
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
text: 'Go back',
|
|
35
|
+
theme: 'action',
|
|
36
|
+
},
|
|
37
|
+
],
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
exports.default = InfoBlockConfig;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
declare const MapBlockConfig: {
|
|
2
|
+
component: ({ map, border, disableShadow, ...props }: import("../..").MapBlockProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
title: string;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default MapBlockConfig;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Map_1 = tslib_1.__importDefault(require("./Map"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const MapBlockConfig = {
|
|
8
|
+
component: Map_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Map Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.MapBlock['map-block']),
|
|
12
|
+
default: {
|
|
13
|
+
title: 'Map Block',
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
exports.default = MapBlockConfig;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
declare const MediaBlockConfig: {
|
|
2
|
+
component: (props: import("../..").MediaBlockProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
type: string;
|
|
8
|
+
title: string;
|
|
9
|
+
additionalInfo: string;
|
|
10
|
+
description: string;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
export default MediaBlockConfig;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Media_1 = tslib_1.__importDefault(require("./Media"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const MediaBlockConfig = {
|
|
8
|
+
component: Media_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Media Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.MediaBlock['media-block']),
|
|
12
|
+
default: {
|
|
13
|
+
type: 'media-block',
|
|
14
|
+
title: 'Media Block',
|
|
15
|
+
additionalInfo: 'Additional info',
|
|
16
|
+
description: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.',
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
|
+
exports.default = MediaBlockConfig;
|
|
@@ -9,6 +9,7 @@ const Media_1 = tslib_1.__importDefault(require("../../components/Media/Media"))
|
|
|
9
9
|
const Title_1 = tslib_1.__importDefault(require("../../components/Title/Title"));
|
|
10
10
|
const YFMWrapper_1 = tslib_1.__importDefault(require("../../components/YFMWrapper/YFMWrapper"));
|
|
11
11
|
const constants_1 = require("../../constants");
|
|
12
|
+
const grid_1 = require("../../grid");
|
|
12
13
|
const utils_1 = require("../../utils");
|
|
13
14
|
const b = (0, utils_1.block)('PromoFeaturesBlock');
|
|
14
15
|
const breakpointColumns = {
|
|
@@ -19,21 +20,23 @@ const breakpointColumns = {
|
|
|
19
20
|
const PromoFeaturesBlock = (props) => {
|
|
20
21
|
const { items, title, description, theme, animated = true } = props;
|
|
21
22
|
const backgroundTheme = theme || 'default';
|
|
22
|
-
return (react_1.default.createElement(
|
|
23
|
-
react_1.default.createElement(
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
'
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
23
|
+
return (react_1.default.createElement(grid_1.Grid, null,
|
|
24
|
+
react_1.default.createElement(AnimateBlock_1.default, { className: b({ [backgroundTheme]: true }), animate: animated },
|
|
25
|
+
react_1.default.createElement(FullWidthBackground_1.default, { className: b('background', { [backgroundTheme]: true }) }),
|
|
26
|
+
react_1.default.createElement(Title_1.default, { title: title, subtitle: description, className: b('header') }),
|
|
27
|
+
react_1.default.createElement(BalancedMasonry_1.default, { breakpointCols: breakpointColumns, className: b('card-container'), columnClassName: b('card-container-column') }, items &&
|
|
28
|
+
items.map(({ title: cardTitle, text, media, theme: cardTheme }, index) => {
|
|
29
|
+
const blockModifier = backgroundTheme === 'default' ? 'default' : 'light';
|
|
30
|
+
const themeMod = cardTheme || blockModifier || '';
|
|
31
|
+
return (react_1.default.createElement("div", { key: index, className: b('card', {
|
|
32
|
+
'no-media': !media,
|
|
33
|
+
[themeMod]: Boolean(themeMod),
|
|
34
|
+
}) },
|
|
35
|
+
react_1.default.createElement("div", { className: b('card-info') },
|
|
36
|
+
react_1.default.createElement("h3", { className: b('card-title') }, cardTitle),
|
|
37
|
+
react_1.default.createElement("div", { className: b('card-text') },
|
|
38
|
+
react_1.default.createElement(YFMWrapper_1.default, { content: text, modifiers: { constructor: true } }))),
|
|
39
|
+
media && react_1.default.createElement(Media_1.default, Object.assign({ className: b('card-media') }, media))));
|
|
40
|
+
})))));
|
|
38
41
|
};
|
|
39
42
|
exports.default = PromoFeaturesBlock;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
declare const PromoFeaturesBlockConfig: {
|
|
2
|
+
component: (props: import("../..").PromoFeaturesProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
title: string;
|
|
8
|
+
items: {}[];
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export default PromoFeaturesBlockConfig;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const PromoFeaturesBlock_1 = tslib_1.__importDefault(require("./PromoFeaturesBlock"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const PromoFeaturesBlockConfig = {
|
|
8
|
+
component: PromoFeaturesBlock_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Promo Features Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.PromoFeaturesBlock['promo-features-block']),
|
|
12
|
+
default: {
|
|
13
|
+
title: 'Promo Features Block',
|
|
14
|
+
items: [{}],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
exports.default = PromoFeaturesBlockConfig;
|
|
@@ -21,15 +21,17 @@ const QuestionsBlock = (props) => {
|
|
|
21
21
|
}
|
|
22
22
|
setOpened(newState);
|
|
23
23
|
};
|
|
24
|
-
return (react_1.default.createElement(
|
|
25
|
-
react_1.default.createElement(
|
|
26
|
-
react_1.default.createElement(grid_1.
|
|
27
|
-
react_1.default.createElement(
|
|
28
|
-
react_1.default.createElement(
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
return (react_1.default.createElement(grid_1.Grid, null,
|
|
25
|
+
react_1.default.createElement("div", { className: b(), itemScope: true, itemType: models_1.FaqMicrodataValues.PageType },
|
|
26
|
+
react_1.default.createElement(grid_1.Row, null,
|
|
27
|
+
react_1.default.createElement(grid_1.Col, { sizes: { all: 12, md: 4 } },
|
|
28
|
+
react_1.default.createElement("div", { className: b('title') },
|
|
29
|
+
react_1.default.createElement(sub_blocks_1.Content, { title: title, text: text, additionalInfo: additionalInfo, links: links, list: list, buttons: buttons, colSizes: { all: 12, md: 12 } }))),
|
|
30
|
+
react_1.default.createElement(grid_1.Col, { sizes: { all: 12, md: 8 }, role: 'list' }, items &&
|
|
31
|
+
items.map(({ title: itemTitle, text: itemText, link, listStyle = 'dash' }, index) => {
|
|
32
|
+
const isOpened = opened.includes(index);
|
|
33
|
+
const onClick = () => toggleItem(index);
|
|
34
|
+
return (react_1.default.createElement(QuestionBlockItem_1.QuestionBlockItem, { key: itemTitle, title: itemTitle, text: itemText, link: link, listStyle: listStyle, isOpened: isOpened, onClick: onClick }));
|
|
35
|
+
}))))));
|
|
34
36
|
};
|
|
35
37
|
exports.default = QuestionsBlock;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
declare const QuestionsBlockConfig: {
|
|
2
|
+
component: (props: import("../..").QuestionsProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
type: string;
|
|
8
|
+
title: string;
|
|
9
|
+
text: string;
|
|
10
|
+
links: {
|
|
11
|
+
text: string;
|
|
12
|
+
url: string;
|
|
13
|
+
}[];
|
|
14
|
+
buttons: {
|
|
15
|
+
text: string;
|
|
16
|
+
theme: string;
|
|
17
|
+
}[];
|
|
18
|
+
list: {
|
|
19
|
+
title: string;
|
|
20
|
+
text: string;
|
|
21
|
+
}[];
|
|
22
|
+
items: {
|
|
23
|
+
title: string;
|
|
24
|
+
text: string;
|
|
25
|
+
}[];
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
export default QuestionsBlockConfig;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Questions_1 = tslib_1.__importDefault(require("./Questions"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const QuestionsBlockConfig = {
|
|
8
|
+
component: Questions_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Questions Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.QuestionsBlock['questions-block']),
|
|
12
|
+
default: {
|
|
13
|
+
type: 'questions-block',
|
|
14
|
+
title: 'Questions Block',
|
|
15
|
+
text: 'Here you can find answers.',
|
|
16
|
+
links: [
|
|
17
|
+
{
|
|
18
|
+
text: 'Report for 2024',
|
|
19
|
+
url: 'file.doc',
|
|
20
|
+
},
|
|
21
|
+
],
|
|
22
|
+
buttons: [
|
|
23
|
+
{
|
|
24
|
+
text: 'Get more',
|
|
25
|
+
theme: 'outlined-info',
|
|
26
|
+
},
|
|
27
|
+
],
|
|
28
|
+
list: [
|
|
29
|
+
{
|
|
30
|
+
title: 'Report for 2024',
|
|
31
|
+
text: 'Some advice here',
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
items: [
|
|
35
|
+
{
|
|
36
|
+
title: 'Question 1',
|
|
37
|
+
text: 'Answer for question 1',
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
title: 'Question 2',
|
|
41
|
+
text: 'Answer for question 2',
|
|
42
|
+
},
|
|
43
|
+
],
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
};
|
|
47
|
+
exports.default = QuestionsBlockConfig;
|
|
@@ -27,15 +27,16 @@ const Share = ({ items, title }) => {
|
|
|
27
27
|
const handleButtonClick = (0, react_1.useCallback)(() => handleAnalytics(), [handleAnalytics]);
|
|
28
28
|
return (react_1.default.createElement("div", { className: b() },
|
|
29
29
|
react_1.default.createElement("h5", { className: b('title') }, title || (0, i18n_1.i18n)('constructor-share')),
|
|
30
|
-
react_1.default.createElement("div", { className: b('items') }, items
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
30
|
+
react_1.default.createElement("div", { className: b('items') }, items &&
|
|
31
|
+
items.map((type) => {
|
|
32
|
+
const url = (0, utils_1.getAbsolutePath)(hostname, pathname);
|
|
33
|
+
const socialUrl = (0, utils_1.getShareLink)(url, type);
|
|
34
|
+
const icon = icons[type];
|
|
35
|
+
const urlTitle = (0, i18n_1.i18n)(`${type}-title`);
|
|
36
|
+
const buttonLabel = (0, i18n_1.i18n)(`${type}-label`);
|
|
37
|
+
return (react_1.default.createElement(uikit_1.Button, { key: type, view: "flat", size: "l", target: "_blank", href: socialUrl, className: b('item', { type: type.toLowerCase() }), onClick: handleButtonClick, title: urlTitle, extraProps: {
|
|
38
|
+
'aria-label': buttonLabel,
|
|
39
|
+
} }, icon && (react_1.default.createElement(uikit_1.Icon, { data: icon, size: 24, className: b('icon', { type }) }))));
|
|
40
|
+
}))));
|
|
40
41
|
};
|
|
41
42
|
exports.default = Share;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
declare const ShareBlockConfig: {
|
|
2
|
+
component: ({ items, title }: import("../..").ShareBlockProps) => JSX.Element;
|
|
3
|
+
schema: {
|
|
4
|
+
name: string;
|
|
5
|
+
inputs: import("../../types/dynamic-form").ConfigInput[];
|
|
6
|
+
default: {
|
|
7
|
+
items: string[];
|
|
8
|
+
title: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export default ShareBlockConfig;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
const form_generator_1 = require("../../utils/form-generator");
|
|
5
|
+
const Share_1 = tslib_1.__importDefault(require("./Share"));
|
|
6
|
+
const schema_1 = require("./schema");
|
|
7
|
+
const ShareBlockConfig = {
|
|
8
|
+
component: Share_1.default,
|
|
9
|
+
schema: {
|
|
10
|
+
name: 'Share Block',
|
|
11
|
+
inputs: (0, form_generator_1.generateFromAJV)(schema_1.ShareBlock['share-block']),
|
|
12
|
+
default: {
|
|
13
|
+
items: ['vk', 'telegram', 'facebook'],
|
|
14
|
+
title: 'Share Block',
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
exports.default = ShareBlockConfig;
|
|
@@ -11,10 +11,13 @@ const Anchor_1 = tslib_1.__importDefault(require("../../components/Anchor/Anchor
|
|
|
11
11
|
const AnimateBlock_1 = tslib_1.__importDefault(require("../../components/AnimateBlock/AnimateBlock"));
|
|
12
12
|
const OutsideClick_1 = tslib_1.__importDefault(require("../../components/OutsideClick/OutsideClick"));
|
|
13
13
|
const Title_1 = tslib_1.__importDefault(require("../../components/Title/Title"));
|
|
14
|
+
const ChildrenWrap_1 = tslib_1.__importDefault(require("../../components/editor/ChildrenWrap/ChildrenWrap"));
|
|
15
|
+
const ItemWrap_1 = tslib_1.__importDefault(require("../../components/editor/ItemWrap/ItemWrap"));
|
|
14
16
|
const constants_1 = require("../../constants");
|
|
15
17
|
const mobileContext_1 = require("../../context/mobileContext");
|
|
16
18
|
const ssrContext_1 = require("../../context/ssrContext");
|
|
17
19
|
const StylesContext_1 = require("../../context/stylesContext/StylesContext");
|
|
20
|
+
const grid_1 = require("../../grid");
|
|
18
21
|
const useFocus_1 = tslib_1.__importDefault(require("../../hooks/useFocus"));
|
|
19
22
|
const models_1 = require("../../models");
|
|
20
23
|
const utils_1 = require("../../utils");
|
|
@@ -32,11 +35,11 @@ const SliderBlock = (props) => {
|
|
|
32
35
|
const [breakpoint, setBreakpoint] = (0, react_1.useState)(constants_1.BREAKPOINTS.xl);
|
|
33
36
|
const disclosedChildren = (0, react_1.useMemo)(() => discloseAllNestedChildren(children), [children]);
|
|
34
37
|
const childrenCount = disclosedChildren.length;
|
|
35
|
-
const
|
|
38
|
+
const slidesToShow = (0, react_1.useMemo)(() => (0, utils_2.getSlidesToShowWithDefaults)({
|
|
36
39
|
contentLength: childrenCount,
|
|
37
40
|
breakpoints: props.slidesToShow,
|
|
38
41
|
mobileFullscreen: Boolean(props.type && Object.values(models_1.SliderType).includes(props.type)),
|
|
39
|
-
}));
|
|
42
|
+
}), [childrenCount, props.slidesToShow, props.type]);
|
|
40
43
|
const slidesToShowCount = (0, utils_2.getSlidesToShowCount)(slidesToShow);
|
|
41
44
|
const slidesCountByBreakpoint = (0, utils_2.getSlidesCountByBreakpoint)(breakpoint, slidesToShow);
|
|
42
45
|
const [currentIndex, setCurrentIndex] = (0, react_1.useState)(0);
|
|
@@ -204,23 +207,25 @@ const SliderBlock = (props) => {
|
|
|
204
207
|
prevArrow: react_1.default.createElement(Arrow_1.default, { type: "left", handleClick: handleArrowClick, size: arrowSize }),
|
|
205
208
|
lazyLoad,
|
|
206
209
|
};
|
|
207
|
-
return (react_1.default.createElement(
|
|
208
|
-
react_1.default.createElement(
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
210
|
+
return (react_1.default.createElement(ChildrenWrap_1.default, null,
|
|
211
|
+
react_1.default.createElement(OutsideClick_1.default, { onOutsideClick: isMobile ? unsetFocus : noop_1.default },
|
|
212
|
+
react_1.default.createElement(react_slick_1.default, Object.assign({}, settings), react_1.default.Children.map(disclosedChildren, (child, index) => (react_1.default.createElement(ItemWrap_1.default, { index: index }, child)))),
|
|
213
|
+
react_1.default.createElement("div", { className: b('footer') },
|
|
214
|
+
renderDisclaimer(),
|
|
215
|
+
renderNavigation()))));
|
|
212
216
|
};
|
|
213
217
|
return (react_1.default.createElement(StylesContext_1.StylesContext.Provider, { value: Object.assign(Object.assign({}, childStyles), { setStyles: setChildStyles }) },
|
|
214
|
-
react_1.default.createElement(
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
218
|
+
react_1.default.createElement(grid_1.Grid, null,
|
|
219
|
+
react_1.default.createElement("div", { className: b({
|
|
220
|
+
'align-left': childrenCount < slidesCountByBreakpoint,
|
|
221
|
+
'one-slide': childrenCount === 1,
|
|
222
|
+
'only-arrows': !(title === null || title === void 0 ? void 0 : title.text) && !description && arrows,
|
|
223
|
+
mobile: isMobile,
|
|
224
|
+
type,
|
|
225
|
+
}, blockClassName) },
|
|
226
|
+
anchorId && react_1.default.createElement(Anchor_1.default, { id: anchorId }),
|
|
227
|
+
react_1.default.createElement(Title_1.default, { title: title, subtitle: description, className: b('header', { 'no-description': !description }) }),
|
|
228
|
+
react_1.default.createElement(AnimateBlock_1.default, { className: b('animate-slides'), animate: animated }, renderSlider())))));
|
|
224
229
|
};
|
|
225
230
|
exports.SliderBlock = SliderBlock;
|
|
226
231
|
// TODO remove this and rework PriceDetailed CLOUDFRONT-12230
|