@ezuikit/player-theme 0.0.1-alpha.2 → 0.0.1-alpha.4

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/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * @ezuikit/player-theme v0.0.1-alpha.2
2
+ * @ezuikit/player-theme v0.0.1-alpha.4
3
3
  * Copyright (c) 2025-10-08 Ezviz-OpenBiz
4
4
  * Released under the MIT License.
5
5
  */
@@ -65,6 +65,18 @@ const THEME_PROPS = [
65
65
  'deviceID',
66
66
  'deviceName'
67
67
  ];
68
+ /**
69
+ * 暂停时能禁用的控件按钮
70
+ */ const PAUSE_DISABLED_BTN = [
71
+ 'capturePicture',
72
+ 'volume',
73
+ 'ptz',
74
+ 'record',
75
+ 'talk',
76
+ 'definition',
77
+ 'speed',
78
+ 'globalFullscreen'
79
+ ];
68
80
  /**
69
81
  * 移动端可以扩展的控件
70
82
  * ['ptz', 'talk', 'record', 'capturePicture', 'timeLine', 'rec', 'date'];
@@ -9546,7 +9558,6 @@ const THEME_DEFAULT_OPTIONS = {
9546
9558
  this._playing = playing;
9547
9559
  if (!playing) {
9548
9560
  this.loading = false;
9549
- this._disabled(true);
9550
9561
  [
9551
9562
  'ptz',
9552
9563
  'talk',
@@ -9556,6 +9567,7 @@ const THEME_DEFAULT_OPTIONS = {
9556
9567
  this.controls[`${key}Control`].reset();
9557
9568
  }
9558
9569
  });
9570
+ this._disabled(true);
9559
9571
  }
9560
9572
  this.emit(EVENTS.play, playing);
9561
9573
  if ((_this_controls = this.controls) == null ? void 0 : _this_controls.playControl) {
@@ -10442,11 +10454,11 @@ const THEME_DEFAULT_OPTIONS = {
10442
10454
  * 禁用按钮
10443
10455
  * @private
10444
10456
  */ _disabled(disabled = true) {
10445
- // PAUSE_DISABLED_BTN.forEach((btn) => {
10446
- // if (this.controls[`${btn}Control`]) {
10447
- // this.controls[`${btn}Control`].disabled = disabled;
10448
- // }
10449
- // });
10457
+ PAUSE_DISABLED_BTN.forEach((btn)=>{
10458
+ if (this.controls[`${btn}Control`]) {
10459
+ this.controls[`${btn}Control`].disabled = disabled;
10460
+ }
10461
+ });
10450
10462
  }
10451
10463
  _onDblClickFullscreen() {
10452
10464
  if (this.isCurrentFullscreen) {
@@ -10588,7 +10600,7 @@ const THEME_DEFAULT_OPTIONS = {
10588
10600
  zh,
10589
10601
  en
10590
10602
  };
10591
- /** 版本号 @since 0.0.1 */ Theme.THEME_VERSION = '0.0.1-alpha.2';
10603
+ /** 版本号 @since 0.0.1 */ Theme.THEME_VERSION = '0.0.1-alpha.4';
10592
10604
 
10593
10605
  exports.Control = Control;
10594
10606
  exports.Fullscreen = Fullscreen;
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * @ezuikit/player-theme v0.0.1-alpha.2
2
+ * @ezuikit/player-theme v0.0.1-alpha.4
3
3
  * Copyright (c) 2025-10-08 Ezviz-OpenBiz
4
4
  * Released under the MIT License.
5
5
  */
@@ -61,6 +61,18 @@ const THEME_PROPS = [
61
61
  'deviceID',
62
62
  'deviceName'
63
63
  ];
64
+ /**
65
+ * 暂停时能禁用的控件按钮
66
+ */ const PAUSE_DISABLED_BTN = [
67
+ 'capturePicture',
68
+ 'volume',
69
+ 'ptz',
70
+ 'record',
71
+ 'talk',
72
+ 'definition',
73
+ 'speed',
74
+ 'globalFullscreen'
75
+ ];
64
76
  /**
65
77
  * 移动端可以扩展的控件
66
78
  * ['ptz', 'talk', 'record', 'capturePicture', 'timeLine', 'rec', 'date'];
@@ -9542,7 +9554,6 @@ const THEME_DEFAULT_OPTIONS = {
9542
9554
  this._playing = playing;
9543
9555
  if (!playing) {
9544
9556
  this.loading = false;
9545
- this._disabled(true);
9546
9557
  [
9547
9558
  'ptz',
9548
9559
  'talk',
@@ -9552,6 +9563,7 @@ const THEME_DEFAULT_OPTIONS = {
9552
9563
  this.controls[`${key}Control`].reset();
9553
9564
  }
9554
9565
  });
9566
+ this._disabled(true);
9555
9567
  }
9556
9568
  this.emit(EVENTS.play, playing);
9557
9569
  if ((_this_controls = this.controls) == null ? void 0 : _this_controls.playControl) {
@@ -10438,11 +10450,11 @@ const THEME_DEFAULT_OPTIONS = {
10438
10450
  * 禁用按钮
10439
10451
  * @private
10440
10452
  */ _disabled(disabled = true) {
10441
- // PAUSE_DISABLED_BTN.forEach((btn) => {
10442
- // if (this.controls[`${btn}Control`]) {
10443
- // this.controls[`${btn}Control`].disabled = disabled;
10444
- // }
10445
- // });
10453
+ PAUSE_DISABLED_BTN.forEach((btn)=>{
10454
+ if (this.controls[`${btn}Control`]) {
10455
+ this.controls[`${btn}Control`].disabled = disabled;
10456
+ }
10457
+ });
10446
10458
  }
10447
10459
  _onDblClickFullscreen() {
10448
10460
  if (this.isCurrentFullscreen) {
@@ -10584,6 +10596,6 @@ const THEME_DEFAULT_OPTIONS = {
10584
10596
  zh,
10585
10597
  en
10586
10598
  };
10587
- /** 版本号 @since 0.0.1 */ Theme.THEME_VERSION = '0.0.1-alpha.2';
10599
+ /** 版本号 @since 0.0.1 */ Theme.THEME_VERSION = '0.0.1-alpha.4';
10588
10600
 
10589
10601
  export { Control, Fullscreen, Loading, Message, Play, Poster, Rec, Theme, Utils, Volume, Theme as default };
package/dist/index.umd.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * @ezuikit/player-theme v0.0.1-alpha.2
2
+ * @ezuikit/player-theme v0.0.1-alpha.4
3
3
  * Copyright (c) 2025-10-08 Ezviz-OpenBiz
4
4
  * Released under the MIT License.
5
5
  */
@@ -412,6 +412,18 @@
412
412
  'deviceID',
413
413
  'deviceName'
414
414
  ];
415
+ /**
416
+ * 暂停时能禁用的控件按钮
417
+ */ var PAUSE_DISABLED_BTN = [
418
+ 'capturePicture',
419
+ 'volume',
420
+ 'ptz',
421
+ 'record',
422
+ 'talk',
423
+ 'definition',
424
+ 'speed',
425
+ 'globalFullscreen'
426
+ ];
415
427
  /**
416
428
  * 移动端可以扩展的控件
417
429
  * ['ptz', 'talk', 'record', 'capturePicture', 'timeLine', 'rec', 'date'];
@@ -13357,11 +13369,13 @@
13357
13369
  * 禁用按钮
13358
13370
  * @private
13359
13371
  */ _proto._disabled = function _disabled(disabled) {
13360
- // PAUSE_DISABLED_BTN.forEach((btn) => {
13361
- // if (this.controls[`${btn}Control`]) {
13362
- // this.controls[`${btn}Control`].disabled = disabled;
13363
- // }
13364
- // });
13372
+ var _this = this;
13373
+ if (disabled === void 0) disabled = true;
13374
+ PAUSE_DISABLED_BTN.forEach(function(btn) {
13375
+ if (_this.controls["" + btn + "Control"]) {
13376
+ _this.controls["" + btn + "Control"].disabled = disabled;
13377
+ }
13378
+ });
13365
13379
  };
13366
13380
  _proto._onDblClickFullscreen = function _onDblClickFullscreen() {
13367
13381
  if (this.isCurrentFullscreen) {
@@ -13469,7 +13483,6 @@
13469
13483
  this._playing = playing;
13470
13484
  if (!playing) {
13471
13485
  this.loading = false;
13472
- this._disabled(true);
13473
13486
  [
13474
13487
  'ptz',
13475
13488
  'talk',
@@ -13479,6 +13492,7 @@
13479
13492
  _this.controls["" + key + "Control"].reset();
13480
13493
  }
13481
13494
  });
13495
+ this._disabled(true);
13482
13496
  }
13483
13497
  this.emit(EVENTS.play, playing);
13484
13498
  if ((_this_controls = this.controls) == null ? void 0 : _this_controls.playControl) {
@@ -13831,7 +13845,7 @@
13831
13845
  zh: zh,
13832
13846
  en: en
13833
13847
  };
13834
- /** 版本号 @since 0.0.1 */ Theme.THEME_VERSION = '0.0.1-alpha.2';
13848
+ /** 版本号 @since 0.0.1 */ Theme.THEME_VERSION = '0.0.1-alpha.4';
13835
13849
 
13836
13850
  // 不要动这里的代码, 这个出口是为了编译成 umd 规范的文件
13837
13851
 
package/dist/style.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * @ezuikit/player-theme v0.0.1-alpha.2
2
+ * @ezuikit/player-theme v0.0.1-alpha.4
3
3
  * Copyright (c) 2025-10-08 Ezviz-OpenBiz
4
4
  * Released under the MIT License.
5
5
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ezuikit/player-theme",
3
- "version": "0.0.1-alpha.2",
3
+ "version": "0.0.1-alpha.4",
4
4
  "description": "player theme",
5
5
  "title": "theme",
6
6
  "main": "dist/index.js",