shaka-video-element 0.6.11 → 0.6.12

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.
@@ -25817,6 +25817,21 @@ var Events = [
25817
25817
  "webkitendfullscreen",
25818
25818
  "webkitpresentationmodechanged"
25819
25819
  ];
25820
+ var Attributes = [
25821
+ "autopictureinpicture",
25822
+ "disablepictureinpicture",
25823
+ "disableremoteplayback",
25824
+ "autoplay",
25825
+ "controls",
25826
+ "controlslist",
25827
+ "crossorigin",
25828
+ "loop",
25829
+ "muted",
25830
+ "playsinline",
25831
+ "poster",
25832
+ "preload",
25833
+ "src"
25834
+ ];
25820
25835
  function getAudioTemplateHTML(attrs) {
25821
25836
  return (
25822
25837
  /*html*/
@@ -25884,19 +25899,7 @@ function CustomMediaMixin(superclass, { tag, is }) {
25884
25899
  const natAttrs = nativeElTest?.constructor?.observedAttributes ?? [];
25885
25900
  return [
25886
25901
  ...natAttrs,
25887
- "autopictureinpicture",
25888
- "disablepictureinpicture",
25889
- "disableremoteplayback",
25890
- "autoplay",
25891
- "controls",
25892
- "controlslist",
25893
- "crossorigin",
25894
- "loop",
25895
- "muted",
25896
- "playsinline",
25897
- "poster",
25898
- "preload",
25899
- "src"
25902
+ ...Attributes
25900
25903
  ];
25901
25904
  }
25902
25905
  static #define() {
@@ -26071,7 +26074,7 @@ function CustomMediaMixin(superclass, { tag, is }) {
26071
26074
  this.#init();
26072
26075
  this.#forwardAttribute(attrName, oldValue, newValue);
26073
26076
  }
26074
- #forwardAttribute(attrName, oldValue, newValue) {
26077
+ #forwardAttribute(attrName, _oldValue, newValue) {
26075
26078
  if (["id", "class"].includes(attrName)) return;
26076
26079
  if (!CustomMedia.observedAttributes.includes(attrName) && this.constructor.observedAttributes.includes(attrName)) {
26077
26080
  return;
@@ -26098,6 +26101,7 @@ function getNativeElProps(nativeElTest) {
26098
26101
  function serializeAttributes(attrs) {
26099
26102
  let html = "";
26100
26103
  for (const key in attrs) {
26104
+ if (!Attributes.includes(key)) continue;
26101
26105
  const value = attrs[key];
26102
26106
  if (value === "") html += ` ${key}`;
26103
26107
  else html += ` ${key}="${value}"`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shaka-video-element",
3
- "version": "0.6.11",
3
+ "version": "0.6.12",
4
4
  "description": "Custom element (web component) for Shaka Player",
5
5
  "author": "@muxinc",
6
6
  "license": "MIT",
@@ -52,7 +52,7 @@
52
52
  "build": "run-s build:*"
53
53
  },
54
54
  "dependencies": {
55
- "custom-media-element": "^1.4.1",
55
+ "custom-media-element": "^1.4.2",
56
56
  "shaka-player": "~4.8.4"
57
57
  },
58
58
  "devDependencies": {