@vkontakte/videoplayer 1.1.68 → 1.1.69-beta.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vkontakte/videoplayer",
3
- "version": "1.1.68",
3
+ "version": "1.1.69-beta.0",
4
4
  "author": "vk.com",
5
5
  "description": "Videoplayer based on the vk.com platform",
6
6
  "homepage": "https://vk.com",
@@ -55,9 +55,9 @@
55
55
  ],
56
56
  "dependencies": {
57
57
  "@adtech/rbadman": "2.2.57",
58
- "@vkontakte/videoplayer-core": "2.0.137",
59
- "@vkontakte/videoplayer-interactive": "1.0.43",
60
- "@vkontakte/videoplayer-shared": "1.0.65",
61
- "@vkontakte/videoplayer-statistics": "1.0.83"
58
+ "@vkontakte/videoplayer-core": "2.0.138-beta.0",
59
+ "@vkontakte/videoplayer-interactive": "1.0.44-beta.0",
60
+ "@vkontakte/videoplayer-shared": "1.0.66-beta.0",
61
+ "@vkontakte/videoplayer-statistics": "1.0.84-beta.0"
62
62
  }
63
63
  }
@@ -53,7 +53,7 @@ export declare class AdmanWrapper {
53
53
  private isVsidOriginal;
54
54
  private watchDogTimeout;
55
55
  events: {
56
- init$: Subject<void>;
56
+ init$: Subject<number>;
57
57
  loadStarted$: Subject<void>;
58
58
  loadEnded$: Subject<void>;
59
59
  loadError$: Subject<void>;
package/types/config.d.ts CHANGED
@@ -12,6 +12,7 @@ export declare enum LogoType {
12
12
  }
13
13
  export interface IUIConfig {
14
14
  isMobile: ForceOrRelay;
15
+ disableInvisibleComponentsTimeout: Milliseconds;
15
16
  debugLog: boolean | {
16
17
  tag?: string;
17
18
  colors?: string[];
@@ -176,6 +177,15 @@ export interface IUIConfig {
176
177
  * вместо переключения на видео из конфига будут вызываться соответствубщие колбэки
177
178
  */
178
179
  useCallbackForMediaSessionNextPrevClick: boolean;
180
+ /**
181
+ * Фикс производительности отрисовки.
182
+ */
183
+ usePerformanceFix: boolean;
184
+ /**
185
+ * Включает восстановление выбранных настроек видео,
186
+ * например, звуковой дорожки и субтитров
187
+ */
188
+ userVideoPrefs: boolean;
179
189
  };
180
190
  interactive: {
181
191
  historyMaxLength: number;
@@ -204,6 +214,8 @@ export interface IUIConfig {
204
214
  controlsGradientHeight: string | null;
205
215
  controlsGradient: string | null;
206
216
  };
217
+ /** уникальный идентификатор пользователя для сохранения настроек */
218
+ userSalt: string;
207
219
  }
208
220
  export declare const defaultConfig: IUIConfig;
209
221
  export type IOptionalUIConfig = RecursivePartial<IUIConfig>;
@@ -0,0 +1,4 @@
1
+ import type { Attachment } from 'svelte/attachments';
2
+ import type { Writable } from 'svelte/store';
3
+ import type { Milliseconds } from '@vkontakte/videoplayer-shared';
4
+ export declare const deferredDisableByCondition: (condition: boolean, disable: Writable<boolean>, disableTimeout: Milliseconds) => Attachment;
@@ -33,4 +33,13 @@ export type QualitySettingsAppliesTo = 'as-default' | 'to-video';
33
33
  export declare const getPreferredQualitySettings: (videoId: number | undefined) => (PreferredQualitySettingsValue & {
34
34
  appliesTo: QualitySettingsAppliesTo;
35
35
  }) | null, migrateSettingsToLegacyWay: (videoId?: number) => void, savePreferredQualitySettings: (value: PreferredQualitySettingsValue, appliesTo?: QualitySettingsAppliesTo) => void, savePreferredDefaultQualitySettings: (value: DefaultPreferredQualitySettingsValue) => void, removePreferredQualitySettingsByVideo: () => void, getPreferredDefaultQualitySettings: () => DefaultPreferredQualitySettingsValue | null;
36
+ type IUserSalt = string & {};
37
+ type IVideoId = string & {};
38
+ interface IVideoPrefsUserVideo {
39
+ updatedTs: number;
40
+ subtitleTrackId?: string;
41
+ audioTrackId?: string;
42
+ }
43
+ export declare const getUserVideoPrefs: (userSalt: IUserSalt, videoId: IVideoId) => IVideoPrefsUserVideo | null;
44
+ export declare const saveUserVideoPrefs: (userSalt: IUserSalt, videoId: IVideoId, settings: Omit<IVideoPrefsUserVideo, "updatedTs">) => void;
36
45
  export {};