@volcengine/veplayer 2.10.0 → 2.10.2-rc.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.
@@ -2297,6 +2297,7 @@ declare class VePlayerBase {
2297
2297
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
2298
2298
  private _transformEvent;
2299
2299
  private _switch;
2300
+ private _restartLiveLogger;
2300
2301
  private _switchDifferentProtocolUrl;
2301
2302
  private _switchUrl;
2302
2303
  private _callBeforePlayerInitForUrl;
@@ -13322,7 +13322,7 @@ var __publicField = (obj, key, value) => {
13322
13322
  var lodash_curry = curry;
13323
13323
  var curry$1 = /* @__PURE__ */ getDefaultExportFromCjs(lodash_curry);
13324
13324
  const src = typeof document === "undefined" && typeof location === "undefined" ? require("url").pathToFileURL(__filename).href : typeof document === "undefined" ? location.href : document.currentScript && document.currentScript.src || new URL("umd/veplayer.vod.development.js", document.baseURI).href;
13325
- const baseUrl = src.slice(0, src.lastIndexOf("/"));
13325
+ const baseUrl = src == null ? void 0 : src.slice(0, src == null ? void 0 : src.lastIndexOf("/"));
13326
13326
  const loader = new Loader({
13327
13327
  baseUrl
13328
13328
  });
@@ -14383,7 +14383,7 @@ var __publicField = (obj, key, value) => {
14383
14383
  * @brief Retrieve the player SDK version number.
14384
14384
  */
14385
14385
  get playerVersion() {
14386
- return "2.10.0";
14386
+ return "2.10.2-rc.0";
14387
14387
  }
14388
14388
  /** {zh}
14389
14389
  * @brief 获取当前播放视频的清晰度唯一标识(definition)。
@@ -14945,6 +14945,7 @@ var __publicField = (obj, key, value) => {
14945
14945
  var _a, _b, _c, _d, _e, _f, _g, _h;
14946
14946
  const preDefinition = clonedeep(this._sourceManager.definition);
14947
14947
  const isPaused = this._player.paused && !this._player.isError;
14948
+ this._restartLiveLogger();
14948
14949
  const {
14949
14950
  plugins: newPlugins,
14950
14951
  options,
@@ -14982,6 +14983,13 @@ var __publicField = (obj, key, value) => {
14982
14983
  isDefinitionSwitching && this.emit(Events.AFTER_DEFINITION_CHANGE);
14983
14984
  }
14984
14985
  }
14986
+ _restartLiveLogger() {
14987
+ var _a, _b, _c, _d;
14988
+ const liveLogger = (_c = (_b = (_a = this._player) == null ? void 0 : _a.plugins) == null ? void 0 : _b.logger) == null ? void 0 : _c._liveLogger;
14989
+ if ((_d = liveLogger == null ? void 0 : liveLogger.logger) == null ? void 0 : _d.destroyed) {
14990
+ liveLogger == null ? void 0 : liveLogger.restart(false);
14991
+ }
14992
+ }
14985
14993
  async _switchDifferentProtocolUrl(plugins, url, isPaused, useSrc) {
14986
14994
  var _a, _b;
14987
14995
  if (useSrc && this._player.media) {
@@ -15018,6 +15026,7 @@ var __publicField = (obj, key, value) => {
15018
15026
  }
15019
15027
  async _switchUrl(url, config) {
15020
15028
  const isPaused = this._player.paused && !this._player.isError;
15029
+ this._restartLiveLogger();
15021
15030
  const {
15022
15031
  plugins: newPlugins,
15023
15032
  options,