@vkontakte/videoplayer 1.1.80 → 1.1.81-dev.10447541.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 +63 -0
- package/es2015.esm.js +37 -37
- package/es2018.cjs +63 -0
- package/es2018.esm.js +41 -41
- package/es2024.cjs +63 -0
- package/es2024.esm.js +39 -39
- package/esnext.cjs +63 -0
- package/esnext.esm.js +39 -39
- package/evergreen.esm.js +39 -39
- package/package.json +16 -16
- package/types/VKVideoPlayer/HTMLElement.d.ts +2 -0
- package/types/VKVideoPlayer/index.svelte.d.ts +2 -0
- package/types/config.d.ts +9 -0
- package/types/store/index.d.ts +3 -2
- package/types/store/utils.d.ts +2 -1
- package/types/utils/webAPI/slotsApi.d.ts +9 -2
- package/es2015.cjs.js +0 -63
- package/es2018.cjs.js +0 -63
- package/es2024.cjs.js +0 -63
- package/esnext.cjs.js +0 -63
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vkontakte/videoplayer",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.81-dev.10447541.0",
|
|
4
4
|
"author": "vk.com",
|
|
5
5
|
"description": "Videoplayer based on the vk.com platform",
|
|
6
6
|
"homepage": "https://vk.com",
|
|
7
7
|
"license": "GPL-3.0",
|
|
8
|
-
"main": "./esnext.cjs
|
|
8
|
+
"main": "./esnext.cjs",
|
|
9
9
|
"module": "./esnext.esm.js",
|
|
10
10
|
"types": "./types/index.d.ts",
|
|
11
11
|
"type": "module",
|
|
@@ -13,51 +13,51 @@
|
|
|
13
13
|
".": {
|
|
14
14
|
"types": "./types/index.d.ts",
|
|
15
15
|
"import": "./esnext.esm.js",
|
|
16
|
-
"require": "./esnext.cjs
|
|
16
|
+
"require": "./esnext.cjs"
|
|
17
17
|
},
|
|
18
18
|
"./evergreen": {
|
|
19
19
|
"types": "./types/index.d.ts",
|
|
20
20
|
"import": "./evergreen.esm.js",
|
|
21
|
-
"require": "./evergreen.cjs
|
|
21
|
+
"require": "./evergreen.cjs"
|
|
22
22
|
},
|
|
23
23
|
"./esnext": {
|
|
24
24
|
"types": "./types/index.d.ts",
|
|
25
25
|
"import": "./esnext.esm.js",
|
|
26
|
-
"require": "./esnext.cjs
|
|
26
|
+
"require": "./esnext.cjs"
|
|
27
27
|
},
|
|
28
28
|
"./es2024": {
|
|
29
29
|
"types": "./types/index.d.ts",
|
|
30
30
|
"import": "./es2024.esm.js",
|
|
31
|
-
"require": "./es2024.cjs
|
|
31
|
+
"require": "./es2024.cjs"
|
|
32
32
|
},
|
|
33
33
|
"./es2018": {
|
|
34
34
|
"types": "./types/index.d.ts",
|
|
35
35
|
"import": "./es2018.esm.js",
|
|
36
|
-
"require": "./es2018.cjs
|
|
36
|
+
"require": "./es2018.cjs"
|
|
37
37
|
},
|
|
38
38
|
"./es2015": {
|
|
39
39
|
"types": "./types/index.d.ts",
|
|
40
40
|
"import": "./es2015.esm.js",
|
|
41
|
-
"require": "./es2015.cjs
|
|
41
|
+
"require": "./es2015.cjs"
|
|
42
42
|
},
|
|
43
43
|
"./evergreen.esm.js": "./evergeen.esm.js",
|
|
44
44
|
"./esnext.esm.js": "./esnext.esm.js",
|
|
45
|
-
"./esnext.cjs
|
|
45
|
+
"./esnext.cjs": "./esnext.cjs",
|
|
46
46
|
"./es2018.esm.js": "./es2018.esm.js",
|
|
47
|
-
"./es2018.cjs
|
|
47
|
+
"./es2018.cjs": "./es2018.cjs",
|
|
48
48
|
"./es2015.esm.js": "./es2015.esm.js",
|
|
49
|
-
"./es2015.cjs
|
|
49
|
+
"./es2015.cjs": "./es2015.cjs"
|
|
50
50
|
},
|
|
51
51
|
"files": [
|
|
52
|
-
"*.cjs
|
|
52
|
+
"*.cjs",
|
|
53
53
|
"*.esm.js",
|
|
54
54
|
"**/*.d.ts"
|
|
55
55
|
],
|
|
56
56
|
"dependencies": {
|
|
57
57
|
"@adtech/rbadman": "2.2.57",
|
|
58
|
-
"@vkontakte/videoplayer-core": "2.0.
|
|
59
|
-
"@vkontakte/videoplayer-interactive": "1.0.
|
|
60
|
-
"@vkontakte/videoplayer-shared": "1.0.
|
|
61
|
-
"@vkontakte/videoplayer-statistics": "1.0.
|
|
58
|
+
"@vkontakte/videoplayer-core": "2.0.150-dev.10447541.0",
|
|
59
|
+
"@vkontakte/videoplayer-interactive": "1.0.56-dev.10447541.0",
|
|
60
|
+
"@vkontakte/videoplayer-shared": "1.0.79-dev.10447541.0",
|
|
61
|
+
"@vkontakte/videoplayer-statistics": "1.0.96-dev.10447541.0"
|
|
62
62
|
}
|
|
63
63
|
}
|
|
@@ -10,6 +10,7 @@ import { AnnotationsApi } from '../utils/webAPI/annotationsApi/annotationsApi';
|
|
|
10
10
|
import type { AdditionalContextMenuItem, AdditionalSettingsMenuItem } from '../components/Menus/subMenuTabs/types';
|
|
11
11
|
import type { AdditionalButton } from '../components/Controls/types';
|
|
12
12
|
import { SlotsApi } from '../utils/webAPI/slotsApi';
|
|
13
|
+
import { HTMLElement } from './HTMLElement';
|
|
13
14
|
export declare class VKVideoPlayer extends HTMLElement {
|
|
14
15
|
private svelteStubComponent?;
|
|
15
16
|
private svelteRootComponent?;
|
|
@@ -31,6 +32,7 @@ export declare class VKVideoPlayer extends HTMLElement {
|
|
|
31
32
|
private uiConfig;
|
|
32
33
|
private coreConfig;
|
|
33
34
|
private statisticsConfig;
|
|
35
|
+
private metaConfig;
|
|
34
36
|
private interactiveController;
|
|
35
37
|
private interactiveContainer;
|
|
36
38
|
private graphMadePause;
|
package/types/config.d.ts
CHANGED
|
@@ -251,6 +251,14 @@ export interface IUIConfig {
|
|
|
251
251
|
*/
|
|
252
252
|
suitableDurationForUsingRichSeek: Seconds;
|
|
253
253
|
titleShowBehaviour: TitleShowBehaviour;
|
|
254
|
+
/**
|
|
255
|
+
* Отключаем слоты по идентификаторам.
|
|
256
|
+
*/
|
|
257
|
+
disabledSlotIds: string[];
|
|
258
|
+
/**
|
|
259
|
+
* Отключаем внешне переданные кнопки по идентификаторам.
|
|
260
|
+
*/
|
|
261
|
+
disabledAdditionalButtonIds: string[];
|
|
254
262
|
}
|
|
255
263
|
export declare const defaultConfig: IUIConfig;
|
|
256
264
|
export type IOptionalUIConfig = RecursivePartial<IUIConfig>;
|
|
@@ -259,6 +267,7 @@ export interface ISDKConfig {
|
|
|
259
267
|
ui: RecursivePartial<IUIConfig>;
|
|
260
268
|
core: ICoreConfig;
|
|
261
269
|
statistics: IStatisticsConfig;
|
|
270
|
+
meta?: string[];
|
|
262
271
|
}
|
|
263
272
|
export declare const setConfig: (config: IUIConfig) => IUIConfig;
|
|
264
273
|
export declare const getConfig: () => IUIConfig;
|
package/types/store/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { IAudioStream, IConfig, IExternalTextTrack, IOptionalTuningConfig, IPlayer, ISources, ITextTrack, IVideoStream, PlaybackRate } from '@vkontakte/videoplayer-core';
|
|
2
2
|
import { ChromecastState, PlaybackState, VideoFormat } from '@vkontakte/videoplayer-core';
|
|
3
3
|
import { type IError, type ILogger, InterfaceLanguage, type IRectangle, type IValueObservable, type QualityLimits, VideoQuality, type InternalsExposure } from '@vkontakte/videoplayer-shared';
|
|
4
|
-
import type { IUIConfig } from '../config';
|
|
4
|
+
import type { ISDKConfig, IUIConfig } from '../config';
|
|
5
5
|
import { SeekAction } from '@vkontakte/videoplayer-statistics';
|
|
6
6
|
import type { InteractiveRange } from '@vkontakte/videoplayer-interactive';
|
|
7
7
|
import type { Readable, Writable } from 'svelte/store';
|
|
@@ -370,6 +370,7 @@ interface IStoreParams {
|
|
|
370
370
|
previewThumbsData?: ITimelinePreviewThumbsData;
|
|
371
371
|
uiConfig: IUIConfig;
|
|
372
372
|
coreConfig: IOptionalTuningConfig;
|
|
373
|
+
metaConfig: ISDKConfig['meta'];
|
|
373
374
|
player?: IPlayer;
|
|
374
375
|
isInteractive: boolean;
|
|
375
376
|
interactiveRanges$?: IValueObservable<InteractiveRange[]>;
|
|
@@ -400,5 +401,5 @@ interface IStoreParams {
|
|
|
400
401
|
* Store приложения.
|
|
401
402
|
* Если будет слишком большим - можно разделить его на модули
|
|
402
403
|
*/
|
|
403
|
-
export declare const createStore: ({ interfaceLanguage, isCyrillicRelatedInterface, videoId, isClip, isLiveCatchUpMode, statAuthToken, isAudioDisabled, canDownload, callbacks, webApi, videoEpisodes, previewThumbsData, uiConfig, coreConfig, player: playerInstance, disabledControls, isInteractive, interactiveRanges$, isInteractiveTime$, replayInteractive, stopPlayer, hasInteractiveBranches, playPrevChapterDisabledTooltip, additionalButtons, additionalSettingsMenuItems, additionalContextMenuItems, playPrevVideo, playNextVideo, onVideoChanged, looped, statistics: uiStatistics, saveRate, internalsExposure, playerView, playerId, }: IStoreParams) => IStore;
|
|
404
|
+
export declare const createStore: ({ interfaceLanguage, isCyrillicRelatedInterface, videoId, isClip, isLiveCatchUpMode, statAuthToken, isAudioDisabled, canDownload, callbacks, webApi, videoEpisodes, previewThumbsData, uiConfig, coreConfig, player: playerInstance, disabledControls, isInteractive, interactiveRanges$, isInteractiveTime$, replayInteractive, stopPlayer, hasInteractiveBranches, playPrevChapterDisabledTooltip, additionalButtons, additionalSettingsMenuItems, additionalContextMenuItems, playPrevVideo, playNextVideo, onVideoChanged, looped, statistics: uiStatistics, saveRate, internalsExposure, playerView, playerId, metaConfig, }: IStoreParams) => IStore;
|
|
404
405
|
export {};
|
package/types/store/utils.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ import type { IPlayer, IConfig, IObservable } from '@vkontakte/videoplayer-core'
|
|
|
4
4
|
import type { IStore } from '.';
|
|
5
5
|
import type { AdditionalButtonDeprecated, IMicroStores } from '../types';
|
|
6
6
|
import type { AdditionalDesktopControlPanelButton } from '../components/Controls/types';
|
|
7
|
+
import type { ISDKConfig } from '../config';
|
|
7
8
|
export declare const setStores: (store: IStore, microStores: IMicroStores) => void;
|
|
8
9
|
export declare const getStore: () => IStore;
|
|
9
10
|
export declare const getMicroStores: () => IMicroStores;
|
|
@@ -12,7 +13,7 @@ export declare const getMicroStores: () => IMicroStores;
|
|
|
12
13
|
*/
|
|
13
14
|
export declare const storeFromObservable: <T>(observable$: IValueObservable<T>, onNewValueEmitted?: (value: T) => void) => Readable<T>;
|
|
14
15
|
export declare const storeFromObservableWithInitValue: <T>(observable$: IObservable<T>, initValue: T, onNewValueEmitted?: (value: T) => void) => Readable<T>;
|
|
15
|
-
export declare const constructDebugTextData: (player: IPlayer, config: IConfig | undefined, store: IStore, traceId: string) => string;
|
|
16
|
+
export declare const constructDebugTextData: (player: IPlayer, config: IConfig | undefined, store: IStore, traceId: string, metaConfig?: ISDKConfig["meta"]) => string;
|
|
16
17
|
export type DebugData = {
|
|
17
18
|
version: string;
|
|
18
19
|
viewport: string;
|
|
@@ -18,13 +18,20 @@ type AddOptions = {
|
|
|
18
18
|
hideAllControls?: boolean;
|
|
19
19
|
controlsBehaviour?: HideControlsWhenIntersectedOptions;
|
|
20
20
|
};
|
|
21
|
+
type AddReturnType = {
|
|
22
|
+
success: true;
|
|
23
|
+
} | {
|
|
24
|
+
success: false;
|
|
25
|
+
message: string;
|
|
26
|
+
};
|
|
21
27
|
export declare class SlotsApi {
|
|
22
28
|
private shadowRootContainer;
|
|
23
29
|
private slots;
|
|
24
30
|
private store;
|
|
25
|
-
|
|
31
|
+
private disabledIds;
|
|
32
|
+
constructor(disabledIds: string[]);
|
|
26
33
|
init(shadowRootContainer: HTMLElement, store: IStore | undefined): void;
|
|
27
|
-
add(element: HTMLElement, options: AddOptions):
|
|
34
|
+
add(element: HTMLElement, options: AddOptions): AddReturnType;
|
|
28
35
|
private setupSlotStyles;
|
|
29
36
|
/**
|
|
30
37
|
* Запускаем отслеживание пересечения между переданным элементом внутри слота и контролами.
|