@ericchen1990/pano-view 3.1.0 → 3.1.1

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.cjs CHANGED
@@ -46,7 +46,7 @@ var require_howler = __commonJS({
46
46
  * @return {Howler}
47
47
  */
48
48
  init: function() {
49
- var self = this || Howler3;
49
+ var self = this || Howler4;
50
50
  self._counter = 1e3;
51
51
  self._html5AudioPool = [];
52
52
  self.html5PoolSize = 10;
@@ -71,7 +71,7 @@ var require_howler = __commonJS({
71
71
  * @return {Howler/Float} Returns self or current volume.
72
72
  */
73
73
  volume: function(vol) {
74
- var self = this || Howler3;
74
+ var self = this || Howler4;
75
75
  vol = parseFloat(vol);
76
76
  if (!self.ctx) {
77
77
  setupAudioContext();
@@ -82,7 +82,7 @@ var require_howler = __commonJS({
82
82
  return self;
83
83
  }
84
84
  if (self.usingWebAudio) {
85
- self.masterGain.gain.setValueAtTime(vol, Howler3.ctx.currentTime);
85
+ self.masterGain.gain.setValueAtTime(vol, Howler4.ctx.currentTime);
86
86
  }
87
87
  for (var i = 0; i < self._howls.length; i++) {
88
88
  if (!self._howls[i]._webAudio) {
@@ -104,13 +104,13 @@ var require_howler = __commonJS({
104
104
  * @param {Boolean} muted Is muted or not.
105
105
  */
106
106
  mute: function(muted) {
107
- var self = this || Howler3;
107
+ var self = this || Howler4;
108
108
  if (!self.ctx) {
109
109
  setupAudioContext();
110
110
  }
111
111
  self._muted = muted;
112
112
  if (self.usingWebAudio) {
113
- self.masterGain.gain.setValueAtTime(muted ? 0 : self._volume, Howler3.ctx.currentTime);
113
+ self.masterGain.gain.setValueAtTime(muted ? 0 : self._volume, Howler4.ctx.currentTime);
114
114
  }
115
115
  for (var i = 0; i < self._howls.length; i++) {
116
116
  if (!self._howls[i]._webAudio) {
@@ -129,7 +129,7 @@ var require_howler = __commonJS({
129
129
  * Handle stopping all sounds globally.
130
130
  */
131
131
  stop: function() {
132
- var self = this || Howler3;
132
+ var self = this || Howler4;
133
133
  for (var i = 0; i < self._howls.length; i++) {
134
134
  self._howls[i].stop();
135
135
  }
@@ -140,7 +140,7 @@ var require_howler = __commonJS({
140
140
  * @return {Howler}
141
141
  */
142
142
  unload: function() {
143
- var self = this || Howler3;
143
+ var self = this || Howler4;
144
144
  for (var i = self._howls.length - 1; i >= 0; i--) {
145
145
  self._howls[i].unload();
146
146
  }
@@ -157,14 +157,14 @@ var require_howler = __commonJS({
157
157
  * @return {Boolean}
158
158
  */
159
159
  codecs: function(ext) {
160
- return (this || Howler3)._codecs[ext.replace(/^x-/, "")];
160
+ return (this || Howler4)._codecs[ext.replace(/^x-/, "")];
161
161
  },
162
162
  /**
163
163
  * Setup various state values for global tracking.
164
164
  * @return {Howler}
165
165
  */
166
166
  _setup: function() {
167
- var self = this || Howler3;
167
+ var self = this || Howler4;
168
168
  self.state = self.ctx ? self.ctx.state || "suspended" : "suspended";
169
169
  self._autoSuspend();
170
170
  if (!self.usingWebAudio) {
@@ -198,7 +198,7 @@ var require_howler = __commonJS({
198
198
  * @return {Howler}
199
199
  */
200
200
  _setupCodecs: function() {
201
- var self = this || Howler3;
201
+ var self = this || Howler4;
202
202
  var audioTest = null;
203
203
  try {
204
204
  audioTest = typeof Audio !== "undefined" ? new Audio() : null;
@@ -241,7 +241,7 @@ var require_howler = __commonJS({
241
241
  * @return {Howler}
242
242
  */
243
243
  _unlockAudio: function() {
244
- var self = this || Howler3;
244
+ var self = this || Howler4;
245
245
  if (self._audioUnlocked || !self.ctx) {
246
246
  return;
247
247
  }
@@ -311,7 +311,7 @@ var require_howler = __commonJS({
311
311
  * @return {Audio} HTML5 Audio object.
312
312
  */
313
313
  _obtainHtml5Audio: function() {
314
- var self = this || Howler3;
314
+ var self = this || Howler4;
315
315
  if (self._html5AudioPool.length) {
316
316
  return self._html5AudioPool.pop();
317
317
  }
@@ -328,7 +328,7 @@ var require_howler = __commonJS({
328
328
  * @return {Howler}
329
329
  */
330
330
  _releaseHtml5Audio: function(audio) {
331
- var self = this || Howler3;
331
+ var self = this || Howler4;
332
332
  if (audio._unlocked) {
333
333
  self._html5AudioPool.push(audio);
334
334
  }
@@ -341,7 +341,7 @@ var require_howler = __commonJS({
341
341
  */
342
342
  _autoSuspend: function() {
343
343
  var self = this;
344
- if (!self.autoSuspend || !self.ctx || typeof self.ctx.suspend === "undefined" || !Howler3.usingWebAudio) {
344
+ if (!self.autoSuspend || !self.ctx || typeof self.ctx.suspend === "undefined" || !Howler4.usingWebAudio) {
345
345
  return;
346
346
  }
347
347
  for (var i = 0; i < self._howls.length; i++) {
@@ -379,7 +379,7 @@ var require_howler = __commonJS({
379
379
  */
380
380
  _autoResume: function() {
381
381
  var self = this;
382
- if (!self.ctx || typeof self.ctx.resume === "undefined" || !Howler3.usingWebAudio) {
382
+ if (!self.ctx || typeof self.ctx.resume === "undefined" || !Howler4.usingWebAudio) {
383
383
  return;
384
384
  }
385
385
  if (self.state === "running" && self.ctx.state !== "interrupted" && self._suspendTimer) {
@@ -402,7 +402,7 @@ var require_howler = __commonJS({
402
402
  return self;
403
403
  }
404
404
  };
405
- var Howler3 = new HowlerGlobal2();
405
+ var Howler4 = new HowlerGlobal2();
406
406
  var Howl3 = function(o) {
407
407
  var self = this;
408
408
  if (!o.src || o.src.length === 0) {
@@ -419,7 +419,7 @@ var require_howler = __commonJS({
419
419
  */
420
420
  init: function(o) {
421
421
  var self = this;
422
- if (!Howler3.ctx) {
422
+ if (!Howler4.ctx) {
423
423
  setupAudioContext();
424
424
  }
425
425
  self._autoplay = o.autoplay || false;
@@ -458,11 +458,11 @@ var require_howler = __commonJS({
458
458
  self._onseek = o.onseek ? [{ fn: o.onseek }] : [];
459
459
  self._onunlock = o.onunlock ? [{ fn: o.onunlock }] : [];
460
460
  self._onresume = [];
461
- self._webAudio = Howler3.usingWebAudio && !self._html5;
462
- if (typeof Howler3.ctx !== "undefined" && Howler3.ctx && Howler3.autoUnlock) {
463
- Howler3._unlockAudio();
461
+ self._webAudio = Howler4.usingWebAudio && !self._html5;
462
+ if (typeof Howler4.ctx !== "undefined" && Howler4.ctx && Howler4.autoUnlock) {
463
+ Howler4._unlockAudio();
464
464
  }
465
- Howler3._howls.push(self);
465
+ Howler4._howls.push(self);
466
466
  if (self._autoplay) {
467
467
  self._queue.push({
468
468
  event: "play",
@@ -483,7 +483,7 @@ var require_howler = __commonJS({
483
483
  load: function() {
484
484
  var self = this;
485
485
  var url = null;
486
- if (Howler3.noAudio) {
486
+ if (Howler4.noAudio) {
487
487
  self._emit("loaderror", null, "No audio support.");
488
488
  return;
489
489
  }
@@ -511,7 +511,7 @@ var require_howler = __commonJS({
511
511
  if (!ext) {
512
512
  console.warn('No file extension was found. Consider using the "format" property or specify an extension.');
513
513
  }
514
- if (ext && Howler3.codecs(ext)) {
514
+ if (ext && Howler4.codecs(ext)) {
515
515
  url = self._src[i];
516
516
  break;
517
517
  }
@@ -589,7 +589,7 @@ var require_howler = __commonJS({
589
589
  return sound._id;
590
590
  }
591
591
  if (self._webAudio) {
592
- Howler3._autoResume();
592
+ Howler4._autoResume();
593
593
  }
594
594
  var seek = Math.max(0, sound._seek > 0 ? sound._seek : self._sprite[sprite][0] / 1e3);
595
595
  var duration = Math.max(0, (self._sprite[sprite][0] + self._sprite[sprite][1]) / 1e3 - seek);
@@ -616,8 +616,8 @@ var require_howler = __commonJS({
616
616
  setParams();
617
617
  self._refreshBuffer(sound);
618
618
  var vol = sound._muted || self._muted ? 0 : sound._volume;
619
- node.gain.setValueAtTime(vol, Howler3.ctx.currentTime);
620
- sound._playStart = Howler3.ctx.currentTime;
619
+ node.gain.setValueAtTime(vol, Howler4.ctx.currentTime);
620
+ sound._playStart = Howler4.ctx.currentTime;
621
621
  if (typeof node.bufferSource.start === "undefined") {
622
622
  sound._loop ? node.bufferSource.noteGrainOn(0, seek, 86400) : node.bufferSource.noteGrainOn(0, seek, duration);
623
623
  } else {
@@ -633,7 +633,7 @@ var require_howler = __commonJS({
633
633
  }, 0);
634
634
  }
635
635
  };
636
- if (Howler3.state === "running" && Howler3.ctx.state !== "interrupted") {
636
+ if (Howler4.state === "running" && Howler4.ctx.state !== "interrupted") {
637
637
  playWebAudio();
638
638
  } else {
639
639
  self._playLock = true;
@@ -643,8 +643,8 @@ var require_howler = __commonJS({
643
643
  } else {
644
644
  var playHtml5 = function() {
645
645
  node.currentTime = seek;
646
- node.muted = sound._muted || self._muted || Howler3._muted || node.muted;
647
- node.volume = sound._volume * Howler3.volume();
646
+ node.muted = sound._muted || self._muted || Howler4._muted || node.muted;
647
+ node.volume = sound._volume * Howler4.volume();
648
648
  node.playbackRate = sound._rate;
649
649
  try {
650
650
  var play = node.play();
@@ -692,7 +692,7 @@ var require_howler = __commonJS({
692
692
  node.src = self._src;
693
693
  node.load();
694
694
  }
695
- var loadedNoReadyState = window && window.ejecta || !node.readyState && Howler3._navigator.isCocoonJS;
695
+ var loadedNoReadyState = window && window.ejecta || !node.readyState && Howler4._navigator.isCocoonJS;
696
696
  if (node.readyState >= 3 || loadedNoReadyState) {
697
697
  playHtml5();
698
698
  } else {
@@ -701,9 +701,9 @@ var require_howler = __commonJS({
701
701
  var listener = function() {
702
702
  self._state = "loaded";
703
703
  playHtml5();
704
- node.removeEventListener(Howler3._canPlayEvent, listener, false);
704
+ node.removeEventListener(Howler4._canPlayEvent, listener, false);
705
705
  };
706
- node.addEventListener(Howler3._canPlayEvent, listener, false);
706
+ node.addEventListener(Howler4._canPlayEvent, listener, false);
707
707
  self._clearTimer(sound._id);
708
708
  }
709
709
  }
@@ -841,9 +841,9 @@ var require_howler = __commonJS({
841
841
  self._stopFade(sound._id);
842
842
  }
843
843
  if (self._webAudio && sound._node) {
844
- sound._node.gain.setValueAtTime(muted ? 0 : sound._volume, Howler3.ctx.currentTime);
844
+ sound._node.gain.setValueAtTime(muted ? 0 : sound._volume, Howler4.ctx.currentTime);
845
845
  } else if (sound._node) {
846
- sound._node.muted = Howler3._muted ? true : muted;
846
+ sound._node.muted = Howler4._muted ? true : muted;
847
847
  }
848
848
  self._emit("mute", sound._id);
849
849
  }
@@ -899,9 +899,9 @@ var require_howler = __commonJS({
899
899
  self._stopFade(id[i]);
900
900
  }
901
901
  if (self._webAudio && sound._node && !sound._muted) {
902
- sound._node.gain.setValueAtTime(vol, Howler3.ctx.currentTime);
902
+ sound._node.gain.setValueAtTime(vol, Howler4.ctx.currentTime);
903
903
  } else if (sound._node && !sound._muted) {
904
- sound._node.volume = vol * Howler3.volume();
904
+ sound._node.volume = vol * Howler4.volume();
905
905
  }
906
906
  self._emit("volume", sound._id);
907
907
  }
@@ -943,7 +943,7 @@ var require_howler = __commonJS({
943
943
  self._stopFade(ids[i]);
944
944
  }
945
945
  if (self._webAudio && !sound._muted) {
946
- var currentTime = Howler3.ctx.currentTime;
946
+ var currentTime = Howler4.ctx.currentTime;
947
947
  var end = currentTime + len / 1e3;
948
948
  sound._volume = from;
949
949
  sound._node.gain.setValueAtTime(from, currentTime);
@@ -1009,7 +1009,7 @@ var require_howler = __commonJS({
1009
1009
  var sound = self._soundById(id);
1010
1010
  if (sound && sound._interval) {
1011
1011
  if (self._webAudio) {
1012
- sound._node.gain.cancelScheduledValues(Howler3.ctx.currentTime);
1012
+ sound._node.gain.cancelScheduledValues(Howler4.ctx.currentTime);
1013
1013
  }
1014
1014
  clearInterval(sound._interval);
1015
1015
  sound._interval = null;
@@ -1111,11 +1111,11 @@ var require_howler = __commonJS({
1111
1111
  if (sound) {
1112
1112
  if (self.playing(id[i])) {
1113
1113
  sound._rateSeek = self.seek(id[i]);
1114
- sound._playStart = self._webAudio ? Howler3.ctx.currentTime : sound._playStart;
1114
+ sound._playStart = self._webAudio ? Howler4.ctx.currentTime : sound._playStart;
1115
1115
  }
1116
1116
  sound._rate = rate;
1117
1117
  if (self._webAudio && sound._node && sound._node.bufferSource) {
1118
- sound._node.bufferSource.playbackRate.setValueAtTime(rate, Howler3.ctx.currentTime);
1118
+ sound._node.bufferSource.playbackRate.setValueAtTime(rate, Howler4.ctx.currentTime);
1119
1119
  } else if (sound._node) {
1120
1120
  sound._node.playbackRate = rate;
1121
1121
  }
@@ -1209,7 +1209,7 @@ var require_howler = __commonJS({
1209
1209
  }
1210
1210
  } else {
1211
1211
  if (self._webAudio) {
1212
- var realTime = self.playing(id) ? Howler3.ctx.currentTime - sound._playStart : 0;
1212
+ var realTime = self.playing(id) ? Howler4.ctx.currentTime - sound._playStart : 0;
1213
1213
  var rateSeek = sound._rateSeek ? sound._rateSeek - sound._seek : 0;
1214
1214
  return sound._seek + (rateSeek + realTime * Math.abs(sound._rate));
1215
1215
  } else {
@@ -1272,20 +1272,20 @@ var require_howler = __commonJS({
1272
1272
  if (!self._webAudio) {
1273
1273
  self._clearSound(sounds[i]._node);
1274
1274
  sounds[i]._node.removeEventListener("error", sounds[i]._errorFn, false);
1275
- sounds[i]._node.removeEventListener(Howler3._canPlayEvent, sounds[i]._loadFn, false);
1275
+ sounds[i]._node.removeEventListener(Howler4._canPlayEvent, sounds[i]._loadFn, false);
1276
1276
  sounds[i]._node.removeEventListener("ended", sounds[i]._endFn, false);
1277
- Howler3._releaseHtml5Audio(sounds[i]._node);
1277
+ Howler4._releaseHtml5Audio(sounds[i]._node);
1278
1278
  }
1279
1279
  delete sounds[i]._node;
1280
1280
  self._clearTimer(sounds[i]._id);
1281
1281
  }
1282
- var index = Howler3._howls.indexOf(self);
1282
+ var index = Howler4._howls.indexOf(self);
1283
1283
  if (index >= 0) {
1284
- Howler3._howls.splice(index, 1);
1284
+ Howler4._howls.splice(index, 1);
1285
1285
  }
1286
1286
  var remCache = true;
1287
- for (i = 0; i < Howler3._howls.length; i++) {
1288
- if (Howler3._howls[i]._src === self._src || self._src.indexOf(Howler3._howls[i]._src) >= 0) {
1287
+ for (i = 0; i < Howler4._howls.length; i++) {
1288
+ if (Howler4._howls[i]._src === self._src || self._src.indexOf(Howler4._howls[i]._src) >= 0) {
1289
1289
  remCache = false;
1290
1290
  break;
1291
1291
  }
@@ -1293,7 +1293,7 @@ var require_howler = __commonJS({
1293
1293
  if (cache && remCache) {
1294
1294
  delete cache[self._src];
1295
1295
  }
1296
- Howler3.noAudio = false;
1296
+ Howler4.noAudio = false;
1297
1297
  self._state = "unloaded";
1298
1298
  self._sounds = [];
1299
1299
  self = null;
@@ -1426,7 +1426,7 @@ var require_howler = __commonJS({
1426
1426
  self._emit("play", sound._id);
1427
1427
  sound._seek = sound._start || 0;
1428
1428
  sound._rateSeek = 0;
1429
- sound._playStart = Howler3.ctx.currentTime;
1429
+ sound._playStart = Howler4.ctx.currentTime;
1430
1430
  var timeout = (sound._stop - sound._start) * 1e3 / Math.abs(sound._rate);
1431
1431
  self._endTimers[sound._id] = setTimeout(self._ended.bind(self, sound), timeout);
1432
1432
  }
@@ -1437,7 +1437,7 @@ var require_howler = __commonJS({
1437
1437
  sound._rateSeek = 0;
1438
1438
  self._clearTimer(sound._id);
1439
1439
  self._cleanBuffer(sound._node);
1440
- Howler3._autoSuspend();
1440
+ Howler4._autoSuspend();
1441
1441
  }
1442
1442
  if (!self._webAudio && !loop) {
1443
1443
  self.stop(sound._id, true);
@@ -1545,7 +1545,7 @@ var require_howler = __commonJS({
1545
1545
  */
1546
1546
  _refreshBuffer: function(sound) {
1547
1547
  var self = this;
1548
- sound._node.bufferSource = Howler3.ctx.createBufferSource();
1548
+ sound._node.bufferSource = Howler4.ctx.createBufferSource();
1549
1549
  sound._node.bufferSource.buffer = cache[self._src];
1550
1550
  if (sound._panner) {
1551
1551
  sound._node.bufferSource.connect(sound._panner);
@@ -1557,7 +1557,7 @@ var require_howler = __commonJS({
1557
1557
  sound._node.bufferSource.loopStart = sound._start || 0;
1558
1558
  sound._node.bufferSource.loopEnd = sound._stop || 0;
1559
1559
  }
1560
- sound._node.bufferSource.playbackRate.setValueAtTime(sound._rate, Howler3.ctx.currentTime);
1560
+ sound._node.bufferSource.playbackRate.setValueAtTime(sound._rate, Howler4.ctx.currentTime);
1561
1561
  return self;
1562
1562
  },
1563
1563
  /**
@@ -1567,16 +1567,16 @@ var require_howler = __commonJS({
1567
1567
  */
1568
1568
  _cleanBuffer: function(node) {
1569
1569
  var self = this;
1570
- var isIOS = Howler3._navigator && Howler3._navigator.vendor.indexOf("Apple") >= 0;
1570
+ var isIOS = Howler4._navigator && Howler4._navigator.vendor.indexOf("Apple") >= 0;
1571
1571
  if (!node.bufferSource) {
1572
1572
  return self;
1573
1573
  }
1574
- if (Howler3._scratchBuffer && node.bufferSource) {
1574
+ if (Howler4._scratchBuffer && node.bufferSource) {
1575
1575
  node.bufferSource.onended = null;
1576
1576
  node.bufferSource.disconnect(0);
1577
1577
  if (isIOS) {
1578
1578
  try {
1579
- node.bufferSource.buffer = Howler3._scratchBuffer;
1579
+ node.bufferSource.buffer = Howler4._scratchBuffer;
1580
1580
  } catch (e) {
1581
1581
  }
1582
1582
  }
@@ -1589,7 +1589,7 @@ var require_howler = __commonJS({
1589
1589
  * @param {Object} node Audio node to clear.
1590
1590
  */
1591
1591
  _clearSound: function(node) {
1592
- var checkIE = /MSIE |Trident\//.test(Howler3._navigator && Howler3._navigator.userAgent);
1592
+ var checkIE = /MSIE |Trident\//.test(Howler4._navigator && Howler4._navigator.userAgent);
1593
1593
  if (!checkIE) {
1594
1594
  node.src = "data:audio/wav;base64,UklGRigAAABXQVZFZm10IBIAAAABAAEARKwAAIhYAQACABAAAABkYXRhAgAAAAEA";
1595
1595
  }
@@ -1615,7 +1615,7 @@ var require_howler = __commonJS({
1615
1615
  self._paused = true;
1616
1616
  self._ended = true;
1617
1617
  self._sprite = "__default";
1618
- self._id = ++Howler3._counter;
1618
+ self._id = ++Howler4._counter;
1619
1619
  parent._sounds.push(self);
1620
1620
  self.create();
1621
1621
  return self;
@@ -1627,23 +1627,23 @@ var require_howler = __commonJS({
1627
1627
  create: function() {
1628
1628
  var self = this;
1629
1629
  var parent = self._parent;
1630
- var volume = Howler3._muted || self._muted || self._parent._muted ? 0 : self._volume;
1630
+ var volume = Howler4._muted || self._muted || self._parent._muted ? 0 : self._volume;
1631
1631
  if (parent._webAudio) {
1632
- self._node = typeof Howler3.ctx.createGain === "undefined" ? Howler3.ctx.createGainNode() : Howler3.ctx.createGain();
1633
- self._node.gain.setValueAtTime(volume, Howler3.ctx.currentTime);
1632
+ self._node = typeof Howler4.ctx.createGain === "undefined" ? Howler4.ctx.createGainNode() : Howler4.ctx.createGain();
1633
+ self._node.gain.setValueAtTime(volume, Howler4.ctx.currentTime);
1634
1634
  self._node.paused = true;
1635
- self._node.connect(Howler3.masterGain);
1636
- } else if (!Howler3.noAudio) {
1637
- self._node = Howler3._obtainHtml5Audio();
1635
+ self._node.connect(Howler4.masterGain);
1636
+ } else if (!Howler4.noAudio) {
1637
+ self._node = Howler4._obtainHtml5Audio();
1638
1638
  self._errorFn = self._errorListener.bind(self);
1639
1639
  self._node.addEventListener("error", self._errorFn, false);
1640
1640
  self._loadFn = self._loadListener.bind(self);
1641
- self._node.addEventListener(Howler3._canPlayEvent, self._loadFn, false);
1641
+ self._node.addEventListener(Howler4._canPlayEvent, self._loadFn, false);
1642
1642
  self._endFn = self._endListener.bind(self);
1643
1643
  self._node.addEventListener("ended", self._endFn, false);
1644
1644
  self._node.src = parent._src;
1645
1645
  self._node.preload = parent._preload === true ? "auto" : parent._preload;
1646
- self._node.volume = volume * Howler3.volume();
1646
+ self._node.volume = volume * Howler4.volume();
1647
1647
  self._node.load();
1648
1648
  }
1649
1649
  return self;
@@ -1664,7 +1664,7 @@ var require_howler = __commonJS({
1664
1664
  self._paused = true;
1665
1665
  self._ended = true;
1666
1666
  self._sprite = "__default";
1667
- self._id = ++Howler3._counter;
1667
+ self._id = ++Howler4._counter;
1668
1668
  return self;
1669
1669
  },
1670
1670
  /**
@@ -1690,7 +1690,7 @@ var require_howler = __commonJS({
1690
1690
  parent._emit("load");
1691
1691
  parent._loadQueue();
1692
1692
  }
1693
- self._node.removeEventListener(Howler3._canPlayEvent, self._loadFn, false);
1693
+ self._node.removeEventListener(Howler4._canPlayEvent, self._loadFn, false);
1694
1694
  },
1695
1695
  /**
1696
1696
  * HTML5 Audio ended listener callback.
@@ -1772,10 +1772,10 @@ var require_howler = __commonJS({
1772
1772
  error();
1773
1773
  }
1774
1774
  };
1775
- if (typeof Promise !== "undefined" && Howler3.ctx.decodeAudioData.length === 1) {
1776
- Howler3.ctx.decodeAudioData(arraybuffer).then(success).catch(error);
1775
+ if (typeof Promise !== "undefined" && Howler4.ctx.decodeAudioData.length === 1) {
1776
+ Howler4.ctx.decodeAudioData(arraybuffer).then(success).catch(error);
1777
1777
  } else {
1778
- Howler3.ctx.decodeAudioData(arraybuffer, success, error);
1778
+ Howler4.ctx.decodeAudioData(arraybuffer, success, error);
1779
1779
  }
1780
1780
  };
1781
1781
  var loadSound = function(self, buffer) {
@@ -1792,59 +1792,59 @@ var require_howler = __commonJS({
1792
1792
  }
1793
1793
  };
1794
1794
  var setupAudioContext = function() {
1795
- if (!Howler3.usingWebAudio) {
1795
+ if (!Howler4.usingWebAudio) {
1796
1796
  return;
1797
1797
  }
1798
1798
  try {
1799
1799
  if (typeof AudioContext !== "undefined") {
1800
- Howler3.ctx = new AudioContext();
1800
+ Howler4.ctx = new AudioContext();
1801
1801
  } else if (typeof webkitAudioContext !== "undefined") {
1802
- Howler3.ctx = new webkitAudioContext();
1802
+ Howler4.ctx = new webkitAudioContext();
1803
1803
  } else {
1804
- Howler3.usingWebAudio = false;
1804
+ Howler4.usingWebAudio = false;
1805
1805
  }
1806
1806
  } catch (e) {
1807
- Howler3.usingWebAudio = false;
1807
+ Howler4.usingWebAudio = false;
1808
1808
  }
1809
- if (!Howler3.ctx) {
1810
- Howler3.usingWebAudio = false;
1809
+ if (!Howler4.ctx) {
1810
+ Howler4.usingWebAudio = false;
1811
1811
  }
1812
- var iOS = /iP(hone|od|ad)/.test(Howler3._navigator && Howler3._navigator.platform);
1813
- var appVersion = Howler3._navigator && Howler3._navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/);
1812
+ var iOS = /iP(hone|od|ad)/.test(Howler4._navigator && Howler4._navigator.platform);
1813
+ var appVersion = Howler4._navigator && Howler4._navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/);
1814
1814
  var version = appVersion ? parseInt(appVersion[1], 10) : null;
1815
1815
  if (iOS && version && version < 9) {
1816
- var safari = /safari/.test(Howler3._navigator && Howler3._navigator.userAgent.toLowerCase());
1817
- if (Howler3._navigator && !safari) {
1818
- Howler3.usingWebAudio = false;
1816
+ var safari = /safari/.test(Howler4._navigator && Howler4._navigator.userAgent.toLowerCase());
1817
+ if (Howler4._navigator && !safari) {
1818
+ Howler4.usingWebAudio = false;
1819
1819
  }
1820
1820
  }
1821
- if (Howler3.usingWebAudio) {
1822
- Howler3.masterGain = typeof Howler3.ctx.createGain === "undefined" ? Howler3.ctx.createGainNode() : Howler3.ctx.createGain();
1823
- Howler3.masterGain.gain.setValueAtTime(Howler3._muted ? 0 : Howler3._volume, Howler3.ctx.currentTime);
1824
- Howler3.masterGain.connect(Howler3.ctx.destination);
1821
+ if (Howler4.usingWebAudio) {
1822
+ Howler4.masterGain = typeof Howler4.ctx.createGain === "undefined" ? Howler4.ctx.createGainNode() : Howler4.ctx.createGain();
1823
+ Howler4.masterGain.gain.setValueAtTime(Howler4._muted ? 0 : Howler4._volume, Howler4.ctx.currentTime);
1824
+ Howler4.masterGain.connect(Howler4.ctx.destination);
1825
1825
  }
1826
- Howler3._setup();
1826
+ Howler4._setup();
1827
1827
  };
1828
1828
  if (typeof define === "function" && define.amd) {
1829
1829
  define([], function() {
1830
1830
  return {
1831
- Howler: Howler3,
1831
+ Howler: Howler4,
1832
1832
  Howl: Howl3
1833
1833
  };
1834
1834
  });
1835
1835
  }
1836
1836
  if (typeof exports2 !== "undefined") {
1837
- exports2.Howler = Howler3;
1837
+ exports2.Howler = Howler4;
1838
1838
  exports2.Howl = Howl3;
1839
1839
  }
1840
1840
  if (typeof global !== "undefined") {
1841
1841
  global.HowlerGlobal = HowlerGlobal2;
1842
- global.Howler = Howler3;
1842
+ global.Howler = Howler4;
1843
1843
  global.Howl = Howl3;
1844
1844
  global.Sound = Sound2;
1845
1845
  } else if (typeof window !== "undefined") {
1846
1846
  window.HowlerGlobal = HowlerGlobal2;
1847
- window.Howler = Howler3;
1847
+ window.Howler = Howler4;
1848
1848
  window.Howl = Howl3;
1849
1849
  window.Sound = Sound2;
1850
1850
  }
@@ -3848,8 +3848,8 @@ function isProduction2() {
3848
3848
  }
3849
3849
 
3850
3850
  // src/media-activation.tsx
3851
+ var import_howler2 = __toESM(require_howler());
3851
3852
  var import_react11 = require("react");
3852
- var import_jsx_runtime2 = require("react/jsx-runtime");
3853
3853
  var PanoMediaActivationHostContext = (0, import_react11.createContext)(null);
3854
3854
  function createPanoMediaActivationHost() {
3855
3855
  return { intents: /* @__PURE__ */ new Set(), listeners: /* @__PURE__ */ new Set(), revision: 0 };
@@ -3872,6 +3872,15 @@ function subscribePanoMediaActivation(host, listener) {
3872
3872
  function hasPanoMediaActivationIntent(host) {
3873
3873
  return host.intents.size > 0;
3874
3874
  }
3875
+ function needsMediaGesture() {
3876
+ if (typeof navigator !== "undefined" && navigator.userActivation?.hasBeenActive) {
3877
+ return false;
3878
+ }
3879
+ if (import_howler2.Howler.ctx?.state === "running") {
3880
+ return false;
3881
+ }
3882
+ return true;
3883
+ }
3875
3884
  function usePanoMediaActivationIntent(required) {
3876
3885
  const host = (0, import_react11.useContext)(PanoMediaActivationHostContext);
3877
3886
  const keyRef = (0, import_react11.useRef)(null);
@@ -3891,27 +3900,10 @@ function usePanoMediaActivationIntent(required) {
3891
3900
  };
3892
3901
  }, [host, required]);
3893
3902
  }
3894
- function PanoMediaActivationOverlay({
3895
- ariaLabel = "Enable sound",
3896
- className,
3897
- message = "Tap to enable sound",
3898
- onActivate
3899
- }) {
3900
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: cn("pano-media-activation", className), children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
3901
- "button",
3902
- {
3903
- "aria-label": ariaLabel,
3904
- className: "pano-media-activation-button",
3905
- onClick: onActivate,
3906
- type: "button",
3907
- children: message
3908
- }
3909
- ) });
3910
- }
3911
3903
 
3912
3904
  // src/pano-context-menu.tsx
3913
3905
  var import_react12 = require("react");
3914
- var import_jsx_runtime3 = require("react/jsx-runtime");
3906
+ var import_jsx_runtime2 = require("react/jsx-runtime");
3915
3907
  var DEFAULT_ICON_SIZE = 16;
3916
3908
  var MENU_EDGE_PADDING = 8;
3917
3909
  var MIN_PANO_CONTEXT_MENU_BACKGROUND_OPACITY = 0.4;
@@ -4074,7 +4066,7 @@ function DefaultContextMenuPanel({
4074
4066
  padding: resolved.padding,
4075
4067
  ...style
4076
4068
  };
4077
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
4069
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
4078
4070
  "div",
4079
4071
  {
4080
4072
  ref: menuRef,
@@ -4085,7 +4077,7 @@ function DefaultContextMenuPanel({
4085
4077
  style: panelStyle,
4086
4078
  tabIndex: -1,
4087
4079
  children: [
4088
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4080
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4089
4081
  "div",
4090
4082
  {
4091
4083
  "aria-hidden": true,
@@ -4097,9 +4089,9 @@ function DefaultContextMenuPanel({
4097
4089
  }
4098
4090
  }
4099
4091
  ),
4100
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "pano-context-menu-items", children: visibleItems.map((item, index) => {
4092
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "pano-context-menu-items", children: visibleItems.map((item, index) => {
4101
4093
  if (!isActionItem(item)) {
4102
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4094
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4103
4095
  "div",
4104
4096
  {
4105
4097
  "aria-hidden": true,
@@ -4116,7 +4108,7 @@ function DefaultContextMenuPanel({
4116
4108
  );
4117
4109
  }
4118
4110
  const disabled = item.disabled === true;
4119
- const iconNode = item.icon ?? (item.image ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4111
+ const iconNode = item.icon ?? (item.image ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4120
4112
  "img",
4121
4113
  {
4122
4114
  alt: item.imageAlt ?? "",
@@ -4130,7 +4122,7 @@ function DefaultContextMenuPanel({
4130
4122
  }
4131
4123
  }
4132
4124
  ) : null);
4133
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
4125
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
4134
4126
  "button",
4135
4127
  {
4136
4128
  "aria-disabled": disabled || void 0,
@@ -4166,7 +4158,7 @@ function DefaultContextMenuPanel({
4166
4158
  tabIndex: disabled ? -1 : activeIndex === index ? 0 : -1,
4167
4159
  type: "button",
4168
4160
  children: [
4169
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4161
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4170
4162
  "span",
4171
4163
  {
4172
4164
  "aria-hidden": true,
@@ -4178,7 +4170,7 @@ function DefaultContextMenuPanel({
4178
4170
  children: iconNode
4179
4171
  }
4180
4172
  ),
4181
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { style: { flex: 1 }, children: item.label })
4173
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { style: { flex: 1 }, children: item.label })
4182
4174
  ]
4183
4175
  },
4184
4176
  item.id
@@ -4231,7 +4223,7 @@ function PositionedMenuShell({
4231
4223
  top: Math.min(Math.max(rawTop, MENU_EDGE_PADDING), maxTop)
4232
4224
  });
4233
4225
  }, [clientX, clientY, overlayElement, children, viewportRevision]);
4234
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4226
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4235
4227
  "div",
4236
4228
  {
4237
4229
  className: "pano-context-menu-shell",
@@ -4290,7 +4282,7 @@ function usePanoContextMenuOverlay() {
4290
4282
  document.removeEventListener("keydown", handleKeyDown);
4291
4283
  };
4292
4284
  }, [session2]);
4293
- const overlay = /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4285
+ const overlay = /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4294
4286
  "div",
4295
4287
  {
4296
4288
  ref: setOverlayNode,
@@ -4301,7 +4293,7 @@ function usePanoContextMenuOverlay() {
4301
4293
  position: "absolute",
4302
4294
  zIndex: 20
4303
4295
  },
4304
- children: session2 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4296
+ children: session2 ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4305
4297
  PositionedMenuShell,
4306
4298
  {
4307
4299
  clientX: session2.event.clientX,
@@ -4394,9 +4386,9 @@ function PanoContextMenu({
4394
4386
  view,
4395
4387
  render: () => {
4396
4388
  if (hasCustomChildren && current.children) {
4397
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { "data-pano-context-menu": true, style: { pointerEvents: "auto" }, children: current.children({ event, view, close }) });
4389
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { "data-pano-context-menu": true, style: { pointerEvents: "auto" }, children: current.children({ event, view, close }) });
4398
4390
  }
4399
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4391
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4400
4392
  DefaultContextMenuPanel,
4401
4393
  {
4402
4394
  appearance: current.appearance,
@@ -4434,7 +4426,7 @@ function PanoContextMenu({
4434
4426
  return null;
4435
4427
  }
4436
4428
  function ResetViewIcon() {
4437
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
4429
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
4438
4430
  "svg",
4439
4431
  {
4440
4432
  "aria-hidden": true,
@@ -4447,14 +4439,14 @@ function ResetViewIcon() {
4447
4439
  viewBox: "0 0 16 16",
4448
4440
  width: "100%",
4449
4441
  children: [
4450
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M3.5 6.5A4.5 4.5 0 1 1 4 10" }),
4451
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M3.5 3.5v3h3" })
4442
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M3.5 6.5A4.5 4.5 0 1 1 4 10" }),
4443
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M3.5 3.5v3h3" })
4452
4444
  ]
4453
4445
  }
4454
4446
  );
4455
4447
  }
4456
4448
  function FullscreenIcon() {
4457
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4449
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4458
4450
  "svg",
4459
4451
  {
4460
4452
  "aria-hidden": true,
@@ -4466,12 +4458,12 @@ function FullscreenIcon() {
4466
4458
  strokeWidth: "1.75",
4467
4459
  viewBox: "0 0 16 16",
4468
4460
  width: "100%",
4469
- children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M3 6V3h3M10 3h3v3M13 10v3h-3M6 13H3v-3" })
4461
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M3 6V3h3M10 3h3v3M13 10v3h-3M6 13H3v-3" })
4470
4462
  }
4471
4463
  );
4472
4464
  }
4473
4465
  function ExitFullscreenIcon() {
4474
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4466
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
4475
4467
  "svg",
4476
4468
  {
4477
4469
  "aria-hidden": true,
@@ -4483,7 +4475,7 @@ function ExitFullscreenIcon() {
4483
4475
  strokeWidth: "1.75",
4484
4476
  viewBox: "0 0 16 16",
4485
4477
  width: "100%",
4486
- children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M6 3v3H3M10 3v3h3M3 10h3v3M10 10h3v3" })
4478
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M6 3v3H3M10 3v3h3M3 10h3v3M10 10h3v3" })
4487
4479
  }
4488
4480
  );
4489
4481
  }
@@ -4492,7 +4484,7 @@ function createPanoContextMenuPresets(actions) {
4492
4484
  const resetView = {
4493
4485
  id: "pano-reset-view",
4494
4486
  label: "Reset view",
4495
- icon: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ResetViewIcon, {}),
4487
+ icon: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(ResetViewIcon, {}),
4496
4488
  onSelect: () => {
4497
4489
  actions.reset();
4498
4490
  }
@@ -4500,7 +4492,7 @@ function createPanoContextMenuPresets(actions) {
4500
4492
  const fullscreen = {
4501
4493
  id: "pano-fullscreen",
4502
4494
  label: isFullscreen ? "Exit fullscreen" : "Enter fullscreen",
4503
- icon: isFullscreen ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ExitFullscreenIcon, {}) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(FullscreenIcon, {}),
4495
+ icon: isFullscreen ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(ExitFullscreenIcon, {}) : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(FullscreenIcon, {}),
4504
4496
  onSelect: () => {
4505
4497
  actions.toggleFullscreen();
4506
4498
  }
@@ -4598,7 +4590,7 @@ var PanoContextMenuActionsContext = (0, import_react12.createContext)(null);
4598
4590
  // src/pano-cursor.tsx
4599
4591
  var import_fiber5 = require("@react-three/fiber");
4600
4592
  var import_react13 = require("react");
4601
- var import_jsx_runtime4 = require("react/jsx-runtime");
4593
+ var import_jsx_runtime3 = require("react/jsx-runtime");
4602
4594
  var DEFAULT_PANO_CURSORS = {
4603
4595
  default: "grab",
4604
4596
  dragging: "grabbing",
@@ -4740,7 +4732,7 @@ function PanoCursorController({
4740
4732
  release(PANO_DRAG_CLAIM_ID);
4741
4733
  };
4742
4734
  }, [claim, eventBus, release]);
4743
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(PanoCursorContext.Provider, { value: api, children });
4735
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(PanoCursorContext.Provider, { value: api, children });
4744
4736
  }
4745
4737
 
4746
4738
  // src/pano-events.tsx
@@ -5101,7 +5093,7 @@ var DEFAULT_PANORAMA_CAMERA_NEAR = 0.1;
5101
5093
  var DEFAULT_PANORAMA_CAMERA_FAR = DEFAULT_PANORAMA_RADIUS * 2;
5102
5094
 
5103
5095
  // src/panorama-event-surface.tsx
5104
- var import_jsx_runtime5 = require("react/jsx-runtime");
5096
+ var import_jsx_runtime4 = require("react/jsx-runtime");
5105
5097
  var EVENT_SURFACE_RADIUS = DEFAULT_PANORAMA_RADIUS - 1;
5106
5098
  function makePanoramaPointerEvent(event) {
5107
5099
  const nativeEvent = event.nativeEvent;
@@ -5159,7 +5151,7 @@ function PanoramaEventSurface() {
5159
5151
  event.stopPropagation();
5160
5152
  eventBus.emit(type, makePanoramaPointerEvent(event));
5161
5153
  };
5162
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
5154
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
5163
5155
  "mesh",
5164
5156
  {
5165
5157
  renderOrder: -200,
@@ -5169,8 +5161,8 @@ function PanoramaEventSurface() {
5169
5161
  onPointerUp: (event) => emit("pointerup", event),
5170
5162
  onPointerMove: (event) => emit("pointermove", event),
5171
5163
  children: [
5172
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("sphereGeometry", { args: [EVENT_SURFACE_RADIUS, 64, 32] }),
5173
- /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
5164
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("sphereGeometry", { args: [EVENT_SURFACE_RADIUS, 64, 32] }),
5165
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
5174
5166
  "meshBasicMaterial",
5175
5167
  {
5176
5168
  colorWrite: false,
@@ -5352,7 +5344,7 @@ function TouchControls({
5352
5344
 
5353
5345
  // src/video/chrome-overlay.tsx
5354
5346
  var import_react18 = require("react");
5355
- var import_jsx_runtime6 = require("react/jsx-runtime");
5347
+ var import_jsx_runtime5 = require("react/jsx-runtime");
5356
5348
  var PanoChromeOverlayContext = (0, import_react18.createContext)(null);
5357
5349
  function usePanoChromeOverlay() {
5358
5350
  const [overlayElement, setOverlayElement] = (0, import_react18.useState)(
@@ -5365,7 +5357,7 @@ function usePanoChromeOverlay() {
5365
5357
  () => ({ overlayElement }),
5366
5358
  [overlayElement]
5367
5359
  );
5368
- const overlay = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
5360
+ const overlay = /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
5369
5361
  "div",
5370
5362
  {
5371
5363
  className: "pano-chrome-overlay",
@@ -5442,7 +5434,7 @@ var import_react22 = require("react");
5442
5434
 
5443
5435
  // src/video/pano-video-captions.tsx
5444
5436
  var import_react20 = require("react");
5445
- var import_jsx_runtime7 = require("react/jsx-runtime");
5437
+ var import_jsx_runtime6 = require("react/jsx-runtime");
5446
5438
  var DEFAULT_PANO_VIDEO_CAPTION_APPEARANCE = {
5447
5439
  color: "#ffffff",
5448
5440
  background: "rgba(0, 0, 0, 0.55)",
@@ -5490,13 +5482,13 @@ function PanoVideoCaptionsOverlay({
5490
5482
  textShadow: snapshot.captionAppearance.textShadow,
5491
5483
  whiteSpace: "pre-wrap"
5492
5484
  };
5493
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5485
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
5494
5486
  "div",
5495
5487
  {
5496
5488
  className: "pano-video-captions",
5497
5489
  "data-pano-video-captions": "",
5498
5490
  style: wrapperStyle,
5499
- children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { style: textStyle, children: snapshot.captionText })
5491
+ children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { style: textStyle, children: snapshot.captionText })
5500
5492
  }
5501
5493
  );
5502
5494
  }
@@ -5639,7 +5631,7 @@ function cueText(cue) {
5639
5631
  }
5640
5632
 
5641
5633
  // src/video/pano-video-controls.tsx
5642
- var import_jsx_runtime8 = require("react/jsx-runtime");
5634
+ var import_jsx_runtime7 = require("react/jsx-runtime");
5643
5635
  var DEFAULT_PANO_VIDEO_CONTROLS_APPEARANCE = {
5644
5636
  background: "rgba(16, 16, 16, 0.88)",
5645
5637
  color: "#f4f4f4",
@@ -5700,7 +5692,7 @@ function volumeFromClientY(clientY, track) {
5700
5692
  return Math.max(0, Math.min(1, (rect.bottom - clientY) / rect.height));
5701
5693
  }
5702
5694
  function Icon({ path }) {
5703
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5695
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5704
5696
  "svg",
5705
5697
  {
5706
5698
  "aria-hidden": true,
@@ -5712,7 +5704,7 @@ function Icon({ path }) {
5712
5704
  strokeWidth: "1.75",
5713
5705
  viewBox: "0 0 16 16",
5714
5706
  width: "16",
5715
- children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("path", { d: path })
5707
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("path", { d: path })
5716
5708
  }
5717
5709
  );
5718
5710
  }
@@ -5724,7 +5716,7 @@ function ChromeButton({
5724
5716
  label,
5725
5717
  onClick
5726
5718
  }) {
5727
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5719
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5728
5720
  "button",
5729
5721
  {
5730
5722
  "aria-label": label,
@@ -5750,14 +5742,14 @@ function ChromeMenu({
5750
5742
  labelledBy,
5751
5743
  items
5752
5744
  }) {
5753
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5745
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5754
5746
  ChromeMenuSurface,
5755
5747
  {
5756
5748
  appearance,
5757
5749
  id,
5758
5750
  labelledBy,
5759
5751
  role: "menu",
5760
- children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5752
+ children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5761
5753
  ChromeMenuRadioItem,
5762
5754
  {
5763
5755
  active: item.active,
@@ -5777,7 +5769,7 @@ function ChromeMenuSurface({
5777
5769
  labelledBy,
5778
5770
  role
5779
5771
  }) {
5780
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5772
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5781
5773
  "div",
5782
5774
  {
5783
5775
  "aria-labelledby": labelledBy,
@@ -5801,7 +5793,7 @@ function ChromeMenuRadioItem({
5801
5793
  label,
5802
5794
  onClick
5803
5795
  }) {
5804
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5796
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5805
5797
  "button",
5806
5798
  {
5807
5799
  "aria-checked": active,
@@ -5826,7 +5818,7 @@ function ChromeMenuActionItem({
5826
5818
  onClick,
5827
5819
  secondary
5828
5820
  }) {
5829
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
5821
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
5830
5822
  "button",
5831
5823
  {
5832
5824
  className: "pano-video-chrome-menu-action",
@@ -5841,7 +5833,7 @@ function ChromeMenuActionItem({
5841
5833
  },
5842
5834
  type: "button",
5843
5835
  children: [
5844
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { children: label }),
5836
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { children: label }),
5845
5837
  secondary
5846
5838
  ]
5847
5839
  }
@@ -5850,10 +5842,10 @@ function ChromeMenuActionItem({
5850
5842
  function ChromeMenuSectionLabel({
5851
5843
  children
5852
5844
  }) {
5853
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "pano-video-chrome-menu-label", children });
5845
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "pano-video-chrome-menu-label", children });
5854
5846
  }
5855
5847
  function ChromeMenuDivider() {
5856
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "pano-video-chrome-menu-divider" });
5848
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "pano-video-chrome-menu-divider" });
5857
5849
  }
5858
5850
  function CaptionsMenu({
5859
5851
  appearance,
@@ -5866,16 +5858,16 @@ function CaptionsMenu({
5866
5858
  panel,
5867
5859
  snapshot
5868
5860
  }) {
5869
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5861
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5870
5862
  ChromeMenuSurface,
5871
5863
  {
5872
5864
  appearance,
5873
5865
  id,
5874
5866
  labelledBy,
5875
5867
  role: "menu",
5876
- children: panel === "tracks" ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
5877
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "pano-video-chrome-menu-list", children: [
5878
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5868
+ children: panel === "tracks" ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_jsx_runtime7.Fragment, { children: [
5869
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "pano-video-chrome-menu-list", children: [
5870
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5879
5871
  ChromeMenuRadioItem,
5880
5872
  {
5881
5873
  active: snapshot.trackId === null,
@@ -5888,7 +5880,7 @@ function CaptionsMenu({
5888
5880
  ),
5889
5881
  snapshot.tracks.map((track) => {
5890
5882
  const trackItemId = panoVideoTrackId(track);
5891
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5883
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5892
5884
  ChromeMenuRadioItem,
5893
5885
  {
5894
5886
  active: snapshot.trackId === trackItemId,
@@ -5902,29 +5894,29 @@ function CaptionsMenu({
5902
5894
  );
5903
5895
  })
5904
5896
  ] }),
5905
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChromeMenuDivider, {}),
5906
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5897
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ChromeMenuDivider, {}),
5898
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5907
5899
  ChromeMenuActionItem,
5908
5900
  {
5909
5901
  appearance,
5910
5902
  label: "Settings",
5911
5903
  onClick: onOpenSettings,
5912
- secondary: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { "aria-hidden": true, children: "\u203A" })
5904
+ secondary: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { "aria-hidden": true, children: "\u203A" })
5913
5905
  }
5914
5906
  )
5915
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
5916
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5907
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_jsx_runtime7.Fragment, { children: [
5908
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5917
5909
  ChromeMenuActionItem,
5918
5910
  {
5919
5911
  appearance,
5920
5912
  label: "Back",
5921
5913
  onClick: onShowTracks,
5922
- secondary: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { "aria-hidden": true, children: "\u2039" })
5914
+ secondary: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { "aria-hidden": true, children: "\u2039" })
5923
5915
  }
5924
5916
  ),
5925
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChromeMenuDivider, {}),
5926
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChromeMenuSectionLabel, { children: "Font size" }),
5927
- CAPTION_SIZE_OPTIONS.map((option) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5917
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ChromeMenuDivider, {}),
5918
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ChromeMenuSectionLabel, { children: "Font size" }),
5919
+ CAPTION_SIZE_OPTIONS.map((option) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5928
5920
  ChromeMenuRadioItem,
5929
5921
  {
5930
5922
  active: Number(snapshot.captionAppearance.fontSize) === option.value,
@@ -5936,9 +5928,9 @@ function CaptionsMenu({
5936
5928
  },
5937
5929
  option.id
5938
5930
  )),
5939
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChromeMenuDivider, {}),
5940
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChromeMenuSectionLabel, { children: "Background" }),
5941
- CAPTION_BACKGROUND_OPTIONS.map((option) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5931
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ChromeMenuDivider, {}),
5932
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ChromeMenuSectionLabel, { children: "Background" }),
5933
+ CAPTION_BACKGROUND_OPTIONS.map((option) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5942
5934
  ChromeMenuRadioItem,
5943
5935
  {
5944
5936
  active: snapshot.captionAppearance.background === option.value,
@@ -5979,7 +5971,7 @@ function VerticalVolumeSlider({
5979
5971
  }
5980
5972
  };
5981
5973
  const percentLabel = formatVolumePercent(volume);
5982
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
5974
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
5983
5975
  "div",
5984
5976
  {
5985
5977
  className: "pano-video-volume-popover",
@@ -5993,7 +5985,7 @@ function VerticalVolumeSlider({
5993
5985
  pointerEvents: "auto"
5994
5986
  },
5995
5987
  children: [
5996
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
5988
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
5997
5989
  "span",
5998
5990
  {
5999
5991
  "aria-hidden": true,
@@ -6005,14 +5997,14 @@ function VerticalVolumeSlider({
6005
5997
  children: percentLabel
6006
5998
  }
6007
5999
  ),
6008
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6000
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6009
6001
  "div",
6010
6002
  {
6011
6003
  style: {
6012
6004
  paddingBottom: VOLUME_THUMB_SIZE / 2,
6013
6005
  paddingTop: VOLUME_THUMB_SIZE / 2
6014
6006
  },
6015
- children: /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
6007
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
6016
6008
  "div",
6017
6009
  {
6018
6010
  "aria-label": "Volume",
@@ -6045,7 +6037,7 @@ function VerticalVolumeSlider({
6045
6037
  },
6046
6038
  tabIndex: 0,
6047
6039
  children: [
6048
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6040
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6049
6041
  "div",
6050
6042
  {
6051
6043
  style: {
@@ -6060,7 +6052,7 @@ function VerticalVolumeSlider({
6060
6052
  }
6061
6053
  }
6062
6054
  ),
6063
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6055
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6064
6056
  "div",
6065
6057
  {
6066
6058
  style: {
@@ -6119,17 +6111,17 @@ function VolumeControl({
6119
6111
  };
6120
6112
  }, [open, volumeAdjustable]);
6121
6113
  if (!volumeAdjustable) {
6122
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6114
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6123
6115
  ChromeButton,
6124
6116
  {
6125
6117
  appearance,
6126
6118
  label: mutedOrSilent ? "Unmute" : "Mute",
6127
6119
  onClick: onToggleMuted,
6128
- children: mutedOrSilent ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.2 6.2l3.2 3.6M13.4 6.2l-3.2 3.6" }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.5 5.5a3 3 0 0 1 0 5" })
6120
+ children: mutedOrSilent ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.2 6.2l3.2 3.6M13.4 6.2l-3.2 3.6" }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.5 5.5a3 3 0 0 1 0 5" })
6129
6121
  }
6130
6122
  );
6131
6123
  }
6132
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
6124
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
6133
6125
  "div",
6134
6126
  {
6135
6127
  "data-pano-video-volume": "",
@@ -6157,7 +6149,7 @@ function VolumeControl({
6157
6149
  },
6158
6150
  ref: rootRef,
6159
6151
  children: [
6160
- open ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6152
+ open ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6161
6153
  VerticalVolumeSlider,
6162
6154
  {
6163
6155
  appearance,
@@ -6165,7 +6157,7 @@ function VolumeControl({
6165
6157
  volume: displayVolume
6166
6158
  }
6167
6159
  ) : null,
6168
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6160
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6169
6161
  ChromeButton,
6170
6162
  {
6171
6163
  appearance,
@@ -6176,7 +6168,7 @@ function VolumeControl({
6176
6168
  }
6177
6169
  onToggleMuted();
6178
6170
  },
6179
- children: mutedOrSilent ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.2 6.2l3.2 3.6M13.4 6.2l-3.2 3.6" }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.5 5.5a3 3 0 0 1 0 5" })
6171
+ children: mutedOrSilent ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.2 6.2l3.2 3.6M13.4 6.2l-3.2 3.6" }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M3 6.5h2.2L8.5 4v8L5.2 9.5H3zM10.5 5.5a3 3 0 0 1 0 5" })
6180
6172
  }
6181
6173
  )
6182
6174
  ]
@@ -6336,7 +6328,7 @@ function PanoVideoControlsHud({
6336
6328
  let menuNode = null;
6337
6329
  switch (menu) {
6338
6330
  case "rate":
6339
- menuNode = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6331
+ menuNode = /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6340
6332
  ChromeMenu,
6341
6333
  {
6342
6334
  appearance: resolved,
@@ -6355,7 +6347,7 @@ function PanoVideoControlsHud({
6355
6347
  );
6356
6348
  break;
6357
6349
  case "variant":
6358
- menuNode = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6350
+ menuNode = /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6359
6351
  ChromeMenu,
6360
6352
  {
6361
6353
  appearance: resolved,
@@ -6374,7 +6366,7 @@ function PanoVideoControlsHud({
6374
6366
  );
6375
6367
  break;
6376
6368
  case "captions":
6377
- menuNode = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6369
+ menuNode = /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6378
6370
  CaptionsMenu,
6379
6371
  {
6380
6372
  appearance: resolved,
@@ -6398,7 +6390,7 @@ function PanoVideoControlsHud({
6398
6390
  );
6399
6391
  break;
6400
6392
  case "more":
6401
- menuNode = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6393
+ menuNode = /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6402
6394
  ChromeMenu,
6403
6395
  {
6404
6396
  appearance: resolved,
@@ -6464,9 +6456,9 @@ function PanoVideoControlsHud({
6464
6456
  transition: "opacity 160ms ease",
6465
6457
  zIndex: 2
6466
6458
  };
6467
- const rateButton = /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "rate", children: [
6459
+ const rateButton = /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "rate", children: [
6468
6460
  !compact && menu === "rate" ? menuNode : null,
6469
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6461
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6470
6462
  ChromeButton,
6471
6463
  {
6472
6464
  appearance: resolved,
@@ -6474,13 +6466,13 @@ function PanoVideoControlsHud({
6474
6466
  onClick: () => {
6475
6467
  toggleMenu("rate");
6476
6468
  },
6477
- children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "pano-video-chrome-label", id: `${barId}-rate-btn`, children: snapshot.playbackRate === 1 ? "1x" : `${snapshot.playbackRate}x` })
6469
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "pano-video-chrome-label", id: `${barId}-rate-btn`, children: snapshot.playbackRate === 1 ? "1x" : `${snapshot.playbackRate}x` })
6478
6470
  }
6479
6471
  )
6480
6472
  ] });
6481
- const variantButton = canSwitchVariant ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "variant", children: [
6473
+ const variantButton = canSwitchVariant ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "variant", children: [
6482
6474
  !compact && menu === "variant" ? menuNode : null,
6483
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6475
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6484
6476
  ChromeButton,
6485
6477
  {
6486
6478
  appearance: resolved,
@@ -6488,13 +6480,13 @@ function PanoVideoControlsHud({
6488
6480
  onClick: () => {
6489
6481
  toggleMenu("variant");
6490
6482
  },
6491
- children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "pano-video-chrome-label", id: `${barId}-variant-btn`, children: snapshot.variants.find((variant) => variant.id === snapshot.variantId)?.label ?? "Quality" })
6483
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "pano-video-chrome-label", id: `${barId}-variant-btn`, children: snapshot.variants.find((variant) => variant.id === snapshot.variantId)?.label ?? "Quality" })
6492
6484
  }
6493
6485
  )
6494
6486
  ] }) : null;
6495
- const captionsButton = showCaptionsMenu ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "captions", children: [
6487
+ const captionsButton = showCaptionsMenu ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "captions", children: [
6496
6488
  !compact && menu === "captions" ? menuNode : null,
6497
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6489
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6498
6490
  ChromeButton,
6499
6491
  {
6500
6492
  appearance: resolved,
@@ -6502,18 +6494,18 @@ function PanoVideoControlsHud({
6502
6494
  onClick: () => {
6503
6495
  toggleMenu("captions");
6504
6496
  },
6505
- children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { id: `${barId}-captions-btn`, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M2.5 4.5h11v7h-11zM5 7.2h2.4M5 9.2h5.5" }) })
6497
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { id: `${barId}-captions-btn`, children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M2.5 4.5h11v7h-11zM5 7.2h2.4M5 9.2h5.5" }) })
6506
6498
  }
6507
6499
  )
6508
6500
  ] }) : null;
6509
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
6501
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
6510
6502
  "div",
6511
6503
  {
6512
6504
  className: "pano-video-controls",
6513
6505
  "data-pano-video-controls": "",
6514
6506
  style: barStyle,
6515
6507
  children: [
6516
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6508
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6517
6509
  ChromeButton,
6518
6510
  {
6519
6511
  appearance: resolved,
@@ -6521,11 +6513,11 @@ function PanoVideoControlsHud({
6521
6513
  onClick: () => {
6522
6514
  controller.togglePlay();
6523
6515
  },
6524
- children: snapshot.playing ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M5 3.5h2.2v9H5zM8.8 3.5H11v9H8.8z" }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M5 3.2v9.6L13 8z" })
6516
+ children: snapshot.playing ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M5 3.5h2.2v9H5zM8.8 3.5H11v9H8.8z" }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M5 3.2v9.6L13 8z" })
6525
6517
  }
6526
6518
  ),
6527
- hideTime ? null : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "pano-video-time", children: formatMediaTime(snapshot.currentTime) }),
6528
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6519
+ hideTime ? null : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "pano-video-time", children: formatMediaTime(snapshot.currentTime) }),
6520
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6529
6521
  "input",
6530
6522
  {
6531
6523
  "aria-label": "Seek",
@@ -6547,8 +6539,8 @@ function PanoVideoControlsHud({
6547
6539
  value: duration > 0 ? snapshot.currentTime : 0
6548
6540
  }
6549
6541
  ),
6550
- hideTime ? null : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "pano-video-time", children: formatMediaTime(duration) }),
6551
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6542
+ hideTime ? null : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "pano-video-time", children: formatMediaTime(duration) }),
6543
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6552
6544
  VolumeControl,
6553
6545
  {
6554
6546
  appearance: resolved,
@@ -6564,9 +6556,9 @@ function PanoVideoControlsHud({
6564
6556
  volumeAdjustable: snapshot.volumeAdjustable
6565
6557
  }
6566
6558
  ),
6567
- compact ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "more", children: [
6559
+ compact ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "pano-video-menu", "data-pano-video-menu": "more", children: [
6568
6560
  menu !== null ? menuNode : null,
6569
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6561
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6570
6562
  ChromeButton,
6571
6563
  {
6572
6564
  appearance: resolved,
@@ -6575,15 +6567,15 @@ function PanoVideoControlsHud({
6575
6567
  onClick: () => {
6576
6568
  toggleMenu("more");
6577
6569
  },
6578
- children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M3 8a1 1 0 1 0 2 0 1 1 0 1 0-2 0M7 8a1 1 0 1 0 2 0 1 1 0 1 0-2 0M11 8a1 1 0 1 0 2 0 1 1 0 1 0-2 0" })
6570
+ children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M3 8a1 1 0 1 0 2 0 1 1 0 1 0-2 0M7 8a1 1 0 1 0 2 0 1 1 0 1 0-2 0M11 8a1 1 0 1 0 2 0 1 1 0 1 0-2 0" })
6579
6571
  }
6580
6572
  )
6581
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
6573
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_jsx_runtime7.Fragment, { children: [
6582
6574
  rateButton,
6583
6575
  variantButton,
6584
6576
  captionsButton
6585
6577
  ] }),
6586
- showFullscreen ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6578
+ showFullscreen ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
6587
6579
  ChromeButton,
6588
6580
  {
6589
6581
  appearance: resolved,
@@ -6591,7 +6583,7 @@ function PanoVideoControlsHud({
6591
6583
  onClick: () => {
6592
6584
  fullscreen?.toggleFullscreen();
6593
6585
  },
6594
- children: fullscreen?.isFullscreen ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M6 3.5H3.5V6M10 3.5h2.5V6M6 12.5H3.5V10M10 12.5h2.5V10" }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Icon, { path: "M3.5 6V3.5H6M10 3.5h2.5V6M3.5 10v2.5H6M10 12.5h2.5V10" })
6586
+ children: fullscreen?.isFullscreen ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M6 3.5H3.5V6M10 3.5h2.5V6M6 12.5H3.5V10M10 12.5h2.5V10" }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Icon, { path: "M3.5 6V3.5H6M10 3.5h2.5V6M3.5 10v2.5H6M10 12.5h2.5V10" })
6595
6587
  }
6596
6588
  ) : null
6597
6589
  ]
@@ -6608,7 +6600,7 @@ function PanoVideoControls({ appearance }) {
6608
6600
  }
6609
6601
 
6610
6602
  // src/video/pano-video-chrome-bridge.tsx
6611
- var import_jsx_runtime9 = require("react/jsx-runtime");
6603
+ var import_jsx_runtime8 = require("react/jsx-runtime");
6612
6604
  function PanoVideoChromeBridge({
6613
6605
  fullscreen,
6614
6606
  host,
@@ -6623,8 +6615,8 @@ function PanoVideoChromeBridge({
6623
6615
  return null;
6624
6616
  }
6625
6617
  const showDefaultControls = host.controller !== null && host.controls !== false && host.controlClaims === 0;
6626
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
6627
- showDefaultControls ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6618
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
6619
+ showDefaultControls ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
6628
6620
  PanoVideoControlsHud,
6629
6621
  {
6630
6622
  appearance: typeof host.controls === "object" ? host.controls : void 0,
@@ -6633,7 +6625,7 @@ function PanoVideoChromeBridge({
6633
6625
  overlayElement
6634
6626
  }
6635
6627
  ) : null,
6636
- host.captions !== false && host.controller ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(PanoVideoCaptionsOverlay, { controller: host.controller }) : null
6628
+ host.captions !== false && host.controller ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(PanoVideoCaptionsOverlay, { controller: host.controller }) : null
6637
6629
  ] });
6638
6630
  }
6639
6631
 
@@ -6786,7 +6778,7 @@ function clamp2(value, min, max) {
6786
6778
  }
6787
6779
 
6788
6780
  // src/webvr/chrome.tsx
6789
- var import_jsx_runtime10 = require("react/jsx-runtime");
6781
+ var import_jsx_runtime9 = require("react/jsx-runtime");
6790
6782
  function resolveAppearance(value) {
6791
6783
  return {
6792
6784
  ...DEFAULT_WEBVR_CHROME_APPEARANCE,
@@ -6798,7 +6790,7 @@ function ChromeButton2({
6798
6790
  children,
6799
6791
  onClick
6800
6792
  }) {
6801
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6793
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6802
6794
  "button",
6803
6795
  {
6804
6796
  className: "pano-webvr-button",
@@ -6835,7 +6827,7 @@ function SetupPanel({
6835
6827
  color: appearance.color,
6836
6828
  fontSize: appearance.fontSize
6837
6829
  };
6838
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
6830
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
6839
6831
  "div",
6840
6832
  {
6841
6833
  "aria-label": "Mobile VR setup",
@@ -6843,11 +6835,11 @@ function SetupPanel({
6843
6835
  role: "dialog",
6844
6836
  style: panelStyle,
6845
6837
  children: [
6846
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("h2", { className: "pano-webvr-setup-title", children: appearance.setupTitle ?? "MobileVR Setup" }),
6847
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("label", { className: "pano-webvr-setup-field", children: [
6838
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("h2", { className: "pano-webvr-setup-title", children: appearance.setupTitle ?? "MobileVR Setup" }),
6839
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("label", { className: "pano-webvr-setup-field", children: [
6848
6840
  "Screen size (inch)",
6849
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "pano-webvr-setup-row", children: [
6850
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6841
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "pano-webvr-setup-row", children: [
6842
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6851
6843
  "button",
6852
6844
  {
6853
6845
  "aria-label": "Decrease screen size",
@@ -6859,8 +6851,8 @@ function SetupPanel({
6859
6851
  children: "\u2039"
6860
6852
  }
6861
6853
  ),
6862
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("strong", { className: "pano-webvr-setup-value", children: settings.screensize === "auto" ? "Auto" : settings.screensize.toFixed(1) }),
6863
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6854
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("strong", { className: "pano-webvr-setup-value", children: settings.screensize === "auto" ? "Auto" : settings.screensize.toFixed(1) }),
6855
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6864
6856
  "button",
6865
6857
  {
6866
6858
  "aria-label": "Increase screen size",
@@ -6874,10 +6866,10 @@ function SetupPanel({
6874
6866
  )
6875
6867
  ] })
6876
6868
  ] }),
6877
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("fieldset", { className: "pano-webvr-setup-fieldset", children: [
6878
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("legend", { className: "pano-webvr-setup-legend", children: "VR headset preset" }),
6879
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "pano-webvr-setup-row", children: [
6880
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6869
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("fieldset", { className: "pano-webvr-setup-fieldset", children: [
6870
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("legend", { className: "pano-webvr-setup-legend", children: "VR headset preset" }),
6871
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "pano-webvr-setup-row", children: [
6872
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6881
6873
  "button",
6882
6874
  {
6883
6875
  "aria-label": "Previous headset preset",
@@ -6887,8 +6879,8 @@ function SetupPanel({
6887
6879
  children: "\u2039"
6888
6880
  }
6889
6881
  ),
6890
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("strong", { className: "pano-webvr-setup-value-wide", children: WEBVR_PROFILES[settings.profileId].label }),
6891
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6882
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("strong", { className: "pano-webvr-setup-value-wide", children: WEBVR_PROFILES[settings.profileId].label }),
6883
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6892
6884
  "button",
6893
6885
  {
6894
6886
  "aria-label": "Next headset preset",
@@ -6900,7 +6892,7 @@ function SetupPanel({
6900
6892
  )
6901
6893
  ] })
6902
6894
  ] }),
6903
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6895
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6904
6896
  ChromeButton2,
6905
6897
  {
6906
6898
  appearance,
@@ -6923,9 +6915,9 @@ function WebVRChromeBridge({ host }) {
6923
6915
  return null;
6924
6916
  }
6925
6917
  const appearance = resolveAppearance(chrome);
6926
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
6927
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "pano-webvr-toolbar", children: mode ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "pano-webvr-toolbar-actions", children: [
6928
- mode !== "webxr" ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6918
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
6919
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "pano-webvr-toolbar", children: mode ? /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "pano-webvr-toolbar-actions", children: [
6920
+ mode !== "webxr" ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6929
6921
  ChromeButton2,
6930
6922
  {
6931
6923
  appearance,
@@ -6933,7 +6925,7 @@ function WebVRChromeBridge({ host }) {
6933
6925
  children: "VR Setup"
6934
6926
  }
6935
6927
  ) : null,
6936
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6928
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6937
6929
  ChromeButton2,
6938
6930
  {
6939
6931
  appearance,
@@ -6941,7 +6933,7 @@ function WebVRChromeBridge({ host }) {
6941
6933
  children: "Exit VR"
6942
6934
  }
6943
6935
  )
6944
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6936
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6945
6937
  ChromeButton2,
6946
6938
  {
6947
6939
  appearance,
@@ -6949,7 +6941,7 @@ function WebVRChromeBridge({ host }) {
6949
6941
  children: available ? "Enter VR" : "VR unavailable"
6950
6942
  }
6951
6943
  ) }),
6952
- mode === "fake" ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6944
+ mode === "fake" ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6953
6945
  "p",
6954
6946
  {
6955
6947
  className: "pano-webvr-hint",
@@ -6957,7 +6949,7 @@ function WebVRChromeBridge({ host }) {
6957
6949
  children: "Simulated VR Mode \xB7 Click the view to lock the mouse, then move to look around. Use a headset or phone for real VR."
6958
6950
  }
6959
6951
  ) : null,
6960
- setupOpen ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
6952
+ setupOpen ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
6961
6953
  SetupPanel,
6962
6954
  {
6963
6955
  appearance,
@@ -6999,7 +6991,7 @@ var import_fiber9 = require("@react-three/fiber");
6999
6991
  var import_xr2 = require("@react-three/xr");
7000
6992
  var import_react25 = require("react");
7001
6993
  var import_three5 = require("three");
7002
- var import_jsx_runtime11 = require("react/jsx-runtime");
6994
+ var import_jsx_runtime10 = require("react/jsx-runtime");
7003
6995
  function PanoramaXROrigin() {
7004
6996
  const originRef = (0, import_react25.useRef)(null);
7005
6997
  const localHeadPositionRef = (0, import_react25.useRef)(new import_three5.Vector3());
@@ -7015,11 +7007,11 @@ function PanoramaXROrigin() {
7015
7007
  origin.position.copy(localHeadPositionRef.current).multiplyScalar(-1);
7016
7008
  origin.updateMatrixWorld();
7017
7009
  }, -100);
7018
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_xr2.XROrigin, { ref: originRef });
7010
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_xr2.XROrigin, { ref: originRef });
7019
7011
  }
7020
7012
 
7021
7013
  // src/pano-viewer.tsx
7022
- var import_jsx_runtime12 = require("react/jsx-runtime");
7014
+ var import_jsx_runtime11 = require("react/jsx-runtime");
7023
7015
  var DEFAULT_VIEW = {
7024
7016
  yaw: 0,
7025
7017
  pitch: 0,
@@ -7064,7 +7056,7 @@ function PanoCursorTree({
7064
7056
  if (!cursors) {
7065
7057
  return children;
7066
7058
  }
7067
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoCursorController, { cursors, children });
7059
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoCursorController, { cursors, children });
7068
7060
  }
7069
7061
  function PanoVideoHostReset() {
7070
7062
  const host = (0, import_react26.useContext)(PanoVideoHostContext);
@@ -7084,10 +7076,10 @@ function DefaultControlChannels({
7084
7076
  if (!claims) {
7085
7077
  return null;
7086
7078
  }
7087
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(DefaultControlChannelContext.Provider, { value: true, children: [
7088
- userControlsEnabled && mouseChannel.mount && claims.mouse === 0 ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(MouseControls, { ...mouseChannel.props, fovSpeed }) : null,
7089
- userControlsEnabled && touchChannel.mount && claims.touch === 0 ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(TouchControls, { ...touchChannel.props }) : null,
7090
- userControlsEnabled && keyboardChannel.mount && claims.keyboard === 0 ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7079
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(DefaultControlChannelContext.Provider, { value: true, children: [
7080
+ userControlsEnabled && mouseChannel.mount && claims.mouse === 0 ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(MouseControls, { ...mouseChannel.props, fovSpeed }) : null,
7081
+ userControlsEnabled && touchChannel.mount && claims.touch === 0 ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TouchControls, { ...touchChannel.props }) : null,
7082
+ userControlsEnabled && keyboardChannel.mount && claims.keyboard === 0 ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7091
7083
  KeyboardControls,
7092
7084
  {
7093
7085
  ...keyboardChannel.props,
@@ -7180,7 +7172,27 @@ var PanoViewer = (0, import_react26.forwardRef)(
7180
7172
  return resume;
7181
7173
  }, [mediaActivationControls, mediaActivationOptions]);
7182
7174
  const hasMediaActivationIntent = mediaActivationRevision >= 0 && hasPanoMediaActivationIntent(mediaActivationHost);
7183
- const shouldShowMediaActivation = mediaActivationOptions !== null && hasMediaActivationIntent && !mediaActivated;
7175
+ const shouldActivateMedia = mediaActivationOptions !== null && hasMediaActivationIntent && !mediaActivated;
7176
+ (0, import_react26.useEffect)(() => {
7177
+ if (!shouldActivateMedia) {
7178
+ return;
7179
+ }
7180
+ if (!needsMediaGesture()) {
7181
+ void activateMedia();
7182
+ return;
7183
+ }
7184
+ const handleGesture = () => {
7185
+ removeListeners();
7186
+ void activateMedia();
7187
+ };
7188
+ const removeListeners = () => {
7189
+ window.removeEventListener("pointerdown", handleGesture, true);
7190
+ window.removeEventListener("keydown", handleGesture, true);
7191
+ };
7192
+ window.addEventListener("pointerdown", handleGesture, { capture: true });
7193
+ window.addEventListener("keydown", handleGesture, { capture: true });
7194
+ return removeListeners;
7195
+ }, [activateMedia, shouldActivateMedia]);
7184
7196
  const fallbackViewRef = (0, import_react26.useRef)(DEFAULT_VIEW);
7185
7197
  const normalizedMinFov = Math.max(1, Math.min(minFov, maxFov - 1));
7186
7198
  const normalizedMaxFov = Math.min(
@@ -7433,7 +7445,7 @@ var PanoViewer = (0, import_react26.forwardRef)(
7433
7445
  }),
7434
7446
  [style]
7435
7447
  );
7436
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
7448
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
7437
7449
  "div",
7438
7450
  {
7439
7451
  ...divProps,
@@ -7443,7 +7455,7 @@ var PanoViewer = (0, import_react26.forwardRef)(
7443
7455
  "aria-label": ariaLabel,
7444
7456
  style: rootStyle,
7445
7457
  children: [
7446
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7458
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7447
7459
  import_fiber10.Canvas,
7448
7460
  {
7449
7461
  "aria-label": `${ariaLabel} canvas`,
@@ -7465,23 +7477,23 @@ var PanoViewer = (0, import_react26.forwardRef)(
7465
7477
  ...DEFAULT_CANVAS_STYLE,
7466
7478
  touchAction: userControlsEnabled ? "none" : "auto"
7467
7479
  },
7468
- children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_xr3.XR, { store: xrStore, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
7480
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_xr3.XR, { store: xrStore, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
7469
7481
  WebVRRuntimeContext.Provider,
7470
7482
  {
7471
7483
  value: { host: webVRHost, xrStore, stereoView },
7472
7484
  children: [
7473
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoramaXROrigin, {}),
7474
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(HotspotAccessibilityContext.Provider, { value: registry, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(HotspotTargetRegistryContext.Provider, { value: hotspotTargetRegistry, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoEventBusContext.Provider, { value: eventBus, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoCursorTree, { cursors: resolvedCursors, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoramaViewContext.Provider, { value: controlsRef, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7485
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoramaXROrigin, {}),
7486
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(HotspotAccessibilityContext.Provider, { value: registry, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(HotspotTargetRegistryContext.Provider, { value: hotspotTargetRegistry, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoEventBusContext.Provider, { value: eventBus, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoCursorTree, { cursors: resolvedCursors, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoramaViewContext.Provider, { value: controlsRef, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7475
7487
  PanoContextMenuOverlayContext.Provider,
7476
7488
  {
7477
7489
  value: contextMenuOverlayApi,
7478
- children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoChromeOverlayContext.Provider, { value: chromeOverlayApi, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoVideoHostContext.Provider, { value: videoHost, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoFilterHostContext.Provider, { value: filterHost, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7490
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoChromeOverlayContext.Provider, { value: chromeOverlayApi, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoVideoHostContext.Provider, { value: videoHost, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoFilterHostContext.Provider, { value: filterHost, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7479
7491
  PanoContextMenuActionsContext.Provider,
7480
7492
  {
7481
7493
  value: contextMenuActions,
7482
- children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ScenesHostContext.Provider, { value: scenesHost, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(BackgroundAudioHostContext.Provider, { value: bgmHost, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(PanoMediaActivationHostContext.Provider, { value: mediaActivationHost, children: [
7483
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoVideoHostReset, {}),
7484
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7494
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ScenesHostContext.Provider, { value: scenesHost, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(BackgroundAudioHostContext.Provider, { value: bgmHost, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(PanoMediaActivationHostContext.Provider, { value: mediaActivationHost, children: [
7495
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoVideoHostReset, {}),
7496
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7485
7497
  PanoramaViewRuntime,
7486
7498
  {
7487
7499
  ref: controlsRef,
@@ -7492,7 +7504,7 @@ var PanoViewer = (0, import_react26.forwardRef)(
7492
7504
  options: controlOptions
7493
7505
  }
7494
7506
  ),
7495
- (onViewChange || onPanoramaClick || onPanoramaDoubleClick || onPanoramaPointerMove) && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7507
+ (onViewChange || onPanoramaClick || onPanoramaDoubleClick || onPanoramaPointerMove) && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7496
7508
  PanoEvents,
7497
7509
  {
7498
7510
  onViewChange,
@@ -7501,18 +7513,18 @@ var PanoViewer = (0, import_react26.forwardRef)(
7501
7513
  onPointerMove: onPanoramaPointerMove
7502
7514
  }
7503
7515
  ),
7504
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7516
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7505
7517
  AutoRotate,
7506
7518
  {
7507
7519
  enabled: legacyAutoRotate,
7508
7520
  speed: legacyAutoRotateOptions.autoRotateSpeed
7509
7521
  }
7510
7522
  ),
7511
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoramaEventSurface, {}),
7512
- contextMenuChannel.mount ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(PanoContextMenu, { ...contextMenuChannel.props }) : null,
7513
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ControlClaimsContext.Provider, { value: controlClaims, children: [
7523
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoramaEventSurface, {}),
7524
+ contextMenuChannel.mount ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PanoContextMenu, { ...contextMenuChannel.props }) : null,
7525
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(ControlClaimsContext.Provider, { value: controlClaims, children: [
7514
7526
  children,
7515
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7527
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7516
7528
  DefaultControlChannels,
7517
7529
  {
7518
7530
  fovSpeed: controlOptions.fovSpeed,
@@ -7533,14 +7545,14 @@ var PanoViewer = (0, import_react26.forwardRef)(
7533
7545
  ) })
7534
7546
  }
7535
7547
  ),
7536
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
7548
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
7537
7549
  "div",
7538
7550
  {
7539
7551
  className: "pano-chrome-overlay",
7540
7552
  "data-pano-chrome-overlay": "",
7541
7553
  ref: setOverlayNode,
7542
7554
  children: [
7543
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7555
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
7544
7556
  PanoVideoChromeBridge,
7545
7557
  {
7546
7558
  fullscreen: contextMenuActions,
@@ -7548,21 +7560,12 @@ var PanoViewer = (0, import_react26.forwardRef)(
7548
7560
  overlayElement
7549
7561
  }
7550
7562
  ),
7551
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(WebVRChromeBridge, { host: webVRHost })
7563
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(WebVRChromeBridge, { host: webVRHost })
7552
7564
  ]
7553
7565
  }
7554
7566
  ),
7555
7567
  contextMenuOverlay,
7556
- hotspotAccessibilityControls,
7557
- shouldShowMediaActivation ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
7558
- PanoMediaActivationOverlay,
7559
- {
7560
- ...mediaActivationOptions,
7561
- onActivate: () => {
7562
- void activateMedia();
7563
- }
7564
- }
7565
- ) : null
7568
+ hotspotAccessibilityControls
7566
7569
  ]
7567
7570
  }
7568
7571
  );
@@ -8470,7 +8473,7 @@ async function detectWebVRCapabilities() {
8470
8473
  var import_fiber12 = require("@react-three/fiber");
8471
8474
  var import_react30 = require("react");
8472
8475
  var import_three8 = require("three");
8473
- var import_jsx_runtime13 = require("react/jsx-runtime");
8476
+ var import_jsx_runtime12 = require("react/jsx-runtime");
8474
8477
  var CENTER_NDC = new import_three8.Vector2(0, 0);
8475
8478
  var HUD_DISTANCE = 2;
8476
8479
  var RETICLE_SCALE = 1;
@@ -8630,7 +8633,7 @@ function WebVRReticle({
8630
8633
  group.quaternion.copy(activeCamera.quaternion);
8631
8634
  group.scale.setScalar(RETICLE_SCALE);
8632
8635
  });
8633
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
8636
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
8634
8637
  "group",
8635
8638
  {
8636
8639
  frustumCulled: false,
@@ -8638,15 +8641,15 @@ function WebVRReticle({
8638
8641
  renderOrder: RETICLE_RENDER_ORDER,
8639
8642
  visible,
8640
8643
  children: [
8641
- /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
8644
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
8642
8645
  "mesh",
8643
8646
  {
8644
8647
  frustumCulled: false,
8645
8648
  raycast: noopRaycast,
8646
8649
  renderOrder: RETICLE_RENDER_ORDER + 1,
8647
8650
  children: [
8648
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("boxGeometry", { args: [CROSSHAIR_LENGTH, CROSSHAIR_THICKNESS, 1e-3] }),
8649
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
8651
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("boxGeometry", { args: [CROSSHAIR_LENGTH, CROSSHAIR_THICKNESS, 1e-3] }),
8652
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
8650
8653
  "meshBasicMaterial",
8651
8654
  {
8652
8655
  color: "#ffffff",
@@ -8659,15 +8662,15 @@ function WebVRReticle({
8659
8662
  ]
8660
8663
  }
8661
8664
  ),
8662
- /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
8665
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
8663
8666
  "mesh",
8664
8667
  {
8665
8668
  frustumCulled: false,
8666
8669
  raycast: noopRaycast,
8667
8670
  renderOrder: RETICLE_RENDER_ORDER + 1,
8668
8671
  children: [
8669
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("boxGeometry", { args: [CROSSHAIR_THICKNESS, CROSSHAIR_LENGTH, 1e-3] }),
8670
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
8672
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("boxGeometry", { args: [CROSSHAIR_THICKNESS, CROSSHAIR_LENGTH, 1e-3] }),
8673
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
8671
8674
  "meshBasicMaterial",
8672
8675
  {
8673
8676
  color: "#ffffff",
@@ -8680,7 +8683,7 @@ function WebVRReticle({
8680
8683
  ]
8681
8684
  }
8682
8685
  ),
8683
- /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
8686
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
8684
8687
  "mesh",
8685
8688
  {
8686
8689
  frustumCulled: false,
@@ -8689,7 +8692,7 @@ function WebVRReticle({
8689
8692
  renderOrder: RETICLE_RENDER_ORDER + 2,
8690
8693
  visible: false,
8691
8694
  children: [
8692
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
8695
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
8693
8696
  "ringGeometry",
8694
8697
  {
8695
8698
  args: [
@@ -8702,7 +8705,7 @@ function WebVRReticle({
8702
8705
  ]
8703
8706
  }
8704
8707
  ),
8705
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
8708
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
8706
8709
  "meshBasicMaterial",
8707
8710
  {
8708
8711
  color: "#ffffff",
@@ -9143,7 +9146,7 @@ function useWebVRWakeLock(enabled) {
9143
9146
  }
9144
9147
 
9145
9148
  // src/webvr/webvr.tsx
9146
- var import_jsx_runtime14 = require("react/jsx-runtime");
9149
+ var import_jsx_runtime13 = require("react/jsx-runtime");
9147
9150
  function initializeSettings(screensize, profile) {
9148
9151
  const stored = loadWebVRSettings();
9149
9152
  return {
@@ -9476,8 +9479,8 @@ var WebVR = (0, import_react34.forwardRef)(function WebVR2({
9476
9479
  useWebVRWakeLock(
9477
9480
  wakelock && (mode === "mobilevr" || mode === "fake")
9478
9481
  );
9479
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(import_jsx_runtime14.Fragment, { children: [
9480
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
9482
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(import_jsx_runtime13.Fragment, { children: [
9483
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
9481
9484
  Gyro,
9482
9485
  {
9483
9486
  ref: gyroRef,
@@ -9491,7 +9494,7 @@ var WebVR = (0, import_react34.forwardRef)(function WebVR2({
9491
9494
  touchMode: "off"
9492
9495
  }
9493
9496
  ),
9494
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
9497
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
9495
9498
  WebVRStereoRenderer,
9496
9499
  {
9497
9500
  mode,
@@ -9499,7 +9502,7 @@ var WebVR = (0, import_react34.forwardRef)(function WebVR2({
9499
9502
  screensize: settings.screensize
9500
9503
  }
9501
9504
  ),
9502
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
9505
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
9503
9506
  WebVRReticle,
9504
9507
  {
9505
9508
  dwellMs: cursorDwellMs,
@@ -9775,7 +9778,7 @@ diffuseColor.rgb = mix(diffuseColor.rgb, applyPanoFilter(diffuseColor.rgb), clam
9775
9778
  }
9776
9779
 
9777
9780
  // src/pano-filter/pano-basic-material.tsx
9778
- var import_jsx_runtime15 = require("react/jsx-runtime");
9781
+ var import_jsx_runtime14 = require("react/jsx-runtime");
9779
9782
  function PanoBasicMaterial({
9780
9783
  map,
9781
9784
  side,
@@ -9822,7 +9825,7 @@ function PanoBasicMaterial({
9822
9825
  intensityUniformRef.current.value = snapshot.intensity;
9823
9826
  }
9824
9827
  }, [snapshot.intensity]);
9825
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
9828
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
9826
9829
  "meshBasicMaterial",
9827
9830
  {
9828
9831
  ref: materialRef,
@@ -9838,7 +9841,7 @@ function PanoBasicMaterial({
9838
9841
  }
9839
9842
 
9840
9843
  // src/sphere.tsx
9841
- var import_jsx_runtime16 = require("react/jsx-runtime");
9844
+ var import_jsx_runtime15 = require("react/jsx-runtime");
9842
9845
  function useEquirectTexture(url, anisotropy, generateMipmaps, onLoad, onError) {
9843
9846
  const [texture, setTexture] = (0, import_react37.useState)(null);
9844
9847
  const onLoadRef = (0, import_react37.useRef)(onLoad);
@@ -9937,14 +9940,14 @@ function Sphere({
9937
9940
  if (!displayTexture) {
9938
9941
  return null;
9939
9942
  }
9940
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
9943
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
9941
9944
  "mesh",
9942
9945
  {
9943
9946
  rotation: [0, import_three10.MathUtils.degToRad(90 + yawOffset), 0],
9944
9947
  visible,
9945
9948
  children: [
9946
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("sphereGeometry", { args: [DEFAULT_PANORAMA_RADIUS, 128, 64] }),
9947
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
9949
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("sphereGeometry", { args: [DEFAULT_PANORAMA_RADIUS, 128, 64] }),
9950
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
9948
9951
  PanoBasicMaterial,
9949
9952
  {
9950
9953
  map: displayTexture,
@@ -9961,7 +9964,7 @@ function Sphere({
9961
9964
  var import_fiber16 = require("@react-three/fiber");
9962
9965
  var import_react38 = require("react");
9963
9966
  var import_three11 = require("three");
9964
- var import_jsx_runtime17 = require("react/jsx-runtime");
9967
+ var import_jsx_runtime16 = require("react/jsx-runtime");
9965
9968
  var EMPTY_TRACKS = [];
9966
9969
  var EMPTY_RATES = DEFAULT_PANO_VIDEO_PLAYBACK_RATES;
9967
9970
  function createEmptySnapshot() {
@@ -10675,15 +10678,15 @@ function PanoVideo({
10675
10678
  if (variants.length === 0) {
10676
10679
  return null;
10677
10680
  }
10678
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(import_jsx_runtime17.Fragment, { children: [
10679
- activeTexture ? /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
10681
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, { children: [
10682
+ activeTexture ? /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
10680
10683
  "mesh",
10681
10684
  {
10682
10685
  rotation: [0, import_three11.MathUtils.degToRad(90 + yawOffset), 0],
10683
10686
  visible,
10684
10687
  children: [
10685
- /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("sphereGeometry", { args: [DEFAULT_PANORAMA_RADIUS, 128, 64] }),
10686
- /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
10688
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("sphereGeometry", { args: [DEFAULT_PANORAMA_RADIUS, 128, 64] }),
10689
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
10687
10690
  PanoBasicMaterial,
10688
10691
  {
10689
10692
  map: activeTexture,
@@ -10694,7 +10697,7 @@ function PanoVideo({
10694
10697
  ]
10695
10698
  }
10696
10699
  ) : null,
10697
- captionsEnabled ? /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(PanoVideoCaptions, { appearance: typeof captions === "object" ? captions : void 0 }) : null
10700
+ captionsEnabled ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(PanoVideoCaptions, { appearance: typeof captions === "object" ? captions : void 0 }) : null
10698
10701
  ] });
10699
10702
  }
10700
10703
 
@@ -10806,7 +10809,7 @@ function overlayProgress(elapsedTime, duration, startTime) {
10806
10809
  }
10807
10810
 
10808
10811
  // src/scene-transitions/particle-overlay.tsx
10809
- var import_jsx_runtime18 = require("react/jsx-runtime");
10812
+ var import_jsx_runtime17 = require("react/jsx-runtime");
10810
10813
  var PARTICLE_GRID = 48;
10811
10814
  var PARTICLE_COUNT = PARTICLE_GRID * PARTICLE_GRID;
10812
10815
  var PARTICLE_VERTEX_SHADER = `
@@ -10928,7 +10931,7 @@ function ParticleOverlay({
10928
10931
  onFinish();
10929
10932
  }
10930
10933
  });
10931
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
10934
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
10932
10935
  "mesh",
10933
10936
  {
10934
10937
  ref: meshRef,
@@ -11222,7 +11225,7 @@ function createSnapshotMaterial(preset, texture) {
11222
11225
  }
11223
11226
 
11224
11227
  // src/scene-transitions/snapshot-overlay.tsx
11225
- var import_jsx_runtime19 = require("react/jsx-runtime");
11228
+ var import_jsx_runtime18 = require("react/jsx-runtime");
11226
11229
  function SnapshotOverlay({
11227
11230
  snapshot,
11228
11231
  transition,
@@ -11271,21 +11274,21 @@ function SnapshotOverlay({
11271
11274
  if (!material) {
11272
11275
  return null;
11273
11276
  }
11274
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("mesh", { ref: meshRef, renderOrder: OVERLAY_RENDER_ORDER, frustumCulled: false, children: [
11275
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("primitive", { attach: "geometry", object: FULLSCREEN_PLANE }),
11276
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("primitive", { attach: "material", object: material })
11277
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("mesh", { ref: meshRef, renderOrder: OVERLAY_RENDER_ORDER, frustumCulled: false, children: [
11278
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("primitive", { attach: "geometry", object: FULLSCREEN_PLANE }),
11279
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("primitive", { attach: "material", object: material })
11277
11280
  ] });
11278
11281
  }
11279
11282
 
11280
11283
  // src/scene-transitions/transition-overlay.tsx
11281
- var import_jsx_runtime20 = require("react/jsx-runtime");
11284
+ var import_jsx_runtime19 = require("react/jsx-runtime");
11282
11285
  function TransitionOverlay(props) {
11283
11286
  const { preset } = props.transition;
11284
11287
  switch (preset) {
11285
11288
  case "none":
11286
11289
  return null;
11287
11290
  case "particles":
11288
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(ParticleOverlay, { ...props });
11291
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(ParticleOverlay, { ...props });
11289
11292
  case "crossfade":
11290
11293
  case "zoom":
11291
11294
  case "blackout":
@@ -11313,7 +11316,7 @@ function TransitionOverlay(props) {
11313
11316
  case "zoomBlur":
11314
11317
  case "hexDissolve":
11315
11318
  case "filmBurn":
11316
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(SnapshotOverlay, { ...props });
11319
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(SnapshotOverlay, { ...props });
11317
11320
  default: {
11318
11321
  const exhaustive = preset;
11319
11322
  void exhaustive;
@@ -11548,7 +11551,7 @@ var TileTextureManager = class {
11548
11551
  };
11549
11552
 
11550
11553
  // src/tile/texture-manager-context.tsx
11551
- var import_jsx_runtime21 = require("react/jsx-runtime");
11554
+ var import_jsx_runtime20 = require("react/jsx-runtime");
11552
11555
  var TileTextureManagerContext = (0, import_react41.createContext)(
11553
11556
  null
11554
11557
  );
@@ -11572,7 +11575,7 @@ function TileTextureManagerProvider({
11572
11575
  manager.resume();
11573
11576
  return () => manager.dispose();
11574
11577
  }, [manager]);
11575
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TileTextureManagerContext.Provider, { value: manager, children });
11578
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(TileTextureManagerContext.Provider, { value: manager, children });
11576
11579
  }
11577
11580
  function useSharedTileTextureManager() {
11578
11581
  return (0, import_react41.useContext)(TileTextureManagerContext);
@@ -11760,7 +11763,7 @@ function resolveTemplateUrl(template, address) {
11760
11763
  }
11761
11764
 
11762
11765
  // src/tile/tile.tsx
11763
- var import_jsx_runtime22 = require("react/jsx-runtime");
11766
+ var import_jsx_runtime21 = require("react/jsx-runtime");
11764
11767
  var MAX_LOD_UPDATE_INTERVAL_MS = 100;
11765
11768
  var FAST_ROTATION_THRESHOLD_RADIANS = Math.PI / 180;
11766
11769
  var FAST_FOV_THRESHOLD_DEGREES = 0.5;
@@ -11847,14 +11850,14 @@ function PreviewFace({
11847
11850
  [geometry]
11848
11851
  );
11849
11852
  const transform = getFaceTransform(face, PREVIEW_RADIUS);
11850
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
11853
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
11851
11854
  "mesh",
11852
11855
  {
11853
11856
  geometry,
11854
11857
  position: transform.position,
11855
11858
  renderOrder: -100,
11856
11859
  rotation: transform.rotation,
11857
- children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
11860
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
11858
11861
  PanoBasicMaterial,
11859
11862
  {
11860
11863
  depthTest: false,
@@ -11870,7 +11873,7 @@ function PreviewCube({
11870
11873
  texture,
11871
11874
  faceOrder
11872
11875
  }) {
11873
- return CUBE_FACES.map((face) => /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
11876
+ return CUBE_FACES.map((face) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
11874
11877
  PreviewFace,
11875
11878
  {
11876
11879
  face,
@@ -11915,14 +11918,14 @@ var TileMesh = (0, import_react42.memo)(function TileMesh2({
11915
11918
  if (!snapshot.texture) {
11916
11919
  return null;
11917
11920
  }
11918
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("group", { position: transform.position, rotation: transform.rotation, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
11921
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("group", { position: transform.position, rotation: transform.rotation, children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
11919
11922
  "mesh",
11920
11923
  {
11921
11924
  geometry: SHARED_TILE_GEOMETRY,
11922
11925
  position: [layout.x, layout.y, 0],
11923
11926
  renderOrder,
11924
11927
  scale: [layout.width, layout.height, 1],
11925
- children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
11928
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
11926
11929
  PanoBasicMaterial,
11927
11930
  {
11928
11931
  depthTest: false,
@@ -11939,7 +11942,7 @@ var TileLayerMeshes = (0, import_react42.memo)(function TileLayerMeshes2({
11939
11942
  manager,
11940
11943
  resolveUrl
11941
11944
  }) {
11942
- return layer.addresses.map((address) => /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
11945
+ return layer.addresses.map((address) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
11943
11946
  TileMesh,
11944
11947
  {
11945
11948
  address,
@@ -12276,15 +12279,15 @@ function Tile({
12276
12279
  };
12277
12280
  commitLayers(nextLayers);
12278
12281
  });
12279
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("group", { visible, children: [
12280
- previewTexture ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12282
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("group", { visible, children: [
12283
+ previewTexture ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
12281
12284
  PreviewCube,
12282
12285
  {
12283
12286
  texture: previewTexture,
12284
12287
  faceOrder: previewFaceOrder
12285
12288
  }
12286
12289
  ) : null,
12287
- layers.map((layer) => /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12290
+ layers.map((layer) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
12288
12291
  TileLayerMeshes,
12289
12292
  {
12290
12293
  layer,
@@ -12297,7 +12300,7 @@ function Tile({
12297
12300
  }
12298
12301
 
12299
12302
  // src/scenes.tsx
12300
- var import_jsx_runtime23 = require("react/jsx-runtime");
12303
+ var import_jsx_runtime22 = require("react/jsx-runtime");
12301
12304
  function SceneSource({
12302
12305
  scene,
12303
12306
  visible,
@@ -12310,7 +12313,7 @@ function SceneSource({
12310
12313
  }
12311
12314
  switch (scene.type) {
12312
12315
  case "sphere":
12313
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12316
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12314
12317
  Sphere,
12315
12318
  {
12316
12319
  src: scene.src,
@@ -12323,7 +12326,7 @@ function SceneSource({
12323
12326
  );
12324
12327
  case "tile": {
12325
12328
  const { id: _id, type: _type, ...tileProps } = scene;
12326
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12329
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12327
12330
  Tile,
12328
12331
  {
12329
12332
  ...tileProps,
@@ -12590,8 +12593,8 @@ function ScenesController({
12590
12593
  }, [gl, manager, releaseInteraction, snapshot]);
12591
12594
  const renderedScene = slots[liveSlot];
12592
12595
  const snapshotVisible = snapshot !== null && (phase === "transitioning" || phase === "recapturing" || phase === "preloading");
12593
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(import_react43.Fragment, { children: [
12594
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12596
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(import_react43.Fragment, { children: [
12597
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12595
12598
  SnapshotCapture,
12596
12599
  {
12597
12600
  requestId: captureRequestId,
@@ -12603,7 +12606,7 @@ function ScenesController({
12603
12606
  const source = slots[slot];
12604
12607
  const isLive = slot === liveSlot;
12605
12608
  const isPending = slot === pendingSlot;
12606
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12609
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12607
12610
  SceneSource,
12608
12611
  {
12609
12612
  scene: source,
@@ -12619,7 +12622,7 @@ function ScenesController({
12619
12622
  `${slot}:${source?.id ?? "empty"}:${recoveryKey}`
12620
12623
  );
12621
12624
  }),
12622
- snapshotVisible ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12625
+ snapshotVisible ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12623
12626
  TransitionOverlay,
12624
12627
  {
12625
12628
  snapshot,
@@ -12712,12 +12715,12 @@ function Scenes({
12712
12715
  }
12713
12716
  };
12714
12717
  }, [host, requestSceneChange]);
12715
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12718
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12716
12719
  TileTextureManagerProvider,
12717
12720
  {
12718
12721
  maxTextureMemoryMb,
12719
12722
  maxConcurrentLoads: maxConcurrentTileLoads,
12720
- children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12723
+ children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
12721
12724
  ScenesController,
12722
12725
  {
12723
12726
  ...rest,
@@ -12746,7 +12749,7 @@ var import_react45 = require("react");
12746
12749
  // src/webvr/stereo-html.tsx
12747
12750
  var import_drei = require("@react-three/drei");
12748
12751
  var import_react44 = require("react");
12749
- var import_jsx_runtime24 = require("react/jsx-runtime");
12752
+ var import_jsx_runtime23 = require("react/jsx-runtime");
12750
12753
  function useFallbackStereoView() {
12751
12754
  const runtime = (0, import_react44.useContext)(WebVRRuntimeContext);
12752
12755
  const host = runtime?.host ?? null;
@@ -12771,10 +12774,10 @@ function stereoCalculatePosition(eye, stereoView) {
12771
12774
  function PanoHtml({ children, ...htmlProps }) {
12772
12775
  const stereoView = useFallbackStereoView();
12773
12776
  if (!stereoView) {
12774
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_drei.Html, { ...htmlProps, children });
12777
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_drei.Html, { ...htmlProps, children });
12775
12778
  }
12776
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
12777
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12779
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(import_jsx_runtime23.Fragment, { children: [
12780
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12778
12781
  import_drei.Html,
12779
12782
  {
12780
12783
  ...htmlProps,
@@ -12782,7 +12785,7 @@ function PanoHtml({ children, ...htmlProps }) {
12782
12785
  children
12783
12786
  }
12784
12787
  ),
12785
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12788
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
12786
12789
  import_drei.Html,
12787
12790
  {
12788
12791
  ...htmlProps,
@@ -12795,7 +12798,7 @@ function PanoHtml({ children, ...htmlProps }) {
12795
12798
  }
12796
12799
 
12797
12800
  // src/hotspot/hotspot-tooltip.tsx
12798
- var import_jsx_runtime25 = require("react/jsx-runtime");
12801
+ var import_jsx_runtime24 = require("react/jsx-runtime");
12799
12802
  var DEFAULT_HOTSPOT_TOOLTIP_OFFSET = 12;
12800
12803
  var DEFAULT_HOTSPOT_TOOLTIP_APPEARANCE = {
12801
12804
  background: "rgba(22, 22, 22, 0.72)",
@@ -12892,14 +12895,14 @@ function HotspotTooltip({
12892
12895
  if (!showImage && !content.text) {
12893
12896
  return null;
12894
12897
  }
12895
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(PanoHtml, { pointerEvents: "none", style: WRAPPER_STYLE, zIndexRange: [20, 10], children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
12898
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(PanoHtml, { pointerEvents: "none", style: WRAPPER_STYLE, zIndexRange: [20, 10], children: /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
12896
12899
  "div",
12897
12900
  {
12898
12901
  className: "pano-hotspot-tooltip",
12899
12902
  role: "tooltip",
12900
12903
  style: bubbleStyle,
12901
12904
  children: [
12902
- showImage ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12905
+ showImage ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12903
12906
  "img",
12904
12907
  {
12905
12908
  alt: content.imageAlt ?? content.text ?? "",
@@ -12908,14 +12911,14 @@ function HotspotTooltip({
12908
12911
  src: content.image
12909
12912
  }
12910
12913
  ) : null,
12911
- content.text ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "pano-hotspot-tooltip-text", children: content.text }) : null
12914
+ content.text ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("p", { className: "pano-hotspot-tooltip-text", children: content.text }) : null
12912
12915
  ]
12913
12916
  }
12914
12917
  ) });
12915
12918
  }
12916
12919
 
12917
12920
  // src/hotspot/hotspot-anchor.tsx
12918
- var import_jsx_runtime26 = require("react/jsx-runtime");
12921
+ var import_jsx_runtime25 = require("react/jsx-runtime");
12919
12922
  var DEFAULT_FLOATING_DISTANCE = 10;
12920
12923
  var PANORAMA_RADIUS = DEFAULT_PANORAMA_RADIUS;
12921
12924
  var PANORAMA_SURFACE_INSET = 4;
@@ -13485,7 +13488,7 @@ function HotspotAnchor({
13485
13488
  setHovered(true);
13486
13489
  }
13487
13490
  };
13488
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
13491
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
13489
13492
  "group",
13490
13493
  {
13491
13494
  ref: groupRef,
@@ -13562,18 +13565,18 @@ function HotspotAnchor({
13562
13565
  } : void 0,
13563
13566
  onPointerUp: acceptsPointer ? (event) => releasePointer(event, true) : void 0,
13564
13567
  children: [
13565
- focused ? focusContent ?? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
13568
+ focused ? focusContent ?? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
13566
13569
  "lineSegments",
13567
13570
  {
13568
13571
  geometry: focusGeometry,
13569
13572
  position: [0, 0, 0.01],
13570
13573
  renderOrder: renderOrder + 1,
13571
13574
  scale: [1.12, 1.12, 1],
13572
- children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("lineBasicMaterial", { color: "#f5fbfc", depthTest: false })
13575
+ children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("lineBasicMaterial", { color: "#f5fbfc", depthTest: false })
13573
13576
  }
13574
13577
  ) : null,
13575
13578
  children,
13576
- tooltipOpen && tooltipContent ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("group", { ref: tooltipAnchorRef, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
13579
+ tooltipOpen && tooltipContent ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("group", { ref: tooltipAnchorRef, children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
13577
13580
  HotspotTooltip,
13578
13581
  {
13579
13582
  appearance: tooltipAppearance,
@@ -13589,7 +13592,7 @@ function HotspotAnchor({
13589
13592
 
13590
13593
  // src/hotspot/hotspot-plane.tsx
13591
13594
  var import_three21 = require("three");
13592
- var import_jsx_runtime27 = require("react/jsx-runtime");
13595
+ var import_jsx_runtime26 = require("react/jsx-runtime");
13593
13596
  var HOTSPOT_ALPHA_CUTOFF = 0.05;
13594
13597
  var SAMPLE_UV = new import_three21.Vector2();
13595
13598
  var RAYCAST_HITS = [];
@@ -13691,9 +13694,9 @@ function HotspotPlane({
13691
13694
  map,
13692
13695
  opacity
13693
13696
  }) {
13694
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("mesh", { raycast: hotspotPlaneRaycast, children: [
13695
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("planeGeometry", { args: [1, 1] }),
13696
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
13697
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("mesh", { raycast: hotspotPlaneRaycast, children: [
13698
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("planeGeometry", { args: [1, 1] }),
13699
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
13697
13700
  "meshBasicMaterial",
13698
13701
  {
13699
13702
  alphaTest: HOTSPOT_ALPHA_CUTOFF,
@@ -13709,7 +13712,7 @@ function HotspotPlane({
13709
13712
  }
13710
13713
 
13711
13714
  // src/hotspot/image-hotspot.tsx
13712
- var import_jsx_runtime28 = require("react/jsx-runtime");
13715
+ var import_jsx_runtime27 = require("react/jsx-runtime");
13713
13716
  function useHotspotImageTexture(src, onLoad, onError) {
13714
13717
  const gl = (0, import_fiber23.useThree)((state) => state.gl);
13715
13718
  const [texture, setTexture] = (0, import_react47.useState)(null);
@@ -13773,7 +13776,7 @@ function ImageHotspot({
13773
13776
  ...anchorProps
13774
13777
  }) {
13775
13778
  const texture = useHotspotImageTexture(src, onLoad, onError);
13776
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(HotspotAnchor, { ...anchorProps, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(HotspotPlane, { map: texture, opacity }) });
13779
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(HotspotAnchor, { ...anchorProps, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(HotspotPlane, { map: texture, opacity }) });
13777
13780
  }
13778
13781
 
13779
13782
  // src/hotspot/polygon-hotspot.tsx
@@ -13785,7 +13788,7 @@ var import_drei2 = require("@react-three/drei");
13785
13788
  var import_fiber24 = require("@react-three/fiber");
13786
13789
  var import_react48 = require("react");
13787
13790
  var import_three23 = require("three");
13788
- var import_jsx_runtime29 = require("react/jsx-runtime");
13791
+ var import_jsx_runtime28 = require("react/jsx-runtime");
13789
13792
  var LINE_WORLD_POSITION = new import_three23.Vector3();
13790
13793
  function applyScreenSpaceDashScale(object, camera, viewportHeight) {
13791
13794
  const material = object?.material;
@@ -13831,7 +13834,7 @@ function HotspotStrokeLine({
13831
13834
  }
13832
13835
  applyScreenSpaceDashScale(lineRef.current, state.camera, state.size.height);
13833
13836
  });
13834
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
13837
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
13835
13838
  import_drei2.Line,
13836
13839
  {
13837
13840
  ref: lineRef,
@@ -13853,7 +13856,7 @@ function HotspotStrokeLine({
13853
13856
  }
13854
13857
 
13855
13858
  // src/hotspot/polygon-hotspot.tsx
13856
- var import_jsx_runtime30 = require("react/jsx-runtime");
13859
+ var import_jsx_runtime29 = require("react/jsx-runtime");
13857
13860
  var POLYGON_RADIUS = 990;
13858
13861
  var MAX_FILL_SEGMENT_DEGREES = 7;
13859
13862
  function cloneVertices(vertices) {
@@ -14141,7 +14144,7 @@ function PolygonHotspot({
14141
14144
  startPosition: event.startPosition
14142
14145
  });
14143
14146
  };
14144
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
14147
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
14145
14148
  HotspotAnchor,
14146
14149
  {
14147
14150
  ...anchorProps,
@@ -14156,7 +14159,7 @@ function PolygonHotspot({
14156
14159
  draggable,
14157
14160
  interactive,
14158
14161
  useAngularScale: false,
14159
- focusContent: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
14162
+ focusContent: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
14160
14163
  HotspotStrokeLine,
14161
14164
  {
14162
14165
  color: "#75cbd3",
@@ -14178,7 +14181,7 @@ function PolygonHotspot({
14178
14181
  startVerticesRef.current = null;
14179
14182
  },
14180
14183
  children: [
14181
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("mesh", { geometry: fillGeometry, renderOrder, children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
14184
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("mesh", { geometry: fillGeometry, renderOrder, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
14182
14185
  "meshBasicMaterial",
14183
14186
  {
14184
14187
  color: fill,
@@ -14188,7 +14191,7 @@ function PolygonHotspot({
14188
14191
  transparent: true
14189
14192
  }
14190
14193
  ) }),
14191
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
14194
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
14192
14195
  HotspotStrokeLine,
14193
14196
  {
14194
14197
  color: stroke,
@@ -14208,7 +14211,7 @@ function PolygonHotspot({
14208
14211
  // src/hotspot/polyline-hotspot.tsx
14209
14212
  var import_react50 = require("react");
14210
14213
  var import_three25 = require("three");
14211
- var import_jsx_runtime31 = require("react/jsx-runtime");
14214
+ var import_jsx_runtime30 = require("react/jsx-runtime");
14212
14215
  var POLYLINE_RADIUS = 990;
14213
14216
  var MAX_SEGMENT_DEGREES = 7;
14214
14217
  function cloneVertices2(vertices) {
@@ -14348,7 +14351,7 @@ function PolylineHotspot({
14348
14351
  startPosition: event.startPosition
14349
14352
  });
14350
14353
  };
14351
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
14354
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
14352
14355
  HotspotAnchor,
14353
14356
  {
14354
14357
  ...anchorProps,
@@ -14362,7 +14365,7 @@ function PolylineHotspot({
14362
14365
  renderOrder,
14363
14366
  draggable,
14364
14367
  useAngularScale: false,
14365
- focusContent: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
14368
+ focusContent: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
14366
14369
  HotspotStrokeLine,
14367
14370
  {
14368
14371
  color: "#75cbd3",
@@ -14383,7 +14386,7 @@ function PolylineHotspot({
14383
14386
  emitVerticesChange(event, onDragEnd);
14384
14387
  startVerticesRef.current = null;
14385
14388
  },
14386
- children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
14389
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
14387
14390
  HotspotStrokeLine,
14388
14391
  {
14389
14392
  color: stroke,
@@ -14402,7 +14405,7 @@ function PolylineHotspot({
14402
14405
  // src/hotspot/graphic-hotspot.tsx
14403
14406
  var import_react51 = require("react");
14404
14407
  var import_three26 = require("three");
14405
- var import_jsx_runtime32 = require("react/jsx-runtime");
14408
+ var import_jsx_runtime31 = require("react/jsx-runtime");
14406
14409
  var GRAPHIC_TEXTURE_SIZE = 512;
14407
14410
  function resolveStrokeWidth(value) {
14408
14411
  return Number.isFinite(value) ? Math.max(value, 0) : 8;
@@ -14622,22 +14625,22 @@ function CanvasGraphicHotspot({
14622
14625
  ...anchorProps
14623
14626
  }) {
14624
14627
  const texture = useGraphicTexture(graphic, width, height, onLoad, onError);
14625
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(HotspotAnchor, { ...anchorProps, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(HotspotPlane, { map: texture, opacity }) });
14628
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(HotspotAnchor, { ...anchorProps, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(HotspotPlane, { map: texture, opacity }) });
14626
14629
  }
14627
14630
  function GraphicHotspot(props) {
14628
14631
  const { graphic, ...restProps } = props;
14629
14632
  if (graphic.kind === "svg") {
14630
14633
  const imageProps = restProps;
14631
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(ImageHotspot, { ...imageProps, src: graphic.src });
14634
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(ImageHotspot, { ...imageProps, src: graphic.src });
14632
14635
  }
14633
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(CanvasGraphicHotspot, { ...restProps, graphic });
14636
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(CanvasGraphicHotspot, { ...restProps, graphic });
14634
14637
  }
14635
14638
 
14636
14639
  // src/hotspot/sequence-hotspot.tsx
14637
14640
  var import_fiber25 = require("@react-three/fiber");
14638
14641
  var import_react52 = require("react");
14639
14642
  var import_three27 = require("three");
14640
- var import_jsx_runtime33 = require("react/jsx-runtime");
14643
+ var import_jsx_runtime32 = require("react/jsx-runtime");
14641
14644
  var DEFAULT_SEQUENCE_FPS = 12;
14642
14645
  function resolveFps(value) {
14643
14646
  return Number.isFinite(value) && value > 0 ? value : DEFAULT_SEQUENCE_FPS;
@@ -14813,14 +14816,14 @@ function SequenceHotspot({
14813
14816
  onFrameChangeRef.current?.({ id, index: nextIndex, src });
14814
14817
  }
14815
14818
  });
14816
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(HotspotAnchor, { ...anchorProps, id, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(HotspotPlane, { map: texture, opacity }) });
14819
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(HotspotAnchor, { ...anchorProps, id, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(HotspotPlane, { map: texture, opacity }) });
14817
14820
  }
14818
14821
 
14819
14822
  // src/hotspot/video-hotspot.tsx
14820
14823
  var import_fiber26 = require("@react-three/fiber");
14821
14824
  var import_react53 = require("react");
14822
14825
  var import_three28 = require("three");
14823
- var import_jsx_runtime34 = require("react/jsx-runtime");
14826
+ var import_jsx_runtime33 = require("react/jsx-runtime");
14824
14827
  function clampVolume2(volume) {
14825
14828
  if (!Number.isFinite(volume)) {
14826
14829
  return 1;
@@ -15045,14 +15048,14 @@ function VideoHotspot({
15045
15048
  };
15046
15049
  }, [playing, resource]);
15047
15050
  const activeTexture = resource?.ready ? resource.texture : posterTexture;
15048
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(HotspotAnchor, { ...anchorProps, id, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(HotspotPlane, { map: activeTexture, opacity }) });
15051
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(HotspotAnchor, { ...anchorProps, id, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(HotspotPlane, { map: activeTexture, opacity }) });
15049
15052
  }
15050
15053
 
15051
15054
  // src/hotspot/audio-hotspot.tsx
15052
15055
  var import_fiber27 = require("@react-three/fiber");
15053
15056
  var import_react54 = require("react");
15054
15057
  var import_three29 = require("three");
15055
- var import_jsx_runtime35 = require("react/jsx-runtime");
15058
+ var import_jsx_runtime34 = require("react/jsx-runtime");
15056
15059
  var SPEAKER_TEXTURE_SIZE = 512;
15057
15060
  function paintSpeakerBody(context, center) {
15058
15061
  context.fillStyle = "#f5fbfc";
@@ -15337,13 +15340,13 @@ function AudioHotspot({
15337
15340
  howl.mute(mutedRef.current);
15338
15341
  howl.volume(clampAudioVolume(volumeRef.current) * spatial.gain);
15339
15342
  });
15340
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(HotspotAnchor, { ...anchorProps, id, height, width, children: marker ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(HotspotPlane, { map: markerTexture, opacity }) : null });
15343
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(HotspotAnchor, { ...anchorProps, id, height, width, children: marker ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(HotspotPlane, { map: markerTexture, opacity }) : null });
15341
15344
  }
15342
15345
 
15343
15346
  // src/hotspot/text-hotspot.tsx
15344
15347
  var import_react55 = require("react");
15345
15348
  var import_three30 = require("three");
15346
- var import_jsx_runtime36 = require("react/jsx-runtime");
15349
+ var import_jsx_runtime35 = require("react/jsx-runtime");
15347
15350
  var TEXT_TEXTURE_LONG_SIDE = 1024;
15348
15351
  var DEFAULT_FONT_FAMILY = "system-ui, sans-serif";
15349
15352
  var DEFAULT_FONT_SIZE = 96;
@@ -15661,13 +15664,13 @@ function TextHotspot({
15661
15664
  whiteSpace
15662
15665
  };
15663
15666
  const texture = useTextTexture(text, width, height, style, onLoad, onError);
15664
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(HotspotAnchor, { ...anchorProps, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(HotspotPlane, { map: texture, opacity }) });
15667
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(HotspotAnchor, { ...anchorProps, height, width, children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(HotspotPlane, { map: texture, opacity }) });
15665
15668
  }
15666
15669
 
15667
15670
  // src/hotspot/iframe-hotspot.tsx
15668
15671
  var import_drei3 = require("@react-three/drei");
15669
15672
  var import_three31 = require("three");
15670
- var import_jsx_runtime37 = require("react/jsx-runtime");
15673
+ var import_jsx_runtime36 = require("react/jsx-runtime");
15671
15674
  var IFRAME_LONG_SIDE = 800;
15672
15675
  var CSS3D_DISTANCE_FACTOR = 400;
15673
15676
  var DEFAULT_SANDBOX = "allow-scripts allow-popups allow-forms";
@@ -15724,7 +15727,7 @@ function IframeHotspot({
15724
15727
  interactive,
15725
15728
  pointerEvents
15726
15729
  );
15727
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
15730
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
15728
15731
  HotspotAnchor,
15729
15732
  {
15730
15733
  ...anchorProps,
@@ -15733,9 +15736,9 @@ function IframeHotspot({
15733
15736
  pointerEvents,
15734
15737
  width,
15735
15738
  children: [
15736
- /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("mesh", { children: [
15737
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("planeGeometry", { args: [1, 1] }),
15738
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
15739
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("mesh", { children: [
15740
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("planeGeometry", { args: [1, 1] }),
15741
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
15739
15742
  "meshBasicMaterial",
15740
15743
  {
15741
15744
  depthWrite: false,
@@ -15746,7 +15749,7 @@ function IframeHotspot({
15746
15749
  }
15747
15750
  )
15748
15751
  ] }),
15749
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
15752
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
15750
15753
  import_drei3.Html,
15751
15754
  {
15752
15755
  distanceFactor: CSS3D_DISTANCE_FACTOR,
@@ -15761,7 +15764,7 @@ function IframeHotspot({
15761
15764
  },
15762
15765
  transform: true,
15763
15766
  zIndexRange: [10, 0],
15764
- children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
15767
+ children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
15765
15768
  "iframe",
15766
15769
  {
15767
15770
  allow,