@gravity-ui/page-constructor 5.23.2 → 5.23.3
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/DefaultVideo/DefaultVideo.js +3 -3
- package/build/cjs/components/HeaderBreadcrumbs/HeaderBreadcrumbs.css +14 -11
- package/build/cjs/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +4 -2
- package/build/esm/components/DefaultVideo/DefaultVideo.js +3 -3
- package/build/esm/components/HeaderBreadcrumbs/HeaderBreadcrumbs.css +14 -11
- package/build/esm/components/HeaderBreadcrumbs/HeaderBreadcrumbs.js +4 -2
- package/package.json +1 -1
- package/widget/index.js +1 -1
|
@@ -2,8 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DefaultVideo = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
|
-
/* eslint-disable jsx-a11y/media-has-caption */
|
|
6
|
-
// TODO fix in https://github.com/gravity-ui/page-constructor/issues/967
|
|
7
5
|
const react_1 = tslib_1.__importStar(require("react"));
|
|
8
6
|
const models_1 = require("../../models");
|
|
9
7
|
const utils_1 = require("../../utils");
|
|
@@ -53,7 +51,9 @@ exports.DefaultVideo = react_1.default.forwardRef((props, ref) => {
|
|
|
53
51
|
react_1.default.createElement("video", { disablePictureInPicture: true, playsInline: true,
|
|
54
52
|
// @ts-ignore
|
|
55
53
|
// eslint-disable-next-line react/no-unknown-property
|
|
56
|
-
pip: "false", className: b(), ref: videoRef, preload: "metadata", muted: isMuted, "aria-label": video.ariaLabel, onClick: onClick },
|
|
54
|
+
pip: "false", className: b(), ref: videoRef, preload: "metadata", muted: isMuted, "aria-label": video.ariaLabel, onClick: onClick },
|
|
55
|
+
(0, utils_2.getVideoTypesWithPriority)(video.src).map(({ src, type }, index) => (react_1.default.createElement("source", { key: index, src: src, type: type, "data-qa": qa }))),
|
|
56
|
+
react_1.default.createElement("track", { default: true, kind: "captions" })),
|
|
57
57
|
controls === models_1.MediaVideoControlsType.Custom && (react_1.default.createElement(CustomBarControls_1.default, { className: customBarControlsClassName, type: customControlsType, isPaused: isPaused, onPlayClick: onPlayToggle, muteButtonShown: muteButtonShown, shown: true, positioning: positioning, mute: {
|
|
58
58
|
isMuted: Boolean(isMuted),
|
|
59
59
|
changeMute: onMuteToggle,
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
@charset "UTF-8";
|
|
2
1
|
/* use this for style redefinitions to awoid problems with
|
|
3
2
|
unpredictable css rules order in build */
|
|
4
3
|
.pc-header-breadcrumbs {
|
|
5
4
|
z-index: 11;
|
|
6
5
|
}
|
|
6
|
+
.pc-header-breadcrumbs__list {
|
|
7
|
+
margin: 0;
|
|
8
|
+
padding: 0;
|
|
9
|
+
list-style: none;
|
|
10
|
+
}
|
|
7
11
|
.pc-header-breadcrumbs__item {
|
|
12
|
+
font-size: var(--g-text-body-2-font-size);
|
|
13
|
+
line-height: var(--g-text-body-2-line-height);
|
|
8
14
|
display: inline-block;
|
|
9
15
|
}
|
|
10
16
|
.pc-header-breadcrumbs__text {
|
|
11
|
-
font-size: var(--g-text-body-2-font-size);
|
|
12
|
-
line-height: var(--g-text-body-2-line-height);
|
|
13
17
|
outline: none;
|
|
14
18
|
color: var(--g-color-text-link);
|
|
15
19
|
text-decoration: none;
|
|
@@ -23,20 +27,19 @@ unpredictable css rules order in build */
|
|
|
23
27
|
--pc-text-header-color: var(--g-color-text-link-hover);
|
|
24
28
|
color: var(--g-color-text-link-hover);
|
|
25
29
|
}
|
|
26
|
-
.pc-header-breadcrumbs__text:after {
|
|
27
|
-
content: " / ";
|
|
28
|
-
margin: 0 8px 0 6px;
|
|
29
|
-
color: var(--g-color-text-secondary);
|
|
30
|
-
}
|
|
31
30
|
.pc-header-breadcrumbs__text:hover {
|
|
32
31
|
color: var(--g-color-text-primary);
|
|
33
32
|
}
|
|
34
|
-
.pc-header-
|
|
35
|
-
|
|
33
|
+
.pc-header-breadcrumbs__separator {
|
|
34
|
+
margin: 0 8px 0 6px;
|
|
35
|
+
color: var(--g-color-text-secondary);
|
|
36
36
|
}
|
|
37
|
-
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__text
|
|
37
|
+
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__text {
|
|
38
38
|
color: var(--g-color-text-light-secondary);
|
|
39
39
|
}
|
|
40
40
|
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__text:hover {
|
|
41
41
|
color: var(--g-color-text-light-primary);
|
|
42
|
+
}
|
|
43
|
+
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__separator {
|
|
44
|
+
color: var(--g-color-text-light-secondary);
|
|
42
45
|
}
|
|
@@ -13,7 +13,9 @@ function HeaderBreadcrumbs(props) {
|
|
|
13
13
|
const onClick = (0, react_1.useCallback)(() => {
|
|
14
14
|
handleAnalytics(analyticsEvents);
|
|
15
15
|
}, [analyticsEvents, handleAnalytics]);
|
|
16
|
-
return (react_1.default.createElement("
|
|
17
|
-
react_1.default.createElement("
|
|
16
|
+
return (react_1.default.createElement("nav", { className: b({ theme }, className), "aria-label": (0, i18n_1.i18n)('label') },
|
|
17
|
+
react_1.default.createElement("ol", { className: b('list') }, items === null || items === void 0 ? void 0 : items.map(({ url, text }) => (react_1.default.createElement("li", { className: b('item'), key: url },
|
|
18
|
+
react_1.default.createElement("a", { href: url, className: b('text'), onClick: onClick }, text),
|
|
19
|
+
react_1.default.createElement("span", { className: b('separator'), "aria-hidden": true }, "/")))))));
|
|
18
20
|
}
|
|
19
21
|
exports.default = HeaderBreadcrumbs;
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/* eslint-disable jsx-a11y/media-has-caption */
|
|
2
|
-
// TODO fix in https://github.com/gravity-ui/page-constructor/issues/967
|
|
3
1
|
import React, { Fragment, useCallback, useImperativeHandle, useRef, useState } from 'react';
|
|
4
2
|
import { CustomControlsType, MediaVideoControlsType } from '../../models';
|
|
5
3
|
import { block } from '../../utils';
|
|
@@ -50,7 +48,9 @@ export const DefaultVideo = React.forwardRef((props, ref) => {
|
|
|
50
48
|
React.createElement("video", { disablePictureInPicture: true, playsInline: true,
|
|
51
49
|
// @ts-ignore
|
|
52
50
|
// eslint-disable-next-line react/no-unknown-property
|
|
53
|
-
pip: "false", className: b(), ref: videoRef, preload: "metadata", muted: isMuted, "aria-label": video.ariaLabel, onClick: onClick },
|
|
51
|
+
pip: "false", className: b(), ref: videoRef, preload: "metadata", muted: isMuted, "aria-label": video.ariaLabel, onClick: onClick },
|
|
52
|
+
getVideoTypesWithPriority(video.src).map(({ src, type }, index) => (React.createElement("source", { key: index, src: src, type: type, "data-qa": qa }))),
|
|
53
|
+
React.createElement("track", { default: true, kind: "captions" })),
|
|
54
54
|
controls === MediaVideoControlsType.Custom && (React.createElement(CustomBarControls, { className: customBarControlsClassName, type: customControlsType, isPaused: isPaused, onPlayClick: onPlayToggle, muteButtonShown: muteButtonShown, shown: true, positioning: positioning, mute: {
|
|
55
55
|
isMuted: Boolean(isMuted),
|
|
56
56
|
changeMute: onMuteToggle,
|
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
@charset "UTF-8";
|
|
2
1
|
/* use this for style redefinitions to awoid problems with
|
|
3
2
|
unpredictable css rules order in build */
|
|
4
3
|
.pc-header-breadcrumbs {
|
|
5
4
|
z-index: 11;
|
|
6
5
|
}
|
|
6
|
+
.pc-header-breadcrumbs__list {
|
|
7
|
+
margin: 0;
|
|
8
|
+
padding: 0;
|
|
9
|
+
list-style: none;
|
|
10
|
+
}
|
|
7
11
|
.pc-header-breadcrumbs__item {
|
|
12
|
+
font-size: var(--g-text-body-2-font-size);
|
|
13
|
+
line-height: var(--g-text-body-2-line-height);
|
|
8
14
|
display: inline-block;
|
|
9
15
|
}
|
|
10
16
|
.pc-header-breadcrumbs__text {
|
|
11
|
-
font-size: var(--g-text-body-2-font-size);
|
|
12
|
-
line-height: var(--g-text-body-2-line-height);
|
|
13
17
|
outline: none;
|
|
14
18
|
color: var(--g-color-text-link);
|
|
15
19
|
text-decoration: none;
|
|
@@ -23,20 +27,19 @@ unpredictable css rules order in build */
|
|
|
23
27
|
--pc-text-header-color: var(--g-color-text-link-hover);
|
|
24
28
|
color: var(--g-color-text-link-hover);
|
|
25
29
|
}
|
|
26
|
-
.pc-header-breadcrumbs__text:after {
|
|
27
|
-
content: " / ";
|
|
28
|
-
margin: 0 8px 0 6px;
|
|
29
|
-
color: var(--g-color-text-secondary);
|
|
30
|
-
}
|
|
31
30
|
.pc-header-breadcrumbs__text:hover {
|
|
32
31
|
color: var(--g-color-text-primary);
|
|
33
32
|
}
|
|
34
|
-
.pc-header-
|
|
35
|
-
|
|
33
|
+
.pc-header-breadcrumbs__separator {
|
|
34
|
+
margin: 0 8px 0 6px;
|
|
35
|
+
color: var(--g-color-text-secondary);
|
|
36
36
|
}
|
|
37
|
-
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__text
|
|
37
|
+
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__text {
|
|
38
38
|
color: var(--g-color-text-light-secondary);
|
|
39
39
|
}
|
|
40
40
|
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__text:hover {
|
|
41
41
|
color: var(--g-color-text-light-primary);
|
|
42
|
+
}
|
|
43
|
+
.pc-header-breadcrumbs_theme_dark .pc-header-breadcrumbs__separator {
|
|
44
|
+
color: var(--g-color-text-light-secondary);
|
|
42
45
|
}
|
|
@@ -11,6 +11,8 @@ export default function HeaderBreadcrumbs(props) {
|
|
|
11
11
|
const onClick = useCallback(() => {
|
|
12
12
|
handleAnalytics(analyticsEvents);
|
|
13
13
|
}, [analyticsEvents, handleAnalytics]);
|
|
14
|
-
return (React.createElement("
|
|
15
|
-
React.createElement("
|
|
14
|
+
return (React.createElement("nav", { className: b({ theme }, className), "aria-label": i18n('label') },
|
|
15
|
+
React.createElement("ol", { className: b('list') }, items === null || items === void 0 ? void 0 : items.map(({ url, text }) => (React.createElement("li", { className: b('item'), key: url },
|
|
16
|
+
React.createElement("a", { href: url, className: b('text'), onClick: onClick }, text),
|
|
17
|
+
React.createElement("span", { className: b('separator'), "aria-hidden": true }, "/")))))));
|
|
16
18
|
}
|