@gravity-ui/page-constructor 4.6.1 → 4.8.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/components/Media/Video/Video.js +2 -2
- package/build/cjs/components/ReactPlayer/CustomBarControls.css +46 -14
- package/build/cjs/components/ReactPlayer/CustomBarControls.d.ts +4 -1
- package/build/cjs/components/ReactPlayer/CustomBarControls.js +33 -9
- package/build/cjs/components/ReactPlayer/ReactPlayer.css +12 -0
- package/build/cjs/components/ReactPlayer/ReactPlayer.js +48 -26
- package/build/cjs/components/ReactPlayer/i18n/en.json +4 -1
- package/build/cjs/components/ReactPlayer/i18n/ru.json +4 -1
- package/build/cjs/components/YFMWrapper/YFMWrapper.js +2 -2
- package/build/cjs/containers/Loadable/Loadable.js +2 -2
- package/build/cjs/containers/PageConstructor/PageConstructor.js +1 -2
- package/build/cjs/icons/Mute.d.ts +2 -0
- package/build/cjs/icons/Mute.js +12 -0
- package/build/cjs/icons/MuteSmall.d.ts +2 -0
- package/build/cjs/icons/MuteSmall.js +15 -0
- package/build/cjs/icons/Unmute.d.ts +2 -0
- package/build/cjs/icons/Unmute.js +12 -0
- package/build/cjs/icons/UnmuteSmall.d.ts +2 -0
- package/build/cjs/icons/UnmuteSmall.js +17 -0
- package/build/cjs/icons/VideoControlPause.d.ts +2 -0
- package/build/cjs/icons/VideoControlPause.js +16 -0
- package/build/cjs/icons/VideoControlPlay.d.ts +2 -0
- package/build/cjs/icons/VideoControlPlay.js +12 -0
- package/build/cjs/models/constructor-items/common.d.ts +9 -30
- package/build/cjs/models/constructor-items/common.js +6 -1
- package/build/cjs/sub-blocks/HubspotForm/HubspotForm.css +2 -2
- package/build/cjs/utils/cn.d.ts +3 -3
- package/build/cjs/utils/cn.js +4 -7
- package/build/esm/components/Media/Video/Video.js +2 -2
- package/build/esm/components/ReactPlayer/CustomBarControls.css +46 -14
- package/build/esm/components/ReactPlayer/CustomBarControls.d.ts +4 -1
- package/build/esm/components/ReactPlayer/CustomBarControls.js +34 -10
- package/build/esm/components/ReactPlayer/ReactPlayer.css +12 -0
- package/build/esm/components/ReactPlayer/ReactPlayer.js +49 -27
- package/build/esm/components/ReactPlayer/i18n/en.json +4 -1
- package/build/esm/components/ReactPlayer/i18n/ru.json +4 -1
- package/build/esm/components/YFMWrapper/YFMWrapper.js +2 -2
- package/build/esm/containers/Loadable/Loadable.js +1 -1
- package/build/esm/containers/PageConstructor/PageConstructor.js +1 -2
- package/build/esm/icons/Mute.d.ts +2 -0
- package/build/esm/icons/Mute.js +7 -0
- package/build/esm/icons/MuteSmall.d.ts +2 -0
- package/build/esm/icons/MuteSmall.js +10 -0
- package/build/esm/icons/Unmute.d.ts +2 -0
- package/build/esm/icons/Unmute.js +7 -0
- package/build/esm/icons/UnmuteSmall.d.ts +2 -0
- package/build/esm/icons/UnmuteSmall.js +12 -0
- package/build/esm/icons/VideoControlPause.d.ts +2 -0
- package/build/esm/icons/VideoControlPause.js +11 -0
- package/build/esm/icons/VideoControlPlay.d.ts +2 -0
- package/build/esm/icons/VideoControlPlay.js +7 -0
- package/build/esm/models/constructor-items/common.d.ts +9 -30
- package/build/esm/models/constructor-items/common.js +5 -0
- package/build/esm/sub-blocks/HubspotForm/HubspotForm.css +2 -2
- package/build/esm/utils/cn.d.ts +3 -3
- package/build/esm/utils/cn.js +3 -4
- package/package.json +4 -5
- package/server/models/constructor-items/common.d.ts +9 -30
- package/server/models/constructor-items/common.js +6 -1
- package/server/utils/cn.d.ts +3 -3
- package/server/utils/cn.js +4 -9
- package/widget/index.js +1 -1
|
@@ -268,9 +268,9 @@ unpredictable css rules order in build */
|
|
|
268
268
|
.pc-hubspot-form .hs-button.primary {
|
|
269
269
|
margin: 0;
|
|
270
270
|
padding: 0;
|
|
271
|
-
font-family: var(--g-font-family
|
|
271
|
+
font-family: var(--g-text-body-font-family);
|
|
272
272
|
font-size: inherit;
|
|
273
|
-
font-weight:
|
|
273
|
+
font-weight: var(--g-text-body-font-weight);
|
|
274
274
|
color: inherit;
|
|
275
275
|
background: none;
|
|
276
276
|
border: none;
|
package/build/esm/utils/cn.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import blockOrigin from 'bem-cn-lite';
|
|
2
1
|
export declare const NAMESPACE = "pc-";
|
|
3
|
-
export
|
|
4
|
-
export declare
|
|
2
|
+
export declare const cn: import("@bem-react/classname").ClassNameInitilizer;
|
|
3
|
+
export declare const block: import("@bem-react/classname").ClassNameInitilizer;
|
|
4
|
+
export type CnBlock = ReturnType<typeof cn>;
|
package/build/esm/utils/cn.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { withNaming } from '@bem-react/classname';
|
|
2
2
|
export const NAMESPACE = 'pc-';
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
}
|
|
3
|
+
export const cn = withNaming({ e: '__', m: '_' });
|
|
4
|
+
export const block = withNaming({ n: NAMESPACE, e: '__', m: '_' });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gravity-ui/page-constructor",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.8.0",
|
|
4
4
|
"description": "Gravity UI Page Constructor",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -80,11 +80,11 @@
|
|
|
80
80
|
"test:watch": "jest --watchAll"
|
|
81
81
|
},
|
|
82
82
|
"dependencies": {
|
|
83
|
-
"@
|
|
83
|
+
"@bem-react/classname": "^1.6.0",
|
|
84
|
+
"@gravity-ui/components": "^2.4.0",
|
|
84
85
|
"@gravity-ui/dynamic-forms": "^2.3.0",
|
|
85
86
|
"@gravity-ui/i18n": "^1.0.0",
|
|
86
87
|
"ajv": "^8.12.0",
|
|
87
|
-
"bem-cn-lite": "^4.0.0",
|
|
88
88
|
"final-form": "^4.20.9",
|
|
89
89
|
"github-buttons": "2.23.0",
|
|
90
90
|
"lodash": "^4.17.21",
|
|
@@ -120,7 +120,7 @@
|
|
|
120
120
|
"@gravity-ui/prettier-config": "^1.0.1",
|
|
121
121
|
"@gravity-ui/stylelint-config": "^1.0.0",
|
|
122
122
|
"@gravity-ui/tsconfig": "^1.0.0",
|
|
123
|
-
"@gravity-ui/uikit": "^5.
|
|
123
|
+
"@gravity-ui/uikit": "^5.9.1",
|
|
124
124
|
"@storybook/addon-actions": "^7.1.0",
|
|
125
125
|
"@storybook/addon-essentials": "^7.1.0",
|
|
126
126
|
"@storybook/addon-knobs": "^7.0.2",
|
|
@@ -147,7 +147,6 @@
|
|
|
147
147
|
"css-loader": "^5.2.7",
|
|
148
148
|
"es5-ext": "0.10.53",
|
|
149
149
|
"eslint": "^8.34.0",
|
|
150
|
-
"eslint-plugin-local": "./eslint-plugin-local",
|
|
151
150
|
"eslint-plugin-no-not-accumulator-reassign": "^0.1.0",
|
|
152
151
|
"eslint-plugin-react": "^7.33.0",
|
|
153
152
|
"eslint-plugin-testing-library": "^5.9.1",
|
|
@@ -25,6 +25,10 @@ export declare enum PlayButtonThemes {
|
|
|
25
25
|
Blue = "blue",
|
|
26
26
|
Grey = "grey"
|
|
27
27
|
}
|
|
28
|
+
export declare enum CustomControlsType {
|
|
29
|
+
WithMuteButton = "with-mute-button",
|
|
30
|
+
WithPlayPauseButton = "with-play-pause-button"
|
|
31
|
+
}
|
|
28
32
|
export declare enum MediaVideoType {
|
|
29
33
|
Default = "default",
|
|
30
34
|
Player = "player"
|
|
@@ -110,7 +114,9 @@ export interface MediaVideoProps extends AnalyticsEventsBase {
|
|
|
110
114
|
elapsedTime?: number;
|
|
111
115
|
playButton?: PlayButtonProps;
|
|
112
116
|
controls?: MediaVideoControlsType;
|
|
117
|
+
customControlsOptions?: CustomControlsOptions;
|
|
113
118
|
metrika?: MetrikaVideo;
|
|
119
|
+
ariaLabel?: string;
|
|
114
120
|
}
|
|
115
121
|
export interface LinkProps extends AnalyticsEventsBase, Stylable, Tabbable {
|
|
116
122
|
url: string;
|
|
@@ -148,23 +154,14 @@ export interface ButtonImageProps {
|
|
|
148
154
|
position?: ButtonImagePosition;
|
|
149
155
|
alt?: string;
|
|
150
156
|
}
|
|
157
|
+
export interface CustomControlsOptions {
|
|
158
|
+
type?: CustomControlsType;
|
|
159
|
+
}
|
|
151
160
|
export interface PlayButtonProps extends ClassNameProps {
|
|
152
161
|
type?: PlayButtonType;
|
|
153
162
|
theme?: PlayButtonThemes;
|
|
154
163
|
text?: string;
|
|
155
164
|
}
|
|
156
|
-
export interface MediaVideoProps {
|
|
157
|
-
src: string[];
|
|
158
|
-
type?: MediaVideoType;
|
|
159
|
-
loop?: LoopProps | boolean;
|
|
160
|
-
muted?: boolean;
|
|
161
|
-
autoplay?: boolean;
|
|
162
|
-
elapsedTime?: number;
|
|
163
|
-
playButton?: PlayButtonProps;
|
|
164
|
-
controls?: MediaVideoControlsType;
|
|
165
|
-
metrika?: MetrikaVideo;
|
|
166
|
-
ariaLabel?: string;
|
|
167
|
-
}
|
|
168
165
|
export type ThemedMediaVideoProps = ThemeSupporting<MediaVideoProps>;
|
|
169
166
|
export interface MediaComponentVideoProps extends AnalyticsEventsBase {
|
|
170
167
|
video: MediaVideoProps;
|
|
@@ -315,24 +312,6 @@ export interface PriceDetailedProps extends CardBaseProps {
|
|
|
315
312
|
foldable?: PriceFoldableDetailsProps;
|
|
316
313
|
labelsDefaultText?: Record<PriceLabelColor, string>;
|
|
317
314
|
}
|
|
318
|
-
export interface PriceDetailedProps extends CardBaseProps {
|
|
319
|
-
items: PriceItemProps[];
|
|
320
|
-
description?: {
|
|
321
|
-
titleSize?: TextSize;
|
|
322
|
-
descriptionSize?: TextSize;
|
|
323
|
-
titleColor?: PriceDescriptionColor;
|
|
324
|
-
};
|
|
325
|
-
details?: {
|
|
326
|
-
titleSize?: TextSize;
|
|
327
|
-
descriptionSize?: TextSize;
|
|
328
|
-
};
|
|
329
|
-
priceType?: PriceDetailsType;
|
|
330
|
-
numberGroupItems?: 3 | 4 | 5;
|
|
331
|
-
isCombined?: boolean;
|
|
332
|
-
useMixedView?: boolean;
|
|
333
|
-
foldable?: PriceFoldableDetailsProps;
|
|
334
|
-
labelsDefaultText?: Record<PriceLabelColor, string>;
|
|
335
|
-
}
|
|
336
315
|
export interface AuthorProps extends QAProps {
|
|
337
316
|
author: AuthorItem;
|
|
338
317
|
className?: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.MediaVideoControlsType = exports.MediaVideoType = exports.PlayButtonThemes = exports.PlayButtonType = exports.PriceLabelColor = exports.PriceDetailsType = exports.AuthorType = void 0;
|
|
3
|
+
exports.MediaVideoControlsType = exports.MediaVideoType = exports.CustomControlsType = exports.PlayButtonThemes = exports.PlayButtonType = exports.PriceLabelColor = exports.PriceDetailsType = exports.AuthorType = void 0;
|
|
4
4
|
// enums
|
|
5
5
|
var AuthorType;
|
|
6
6
|
(function (AuthorType) {
|
|
@@ -30,6 +30,11 @@ var PlayButtonThemes;
|
|
|
30
30
|
PlayButtonThemes["Blue"] = "blue";
|
|
31
31
|
PlayButtonThemes["Grey"] = "grey";
|
|
32
32
|
})(PlayButtonThemes = exports.PlayButtonThemes || (exports.PlayButtonThemes = {}));
|
|
33
|
+
var CustomControlsType;
|
|
34
|
+
(function (CustomControlsType) {
|
|
35
|
+
CustomControlsType["WithMuteButton"] = "with-mute-button";
|
|
36
|
+
CustomControlsType["WithPlayPauseButton"] = "with-play-pause-button";
|
|
37
|
+
})(CustomControlsType = exports.CustomControlsType || (exports.CustomControlsType = {}));
|
|
33
38
|
var MediaVideoType;
|
|
34
39
|
(function (MediaVideoType) {
|
|
35
40
|
MediaVideoType["Default"] = "default";
|
package/server/utils/cn.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import blockOrigin from 'bem-cn-lite';
|
|
2
1
|
export declare const NAMESPACE = "pc-";
|
|
3
|
-
export
|
|
4
|
-
export declare
|
|
2
|
+
export declare const cn: import("@bem-react/classname").ClassNameInitilizer;
|
|
3
|
+
export declare const block: import("@bem-react/classname").ClassNameInitilizer;
|
|
4
|
+
export type CnBlock = ReturnType<typeof cn>;
|
package/server/utils/cn.js
CHANGED
|
@@ -1,12 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.block = exports.NAMESPACE = void 0;
|
|
7
|
-
const
|
|
3
|
+
exports.block = exports.cn = exports.NAMESPACE = void 0;
|
|
4
|
+
const classname_1 = require("@bem-react/classname");
|
|
8
5
|
exports.NAMESPACE = 'pc-';
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
exports.block = block;
|
|
6
|
+
exports.cn = (0, classname_1.withNaming)({ e: '__', m: '_' });
|
|
7
|
+
exports.block = (0, classname_1.withNaming)({ n: exports.NAMESPACE, e: '__', m: '_' });
|