@vkontakte/videoplayer 1.1.86 → 1.1.87-dev.04ce2cd1.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/es2015.cjs +423 -56
- package/es2015.esm.js +423 -56
- package/es2018.cjs +423 -56
- package/es2018.esm.js +423 -56
- package/es2024.cjs +423 -56
- package/es2024.esm.js +423 -56
- package/esnext.cjs +423 -56
- package/esnext.esm.js +423 -56
- package/evergreen.esm.js +423 -56
- package/package.json +5 -5
- package/types/VKVideoPlayer/HTMLElement.d.ts +1 -1
- package/types/VKVideoPlayer/index.svelte.d.ts +173 -173
- package/types/components/Ads/admanWrapper.d.ts +79 -75
- package/types/components/Ads/types.d.ts +27 -27
- package/types/components/Controls/contants/desktopButtonsLeftIds.d.ts +8 -8
- package/types/components/Controls/contants/desktopButtonsLeftWeights.d.ts +2 -4
- package/types/components/Controls/contants/desktopButtonsRightIds.d.ts +8 -8
- package/types/components/Controls/contants/desktopButtonsRightWeights.d.ts +2 -4
- package/types/components/Controls/types.d.ts +27 -27
- package/types/components/Controls/utils/isInnerButtonGuard.d.ts +1 -1
- package/types/components/Icons/constants.d.ts +5 -5
- package/types/components/Icons/utils.d.ts +1 -1
- package/types/components/Menus/constants/contextMenuItemIds.d.ts +10 -10
- package/types/components/Menus/constants/contextMenuItemWeights.d.ts +2 -4
- package/types/components/Menus/constants/index.d.ts +4 -4
- package/types/components/Menus/constants/openSubMenuItemsIds.d.ts +1 -1
- package/types/components/Menus/constants/settingsMenuItemIds.d.ts +10 -10
- package/types/components/Menus/constants/settingsMenuItemWeights.d.ts +2 -4
- package/types/components/Menus/constants/subMenuIds.d.ts +6 -6
- package/types/components/Menus/subMenuTabs/rootMenuItems.d.ts +26 -26
- package/types/components/Menus/subMenuTabs/sharedMenuItems.d.ts +7 -7
- package/types/components/Menus/subMenuTabs/subMenuItems.d.ts +4 -10
- package/types/components/Menus/subMenuTabs/types.d.ts +108 -108
- package/types/components/Menus/subMenuTabs/utils.d.ts +2 -2
- package/types/components/Menus/types.d.ts +64 -61
- package/types/components/Menus/utils/getCurrentQualityDisplayValue.d.ts +12 -12
- package/types/components/Menus/utils/getQualityIcon.d.ts +2 -2
- package/types/components/Menus/utils/getSubMenusStack.svelte.d.ts +7 -7
- package/types/components/Menus/utils/menuNavigation.d.ts +5 -5
- package/types/components/Root/types.d.ts +79 -79
- package/types/components/Root/utils.d.ts +2 -2
- package/types/components/Timeline/PreviewTrack/useTransitionToPreviewTrack.svelte.d.ts +15 -15
- package/types/components/Timeline/consts.d.ts +2 -2
- package/types/components/shared/interpolateUtils.d.ts +2 -2
- package/types/config.d.ts +270 -260
- package/types/constans/controls.d.ts +21 -21
- package/types/constans/grid.d.ts +9 -9
- package/types/constans/index.d.ts +8 -8
- package/types/constans/interactives.d.ts +4 -4
- package/types/constans/keyboard.d.ts +43 -48
- package/types/index.d.ts +16 -16
- package/types/services/statistics.d.ts +13 -13
- package/types/store/index.d.ts +391 -391
- package/types/store/micro/base.d.ts +6 -6
- package/types/store/micro/fakeIsPlaying.d.ts +8 -10
- package/types/store/micro/graphIsOpened.d.ts +11 -13
- package/types/store/micro/index.d.ts +1 -1
- package/types/store/micro/interactiveControlsOpacity.d.ts +8 -10
- package/types/store/micro/notifications.d.ts +7 -10
- package/types/store/micro/pictureInPicture.d.ts +6 -9
- package/types/store/micro/seekToInteractiveDisabledTooltip.d.ts +8 -7
- package/types/store/micro/showInteractiveTimeIndicatorTooltip.d.ts +13 -12
- package/types/store/utils.d.ts +36 -36
- package/types/translation/index.d.ts +2 -2
- package/types/translation/labels.d.ts +1 -1
- package/types/translation/packs/en.d.ts +1 -1
- package/types/translation/packs/ru.d.ts +1 -1
- package/types/translation/types.d.ts +5 -5
- package/types/types/index.d.ts +534 -516
- package/types/types/svg.d.d.ts +5 -0
- package/types/utils/CaptionsPrepared.d.ts +15 -15
- package/types/utils/WebVttParser.d.ts +11 -11
- package/types/utils/attachments/defferedDisableByCondition.d.ts +3 -3
- package/types/utils/changeVolume.d.ts +6 -6
- package/types/utils/elementHelpers.d.ts +2 -2
- package/types/utils/findCurrentSubtltlePhrase.d.ts +1 -1
- package/types/utils/fullscreen.d.ts +14 -14
- package/types/utils/getActualEpisode.d.ts +7 -7
- package/types/utils/getControlInfo.d.ts +5 -7
- package/types/utils/getHotKeyMapData.d.ts +1 -1
- package/types/utils/grid.d.ts +1 -1
- package/types/utils/hooks/useIosSafariFullscreen.d.ts +2 -2
- package/types/utils/hooks/useIosSafariFullscreenSubtitles.d.ts +3 -3
- package/types/utils/keyboardHandleCases.d.ts +1 -1
- package/types/utils/notificationShowManager.d.ts +7 -6
- package/types/utils/roundFps.d.ts +1 -1
- package/types/utils/sanitizeHtml.d.ts +3 -3
- package/types/utils/sorts.d.ts +2 -2
- package/types/utils/stack/index.d.ts +7 -7
- package/types/utils/stack/node.d.ts +3 -3
- package/types/utils/subtitles.d.ts +8 -8
- package/types/utils/timeout.d.ts +2 -2
- package/types/utils/updatePlayerControlBlocks.d.ts +2 -2
- package/types/utils/updatePlayerControlsInfo.d.ts +2 -2
- package/types/utils/userSettings.d.ts +26 -21
- package/types/utils/videoConfig.d.ts +6 -2
- package/types/utils/volumeChange.d.ts +1 -1
- package/types/utils/webAPI/annotationsApi/annotationsApi.d.ts +31 -31
- package/types/utils/webAPI/annotationsApi/errors.d.ts +1 -1
- package/types/utils/webAPI/focusLock.d.ts +30 -30
- package/types/utils/webAPI/focusManager.d.ts +15 -15
- package/types/utils/webAPI/language.d.ts +1 -1
- package/types/utils/webAPI/mediaSessionApi.d.ts +14 -14
- package/types/utils/webAPI/pictureInPictureApi/documentPictureInPictureApi.svelte.d.ts +41 -41
- package/types/utils/webAPI/pictureInPictureApi/factory.d.ts +2 -2
- package/types/utils/webAPI/pictureInPictureApi/index.d.ts +4 -4
- package/types/utils/webAPI/pictureInPictureApi/pictureInPictureApi.d.ts +46 -46
- package/types/utils/webAPI/pictureInPictureApi/types.d.ts +4 -4
- package/types/utils/webAPI/pictureInPictureApi/utils.d.ts +3 -3
- package/types/utils/webAPI/slotsApi.d.ts +41 -41
|
@@ -1,93 +1,96 @@
|
|
|
1
|
-
import { UIType } from
|
|
2
|
-
import { SubMenuIds } from
|
|
3
|
-
import type { TmpComponentType } from
|
|
1
|
+
import type { UIType } from "../../types";
|
|
2
|
+
import type { SubMenuIds } from "./constants/subMenuIds";
|
|
3
|
+
import type { TmpComponentType } from "../../types/tmp";
|
|
4
4
|
interface BaseMenuItem {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
id: string;
|
|
6
|
+
weight: number;
|
|
7
|
+
ariaLabel?: string;
|
|
8
|
+
label: string;
|
|
9
9
|
}
|
|
10
10
|
interface BaseSettingsMenuItem extends BaseMenuItem {
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
icon: TmpComponentType | string;
|
|
12
|
+
isHiddenFor?: UIType[];
|
|
13
13
|
}
|
|
14
14
|
export declare enum MenuItemType {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
OPEN_SUB_MENU = "OPEN_SUB_MENU",
|
|
16
|
+
CLICK = "CLICK",
|
|
17
|
+
SWITCH = "SWITCH"
|
|
18
18
|
}
|
|
19
19
|
export declare enum SubMenuItemType {
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
OPEN_SUB_MENU = "OPEN_SUB_MENU",
|
|
21
|
+
SELECT_VALUE = "SELECT_VALUE"
|
|
22
22
|
}
|
|
23
23
|
export interface OpenSubMenuSettingsMenuItem extends BaseSettingsMenuItem {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
type: MenuItemType.OPEN_SUB_MENU;
|
|
25
|
+
subMenuId: SubMenuIds;
|
|
26
|
+
value: string;
|
|
27
|
+
valueComponent?: any;
|
|
28
|
+
getSubItemForFocus: () => HTMLLIElement;
|
|
29
29
|
}
|
|
30
30
|
export interface ClickSettingsMenuItem extends BaseSettingsMenuItem {
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
type: MenuItemType.CLICK;
|
|
32
|
+
onClick: () => void;
|
|
33
33
|
}
|
|
34
34
|
export interface SwitchSettingsMenuItem extends BaseSettingsMenuItem {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
35
|
+
type: MenuItemType.SWITCH;
|
|
36
|
+
onClick: (enabled: boolean) => void;
|
|
37
|
+
enabled: boolean;
|
|
38
|
+
tooltipText?: string;
|
|
39
|
+
maxTooltipWidth?: number;
|
|
40
40
|
}
|
|
41
|
-
export type AdditionalSwitchSettingsMenuItem = Omit<SwitchSettingsMenuItem,
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
export type AdditionalSwitchSettingsMenuItem = Omit<SwitchSettingsMenuItem, "icon" | "onClick"> & {
|
|
42
|
+
icon: string;
|
|
43
|
+
onChangeEnabled: (enabled: boolean) => void;
|
|
44
44
|
};
|
|
45
|
-
export type AdditionalClickSettingsMenuItem = Omit<SwitchSettingsMenuItem,
|
|
46
|
-
|
|
45
|
+
export type AdditionalClickSettingsMenuItem = Omit<SwitchSettingsMenuItem, "icon"> & {
|
|
46
|
+
icon: string;
|
|
47
47
|
};
|
|
48
48
|
export type SettingsMenuItem = OpenSubMenuSettingsMenuItem | ClickSettingsMenuItem | SwitchSettingsMenuItem;
|
|
49
49
|
export type AdditionalSettingsMenuItem = AdditionalSwitchSettingsMenuItem | AdditionalClickSettingsMenuItem;
|
|
50
50
|
interface SubMenuItemBase<U = any> {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
51
|
+
selected?: boolean;
|
|
52
|
+
valueComponent?: TmpComponentType;
|
|
53
|
+
valueComponentParams?: {
|
|
54
|
+
[key: string]: U;
|
|
55
|
+
};
|
|
56
|
+
bottomBordered?: boolean;
|
|
57
|
+
label?: string;
|
|
58
|
+
sublabel?: string;
|
|
59
|
+
ariaLabel?: string;
|
|
60
|
+
onClick?: () => void;
|
|
61
61
|
}
|
|
62
|
-
export interface SelectValueSubMenuItem<
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
62
|
+
export interface SelectValueSubMenuItem<
|
|
63
|
+
T = any,
|
|
64
|
+
U = any
|
|
65
|
+
> extends SubMenuItemBase<U> {
|
|
66
|
+
type: SubMenuItemType.SELECT_VALUE;
|
|
67
|
+
value: T;
|
|
68
|
+
dataValue?: T | keyof T;
|
|
69
|
+
selectItem: (value: T) => void;
|
|
67
70
|
}
|
|
68
71
|
export interface OpenSubMenuSubMenuItem extends SubMenuItemBase {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
72
|
+
type: SubMenuItemType.OPEN_SUB_MENU;
|
|
73
|
+
id: string;
|
|
74
|
+
subMenuId: SubMenuIds;
|
|
75
|
+
getSubItemForFocus?: () => HTMLLIElement;
|
|
73
76
|
}
|
|
74
77
|
export type SubMenuItem = SelectValueSubMenuItem | OpenSubMenuSubMenuItem;
|
|
75
78
|
export interface SubMenuList {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
79
|
+
id: SubMenuIds;
|
|
80
|
+
parentItemId?: string;
|
|
81
|
+
items: SubMenuItem[];
|
|
82
|
+
returnFromSubMenu?: () => void;
|
|
83
|
+
ariaLabelReturnFromSubMenu?: string;
|
|
84
|
+
title: string;
|
|
85
|
+
closeSettingsMenu: () => void;
|
|
86
|
+
minWidth?: number;
|
|
87
|
+
onMount?: () => void;
|
|
85
88
|
}
|
|
86
89
|
export interface ContextMenuItem extends BaseMenuItem {
|
|
87
|
-
|
|
90
|
+
onClick: () => void;
|
|
88
91
|
}
|
|
89
92
|
export type AdditionalContextMenuItem = ContextMenuItem;
|
|
90
93
|
export type MenuRefs = {
|
|
91
|
-
|
|
94
|
+
[key: string]: HTMLUListElement;
|
|
92
95
|
};
|
|
93
96
|
export {};
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { VideoQuality } from
|
|
2
|
-
import { type VideoQualityForRender } from
|
|
1
|
+
import { VideoQuality } from "@vkontakte/videoplayer-core";
|
|
2
|
+
import { type VideoQualityForRender } from "../../../types";
|
|
3
3
|
type Params = {
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
quality: VideoQuality;
|
|
5
|
+
availableQualities: VideoQualityForRender[];
|
|
6
6
|
};
|
|
7
7
|
export declare const getQualityDisplayValue: ({ quality, availableQualities }: Params) => string;
|
|
8
8
|
type CurrentQualityParams = {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
isAutoQualityEnabled: boolean | undefined;
|
|
10
|
+
quality: VideoQuality | undefined;
|
|
11
|
+
availableQualities: VideoQualityForRender[];
|
|
12
12
|
};
|
|
13
|
-
export declare const getCurrentQualityDisplayValue: ({ quality, availableQualities, isAutoQualityEnabled
|
|
13
|
+
export declare const getCurrentQualityDisplayValue: ({ quality, availableQualities, isAutoQualityEnabled }: CurrentQualityParams) => string;
|
|
14
14
|
type QualityWithPrefixParams = {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
quality: VideoQuality | undefined;
|
|
16
|
+
availableQualities: VideoQualityForRender[];
|
|
17
|
+
prefix: string;
|
|
18
|
+
onlyPrefix: boolean;
|
|
19
19
|
};
|
|
20
20
|
export declare const getQualityWithPrefix: ({ quality, availableQualities, prefix, onlyPrefix }: QualityWithPrefixParams) => string;
|
|
21
21
|
export {};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { VideoQualityUI } from
|
|
2
|
-
import type { TmpComponentType } from
|
|
1
|
+
import type { VideoQualityUI } from "../../../types";
|
|
2
|
+
import type { TmpComponentType } from "../../../types/tmp";
|
|
3
3
|
export declare const getQualityIcon: (quality?: VideoQualityUI) => TmpComponentType | undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { SubMenuId } from
|
|
1
|
+
import type { SubMenuId } from "../subMenuTabs/types";
|
|
2
2
|
/**
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
* Представляем цепочку открытия подменюшек стеком, таким образом можем открывать хоть сколько.
|
|
4
|
+
*/
|
|
5
5
|
export declare const getSubMenusStack: () => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
readonly current: SubMenuId | null;
|
|
7
|
+
pushSubMenu: (subMenuId: SubMenuId) => void;
|
|
8
|
+
popSubMenu: () => void;
|
|
9
|
+
popAllSubMenus: () => void;
|
|
10
10
|
};
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { ProcessedKeysCodes } from
|
|
2
|
-
import { type Writable } from
|
|
3
|
-
import type { Position } from
|
|
1
|
+
import { ProcessedKeysCodes } from "../../../constans";
|
|
2
|
+
import { type Writable } from "svelte/store";
|
|
3
|
+
import type { Position } from "../../../types";
|
|
4
4
|
export declare const eventStop: (event: Event) => void;
|
|
5
5
|
export declare const clearFocusHiddenClass: (target: HTMLElement) => void;
|
|
6
6
|
export declare const isChoseItemCase: (event: KeyboardEvent, extraKeys?: ProcessedKeysCodes[]) => boolean;
|
|
7
|
-
export declare const isKeyboardHandleCase: (event?: MouseEvent) => boolean;
|
|
7
|
+
export declare const isKeyboardHandleCase: (event?: MouseEvent | PointerEvent) => boolean;
|
|
8
8
|
export declare const handleFocusReturnToBtn: (ref: HTMLButtonElement, menuVisible: boolean, openedByKeyboard$: Writable<boolean>) => Promise<void>;
|
|
9
9
|
export declare const handleFocusReturnToElem: (ref: HTMLButtonElement, menuVisible: boolean, openedByKeyboard$: Writable<boolean>) => Promise<void>;
|
|
10
10
|
export declare const handleFocusOnMenu: (ref: HTMLUListElement, menuVisible: boolean, isOpenedByKeyboard: boolean, isMobile?: boolean) => Promise<void>;
|
|
11
11
|
export declare const returnFocusToMenuItem: (refMenuItems: {
|
|
12
|
-
|
|
12
|
+
[key: string]: HTMLLIElement;
|
|
13
13
|
}, id: string) => Promise<void>;
|
|
14
14
|
export declare const handleKeyDownMainMenu: (event: KeyboardEvent, closeCallback: () => void) => void;
|
|
15
15
|
export declare const handleKeyDownOpenSubMenuItem: (event: KeyboardEvent, openSubmenuFn: () => void) => Promise<void>;
|
|
@@ -1,85 +1,85 @@
|
|
|
1
|
-
import type { IExternalTextTrack, ISources, PlaybackRate } from
|
|
2
|
-
import type { IStore } from
|
|
3
|
-
import type { IMicroStoresRoot, IVideoLive, IVKVideoPlayerConfig } from
|
|
4
|
-
import type { IUIConfig } from
|
|
5
|
-
import type { Interactives } from
|
|
6
|
-
import KeyboardControls from
|
|
7
|
-
import type { QualityLimits } from
|
|
8
|
-
import type { AdmanInitParams } from
|
|
1
|
+
import type { IExternalTextTrack, ISources, PlaybackRate } from "@vkontakte/videoplayer-core";
|
|
2
|
+
import type { IStore } from "../../store";
|
|
3
|
+
import type { IMicroStoresRoot, IVideoLive, IVKVideoPlayerConfig } from "../../types";
|
|
4
|
+
import type { IUIConfig } from "../../config";
|
|
5
|
+
import type { Interactives } from "@vkontakte/videoplayer-interactive";
|
|
6
|
+
import type KeyboardControls from "../KeyboardControls.svelte";
|
|
7
|
+
import type { QualityLimits } from "@vkontakte/videoplayer-shared";
|
|
8
|
+
import type { AdmanInitParams } from "../Ads/types";
|
|
9
9
|
export interface RootProps {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
10
|
+
sources: ISources | undefined;
|
|
11
|
+
store: IStore;
|
|
12
|
+
microStoresRoot: IMicroStoresRoot;
|
|
13
|
+
videoConfig: IVKVideoPlayerConfig;
|
|
14
|
+
uiConfig: IUIConfig;
|
|
15
|
+
title: string;
|
|
16
|
+
thumbUrl: string | undefined;
|
|
17
|
+
interactiveContainer: HTMLElement | undefined;
|
|
18
|
+
interactiveController: Interactives | undefined;
|
|
19
|
+
subtitles: Omit<IExternalTextTrack, "type">[] | undefined;
|
|
20
|
+
subtitlesForcedLanguage?: string;
|
|
21
|
+
live: IVideoLive | undefined;
|
|
22
|
+
preload: boolean;
|
|
23
|
+
autoplay: boolean;
|
|
24
|
+
volume?: number | undefined;
|
|
25
|
+
muted?: boolean | undefined;
|
|
26
|
+
fromTime: number;
|
|
27
|
+
canRewindLive: boolean;
|
|
28
|
+
showAds: boolean;
|
|
29
|
+
adsSlotId?: number | undefined;
|
|
30
|
+
adsParams?: AdmanInitParams["params"];
|
|
31
|
+
adsAutoplayParam?: boolean;
|
|
32
|
+
adsExternalApi?: AdmanInitParams["externalApi"];
|
|
33
|
+
adsJson?: AdmanInitParams["json"];
|
|
34
|
+
duration?: number | undefined;
|
|
35
|
+
logoClickable: boolean;
|
|
36
|
+
logoHidden: boolean;
|
|
37
|
+
isMobile: boolean;
|
|
38
|
+
showNextPrevButtons?: boolean;
|
|
39
|
+
nextButtonActive?: boolean;
|
|
40
|
+
prevButtonActive?: boolean;
|
|
41
|
+
endScreenVideoTitle?: string | undefined;
|
|
42
|
+
endScreenVideoThumb?: string | undefined;
|
|
43
|
+
isOneVideoPlaylist?: boolean;
|
|
44
|
+
supportLink: string;
|
|
45
|
+
shadowRootContainer: HTMLElement;
|
|
46
|
+
outerContainerRef: HTMLElement;
|
|
47
|
+
fullScreenTarget?: HTMLElement | undefined;
|
|
48
|
+
failoverHosts?: string[] | undefined;
|
|
49
|
+
showMiniTimer?: boolean;
|
|
50
|
+
saveRate: boolean;
|
|
51
|
+
seekToInteractive?: () => void;
|
|
52
|
+
playPrevChapter?: () => void;
|
|
53
|
+
volumeMultiplier: number;
|
|
54
|
+
showEndScreen?: boolean;
|
|
55
|
+
showAutoplayNext: boolean;
|
|
56
|
+
keyboardControls?: KeyboardControls | undefined;
|
|
57
|
+
needToRepeatPlaylist?: boolean;
|
|
58
|
+
getVideoDeeplink?: (timestamp: number) => string;
|
|
59
59
|
}
|
|
60
60
|
export interface RootExports {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
61
|
+
play: () => void;
|
|
62
|
+
pause: () => void;
|
|
63
|
+
setMuted: (muted: boolean) => void;
|
|
64
|
+
toggleSubtitle: () => void;
|
|
65
|
+
changeSubtitle: (enabled: boolean, id?: string) => void;
|
|
66
|
+
changeAudioStream: (id: string) => void;
|
|
67
|
+
hideControls: () => void;
|
|
68
|
+
showControls: () => void;
|
|
69
|
+
setVolume: (volume: number) => void;
|
|
70
|
+
seekTime: (time: number) => void;
|
|
71
|
+
seekEpisodeStartTime: (time: number) => void;
|
|
72
|
+
returnFocusToEpisodes: () => void;
|
|
73
|
+
setPlaybackRate: (playbackRate: PlaybackRate) => void;
|
|
74
|
+
setAutoQualityLimits: (limits: QualityLimits) => void;
|
|
75
|
+
keyboardControls?: {
|
|
76
|
+
focus: () => void;
|
|
77
|
+
handleExternalKeyboardEvent: (event: KeyboardEvent) => boolean;
|
|
78
|
+
};
|
|
79
|
+
setAutoQuality: () => void;
|
|
80
|
+
toggleTrafficSaving: (value: boolean) => void;
|
|
81
|
+
toggleHighQuality: (value: boolean) => void;
|
|
82
82
|
}
|
|
83
83
|
export interface PersistentLayerExports {
|
|
84
|
-
|
|
84
|
+
startVideoChangedAnimation: (prev: boolean) => void;
|
|
85
85
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { IUIConfig } from
|
|
2
|
-
export declare function mapConfigStyle(options: IUIConfig[
|
|
1
|
+
import type { IUIConfig } from "../../config";
|
|
2
|
+
export declare function mapConfigStyle(options: IUIConfig["view"]): string | undefined;
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
type Params = {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
onPreviewTrackOpened: () => void;
|
|
3
|
+
getTimelineRef: () => HTMLElement | undefined;
|
|
4
|
+
isHorizontal: boolean;
|
|
5
5
|
};
|
|
6
6
|
/**
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
* Координирует анимацию показа превью трека.
|
|
8
|
+
* Поднимает прогресс бар, опускает контролы, проявляет превью трек.
|
|
9
|
+
* Все строится вокруг progressToOpenTrack.
|
|
10
|
+
*
|
|
11
|
+
*/
|
|
12
12
|
export declare const useTransitionToPreviewTrack: ({ onPreviewTrackOpened, getTimelineRef, isHorizontal }: Params) => {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
13
|
+
progressBarY: () => number;
|
|
14
|
+
controlsY: () => number;
|
|
15
|
+
calculatedHeight: () => number;
|
|
16
|
+
onPointerDown: (e: PointerEvent) => void;
|
|
17
|
+
onPointerMove: (e: PointerEvent) => void;
|
|
18
|
+
onPointerUp: () => void;
|
|
19
|
+
closePreviewTrack: () => void;
|
|
20
20
|
};
|
|
21
21
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
* Сколько картинок показываем слева и справа от картинки, на которую указывает каретка с учетом картинки на которой находится каретка.
|
|
3
|
+
*/
|
|
4
4
|
export declare const PREVIEW_IMAGE_BUFFER = 3;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
type AllowedHTML = Record<string, boolean>;
|
|
2
2
|
/**
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
* В дальнейшем можно по надобности указывать возможные атрибуты.
|
|
4
|
+
*/
|
|
5
5
|
export declare const DEFAULT_ALLOWED_HTML: AllowedHTML;
|
|
6
6
|
export declare const interpolateMessage: (message?: string, customAllowedHTML?: AllowedHTML) => string | undefined;
|
|
7
7
|
export {};
|