@gravity-ui/page-constructor 4.56.0 → 5.0.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/README.md +6 -4
- package/build/cjs/blocks/Banner/schema.d.ts +0 -264
- package/build/cjs/blocks/FilterBlock/FilterBlock.js +2 -2
- package/build/cjs/blocks/FilterBlock/i18n/index.d.ts +1 -2
- package/build/cjs/blocks/FilterBlock/i18n/index.js +4 -3
- package/build/cjs/blocks/Map/schema.d.ts +0 -88
- package/build/cjs/blocks/Media/schema.d.ts +0 -176
- package/build/cjs/blocks/Security/i18n/index.d.ts +1 -2
- package/build/cjs/blocks/Security/i18n/index.js +4 -3
- package/build/cjs/blocks/Share/Share.css +2 -1
- package/build/cjs/blocks/Share/Share.js +4 -4
- package/build/cjs/blocks/Share/i18n/index.d.ts +1 -2
- package/build/cjs/blocks/Share/i18n/index.js +4 -3
- package/build/cjs/blocks/Slider/Arrow/Arrow.js +2 -2
- package/build/cjs/blocks/Slider/i18n/index.d.ts +1 -2
- package/build/cjs/blocks/Slider/i18n/index.js +4 -3
- package/build/cjs/components/BackLink/BackLink.js +2 -2
- package/build/cjs/components/Button/Button.css +1 -5
- package/build/cjs/components/Button/Button.js +4 -7
- package/build/cjs/components/Button/i18n/index.d.ts +1 -2
- package/build/cjs/components/Button/i18n/index.js +4 -3
- package/build/cjs/components/ButtonTabs/ButtonTabs.css +0 -4
- package/build/cjs/components/CardBase/CardBase.d.ts +1 -3
- package/build/cjs/components/CardBase/CardBase.js +1 -4
- package/build/cjs/components/Control/Control.js +2 -2
- package/build/cjs/components/Control/i18n/index.d.ts +1 -2
- package/build/cjs/components/Control/i18n/index.js +4 -3
- package/build/cjs/components/FileLink/FileLink.css +4 -5
- package/build/cjs/components/FullscreenImage/FullscreenImage.css +1 -0
- package/build/cjs/components/FullscreenImage/FullscreenImage.js +9 -10
- package/build/cjs/components/FullscreenImage/i18n/index.d.ts +1 -2
- package/build/cjs/components/FullscreenImage/i18n/index.js +4 -3
- package/build/cjs/components/FullscreenMedia/FullscreenMedia.css +1 -0
- package/build/cjs/components/FullscreenMedia/FullscreenMedia.js +14 -15
- package/build/cjs/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +3 -6
- package/build/cjs/components/Link/Link.css +1 -2
- package/build/cjs/components/Link/Link.js +3 -6
- package/build/cjs/components/Map/GoogleMap.js +2 -2
- package/build/cjs/components/Map/YMap/YandexMap.js +2 -2
- package/build/cjs/components/Map/YMap/i18n/index.d.ts +1 -2
- package/build/cjs/components/Map/YMap/i18n/index.js +4 -3
- package/build/cjs/components/Media/DataLens/DataLens.js +2 -2
- package/build/cjs/components/Media/DataLens/i18n/index.d.ts +1 -2
- package/build/cjs/components/Media/DataLens/i18n/index.js +4 -3
- package/build/cjs/components/Media/Iframe/Iframe.js +2 -2
- package/build/cjs/components/Media/Iframe/i18n/index.d.ts +1 -2
- package/build/cjs/components/Media/Iframe/i18n/index.js +4 -3
- package/build/cjs/components/Media/Media.js +1 -3
- package/build/cjs/components/Media/Video/Video.js +2 -3
- package/build/cjs/components/OverflowScroller/OverflowScroller.js +2 -2
- package/build/cjs/components/OverflowScroller/i18n/index.d.ts +1 -2
- package/build/cjs/components/OverflowScroller/i18n/index.js +4 -3
- package/build/cjs/components/ReactPlayer/CustomBarControls.js +5 -7
- package/build/cjs/components/ReactPlayer/ReactPlayer.css +1 -1
- package/build/cjs/components/ReactPlayer/ReactPlayer.js +7 -31
- package/build/cjs/components/ReactPlayer/i18n/index.d.ts +1 -2
- package/build/cjs/components/ReactPlayer/i18n/index.js +4 -3
- package/build/cjs/components/Table/Table.css +6 -0
- package/build/cjs/components/Table/Table.js +2 -2
- package/build/cjs/components/UnpublishedLabel/UnpublishedLabel.js +2 -2
- package/build/cjs/components/UnpublishedLabel/i18n/index.d.ts +1 -2
- package/build/cjs/components/UnpublishedLabel/i18n/index.js +4 -3
- package/build/cjs/components/VideoBlock/VideoBlock.css +1 -1
- package/build/cjs/components/VideoBlock/VideoBlock.js +4 -4
- package/build/cjs/components/VideoBlock/i18n/index.d.ts +1 -2
- package/build/cjs/components/VideoBlock/i18n/index.js +4 -3
- package/build/cjs/components/YandexForm/YandexForm.js +2 -13
- package/build/cjs/containers/Loadable/Loadable.js +2 -2
- package/build/cjs/containers/Loadable/i18n/index.d.ts +1 -2
- package/build/cjs/containers/Loadable/i18n/index.js +4 -3
- package/build/cjs/containers/PageConstructor/PageConstructor.css +1 -1
- package/build/cjs/containers/PageConstructor/PageConstructor.d.ts +1 -1
- package/build/cjs/containers/PageConstructor/PageConstructor.js +1 -1
- package/build/cjs/containers/PageConstructor/Provider.d.ts +0 -2
- package/build/cjs/containers/PageConstructor/Provider.js +1 -3
- package/build/cjs/context/localeContext/localeContext.d.ts +2 -2
- package/build/cjs/context/localeContext/localeContext.js +2 -2
- package/build/cjs/editor/components/ControlPanel/ControlPanel.js +3 -3
- package/build/cjs/editor/components/ControlPanel/i18n/en.json +2 -1
- package/build/cjs/editor/components/ControlPanel/i18n/index.d.ts +1 -2
- package/build/cjs/editor/components/ControlPanel/i18n/index.js +4 -3
- package/build/cjs/editor/components/ControlPanel/i18n/ru.json +2 -1
- package/build/cjs/editor/components/ErrorBoundary/ErrorBoundary.js +3 -3
- package/build/cjs/editor/components/ErrorBoundary/i18n/index.d.ts +1 -2
- package/build/cjs/editor/components/ErrorBoundary/i18n/index.js +4 -3
- package/build/cjs/editor/components/NotFoundBlock/NotFoundBlock.js +2 -2
- package/build/cjs/editor/components/NotFoundBlock/i18n/index.d.ts +1 -2
- package/build/cjs/editor/components/NotFoundBlock/i18n/index.js +4 -3
- package/build/cjs/editor/containers/Form/Form.css +1 -1
- package/build/cjs/editor/dynamic-forms-custom/hooks/useOneOf.d.ts +1 -1
- package/build/cjs/hooks/useAnalytics.d.ts +2 -2
- package/build/cjs/hooks/useMetrika.d.ts +1 -13
- package/build/cjs/hooks/useMetrika.js +0 -41
- package/build/cjs/icons/index.d.ts +0 -9
- package/build/cjs/icons/index.js +0 -9
- package/build/cjs/index.d.ts +0 -1
- package/build/cjs/index.js +0 -1
- package/build/cjs/models/common.d.ts +2 -53
- package/build/cjs/models/common.js +1 -25
- package/build/cjs/models/constructor-items/common.d.ts +3 -28
- package/build/cjs/models/constructor-items/sub-blocks.d.ts +3 -3
- package/build/cjs/models/guards.d.ts +0 -2
- package/build/cjs/models/guards.js +1 -5
- package/build/cjs/navigation/components/MobileMenuButton/MobileMenuButton.js +3 -3
- package/build/cjs/schema/constants.d.ts +0 -176
- package/build/cjs/schema/constants.js +2 -0
- package/build/cjs/schema/validators/common.d.ts +0 -188
- package/build/cjs/schema/validators/common.js +0 -31
- package/build/cjs/schema/validators/index.d.ts +0 -2
- package/build/cjs/schema/validators/index.js +0 -2
- package/build/cjs/sub-blocks/HubspotForm/HubspotForm.css +0 -1
- package/build/cjs/sub-blocks/HubspotForm/index.js +1 -6
- package/build/cjs/sub-blocks/LayoutItem/utils.d.ts +1 -15
- package/build/cjs/sub-blocks/PriceCard/schema.d.ts +0 -88
- package/build/cjs/sub-blocks/PriceDetailed/PriceDetailed.d.ts +1 -0
- package/build/cjs/sub-blocks/PriceDetailed/PriceDetailed.js +2 -0
- package/build/cjs/sub-blocks/PriceDetailed/schema.d.ts +1 -0
- package/build/cjs/sub-blocks/PriceDetailed/schema.js +1 -0
- package/build/cjs/text-transform/common.d.ts +5 -5
- package/build/cjs/text-transform/common.js +1 -1
- package/build/cjs/text-transform/filter.js +1 -1
- package/build/cjs/text-transform/transformers.d.ts +3 -3
- package/build/cjs/text-transform/utils.d.ts +7 -7
- package/build/cjs/text-transform/utils.js +6 -6
- package/build/cjs/utils/index.d.ts +0 -1
- package/build/cjs/utils/index.js +1 -4
- package/build/esm/blocks/Banner/schema.d.ts +0 -264
- package/build/esm/blocks/FilterBlock/FilterBlock.js +1 -1
- package/build/esm/blocks/FilterBlock/i18n/index.d.ts +1 -2
- package/build/esm/blocks/FilterBlock/i18n/index.js +3 -3
- package/build/esm/blocks/Map/schema.d.ts +0 -88
- package/build/esm/blocks/Media/schema.d.ts +0 -176
- package/build/esm/blocks/Security/i18n/index.d.ts +1 -2
- package/build/esm/blocks/Security/i18n/index.js +3 -3
- package/build/esm/blocks/Share/Share.css +2 -1
- package/build/esm/blocks/Share/Share.js +1 -1
- package/build/esm/blocks/Share/i18n/index.d.ts +1 -2
- package/build/esm/blocks/Share/i18n/index.js +3 -3
- package/build/esm/blocks/Slider/Arrow/Arrow.js +1 -1
- package/build/esm/blocks/Slider/i18n/index.d.ts +1 -2
- package/build/esm/blocks/Slider/i18n/index.js +3 -3
- package/build/esm/components/BackLink/BackLink.js +2 -2
- package/build/esm/components/Button/Button.css +1 -5
- package/build/esm/components/Button/Button.js +3 -6
- package/build/esm/components/Button/i18n/index.d.ts +1 -2
- package/build/esm/components/Button/i18n/index.js +3 -3
- package/build/esm/components/ButtonTabs/ButtonTabs.css +0 -4
- package/build/esm/components/CardBase/CardBase.d.ts +1 -3
- package/build/esm/components/CardBase/CardBase.js +1 -4
- package/build/esm/components/Control/Control.js +1 -1
- package/build/esm/components/Control/i18n/index.d.ts +1 -2
- package/build/esm/components/Control/i18n/index.js +3 -3
- package/build/esm/components/FileLink/FileLink.css +4 -5
- package/build/esm/components/FullscreenImage/FullscreenImage.css +1 -0
- package/build/esm/components/FullscreenImage/FullscreenImage.js +8 -9
- package/build/esm/components/FullscreenImage/i18n/index.d.ts +1 -2
- package/build/esm/components/FullscreenImage/i18n/index.js +3 -3
- package/build/esm/components/FullscreenMedia/FullscreenMedia.css +1 -0
- package/build/esm/components/FullscreenMedia/FullscreenMedia.js +14 -15
- package/build/esm/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +3 -6
- package/build/esm/components/Link/Link.css +1 -2
- package/build/esm/components/Link/Link.js +3 -6
- package/build/esm/components/Map/GoogleMap.js +1 -1
- package/build/esm/components/Map/YMap/YandexMap.js +1 -1
- package/build/esm/components/Map/YMap/i18n/index.d.ts +1 -2
- package/build/esm/components/Map/YMap/i18n/index.js +3 -3
- package/build/esm/components/Media/DataLens/DataLens.js +1 -1
- package/build/esm/components/Media/DataLens/i18n/index.d.ts +1 -2
- package/build/esm/components/Media/DataLens/i18n/index.js +3 -3
- package/build/esm/components/Media/Iframe/Iframe.js +1 -1
- package/build/esm/components/Media/Iframe/i18n/index.d.ts +1 -2
- package/build/esm/components/Media/Iframe/i18n/index.js +3 -3
- package/build/esm/components/Media/Media.js +1 -3
- package/build/esm/components/Media/Video/Video.js +2 -3
- package/build/esm/components/OverflowScroller/OverflowScroller.js +1 -1
- package/build/esm/components/OverflowScroller/i18n/index.d.ts +1 -2
- package/build/esm/components/OverflowScroller/i18n/index.js +3 -3
- package/build/esm/components/ReactPlayer/CustomBarControls.js +4 -6
- package/build/esm/components/ReactPlayer/ReactPlayer.css +1 -1
- package/build/esm/components/ReactPlayer/ReactPlayer.js +6 -30
- package/build/esm/components/ReactPlayer/i18n/index.d.ts +1 -2
- package/build/esm/components/ReactPlayer/i18n/index.js +3 -3
- package/build/esm/components/Table/Table.css +6 -0
- package/build/esm/components/Table/Table.js +2 -2
- package/build/esm/components/UnpublishedLabel/UnpublishedLabel.js +1 -1
- package/build/esm/components/UnpublishedLabel/i18n/index.d.ts +1 -2
- package/build/esm/components/UnpublishedLabel/i18n/index.js +3 -3
- package/build/esm/components/VideoBlock/VideoBlock.css +1 -1
- package/build/esm/components/VideoBlock/VideoBlock.js +3 -3
- package/build/esm/components/VideoBlock/i18n/index.d.ts +1 -2
- package/build/esm/components/VideoBlock/i18n/index.js +3 -3
- package/build/esm/components/YandexForm/YandexForm.js +2 -13
- package/build/esm/containers/Loadable/Loadable.js +1 -1
- package/build/esm/containers/Loadable/i18n/index.d.ts +1 -2
- package/build/esm/containers/Loadable/i18n/index.js +3 -3
- package/build/esm/containers/PageConstructor/PageConstructor.css +1 -1
- package/build/esm/containers/PageConstructor/PageConstructor.d.ts +1 -1
- package/build/esm/containers/PageConstructor/PageConstructor.js +1 -1
- package/build/esm/containers/PageConstructor/Provider.d.ts +0 -2
- package/build/esm/containers/PageConstructor/Provider.js +1 -3
- package/build/esm/context/localeContext/localeContext.d.ts +2 -2
- package/build/esm/context/localeContext/localeContext.js +1 -1
- package/build/esm/editor/components/ControlPanel/ControlPanel.js +2 -2
- package/build/esm/editor/components/ControlPanel/i18n/en.json +2 -1
- package/build/esm/editor/components/ControlPanel/i18n/index.d.ts +1 -2
- package/build/esm/editor/components/ControlPanel/i18n/index.js +3 -3
- package/build/esm/editor/components/ControlPanel/i18n/ru.json +2 -1
- package/build/esm/editor/components/ErrorBoundary/ErrorBoundary.js +1 -1
- package/build/esm/editor/components/ErrorBoundary/i18n/index.d.ts +1 -2
- package/build/esm/editor/components/ErrorBoundary/i18n/index.js +3 -3
- package/build/esm/editor/components/NotFoundBlock/NotFoundBlock.js +1 -1
- package/build/esm/editor/components/NotFoundBlock/i18n/index.d.ts +1 -2
- package/build/esm/editor/components/NotFoundBlock/i18n/index.js +3 -3
- package/build/esm/editor/containers/Form/Form.css +1 -1
- package/build/esm/editor/dynamic-forms-custom/hooks/useOneOf.d.ts +1 -1
- package/build/esm/hooks/useAnalytics.d.ts +2 -2
- package/build/esm/hooks/useMetrika.d.ts +1 -13
- package/build/esm/hooks/useMetrika.js +1 -38
- package/build/esm/icons/index.d.ts +0 -9
- package/build/esm/icons/index.js +0 -9
- package/build/esm/index.d.ts +0 -1
- package/build/esm/index.js +0 -1
- package/build/esm/models/common.d.ts +2 -53
- package/build/esm/models/common.js +0 -24
- package/build/esm/models/constructor-items/common.d.ts +3 -28
- package/build/esm/models/constructor-items/sub-blocks.d.ts +3 -3
- package/build/esm/models/guards.d.ts +0 -2
- package/build/esm/models/guards.js +0 -3
- package/build/esm/navigation/components/MobileMenuButton/MobileMenuButton.js +3 -3
- package/build/esm/schema/constants.d.ts +0 -176
- package/build/esm/schema/constants.js +2 -0
- package/build/esm/schema/validators/common.d.ts +0 -188
- package/build/esm/schema/validators/common.js +0 -31
- package/build/esm/schema/validators/index.d.ts +0 -2
- package/build/esm/schema/validators/index.js +0 -2
- package/build/esm/sub-blocks/HubspotForm/HubspotForm.css +0 -1
- package/build/esm/sub-blocks/HubspotForm/index.js +1 -6
- package/build/esm/sub-blocks/LayoutItem/utils.d.ts +1 -15
- package/build/esm/sub-blocks/PriceCard/schema.d.ts +0 -88
- package/build/esm/sub-blocks/PriceDetailed/PriceDetailed.d.ts +1 -0
- package/build/esm/sub-blocks/PriceDetailed/PriceDetailed.js +2 -0
- package/build/esm/sub-blocks/PriceDetailed/schema.d.ts +1 -0
- package/build/esm/sub-blocks/PriceDetailed/schema.js +1 -0
- package/build/esm/text-transform/common.d.ts +5 -5
- package/build/esm/text-transform/common.js +1 -1
- package/build/esm/text-transform/filter.js +1 -1
- package/build/esm/text-transform/transformers.d.ts +3 -3
- package/build/esm/text-transform/utils.d.ts +7 -7
- package/build/esm/text-transform/utils.js +2 -2
- package/build/esm/utils/index.d.ts +0 -1
- package/build/esm/utils/index.js +0 -1
- package/package.json +16 -15
- package/server/models/common.d.ts +2 -53
- package/server/models/common.js +1 -25
- package/server/models/constructor-items/common.d.ts +3 -28
- package/server/models/constructor-items/sub-blocks.d.ts +3 -3
- package/server/models/guards.d.ts +0 -2
- package/server/models/guards.js +1 -5
- package/server/text-transform/common.d.ts +5 -5
- package/server/text-transform/common.js +1 -1
- package/server/text-transform/filter.js +1 -1
- package/server/text-transform/transformers.d.ts +3 -3
- package/server/text-transform/utils.d.ts +7 -7
- package/server/text-transform/utils.js +6 -6
- package/server/utils/index.d.ts +0 -1
- package/server/utils/index.js +1 -4
- package/styles/mixins.scss +0 -4
- package/styles/storybook/index.scss +1 -1
- package/styles/styles.css +1 -1
- package/styles/yfm.scss +1 -1
- package/widget/index.js +1 -1
- package/build/cjs/context/metrikaContext/index.d.ts +0 -1
- package/build/cjs/context/metrikaContext/index.js +0 -4
- package/build/cjs/context/metrikaContext/metrikaContext.d.ts +0 -13
- package/build/cjs/context/metrikaContext/metrikaContext.js +0 -6
- package/build/cjs/i18n.d.ts +0 -2
- package/build/cjs/i18n.js +0 -12
- package/build/cjs/icons/ArrowConstructor.d.ts +0 -2
- package/build/cjs/icons/ArrowConstructor.js +0 -9
- package/build/cjs/icons/ArrowSidebar.d.ts +0 -2
- package/build/cjs/icons/ArrowSidebar.js +0 -9
- package/build/cjs/icons/Fullscreen.d.ts +0 -2
- package/build/cjs/icons/Fullscreen.js +0 -9
- package/build/cjs/icons/Minus.d.ts +0 -2
- package/build/cjs/icons/Minus.js +0 -9
- package/build/cjs/icons/Mute.d.ts +0 -2
- package/build/cjs/icons/Mute.js +0 -12
- package/build/cjs/icons/NavigationClose.d.ts +0 -2
- package/build/cjs/icons/NavigationClose.js +0 -9
- package/build/cjs/icons/NavigationOpen.d.ts +0 -2
- package/build/cjs/icons/NavigationOpen.js +0 -11
- package/build/cjs/icons/PlayVideo.d.ts +0 -2
- package/build/cjs/icons/PlayVideo.js +0 -9
- package/build/cjs/icons/PreviewClose.d.ts +0 -2
- package/build/cjs/icons/PreviewClose.js +0 -9
- package/build/cjs/icons/Tick.d.ts +0 -2
- package/build/cjs/icons/Tick.js +0 -13
- package/build/cjs/icons/Unmute.d.ts +0 -2
- package/build/cjs/icons/Unmute.js +0 -12
- package/build/cjs/schema/validators/pixel.d.ts +0 -57
- package/build/cjs/schema/validators/pixel.js +0 -63
- package/build/cjs/utils/configure.d.ts +0 -12
- package/build/cjs/utils/configure.js +0 -26
- package/build/cjs/utils/registerKeyset.d.ts +0 -5
- package/build/cjs/utils/registerKeyset.js +0 -9
- package/build/esm/context/metrikaContext/index.d.ts +0 -1
- package/build/esm/context/metrikaContext/index.js +0 -1
- package/build/esm/context/metrikaContext/metrikaContext.d.ts +0 -13
- package/build/esm/context/metrikaContext/metrikaContext.js +0 -2
- package/build/esm/i18n.d.ts +0 -2
- package/build/esm/i18n.js +0 -9
- package/build/esm/icons/ArrowConstructor.d.ts +0 -2
- package/build/esm/icons/ArrowConstructor.js +0 -4
- package/build/esm/icons/ArrowSidebar.d.ts +0 -2
- package/build/esm/icons/ArrowSidebar.js +0 -4
- package/build/esm/icons/Fullscreen.d.ts +0 -2
- package/build/esm/icons/Fullscreen.js +0 -4
- package/build/esm/icons/Minus.d.ts +0 -2
- package/build/esm/icons/Minus.js +0 -4
- package/build/esm/icons/Mute.d.ts +0 -2
- package/build/esm/icons/Mute.js +0 -7
- package/build/esm/icons/NavigationClose.d.ts +0 -2
- package/build/esm/icons/NavigationClose.js +0 -4
- package/build/esm/icons/NavigationOpen.d.ts +0 -2
- package/build/esm/icons/NavigationOpen.js +0 -6
- package/build/esm/icons/PlayVideo.d.ts +0 -2
- package/build/esm/icons/PlayVideo.js +0 -4
- package/build/esm/icons/PreviewClose.d.ts +0 -2
- package/build/esm/icons/PreviewClose.js +0 -4
- package/build/esm/icons/Tick.d.ts +0 -2
- package/build/esm/icons/Tick.js +0 -8
- package/build/esm/icons/Unmute.d.ts +0 -2
- package/build/esm/icons/Unmute.js +0 -7
- package/build/esm/schema/validators/pixel.d.ts +0 -57
- package/build/esm/schema/validators/pixel.js +0 -60
- package/build/esm/utils/configure.d.ts +0 -12
- package/build/esm/utils/configure.js +0 -20
- package/build/esm/utils/registerKeyset.d.ts +0 -5
- package/build/esm/utils/registerKeyset.js +0 -5
- package/server/utils/configure.d.ts +0 -12
- package/server/utils/configure.js +0 -26
|
@@ -349,94 +349,6 @@ export declare const MediaBlockBaseProps: {
|
|
|
349
349
|
optionName: string;
|
|
350
350
|
})[];
|
|
351
351
|
};
|
|
352
|
-
metrikaGoals: {
|
|
353
|
-
oneOf: ({
|
|
354
|
-
type: string;
|
|
355
|
-
optionName: string;
|
|
356
|
-
items?: undefined;
|
|
357
|
-
} | {
|
|
358
|
-
type: string;
|
|
359
|
-
items: {
|
|
360
|
-
type: string;
|
|
361
|
-
additionalProperties?: undefined;
|
|
362
|
-
required?: undefined;
|
|
363
|
-
properties?: undefined;
|
|
364
|
-
};
|
|
365
|
-
optionName: string;
|
|
366
|
-
} | {
|
|
367
|
-
type: string;
|
|
368
|
-
items: {
|
|
369
|
-
type: string;
|
|
370
|
-
additionalProperties: boolean;
|
|
371
|
-
required: string[];
|
|
372
|
-
properties: {
|
|
373
|
-
name: {
|
|
374
|
-
type: string;
|
|
375
|
-
};
|
|
376
|
-
isCrossSite: {
|
|
377
|
-
type: string;
|
|
378
|
-
};
|
|
379
|
-
};
|
|
380
|
-
};
|
|
381
|
-
optionName: string;
|
|
382
|
-
})[];
|
|
383
|
-
};
|
|
384
|
-
pixelEvents: {
|
|
385
|
-
type: string;
|
|
386
|
-
items: {
|
|
387
|
-
type: string;
|
|
388
|
-
required: string[];
|
|
389
|
-
additionalProperties: boolean;
|
|
390
|
-
properties: {
|
|
391
|
-
name: {
|
|
392
|
-
type: string;
|
|
393
|
-
enum: import("../..").PixelEventType[];
|
|
394
|
-
};
|
|
395
|
-
data: {};
|
|
396
|
-
};
|
|
397
|
-
select: {
|
|
398
|
-
$data: string;
|
|
399
|
-
};
|
|
400
|
-
selectCases: {
|
|
401
|
-
SubmitApplication: {
|
|
402
|
-
additionalProperties: boolean;
|
|
403
|
-
properties: {
|
|
404
|
-
name: {};
|
|
405
|
-
};
|
|
406
|
-
};
|
|
407
|
-
Contact: {
|
|
408
|
-
additionalProperties: boolean;
|
|
409
|
-
properties: {
|
|
410
|
-
name: {};
|
|
411
|
-
};
|
|
412
|
-
};
|
|
413
|
-
Lead: {
|
|
414
|
-
additionalProperties: boolean;
|
|
415
|
-
properties: {
|
|
416
|
-
name: {};
|
|
417
|
-
data: {
|
|
418
|
-
type: string;
|
|
419
|
-
additionalProperties: boolean;
|
|
420
|
-
properties: {
|
|
421
|
-
content_category: {
|
|
422
|
-
type: string;
|
|
423
|
-
};
|
|
424
|
-
content_name: {
|
|
425
|
-
type: string;
|
|
426
|
-
};
|
|
427
|
-
currency: {
|
|
428
|
-
type: string;
|
|
429
|
-
};
|
|
430
|
-
value: {
|
|
431
|
-
type: string;
|
|
432
|
-
};
|
|
433
|
-
};
|
|
434
|
-
};
|
|
435
|
-
};
|
|
436
|
-
};
|
|
437
|
-
};
|
|
438
|
-
};
|
|
439
|
-
};
|
|
440
352
|
analyticsEvents: {
|
|
441
353
|
oneOf: ({
|
|
442
354
|
optionName: string;
|
|
@@ -1035,94 +947,6 @@ export declare const MediaBlock: {
|
|
|
1035
947
|
optionName: string;
|
|
1036
948
|
})[];
|
|
1037
949
|
};
|
|
1038
|
-
metrikaGoals: {
|
|
1039
|
-
oneOf: ({
|
|
1040
|
-
type: string;
|
|
1041
|
-
optionName: string;
|
|
1042
|
-
items?: undefined;
|
|
1043
|
-
} | {
|
|
1044
|
-
type: string;
|
|
1045
|
-
items: {
|
|
1046
|
-
type: string;
|
|
1047
|
-
additionalProperties?: undefined;
|
|
1048
|
-
required?: undefined;
|
|
1049
|
-
properties?: undefined;
|
|
1050
|
-
};
|
|
1051
|
-
optionName: string;
|
|
1052
|
-
} | {
|
|
1053
|
-
type: string;
|
|
1054
|
-
items: {
|
|
1055
|
-
type: string;
|
|
1056
|
-
additionalProperties: boolean;
|
|
1057
|
-
required: string[];
|
|
1058
|
-
properties: {
|
|
1059
|
-
name: {
|
|
1060
|
-
type: string;
|
|
1061
|
-
};
|
|
1062
|
-
isCrossSite: {
|
|
1063
|
-
type: string;
|
|
1064
|
-
};
|
|
1065
|
-
};
|
|
1066
|
-
};
|
|
1067
|
-
optionName: string;
|
|
1068
|
-
})[];
|
|
1069
|
-
};
|
|
1070
|
-
pixelEvents: {
|
|
1071
|
-
type: string;
|
|
1072
|
-
items: {
|
|
1073
|
-
type: string;
|
|
1074
|
-
required: string[];
|
|
1075
|
-
additionalProperties: boolean;
|
|
1076
|
-
properties: {
|
|
1077
|
-
name: {
|
|
1078
|
-
type: string;
|
|
1079
|
-
enum: import("../..").PixelEventType[];
|
|
1080
|
-
};
|
|
1081
|
-
data: {};
|
|
1082
|
-
};
|
|
1083
|
-
select: {
|
|
1084
|
-
$data: string;
|
|
1085
|
-
};
|
|
1086
|
-
selectCases: {
|
|
1087
|
-
SubmitApplication: {
|
|
1088
|
-
additionalProperties: boolean;
|
|
1089
|
-
properties: {
|
|
1090
|
-
name: {};
|
|
1091
|
-
};
|
|
1092
|
-
};
|
|
1093
|
-
Contact: {
|
|
1094
|
-
additionalProperties: boolean;
|
|
1095
|
-
properties: {
|
|
1096
|
-
name: {};
|
|
1097
|
-
};
|
|
1098
|
-
};
|
|
1099
|
-
Lead: {
|
|
1100
|
-
additionalProperties: boolean;
|
|
1101
|
-
properties: {
|
|
1102
|
-
name: {};
|
|
1103
|
-
data: {
|
|
1104
|
-
type: string;
|
|
1105
|
-
additionalProperties: boolean;
|
|
1106
|
-
properties: {
|
|
1107
|
-
content_category: {
|
|
1108
|
-
type: string;
|
|
1109
|
-
};
|
|
1110
|
-
content_name: {
|
|
1111
|
-
type: string;
|
|
1112
|
-
};
|
|
1113
|
-
currency: {
|
|
1114
|
-
type: string;
|
|
1115
|
-
};
|
|
1116
|
-
value: {
|
|
1117
|
-
type: string;
|
|
1118
|
-
};
|
|
1119
|
-
};
|
|
1120
|
-
};
|
|
1121
|
-
};
|
|
1122
|
-
};
|
|
1123
|
-
};
|
|
1124
|
-
};
|
|
1125
|
-
};
|
|
1126
950
|
analyticsEvents: {
|
|
1127
951
|
oneOf: ({
|
|
1128
952
|
optionName: string;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default _default;
|
|
1
|
+
export declare const i18n: (key: "image-alt", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { addComponentKeysets } from '@gravity-ui/uikit/i18n';
|
|
2
|
+
import { NAMESPACE } from '../../../utils/cn';
|
|
2
3
|
import en from './en.json';
|
|
3
4
|
import ru from './ru.json';
|
|
4
|
-
const
|
|
5
|
-
export default registerKeyset({ en, ru }, COMPONENT);
|
|
5
|
+
export const i18n = addComponentKeysets({ en, ru }, `${NAMESPACE}SecurityBlock`);
|
|
@@ -24,7 +24,8 @@ unpredictable css rules order in build */
|
|
|
24
24
|
/* stylelint-disable-next-line declaration-no-important */
|
|
25
25
|
width: 48px !important;
|
|
26
26
|
height: 48px;
|
|
27
|
-
|
|
27
|
+
/* stylelint-disable-next-line declaration-no-important */
|
|
28
|
+
border-radius: 100% !important;
|
|
28
29
|
}
|
|
29
30
|
.pc-share-block__item.pc-share-block__item_type_vk {
|
|
30
31
|
background-color: var(--pc-color-vk);
|
|
@@ -9,7 +9,7 @@ import { Twitter } from '../../icons/Twitter';
|
|
|
9
9
|
import { Vk } from '../../icons/Vk';
|
|
10
10
|
import { DefaultEventNames } from '../../models';
|
|
11
11
|
import { block, getAbsolutePath, getShareLink } from '../../utils';
|
|
12
|
-
import i18n from './i18n';
|
|
12
|
+
import { i18n } from './i18n';
|
|
13
13
|
import './Share.css';
|
|
14
14
|
const icons = {
|
|
15
15
|
facebook: Facebook,
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default _default;
|
|
1
|
+
export declare const i18n: (key: "constructor-share" | "facebook-title" | "twitter-title" | "linkedin-title" | "vk-title" | "telegram-title" | "facebook-label" | "twitter-label" | "linkedin-label" | "vk-label" | "telegram-label", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { addComponentKeysets } from '@gravity-ui/uikit/i18n';
|
|
2
|
+
import { NAMESPACE } from '../../../utils/cn';
|
|
2
3
|
import en from './en.json';
|
|
3
4
|
import ru from './ru.json';
|
|
4
|
-
const
|
|
5
|
-
export default registerKeyset({ en, ru }, COMPONENT);
|
|
5
|
+
export const i18n = addComponentKeysets({ en, ru }, `${NAMESPACE}Share`);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import ToggleArrow from '../../../components/ToggleArrow/ToggleArrow';
|
|
3
3
|
import { block } from '../../../utils';
|
|
4
|
-
import i18n from '../i18n';
|
|
4
|
+
import { i18n } from '../i18n';
|
|
5
5
|
import './Arrow.css';
|
|
6
6
|
const b = block('slider-block-arrow');
|
|
7
7
|
const Arrow = ({ type, handleClick, className, size = 16 }) => (React.createElement("div", { className: b({ type }, className) },
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default _default;
|
|
1
|
+
export declare const i18n: (key: "arrow-right" | "arrow-left", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { addComponentKeysets } from '@gravity-ui/uikit/i18n';
|
|
2
|
+
import { NAMESPACE } from '../../../utils/cn';
|
|
2
3
|
import en from './en.json';
|
|
3
4
|
import ru from './ru.json';
|
|
4
|
-
const
|
|
5
|
-
export default registerKeyset({ en, ru }, COMPONENT);
|
|
5
|
+
export const i18n = addComponentKeysets({ en, ru }, `${NAMESPACE}SliderBlock`);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { useCallback, useContext } from 'react';
|
|
2
|
+
import { ArrowLeft } from '@gravity-ui/icons';
|
|
2
3
|
import { Button, Icon } from '@gravity-ui/uikit';
|
|
3
4
|
import { LocationContext } from '../../context/locationContext';
|
|
4
5
|
import { useAnalytics } from '../../hooks';
|
|
5
|
-
import { ArrowSidebar } from '../../icons';
|
|
6
6
|
import { DefaultEventNames } from '../../models';
|
|
7
7
|
export default function BackLink(props) {
|
|
8
8
|
const { history } = useContext(LocationContext);
|
|
@@ -24,6 +24,6 @@ export default function BackLink(props) {
|
|
|
24
24
|
}
|
|
25
25
|
}, [handleAnalytics, history, onClick, url]);
|
|
26
26
|
return (React.createElement(Button, { className: className, view: theme === 'special' ? 'flat-contrast' : 'flat-secondary', size: size, href: shouldHandleBackAction ? undefined : url, onClick: shouldHandleBackAction ? backActionHandler : undefined, tabIndex: tabIndex, extraProps: extraProps },
|
|
27
|
-
React.createElement(Icon, { data:
|
|
27
|
+
React.createElement(Icon, { data: ArrowLeft, size: 20 }),
|
|
28
28
|
React.createElement("span", null, title)));
|
|
29
29
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* use this for style redefinitions to awoid problems with
|
|
2
2
|
unpredictable css rules order in build */
|
|
3
3
|
.pc-button-block {
|
|
4
|
-
--
|
|
4
|
+
--g-button-focus-outline-color: var(--g-color-line-focus);
|
|
5
5
|
}
|
|
6
6
|
.pc-button-block__content {
|
|
7
7
|
display: flex;
|
|
@@ -17,8 +17,6 @@ unpredictable css rules order in build */
|
|
|
17
17
|
.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github {
|
|
18
18
|
--g-button-background-color: var(--pc-monochrome-button-background-color);
|
|
19
19
|
--g-button-background-color-hover: var(--pc-monochrome-button-background-color-hover);
|
|
20
|
-
--yc-button-background-color: var(--pc-monochrome-button-background-color);
|
|
21
|
-
--yc-button-background-color-hover: var(--pc-monochrome-button-background-color-hover);
|
|
22
20
|
}
|
|
23
21
|
.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github, .pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github:link, .pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github:visited, .pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github:active, .pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github.pc-button-block_theme_github:focus {
|
|
24
22
|
color: var(--pc-monochrome-button-color);
|
|
@@ -33,8 +31,6 @@ unpredictable css rules order in build */
|
|
|
33
31
|
.pc-button-block_theme_monochrome.pc-button-block_theme_monochrome {
|
|
34
32
|
--g-button-background-color: var(--pc-monochrome-button-background-color);
|
|
35
33
|
--g-button-background-color-hover: var(--pc-monochrome-button-background-color-hover);
|
|
36
|
-
--yc-button-background-color: var(--pc-monochrome-button-background-color);
|
|
37
|
-
--yc-button-background-color-hover: var(--pc-monochrome-button-background-color-hover);
|
|
38
34
|
}
|
|
39
35
|
.pc-button-block_theme_monochrome.pc-button-block_theme_monochrome, .pc-button-block_theme_monochrome.pc-button-block_theme_monochrome:link, .pc-button-block_theme_monochrome.pc-button-block_theme_monochrome:visited, .pc-button-block_theme_monochrome.pc-button-block_theme_monochrome:active, .pc-button-block_theme_monochrome.pc-button-block_theme_monochrome:focus {
|
|
40
36
|
color: var(--pc-monochrome-button-color);
|
|
@@ -4,27 +4,24 @@ import { StoreBadge } from '@gravity-ui/components';
|
|
|
4
4
|
import { Button as CommonButton, Icon, Platform } from '@gravity-ui/uikit';
|
|
5
5
|
import { LocaleContext } from '../../context/localeContext/localeContext';
|
|
6
6
|
import { useAnalytics } from '../../hooks';
|
|
7
|
-
import { useMetrika } from '../../hooks/useMetrika';
|
|
8
7
|
import { Github } from '../../icons';
|
|
9
8
|
import { DefaultEventNames } from '../../models';
|
|
10
9
|
import { block, setUrlTld } from '../../utils';
|
|
11
|
-
import i18n from './i18n';
|
|
10
|
+
import { i18n } from './i18n';
|
|
12
11
|
import { ICON_QA, toCommonSize, toCommonView } from './utils';
|
|
13
12
|
import './Button.css';
|
|
14
13
|
const b = block('button-block');
|
|
15
14
|
const Button = (props) => {
|
|
16
|
-
const handleMetrika = useMetrika();
|
|
17
15
|
const { tld } = useContext(LocaleContext);
|
|
18
|
-
const { className,
|
|
16
|
+
const { className, analyticsEvents, size = 'l', theme = 'normal', url, urlTitle, img, onClick: onClickOrigin, text, width } = props, rest = __rest(props, ["className", "analyticsEvents", "size", "theme", "url", "urlTitle", "img", "onClick", "text", "width"]);
|
|
19
17
|
const defaultImgPosition = 'left';
|
|
20
18
|
const handleAnalytics = useAnalytics(DefaultEventNames.Button, url);
|
|
21
19
|
const onClick = useCallback((e) => {
|
|
22
|
-
handleMetrika({ metrikaGoals, pixelEvents });
|
|
23
20
|
handleAnalytics(analyticsEvents);
|
|
24
21
|
if (onClickOrigin) {
|
|
25
22
|
onClickOrigin(e);
|
|
26
23
|
}
|
|
27
|
-
}, [
|
|
24
|
+
}, [handleAnalytics, analyticsEvents, onClickOrigin]);
|
|
28
25
|
const buttonModifiers = { size, theme, width };
|
|
29
26
|
const buttonImg = img instanceof Object
|
|
30
27
|
? { url: img.url, position: img.position || defaultImgPosition, alt: img.alt }
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default _default;
|
|
1
|
+
export declare const i18n: (key: "image-alt", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { addComponentKeysets } from '@gravity-ui/uikit/i18n';
|
|
2
|
+
import { NAMESPACE } from '../../../utils/cn';
|
|
2
3
|
import en from './en.json';
|
|
3
4
|
import ru from './ru.json';
|
|
4
|
-
const
|
|
5
|
-
export default registerKeyset({ en, ru }, COMPONENT);
|
|
5
|
+
export const i18n = addComponentKeysets({ en, ru }, `${NAMESPACE}Button`);
|
|
@@ -5,8 +5,6 @@ unpredictable css rules order in build */
|
|
|
5
5
|
margin-bottom: 12px;
|
|
6
6
|
--g-button-background-color: var(--pc-tab-item-background-color);
|
|
7
7
|
--g-button-background-color-hover: var(--pc-tab-item-background-color-hover);
|
|
8
|
-
--yc-button-background-color: var(--pc-tab-item-background-color);
|
|
9
|
-
--yc-button-background-color-hover: var(--pc-tab-item-background-color-hover);
|
|
10
8
|
}
|
|
11
9
|
.pc-button-tabs__item.pc-button-tabs__item, .pc-button-tabs__item.pc-button-tabs__item:link, .pc-button-tabs__item.pc-button-tabs__item:visited, .pc-button-tabs__item.pc-button-tabs__item:active, .pc-button-tabs__item.pc-button-tabs__item:focus {
|
|
12
10
|
color: var(--pc-tab-item-color);
|
|
@@ -18,8 +16,6 @@ unpredictable css rules order in build */
|
|
|
18
16
|
pointer-events: none;
|
|
19
17
|
--g-button-background-color: var(--pc-selected-tab-item-background-color);
|
|
20
18
|
--g-button-background-color-hover: var(--pc-selected-tab-item-background-color-hover);
|
|
21
|
-
--yc-button-background-color: var(--pc-selected-tab-item-background-color);
|
|
22
|
-
--yc-button-background-color-hover: var(--pc-selected-tab-item-background-color-hover);
|
|
23
19
|
}
|
|
24
20
|
.pc-button-tabs__item.pc-button-tabs__item_active, .pc-button-tabs__item.pc-button-tabs__item_active:link, .pc-button-tabs__item.pc-button-tabs__item_active:visited, .pc-button-tabs__item.pc-button-tabs__item_active:active, .pc-button-tabs__item.pc-button-tabs__item_active:focus {
|
|
25
21
|
color: var(--pc-selected-tab-item-color);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { HTMLAttributeAnchorTarget, PropsWithChildren } from 'react';
|
|
2
|
-
import { AnalyticsEventsBase,
|
|
2
|
+
import { AnalyticsEventsBase, CardBaseProps as CardBaseParams, ImageProps, WithChildren } from '../../models';
|
|
3
3
|
import './CardBase.css';
|
|
4
4
|
export interface CardBaseProps extends AnalyticsEventsBase, CardBaseParams, PropsWithChildren {
|
|
5
5
|
className?: string;
|
|
@@ -8,8 +8,6 @@ export interface CardBaseProps extends AnalyticsEventsBase, CardBaseParams, Prop
|
|
|
8
8
|
url?: string;
|
|
9
9
|
urlTitle?: string;
|
|
10
10
|
target?: HTMLAttributeAnchorTarget;
|
|
11
|
-
metrikaGoals?: MetrikaGoal;
|
|
12
|
-
pixelEvents?: ButtonPixel;
|
|
13
11
|
qa?: string;
|
|
14
12
|
extraProps?: React.HTMLAttributes<HTMLElement>;
|
|
15
13
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React, { Children, Fragment, isValidElement, } from 'react';
|
|
2
2
|
import { Link } from '@gravity-ui/uikit';
|
|
3
3
|
import { useAnalytics } from '../../hooks';
|
|
4
|
-
import { useMetrika } from '../../hooks/useMetrika';
|
|
5
4
|
import { DefaultEventNames, } from '../../models';
|
|
6
5
|
import { block, getQaAttrubutes } from '../../utils';
|
|
7
6
|
import BackgroundImage from '../BackgroundImage/BackgroundImage';
|
|
@@ -12,8 +11,7 @@ const Header = () => null;
|
|
|
12
11
|
const Content = () => null;
|
|
13
12
|
const Footer = () => null;
|
|
14
13
|
export const Layout = (props) => {
|
|
15
|
-
const { className, bodyClassName,
|
|
16
|
-
const handleMetrika = useMetrika();
|
|
14
|
+
const { className, bodyClassName, analyticsEvents, contentClassName, children, url, target, border = 'shadow', urlTitle, qa, extraProps = {}, } = props;
|
|
17
15
|
const handleAnalytics = useAnalytics(DefaultEventNames.CardBase, url);
|
|
18
16
|
let header, content, footer, image, headerClass, footerClass;
|
|
19
17
|
const qaAttributes = getQaAttrubutes(qa, 'header', 'footer', 'body', 'content');
|
|
@@ -46,7 +44,6 @@ export const Layout = (props) => {
|
|
|
46
44
|
footer && (React.createElement("div", { className: b('footer', footerClass), "data-qa": qaAttributes.footer }, footer)))));
|
|
47
45
|
const fullClassName = b({ border }, className);
|
|
48
46
|
const onClick = () => {
|
|
49
|
-
handleMetrika({ metrikaGoals, pixelEvents });
|
|
50
47
|
handleAnalytics(analyticsEvents);
|
|
51
48
|
};
|
|
52
49
|
return url ? (React.createElement(RouterLink, { href: url },
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Icon } from '@gravity-ui/uikit';
|
|
3
3
|
import { block } from '../../utils';
|
|
4
|
-
import i18n from './i18n';
|
|
4
|
+
import { i18n } from './i18n';
|
|
5
5
|
import './Control.css';
|
|
6
6
|
const b = block('control');
|
|
7
7
|
export const defaultIconId = 'icon-test-id';
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default _default;
|
|
1
|
+
export declare const i18n: (key: "aria-label", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { addComponentKeysets } from '@gravity-ui/uikit/i18n';
|
|
2
|
+
import { NAMESPACE } from '../../../utils/cn';
|
|
2
3
|
import en from './en.json';
|
|
3
4
|
import ru from './ru.json';
|
|
4
|
-
const
|
|
5
|
-
export default registerKeyset({ en, ru }, COMPONENT);
|
|
5
|
+
export const i18n = addComponentKeysets({ en, ru }, `${NAMESPACE}Control`);
|
|
@@ -13,8 +13,9 @@ unpredictable css rules order in build */
|
|
|
13
13
|
display: flex;
|
|
14
14
|
justify-content: center;
|
|
15
15
|
text-transform: uppercase;
|
|
16
|
+
width: 52px;
|
|
16
17
|
}
|
|
17
|
-
.pc-file-link__file-label .
|
|
18
|
+
.pc-file-link__file-label .g-label__text {
|
|
18
19
|
width: initial;
|
|
19
20
|
}
|
|
20
21
|
.pc-file-link__link > a {
|
|
@@ -31,15 +32,13 @@ unpredictable css rules order in build */
|
|
|
31
32
|
.pc-file-link__link > a:hover {
|
|
32
33
|
color: var(--g-color-text-secondary);
|
|
33
34
|
}
|
|
34
|
-
.pc-file-link_size_l .pc-file-link__file-label {
|
|
35
|
+
.pc-file-link_size_l .pc-file-link__file-label, .pc-file-link_size_m .pc-file-link__file-label {
|
|
35
36
|
font-size: var(--g-text-body-2-font-size);
|
|
36
37
|
line-height: var(--g-text-body-2-line-height);
|
|
37
|
-
width: 52px;
|
|
38
38
|
}
|
|
39
|
-
.pc-file-
|
|
39
|
+
.pc-file-link_size_xs .pc-file-link__file-label, .pc-file-link_size_s .pc-file-link__file-label {
|
|
40
40
|
font-size: var(--g-text-body-1-font-size);
|
|
41
41
|
line-height: var(--g-text-body-1-line-height);
|
|
42
|
-
width: 44px;
|
|
43
42
|
}
|
|
44
43
|
.pc-file-link_theme_dark .pc-file-link__link > a {
|
|
45
44
|
color: var(--g-color-text-light-primary);
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
|
+
import { ChevronsExpandUpRight, Xmark } from '@gravity-ui/icons';
|
|
2
3
|
import { Icon, Modal } from '@gravity-ui/uikit';
|
|
3
|
-
import { Fullscreen, PreviewClose } from '../../icons';
|
|
4
4
|
import { block } from '../../utils';
|
|
5
5
|
import Image from '../Image/Image';
|
|
6
|
-
import i18n from './i18n';
|
|
6
|
+
import { i18n } from './i18n';
|
|
7
7
|
import './FullscreenImage.css';
|
|
8
8
|
const b = block('fullscreen-image');
|
|
9
9
|
const FULL_SCREEN_ICON_SIZE = 18;
|
|
10
|
-
const CLOSE_ICON_SIZE =
|
|
10
|
+
const CLOSE_ICON_SIZE = 24;
|
|
11
11
|
const FullscreenImage = (props) => {
|
|
12
12
|
const { imageClassName, modalImageClass, imageStyle, alt = i18n('img-alt'), extraProps } = props;
|
|
13
13
|
const [isOpened, setIsOpened] = useState(false);
|
|
@@ -17,11 +17,10 @@ const FullscreenImage = (props) => {
|
|
|
17
17
|
React.createElement("div", { className: b('image-wrapper') },
|
|
18
18
|
React.createElement(Image, Object.assign({}, props, { alt: alt, className: b('image', imageClassName), onClick: openModal, style: imageStyle })),
|
|
19
19
|
React.createElement("button", { className: b('icon-wrapper'), onClick: openModal },
|
|
20
|
-
React.createElement(Icon, { data:
|
|
21
|
-
isOpened && (React.createElement(Modal, { open: isOpened, onClose: closeModal, className: b('modal') },
|
|
22
|
-
React.createElement("
|
|
23
|
-
React.createElement(
|
|
24
|
-
|
|
25
|
-
React.createElement(Image, Object.assign({}, props, { className: b('modal-image', modalImageClass) })))))));
|
|
20
|
+
React.createElement(Icon, { data: ChevronsExpandUpRight, width: FULL_SCREEN_ICON_SIZE, height: FULL_SCREEN_ICON_SIZE, className: b('icon') }))),
|
|
21
|
+
isOpened && (React.createElement(Modal, { open: isOpened, onClose: closeModal, className: b('modal'), contentClassName: b('modal-content') },
|
|
22
|
+
React.createElement("button", { className: b('icon-wrapper', { visible: true }), onClick: closeModal, "aria-label": i18n('close') },
|
|
23
|
+
React.createElement(Icon, { data: Xmark, width: CLOSE_ICON_SIZE, height: CLOSE_ICON_SIZE, className: b('icon', { hover: true }) })),
|
|
24
|
+
React.createElement(Image, Object.assign({}, props, { className: b('modal-image', modalImageClass) }))))));
|
|
26
25
|
};
|
|
27
26
|
export default FullscreenImage;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
declare const
|
|
2
|
-
export default _default;
|
|
1
|
+
export declare const i18n: (key: "close" | "img-alt", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { addComponentKeysets } from '@gravity-ui/uikit/i18n';
|
|
2
|
+
import { NAMESPACE } from '../../../utils/cn';
|
|
2
3
|
import en from './en.json';
|
|
3
4
|
import ru from './ru.json';
|
|
4
|
-
const
|
|
5
|
-
export default registerKeyset({ en, ru }, COMPONENT);
|
|
5
|
+
export const i18n = addComponentKeysets({ en, ru }, `${NAMESPACE}FullscreenImage`);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import React, { useContext, useState } from 'react';
|
|
2
|
+
import { ChevronsExpandUpRight, Xmark } from '@gravity-ui/icons';
|
|
2
3
|
import { Button, Icon, Modal } from '@gravity-ui/uikit';
|
|
3
4
|
import { MobileContext } from '../../context/mobileContext';
|
|
4
|
-
import { Fullscreen, PreviewClose } from '../../icons';
|
|
5
5
|
import { block } from '../../utils';
|
|
6
6
|
import './FullscreenMedia.css';
|
|
7
7
|
const b = block('full-screen-media');
|
|
8
8
|
const FULL_SCREEN_ICON_SIZE = 18;
|
|
9
|
-
const CLOSE_ICON_SIZE =
|
|
9
|
+
const CLOSE_ICON_SIZE = 24;
|
|
10
10
|
const getMediaClass = (type) => b('modal-media', { type });
|
|
11
11
|
const FullscreenMedia = ({ children, showFullscreenIcon = true }) => {
|
|
12
12
|
const [isOpened, setIsOpened] = useState(false);
|
|
@@ -23,18 +23,17 @@ const FullscreenMedia = ({ children, showFullscreenIcon = true }) => {
|
|
|
23
23
|
React.createElement("div", { className: b('media-wrapper'), onClickCapture: openModal },
|
|
24
24
|
children({ className: b('inline-media') }),
|
|
25
25
|
showFullscreenIcon && (React.createElement(Button, { className: b('icon-wrapper'), extraProps: { onClickCapture: openModal }, size: 'l' },
|
|
26
|
-
React.createElement(Icon, { data:
|
|
27
|
-
isOpened && (React.createElement(Modal, { open: isOpened, onClose: closeModal, className: b('modal') },
|
|
28
|
-
React.createElement(
|
|
29
|
-
React.createElement(
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
}))))));
|
|
26
|
+
React.createElement(Icon, { data: ChevronsExpandUpRight, width: FULL_SCREEN_ICON_SIZE, height: FULL_SCREEN_ICON_SIZE, className: b('icon') })))),
|
|
27
|
+
isOpened && (React.createElement(Modal, { open: isOpened, onClose: closeModal, className: b('modal'), contentClassName: b('modal-content') },
|
|
28
|
+
React.createElement(Button, { className: b('icon-wrapper', { visible: true }), onClick: closeModal, size: 'l' },
|
|
29
|
+
React.createElement(Icon, { data: Xmark, width: CLOSE_ICON_SIZE, height: CLOSE_ICON_SIZE, className: b('icon', { hover: true }) })),
|
|
30
|
+
children({
|
|
31
|
+
imageClassName: getMediaClass('image'),
|
|
32
|
+
videoClassName: getMediaClass('video'),
|
|
33
|
+
youtubeClassName: getMediaClass('youtube'),
|
|
34
|
+
fullscreen: true,
|
|
35
|
+
previewImg: undefined,
|
|
36
|
+
autoplay: true,
|
|
37
|
+
})))));
|
|
39
38
|
};
|
|
40
39
|
export default FullscreenMedia;
|
|
@@ -1,18 +1,15 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
2
|
import { useAnalytics } from '../../hooks';
|
|
3
|
-
import { useMetrika } from '../../hooks/useMetrika';
|
|
4
3
|
import { DefaultEventNames } from '../../models';
|
|
5
4
|
import { block } from '../../utils';
|
|
6
5
|
import './HeaderBreadcrumbs.css';
|
|
7
6
|
const b = block('header-breadcrumbs');
|
|
8
7
|
export default function HeaderBreadcrumbs(props) {
|
|
9
|
-
const { items,
|
|
10
|
-
const handleMetrika = useMetrika();
|
|
8
|
+
const { items, theme = 'light', className, analyticsEvents } = props;
|
|
11
9
|
const handleAnalytics = useAnalytics(DefaultEventNames.Breadcrumb);
|
|
12
10
|
const onClick = useCallback(() => {
|
|
13
|
-
handleAnalytics();
|
|
14
|
-
|
|
15
|
-
}, [handleAnalytics, handleMetrika, metrikaGoals, pixelEvents]);
|
|
11
|
+
handleAnalytics(analyticsEvents);
|
|
12
|
+
}, [analyticsEvents, handleAnalytics]);
|
|
16
13
|
return (React.createElement("div", { className: b({ theme }, className) }, items === null || items === void 0 ? void 0 : items.map((item) => (React.createElement("div", { className: b('item'), key: item.url },
|
|
17
14
|
React.createElement("a", { href: item.url, className: b('text'), onClick: onClick }, item.text))))));
|
|
18
15
|
}
|