@gravity-ui/page-constructor 4.51.0 → 4.51.2-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/README.md +5 -3
- package/build/cjs/blocks/Banner/schema.d.ts +12 -264
- package/build/cjs/blocks/Banner/schema.js +4 -1
- 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/Header/schema.js +1 -1
- 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.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/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/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/FullscreenImage/FullscreenImage.js +3 -3
- 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/HeaderBreadcrumbs/HeaderBreadcrumbs.js +3 -6
- package/build/cjs/components/Link/Link.js +1 -4
- 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 +3 -3
- package/build/cjs/components/ReactPlayer/ReactPlayer.js +5 -29
- 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/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.js +2 -2
- 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/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/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/models/common.d.ts +2 -53
- package/build/cjs/models/common.js +1 -25
- package/build/cjs/models/constructor-items/common.d.ts +2 -28
- package/build/cjs/models/constructor-items/sub-blocks.d.ts +2 -3
- package/build/cjs/models/guards.d.ts +0 -2
- package/build/cjs/models/guards.js +1 -5
- package/build/cjs/schema/constants.d.ts +4 -176
- package/build/cjs/schema/validators/common.d.ts +1 -188
- package/build/cjs/schema/validators/common.js +2 -32
- 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/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/text-transform/common.d.ts +4 -4
- package/build/cjs/text-transform/transformers.d.ts +2 -2
- package/build/cjs/text-transform/utils.d.ts +6 -6
- package/build/cjs/text-transform/utils.js +5 -5
- 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 +12 -264
- package/build/esm/blocks/Banner/schema.js +5 -2
- 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/Header/schema.js +2 -2
- 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.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/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/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/FullscreenImage/FullscreenImage.js +1 -1
- 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/HeaderBreadcrumbs/HeaderBreadcrumbs.js +3 -6
- package/build/esm/components/Link/Link.js +1 -4
- 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 +1 -1
- package/build/esm/components/ReactPlayer/ReactPlayer.js +4 -28
- 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/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.js +1 -1
- 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/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/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/models/common.d.ts +2 -53
- package/build/esm/models/common.js +0 -24
- package/build/esm/models/constructor-items/common.d.ts +2 -28
- package/build/esm/models/constructor-items/sub-blocks.d.ts +2 -3
- package/build/esm/models/guards.d.ts +0 -2
- package/build/esm/models/guards.js +0 -3
- package/build/esm/schema/constants.d.ts +4 -176
- package/build/esm/schema/validators/common.d.ts +1 -188
- package/build/esm/schema/validators/common.js +1 -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/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/text-transform/common.d.ts +4 -4
- package/build/esm/text-transform/transformers.d.ts +2 -2
- package/build/esm/text-transform/utils.d.ts +6 -6
- package/build/esm/text-transform/utils.js +1 -1
- package/build/esm/utils/index.d.ts +0 -1
- package/build/esm/utils/index.js +0 -1
- package/package.json +1 -1
- package/server/models/common.d.ts +2 -53
- package/server/models/common.js +1 -25
- package/server/models/constructor-items/common.d.ts +2 -28
- package/server/models/constructor-items/sub-blocks.d.ts +2 -3
- package/server/models/guards.d.ts +0 -2
- package/server/models/guards.js +1 -5
- package/server/text-transform/common.d.ts +4 -4
- package/server/text-transform/transformers.d.ts +2 -2
- package/server/text-transform/utils.d.ts +6 -6
- package/server/text-transform/utils.js +5 -5
- package/server/utils/index.d.ts +0 -1
- package/server/utils/index.js +1 -4
- 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/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/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
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { CSSProperties, HTMLProps, ReactNode } from 'react';
|
|
2
2
|
import { ButtonView, ButtonProps as UikitButtonProps } from '@gravity-ui/uikit';
|
|
3
3
|
import { ThemeSupporting } from '../../utils';
|
|
4
|
-
import { AnalyticsEventsBase,
|
|
4
|
+
import { AnalyticsEventsBase, AnalyticsEventsProp, ClassNameProps, QAProps } from '../common';
|
|
5
5
|
export declare enum AuthorType {
|
|
6
6
|
Column = "column",
|
|
7
7
|
Line = "line"
|
|
@@ -124,7 +124,6 @@ export interface MediaVideoProps extends AnalyticsEventsBase {
|
|
|
124
124
|
playButton?: PlayButtonProps;
|
|
125
125
|
controls?: MediaVideoControlsType;
|
|
126
126
|
customControlsOptions?: CustomControlsOptions;
|
|
127
|
-
metrika?: MetrikaVideo;
|
|
128
127
|
ariaLabel?: string;
|
|
129
128
|
}
|
|
130
129
|
export interface LinkProps extends AnalyticsEventsBase, Stylable, Tabbable {
|
|
@@ -136,8 +135,6 @@ export interface LinkProps extends AnalyticsEventsBase, Stylable, Tabbable {
|
|
|
136
135
|
colorTheme?: TextTheme;
|
|
137
136
|
arrow?: boolean;
|
|
138
137
|
target?: string;
|
|
139
|
-
metrikaGoals?: MetrikaGoal;
|
|
140
|
-
pixelEvents?: ButtonPixel;
|
|
141
138
|
extraProps?: HTMLProps<HTMLAnchorElement>;
|
|
142
139
|
}
|
|
143
140
|
export interface FileLinkProps extends ClassNameProps, Tabbable {
|
|
@@ -158,8 +155,6 @@ export interface ButtonProps extends AnalyticsEventsBase, Pick<UikitButtonProps,
|
|
|
158
155
|
primary?: boolean;
|
|
159
156
|
theme?: ButtonTheme;
|
|
160
157
|
img?: ButtonImageProps | string;
|
|
161
|
-
metrikaGoals?: MetrikaGoal;
|
|
162
|
-
pixelEvents?: ButtonPixel;
|
|
163
158
|
target?: string;
|
|
164
159
|
}
|
|
165
160
|
export type ButtonImagePosition = 'left' | 'right';
|
|
@@ -183,7 +178,6 @@ export interface MediaComponentVideoProps extends AnalyticsEventsBase {
|
|
|
183
178
|
video: MediaVideoProps;
|
|
184
179
|
height?: number;
|
|
185
180
|
ratio?: number;
|
|
186
|
-
metrika?: MetrikaVideo;
|
|
187
181
|
previewImg?: string;
|
|
188
182
|
}
|
|
189
183
|
export interface MediaComponentYoutubeProps {
|
|
@@ -237,23 +231,6 @@ export interface YMapMarkerLabel {
|
|
|
237
231
|
}
|
|
238
232
|
export type MapProps = GMapProps | YMapProps;
|
|
239
233
|
export type ThemedMediaProps = ThemeSupporting<MediaProps>;
|
|
240
|
-
export interface NewMetrikaGoal {
|
|
241
|
-
name: string;
|
|
242
|
-
isCrossSite?: boolean;
|
|
243
|
-
counterName?: string;
|
|
244
|
-
params?: Record<string, string>;
|
|
245
|
-
}
|
|
246
|
-
export type MetrikaGoal = string | string[] | NewMetrikaGoal[];
|
|
247
|
-
export interface MetrikaVideo {
|
|
248
|
-
counterName?: string;
|
|
249
|
-
play?: MetrikaGoal;
|
|
250
|
-
stop?: MetrikaGoal;
|
|
251
|
-
}
|
|
252
|
-
export interface ButtonPixelEvent {
|
|
253
|
-
name: PixelEventType;
|
|
254
|
-
data?: Object;
|
|
255
|
-
}
|
|
256
|
-
export type ButtonPixel = ButtonPixelEvent[];
|
|
257
234
|
export interface DataLensObjectProps {
|
|
258
235
|
id: string;
|
|
259
236
|
theme: 'dark' | 'light';
|
|
@@ -278,8 +255,7 @@ export interface HeaderBreadCrumbsProps extends ClassNameProps {
|
|
|
278
255
|
text: ReactNode;
|
|
279
256
|
}[];
|
|
280
257
|
theme?: TextTheme;
|
|
281
|
-
|
|
282
|
-
pixelEvents?: ButtonPixel;
|
|
258
|
+
analyticsEvents?: AnalyticsEventsProp;
|
|
283
259
|
}
|
|
284
260
|
export interface TitleItemProps extends Justifyable, TitleItemBaseProps {
|
|
285
261
|
navTitle?: string;
|
|
@@ -368,8 +344,6 @@ export interface YandexFormProps extends AnalyticsEventsBase {
|
|
|
368
344
|
};
|
|
369
345
|
onSubmit?: () => void;
|
|
370
346
|
onLoad?: () => void;
|
|
371
|
-
metrikaGoals?: string | string[];
|
|
372
|
-
pixelEvents?: string | string[] | PixelEvent | PixelEvent[];
|
|
373
347
|
}
|
|
374
348
|
export interface WithBorder {
|
|
375
349
|
border?: MediaBorder;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ClassNameProps, QuoteType } from '../../models';
|
|
2
2
|
import { ThemeSupporting } from '../../utils';
|
|
3
3
|
import { HubspotEventData, HubspotEventHandlers } from '../../utils/hubspot';
|
|
4
|
-
import { AnalyticsEventsBase
|
|
4
|
+
import { AnalyticsEventsBase } from '../common';
|
|
5
5
|
import { ContentBlockProps } from './blocks';
|
|
6
|
-
import { AuthorItem,
|
|
6
|
+
import { AuthorItem, ButtonProps, CardBaseProps, ContentTheme, DividerSize, ImageObjectProps, ImageProps, LinkProps, MediaProps, MediaView, PriceDetailedProps, TextTheme, Themable, ThemedImage } from './common';
|
|
7
7
|
export declare enum SubBlockType {
|
|
8
8
|
Divider = "divider",
|
|
9
9
|
Quote = "quote",
|
|
@@ -65,7 +65,6 @@ export interface HubspotFormProps extends HubspotEventHandlers, AnalyticsEventsB
|
|
|
65
65
|
* To use this handler for component that is rendered in iframe, set up useLoopBackHubspotEvents hook on top level frame
|
|
66
66
|
*/
|
|
67
67
|
onLoad?: (arg: HubspotEventData) => void;
|
|
68
|
-
pixelEvents?: string | string[] | PixelEvent | PixelEvent[] | ButtonPixel;
|
|
69
68
|
hubspotEvents?: string[];
|
|
70
69
|
createDOMElement?: boolean;
|
|
71
70
|
}
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
import { Block, ConstructorItem, FormBlockData, FormBlockHubspotData, FormBlockYandexData } from './';
|
|
2
|
-
import { MetrikaGoal, NewMetrikaGoal } from './index';
|
|
3
2
|
export declare function isBlock(block: ConstructorItem): block is Block;
|
|
4
|
-
export declare function isNewMetrikaFormat(metrika: MetrikaGoal): metrika is NewMetrikaGoal[];
|
|
5
3
|
export declare function isYandexDataForm(data: FormBlockData): data is FormBlockYandexData;
|
|
6
4
|
export declare function isHubspotDataForm(data: FormBlockData): data is FormBlockHubspotData;
|
|
@@ -1,15 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.isHubspotDataForm = exports.isYandexDataForm = exports.
|
|
3
|
+
exports.isHubspotDataForm = exports.isYandexDataForm = exports.isBlock = void 0;
|
|
4
4
|
const _1 = require("./");
|
|
5
5
|
function isBlock(block) {
|
|
6
6
|
return block.type in _1.BlockTypes;
|
|
7
7
|
}
|
|
8
8
|
exports.isBlock = isBlock;
|
|
9
|
-
function isNewMetrikaFormat(metrika) {
|
|
10
|
-
return Boolean(Array.isArray(metrika) && metrika.length && typeof metrika[0] === 'object');
|
|
11
|
-
}
|
|
12
|
-
exports.isNewMetrikaFormat = isNewMetrikaFormat;
|
|
13
9
|
function isYandexDataForm(data) {
|
|
14
10
|
return Boolean(data.yandex);
|
|
15
11
|
}
|
|
@@ -78,94 +78,6 @@ export declare const cardSchemas: {
|
|
|
78
78
|
optionName: string;
|
|
79
79
|
})[];
|
|
80
80
|
};
|
|
81
|
-
metrikaGoals: {
|
|
82
|
-
oneOf: ({
|
|
83
|
-
type: string;
|
|
84
|
-
optionName: string;
|
|
85
|
-
items?: undefined;
|
|
86
|
-
} | {
|
|
87
|
-
type: string;
|
|
88
|
-
items: {
|
|
89
|
-
type: string;
|
|
90
|
-
additionalProperties?: undefined;
|
|
91
|
-
required?: undefined;
|
|
92
|
-
properties?: undefined;
|
|
93
|
-
};
|
|
94
|
-
optionName: string;
|
|
95
|
-
} | {
|
|
96
|
-
type: string;
|
|
97
|
-
items: {
|
|
98
|
-
type: string;
|
|
99
|
-
additionalProperties: boolean;
|
|
100
|
-
required: string[];
|
|
101
|
-
properties: {
|
|
102
|
-
name: {
|
|
103
|
-
type: string;
|
|
104
|
-
};
|
|
105
|
-
isCrossSite: {
|
|
106
|
-
type: string;
|
|
107
|
-
};
|
|
108
|
-
};
|
|
109
|
-
};
|
|
110
|
-
optionName: string;
|
|
111
|
-
})[];
|
|
112
|
-
};
|
|
113
|
-
pixelEvents: {
|
|
114
|
-
type: string;
|
|
115
|
-
items: {
|
|
116
|
-
type: string;
|
|
117
|
-
required: string[];
|
|
118
|
-
additionalProperties: boolean;
|
|
119
|
-
properties: {
|
|
120
|
-
name: {
|
|
121
|
-
type: string;
|
|
122
|
-
enum: import("../models").PixelEventType[];
|
|
123
|
-
};
|
|
124
|
-
data: {};
|
|
125
|
-
};
|
|
126
|
-
select: {
|
|
127
|
-
$data: string;
|
|
128
|
-
};
|
|
129
|
-
selectCases: {
|
|
130
|
-
SubmitApplication: {
|
|
131
|
-
additionalProperties: boolean;
|
|
132
|
-
properties: {
|
|
133
|
-
name: {};
|
|
134
|
-
};
|
|
135
|
-
};
|
|
136
|
-
Contact: {
|
|
137
|
-
additionalProperties: boolean;
|
|
138
|
-
properties: {
|
|
139
|
-
name: {};
|
|
140
|
-
};
|
|
141
|
-
};
|
|
142
|
-
Lead: {
|
|
143
|
-
additionalProperties: boolean;
|
|
144
|
-
properties: {
|
|
145
|
-
name: {};
|
|
146
|
-
data: {
|
|
147
|
-
type: string;
|
|
148
|
-
additionalProperties: boolean;
|
|
149
|
-
properties: {
|
|
150
|
-
content_category: {
|
|
151
|
-
type: string;
|
|
152
|
-
};
|
|
153
|
-
content_name: {
|
|
154
|
-
type: string;
|
|
155
|
-
};
|
|
156
|
-
currency: {
|
|
157
|
-
type: string;
|
|
158
|
-
};
|
|
159
|
-
value: {
|
|
160
|
-
type: string;
|
|
161
|
-
};
|
|
162
|
-
};
|
|
163
|
-
};
|
|
164
|
-
};
|
|
165
|
-
};
|
|
166
|
-
};
|
|
167
|
-
};
|
|
168
|
-
};
|
|
169
81
|
analyticsEvents: {
|
|
170
82
|
oneOf: ({
|
|
171
83
|
optionName: string;
|
|
@@ -986,6 +898,10 @@ export declare const cardSchemas: {
|
|
|
986
898
|
optionName: string;
|
|
987
899
|
})[];
|
|
988
900
|
};
|
|
901
|
+
mediaView: {
|
|
902
|
+
type: string;
|
|
903
|
+
enum: string[];
|
|
904
|
+
};
|
|
989
905
|
disableCompress: {
|
|
990
906
|
type: string;
|
|
991
907
|
};
|
|
@@ -1062,94 +978,6 @@ export declare const cardSchemas: {
|
|
|
1062
978
|
optionName: string;
|
|
1063
979
|
})[];
|
|
1064
980
|
};
|
|
1065
|
-
metrikaGoals: {
|
|
1066
|
-
oneOf: ({
|
|
1067
|
-
type: string;
|
|
1068
|
-
optionName: string;
|
|
1069
|
-
items?: undefined;
|
|
1070
|
-
} | {
|
|
1071
|
-
type: string;
|
|
1072
|
-
items: {
|
|
1073
|
-
type: string;
|
|
1074
|
-
additionalProperties?: undefined;
|
|
1075
|
-
required?: undefined;
|
|
1076
|
-
properties?: undefined;
|
|
1077
|
-
};
|
|
1078
|
-
optionName: string;
|
|
1079
|
-
} | {
|
|
1080
|
-
type: string;
|
|
1081
|
-
items: {
|
|
1082
|
-
type: string;
|
|
1083
|
-
additionalProperties: boolean;
|
|
1084
|
-
required: string[];
|
|
1085
|
-
properties: {
|
|
1086
|
-
name: {
|
|
1087
|
-
type: string;
|
|
1088
|
-
};
|
|
1089
|
-
isCrossSite: {
|
|
1090
|
-
type: string;
|
|
1091
|
-
};
|
|
1092
|
-
};
|
|
1093
|
-
};
|
|
1094
|
-
optionName: string;
|
|
1095
|
-
})[];
|
|
1096
|
-
};
|
|
1097
|
-
pixelEvents: {
|
|
1098
|
-
type: string;
|
|
1099
|
-
items: {
|
|
1100
|
-
type: string;
|
|
1101
|
-
required: string[];
|
|
1102
|
-
additionalProperties: boolean;
|
|
1103
|
-
properties: {
|
|
1104
|
-
name: {
|
|
1105
|
-
type: string;
|
|
1106
|
-
enum: import("../models").PixelEventType[];
|
|
1107
|
-
};
|
|
1108
|
-
data: {};
|
|
1109
|
-
};
|
|
1110
|
-
select: {
|
|
1111
|
-
$data: string;
|
|
1112
|
-
};
|
|
1113
|
-
selectCases: {
|
|
1114
|
-
SubmitApplication: {
|
|
1115
|
-
additionalProperties: boolean;
|
|
1116
|
-
properties: {
|
|
1117
|
-
name: {};
|
|
1118
|
-
};
|
|
1119
|
-
};
|
|
1120
|
-
Contact: {
|
|
1121
|
-
additionalProperties: boolean;
|
|
1122
|
-
properties: {
|
|
1123
|
-
name: {};
|
|
1124
|
-
};
|
|
1125
|
-
};
|
|
1126
|
-
Lead: {
|
|
1127
|
-
additionalProperties: boolean;
|
|
1128
|
-
properties: {
|
|
1129
|
-
name: {};
|
|
1130
|
-
data: {
|
|
1131
|
-
type: string;
|
|
1132
|
-
additionalProperties: boolean;
|
|
1133
|
-
properties: {
|
|
1134
|
-
content_category: {
|
|
1135
|
-
type: string;
|
|
1136
|
-
};
|
|
1137
|
-
content_name: {
|
|
1138
|
-
type: string;
|
|
1139
|
-
};
|
|
1140
|
-
currency: {
|
|
1141
|
-
type: string;
|
|
1142
|
-
};
|
|
1143
|
-
value: {
|
|
1144
|
-
type: string;
|
|
1145
|
-
};
|
|
1146
|
-
};
|
|
1147
|
-
};
|
|
1148
|
-
};
|
|
1149
|
-
};
|
|
1150
|
-
};
|
|
1151
|
-
};
|
|
1152
|
-
};
|
|
1153
981
|
analyticsEvents: {
|
|
1154
982
|
oneOf: ({
|
|
1155
983
|
optionName: string;
|
|
@@ -20,6 +20,7 @@ export declare const sizeNumber: {
|
|
|
20
20
|
};
|
|
21
21
|
export declare const contentThemes: string[];
|
|
22
22
|
export declare const quoteTypes: QuoteType[];
|
|
23
|
+
export declare const mediaView: string[];
|
|
23
24
|
export declare const customControlsType: CustomControlsType[];
|
|
24
25
|
export declare const customControlsButtonPositioning: CustomControlsButtonPositioning[];
|
|
25
26
|
export declare const BaseProps: {
|
|
@@ -589,100 +590,6 @@ export declare const ButtonProps: {
|
|
|
589
590
|
optionName: string;
|
|
590
591
|
})[];
|
|
591
592
|
};
|
|
592
|
-
/**
|
|
593
|
-
* @deprecated Metrika will be deleted
|
|
594
|
-
*/
|
|
595
|
-
metrikaGoals: {
|
|
596
|
-
oneOf: ({
|
|
597
|
-
type: string;
|
|
598
|
-
optionName: string;
|
|
599
|
-
items?: undefined;
|
|
600
|
-
} | {
|
|
601
|
-
type: string;
|
|
602
|
-
items: {
|
|
603
|
-
type: string;
|
|
604
|
-
additionalProperties?: undefined;
|
|
605
|
-
required?: undefined;
|
|
606
|
-
properties?: undefined;
|
|
607
|
-
};
|
|
608
|
-
optionName: string;
|
|
609
|
-
} | {
|
|
610
|
-
type: string;
|
|
611
|
-
items: {
|
|
612
|
-
type: string;
|
|
613
|
-
additionalProperties: boolean;
|
|
614
|
-
required: string[];
|
|
615
|
-
properties: {
|
|
616
|
-
name: {
|
|
617
|
-
type: string;
|
|
618
|
-
};
|
|
619
|
-
isCrossSite: {
|
|
620
|
-
type: string;
|
|
621
|
-
};
|
|
622
|
-
};
|
|
623
|
-
};
|
|
624
|
-
optionName: string;
|
|
625
|
-
})[];
|
|
626
|
-
};
|
|
627
|
-
/**
|
|
628
|
-
* @deprecated Pixel will be deleted
|
|
629
|
-
*/
|
|
630
|
-
pixelEvents: {
|
|
631
|
-
type: string;
|
|
632
|
-
items: {
|
|
633
|
-
type: string;
|
|
634
|
-
required: string[];
|
|
635
|
-
additionalProperties: boolean;
|
|
636
|
-
properties: {
|
|
637
|
-
name: {
|
|
638
|
-
type: string;
|
|
639
|
-
enum: import("../../models").PixelEventType[];
|
|
640
|
-
};
|
|
641
|
-
data: {};
|
|
642
|
-
};
|
|
643
|
-
select: {
|
|
644
|
-
$data: string;
|
|
645
|
-
};
|
|
646
|
-
selectCases: {
|
|
647
|
-
SubmitApplication: {
|
|
648
|
-
additionalProperties: boolean;
|
|
649
|
-
properties: {
|
|
650
|
-
name: {};
|
|
651
|
-
};
|
|
652
|
-
};
|
|
653
|
-
Contact: {
|
|
654
|
-
additionalProperties: boolean;
|
|
655
|
-
properties: {
|
|
656
|
-
name: {};
|
|
657
|
-
};
|
|
658
|
-
};
|
|
659
|
-
Lead: {
|
|
660
|
-
additionalProperties: boolean;
|
|
661
|
-
properties: {
|
|
662
|
-
name: {};
|
|
663
|
-
data: {
|
|
664
|
-
type: string;
|
|
665
|
-
additionalProperties: boolean;
|
|
666
|
-
properties: {
|
|
667
|
-
content_category: {
|
|
668
|
-
type: string;
|
|
669
|
-
};
|
|
670
|
-
content_name: {
|
|
671
|
-
type: string;
|
|
672
|
-
};
|
|
673
|
-
currency: {
|
|
674
|
-
type: string;
|
|
675
|
-
};
|
|
676
|
-
value: {
|
|
677
|
-
type: string;
|
|
678
|
-
};
|
|
679
|
-
};
|
|
680
|
-
};
|
|
681
|
-
};
|
|
682
|
-
};
|
|
683
|
-
};
|
|
684
|
-
};
|
|
685
|
-
};
|
|
686
593
|
analyticsEvents: {
|
|
687
594
|
oneOf: ({
|
|
688
595
|
optionName: string;
|
|
@@ -932,100 +839,6 @@ export declare const ButtonBlock: {
|
|
|
932
839
|
optionName: string;
|
|
933
840
|
})[];
|
|
934
841
|
};
|
|
935
|
-
/**
|
|
936
|
-
* @deprecated Metrika will be deleted
|
|
937
|
-
*/
|
|
938
|
-
metrikaGoals: {
|
|
939
|
-
oneOf: ({
|
|
940
|
-
type: string;
|
|
941
|
-
optionName: string;
|
|
942
|
-
items?: undefined;
|
|
943
|
-
} | {
|
|
944
|
-
type: string;
|
|
945
|
-
items: {
|
|
946
|
-
type: string;
|
|
947
|
-
additionalProperties?: undefined;
|
|
948
|
-
required?: undefined;
|
|
949
|
-
properties?: undefined;
|
|
950
|
-
};
|
|
951
|
-
optionName: string;
|
|
952
|
-
} | {
|
|
953
|
-
type: string;
|
|
954
|
-
items: {
|
|
955
|
-
type: string;
|
|
956
|
-
additionalProperties: boolean;
|
|
957
|
-
required: string[];
|
|
958
|
-
properties: {
|
|
959
|
-
name: {
|
|
960
|
-
type: string;
|
|
961
|
-
};
|
|
962
|
-
isCrossSite: {
|
|
963
|
-
type: string;
|
|
964
|
-
};
|
|
965
|
-
};
|
|
966
|
-
};
|
|
967
|
-
optionName: string;
|
|
968
|
-
})[];
|
|
969
|
-
};
|
|
970
|
-
/**
|
|
971
|
-
* @deprecated Pixel will be deleted
|
|
972
|
-
*/
|
|
973
|
-
pixelEvents: {
|
|
974
|
-
type: string;
|
|
975
|
-
items: {
|
|
976
|
-
type: string;
|
|
977
|
-
required: string[];
|
|
978
|
-
additionalProperties: boolean;
|
|
979
|
-
properties: {
|
|
980
|
-
name: {
|
|
981
|
-
type: string;
|
|
982
|
-
enum: import("../../models").PixelEventType[];
|
|
983
|
-
};
|
|
984
|
-
data: {};
|
|
985
|
-
};
|
|
986
|
-
select: {
|
|
987
|
-
$data: string;
|
|
988
|
-
};
|
|
989
|
-
selectCases: {
|
|
990
|
-
SubmitApplication: {
|
|
991
|
-
additionalProperties: boolean;
|
|
992
|
-
properties: {
|
|
993
|
-
name: {};
|
|
994
|
-
};
|
|
995
|
-
};
|
|
996
|
-
Contact: {
|
|
997
|
-
additionalProperties: boolean;
|
|
998
|
-
properties: {
|
|
999
|
-
name: {};
|
|
1000
|
-
};
|
|
1001
|
-
};
|
|
1002
|
-
Lead: {
|
|
1003
|
-
additionalProperties: boolean;
|
|
1004
|
-
properties: {
|
|
1005
|
-
name: {};
|
|
1006
|
-
data: {
|
|
1007
|
-
type: string;
|
|
1008
|
-
additionalProperties: boolean;
|
|
1009
|
-
properties: {
|
|
1010
|
-
content_category: {
|
|
1011
|
-
type: string;
|
|
1012
|
-
};
|
|
1013
|
-
content_name: {
|
|
1014
|
-
type: string;
|
|
1015
|
-
};
|
|
1016
|
-
currency: {
|
|
1017
|
-
type: string;
|
|
1018
|
-
};
|
|
1019
|
-
value: {
|
|
1020
|
-
type: string;
|
|
1021
|
-
};
|
|
1022
|
-
};
|
|
1023
|
-
};
|
|
1024
|
-
};
|
|
1025
|
-
};
|
|
1026
|
-
};
|
|
1027
|
-
};
|
|
1028
|
-
};
|
|
1029
842
|
analyticsEvents: {
|
|
1030
843
|
oneOf: ({
|
|
1031
844
|
optionName: string;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.BlockHeaderProps = exports.CardBase = exports.BorderProps = exports.MapProps = exports.YMapMarker = exports.YMapMarkerLabel = exports.MediaProps = exports.ButtonBlock = exports.TitleProps = exports.BlockBaseProps = exports.AnchorProps = exports.withTheme = exports.MenuProps = exports.ButtonProps = exports.authorItem = exports.FileLinkProps = exports.LinkProps = exports.BackgroundProps = exports.DataLensProps = exports.DataLensObjectProps = exports.JustifyProps = exports.ThemeProps = exports.VideoProps = exports.CustomControlsOptionsProps = exports.PlayButtonProps = exports.LoopProps = exports.ChildrenCardsProps = exports.ChildrenProps = exports.AnimatableProps = exports.sliderSizesObject = exports.containerSizesObject = exports.BaseProps = exports.customControlsButtonPositioning = exports.customControlsType = exports.quoteTypes = exports.contentThemes = exports.sizeNumber = exports.dividerEnum = exports.fileLinkTypes = exports.videoControlsTypes = exports.playIconThemes = exports.playIconTypes = exports.videoTypes = exports.contentTextWidth = exports.contentSizes = exports.sliderSizesArray = exports.containerSizesArray = exports.textSize = exports.mediaDirection = void 0;
|
|
3
|
+
exports.BlockHeaderProps = exports.CardBase = exports.BorderProps = exports.MapProps = exports.YMapMarker = exports.YMapMarkerLabel = exports.MediaProps = exports.ButtonBlock = exports.TitleProps = exports.BlockBaseProps = exports.AnchorProps = exports.withTheme = exports.MenuProps = exports.ButtonProps = exports.authorItem = exports.FileLinkProps = exports.LinkProps = exports.BackgroundProps = exports.DataLensProps = exports.DataLensObjectProps = exports.JustifyProps = exports.ThemeProps = exports.VideoProps = exports.CustomControlsOptionsProps = exports.PlayButtonProps = exports.LoopProps = exports.ChildrenCardsProps = exports.ChildrenProps = exports.AnimatableProps = exports.sliderSizesObject = exports.containerSizesObject = exports.BaseProps = exports.customControlsButtonPositioning = exports.customControlsType = exports.mediaView = exports.quoteTypes = exports.contentThemes = exports.sizeNumber = exports.dividerEnum = exports.fileLinkTypes = exports.videoControlsTypes = exports.playIconThemes = exports.playIconTypes = exports.videoTypes = exports.contentTextWidth = exports.contentSizes = exports.sliderSizesArray = exports.containerSizesArray = exports.textSize = exports.mediaDirection = void 0;
|
|
4
4
|
const schema_1 = require("../../components/Image/schema");
|
|
5
5
|
const models_1 = require("../../models");
|
|
6
6
|
const event_1 = require("./event");
|
|
7
|
-
const pixel_1 = require("./pixel");
|
|
8
7
|
exports.mediaDirection = ['media-content', 'content-media'];
|
|
9
8
|
exports.textSize = ['s', 'm', 'l'];
|
|
10
9
|
exports.containerSizesArray = ['sm', 'md', 'lg', 'xl', 'all'];
|
|
@@ -20,6 +19,7 @@ exports.dividerEnum = { enum: ['0', 'xxs', 'xs', 's', 'm', 'l', 'xl', 'xxl', 'xx
|
|
|
20
19
|
exports.sizeNumber = { type: 'number', maximum: 12, minimum: 1 };
|
|
21
20
|
exports.contentThemes = ['default', 'dark', 'light'];
|
|
22
21
|
exports.quoteTypes = Object.values(models_1.QuoteType);
|
|
22
|
+
exports.mediaView = ['fit', 'full'];
|
|
23
23
|
exports.customControlsType = [
|
|
24
24
|
models_1.CustomControlsType.WithMuteButton,
|
|
25
25
|
models_1.CustomControlsType.WithPlayPauseButton,
|
|
@@ -367,36 +367,6 @@ exports.ButtonProps = {
|
|
|
367
367
|
},
|
|
368
368
|
],
|
|
369
369
|
},
|
|
370
|
-
/**
|
|
371
|
-
* @deprecated Metrika will be deleted
|
|
372
|
-
*/
|
|
373
|
-
metrikaGoals: {
|
|
374
|
-
oneOf: [
|
|
375
|
-
{ type: 'string', optionName: 'single' },
|
|
376
|
-
{ type: 'array', items: { type: 'string' }, optionName: 'list' },
|
|
377
|
-
{
|
|
378
|
-
type: 'array',
|
|
379
|
-
items: {
|
|
380
|
-
type: 'object',
|
|
381
|
-
additionalProperties: false,
|
|
382
|
-
required: ['name'],
|
|
383
|
-
properties: {
|
|
384
|
-
name: {
|
|
385
|
-
type: 'string',
|
|
386
|
-
},
|
|
387
|
-
isCrossSite: {
|
|
388
|
-
type: 'boolean',
|
|
389
|
-
},
|
|
390
|
-
},
|
|
391
|
-
},
|
|
392
|
-
optionName: 'list-extended',
|
|
393
|
-
},
|
|
394
|
-
],
|
|
395
|
-
},
|
|
396
|
-
/**
|
|
397
|
-
* @deprecated Pixel will be deleted
|
|
398
|
-
*/
|
|
399
|
-
pixelEvents: pixel_1.pixelEvents,
|
|
400
370
|
analyticsEvents: {
|
|
401
371
|
oneOf: [
|
|
402
372
|
Object.assign(Object.assign({}, event_1.AnalyticsEventSchema), { optionName: 'single' }),
|
|
@@ -2,7 +2,6 @@ import * as blocks from './blocks';
|
|
|
2
2
|
import * as common from './common';
|
|
3
3
|
import * as components from './components';
|
|
4
4
|
import * as navigation from './navigation';
|
|
5
|
-
import * as pixel from './pixel';
|
|
6
5
|
import * as subBlocks from './sub-blocks';
|
|
7
6
|
import * as utils from './utils';
|
|
8
7
|
export declare const validators: {
|
|
@@ -10,7 +9,6 @@ export declare const validators: {
|
|
|
10
9
|
common: typeof common;
|
|
11
10
|
components: typeof components;
|
|
12
11
|
subBlocks: typeof subBlocks;
|
|
13
|
-
pixel: typeof pixel;
|
|
14
12
|
utils: typeof utils;
|
|
15
13
|
navigation: typeof navigation;
|
|
16
14
|
};
|
|
@@ -6,7 +6,6 @@ const blocks = tslib_1.__importStar(require("./blocks"));
|
|
|
6
6
|
const common = tslib_1.__importStar(require("./common"));
|
|
7
7
|
const components = tslib_1.__importStar(require("./components"));
|
|
8
8
|
const navigation = tslib_1.__importStar(require("./navigation"));
|
|
9
|
-
const pixel = tslib_1.__importStar(require("./pixel"));
|
|
10
9
|
const subBlocks = tslib_1.__importStar(require("./sub-blocks"));
|
|
11
10
|
const utils = tslib_1.__importStar(require("./utils"));
|
|
12
11
|
exports.validators = {
|
|
@@ -14,7 +13,6 @@ exports.validators = {
|
|
|
14
13
|
common,
|
|
15
14
|
components,
|
|
16
15
|
subBlocks,
|
|
17
|
-
pixel,
|
|
18
16
|
utils,
|
|
19
17
|
navigation,
|
|
20
18
|
};
|
|
@@ -5,16 +5,14 @@ const react_1 = tslib_1.__importStar(require("react"));
|
|
|
5
5
|
const mobileContext_1 = require("../../context/mobileContext");
|
|
6
6
|
const theme_1 = require("../../context/theme");
|
|
7
7
|
const hooks_1 = require("../../hooks");
|
|
8
|
-
const useMetrika_1 = require("../../hooks/useMetrika");
|
|
9
8
|
const models_1 = require("../../models");
|
|
10
9
|
const utils_1 = require("../../utils");
|
|
11
10
|
const HubspotFormContainer_1 = tslib_1.__importDefault(require("./HubspotFormContainer"));
|
|
12
11
|
const b = (0, utils_1.block)('hubspot-form');
|
|
13
12
|
const HubspotForm = (0, react_1.forwardRef)((props, ref) => {
|
|
14
|
-
const { className, theme: themeProp, isMobile: isMobileProp, formId, formInstanceId, portalId, region, formClassName,
|
|
13
|
+
const { className, theme: themeProp, isMobile: isMobileProp, formId, formInstanceId, portalId, region, formClassName,
|
|
15
14
|
// hubspotEvents, // TODO: decide how to handle them
|
|
16
15
|
analyticsEvents, onBeforeSubmit, onSubmit, onBeforeLoad, onLoad, createDOMElement, onSubmitError, } = props;
|
|
17
|
-
const handleMetrika = (0, useMetrika_1.useMetrika)();
|
|
18
16
|
const themeValue = (0, theme_1.useTheme)();
|
|
19
17
|
const handleAnalytics = (0, hooks_1.useAnalytics)(models_1.DefaultEventNames.HubspotFormSubmit);
|
|
20
18
|
const isMobileValue = (0, react_1.useContext)(mobileContext_1.MobileContext);
|
|
@@ -26,7 +24,6 @@ const HubspotForm = (0, react_1.forwardRef)((props, ref) => {
|
|
|
26
24
|
onLoad,
|
|
27
25
|
onSubmitError,
|
|
28
26
|
onSubmit: (event) => {
|
|
29
|
-
handleMetrika === null || handleMetrika === void 0 ? void 0 : handleMetrika({ pixelEvents });
|
|
30
27
|
handleAnalytics(analyticsEvents);
|
|
31
28
|
onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(event);
|
|
32
29
|
},
|
|
@@ -34,8 +31,6 @@ const HubspotForm = (0, react_1.forwardRef)((props, ref) => {
|
|
|
34
31
|
onBeforeLoad,
|
|
35
32
|
onBeforeSubmit,
|
|
36
33
|
onLoad,
|
|
37
|
-
handleMetrika,
|
|
38
|
-
pixelEvents,
|
|
39
34
|
handleAnalytics,
|
|
40
35
|
analyticsEvents,
|
|
41
36
|
onSubmit,
|