@playcanvas/web-components 0.2.3 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/pwc.cjs CHANGED
@@ -3931,7 +3931,6 @@ class SoundSlotElement extends AsyncElement {
3931
3931
  }
3932
3932
  this.soundSlot = this.soundElement.component.addSlot(this._name, options);
3933
3933
  this.asset = this._asset;
3934
- this.soundSlot.play();
3935
3934
  this._onReady();
3936
3935
  }
3937
3936
  disconnectedCallback() {
@@ -4103,13 +4102,16 @@ class SoundSlotElement extends AsyncElement {
4103
4102
  return this._volume;
4104
4103
  }
4105
4104
  static get observedAttributes() {
4106
- return ['asset', 'autoPlay', 'duration', 'loop', 'name', 'overlap', 'pitch', 'startTime', 'volume'];
4105
+ return ['asset', 'auto-play', 'duration', 'loop', 'name', 'overlap', 'pitch', 'start-time', 'volume'];
4107
4106
  }
4108
4107
  attributeChangedCallback(name, _oldValue, newValue) {
4109
4108
  switch (name) {
4110
4109
  case 'asset':
4111
4110
  this.asset = newValue;
4112
4111
  break;
4112
+ case 'auto-play':
4113
+ this.autoPlay = this.hasAttribute('auto-play');
4114
+ break;
4113
4115
  case 'duration':
4114
4116
  this.duration = parseFloat(newValue);
4115
4117
  break;
@@ -4125,7 +4127,7 @@ class SoundSlotElement extends AsyncElement {
4125
4127
  case 'pitch':
4126
4128
  this.pitch = parseFloat(newValue);
4127
4129
  break;
4128
- case 'startTime':
4130
+ case 'start-time':
4129
4131
  this.startTime = parseFloat(newValue);
4130
4132
  break;
4131
4133
  case 'volume':
@@ -4523,6 +4525,7 @@ class SkyElement extends AsyncElement {
4523
4525
  this._scene.sky.node.setLocalScale(this._scale);
4524
4526
  this._scene.sky.center = this._center;
4525
4527
  this._scene.skyboxIntensity = this._intensity;
4528
+ this._scene.skyboxMip = this._level;
4526
4529
  }
4527
4530
  async _loadSkybox() {
4528
4531
  var _a;