const plyr_icons = $('.post-data').attr('data-icon');
"object" == typeof navigator &&
  (function (e, t) {
    "object" == typeof exports && "undefined" != typeof module
      ? (module.exports = t())
      : "function" == typeof define && define.amd
        ? define("Plyr", t)
        : ((e = e || self).Plyr = t());
  })(this, function () {
    "use strict";
    function e(e, t) {
      if (!(e instanceof t))
        throw new TypeError("Cannot call a class as a function");
    }
    function t(e, t) {
      for (var i = 0; i < t.length; i++) {
        var n = t[i];
        (n.enumerable = n.enumerable || !1),
          (n.configurable = !0),
          "value" in n && (n.writable = !0),
          Object.defineProperty(e, n.key, n);
      }
    }
    function i(e, i, n) {
      return i && t(e.prototype, i), n && t(e, n), e;
    }
    function n(e, t, i) {
      return (
        t in e
          ? Object.defineProperty(e, t, {
            value: i,
            enumerable: !0,
            configurable: !0,
            writable: !0,
          })
          : (e[t] = i),
        e
      );
    }
    function a(e, t) {
      var i = Object.keys(e);
      if (Object.getOwnPropertySymbols) {
        var n = Object.getOwnPropertySymbols(e);
        t &&
          (n = n.filter(function (t) {
            return Object.getOwnPropertyDescriptor(e, t).enumerable;
          })),
          i.push.apply(i, n);
      }
      return i;
    }
    function s(e) {
      for (var t = 1; t < arguments.length; t++) {
        var i = null != arguments[t] ? arguments[t] : {};
        t % 2
          ? a(Object(i), !0).forEach(function (t) {
            n(e, t, i[t]);
          })
          : Object.getOwnPropertyDescriptors
            ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(i))
            : a(Object(i)).forEach(function (t) {
              Object.defineProperty(
                e,
                t,
                Object.getOwnPropertyDescriptor(i, t)
              );
            });
      }
      return e;
    }
    function r(e, t) {
      if (null == e) return {};
      var i,
        n,
        a = (function (e, t) {
          if (null == e) return {};
          var i,
            n,
            a = {},
            s = Object.keys(e);
          for (n = 0; n < s.length; n++)
            (i = s[n]), t.indexOf(i) >= 0 || (a[i] = e[i]);
          return a;
        })(e, t);
      if (Object.getOwnPropertySymbols) {
        var s = Object.getOwnPropertySymbols(e);
        for (n = 0; n < s.length; n++)
          (i = s[n]),
            t.indexOf(i) >= 0 ||
            (Object.prototype.propertyIsEnumerable.call(e, i) &&
              (a[i] = e[i]));
      }
      return a;
    }
    function o(e, t) {
      return (
        (function (e) {
          if (Array.isArray(e)) return e;
        })(e) ||
        (function (e, t) {
          if ("undefined" == typeof Symbol || !(Symbol.iterator in Object(e)))
            return;
          var i = [],
            n = !0,
            a = !1,
            s = void 0;
          try {
            for (
              var r, o = e[Symbol.iterator]();
              !(n = (r = o.next()).done) &&
              (i.push(r.value), !t || i.length !== t);
              n = !0
            );
          } catch (e) {
            (a = !0), (s = e);
          } finally {
            try {
              n || null == o.return || o.return();
            } finally {
              if (a) throw s;
            }
          }
          return i;
        })(e, t) ||
        c(e, t) ||
        (function () {
          throw new TypeError(
            "Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."
          );
        })()
      );
    }
    function l(e) {
      return (
        (function (e) {
          if (Array.isArray(e)) return u(e);
        })(e) ||
        (function (e) {
          if ("undefined" != typeof Symbol && Symbol.iterator in Object(e))
            return Array.from(e);
        })(e) ||
        c(e) ||
        (function () {
          throw new TypeError(
            "Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."
          );
        })()
      );
    }
    function c(e, t) {
      if (e) {
        if ("string" == typeof e) return u(e, t);
        var i = Object.prototype.toString.call(e).slice(8, -1);
        return (
          "Object" === i && e.constructor && (i = e.constructor.name),
          "Map" === i || "Set" === i
            ? Array.from(i)
            : "Arguments" === i ||
              /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)
              ? u(e, t)
              : void 0
        );
      }
    }
    function u(e, t) {
      (null == t || t > e.length) && (t = e.length);
      for (var i = 0, n = new Array(t); i < t; i++) n[i] = e[i];
      return n;
    }
    function d(e, t) {
      for (var i = 0; i < t.length; i++) {
        var n = t[i];
        (n.enumerable = n.enumerable || !1),
          (n.configurable = !0),
          "value" in n && (n.writable = !0),
          Object.defineProperty(e, n.key, n);
      }
    }
    function h(e, t, i) {
      return (
        t in e
          ? Object.defineProperty(e, t, {
            value: i,
            enumerable: !0,
            configurable: !0,
            writable: !0,
          })
          : (e[t] = i),
        e
      );
    }
    function p(e, t) {
      var i = Object.keys(e);
      if (Object.getOwnPropertySymbols) {
        var n = Object.getOwnPropertySymbols(e);
        t &&
          (n = n.filter(function (t) {
            return Object.getOwnPropertyDescriptor(e, t).enumerable;
          })),
          i.push.apply(i, n);
      }
      return i;
    }
    function m(e) {
      for (var t = 1; t < arguments.length; t++) {
        var i = null != arguments[t] ? arguments[t] : {};
        t % 2
          ? p(Object(i), !0).forEach(function (t) {
            h(e, t, i[t]);
          })
          : Object.getOwnPropertyDescriptors
            ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(i))
            : p(Object(i)).forEach(function (t) {
              Object.defineProperty(
                e,
                t,
                Object.getOwnPropertyDescriptor(i, t)
              );
            });
      }
      return e;
    }
    var f = { addCSS: !0, thumbWidth: 15, watch: !0 };
    function g(e, t) {
      return function () {
        return Array.from(document.querySelectorAll(t)).includes(this);
      }.call(e, t);
    }
    var y = function (e) {
      return null != e ? e.constructor : null;
    },
      v = function (e, t) {
        return !!(e && t && e instanceof t);
      },
      b = function (e) {
        return null == e;
      },
      w = function (e) {
        return y(e) === Object;
      },
      k = function (e) {
        return y(e) === String;
      },
      T = function (e) {
        return Array.isArray(e);
      },
      C = function (e) {
        return v(e, NodeList);
      },
      A = k,
      S = T,
      P = C,
      E = function (e) {
        return v(e, Element);
      },
      M = function (e) {
        return v(e, Event);
      },
      N = function (e) {
        return (
          b(e) ||
          ((k(e) || T(e) || C(e)) && !e.length) ||
          (w(e) && !Object.keys(e).length)
        );
      };
    function x(e, t) {
      if (1 > t) {
        var i = (function (e) {
          var t = "".concat(e).match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);
          return t
            ? Math.max(0, (t[1] ? t[1].length : 0) - (t[2] ? +t[2] : 0))
            : 0;
        })(t);
        return parseFloat(e.toFixed(i));
      }
      return Math.round(e / t) * t;
    }
    var I,
      L,
      O,
      _ = (function () {
        function e(t, i) {
          (function (e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          })(this, e),
            E(t)
              ? (this.element = t)
              : A(t) && (this.element = document.querySelector(t)),
            E(this.element) &&
            N(this.element.rangeTouch) &&
            ((this.config = m({}, f, {}, i)), this.init());
        }
        return (
          (function (e, t, i) {
            t && d(e.prototype, t), i && d(e, i);
          })(
            e,
            [
              {
                key: "init",
                value: function () {
                  e.enabled &&
                    (this.config.addCSS &&
                      ((this.element.style.userSelect = "none"),
                        (this.element.style.webKitUserSelect = "none"),
                        (this.element.style.touchAction = "manipulation")),
                      this.listeners(!0),
                      (this.element.rangeTouch = this));
                },
              },
              {
                key: "destroy",
                value: function () {
                  e.enabled &&
                    (this.config.addCSS &&
                      ((this.element.style.userSelect = ""),
                        (this.element.style.webKitUserSelect = ""),
                        (this.element.style.touchAction = "")),
                      this.listeners(!1),
                      (this.element.rangeTouch = null));
                },
              },
              {
                key: "listeners",
                value: function (e) {
                  var t = this,
                    i = e ? "addEventListener" : "removeEventListener";
                  ["touchstart", "touchmove", "touchend"].forEach(function (e) {
                    t.element[i](
                      e,
                      function (e) {
                        return t.set(e);
                      },
                      !1
                    );
                  });
                },
              },
              {
                key: "get",
                value: function (t) {
                  if (!e.enabled || !M(t)) return null;
                  var i,
                    n = t.target,
                    a = t.changedTouches[0],
                    s = parseFloat(n.getAttribute("min")) || 0,
                    r = parseFloat(n.getAttribute("max")) || 100,
                    o = parseFloat(n.getAttribute("step")) || 1,
                    l = n.getBoundingClientRect(),
                    c = ((100 / l.width) * (this.config.thumbWidth / 2)) / 100;
                  return (
                    0 > (i = (100 / l.width) * (a.clientX - l.left))
                      ? (i = 0)
                      : 100 < i && (i = 100),
                    50 > i
                      ? (i -= (100 - 2 * i) * c)
                      : 50 < i && (i += 2 * (i - 50) * c),
                    s + x((i / 100) * (r - s), o)
                  );
                },
              },
              {
                key: "set",
                value: function (t) {
                  e.enabled &&
                    M(t) &&
                    !t.target.disabled &&
                    (t.preventDefault(),
                      (t.target.value = this.get(t)),
                      (function (e, t) {
                        if (e && t) {
                          var i = new Event(t, { bubbles: !0 });
                          e.dispatchEvent(i);
                        }
                      })(t.target, "touchend" === t.type ? "change" : "input"));
                },
              },
            ],
            [
              {
                key: "setup",
                value: function (t) {
                  var i =
                    1 < arguments.length && void 0 !== arguments[1]
                      ? arguments[1]
                      : {},
                    n = null;
                  if (
                    (N(t) || A(t)
                      ? (n = Array.from(
                        document.querySelectorAll(
                          A(t) ? t : 'input[type="range"]'
                        )
                      ))
                      : E(t)
                        ? (n = [t])
                        : P(t)
                          ? (n = Array.from(t))
                          : S(t) && (n = t.filter(E)),
                      N(n))
                  )
                    return null;
                  var a = m({}, f, {}, i);
                  if (A(t) && a.watch) {
                    var s = new MutationObserver(function (i) {
                      Array.from(i).forEach(function (i) {
                        Array.from(i.addedNodes).forEach(function (i) {
                          E(i) && g(i, t) && new e(i, a);
                        });
                      });
                    });
                    s.observe(document.body, { childList: !0, subtree: !0 });
                  }
                  return n.map(function (t) {
                    return new e(t, i);
                  });
                },
              },
              {
                key: "enabled",
                get: function () {
                  return "ontouchstart" in document.documentElement;
                },
              },
            ]
          ),
          e
        );
      })(),
      j = function (e) {
        return null != e ? e.constructor : null;
      },
      q = function (e, t) {
        return Boolean(e && t && e instanceof t);
      },
      D = function (e) {
        return null == e;
      },
      H = function (e) {
        return j(e) === Object;
      },
      F = function (e) {
        return j(e) === String;
      },
      R = function (e) {
        return j(e) === Function;
      },
      V = function (e) {
        return Array.isArray(e);
      },
      B = function (e) {
        return q(e, NodeList);
      },
      U = function (e) {
        return (
          D(e) ||
          ((F(e) || V(e) || B(e)) && !e.length) ||
          (H(e) && !Object.keys(e).length)
        );
      },
      W = D,
      z = H,
      K = function (e) {
        return j(e) === Number && !Number.isNaN(e);
      },
      Y = F,
      Q = function (e) {
        return j(e) === Boolean;
      },
      X = R,
      $ = V,
      J = B,
      G = function (e) {
        return q(e, Element);
      },
      Z = function (e) {
        return q(e, Event);
      },
      ee = function (e) {
        return q(e, KeyboardEvent);
      },
      te = function (e) {
        return q(e, TextTrack) || (!D(e) && F(e.kind));
      },
      ie = function (e) {
        return q(e, Promise) && R(e.then);
      },
      ne = function (e) {
        if (q(e, window.URL)) return !0;
        if (!F(e)) return !1;
        var t = e;
        (e.startsWith("http://") && e.startsWith("https://")) ||
          (t = "http://".concat(e));
        try {
          return !U(new URL(t).hostname);
        } catch (e) {
          return !1;
        }
      },
      ae = U,
      se =
        ((I = document.createElement("span")),
          (L = {
            WebkitTransition: "webkitTransitionEnd",
            MozTransition: "transitionend",
            OTransition: "oTransitionEnd otransitionend",
            transition: "transitionend",
          }),
          (O = Object.keys(L).find(function (e) {
            return void 0 !== I.style[e];
          })),
          !!Y(O) && L[O]);
    function re(e, t) {
      setTimeout(function () {
        try {
          (e.hidden = !0), e.offsetHeight, (e.hidden = !1);
        } catch (e) { }
      }, t);
    }
    var oe = {
      isIE:
        /* @cc_on!@ */
        !!document.documentMode,
      isEdge: window.navigator.userAgent.includes("Edge"),
      isWebkit:
        "WebkitAppearance" in document.documentElement.style &&
        !/Edge/.test(navigator.userAgent),
      isIPhone: /(iPhone|iPod)/gi.test(navigator.platform),
      isIos: /(iPad|iPhone|iPod)/gi.test(navigator.platform),
    };
    function le(e, t) {
      return t.split(".").reduce(function (e, t) {
        return e && e[t];
      }, e);
    }
    function ce() {
      for (
        var e =
          arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {},
        t = arguments.length,
        i = new Array(t > 1 ? t - 1 : 0),
        a = 1;
        a < t;
        a++
      )
        i[a - 1] = arguments[a];
      if (!i.length) return e;
      var s = i.shift();
      return z(s)
        ? (Object.keys(s).forEach(function (t) {
          z(s[t])
            ? (Object.keys(e).includes(t) || Object.assign(e, n({}, t, {})),
              ce(e[t], s[t]))
            : Object.assign(e, n({}, t, s[t]));
        }),
          ce.apply(void 0, [e].concat(i)))
        : e;
    }
    function ue(e, t) {
      var i = e.length ? e : [e];
      Array.from(i)
        .reverse()
        .forEach(function (e, i) {
          var n = i > 0 ? t.cloneNode(!0) : t,
            a = e.parentNode,
            s = e.nextSibling;
          n.appendChild(e), s ? a.insertBefore(n, s) : a.appendChild(n);
        });
    }
    function de(e, t) {
      G(e) &&
        !ae(t) &&
        Object.entries(t)
          .filter(function (e) {
            var t = o(e, 2)[1];
            return !W(t);
          })
          .forEach(function (t) {
            var i = o(t, 2),
              n = i[0],
              a = i[1];
            return e.setAttribute(n, a);
          });
    }
    function he(e, t, i) {
      var n = document.createElement(e);
      return z(t) && de(n, t), Y(i) && (n.innerText = i), n;
    }
    function pe(e, t, i, n) {
      G(t) && t.appendChild(he(e, i, n));
    }
    function me(e) {
      J(e) || $(e)
        ? Array.from(e).forEach(me)
        : G(e) && G(e.parentNode) && e.parentNode.removeChild(e);
    }
    function fe(e) {
      if (G(e))
        for (var t = e.childNodes.length; t > 0;)
          e.removeChild(e.lastChild), (t -= 1);
    }
    function ge(e, t) {
      return G(t) && G(t.parentNode) && G(e)
        ? (t.parentNode.replaceChild(e, t), e)
        : null;
    }
    function ye(e, t) {
      if (!Y(e) || ae(e)) return {};
      var i = {},
        n = ce({}, t);
      return (
        e.split(",").forEach(function (e) {
          var t = e.trim(),
            a = t.replace(".", ""),
            s = t.replace(/[[\]]/g, "").split("="),
            r = o(s, 1)[0],
            l = s.length > 1 ? s[1].replace(/["']/g, "") : "";
          switch (t.charAt(0)) {
            case ".":
              Y(n.class)
                ? (i.class = "".concat(n.class, " ").concat(a))
                : (i.class = a);
              break;
            case "#":
              i.id = t.replace("#", "");
              break;
            case "[":
              i[r] = l;
          }
        }),
        ce(n, i)
      );
    }
    function ve(e, t) {
      if (G(e)) {
        var i = t;
        Q(i) || (i = !e.hidden), (e.hidden = i);
      }
    }
    function be(e, t, i) {
      if (J(e))
        return Array.from(e).map(function (e) {
          return be(e, t, i);
        });
      if (G(e)) {
        var n = "toggle";
        return (
          void 0 !== i && (n = i ? "add" : "remove"),
          e.classList[n](t),
          e.classList.contains(t)
        );
      }
      return !1;
    }
    function we(e, t) {
      return G(e) && e.classList.contains(t);
    }
    function ke(e, t) {
      var i = Element.prototype;
      return (
        i.matches ||
        i.webkitMatchesSelector ||
        i.mozMatchesSelector ||
        i.msMatchesSelector ||
        function () {
          return Array.from(document.querySelectorAll(t)).includes(this);
        }
      ).call(e, t);
    }
    function Te(e) {
      return this.elements.container.querySelectorAll(e);
    }
    function Ce(e) {
      return this.elements.container.querySelector(e);
    }
    function Ae() {
      var e =
        arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : null,
        t = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
      G(e) &&
        (e.focus({ preventScroll: !0 }),
          t && be(e, this.config.classNames.tabFocus));
    }
    var Se,
      Pe = {
        "audio/ogg": "vorbis",
        "audio/wav": "1",
        "video/webm": "vp8, vorbis",
        "video/mp4": "avc1.42E01E, mp4a.40.2",
        "video/ogg": "theora",
      },
      Ee = {
        audio: "canPlayType" in document.createElement("audio"),
        video: "canPlayType" in document.createElement("video"),
        check: function (e, t, i) {
          var n = oe.isIPhone && i && Ee.playsinline,
            a = Ee[e] || "html5" !== t;
          return {
            api: a,
            ui: a && Ee.rangeInput && ("video" !== e || !oe.isIPhone || n),
          };
        },
        pip: !(
          oe.isIPhone ||
          (!X(he("video").webkitSetPresentationMode) &&
            (!document.pictureInPictureEnabled ||
              he("video").disablePictureInPicture))
        ),
        airplay: X(window.WebKitPlaybackTargetAvailabilityEvent),
        playsinline: "playsInline" in document.createElement("video"),
        mime: function (e) {
          if (ae(e)) return !1;
          var t = o(e.split("/"), 1)[0],
            i = e;
          if (!this.isHTML5 || t !== this.type) return !1;
          Object.keys(Pe).includes(i) && (i += '; codecs="'.concat(Pe[e], '"'));
          try {
            return Boolean(i && this.media.canPlayType(i).replace(/no/, ""));
          } catch (e) {
            return !1;
          }
        },
        textTracks: "textTracks" in document.createElement("video"),
        rangeInput:
          ((Se = document.createElement("input")),
            (Se.type = "range"),
            "range" === Se.type),
        touch: "ontouchstart" in document.documentElement,
        transitions: !1 !== se,
        reducedMotion:
          "matchMedia" in window &&
          window.matchMedia("(prefers-reduced-motion)").matches,
      },
      Me = (function () {
        var e = !1;
        try {
          var t = Object.defineProperty({}, "passive", {
            get: function () {
              return (e = !0), null;
            },
          });
          window.addEventListener("test", null, t),
            window.removeEventListener("test", null, t);
        } catch (e) { }
        return e;
      })();
    function Ne(e, t, i) {
      var n = this,
        a = arguments.length > 3 && void 0 !== arguments[3] && arguments[3],
        s = !(arguments.length > 4 && void 0 !== arguments[4]) || arguments[4],
        r = arguments.length > 5 && void 0 !== arguments[5] && arguments[5];
      if (e && "addEventListener" in e && !ae(t) && X(i)) {
        var o = t.split(" "),
          l = r;
        Me && (l = { passive: s, capture: r }),
          o.forEach(function (t) {
            n &&
              n.eventListeners &&
              a &&
              n.eventListeners.push({
                element: e,
                type: t,
                callback: i,
                options: l,
              }),
              e[a ? "addEventListener" : "removeEventListener"](t, i, l);
          });
      }
    }
    function xe(e) {
      var t =
        arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "",
        i = arguments.length > 2 ? arguments[2] : void 0,
        n = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3],
        a = arguments.length > 4 && void 0 !== arguments[4] && arguments[4];
      Ne.call(this, e, t, i, !0, n, a);
    }
    function Ie(e) {
      var t =
        arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "",
        i = arguments.length > 2 ? arguments[2] : void 0,
        n = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3],
        a = arguments.length > 4 && void 0 !== arguments[4] && arguments[4];
      Ne.call(this, e, t, i, !1, n, a);
    }
    function Le(e) {
      var t = this,
        i = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "",
        n = arguments.length > 2 ? arguments[2] : void 0,
        a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3],
        s = arguments.length > 4 && void 0 !== arguments[4] && arguments[4],
        r = function r() {
          Ie(e, i, r, a, s);
          for (var o = arguments.length, l = new Array(o), c = 0; c < o; c++)
            l[c] = arguments[c];
          n.apply(t, l);
        };
      Ne.call(this, e, i, r, !0, a, s);
    }
    function Oe(e) {
      var t =
        arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "",
        i = arguments.length > 2 && void 0 !== arguments[2] && arguments[2],
        n = arguments.length > 3 && void 0 !== arguments[3] ? arguments[3] : {};
      if (G(e) && !ae(t)) {
        var a = new CustomEvent(t, {
          bubbles: i,
          detail: s({}, n, { plyr: this }),
        });
        e.dispatchEvent(a);
      }
    }
    function _e() {
      this &&
        this.eventListeners &&
        (this.eventListeners.forEach(function (e) {
          var t = e.element,
            i = e.type,
            n = e.callback,
            a = e.options;
          t.removeEventListener(i, n, a);
        }),
          (this.eventListeners = []));
    }
    function je() {
      var e = this;
      return new Promise(function (t) {
        return e.ready
          ? setTimeout(t, 0)
          : xe.call(e, e.elements.container, "ready", t);
      }).then(function () { });
    }
    function qe(e) {
      ie(e) && e.then(null, function () { });
    }
    function De(e) {
      return (
        !!($(e) || (Y(e) && e.includes(":"))) &&
        ($(e) ? e : e.split(":")).map(Number).every(K)
      );
    }
    function He(e) {
      if (!$(e) || !e.every(K)) return null;
      var t = o(e, 2),
        i = t[0],
        n = t[1],
        a = (function e(t, i) {
          return 0 === i ? t : e(i, t % i);
        })(i, n);
      return [i / a, n / a];
    }
    function Fe(e) {
      var t = function (e) {
        return De(e) ? e.split(":").map(Number) : null;
      },
        i = t(e);
      if (
        (null === i && (i = t(this.config.ratio)),
          null === i &&
          !ae(this.embed) &&
          $(this.embed.ratio) &&
          (i = this.embed.ratio),
          null === i && this.isHTML5)
      ) {
        var n = this.media;
        i = He([n.videoWidth, n.videoHeight]);
      }
      return i;
    }
    function Re(e) {
      if (!this.isVideo) return {};
      var t = this.elements.wrapper,
        i = Fe.call(this, e),
        n = o($(i) ? i : [0, 0], 2),
        a = (100 / n[0]) * n[1];
      if (
        ((t.style.paddingBottom = "".concat(a, "%")),
          this.isVimeo && !this.config.vimeo.premium && this.supported.ui)
      ) {
        var s =
          (100 / this.media.offsetWidth) *
          parseInt(window.getComputedStyle(this.media).paddingBottom, 10),
          r = (s - a) / (s / 50);
        this.media.style.transform = "translateY(-".concat(r, "%)");
      } else this.isHTML5 && t.classList.toggle(this.config.classNames.videoFixedRatio, null !== i);
      return { padding: a, ratio: i };
    }
    var Ve = {
      getSources: function () {
        var e = this;
        return this.isHTML5
          ? Array.from(this.media.querySelectorAll("source")).filter(function (
            t
          ) {
            var i = t.getAttribute("type");
            return !!ae(i) || Ee.mime.call(e, i);
          })
          : [];
      },
      getQualityOptions: function () {
        return this.config.quality.forced
          ? this.config.quality.options
          : Ve.getSources
            .call(this)
            .map(function (e) {
              return Number(e.getAttribute("size"));
            })
            .filter(Boolean);
      },
      setup: function () {
        if (this.isHTML5) {
          var e = this;
          (e.options.speed = e.config.speed.options),
            ae(this.config.ratio) || Re.call(e),
            Object.defineProperty(e.media, "quality", {
              get: function () {
                var t = Ve.getSources.call(e).find(function (t) {
                  return t.getAttribute("src") === e.source;
                });
                return t && Number(t.getAttribute("size"));
              },
              set: function (t) {
                if (e.quality !== t) {
                  if (e.config.quality.forced && X(e.config.quality.onChange))
                    e.config.quality.onChange(t);
                  else {
                    var i = Ve.getSources.call(e).find(function (e) {
                      return Number(e.getAttribute("size")) === t;
                    });
                    if (!i) return;
                    var n = e.media,
                      a = n.currentTime,
                      s = n.paused,
                      r = n.preload,
                      o = n.readyState,
                      l = n.playbackRate;
                    (e.media.src = i.getAttribute("src")),
                      ("none" !== r || o) &&
                      (e.once("loadedmetadata", function () {
                        (e.speed = l), (e.currentTime = a), s || qe(e.play());
                      }),
                        e.media.load());
                  }
                  Oe.call(e, e.media, "qualitychange", !1, { quality: t });
                }
              },
            });
        }
      },
      cancelRequests: function () {
        this.isHTML5 &&
          (me(Ve.getSources.call(this)),
            this.media.setAttribute("src", this.config.blankVideo),
            this.media.load(),
            this.debug.log("Cancelled network requests"));
      },
    };
    function Be(e) {
      return $(e)
        ? e.filter(function (t, i) {
          return e.indexOf(t) === i;
        })
        : e;
    }
    function Ue(e) {
      for (
        var t = arguments.length, i = new Array(t > 1 ? t - 1 : 0), n = 1;
        n < t;
        n++
      )
        i[n - 1] = arguments[n];
      return ae(e)
        ? e
        : e.toString().replace(/{(\d+)}/g, function (e, t) {
          return i[t].toString();
        });
    }
    var We = function () {
      var e =
        arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "",
        t =
          arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "",
        i =
          arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : "";
      return e.replace(
        new RegExp(
          t.toString().replace(/([.*+?^=!:${}()|[\]/\\])/g, "\\$1"),
          "g"
        ),
        i.toString()
      );
    },
      ze = function () {
        var e =
          arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "";
        return e.toString().replace(/\w\S*/g, function (e) {
          return e.charAt(0).toUpperCase() + e.substr(1).toLowerCase();
        });
      };
    function Ke() {
      var e =
        arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "",
        t = e.toString();
      return (
        (t = We(t, "-", " ")),
        (t = We(t, "_", " ")),
        (t = ze(t)),
        We(t, " ", "")
      );
    }
    function Ye(e) {
      var t = document.createElement("div");
      return t.appendChild(e), t.innerHTML;
    }
    var Qe = {
      pip: "PIP",
      airplay: "AirPlay",
      html5: "HTML5",
      vimeo: "Vimeo",
      youtube: "YouTube",
    },
      Xe = function () {
        var e =
          arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "",
          t =
            arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {};
        if (ae(e) || ae(t)) return "";
        var i = le(t.i18n, e);
        if (ae(i)) return Object.keys(Qe).includes(e) ? Qe[e] : "";
        var n = { "{seektime}": t.seekTime, "{title}": t.title };
        return (
          Object.entries(n).forEach(function (e) {
            var t = o(e, 2),
              n = t[0],
              a = t[1];
            i = We(i, n, a);
          }),
          i
        );
      },
      $e = (function () {
        function t(i) {
          e(this, t),
            (this.enabled = i.config.storage.enabled),
            (this.key = i.config.storage.key);
        }
        return (
          i(
            t,
            [
              {
                key: "get",
                value: function (e) {
                  if (!t.supported || !this.enabled) return null;
                  var i = window.localStorage.getItem(this.key);
                  if (ae(i)) return null;
                  var n = JSON.parse(i);
                  return Y(e) && e.length ? n[e] : n;
                },
              },
              {
                key: "set",
                value: function (e) {
                  if (t.supported && this.enabled && z(e)) {
                    var i = this.get();
                    ae(i) && (i = {}),
                      ce(i, e),
                      window.localStorage.setItem(this.key, JSON.stringify(i));
                  }
                },
              },
            ],
            [
              {
                key: "supported",
                get: function () {
                  try {
                    if (!("localStorage" in window)) return !1;
                    return (
                      window.localStorage.setItem("___test", "___test"),
                      window.localStorage.removeItem("___test"),
                      !0
                    );
                  } catch (e) {
                    return !1;
                  }
                },
              },
            ]
          ),
          t
        );
      })();
    function Je(e) {
      var t =
        arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "text";
      return new Promise(function (i, n) {
        try {
          var a = new XMLHttpRequest();
          if (!("withCredentials" in a)) return;
          a.addEventListener("load", function () {
            if ("text" === t)
              try {
                i(JSON.parse(a.responseText));
              } catch (e) {
                i(a.responseText);
              }
            else i(a.response);
          }),
            a.addEventListener("error", function () {
              throw new Error(a.status);
            }),
            a.open("GET", e, !0),
            (a.responseType = t),
            a.send();
        } catch (e) {
          n(e);
        }
      });
    }
    function Ge(e, t) {
      if (Y(e)) {
        var i = Y(t),
          n = function () {
            return null !== document.getElementById(t);
          },
          a = function (e, t) {
            (e.innerHTML = t),
              (i && n()) ||
              document.body.insertAdjacentElement("afterbegin", e);
          };
        if (!i || !n()) {
          var s = $e.supported,
            r = document.createElement("div");
          if ((r.setAttribute("hidden", ""), i && r.setAttribute("id", t), s)) {
            var o = window.localStorage.getItem(
              "".concat("cache", "-").concat(t)
            );
            if (null !== o) {
              var l = JSON.parse(o);
              a(r, l.content);
            }
          }
          Je(e)
            .then(function (e) {
              ae(e) ||
                (s &&
                  window.localStorage.setItem(
                    "".concat("cache", "-").concat(t),
                    JSON.stringify({ content: e })
                  ),
                  a(r, e));
            })
            .catch(function () { });
        }
      }
    }
    var Ze = function (e) {
      return Math.trunc((e / 60 / 60) % 60, 10);
    },
      et = function (e) {
        return Math.trunc((e / 60) % 60, 10);
      },
      tt = function (e) {
        return Math.trunc(e % 60, 10);
      };
    function it() {
      var e =
        arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : 0,
        t = arguments.length > 1 && void 0 !== arguments[1] && arguments[1],
        i = arguments.length > 2 && void 0 !== arguments[2] && arguments[2];
      if (!K(e)) return it(void 0, t, i);
      var n = function (e) {
        return "0".concat(e).slice(-2);
      },
        a = Ze(e),
        s = et(e),
        r = tt(e);
      return (
        (a = t || a > 0 ? "".concat(a, ":") : ""),
        ""
          .concat(i && e > 0 ? "-" : "")
          .concat(a)
          .concat(n(s), ":")
          .concat(n(r))
      );
    }
    var nt = {
      getIconUrl: function () {
        var e =
          new URL(this.config.iconUrl, window.location).host !==
          window.location.host ||
          (oe.isIE && !window.svg4everybody);
        return { url: this.config.iconUrl, cors: e };
      },
      findElements: function () {
        try {
          return (
            (this.elements.controls = Ce.call(
              this,
              this.config.selectors.controls.wrapper
            )),
            (this.elements.buttons = {
              play: Te.call(this, this.config.selectors.buttons.play),
              pause: Ce.call(this, this.config.selectors.buttons.pause),
              restart: Ce.call(this, this.config.selectors.buttons.restart),
              rewind: Ce.call(this, this.config.selectors.buttons.rewind),
              fastForward: Ce.call(
                this,
                this.config.selectors.buttons.fastForward
              ),
              mute: Ce.call(this, this.config.selectors.buttons.mute),
              pip: Ce.call(this, this.config.selectors.buttons.pip),
              airplay: Ce.call(this, this.config.selectors.buttons.airplay),
              settings: Ce.call(this, this.config.selectors.buttons.settings),
              captions: Ce.call(this, this.config.selectors.buttons.captions),
              fullscreen: Ce.call(
                this,
                this.config.selectors.buttons.fullscreen
              ),
            }),
            (this.elements.progress = Ce.call(
              this,
              this.config.selectors.progress
            )),
            (this.elements.inputs = {
              seek: Ce.call(this, this.config.selectors.inputs.seek),
              volume: Ce.call(this, this.config.selectors.inputs.volume),
            }),
            (this.elements.display = {
              buffer: Ce.call(this, this.config.selectors.display.buffer),
              currentTime: Ce.call(
                this,
                this.config.selectors.display.currentTime
              ),
              duration: Ce.call(this, this.config.selectors.display.duration),
            }),
            G(this.elements.progress) &&
            (this.elements.display.seekTooltip =
              this.elements.progress.querySelector(
                ".".concat(this.config.classNames.tooltip)
              )),
            !0
          );
        } catch (e) {
          return (
            this.debug.warn(
              "It looks like there is a problem with your custom controls HTML",
              e
            ),
            this.toggleNativeControls(!0),
            !1
          );
        }
      },
      createIcon: function (e, t) {
        var i = nt.getIconUrl.call(this),
          n = ""
            .concat(i.cors ? "" : i.url, "#")
            .concat(this.config.iconPrefix),
          a = document.createElementNS("http://www.w3.org/2000/svg", "svg");
        de(a, ce(t, { "aria-hidden": "true", focusable: "false" }));
        var s = document.createElementNS("http://www.w3.org/2000/svg", "use"),
          r = "".concat(n, "-").concat(e);
        return (
          "href" in s &&
          s.setAttributeNS("http://www.w3.org/1999/xlink", "href", r),
          s.setAttributeNS("http://www.w3.org/1999/xlink", "xlink:href", r),
          a.appendChild(s),
          a
        );
      },
      createLabel: function (e) {
        var t =
          arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {},
          i = Xe(e, this.config),
          n = s({}, t, {
            class: [t.class, this.config.classNames.hidden]
              .filter(Boolean)
              .join(" "),
          });
        return he("span", n, i);
      },
      createBadge: function (e) {
        if (ae(e)) return null;
        var t = he("span", { class: this.config.classNames.menu.value });
        return (
          t.appendChild(
            he("span", { class: this.config.classNames.menu.badge }, e)
          ),
          t
        );
      },
      createButton: function (e, t) {
        var i = this,
          n = ce({}, t),
          a = (function () {
            var e =
              arguments.length > 0 && void 0 !== arguments[0]
                ? arguments[0]
                : "",
              t = e.toString();
            return (t = Ke(t)).charAt(0).toLowerCase() + t.slice(1);
          })(e),
          s = {
            element: "button",
            toggle: !1,
            label: null,
            icon: null,
            labelPressed: null,
            iconPressed: null,
          };
        switch (
        (["element", "icon", "label"].forEach(function (e) {
          Object.keys(n).includes(e) && ((s[e] = n[e]), delete n[e]);
        }),
          "button" !== s.element ||
          Object.keys(n).includes("type") ||
          (n.type = "button"),
          Object.keys(n).includes("class")
            ? n.class.split(" ").some(function (e) {
              return e === i.config.classNames.control;
            }) ||
            ce(n, {
              class: ""
                .concat(n.class, " ")
                .concat(this.config.classNames.control),
            })
            : (n.class = this.config.classNames.control),
          e)
        ) {
          case "play":
            (s.toggle = !0),
              (s.label = "play"),
              (s.labelPressed = "pause"),
              (s.icon = "play"),
              (s.iconPressed = "pause");
            break;
          case "mute":
            (s.toggle = !0),
              (s.label = "mute"),
              (s.labelPressed = "unmute"),
              (s.icon = "volume"),
              (s.iconPressed = "muted");
            break;
          case "captions":
            (s.toggle = !0),
              (s.label = "enableCaptions"),
              (s.labelPressed = "disableCaptions"),
              (s.icon = "captions-off"),
              (s.iconPressed = "captions-on");
            break;
          case "fullscreen":
            (s.toggle = !0),
              (s.label = "enterFullscreen"),
              (s.labelPressed = "exitFullscreen"),
              (s.icon = "enter-fullscreen"),
              (s.iconPressed = "exit-fullscreen");
            break;
          case "play-large":
            (n.class += " ".concat(
              this.config.classNames.control,
              "--overlaid"
            )),
              (a = "play"),
              (s.label = "play"),
              (s.icon = "play");
            break;
          default:
            ae(s.label) && (s.label = a), ae(s.icon) && (s.icon = e);
        }
        var r = he(s.element);
        return (
          s.toggle
            ? (r.appendChild(
              nt.createIcon.call(this, s.iconPressed, {
                class: "icon--pressed",
              })
            ),
              r.appendChild(
                nt.createIcon.call(this, s.icon, { class: "icon--not-pressed" })
              ),
              r.appendChild(
                nt.createLabel.call(this, s.labelPressed, {
                  class: "label--pressed",
                })
              ),
              r.appendChild(
                nt.createLabel.call(this, s.label, {
                  class: "label--not-pressed",
                })
              ))
            : (r.appendChild(nt.createIcon.call(this, s.icon)),
              r.appendChild(nt.createLabel.call(this, s.label))),
          ce(n, ye(this.config.selectors.buttons[a], n)),
          de(r, n),
          "play" === a
            ? ($(this.elements.buttons[a]) || (this.elements.buttons[a] = []),
              this.elements.buttons[a].push(r))
            : (this.elements.buttons[a] = r),
          r
        );
      },
      createRange: function (e, t) {
        var i = he(
          "input",
          ce(
            ye(this.config.selectors.inputs[e]),
            {
              type: "range",
              min: 0,
              max: 100,
              step: 0.01,
              value: 0,
              autocomplete: "off",
              role: "slider",
              "aria-label": Xe(e, this.config),
              "aria-valuemin": 0,
              "aria-valuemax": 100,
              "aria-valuenow": 0,
            },
            t
          )
        );
        return (
          (this.elements.inputs[e] = i),
          nt.updateRangeFill.call(this, i),
          _.setup(i),
          i
        );
      },
      createProgress: function (e, t) {
        var i = he(
          "progress",
          ce(
            ye(this.config.selectors.display[e]),
            {
              min: 0,
              max: 100,
              value: 0,
              role: "progressbar",
              "aria-hidden": !0,
            },
            t
          )
        );
        if ("volume" !== e) {
          i.appendChild(he("span", null, "0"));
          var n = { played: "played", buffer: "buffered" }[e],
            a = n ? Xe(n, this.config) : "";
          i.innerText = "% ".concat(a.toLowerCase());
        }
        return (this.elements.display[e] = i), i;
      },
      createTime: function (e, t) {
        var i = ye(this.config.selectors.display[e], t),
          n = he(
            "div",
            ce(i, {
              class: ""
                .concat(i.class ? i.class : "", " ")
                .concat(this.config.classNames.display.time, " ")
                .trim(),
              "aria-label": Xe(e, this.config),
            }),
            "00:00"
          );
        return (this.elements.display[e] = n), n;
      },
      bindMenuItemShortcuts: function (e, t) {
        var i = this;
        xe.call(
          this,
          e,
          "keydown keyup",
          function (n) {
            if (
              [32, 38, 39, 40].includes(n.which) &&
              (n.preventDefault(), n.stopPropagation(), "keydown" !== n.type)
            ) {
              var a,
                s = ke(e, '[role="menuitemradio"]');
              if (!s && [32, 39].includes(n.which))
                nt.showMenuPanel.call(i, t, !0);
              else
                32 !== n.which &&
                  (40 === n.which || (s && 39 === n.which)
                    ? ((a = e.nextElementSibling),
                      G(a) || (a = e.parentNode.firstElementChild))
                    : ((a = e.previousElementSibling),
                      G(a) || (a = e.parentNode.lastElementChild)),
                    Ae.call(i, a, !0));
            }
          },
          !1
        ),
          xe.call(this, e, "keyup", function (e) {
            13 === e.which && nt.focusFirstMenuItem.call(i, null, !0);
          });
      },
      createMenuItem: function (e) {
        var t = this,
          i = e.value,
          n = e.list,
          a = e.type,
          s = e.title,
          r = e.badge,
          o = void 0 === r ? null : r,
          l = e.checked,
          c = void 0 !== l && l,
          u = ye(this.config.selectors.inputs[a]),
          d = he(
            "button",
            ce(u, {
              type: "button",
              role: "menuitemradio",
              class: ""
                .concat(this.config.classNames.control, " ")
                .concat(u.class ? u.class : "")
                .trim(),
              "aria-checked": c,
              value: i,
            })
          ),
          h = he("span");
        (h.innerHTML = s),
          G(o) && h.appendChild(o),
          d.appendChild(h),
          Object.defineProperty(d, "checked", {
            enumerable: !0,
            get: function () {
              return "true" === d.getAttribute("aria-checked");
            },
            set: function (e) {
              e &&
                Array.from(d.parentNode.children)
                  .filter(function (e) {
                    return ke(e, '[role="menuitemradio"]');
                  })
                  .forEach(function (e) {
                    return e.setAttribute("aria-checked", "false");
                  }),
                d.setAttribute("aria-checked", e ? "true" : "false");
            },
          }),
          this.listeners.bind(
            d,
            "click keyup",
            function (e) {
              if (!ee(e) || 32 === e.which) {
                switch (
                (e.preventDefault(), e.stopPropagation(), (d.checked = !0), a)
                ) {
                  case "language":
                    t.currentTrack = Number(i);
                    break;
                  case "quality":
                    t.quality = i;
                    break;
                  case "speed":
                    t.speed = parseFloat(i);
                }
                nt.showMenuPanel.call(t, "home", ee(e));
              }
            },
            a,
            !1
          ),
          nt.bindMenuItemShortcuts.call(this, d, a),
          n.appendChild(d);
      },
      formatTime: function () {
        var e =
          arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : 0,
          t = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
        if (!K(e)) return e;
        var i = Ze(this.duration) > 0;
        return it(e, i, t);
      },
      updateTimeDisplay: function () {
        var e =
          arguments.length > 0 && void 0 !== arguments[0]
            ? arguments[0]
            : null,
          t =
            arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 0,
          i = arguments.length > 2 && void 0 !== arguments[2] && arguments[2];
        G(e) && K(t) && (e.innerText = nt.formatTime(t, i));
      },
      updateVolume: function () {
        this.supported.ui &&
          (G(this.elements.inputs.volume) &&
            nt.setRange.call(
              this,
              this.elements.inputs.volume,
              this.muted ? 0 : this.volume
            ),
            G(this.elements.buttons.mute) &&
            (this.elements.buttons.mute.pressed =
              this.muted || 0 === this.volume));
      },
      setRange: function (e) {
        var t =
          arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 0;
        G(e) && ((e.value = t), nt.updateRangeFill.call(this, e));
      },
      updateProgress: function (e) {
        var t = this;
        if (this.supported.ui && Z(e)) {
          var i,
            n,
            a = 0;
          if (e)
            switch (e.type) {
              case "timeupdate":
              case "seeking":
              case "seeked":
                (i = this.currentTime),
                  (n = this.duration),
                  (a =
                    0 === i || 0 === n || Number.isNaN(i) || Number.isNaN(n)
                      ? 0
                      : ((i / n) * 100).toFixed(2)),
                  "timeupdate" === e.type &&
                  nt.setRange.call(this, this.elements.inputs.seek, a);
                break;
              case "playing":
              case "progress":
                !(function (e, i) {
                  var n = K(i) ? i : 0,
                    a = G(e) ? e : t.elements.display.buffer;
                  if (G(a)) {
                    a.value = n;
                    var s = a.getElementsByTagName("span")[0];
                    G(s) && (s.childNodes[0].nodeValue = n);
                  }
                })(this.elements.display.buffer, 100 * this.buffered);
            }
        }
      },
      updateRangeFill: function (e) {
        var t = Z(e) ? e.target : e;
        if (G(t) && "range" === t.getAttribute("type")) {
          if (ke(t, this.config.selectors.inputs.seek)) {
            t.setAttribute("aria-valuenow", this.currentTime);
            var i = nt.formatTime(this.currentTime),
              n = nt.formatTime(this.duration),
              a = Xe("seekLabel", this.config);
            t.setAttribute(
              "aria-valuetext",
              a.replace("{currentTime}", i).replace("{duration}", n)
            );
          } else if (ke(t, this.config.selectors.inputs.volume)) {
            var s = 100 * t.value;
            t.setAttribute("aria-valuenow", s),
              t.setAttribute("aria-valuetext", "".concat(s.toFixed(1), "%"));
          } else t.setAttribute("aria-valuenow", t.value);
          oe.isWebkit &&
            t.style.setProperty(
              "--value",
              "".concat((t.value / t.max) * 100, "%")
            );
        }
      },
      updateSeekTooltip: function (e) {
        var t = this;
        if (
          this.config.tooltips.seek &&
          G(this.elements.inputs.seek) &&
          G(this.elements.display.seekTooltip) &&
          0 !== this.duration
        ) {
          var i = "".concat(this.config.classNames.tooltip, "--visible"),
            n = function (e) {
              return be(t.elements.display.seekTooltip, i, e);
            };
          if (this.touch) n(!1);
          else {
            var a = 0,
              s = this.elements.progress.getBoundingClientRect();
            if (Z(e)) a = (100 / s.width) * (e.pageX - s.left);
            else {
              if (!we(this.elements.display.seekTooltip, i)) return;
              a = parseFloat(this.elements.display.seekTooltip.style.left, 10);
            }
            a < 0 ? (a = 0) : a > 100 && (a = 100),
              nt.updateTimeDisplay.call(
                this,
                this.elements.display.seekTooltip,
                (this.duration / 100) * a
              ),
              (this.elements.display.seekTooltip.style.left = "".concat(
                a,
                "%"
              )),
              Z(e) &&
              ["mouseenter", "mouseleave"].includes(e.type) &&
              n("mouseenter" === e.type);
          }
        }
      },
      timeUpdate: function (e) {
        var t = !G(this.elements.display.duration) && this.config.invertTime;
        nt.updateTimeDisplay.call(
          this,
          this.elements.display.currentTime,
          t ? this.duration - this.currentTime : this.currentTime,
          t
        ),
          (e && "timeupdate" === e.type && this.media.seeking) ||
          nt.updateProgress.call(this, e);
      },
      durationUpdate: function () {
        if (
          this.supported.ui &&
          (this.config.invertTime || !this.currentTime)
        ) {
          if (this.duration >= Math.pow(2, 32))
            return (
              ve(this.elements.display.currentTime, !0),
              void ve(this.elements.progress, !0)
            );
          G(this.elements.inputs.seek) &&
            this.elements.inputs.seek.setAttribute(
              "aria-valuemax",
              this.duration
            );
          var e = G(this.elements.display.duration);
          !e &&
            this.config.displayDuration &&
            this.paused &&
            nt.updateTimeDisplay.call(
              this,
              this.elements.display.currentTime,
              this.duration
            ),
            e &&
            nt.updateTimeDisplay.call(
              this,
              this.elements.display.duration,
              this.duration
            ),
            nt.updateSeekTooltip.call(this);
        }
      },
      toggleMenuButton: function (e, t) {
        ve(this.elements.settings.buttons[e], !t);
      },
      updateSetting: function (e, t, i) {
        var n = this.elements.settings.panels[e],
          a = null,
          s = t;
        if ("captions" === e) a = this.currentTrack;
        else {
          if (
            ((a = ae(i) ? this[e] : i),
              ae(a) && (a = this.config[e].default),
              !ae(this.options[e]) && !this.options[e].includes(a))
          )
            return void this.debug.warn(
              "Unsupported value of '".concat(a, "' for ").concat(e)
            );
          if (!this.config[e].options.includes(a))
            return void this.debug.warn(
              "Disabled value of '".concat(a, "' for ").concat(e)
            );
        }
        if ((G(s) || (s = n && n.querySelector('[role="menu"]')), G(s))) {
          this.elements.settings.buttons[e].querySelector(
            ".".concat(this.config.classNames.menu.value)
          ).innerHTML = nt.getLabel.call(this, e, a);
          var r = s && s.querySelector('[value="'.concat(a, '"]'));
          G(r) && (r.checked = !0);
        }
      },
      getLabel: function (e, t) {
        switch (e) {
          case "speed":
            return 1 === t
              ? Xe("normal", this.config)
              : "".concat(t, "&times;");
          case "quality":
            if (K(t)) {
              var i = Xe("qualityLabel.".concat(t), this.config);
              return i.length ? i : "".concat(t, "p");
            }
            return ze(t);
          case "captions":
            return rt.getLabel.call(this);
          default:
            return null;
        }
      },
      setQualityMenu: function (e) {
        var t = this;
        if (G(this.elements.settings.panels.quality)) {
          var i =
            this.elements.settings.panels.quality.querySelector(
              '[role="menu"]'
            );
          $(e) &&
            (this.options.quality = Be(e).filter(function (e) {
              return t.config.quality.options.includes(e);
            }));
          var n = !ae(this.options.quality) && this.options.quality.length > 1;
          if (
            (nt.toggleMenuButton.call(this, "quality", n),
              fe(i),
              nt.checkMenu.call(this),
              n)
          ) {
            var a = function (e) {
              var i = Xe("qualityBadge.".concat(e), t.config);
              return i.length ? nt.createBadge.call(t, i) : null;
            };
            this.options.quality
              .sort(function (e, i) {
                var n = t.config.quality.options;
                return n.indexOf(e) > n.indexOf(i) ? 1 : -1;
              })
              .forEach(function (e) {
                nt.createMenuItem.call(t, {
                  value: e,
                  list: i,
                  type: "quality",
                  title: nt.getLabel.call(t, "quality", e),
                  badge: a(e),
                });
              }),
              nt.updateSetting.call(this, "quality", i);
          }
        }
      },
      setCaptionsMenu: function () {
        var e = this;
        if (G(this.elements.settings.panels.captions)) {
          var t =
            this.elements.settings.panels.captions.querySelector(
              '[role="menu"]'
            ),
            i = rt.getTracks.call(this),
            n = Boolean(i.length);
          if (
            (nt.toggleMenuButton.call(this, "captions", n),
              fe(t),
              nt.checkMenu.call(this),
              n)
          ) {
            var a = i.map(function (i, n) {
              return {
                value: n,
                checked: e.captions.toggled && e.currentTrack === n,
                title: rt.getLabel.call(e, i),
                badge:
                  i.language &&
                  nt.createBadge.call(e, i.language.toUpperCase()),
                list: t,
                type: "language",
              };
            });
            a.unshift({
              value: -1,
              checked: !this.captions.toggled,
              title: Xe("disabled", this.config),
              list: t,
              type: "language",
            }),
              a.forEach(nt.createMenuItem.bind(this)),
              nt.updateSetting.call(this, "captions", t);
          }
        }
      },
      setSpeedMenu: function () {
        var e = this;
        if (G(this.elements.settings.panels.speed)) {
          var t =
            this.elements.settings.panels.speed.querySelector('[role="menu"]');
          this.options.speed = this.options.speed.filter(function (t) {
            return t >= e.minimumSpeed && t <= e.maximumSpeed;
          });
          var i = !ae(this.options.speed) && this.options.speed.length > 1;
          nt.toggleMenuButton.call(this, "speed", i),
            fe(t),
            nt.checkMenu.call(this),
            i &&
            (this.options.speed.forEach(function (i) {
              nt.createMenuItem.call(e, {
                value: i,
                list: t,
                type: "speed",
                title: nt.getLabel.call(e, "speed", i),
              });
            }),
              nt.updateSetting.call(this, "speed", t));
        }
      },
      checkMenu: function () {
        var e = this.elements.settings.buttons,
          t =
            !ae(e) &&
            Object.values(e).some(function (e) {
              return !e.hidden;
            });
        ve(this.elements.settings.menu, !t);
      },
      focusFirstMenuItem: function (e) {
        var t = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
        if (!this.elements.settings.popup.hidden) {
          var i = e;
          G(i) ||
            (i = Object.values(this.elements.settings.panels).find(function (
              e
            ) {
              return !e.hidden;
            }));
          var n = i.querySelector('[role^="menuitem"]');
          Ae.call(this, n, t);
        }
      },
      toggleMenu: function (e) {
        var t = this.elements.settings.popup,
          i = this.elements.buttons.settings;
        if (G(t) && G(i)) {
          var n = t.hidden,
            a = n;
          if (Q(e)) a = e;
          else if (ee(e) && 27 === e.which) a = !1;
          else if (Z(e)) {
            var s = X(e.composedPath) ? e.composedPath()[0] : e.target,
              r = t.contains(s);
            if (r || (!r && e.target !== i && a)) return;
          }
          i.setAttribute("aria-expanded", a),
            ve(t, !a),
            be(this.elements.container, this.config.classNames.menu.open, a),
            a && ee(e)
              ? nt.focusFirstMenuItem.call(this, null, !0)
              : a || n || Ae.call(this, i, ee(e));
        }
      },
      getMenuSize: function (e) {
        var t = e.cloneNode(!0);
        (t.style.position = "absolute"),
          (t.style.opacity = 0),
          t.removeAttribute("hidden"),
          e.parentNode.appendChild(t);
        var i = t.scrollWidth,
          n = t.scrollHeight;
        return me(t), { width: i, height: n };
      },
      showMenuPanel: function () {
        var e = this,
          t =
            arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "",
          i = arguments.length > 1 && void 0 !== arguments[1] && arguments[1],
          n = this.elements.container.querySelector(
            "#plyr-settings-".concat(this.id, "-").concat(t)
          );
        if (G(n)) {
          var a = n.parentNode,
            s = Array.from(a.children).find(function (e) {
              return !e.hidden;
            });
          if (Ee.transitions && !Ee.reducedMotion) {
            (a.style.width = "".concat(s.scrollWidth, "px")),
              (a.style.height = "".concat(s.scrollHeight, "px"));
            var r = nt.getMenuSize.call(this, n),
              o = function t(i) {
                i.target === a &&
                  ["width", "height"].includes(i.propertyName) &&
                  ((a.style.width = ""),
                    (a.style.height = ""),
                    Ie.call(e, a, se, t));
              };
            xe.call(this, a, se, o),
              (a.style.width = "".concat(r.width, "px")),
              (a.style.height = "".concat(r.height, "px"));
          }
          ve(s, !0), ve(n, !1), nt.focusFirstMenuItem.call(this, n, i);
        }
      },
      setDownloadUrl: function () {
        var e = this.elements.buttons.download;
        G(e) && e.setAttribute("href", this.download);
      },
      create: function (e) {
        var t = this,
          i = nt.bindMenuItemShortcuts,
          n = nt.createButton,
          a = nt.createProgress,
          s = nt.createRange,
          r = nt.createTime,
          o = nt.setQualityMenu,
          l = nt.setSpeedMenu,
          c = nt.showMenuPanel;
        (this.elements.controls = null),
          this.config.controls.includes("play-large") &&
          this.elements.container.appendChild(n.call(this, "play-large"));
        var u = he("div", ye(this.config.selectors.controls.wrapper));
        this.elements.controls = u;
        var d = { class: "plyr__controls__item" };
        return (
          Be(this.config.controls).forEach(function (o) {
            if (
              ("restart" === o && u.appendChild(n.call(t, "restart", d)),
                "rewind" === o && u.appendChild(n.call(t, "rewind", d)),
                "play" === o && u.appendChild(n.call(t, "play", d)),
                "fast-forward" === o &&
                u.appendChild(n.call(t, "fast-forward", d)),
                "progress" === o)
            ) {
              var l = he("div", {
                class: "".concat(d.class, " plyr__progress__container"),
              }),
                h = he("div", ye(t.config.selectors.progress));
              if (
                (h.appendChild(
                  s.call(t, "seek", { id: "plyr-seek-".concat(e.id) })
                ),
                  h.appendChild(a.call(t, "buffer")),
                  t.config.tooltips.seek)
              ) {
                var p = he(
                  "span",
                  { class: t.config.classNames.tooltip },
                  "00:00"
                );
                h.appendChild(p), (t.elements.display.seekTooltip = p);
              }
              (t.elements.progress = h),
                l.appendChild(t.elements.progress),
                u.appendChild(l);
            }
            if (
              ("current-time" === o &&
                u.appendChild(r.call(t, "currentTime", d)),
                "duration" === o && u.appendChild(r.call(t, "duration", d)),
                "mute" === o || "volume" === o)
            ) {
              var m = t.elements.volume;
              if (
                ((G(m) && u.contains(m)) ||
                  ((m = he(
                    "div",
                    ce({}, d, {
                      class: "".concat(d.class, " plyr__volume").trim(),
                    })
                  )),
                    (t.elements.volume = m),
                    u.appendChild(m)),
                  "mute" === o && m.appendChild(n.call(t, "mute")),
                  "volume" === o && !oe.isIos)
              ) {
                var f = { max: 1, step: 0.05, value: t.config.volume };
                m.appendChild(
                  s.call(
                    t,
                    "volume",
                    ce(f, { id: "plyr-volume-".concat(e.id) })
                  )
                );
              }
            }
            if (
              ("captions" === o && u.appendChild(n.call(t, "captions", d)),
                "settings" === o && !ae(t.config.settings))
            ) {
              var g = he(
                "div",
                ce({}, d, {
                  class: "".concat(d.class, " plyr__menu").trim(),
                  hidden: "",
                })
              );
              g.appendChild(
                n.call(t, "settings", {
                  "aria-haspopup": !0,
                  "aria-controls": "plyr-settings-".concat(e.id),
                  "aria-expanded": !1,
                })
              );
              var y = he("div", {
                class: "plyr__menu__container",
                id: "plyr-settings-".concat(e.id),
                hidden: "",
              }),
                v = he("div"),
                b = he("div", { id: "plyr-settings-".concat(e.id, "-home") }),
                w = he("div", { role: "menu" });
              b.appendChild(w),
                v.appendChild(b),
                (t.elements.settings.panels.home = b),
                t.config.settings.forEach(function (n) {
                  var a = he(
                    "button",
                    ce(ye(t.config.selectors.buttons.settings), {
                      type: "button",
                      class: ""
                        .concat(t.config.classNames.control, " ")
                        .concat(t.config.classNames.control, "--forward"),
                      role: "menuitem",
                      "aria-haspopup": !0,
                      hidden: "",
                    })
                  );
                  i.call(t, a, n),
                    xe.call(t, a, "click", function () {
                      c.call(t, n, !1);
                    });
                  var s = he("span", null, Xe(n, t.config)),
                    r = he("span", { class: t.config.classNames.menu.value });
                  (r.innerHTML = e[n]),
                    s.appendChild(r),
                    a.appendChild(s),
                    w.appendChild(a);
                  var o = he("div", {
                    id: "plyr-settings-".concat(e.id, "-").concat(n),
                    hidden: "",
                  }),
                    l = he("button", {
                      type: "button",
                      class: ""
                        .concat(t.config.classNames.control, " ")
                        .concat(t.config.classNames.control, "--back"),
                    });
                  l.appendChild(
                    he("span", { "aria-hidden": !0 }, Xe(n, t.config))
                  ),
                    l.appendChild(
                      he(
                        "span",
                        { class: t.config.classNames.hidden },
                        Xe("menuBack", t.config)
                      )
                    ),
                    xe.call(
                      t,
                      o,
                      "keydown",
                      function (e) {
                        37 === e.which &&
                          (e.preventDefault(),
                            e.stopPropagation(),
                            c.call(t, "home", !0));
                      },
                      !1
                    ),
                    xe.call(t, l, "click", function () {
                      c.call(t, "home", !1);
                    }),
                    o.appendChild(l),
                    o.appendChild(he("div", { role: "menu" })),
                    v.appendChild(o),
                    (t.elements.settings.buttons[n] = a),
                    (t.elements.settings.panels[n] = o);
                }),
                y.appendChild(v),
                g.appendChild(y),
                u.appendChild(g),
                (t.elements.settings.popup = y),
                (t.elements.settings.menu = g);
            }
            if (
              ("pip" === o && Ee.pip && u.appendChild(n.call(t, "pip", d)),
                "airplay" === o &&
                Ee.airplay &&
                u.appendChild(n.call(t, "airplay", d)),
                "download" === o)
            ) {
              var k = ce({}, d, {
                element: "a",
                href: t.download,
                target: "_blank",
              });
              t.isHTML5 && (k.download = "");
              var T = t.config.urls.download;
              !ne(T) &&
                t.isEmbed &&
                ce(k, { icon: "logo-".concat(t.provider), label: t.provider }),
                u.appendChild(n.call(t, "download", k));
            }
            "fullscreen" === o && u.appendChild(n.call(t, "fullscreen", d));
          }),
          this.isHTML5 && o.call(this, Ve.getQualityOptions.call(this)),
          l.call(this),
          u
        );
      },
      inject: function () {
        var e = this;
        if (this.config.loadSprite) {
          var t = nt.getIconUrl.call(this);
          t.cors && Ge(t.url, "sprite-plyr");
        }
        this.id = Math.floor(1e4 * Math.random());
        var i = null;
        this.elements.controls = null;
        var n = {
          id: this.id,
          seektime: this.config.seekTime,
          title: this.config.title,
        },
          a = !0;
        X(this.config.controls) &&
          (this.config.controls = this.config.controls.call(this, n)),
          this.config.controls || (this.config.controls = []),
          G(this.config.controls) || Y(this.config.controls)
            ? (i = this.config.controls)
            : ((i = nt.create.call(this, {
              id: this.id,
              seektime: this.config.seekTime,
              speed: this.speed,
              quality: this.quality,
              captions: rt.getLabel.call(this),
            })),
              (a = !1));
        var s,
          r = function (e) {
            var t = e;
            return (
              Object.entries(n).forEach(function (e) {
                var i = o(e, 2),
                  n = i[0],
                  a = i[1];
                t = We(t, "{".concat(n, "}"), a);
              }),
              t
            );
          };
        if (
          (a &&
            (Y(this.config.controls)
              ? (i = r(i))
              : G(i) && (i.innerHTML = r(i.innerHTML))),
            Y(this.config.selectors.controls.container) &&
            (s = document.querySelector(
              this.config.selectors.controls.container
            )),
            G(s) || (s = this.elements.container),
            s[G(i) ? "insertAdjacentElement" : "insertAdjacentHTML"](
              "afterbegin",
              i
            ),
            G(this.elements.controls) || nt.findElements.call(this),
            !ae(this.elements.buttons))
        ) {
          var l = function (t) {
            var i = e.config.classNames.controlPressed;
            Object.defineProperty(t, "pressed", {
              enumerable: !0,
              get: function () {
                return we(t, i);
              },
              set: function () {
                var e =
                  arguments.length > 0 &&
                  void 0 !== arguments[0] &&
                  arguments[0];
                be(t, i, e);
              },
            });
          };
          Object.values(this.elements.buttons)
            .filter(Boolean)
            .forEach(function (e) {
              $(e) || J(e) ? Array.from(e).filter(Boolean).forEach(l) : l(e);
            });
        }
        if ((oe.isEdge && re(s), this.config.tooltips.controls)) {
          var c = this.config,
            u = c.classNames,
            d = c.selectors,
            h = ""
              .concat(d.controls.wrapper, " ")
              .concat(d.labels, " .")
              .concat(u.hidden),
            p = Te.call(this, h);
          Array.from(p).forEach(function (t) {
            be(t, e.config.classNames.hidden, !1),
              be(t, e.config.classNames.tooltip, !0);
          });
        }
      },
    };
    function at(e) {
      var t =
        !(arguments.length > 1 && void 0 !== arguments[1]) || arguments[1],
        i = e;
      if (t) {
        var n = document.createElement("a");
        (n.href = i), (i = n.href);
      }
      try {
        return new URL(i);
      } catch (e) {
        return null;
      }
    }
    function st(e) {
      var t = new URLSearchParams();
      return (
        z(e) &&
        Object.entries(e).forEach(function (e) {
          var i = o(e, 2),
            n = i[0],
            a = i[1];
          t.set(n, a);
        }),
        t
      );
    }
    var rt = {
      setup: function () {
        if (this.supported.ui)
          if (
            !this.isVideo ||
            this.isYouTube ||
            (this.isHTML5 && !Ee.textTracks)
          )
            $(this.config.controls) &&
              this.config.controls.includes("settings") &&
              this.config.settings.includes("captions") &&
              nt.setCaptionsMenu.call(this);
          else {
            if (
              (G(this.elements.captions) ||
                ((this.elements.captions = he(
                  "div",
                  ye(this.config.selectors.captions)
                )),
                  (function (e, t) {
                    G(e) && G(t) && t.parentNode.insertBefore(e, t.nextSibling);
                  })(this.elements.captions, this.elements.wrapper)),
                oe.isIE && window.URL)
            ) {
              var e = this.media.querySelectorAll("track");
              Array.from(e).forEach(function (e) {
                var t = e.getAttribute("src"),
                  i = at(t);
                null !== i &&
                  i.hostname !== window.location.href.hostname &&
                  ["http:", "https:"].includes(i.protocol) &&
                  Je(t, "blob")
                    .then(function (t) {
                      e.setAttribute("src", window.URL.createObjectURL(t));
                    })
                    .catch(function () {
                      me(e);
                    });
              });
            }
            var t = Be(
              (
                navigator.languages || [
                  navigator.language || navigator.userLanguage || "en",
                ]
              ).map(function (e) {
                return e.split("-")[0];
              })
            ),
              i = (
                this.storage.get("language") ||
                this.config.captions.language ||
                "auto"
              ).toLowerCase();
            if ("auto" === i) i = o(t, 1)[0];
            var n = this.storage.get("captions");
            if (
              (Q(n) || (n = this.config.captions.active),
                Object.assign(this.captions, {
                  toggled: !1,
                  active: n,
                  language: i,
                  languages: t,
                }),
                this.isHTML5)
            ) {
              var a = this.config.captions.update
                ? "addtrack removetrack"
                : "removetrack";
              xe.call(this, this.media.textTracks, a, rt.update.bind(this));
            }
            setTimeout(rt.update.bind(this), 0);
          }
      },
      update: function () {
        var e = this,
          t = rt.getTracks.call(this, !0),
          i = this.captions,
          n = i.active,
          a = i.language,
          s = i.meta,
          r = i.currentTrackNode,
          o = Boolean(
            t.find(function (e) {
              return e.language === a;
            })
          );
        this.isHTML5 &&
          this.isVideo &&
          t
            .filter(function (e) {
              return !s.get(e);
            })
            .forEach(function (t) {
              e.debug.log("Track added", t),
                s.set(t, { default: "showing" === t.mode }),
                "showing" === t.mode && (t.mode = "hidden"),
                xe.call(e, t, "cuechange", function () {
                  return rt.updateCues.call(e);
                });
            }),
          ((o && this.language !== a) || !t.includes(r)) &&
          (rt.setLanguage.call(this, a), rt.toggle.call(this, n && o)),
          be(
            this.elements.container,
            this.config.classNames.captions.enabled,
            !ae(t)
          ),
          $(this.config.controls) &&
          this.config.controls.includes("settings") &&
          this.config.settings.includes("captions") &&
          nt.setCaptionsMenu.call(this);
      },
      toggle: function (e) {
        var t = this,
          i =
            !(arguments.length > 1 && void 0 !== arguments[1]) ||
            arguments[1];
        if (this.supported.ui) {
          var n = this.captions.toggled,
            a = this.config.classNames.captions.active,
            s = W(e) ? !n : e;
          if (s !== n) {
            if (
              (i ||
                ((this.captions.active = s),
                  this.storage.set({ captions: s })),
                !this.language && s && !i)
            ) {
              var r = rt.getTracks.call(this),
                o = rt.findTrack.call(
                  this,
                  [this.captions.language].concat(l(this.captions.languages)),
                  !0
                );
              return (
                (this.captions.language = o.language),
                void rt.set.call(this, r.indexOf(o))
              );
            }
            this.elements.buttons.captions &&
              (this.elements.buttons.captions.pressed = s),
              be(this.elements.container, a, s),
              (this.captions.toggled = s),
              nt.updateSetting.call(this, "captions"),
              Oe.call(
                this,
                this.media,
                s ? "captionsenabled" : "captionsdisabled"
              );
          }
          setTimeout(function () {
            s &&
              t.captions.toggled &&
              (t.captions.currentTrackNode.mode = "hidden");
          });
        }
      },
      set: function (e) {
        var t =
          !(arguments.length > 1 && void 0 !== arguments[1]) ||
          arguments[1],
          i = rt.getTracks.call(this);
        if (-1 !== e)
          if (K(e))
            if (e in i) {
              if (this.captions.currentTrack !== e) {
                this.captions.currentTrack = e;
                var n = i[e],
                  a = n || {},
                  s = a.language;
                (this.captions.currentTrackNode = n),
                  nt.updateSetting.call(this, "captions"),
                  t ||
                  ((this.captions.language = s),
                    this.storage.set({ language: s })),
                  this.isVimeo && this.embed.enableTextTrack(s),
                  Oe.call(this, this.media, "languagechange");
              }
              rt.toggle.call(this, !0, t),
                this.isHTML5 && this.isVideo && rt.updateCues.call(this);
            } else this.debug.warn("Track not found", e);
          else this.debug.warn("Invalid caption argument", e);
        else rt.toggle.call(this, !1, t);
      },
      setLanguage: function (e) {
        var t =
          !(arguments.length > 1 && void 0 !== arguments[1]) || arguments[1];
        if (Y(e)) {
          var i = e.toLowerCase();
          this.captions.language = i;
          var n = rt.getTracks.call(this),
            a = rt.findTrack.call(this, [i]);
          rt.set.call(this, n.indexOf(a), t);
        } else this.debug.warn("Invalid language argument", e);
      },
      getTracks: function () {
        var e = this,
          t = arguments.length > 0 && void 0 !== arguments[0] && arguments[0],
          i = Array.from((this.media || {}).textTracks || []);
        return i
          .filter(function (i) {
            return !e.isHTML5 || t || e.captions.meta.has(i);
          })
          .filter(function (e) {
            return ["captions", "subtitles"].includes(e.kind);
          });
      },
      findTrack: function (e) {
        var t,
          i = this,
          n = arguments.length > 1 && void 0 !== arguments[1] && arguments[1],
          a = rt.getTracks.call(this),
          s = function (e) {
            return Number((i.captions.meta.get(e) || {}).default);
          },
          r = Array.from(a).sort(function (e, t) {
            return s(t) - s(e);
          });
        return (
          e.every(function (e) {
            return !(t = r.find(function (t) {
              return t.language === e;
            }));
          }),
          t || (n ? r[0] : void 0)
        );
      },
      getCurrentTrack: function () {
        return rt.getTracks.call(this)[this.currentTrack];
      },
      getLabel: function (e) {
        var t = e;
        return (
          !te(t) &&
          Ee.textTracks &&
          this.captions.toggled &&
          (t = rt.getCurrentTrack.call(this)),
          te(t)
            ? ae(t.label)
              ? ae(t.language)
                ? Xe("enabled", this.config)
                : e.language.toUpperCase()
              : t.label
            : Xe("disabled", this.config)
        );
      },
      updateCues: function (e) {
        if (this.supported.ui)
          if (G(this.elements.captions))
            if (W(e) || Array.isArray(e)) {
              var t = e;
              if (!t) {
                var i = rt.getCurrentTrack.call(this);
                t = Array.from((i || {}).activeCues || [])
                  .map(function (e) {
                    return e.getCueAsHTML();
                  })
                  .map(Ye);
              }
              var n = t
                .map(function (e) {
                  return e.trim();
                })
                .join("\n");
              if (n !== this.elements.captions.innerHTML) {
                fe(this.elements.captions);
                var a = he("span", ye(this.config.selectors.caption));
                (a.innerHTML = n),
                  this.elements.captions.appendChild(a),
                  Oe.call(this, this.media, "cuechange");
              }
            } else this.debug.warn("updateCues: Invalid input", e);
          else this.debug.warn("No captions element to render to");
      },
    },
      ot = {
        enabled: !0,
        title: "",
        debug: !1,
        autoplay: !1,
        autopause: !0,
        playsinline: !0,
        seekTime: 10,
        volume: 1,
        muted: !1,
        duration: null,
        displayDuration: !0,
        invertTime: !0,
        toggleInvert: !0,
        ratio: null,
        clickToPlay: !0,
        hideControls: !0,
        resetOnEnd: !1,
        disableContextMenu: !0,
        loadSprite: !0,
        iconPrefix: "plyr",
        iconUrl: (plyr_icons != '') ? plyr_icons : "https://cdn.plyr.io/3.6.1/plyr.svg",
        blankVideo: "https://cdn.plyr.io/static/blank.mp4",
        quality: {
          default: 576,
          options: [4320, 2880, 2160, 1440, 1080, 720, 576, 480, 360, 240],
          forced: !1,
          onChange: null,
        },
        loop: { active: !1 },
        speed: { selected: 1, options: [0.5, 0.75, 1, 1.25, 1.5, 1.75, 2, 4] },
        keyboard: { focused: !0, global: !1 },
        tooltips: { controls: !1, seek: !0 },
        captions: { active: !1, language: "auto", update: !1 },
        fullscreen: { enabled: !0, fallback: !0, iosNative: !1 },
        storage: { enabled: !0, key: "plyr" },
        controls: [
          "play-large",
          "play",
          "progress",
          "current-time",
          "mute",
          "volume",
          "captions",
          "settings",
          "pip",
          "airplay",
          "fullscreen",
        ],
        settings: ["captions", "quality", "speed"],
        i18n: {
          restart: "Restart",
          rewind: "Rewind {seektime}s",
          play: "شروع",
          pause: "توقف",
          fastForward: "Forward {seektime}s",
          seek: "Seek",
          seekLabel: "{currentTime} of {duration}",
          played: "Played",
          buffered: "Buffered",
          currentTime: "Current time",
          duration: "Duration",
          volume: "Volume",
          mute: "بی‌صدا",
          unmute: "باصدا",
          enableCaptions: "فعالسازی زیرنویس",
          disableCaptions: "غیرفعالسازی زیرنویس",
          download: "Download",
          enterFullscreen: "تمام صفحه",
          exitFullscreen: "بستن تمام صفحه",
          frameTitle: "Player for {title}",
          captions: "زیرنویس ها",
          settings: "تنظیمات",
          pip: "PIP",
          menuBack: "Go back to previous menu",
          speed: "سرعت",
          normal: "Normal",
          quality: "کیفیت",
          loop: "Loop",
          start: "Start",
          end: "End",
          all: "All",
          reset: "Reset",
          disabled: "Disabled",
          enabled: "Enabled",
          advertisement: "Ad",
          qualityBadge: {
            2160: "4K",
            1440: "QHD",
            1080: "FHD",
            720: "HD",
            576: "SD",
            480: "SD",
          },
        },
        urls: {
          download: null,
          vimeo: {
            sdk: "https://player.vimeo.com/api/player.js",
            iframe: "https://player.vimeo.com/video/{0}?{1}",
            api: "https://vimeo.com/api/v2/video/{0}.json",
          },
          youtube: {
            sdk: "https://www.youtube.com/iframe_api",
            api: "https://noembed.com/embed?url=https://www.youtube.com/watch?v={0}",
          },
          googleIMA: {
            sdk: "https://imasdk.googleapis.com/js/sdkloader/ima3.js",
          },
        },
        listeners: {
          seek: null,
          play: null,
          pause: null,
          restart: null,
          rewind: null,
          fastForward: null,
          mute: null,
          volume: null,
          captions: null,
          download: null,
          fullscreen: null,
          pip: null,
          airplay: null,
          speed: null,
          quality: null,
          loop: null,
          language: null,
        },
        events: [
          "ended",
          "progress",
          "stalled",
          "playing",
          "waiting",
          "canplay",
          "canplaythrough",
          "loadstart",
          "loadeddata",
          "loadedmetadata",
          "timeupdate",
          "volumechange",
          "play",
          "pause",
          "error",
          "seeking",
          "seeked",
          "emptied",
          "ratechange",
          "cuechange",
          "download",
          "enterfullscreen",
          "exitfullscreen",
          "captionsenabled",
          "captionsdisabled",
          "languagechange",
          "controlshidden",
          "controlsshown",
          "ready",
          "statechange",
          "qualitychange",
          "adsloaded",
          "adscontentpause",
          "adscontentresume",
          "adstarted",
          "adsmidpoint",
          "adscomplete",
          "adsallcomplete",
          "adsimpression",
          "adsclick",
        ],
        selectors: {
          editable: "input, textarea, select, [contenteditable]",
          container: ".plyr",
          controls: { container: null, wrapper: ".plyr__controls" },
          labels: "[data-plyr]",
          buttons: {
            play: '[data-plyr="play"]',
            pause: '[data-plyr="pause"]',
            restart: '[data-plyr="restart"]',
            rewind: '[data-plyr="rewind"]',
            fastForward: '[data-plyr="fast-forward"]',
            mute: '[data-plyr="mute"]',
            captions: '[data-plyr="captions"]',
            download: '[data-plyr="download"]',
            fullscreen: '[data-plyr="fullscreen"]',
            pip: '[data-plyr="pip"]',
            airplay: '[data-plyr="airplay"]',
            settings: '[data-plyr="settings"]',
            loop: '[data-plyr="loop"]',
          },
          inputs: {
            seek: '[data-plyr="seek"]',
            volume: '[data-plyr="volume"]',
            speed: '[data-plyr="speed"]',
            language: '[data-plyr="language"]',
            quality: '[data-plyr="quality"]',
          },
          display: {
            currentTime: ".plyr__time--current",
            duration: ".plyr__time--duration",
            buffer: ".plyr__progress__buffer",
            loop: ".plyr__progress__loop",
            volume: ".plyr__volume--display",
          },
          progress: ".plyr__progress",
          captions: ".plyr__captions",
          caption: ".plyr__caption",
        },
        classNames: {
          type: "plyr--{0}",
          provider: "plyr--{0}",
          video: "plyr__video-wrapper",
          embed: "plyr__video-embed",
          videoFixedRatio: "plyr__video-wrapper--fixed-ratio",
          embedContainer: "plyr__video-embed__container",
          poster: "plyr__poster",
          posterEnabled: "plyr__poster-enabled",
          ads: "plyr__ads",
          control: "plyr__control",
          controlPressed: "plyr__control--pressed",
          playing: "plyr--playing",
          paused: "plyr--paused",
          stopped: "plyr--stopped",
          loading: "plyr--loading",
          hover: "plyr--hover",
          tooltip: "plyr__tooltip",
          cues: "plyr__cues",
          hidden: "plyr__sr-only",
          hideControls: "plyr--hide-controls",
          isIos: "plyr--is-ios",
          isTouch: "plyr--is-touch",
          uiSupported: "plyr--full-ui",
          noTransition: "plyr--no-transition",
          display: { time: "plyr__time" },
          menu: {
            value: "plyr__menu__value",
            badge: "plyr__badge",
            open: "plyr--menu-open",
          },
          captions: {
            enabled: "plyr--captions-enabled",
            active: "plyr--captions-active",
          },
          fullscreen: {
            enabled: "plyr--fullscreen-enabled",
            fallback: "plyr--fullscreen-fallback",
          },
          pip: { supported: "plyr--pip-supported", active: "plyr--pip-active" },
          airplay: {
            supported: "plyr--airplay-supported",
            active: "plyr--airplay-active",
          },
          tabFocus: "plyr__tab-focus",
          previewThumbnails: {
            thumbContainer: "plyr__preview-thumb",
            thumbContainerShown: "plyr__preview-thumb--is-shown",
            imageContainer: "plyr__preview-thumb__image-container",
            timeContainer: "plyr__preview-thumb__time-container",
            scrubbingContainer: "plyr__preview-scrubbing",
            scrubbingContainerShown: "plyr__preview-scrubbing--is-shown",
          },
        },
        attributes: {
          embed: { provider: "data-plyr-provider", id: "data-plyr-embed-id" },
        },
        ads: { enabled: !1, publisherId: "", tagUrl: "" },
        previewThumbnails: { enabled: !1, src: "" },
        vimeo: {
          byline: !1,
          portrait: !1,
          title: !1,
          speed: !0,
          transparent: !1,
          premium: !1,
          referrerPolicy: null,
        },
        youtube: {
          noCookie: !0,
          rel: 0,
          showinfo: 0,
          iv_load_policy: 3,
          modestbranding: 1,
        },
      },
      lt = "picture-in-picture",
      ct = "inline",
      ut = { html5: "html5", youtube: "youtube", vimeo: "vimeo" },
      dt = "audio",
      ht = "video";
    var pt = function () { },
      mt = (function () {
        function t() {
          var i =
            arguments.length > 0 && void 0 !== arguments[0] && arguments[0];
          e(this, t),
            (this.enabled = window.console && i),
            this.enabled && this.log("Debugging enabled");
        }
        return (
          i(t, [
            {
              key: "log",
              get: function () {
                return this.enabled
                  ? Function.prototype.bind.call(console.log, console)
                  : pt;
              },
            },
            {
              key: "warn",
              get: function () {
                return this.enabled
                  ? Function.prototype.bind.call(console.warn, console)
                  : pt;
              },
            },
            {
              key: "error",
              get: function () {
                return this.enabled
                  ? Function.prototype.bind.call(console.error, console)
                  : pt;
              },
            },
          ]),
          t
        );
      })(),
      ft = (function () {
        function t(i) {
          var n = this;
          e(this, t),
            (this.player = i),
            (this.prefix = t.prefix),
            (this.property = t.property),
            (this.scrollPosition = { x: 0, y: 0 }),
            (this.forceFallback = "force" === i.config.fullscreen.fallback),
            (this.player.elements.fullscreen =
              i.config.fullscreen.container &&
              (function (e, t) {
                return (
                  Element.prototype.closest ||
                  function () {
                    var e = this;
                    do {
                      if (ke.matches(e, t)) return e;
                      e = e.parentElement || e.parentNode;
                    } while (null !== e && 1 === e.nodeType);
                    return null;
                  }
                ).call(e, t);
              })(
                this.player.elements.container,
                i.config.fullscreen.container
              )),
            xe.call(
              this.player,
              document,
              "ms" === this.prefix
                ? "MSFullscreenChange"
                : "".concat(this.prefix, "fullscreenchange"),
              function () {
                n.onChange();
              }
            ),
            xe.call(
              this.player,
              this.player.elements.container,
              "dblclick",
              function (e) {
                (G(n.player.elements.controls) &&
                  n.player.elements.controls.contains(e.target)) ||
                  n.toggle();
              }
            ),
            xe.call(
              this,
              this.player.elements.container,
              "keydown",
              function (e) {
                return n.trapFocus(e);
              }
            ),
            this.update();
        }
        return (
          i(
            t,
            [
              {
                key: "onChange",
                value: function () {
                  if (this.enabled) {
                    var e = this.player.elements.buttons.fullscreen;
                    G(e) && (e.pressed = this.active),
                      Oe.call(
                        this.player,
                        this.target,
                        this.active ? "enterfullscreen" : "exitfullscreen",
                        !0
                      );
                  }
                },
              },
              {
                key: "toggleFallback",
                value: function () {
                  var e =
                    arguments.length > 0 &&
                    void 0 !== arguments[0] &&
                    arguments[0];
                  if (
                    (e
                      ? (this.scrollPosition = {
                        x: window.scrollX || 0,
                        y: window.scrollY || 0,
                      })
                      : window.scrollTo(
                        this.scrollPosition.x,
                        this.scrollPosition.y
                      ),
                      (document.body.style.overflow = e ? "hidden" : ""),
                      be(
                        this.target,
                        this.player.config.classNames.fullscreen.fallback,
                        e
                      ),
                      oe.isIos)
                  ) {
                    var t = document.head.querySelector(
                      'meta[name="viewport"]'
                    ),
                      i = "viewport-fit=cover";
                    t ||
                      (t = document.createElement("meta")).setAttribute(
                        "name",
                        "viewport"
                      );
                    var n = Y(t.content) && t.content.includes(i);
                    e
                      ? ((this.cleanupViewport = !n),
                        n || (t.content += ",".concat(i)))
                      : this.cleanupViewport &&
                      (t.content = t.content
                        .split(",")
                        .filter(function (e) {
                          return e.trim() !== i;
                        })
                        .join(","));
                  }
                  this.onChange();
                },
              },
              {
                key: "trapFocus",
                value: function (e) {
                  if (
                    !oe.isIos &&
                    this.active &&
                    "Tab" === e.key &&
                    9 === e.keyCode
                  ) {
                    var t = document.activeElement,
                      i = Te.call(
                        this.player,
                        "a[href], button:not(:disabled), input:not(:disabled), [tabindex]"
                      ),
                      n = o(i, 1)[0],
                      a = i[i.length - 1];
                    t !== a || e.shiftKey
                      ? t === n && e.shiftKey && (a.focus(), e.preventDefault())
                      : (n.focus(), e.preventDefault());
                  }
                },
              },
              {
                key: "update",
                value: function () {
                  var e;
                  this.enabled
                    ? ((e = this.forceFallback
                      ? "Fallback (forced)"
                      : t.native
                        ? "Native"
                        : "Fallback"),
                      this.player.debug.log(
                        "".concat(e, " fullscreen enabled")
                      ))
                    : this.player.debug.log(
                      "Fullscreen not supported and fallback disabled"
                    );
                  be(
                    this.player.elements.container,
                    this.player.config.classNames.fullscreen.enabled,
                    this.enabled
                  );
                },
              },
              {
                key: "enter",
                value: function () {
                  this.enabled &&
                    (oe.isIos && this.player.config.fullscreen.iosNative
                      ? this.target.webkitEnterFullscreen()
                      : !t.native || this.forceFallback
                        ? this.toggleFallback(!0)
                        : this.prefix
                          ? ae(this.prefix) ||
                          this.target[
                            ""
                              .concat(this.prefix, "Request")
                              .concat(this.property)
                          ]()
                          : this.target.requestFullscreen({
                            navigationUI: "hide",
                          }));
                },
              },
              {
                key: "exit",
                value: function () {
                  if (this.enabled)
                    if (oe.isIos && this.player.config.fullscreen.iosNative)
                      this.target.webkitExitFullscreen(),
                        qe(this.player.play());
                    else if (!t.native || this.forceFallback)
                      this.toggleFallback(!1);
                    else if (this.prefix) {
                      if (!ae(this.prefix)) {
                        var e = "moz" === this.prefix ? "Cancel" : "Exit";
                        document[
                          "".concat(this.prefix).concat(e).concat(this.property)
                        ]();
                      }
                    } else
                      (
                        document.cancelFullScreen || document.exitFullscreen
                      ).call(document);
                },
              },
              {
                key: "toggle",
                value: function () {
                  this.active ? this.exit() : this.enter();
                },
              },
              {
                key: "usingNative",
                get: function () {
                  return t.native && !this.forceFallback;
                },
              },
              {
                key: "enabled",
                get: function () {
                  return (
                    (t.native || this.player.config.fullscreen.fallback) &&
                    this.player.config.fullscreen.enabled &&
                    this.player.supported.ui &&
                    this.player.isVideo
                  );
                },
              },
              {
                key: "active",
                get: function () {
                  if (!this.enabled) return !1;
                  if (!t.native || this.forceFallback)
                    return we(
                      this.target,
                      this.player.config.classNames.fullscreen.fallback
                    );
                  var e = this.prefix
                    ? document[
                    "".concat(this.prefix).concat(this.property, "Element")
                    ]
                    : document.fullscreenElement;
                  return e && e.shadowRoot
                    ? e === this.target.getRootNode().host
                    : e === this.target;
                },
              },
              {
                key: "target",
                get: function () {
                  return oe.isIos && this.player.config.fullscreen.iosNative
                    ? this.player.media
                    : this.player.elements.fullscreen ||
                    this.player.elements.container;
                },
              },
            ],
            [
              {
                key: "native",
                get: function () {
                  return !!(
                    document.fullscreenEnabled ||
                    document.webkitFullscreenEnabled ||
                    document.mozFullScreenEnabled ||
                    document.msFullscreenEnabled
                  );
                },
              },
              {
                key: "prefix",
                get: function () {
                  if (X(document.exitFullscreen)) return "";
                  var e = "";
                  return (
                    ["webkit", "moz", "ms"].some(function (t) {
                      return (
                        !(
                          !X(document["".concat(t, "ExitFullscreen")]) &&
                          !X(document["".concat(t, "CancelFullScreen")])
                        ) && ((e = t), !0)
                      );
                    }),
                    e
                  );
                },
              },
              {
                key: "property",
                get: function () {
                  return "moz" === this.prefix ? "FullScreen" : "Fullscreen";
                },
              },
            ]
          ),
          t
        );
      })();
    function gt(e) {
      var t =
        arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 1;
      return new Promise(function (i, n) {
        var a = new Image(),
          s = function () {
            delete a.onload, delete a.onerror, (a.naturalWidth >= t ? i : n)(a);
          };
        Object.assign(a, { onload: s, onerror: s, src: e });
      });
    }
    var yt = {
      addStyleHook: function () {
        be(
          this.elements.container,
          this.config.selectors.container.replace(".", ""),
          !0
        ),
          be(
            this.elements.container,
            this.config.classNames.uiSupported,
            this.supported.ui
          );
      },
      toggleNativeControls: function () {
        var e =
          arguments.length > 0 && void 0 !== arguments[0] && arguments[0];
        e && this.isHTML5
          ? this.media.setAttribute("controls", "")
          : this.media.removeAttribute("controls");
      },
      build: function () {
        var e = this;
        if ((this.listeners.media(), !this.supported.ui))
          return (
            this.debug.warn(
              "Basic support only for "
                .concat(this.provider, " ")
                .concat(this.type)
            ),
            void yt.toggleNativeControls.call(this, !0)
          );
        G(this.elements.controls) ||
          (nt.inject.call(this), this.listeners.controls()),
          yt.toggleNativeControls.call(this),
          this.isHTML5 && rt.setup.call(this),
          (this.volume = null),
          (this.muted = null),
          (this.loop = null),
          (this.quality = null),
          (this.speed = null),
          nt.updateVolume.call(this),
          nt.timeUpdate.call(this),
          yt.checkPlaying.call(this),
          be(
            this.elements.container,
            this.config.classNames.pip.supported,
            Ee.pip && this.isHTML5 && this.isVideo
          ),
          be(
            this.elements.container,
            this.config.classNames.airplay.supported,
            Ee.airplay && this.isHTML5
          ),
          be(this.elements.container, this.config.classNames.isIos, oe.isIos),
          be(
            this.elements.container,
            this.config.classNames.isTouch,
            this.touch
          ),
          (this.ready = !0),
          setTimeout(function () {
            Oe.call(e, e.media, "ready");
          }, 0),
          yt.setTitle.call(this),
          this.poster &&
          yt.setPoster.call(this, this.poster, !1).catch(function () { }),
          this.config.duration && nt.durationUpdate.call(this);
      },
      setTitle: function () {
        var e = Xe("play", this.config);
        if (
          (Y(this.config.title) &&
            !ae(this.config.title) &&
            (e += ", ".concat(this.config.title)),
            Array.from(this.elements.buttons.play || []).forEach(function (t) {
              t.setAttribute("aria-label", e);
            }),
            this.isEmbed)
        ) {
          var t = Ce.call(this, "iframe");
          if (!G(t)) return;
          var i = ae(this.config.title) ? "video" : this.config.title,
            n = Xe("frameTitle", this.config);
          t.setAttribute("title", n.replace("{title}", i));
        }
      },
      togglePoster: function (e) {
        be(this.elements.container, this.config.classNames.posterEnabled, e);
      },
      setPoster: function (e) {
        var t = this,
          i =
            !(arguments.length > 1 && void 0 !== arguments[1]) ||
            arguments[1];
        return i && this.poster
          ? Promise.reject(new Error("Poster already set"))
          : (this.media.setAttribute("data-poster", e),
            je
              .call(this)
              .then(function () {
                return gt(e);
              })
              .catch(function (i) {
                throw (e === t.poster && yt.togglePoster.call(t, !1), i);
              })
              .then(function () {
                if (e !== t.poster)
                  throw new Error(
                    "setPoster cancelled by later call to setPoster"
                  );
              })
              .then(function () {
                return (
                  Object.assign(t.elements.poster.style, {
                    backgroundImage: "url('".concat(e, "')"),
                    backgroundSize: "",
                  }),
                  yt.togglePoster.call(t, !0),
                  e
                );
              }));
      },
      checkPlaying: function (e) {
        var t = this;
        be(
          this.elements.container,
          this.config.classNames.playing,
          this.playing
        ),
          be(
            this.elements.container,
            this.config.classNames.paused,
            this.paused
          ),
          be(
            this.elements.container,
            this.config.classNames.stopped,
            this.stopped
          ),
          Array.from(this.elements.buttons.play || []).forEach(function (e) {
            Object.assign(e, { pressed: t.playing }),
              e.setAttribute(
                "aria-label",
                Xe(t.playing ? "pause" : "play", t.config)
              );
          }),
          (Z(e) && "timeupdate" === e.type) || yt.toggleControls.call(this);
      },
      checkLoading: function (e) {
        var t = this;
        (this.loading = ["stalled", "waiting"].includes(e.type)),
          clearTimeout(this.timers.loading),
          (this.timers.loading = setTimeout(
            function () {
              be(
                t.elements.container,
                t.config.classNames.loading,
                t.loading
              ),
                yt.toggleControls.call(t);
            },
            this.loading ? 250 : 0
          ));
      },
      toggleControls: function (e) {
        var t = this.elements.controls;
        if (t && this.config.hideControls) {
          var i = this.touch && this.lastSeekTime + 2e3 > Date.now();
          this.toggleControls(
            Boolean(
              e || this.loading || this.paused || t.pressed || t.hover || i
            )
          );
        }
      },
      migrateStyles: function () {
        var e = this;
        Object.values(s({}, this.media.style))
          .filter(function (e) {
            return !ae(e) && e.startsWith("--plyr");
          })
          .forEach(function (t) {
            e.elements.container.style.setProperty(
              t,
              e.media.style.getPropertyValue(t)
            ),
              e.media.style.removeProperty(t);
          }),
          ae(this.media.style) && this.media.removeAttribute("style");
      },
    },
      vt = (function () {
        function t(i) {
          e(this, t),
            (this.player = i),
            (this.lastKey = null),
            (this.focusTimer = null),
            (this.lastKeyDown = null),
            (this.handleKey = this.handleKey.bind(this)),
            (this.toggleMenu = this.toggleMenu.bind(this)),
            (this.setTabFocus = this.setTabFocus.bind(this)),
            (this.firstTouch = this.firstTouch.bind(this));
        }
        return (
          i(t, [
            {
              key: "handleKey",
              value: function (e) {
                var t = this.player,
                  i = t.elements,
                  n = e.keyCode ? e.keyCode : e.which,
                  a = "keydown" === e.type,
                  s = a && n === this.lastKey;
                if (
                  !(e.altKey || e.ctrlKey || e.metaKey || e.shiftKey) &&
                  K(n)
                ) {
                  if (a) {
                    var r = document.activeElement;
                    if (G(r)) {
                      var o = t.config.selectors.editable;
                      if (r !== i.inputs.seek && ke(r, o)) return;
                      if (32 === e.which && ke(r, 'button, [role^="menuitem"]'))
                        return;
                    }
                    switch (
                    ([
                      32, 37, 38, 39, 40, 48, 49, 50, 51, 52, 53, 54, 56, 57,
                      67, 70, 73, 75, 76, 77, 79,
                    ].includes(n) &&
                      (e.preventDefault(), e.stopPropagation()),
                      n)
                    ) {
                      case 48:
                      case 49:
                      case 50:
                      case 51:
                      case 52:
                      case 53:
                      case 54:
                      case 55:
                      case 56:
                      case 57:
                        s || (t.currentTime = (t.duration / 10) * (n - 48));
                        break;
                      case 32:
                      case 75:
                        s || qe(t.togglePlay());
                        break;
                      case 38:
                        t.increaseVolume(0.1);
                        break;
                      case 40:
                        t.decreaseVolume(0.1);
                        break;
                      case 77:
                        s || (t.muted = !t.muted);
                        break;
                      case 39:
                        t.forward();
                        break;
                      case 37:
                        t.rewind();
                        break;
                      case 70:
                        t.fullscreen.toggle();
                        break;
                      case 67:
                        s || t.toggleCaptions();
                        break;
                      case 76:
                        t.loop = !t.loop;
                    }
                    27 === n &&
                      !t.fullscreen.usingNative &&
                      t.fullscreen.active &&
                      t.fullscreen.toggle(),
                      (this.lastKey = n);
                  } else this.lastKey = null;
                }
              },
            },
            {
              key: "toggleMenu",
              value: function (e) {
                nt.toggleMenu.call(this.player, e);
              },
            },
            {
              key: "firstTouch",
              value: function () {
                var e = this.player,
                  t = e.elements;
                (e.touch = !0),
                  be(t.container, e.config.classNames.isTouch, !0);
              },
            },
            {
              key: "setTabFocus",
              value: function (e) {
                var t = this.player,
                  i = t.elements;
                if (
                  (clearTimeout(this.focusTimer),
                    "keydown" !== e.type || 9 === e.which)
                ) {
                  "keydown" === e.type && (this.lastKeyDown = e.timeStamp);
                  var n,
                    a = e.timeStamp - this.lastKeyDown <= 20;
                  if ("focus" !== e.type || a)
                    (n = t.config.classNames.tabFocus),
                      be(Te.call(t, ".".concat(n)), n, !1),
                      "focusout" !== e.type &&
                      (this.focusTimer = setTimeout(function () {
                        var e = document.activeElement;
                        i.container.contains(e) &&
                          be(
                            document.activeElement,
                            t.config.classNames.tabFocus,
                            !0
                          );
                      }, 10));
                }
              },
            },
            {
              key: "global",
              value: function () {
                var e =
                  !(arguments.length > 0 && void 0 !== arguments[0]) ||
                  arguments[0],
                  t = this.player;
                t.config.keyboard.global &&
                  Ne.call(t, window, "keydown keyup", this.handleKey, e, !1),
                  Ne.call(t, document.body, "click", this.toggleMenu, e),
                  Le.call(t, document.body, "touchstart", this.firstTouch),
                  Ne.call(
                    t,
                    document.body,
                    "keydown focus blur focusout",
                    this.setTabFocus,
                    e,
                    !1,
                    !0
                  );
              },
            },
            {
              key: "container",
              value: function () {
                var e = this.player,
                  t = e.config,
                  i = e.elements,
                  n = e.timers;
                !t.keyboard.global &&
                  t.keyboard.focused &&
                  xe.call(e, i.container, "keydown keyup", this.handleKey, !1),
                  xe.call(
                    e,
                    i.container,
                    "mousemove mouseleave touchstart touchmove enterfullscreen exitfullscreen",
                    function (t) {
                      var a = i.controls;
                      a &&
                        "enterfullscreen" === t.type &&
                        ((a.pressed = !1), (a.hover = !1));
                      var s = 0;
                      ["touchstart", "touchmove", "mousemove"].includes(
                        t.type
                      ) &&
                        (yt.toggleControls.call(e, !0),
                          (s = e.touch ? 3e3 : 2e3)),
                        clearTimeout(n.controls),
                        (n.controls = setTimeout(function () {
                          return yt.toggleControls.call(e, !1);
                        }, s));
                    }
                  );
                var a = function (t) {
                  if (!t) return Re.call(e);
                  var n = i.container.getBoundingClientRect(),
                    a = n.width,
                    s = n.height;
                  return Re.call(e, "".concat(a, ":").concat(s));
                },
                  s = function () {
                    clearTimeout(n.resized), (n.resized = setTimeout(a, 50));
                  };
                xe.call(
                  e,
                  i.container,
                  "enterfullscreen exitfullscreen",
                  function (t) {
                    var n = e.fullscreen,
                      r = n.target,
                      l = n.usingNative;
                    if (
                      r === i.container &&
                      (e.isEmbed || !ae(e.config.ratio))
                    ) {
                      var c = "enterfullscreen" === t.type,
                        u = a(c);
                      u.padding;
                      !(function (t, i, n) {
                        if (e.isVimeo && !e.config.vimeo.premium) {
                          var a = e.elements.wrapper.firstChild,
                            s = o(t, 2)[1],
                            r = o(Fe.call(e), 2),
                            l = r[0],
                            c = r[1];
                          (a.style.maxWidth = n
                            ? "".concat((s / c) * l, "px")
                            : null),
                            (a.style.margin = n ? "0 auto" : null);
                        }
                      })(u.ratio, 0, c),
                        l ||
                        (c
                          ? xe.call(e, window, "resize", s)
                          : Ie.call(e, window, "resize", s));
                    }
                  }
                );
              },
            },
            {
              key: "media",
              value: function () {
                var e = this,
                  t = this.player,
                  i = t.elements;
                if (
                  (xe.call(
                    t,
                    t.media,
                    "timeupdate seeking seeked",
                    function (e) {
                      return nt.timeUpdate.call(t, e);
                    }
                  ),
                    xe.call(
                      t,
                      t.media,
                      "durationchange loadeddata loadedmetadata",
                      function (e) {
                        return nt.durationUpdate.call(t, e);
                      }
                    ),
                    xe.call(t, t.media, "ended", function () {
                      t.isHTML5 &&
                        t.isVideo &&
                        t.config.resetOnEnd &&
                        (t.restart(), t.pause());
                    }),
                    xe.call(
                      t,
                      t.media,
                      "progress playing seeking seeked",
                      function (e) {
                        return nt.updateProgress.call(t, e);
                      }
                    ),
                    xe.call(t, t.media, "volumechange", function (e) {
                      return nt.updateVolume.call(t, e);
                    }),
                    xe.call(
                      t,
                      t.media,
                      "playing play pause ended emptied timeupdate",
                      function (e) {
                        return yt.checkPlaying.call(t, e);
                      }
                    ),
                    xe.call(
                      t,
                      t.media,
                      "waiting canplay seeked playing",
                      function (e) {
                        return yt.checkLoading.call(t, e);
                      }
                    ),
                    t.supported.ui && t.config.clickToPlay && !t.isAudio)
                ) {
                  var n = Ce.call(t, ".".concat(t.config.classNames.video));
                  if (!G(n)) return;
                  xe.call(t, i.container, "click", function (a) {
                    ([i.container, n].includes(a.target) ||
                      n.contains(a.target)) &&
                      ((t.touch && t.config.hideControls) ||
                        (t.ended
                          ? (e.proxy(a, t.restart, "restart"),
                            e.proxy(
                              a,
                              function () {
                                qe(t.play());
                              },
                              "play"
                            ))
                          : e.proxy(
                            a,
                            function () {
                              qe(t.togglePlay());
                            },
                            "play"
                          )));
                  });
                }
                t.supported.ui &&
                  t.config.disableContextMenu &&
                  xe.call(
                    t,
                    i.wrapper,
                    "contextmenu",
                    function (e) {
                      e.preventDefault();
                    },
                    !1
                  ),
                  xe.call(t, t.media, "volumechange", function () {
                    t.storage.set({ volume: t.volume, muted: t.muted });
                  }),
                  xe.call(t, t.media, "ratechange", function () {
                    nt.updateSetting.call(t, "speed"),
                      t.storage.set({ speed: t.speed });
                  }),
                  xe.call(t, t.media, "qualitychange", function (e) {
                    nt.updateSetting.call(t, "quality", null, e.detail.quality);
                  }),
                  xe.call(t, t.media, "ready qualitychange", function () {
                    nt.setDownloadUrl.call(t);
                  });
                var a = t.config.events.concat(["keyup", "keydown"]).join(" ");
                xe.call(t, t.media, a, function (e) {
                  var n = e.detail,
                    a = void 0 === n ? {} : n;
                  "error" === e.type && (a = t.media.error),
                    Oe.call(t, i.container, e.type, !0, a);
                });
              },
            },
            {
              key: "proxy",
              value: function (e, t, i) {
                var n = this.player,
                  a = n.config.listeners[i],
                  s = !0;
                X(a) && (s = a.call(n, e)), !1 !== s && X(t) && t.call(n, e);
              },
            },
            {
              key: "bind",
              value: function (e, t, i, n) {
                var a = this,
                  s =
                    !(arguments.length > 4 && void 0 !== arguments[4]) ||
                    arguments[4],
                  r = this.player,
                  o = r.config.listeners[n],
                  l = X(o);
                xe.call(
                  r,
                  e,
                  t,
                  function (e) {
                    return a.proxy(e, i, n);
                  },
                  s && !l
                );
              },
            },
            {
              key: "controls",
              value: function () {
                var e = this,
                  t = this.player,
                  i = t.elements,
                  n = oe.isIE ? "change" : "input";
                if (
                  (i.buttons.play &&
                    Array.from(i.buttons.play).forEach(function (i) {
                      e.bind(
                        i,
                        "click",
                        function () {
                          qe(t.togglePlay());
                        },
                        "play"
                      );
                    }),
                    this.bind(i.buttons.restart, "click", t.restart, "restart"),
                    this.bind(i.buttons.rewind, "click", t.rewind, "rewind"),
                    this.bind(
                      i.buttons.fastForward,
                      "click",
                      t.forward,
                      "fastForward"
                    ),
                    this.bind(
                      i.buttons.mute,
                      "click",
                      function () {
                        t.muted = !t.muted;
                      },
                      "mute"
                    ),
                    this.bind(i.buttons.captions, "click", function () {
                      return t.toggleCaptions();
                    }),
                    this.bind(
                      i.buttons.download,
                      "click",
                      function () {
                        Oe.call(t, t.media, "download");
                      },
                      "download"
                    ),
                    this.bind(
                      i.buttons.fullscreen,
                      "click",
                      function () {
                        t.fullscreen.toggle();
                      },
                      "fullscreen"
                    ),
                    this.bind(
                      i.buttons.pip,
                      "click",
                      function () {
                        t.pip = "toggle";
                      },
                      "pip"
                    ),
                    this.bind(i.buttons.airplay, "click", t.airplay, "airplay"),
                    this.bind(
                      i.buttons.settings,
                      "click",
                      function (e) {
                        e.stopPropagation(),
                          e.preventDefault(),
                          nt.toggleMenu.call(t, e);
                      },
                      null,
                      !1
                    ),
                    this.bind(
                      i.buttons.settings,
                      "keyup",
                      function (e) {
                        var i = e.which;
                        [13, 32].includes(i) &&
                          (13 !== i
                            ? (e.preventDefault(),
                              e.stopPropagation(),
                              nt.toggleMenu.call(t, e))
                            : nt.focusFirstMenuItem.call(t, null, !0));
                      },
                      null,
                      !1
                    ),
                    this.bind(i.settings.menu, "keydown", function (e) {
                      27 === e.which && nt.toggleMenu.call(t, e);
                    }),
                    this.bind(i.inputs.seek, "mousedown mousemove", function (e) {
                      var t = i.progress.getBoundingClientRect(),
                        n = (100 / t.width) * (e.pageX - t.left);
                      e.currentTarget.setAttribute("seek-value", n);
                    }),
                    this.bind(
                      i.inputs.seek,
                      "mousedown mouseup keydown keyup touchstart touchend",
                      function (e) {
                        var i = e.currentTarget,
                          n = e.keyCode ? e.keyCode : e.which;
                        if (!ee(e) || 39 === n || 37 === n) {
                          t.lastSeekTime = Date.now();
                          var a = i.hasAttribute("play-on-seeked"),
                            s = ["mouseup", "touchend", "keyup"].includes(e.type);
                          a && s
                            ? (i.removeAttribute("play-on-seeked"), qe(t.play()))
                            : !s &&
                            t.playing &&
                            (i.setAttribute("play-on-seeked", ""), t.pause());
                        }
                      }
                    ),
                    oe.isIos)
                ) {
                  var a = Te.call(t, 'input[type="range"]');
                  Array.from(a).forEach(function (t) {
                    return e.bind(t, n, function (e) {
                      return re(e.target);
                    });
                  });
                }
                this.bind(
                  i.inputs.seek,
                  n,
                  function (e) {
                    var i = e.currentTarget,
                      n = i.getAttribute("seek-value");
                    ae(n) && (n = i.value),
                      i.removeAttribute("seek-value"),
                      (t.currentTime = (n / i.max) * t.duration);
                  },
                  "seek"
                ),
                  this.bind(
                    i.progress,
                    "mouseenter mouseleave mousemove",
                    function (e) {
                      return nt.updateSeekTooltip.call(t, e);
                    }
                  ),
                  this.bind(i.progress, "mousemove touchmove", function (e) {
                    var i = t.previewThumbnails;
                    i && i.loaded && i.startMove(e);
                  }),
                  this.bind(
                    i.progress,
                    "mouseleave touchend click",
                    function () {
                      var e = t.previewThumbnails;
                      e && e.loaded && e.endMove(!1, !0);
                    }
                  ),
                  this.bind(i.progress, "mousedown touchstart", function (e) {
                    var i = t.previewThumbnails;
                    i && i.loaded && i.startScrubbing(e);
                  }),
                  this.bind(i.progress, "mouseup touchend", function (e) {
                    var i = t.previewThumbnails;
                    i && i.loaded && i.endScrubbing(e);
                  }),
                  oe.isWebkit &&
                  Array.from(Te.call(t, 'input[type="range"]')).forEach(
                    function (i) {
                      e.bind(i, "input", function (e) {
                        return nt.updateRangeFill.call(t, e.target);
                      });
                    }
                  ),
                  t.config.toggleInvert &&
                  !G(i.display.duration) &&
                  this.bind(i.display.currentTime, "click", function () {
                    0 !== t.currentTime &&
                      ((t.config.invertTime = !t.config.invertTime),
                        nt.timeUpdate.call(t));
                  }),
                  this.bind(
                    i.inputs.volume,
                    n,
                    function (e) {
                      t.volume = e.target.value;
                    },
                    "volume"
                  ),
                  this.bind(i.controls, "mouseenter mouseleave", function (e) {
                    i.controls.hover = !t.touch && "mouseenter" === e.type;
                  }),
                  i.fullscreen &&
                  Array.from(i.fullscreen.children)
                    .filter(function (e) {
                      return !e.contains(i.container);
                    })
                    .forEach(function (n) {
                      e.bind(n, "mouseenter mouseleave", function (e) {
                        i.controls.hover =
                          !t.touch && "mouseenter" === e.type;
                      });
                    }),
                  this.bind(
                    i.controls,
                    "mousedown mouseup touchstart touchend touchcancel",
                    function (e) {
                      i.controls.pressed = ["mousedown", "touchstart"].includes(
                        e.type
                      );
                    }
                  ),
                  this.bind(i.controls, "focusin", function () {
                    var n = t.config,
                      a = t.timers;
                    be(i.controls, n.classNames.noTransition, !0),
                      yt.toggleControls.call(t, !0),
                      setTimeout(function () {
                        be(i.controls, n.classNames.noTransition, !1);
                      }, 0);
                    var s = e.touch ? 3e3 : 4e3;
                    clearTimeout(a.controls),
                      (a.controls = setTimeout(function () {
                        return yt.toggleControls.call(t, !1);
                      }, s));
                  }),
                  this.bind(
                    i.inputs.volume,
                    "wheel",
                    function (e) {
                      var i = e.webkitDirectionInvertedFromDevice,
                        n = o(
                          [e.deltaX, -e.deltaY].map(function (e) {
                            return i ? -e : e;
                          }),
                          2
                        ),
                        a = n[0],
                        s = n[1],
                        r = Math.sign(Math.abs(a) > Math.abs(s) ? a : s);
                      t.increaseVolume(r / 50);
                      var l = t.media.volume;
                      ((1 === r && l < 1) || (-1 === r && l > 0)) &&
                        e.preventDefault();
                    },
                    "volume",
                    !1
                  );
              },
            },
          ]),
          t
        );
      })();
    "undefined" != typeof globalThis
      ? globalThis
      : "undefined" != typeof window
        ? window
        : "undefined" != typeof global
          ? global
          : "undefined" != typeof self && self;
    var bt = (function (e, t) {
      return e((t = { exports: {} }), t.exports), t.exports;
    })(function (e, t) {
      e.exports = (function () {
        var e = function () { },
          t = {},
          i = {},
          n = {};
        function a(e, t) {
          if (e) {
            var a = n[e];
            if (((i[e] = t), a)) for (; a.length;) a[0](e, t), a.splice(0, 1);
          }
        }
        function s(t, i) {
          t.call && (t = { success: t }),
            i.length ? (t.error || e)(i) : (t.success || e)(t);
        }
        function r(t, i, n, a) {
          var s,
            o,
            l = document,
            c = n.async,
            u = (n.numRetries || 0) + 1,
            d = n.before || e,
            h = t.replace(/[\?|#].*$/, ""),
            p = t.replace(/^(css|img)!/, "");
          (a = a || 0),
            /(^css!|\.css$)/.test(h)
              ? (((o = l.createElement("link")).rel = "stylesheet"),
                (o.href = p),
                (s = "hideFocus" in o) &&
                o.relList &&
                ((s = 0), (o.rel = "preload"), (o.as = "style")))
              : /(^img!|\.(png|gif|jpg|svg|webp)$)/.test(h)
                ? ((o = l.createElement("img")).src = p)
                : (((o = l.createElement("script")).src = t),
                  (o.async = void 0 === c || c)),
            (o.onload =
              o.onerror =
              o.onbeforeload =
              function (e) {
                var l = e.type[0];
                if (s)
                  try {
                    o.sheet.cssText.length || (l = "e");
                  } catch (e) {
                    18 != e.code && (l = "e");
                  }
                if ("e" == l) {
                  if ((a += 1) < u) return r(t, i, n, a);
                } else if ("preload" == o.rel && "style" == o.as)
                  return (o.rel = "stylesheet");
                i(t, l, e.defaultPrevented);
              }),
            !1 !== d(t, o) && l.head.appendChild(o);
        }
        function o(e, i, n) {
          var o, l;
          if ((i && i.trim && (o = i), (l = (o ? n : i) || {}), o)) {
            if (o in t) throw "LoadJS";
            t[o] = !0;
          }
          function c(t, i) {
            !(function (e, t, i) {
              var n,
                a,
                s = (e = e.push ? e : [e]).length,
                o = s,
                l = [];
              for (
                n = function (e, i, n) {
                  if (("e" == i && l.push(e), "b" == i)) {
                    if (!n) return;
                    l.push(e);
                  }
                  --s || t(l);
                },
                a = 0;
                a < o;
                a++
              )
                r(e[a], n, i);
            })(
              e,
              function (e) {
                s(l, e), t && s({ success: t, error: i }, e), a(o, e);
              },
              l
            );
          }
          if (l.returnPromise) return new Promise(c);
          c();
        }
        return (
          (o.ready = function (e, t) {
            return (
              (function (e, t) {
                e = e.push ? e : [e];
                var a,
                  s,
                  r,
                  o = [],
                  l = e.length,
                  c = l;
                for (
                  a = function (e, i) {
                    i.length && o.push(e), --c || t(o);
                  };
                  l--;

                )
                  (s = e[l]),
                    (r = i[s]) ? a(s, r) : (n[s] = n[s] || []).push(a);
              })(e, function (e) {
                s(t, e);
              }),
              o
            );
          }),
          (o.done = function (e) {
            a(e, []);
          }),
          (o.reset = function () {
            (t = {}), (i = {}), (n = {});
          }),
          (o.isDefined = function (e) {
            return e in t;
          }),
          o
        );
      })();
    });
    function wt(e) {
      return new Promise(function (t, i) {
        bt(e, { success: t, error: i });
      });
    }
    function kt(e) {
      e && !this.embed.hasPlayed && (this.embed.hasPlayed = !0),
        this.media.paused === e &&
        ((this.media.paused = !e),
          Oe.call(this, this.media, e ? "play" : "pause"));
    }
    var Tt = {
      setup: function () {
        var e = this;
        be(e.elements.wrapper, e.config.classNames.embed, !0),
          (e.options.speed = e.config.speed.options),
          Re.call(e),
          z(window.Vimeo)
            ? Tt.ready.call(e)
            : wt(e.config.urls.vimeo.sdk)
              .then(function () {
                Tt.ready.call(e);
              })
              .catch(function (t) {
                e.debug.warn("Vimeo SDK (player.js) failed to load", t);
              });
      },
      ready: function () {
        var e = this,
          t = this,
          i = t.config.vimeo,
          n = i.premium,
          a = i.referrerPolicy,
          l = r(i, ["premium", "referrerPolicy"]);
        n && Object.assign(l, { controls: !1, sidedock: !1 });
        var c = st(
          s(
            {
              loop: t.config.loop.active,
              autoplay: t.autoplay,
              muted: t.muted,
              gesture: "media",
              playsinline: !this.config.fullscreen.iosNative,
            },
            l
          )
        ),
          u = t.media.getAttribute("src");
        ae(u) && (u = t.media.getAttribute(t.config.attributes.embed.id));
        var d,
          h = ae((d = u))
            ? null
            : K(Number(d))
              ? d
              : d.match(/^.*(vimeo.com\/|video\/)(\d+).*/)
                ? RegExp.$2
                : d,
          p = he("iframe"),
          m = Ue(t.config.urls.vimeo.iframe, h, c);
        p.setAttribute("src", m),
          p.setAttribute("allowfullscreen", ""),
          p.setAttribute("allow", "autoplay,fullscreen,picture-in-picture"),
          ae(a) || p.setAttribute("referrerPolicy", a);
        var f = t.poster;
        if (n) p.setAttribute("data-poster", f), (t.media = ge(p, t.media));
        else {
          var g = he("div", {
            class: t.config.classNames.embedContainer,
            "data-poster": f,
          });
          g.appendChild(p), (t.media = ge(g, t.media));
        }
        Je(Ue(t.config.urls.vimeo.api, h), "json").then(function (e) {
          if (!ae(e)) {
            var i = new URL(e[0].thumbnail_large);
            (i.pathname = "".concat(i.pathname.split("_")[0], ".jpg")),
              yt.setPoster.call(t, i.href).catch(function () { });
          }
        }),
          (t.embed = new window.Vimeo.Player(p, {
            autopause: t.config.autopause,
            muted: t.muted,
          })),
          (t.media.paused = !0),
          (t.media.currentTime = 0),
          t.supported.ui && t.embed.disableTextTrack(),
          (t.media.play = function () {
            return kt.call(t, !0), t.embed.play();
          }),
          (t.media.pause = function () {
            return kt.call(t, !1), t.embed.pause();
          }),
          (t.media.stop = function () {
            t.pause(), (t.currentTime = 0);
          });
        var y = t.media.currentTime;
        Object.defineProperty(t.media, "currentTime", {
          get: function () {
            return y;
          },
          set: function (e) {
            var i = t.embed,
              n = t.media,
              a = t.paused,
              s = t.volume,
              r = a && !i.hasPlayed;
            (n.seeking = !0),
              Oe.call(t, n, "seeking"),
              Promise.resolve(r && i.setVolume(0))
                .then(function () {
                  return i.setCurrentTime(e);
                })
                .then(function () {
                  return r && i.pause();
                })
                .then(function () {
                  return r && i.setVolume(s);
                })
                .catch(function () { });
          },
        });
        var v = t.config.speed.selected;
        Object.defineProperty(t.media, "playbackRate", {
          get: function () {
            return v;
          },
          set: function (e) {
            t.embed
              .setPlaybackRate(e)
              .then(function () {
                (v = e), Oe.call(t, t.media, "ratechange");
              })
              .catch(function () {
                t.options.speed = [1];
              });
          },
        });
        var b = t.config.volume;
        Object.defineProperty(t.media, "volume", {
          get: function () {
            return b;
          },
          set: function (e) {
            t.embed.setVolume(e).then(function () {
              (b = e), Oe.call(t, t.media, "volumechange");
            });
          },
        });
        var w = t.config.muted;
        Object.defineProperty(t.media, "muted", {
          get: function () {
            return w;
          },
          set: function (e) {
            var i = !!Q(e) && e;
            t.embed.setVolume(i ? 0 : t.config.volume).then(function () {
              (w = i), Oe.call(t, t.media, "volumechange");
            });
          },
        });
        var k,
          T = t.config.loop;
        Object.defineProperty(t.media, "loop", {
          get: function () {
            return T;
          },
          set: function (e) {
            var i = Q(e) ? e : t.config.loop.active;
            t.embed.setLoop(i).then(function () {
              T = i;
            });
          },
        }),
          t.embed
            .getVideoUrl()
            .then(function (e) {
              (k = e), nt.setDownloadUrl.call(t);
            })
            .catch(function (t) {
              e.debug.warn(t);
            }),
          Object.defineProperty(t.media, "currentSrc", {
            get: function () {
              return k;
            },
          }),
          Object.defineProperty(t.media, "ended", {
            get: function () {
              return t.currentTime === t.duration;
            },
          }),
          Promise.all([t.embed.getVideoWidth(), t.embed.getVideoHeight()]).then(
            function (i) {
              var n = o(i, 2),
                a = n[0],
                s = n[1];
              (t.embed.ratio = [a, s]), Re.call(e);
            }
          ),
          t.embed.setAutopause(t.config.autopause).then(function (e) {
            t.config.autopause = e;
          }),
          t.embed.getVideoTitle().then(function (i) {
            (t.config.title = i), yt.setTitle.call(e);
          }),
          t.embed.getCurrentTime().then(function (e) {
            (y = e), Oe.call(t, t.media, "timeupdate");
          }),
          t.embed.getDuration().then(function (e) {
            (t.media.duration = e), Oe.call(t, t.media, "durationchange");
          }),
          t.embed.getTextTracks().then(function (e) {
            (t.media.textTracks = e), rt.setup.call(t);
          }),
          t.embed.on("cuechange", function (e) {
            var i = e.cues,
              n = (void 0 === i ? [] : i).map(function (e) {
                return (function (e) {
                  var t = document.createDocumentFragment(),
                    i = document.createElement("div");
                  return (
                    t.appendChild(i), (i.innerHTML = e), t.firstChild.innerText
                  );
                })(e.text);
              });
            rt.updateCues.call(t, n);
          }),
          t.embed.on("loaded", function () {
            (t.embed.getPaused().then(function (e) {
              kt.call(t, !e), e || Oe.call(t, t.media, "playing");
            }),
              G(t.embed.element) && t.supported.ui) &&
              t.embed.element.setAttribute("tabindex", -1);
          }),
          t.embed.on("bufferstart", function () {
            Oe.call(t, t.media, "waiting");
          }),
          t.embed.on("bufferend", function () {
            Oe.call(t, t.media, "playing");
          }),
          t.embed.on("play", function () {
            kt.call(t, !0), Oe.call(t, t.media, "playing");
          }),
          t.embed.on("pause", function () {
            kt.call(t, !1);
          }),
          t.embed.on("timeupdate", function (e) {
            (t.media.seeking = !1),
              (y = e.seconds),
              Oe.call(t, t.media, "timeupdate");
          }),
          t.embed.on("progress", function (e) {
            (t.media.buffered = e.percent),
              Oe.call(t, t.media, "progress"),
              1 === parseInt(e.percent, 10) &&
              Oe.call(t, t.media, "canplaythrough"),
              t.embed.getDuration().then(function (e) {
                e !== t.media.duration &&
                  ((t.media.duration = e),
                    Oe.call(t, t.media, "durationchange"));
              });
          }),
          t.embed.on("seeked", function () {
            (t.media.seeking = !1), Oe.call(t, t.media, "seeked");
          }),
          t.embed.on("ended", function () {
            (t.media.paused = !0), Oe.call(t, t.media, "ended");
          }),
          t.embed.on("error", function (e) {
            (t.media.error = e), Oe.call(t, t.media, "error");
          }),
          setTimeout(function () {
            return yt.build.call(t);
          }, 0);
      },
    };
    function Ct(e) {
      e && !this.embed.hasPlayed && (this.embed.hasPlayed = !0),
        this.media.paused === e &&
        ((this.media.paused = !e),
          Oe.call(this, this.media, e ? "play" : "pause"));
    }
    function At(e) {
      return e.noCookie
        ? "https://www.youtube-nocookie.com"
        : "http:" === window.location.protocol
          ? "http://www.youtube.com"
          : void 0;
    }
    var St = {
      setup: function () {
        var e = this;
        if (
          (be(this.elements.wrapper, this.config.classNames.embed, !0),
            z(window.YT) && X(window.YT.Player))
        )
          St.ready.call(this);
        else {
          var t = window.onYouTubeIframeAPIReady;
          (window.onYouTubeIframeAPIReady = function () {
            X(t) && t(), St.ready.call(e);
          }),
            wt(this.config.urls.youtube.sdk).catch(function (t) {
              e.debug.warn("YouTube API failed to load", t);
            });
        }
      },
      getTitle: function (e) {
        var t = this;
        Je(Ue(this.config.urls.youtube.api, e))
          .then(function (e) {
            if (z(e)) {
              var i = e.title,
                n = e.height,
                a = e.width;
              (t.config.title = i),
                yt.setTitle.call(t),
                (t.embed.ratio = [a, n]);
            }
            Re.call(t);
          })
          .catch(function () {
            Re.call(t);
          });
      },
      ready: function () {
        var e = this,
          t = e.media && e.media.getAttribute("id");
        if (ae(t) || !t.startsWith("youtube-")) {
          var i = e.media.getAttribute("src");
          ae(i) &&
            (i = e.media.getAttribute(this.config.attributes.embed.id));
          var n,
            a,
            s = ae((n = i))
              ? null
              : n.match(
                /^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|&v=)([^#&?]*).*/
              )
                ? RegExp.$2
                : n,
            r =
              ((a = e.provider),
                "".concat(a, "-").concat(Math.floor(1e4 * Math.random()))),
            o = he("div", { id: r, "data-poster": e.poster });
          e.media = ge(o, e.media);
          var l = function (e) {
            return "https://i.ytimg.com/vi/"
              .concat(s, "/")
              .concat(e, "default.jpg");
          };
          gt(l("maxres"), 121)
            .catch(function () {
              return gt(l("sd"), 121);
            })
            .catch(function () {
              return gt(l("hq"));
            })
            .then(function (t) {
              return yt.setPoster.call(e, t.src);
            })
            .then(function (t) {
              t.includes("maxres") ||
                (e.elements.poster.style.backgroundSize = "cover");
            })
            .catch(function () { });
          var c = e.config.youtube;
          e.embed = new window.YT.Player(r, {
            videoId: s,
            host: At(c),
            playerVars: ce(
              {},
              {
                autoplay: e.config.autoplay ? 1 : 0,
                hl: e.config.hl,
                controls: e.supported.ui ? 0 : 1,
                disablekb: 1,
                playsinline: e.config.fullscreen.iosNative ? 0 : 1,
                cc_load_policy: e.captions.active ? 1 : 0,
                cc_lang_pref: e.config.captions.language,
                widget_referrer: window ? window.location.href : null,
              },
              c
            ),
            events: {
              onError: function (t) {
                if (!e.media.error) {
                  var i = t.data,
                    n =
                      {
                        2: "The request contains an invalid parameter value. For example, this error occurs if you specify a video ID that does not have 11 characters, or if the video ID contains invalid characters, such as exclamation points or asterisks.",
                        5: "The requested content cannot be played in an HTML5 player or another error related to the HTML5 player has occurred.",
                        100: "The video requested was not found. This error occurs when a video has been removed (for any reason) or has been marked as private.",
                        101: "The owner of the requested video does not allow it to be played in embedded players.",
                        150: "The owner of the requested video does not allow it to be played in embedded players.",
                      }[i] || "An unknown error occured";
                  (e.media.error = { code: i, message: n }),
                    Oe.call(e, e.media, "error");
                }
              },
              onPlaybackRateChange: function (t) {
                var i = t.target;
                (e.media.playbackRate = i.getPlaybackRate()),
                  Oe.call(e, e.media, "ratechange");
              },
              onReady: function (t) {
                if (!X(e.media.play)) {
                  var i = t.target;
                  St.getTitle.call(e, s),
                    (e.media.play = function () {
                      Ct.call(e, !0), i.playVideo();
                    }),
                    (e.media.pause = function () {
                      Ct.call(e, !1), i.pauseVideo();
                    }),
                    (e.media.stop = function () {
                      i.stopVideo();
                    }),
                    (e.media.duration = i.getDuration()),
                    (e.media.paused = !0),
                    (e.media.currentTime = 0),
                    Object.defineProperty(e.media, "currentTime", {
                      get: function () {
                        return Number(i.getCurrentTime());
                      },
                      set: function (t) {
                        e.paused && !e.embed.hasPlayed && e.embed.mute(),
                          (e.media.seeking = !0),
                          Oe.call(e, e.media, "seeking"),
                          i.seekTo(t);
                      },
                    }),
                    Object.defineProperty(e.media, "playbackRate", {
                      get: function () {
                        return i.getPlaybackRate();
                      },
                      set: function (e) {
                        i.setPlaybackRate(e);
                      },
                    });
                  var n = e.config.volume;
                  Object.defineProperty(e.media, "volume", {
                    get: function () {
                      return n;
                    },
                    set: function (t) {
                      (n = t),
                        i.setVolume(100 * n),
                        Oe.call(e, e.media, "volumechange");
                    },
                  });
                  var a = e.config.muted;
                  Object.defineProperty(e.media, "muted", {
                    get: function () {
                      return a;
                    },
                    set: function (t) {
                      var n = Q(t) ? t : a;
                      (a = n),
                        i[n ? "mute" : "unMute"](),
                        Oe.call(e, e.media, "volumechange");
                    },
                  }),
                    Object.defineProperty(e.media, "currentSrc", {
                      get: function () {
                        return i.getVideoUrl();
                      },
                    }),
                    Object.defineProperty(e.media, "ended", {
                      get: function () {
                        return e.currentTime === e.duration;
                      },
                    });
                  var r = i.getAvailablePlaybackRates();
                  (e.options.speed = r.filter(function (t) {
                    return e.config.speed.options.includes(t);
                  })),
                    e.supported.ui && e.media.setAttribute("tabindex", -1),
                    Oe.call(e, e.media, "timeupdate"),
                    Oe.call(e, e.media, "durationchange"),
                    clearInterval(e.timers.buffering),
                    (e.timers.buffering = setInterval(function () {
                      (e.media.buffered = i.getVideoLoadedFraction()),
                        (null === e.media.lastBuffered ||
                          e.media.lastBuffered < e.media.buffered) &&
                        Oe.call(e, e.media, "progress"),
                        (e.media.lastBuffered = e.media.buffered),
                        1 === e.media.buffered &&
                        (clearInterval(e.timers.buffering),
                          Oe.call(e, e.media, "canplaythrough"));
                    }, 200)),
                    setTimeout(function () {
                      return yt.build.call(e);
                    }, 50);
                }
              },
              onStateChange: function (t) {
                var i = t.target;
                switch (
                (clearInterval(e.timers.playing),
                  e.media.seeking &&
                  [1, 2].includes(t.data) &&
                  ((e.media.seeking = !1), Oe.call(e, e.media, "seeked")),
                  t.data)
                ) {
                  case -1:
                    Oe.call(e, e.media, "timeupdate"),
                      (e.media.buffered = i.getVideoLoadedFraction()),
                      Oe.call(e, e.media, "progress");
                    break;
                  case 0:
                    Ct.call(e, !1),
                      e.media.loop
                        ? (i.stopVideo(), i.playVideo())
                        : Oe.call(e, e.media, "ended");
                    break;
                  case 1:
                    e.config.autoplay || !e.media.paused || e.embed.hasPlayed
                      ? (Ct.call(e, !0),
                        Oe.call(e, e.media, "playing"),
                        (e.timers.playing = setInterval(function () {
                          Oe.call(e, e.media, "timeupdate");
                        }, 50)),
                        e.media.duration !== i.getDuration() &&
                        ((e.media.duration = i.getDuration()),
                          Oe.call(e, e.media, "durationchange")))
                      : e.media.pause();
                    break;
                  case 2:
                    e.muted || e.embed.unMute(), Ct.call(e, !1);
                    break;
                  case 3:
                    Oe.call(e, e.media, "waiting");
                }
                Oe.call(e, e.elements.container, "statechange", !1, {
                  code: t.data,
                });
              },
            },
          });
        }
      },
    },
      Pt = {
        setup: function () {
          this.media
            ? (be(
              this.elements.container,
              this.config.classNames.type.replace("{0}", this.type),
              !0
            ),
              be(
                this.elements.container,
                this.config.classNames.provider.replace("{0}", this.provider),
                !0
              ),
              this.isEmbed &&
              be(
                this.elements.container,
                this.config.classNames.type.replace("{0}", "video"),
                !0
              ),
              this.isVideo &&
              ((this.elements.wrapper = he("div", {
                class: this.config.classNames.video,
              })),
                ue(this.media, this.elements.wrapper),
                (this.elements.poster = he("div", {
                  class: this.config.classNames.poster,
                })),
                this.elements.wrapper.appendChild(this.elements.poster)),
              this.isHTML5
                ? Ve.setup.call(this)
                : this.isYouTube
                  ? St.setup.call(this)
                  : this.isVimeo && Tt.setup.call(this))
            : this.debug.warn("No media element found!");
        },
      },
      Et = (function () {
        function t(i) {
          var n = this;
          e(this, t),
            (this.player = i),
            (this.config = i.config.ads),
            (this.playing = !1),
            (this.initialized = !1),
            (this.elements = { container: null, displayContainer: null }),
            (this.manager = null),
            (this.loader = null),
            (this.cuePoints = null),
            (this.events = {}),
            (this.safetyTimer = null),
            (this.countdownTimer = null),
            (this.managerPromise = new Promise(function (e, t) {
              n.on("loaded", e), n.on("error", t);
            })),
            this.load();
        }
        return (
          i(t, [
            {
              key: "load",
              value: function () {
                var e = this;
                this.enabled &&
                  (z(window.google) && z(window.google.ima)
                    ? this.ready()
                    : wt(this.player.config.urls.googleIMA.sdk)
                      .then(function () {
                        e.ready();
                      })
                      .catch(function () {
                        e.trigger(
                          "error",
                          new Error("Google IMA SDK failed to load")
                        );
                      }));
              },
            },
            {
              key: "ready",
              value: function () {
                var e,
                  t = this;
                this.enabled ||
                  ((e = this).manager && e.manager.destroy(),
                    e.elements.displayContainer &&
                    e.elements.displayContainer.destroy(),
                    e.elements.container.remove()),
                  this.startSafetyTimer(12e3, "ready()"),
                  this.managerPromise.then(function () {
                    t.clearSafetyTimer("onAdsManagerLoaded()");
                  }),
                  this.listeners(),
                  this.setupIMA();
              },
            },
            {
              key: "setupIMA",
              value: function () {
                var e = this;
                (this.elements.container = he("div", {
                  class: this.player.config.classNames.ads,
                })),
                  this.player.elements.container.appendChild(
                    this.elements.container
                  ),
                  google.ima.settings.setVpaidMode(
                    google.ima.ImaSdkSettings.VpaidMode.ENABLED
                  ),
                  google.ima.settings.setLocale(
                    this.player.config.ads.language
                  ),
                  google.ima.settings.setDisableCustomPlaybackForIOS10Plus(
                    this.player.config.playsinline
                  ),
                  (this.elements.displayContainer =
                    new google.ima.AdDisplayContainer(
                      this.elements.container,
                      this.player.media
                    )),
                  (this.loader = new google.ima.AdsLoader(
                    this.elements.displayContainer
                  )),
                  this.loader.addEventListener(
                    google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,
                    function (t) {
                      return e.onAdsManagerLoaded(t);
                    },
                    !1
                  ),
                  this.loader.addEventListener(
                    google.ima.AdErrorEvent.Type.AD_ERROR,
                    function (t) {
                      return e.onAdError(t);
                    },
                    !1
                  ),
                  this.requestAds();
              },
            },
            {
              key: "requestAds",
              value: function () {
                var e = this.player.elements.container;
                try {
                  var t = new google.ima.AdsRequest();
                  (t.adTagUrl = this.tagUrl),
                    (t.linearAdSlotWidth = e.offsetWidth),
                    (t.linearAdSlotHeight = e.offsetHeight),
                    (t.nonLinearAdSlotWidth = e.offsetWidth),
                    (t.nonLinearAdSlotHeight = e.offsetHeight),
                    (t.forceNonLinearFullSlot = !1),
                    t.setAdWillPlayMuted(!this.player.muted),
                    this.loader.requestAds(t);
                } catch (e) {
                  this.onAdError(e);
                }
              },
            },
            {
              key: "pollCountdown",
              value: function () {
                var e = this,
                  t =
                    arguments.length > 0 &&
                    void 0 !== arguments[0] &&
                    arguments[0];
                if (!t)
                  return (
                    clearInterval(this.countdownTimer),
                    void this.elements.container.removeAttribute(
                      "data-badge-text"
                    )
                  );
                var i = function () {
                  var t = it(Math.max(e.manager.getRemainingTime(), 0)),
                    i = ""
                      .concat(Xe("advertisement", e.player.config), " - ")
                      .concat(t);
                  e.elements.container.setAttribute("data-badge-text", i);
                };
                this.countdownTimer = setInterval(i, 100);
              },
            },
            {
              key: "onAdsManagerLoaded",
              value: function (e) {
                var t = this;
                if (this.enabled) {
                  var i = new google.ima.AdsRenderingSettings();
                  (i.restoreCustomPlaybackStateOnAdBreakComplete = !0),
                    (i.enablePreloading = !0),
                    (this.manager = e.getAdsManager(this.player, i)),
                    (this.cuePoints = this.manager.getCuePoints()),
                    this.manager.addEventListener(
                      google.ima.AdErrorEvent.Type.AD_ERROR,
                      function (e) {
                        return t.onAdError(e);
                      }
                    ),
                    Object.keys(google.ima.AdEvent.Type).forEach(function (e) {
                      t.manager.addEventListener(
                        google.ima.AdEvent.Type[e],
                        function (e) {
                          return t.onAdEvent(e);
                        }
                      );
                    }),
                    this.trigger("loaded");
                }
              },
            },
            {
              key: "addCuePoints",
              value: function () {
                var e = this;
                ae(this.cuePoints) ||
                  this.cuePoints.forEach(function (t) {
                    if (0 !== t && -1 !== t && t < e.player.duration) {
                      var i = e.player.elements.progress;
                      if (G(i)) {
                        var n = (100 / e.player.duration) * t,
                          a = he("span", {
                            class: e.player.config.classNames.cues,
                          });
                        (a.style.left = "".concat(n.toString(), "%")),
                          i.appendChild(a);
                      }
                    }
                  });
              },
            },
            {
              key: "onAdEvent",
              value: function (e) {
                var t = this,
                  i = this.player.elements.container,
                  n = e.getAd(),
                  a = e.getAdData();
                switch (
                ((function (e) {
                  Oe.call(
                    t.player,
                    t.player.media,
                    "ads".concat(e.replace(/_/g, "").toLowerCase())
                  );
                })(e.type),
                  e.type)
                ) {
                  case google.ima.AdEvent.Type.LOADED:
                    this.trigger("loaded"),
                      this.pollCountdown(!0),
                      n.isLinear() ||
                      ((n.width = i.offsetWidth),
                        (n.height = i.offsetHeight));
                    break;
                  case google.ima.AdEvent.Type.STARTED:
                    this.manager.setVolume(this.player.volume);
                    break;
                  case google.ima.AdEvent.Type.ALL_ADS_COMPLETED:
                    this.player.ended
                      ? this.loadAds()
                      : this.loader.contentComplete();
                    break;
                  case google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED:
                    this.pauseContent();
                    break;
                  case google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED:
                    this.pollCountdown(), this.resumeContent();
                    break;
                  case google.ima.AdEvent.Type.LOG:
                    a.adError &&
                      this.player.debug.warn(
                        "Non-fatal ad error: ".concat(a.adError.getMessage())
                      );
                }
              },
            },
            {
              key: "onAdError",
              value: function (e) {
                this.cancel(), this.player.debug.warn("Ads error", e);
              },
            },
            {
              key: "listeners",
              value: function () {
                var e,
                  t = this,
                  i = this.player.elements.container;
                this.player.on("canplay", function () {
                  t.addCuePoints();
                }),
                  this.player.on("ended", function () {
                    t.loader.contentComplete();
                  }),
                  this.player.on("timeupdate", function () {
                    e = t.player.currentTime;
                  }),
                  this.player.on("seeked", function () {
                    var i = t.player.currentTime;
                    ae(t.cuePoints) ||
                      t.cuePoints.forEach(function (n, a) {
                        e < n &&
                          n < i &&
                          (t.manager.discardAdBreak(),
                            t.cuePoints.splice(a, 1));
                      });
                  }),
                  window.addEventListener("resize", function () {
                    t.manager &&
                      t.manager.resize(
                        i.offsetWidth,
                        i.offsetHeight,
                        google.ima.ViewMode.NORMAL
                      );
                  });
              },
            },
            {
              key: "play",
              value: function () {
                var e = this,
                  t = this.player.elements.container;
                this.managerPromise || this.resumeContent(),
                  this.managerPromise
                    .then(function () {
                      e.manager.setVolume(e.player.volume),
                        e.elements.displayContainer.initialize();
                      try {
                        e.initialized ||
                          (e.manager.init(
                            t.offsetWidth,
                            t.offsetHeight,
                            google.ima.ViewMode.NORMAL
                          ),
                            e.manager.start()),
                          (e.initialized = !0);
                      } catch (t) {
                        e.onAdError(t);
                      }
                    })
                    .catch(function () { });
              },
            },
            {
              key: "resumeContent",
              value: function () {
                (this.elements.container.style.zIndex = ""),
                  (this.playing = !1),
                  qe(this.player.media.play());
              },
            },
            {
              key: "pauseContent",
              value: function () {
                (this.elements.container.style.zIndex = 3),
                  (this.playing = !0),
                  this.player.media.pause();
              },
            },
            {
              key: "cancel",
              value: function () {
                this.initialized && this.resumeContent(),
                  this.trigger("error"),
                  this.loadAds();
              },
            },
            {
              key: "loadAds",
              value: function () {
                var e = this;
                this.managerPromise
                  .then(function () {
                    e.manager && e.manager.destroy(),
                      (e.managerPromise = new Promise(function (t) {
                        e.on("loaded", t), e.player.debug.log(e.manager);
                      })),
                      (e.initialized = !1),
                      e.requestAds();
                  })
                  .catch(function () { });
              },
            },
            {
              key: "trigger",
              value: function (e) {
                for (
                  var t = this,
                  i = arguments.length,
                  n = new Array(i > 1 ? i - 1 : 0),
                  a = 1;
                  a < i;
                  a++
                )
                  n[a - 1] = arguments[a];
                var s = this.events[e];
                $(s) &&
                  s.forEach(function (e) {
                    X(e) && e.apply(t, n);
                  });
              },
            },
            {
              key: "on",
              value: function (e, t) {
                return (
                  $(this.events[e]) || (this.events[e] = []),
                  this.events[e].push(t),
                  this
                );
              },
            },
            {
              key: "startSafetyTimer",
              value: function (e, t) {
                var i = this;
                this.player.debug.log("Safety timer invoked from: ".concat(t)),
                  (this.safetyTimer = setTimeout(function () {
                    i.cancel(), i.clearSafetyTimer("startSafetyTimer()");
                  }, e));
              },
            },
            {
              key: "clearSafetyTimer",
              value: function (e) {
                W(this.safetyTimer) ||
                  (this.player.debug.log(
                    "Safety timer cleared from: ".concat(e)
                  ),
                    clearTimeout(this.safetyTimer),
                    (this.safetyTimer = null));
              },
            },
            {
              key: "enabled",
              get: function () {
                var e = this.config;
                return (
                  this.player.isHTML5 &&
                  this.player.isVideo &&
                  e.enabled &&
                  (!ae(e.publisherId) || ne(e.tagUrl))
                );
              },
            },
            {
              key: "tagUrl",
              get: function () {
                var e = this.config;
                if (ne(e.tagUrl)) return e.tagUrl;
                var t = {
                  AV_PUBLISHERID: "58c25bb0073ef448b1087ad6",
                  AV_CHANNELID: "5a0458dc28a06145e4519d21",
                  AV_URL: window.location.hostname,
                  cb: Date.now(),
                  AV_WIDTH: 640,
                  AV_HEIGHT: 480,
                  AV_CDIM2: e.publisherId,
                };
                return ""
                  .concat("https://go.aniview.com/api/adserver6/vast/", "?")
                  .concat(st(t));
              },
            },
          ]),
          t
        );
      })(),
      Mt = function (e, t) {
        var i = {};
        return (
          e > t.width / t.height
            ? ((i.width = t.width), (i.height = (1 / e) * t.width))
            : ((i.height = t.height), (i.width = e * t.height)),
          i
        );
      },
      Nt = (function () {
        function t(i) {
          e(this, t),
            (this.player = i),
            (this.thumbnails = []),
            (this.loaded = !1),
            (this.lastMouseMoveTime = Date.now()),
            (this.mouseDown = !1),
            (this.loadedImages = []),
            (this.elements = { thumb: {}, scrubbing: {} }),
            this.load();
        }
        return (
          i(t, [
            {
              key: "load",
              value: function () {
                var e = this;
                this.player.elements.display.seekTooltip &&
                  (this.player.elements.display.seekTooltip.hidden =
                    this.enabled),
                  this.enabled &&
                  this.getThumbnails().then(function () {
                    e.enabled &&
                      (e.render(),
                        e.determineContainerAutoSizing(),
                        (e.loaded = !0));
                  });
              },
            },
            {
              key: "getThumbnails",
              value: function () {
                var e = this;
                return new Promise(function (t) {
                  var i = e.player.config.previewThumbnails.src;
                  if (ae(i))
                    throw new Error(
                      "Missing previewThumbnails.src config attribute"
                    );
                  var n = function () {
                    e.thumbnails.sort(function (e, t) {
                      return e.height - t.height;
                    }),
                      e.player.debug.log("Preview thumbnails", e.thumbnails),
                      t();
                  };
                  if (X(i))
                    i(function (t) {
                      (e.thumbnails = t), n();
                    });
                  else {
                    var a = (Y(i) ? [i] : i).map(function (t) {
                      return e.getThumbnail(t);
                    });
                    Promise.all(a).then(n);
                  }
                });
              },
            },
            {
              key: "getThumbnail",
              value: function (e) {
                var t = this;
                return new Promise(function (i) {
                  Je(e).then(function (n) {
                    var a,
                      s,
                      r = {
                        frames:
                          ((a = n),
                            (s = []),
                            a.split(/\r\n\r\n|\n\n|\r\r/).forEach(function (e) {
                              var t = {};
                              e.split(/\r\n|\n|\r/).forEach(function (e) {
                                if (K(t.startTime)) {
                                  if (!ae(e.trim()) && ae(t.text)) {
                                    var i = e.trim().split("#xywh="),
                                      n = o(i, 1);
                                    if (((t.text = n[0]), i[1])) {
                                      var a = o(i[1].split(","), 4);
                                      (t.x = a[0]),
                                        (t.y = a[1]),
                                        (t.w = a[2]),
                                        (t.h = a[3]);
                                    }
                                  }
                                } else {
                                  var s = e.match(
                                    /([0-9]{2})?:?([0-9]{2}):([0-9]{2}).([0-9]{2,3})( ?--> ?)([0-9]{2})?:?([0-9]{2}):([0-9]{2}).([0-9]{2,3})/
                                  );
                                  s &&
                                    ((t.startTime =
                                      60 * Number(s[1] || 0) * 60 +
                                      60 * Number(s[2]) +
                                      Number(s[3]) +
                                      Number("0.".concat(s[4]))),
                                      (t.endTime =
                                        60 * Number(s[6] || 0) * 60 +
                                        60 * Number(s[7]) +
                                        Number(s[8]) +
                                        Number("0.".concat(s[9]))));
                                }
                              }),
                                t.text && s.push(t);
                            }),
                            s),
                        height: null,
                        urlPrefix: "",
                      };
                    r.frames[0].text.startsWith("/") ||
                      r.frames[0].text.startsWith("http://") ||
                      r.frames[0].text.startsWith("https://") ||
                      (r.urlPrefix = e.substring(0, e.lastIndexOf("/") + 1));
                    var l = new Image();
                    (l.onload = function () {
                      (r.height = l.naturalHeight),
                        (r.width = l.naturalWidth),
                        t.thumbnails.push(r),
                        i();
                    }),
                      (l.src = r.urlPrefix + r.frames[0].text);
                  });
                });
              },
            },
            {
              key: "startMove",
              value: function (e) {
                if (
                  this.loaded &&
                  Z(e) &&
                  ["touchmove", "mousemove"].includes(e.type) &&
                  this.player.media.duration
                ) {
                  if ("touchmove" === e.type)
                    this.seekTime =
                      this.player.media.duration *
                      (this.player.elements.inputs.seek.value / 100);
                  else {
                    var t =
                      this.player.elements.progress.getBoundingClientRect(),
                      i = (100 / t.width) * (e.pageX - t.left);
                    (this.seekTime = this.player.media.duration * (i / 100)),
                      this.seekTime < 0 && (this.seekTime = 0),
                      this.seekTime > this.player.media.duration - 1 &&
                      (this.seekTime = this.player.media.duration - 1),
                      (this.mousePosX = e.pageX),
                      (this.elements.thumb.time.innerText = it(this.seekTime));
                  }
                  this.showImageAtCurrentTime();
                }
              },
            },
            {
              key: "endMove",
              value: function () {
                this.toggleThumbContainer(!1, !0);
              },
            },
            {
              key: "startScrubbing",
              value: function (e) {
                (W(e.button) || !1 === e.button || 0 === e.button) &&
                  ((this.mouseDown = !0),
                    this.player.media.duration &&
                    (this.toggleScrubbingContainer(!0),
                      this.toggleThumbContainer(!1, !0),
                      this.showImageAtCurrentTime()));
              },
            },
            {
              key: "endScrubbing",
              value: function () {
                var e = this;
                (this.mouseDown = !1),
                  Math.ceil(this.lastTime) ===
                    Math.ceil(this.player.media.currentTime)
                    ? this.toggleScrubbingContainer(!1)
                    : Le.call(
                      this.player,
                      this.player.media,
                      "timeupdate",
                      function () {
                        e.mouseDown || e.toggleScrubbingContainer(!1);
                      }
                    );
              },
            },
            {
              key: "listeners",
              value: function () {
                var e = this;
                this.player.on("play", function () {
                  e.toggleThumbContainer(!1, !0);
                }),
                  this.player.on("seeked", function () {
                    e.toggleThumbContainer(!1);
                  }),
                  this.player.on("timeupdate", function () {
                    e.lastTime = e.player.media.currentTime;
                  });
              },
            },
            {
              key: "render",
              value: function () {
                (this.elements.thumb.container = he("div", {
                  class:
                    this.player.config.classNames.previewThumbnails
                      .thumbContainer,
                })),
                  (this.elements.thumb.imageContainer = he("div", {
                    class:
                      this.player.config.classNames.previewThumbnails
                        .imageContainer,
                  })),
                  this.elements.thumb.container.appendChild(
                    this.elements.thumb.imageContainer
                  );
                var e = he("div", {
                  class:
                    this.player.config.classNames.previewThumbnails
                      .timeContainer,
                });
                (this.elements.thumb.time = he("span", {}, "00:00")),
                  e.appendChild(this.elements.thumb.time),
                  this.elements.thumb.container.appendChild(e),
                  G(this.player.elements.progress) &&
                  this.player.elements.progress.appendChild(
                    this.elements.thumb.container
                  ),
                  (this.elements.scrubbing.container = he("div", {
                    class:
                      this.player.config.classNames.previewThumbnails
                        .scrubbingContainer,
                  })),
                  this.player.elements.wrapper.appendChild(
                    this.elements.scrubbing.container
                  );
              },
            },
            {
              key: "destroy",
              value: function () {
                this.elements.thumb.container &&
                  this.elements.thumb.container.remove(),
                  this.elements.scrubbing.container &&
                  this.elements.scrubbing.container.remove();
              },
            },
            {
              key: "showImageAtCurrentTime",
              value: function () {
                var e = this;
                this.mouseDown
                  ? this.setScrubbingContainerSize()
                  : this.setThumbContainerSizeAndPos();
                var t = this.thumbnails[0].frames.findIndex(function (t) {
                  return e.seekTime >= t.startTime && e.seekTime <= t.endTime;
                }),
                  i = t >= 0,
                  n = 0;
                this.mouseDown || this.toggleThumbContainer(i),
                  i &&
                  (this.thumbnails.forEach(function (i, a) {
                    e.loadedImages.includes(i.frames[t].text) && (n = a);
                  }),
                    t !== this.showingThumb &&
                    ((this.showingThumb = t), this.loadImage(n)));
              },
            },
            {
              key: "loadImage",
              value: function () {
                var e = this,
                  t =
                    arguments.length > 0 && void 0 !== arguments[0]
                      ? arguments[0]
                      : 0,
                  i = this.showingThumb,
                  n = this.thumbnails[t],
                  a = n.urlPrefix,
                  s = n.frames[i],
                  r = n.frames[i].text,
                  o = a + r;
                if (
                  this.currentImageElement &&
                  this.currentImageElement.dataset.filename === r
                )
                  this.showImage(this.currentImageElement, s, t, i, r, !1),
                    (this.currentImageElement.dataset.index = i),
                    this.removeOldImages(this.currentImageElement);
                else {
                  this.loadingImage &&
                    this.usingSprites &&
                    (this.loadingImage.onload = null);
                  var l = new Image();
                  (l.src = o),
                    (l.dataset.index = i),
                    (l.dataset.filename = r),
                    (this.showingThumbFilename = r),
                    this.player.debug.log("Loading image: ".concat(o)),
                    (l.onload = function () {
                      return e.showImage(l, s, t, i, r, !0);
                    }),
                    (this.loadingImage = l),
                    this.removeOldImages(l);
                }
              },
            },
            {
              key: "showImage",
              value: function (e, t, i, n, a) {
                var s =
                  !(arguments.length > 5 && void 0 !== arguments[5]) ||
                  arguments[5];
                this.player.debug.log(
                  "Showing thumb: "
                    .concat(a, ". num: ")
                    .concat(n, ". qual: ")
                    .concat(i, ". newimg: ")
                    .concat(s)
                ),
                  this.setImageSizeAndOffset(e, t),
                  s &&
                  (this.currentImageContainer.appendChild(e),
                    (this.currentImageElement = e),
                    this.loadedImages.includes(a) || this.loadedImages.push(a)),
                  this.preloadNearby(n, !0)
                    .then(this.preloadNearby(n, !1))
                    .then(this.getHigherQuality(i, e, t, a));
              },
            },
            {
              key: "removeOldImages",
              value: function (e) {
                var t = this;
                Array.from(this.currentImageContainer.children).forEach(
                  function (i) {
                    if ("img" === i.tagName.toLowerCase()) {
                      var n = t.usingSprites ? 500 : 1e3;
                      if (
                        i.dataset.index !== e.dataset.index &&
                        !i.dataset.deleting
                      ) {
                        i.dataset.deleting = !0;
                        var a = t.currentImageContainer;
                        setTimeout(function () {
                          a.removeChild(i),
                            t.player.debug.log(
                              "Removing thumb: ".concat(i.dataset.filename)
                            );
                        }, n);
                      }
                    }
                  }
                );
              },
            },
            {
              key: "preloadNearby",
              value: function (e) {
                var t = this,
                  i =
                    !(arguments.length > 1 && void 0 !== arguments[1]) ||
                    arguments[1];
                return new Promise(function (n) {
                  setTimeout(function () {
                    var a = t.thumbnails[0].frames[e].text;
                    if (t.showingThumbFilename === a) {
                      var s;
                      s = i
                        ? t.thumbnails[0].frames.slice(e)
                        : t.thumbnails[0].frames.slice(0, e).reverse();
                      var r = !1;
                      s.forEach(function (e) {
                        var i = e.text;
                        if (i !== a && !t.loadedImages.includes(i)) {
                          (r = !0),
                            t.player.debug.log(
                              "Preloading thumb filename: ".concat(i)
                            );
                          var s = t.thumbnails[0].urlPrefix + i,
                            o = new Image();
                          (o.src = s),
                            (o.onload = function () {
                              t.player.debug.log(
                                "Preloaded thumb filename: ".concat(i)
                              ),
                                t.loadedImages.includes(i) ||
                                t.loadedImages.push(i),
                                n();
                            });
                        }
                      }),
                        r || n();
                    }
                  }, 300);
                });
              },
            },
            {
              key: "getHigherQuality",
              value: function (e, t, i, n) {
                var a = this;
                if (e < this.thumbnails.length - 1) {
                  var s = t.naturalHeight;
                  this.usingSprites && (s = i.h),
                    s < this.thumbContainerHeight &&
                    setTimeout(function () {
                      a.showingThumbFilename === n &&
                        (a.player.debug.log(
                          "Showing higher quality thumb for: ".concat(n)
                        ),
                          a.loadImage(e + 1));
                    }, 300);
                }
              },
            },
            {
              key: "toggleThumbContainer",
              value: function () {
                var e =
                  arguments.length > 0 &&
                  void 0 !== arguments[0] &&
                  arguments[0],
                  t =
                    arguments.length > 1 &&
                    void 0 !== arguments[1] &&
                    arguments[1],
                  i =
                    this.player.config.classNames.previewThumbnails
                      .thumbContainerShown;
                this.elements.thumb.container.classList.toggle(i, e),
                  !e &&
                  t &&
                  ((this.showingThumb = null),
                    (this.showingThumbFilename = null));
              },
            },
            {
              key: "toggleScrubbingContainer",
              value: function () {
                var e =
                  arguments.length > 0 &&
                  void 0 !== arguments[0] &&
                  arguments[0],
                  t =
                    this.player.config.classNames.previewThumbnails
                      .scrubbingContainerShown;
                this.elements.scrubbing.container.classList.toggle(t, e),
                  e ||
                  ((this.showingThumb = null),
                    (this.showingThumbFilename = null));
              },
            },
            {
              key: "determineContainerAutoSizing",
              value: function () {
                (this.elements.thumb.imageContainer.clientHeight > 20 ||
                  this.elements.thumb.imageContainer.clientWidth > 20) &&
                  (this.sizeSpecifiedInCSS = !0);
              },
            },
            {
              key: "setThumbContainerSizeAndPos",
              value: function () {
                if (this.sizeSpecifiedInCSS) {
                  if (
                    this.elements.thumb.imageContainer.clientHeight > 20 &&
                    this.elements.thumb.imageContainer.clientWidth < 20
                  ) {
                    var e = Math.floor(
                      this.elements.thumb.imageContainer.clientHeight *
                      this.thumbAspectRatio
                    );
                    this.elements.thumb.imageContainer.style.width = "".concat(
                      e,
                      "px"
                    );
                  } else if (
                    this.elements.thumb.imageContainer.clientHeight < 20 &&
                    this.elements.thumb.imageContainer.clientWidth > 20
                  ) {
                    var t = Math.floor(
                      this.elements.thumb.imageContainer.clientWidth /
                      this.thumbAspectRatio
                    );
                    this.elements.thumb.imageContainer.style.height = "".concat(
                      t,
                      "px"
                    );
                  }
                } else {
                  var i = Math.floor(
                    this.thumbContainerHeight * this.thumbAspectRatio
                  );
                  (this.elements.thumb.imageContainer.style.height = "".concat(
                    this.thumbContainerHeight,
                    "px"
                  )),
                    (this.elements.thumb.imageContainer.style.width = "".concat(
                      i,
                      "px"
                    ));
                }
                this.setThumbContainerPos();
              },
            },
            {
              key: "setThumbContainerPos",
              value: function () {
                var e = this.player.elements.progress.getBoundingClientRect(),
                  t = this.player.elements.container.getBoundingClientRect(),
                  i = this.elements.thumb.container,
                  n = t.left - e.left + 10,
                  a = t.right - e.left - i.clientWidth - 10,
                  s = this.mousePosX - e.left - i.clientWidth / 2;
                s < n && (s = n),
                  s > a && (s = a),
                  (i.style.left = "".concat(s, "px"));
              },
            },
            {
              key: "setScrubbingContainerSize",
              value: function () {
                var e = Mt(this.thumbAspectRatio, {
                  width: this.player.media.clientWidth,
                  height: this.player.media.clientHeight,
                }),
                  t = e.width,
                  i = e.height;
                (this.elements.scrubbing.container.style.width = "".concat(
                  t,
                  "px"
                )),
                  (this.elements.scrubbing.container.style.height = "".concat(
                    i,
                    "px"
                  ));
              },
            },
            {
              key: "setImageSizeAndOffset",
              value: function (e, t) {
                if (this.usingSprites) {
                  var i = this.thumbContainerHeight / t.h;
                  (e.style.height = "".concat(e.naturalHeight * i, "px")),
                    (e.style.width = "".concat(e.naturalWidth * i, "px")),
                    (e.style.left = "-".concat(t.x * i, "px")),
                    (e.style.top = "-".concat(t.y * i, "px"));
                }
              },
            },
            {
              key: "enabled",
              get: function () {
                return (
                  this.player.isHTML5 &&
                  this.player.isVideo &&
                  this.player.config.previewThumbnails.enabled
                );
              },
            },
            {
              key: "currentImageContainer",
              get: function () {
                return this.mouseDown
                  ? this.elements.scrubbing.container
                  : this.elements.thumb.imageContainer;
              },
            },
            {
              key: "usingSprites",
              get: function () {
                return Object.keys(this.thumbnails[0].frames[0]).includes("w");
              },
            },
            {
              key: "thumbAspectRatio",
              get: function () {
                return this.usingSprites
                  ? this.thumbnails[0].frames[0].w /
                  this.thumbnails[0].frames[0].h
                  : this.thumbnails[0].width / this.thumbnails[0].height;
              },
            },
            {
              key: "thumbContainerHeight",
              get: function () {
                return this.mouseDown
                  ? Mt(this.thumbAspectRatio, {
                    width: this.player.media.clientWidth,
                    height: this.player.media.clientHeight,
                  }).height
                  : this.sizeSpecifiedInCSS
                    ? this.elements.thumb.imageContainer.clientHeight
                    : Math.floor(
                      this.player.media.clientWidth / this.thumbAspectRatio / 4
                    );
              },
            },
            {
              key: "currentImageElement",
              get: function () {
                return this.mouseDown
                  ? this.currentScrubbingImageElement
                  : this.currentThumbnailImageElement;
              },
              set: function (e) {
                this.mouseDown
                  ? (this.currentScrubbingImageElement = e)
                  : (this.currentThumbnailImageElement = e);
              },
            },
          ]),
          t
        );
      })(),
      xt = {
        insertElements: function (e, t) {
          var i = this;
          Y(t)
            ? pe(e, this.media, { src: t })
            : $(t) &&
            t.forEach(function (t) {
              pe(e, i.media, t);
            });
        },
        change: function (e) {
          var t = this;
          le(e, "sources.length")
            ? (Ve.cancelRequests.call(this),
              this.destroy.call(
                this,
                function () {
                  (t.options.quality = []),
                    me(t.media),
                    (t.media = null),
                    G(t.elements.container) &&
                    t.elements.container.removeAttribute("class");
                  var i = e.sources,
                    n = e.type,
                    a = o(i, 1)[0],
                    s = a.provider,
                    r = void 0 === s ? ut.html5 : s,
                    l = a.src,
                    c = "html5" === r ? n : "div",
                    u = "html5" === r ? {} : { src: l };
                  Object.assign(t, {
                    provider: r,
                    type: n,
                    supported: Ee.check(n, r, t.config.playsinline),
                    media: he(c, u),
                  }),
                    t.elements.container.appendChild(t.media),
                    Q(e.autoplay) && (t.config.autoplay = e.autoplay),
                    t.isHTML5 &&
                    (t.config.crossorigin &&
                      t.media.setAttribute("crossorigin", ""),
                      t.config.autoplay && t.media.setAttribute("autoplay", ""),
                      ae(e.poster) || (t.poster = e.poster),
                      t.config.loop.active && t.media.setAttribute("loop", ""),
                      t.config.muted && t.media.setAttribute("muted", ""),
                      t.config.playsinline &&
                      t.media.setAttribute("playsinline", "")),
                    yt.addStyleHook.call(t),
                    t.isHTML5 && xt.insertElements.call(t, "source", i),
                    (t.config.title = e.title),
                    Pt.setup.call(t),
                    t.isHTML5 &&
                    Object.keys(e).includes("tracks") &&
                    xt.insertElements.call(t, "track", e.tracks),
                    (t.isHTML5 || (t.isEmbed && !t.supported.ui)) &&
                    yt.build.call(t),
                    t.isHTML5 && t.media.load(),
                    ae(e.previewThumbnails) ||
                    (Object.assign(
                      t.config.previewThumbnails,
                      e.previewThumbnails
                    ),
                      t.previewThumbnails &&
                      t.previewThumbnails.loaded &&
                      (t.previewThumbnails.destroy(),
                        (t.previewThumbnails = null)),
                      t.config.previewThumbnails.enabled &&
                      (t.previewThumbnails = new Nt(t))),
                    t.fullscreen.update();
                },
                !0
              ))
            : this.debug.warn("Invalid source format");
        },
      };
    var It,
      Lt = (function () {
        function t(i, n) {
          var a = this;
          if (
            (e(this, t),
              (this.timers = {}),
              (this.ready = !1),
              (this.loading = !1),
              (this.failed = !1),
              (this.touch = Ee.touch),
              (this.media = i),
              Y(this.media) &&
              (this.media = document.querySelectorAll(this.media)),
              ((window.jQuery && this.media instanceof jQuery) ||
                J(this.media) ||
                $(this.media)) &&
              (this.media = this.media[0]),
              (this.config = ce(
                {},
                ot,
                t.defaults,
                n || {},
                (function () {
                  try {
                    return JSON.parse(a.media.getAttribute("data-plyr-config"));
                  } catch (e) {
                    return {};
                  }
                })()
              )),
              (this.elements = {
                container: null,
                fullscreen: null,
                captions: null,
                buttons: {},
                display: {},
                progress: {},
                inputs: {},
                settings: { popup: null, menu: null, panels: {}, buttons: {} },
              }),
              (this.captions = {
                active: null,
                currentTrack: -1,
                meta: new WeakMap(),
              }),
              (this.fullscreen = { active: !1 }),
              (this.options = { speed: [], quality: [] }),
              (this.debug = new mt(this.config.debug)),
              this.debug.log("Config", this.config),
              this.debug.log("Support", Ee),
              !W(this.media) && G(this.media))
          )
            if (this.media.plyr) this.debug.warn("Target already setup");
            else if (this.config.enabled)
              if (Ee.check().api) {
                var s = this.media.cloneNode(!0);
                (s.autoplay = !1), (this.elements.original = s);
                var r = this.media.tagName.toLowerCase(),
                  o = null,
                  l = null;
                switch (r) {
                  case "div":
                    if (((o = this.media.querySelector("iframe")), G(o))) {
                      if (
                        ((l = at(o.getAttribute("src"))),
                          (this.provider = (function (e) {
                            return /^(https?:\/\/)?(www\.)?(youtube\.com|youtube-nocookie\.com|youtu\.?be)\/.+$/.test(
                              e
                            )
                              ? ut.youtube
                              : /^https?:\/\/player.vimeo.com\/video\/\d{0,9}(?=\b|\/)/.test(
                                e
                              )
                                ? ut.vimeo
                                : null;
                          })(l.toString())),
                          (this.elements.container = this.media),
                          (this.media = o),
                          (this.elements.container.className = ""),
                          l.search.length)
                      ) {
                        var c = ["1", "true"];
                        c.includes(l.searchParams.get("autoplay")) &&
                          (this.config.autoplay = !0),
                          c.includes(l.searchParams.get("loop")) &&
                          (this.config.loop.active = !0),
                          this.isYouTube
                            ? ((this.config.playsinline = c.includes(
                              l.searchParams.get("playsinline")
                            )),
                              (this.config.youtube.hl =
                                l.searchParams.get("hl")))
                            : (this.config.playsinline = !0);
                      }
                    } else
                      (this.provider = this.media.getAttribute(
                        this.config.attributes.embed.provider
                      )),
                        this.media.removeAttribute(
                          this.config.attributes.embed.provider
                        );
                    if (
                      ae(this.provider) ||
                      !Object.keys(ut).includes(this.provider)
                    )
                      return void this.debug.error(
                        "Setup failed: Invalid provider"
                      );
                    this.type = ht;
                    break;
                  case "video":
                  case "audio":
                    (this.type = r),
                      (this.provider = ut.html5),
                      this.media.hasAttribute("crossorigin") &&
                      (this.config.crossorigin = !0),
                      this.media.hasAttribute("autoplay") &&
                      (this.config.autoplay = !0),
                      (this.media.hasAttribute("playsinline") ||
                        this.media.hasAttribute("webkit-playsinline")) &&
                      (this.config.playsinline = !0),
                      this.media.hasAttribute("muted") &&
                      (this.config.muted = !0),
                      this.media.hasAttribute("loop") &&
                      (this.config.loop.active = !0);
                    break;
                  default:
                    return void this.debug.error(
                      "Setup failed: unsupported type"
                    );
                }
                (this.supported = Ee.check(
                  this.type,
                  this.provider,
                  this.config.playsinline
                )),
                  this.supported.api
                    ? ((this.eventListeners = []),
                      (this.listeners = new vt(this)),
                      (this.storage = new $e(this)),
                      (this.media.plyr = this),
                      G(this.elements.container) ||
                      ((this.elements.container = he("div", { tabindex: 0 })),
                        ue(this.media, this.elements.container)),
                      yt.migrateStyles.call(this),
                      yt.addStyleHook.call(this),
                      Pt.setup.call(this),
                      this.config.debug &&
                      xe.call(
                        this,
                        this.elements.container,
                        this.config.events.join(" "),
                        function (e) {
                          a.debug.log("event: ".concat(e.type));
                        }
                      ),
                      (this.fullscreen = new ft(this)),
                      (this.isHTML5 || (this.isEmbed && !this.supported.ui)) &&
                      yt.build.call(this),
                      this.listeners.container(),
                      this.listeners.global(),
                      this.config.ads.enabled && (this.ads = new Et(this)),
                      this.isHTML5 &&
                      this.config.autoplay &&
                      setTimeout(function () {
                        return qe(a.play());
                      }, 10),
                      (this.lastSeekTime = 0),
                      this.config.previewThumbnails.enabled &&
                      (this.previewThumbnails = new Nt(this)))
                    : this.debug.error("Setup failed: no support");
              } else this.debug.error("Setup failed: no support");
            else this.debug.error("Setup failed: disabled by config");
          else this.debug.error("Setup failed: no suitable element passed");
        }
        return (
          i(
            t,
            [
              {
                key: "play",
                value: function () {
                  var e = this;
                  return X(this.media.play)
                    ? (this.ads &&
                      this.ads.enabled &&
                      this.ads.managerPromise
                        .then(function () {
                          return e.ads.play();
                        })
                        .catch(function () {
                          return qe(e.media.play());
                        }),
                      this.media.play())
                    : null;
                },
              },
              {
                key: "pause",
                value: function () {
                  return this.playing && X(this.media.pause)
                    ? this.media.pause()
                    : null;
                },
              },
              {
                key: "togglePlay",
                value: function (e) {
                  return (Q(e) ? e : !this.playing)
                    ? this.play()
                    : this.pause();
                },
              },
              {
                key: "stop",
                value: function () {
                  this.isHTML5
                    ? (this.pause(), this.restart())
                    : X(this.media.stop) && this.media.stop();
                },
              },
              {
                key: "restart",
                value: function () {
                  this.currentTime = 0;
                },
              },
              {
                key: "rewind",
                value: function (e) {
                  this.currentTime -= K(e) ? e : this.config.seekTime;
                },
              },
              {
                key: "forward",
                value: function (e) {
                  this.currentTime += K(e) ? e : this.config.seekTime;
                },
              },
              {
                key: "increaseVolume",
                value: function (e) {
                  var t = this.media.muted ? 0 : this.volume;
                  this.volume = t + (K(e) ? e : 0);
                },
              },
              {
                key: "decreaseVolume",
                value: function (e) {
                  this.increaseVolume(-e);
                },
              },
              {
                key: "toggleCaptions",
                value: function (e) {
                  rt.toggle.call(this, e, !1);
                },
              },
              {
                key: "airplay",
                value: function () {
                  Ee.airplay && this.media.webkitShowPlaybackTargetPicker();
                },
              },
              {
                key: "toggleControls",
                value: function (e) {
                  if (this.supported.ui && !this.isAudio) {
                    var t = we(
                      this.elements.container,
                      this.config.classNames.hideControls
                    ),
                      i = void 0 === e ? void 0 : !e,
                      n = be(
                        this.elements.container,
                        this.config.classNames.hideControls,
                        i
                      );
                    if (
                      (n &&
                        this.config.controls.includes("settings") &&
                        !ae(this.config.settings) &&
                        nt.toggleMenu.call(this, !1),
                        n !== t)
                    ) {
                      var a = n ? "controlshidden" : "controlsshown";
                      Oe.call(this, this.media, a);
                    }
                    return !n;
                  }
                  return !1;
                },
              },
              {
                key: "on",
                value: function (e, t) {
                  xe.call(this, this.elements.container, e, t);
                },
              },
              {
                key: "once",
                value: function (e, t) {
                  Le.call(this, this.elements.container, e, t);
                },
              },
              {
                key: "off",
                value: function (e, t) {
                  Ie(this.elements.container, e, t);
                },
              },
              {
                key: "destroy",
                value: function (e) {
                  var t = this,
                    i =
                      arguments.length > 1 &&
                      void 0 !== arguments[1] &&
                      arguments[1];
                  if (this.ready) {
                    var n = function () {
                      (document.body.style.overflow = ""),
                        (t.embed = null),
                        i
                          ? (Object.keys(t.elements).length &&
                            (me(t.elements.buttons.play),
                              me(t.elements.captions),
                              me(t.elements.controls),
                              me(t.elements.wrapper),
                              (t.elements.buttons.play = null),
                              (t.elements.captions = null),
                              (t.elements.controls = null),
                              (t.elements.wrapper = null)),
                            X(e) && e())
                          : (_e.call(t),
                            ge(t.elements.original, t.elements.container),
                            Oe.call(t, t.elements.original, "destroyed", !0),
                            X(e) && e.call(t.elements.original),
                            (t.ready = !1),
                            setTimeout(function () {
                              (t.elements = null), (t.media = null);
                            }, 200));
                    };
                    this.stop(),
                      clearTimeout(this.timers.loading),
                      clearTimeout(this.timers.controls),
                      clearTimeout(this.timers.resized),
                      this.isHTML5
                        ? (yt.toggleNativeControls.call(this, !0), n())
                        : this.isYouTube
                          ? (clearInterval(this.timers.buffering),
                            clearInterval(this.timers.playing),
                            null !== this.embed &&
                            X(this.embed.destroy) &&
                            this.embed.destroy(),
                            n())
                          : this.isVimeo &&
                          (null !== this.embed && this.embed.unload().then(n),
                            setTimeout(n, 200));
                  }
                },
              },
              {
                key: "supports",
                value: function (e) {
                  return Ee.mime.call(this, e);
                },
              },
              {
                key: "isHTML5",
                get: function () {
                  return this.provider === ut.html5;
                },
              },
              {
                key: "isEmbed",
                get: function () {
                  return this.isYouTube || this.isVimeo;
                },
              },
              {
                key: "isYouTube",
                get: function () {
                  return this.provider === ut.youtube;
                },
              },
              {
                key: "isVimeo",
                get: function () {
                  return this.provider === ut.vimeo;
                },
              },
              {
                key: "isVideo",
                get: function () {
                  return this.type === ht;
                },
              },
              {
                key: "isAudio",
                get: function () {
                  return this.type === dt;
                },
              },
              {
                key: "playing",
                get: function () {
                  return Boolean(this.ready && !this.paused && !this.ended);
                },
              },
              {
                key: "paused",
                get: function () {
                  return Boolean(this.media.paused);
                },
              },
              {
                key: "stopped",
                get: function () {
                  return Boolean(this.paused && 0 === this.currentTime);
                },
              },
              {
                key: "ended",
                get: function () {
                  return Boolean(this.media.ended);
                },
              },
              {
                key: "currentTime",
                set: function (e) {
                  if (this.duration) {
                    var t = K(e) && e > 0;
                    (this.media.currentTime = t
                      ? Math.min(e, this.duration)
                      : 0),
                      this.debug.log(
                        "Seeking to ".concat(this.currentTime, " seconds")
                      );
                  }
                },
                get: function () {
                  return Number(this.media.currentTime);
                },
              },
              {
                key: "buffered",
                get: function () {
                  var e = this.media.buffered;
                  return K(e)
                    ? e
                    : e && e.length && this.duration > 0
                      ? e.end(0) / this.duration
                      : 0;
                },
              },
              {
                key: "seeking",
                get: function () {
                  return Boolean(this.media.seeking);
                },
              },
              {
                key: "duration",
                get: function () {
                  var e = parseFloat(this.config.duration),
                    t = (this.media || {}).duration,
                    i = K(t) && t !== 1 / 0 ? t : 0;
                  return e || i;
                },
              },
              {
                key: "volume",
                set: function (e) {
                  var t = e;
                  Y(t) && (t = Number(t)),
                    K(t) || (t = this.storage.get("volume")),
                    K(t) || (t = this.config.volume),
                    t > 1 && (t = 1),
                    t < 0 && (t = 0),
                    (this.config.volume = t),
                    (this.media.volume = t),
                    !ae(e) && this.muted && t > 0 && (this.muted = !1);
                },
                get: function () {
                  return Number(this.media.volume);
                },
              },
              {
                key: "muted",
                set: function (e) {
                  var t = e;
                  Q(t) || (t = this.storage.get("muted")),
                    Q(t) || (t = this.config.muted),
                    (this.config.muted = t),
                    (this.media.muted = t);
                },
                get: function () {
                  return Boolean(this.media.muted);
                },
              },
              {
                key: "hasAudio",
                get: function () {
                  return (
                    !this.isHTML5 ||
                    !!this.isAudio ||
                    Boolean(this.media.mozHasAudio) ||
                    Boolean(this.media.webkitAudioDecodedByteCount) ||
                    Boolean(
                      this.media.audioTracks && this.media.audioTracks.length
                    )
                  );
                },
              },
              {
                key: "speed",
                set: function (e) {
                  var t = this,
                    i = null;
                  K(e) && (i = e),
                    K(i) || (i = this.storage.get("speed")),
                    K(i) || (i = this.config.speed.selected);
                  var n = this.minimumSpeed,
                    a = this.maximumSpeed;
                  (i = (function () {
                    var e =
                      arguments.length > 0 && void 0 !== arguments[0]
                        ? arguments[0]
                        : 0,
                      t =
                        arguments.length > 1 && void 0 !== arguments[1]
                          ? arguments[1]
                          : 0,
                      i =
                        arguments.length > 2 && void 0 !== arguments[2]
                          ? arguments[2]
                          : 255;
                    return Math.min(Math.max(e, t), i);
                  })(i, n, a)),
                    (this.config.speed.selected = i),
                    setTimeout(function () {
                      t.media.playbackRate = i;
                    }, 0);
                },
                get: function () {
                  return Number(this.media.playbackRate);
                },
              },
              {
                key: "minimumSpeed",
                get: function () {
                  return this.isYouTube
                    ? Math.min.apply(Math, l(this.options.speed))
                    : this.isVimeo
                      ? 0.5
                      : 0.0625;
                },
              },
              {
                key: "maximumSpeed",
                get: function () {
                  return this.isYouTube
                    ? Math.max.apply(Math, l(this.options.speed))
                    : this.isVimeo
                      ? 2
                      : 16;
                },
              },
              {
                key: "quality",
                set: function (e) {
                  var t = this.config.quality,
                    i = this.options.quality;
                  if (i.length) {
                    var n = [
                      !ae(e) && Number(e),
                      this.storage.get("quality"),
                      t.selected,
                      t.default,
                    ].find(K),
                      a = !0;
                    if (!i.includes(n)) {
                      var s = (function (e, t) {
                        return $(e) && e.length
                          ? e.reduce(function (e, i) {
                            return Math.abs(i - t) < Math.abs(e - t) ? i : e;
                          })
                          : null;
                      })(i, n);
                      this.debug.warn(
                        "Unsupported quality option: "
                          .concat(n, ", using ")
                          .concat(s, " instead")
                      ),
                        (n = s),
                        (a = !1);
                    }
                    (t.selected = n),
                      (this.media.quality = n),
                      a && this.storage.set({ quality: n });
                  }
                },
                get: function () {
                  return this.media.quality;
                },
              },
              {
                key: "loop",
                set: function (e) {
                  var t = Q(e) ? e : this.config.loop.active;
                  (this.config.loop.active = t), (this.media.loop = t);
                },
                get: function () {
                  return Boolean(this.media.loop);
                },
              },
              {
                key: "source",
                set: function (e) {
                  xt.change.call(this, e);
                },
                get: function () {
                  return this.media.currentSrc;
                },
              },
              {
                key: "download",
                get: function () {
                  var e = this.config.urls.download;
                  return ne(e) ? e : this.source;
                },
                set: function (e) {
                  ne(e) &&
                    ((this.config.urls.download = e),
                      nt.setDownloadUrl.call(this));
                },
              },
              {
                key: "poster",
                set: function (e) {
                  this.isVideo
                    ? yt.setPoster.call(this, e, !1).catch(function () { })
                    : this.debug.warn("Poster can only be set for video");
                },
                get: function () {
                  return this.isVideo
                    ? this.media.getAttribute("poster") ||
                    this.media.getAttribute("data-poster")
                    : null;
                },
              },
              {
                key: "ratio",
                get: function () {
                  if (!this.isVideo) return null;
                  var e = He(Fe.call(this));
                  return $(e) ? e.join(":") : e;
                },
                set: function (e) {
                  this.isVideo
                    ? Y(e) && De(e)
                      ? ((this.config.ratio = e), Re.call(this))
                      : this.debug.error(
                        "Invalid aspect ratio specified (".concat(e, ")")
                      )
                    : this.debug.warn("Aspect ratio can only be set for video");
                },
              },
              {
                key: "autoplay",
                set: function (e) {
                  var t = Q(e) ? e : this.config.autoplay;
                  this.config.autoplay = t;
                },
                get: function () {
                  return Boolean(this.config.autoplay);
                },
              },
              {
                key: "currentTrack",
                set: function (e) {
                  rt.set.call(this, e, !1);
                },
                get: function () {
                  var e = this.captions,
                    t = e.toggled,
                    i = e.currentTrack;
                  return t ? i : -1;
                },
              },
              {
                key: "language",
                set: function (e) {
                  rt.setLanguage.call(this, e, !1);
                },
                get: function () {
                  return (rt.getCurrentTrack.call(this) || {}).language;
                },
              },
              {
                key: "pip",
                set: function (e) {
                  if (Ee.pip) {
                    var t = Q(e) ? e : !this.pip;
                    X(this.media.webkitSetPresentationMode) &&
                      this.media.webkitSetPresentationMode(t ? lt : ct),
                      X(this.media.requestPictureInPicture) &&
                      (!this.pip && t
                        ? this.media.requestPictureInPicture()
                        : this.pip && !t && document.exitPictureInPicture());
                  }
                },
                get: function () {
                  return Ee.pip
                    ? ae(this.media.webkitPresentationMode)
                      ? this.media === document.pictureInPictureElement
                      : this.media.webkitPresentationMode === lt
                    : null;
                },
              },
            ],
            [
              {
                key: "supported",
                value: function (e, t, i) {
                  return Ee.check(e, t, i);
                },
              },
              {
                key: "loadSprite",
                value: function (e, t) {
                  return Ge(e, t);
                },
              },
              {
                key: "setup",
                value: function (e) {
                  var i =
                    arguments.length > 1 && void 0 !== arguments[1]
                      ? arguments[1]
                      : {},
                    n = null;
                  return (
                    Y(e)
                      ? (n = Array.from(document.querySelectorAll(e)))
                      : J(e)
                        ? (n = Array.from(e))
                        : $(e) && (n = e.filter(G)),
                    ae(n)
                      ? null
                      : n.map(function (e) {
                        return new t(e, i);
                      })
                  );
                },
              },
            ]
          ),
          t
        );
      })();
    return (Lt.defaults = ((It = ot), JSON.parse(JSON.stringify(It)))), Lt;
  });
//hls scripts
!(function (e) {
  if ("object" == typeof exports && "undefined" != typeof module)
    module.exports = e();
  else if ("function" == typeof define && define.amd) define([], e);
  else {
    var t;
    (t =
      "undefined" != typeof window
        ? window
        : "undefined" != typeof global
          ? global
          : "undefined" != typeof self
            ? self
            : this),
      (t.Hls = e());
  }
})(function () {
  var e;
  return (function e(t, r, i) {
    function a(s, o) {
      if (!r[s]) {
        if (!t[s]) {
          var l = "function" == typeof require && require;
          if (!o && l) return l(s, !0);
          if (n) return n(s, !0);
          var u = new Error("Cannot find module '" + s + "'");
          throw ((u.code = "MODULE_NOT_FOUND"), u);
        }
        var d = (r[s] = { exports: {} });
        t[s][0].call(
          d.exports,
          function (e) {
            var r = t[s][1][e];
            return a(r ? r : e);
          },
          d,
          d.exports,
          e,
          t,
          r,
          i
        );
      }
      return r[s].exports;
    }
    for (
      var n = "function" == typeof require && require, s = 0;
      s < i.length;
      s++
    )
      a(i[s]);
    return a;
  })(
    {
      1: [
        function (e, t, r) {
          function i() {
            (this._events = this._events || {}),
              (this._maxListeners = this._maxListeners || void 0);
          }
          function a(e) {
            return "function" == typeof e;
          }
          function n(e) {
            return "number" == typeof e;
          }
          function s(e) {
            return "object" == typeof e && null !== e;
          }
          function o(e) {
            return void 0 === e;
          }
          (t.exports = i),
            (i.EventEmitter = i),
            (i.prototype._events = void 0),
            (i.prototype._maxListeners = void 0),
            (i.defaultMaxListeners = 10),
            (i.prototype.setMaxListeners = function (e) {
              if (!n(e) || e < 0 || isNaN(e))
                throw TypeError("n must be a positive number");
              return (this._maxListeners = e), this;
            }),
            (i.prototype.emit = function (e) {
              var t, r, i, n, l, u;
              if (
                (this._events || (this._events = {}),
                  "error" === e &&
                  (!this._events.error ||
                    (s(this._events.error) && !this._events.error.length)))
              ) {
                if ((t = arguments[1]) instanceof Error) throw t;
                var d = new Error(
                  'Uncaught, unspecified "error" event. (' + t + ")"
                );
                throw ((d.context = t), d);
              }
              if (((r = this._events[e]), o(r))) return !1;
              if (a(r))
                switch (arguments.length) {
                  case 1:
                    r.call(this);
                    break;
                  case 2:
                    r.call(this, arguments[1]);
                    break;
                  case 3:
                    r.call(this, arguments[1], arguments[2]);
                    break;
                  default:
                    (n = Array.prototype.slice.call(arguments, 1)),
                      r.apply(this, n);
                }
              else if (s(r))
                for (
                  n = Array.prototype.slice.call(arguments, 1),
                  u = r.slice(),
                  i = u.length,
                  l = 0;
                  l < i;
                  l++
                )
                  u[l].apply(this, n);
              return !0;
            }),
            (i.prototype.addListener = function (e, t) {
              var r;
              if (!a(t)) throw TypeError("listener must be a function");
              return (
                this._events || (this._events = {}),
                this._events.newListener &&
                this.emit("newListener", e, a(t.listener) ? t.listener : t),
                this._events[e]
                  ? s(this._events[e])
                    ? this._events[e].push(t)
                    : (this._events[e] = [this._events[e], t])
                  : (this._events[e] = t),
                s(this._events[e]) &&
                !this._events[e].warned &&
                (r = o(this._maxListeners)
                  ? i.defaultMaxListeners
                  : this._maxListeners) &&
                r > 0 &&
                this._events[e].length > r &&
                ((this._events[e].warned = !0), console.trace),
                this
              );
            }),
            (i.prototype.on = i.prototype.addListener),
            (i.prototype.once = function (e, t) {
              function r() {
                this.removeListener(e, r),
                  i || ((i = !0), t.apply(this, arguments));
              }
              if (!a(t)) throw TypeError("listener must be a function");
              var i = !1;
              return (r.listener = t), this.on(e, r), this;
            }),
            (i.prototype.removeListener = function (e, t) {
              var r, i, n, o;
              if (!a(t)) throw TypeError("listener must be a function");
              if (!this._events || !this._events[e]) return this;
              if (
                ((r = this._events[e]),
                  (n = r.length),
                  (i = -1),
                  r === t || (a(r.listener) && r.listener === t))
              )
                delete this._events[e],
                  this._events.removeListener &&
                  this.emit("removeListener", e, t);
              else if (s(r)) {
                for (o = n; o-- > 0;)
                  if (r[o] === t || (r[o].listener && r[o].listener === t)) {
                    i = o;
                    break;
                  }
                if (i < 0) return this;
                1 === r.length
                  ? ((r.length = 0), delete this._events[e])
                  : r.splice(i, 1),
                  this._events.removeListener &&
                  this.emit("removeListener", e, t);
              }
              return this;
            }),
            (i.prototype.removeAllListeners = function (e) {
              var t, r;
              if (!this._events) return this;
              if (!this._events.removeListener)
                return (
                  0 === arguments.length
                    ? (this._events = {})
                    : this._events[e] && delete this._events[e],
                  this
                );
              if (0 === arguments.length) {
                for (t in this._events)
                  "removeListener" !== t && this.removeAllListeners(t);
                return (
                  this.removeAllListeners("removeListener"),
                  (this._events = {}),
                  this
                );
              }
              if (((r = this._events[e]), a(r))) this.removeListener(e, r);
              else if (r)
                for (; r.length;) this.removeListener(e, r[r.length - 1]);
              return delete this._events[e], this;
            }),
            (i.prototype.listeners = function (e) {
              return this._events && this._events[e]
                ? a(this._events[e])
                  ? [this._events[e]]
                  : this._events[e].slice()
                : [];
            }),
            (i.prototype.listenerCount = function (e) {
              if (this._events) {
                var t = this._events[e];
                if (a(t)) return 1;
                if (t) return t.length;
              }
              return 0;
            }),
            (i.listenerCount = function (e, t) {
              return e.listenerCount(t);
            });
        },
        {},
      ],
      2: [
        function (t, r, i) {
          !(function (t) {
            var a =
              /^((?:[^\/;?#]+:)?)(\/\/[^\/\;?#]*)?(.*?)??(;.*?)?(\?.*?)?(#.*?)?$/,
              n = /^([^\/;?#]*)(.*)$/,
              s = {
                buildAbsoluteURL: function (e, t, r) {
                  if (((r = r || {}), (e = e.trim()), !(t = t.trim()))) {
                    if (!r.alwaysNormalize) return e;
                    var i = this.parseURL(e);
                    if (!o) throw new Error("Error trying to parse base URL.");
                    return (
                      (i.path = s.normalizePath(i.path)), s.buildURLFromParts(i)
                    );
                  }
                  var a = this.parseURL(t);
                  if (!a)
                    throw new Error("Error trying to parse relative URL.");
                  if (a.scheme)
                    return r.alwaysNormalize
                      ? ((a.path = s.normalizePath(a.path)),
                        s.buildURLFromParts(a))
                      : t;
                  var o = this.parseURL(e);
                  if (!o) throw new Error("Error trying to parse base URL.");
                  if (!o.netLoc && o.path && "/" !== o.path[0]) {
                    var l = n.exec(o.path);
                    (o.netLoc = l[1]), (o.path = l[2]);
                  }
                  o.netLoc && !o.path && (o.path = "/");
                  var u = {
                    scheme: o.scheme,
                    netLoc: a.netLoc,
                    path: null,
                    params: a.params,
                    query: a.query,
                    fragment: a.fragment,
                  };
                  if (!a.netLoc && ((u.netLoc = o.netLoc), "/" !== a.path[0]))
                    if (a.path) {
                      var d = o.path,
                        f = d.substring(0, d.lastIndexOf("/") + 1) + a.path;
                      u.path = s.normalizePath(f);
                    } else
                      (u.path = o.path),
                        a.params ||
                        ((u.params = o.params),
                          a.query || (u.query = o.query));
                  return (
                    null === u.path &&
                    (u.path = r.alwaysNormalize
                      ? s.normalizePath(a.path)
                      : a.path),
                    s.buildURLFromParts(u)
                  );
                },
                parseURL: function (e) {
                  var t = a.exec(e);
                  return t
                    ? {
                      scheme: t[1] || "",
                      netLoc: t[2] || "",
                      path: t[3] || "",
                      params: t[4] || "",
                      query: t[5] || "",
                      fragment: t[6] || "",
                    }
                    : null;
                },
                normalizePath: function (e) {
                  for (
                    e = e
                      .split("")
                      .reverse()
                      .join("")
                      .replace(/(?:\/|^)\.(?=\/)/g, "");
                    e.length !==
                    (e = e.replace(/(?:\/|^)\.\.\/(?!\.\.\/).*?(?=\/)/g, ""))
                      .length;

                  );
                  return e.split("").reverse().join("");
                },
                buildURLFromParts: function (e) {
                  return (
                    e.scheme +
                    e.netLoc +
                    e.path +
                    e.params +
                    e.query +
                    e.fragment
                  );
                },
              };
            "object" == typeof i && "object" == typeof r
              ? (r.exports = s)
              : "function" == typeof e && e.amd
                ? e([], function () {
                  return s;
                })
                : "object" == typeof i
                  ? (i.URLToolkit = s)
                  : (t.URLToolkit = s);
          })(this);
        },
        {},
      ],
      3: [
        function (e, t, r) {
          var i = arguments[3],
            a = arguments[4],
            n = arguments[5],
            s = JSON.stringify;
          t.exports = function (e, t) {
            function r(e) {
              p[e] = !0;
              for (var t in a[e][1]) {
                var i = a[e][1][t];
                p[i] || r(i);
              }
            }
            for (var o, l = Object.keys(n), u = 0, d = l.length; u < d; u++) {
              var f = l[u],
                c = n[f].exports;
              if (c === e || (c && c.default === e)) {
                o = f;
                break;
              }
            }
            if (!o) {
              o = Math.floor(Math.pow(16, 8) * Math.random()).toString(16);
              for (var h = {}, u = 0, d = l.length; u < d; u++) {
                var f = l[u];
                h[f] = f;
              }
              a[o] = [
                Function(["require", "module", "exports"], "(" + e + ")(self)"),
                h,
              ];
            }
            var g = Math.floor(Math.pow(16, 8) * Math.random()).toString(16),
              v = {};
            (v[o] = o),
              (a[g] = [
                Function(
                  ["require"],
                  "var f = require(" +
                  s(o) +
                  ");(f.default ? f.default : f)(self);"
                ),
                v,
              ]);
            var p = {};
            r(g);
            var y =
              "(" +
              i +
              ")({" +
              Object.keys(p)
                .map(function (e) {
                  return s(e) + ":[" + a[e][0] + "," + s(a[e][1]) + "]";
                })
                .join(",") +
              "},{},[" +
              s(g) +
              "])",
              m =
                window.URL || window.webkitURL || window.mozURL || window.msURL,
              E = new Blob([y], { type: "text/javascript" });
            if (t && t.bare) return E;
            var b = m.createObjectURL(E),
              T = new Worker(b);
            return (T.objectURL = b), T;
          };
        },
        {},
      ],
      4: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          Object.defineProperty(r, "__esModule", { value: !0 }),
            (r.hlsDefaultConfig = void 0);
          var a = e(5),
            n = i(a),
            s = e(8),
            o = i(s),
            l = e(9),
            u = i(l),
            d = e(10),
            f = i(d),
            c = e(56),
            h = i(c),
            g = e(7),
            v = i(g),
            p = e(6),
            y = i(p),
            m = e(48),
            E = i(m),
            b = e(16),
            T = i(b),
            _ = e(15),
            k = i(_),
            R = e(14),
            A = i(R);
          r.hlsDefaultConfig = {
            autoStartLoad: !0,
            startPosition: -1,
            defaultAudioCodec: void 0,
            debug: !1,
            capLevelOnFPSDrop: !1,
            capLevelToPlayerSize: !1,
            initialLiveManifestSize: 1,
            maxBufferLength: 30,
            maxBufferSize: 6e7,
            maxBufferHole: 0.5,
            maxSeekHole: 2,
            lowBufferWatchdogPeriod: 0.5,
            highBufferWatchdogPeriod: 3,
            nudgeOffset: 0.1,
            nudgeMaxRetry: 3,
            maxFragLookUpTolerance: 0.2,
            liveSyncDurationCount: 3,
            liveMaxLatencyDurationCount: 1 / 0,
            liveSyncDuration: void 0,
            liveMaxLatencyDuration: void 0,
            maxMaxBufferLength: 600,
            enableWorker: !0,
            enableSoftwareAES: !0,
            manifestLoadingTimeOut: 1e4,
            manifestLoadingMaxRetry: 1,
            manifestLoadingRetryDelay: 1e3,
            manifestLoadingMaxRetryTimeout: 64e3,
            startLevel: void 0,
            levelLoadingTimeOut: 1e4,
            levelLoadingMaxRetry: 4,
            levelLoadingRetryDelay: 1e3,
            levelLoadingMaxRetryTimeout: 64e3,
            fragLoadingTimeOut: 2e4,
            fragLoadingMaxRetry: 6,
            fragLoadingRetryDelay: 1e3,
            fragLoadingMaxRetryTimeout: 64e3,
            fragLoadingLoopThreshold: 3,
            startFragPrefetch: !1,
            fpsDroppedMonitoringPeriod: 5e3,
            fpsDroppedMonitoringThreshold: 0.2,
            appendErrorMaxRetry: 3,
            loader: h.default,
            fLoader: void 0,
            pLoader: void 0,
            xhrSetup: void 0,
            fetchSetup: void 0,
            abrController: n.default,
            bufferController: o.default,
            capLevelController: u.default,
            fpsController: f.default,
            audioStreamController: y.default,
            audioTrackController: v.default,
            subtitleStreamController: A.default,
            subtitleTrackController: k.default,
            timelineController: T.default,
            cueHandler: E.default,
            enableCEA708Captions: !0,
            enableWebVTT: !0,
            captionsTextTrack1Label: "English",
            captionsTextTrack1LanguageCode: "en",
            captionsTextTrack2Label: "Spanish",
            captionsTextTrack2LanguageCode: "es",
            stretchShortVideoTrack: !1,
            forceKeyFrameOnDiscontinuity: !0,
            abrEwmaFastLive: 3,
            abrEwmaSlowLive: 9,
            abrEwmaFastVoD: 3,
            abrEwmaSlowVoD: 9,
            abrEwmaDefaultEstimate: 5e5,
            abrBandWidthFactor: 0.95,
            abrBandWidthUpFactor: 0.7,
            abrMaxWithRealBitrate: !1,
            maxStarvationDelay: 4,
            maxLoadingDelay: 4,
            minAutoBitrate: 0,
          };
        },
        {
          10: 10,
          14: 14,
          15: 15,
          16: 16,
          48: 48,
          5: 5,
          56: 56,
          6: 6,
          7: 7,
          8: 8,
          9: 9,
        },
      ],
      5: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(35),
            h = i(c),
            g = e(31),
            v = e(51),
            p = e(49),
            y = i(p),
            m = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.FRAG_LOADING,
                    u.default.FRAG_LOADED,
                    u.default.FRAG_BUFFERED,
                    u.default.ERROR
                  )
                );
                return (
                  (r.lastLoadedFragLevel = 0),
                  (r._nextAutoLevel = -1),
                  (r.hls = e),
                  (r.onCheck = r._abandonRulesCheck.bind(r)),
                  r
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      this.clearTimer(), f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onFragLoading",
                    value: function (e) {
                      var t = e.frag;
                      if ("main" === t.type) {
                        if (
                          (this.timer ||
                            (this.timer = setInterval(this.onCheck, 100)),
                            !this._bwEstimator)
                        ) {
                          var r = this.hls,
                            i = e.frag.level,
                            a = r.levels[i].details.live,
                            n = r.config,
                            s = void 0,
                            o = void 0;
                          a
                            ? ((s = n.abrEwmaFastLive), (o = n.abrEwmaSlowLive))
                            : ((s = n.abrEwmaFastVoD), (o = n.abrEwmaSlowVoD)),
                            (this._bwEstimator = new y.default(
                              r,
                              o,
                              s,
                              n.abrEwmaDefaultEstimate
                            ));
                        }
                        this.fragCurrent = t;
                      }
                    },
                  },
                  {
                    key: "_abandonRulesCheck",
                    value: function () {
                      var e = this.hls,
                        t = e.media,
                        r = this.fragCurrent,
                        i = r.loader,
                        a = e.minAutoLevel;
                      if (!i || (i.stats && i.stats.aborted))
                        return (
                          v.logger.warn(
                            "frag loader destroy or aborted, disarm abandonRules"
                          ),
                          void this.clearTimer()
                        );
                      var n = i.stats;
                      if (
                        t &&
                        ((!t.paused && 0 !== t.playbackRate) ||
                          !t.readyState) &&
                        r.autoLevel &&
                        r.level
                      ) {
                        var s = performance.now() - n.trequest,
                          o = Math.abs(t.playbackRate);
                        if (s > (500 * r.duration) / o) {
                          var l = e.levels,
                            d = Math.max(
                              1,
                              n.bw ? n.bw / 8 : (1e3 * n.loaded) / s
                            ),
                            f = l[r.level],
                            c = f.realBitrate
                              ? Math.max(f.realBitrate, f.bitrate)
                              : f.bitrate,
                            g = n.total
                              ? n.total
                              : Math.max(
                                n.loaded,
                                Math.round((r.duration * c) / 8)
                              ),
                            p = t.currentTime,
                            y = (g - n.loaded) / d,
                            m =
                              (h.default.bufferInfo(
                                t,
                                p,
                                e.config.maxBufferHole
                              ).end -
                                p) /
                              o;
                          if (m < (2 * r.duration) / o && y > m) {
                            var E = void 0,
                              b = void 0;
                            for (b = r.level - 1; b > a; b--) {
                              var T = l[b].realBitrate
                                ? Math.max(l[b].realBitrate, l[b].bitrate)
                                : l[b].bitrate;
                              if ((E = (r.duration * T) / (6.4 * d)) < m) break;
                            }
                            E < y &&
                              (v.logger.warn(
                                "loading too slow, abort fragment loading and switch to level " +
                                b +
                                ":fragLoadedDelay[" +
                                b +
                                "]<fragLoadedDelay[" +
                                (r.level - 1) +
                                "];bufferStarvationDelay:" +
                                E.toFixed(1) +
                                "<" +
                                y.toFixed(1) +
                                ":" +
                                m.toFixed(1)
                              ),
                                (e.nextLoadLevel = b),
                                this._bwEstimator.sample(s, n.loaded),
                                i.abort(),
                                this.clearTimer(),
                                e.trigger(u.default.FRAG_LOAD_EMERGENCY_ABORTED, {
                                  frag: r,
                                  stats: n,
                                }));
                          }
                        }
                      }
                    },
                  },
                  {
                    key: "onFragLoaded",
                    value: function (e) {
                      var t = e.frag;
                      if ("main" === t.type && !isNaN(t.sn)) {
                        if (
                          (this.clearTimer(),
                            (this.lastLoadedFragLevel = t.level),
                            (this._nextAutoLevel = -1),
                            this.hls.config.abrMaxWithRealBitrate)
                        ) {
                          var r = this.hls.levels[t.level],
                            i =
                              (r.loaded ? r.loaded.bytes : 0) + e.stats.loaded,
                            a =
                              (r.loaded ? r.loaded.duration : 0) +
                              e.frag.duration;
                          (r.loaded = { bytes: i, duration: a }),
                            (r.realBitrate = Math.round((8 * i) / a));
                        }
                        if (e.frag.bitrateTest) {
                          var n = e.stats;
                          (n.tparsed = n.tbuffered = n.tload),
                            this.onFragBuffered(e);
                        }
                      }
                    },
                  },
                  {
                    key: "onFragBuffered",
                    value: function (e) {
                      var t = e.stats,
                        r = e.frag;
                      if (
                        !(
                          t.aborted === !0 ||
                          1 !== r.loadCounter ||
                          "main" !== r.type ||
                          isNaN(r.sn) ||
                          (r.bitrateTest && t.tload !== t.tbuffered)
                        )
                      ) {
                        var i = t.tparsed - t.trequest;
                        v.logger.log(
                          "latency/loading/parsing/append/kbps:" +
                          Math.round(t.tfirst - t.trequest) +
                          "/" +
                          Math.round(t.tload - t.tfirst) +
                          "/" +
                          Math.round(t.tparsed - t.tload) +
                          "/" +
                          Math.round(t.tbuffered - t.tparsed) +
                          "/" +
                          Math.round(
                            (8 * t.loaded) / (t.tbuffered - t.trequest)
                          )
                        ),
                          this._bwEstimator.sample(i, t.loaded),
                          (t.bwEstimate = this._bwEstimator.getEstimate()),
                          r.bitrateTest
                            ? (this.bitrateTestDelay = i / 1e3)
                            : (this.bitrateTestDelay = 0);
                      }
                    },
                  },
                  {
                    key: "onError",
                    value: function (e) {
                      switch (e.details) {
                        case g.ErrorDetails.FRAG_LOAD_ERROR:
                        case g.ErrorDetails.FRAG_LOAD_TIMEOUT:
                          this.clearTimer();
                      }
                    },
                  },
                  {
                    key: "clearTimer",
                    value: function () {
                      this.timer &&
                        (clearInterval(this.timer), (this.timer = null));
                    },
                  },
                  {
                    key: "_findBestLevel",
                    value: function (e, t, r, i, a, n, s, o, l) {
                      for (var u = a; u >= i; u--) {
                        var d = l[u],
                          f = d.details,
                          c = f ? f.totalduration / f.fragments.length : t,
                          h = !!f && f.live,
                          g = void 0;
                        g = u <= e ? s * r : o * r;
                        var p = l[u].realBitrate
                          ? Math.max(l[u].realBitrate, l[u].bitrate)
                          : l[u].bitrate,
                          y = (p * c) / g;
                        if (
                          (v.logger.trace(
                            "level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: " +
                            u +
                            "/" +
                            Math.round(g) +
                            "/" +
                            p +
                            "/" +
                            c +
                            "/" +
                            n +
                            "/" +
                            y
                          ),
                            g > p && (!y || h || y < n))
                        )
                          return u;
                      }
                      return -1;
                    },
                  },
                  {
                    key: "nextAutoLevel",
                    get: function () {
                      var e = this._nextAutoLevel,
                        t = this._bwEstimator;
                      if (!(e === -1 || (t && t.canEstimate()))) return e;
                      var r = this._nextABRAutoLevel;
                      return e !== -1 && (r = Math.min(e, r)), r;
                    },
                    set: function (e) {
                      this._nextAutoLevel = e;
                    },
                  },
                  {
                    key: "_nextABRAutoLevel",
                    get: function () {
                      var e = this.hls,
                        t = e.maxAutoLevel,
                        r = e.levels,
                        i = e.config,
                        a = e.minAutoLevel,
                        n = e.media,
                        s = this.lastLoadedFragLevel,
                        o = this.fragCurrent ? this.fragCurrent.duration : 0,
                        l = n ? n.currentTime : 0,
                        u =
                          n && 0 !== n.playbackRate
                            ? Math.abs(n.playbackRate)
                            : 1,
                        d = this._bwEstimator
                          ? this._bwEstimator.getEstimate()
                          : i.abrEwmaDefaultEstimate,
                        f =
                          (h.default.bufferInfo(n, l, i.maxBufferHole).end -
                            l) /
                          u,
                        c = this._findBestLevel(
                          s,
                          o,
                          d,
                          a,
                          t,
                          f,
                          i.abrBandWidthFactor,
                          i.abrBandWidthUpFactor,
                          r
                        );
                      if (c >= 0) return c;
                      v.logger.trace(
                        "rebuffering expected to happen, lets try to find a quality level minimizing the rebuffering"
                      );
                      var g = o
                        ? Math.min(o, i.maxStarvationDelay)
                        : i.maxStarvationDelay,
                        p = i.abrBandWidthFactor,
                        y = i.abrBandWidthUpFactor;
                      if (0 === f) {
                        var m = this.bitrateTestDelay;
                        if (m) {
                          (g =
                            (o
                              ? Math.min(o, i.maxLoadingDelay)
                              : i.maxLoadingDelay) - m),
                            v.logger.trace(
                              "bitrate test took " +
                              Math.round(1e3 * m) +
                              "ms, set first fragment max fetchDuration to " +
                              Math.round(1e3 * g) +
                              " ms"
                            ),
                            (p = y = 1);
                        }
                      }
                      return (
                        (c = this._findBestLevel(
                          s,
                          o,
                          d,
                          a,
                          t,
                          f + g,
                          p,
                          y,
                          r
                        )),
                        Math.max(c, 0)
                      );
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = m;
        },
        { 31: 31, 32: 32, 33: 33, 35: 35, 49: 49, 51: 51 },
      ],
      6: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(46),
            u = i(l),
            d = e(35),
            f = i(d),
            c = e(25),
            h = i(c),
            g = e(33),
            v = i(g),
            p = e(32),
            y = i(p),
            m = e(36),
            E = i(m),
            b = e(52),
            T = i(b),
            _ = e(31),
            k = e(51),
            R = {
              STOPPED: "STOPPED",
              STARTING: "STARTING",
              IDLE: "IDLE",
              PAUSED: "PAUSED",
              KEY_LOADING: "KEY_LOADING",
              FRAG_LOADING: "FRAG_LOADING",
              FRAG_LOADING_WAITING_RETRY: "FRAG_LOADING_WAITING_RETRY",
              WAITING_TRACK: "WAITING_TRACK",
              PARSING: "PARSING",
              PARSED: "PARSED",
              BUFFER_FLUSHING: "BUFFER_FLUSHING",
              ENDED: "ENDED",
              ERROR: "ERROR",
              WAITING_INIT_PTS: "WAITING_INIT_PTS",
            },
            A = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    v.default.MEDIA_ATTACHED,
                    v.default.MEDIA_DETACHING,
                    v.default.AUDIO_TRACKS_UPDATED,
                    v.default.AUDIO_TRACK_SWITCHING,
                    v.default.AUDIO_TRACK_LOADED,
                    v.default.KEY_LOADED,
                    v.default.FRAG_LOADED,
                    v.default.FRAG_PARSING_INIT_SEGMENT,
                    v.default.FRAG_PARSING_DATA,
                    v.default.FRAG_PARSED,
                    v.default.ERROR,
                    v.default.BUFFER_CREATED,
                    v.default.BUFFER_APPENDED,
                    v.default.BUFFER_FLUSHED,
                    v.default.INIT_PTS_FOUND
                  )
                );
                return (
                  (r.config = e.config),
                  (r.audioCodecSwap = !1),
                  (r.ticks = 0),
                  (r._state = R.STOPPED),
                  (r.ontick = r.tick.bind(r)),
                  (r.initPTS = []),
                  (r.waitingFragment = null),
                  r
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      this.stopLoad(),
                        this.timer &&
                        (clearInterval(this.timer), (this.timer = null)),
                        y.default.prototype.destroy.call(this),
                        (this.state = R.STOPPED);
                    },
                  },
                  {
                    key: "onInitPtsFound",
                    value: function (e) {
                      var t = e.id,
                        r = e.frag.cc,
                        i = e.initPTS;
                      "main" === t &&
                        ((this.initPTS[r] = i),
                          k.logger.log(
                            "InitPTS for cc:" + r + " found from video track:" + i
                          ),
                          this.state === R.WAITING_INIT_PTS &&
                          (k.logger.log(
                            "sending pending audio frag to demuxer"
                          ),
                            (this.state = R.FRAG_LOADING),
                            this.onFragLoaded(this.waitingFragment),
                            (this.waitingFragment = null)));
                    },
                  },
                  {
                    key: "startLoad",
                    value: function (e) {
                      if (this.tracks) {
                        var t = this.lastCurrentTime;
                        this.stopLoad(),
                          this.timer ||
                          (this.timer = setInterval(this.ontick, 100)),
                          (this.fragLoadError = 0),
                          t > 0 && e === -1
                            ? (k.logger.log(
                              "audio:override startPosition with lastCurrentTime @" +
                              t.toFixed(3)
                            ),
                              (this.state = R.IDLE))
                            : ((this.lastCurrentTime = this.startPosition
                              ? this.startPosition
                              : e),
                              (this.state = R.STARTING)),
                          (this.nextLoadPosition = this.startPosition =
                            this.lastCurrentTime),
                          this.tick();
                      } else (this.startPosition = e), (this.state = R.STOPPED);
                    },
                  },
                  {
                    key: "stopLoad",
                    value: function () {
                      var e = this.fragCurrent;
                      e &&
                        (e.loader && e.loader.abort(),
                          (this.fragCurrent = null)),
                        (this.fragPrevious = null),
                        this.demuxer &&
                        (this.demuxer.destroy(), (this.demuxer = null)),
                        (this.state = R.STOPPED);
                    },
                  },
                  {
                    key: "tick",
                    value: function () {
                      1 === ++this.ticks &&
                        (this.doTick(),
                          this.ticks > 1 && setTimeout(this.tick, 1),
                          (this.ticks = 0));
                    },
                  },
                  {
                    key: "doTick",
                    value: function () {
                      var e,
                        t,
                        r,
                        i = this.hls,
                        a = i.config;
                      switch (this.state) {
                        case R.ERROR:
                        case R.PAUSED:
                        case R.BUFFER_FLUSHING:
                          break;
                        case R.STARTING:
                          (this.state = R.WAITING_TRACK),
                            (this.loadedmetadata = !1);
                          break;
                        case R.IDLE:
                          var n = this.tracks;
                          if (!n) break;
                          if (
                            !this.media &&
                            (this.startFragRequested || !a.startFragPrefetch)
                          )
                            break;
                          e = this.loadedmetadata
                            ? this.media.currentTime
                            : this.nextLoadPosition;
                          var s = this.mediaBuffer
                            ? this.mediaBuffer
                            : this.media,
                            o = f.default.bufferInfo(s, e, a.maxBufferHole),
                            l = o.len,
                            d = o.end,
                            c = this.fragPrevious,
                            h = a.maxMaxBufferLength,
                            g = this.audioSwitch,
                            p = this.trackId;
                          if ((l < h || g) && p < n.length) {
                            if (void 0 === (r = n[p].details)) {
                              this.state = R.WAITING_TRACK;
                              break;
                            }
                            if (
                              !g &&
                              !r.live &&
                              c &&
                              c.sn === r.endSN &&
                              (!this.media.seeking ||
                                this.media.duration - d < c.duration / 2)
                            ) {
                              this.hls.trigger(v.default.BUFFER_EOS, {
                                type: "audio",
                              }),
                                (this.state = R.ENDED);
                              break;
                            }
                            var y = r.fragments,
                              m = y.length,
                              E = y[0].start,
                              b = y[m - 1].start + y[m - 1].duration,
                              T = void 0;
                            if (g)
                              if (r.live && !r.PTSKnown)
                                k.logger.log(
                                  "switching audiotrack, live stream, unknown PTS,load first fragment"
                                ),
                                  (d = 0);
                              else if (((d = e), r.PTSKnown && e < E)) {
                                if (!(o.end > E || o.nextStart)) return;
                                k.logger.log(
                                  "alt audio track ahead of main track, seek to start of alt audio track"
                                ),
                                  (this.media.currentTime = E + 0.05);
                              }
                            if (r.initSegment && !r.initSegment.data)
                              T = r.initSegment;
                            else if (d <= E) {
                              if (
                                ((T = y[0]),
                                  r.live &&
                                  T.loadIdx &&
                                  T.loadIdx === this.fragLoadIdx)
                              ) {
                                var A = o.nextStart ? o.nextStart : E;
                                return (
                                  k.logger.log(
                                    "no alt audio available @currentTime:" +
                                    this.media.currentTime +
                                    ", seeking @" +
                                    (A + 0.05)
                                  ),
                                  void (this.media.currentTime = A + 0.05)
                                );
                              }
                            } else {
                              var S = void 0,
                                L = a.maxFragLookUpTolerance,
                                w = c ? y[c.sn - y[0].sn + 1] : void 0,
                                D = function (e) {
                                  var t = Math.min(L, e.duration);
                                  return e.start + e.duration - t <= d
                                    ? 1
                                    : e.start - t > d && e.start
                                      ? -1
                                      : 0;
                                };
                              d < b
                                ? (d > b - L && (L = 0),
                                  (S = w && !D(w) ? w : u.default.search(y, D)))
                                : (S = y[m - 1]),
                                S &&
                                ((T = S),
                                  (E = S.start),
                                  c &&
                                  T.level === c.level &&
                                  T.sn === c.sn &&
                                  (T.sn < r.endSN
                                    ? ((T = y[T.sn + 1 - r.startSN]),
                                      k.logger.log(
                                        "SN just loaded, load next one: " +
                                        T.sn
                                      ))
                                    : (T = null)));
                            }
                            if (T)
                              if (
                                T.decryptdata &&
                                null != T.decryptdata.uri &&
                                null == T.decryptdata.key
                              )
                                k.logger.log(
                                  "Loading key for " +
                                  T.sn +
                                  " of [" +
                                  r.startSN +
                                  " ," +
                                  r.endSN +
                                  "],track " +
                                  p
                                ),
                                  (this.state = R.KEY_LOADING),
                                  i.trigger(v.default.KEY_LOADING, { frag: T });
                              else {
                                if (
                                  (k.logger.log(
                                    "Loading " +
                                    T.sn +
                                    " of [" +
                                    r.startSN +
                                    " ," +
                                    r.endSN +
                                    "],track " +
                                    p +
                                    ", currentTime:" +
                                    e +
                                    ",bufferEnd:" +
                                    d.toFixed(3)
                                  ),
                                    void 0 !== this.fragLoadIdx
                                      ? this.fragLoadIdx++
                                      : (this.fragLoadIdx = 0),
                                    T.loadCounter)
                                ) {
                                  T.loadCounter++;
                                  var O = a.fragLoadingLoopThreshold;
                                  if (
                                    T.loadCounter > O &&
                                    Math.abs(this.fragLoadIdx - T.loadIdx) < O
                                  )
                                    return void i.trigger(v.default.ERROR, {
                                      type: _.ErrorTypes.MEDIA_ERROR,
                                      details:
                                        _.ErrorDetails.FRAG_LOOP_LOADING_ERROR,
                                      fatal: !1,
                                      frag: T,
                                    });
                                } else T.loadCounter = 1;
                                (T.loadIdx = this.fragLoadIdx),
                                  (this.fragCurrent = T),
                                  (this.startFragRequested = !0),
                                  isNaN(T.sn) ||
                                  (this.nextLoadPosition =
                                    T.start + T.duration),
                                  i.trigger(v.default.FRAG_LOADING, {
                                    frag: T,
                                  }),
                                  (this.state = R.FRAG_LOADING);
                              }
                          }
                          break;
                        case R.WAITING_TRACK:
                          (t = this.tracks[this.trackId]),
                            t && t.details && (this.state = R.IDLE);
                          break;
                        case R.FRAG_LOADING_WAITING_RETRY:
                          var I = performance.now(),
                            P = this.retryDate;
                          s = this.media;
                          var C = s && s.seeking;
                          (!P || I >= P || C) &&
                            (k.logger.log(
                              "audioStreamController: retryDate reached, switch back to IDLE state"
                            ),
                              (this.state = R.IDLE));
                          break;
                        case R.WAITING_INIT_PTS:
                        case R.STOPPED:
                        case R.FRAG_LOADING:
                        case R.PARSING:
                        case R.PARSED:
                        case R.ENDED:
                      }
                    },
                  },
                  {
                    key: "onMediaAttached",
                    value: function (e) {
                      var t = (this.media = this.mediaBuffer = e.media);
                      (this.onvseeking = this.onMediaSeeking.bind(this)),
                        (this.onvended = this.onMediaEnded.bind(this)),
                        t.addEventListener("seeking", this.onvseeking),
                        t.addEventListener("ended", this.onvended);
                      var r = this.config;
                      this.tracks &&
                        r.autoStartLoad &&
                        this.startLoad(r.startPosition);
                    },
                  },
                  {
                    key: "onMediaDetaching",
                    value: function () {
                      var e = this.media;
                      e &&
                        e.ended &&
                        (k.logger.log(
                          "MSE detaching and video ended, reset startPosition"
                        ),
                          (this.startPosition = this.lastCurrentTime = 0));
                      var t = this.tracks;
                      t &&
                        t.forEach(function (e) {
                          e.details &&
                            e.details.fragments.forEach(function (e) {
                              e.loadCounter = void 0;
                            });
                        }),
                        e &&
                        (e.removeEventListener("seeking", this.onvseeking),
                          e.removeEventListener("ended", this.onvended),
                          (this.onvseeking =
                            this.onvseeked =
                            this.onvended =
                            null)),
                        (this.media = this.mediaBuffer = null),
                        (this.loadedmetadata = !1),
                        this.stopLoad();
                    },
                  },
                  {
                    key: "onMediaSeeking",
                    value: function () {
                      this.state === R.ENDED && (this.state = R.IDLE),
                        this.media &&
                        (this.lastCurrentTime = this.media.currentTime),
                        void 0 !== this.fragLoadIdx &&
                        (this.fragLoadIdx +=
                          2 * this.config.fragLoadingLoopThreshold),
                        this.tick();
                    },
                  },
                  {
                    key: "onMediaEnded",
                    value: function () {
                      this.startPosition = this.lastCurrentTime = 0;
                    },
                  },
                  {
                    key: "onAudioTracksUpdated",
                    value: function (e) {
                      k.logger.log("audio tracks updated"),
                        (this.tracks = e.audioTracks);
                    },
                  },
                  {
                    key: "onAudioTrackSwitching",
                    value: function (e) {
                      var t = !!e.url;
                      (this.trackId = e.id),
                        (this.state = R.IDLE),
                        (this.fragCurrent = null),
                        (this.state = R.PAUSED),
                        (this.waitingFragment = null),
                        t
                          ? this.timer ||
                          (this.timer = setInterval(this.ontick, 100))
                          : this.demuxer &&
                          (this.demuxer.destroy(), (this.demuxer = null)),
                        t &&
                        ((this.audioSwitch = !0),
                          (this.state = R.IDLE),
                          void 0 !== this.fragLoadIdx &&
                          (this.fragLoadIdx +=
                            2 * this.config.fragLoadingLoopThreshold)),
                        this.tick();
                    },
                  },
                  {
                    key: "onAudioTrackLoaded",
                    value: function (e) {
                      var t = e.details,
                        r = e.id,
                        i = this.tracks[r],
                        a = t.totalduration,
                        n = 0;
                      if (
                        (k.logger.log(
                          "track " +
                          r +
                          " loaded [" +
                          t.startSN +
                          "," +
                          t.endSN +
                          "],duration:" +
                          a
                        ),
                          t.live)
                      ) {
                        var s = i.details;
                        s && t.fragments.length > 0
                          ? (E.default.mergeDetails(s, t),
                            (n = t.fragments[0].start),
                            t.PTSKnown
                              ? k.logger.log(
                                "live audio playlist sliding:" + n.toFixed(3)
                              )
                              : k.logger.log(
                                "live audio playlist - outdated PTS, unknown sliding"
                              ))
                          : ((t.PTSKnown = !1),
                            k.logger.log(
                              "live audio playlist - first load, unknown sliding"
                            ));
                      } else t.PTSKnown = !1;
                      if (((i.details = t), !this.startFragRequested)) {
                        if (this.startPosition === -1) {
                          var o = t.startTimeOffset;
                          isNaN(o)
                            ? (this.startPosition = 0)
                            : (k.logger.log(
                              "start time offset found in playlist, adjust startPosition to " +
                              o
                            ),
                              (this.startPosition = o));
                        }
                        this.nextLoadPosition = this.startPosition;
                      }
                      this.state === R.WAITING_TRACK && (this.state = R.IDLE),
                        this.tick();
                    },
                  },
                  {
                    key: "onKeyLoaded",
                    value: function () {
                      this.state === R.KEY_LOADING &&
                        ((this.state = R.IDLE), this.tick());
                    },
                  },
                  {
                    key: "onFragLoaded",
                    value: function (e) {
                      var t = this.fragCurrent,
                        r = e.frag;
                      if (
                        this.state === R.FRAG_LOADING &&
                        t &&
                        "audio" === r.type &&
                        r.level === t.level &&
                        r.sn === t.sn
                      ) {
                        var i = this.tracks[this.trackId],
                          a = i.details,
                          n = a.totalduration,
                          s = t.level,
                          o = t.sn,
                          l = t.cc,
                          u =
                            this.config.defaultAudioCodec ||
                            i.audioCodec ||
                            "mp4a.40.2",
                          d = (this.stats = e.stats);
                        if ("initSegment" === o)
                          (this.state = R.IDLE),
                            (d.tparsed = d.tbuffered = performance.now()),
                            (a.initSegment.data = e.payload),
                            this.hls.trigger(v.default.FRAG_BUFFERED, {
                              stats: d,
                              frag: t,
                              id: "audio",
                            }),
                            this.tick();
                        else {
                          (this.state = R.PARSING),
                            (this.appended = !1),
                            this.demuxer ||
                            (this.demuxer = new h.default(this.hls, "audio"));
                          var f = this.initPTS[l],
                            c = a.initSegment ? a.initSegment.data : [];
                          if (a.initSegment || void 0 !== f) {
                            (this.pendingBuffering = !0),
                              k.logger.log(
                                "Demuxing " +
                                o +
                                " of [" +
                                a.startSN +
                                " ," +
                                a.endSN +
                                "],track " +
                                s
                              );
                            this.demuxer.push(
                              e.payload,
                              c,
                              u,
                              null,
                              t,
                              n,
                              !1,
                              f
                            );
                          } else
                            k.logger.log(
                              "unknown video PTS for continuity counter " +
                              l +
                              ", waiting for video PTS before demuxing audio frag " +
                              o +
                              " of [" +
                              a.startSN +
                              " ," +
                              a.endSN +
                              "],track " +
                              s
                            ),
                              (this.waitingFragment = e),
                              (this.state = R.WAITING_INIT_PTS);
                        }
                      }
                      this.fragLoadError = 0;
                    },
                  },
                  {
                    key: "onFragParsingInitSegment",
                    value: function (e) {
                      var t = this.fragCurrent,
                        r = e.frag;
                      if (
                        t &&
                        "audio" === e.id &&
                        r.sn === t.sn &&
                        r.level === t.level &&
                        this.state === R.PARSING
                      ) {
                        var i = e.tracks,
                          a = void 0;
                        if ((i.video && delete i.video, (a = i.audio))) {
                          (a.levelCodec = "mp4a.40.2"),
                            (a.id = e.id),
                            this.hls.trigger(v.default.BUFFER_CODECS, i),
                            k.logger.log(
                              "audio track:audio,container:" +
                              a.container +
                              ",codecs[level/parsed]=[" +
                              a.levelCodec +
                              "/" +
                              a.codec +
                              "]"
                            );
                          var n = a.initSegment;
                          if (n) {
                            var s = {
                              type: "audio",
                              data: n,
                              parent: "audio",
                              content: "initSegment",
                            };
                            this.audioSwitch
                              ? (this.pendingData = [s])
                              : ((this.appended = !0),
                                (this.pendingBuffering = !0),
                                this.hls.trigger(
                                  v.default.BUFFER_APPENDING,
                                  s
                                ));
                          }
                          this.tick();
                        }
                      }
                    },
                  },
                  {
                    key: "onFragParsingData",
                    value: function (e) {
                      var t = this,
                        r = this.fragCurrent,
                        i = e.frag;
                      if (
                        r &&
                        "audio" === e.id &&
                        "audio" === e.type &&
                        i.sn === r.sn &&
                        i.level === r.level &&
                        this.state === R.PARSING
                      ) {
                        var a = this.trackId,
                          n = this.tracks[a],
                          s = this.hls;
                        isNaN(e.endPTS) &&
                          ((e.endPTS = e.startPTS + r.duration),
                            (e.endDTS = e.startDTS + r.duration)),
                          k.logger.log(
                            "parsed " +
                            e.type +
                            ",PTS:[" +
                            e.startPTS.toFixed(3) +
                            "," +
                            e.endPTS.toFixed(3) +
                            "],DTS:[" +
                            e.startDTS.toFixed(3) +
                            "/" +
                            e.endDTS.toFixed(3) +
                            "],nb:" +
                            e.nb
                          ),
                          E.default.updateFragPTSDTS(
                            n.details,
                            r,
                            e.startPTS,
                            e.endPTS
                          );
                        var o = this.audioSwitch,
                          l = this.media,
                          u = !1;
                        if (o && l)
                          if (l.readyState) {
                            var d = l.currentTime;
                            k.logger.log(
                              "switching audio track : currentTime:" + d
                            ),
                              d >= e.startPTS &&
                              (k.logger.log(
                                "switching audio track : flushing all audio"
                              ),
                                (this.state = R.BUFFER_FLUSHING),
                                s.trigger(v.default.BUFFER_FLUSHING, {
                                  startOffset: 0,
                                  endOffset: Number.POSITIVE_INFINITY,
                                  type: "audio",
                                }),
                                (u = !0),
                                (this.audioSwitch = !1),
                                s.trigger(v.default.AUDIO_TRACK_SWITCHED, {
                                  id: a,
                                }));
                          } else
                            (this.audioSwitch = !1),
                              s.trigger(v.default.AUDIO_TRACK_SWITCHED, {
                                id: a,
                              });
                        var f = this.pendingData;
                        this.audioSwitch ||
                          ([e.data1, e.data2].forEach(function (t) {
                            t &&
                              t.length &&
                              f.push({
                                type: e.type,
                                data: t,
                                parent: "audio",
                                content: "data",
                              });
                          }),
                            !u &&
                            f.length &&
                            (f.forEach(function (e) {
                              t.state === R.PARSING &&
                                ((t.pendingBuffering = !0),
                                  t.hls.trigger(v.default.BUFFER_APPENDING, e));
                            }),
                              (this.pendingData = []),
                              (this.appended = !0))),
                          this.tick();
                      }
                    },
                  },
                  {
                    key: "onFragParsed",
                    value: function (e) {
                      var t = this.fragCurrent,
                        r = e.frag;
                      t &&
                        "audio" === e.id &&
                        r.sn === t.sn &&
                        r.level === t.level &&
                        this.state === R.PARSING &&
                        ((this.stats.tparsed = performance.now()),
                          (this.state = R.PARSED),
                          this._checkAppendedParsed());
                    },
                  },
                  {
                    key: "onBufferCreated",
                    value: function (e) {
                      var t = e.tracks.audio;
                      t &&
                        ((this.mediaBuffer = t.buffer),
                          (this.loadedmetadata = !0));
                    },
                  },
                  {
                    key: "onBufferAppended",
                    value: function (e) {
                      if ("audio" === e.parent) {
                        var t = this.state;
                        (t !== R.PARSING && t !== R.PARSED) ||
                          ((this.pendingBuffering = e.pending > 0),
                            this._checkAppendedParsed());
                      }
                    },
                  },
                  {
                    key: "_checkAppendedParsed",
                    value: function () {
                      if (
                        !(
                          this.state !== R.PARSED ||
                          (this.appended && this.pendingBuffering)
                        )
                      ) {
                        var e = this.fragCurrent,
                          t = this.stats,
                          r = this.hls;
                        if (e) {
                          (this.fragPrevious = e),
                            (t.tbuffered = performance.now()),
                            r.trigger(v.default.FRAG_BUFFERED, {
                              stats: t,
                              frag: e,
                              id: "audio",
                            });
                          var i = this.mediaBuffer
                            ? this.mediaBuffer
                            : this.media;
                          k.logger.log(
                            "audio buffered : " + T.default.toString(i.buffered)
                          ),
                            this.audioSwitch &&
                            this.appended &&
                            ((this.audioSwitch = !1),
                              r.trigger(v.default.AUDIO_TRACK_SWITCHED, {
                                id: this.trackId,
                              })),
                            (this.state = R.IDLE);
                        }
                        this.tick();
                      }
                    },
                  },
                  {
                    key: "onError",
                    value: function (e) {
                      var t = e.frag;
                      if (!t || "audio" === t.type)
                        switch (e.details) {
                          case _.ErrorDetails.FRAG_LOAD_ERROR:
                          case _.ErrorDetails.FRAG_LOAD_TIMEOUT:
                            if (!e.fatal) {
                              var r = this.fragLoadError;
                              r ? r++ : (r = 1);
                              var i = this.config;
                              if (r <= i.fragLoadingMaxRetry) {
                                (this.fragLoadError = r), (t.loadCounter = 0);
                                var a = Math.min(
                                  Math.pow(2, r - 1) * i.fragLoadingRetryDelay,
                                  i.fragLoadingMaxRetryTimeout
                                );
                                k.logger.warn(
                                  "audioStreamController: frag loading failed, retry in " +
                                  a +
                                  " ms"
                                ),
                                  (this.retryDate = performance.now() + a),
                                  (this.state = R.FRAG_LOADING_WAITING_RETRY);
                              } else
                                k.logger.error(
                                  "audioStreamController: " +
                                  e.details +
                                  " reaches max retry, redispatch as fatal ..."
                                ),
                                  (e.fatal = !0),
                                  (this.state = R.ERROR);
                            }
                            break;
                          case _.ErrorDetails.FRAG_LOOP_LOADING_ERROR:
                          case _.ErrorDetails.AUDIO_TRACK_LOAD_ERROR:
                          case _.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:
                          case _.ErrorDetails.KEY_LOAD_ERROR:
                          case _.ErrorDetails.KEY_LOAD_TIMEOUT:
                            this.state !== R.ERROR &&
                              ((this.state = e.fatal ? R.ERROR : R.IDLE),
                                k.logger.warn(
                                  "audioStreamController: " +
                                  e.details +
                                  " while loading frag,switch to " +
                                  this.state +
                                  " state ..."
                                ));
                            break;
                          case _.ErrorDetails.BUFFER_FULL_ERROR:
                            if (
                              "audio" === e.parent &&
                              (this.state === R.PARSING ||
                                this.state === R.PARSED)
                            ) {
                              var n = this.mediaBuffer,
                                s = this.media.currentTime;
                              if (
                                n &&
                                f.default.isBuffered(n, s) &&
                                f.default.isBuffered(n, s + 0.5)
                              ) {
                                var o = this.config;
                                o.maxMaxBufferLength >= o.maxBufferLength &&
                                  ((o.maxMaxBufferLength /= 2),
                                    k.logger.warn(
                                      "audio:reduce max buffer length to " +
                                      o.maxMaxBufferLength +
                                      "s"
                                    ),
                                    (this.fragLoadIdx +=
                                      2 * o.fragLoadingLoopThreshold)),
                                  (this.state = R.IDLE);
                              } else
                                k.logger.warn(
                                  "buffer full error also media.currentTime is not buffered, flush audio buffer"
                                ),
                                  (this.fragCurrent = null),
                                  (this.state = R.BUFFER_FLUSHING),
                                  this.hls.trigger(v.default.BUFFER_FLUSHING, {
                                    startOffset: 0,
                                    endOffset: Number.POSITIVE_INFINITY,
                                    type: "audio",
                                  });
                            }
                        }
                    },
                  },
                  {
                    key: "onBufferFlushed",
                    value: function () {
                      var e = this,
                        t = this.pendingData;
                      t && t.length
                        ? (k.logger.log(
                          "appending pending audio data on Buffer Flushed"
                        ),
                          t.forEach(function (t) {
                            e.hls.trigger(v.default.BUFFER_APPENDING, t);
                          }),
                          (this.appended = !0),
                          (this.pendingData = []),
                          (this.state = R.PARSED))
                        : ((this.state = R.IDLE),
                          (this.fragPrevious = null),
                          this.tick());
                    },
                  },
                  {
                    key: "state",
                    set: function (e) {
                      if (this.state !== e) {
                        var t = this.state;
                        (this._state = e),
                          k.logger.log("audio stream:" + t + "->" + e);
                      }
                    },
                    get: function () {
                      return this._state;
                    },
                  },
                ]),
                t
              );
            })(y.default);
          r.default = A;
        },
        {
          25: 25,
          31: 31,
          32: 32,
          33: 33,
          35: 35,
          36: 36,
          46: 46,
          51: 51,
          52: 52,
        },
      ],
      7: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(51),
            h = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.MANIFEST_LOADING,
                    u.default.MANIFEST_LOADED,
                    u.default.AUDIO_TRACK_LOADED
                  )
                );
                return (r.ticks = 0), (r.ontick = r.tick.bind(r)), r;
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "tick",
                    value: function () {
                      1 === ++this.ticks &&
                        (this.doTick(),
                          this.ticks > 1 && setTimeout(this.tick, 1),
                          (this.ticks = 0));
                    },
                  },
                  {
                    key: "doTick",
                    value: function () {
                      this.updateTrack(this.trackId);
                    },
                  },
                  {
                    key: "onManifestLoading",
                    value: function () {
                      (this.tracks = []), (this.trackId = -1);
                    },
                  },
                  {
                    key: "onManifestLoaded",
                    value: function (e) {
                      var t = this,
                        r = e.audioTracks || [],
                        i = !1;
                      (this.tracks = r),
                        this.hls.trigger(u.default.AUDIO_TRACKS_UPDATED, {
                          audioTracks: r,
                        });
                      var a = 0;
                      r.forEach(function (e) {
                        if (e.default) return (t.audioTrack = a), void (i = !0);
                        a++;
                      }),
                        i === !1 &&
                        r.length &&
                        (c.logger.log(
                          "no default audio track defined, use first audio track as default"
                        ),
                          (this.audioTrack = 0));
                    },
                  },
                  {
                    key: "onAudioTrackLoaded",
                    value: function (e) {
                      e.id < this.tracks.length &&
                        (c.logger.log("audioTrack " + e.id + " loaded"),
                          (this.tracks[e.id].details = e.details),
                          e.details.live &&
                          !this.timer &&
                          (this.timer = setInterval(
                            this.ontick,
                            1e3 * e.details.targetduration
                          )),
                          !e.details.live &&
                          this.timer &&
                          (clearInterval(this.timer), (this.timer = null)));
                    },
                  },
                  {
                    key: "setAudioTrackInternal",
                    value: function (e) {
                      if (e >= 0 && e < this.tracks.length) {
                        this.timer &&
                          (clearInterval(this.timer), (this.timer = null)),
                          (this.trackId = e),
                          c.logger.log("switching to audioTrack " + e);
                        var t = this.tracks[e],
                          r = this.hls,
                          i = t.type,
                          a = t.url,
                          n = { id: e, type: i, url: a };
                        r.trigger(u.default.AUDIO_TRACK_SWITCH, n),
                          r.trigger(u.default.AUDIO_TRACK_SWITCHING, n);
                        var s = t.details;
                        !a ||
                          (void 0 !== s && s.live !== !0) ||
                          (c.logger.log(
                            "(re)loading playlist for audioTrack " + e
                          ),
                            r.trigger(u.default.AUDIO_TRACK_LOADING, {
                              url: a,
                              id: e,
                            }));
                      }
                    },
                  },
                  {
                    key: "updateTrack",
                    value: function (e) {
                      if (e >= 0 && e < this.tracks.length) {
                        this.timer &&
                          (clearInterval(this.timer), (this.timer = null)),
                          (this.trackId = e),
                          c.logger.log("updating audioTrack " + e);
                        var t = this.tracks[e],
                          r = t.url,
                          i = t.details;
                        !r ||
                          (void 0 !== i && i.live !== !0) ||
                          (c.logger.log(
                            "(re)loading playlist for audioTrack " + e
                          ),
                            this.hls.trigger(u.default.AUDIO_TRACK_LOADING, {
                              url: r,
                              id: e,
                            }));
                      }
                    },
                  },
                  {
                    key: "audioTracks",
                    get: function () {
                      return this.tracks;
                    },
                  },
                  {
                    key: "audioTrack",
                    get: function () {
                      return this.trackId;
                    },
                    set: function (e) {
                      (this.trackId === e &&
                        void 0 !== this.tracks[e].details) ||
                        this.setAudioTrackInternal(e);
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = h;
        },
        { 32: 32, 33: 33, 51: 51 },
      ],
      8: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(51),
            h = e(31),
            g = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.MEDIA_ATTACHING,
                    u.default.MEDIA_DETACHING,
                    u.default.MANIFEST_PARSED,
                    u.default.BUFFER_RESET,
                    u.default.BUFFER_APPENDING,
                    u.default.BUFFER_CODECS,
                    u.default.BUFFER_EOS,
                    u.default.BUFFER_FLUSHING,
                    u.default.LEVEL_PTS_UPDATED,
                    u.default.LEVEL_UPDATED
                  )
                );
                return (
                  (r._msDuration = null),
                  (r._levelDuration = null),
                  (r.onsbue = r.onSBUpdateEnd.bind(r)),
                  (r.onsbe = r.onSBUpdateError.bind(r)),
                  (r.pendingTracks = {}),
                  (r.tracks = {}),
                  r
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onLevelPtsUpdated",
                    value: function (e) {
                      var t = e.type,
                        r = this.tracks.audio;
                      if ("audio" === t && r && "audio/mpeg" === r.container) {
                        var i = this.sourceBuffer.audio;
                        if (Math.abs(i.timestampOffset - e.start) > 0.1) {
                          var a = i.updating;
                          try {
                            i.abort();
                          } catch (e) {
                            (a = !0),
                              c.logger.warn("can not abort audio buffer: " + e);
                          }
                          a
                            ? (this.audioTimestampOffset = e.start)
                            : (c.logger.warn(
                              "change mpeg audio timestamp offset from " +
                              i.timestampOffset +
                              " to " +
                              e.start
                            ),
                              (i.timestampOffset = e.start));
                        }
                      }
                    },
                  },
                  {
                    key: "onManifestParsed",
                    value: function (e) {
                      var t = e.audio,
                        r = e.video,
                        i = 0;
                      e.altAudio &&
                        (t || r) &&
                        ((i = (t ? 1 : 0) + (r ? 1 : 0)),
                          c.logger.log(i + " sourceBuffer(s) expected")),
                        (this.sourceBufferNb = i);
                    },
                  },
                  {
                    key: "onMediaAttaching",
                    value: function (e) {
                      var t = (this.media = e.media);
                      if (t) {
                        var r = (this.mediaSource = new MediaSource());
                        (this.onmso = this.onMediaSourceOpen.bind(this)),
                          (this.onmse = this.onMediaSourceEnded.bind(this)),
                          (this.onmsc = this.onMediaSourceClose.bind(this)),
                          r.addEventListener("sourceopen", this.onmso),
                          r.addEventListener("sourceended", this.onmse),
                          r.addEventListener("sourceclose", this.onmsc),
                          (t.src = URL.createObjectURL(r));
                      }
                    },
                  },
                  {
                    key: "onMediaDetaching",
                    value: function () {
                      c.logger.log("media source detaching");
                      var e = this.mediaSource;
                      if (e) {
                        if ("open" === e.readyState)
                          try {
                            e.endOfStream();
                          } catch (e) {
                            c.logger.warn(
                              "onMediaDetaching:" +
                              e.message +
                              " while calling endOfStream"
                            );
                          }
                        e.removeEventListener("sourceopen", this.onmso),
                          e.removeEventListener("sourceended", this.onmse),
                          e.removeEventListener("sourceclose", this.onmsc),
                          this.media &&
                          (URL.revokeObjectURL(this.media.src),
                            this.media.removeAttribute("src"),
                            this.media.load()),
                          (this.mediaSource = null),
                          (this.media = null),
                          (this.pendingTracks = {}),
                          (this.tracks = {}),
                          (this.sourceBuffer = {}),
                          (this.flushRange = []),
                          (this.segments = []),
                          (this.appended = 0);
                      }
                      (this.onmso = this.onmse = this.onmsc = null),
                        this.hls.trigger(u.default.MEDIA_DETACHED);
                    },
                  },
                  {
                    key: "onMediaSourceOpen",
                    value: function () {
                      c.logger.log("media source opened"),
                        this.hls.trigger(u.default.MEDIA_ATTACHED, {
                          media: this.media,
                        });
                      var e = this.mediaSource;
                      e && e.removeEventListener("sourceopen", this.onmso),
                        this.checkPendingTracks();
                    },
                  },
                  {
                    key: "checkPendingTracks",
                    value: function () {
                      var e = this.pendingTracks,
                        t = Object.keys(e).length;
                      t &&
                        (this.sourceBufferNb <= t ||
                          0 === this.sourceBufferNb) &&
                        (this.createSourceBuffers(e),
                          (this.pendingTracks = {}),
                          this.doAppending());
                    },
                  },
                  {
                    key: "onMediaSourceClose",
                    value: function () {
                      c.logger.log("media source closed");
                    },
                  },
                  {
                    key: "onMediaSourceEnded",
                    value: function () {
                      c.logger.log("media source ended");
                    },
                  },
                  {
                    key: "onSBUpdateEnd",
                    value: function () {
                      if (this.audioTimestampOffset) {
                        var e = this.sourceBuffer.audio;
                        c.logger.warn(
                          "change mpeg audio timestamp offset from " +
                          e.timestampOffset +
                          " to " +
                          this.audioTimestampOffset
                        ),
                          (e.timestampOffset = this.audioTimestampOffset),
                          delete this.audioTimestampOffset;
                      }
                      this._needsFlush && this.doFlush(),
                        this._needsEos && this.checkEos(),
                        (this.appending = !1);
                      var t = this.parent,
                        r = this.segments.reduce(function (e, r) {
                          return r.parent === t ? e + 1 : e;
                        }, 0);
                      this.hls.trigger(u.default.BUFFER_APPENDED, {
                        parent: t,
                        pending: r,
                      }),
                        this._needsFlush || this.doAppending(),
                        this.updateMediaElementDuration();
                    },
                  },
                  {
                    key: "onSBUpdateError",
                    value: function (e) {
                      c.logger.error("sourceBuffer error:", e),
                        this.hls.trigger(u.default.ERROR, {
                          type: h.ErrorTypes.MEDIA_ERROR,
                          details: h.ErrorDetails.BUFFER_APPENDING_ERROR,
                          fatal: !1,
                        });
                    },
                  },
                  {
                    key: "onBufferReset",
                    value: function () {
                      var e = this.sourceBuffer;
                      for (var t in e) {
                        var r = e[t];
                        try {
                          this.mediaSource.removeSourceBuffer(r),
                            r.removeEventListener("updateend", this.onsbue),
                            r.removeEventListener("error", this.onsbe);
                        } catch (e) { }
                      }
                      (this.sourceBuffer = {}),
                        (this.flushRange = []),
                        (this.segments = []),
                        (this.appended = 0);
                    },
                  },
                  {
                    key: "onBufferCodecs",
                    value: function (e) {
                      if (0 === Object.keys(this.sourceBuffer).length) {
                        for (var t in e) this.pendingTracks[t] = e[t];
                        var r = this.mediaSource;
                        r &&
                          "open" === r.readyState &&
                          this.checkPendingTracks();
                      }
                    },
                  },
                  {
                    key: "createSourceBuffers",
                    value: function (e) {
                      var t = this.sourceBuffer,
                        r = this.mediaSource;
                      for (var i in e)
                        if (!t[i]) {
                          var a = e[i],
                            n = a.levelCodec || a.codec,
                            s = a.container + ";codecs=" + n;
                          c.logger.log("creating sourceBuffer(" + s + ")");
                          try {
                            var o = (t[i] = r.addSourceBuffer(s));
                            o.addEventListener("updateend", this.onsbue),
                              o.addEventListener("error", this.onsbe),
                              (this.tracks[i] = {
                                codec: n,
                                container: a.container,
                              }),
                              (a.buffer = o);
                          } catch (e) {
                            c.logger.error(
                              "error while trying to add sourceBuffer:" +
                              e.message
                            ),
                              this.hls.trigger(u.default.ERROR, {
                                type: h.ErrorTypes.MEDIA_ERROR,
                                details: h.ErrorDetails.BUFFER_ADD_CODEC_ERROR,
                                fatal: !1,
                                err: e,
                                mimeType: s,
                              });
                          }
                        }
                      this.hls.trigger(u.default.BUFFER_CREATED, { tracks: e });
                    },
                  },
                  {
                    key: "onBufferAppending",
                    value: function (e) {
                      this._needsFlush ||
                        (this.segments
                          ? this.segments.push(e)
                          : (this.segments = [e]),
                          this.doAppending());
                    },
                  },
                  {
                    key: "onBufferAppendFail",
                    value: function (e) {
                      c.logger.error("sourceBuffer error:", e.event),
                        this.hls.trigger(u.default.ERROR, {
                          type: h.ErrorTypes.MEDIA_ERROR,
                          details: h.ErrorDetails.BUFFER_APPENDING_ERROR,
                          fatal: !1,
                        });
                    },
                  },
                  {
                    key: "onBufferEos",
                    value: function (e) {
                      var t = this.sourceBuffer,
                        r = e.type;
                      for (var i in t)
                        (r && i !== r) ||
                          t[i].ended ||
                          ((t[i].ended = !0),
                            c.logger.log(i + " sourceBuffer now EOS"));
                      this.checkEos();
                    },
                  },
                  {
                    key: "checkEos",
                    value: function () {
                      var e = this.sourceBuffer,
                        t = this.mediaSource;
                      if (!t || "open" !== t.readyState)
                        return void (this._needsEos = !1);
                      for (var r in e) {
                        var i = e[r];
                        if (!i.ended) return;
                        if (i.updating) return void (this._needsEos = !0);
                      }
                      c.logger.log(
                        "all media data available, signal endOfStream() to MediaSource and stop loading fragment"
                      );
                      try {
                        t.endOfStream();
                      } catch (e) {
                        c.logger.warn(
                          "exception while calling mediaSource.endOfStream()"
                        );
                      }
                      this._needsEos = !1;
                    },
                  },
                  {
                    key: "onBufferFlushing",
                    value: function (e) {
                      this.flushRange.push({
                        start: e.startOffset,
                        end: e.endOffset,
                        type: e.type,
                      }),
                        (this.flushBufferCounter = 0),
                        this.doFlush();
                    },
                  },
                  {
                    key: "onLevelUpdated",
                    value: function (e) {
                      var t = e.details;
                      0 !== t.fragments.length &&
                        ((this._levelDuration =
                          t.totalduration + t.fragments[0].start),
                          this.updateMediaElementDuration());
                    },
                  },
                  {
                    key: "updateMediaElementDuration",
                    value: function () {
                      var e = this.media,
                        t = this.mediaSource,
                        r = this.sourceBuffer,
                        i = this._levelDuration;
                      if (
                        null !== i &&
                        e &&
                        t &&
                        r &&
                        0 !== e.readyState &&
                        "open" === t.readyState
                      ) {
                        for (var a in r) if (r[a].updating) return;
                        null === this._msDuration &&
                          (this._msDuration = t.duration);
                        var n = e.duration;
                        ((i > this._msDuration && i > n) ||
                          n === 1 / 0 ||
                          isNaN(n)) &&
                          (c.logger.log(
                            "Updating mediasource duration to " + i.toFixed(3)
                          ),
                            (this._msDuration = t.duration = i));
                      }
                    },
                  },
                  {
                    key: "doFlush",
                    value: function () {
                      for (; this.flushRange.length;) {
                        var e = this.flushRange[0];
                        if (!this.flushBuffer(e.start, e.end, e.type))
                          return void (this._needsFlush = !0);
                        this.flushRange.shift(), (this.flushBufferCounter = 0);
                      }
                      if (0 === this.flushRange.length) {
                        this._needsFlush = !1;
                        var t = 0,
                          r = this.sourceBuffer;
                        try {
                          for (var i in r) t += r[i].buffered.length;
                        } catch (e) {
                          c.logger.error(
                            "error while accessing sourceBuffer.buffered"
                          );
                        }
                        (this.appended = t),
                          this.hls.trigger(u.default.BUFFER_FLUSHED);
                      }
                    },
                  },
                  {
                    key: "doAppending",
                    value: function () {
                      var e = this.hls,
                        t = this.sourceBuffer,
                        r = this.segments;
                      if (Object.keys(t).length) {
                        if (this.media.error)
                          return (
                            (this.segments = []),
                            void c.logger.error(
                              "trying to append although a media error occured, flush segment and abort"
                            )
                          );
                        if (this.appending) return;
                        if (r && r.length) {
                          var i = r.shift();
                          try {
                            var a = i.type,
                              n = t[a];
                            n
                              ? n.updating
                                ? r.unshift(i)
                                : ((n.ended = !1),
                                  (this.parent = i.parent),
                                  n.appendBuffer(i.data),
                                  (this.appendError = 0),
                                  this.appended++,
                                  (this.appending = !0))
                              : this.onSBUpdateEnd();
                          } catch (t) {
                            c.logger.error(
                              "error while trying to append buffer:" + t.message
                            ),
                              r.unshift(i);
                            var s = {
                              type: h.ErrorTypes.MEDIA_ERROR,
                              parent: i.parent,
                            };
                            if (22 === t.code)
                              return (
                                (this.segments = []),
                                (s.details = h.ErrorDetails.BUFFER_FULL_ERROR),
                                (s.fatal = !1),
                                void e.trigger(u.default.ERROR, s)
                              );
                            if (
                              (this.appendError
                                ? this.appendError++
                                : (this.appendError = 1),
                                (s.details = h.ErrorDetails.BUFFER_APPEND_ERROR),
                                this.appendError > e.config.appendErrorMaxRetry)
                            )
                              return (
                                c.logger.log(
                                  "fail " +
                                  e.config.appendErrorMaxRetry +
                                  " times to append segment in sourceBuffer"
                                ),
                                (r = []),
                                (s.fatal = !0),
                                void e.trigger(u.default.ERROR, s)
                              );
                            (s.fatal = !1), e.trigger(u.default.ERROR, s);
                          }
                        }
                      }
                    },
                  },
                  {
                    key: "flushBuffer",
                    value: function (e, t, r) {
                      var i,
                        a,
                        n,
                        s,
                        o,
                        l,
                        u = this.sourceBuffer;
                      if (Object.keys(u).length) {
                        if (
                          (c.logger.log(
                            "flushBuffer,pos/start/end: " +
                            this.media.currentTime.toFixed(3) +
                            "/" +
                            e +
                            "/" +
                            t
                          ),
                            this.flushBufferCounter < this.appended)
                        ) {
                          for (var d in u)
                            if (!r || d === r) {
                              if (((i = u[d]), (i.ended = !1), i.updating))
                                return (
                                  c.logger.warn(
                                    "cannot flush, sb updating in progress"
                                  ),
                                  !1
                                );
                              try {
                                for (a = 0; a < i.buffered.length; a++)
                                  if (
                                    ((n = i.buffered.start(a)),
                                      (s = i.buffered.end(a)),
                                      navigator.userAgent
                                        .toLowerCase()
                                        .indexOf("firefox") !== -1 &&
                                        t === Number.POSITIVE_INFINITY
                                        ? ((o = e), (l = t))
                                        : ((o = Math.max(n, e)),
                                          (l = Math.min(s, t))),
                                      Math.min(l, s) - o > 0.5)
                                  )
                                    return (
                                      this.flushBufferCounter++,
                                      c.logger.log(
                                        "flush " +
                                        d +
                                        " [" +
                                        o +
                                        "," +
                                        l +
                                        "], of [" +
                                        n +
                                        "," +
                                        s +
                                        "], pos:" +
                                        this.media.currentTime
                                      ),
                                      i.remove(o, l),
                                      !1
                                    );
                              } catch (e) {
                                c.logger.warn(
                                  "exception while accessing sourcebuffer, it might have been removed from MediaSource"
                                );
                              }
                            }
                        } else c.logger.warn("abort flushing too many retries");
                        c.logger.log("buffer flushed");
                      }
                      return !0;
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = g;
        },
        { 31: 31, 32: 32, 33: 33, 51: 51 },
      ],
      9: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = (function (e) {
              function t(e) {
                return (
                  a(this, t),
                  n(
                    this,
                    (t.__proto__ || Object.getPrototypeOf(t)).call(
                      this,
                      e,
                      u.default.FPS_DROP_LEVEL_CAPPING,
                      u.default.MEDIA_ATTACHING,
                      u.default.MANIFEST_PARSED
                    )
                  )
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      this.hls.config.capLevelToPlayerSize &&
                        ((this.media = this.restrictedLevels = null),
                          (this.autoLevelCapping = Number.POSITIVE_INFINITY),
                          this.timer && (this.timer = clearInterval(this.timer)));
                    },
                  },
                  {
                    key: "onFpsDropLevelCapping",
                    value: function (e) {
                      this.restrictedLevels || (this.restrictedLevels = []),
                        this.isLevelRestricted(e.droppedLevel) ||
                        this.restrictedLevels.push(e.droppedLevel);
                    },
                  },
                  {
                    key: "onMediaAttaching",
                    value: function (e) {
                      this.media =
                        e.media instanceof HTMLVideoElement ? e.media : null;
                    },
                  },
                  {
                    key: "onManifestParsed",
                    value: function (e) {
                      var t = this.hls;
                      t.config.capLevelToPlayerSize &&
                        ((this.autoLevelCapping = Number.POSITIVE_INFINITY),
                          (this.levels = e.levels),
                          (t.firstLevel = this.getMaxLevel(e.firstLevel)),
                          clearInterval(this.timer),
                          (this.timer = setInterval(
                            this.detectPlayerSize.bind(this),
                            1e3
                          )),
                          this.detectPlayerSize());
                    },
                  },
                  {
                    key: "detectPlayerSize",
                    value: function () {
                      if (this.media) {
                        var e = this.levels ? this.levels.length : 0;
                        if (e) {
                          var t = this.hls;
                          (t.autoLevelCapping = this.getMaxLevel(e - 1)),
                            t.autoLevelCapping > this.autoLevelCapping &&
                            t.streamController.nextLevelSwitch(),
                            (this.autoLevelCapping = t.autoLevelCapping);
                        }
                      }
                    },
                  },
                  {
                    key: "getMaxLevel",
                    value: function (e) {
                      var t = 0,
                        r = void 0,
                        i = void 0,
                        a = this.mediaWidth,
                        n = this.mediaHeight,
                        s = 0,
                        o = 0;
                      for (
                        r = 0;
                        r <= e &&
                        ((i = this.levels[r]), !this.isLevelRestricted(r)) &&
                        ((t = r),
                          (s = i.width),
                          (o = i.height),
                          !(a <= s || n <= o));
                        r++
                      );
                      return t;
                    },
                  },
                  {
                    key: "isLevelRestricted",
                    value: function (e) {
                      return !(
                        !this.restrictedLevels ||
                        this.restrictedLevels.indexOf(e) === -1
                      );
                    },
                  },
                  {
                    key: "contentScaleFactor",
                    get: function () {
                      var e = 1;
                      try {
                        e = window.devicePixelRatio;
                      } catch (e) { }
                      return e;
                    },
                  },
                  {
                    key: "mediaWidth",
                    get: function () {
                      var e = void 0,
                        t = this.media;
                      return (
                        t &&
                        ((e = t.width || t.clientWidth || t.offsetWidth),
                          (e *= this.contentScaleFactor)),
                        e
                      );
                    },
                  },
                  {
                    key: "mediaHeight",
                    get: function () {
                      var e = void 0,
                        t = this.media;
                      return (
                        t &&
                        ((e = t.height || t.clientHeight || t.offsetHeight),
                          (e *= this.contentScaleFactor)),
                        e
                      );
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = c;
        },
        { 32: 32, 33: 33 },
      ],
      10: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(51),
            h = (function (e) {
              function t(e) {
                return (
                  a(this, t),
                  n(
                    this,
                    (t.__proto__ || Object.getPrototypeOf(t)).call(
                      this,
                      e,
                      u.default.MEDIA_ATTACHING
                    )
                  )
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      this.timer && clearInterval(this.timer),
                        (this.isVideoPlaybackQualityAvailable = !1);
                    },
                  },
                  {
                    key: "onMediaAttaching",
                    value: function (e) {
                      var t = this.hls.config;
                      if (t.capLevelOnFPSDrop) {
                        "function" ==
                          typeof (this.video =
                            e.media instanceof HTMLVideoElement
                              ? e.media
                              : null).getVideoPlaybackQuality &&
                          (this.isVideoPlaybackQualityAvailable = !0),
                          clearInterval(this.timer),
                          (this.timer = setInterval(
                            this.checkFPSInterval.bind(this),
                            t.fpsDroppedMonitoringPeriod
                          ));
                      }
                    },
                  },
                  {
                    key: "checkFPS",
                    value: function (e, t, r) {
                      var i = performance.now();
                      if (t) {
                        if (this.lastTime) {
                          var a = i - this.lastTime,
                            n = r - this.lastDroppedFrames,
                            s = t - this.lastDecodedFrames,
                            o = (1e3 * n) / a,
                            l = this.hls;
                          if (
                            (l.trigger(u.default.FPS_DROP, {
                              currentDropped: n,
                              currentDecoded: s,
                              totalDroppedFrames: r,
                            }),
                              o > 0 &&
                              n > l.config.fpsDroppedMonitoringThreshold * s)
                          ) {
                            var d = l.currentLevel;
                            c.logger.warn(
                              "drop FPS ratio greater than max allowed value for currentLevel: " +
                              d
                            ),
                              d > 0 &&
                              (l.autoLevelCapping === -1 ||
                                l.autoLevelCapping >= d) &&
                              ((d -= 1),
                                l.trigger(u.default.FPS_DROP_LEVEL_CAPPING, {
                                  level: d,
                                  droppedLevel: l.currentLevel,
                                }),
                                (l.autoLevelCapping = d),
                                l.streamController.nextLevelSwitch());
                          }
                        }
                        (this.lastTime = i),
                          (this.lastDroppedFrames = r),
                          (this.lastDecodedFrames = t);
                      }
                    },
                  },
                  {
                    key: "checkFPSInterval",
                    value: function () {
                      var e = this.video;
                      if (e)
                        if (this.isVideoPlaybackQualityAvailable) {
                          var t = e.getVideoPlaybackQuality();
                          this.checkFPS(
                            e,
                            t.totalVideoFrames,
                            t.droppedVideoFrames
                          );
                        } else
                          this.checkFPS(
                            e,
                            e.webkitDecodedFrameCount,
                            e.webkitDroppedFrameCount
                          );
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = h;
        },
        { 32: 32, 33: 33, 51: 51 },
      ],
      11: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.MEDIA_ATTACHED,
                    u.default.MEDIA_DETACHING,
                    u.default.FRAG_PARSING_METADATA
                  )
                );
                return (r.id3Track = void 0), (r.media = void 0), r;
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onMediaAttached",
                    value: function (e) {
                      (this.media = e.media),
                        this.media &&
                        ((this.id3Track = this.media.addTextTrack(
                          "metadata",
                          "id3"
                        )),
                          (this.id3Track.mode = "hidden"));
                    },
                  },
                  {
                    key: "onMediaDetaching",
                    value: function () {
                      this.media = void 0;
                    },
                  },
                  {
                    key: "onFragParsingMetadata",
                    value: function (e) {
                      var t = e.frag,
                        r = e.samples,
                        i = t.start,
                        a = t.start + t.duration;
                      i === a && (a += 1e-4);
                      for (
                        var n =
                          window.WebKitDataCue ||
                          window.VTTCue ||
                          window.TextTrackCue,
                        s = 0;
                        s < r.length;
                        s++
                      ) {
                        var o = this.parseID3Frame(r[s].data),
                          l = this.decodeID3Frame(o);
                        if (l) {
                          var u = new n(i, a, "");
                          (u.value = l), this.id3Track.addCue(u);
                        }
                      }
                    },
                  },
                  {
                    key: "parseID3Frame",
                    value: function (e) {
                      if (
                        !(e.length < 21) &&
                        73 === e[0] &&
                        68 === e[1] &&
                        51 === e[2]
                      ) {
                        var t = String.fromCharCode(e[10], e[11], e[12], e[13]);
                        return (e = e.subarray(20)), { type: t, data: e };
                      }
                    },
                  },
                  {
                    key: "decodeID3Frame",
                    value: function (e) {
                      return "TXXX" === e.type
                        ? this.decodeTxxxFrame(e)
                        : "PRIV" === e.type
                          ? this.decodePrivFrame(e)
                          : "T" === e.type[0]
                            ? this.decodeTextFrame(e)
                            : void 0;
                    },
                  },
                  {
                    key: "decodeTxxxFrame",
                    value: function (e) {
                      if (!(e.size < 2) && 3 === e.data[0]) {
                        var t = 1,
                          r = this.utf8ArrayToStr(e.data.subarray(t));
                        t += r.length + 1;
                        return {
                          key: "TXXX",
                          description: r,
                          data: this.utf8ArrayToStr(e.data.subarray(t)),
                        };
                      }
                    },
                  },
                  {
                    key: "decodeTextFrame",
                    value: function (e) {
                      if (!(e.size < 2) && 3 === e.data[0]) {
                        var t = e.data.subarray(1);
                        return { key: e.type, data: this.utf8ArrayToStr(t) };
                      }
                    },
                  },
                  {
                    key: "decodePrivFrame",
                    value: function (e) {
                      if (!(e.size < 2)) {
                        var t = this.utf8ArrayToStr(e.data);
                        return {
                          key: "PRIV",
                          info: t,
                          data: e.data.subarray(t.length + 1).buffer,
                        };
                      }
                    },
                  },
                  {
                    key: "utf8ArrayToStr",
                    value: function (e) {
                      for (
                        var t = void 0, r = void 0, i = "", a = 0, n = e.length;
                        a < n;

                      ) {
                        var s = e[a++];
                        switch (s >> 4) {
                          case 0:
                            return i;
                          case 1:
                          case 2:
                          case 3:
                          case 4:
                          case 5:
                          case 6:
                          case 7:
                            i += String.fromCharCode(s);
                            break;
                          case 12:
                          case 13:
                            (t = e[a++]),
                              (i += String.fromCharCode(
                                ((31 & s) << 6) | (63 & t)
                              ));
                            break;
                          case 14:
                            (t = e[a++]),
                              (r = e[a++]),
                              (i += String.fromCharCode(
                                ((15 & s) << 12) |
                                ((63 & t) << 6) |
                                ((63 & r) << 0)
                              ));
                        }
                      }
                      return i;
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = c;
        },
        { 32: 32, 33: 33 },
      ],
      12: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(51),
            h = e(31),
            g = e(35),
            v = i(g),
            p = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.MANIFEST_LOADED,
                    u.default.LEVEL_LOADED,
                    u.default.FRAG_LOADED,
                    u.default.ERROR
                  )
                );
                return (r.ontick = r.tick.bind(r)), (r._manualLevel = -1), r;
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      this.timer &&
                        (clearTimeout(this.timer), (this.timer = null)),
                        (this._manualLevel = -1);
                    },
                  },
                  {
                    key: "startLoad",
                    value: function () {
                      this.canload = !0;
                      var e = this._levels;
                      e &&
                        e.forEach(function (e) {
                          e.loadError = 0;
                          var t = e.details;
                          t && t.live && (e.details = void 0);
                        }),
                        this.timer && this.tick();
                    },
                  },
                  {
                    key: "stopLoad",
                    value: function () {
                      this.canload = !1;
                    },
                  },
                  {
                    key: "onManifestLoaded",
                    value: function (e) {
                      var t,
                        r = [],
                        i = [],
                        a = {},
                        n = !1,
                        s = !1,
                        o = this.hls,
                        l = /chrome|firefox/.test(
                          navigator.userAgent.toLowerCase()
                        ),
                        d = function (e, t) {
                          return MediaSource.isTypeSupported(
                            e + "/mp4;codecs=" + t
                          );
                        };
                      if (
                        (e.levels.forEach(function (e) {
                          e.videoCodec && (n = !0),
                            l &&
                            e.audioCodec &&
                            e.audioCodec.indexOf("mp4a.40.34") !== -1 &&
                            (e.audioCodec = void 0),
                            (e.audioCodec || (e.attrs && e.attrs.AUDIO)) &&
                            (s = !0);
                          var t = a[e.bitrate];
                          void 0 === t
                            ? ((a[e.bitrate] = r.length),
                              (e.url = [e.url]),
                              (e.urlId = 0),
                              r.push(e))
                            : r[t].url.push(e.url);
                        }),
                          n && s
                            ? r.forEach(function (e) {
                              e.videoCodec && i.push(e);
                            })
                            : (i = r),
                          (i = i.filter(function (e) {
                            var t = e.audioCodec,
                              r = e.videoCodec;
                            return (!t || d("audio", t)) && (!r || d("video", r));
                          })),
                          i.length)
                      ) {
                        (t = i[0].bitrate),
                          i.sort(function (e, t) {
                            return e.bitrate - t.bitrate;
                          }),
                          (this._levels = i);
                        for (var f = 0; f < i.length; f++)
                          if (i[f].bitrate === t) {
                            (this._firstLevel = f),
                              c.logger.log(
                                "manifest loaded," +
                                i.length +
                                " level(s) found, first bitrate:" +
                                t
                              );
                            break;
                          }
                        o.trigger(u.default.MANIFEST_PARSED, {
                          levels: i,
                          firstLevel: this._firstLevel,
                          stats: e.stats,
                          audio: s,
                          video: n,
                          altAudio: e.audioTracks.length > 0,
                        });
                      } else
                        o.trigger(u.default.ERROR, {
                          type: h.ErrorTypes.MEDIA_ERROR,
                          details:
                            h.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR,
                          fatal: !0,
                          url: o.url,
                          reason:
                            "no level with compatible codecs found in manifest",
                        });
                    },
                  },
                  {
                    key: "setLevelInternal",
                    value: function (e) {
                      var t = this._levels,
                        r = this.hls;
                      if (e >= 0 && e < t.length) {
                        if (
                          (this.timer &&
                            (clearTimeout(this.timer), (this.timer = null)),
                            this._level !== e)
                        ) {
                          c.logger.log("switching to level " + e),
                            (this._level = e);
                          var i = t[e];
                          (i.level = e),
                            r.trigger(u.default.LEVEL_SWITCH, i),
                            r.trigger(u.default.LEVEL_SWITCHING, i);
                        }
                        var a = t[e],
                          n = a.details;
                        if (!n || n.live === !0) {
                          var s = a.urlId;
                          r.trigger(u.default.LEVEL_LOADING, {
                            url: a.url[s],
                            level: e,
                            id: s,
                          });
                        }
                      } else
                        r.trigger(u.default.ERROR, {
                          type: h.ErrorTypes.OTHER_ERROR,
                          details: h.ErrorDetails.LEVEL_SWITCH_ERROR,
                          level: e,
                          fatal: !1,
                          reason: "invalid level idx",
                        });
                    },
                  },
                  {
                    key: "onError",
                    value: function (e) {
                      if (!e.fatal) {
                        var t = e.details,
                          r = this.hls,
                          i = void 0,
                          a = void 0,
                          n = !1;
                        switch (t) {
                          case h.ErrorDetails.FRAG_LOAD_ERROR:
                          case h.ErrorDetails.FRAG_LOAD_TIMEOUT:
                          case h.ErrorDetails.FRAG_LOOP_LOADING_ERROR:
                          case h.ErrorDetails.KEY_LOAD_ERROR:
                          case h.ErrorDetails.KEY_LOAD_TIMEOUT:
                            i = e.frag.level;
                            break;
                          case h.ErrorDetails.LEVEL_LOAD_ERROR:
                          case h.ErrorDetails.LEVEL_LOAD_TIMEOUT:
                            (i = e.context.level), (n = !0);
                            break;
                          case h.ErrorDetails.REMUX_ALLOC_ERROR:
                            i = e.level;
                        }
                        if (void 0 !== i) {
                          (a = this._levels[i]),
                            a.loadError ? a.loadError++ : (a.loadError = 1);
                          var s = a.url.length;
                          if (s > 1 && a.loadError < s)
                            (a.urlId = (a.urlId + 1) % s),
                              (a.details = void 0),
                              c.logger.warn(
                                "level controller," +
                                t +
                                " for level " +
                                i +
                                ": switching to redundant stream id " +
                                a.urlId
                              );
                          else {
                            if (this._manualLevel === -1 && i)
                              c.logger.warn(
                                "level controller," +
                                t +
                                ": switch-down for next fragment"
                              ),
                                (r.nextAutoLevel = Math.max(0, i - 1));
                            else if (a && a.details && a.details.live)
                              c.logger.warn(
                                "level controller," +
                                t +
                                " on live stream, discard"
                              ),
                                n && (this._level = void 0);
                            else if (
                              t === h.ErrorDetails.LEVEL_LOAD_ERROR ||
                              t === h.ErrorDetails.LEVEL_LOAD_TIMEOUT
                            ) {
                              var o = r.media,
                                l =
                                  o &&
                                  v.default.isBuffered(o, o.currentTime) &&
                                  v.default.isBuffered(o, o.currentTime + 0.5);
                              if (l) {
                                var u = r.config.levelLoadingRetryDelay;
                                c.logger.warn(
                                  "level controller," +
                                  t +
                                  ", but media buffered, retry in " +
                                  u +
                                  "ms"
                                ),
                                  (this.timer = setTimeout(this.ontick, u));
                              } else
                                c.logger.error(
                                  "cannot recover " + t + " error"
                                ),
                                  (this._level = void 0),
                                  this.timer &&
                                  (clearTimeout(this.timer),
                                    (this.timer = null)),
                                  (e.fatal = !0);
                            }
                          }
                        }
                      }
                    },
                  },
                  {
                    key: "onFragLoaded",
                    value: function (e) {
                      var t = e.frag;
                      if (t && "main" === t.type) {
                        var r = this._levels[t.level];
                        r && (r.loadError = 0);
                      }
                    },
                  },
                  {
                    key: "onLevelLoaded",
                    value: function (e) {
                      var t = e.level;
                      if (t === this._level) {
                        var r = this._levels[t];
                        r.loadError = 0;
                        var i = e.details;
                        if (i.live) {
                          var a =
                            1e3 *
                            (i.averagetargetduration
                              ? i.averagetargetduration
                              : i.targetduration),
                            n = r.details;
                          n &&
                            i.endSN === n.endSN &&
                            ((a /= 2),
                              c.logger.log(
                                "same live playlist, reload twice faster"
                              )),
                            (a -= performance.now() - e.stats.trequest),
                            (a = Math.max(1e3, Math.round(a))),
                            c.logger.log(
                              "live playlist, reload in " + a + " ms"
                            ),
                            (this.timer = setTimeout(this.ontick, a));
                        } else this.timer = null;
                      }
                    },
                  },
                  {
                    key: "tick",
                    value: function () {
                      var e = this._level;
                      if (void 0 !== e && this.canload) {
                        var t = this._levels[e];
                        if (t && t.url) {
                          var r = t.urlId;
                          this.hls.trigger(u.default.LEVEL_LOADING, {
                            url: t.url[r],
                            level: e,
                            id: r,
                          });
                        }
                      }
                    },
                  },
                  {
                    key: "levels",
                    get: function () {
                      return this._levels;
                    },
                  },
                  {
                    key: "level",
                    get: function () {
                      return this._level;
                    },
                    set: function (e) {
                      var t = this._levels;
                      t &&
                        t.length > e &&
                        ((this._level === e && void 0 !== t[e].details) ||
                          this.setLevelInternal(e));
                    },
                  },
                  {
                    key: "manualLevel",
                    get: function () {
                      return this._manualLevel;
                    },
                    set: function (e) {
                      (this._manualLevel = e),
                        void 0 === this._startLevel && (this._startLevel = e),
                        e !== -1 && (this.level = e);
                    },
                  },
                  {
                    key: "firstLevel",
                    get: function () {
                      return this._firstLevel;
                    },
                    set: function (e) {
                      this._firstLevel = e;
                    },
                  },
                  {
                    key: "startLevel",
                    get: function () {
                      if (void 0 === this._startLevel) {
                        var e = this.hls.config.startLevel;
                        return void 0 !== e ? e : this._firstLevel;
                      }
                      return this._startLevel;
                    },
                    set: function (e) {
                      this._startLevel = e;
                    },
                  },
                  {
                    key: "nextLoadLevel",
                    get: function () {
                      return this._manualLevel !== -1
                        ? this._manualLevel
                        : this.hls.nextAutoLevel;
                    },
                    set: function (e) {
                      (this.level = e),
                        this._manualLevel === -1 &&
                        (this.hls.nextAutoLevel = e);
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = p;
        },
        { 31: 31, 32: 32, 33: 33, 35: 35, 51: 51 },
      ],
      13: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(46),
            u = i(l),
            d = e(35),
            f = i(d),
            c = e(25),
            h = i(c),
            g = e(33),
            v = i(g),
            p = e(32),
            y = i(p),
            m = e(36),
            E = i(m),
            b = e(52),
            T = i(b),
            _ = e(31),
            k = e(51),
            R = {
              STOPPED: "STOPPED",
              IDLE: "IDLE",
              KEY_LOADING: "KEY_LOADING",
              FRAG_LOADING: "FRAG_LOADING",
              FRAG_LOADING_WAITING_RETRY: "FRAG_LOADING_WAITING_RETRY",
              WAITING_LEVEL: "WAITING_LEVEL",
              PARSING: "PARSING",
              PARSED: "PARSED",
              BUFFER_FLUSHING: "BUFFER_FLUSHING",
              ENDED: "ENDED",
              ERROR: "ERROR",
            },
            A = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    v.default.MEDIA_ATTACHED,
                    v.default.MEDIA_DETACHING,
                    v.default.MANIFEST_LOADING,
                    v.default.MANIFEST_PARSED,
                    v.default.LEVEL_LOADED,
                    v.default.KEY_LOADED,
                    v.default.FRAG_LOADED,
                    v.default.FRAG_LOAD_EMERGENCY_ABORTED,
                    v.default.FRAG_PARSING_INIT_SEGMENT,
                    v.default.FRAG_PARSING_DATA,
                    v.default.FRAG_PARSED,
                    v.default.ERROR,
                    v.default.AUDIO_TRACK_SWITCHING,
                    v.default.AUDIO_TRACK_SWITCHED,
                    v.default.BUFFER_CREATED,
                    v.default.BUFFER_APPENDED,
                    v.default.BUFFER_FLUSHED
                  )
                );
                return (
                  (r.config = e.config),
                  (r.audioCodecSwap = !1),
                  (r.ticks = 0),
                  (r._state = R.STOPPED),
                  (r.ontick = r.tick.bind(r)),
                  r
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      this.stopLoad(),
                        this.timer &&
                        (clearInterval(this.timer), (this.timer = null)),
                        y.default.prototype.destroy.call(this),
                        (this.state = R.STOPPED);
                    },
                  },
                  {
                    key: "startLoad",
                    value: function (e) {
                      if (this.levels) {
                        var t = this.lastCurrentTime,
                          r = this.hls;
                        if (
                          (this.stopLoad(),
                            this.timer ||
                            (this.timer = setInterval(this.ontick, 100)),
                            (this.level = -1),
                            (this.fragLoadError = 0),
                            !this.startFragRequested)
                        ) {
                          var i = r.startLevel;
                          i === -1 && ((i = 0), (this.bitrateTest = !0)),
                            (this.level = r.nextLoadLevel = i),
                            (this.loadedmetadata = !1);
                        }
                        t > 0 &&
                          e === -1 &&
                          (k.logger.log(
                            "override startPosition with lastCurrentTime @" +
                            t.toFixed(3)
                          ),
                            (e = t)),
                          (this.state = R.IDLE),
                          (this.nextLoadPosition =
                            this.startPosition =
                            this.lastCurrentTime =
                            e),
                          this.tick();
                      } else
                        (this.forceStartLoad = !0), (this.state = R.STOPPED);
                    },
                  },
                  {
                    key: "stopLoad",
                    value: function () {
                      var e = this.fragCurrent;
                      e &&
                        (e.loader && e.loader.abort(),
                          (this.fragCurrent = null)),
                        (this.fragPrevious = null),
                        this.demuxer &&
                        (this.demuxer.destroy(), (this.demuxer = null)),
                        (this.state = R.STOPPED),
                        (this.forceStartLoad = !1);
                    },
                  },
                  {
                    key: "tick",
                    value: function () {
                      1 === ++this.ticks &&
                        (this.doTick(),
                          this.ticks > 1 && setTimeout(this.tick, 1),
                          (this.ticks = 0));
                    },
                  },
                  {
                    key: "doTick",
                    value: function () {
                      switch (this.state) {
                        case R.ERROR:
                          break;
                        case R.BUFFER_FLUSHING:
                          this.fragLoadError = 0;
                          break;
                        case R.IDLE:
                          this._doTickIdle();
                          break;
                        case R.WAITING_LEVEL:
                          var e = this.levels[this.level];
                          e && e.details && (this.state = R.IDLE);
                          break;
                        case R.FRAG_LOADING_WAITING_RETRY:
                          var t = performance.now(),
                            r = this.retryDate;
                          (!r ||
                            t >= r ||
                            (this.media && this.media.seeking)) &&
                            (k.logger.log(
                              "mediaController: retryDate reached, switch back to IDLE state"
                            ),
                              (this.state = R.IDLE));
                          break;
                        case R.ERROR:
                        case R.STOPPED:
                        case R.FRAG_LOADING:
                        case R.PARSING:
                        case R.PARSED:
                        case R.ENDED:
                      }
                      this._checkBuffer(), this._checkFragmentChanged();
                    },
                  },
                  {
                    key: "_doTickIdle",
                    value: function () {
                      var e = this.hls,
                        t = e.config,
                        r = this.media;
                      if (
                        void 0 === this.levelLastLoaded ||
                        r ||
                        (!this.startFragRequested && t.startFragPrefetch)
                      ) {
                        var i = void 0;
                        i = this.loadedmetadata
                          ? r.currentTime
                          : this.nextLoadPosition;
                        var a = e.nextLoadLevel,
                          n = this.levels[a],
                          s = n.bitrate,
                          o = void 0;
                        (o = s
                          ? Math.max(
                            (8 * t.maxBufferSize) / s,
                            t.maxBufferLength
                          )
                          : t.maxBufferLength),
                          (o = Math.min(o, t.maxMaxBufferLength));
                        var l = f.default.bufferInfo(
                          this.mediaBuffer ? this.mediaBuffer : r,
                          i,
                          t.maxBufferHole
                        ),
                          u = l.len;
                        if (!(u >= o)) {
                          k.logger.trace(
                            "buffer length of " +
                            u.toFixed(3) +
                            " is below max of " +
                            o.toFixed(3) +
                            ". checking for more payload ..."
                          ),
                            (this.level = e.nextLoadLevel = a);
                          var d = n.details;
                          if (
                            void 0 === d ||
                            (d.live && this.levelLastLoaded !== a)
                          )
                            return void (this.state = R.WAITING_LEVEL);
                          var c = this.fragPrevious;
                          if (!d.live && c && c.sn === d.endSN) {
                            if (
                              Math.min(r.duration, c.start + c.duration) -
                              Math.max(l.end, c.start) <=
                              Math.max(0.2, c.duration / 2)
                            ) {
                              var h = {};
                              return (
                                this.altAudio && (h.type = "video"),
                                this.hls.trigger(v.default.BUFFER_EOS, h),
                                void (this.state = R.ENDED)
                              );
                            }
                          }
                          this._fetchPayloadOrEos(i, l, d);
                        }
                      }
                    },
                  },
                  {
                    key: "_fetchPayloadOrEos",
                    value: function (e, t, r) {
                      var i = this.fragPrevious,
                        a = this.level,
                        n = r.fragments,
                        s = n.length;
                      if (0 !== s) {
                        var o = n[0].start,
                          l = n[s - 1].start + n[s - 1].duration,
                          u = t.end,
                          d = void 0;
                        if (r.initSegment && !r.initSegment.data)
                          d = r.initSegment;
                        else if (r.live) {
                          var f = this.config.initialLiveManifestSize;
                          if (s < f)
                            return void k.logger.warn(
                              "Can not start playback of a level, reason: not enough fragments " +
                              s +
                              " < " +
                              f
                            );
                          if (
                            null ===
                            (d = this._ensureFragmentAtLivePoint(
                              r,
                              u,
                              o,
                              l,
                              i,
                              n,
                              s
                            ))
                          )
                            return;
                        } else u < o && (d = n[0]);
                        d || (d = this._findFragment(o, i, s, n, u, l, r)),
                          d && this._loadFragmentOrKey(d, a, r, e, u);
                      }
                    },
                  },
                  {
                    key: "_ensureFragmentAtLivePoint",
                    value: function (e, t, r, i, a, n, s) {
                      var o = this.hls.config,
                        l = this.media,
                        u = void 0,
                        d =
                          void 0 !== o.liveMaxLatencyDuration
                            ? o.liveMaxLatencyDuration
                            : o.liveMaxLatencyDurationCount * e.targetduration;
                      if (t < Math.max(r - o.maxFragLookUpTolerance, i - d)) {
                        var f = (this.liveSyncPosition =
                          this.computeLivePosition(r, e));
                        k.logger.log(
                          "buffer end: " +
                          t.toFixed(3) +
                          " is located too far from the end of live sliding playlist, reset currentTime to : " +
                          f.toFixed(3)
                        ),
                          (t = f),
                          l &&
                          l.readyState &&
                          l.duration > f &&
                          (l.currentTime = f);
                      }
                      if (e.PTSKnown && t > i && l && l.readyState) return null;
                      if (this.startFragRequested && !e.PTSKnown) {
                        if (a) {
                          var c = a.sn + 1;
                          c >= e.startSN &&
                            c <= e.endSN &&
                            ((u = n[c - e.startSN]),
                              k.logger.log(
                                "live playlist, switching playlist, load frag with next SN: " +
                                u.sn
                              ));
                        }
                        u ||
                          ((u = n[Math.min(s - 1, Math.round(s / 2))]),
                            k.logger.log(
                              "live playlist, switching playlist, unknown, load middle frag : " +
                              u.sn
                            ));
                      }
                      return u;
                    },
                  },
                  {
                    key: "_findFragment",
                    value: function (e, t, r, i, a, n, s) {
                      var o = this.hls.config,
                        l = void 0,
                        d = void 0,
                        f = o.maxFragLookUpTolerance,
                        c = t ? i[t.sn - i[0].sn + 1] : void 0,
                        h = function (e) {
                          var t = Math.min(f, e.duration);
                          return e.start + e.duration - t <= a
                            ? 1
                            : e.start - t > a && e.start
                              ? -1
                              : 0;
                        };
                      if (
                        (a < n
                          ? (a > n - f && (f = 0),
                            (d = c && !h(c) ? c : u.default.search(i, h)))
                          : (d = i[r - 1]),
                          d)
                      ) {
                        l = d;
                        var g = l.sn - s.startSN,
                          v = t && l.level === t.level,
                          p = i[g - 1],
                          y = i[g + 1];
                        if (v && l.sn === t.sn)
                          if (l.sn < s.endSN) {
                            var m = t.deltaPTS;
                            m && m > o.maxBufferHole && t.dropped && g
                              ? ((l = p),
                                k.logger.warn(
                                  "SN just loaded, with large PTS gap between audio and video, maybe frag is not starting with a keyframe ? load previous one to try to overcome this"
                                ),
                                t.loadCounter--)
                              : ((l = y),
                                k.logger.log(
                                  "SN just loaded, load next one: " + l.sn
                                ));
                          } else l = null;
                        else
                          l.dropped &&
                            !v &&
                            (y && y.backtracked
                              ? (k.logger.warn(
                                "Already backtracked from fragment " +
                                (g + 1) +
                                ", will not backtrack to fragment " +
                                g +
                                ". Loading fragment " +
                                (g + 1)
                              ),
                                (l = y))
                              : (k.logger.warn(
                                "Loaded fragment with dropped frames, backtracking 1 segment to find a keyframe"
                              ),
                                (l.dropped = 0),
                                p
                                  ? (p.loadCounter && p.loadCounter--, (l = p))
                                  : (l = null)));
                      }
                      return l;
                    },
                  },
                  {
                    key: "_loadFragmentOrKey",
                    value: function (e, t, r, i, a) {
                      var n = this.hls,
                        s = n.config;
                      if (
                        !e.decryptdata ||
                        null == e.decryptdata.uri ||
                        null != e.decryptdata.key
                      ) {
                        if (
                          (k.logger.log(
                            "Loading " +
                            e.sn +
                            " of [" +
                            r.startSN +
                            " ," +
                            r.endSN +
                            "],level " +
                            t +
                            ", currentTime:" +
                            i.toFixed(3) +
                            ",bufferEnd:" +
                            a.toFixed(3)
                          ),
                            void 0 !== this.fragLoadIdx
                              ? this.fragLoadIdx++
                              : (this.fragLoadIdx = 0),
                            e.loadCounter)
                        ) {
                          e.loadCounter++;
                          var o = s.fragLoadingLoopThreshold;
                          if (
                            e.loadCounter > o &&
                            Math.abs(this.fragLoadIdx - e.loadIdx) < o
                          )
                            return void n.trigger(v.default.ERROR, {
                              type: _.ErrorTypes.MEDIA_ERROR,
                              details: _.ErrorDetails.FRAG_LOOP_LOADING_ERROR,
                              fatal: !1,
                              frag: e,
                            });
                        } else e.loadCounter = 1;
                        return (
                          (e.loadIdx = this.fragLoadIdx),
                          (this.fragCurrent = e),
                          (this.startFragRequested = !0),
                          isNaN(e.sn) ||
                          (this.nextLoadPosition = e.start + e.duration),
                          (e.autoLevel = n.autoLevelEnabled),
                          (e.bitrateTest = this.bitrateTest),
                          n.trigger(v.default.FRAG_LOADING, { frag: e }),
                          this.demuxer ||
                          (this.demuxer = new h.default(n, "main")),
                          void (this.state = R.FRAG_LOADING)
                        );
                      }
                      k.logger.log(
                        "Loading key for " +
                        e.sn +
                        " of [" +
                        r.startSN +
                        " ," +
                        r.endSN +
                        "],level " +
                        t
                      ),
                        (this.state = R.KEY_LOADING),
                        n.trigger(v.default.KEY_LOADING, { frag: e });
                    },
                  },
                  {
                    key: "getBufferedFrag",
                    value: function (e) {
                      return u.default.search(
                        this._bufferedFrags,
                        function (t) {
                          return e < t.startPTS ? -1 : e > t.endPTS ? 1 : 0;
                        }
                      );
                    },
                  },
                  {
                    key: "followingBufferedFrag",
                    value: function (e) {
                      return e ? this.getBufferedFrag(e.endPTS + 0.5) : null;
                    },
                  },
                  {
                    key: "_checkFragmentChanged",
                    value: function () {
                      var e,
                        t,
                        r = this.media;
                      if (
                        r &&
                        r.readyState &&
                        r.seeking === !1 &&
                        ((t = r.currentTime),
                          t > r.playbackRate * this.lastCurrentTime &&
                          (this.lastCurrentTime = t),
                          f.default.isBuffered(r, t)
                            ? (e = this.getBufferedFrag(t))
                            : f.default.isBuffered(r, t + 0.1) &&
                            (e = this.getBufferedFrag(t + 0.1)),
                          e)
                      ) {
                        var i = e;
                        if (i !== this.fragPlaying) {
                          this.hls.trigger(v.default.FRAG_CHANGED, { frag: i });
                          var a = i.level;
                          (this.fragPlaying && this.fragPlaying.level === a) ||
                            this.hls.trigger(v.default.LEVEL_SWITCHED, {
                              level: a,
                            }),
                            (this.fragPlaying = i);
                        }
                      }
                    },
                  },
                  {
                    key: "immediateLevelSwitch",
                    value: function () {
                      if (
                        (k.logger.log("immediateLevelSwitch"),
                          !this.immediateSwitch)
                      ) {
                        this.immediateSwitch = !0;
                        var e = this.media,
                          t = void 0;
                        e ? ((t = e.paused), e.pause()) : (t = !0),
                          (this.previouslyPaused = t);
                      }
                      var r = this.fragCurrent;
                      r && r.loader && r.loader.abort(),
                        (this.fragCurrent = null),
                        (this.fragLoadIdx +=
                          2 * this.config.fragLoadingLoopThreshold),
                        this.flushMainBuffer(0, Number.POSITIVE_INFINITY);
                    },
                  },
                  {
                    key: "immediateLevelSwitchEnd",
                    value: function () {
                      var e = this.media;
                      e &&
                        e.buffered.length &&
                        ((this.immediateSwitch = !1),
                          f.default.isBuffered(e, e.currentTime) &&
                          (e.currentTime -= 1e-4),
                          this.previouslyPaused || e.play());
                    },
                  },
                  {
                    key: "nextLevelSwitch",
                    value: function () {
                      var e = this.media;
                      if (e && e.readyState) {
                        var t = void 0,
                          r = void 0,
                          i = void 0;
                        if (
                          ((this.fragLoadIdx +=
                            2 * this.config.fragLoadingLoopThreshold),
                            (r = this.getBufferedFrag(e.currentTime)),
                            r &&
                            r.startPTS > 1 &&
                            this.flushMainBuffer(0, r.startPTS - 1),
                            e.paused)
                        )
                          t = 0;
                        else {
                          var a = this.hls.nextLoadLevel,
                            n = this.levels[a],
                            s = this.fragLastKbps;
                          t =
                            s && this.fragCurrent
                              ? (this.fragCurrent.duration * n.bitrate) /
                              (1e3 * s) +
                              1
                              : 0;
                        }
                        if (
                          (i = this.getBufferedFrag(e.currentTime + t)) &&
                          (i = this.followingBufferedFrag(i))
                        ) {
                          var o = this.fragCurrent;
                          o && o.loader && o.loader.abort(),
                            (this.fragCurrent = null),
                            this.flushMainBuffer(
                              i.startPTS,
                              Number.POSITIVE_INFINITY
                            );
                        }
                      }
                    },
                  },
                  {
                    key: "flushMainBuffer",
                    value: function (e, t) {
                      this.state = R.BUFFER_FLUSHING;
                      var r = { startOffset: e, endOffset: t };
                      this.altAudio && (r.type = "video"),
                        this.hls.trigger(v.default.BUFFER_FLUSHING, r);
                    },
                  },
                  {
                    key: "onMediaAttached",
                    value: function (e) {
                      var t = (this.media = this.mediaBuffer = e.media);
                      (this.onvseeking = this.onMediaSeeking.bind(this)),
                        (this.onvseeked = this.onMediaSeeked.bind(this)),
                        (this.onvended = this.onMediaEnded.bind(this)),
                        t.addEventListener("seeking", this.onvseeking),
                        t.addEventListener("seeked", this.onvseeked),
                        t.addEventListener("ended", this.onvended);
                      var r = this.config;
                      this.levels &&
                        r.autoStartLoad &&
                        this.hls.startLoad(r.startPosition);
                    },
                  },
                  {
                    key: "onMediaDetaching",
                    value: function () {
                      var e = this.media;
                      e &&
                        e.ended &&
                        (k.logger.log(
                          "MSE detaching and video ended, reset startPosition"
                        ),
                          (this.startPosition = this.lastCurrentTime = 0));
                      var t = this.levels;
                      t &&
                        t.forEach(function (e) {
                          e.details &&
                            e.details.fragments.forEach(function (e) {
                              (e.loadCounter = void 0),
                                (e.backtracked = void 0);
                            });
                        }),
                        e &&
                        (e.removeEventListener("seeking", this.onvseeking),
                          e.removeEventListener("seeked", this.onvseeked),
                          e.removeEventListener("ended", this.onvended),
                          (this.onvseeking =
                            this.onvseeked =
                            this.onvended =
                            null)),
                        (this.media = this.mediaBuffer = null),
                        (this.loadedmetadata = !1),
                        this.stopLoad();
                    },
                  },
                  {
                    key: "onMediaSeeking",
                    value: function () {
                      var e = this.media,
                        t = e ? e.currentTime : void 0,
                        r = this.config;
                      if (
                        (k.logger.log("media seeking to " + t.toFixed(3)),
                          this.state === R.FRAG_LOADING)
                      ) {
                        var i = this.mediaBuffer ? this.mediaBuffer : e,
                          a = f.default.bufferInfo(
                            i,
                            t,
                            this.config.maxBufferHole
                          ),
                          n = this.fragCurrent;
                        if (0 === a.len && n) {
                          var s = r.maxFragLookUpTolerance,
                            o = n.start - s,
                            l = n.start + n.duration + s;
                          t < o || t > l
                            ? (n.loader &&
                              (k.logger.log(
                                "seeking outside of buffer while fragment load in progress, cancel fragment load"
                              ),
                                n.loader.abort()),
                              (this.fragCurrent = null),
                              (this.fragPrevious = null),
                              (this.state = R.IDLE))
                            : k.logger.log(
                              "seeking outside of buffer but within currently loaded fragment range"
                            );
                        }
                      } else this.state === R.ENDED && (this.state = R.IDLE);
                      e && (this.lastCurrentTime = t),
                        this.state !== R.FRAG_LOADING &&
                        void 0 !== this.fragLoadIdx &&
                        (this.fragLoadIdx += 2 * r.fragLoadingLoopThreshold),
                        this.loadedmetadata ||
                        (this.nextLoadPosition = this.startPosition = t),
                        this.tick();
                    },
                  },
                  {
                    key: "onMediaSeeked",
                    value: function () {
                      k.logger.log(
                        "media seeked to " + this.media.currentTime.toFixed(3)
                      ),
                        this.tick();
                    },
                  },
                  {
                    key: "onMediaEnded",
                    value: function () {
                      k.logger.log("media ended"),
                        (this.startPosition = this.lastCurrentTime = 0);
                    },
                  },
                  {
                    key: "onManifestLoading",
                    value: function () {
                      k.logger.log("trigger BUFFER_RESET"),
                        this.hls.trigger(v.default.BUFFER_RESET),
                        (this._bufferedFrags = []),
                        (this.stalled = !1),
                        (this.startPosition = this.lastCurrentTime = 0);
                    },
                  },
                  {
                    key: "onManifestParsed",
                    value: function (e) {
                      var t,
                        r = !1,
                        i = !1;
                      e.levels.forEach(function (e) {
                        (t = e.audioCodec) &&
                          (t.indexOf("mp4a.40.2") !== -1 && (r = !0),
                            t.indexOf("mp4a.40.5") !== -1 && (i = !0));
                      }),
                        (this.audioCodecSwitch = r && i),
                        this.audioCodecSwitch &&
                        k.logger.log(
                          "both AAC/HE-AAC audio found in levels; declaring level codec as HE-AAC"
                        ),
                        (this.levels = e.levels),
                        (this.startLevelLoaded = !1),
                        (this.startFragRequested = !1);
                      var a = this.config;
                      (a.autoStartLoad || this.forceStartLoad) &&
                        this.hls.startLoad(a.startPosition);
                    },
                  },
                  {
                    key: "onLevelLoaded",
                    value: function (e) {
                      var t = e.details,
                        r = e.level,
                        i = this.levels[r],
                        a = t.totalduration,
                        n = 0;
                      if (
                        (k.logger.log(
                          "level " +
                          r +
                          " loaded [" +
                          t.startSN +
                          "," +
                          t.endSN +
                          "],duration:" +
                          a
                        ),
                          (this.levelLastLoaded = r),
                          t.live)
                      ) {
                        var s = i.details;
                        s && t.fragments.length > 0
                          ? (E.default.mergeDetails(s, t),
                            (n = t.fragments[0].start),
                            (this.liveSyncPosition = this.computeLivePosition(
                              n,
                              s
                            )),
                            t.PTSKnown
                              ? k.logger.log(
                                "live playlist sliding:" + n.toFixed(3)
                              )
                              : k.logger.log(
                                "live playlist - outdated PTS, unknown sliding"
                              ))
                          : ((t.PTSKnown = !1),
                            k.logger.log(
                              "live playlist - first load, unknown sliding"
                            ));
                      } else t.PTSKnown = !1;
                      if (
                        ((i.details = t),
                          this.hls.trigger(v.default.LEVEL_UPDATED, {
                            details: t,
                            level: r,
                          }),
                          this.startFragRequested === !1)
                      ) {
                        if (
                          this.startPosition === -1 ||
                          this.lastCurrentTime === -1
                        ) {
                          var o = t.startTimeOffset;
                          isNaN(o)
                            ? t.live
                              ? ((this.startPosition = this.computeLivePosition(
                                n,
                                t
                              )),
                                k.logger.log(
                                  "configure startPosition to " +
                                  this.startPosition
                                ))
                              : (this.startPosition = 0)
                            : (o < 0 &&
                              (k.logger.log(
                                "negative start time offset " +
                                o +
                                ", count from end of last fragment"
                              ),
                                (o = n + a + o)),
                              k.logger.log(
                                "start time offset found in playlist, adjust startPosition to " +
                                o
                              ),
                              (this.startPosition = o)),
                            (this.lastCurrentTime = this.startPosition);
                        }
                        this.nextLoadPosition = this.startPosition;
                      }
                      this.state === R.WAITING_LEVEL && (this.state = R.IDLE),
                        this.tick();
                    },
                  },
                  {
                    key: "onKeyLoaded",
                    value: function () {
                      this.state === R.KEY_LOADING &&
                        ((this.state = R.IDLE), this.tick());
                    },
                  },
                  {
                    key: "onFragLoaded",
                    value: function (e) {
                      var t = this.fragCurrent,
                        r = e.frag;
                      if (
                        this.state === R.FRAG_LOADING &&
                        t &&
                        "main" === r.type &&
                        r.level === t.level &&
                        r.sn === t.sn
                      ) {
                        var i = e.stats,
                          a = this.levels[t.level],
                          n = a.details;
                        if (
                          (k.logger.log(
                            "Loaded  " +
                            t.sn +
                            " of [" +
                            n.startSN +
                            " ," +
                            n.endSN +
                            "],level " +
                            t.level
                          ),
                            (this.bitrateTest = !1),
                            (this.stats = i),
                            r.bitrateTest === !0 && this.hls.nextLoadLevel)
                        )
                          (this.state = R.IDLE),
                            (this.startFragRequested = !1),
                            (i.tparsed = i.tbuffered = performance.now()),
                            this.hls.trigger(v.default.FRAG_BUFFERED, {
                              stats: i,
                              frag: t,
                              id: "main",
                            }),
                            this.tick();
                        else if ("initSegment" === r.sn)
                          (this.state = R.IDLE),
                            (i.tparsed = i.tbuffered = performance.now()),
                            (n.initSegment.data = e.payload),
                            this.hls.trigger(v.default.FRAG_BUFFERED, {
                              stats: i,
                              frag: t,
                              id: "main",
                            }),
                            this.tick();
                        else {
                          this.state = R.PARSING;
                          var s = n.totalduration,
                            o = t.level,
                            l = t.sn,
                            u = this.config.defaultAudioCodec || a.audioCodec;
                          this.audioCodecSwap &&
                            (k.logger.log("swapping playlist audio codec"),
                              void 0 === u && (u = this.lastAudioCodec),
                              u &&
                              (u =
                                u.indexOf("mp4a.40.5") !== -1
                                  ? "mp4a.40.2"
                                  : "mp4a.40.5")),
                            (this.pendingBuffering = !0),
                            (this.appended = !1),
                            k.logger.log(
                              "Parsing " +
                              l +
                              " of [" +
                              n.startSN +
                              " ," +
                              n.endSN +
                              "],level " +
                              o +
                              ", cc " +
                              t.cc
                            );
                          var d = this.demuxer;
                          d ||
                            (d = this.demuxer =
                              new h.default(this.hls, "main"));
                          var f = this.media,
                            c = f && f.seeking,
                            g = !c && (n.PTSKnown || !n.live),
                            p = n.initSegment ? n.initSegment.data : [];
                          d.push(
                            e.payload,
                            p,
                            u,
                            a.videoCodec,
                            t,
                            s,
                            g,
                            void 0
                          );
                        }
                      }
                      this.fragLoadError = 0;
                    },
                  },
                  {
                    key: "onFragParsingInitSegment",
                    value: function (e) {
                      var t = this.fragCurrent,
                        r = e.frag;
                      if (
                        t &&
                        "main" === e.id &&
                        r.sn === t.sn &&
                        r.level === t.level &&
                        this.state === R.PARSING
                      ) {
                        var i,
                          a,
                          n = e.tracks;
                        if (
                          (n.audio && this.altAudio && delete n.audio,
                            (a = n.audio))
                        ) {
                          var s = this.levels[this.level].audioCodec,
                            o = navigator.userAgent.toLowerCase();
                          s &&
                            this.audioCodecSwap &&
                            (k.logger.log("swapping playlist audio codec"),
                              (s =
                                s.indexOf("mp4a.40.5") !== -1
                                  ? "mp4a.40.2"
                                  : "mp4a.40.5")),
                            this.audioCodecSwitch &&
                            1 !== a.metadata.channelCount &&
                            o.indexOf("firefox") === -1 &&
                            (s = "mp4a.40.5"),
                            o.indexOf("android") !== -1 &&
                            "audio/mpeg" !== a.container &&
                            ((s = "mp4a.40.2"),
                              k.logger.log(
                                "Android: force audio codec to " + s
                              )),
                            (a.levelCodec = s),
                            (a.id = e.id);
                        }
                        (a = n.video),
                          a &&
                          ((a.levelCodec =
                            this.levels[this.level].videoCodec),
                            (a.id = e.id)),
                          this.hls.trigger(v.default.BUFFER_CODECS, n);
                        for (i in n) {
                          (a = n[i]),
                            k.logger.log(
                              "main track:" +
                              i +
                              ",container:" +
                              a.container +
                              ",codecs[level/parsed]=[" +
                              a.levelCodec +
                              "/" +
                              a.codec +
                              "]"
                            );
                          var l = a.initSegment;
                          l &&
                            ((this.appended = !0),
                              (this.pendingBuffering = !0),
                              this.hls.trigger(v.default.BUFFER_APPENDING, {
                                type: i,
                                data: l,
                                parent: "main",
                                content: "initSegment",
                              }));
                        }
                        this.tick();
                      }
                    },
                  },
                  {
                    key: "onFragParsingData",
                    value: function (e) {
                      var t = this,
                        r = this.fragCurrent,
                        i = e.frag;
                      if (
                        r &&
                        "main" === e.id &&
                        i.sn === r.sn &&
                        i.level === r.level &&
                        ("audio" !== e.type || !this.altAudio) &&
                        this.state === R.PARSING
                      ) {
                        var a = this.levels[this.level],
                          n = r;
                        if (
                          (isNaN(e.endPTS) &&
                            ((e.endPTS = e.startPTS + r.duration),
                              (e.endDTS = e.startDTS + r.duration)),
                            k.logger.log(
                              "Parsed " +
                              e.type +
                              ",PTS:[" +
                              e.startPTS.toFixed(3) +
                              "," +
                              e.endPTS.toFixed(3) +
                              "],DTS:[" +
                              e.startDTS.toFixed(3) +
                              "/" +
                              e.endDTS.toFixed(3) +
                              "],nb:" +
                              e.nb +
                              ",dropped:" +
                              (e.dropped || 0)
                            ),
                            "video" === e.type)
                        )
                          if (((n.dropped = e.dropped), n.dropped)) {
                            if (!n.backtracked)
                              return (
                                (n.backtracked = !0),
                                (this.nextLoadPosition = e.startPTS),
                                (this.state = R.IDLE),
                                void this.tick()
                              );
                            k.logger.warn(
                              "Already backtracked on this fragment, appending with the gap"
                            );
                          } else n.backtracked = !1;
                        var s = E.default.updateFragPTSDTS(
                          a.details,
                          n,
                          e.startPTS,
                          e.endPTS,
                          e.startDTS,
                          e.endDTS
                        ),
                          o = this.hls;
                        o.trigger(v.default.LEVEL_PTS_UPDATED, {
                          details: a.details,
                          level: this.level,
                          drift: s,
                          type: e.type,
                          start: e.startPTS,
                          end: e.endPTS,
                        }),
                          [e.data1, e.data2].forEach(function (r) {
                            r &&
                              r.length &&
                              t.state === R.PARSING &&
                              ((t.appended = !0),
                                (t.pendingBuffering = !0),
                                o.trigger(v.default.BUFFER_APPENDING, {
                                  type: e.type,
                                  data: r,
                                  parent: "main",
                                  content: "data",
                                }));
                          }),
                          this.tick();
                      }
                    },
                  },
                  {
                    key: "onFragParsed",
                    value: function (e) {
                      var t = this.fragCurrent,
                        r = e.frag;
                      t &&
                        "main" === e.id &&
                        r.sn === t.sn &&
                        r.level === t.level &&
                        this.state === R.PARSING &&
                        ((this.stats.tparsed = performance.now()),
                          (this.state = R.PARSED),
                          this._checkAppendedParsed());
                    },
                  },
                  {
                    key: "onAudioTrackSwitching",
                    value: function (e) {
                      var t = !!e.url,
                        r = e.id;
                      if (!t) {
                        if (this.mediaBuffer !== this.media) {
                          k.logger.log(
                            "switching on main audio, use media.buffered to schedule main fragment loading"
                          ),
                            (this.mediaBuffer = this.media);
                          var i = this.fragCurrent;
                          i.loader &&
                            (k.logger.log(
                              "switching to main audio track, cancel main fragment load"
                            ),
                              i.loader.abort()),
                            (this.fragCurrent = null),
                            (this.fragPrevious = null),
                            this.demuxer &&
                            (this.demuxer.destroy(), (this.demuxer = null)),
                            (this.state = R.IDLE);
                        }
                        var a = this.hls;
                        a.trigger(v.default.BUFFER_FLUSHING, {
                          startOffset: 0,
                          endOffset: Number.POSITIVE_INFINITY,
                          type: "audio",
                        }),
                          a.trigger(v.default.AUDIO_TRACK_SWITCHED, { id: r }),
                          (this.altAudio = !1);
                      }
                    },
                  },
                  {
                    key: "onAudioTrackSwitched",
                    value: function (e) {
                      var t = e.id,
                        r = !!this.hls.audioTracks[t].url;
                      if (r) {
                        var i = this.videoBuffer;
                        i &&
                          this.mediaBuffer !== i &&
                          (k.logger.log(
                            "switching on alternate audio, use video.buffered to schedule main fragment loading"
                          ),
                            (this.mediaBuffer = i));
                      }
                      (this.altAudio = r), this.tick();
                    },
                  },
                  {
                    key: "onBufferCreated",
                    value: function (e) {
                      var t = e.tracks,
                        r = void 0,
                        i = void 0,
                        a = !1;
                      for (var n in t) {
                        var s = t[n];
                        "main" === s.id
                          ? ((i = n),
                            (r = s),
                            "video" === n && (this.videoBuffer = t[n].buffer))
                          : (a = !0);
                      }
                      a && r
                        ? (k.logger.log(
                          "alternate track found, use " +
                          i +
                          ".buffered to schedule main fragment loading"
                        ),
                          (this.mediaBuffer = r.buffer))
                        : (this.mediaBuffer = this.media);
                    },
                  },
                  {
                    key: "onBufferAppended",
                    value: function (e) {
                      if ("main" === e.parent) {
                        var t = this.state;
                        (t !== R.PARSING && t !== R.PARSED) ||
                          ((this.pendingBuffering = e.pending > 0),
                            this._checkAppendedParsed());
                      }
                    },
                  },
                  {
                    key: "_checkAppendedParsed",
                    value: function () {
                      if (
                        !(
                          this.state !== R.PARSED ||
                          (this.appended && this.pendingBuffering)
                        )
                      ) {
                        var e = this.fragCurrent;
                        if (e) {
                          var t = this.mediaBuffer
                            ? this.mediaBuffer
                            : this.media;
                          k.logger.log(
                            "main buffered : " + T.default.toString(t.buffered)
                          );
                          var r = this._bufferedFrags.filter(function (e) {
                            return f.default.isBuffered(
                              t,
                              (e.startPTS + e.endPTS) / 2
                            );
                          });
                          r.push(e),
                            (this._bufferedFrags = r.sort(function (e, t) {
                              return e.startPTS - t.startPTS;
                            })),
                            (this.fragPrevious = e);
                          var i = this.stats;
                          (i.tbuffered = performance.now()),
                            (this.fragLastKbps = Math.round(
                              (8 * i.total) / (i.tbuffered - i.tfirst)
                            )),
                            this.hls.trigger(v.default.FRAG_BUFFERED, {
                              stats: i,
                              frag: e,
                              id: "main",
                            }),
                            (this.state = R.IDLE);
                        }
                        this.tick();
                      }
                    },
                  },
                  {
                    key: "onError",
                    value: function (e) {
                      var t = e.frag || this.fragCurrent;
                      if (!t || "main" === t.type) {
                        var r = this.media,
                          i =
                            r &&
                            f.default.isBuffered(r, r.currentTime) &&
                            f.default.isBuffered(r, r.currentTime + 0.5);
                        switch (e.details) {
                          case _.ErrorDetails.FRAG_LOAD_ERROR:
                          case _.ErrorDetails.FRAG_LOAD_TIMEOUT:
                          case _.ErrorDetails.KEY_LOAD_ERROR:
                          case _.ErrorDetails.KEY_LOAD_TIMEOUT:
                            if (!e.fatal) {
                              var a = this.fragLoadError;
                              a ? a++ : (a = 1);
                              var n = this.config;
                              if (
                                a <= n.fragLoadingMaxRetry ||
                                i ||
                                (t.autoLevel && t.level)
                              ) {
                                (this.fragLoadError = a), (t.loadCounter = 0);
                                var s = Math.min(
                                  Math.pow(2, a - 1) * n.fragLoadingRetryDelay,
                                  n.fragLoadingMaxRetryTimeout
                                );
                                k.logger.warn(
                                  "mediaController: frag loading failed, retry in " +
                                  s +
                                  " ms"
                                ),
                                  (this.retryDate = performance.now() + s),
                                  this.loadedmetadata ||
                                  ((this.startFragRequested = !1),
                                    (this.nextLoadPosition =
                                      this.startPosition)),
                                  (this.state = R.FRAG_LOADING_WAITING_RETRY);
                              } else
                                k.logger.error(
                                  "mediaController: " +
                                  e.details +
                                  " reaches max retry, redispatch as fatal ..."
                                ),
                                  (e.fatal = !0),
                                  (this.state = R.ERROR);
                            }
                            break;
                          case _.ErrorDetails.FRAG_LOOP_LOADING_ERROR:
                            e.fatal ||
                              (i
                                ? (this._reduceMaxBufferLength(t.duration),
                                  (this.state = R.IDLE))
                                : (t.autoLevel && 0 !== t.level) ||
                                ((e.fatal = !0), (this.state = R.ERROR)));
                            break;
                          case _.ErrorDetails.LEVEL_LOAD_ERROR:
                          case _.ErrorDetails.LEVEL_LOAD_TIMEOUT:
                            this.state !== R.ERROR &&
                              (e.fatal
                                ? ((this.state = R.ERROR),
                                  k.logger.warn(
                                    "streamController: " +
                                    e.details +
                                    ",switch to " +
                                    this.state +
                                    " state ..."
                                  ))
                                : this.state === R.WAITING_LEVEL &&
                                (this.state = R.IDLE));
                            break;
                          case _.ErrorDetails.BUFFER_FULL_ERROR:
                            "main" !== e.parent ||
                              (this.state !== R.PARSING &&
                                this.state !== R.PARSED) ||
                              (i
                                ? (this._reduceMaxBufferLength(
                                  this.config.maxBufferLength
                                ),
                                  (this.state = R.IDLE))
                                : (k.logger.warn(
                                  "buffer full error also media.currentTime is not buffered, flush everything"
                                ),
                                  (this.fragCurrent = null),
                                  this.flushMainBuffer(
                                    0,
                                    Number.POSITIVE_INFINITY
                                  )));
                        }
                      }
                    },
                  },
                  {
                    key: "_reduceMaxBufferLength",
                    value: function (e) {
                      var t = this.config;
                      t.maxMaxBufferLength >= e &&
                        ((t.maxMaxBufferLength /= 2),
                          k.logger.warn(
                            "main:reduce max buffer length to " +
                            t.maxMaxBufferLength +
                            "s"
                          ),
                          (this.fragLoadIdx += 2 * t.fragLoadingLoopThreshold));
                    },
                  },
                  {
                    key: "_checkBuffer",
                    value: function () {
                      var e = this.media;
                      if (e && e.readyState) {
                        var t = e.currentTime,
                          r = this.mediaBuffer ? this.mediaBuffer : e,
                          i = r.buffered;
                        if (!this.loadedmetadata && i.length) {
                          this.loadedmetadata = !0;
                          var a = e.seeking ? t : this.startPosition,
                            n = f.default.isBuffered(r, a);
                          (t === a && n) ||
                            (k.logger.log("target start position:" + a),
                              n ||
                              ((a = i.start(0)),
                                k.logger.log(
                                  "target start position not buffered, seek to buffered.start(0) " +
                                  a
                                )),
                              k.logger.log(
                                "adjust currentTime from " + t + " to " + a
                              ),
                              (e.currentTime = a));
                        } else if (this.immediateSwitch)
                          this.immediateLevelSwitchEnd();
                        else {
                          var s = f.default.bufferInfo(e, t, 0),
                            o = !(
                              e.paused ||
                              e.ended ||
                              0 === e.buffered.length
                            ),
                            l = t !== this.lastCurrentTime,
                            u = this.config;
                          if (l)
                            this.stallReported &&
                              (k.logger.warn(
                                "playback not stuck anymore @" +
                                t +
                                ", after " +
                                Math.round(performance.now() - this.stalled) +
                                "ms"
                              ),
                                (this.stallReported = !1)),
                              (this.stalled = void 0),
                              (this.nudgeRetry = 0);
                          else if (o) {
                            var d = performance.now(),
                              c = this.hls;
                            if (this.stalled) {
                              var h = d - this.stalled,
                                g = s.len,
                                p = this.nudgeRetry || 0;
                              if (
                                g <= 0.5 &&
                                h > 1e3 * u.lowBufferWatchdogPeriod
                              ) {
                                this.stallReported ||
                                  ((this.stallReported = !0),
                                    k.logger.warn(
                                      "playback stalling in low buffer @" + t
                                    ),
                                    c.trigger(v.default.ERROR, {
                                      type: _.ErrorTypes.MEDIA_ERROR,
                                      details:
                                        _.ErrorDetails.BUFFER_STALLED_ERROR,
                                      fatal: !1,
                                      buffer: g,
                                    }));
                                var y = s.nextStart,
                                  m = y - t;
                                if (y && m < u.maxSeekHole && m > 0) {
                                  this.nudgeRetry = ++p;
                                  var E = p * u.nudgeOffset;
                                  k.logger.log(
                                    "adjust currentTime from " +
                                    e.currentTime +
                                    " to next buffered @ " +
                                    y +
                                    " + nudge " +
                                    E
                                  ),
                                    (e.currentTime = y + E),
                                    (this.stalled = void 0),
                                    c.trigger(v.default.ERROR, {
                                      type: _.ErrorTypes.MEDIA_ERROR,
                                      details:
                                        _.ErrorDetails.BUFFER_SEEK_OVER_HOLE,
                                      fatal: !1,
                                      hole: y + E - t,
                                    });
                                }
                              } else if (
                                g > 0.5 &&
                                h > 1e3 * u.highBufferWatchdogPeriod
                              )
                                if (
                                  (this.stallReported ||
                                    ((this.stallReported = !0),
                                      k.logger.warn(
                                        "playback stalling in high buffer @" + t
                                      ),
                                      c.trigger(v.default.ERROR, {
                                        type: _.ErrorTypes.MEDIA_ERROR,
                                        details:
                                          _.ErrorDetails.BUFFER_STALLED_ERROR,
                                        fatal: !1,
                                        buffer: g,
                                      })),
                                    (this.stalled = void 0),
                                    (this.nudgeRetry = ++p),
                                    p < u.nudgeMaxRetry)
                                ) {
                                  var b = e.currentTime,
                                    T = b + p * u.nudgeOffset;
                                  k.logger.log(
                                    "adjust currentTime from " + b + " to " + T
                                  ),
                                    (e.currentTime = T),
                                    c.trigger(v.default.ERROR, {
                                      type: _.ErrorTypes.MEDIA_ERROR,
                                      details:
                                        _.ErrorDetails.BUFFER_NUDGE_ON_STALL,
                                      fatal: !1,
                                    });
                                } else
                                  k.logger.error(
                                    "still stuck in high buffer @" +
                                    t +
                                    " after " +
                                    u.nudgeMaxRetry +
                                    ", raise fatal error"
                                  ),
                                    c.trigger(v.default.ERROR, {
                                      type: _.ErrorTypes.MEDIA_ERROR,
                                      details:
                                        _.ErrorDetails.BUFFER_STALLED_ERROR,
                                      fatal: !0,
                                    });
                            } else
                              (this.stalled = d), (this.stallReported = !1);
                          }
                        }
                      }
                    },
                  },
                  {
                    key: "onFragLoadEmergencyAborted",
                    value: function () {
                      (this.state = R.IDLE),
                        this.loadedmetadata ||
                        ((this.startFragRequested = !1),
                          (this.nextLoadPosition = this.startPosition)),
                        this.tick();
                    },
                  },
                  {
                    key: "onBufferFlushed",
                    value: function () {
                      var e = this.mediaBuffer ? this.mediaBuffer : this.media;
                      (this._bufferedFrags = this._bufferedFrags.filter(
                        function (t) {
                          return f.default.isBuffered(
                            e,
                            (t.startPTS + t.endPTS) / 2
                          );
                        }
                      )),
                        (this.fragLoadIdx +=
                          2 * this.config.fragLoadingLoopThreshold),
                        (this.state = R.IDLE),
                        (this.fragPrevious = null);
                    },
                  },
                  {
                    key: "swapAudioCodec",
                    value: function () {
                      this.audioCodecSwap = !this.audioCodecSwap;
                    },
                  },
                  {
                    key: "computeLivePosition",
                    value: function (e, t) {
                      var r =
                        void 0 !== this.config.liveSyncDuration
                          ? this.config.liveSyncDuration
                          : this.config.liveSyncDurationCount *
                          t.targetduration;
                      return e + Math.max(0, t.totalduration - r);
                    },
                  },
                  {
                    key: "state",
                    set: function (e) {
                      if (this.state !== e) {
                        var t = this.state;
                        (this._state = e),
                          k.logger.log("main stream:" + t + "->" + e),
                          this.hls.trigger(v.default.STREAM_STATE_TRANSITION, {
                            previousState: t,
                            nextState: e,
                          });
                      }
                    },
                    get: function () {
                      return this._state;
                    },
                  },
                  {
                    key: "currentLevel",
                    get: function () {
                      var e = this.media;
                      if (e) {
                        var t = this.getBufferedFrag(e.currentTime);
                        if (t) return t.level;
                      }
                      return -1;
                    },
                  },
                  {
                    key: "nextBufferedFrag",
                    get: function () {
                      var e = this.media;
                      return e
                        ? this.followingBufferedFrag(
                          this.getBufferedFrag(e.currentTime)
                        )
                        : null;
                    },
                  },
                  {
                    key: "nextLevel",
                    get: function () {
                      var e = this.nextBufferedFrag;
                      return e ? e.level : -1;
                    },
                  },
                  {
                    key: "liveSyncPosition",
                    get: function () {
                      return this._liveSyncPosition;
                    },
                    set: function (e) {
                      this._liveSyncPosition = e;
                    },
                  },
                ]),
                t
              );
            })(y.default);
          r.default = A;
        },
        {
          25: 25,
          31: 31,
          32: 32,
          33: 33,
          35: 35,
          36: 36,
          46: 46,
          51: 51,
          52: 52,
        },
      ],
      14: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(51),
            h = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.ERROR,
                    u.default.SUBTITLE_TRACKS_UPDATED,
                    u.default.SUBTITLE_TRACK_SWITCH,
                    u.default.SUBTITLE_TRACK_LOADED,
                    u.default.SUBTITLE_FRAG_PROCESSED
                  )
                );
                return (
                  (r.config = e.config),
                  (r.vttFragSNsProcessed = {}),
                  (r.vttFragQueues = void 0),
                  (r.currentlyProcessing = null),
                  (r.currentTrackId = -1),
                  r
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "clearVttFragQueues",
                    value: function () {
                      var e = this;
                      (this.vttFragQueues = {}),
                        this.tracks.forEach(function (t) {
                          e.vttFragQueues[t.id] = [];
                        });
                    },
                  },
                  {
                    key: "nextFrag",
                    value: function () {
                      if (
                        null === this.currentlyProcessing &&
                        this.currentTrackId > -1 &&
                        this.vttFragQueues[this.currentTrackId].length
                      ) {
                        var e = (this.currentlyProcessing =
                          this.vttFragQueues[this.currentTrackId].shift());
                        this.hls.trigger(u.default.FRAG_LOADING, { frag: e });
                      }
                    },
                  },
                  {
                    key: "onSubtitleFragProcessed",
                    value: function (e) {
                      e.success &&
                        this.vttFragSNsProcessed[e.frag.trackId].push(
                          e.frag.sn
                        ),
                        (this.currentlyProcessing = null),
                        this.nextFrag();
                    },
                  },
                  {
                    key: "onError",
                    value: function (e) {
                      var t = e.frag;
                      (t && "subtitle" !== t.type) ||
                        (this.currentlyProcessing &&
                          ((this.currentlyProcessing = null), this.nextFrag()));
                    },
                  },
                  {
                    key: "onSubtitleTracksUpdated",
                    value: function (e) {
                      var t = this;
                      c.logger.log("subtitle tracks updated"),
                        (this.tracks = e.subtitleTracks),
                        this.clearVttFragQueues(),
                        (this.vttFragSNsProcessed = {}),
                        this.tracks.forEach(function (e) {
                          t.vttFragSNsProcessed[e.id] = [];
                        });
                    },
                  },
                  {
                    key: "onSubtitleTrackSwitch",
                    value: function (e) {
                      (this.currentTrackId = e.id), this.clearVttFragQueues();
                    },
                  },
                  {
                    key: "onSubtitleTrackLoaded",
                    value: function (e) {
                      var t = this.vttFragSNsProcessed[e.id],
                        r = this.vttFragQueues[e.id],
                        i = this.currentlyProcessing
                          ? this.currentlyProcessing.sn
                          : -1,
                        a = function (e) {
                          return t.indexOf(e.sn) > -1;
                        },
                        n = function (e) {
                          return r.some(function (t) {
                            return t.sn === e.sn;
                          });
                        };
                      e.details.fragments.forEach(function (t) {
                        a(t) ||
                          t.sn === i ||
                          n(t) ||
                          ((t.trackId = e.id), r.push(t));
                      }),
                        this.nextFrag();
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = h;
        },
        { 32: 32, 33: 33, 51: 51 },
      ],
      15: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          function o(e) {
            for (var t = [], r = 0; r < e.length; r++)
              "subtitles" === e[r].kind && t.push(e[r]);
            return t;
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var l = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            u = e(33),
            d = i(u),
            f = e(32),
            c = i(f),
            h = e(51),
            g = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    d.default.MEDIA_ATTACHED,
                    d.default.MEDIA_DETACHING,
                    d.default.MANIFEST_LOADING,
                    d.default.MANIFEST_LOADED,
                    d.default.SUBTITLE_TRACK_LOADED
                  )
                );
                return (r.tracks = []), (r.trackId = -1), (r.media = void 0), r;
              }
              return (
                s(t, e),
                l(t, [
                  {
                    key: "destroy",
                    value: function () {
                      c.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onMediaAttached",
                    value: function (e) {
                      var t = this;
                      (this.media = e.media),
                        this.media &&
                        this.media.textTracks.addEventListener(
                          "change",
                          function () {
                            if (t.media) {
                              for (
                                var e = -1, r = o(t.media.textTracks), i = 0;
                                i < r.length;
                                i++
                              )
                                "showing" === r[i].mode && (e = i);
                              t.subtitleTrack = e;
                            }
                          }
                        );
                    },
                  },
                  {
                    key: "onMediaDetaching",
                    value: function () {
                      this.media = void 0;
                    },
                  },
                  {
                    key: "onManifestLoading",
                    value: function () {
                      (this.tracks = []), (this.trackId = -1);
                    },
                  },
                  {
                    key: "onManifestLoaded",
                    value: function (e) {
                      var t = this,
                        r = e.subtitles || [],
                        i = !1;
                      (this.tracks = r),
                        (this.trackId = -1),
                        this.hls.trigger(d.default.SUBTITLE_TRACKS_UPDATED, {
                          subtitleTracks: r,
                        }),
                        r.forEach(function (e) {
                          e.default && ((t.subtitleTrack = e.id), (i = !0));
                        });
                    },
                  },
                  {
                    key: "onTick",
                    value: function () {
                      var e = this.trackId,
                        t = this.tracks[e];
                      if (t) {
                        var r = t.details;
                        (void 0 !== r && r.live !== !0) ||
                          (h.logger.log(
                            "(re)loading playlist for subtitle track " + e
                          ),
                            this.hls.trigger(d.default.SUBTITLE_TRACK_LOADING, {
                              url: t.url,
                              id: e,
                            }));
                      }
                    },
                  },
                  {
                    key: "onSubtitleTrackLoaded",
                    value: function (e) {
                      var t = this;
                      e.id < this.tracks.length &&
                        (h.logger.log("subtitle track " + e.id + " loaded"),
                          (this.tracks[e.id].details = e.details),
                          e.details.live &&
                          !this.timer &&
                          (this.timer = setInterval(
                            function () {
                              t.onTick();
                            },
                            1e3 * e.details.targetduration,
                            this
                          )),
                          !e.details.live &&
                          this.timer &&
                          (clearInterval(this.timer), (this.timer = null)));
                    },
                  },
                  {
                    key: "setSubtitleTrackInternal",
                    value: function (e) {
                      if (e >= 0 && e < this.tracks.length) {
                        this.timer &&
                          (clearInterval(this.timer), (this.timer = null)),
                          (this.trackId = e),
                          h.logger.log("switching to subtitle track " + e);
                        var t = this.tracks[e];
                        this.hls.trigger(d.default.SUBTITLE_TRACK_SWITCH, {
                          id: e,
                        });
                        var r = t.details;
                        (void 0 !== r && r.live !== !0) ||
                          (h.logger.log(
                            "(re)loading playlist for subtitle track " + e
                          ),
                            this.hls.trigger(d.default.SUBTITLE_TRACK_LOADING, {
                              url: t.url,
                              id: e,
                            }));
                      }
                    },
                  },
                  {
                    key: "subtitleTracks",
                    get: function () {
                      return this.tracks;
                    },
                  },
                  {
                    key: "subtitleTrack",
                    get: function () {
                      return this.trackId;
                    },
                    set: function (e) {
                      this.trackId !== e && this.setSubtitleTrackInternal(e);
                    },
                  },
                ]),
                t
              );
            })(c.default);
          r.default = g;
        },
        { 32: 32, 33: 33, 51: 51 },
      ],
      16: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          function o(e) {
            if (e && e.cues) for (; e.cues.length > 0;) e.removeCue(e.cues[0]);
          }
          function l(e, t) {
            return e && e.label === t.name && !(e.textTrack1 || e.textTrack2);
          }
          function u(e, t, r, i) {
            return Math.min(t, i) - Math.max(e, r);
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var d = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            f = e(33),
            c = i(f),
            h = e(32),
            g = i(h),
            v = e(47),
            p = i(v),
            y = e(55),
            m = i(y),
            E = e(51),
            b = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    c.default.MEDIA_ATTACHING,
                    c.default.MEDIA_DETACHING,
                    c.default.FRAG_PARSING_USERDATA,
                    c.default.MANIFEST_LOADING,
                    c.default.MANIFEST_LOADED,
                    c.default.FRAG_LOADED,
                    c.default.LEVEL_SWITCHING,
                    c.default.INIT_PTS_FOUND
                  )
                );
                if (
                  ((r.hls = e),
                    (r.config = e.config),
                    (r.enabled = !0),
                    (r.Cues = e.config.cueHandler),
                    (r.textTracks = []),
                    (r.tracks = []),
                    (r.unparsedVttFrags = []),
                    (r.initPTS = void 0),
                    (r.cueRanges = []),
                    r.config.enableCEA708Captions)
                ) {
                  var i = r,
                    s = function (e, t) {
                      var r = null;
                      try {
                        r = new window.Event("addtrack");
                      } catch (e) {
                        (r = document.createEvent("Event")),
                          r.initEvent("addtrack", !1, !1);
                      }
                      (r.track = e), t.dispatchEvent(r);
                    },
                    l = {
                      newCue: function (e, t, r) {
                        if (!i.textTrack1) {
                          var a = i.getExistingTrack("1");
                          if (a)
                            (i.textTrack1 = a),
                              o(i.textTrack1),
                              s(i.textTrack1, i.media);
                          else {
                            var n = i.createTextTrack(
                              "captions",
                              i.config.captionsTextTrack1Label,
                              i.config.captionsTextTrack1LanguageCode
                            );
                            n && ((n.textTrack1 = !0), (i.textTrack1 = n));
                          }
                        }
                        i.addCues("textTrack1", e, t, r);
                      },
                    },
                    u = {
                      newCue: function (e, t, r) {
                        if (!i.textTrack2) {
                          var a = i.getExistingTrack("2");
                          if (a)
                            (i.textTrack2 = a),
                              o(i.textTrack2),
                              s(i.textTrack2, i.media);
                          else {
                            var n = i.createTextTrack(
                              "captions",
                              i.config.captionsTextTrack2Label,
                              i.config.captionsTextTrack1LanguageCode
                            );
                            n && ((n.textTrack2 = !0), (i.textTrack2 = n));
                          }
                        }
                        i.addCues("textTrack2", e, t, r);
                      },
                    };
                  r.cea608Parser = new p.default(0, l, u);
                }
                return r;
              }
              return (
                s(t, e),
                d(t, [
                  {
                    key: "addCues",
                    value: function (e, t, r, i) {
                      for (
                        var a = this.cueRanges, n = !1, s = a.length;
                        s--;

                      ) {
                        var o = a[s],
                          l = u(o[0], o[1], t, r);
                        if (
                          l >= 0 &&
                          ((o[0] = Math.min(o[0], t)),
                            (o[1] = Math.max(o[1], r)),
                            (n = !0),
                            l / (r - t) > 0.5)
                        )
                          return;
                      }
                      n || a.push([t, r]), this.Cues.newCue(this[e], t, r, i);
                    },
                  },
                  {
                    key: "onInitPtsFound",
                    value: function (e) {
                      var t = this;
                      void 0 === this.initPTS && (this.initPTS = e.initPTS),
                        this.unparsedVttFrags.length &&
                        (this.unparsedVttFrags.forEach(function (e) {
                          t.onFragLoaded(e);
                        }),
                          (this.unparsedVttFrags = []));
                    },
                  },
                  {
                    key: "getExistingTrack",
                    value: function (e) {
                      var t = this.media;
                      if (t)
                        for (var r = 0; r < t.textTracks.length; r++) {
                          var i = t.textTracks[r],
                            a = "textTrack" + e;
                          if (i[a] === !0) return i;
                        }
                      return null;
                    },
                  },
                  {
                    key: "createTextTrack",
                    value: function (e, t, r) {
                      var i = this.media;
                      if (i) return i.addTextTrack(e, t, r);
                    },
                  },
                  {
                    key: "destroy",
                    value: function () {
                      g.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onMediaAttaching",
                    value: function (e) {
                      this.media = e.media;
                    },
                  },
                  {
                    key: "onMediaDetaching",
                    value: function () {
                      o(this.textTrack1), o(this.textTrack2);
                    },
                  },
                  {
                    key: "onManifestLoading",
                    value: function () {
                      (this.lastSn = -1),
                        (this.prevCC = -1),
                        (this.vttCCs = { ccOffset: 0, presentationOffset: 0 });
                      var e = this.media;
                      if (e) {
                        var t = e.textTracks;
                        if (t) for (var r = 0; r < t.length; r++) o(t[r]);
                      }
                    },
                  },
                  {
                    key: "onManifestLoaded",
                    value: function (e) {
                      var t = this;
                      if (
                        ((this.textTracks = []),
                          (this.unparsedVttFrags = this.unparsedVttFrags || []),
                          (this.initPTS = void 0),
                          (this.cueRanges = []),
                          this.config.enableWebVTT)
                      ) {
                        this.tracks = e.subtitles || [];
                        var r = this.media ? this.media.textTracks : [];
                        this.tracks.forEach(function (e, i) {
                          var a = void 0;
                          if (i < r.length) {
                            var n = r[i];
                            l(n, e) && (a = n);
                          }
                          a ||
                            (a = t.createTextTrack(
                              "subtitles",
                              e.name,
                              e.lang
                            )),
                            (a.mode = e.default ? "showing" : "hidden"),
                            t.textTracks.push(a);
                        });
                      }
                    },
                  },
                  {
                    key: "onLevelSwitching",
                    value: function () {
                      this.enabled =
                        "NONE" !== this.hls.currentLevel.closedCaptions;
                    },
                  },
                  {
                    key: "onFragLoaded",
                    value: function (e) {
                      var t = e.frag,
                        r = e.payload;
                      if ("main" === t.type) {
                        var i = t.sn;
                        i !== this.lastSn + 1 && this.cea608Parser.reset(),
                          (this.lastSn = i);
                      } else if ("subtitle" === t.type)
                        if (r.byteLength) {
                          if (void 0 === this.initPTS)
                            return void this.unparsedVttFrags.push(e);
                          var a = this.vttCCs;
                          a[t.cc] ||
                            ((a[t.cc] = {
                              start: t.start,
                              prevCC: this.prevCC,
                              new: !0,
                            }),
                              (this.prevCC = t.cc));
                          var n = this.textTracks,
                            s = this.hls;
                          m.default.parse(
                            r,
                            this.initPTS,
                            a,
                            t.cc,
                            function (e) {
                              e.forEach(function (e) {
                                n[t.trackId].addCue(e);
                              }),
                                s.trigger(c.default.SUBTITLE_FRAG_PROCESSED, {
                                  success: !0,
                                  frag: t,
                                });
                            },
                            function (e) {
                              E.logger.log("Failed to parse VTT cue: " + e),
                                s.trigger(c.default.SUBTITLE_FRAG_PROCESSED, {
                                  success: !1,
                                  frag: t,
                                });
                            }
                          );
                        } else
                          this.hls.trigger(c.default.SUBTITLE_FRAG_PROCESSED, {
                            success: !1,
                            frag: t,
                          });
                    },
                  },
                  {
                    key: "onFragParsingUserdata",
                    value: function (e) {
                      if (this.enabled && this.config.enableCEA708Captions)
                        for (var t = 0; t < e.samples.length; t++) {
                          var r = this.extractCea608Data(e.samples[t].bytes);
                          this.cea608Parser.addData(e.samples[t].pts, r);
                        }
                    },
                  },
                  {
                    key: "extractCea608Data",
                    value: function (e) {
                      for (
                        var t, r, i, a, n, s = 31 & e[0], o = 2, l = [], u = 0;
                        u < s;
                        u++
                      )
                        (t = e[o++]),
                          (r = 127 & e[o++]),
                          (i = 127 & e[o++]),
                          (a = 0 != (4 & t)),
                          (n = 3 & t),
                          (0 === r && 0 === i) ||
                          (a && 0 === n && (l.push(r), l.push(i)));
                      return l;
                    },
                  },
                ]),
                t
              );
            })(g.default);
          r.default = b;
        },
        { 32: 32, 33: 33, 47: 47, 51: 51, 55: 55 },
      ],
      17: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = (function () {
              function e(t, r) {
                i(this, e), (this.subtle = t), (this.aesIV = r);
              }
              return (
                a(e, [
                  {
                    key: "decrypt",
                    value: function (e, t) {
                      return this.subtle.decrypt(
                        { name: "AES-CBC", iv: this.aesIV },
                        t,
                        e
                      );
                    },
                  },
                ]),
                e
              );
            })();
          r.default = n;
        },
        {},
      ],
      18: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = (function () {
              function e() {
                i(this, e),
                  (this.rcon = [0, 1, 2, 4, 8, 16, 32, 64, 128, 27, 54]),
                  (this.subMix = [
                    new Uint32Array(256),
                    new Uint32Array(256),
                    new Uint32Array(256),
                    new Uint32Array(256),
                  ]),
                  (this.invSubMix = [
                    new Uint32Array(256),
                    new Uint32Array(256),
                    new Uint32Array(256),
                    new Uint32Array(256),
                  ]),
                  (this.sBox = new Uint32Array(256)),
                  (this.invSBox = new Uint32Array(256)),
                  (this.key = new Uint32Array(0)),
                  this.initTable();
              }
              return (
                a(e, [
                  {
                    key: "uint8ArrayToUint32Array_",
                    value: function (e) {
                      for (
                        var t = new DataView(e), r = new Uint32Array(4), i = 0;
                        i < 4;
                        i++
                      )
                        r[i] = t.getUint32(4 * i);
                      return r;
                    },
                  },
                  {
                    key: "initTable",
                    value: function () {
                      var e = this.sBox,
                        t = this.invSBox,
                        r = this.subMix,
                        i = r[0],
                        a = r[1],
                        n = r[2],
                        s = r[3],
                        o = this.invSubMix,
                        l = o[0],
                        u = o[1],
                        d = o[2],
                        f = o[3],
                        c = new Uint32Array(256),
                        h = 0,
                        g = 0,
                        v = 0;
                      for (v = 0; v < 256; v++)
                        c[v] = v < 128 ? v << 1 : (v << 1) ^ 283;
                      for (v = 0; v < 256; v++) {
                        var p = g ^ (g << 1) ^ (g << 2) ^ (g << 3) ^ (g << 4);
                        (p = (p >>> 8) ^ (255 & p) ^ 99),
                          (e[h] = p),
                          (t[p] = h);
                        var y = c[h],
                          m = c[y],
                          E = c[m],
                          b = (257 * c[p]) ^ (16843008 * p);
                        (i[h] = (b << 24) | (b >>> 8)),
                          (a[h] = (b << 16) | (b >>> 16)),
                          (n[h] = (b << 8) | (b >>> 24)),
                          (s[h] = b),
                          (b =
                            (16843009 * E) ^
                            (65537 * m) ^
                            (257 * y) ^
                            (16843008 * h)),
                          (l[p] = (b << 24) | (b >>> 8)),
                          (u[p] = (b << 16) | (b >>> 16)),
                          (d[p] = (b << 8) | (b >>> 24)),
                          (f[p] = b),
                          h
                            ? ((h = y ^ c[c[c[E ^ y]]]), (g ^= c[c[g]]))
                            : (h = g = 1);
                      }
                    },
                  },
                  {
                    key: "expandKey",
                    value: function (e) {
                      for (
                        var t = this.uint8ArrayToUint32Array_(e), r = !0, i = 0;
                        i < t.length && r;

                      )
                        (r = t[i] === this.key[i]), i++;
                      if (!r) {
                        this.key = t;
                        var a = (this.keySize = t.length);
                        if (4 !== a && 6 !== a && 8 !== a)
                          throw new Error("Invalid aes key size=" + a);
                        var n = (this.ksRows = 4 * (a + 6 + 1)),
                          s = void 0,
                          o = void 0,
                          l = (this.keySchedule = new Uint32Array(n)),
                          u = (this.invKeySchedule = new Uint32Array(n)),
                          d = this.sBox,
                          f = this.rcon,
                          c = this.invSubMix,
                          h = c[0],
                          g = c[1],
                          v = c[2],
                          p = c[3],
                          y = void 0,
                          m = void 0;
                        for (s = 0; s < n; s++)
                          s < a
                            ? (y = l[s] = t[s])
                            : ((m = y),
                              s % a == 0
                                ? ((m = (m << 8) | (m >>> 24)),
                                  (m =
                                    (d[m >>> 24] << 24) |
                                    (d[(m >>> 16) & 255] << 16) |
                                    (d[(m >>> 8) & 255] << 8) |
                                    d[255 & m]),
                                  (m ^= f[(s / a) | 0] << 24))
                                : a > 6 &&
                                s % a == 4 &&
                                (m =
                                  (d[m >>> 24] << 24) |
                                  (d[(m >>> 16) & 255] << 16) |
                                  (d[(m >>> 8) & 255] << 8) |
                                  d[255 & m]),
                              (l[s] = y = (l[s - a] ^ m) >>> 0));
                        for (o = 0; o < n; o++)
                          (s = n - o),
                            (m = 3 & o ? l[s] : l[s - 4]),
                            (u[o] =
                              o < 4 || s <= 4
                                ? m
                                : h[d[m >>> 24]] ^
                                g[d[(m >>> 16) & 255]] ^
                                v[d[(m >>> 8) & 255]] ^
                                p[d[255 & m]]),
                            (u[o] = u[o] >>> 0);
                      }
                    },
                  },
                  {
                    key: "networkToHostOrderSwap",
                    value: function (e) {
                      return (
                        (e << 24) |
                        ((65280 & e) << 8) |
                        ((16711680 & e) >> 8) |
                        (e >>> 24)
                      );
                    },
                  },
                  {
                    key: "decrypt",
                    value: function (e, t, r) {
                      for (
                        var i,
                        a,
                        n = this.keySize + 6,
                        s = this.invKeySchedule,
                        o = this.invSBox,
                        l = this.invSubMix,
                        u = l[0],
                        d = l[1],
                        f = l[2],
                        c = l[3],
                        h = this.uint8ArrayToUint32Array_(r),
                        g = h[0],
                        v = h[1],
                        p = h[2],
                        y = h[3],
                        m = new Int32Array(e),
                        E = new Int32Array(m.length),
                        b = void 0,
                        T = void 0,
                        _ = void 0,
                        k = void 0,
                        R = void 0,
                        A = void 0,
                        S = void 0,
                        L = void 0,
                        w = void 0,
                        D = void 0,
                        O = void 0,
                        I = void 0,
                        P = this.networkToHostOrderSwap;
                        t < m.length;

                      ) {
                        for (
                          w = P(m[t]),
                          D = P(m[t + 1]),
                          O = P(m[t + 2]),
                          I = P(m[t + 3]),
                          R = w ^ s[0],
                          A = I ^ s[1],
                          S = O ^ s[2],
                          L = D ^ s[3],
                          i = 4,
                          a = 1;
                          a < n;
                          a++
                        )
                          (b =
                            u[R >>> 24] ^
                            d[(A >> 16) & 255] ^
                            f[(S >> 8) & 255] ^
                            c[255 & L] ^
                            s[i]),
                            (T =
                              u[A >>> 24] ^
                              d[(S >> 16) & 255] ^
                              f[(L >> 8) & 255] ^
                              c[255 & R] ^
                              s[i + 1]),
                            (_ =
                              u[S >>> 24] ^
                              d[(L >> 16) & 255] ^
                              f[(R >> 8) & 255] ^
                              c[255 & A] ^
                              s[i + 2]),
                            (k =
                              u[L >>> 24] ^
                              d[(R >> 16) & 255] ^
                              f[(A >> 8) & 255] ^
                              c[255 & S] ^
                              s[i + 3]),
                            (R = b),
                            (A = T),
                            (S = _),
                            (L = k),
                            (i += 4);
                        (b =
                          (o[R >>> 24] << 24) ^
                          (o[(A >> 16) & 255] << 16) ^
                          (o[(S >> 8) & 255] << 8) ^
                          o[255 & L] ^
                          s[i]),
                          (T =
                            (o[A >>> 24] << 24) ^
                            (o[(S >> 16) & 255] << 16) ^
                            (o[(L >> 8) & 255] << 8) ^
                            o[255 & R] ^
                            s[i + 1]),
                          (_ =
                            (o[S >>> 24] << 24) ^
                            (o[(L >> 16) & 255] << 16) ^
                            (o[(R >> 8) & 255] << 8) ^
                            o[255 & A] ^
                            s[i + 2]),
                          (k =
                            (o[L >>> 24] << 24) ^
                            (o[(R >> 16) & 255] << 16) ^
                            (o[(A >> 8) & 255] << 8) ^
                            o[255 & S] ^
                            s[i + 3]),
                          (i += 3),
                          (E[t] = P(b ^ g)),
                          (E[t + 1] = P(k ^ v)),
                          (E[t + 2] = P(_ ^ p)),
                          (E[t + 3] = P(T ^ y)),
                          (g = w),
                          (v = D),
                          (p = O),
                          (y = I),
                          (t += 4);
                      }
                      return E.buffer;
                    },
                  },
                  {
                    key: "destroy",
                    value: function () {
                      (this.key = void 0),
                        (this.keySize = void 0),
                        (this.ksRows = void 0),
                        (this.sBox = void 0),
                        (this.invSBox = void 0),
                        (this.subMix = void 0),
                        (this.invSubMix = void 0),
                        (this.keySchedule = void 0),
                        (this.invKeySchedule = void 0),
                        (this.rcon = void 0);
                    },
                  },
                ]),
                e
              );
            })();
          r.default = n;
        },
        {},
      ],
      19: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(17),
            o = i(s),
            l = e(20),
            u = i(l),
            d = e(18),
            f = i(d),
            c = e(31),
            h = e(51),
            g = (function () {
              function e(t, r) {
                a(this, e),
                  (this.observer = t),
                  (this.config = r),
                  (this.logEnabled = !0);
                try {
                  var i = crypto ? crypto : self.crypto;
                  this.subtle = i.subtle || i.webkitSubtle;
                } catch (e) { }
                this.disableWebCrypto = !this.subtle;
              }
              return (
                n(e, [
                  {
                    key: "isSync",
                    value: function () {
                      return (
                        this.disableWebCrypto && this.config.enableSoftwareAES
                      );
                    },
                  },
                  {
                    key: "decrypt",
                    value: function (e, t, r, i) {
                      var a = this;
                      if (
                        this.disableWebCrypto &&
                        this.config.enableSoftwareAES
                      ) {
                        this.logEnabled &&
                          (h.logger.log("JS AES decrypt"),
                            (this.logEnabled = !1));
                        var n = this.decryptor;
                        n || (this.decryptor = n = new f.default()),
                          n.expandKey(t),
                          i(n.decrypt(e, 0, r));
                      } else {
                        this.logEnabled &&
                          (h.logger.log("WebCrypto AES decrypt"),
                            (this.logEnabled = !1));
                        var s = this.subtle;
                        this.key !== t &&
                          ((this.key = t),
                            (this.fastAesKey = new u.default(s, t))),
                          this.fastAesKey
                            .expandKey()
                            .then(function (n) {
                              new o.default(s, r)
                                .decrypt(e, n)
                                .catch(function (n) {
                                  a.onWebCryptoError(n, e, t, r, i);
                                })
                                .then(function (e) {
                                  i(e);
                                });
                            })
                            .catch(function (n) {
                              a.onWebCryptoError(n, e, t, r, i);
                            });
                      }
                    },
                  },
                  {
                    key: "onWebCryptoError",
                    value: function (e, t, r, i, a) {
                      this.config.enableSoftwareAES
                        ? (h.logger.log(
                          "WebCrypto Error, disable WebCrypto API"
                        ),
                          (this.disableWebCrypto = !0),
                          (this.logEnabled = !0),
                          this.decrypt(t, r, i, a))
                        : (h.logger.error("decrypting error : " + e.message),
                          this.observer.trigger(Event.ERROR, {
                            type: c.ErrorTypes.MEDIA_ERROR,
                            details: c.ErrorDetails.FRAG_DECRYPT_ERROR,
                            fatal: !0,
                            reason: e.message,
                          }));
                    },
                  },
                  {
                    key: "destroy",
                    value: function () {
                      var e = this.decryptor;
                      e && (e.destroy(), (this.decryptor = void 0));
                    },
                  },
                ]),
                e
              );
            })();
          r.default = g;
        },
        { 17: 17, 18: 18, 20: 20, 31: 31, 51: 51 },
      ],
      20: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = (function () {
              function e(t, r) {
                i(this, e), (this.subtle = t), (this.key = r);
              }
              return (
                a(e, [
                  {
                    key: "expandKey",
                    value: function () {
                      return this.subtle.importKey(
                        "raw",
                        this.key,
                        { name: "AES-CBC" },
                        !1,
                        ["encrypt", "decrypt"]
                      );
                    },
                  },
                ]),
                e
              );
            })();
          r.default = n;
        },
        {},
      ],
      21: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(22),
            o = i(s),
            l = e(51),
            u = e(27),
            d = i(u),
            f = (function () {
              function e(t, r, i) {
                a(this, e),
                  (this.observer = t),
                  (this.config = i),
                  (this.remuxer = r);
              }
              return (
                n(
                  e,
                  [
                    {
                      key: "resetInitSegment",
                      value: function (e, t, r, i) {
                        this._aacTrack = {
                          container: "audio/adts",
                          type: "audio",
                          id: -1,
                          sequenceNumber: 0,
                          isAAC: !0,
                          samples: [],
                          len: 0,
                          manifestCodec: t,
                          duration: i,
                          inputTimeScale: 9e4,
                        };
                      },
                    },
                    { key: "resetTimeStamp", value: function () { } },
                    {
                      key: "append",
                      value: function (e, t, r, i) {
                        var a,
                          n,
                          s,
                          u,
                          f,
                          c,
                          h,
                          g,
                          v,
                          p,
                          y = new d.default(e),
                          m = 90 * y.timeStamp;
                        for (
                          a = this._aacTrack, c = y.length, v = e.length;
                          c < v - 1 &&
                          (255 !== e[c] || 240 != (240 & e[c + 1]));
                          c++
                        );
                        for (
                          a.samplerate ||
                          ((n = o.default.getAudioConfig(
                            this.observer,
                            e,
                            c,
                            a.manifestCodec
                          )),
                            (a.config = n.config),
                            (a.samplerate = n.samplerate),
                            (a.channelCount = n.channelCount),
                            (a.codec = n.codec),
                            l.logger.log(
                              "parsed codec:" +
                              a.codec +
                              ",rate:" +
                              n.samplerate +
                              ",nb channel:" +
                              n.channelCount
                            )),
                          f = 0,
                          u = 9216e4 / a.samplerate;
                          c + 5 < v &&
                          ((h = 1 & e[c + 1] ? 7 : 9),
                            (s =
                              ((3 & e[c + 3]) << 11) |
                              (e[c + 4] << 3) |
                              ((224 & e[c + 5]) >>> 5)),
                            (s -= h) > 0 && c + h + s <= v);

                        )
                          for (
                            g = m + f * u,
                            p = {
                              unit: e.subarray(c + h, c + h + s),
                              pts: g,
                              dts: g,
                            },
                            a.samples.push(p),
                            a.len += s,
                            c += s + h,
                            f++;
                            c < v - 1 &&
                            (255 !== e[c] || 240 != (240 & e[c + 1]));
                            c++
                          );
                        this.remuxer.remux(
                          a,
                          { samples: [] },
                          {
                            samples: [{ pts: m, dts: m, unit: y.payload }],
                            inputTimeScale: 9e4,
                          },
                          { samples: [] },
                          t,
                          r,
                          i
                        );
                      },
                    },
                    { key: "destroy", value: function () { } },
                  ],
                  [
                    {
                      key: "probe",
                      value: function (e) {
                        var t,
                          r,
                          i = new d.default(e);
                        if (i.hasTimeStamp)
                          for (t = i.length, r = e.length; t < r - 1; t++)
                            if (255 === e[t] && 240 == (240 & e[t + 1]))
                              return !0;
                        return !1;
                      },
                    },
                  ]
                ),
                e
              );
            })();
          r.default = f;
        },
        { 22: 22, 27: 27, 51: 51 },
      ],
      22: [
        function (e, t, r) {
          "use strict";
          var i = e(51),
            a = e(31),
            n = {
              getAudioConfig: function (e, t, r, n) {
                var s,
                  o,
                  l,
                  u,
                  d,
                  f = navigator.userAgent.toLowerCase(),
                  c = n,
                  h = [
                    96e3, 88200, 64e3, 48e3, 44100, 32e3, 24e3, 22050, 16e3,
                    12e3, 11025, 8e3, 7350,
                  ];
                return (
                  (s = 1 + ((192 & t[r + 2]) >>> 6)),
                  (o = (60 & t[r + 2]) >>> 2) > h.length - 1
                    ? void e.trigger(Event.ERROR, {
                      type: a.ErrorTypes.MEDIA_ERROR,
                      details: a.ErrorDetails.FRAG_PARSING_ERROR,
                      fatal: !0,
                      reason: "invalid ADTS sampling index:" + o,
                    })
                    : ((u = (1 & t[r + 2]) << 2),
                      (u |= (192 & t[r + 3]) >>> 6),
                      i.logger.log(
                        "manifest codec:" +
                        n +
                        ",ADTS data:type:" +
                        s +
                        ",sampleingIndex:" +
                        o +
                        "[" +
                        h[o] +
                        "Hz],channelConfig:" +
                        u
                      ),
                      /firefox/i.test(f)
                        ? o >= 6
                          ? ((s = 5), (d = new Array(4)), (l = o - 3))
                          : ((s = 2), (d = new Array(2)), (l = o))
                        : f.indexOf("android") !== -1
                          ? ((s = 2), (d = new Array(2)), (l = o))
                          : ((s = 5),
                            (d = new Array(4)),
                            (n &&
                              (n.indexOf("mp4a.40.29") !== -1 ||
                                n.indexOf("mp4a.40.5") !== -1)) ||
                              (!n && o >= 6)
                              ? (l = o - 3)
                              : (((n &&
                                n.indexOf("mp4a.40.2") !== -1 &&
                                o >= 6 &&
                                1 === u) ||
                                (!n && 1 === u)) &&
                                ((s = 2), (d = new Array(2))),
                                (l = o))),
                      (d[0] = s << 3),
                      (d[0] |= (14 & o) >> 1),
                      (d[1] |= (1 & o) << 7),
                      (d[1] |= u << 3),
                      5 === s &&
                      ((d[1] |= (14 & l) >> 1),
                        (d[2] = (1 & l) << 7),
                        (d[2] |= 8),
                        (d[3] = 0)),
                    {
                      config: d,
                      samplerate: h[o],
                      channelCount: u,
                      codec: "mp4a.40." + s,
                      manifestCodec: c,
                    })
                );
              },
            };
          t.exports = n;
        },
        { 31: 31, 51: 51 },
      ],
      23: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(33),
            o = i(s),
            l = e(31),
            u = e(19),
            d = i(u),
            f = e(21),
            c = i(f),
            h = e(28),
            g = i(h),
            v = e(30),
            p = i(v),
            y = e(43),
            m = i(y),
            E = e(44),
            b = i(E),
            T = (function () {
              function e(t, r, i, n) {
                a(this, e),
                  (this.observer = t),
                  (this.typeSupported = r),
                  (this.config = i),
                  (this.vendor = n);
              }
              return (
                n(e, [
                  {
                    key: "destroy",
                    value: function () {
                      var e = this.demuxer;
                      e && e.destroy();
                    },
                  },
                  {
                    key: "push",
                    value: function (e, t, r, i, a, n, s, l, u, f, c, h) {
                      if (
                        e.byteLength > 0 &&
                        null != t &&
                        null != t.key &&
                        "AES-128" === t.method
                      ) {
                        var g = this.decrypter;
                        null == g &&
                          (g = this.decrypter =
                            new d.default(this.observer, this.config));
                        var v,
                          p = this;
                        try {
                          v = performance.now();
                        } catch (e) {
                          v = Date.now();
                        }
                        g.decrypt(e, t.key.buffer, t.iv.buffer, function (e) {
                          var d;
                          try {
                            d = performance.now();
                          } catch (e) {
                            d = Date.now();
                          }
                          p.observer.trigger(o.default.FRAG_DECRYPTED, {
                            stats: { tstart: v, tdecrypt: d },
                          }),
                            p.pushDecrypted(
                              new Uint8Array(e),
                              t,
                              new Uint8Array(r),
                              i,
                              a,
                              n,
                              s,
                              l,
                              u,
                              f,
                              c,
                              h
                            );
                        });
                      } else
                        this.pushDecrypted(
                          new Uint8Array(e),
                          t,
                          new Uint8Array(r),
                          i,
                          a,
                          n,
                          s,
                          l,
                          u,
                          f,
                          c,
                          h
                        );
                    },
                  },
                  {
                    key: "pushDecrypted",
                    value: function (e, t, r, i, a, n, s, u, d, f, h, v) {
                      var y = this.demuxer;
                      if (!y || (s && !this.probe(e))) {
                        var E = this.observer,
                          T = this.typeSupported,
                          _ = this.config,
                          k = [
                            { demux: p.default, remux: m.default },
                            { demux: c.default, remux: m.default },
                            { demux: g.default, remux: b.default },
                          ];
                        for (var R in k) {
                          var A = k[R],
                            S = A.demux.probe;
                          if (S(e)) {
                            var L = (this.remuxer = new A.remux(
                              E,
                              _,
                              T,
                              this.vendor
                            ));
                            (y = new A.demux(E, L, _, T)), (this.probe = S);
                            break;
                          }
                        }
                        if (!y)
                          return void E.trigger(o.default.ERROR, {
                            type: l.ErrorTypes.MEDIA_ERROR,
                            details: l.ErrorDetails.FRAG_PARSING_ERROR,
                            fatal: !0,
                            reason: "no demux matching with content found",
                          });
                        this.demuxer = y;
                      }
                      var w = this.remuxer;
                      (s || u) &&
                        (y.resetInitSegment(r, i, a, f), w.resetInitSegment()),
                        s && (y.resetTimeStamp(), w.resetTimeStamp(v)),
                        "function" == typeof y.setDecryptData &&
                        y.setDecryptData(t),
                        y.append(e, n, d, h);
                    },
                  },
                ]),
                e
              );
            })();
          r.default = T;
        },
        { 19: 19, 21: 21, 28: 28, 30: 30, 31: 31, 33: 33, 43: 43, 44: 44 },
      ],
      24: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = e(23),
            n = i(a),
            s = e(33),
            o = i(s),
            l = e(51),
            u = e(1),
            d = i(u),
            f = function (e) {
              var t = new d.default();
              (t.trigger = function (e) {
                for (
                  var r = arguments.length, i = Array(r > 1 ? r - 1 : 0), a = 1;
                  a < r;
                  a++
                )
                  i[a - 1] = arguments[a];
                t.emit.apply(t, [e, e].concat(i));
              }),
                (t.off = function (e) {
                  for (
                    var r = arguments.length,
                    i = Array(r > 1 ? r - 1 : 0),
                    a = 1;
                    a < r;
                    a++
                  )
                    i[a - 1] = arguments[a];
                  t.removeListener.apply(t, [e].concat(i));
                });
              var r = function (t, r) {
                e.postMessage({ event: t, data: r });
              };
              e.addEventListener("message", function (i) {
                var a = i.data;
                switch (a.cmd) {
                  case "init":
                    var s = JSON.parse(a.config);
                    e.demuxer = new n.default(t, a.typeSupported, s, a.vendor);
                    try {
                      (0, l.enableLogs)(s.debug === !0);
                    } catch (e) { }
                    r("init", null);
                    break;
                  case "demux":
                    e.demuxer.push(
                      a.data,
                      a.decryptdata,
                      a.initSegment,
                      a.audioCodec,
                      a.videoCodec,
                      a.timeOffset,
                      a.discontinuity,
                      a.trackSwitch,
                      a.contiguous,
                      a.duration,
                      a.accurateTimeOffset,
                      a.defaultInitPTS
                    );
                }
              }),
                t.on(o.default.FRAG_DECRYPTED, r),
                t.on(o.default.FRAG_PARSING_INIT_SEGMENT, r),
                t.on(o.default.FRAG_PARSED, r),
                t.on(o.default.ERROR, r),
                t.on(o.default.FRAG_PARSING_METADATA, r),
                t.on(o.default.FRAG_PARSING_USERDATA, r),
                t.on(o.default.INIT_PTS_FOUND, r),
                t.on(o.default.FRAG_PARSING_DATA, function (t, r) {
                  var i = [],
                    a = { event: t, data: r };
                  r.data1 &&
                    ((a.data1 = r.data1.buffer),
                      i.push(r.data1.buffer),
                      delete r.data1),
                    r.data2 &&
                    ((a.data2 = r.data2.buffer),
                      i.push(r.data2.buffer),
                      delete r.data2),
                    e.postMessage(a, i);
                });
            };
          r.default = f;
        },
        { 1: 1, 23: 23, 33: 33, 51: 51 },
      ],
      25: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(33),
            o = i(s),
            l = e(23),
            u = i(l),
            d = e(24),
            f = i(d),
            c = e(51),
            h = e(31),
            g = e(1),
            v = i(g),
            p = (function () {
              function t(r, i) {
                a(this, t), (this.hls = r), (this.id = i);
                var n = (this.observer = new v.default()),
                  s = r.config;
                (n.trigger = function (e) {
                  for (
                    var t = arguments.length,
                    r = Array(t > 1 ? t - 1 : 0),
                    i = 1;
                    i < t;
                    i++
                  )
                    r[i - 1] = arguments[i];
                  n.emit.apply(n, [e, e].concat(r));
                }),
                  (n.off = function (e) {
                    for (
                      var t = arguments.length,
                      r = Array(t > 1 ? t - 1 : 0),
                      i = 1;
                      i < t;
                      i++
                    )
                      r[i - 1] = arguments[i];
                    n.removeListener.apply(n, [e].concat(r));
                  });
                var l = function (e, t) {
                  (t = t || {}),
                    (t.frag = this.frag),
                    (t.id = this.id),
                    r.trigger(e, t);
                }.bind(this);
                n.on(o.default.FRAG_DECRYPTED, l),
                  n.on(o.default.FRAG_PARSING_INIT_SEGMENT, l),
                  n.on(o.default.FRAG_PARSING_DATA, l),
                  n.on(o.default.FRAG_PARSED, l),
                  n.on(o.default.ERROR, l),
                  n.on(o.default.FRAG_PARSING_METADATA, l),
                  n.on(o.default.FRAG_PARSING_USERDATA, l),
                  n.on(o.default.INIT_PTS_FOUND, l);
                var d = {
                  mp4: MediaSource.isTypeSupported("video/mp4"),
                  mpeg: MediaSource.isTypeSupported("audio/mpeg"),
                  mp3: MediaSource.isTypeSupported('audio/mp4; codecs="mp3"'),
                },
                  g = navigator.vendor;
                if (s.enableWorker && "undefined" != typeof Worker) {
                  c.logger.log("demuxing in webworker");
                  var p = void 0;
                  try {
                    var y = e(3);
                    (p = this.w = y(f.default)),
                      (this.onwmsg = this.onWorkerMessage.bind(this)),
                      p.addEventListener("message", this.onwmsg),
                      (p.onerror = function (e) {
                        r.trigger(o.default.ERROR, {
                          type: h.ErrorTypes.OTHER_ERROR,
                          details: h.ErrorDetails.INTERNAL_EXCEPTION,
                          fatal: !0,
                          event: "demuxerWorker",
                          err: {
                            message:
                              e.message +
                              " (" +
                              e.filename +
                              ":" +
                              e.lineno +
                              ")",
                          },
                        });
                      }),
                      p.postMessage({
                        cmd: "init",
                        typeSupported: d,
                        vendor: g,
                        id: i,
                        config: JSON.stringify(s),
                      });
                  } catch (e) {
                    c.logger.error(
                      "error while initializing DemuxerWorker, fallback on DemuxerInline"
                    ),
                      p && URL.revokeObjectURL(p.objectURL),
                      (this.demuxer = new u.default(n, d, s, g)),
                      (this.w = void 0);
                  }
                } else this.demuxer = new u.default(n, d, s, g);
              }
              return (
                n(t, [
                  {
                    key: "destroy",
                    value: function () {
                      var e = this.w;
                      if (e)
                        e.removeEventListener("message", this.onwmsg),
                          e.terminate(),
                          (this.w = null);
                      else {
                        var t = this.demuxer;
                        t && (t.destroy(), (this.demuxer = null));
                      }
                      var r = this.observer;
                      r && (r.removeAllListeners(), (this.observer = null));
                    },
                  },
                  {
                    key: "push",
                    value: function (e, t, r, i, a, n, s, o) {
                      var l = this.w,
                        u = isNaN(a.startDTS) ? a.start : a.startDTS,
                        d = a.decryptdata,
                        f = this.frag,
                        h = !(f && a.cc === f.cc),
                        g = !(f && a.level === f.level),
                        v = f && a.sn === f.sn + 1,
                        p = !g && v;
                      if (
                        (h && c.logger.log(this.id + ":discontinuity detected"),
                          g && c.logger.log(this.id + ":switch detected"),
                          (this.frag = a),
                          l)
                      )
                        l.postMessage(
                          {
                            cmd: "demux",
                            data: e,
                            decryptdata: d,
                            initSegment: t,
                            audioCodec: r,
                            videoCodec: i,
                            timeOffset: u,
                            discontinuity: h,
                            trackSwitch: g,
                            contiguous: p,
                            duration: n,
                            accurateTimeOffset: s,
                            defaultInitPTS: o,
                          },
                          [e]
                        );
                      else {
                        var y = this.demuxer;
                        y && y.push(e, d, t, r, i, u, h, g, p, n, s, o);
                      }
                    },
                  },
                  {
                    key: "onWorkerMessage",
                    value: function (e) {
                      var t = e.data,
                        r = this.hls;
                      switch (t.event) {
                        case "init":
                          URL.revokeObjectURL(this.w.objectURL);
                          break;
                        case o.default.FRAG_PARSING_DATA:
                          (t.data.data1 = new Uint8Array(t.data1)),
                            t.data2 && (t.data.data2 = new Uint8Array(t.data2));
                        default:
                          (t.data = t.data || {}),
                            (t.data.frag = this.frag),
                            (t.data.id = this.id),
                            r.trigger(t.event, t.data);
                      }
                    },
                  },
                ]),
                t
              );
            })();
          r.default = p;
        },
        { 1: 1, 23: 23, 24: 24, 3: 3, 31: 31, 33: 33, 51: 51 },
      ],
      26: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(51),
            s = (function () {
              function e(t) {
                i(this, e),
                  (this.data = t),
                  (this.bytesAvailable = t.byteLength),
                  (this.word = 0),
                  (this.bitsAvailable = 0);
              }
              return (
                a(e, [
                  {
                    key: "loadWord",
                    value: function () {
                      var e = this.data,
                        t = this.bytesAvailable,
                        r = e.byteLength - t,
                        i = new Uint8Array(4),
                        a = Math.min(4, t);
                      if (0 === a) throw new Error("no bytes available");
                      i.set(e.subarray(r, r + a)),
                        (this.word = new DataView(i.buffer).getUint32(0)),
                        (this.bitsAvailable = 8 * a),
                        (this.bytesAvailable -= a);
                    },
                  },
                  {
                    key: "skipBits",
                    value: function (e) {
                      var t;
                      this.bitsAvailable > e
                        ? ((this.word <<= e), (this.bitsAvailable -= e))
                        : ((e -= this.bitsAvailable),
                          (t = e >> 3),
                          (e -= t >> 3),
                          (this.bytesAvailable -= t),
                          this.loadWord(),
                          (this.word <<= e),
                          (this.bitsAvailable -= e));
                    },
                  },
                  {
                    key: "readBits",
                    value: function (e) {
                      var t = Math.min(this.bitsAvailable, e),
                        r = this.word >>> (32 - t);
                      return (
                        e > 32 &&
                        n.logger.error(
                          "Cannot read more than 32 bits at a time"
                        ),
                        (this.bitsAvailable -= t),
                        this.bitsAvailable > 0
                          ? (this.word <<= t)
                          : this.bytesAvailable > 0 && this.loadWord(),
                        (t = e - t),
                        t > 0 && this.bitsAvailable
                          ? (r << t) | this.readBits(t)
                          : r
                      );
                    },
                  },
                  {
                    key: "skipLZ",
                    value: function () {
                      var e;
                      for (e = 0; e < this.bitsAvailable; ++e)
                        if (0 != (this.word & (2147483648 >>> e)))
                          return (
                            (this.word <<= e), (this.bitsAvailable -= e), e
                          );
                      return this.loadWord(), e + this.skipLZ();
                    },
                  },
                  {
                    key: "skipUEG",
                    value: function () {
                      this.skipBits(1 + this.skipLZ());
                    },
                  },
                  {
                    key: "skipEG",
                    value: function () {
                      this.skipBits(1 + this.skipLZ());
                    },
                  },
                  {
                    key: "readUEG",
                    value: function () {
                      var e = this.skipLZ();
                      return this.readBits(e + 1) - 1;
                    },
                  },
                  {
                    key: "readEG",
                    value: function () {
                      var e = this.readUEG();
                      return 1 & e ? (1 + e) >>> 1 : -1 * (e >>> 1);
                    },
                  },
                  {
                    key: "readBoolean",
                    value: function () {
                      return 1 === this.readBits(1);
                    },
                  },
                  {
                    key: "readUByte",
                    value: function () {
                      return this.readBits(8);
                    },
                  },
                  {
                    key: "readUShort",
                    value: function () {
                      return this.readBits(16);
                    },
                  },
                  {
                    key: "readUInt",
                    value: function () {
                      return this.readBits(32);
                    },
                  },
                  {
                    key: "skipScalingList",
                    value: function (e) {
                      var t,
                        r,
                        i = 8,
                        a = 8;
                      for (t = 0; t < e; t++)
                        0 !== a &&
                          ((r = this.readEG()), (a = (i + r + 256) % 256)),
                          (i = 0 === a ? i : a);
                    },
                  },
                  {
                    key: "readSPS",
                    value: function () {
                      var e,
                        t,
                        r,
                        i,
                        a,
                        n,
                        s,
                        o = 0,
                        l = 0,
                        u = 0,
                        d = 0,
                        f = this.readUByte.bind(this),
                        c = this.readBits.bind(this),
                        h = this.readUEG.bind(this),
                        g = this.readBoolean.bind(this),
                        v = this.skipBits.bind(this),
                        p = this.skipEG.bind(this),
                        y = this.skipUEG.bind(this),
                        m = this.skipScalingList.bind(this);
                      if (
                        (f(),
                          (e = f()),
                          c(5),
                          v(3),
                          f(),
                          y(),
                          100 === e ||
                          110 === e ||
                          122 === e ||
                          244 === e ||
                          44 === e ||
                          83 === e ||
                          86 === e ||
                          118 === e ||
                          128 === e)
                      ) {
                        var E = h();
                        if ((3 === E && v(1), y(), y(), v(1), g()))
                          for (n = 3 !== E ? 8 : 12, s = 0; s < n; s++)
                            g() && m(s < 6 ? 16 : 64);
                      }
                      y();
                      var b = h();
                      if (0 === b) h();
                      else if (1 === b)
                        for (v(1), p(), p(), t = h(), s = 0; s < t; s++) p();
                      y(),
                        v(1),
                        (r = h()),
                        (i = h()),
                        (a = c(1)),
                        0 === a && v(1),
                        v(1),
                        g() && ((o = h()), (l = h()), (u = h()), (d = h()));
                      var T = [1, 1];
                      if (g() && g()) {
                        switch (f()) {
                          case 1:
                            T = [1, 1];
                            break;
                          case 2:
                            T = [12, 11];
                            break;
                          case 3:
                            T = [10, 11];
                            break;
                          case 4:
                            T = [16, 11];
                            break;
                          case 5:
                            T = [40, 33];
                            break;
                          case 6:
                            T = [24, 11];
                            break;
                          case 7:
                            T = [20, 11];
                            break;
                          case 8:
                            T = [32, 11];
                            break;
                          case 9:
                            T = [80, 33];
                            break;
                          case 10:
                            T = [18, 11];
                            break;
                          case 11:
                            T = [15, 11];
                            break;
                          case 12:
                            T = [64, 33];
                            break;
                          case 13:
                            T = [160, 99];
                            break;
                          case 14:
                            T = [4, 3];
                            break;
                          case 15:
                            T = [3, 2];
                            break;
                          case 16:
                            T = [2, 1];
                            break;
                          case 255:
                            T = [(f() << 8) | f(), (f() << 8) | f()];
                        }
                      }
                      return {
                        width: Math.ceil(16 * (r + 1) - 2 * o - 2 * l),
                        height: (2 - a) * (i + 1) * 16 - (a ? 2 : 4) * (u + d),
                        pixelRatio: T,
                      };
                    },
                  },
                  {
                    key: "readSliceType",
                    value: function () {
                      return this.readUByte(), this.readUEG(), this.readUEG();
                    },
                  },
                ]),
                e
              );
            })();
          r.default = s;
        },
        { 51: 51 },
      ],
      27: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(51),
            s = (function () {
              function e(t) {
                i(this, e), (this._hasTimeStamp = !1);
                for (var r, a, s, o, l, u, d, f, c = 0; ;)
                  if (((d = this.readUTF(t, c, 3)), (c += 3), "ID3" === d))
                    (c += 3),
                      (r = 127 & t[c++]),
                      (a = 127 & t[c++]),
                      (s = 127 & t[c++]),
                      (o = 127 & t[c++]),
                      (l = (r << 21) + (a << 14) + (s << 7) + o),
                      (u = c + l),
                      this._parseID3Frames(t, c, u),
                      (c = u);
                  else {
                    if ("3DI" !== d)
                      return (
                        (c -= 3),
                        void (
                          (f = c) &&
                          (this.hasTimeStamp ||
                            n.logger.warn("ID3 tag found, but no timestamp"),
                            (this._length = f),
                            (this._payload = t.subarray(0, f)))
                        )
                      );
                    (c += 7), n.logger.log("3DI footer found, end: " + c);
                  }
              }
              return (
                a(e, [
                  {
                    key: "readUTF",
                    value: function (e, t, r) {
                      var i = "",
                        a = t,
                        n = t + r;
                      do {
                        i += String.fromCharCode(e[a++]);
                      } while (a < n);
                      return i;
                    },
                  },
                  {
                    key: "_parseID3Frames",
                    value: function (e, t, r) {
                      for (var i, a; t + 8 <= r;)
                        switch (
                        ((i = this.readUTF(e, t, 4)),
                          (t += 4),
                          ((e[t++] << (24 + e[t++])) << (16 + e[t++])) <<
                          (8 + e[t++]),
                          e[t++] << (8 + e[t++]),
                          t,
                          i)
                        ) {
                          case "PRIV":
                            if (
                              "com.apple.streaming.transportStreamTimestamp" ===
                              this.readUTF(e, t, 44)
                            ) {
                              (t += 44), (t += 4);
                              var s = 1 & e[t++];
                              (this._hasTimeStamp = !0),
                                (a =
                                  ((e[t++] << 23) +
                                    (e[t++] << 15) +
                                    (e[t++] << 7) +
                                    e[t++]) /
                                  45),
                                s && (a += 47721858.84),
                                (a = Math.round(a)),
                                n.logger.trace("ID3 timestamp found: " + a),
                                (this._timeStamp = a);
                            }
                        }
                    },
                  },
                  {
                    key: "hasTimeStamp",
                    get: function () {
                      return this._hasTimeStamp;
                    },
                  },
                  {
                    key: "timeStamp",
                    get: function () {
                      return this._timeStamp;
                    },
                  },
                  {
                    key: "length",
                    get: function () {
                      return this._length;
                    },
                  },
                  {
                    key: "payload",
                    get: function () {
                      return this._payload;
                    },
                  },
                ]),
                e
              );
            })();
          r.default = s;
        },
        { 51: 51 },
      ],
      28: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(33),
            s = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(n),
            o = (function () {
              function e(t, r) {
                i(this, e), (this.observer = t), (this.remuxer = r);
              }
              return (
                a(
                  e,
                  [
                    { key: "resetTimeStamp", value: function () { } },
                    {
                      key: "resetInitSegment",
                      value: function (t, r, i, a) {
                        var n = (this.initData = e.parseInitSegment(t)),
                          o = {};
                        n.audio &&
                          (o.audio = {
                            container: "audio/mp4",
                            codec: r,
                            initSegment: t,
                          }),
                          n.video &&
                          (o.video = {
                            container: "video/mp4",
                            codec: i,
                            initSegment: t,
                          }),
                          this.observer.trigger(
                            s.default.FRAG_PARSING_INIT_SEGMENT,
                            { tracks: o }
                          );
                      },
                    },
                    {
                      key: "append",
                      value: function (t, r, i, a) {
                        var n = this.initData,
                          s = e.startDTS(n, t);
                        this.remuxer.remux(
                          n.audio,
                          n.video,
                          null,
                          null,
                          s,
                          i,
                          a,
                          t
                        );
                      },
                    },
                    { key: "destroy", value: function () { } },
                  ],
                  [
                    {
                      key: "probe",
                      value: function (t) {
                        if (t.length >= 8) {
                          var r = e.bin2str(t.subarray(4, 8));
                          return ["moof", "ftyp", "styp"].indexOf(r) >= 0;
                        }
                        return !1;
                      },
                    },
                    {
                      key: "bin2str",
                      value: function (e) {
                        return String.fromCharCode.apply(null, e);
                      },
                    },
                    {
                      key: "findBox",
                      value: function (t, r) {
                        var i,
                          a,
                          n,
                          s,
                          o,
                          l = [];
                        if (!r.length) return null;
                        for (i = 0; i < t.byteLength;)
                          (a = t[i] << 24),
                            (a |= t[i + 1] << 16),
                            (a |= t[i + 2] << 8),
                            (a |= t[i + 3]),
                            (n = e.bin2str(t.subarray(i + 4, i + 8))),
                            (s = a > 1 ? i + a : t.byteLength),
                            n === r[0] &&
                            (1 === r.length
                              ? l.push(t.subarray(i + 8, s))
                              : ((o = e.findBox(
                                t.subarray(i + 8, s),
                                r.slice(1)
                              )),
                                o.length && (l = l.concat(o)))),
                            (i = s);
                        return l;
                      },
                    },
                    {
                      key: "parseInitSegment",
                      value: function (t) {
                        var r = [];
                        return (
                          e.findBox(t, ["moov", "trak"]).forEach(function (t) {
                            var i = e.findBox(t, ["tkhd"])[0];
                            if (i) {
                              var a = i[0],
                                n = 0 === a ? 12 : 20,
                                s =
                                  (i[n] << 24) |
                                  (i[n + 1] << 16) |
                                  (i[n + 2] << 8) |
                                  i[n + 3];
                              s = s < 0 ? 4294967296 + s : s;
                              var o = e.findBox(t, ["mdia", "mdhd"])[0];
                              if (o) {
                                (a = o[0]), (n = 0 === a ? 12 : 20);
                                var l =
                                  (o[n] << 24) |
                                  (o[n + 1] << 16) |
                                  (o[n + 2] << 8) |
                                  o[n + 3],
                                  u = e.findBox(t, ["mdia", "hdlr"])[0];
                                if (u) {
                                  var d = e.bin2str(u.subarray(8, 12)),
                                    f = { soun: "audio", vide: "video" }[d];
                                  f &&
                                    ((r[s] = { timescale: l, type: f }),
                                      (r[f] = { timescale: l, id: s }));
                                }
                              }
                            }
                          }),
                          r
                        );
                      },
                    },
                    {
                      key: "startDTS",
                      value: function (t, r) {
                        var i, a, n;
                        return (
                          (i = e.findBox(r, ["moof", "traf"])),
                          (a = [].concat.apply(
                            [],
                            i.map(function (r) {
                              return e.findBox(r, ["tfhd"]).map(function (i) {
                                var a, n, s;
                                return (
                                  (a =
                                    (i[4] << 24) |
                                    (i[5] << 16) |
                                    (i[6] << 8) |
                                    i[7]),
                                  (n = t[a].timescale || 9e4),
                                  (s = e.findBox(r, ["tfdt"]).map(function (e) {
                                    var t, r;
                                    return (
                                      (t = e[0]),
                                      (r =
                                        (e[4] << 24) |
                                        (e[5] << 16) |
                                        (e[6] << 8) |
                                        e[7]),
                                      1 === t &&
                                      ((r *= Math.pow(2, 32)),
                                        (r +=
                                          (e[8] << 24) |
                                          (e[9] << 16) |
                                          (e[10] << 8) |
                                          e[11])),
                                      r
                                    );
                                  })[0]),
                                  (s = s || 1 / 0) / n
                                );
                              });
                            })
                          )),
                          (n = Math.min.apply(null, a)),
                          isFinite(n) ? n : 0
                        );
                      },
                    },
                  ]
                ),
                e
              );
            })();
          r.default = o;
        },
        { 33: 33 },
      ],
      29: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(19),
            s = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(n),
            o = (function () {
              function e(t, r, a, n) {
                i(this, e),
                  (this.decryptdata = a),
                  (this.discardEPB = n),
                  (this.decrypter = new s.default(t, r));
              }
              return (
                a(e, [
                  {
                    key: "decryptBuffer",
                    value: function (e, t) {
                      this.decrypter.decrypt(
                        e,
                        this.decryptdata.key.buffer,
                        this.decryptdata.iv.buffer,
                        t
                      );
                    },
                  },
                  {
                    key: "decryptAacSample",
                    value: function (e, t, r, i) {
                      var a = e[t].unit,
                        n = a.subarray(16, a.length - (a.length % 16)),
                        s = n.buffer.slice(
                          n.byteOffset,
                          n.byteOffset + n.length
                        ),
                        o = this;
                      this.decryptBuffer(s, function (n) {
                        (n = new Uint8Array(n)),
                          a.set(n, 16),
                          i || o.decryptAacSamples(e, t + 1, r);
                      });
                    },
                  },
                  {
                    key: "decryptAacSamples",
                    value: function (e, t, r) {
                      for (; ; t++) {
                        if (t >= e.length) return void r();
                        if (!(e[t].unit.length < 32)) {
                          var i = this.decrypter.isSync();
                          if ((this.decryptAacSample(e, t, r, i), !i)) return;
                        }
                      }
                    },
                  },
                  {
                    key: "getAvcEncryptedData",
                    value: function (e) {
                      for (
                        var t = 16 * Math.floor((e.length - 48) / 160) + 16,
                        r = new Int8Array(t),
                        i = 0,
                        a = 32;
                        a <= e.length - 16;
                        a += 160, i += 16
                      )
                        r.set(e.subarray(a, a + 16), i);
                      return r;
                    },
                  },
                  {
                    key: "getAvcDecryptedUnit",
                    value: function (e, t) {
                      t = new Uint8Array(t);
                      for (
                        var r = 0, i = 32;
                        i <= e.length - 16;
                        i += 160, r += 16
                      )
                        e.set(t.subarray(r, r + 16), i);
                      return e;
                    },
                  },
                  {
                    key: "decryptAvcSample",
                    value: function (e, t, r, i, a, n) {
                      var s = this.discardEPB(a.data),
                        o = this.getAvcEncryptedData(s),
                        l = this;
                      this.decryptBuffer(o.buffer, function (o) {
                        (a.data = l.getAvcDecryptedUnit(s, o)),
                          n || l.decryptAvcSamples(e, t, r + 1, i);
                      });
                    },
                  },
                  {
                    key: "decryptAvcSamples",
                    value: function (e, t, r, i) {
                      for (; ; t++, r = 0) {
                        if (t >= e.length) return void i();
                        for (var a = e[t].units; !(r >= a.length); r++) {
                          var n = a[r];
                          if (
                            !(n.length <= 48 || (1 !== n.type && 5 !== n.type))
                          ) {
                            var s = this.decrypter.isSync();
                            if ((this.decryptAvcSample(e, t, r, i, n, s), !s))
                              return;
                          }
                        }
                      }
                    },
                  },
                ]),
                e
              );
            })();
          r.default = o;
        },
        { 19: 19 },
      ],
      30: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(22),
            o = i(s),
            l = e(33),
            u = i(l),
            d = e(26),
            f = i(d),
            c = e(29),
            h = i(c),
            g = e(51),
            v = e(31),
            p = (function () {
              function e(t, r, i, n) {
                a(this, e),
                  (this.observer = t),
                  (this.config = i),
                  (this.typeSupported = n),
                  (this.remuxer = r),
                  (this.sampleAes = null);
              }
              return (
                n(
                  e,
                  [
                    {
                      key: "setDecryptData",
                      value: function (e) {
                        null != e && null != e.key && "SAMPLE-AES" === e.method
                          ? (this.sampleAes = new h.default(
                            this.observer,
                            this.config,
                            e,
                            this.discardEPB
                          ))
                          : (this.sampleAes = null);
                      },
                    },
                    {
                      key: "resetInitSegment",
                      value: function (e, t, r, i) {
                        (this.pmtParsed = !1),
                          (this._pmtId = -1),
                          (this._avcTrack = {
                            container: "video/mp2t",
                            type: "video",
                            id: -1,
                            inputTimeScale: 9e4,
                            sequenceNumber: 0,
                            samples: [],
                            len: 0,
                            dropped: 0,
                          }),
                          (this._audioTrack = {
                            container: "video/mp2t",
                            type: "audio",
                            id: -1,
                            inputTimeScale: 9e4,
                            sequenceNumber: 0,
                            samples: [],
                            len: 0,
                            isAAC: !0,
                          }),
                          (this._id3Track = {
                            type: "id3",
                            id: -1,
                            inputTimeScale: 9e4,
                            sequenceNumber: 0,
                            samples: [],
                            len: 0,
                          }),
                          (this._txtTrack = {
                            type: "text",
                            id: -1,
                            inputTimeScale: 9e4,
                            sequenceNumber: 0,
                            samples: [],
                            len: 0,
                          }),
                          (this.aacOverFlow = null),
                          (this.aacLastPTS = null),
                          (this.avcSample = null),
                          (this.audioCodec = t),
                          (this.videoCodec = r),
                          (this._duration = i);
                      },
                    },
                    { key: "resetTimeStamp", value: function () { } },
                    {
                      key: "append",
                      value: function (e, t, r, i) {
                        var a,
                          n,
                          s,
                          o,
                          l,
                          d = e.length,
                          f = !1;
                        this.contiguous = r;
                        var c = this.pmtParsed,
                          h = this._avcTrack,
                          p = this._audioTrack,
                          y = this._id3Track,
                          m = h.id,
                          E = p.id,
                          b = y.id,
                          T = this._pmtId,
                          _ = h.pesData,
                          k = p.pesData,
                          R = y.pesData,
                          A = this._parsePAT,
                          S = this._parsePMT,
                          L = this._parsePES,
                          w = this._parseAVCPES.bind(this),
                          D = this._parseAACPES.bind(this),
                          O = this._parseMPEGPES.bind(this),
                          I = this._parseID3PES.bind(this);
                        for (d -= d % 188, a = 0; a < d; a += 188)
                          if (71 === e[a]) {
                            if (
                              ((n = !!(64 & e[a + 1])),
                                (s = ((31 & e[a + 1]) << 8) + e[a + 2]),
                                (48 & e[a + 3]) >> 4 > 1)
                            ) {
                              if ((o = a + 5 + e[a + 4]) === a + 188) continue;
                            } else o = a + 4;
                            switch (s) {
                              case m:
                                n &&
                                  (_ && (l = L(_)) && w(l, !1),
                                    (_ = { data: [], size: 0 })),
                                  _ &&
                                  (_.data.push(e.subarray(o, a + 188)),
                                    (_.size += a + 188 - o));
                                break;
                              case E:
                                n &&
                                  (k && (l = L(k)) && (p.isAAC ? D(l) : O(l)),
                                    (k = { data: [], size: 0 })),
                                  k &&
                                  (k.data.push(e.subarray(o, a + 188)),
                                    (k.size += a + 188 - o));
                                break;
                              case b:
                                n &&
                                  (R && (l = L(R)) && I(l),
                                    (R = { data: [], size: 0 })),
                                  R &&
                                  (R.data.push(e.subarray(o, a + 188)),
                                    (R.size += a + 188 - o));
                                break;
                              case 0:
                                n && (o += e[o] + 1),
                                  (T = this._pmtId = A(e, o));
                                break;
                              case T:
                                n && (o += e[o] + 1);
                                var P = S(
                                  e,
                                  o,
                                  this.typeSupported.mpeg === !0 ||
                                  this.typeSupported.mp3 === !0,
                                  null != this.sampleAes
                                );
                                (m = P.avc),
                                  m > 0 && (h.id = m),
                                  (E = P.audio),
                                  E > 0 && ((p.id = E), (p.isAAC = P.isAAC)),
                                  (b = P.id3),
                                  b > 0 && (y.id = b),
                                  f &&
                                  !c &&
                                  (g.logger.log("reparse from beginning"),
                                    (f = !1),
                                    (a = -188)),
                                  (c = this.pmtParsed = !0);
                                break;
                              case 17:
                              case 8191:
                                break;
                              default:
                                f = !0;
                            }
                          } else
                            this.observer.trigger(u.default.ERROR, {
                              type: v.ErrorTypes.MEDIA_ERROR,
                              details: v.ErrorDetails.FRAG_PARSING_ERROR,
                              fatal: !1,
                              reason: "TS packet did not start with 0x47",
                            });
                        _ && (l = L(_))
                          ? (w(l, !0), (h.pesData = null))
                          : (h.pesData = _),
                          k && (l = L(k))
                            ? (p.isAAC ? D(l) : O(l), (p.pesData = null))
                            : (k &&
                              k.size &&
                              g.logger.log(
                                "last AAC PES packet truncated,might overlap between fragments"
                              ),
                              (p.pesData = k)),
                          R && (l = L(R))
                            ? (I(l), (y.pesData = null))
                            : (y.pesData = R),
                          null == this.sampleAes
                            ? this.remuxer.remux(
                              p,
                              h,
                              y,
                              this._txtTrack,
                              t,
                              r,
                              i
                            )
                            : this.decryptAndRemux(
                              p,
                              h,
                              y,
                              this._txtTrack,
                              t,
                              r,
                              i
                            );
                      },
                    },
                    {
                      key: "decryptAndRemux",
                      value: function (e, t, r, i, a, n, s) {
                        if (e.samples && e.isAAC) {
                          var o = this;
                          this.sampleAes.decryptAacSamples(
                            e.samples,
                            0,
                            function () {
                              o.decryptAndRemuxAvc(e, t, r, i, a, n, s);
                            }
                          );
                        } else this.decryptAndRemuxAvc(e, t, r, i, a, n, s);
                      },
                    },
                    {
                      key: "decryptAndRemuxAvc",
                      value: function (e, t, r, i, a, n, s) {
                        if (t.samples) {
                          var o = this;
                          this.sampleAes.decryptAvcSamples(
                            t.samples,
                            0,
                            0,
                            function () {
                              o.remuxer.remux(e, t, r, i, a, n, s);
                            }
                          );
                        } else this.remuxer.remux(e, t, r, i, a, n, s);
                      },
                    },
                    {
                      key: "destroy",
                      value: function () {
                        (this._initPTS = this._initDTS = void 0),
                          (this._duration = 0);
                      },
                    },
                    {
                      key: "_parsePAT",
                      value: function (e, t) {
                        return ((31 & e[t + 10]) << 8) | e[t + 11];
                      },
                    },
                    {
                      key: "_parsePMT",
                      value: function (e, t, r, i) {
                        var a,
                          n,
                          s,
                          o,
                          l = { audio: -1, avc: -1, id3: -1, isAAC: !0 };
                        for (
                          a = ((15 & e[t + 1]) << 8) | e[t + 2],
                          n = t + 3 + a - 4,
                          s = ((15 & e[t + 10]) << 8) | e[t + 11],
                          t += 12 + s;
                          t < n;

                        ) {
                          switch (
                          ((o = ((31 & e[t + 1]) << 8) | e[t + 2]), e[t])
                          ) {
                            case 207:
                              if (!i) {
                                g.logger.log("unkown stream type:" + e[t]);
                                break;
                              }
                            case 15:
                              l.audio === -1 && (l.audio = o);
                              break;
                            case 21:
                              l.id3 === -1 && (l.id3 = o);
                              break;
                            case 219:
                              if (!i) {
                                g.logger.log("unkown stream type:" + e[t]);
                                break;
                              }
                            case 27:
                              l.avc === -1 && (l.avc = o);
                              break;
                            case 3:
                            case 4:
                              r
                                ? l.audio === -1 &&
                                ((l.audio = o), (l.isAAC = !1))
                                : g.logger.log(
                                  "MPEG audio found, not supported in this browser for now"
                                );
                              break;
                            case 36:
                              g.logger.warn(
                                "HEVC stream type found, not supported for now"
                              );
                              break;
                            default:
                              g.logger.log("unkown stream type:" + e[t]);
                          }
                          t += 5 + (((15 & e[t + 3]) << 8) | e[t + 4]);
                        }
                        return l;
                      },
                    },
                    {
                      key: "_parsePES",
                      value: function (e) {
                        var t,
                          r,
                          i,
                          a,
                          n,
                          s,
                          o,
                          l,
                          u = 0,
                          d = e.data;
                        if (!e || 0 === e.size) return null;
                        for (; d[0].length < 19 && d.length > 1;) {
                          var f = new Uint8Array(d[0].length + d[1].length);
                          f.set(d[0]),
                            f.set(d[1], d[0].length),
                            (d[0] = f),
                            d.splice(1, 1);
                        }
                        if (
                          ((t = d[0]), 1 === (t[0] << 16) + (t[1] << 8) + t[2])
                        ) {
                          if ((i = (t[4] << 8) + t[5]) && i > e.size - 6)
                            return null;
                          (r = t[7]),
                            192 & r &&
                            ((s =
                              536870912 * (14 & t[9]) +
                              4194304 * (255 & t[10]) +
                              16384 * (254 & t[11]) +
                              128 * (255 & t[12]) +
                              (254 & t[13]) / 2),
                              s > 4294967295 && (s -= 8589934592),
                              64 & r
                                ? ((o =
                                  536870912 * (14 & t[14]) +
                                  4194304 * (255 & t[15]) +
                                  16384 * (254 & t[16]) +
                                  128 * (255 & t[17]) +
                                  (254 & t[18]) / 2),
                                  o > 4294967295 && (o -= 8589934592),
                                  s - o > 54e5 &&
                                  (g.logger.warn(
                                    Math.round((s - o) / 9e4) +
                                    "s delta between PTS and DTS, align them"
                                  ),
                                    (s = o)))
                                : (o = s)),
                            (a = t[8]),
                            (l = a + 9),
                            (e.size -= l),
                            (n = new Uint8Array(e.size));
                          for (var c = 0, h = d.length; c < h; c++) {
                            t = d[c];
                            var v = t.byteLength;
                            if (l) {
                              if (l > v) {
                                l -= v;
                                continue;
                              }
                              (t = t.subarray(l)), (v -= l), (l = 0);
                            }
                            n.set(t, u), (u += v);
                          }
                          return (
                            i && (i -= a + 3),
                            { data: n, pts: s, dts: o, len: i }
                          );
                        }
                        return null;
                      },
                    },
                    {
                      key: "pushAccesUnit",
                      value: function (e, t) {
                        if (e.units.length && e.frame) {
                          var r = t.samples,
                            i = r.length;
                          !this.config.forceKeyFrameOnDiscontinuity ||
                            e.key === !0 ||
                            (t.sps && (i || this.contiguous))
                            ? ((e.id = i), r.push(e))
                            : t.dropped++;
                        }
                        e.debug.length &&
                          g.logger.log(e.pts + "/" + e.dts + ":" + e.debug);
                      },
                    },
                    {
                      key: "_parseAVCPES",
                      value: function (e, t) {
                        var r,
                          i,
                          a,
                          n = this,
                          s = this._avcTrack,
                          o = this._parseAVCNALu(e.data),
                          l = this.avcSample;
                        (e.data = null),
                          o.forEach(function (t) {
                            switch (t.type) {
                              case 1:
                                (i = !0), (l.frame = !0);
                                var o = t.data;
                                if (o.length > 4) {
                                  var u = new f.default(o).readSliceType();
                                  (2 !== u && 4 !== u && 7 !== u && 9 !== u) ||
                                    (l.key = !0);
                                }
                                break;
                              case 5:
                                (i = !0),
                                  l ||
                                  (l = n.avcSample =
                                    n._createAVCSample(!0, e.pts, e.dts, "")),
                                  (l.key = !0),
                                  (l.frame = !0);
                                break;
                              case 6:
                                (i = !0),
                                  (r = new f.default(n.discardEPB(t.data))),
                                  r.readUByte();
                                for (
                                  var d = 0, c = 0, h = !1, g = 0;
                                  !h && r.bytesAvailable > 1;

                                ) {
                                  d = 0;
                                  do {
                                    (g = r.readUByte()), (d += g);
                                  } while (255 === g);
                                  c = 0;
                                  do {
                                    (g = r.readUByte()), (c += g);
                                  } while (255 === g);
                                  if (4 === d && 0 !== r.bytesAvailable) {
                                    h = !0;
                                    if (181 === r.readUByte()) {
                                      if (49 === r.readUShort()) {
                                        if (1195456820 === r.readUInt()) {
                                          if (3 === r.readUByte()) {
                                            var v = r.readUByte(),
                                              p = r.readUByte(),
                                              y = 31 & v,
                                              m = [v, p];
                                            for (a = 0; a < y; a++)
                                              m.push(r.readUByte()),
                                                m.push(r.readUByte()),
                                                m.push(r.readUByte());
                                            n._insertSampleInOrder(
                                              n._txtTrack.samples,
                                              { type: 3, pts: e.pts, bytes: m }
                                            );
                                          }
                                        }
                                      }
                                    }
                                  } else if (c < r.bytesAvailable)
                                    for (a = 0; a < c; a++) r.readUByte();
                                }
                                break;
                              case 7:
                                if (((i = !0), !s.sps)) {
                                  r = new f.default(t.data);
                                  var E = r.readSPS();
                                  (s.width = E.width),
                                    (s.height = E.height),
                                    (s.pixelRatio = E.pixelRatio),
                                    (s.sps = [t.data]),
                                    (s.duration = n._duration);
                                  var b = t.data.subarray(1, 4),
                                    T = "avc1.";
                                  for (a = 0; a < 3; a++) {
                                    var _ = b[a].toString(16);
                                    _.length < 2 && (_ = "0" + _), (T += _);
                                  }
                                  s.codec = T;
                                }
                                break;
                              case 8:
                                (i = !0), s.pps || (s.pps = [t.data]);
                                break;
                              case 9:
                                (i = !1),
                                  l && n.pushAccesUnit(l, s),
                                  (l = n.avcSample =
                                    n._createAVCSample(!1, e.pts, e.dts, ""));
                                break;
                              case 12:
                                i = !1;
                                break;
                              default:
                                (i = !1),
                                  l &&
                                  (l.debug += "unknown NAL " + t.type + " ");
                            }
                            if (l && i) {
                              l.units.push(t);
                            }
                          }),
                          t &&
                          l &&
                          (this.pushAccesUnit(l, s), (this.avcSample = null));
                      },
                    },
                    {
                      key: "_createAVCSample",
                      value: function (e, t, r, i) {
                        return { key: e, pts: t, dts: r, units: [], debug: i };
                      },
                    },
                    {
                      key: "_insertSampleInOrder",
                      value: function (e, t) {
                        var r = e.length;
                        if (r > 0) {
                          if (t.pts >= e[r - 1].pts) e.push(t);
                          else
                            for (var i = r - 1; i >= 0; i--)
                              if (t.pts < e[i].pts) {
                                e.splice(i, 0, t);
                                break;
                              }
                        } else e.push(t);
                      },
                    },
                    {
                      key: "_getLastNalUnit",
                      value: function () {
                        var e = this.avcSample,
                          t = void 0;
                        if (!e || 0 === e.units.length) {
                          var r = this._avcTrack,
                            i = r.samples;
                          e = i[i.length - 1];
                        }
                        if (e) {
                          var a = e.units;
                          t = a[a.length - 1];
                        }
                        return t;
                      },
                    },
                    {
                      key: "_parseAVCNALu",
                      value: function (e) {
                        var t,
                          r,
                          i,
                          a,
                          n,
                          s = 0,
                          o = e.byteLength,
                          l = this._avcTrack,
                          u = l.naluState || 0,
                          d = u,
                          f = [],
                          c = -1;
                        for (
                          u === -1 &&
                          ((c = 0), (n = 31 & e[0]), (u = 0), (s = 1));
                          s < o;

                        )
                          if (((t = e[s++]), u))
                            if (1 !== u)
                              if (t)
                                if (1 === t) {
                                  if (c >= 0)
                                    (i = {
                                      data: e.subarray(c, s - u - 1),
                                      type: n,
                                    }),
                                      f.push(i);
                                  else {
                                    var h = this._getLastNalUnit();
                                    if (
                                      h &&
                                      (d &&
                                        s <= 4 - d &&
                                        h.state &&
                                        (h.data = h.data.subarray(
                                          0,
                                          h.data.byteLength - d
                                        )),
                                        (r = s - u - 1) > 0)
                                    ) {
                                      var g = new Uint8Array(
                                        h.data.byteLength + r
                                      );
                                      g.set(h.data, 0),
                                        g.set(
                                          e.subarray(0, r),
                                          h.data.byteLength
                                        ),
                                        (h.data = g);
                                    }
                                  }
                                  s < o
                                    ? ((a = 31 & e[s]),
                                      (c = s),
                                      (n = a),
                                      (u = 0))
                                    : (u = -1);
                                } else u = 0;
                              else u = 3;
                            else u = t ? 0 : 2;
                          else u = t ? 0 : 1;
                        if (
                          (c >= 0 &&
                            u >= 0 &&
                            ((i = {
                              data: e.subarray(c, o),
                              type: n,
                              state: u,
                            }),
                              f.push(i)),
                            0 === f.length)
                        ) {
                          var v = this._getLastNalUnit();
                          if (v) {
                            var p = new Uint8Array(
                              v.data.byteLength + e.byteLength
                            );
                            p.set(v.data, 0),
                              p.set(e, v.data.byteLength),
                              (v.data = p);
                          }
                        }
                        return (l.naluState = u), f;
                      },
                    },
                    {
                      key: "discardEPB",
                      value: function (e) {
                        for (
                          var t, r, i = e.byteLength, a = [], n = 1;
                          n < i - 2;

                        )
                          0 === e[n] && 0 === e[n + 1] && 3 === e[n + 2]
                            ? (a.push(n + 2), (n += 2))
                            : n++;
                        if (0 === a.length) return e;
                        (t = i - a.length), (r = new Uint8Array(t));
                        var s = 0;
                        for (n = 0; n < t; s++, n++)
                          s === a[0] && (s++, a.shift()), (r[n] = e[s]);
                        return r;
                      },
                    },
                    {
                      key: "_parseAACPES",
                      value: function (e) {
                        var t,
                          r,
                          i,
                          a,
                          n,
                          s,
                          l,
                          d,
                          f,
                          c = this._audioTrack,
                          h = e.data,
                          p = e.pts,
                          y = this.aacOverFlow,
                          m = this.aacLastPTS;
                        if (y) {
                          var E = new Uint8Array(y.byteLength + h.byteLength);
                          E.set(y, 0), E.set(h, y.byteLength), (h = E);
                        }
                        for (
                          n = 0, d = h.length;
                          n < d - 1 &&
                          (255 !== h[n] || 240 != (240 & h[n + 1]));
                          n++
                        );
                        if (n) {
                          var b, T;
                          if (
                            (n < d - 1
                              ? ((b =
                                "AAC PES did not start with ADTS header,offset:" +
                                n),
                                (T = !1))
                              : ((b = "no ADTS header found in AAC PES"),
                                (T = !0)),
                              g.logger.warn("parsing error:" + b),
                              this.observer.trigger(u.default.ERROR, {
                                type: v.ErrorTypes.MEDIA_ERROR,
                                details: v.ErrorDetails.FRAG_PARSING_ERROR,
                                fatal: T,
                                reason: b,
                              }),
                              T)
                          )
                            return;
                        }
                        if (!c.samplerate) {
                          var _ = this.audioCodec;
                          (t = o.default.getAudioConfig(
                            this.observer,
                            h,
                            n,
                            _
                          )),
                            (c.config = t.config),
                            (c.samplerate = t.samplerate),
                            (c.channelCount = t.channelCount),
                            (c.codec = t.codec),
                            (c.manifestCodec = t.manifestCodec),
                            (c.duration = this._duration),
                            g.logger.log(
                              "parsed codec:" +
                              c.codec +
                              ",rate:" +
                              t.samplerate +
                              ",nb channel:" +
                              t.channelCount
                            );
                        }
                        if (((a = 0), (i = 9216e4 / c.samplerate), y && m)) {
                          var k = m + i;
                          Math.abs(k - p) > 1 &&
                            (g.logger.log(
                              "AAC: align PTS for overlapping frames by " +
                              Math.round((k - p) / 90)
                            ),
                              (p = k));
                        }
                        for (
                          ;
                          n + 5 < d &&
                          ((s = 1 & h[n + 1] ? 7 : 9),
                            (r =
                              ((3 & h[n + 3]) << 11) |
                              (h[n + 4] << 3) |
                              ((224 & h[n + 5]) >>> 5)),
                            (r -= s) > 0 && n + s + r <= d);

                        )
                          for (
                            l = p + a * i,
                            f = {
                              unit: h.subarray(n + s, n + s + r),
                              pts: l,
                              dts: l,
                            },
                            c.samples.push(f),
                            c.len += r,
                            n += r + s,
                            a++;
                            n < d - 1 &&
                            (255 !== h[n] || 240 != (240 & h[n + 1]));
                            n++
                          );
                        (y = n < d ? h.subarray(n, d) : null),
                          (this.aacOverFlow = y),
                          (this.aacLastPTS = l);
                      },
                    },
                    {
                      key: "_parseMPEGPES",
                      value: function (e) {
                        for (
                          var t,
                          r = e.data,
                          i = e.pts,
                          a = r.length,
                          n = 0,
                          s = 0;
                          s < a && (t = this._parseMpeg(r, s, a, n++, i)) > 0;

                        )
                          s += t;
                      },
                    },
                    {
                      key: "_onMpegFrame",
                      value: function (e, t, r, i, a, n) {
                        var s = (1152 / r) * 1e3,
                          o = n + a * s,
                          l = this._audioTrack;
                        (l.config = []),
                          (l.channelCount = i),
                          (l.samplerate = r),
                          (l.duration = this._duration),
                          l.samples.push({ unit: e, pts: o, dts: o }),
                          (l.len += e.length);
                      },
                    },
                    {
                      key: "_onMpegNoise",
                      value: function (e) {
                        g.logger.warn(
                          "mpeg audio has noise: " + e.length + " bytes"
                        );
                      },
                    },
                    {
                      key: "_parseMpeg",
                      value: function (e, t, r, i, a) {
                        var n = [
                          32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352,
                          384, 416, 448, 32, 48, 56, 64, 80, 96, 112, 128,
                          160, 192, 224, 256, 320, 384, 32, 40, 48, 56, 64,
                          80, 96, 112, 128, 160, 192, 224, 256, 320, 32, 48,
                          56, 64, 80, 96, 112, 128, 144, 160, 176, 192, 224,
                          256, 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112,
                          128, 144, 160,
                        ],
                          s = [
                            44100, 48e3, 32e3, 22050, 24e3, 16e3, 11025, 12e3,
                            8e3,
                          ];
                        if (t + 2 > r) return -1;
                        if (255 === e[t] || 224 == (224 & e[t + 1])) {
                          if (t + 24 > r) return -1;
                          var o = (e[t + 1] >> 3) & 3,
                            l = (e[t + 1] >> 1) & 3,
                            u = (e[t + 2] >> 4) & 15,
                            d = (e[t + 2] >> 2) & 3,
                            f = !!(2 & e[t + 2]);
                          if (1 !== o && 0 !== u && 15 !== u && 3 !== d) {
                            var c = 3 === o ? 3 - l : 3 === l ? 3 : 4,
                              h = 1e3 * n[14 * c + u - 1],
                              g = 3 === o ? 0 : 2 === o ? 1 : 2,
                              v = s[3 * g + d],
                              p = f ? 1 : 0,
                              y = e[t + 3] >> 6 == 3 ? 1 : 2,
                              m =
                                3 === l
                                  ? (((3 === o ? 12 : 6) * h) / v + p) << 2
                                  : (((3 === o ? 144 : 72) * h) / v + p) | 0;
                            return t + m > r
                              ? -1
                              : (this._onMpegFrame &&
                                this._onMpegFrame(
                                  e.subarray(t, t + m),
                                  h,
                                  v,
                                  y,
                                  i,
                                  a
                                ),
                                m);
                          }
                        }
                        for (var E = t + 2; E < r;) {
                          if (255 === e[E - 1] && 224 == (224 & e[E]))
                            return (
                              this._onMpegNoise &&
                              this._onMpegNoise(e.subarray(t, E - 1)),
                              E - t - 1
                            );
                          E++;
                        }
                        return -1;
                      },
                    },
                    {
                      key: "_parseID3PES",
                      value: function (e) {
                        this._id3Track.samples.push(e);
                      },
                    },
                  ],
                  [
                    {
                      key: "probe",
                      value: function (e) {
                        return (
                          e.length >= 564 &&
                          71 === e[0] &&
                          71 === e[188] &&
                          71 === e[376]
                        );
                      },
                    },
                  ]
                ),
                e
              );
            })();
          r.default = p;
        },
        { 22: 22, 26: 26, 29: 29, 31: 31, 33: 33, 51: 51 },
      ],
      31: [
        function (e, t, r) {
          "use strict";
          Object.defineProperty(r, "__esModule", { value: !0 });
          (r.ErrorTypes = {
            NETWORK_ERROR: "networkError",
            MEDIA_ERROR: "mediaError",
            MUX_ERROR: "muxError",
            OTHER_ERROR: "otherError",
          }),
            (r.ErrorDetails = {
              MANIFEST_LOAD_ERROR: "manifestLoadError",
              MANIFEST_LOAD_TIMEOUT: "manifestLoadTimeOut",
              MANIFEST_PARSING_ERROR: "manifestParsingError",
              MANIFEST_INCOMPATIBLE_CODECS_ERROR:
                "manifestIncompatibleCodecsError",
              LEVEL_LOAD_ERROR: "levelLoadError",
              LEVEL_LOAD_TIMEOUT: "levelLoadTimeOut",
              LEVEL_SWITCH_ERROR: "levelSwitchError",
              AUDIO_TRACK_LOAD_ERROR: "audioTrackLoadError",
              AUDIO_TRACK_LOAD_TIMEOUT: "audioTrackLoadTimeOut",
              FRAG_LOAD_ERROR: "fragLoadError",
              FRAG_LOOP_LOADING_ERROR: "fragLoopLoadingError",
              FRAG_LOAD_TIMEOUT: "fragLoadTimeOut",
              FRAG_DECRYPT_ERROR: "fragDecryptError",
              FRAG_PARSING_ERROR: "fragParsingError",
              REMUX_ALLOC_ERROR: "remuxAllocError",
              KEY_LOAD_ERROR: "keyLoadError",
              KEY_LOAD_TIMEOUT: "keyLoadTimeOut",
              BUFFER_ADD_CODEC_ERROR: "bufferAddCodecError",
              BUFFER_APPEND_ERROR: "bufferAppendError",
              BUFFER_APPENDING_ERROR: "bufferAppendingError",
              BUFFER_STALLED_ERROR: "bufferStalledError",
              BUFFER_FULL_ERROR: "bufferFullError",
              BUFFER_SEEK_OVER_HOLE: "bufferSeekOverHole",
              BUFFER_NUDGE_ON_STALL: "bufferNudgeOnStall",
              INTERNAL_EXCEPTION: "internalException",
              WEBVTT_EXCEPTION: "webVTTException",
            });
        },
        {},
      ],
      32: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a =
            "function" == typeof Symbol && "symbol" == typeof Symbol.iterator
              ? function (e) {
                return typeof e;
              }
              : function (e) {
                return e &&
                  "function" == typeof Symbol &&
                  e.constructor === Symbol &&
                  e !== Symbol.prototype
                  ? "symbol"
                  : typeof e;
              },
            n = (function () {
              function e(e, t) {
                for (var r = 0; r < t.length; r++) {
                  var i = t[r];
                  (i.enumerable = i.enumerable || !1),
                    (i.configurable = !0),
                    "value" in i && (i.writable = !0),
                    Object.defineProperty(e, i.key, i);
                }
              }
              return function (t, r, i) {
                return r && e(t.prototype, r), i && e(t, i), t;
              };
            })(),
            s = e(51),
            o = e(31),
            l = e(33),
            u = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(l),
            d = (function () {
              function e(t) {
                i(this, e),
                  (this.hls = t),
                  (this.onEvent = this.onEvent.bind(this));
                for (
                  var r = arguments.length, a = Array(r > 1 ? r - 1 : 0), n = 1;
                  n < r;
                  n++
                )
                  a[n - 1] = arguments[n];
                (this.handledEvents = a),
                  (this.useGenericHandler = !0),
                  this.registerListeners();
              }
              return (
                n(e, [
                  {
                    key: "destroy",
                    value: function () {
                      this.unregisterListeners();
                    },
                  },
                  {
                    key: "isEventHandler",
                    value: function () {
                      return (
                        "object" === a(this.handledEvents) &&
                        this.handledEvents.length &&
                        "function" == typeof this.onEvent
                      );
                    },
                  },
                  {
                    key: "registerListeners",
                    value: function () {
                      this.isEventHandler() &&
                        this.handledEvents.forEach(
                          function (e) {
                            if ("hlsEventGeneric" === e)
                              throw new Error("Forbidden event name: " + e);
                            this.hls.on(e, this.onEvent);
                          }.bind(this)
                        );
                    },
                  },
                  {
                    key: "unregisterListeners",
                    value: function () {
                      this.isEventHandler() &&
                        this.handledEvents.forEach(
                          function (e) {
                            this.hls.off(e, this.onEvent);
                          }.bind(this)
                        );
                    },
                  },
                  {
                    key: "onEvent",
                    value: function (e, t) {
                      this.onEventGeneric(e, t);
                    },
                  },
                  {
                    key: "onEventGeneric",
                    value: function (e, t) {
                      var r = function (e, t) {
                        var r = "on" + e.replace("hls", "");
                        if ("function" != typeof this[r])
                          throw new Error(
                            "Event " +
                            e +
                            " has no generic handler in this " +
                            this.constructor.name +
                            " class (tried " +
                            r +
                            ")"
                          );
                        return this[r].bind(this, t);
                      };
                      try {
                        r.call(this, e, t).call();
                      } catch (t) {
                        s.logger.error(
                          "internal error happened while processing " +
                          e +
                          ":" +
                          t.message
                        ),
                          this.hls.trigger(u.default.ERROR, {
                            type: o.ErrorTypes.OTHER_ERROR,
                            details: o.ErrorDetails.INTERNAL_EXCEPTION,
                            fatal: !1,
                            event: e,
                            err: t,
                          });
                      }
                    },
                  },
                ]),
                e
              );
            })();
          r.default = d;
        },
        { 31: 31, 33: 33, 51: 51 },
      ],
      33: [
        function (e, t, r) {
          "use strict";
          t.exports = {
            MEDIA_ATTACHING: "hlsMediaAttaching",
            MEDIA_ATTACHED: "hlsMediaAttached",
            MEDIA_DETACHING: "hlsMediaDetaching",
            MEDIA_DETACHED: "hlsMediaDetached",
            BUFFER_RESET: "hlsBufferReset",
            BUFFER_CODECS: "hlsBufferCodecs",
            BUFFER_CREATED: "hlsBufferCreated",
            BUFFER_APPENDING: "hlsBufferAppending",
            BUFFER_APPENDED: "hlsBufferAppended",
            BUFFER_EOS: "hlsBufferEos",
            BUFFER_FLUSHING: "hlsBufferFlushing",
            BUFFER_FLUSHED: "hlsBufferFlushed",
            MANIFEST_LOADING: "hlsManifestLoading",
            MANIFEST_LOADED: "hlsManifestLoaded",
            MANIFEST_PARSED: "hlsManifestParsed",
            LEVEL_SWITCH: "hlsLevelSwitch",
            LEVEL_SWITCHING: "hlsLevelSwitching",
            LEVEL_SWITCHED: "hlsLevelSwitched",
            LEVEL_LOADING: "hlsLevelLoading",
            LEVEL_LOADED: "hlsLevelLoaded",
            LEVEL_UPDATED: "hlsLevelUpdated",
            LEVEL_PTS_UPDATED: "hlsLevelPtsUpdated",
            AUDIO_TRACKS_UPDATED: "hlsAudioTracksUpdated",
            AUDIO_TRACK_SWITCH: "hlsAudioTrackSwitch",
            AUDIO_TRACK_SWITCHING: "hlsAudioTrackSwitching",
            AUDIO_TRACK_SWITCHED: "hlsAudioTrackSwitched",
            AUDIO_TRACK_LOADING: "hlsAudioTrackLoading",
            AUDIO_TRACK_LOADED: "hlsAudioTrackLoaded",
            SUBTITLE_TRACKS_UPDATED: "hlsSubtitleTracksUpdated",
            SUBTITLE_TRACK_SWITCH: "hlsSubtitleTrackSwitch",
            SUBTITLE_TRACK_LOADING: "hlsSubtitleTrackLoading",
            SUBTITLE_TRACK_LOADED: "hlsSubtitleTrackLoaded",
            SUBTITLE_FRAG_PROCESSED: "hlsSubtitleFragProcessed",
            INIT_PTS_FOUND: "hlsInitPtsFound",
            FRAG_LOADING: "hlsFragLoading",
            FRAG_LOAD_PROGRESS: "hlsFragLoadProgress",
            FRAG_LOAD_EMERGENCY_ABORTED: "hlsFragLoadEmergencyAborted",
            FRAG_LOADED: "hlsFragLoaded",
            FRAG_DECRYPTED: "hlsFragDecrypted",
            FRAG_PARSING_INIT_SEGMENT: "hlsFragParsingInitSegment",
            FRAG_PARSING_USERDATA: "hlsFragParsingUserdata",
            FRAG_PARSING_METADATA: "hlsFragParsingMetadata",
            FRAG_PARSING_DATA: "hlsFragParsingData",
            FRAG_PARSED: "hlsFragParsed",
            FRAG_BUFFERED: "hlsFragBuffered",
            FRAG_CHANGED: "hlsFragChanged",
            FPS_DROP: "hlsFpsDrop",
            FPS_DROP_LEVEL_CAPPING: "hlsFpsDropLevelCapping",
            ERROR: "hlsError",
            DESTROYING: "hlsDestroying",
            KEY_LOADING: "hlsKeyLoading",
            KEY_LOADED: "hlsKeyLoaded",
            STREAM_STATE_TRANSITION: "hlsStreamStateTransition",
          };
        },
        {},
      ],
      34: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = (function () {
              function e() {
                i(this, e);
              }
              return (
                a(e, null, [
                  {
                    key: "getSilentFrame",
                    value: function (e, t) {
                      switch (e) {
                        case "mp4a.40.2":
                          if (1 === t)
                            return new Uint8Array([0, 200, 0, 128, 35, 128]);
                          if (2 === t)
                            return new Uint8Array([
                              33, 0, 73, 144, 2, 25, 0, 35, 128,
                            ]);
                          if (3 === t)
                            return new Uint8Array([
                              0, 200, 0, 128, 32, 132, 1, 38, 64, 8, 100, 0,
                              142,
                            ]);
                          if (4 === t)
                            return new Uint8Array([
                              0, 200, 0, 128, 32, 132, 1, 38, 64, 8, 100, 0,
                              128, 44, 128, 8, 2, 56,
                            ]);
                          if (5 === t)
                            return new Uint8Array([
                              0, 200, 0, 128, 32, 132, 1, 38, 64, 8, 100, 0,
                              130, 48, 4, 153, 0, 33, 144, 2, 56,
                            ]);
                          if (6 === t)
                            return new Uint8Array([
                              0, 200, 0, 128, 32, 132, 1, 38, 64, 8, 100, 0,
                              130, 48, 4, 153, 0, 33, 144, 2, 0, 178, 0, 32, 8,
                              224,
                            ]);
                          break;
                        default:
                          if (1 === t)
                            return new Uint8Array([
                              1, 64, 34, 128, 163, 78, 230, 128, 186, 8, 0, 0,
                              0, 28, 6, 241, 193, 10, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 94,
                            ]);
                          if (2 === t)
                            return new Uint8Array([
                              1, 64, 34, 128, 163, 94, 230, 128, 186, 8, 0, 0,
                              0, 0, 149, 0, 6, 241, 161, 10, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 94,
                            ]);
                          if (3 === t)
                            return new Uint8Array([
                              1, 64, 34, 128, 163, 94, 230, 128, 186, 8, 0, 0,
                              0, 0, 149, 0, 6, 241, 161, 10, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, 90,
                              90, 90, 90, 90, 90, 90, 90, 90, 90, 94,
                            ]);
                      }
                      return null;
                    },
                  },
                ]),
                e
              );
            })();
          r.default = n;
        },
        {},
      ],
      35: [
        function (e, t, r) {
          "use strict";
          var i = {
            isBuffered: function (e, t) {
              if (e)
                for (var r = e.buffered, i = 0; i < r.length; i++)
                  if (t >= r.start(i) && t <= r.end(i)) return !0;
              return !1;
            },
            bufferInfo: function (e, t, r) {
              if (e) {
                var i,
                  a = e.buffered,
                  n = [];
                for (i = 0; i < a.length; i++)
                  n.push({ start: a.start(i), end: a.end(i) });
                return this.bufferedInfo(n, t, r);
              }
              return { len: 0, start: t, end: t, nextStart: void 0 };
            },
            bufferedInfo: function (e, t, r) {
              var i,
                a,
                n,
                s,
                o,
                l = [];
              for (
                e.sort(function (e, t) {
                  var r = e.start - t.start;
                  return r ? r : t.end - e.end;
                }),
                o = 0;
                o < e.length;
                o++
              ) {
                var u = l.length;
                if (u) {
                  var d = l[u - 1].end;
                  e[o].start - d < r
                    ? e[o].end > d && (l[u - 1].end = e[o].end)
                    : l.push(e[o]);
                } else l.push(e[o]);
              }
              for (o = 0, i = 0, a = n = t; o < l.length; o++) {
                var f = l[o].start,
                  c = l[o].end;
                if (t + r >= f && t < c) (a = f), (n = c), (i = n - t);
                else if (t + r < f) {
                  s = f;
                  break;
                }
              }
              return { len: i, start: a, end: n, nextStart: s };
            },
          };
          t.exports = i;
        },
        {},
      ],
      36: [
        function (e, t, r) {
          "use strict";
          var i = e(51),
            a = {
              mergeDetails: function (e, t) {
                var r,
                  n = Math.max(e.startSN, t.startSN) - t.startSN,
                  s = Math.min(e.endSN, t.endSN) - t.startSN,
                  o = t.startSN - e.startSN,
                  l = e.fragments,
                  u = t.fragments,
                  d = 0;
                if (s < n) return void (t.PTSKnown = !1);
                for (var f = n; f <= s; f++) {
                  var c = l[o + f],
                    h = u[f];
                  h &&
                    c &&
                    ((d = c.cc - h.cc),
                      isNaN(c.startPTS) ||
                      ((h.start = h.startPTS = c.startPTS),
                        (h.endPTS = c.endPTS),
                        (h.duration = c.duration),
                        (r = h)));
                }
                if (d)
                  for (
                    i.logger.log(
                      "discontinuity sliding from playlist, take drift into account"
                    ),
                    f = 0;
                    f < u.length;
                    f++
                  )
                    u[f].cc += d;
                if (r)
                  a.updateFragPTSDTS(
                    t,
                    r,
                    r.startPTS,
                    r.endPTS,
                    r.startDTS,
                    r.endDTS
                  );
                else if (o >= 0 && o < l.length) {
                  var g = l[o].start;
                  for (f = 0; f < u.length; f++) u[f].start += g;
                }
                t.PTSKnown = e.PTSKnown;
              },
              updateFragPTSDTS: function (e, t, r, i, n, s) {
                if (!isNaN(t.startPTS)) {
                  var o = Math.abs(t.startPTS - r);
                  isNaN(t.deltaPTS)
                    ? (t.deltaPTS = o)
                    : (t.deltaPTS = Math.max(o, t.deltaPTS)),
                    (r = Math.min(r, t.startPTS)),
                    (i = Math.max(i, t.endPTS)),
                    (n = Math.min(n, t.startDTS)),
                    (s = Math.max(s, t.endDTS));
                }
                var l = r - t.start;
                (t.start = t.startPTS = r),
                  (t.endPTS = i),
                  (t.startDTS = n),
                  (t.endDTS = s),
                  (t.duration = i - r);
                var u = t.sn;
                if (!e || u < e.startSN || u > e.endSN) return 0;
                var d, f, c;
                for (
                  d = u - e.startSN, f = e.fragments, t = f[d], c = d;
                  c > 0;
                  c--
                )
                  a.updatePTS(f, c, c - 1);
                for (c = d; c < f.length - 1; c++) a.updatePTS(f, c, c + 1);
                return (e.PTSKnown = !0), l;
              },
              updatePTS: function (e, t, r) {
                var a = e[t],
                  n = e[r],
                  s = n.startPTS;
                isNaN(s)
                  ? (n.start =
                    r > t
                      ? a.start + a.duration
                      : Math.max(a.start - n.duration, 0))
                  : r > t
                    ? ((a.duration = s - a.start),
                      a.duration < 0 &&
                      i.logger.warn(
                        "negative duration computed for frag " +
                        a.sn +
                        ",level " +
                        a.level +
                        ", there should be some duration drift between playlist and fragment!"
                      ))
                    : ((n.duration = a.start - s),
                      n.duration < 0 &&
                      i.logger.warn(
                        "negative duration computed for frag " +
                        n.sn +
                        ",level " +
                        n.level +
                        ", there should be some duration drift between playlist and fragment!"
                      ));
              },
            };
          t.exports = a;
        },
        { 51: 51 },
      ],
      37: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(2),
            o = i(s),
            l = e(33),
            u = i(l),
            d = e(31),
            f = e(41),
            c = i(f),
            h = e(39),
            g = i(h),
            v = e(40),
            p = i(v),
            y = e(13),
            m = i(y),
            E = e(12),
            b = i(E),
            T = e(11),
            _ = i(T),
            k = e(51),
            R = e(1),
            A = i(R),
            S = e(4),
            L = (function () {
              function e() {
                var t = this,
                  r =
                    arguments.length > 0 && void 0 !== arguments[0]
                      ? arguments[0]
                      : {};
                a(this, e);
                var i = e.DefaultConfig;
                if (
                  (r.liveSyncDurationCount || r.liveMaxLatencyDurationCount) &&
                  (r.liveSyncDuration || r.liveMaxLatencyDuration)
                )
                  throw new Error(
                    "Illegal hls.js config: don't mix up liveSyncDurationCount/liveMaxLatencyDurationCount and liveSyncDuration/liveMaxLatencyDuration"
                  );
                for (var n in i) n in r || (r[n] = i[n]);
                if (
                  void 0 !== r.liveMaxLatencyDurationCount &&
                  r.liveMaxLatencyDurationCount <= r.liveSyncDurationCount
                )
                  throw new Error(
                    'Illegal hls.js config: "liveMaxLatencyDurationCount" must be gt "liveSyncDurationCount"'
                  );
                if (
                  void 0 !== r.liveMaxLatencyDuration &&
                  (r.liveMaxLatencyDuration <= r.liveSyncDuration ||
                    void 0 === r.liveSyncDuration)
                )
                  throw new Error(
                    'Illegal hls.js config: "liveMaxLatencyDuration" must be gt "liveSyncDuration"'
                  );
                (0, k.enableLogs)(r.debug),
                  (this.config = r),
                  (this._autoLevelCapping = -1);
                var s = (this.observer = new A.default());
                (s.trigger = function (e) {
                  for (
                    var t = arguments.length,
                    r = Array(t > 1 ? t - 1 : 0),
                    i = 1;
                    i < t;
                    i++
                  )
                    r[i - 1] = arguments[i];
                  s.emit.apply(s, [e, e].concat(r));
                }),
                  (s.off = function (e) {
                    for (
                      var t = arguments.length,
                      r = Array(t > 1 ? t - 1 : 0),
                      i = 1;
                      i < t;
                      i++
                    )
                      r[i - 1] = arguments[i];
                    s.removeListener.apply(s, [e].concat(r));
                  }),
                  (this.on = s.on.bind(s)),
                  (this.off = s.off.bind(s)),
                  (this.trigger = s.trigger.bind(s));
                var o = (this.abrController = new r.abrController(this)),
                  l = new r.bufferController(this),
                  u = new r.capLevelController(this),
                  d = new r.fpsController(this),
                  f = new c.default(this),
                  h = new g.default(this),
                  v = new p.default(this),
                  y = new _.default(this),
                  E = (this.levelController = new b.default(this)),
                  T = (this.streamController = new m.default(this)),
                  R = [E, T],
                  S = r.audioStreamController;
                S && R.push(new S(this)), (this.networkControllers = R);
                var L = [f, h, v, o, l, u, d, y];
                if ((S = r.audioTrackController)) {
                  var w = new S(this);
                  (this.audioTrackController = w), L.push(w);
                }
                if ((S = r.subtitleTrackController)) {
                  var D = new S(this);
                  (this.subtitleTrackController = D), L.push(D);
                }
                [r.subtitleStreamController, r.timelineController].forEach(
                  function (e) {
                    e && L.push(new e(t));
                  }
                ),
                  (this.coreComponents = L);
              }
              return (
                n(e, null, [
                  {
                    key: "isSupported",
                    value: function () {
                      return (
                        (window.MediaSource =
                          window.MediaSource || window.WebKitMediaSource),
                        window.MediaSource &&
                        "function" ==
                        typeof window.MediaSource.isTypeSupported &&
                        window.MediaSource.isTypeSupported(
                          'video/mp4; codecs="avc1.42E01E,mp4a.40.2"'
                        )
                      );
                    },
                  },
                  {
                    key: "version",
                    get: function () {
                      return "0.7.6";
                    },
                  },
                  {
                    key: "Events",
                    get: function () {
                      return u.default;
                    },
                  },
                  {
                    key: "ErrorTypes",
                    get: function () {
                      return d.ErrorTypes;
                    },
                  },
                  {
                    key: "ErrorDetails",
                    get: function () {
                      return d.ErrorDetails;
                    },
                  },
                  {
                    key: "DefaultConfig",
                    get: function () {
                      return e.defaultConfig
                        ? e.defaultConfig
                        : S.hlsDefaultConfig;
                    },
                    set: function (t) {
                      e.defaultConfig = t;
                    },
                  },
                ]),
                n(e, [
                  {
                    key: "destroy",
                    value: function () {
                      k.logger.log("destroy"),
                        this.trigger(u.default.DESTROYING),
                        this.detachMedia(),
                        this.coreComponents
                          .concat(this.networkControllers)
                          .forEach(function (e) {
                            e.destroy();
                          }),
                        (this.url = null),
                        this.observer.removeAllListeners(),
                        (this._autoLevelCapping = -1);
                    },
                  },
                  {
                    key: "attachMedia",
                    value: function (e) {
                      k.logger.log("attachMedia"),
                        (this.media = e),
                        this.trigger(u.default.MEDIA_ATTACHING, { media: e });
                    },
                  },
                  {
                    key: "detachMedia",
                    value: function () {
                      k.logger.log("detachMedia"),
                        this.trigger(u.default.MEDIA_DETACHING),
                        (this.media = null);
                    },
                  },
                  {
                    key: "loadSource",
                    value: function (e) {
                      (e = o.default.buildAbsoluteURL(window.location.href, e, {
                        alwaysNormalize: !0,
                      })),
                        k.logger.log("loadSource:" + e),
                        (this.url = e),
                        this.trigger(u.default.MANIFEST_LOADING, { url: e });
                    },
                  },
                  {
                    key: "startLoad",
                    value: function () {
                      var e =
                        arguments.length > 0 && void 0 !== arguments[0]
                          ? arguments[0]
                          : -1;
                      k.logger.log("startLoad(" + e + ")"),
                        this.networkControllers.forEach(function (t) {
                          t.startLoad(e);
                        });
                    },
                  },
                  {
                    key: "stopLoad",
                    value: function () {
                      k.logger.log("stopLoad"),
                        this.networkControllers.forEach(function (e) {
                          e.stopLoad();
                        });
                    },
                  },
                  {
                    key: "swapAudioCodec",
                    value: function () {
                      k.logger.log("swapAudioCodec"),
                        this.streamController.swapAudioCodec();
                    },
                  },
                  {
                    key: "recoverMediaError",
                    value: function () {
                      k.logger.log("recoverMediaError");
                      var e = this.media;
                      this.detachMedia(), this.attachMedia(e);
                    },
                  },
                  {
                    key: "levels",
                    get: function () {
                      return this.levelController.levels;
                    },
                  },
                  {
                    key: "currentLevel",
                    get: function () {
                      return this.streamController.currentLevel;
                    },
                    set: function (e) {
                      k.logger.log("set currentLevel:" + e),
                        (this.loadLevel = e),
                        this.streamController.immediateLevelSwitch();
                    },
                  },
                  {
                    key: "nextLevel",
                    get: function () {
                      return this.streamController.nextLevel;
                    },
                    set: function (e) {
                      k.logger.log("set nextLevel:" + e),
                        (this.levelController.manualLevel = e),
                        this.streamController.nextLevelSwitch();
                    },
                  },
                  {
                    key: "loadLevel",
                    get: function () {
                      return this.levelController.level;
                    },
                    set: function (e) {
                      k.logger.log("set loadLevel:" + e),
                        (this.levelController.manualLevel = e);
                    },
                  },
                  {
                    key: "nextLoadLevel",
                    get: function () {
                      return this.levelController.nextLoadLevel;
                    },
                    set: function (e) {
                      this.levelController.nextLoadLevel = e;
                    },
                  },
                  {
                    key: "firstLevel",
                    get: function () {
                      return Math.max(
                        this.levelController.firstLevel,
                        this.minAutoLevel
                      );
                    },
                    set: function (e) {
                      k.logger.log("set firstLevel:" + e),
                        (this.levelController.firstLevel = e);
                    },
                  },
                  {
                    key: "startLevel",
                    get: function () {
                      return this.levelController.startLevel;
                    },
                    set: function (e) {
                      k.logger.log("set startLevel:" + e);
                      var t = this;
                      e !== -1 && (e = Math.max(e, t.minAutoLevel)),
                        (t.levelController.startLevel = e);
                    },
                  },
                  {
                    key: "autoLevelCapping",
                    get: function () {
                      return this._autoLevelCapping;
                    },
                    set: function (e) {
                      k.logger.log("set autoLevelCapping:" + e),
                        (this._autoLevelCapping = e);
                    },
                  },
                  {
                    key: "autoLevelEnabled",
                    get: function () {
                      return this.levelController.manualLevel === -1;
                    },
                  },
                  {
                    key: "manualLevel",
                    get: function () {
                      return this.levelController.manualLevel;
                    },
                  },
                  {
                    key: "minAutoLevel",
                    get: function () {
                      for (
                        var e = this,
                        t = e.levels,
                        r = e.config.minAutoBitrate,
                        i = t ? t.length : 0,
                        a = 0;
                        a < i;
                        a++
                      ) {
                        if (
                          (t[a].realBitrate
                            ? Math.max(t[a].realBitrate, t[a].bitrate)
                            : t[a].bitrate) > r
                        )
                          return a;
                      }
                      return 0;
                    },
                  },
                  {
                    key: "maxAutoLevel",
                    get: function () {
                      var e = this,
                        t = e.levels,
                        r = e.autoLevelCapping;
                      return r === -1 && t && t.length ? t.length - 1 : r;
                    },
                  },
                  {
                    key: "nextAutoLevel",
                    get: function () {
                      var e = this;
                      return Math.min(
                        Math.max(e.abrController.nextAutoLevel, e.minAutoLevel),
                        e.maxAutoLevel
                      );
                    },
                    set: function (e) {
                      var t = this;
                      t.abrController.nextAutoLevel = Math.max(
                        t.minAutoLevel,
                        e
                      );
                    },
                  },
                  {
                    key: "audioTracks",
                    get: function () {
                      var e = this.audioTrackController;
                      return e ? e.audioTracks : [];
                    },
                  },
                  {
                    key: "audioTrack",
                    get: function () {
                      var e = this.audioTrackController;
                      return e ? e.audioTrack : -1;
                    },
                    set: function (e) {
                      var t = this.audioTrackController;
                      t && (t.audioTrack = e);
                    },
                  },
                  {
                    key: "liveSyncPosition",
                    get: function () {
                      return this.streamController.liveSyncPosition;
                    },
                  },
                  {
                    key: "subtitleTracks",
                    get: function () {
                      var e = this.subtitleTrackController;
                      return e ? e.subtitleTracks : [];
                    },
                  },
                  {
                    key: "subtitleTrack",
                    get: function () {
                      var e = this.subtitleTrackController;
                      return e ? e.subtitleTrack : -1;
                    },
                    set: function (e) {
                      var t = this.subtitleTrackController;
                      t && (t.subtitleTrack = e);
                    },
                  },
                ]),
                e
              );
            })();
          r.default = L;
        },
        {
          1: 1,
          11: 11,
          12: 12,
          13: 13,
          2: 2,
          31: 31,
          33: 33,
          39: 39,
          4: 4,
          40: 40,
          41: 41,
          51: 51,
        },
      ],
      38: [
        function (e, t, r) {
          "use strict";
          t.exports = e(37).default;
        },
        { 37: 37 },
      ],
      39: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(31),
            h = e(51),
            g = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.FRAG_LOADING
                  )
                );
                return (r.loaders = {}), r;
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      var e = this.loaders;
                      for (var t in e) {
                        var r = e[t];
                        r && r.destroy();
                      }
                      (this.loaders = {}),
                        f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onFragLoading",
                    value: function (e) {
                      var t = e.frag,
                        r = t.type,
                        i = this.loaders[r],
                        a = this.hls.config;
                      (t.loaded = 0),
                        i &&
                        (h.logger.warn(
                          "abort previous fragment loader for type:" + r
                        ),
                          i.abort()),
                        (i =
                          this.loaders[r] =
                          t.loader =
                          void 0 !== a.fLoader
                            ? new a.fLoader(a)
                            : new a.loader(a));
                      var n = void 0,
                        s = void 0,
                        o = void 0;
                      n = {
                        url: t.url,
                        frag: t,
                        responseType: "arraybuffer",
                        progressData: !1,
                      };
                      var l = t.byteRangeStartOffset,
                        u = t.byteRangeEndOffset;
                      isNaN(l) ||
                        isNaN(u) ||
                        ((n.rangeStart = l), (n.rangeEnd = u)),
                        (s = {
                          timeout: a.fragLoadingTimeOut,
                          maxRetry: 0,
                          retryDelay: 0,
                          maxRetryDelay: a.fragLoadingMaxRetryTimeout,
                        }),
                        (o = {
                          onSuccess: this.loadsuccess.bind(this),
                          onError: this.loaderror.bind(this),
                          onTimeout: this.loadtimeout.bind(this),
                          onProgress: this.loadprogress.bind(this),
                        }),
                        i.load(n, s, o);
                    },
                  },
                  {
                    key: "loadsuccess",
                    value: function (e, t, r) {
                      var i = e.data,
                        a = r.frag;
                      (a.loader = void 0),
                        (this.loaders[a.type] = void 0),
                        this.hls.trigger(u.default.FRAG_LOADED, {
                          payload: i,
                          frag: a,
                          stats: t,
                        });
                    },
                  },
                  {
                    key: "loaderror",
                    value: function (e, t) {
                      var r = t.loader;
                      r && r.abort(),
                        (this.loaders[t.type] = void 0),
                        this.hls.trigger(u.default.ERROR, {
                          type: c.ErrorTypes.NETWORK_ERROR,
                          details: c.ErrorDetails.FRAG_LOAD_ERROR,
                          fatal: !1,
                          frag: t.frag,
                          response: e,
                        });
                    },
                  },
                  {
                    key: "loadtimeout",
                    value: function (e, t) {
                      var r = t.loader;
                      r && r.abort(),
                        (this.loaders[t.type] = void 0),
                        this.hls.trigger(u.default.ERROR, {
                          type: c.ErrorTypes.NETWORK_ERROR,
                          details: c.ErrorDetails.FRAG_LOAD_TIMEOUT,
                          fatal: !1,
                          frag: t.frag,
                        });
                    },
                  },
                  {
                    key: "loadprogress",
                    value: function (e, t, r) {
                      var i = t.frag;
                      (i.loaded = e.loaded),
                        this.hls.trigger(u.default.FRAG_LOAD_PROGRESS, {
                          frag: i,
                          stats: e,
                        });
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = g;
        },
        { 31: 31, 32: 32, 33: 33, 51: 51 },
      ],
      40: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          function n(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function s(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(33),
            u = i(l),
            d = e(32),
            f = i(d),
            c = e(31),
            h = e(51),
            g = (function (e) {
              function t(e) {
                a(this, t);
                var r = n(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    u.default.KEY_LOADING
                  )
                );
                return (
                  (r.loaders = {}),
                  (r.decryptkey = null),
                  (r.decrypturl = null),
                  r
                );
              }
              return (
                s(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      for (var e in this.loaders) {
                        var t = this.loaders[e];
                        t && t.destroy();
                      }
                      (this.loaders = {}),
                        f.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onKeyLoading",
                    value: function (e) {
                      var t = e.frag,
                        r = t.type,
                        i = this.loaders[r],
                        a = t.decryptdata,
                        n = a.uri;
                      if (n !== this.decrypturl || null === this.decryptkey) {
                        var s = this.hls.config;
                        i &&
                          (h.logger.warn(
                            "abort previous key loader for type:" + r
                          ),
                            i.abort()),
                          (t.loader = this.loaders[r] = new s.loader(s)),
                          (this.decrypturl = n),
                          (this.decryptkey = null);
                        var o = void 0,
                          l = void 0,
                          d = void 0;
                        (o = { url: n, frag: t, responseType: "arraybuffer" }),
                          (l = {
                            timeout: s.fragLoadingTimeOut,
                            maxRetry: s.fragLoadingMaxRetry,
                            retryDelay: s.fragLoadingRetryDelay,
                            maxRetryDelay: s.fragLoadingMaxRetryTimeout,
                          }),
                          (d = {
                            onSuccess: this.loadsuccess.bind(this),
                            onError: this.loaderror.bind(this),
                            onTimeout: this.loadtimeout.bind(this),
                          }),
                          t.loader.load(o, l, d);
                      } else
                        this.decryptkey &&
                          ((a.key = this.decryptkey),
                            this.hls.trigger(u.default.KEY_LOADED, { frag: t }));
                    },
                  },
                  {
                    key: "loadsuccess",
                    value: function (e, t, r) {
                      var i = r.frag;
                      (this.decryptkey = i.decryptdata.key =
                        new Uint8Array(e.data)),
                        (i.loader = void 0),
                        (this.loaders[i.type] = void 0),
                        this.hls.trigger(u.default.KEY_LOADED, { frag: i });
                    },
                  },
                  {
                    key: "loaderror",
                    value: function (e, t) {
                      var r = t.frag,
                        i = r.loader;
                      i && i.abort(),
                        (this.loaders[t.type] = void 0),
                        this.hls.trigger(u.default.ERROR, {
                          type: c.ErrorTypes.NETWORK_ERROR,
                          details: c.ErrorDetails.KEY_LOAD_ERROR,
                          fatal: !1,
                          frag: r,
                          response: e,
                        });
                    },
                  },
                  {
                    key: "loadtimeout",
                    value: function (e, t) {
                      var r = t.frag,
                        i = r.loader;
                      i && i.abort(),
                        (this.loaders[t.type] = void 0),
                        this.hls.trigger(u.default.ERROR, {
                          type: c.ErrorTypes.NETWORK_ERROR,
                          details: c.ErrorDetails.KEY_LOAD_TIMEOUT,
                          fatal: !1,
                          frag: r,
                        });
                    },
                  },
                ]),
                t
              );
            })(f.default);
          r.default = g;
        },
        { 31: 31, 32: 32, 33: 33, 51: 51 },
      ],
      41: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!e)
              throw new ReferenceError(
                "this hasn't been initialised - super() hasn't been called"
              );
            return !t || ("object" != typeof t && "function" != typeof t)
              ? e
              : t;
          }
          function n(e, t) {
            if ("function" != typeof t && null !== t)
              throw new TypeError(
                "Super expression must either be null or a function, not " +
                typeof t
              );
            (e.prototype = Object.create(t && t.prototype, {
              constructor: {
                value: e,
                enumerable: !1,
                writable: !0,
                configurable: !0,
              },
            })),
              t &&
              (Object.setPrototypeOf
                ? Object.setPrototypeOf(e, t)
                : (e.__proto__ = t));
          }
          function s(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            l = e(2),
            u = i(l),
            d = e(33),
            f = i(d),
            c = e(32),
            h = i(c),
            g = e(31),
            v = e(45),
            p = i(v),
            y = e(51),
            m = /#EXT-X-STREAM-INF:([^\n\r]*)[\r\n]+([^\r\n]+)/g,
            E = /#EXT-X-MEDIA:(.*)/g,
            b =
              /#EXTINF:(\d*(?:\.\d+)?)(?:,(.*))?|(?!#)(\S.+)|#EXT-X-BYTERANGE: *(.+)|#EXT-X-PROGRAM-DATE-TIME:(.+)|#.*/g,
            T = (function () {
              function e() {
                s(this, e),
                  (this.method = null),
                  (this.key = null),
                  (this.iv = null),
                  (this._uri = null);
              }
              return (
                o(e, [
                  {
                    key: "uri",
                    get: function () {
                      return (
                        !this._uri &&
                        this.reluri &&
                        (this._uri = u.default.buildAbsoluteURL(
                          this.baseuri,
                          this.reluri,
                          { alwaysNormalize: !0 }
                        )),
                        this._uri
                      );
                    },
                  },
                ]),
                e
              );
            })(),
            _ = (function () {
              function e() {
                s(this, e),
                  (this._url = null),
                  (this._byteRange = null),
                  (this._decryptdata = null),
                  (this.tagList = []);
              }
              return (
                o(e, [
                  {
                    key: "createInitializationVector",
                    value: function (e) {
                      for (var t = new Uint8Array(16), r = 12; r < 16; r++)
                        t[r] = (e >> (8 * (15 - r))) & 255;
                      return t;
                    },
                  },
                  {
                    key: "fragmentDecryptdataFromLevelkey",
                    value: function (e, t) {
                      var r = e;
                      return (
                        e &&
                        e.method &&
                        e.uri &&
                        !e.iv &&
                        ((r = new T()),
                          (r.method = e.method),
                          (r.baseuri = e.baseuri),
                          (r.reluri = e.reluri),
                          (r.iv = this.createInitializationVector(t))),
                        r
                      );
                    },
                  },
                  {
                    key: "cloneObj",
                    value: function (e) {
                      return JSON.parse(JSON.stringify(e));
                    },
                  },
                  {
                    key: "url",
                    get: function () {
                      return (
                        !this._url &&
                        this.relurl &&
                        (this._url = u.default.buildAbsoluteURL(
                          this.baseurl,
                          this.relurl,
                          { alwaysNormalize: !0 }
                        )),
                        this._url
                      );
                    },
                    set: function (e) {
                      this._url = e;
                    },
                  },
                  {
                    key: "programDateTime",
                    get: function () {
                      return (
                        !this._programDateTime &&
                        this.rawProgramDateTime &&
                        (this._programDateTime = new Date(
                          Date.parse(this.rawProgramDateTime)
                        )),
                        this._programDateTime
                      );
                    },
                  },
                  {
                    key: "byteRange",
                    get: function () {
                      if (!this._byteRange) {
                        var e = (this._byteRange = []);
                        if (this.rawByteRange) {
                          var t = this.rawByteRange.split("@", 2);
                          if (1 === t.length) {
                            var r = this.lastByteRangeEndOffset;
                            e[0] = r ? r : 0;
                          } else e[0] = parseInt(t[1]);
                          e[1] = parseInt(t[0]) + e[0];
                        }
                      }
                      return this._byteRange;
                    },
                  },
                  {
                    key: "byteRangeStartOffset",
                    get: function () {
                      return this.byteRange[0];
                    },
                  },
                  {
                    key: "byteRangeEndOffset",
                    get: function () {
                      return this.byteRange[1];
                    },
                  },
                  {
                    key: "decryptdata",
                    get: function () {
                      return (
                        this._decryptdata ||
                        (this._decryptdata =
                          this.fragmentDecryptdataFromLevelkey(
                            this.levelkey,
                            this.sn
                          )),
                        this._decryptdata
                      );
                    },
                  },
                ]),
                e
              );
            })(),
            k = (function (e) {
              function t(e) {
                s(this, t);
                var r = a(
                  this,
                  (t.__proto__ || Object.getPrototypeOf(t)).call(
                    this,
                    e,
                    f.default.MANIFEST_LOADING,
                    f.default.LEVEL_LOADING,
                    f.default.AUDIO_TRACK_LOADING,
                    f.default.SUBTITLE_TRACK_LOADING
                  )
                );
                return (r.loaders = {}), r;
              }
              return (
                n(t, e),
                o(t, [
                  {
                    key: "destroy",
                    value: function () {
                      for (var e in this.loaders) {
                        var t = this.loaders[e];
                        t && t.destroy();
                      }
                      (this.loaders = {}),
                        h.default.prototype.destroy.call(this);
                    },
                  },
                  {
                    key: "onManifestLoading",
                    value: function (e) {
                      this.load(e.url, { type: "manifest" });
                    },
                  },
                  {
                    key: "onLevelLoading",
                    value: function (e) {
                      this.load(e.url, {
                        type: "level",
                        level: e.level,
                        id: e.id,
                      });
                    },
                  },
                  {
                    key: "onAudioTrackLoading",
                    value: function (e) {
                      this.load(e.url, { type: "audioTrack", id: e.id });
                    },
                  },
                  {
                    key: "onSubtitleTrackLoading",
                    value: function (e) {
                      this.load(e.url, { type: "subtitleTrack", id: e.id });
                    },
                  },
                  {
                    key: "load",
                    value: function (e, t) {
                      var r = this.loaders[t.type];
                      if (r) {
                        var i = r.context;
                        if (i && i.url === e)
                          return void y.logger.trace(
                            "playlist request ongoing"
                          );
                        y.logger.warn(
                          "abort previous loader for type:" + t.type
                        ),
                          r.abort();
                      }
                      var a = this.hls.config,
                        n = void 0,
                        s = void 0,
                        o = void 0,
                        l = void 0;
                      "manifest" === t.type
                        ? ((n = a.manifestLoadingMaxRetry),
                          (s = a.manifestLoadingTimeOut),
                          (o = a.manifestLoadingRetryDelay),
                          (l = a.manifestLoadingMaxRetryTimeout))
                        : ((n = a.levelLoadingMaxRetry),
                          (s = a.levelLoadingTimeOut),
                          (o = a.levelLoadingRetryDelay),
                          (l = a.levelLoadingMaxRetryTimeout),
                          y.logger.log(
                            "loading playlist for " +
                            t.type +
                            " " +
                            (t.level || t.id)
                          )),
                        (r =
                          this.loaders[t.type] =
                          t.loader =
                          void 0 !== a.pLoader
                            ? new a.pLoader(a)
                            : new a.loader(a)),
                        (t.url = e),
                        (t.responseType = "");
                      var u = void 0,
                        d = void 0;
                      (u = {
                        timeout: s,
                        maxRetry: n,
                        retryDelay: o,
                        maxRetryDelay: l,
                      }),
                        (d = {
                          onSuccess: this.loadsuccess.bind(this),
                          onError: this.loaderror.bind(this),
                          onTimeout: this.loadtimeout.bind(this),
                        }),
                        r.load(t, u, d);
                    },
                  },
                  {
                    key: "resolve",
                    value: function (e, t) {
                      return u.default.buildAbsoluteURL(t, e, {
                        alwaysNormalize: !0,
                      });
                    },
                  },
                  {
                    key: "parseMasterPlaylist",
                    value: function (e, t) {
                      var r = [],
                        i = void 0;
                      for (m.lastIndex = 0; null != (i = m.exec(e));) {
                        var a = {},
                          n = (a.attrs = new p.default(i[1]));
                        a.url = this.resolve(i[2], t);
                        var s = n.decimalResolution("RESOLUTION");
                        s && ((a.width = s.width), (a.height = s.height)),
                          (a.bitrate =
                            n.decimalInteger("AVERAGE-BANDWIDTH") ||
                            n.decimalInteger("BANDWIDTH")),
                          (a.name = n.NAME);
                        var o = n.CODECS;
                        if (o) {
                          o = o.split(/[ ,]+/);
                          for (var l = 0; l < o.length; l++) {
                            var u = o[l];
                            u.indexOf("avc1") !== -1
                              ? (a.videoCodec = this.avc1toavcoti(u))
                              : (a.audioCodec = u);
                          }
                        }
                        r.push(a);
                      }
                      return r;
                    },
                  },
                  {
                    key: "parseMasterPlaylistMedia",
                    value: function (e, t, r) {
                      var i = void 0,
                        a = [],
                        n = 0;
                      for (E.lastIndex = 0; null != (i = E.exec(e));) {
                        var s = {},
                          o = new p.default(i[1]);
                        o.TYPE === r &&
                          ((s.groupId = o["GROUP-ID"]),
                            (s.name = o.NAME),
                            (s.type = r),
                            (s.default = "YES" === o.DEFAULT),
                            (s.autoselect = "YES" === o.AUTOSELECT),
                            (s.forced = "YES" === o.FORCED),
                            o.URI && (s.url = this.resolve(o.URI, t)),
                            (s.lang = o.LANGUAGE),
                            s.name || (s.name = s.lang),
                            (s.id = n++),
                            a.push(s));
                      }
                      return a;
                    },
                  },
                  {
                    key: "avc1toavcoti",
                    value: function (e) {
                      var t,
                        r = e.split(".");
                      return (
                        r.length > 2
                          ? ((t = r.shift() + "."),
                            (t += parseInt(r.shift()).toString(16)),
                            (t += (
                              "000" + parseInt(r.shift()).toString(16)
                            ).substr(-4)))
                          : (t = e),
                        t
                      );
                    },
                  },
                  {
                    key: "parseLevelPlaylist",
                    value: function (e, t, r, i) {
                      var a,
                        n,
                        s = 0,
                        o = 0,
                        l = {
                          type: null,
                          version: null,
                          url: t,
                          fragments: [],
                          live: !0,
                          startSN: 0,
                        },
                        u = new T(),
                        d = 0,
                        f = null,
                        c = new _();
                      for (b.lastIndex = 0; null !== (a = b.exec(e));) {
                        var h = a[1];
                        if (h) {
                          c.duration = parseFloat(h);
                          var g = (" " + a[2]).slice(1);
                          (c.title = g ? g : null),
                            c.tagList.push(g ? ["INF", h, g] : ["INF", h]);
                        } else if (a[3]) {
                          if (!isNaN(c.duration)) {
                            var v = s++;
                            (c.type = i),
                              (c.start = o),
                              (c.levelkey = u),
                              (c.sn = v),
                              (c.level = r),
                              (c.cc = d),
                              (c.baseurl = t),
                              (c.relurl = (" " + a[3]).slice(1)),
                              l.fragments.push(c),
                              (f = c),
                              (o += c.duration),
                              (c = new _());
                          }
                        } else if (a[4]) {
                          if (((c.rawByteRange = (" " + a[4]).slice(1)), f)) {
                            var m = f.byteRangeEndOffset;
                            m && (c.lastByteRangeEndOffset = m);
                          }
                        } else if (a[5])
                          (c.rawProgramDateTime = (" " + a[5]).slice(1)),
                            c.tagList.push([
                              "PROGRAM-DATE-TIME",
                              c.rawProgramDateTime,
                            ]);
                        else {
                          for (
                            a = a[0].match(
                              /(?:(?:#(EXTM3U))|(?:#EXT-X-(PLAYLIST-TYPE):(.+))|(?:#EXT-X-(MEDIA-SEQUENCE): *(\d+))|(?:#EXT-X-(TARGETDURATION): *(\d+))|(?:#EXT-X-(KEY):(.+))|(?:#EXT-X-(START):(.+))|(?:#EXT-X-(ENDLIST))|(?:#EXT-X-(DISCONTINUITY-SEQ)UENCE:(\d+))|(?:#EXT-X-(DIS)CONTINUITY))|(?:#EXT-X-(VERSION):(\d+))|(?:#EXT-X-(MAP):(.+))|(?:(#)(.*):(.*))|(?:(#)(.*))(?:.*)\r?\n?/
                            ),
                            n = 1;
                            n < a.length && void 0 === a[n];
                            n++
                          );
                          var E = (" " + a[n + 1]).slice(1),
                            k = (" " + a[n + 2]).slice(1);
                          switch (a[n]) {
                            case "#":
                              c.tagList.push(k ? [E, k] : [E]);
                              break;
                            case "PLAYLIST-TYPE":
                              l.type = E.toUpperCase();
                              break;
                            case "MEDIA-SEQUENCE":
                              s = l.startSN = parseInt(E);
                              break;
                            case "TARGETDURATION":
                              l.targetduration = parseFloat(E);
                              break;
                            case "VERSION":
                              l.version = parseInt(E);
                              break;
                            case "EXTM3U":
                              break;
                            case "ENDLIST":
                              l.live = !1;
                              break;
                            case "DIS":
                              d++, c.tagList.push(["DIS"]);
                              break;
                            case "DISCONTINUITY-SEQ":
                              d = parseInt(E);
                              break;
                            case "KEY":
                              var R = E,
                                A = new p.default(R),
                                S = A.enumeratedString("METHOD"),
                                L = A.URI,
                                w = A.hexadecimalInteger("IV");
                              S &&
                                ((u = new T()),
                                  L &&
                                  ["AES-128", "SAMPLE-AES"].indexOf(S) >= 0 &&
                                  ((u.method = S),
                                    (u.baseuri = t),
                                    (u.reluri = L),
                                    (u.key = null),
                                    (u.iv = w)));
                              break;
                            case "START":
                              var D = E,
                                O = new p.default(D),
                                I = O.decimalFloatingPoint("TIME-OFFSET");
                              isNaN(I) || (l.startTimeOffset = I);
                              break;
                            case "MAP":
                              var P = new p.default(E);
                              (c.relurl = P.URI),
                                (c.rawByteRange = P.BYTERANGE),
                                (c.baseurl = t),
                                (c.level = r),
                                (c.type = i),
                                (c.sn = "initSegment"),
                                (l.initSegment = c),
                                (c = new _());
                              break;
                            default:
                              y.logger.warn(
                                "line parsed but not handled: " + a
                              );
                          }
                        }
                      }
                      return (
                        (c = f),
                        c &&
                        !c.relurl &&
                        (l.fragments.pop(), (o -= c.duration)),
                        (l.totalduration = o),
                        (l.averagetargetduration = o / l.fragments.length),
                        (l.endSN = s - 1),
                        l
                      );
                    },
                  },
                  {
                    key: "loadsuccess",
                    value: function (e, t, r) {
                      var i = e.data,
                        a = e.url,
                        n = r.type,
                        s = r.id,
                        o = r.level,
                        l = this.hls;
                      if (
                        ((this.loaders[n] = void 0),
                          (void 0 !== a && 0 !== a.indexOf("data:")) ||
                          (a = r.url),
                          (t.tload = performance.now()),
                          0 === i.indexOf("#EXTM3U"))
                      )
                        if (i.indexOf("#EXTINF:") > 0) {
                          var u = "audioTrack" !== n && "subtitleTrack" !== n,
                            d = isNaN(o) ? (isNaN(s) ? 0 : s) : o,
                            c = this.parseLevelPlaylist(
                              i,
                              a,
                              d,
                              "audioTrack" === n
                                ? "audio"
                                : "subtitleTrack" === n
                                  ? "subtitle"
                                  : "main"
                            );
                          (c.tload = t.tload),
                            "manifest" === n &&
                            l.trigger(f.default.MANIFEST_LOADED, {
                              levels: [{ url: a, details: c }],
                              audioTracks: [],
                              url: a,
                              stats: t,
                            }),
                            (t.tparsed = performance.now()),
                            c.targetduration
                              ? u
                                ? l.trigger(f.default.LEVEL_LOADED, {
                                  details: c,
                                  level: o || 0,
                                  id: s || 0,
                                  stats: t,
                                })
                                : "audioTrack" === n
                                  ? l.trigger(f.default.AUDIO_TRACK_LOADED, {
                                    details: c,
                                    id: s,
                                    stats: t,
                                  })
                                  : "subtitleTrack" === n &&
                                  l.trigger(f.default.SUBTITLE_TRACK_LOADED, {
                                    details: c,
                                    id: s,
                                    stats: t,
                                  })
                              : l.trigger(f.default.ERROR, {
                                type: g.ErrorTypes.NETWORK_ERROR,
                                details:
                                  g.ErrorDetails.MANIFEST_PARSING_ERROR,
                                fatal: !0,
                                url: a,
                                reason: "invalid targetduration",
                              });
                        } else {
                          var h = this.parseMasterPlaylist(i, a);
                          if (h.length) {
                            var v = this.parseMasterPlaylistMedia(
                              i,
                              a,
                              "AUDIO"
                            ),
                              p = this.parseMasterPlaylistMedia(
                                i,
                                a,
                                "SUBTITLES"
                              );
                            if (v.length) {
                              var m = !1;
                              v.forEach(function (e) {
                                e.url || (m = !0);
                              }),
                                m === !1 &&
                                h[0].audioCodec &&
                                !h[0].attrs.AUDIO &&
                                (y.logger.log(
                                  "audio codec signaled in quality level, but no embedded audio track signaled, create one"
                                ),
                                  v.unshift({ type: "main", name: "main" }));
                            }
                            l.trigger(f.default.MANIFEST_LOADED, {
                              levels: h,
                              audioTracks: v,
                              subtitles: p,
                              url: a,
                              stats: t,
                            });
                          } else
                            l.trigger(f.default.ERROR, {
                              type: g.ErrorTypes.NETWORK_ERROR,
                              details: g.ErrorDetails.MANIFEST_PARSING_ERROR,
                              fatal: !0,
                              url: a,
                              reason: "no level found in manifest",
                            });
                        }
                      else
                        l.trigger(f.default.ERROR, {
                          type: g.ErrorTypes.NETWORK_ERROR,
                          details: g.ErrorDetails.MANIFEST_PARSING_ERROR,
                          fatal: !0,
                          url: a,
                          reason: "no EXTM3U delimiter",
                        });
                    },
                  },
                  {
                    key: "loaderror",
                    value: function (e, t) {
                      var r,
                        i,
                        a = t.loader;
                      switch (t.type) {
                        case "manifest":
                          (r = g.ErrorDetails.MANIFEST_LOAD_ERROR), (i = !0);
                          break;
                        case "level":
                          (r = g.ErrorDetails.LEVEL_LOAD_ERROR), (i = !1);
                          break;
                        case "audioTrack":
                          (r = g.ErrorDetails.AUDIO_TRACK_LOAD_ERROR), (i = !1);
                      }
                      a && (a.abort(), (this.loaders[t.type] = void 0)),
                        this.hls.trigger(f.default.ERROR, {
                          type: g.ErrorTypes.NETWORK_ERROR,
                          details: r,
                          fatal: i,
                          url: a.url,
                          loader: a,
                          response: e,
                          context: t,
                        });
                    },
                  },
                  {
                    key: "loadtimeout",
                    value: function (e, t) {
                      var r,
                        i,
                        a = t.loader;
                      switch (t.type) {
                        case "manifest":
                          (r = g.ErrorDetails.MANIFEST_LOAD_TIMEOUT), (i = !0);
                          break;
                        case "level":
                          (r = g.ErrorDetails.LEVEL_LOAD_TIMEOUT), (i = !1);
                          break;
                        case "audioTrack":
                          (r = g.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT),
                            (i = !1);
                      }
                      a && (a.abort(), (this.loaders[t.type] = void 0)),
                        this.hls.trigger(f.default.ERROR, {
                          type: g.ErrorTypes.NETWORK_ERROR,
                          details: r,
                          fatal: i,
                          url: a.url,
                          loader: a,
                          context: t,
                        });
                    },
                  },
                ]),
                t
              );
            })(h.default);
          r.default = k;
        },
        { 2: 2, 31: 31, 32: 32, 33: 33, 45: 45, 51: 51 },
      ],
      42: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = Math.pow(2, 32) - 1,
            s = (function () {
              function e() {
                i(this, e);
              }
              return (
                a(e, null, [
                  {
                    key: "init",
                    value: function () {
                      e.types = {
                        avc1: [],
                        avcC: [],
                        btrt: [],
                        dinf: [],
                        dref: [],
                        esds: [],
                        ftyp: [],
                        hdlr: [],
                        mdat: [],
                        mdhd: [],
                        mdia: [],
                        mfhd: [],
                        minf: [],
                        moof: [],
                        moov: [],
                        mp4a: [],
                        ".mp3": [],
                        mvex: [],
                        mvhd: [],
                        pasp: [],
                        sdtp: [],
                        stbl: [],
                        stco: [],
                        stsc: [],
                        stsd: [],
                        stsz: [],
                        stts: [],
                        tfdt: [],
                        tfhd: [],
                        traf: [],
                        trak: [],
                        trun: [],
                        trex: [],
                        tkhd: [],
                        vmhd: [],
                        smhd: [],
                      };
                      var t;
                      for (t in e.types)
                        e.types.hasOwnProperty(t) &&
                          (e.types[t] = [
                            t.charCodeAt(0),
                            t.charCodeAt(1),
                            t.charCodeAt(2),
                            t.charCodeAt(3),
                          ]);
                      var r = new Uint8Array([
                        0, 0, 0, 0, 0, 0, 0, 0, 118, 105, 100, 101, 0, 0, 0,
                        0, 0, 0, 0, 0, 0, 0, 0, 0, 86, 105, 100, 101, 111, 72,
                        97, 110, 100, 108, 101, 114, 0,
                      ]),
                        i = new Uint8Array([
                          0, 0, 0, 0, 0, 0, 0, 0, 115, 111, 117, 110, 0, 0, 0,
                          0, 0, 0, 0, 0, 0, 0, 0, 0, 83, 111, 117, 110, 100, 72,
                          97, 110, 100, 108, 101, 114, 0,
                        ]);
                      e.HDLR_TYPES = { video: r, audio: i };
                      var a = new Uint8Array([
                        0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 117, 114, 108,
                        32, 0, 0, 0, 1,
                      ]),
                        n = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0]);
                      (e.STTS = e.STSC = e.STCO = n),
                        (e.STSZ = new Uint8Array([
                          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
                        ])),
                        (e.VMHD = new Uint8Array([
                          0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0,
                        ])),
                        (e.SMHD = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0])),
                        (e.STSD = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1]));
                      var s = new Uint8Array([105, 115, 111, 109]),
                        o = new Uint8Array([97, 118, 99, 49]),
                        l = new Uint8Array([0, 0, 0, 1]);
                      (e.FTYP = e.box(e.types.ftyp, s, l, s, o)),
                        (e.DINF = e.box(e.types.dinf, e.box(e.types.dref, a)));
                    },
                  },
                  {
                    key: "box",
                    value: function (e) {
                      for (
                        var t,
                        r = Array.prototype.slice.call(arguments, 1),
                        i = 8,
                        a = r.length,
                        n = a;
                        a--;

                      )
                        i += r[a].byteLength;
                      for (
                        t = new Uint8Array(i),
                        t[0] = (i >> 24) & 255,
                        t[1] = (i >> 16) & 255,
                        t[2] = (i >> 8) & 255,
                        t[3] = 255 & i,
                        t.set(e, 4),
                        a = 0,
                        i = 8;
                        a < n;
                        a++
                      )
                        t.set(r[a], i), (i += r[a].byteLength);
                      return t;
                    },
                  },
                  {
                    key: "hdlr",
                    value: function (t) {
                      return e.box(e.types.hdlr, e.HDLR_TYPES[t]);
                    },
                  },
                  {
                    key: "mdat",
                    value: function (t) {
                      return e.box(e.types.mdat, t);
                    },
                  },
                  {
                    key: "mdhd",
                    value: function (t, r) {
                      r *= t;
                      var i = Math.floor(r / (n + 1)),
                        a = Math.floor(r % (n + 1));
                      return e.box(
                        e.types.mdhd,
                        new Uint8Array([
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          2,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          3,
                          (t >> 24) & 255,
                          (t >> 16) & 255,
                          (t >> 8) & 255,
                          255 & t,
                          i >> 24,
                          (i >> 16) & 255,
                          (i >> 8) & 255,
                          255 & i,
                          a >> 24,
                          (a >> 16) & 255,
                          (a >> 8) & 255,
                          255 & a,
                          85,
                          196,
                          0,
                          0,
                        ])
                      );
                    },
                  },
                  {
                    key: "mdia",
                    value: function (t) {
                      return e.box(
                        e.types.mdia,
                        e.mdhd(t.timescale, t.duration),
                        e.hdlr(t.type),
                        e.minf(t)
                      );
                    },
                  },
                  {
                    key: "mfhd",
                    value: function (t) {
                      return e.box(
                        e.types.mfhd,
                        new Uint8Array([
                          0,
                          0,
                          0,
                          0,
                          t >> 24,
                          (t >> 16) & 255,
                          (t >> 8) & 255,
                          255 & t,
                        ])
                      );
                    },
                  },
                  {
                    key: "minf",
                    value: function (t) {
                      return "audio" === t.type
                        ? e.box(
                          e.types.minf,
                          e.box(e.types.smhd, e.SMHD),
                          e.DINF,
                          e.stbl(t)
                        )
                        : e.box(
                          e.types.minf,
                          e.box(e.types.vmhd, e.VMHD),
                          e.DINF,
                          e.stbl(t)
                        );
                    },
                  },
                  {
                    key: "moof",
                    value: function (t, r, i) {
                      return e.box(e.types.moof, e.mfhd(t), e.traf(i, r));
                    },
                  },
                  {
                    key: "moov",
                    value: function (t) {
                      for (var r = t.length, i = []; r--;) i[r] = e.trak(t[r]);
                      return e.box.apply(
                        null,
                        [e.types.moov, e.mvhd(t[0].timescale, t[0].duration)]
                          .concat(i)
                          .concat(e.mvex(t))
                      );
                    },
                  },
                  {
                    key: "mvex",
                    value: function (t) {
                      for (var r = t.length, i = []; r--;) i[r] = e.trex(t[r]);
                      return e.box.apply(null, [e.types.mvex].concat(i));
                    },
                  },
                  {
                    key: "mvhd",
                    value: function (t, r) {
                      r *= t;
                      var i = Math.floor(r / (n + 1)),
                        a = Math.floor(r % (n + 1)),
                        s = new Uint8Array([
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          2,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          3,
                          (t >> 24) & 255,
                          (t >> 16) & 255,
                          (t >> 8) & 255,
                          255 & t,
                          i >> 24,
                          (i >> 16) & 255,
                          (i >> 8) & 255,
                          255 & i,
                          a >> 24,
                          (a >> 16) & 255,
                          (a >> 8) & 255,
                          255 & a,
                          0,
                          1,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          64,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          255,
                          255,
                          255,
                          255,
                        ]);
                      return e.box(e.types.mvhd, s);
                    },
                  },
                  {
                    key: "sdtp",
                    value: function (t) {
                      var r,
                        i,
                        a = t.samples || [],
                        n = new Uint8Array(4 + a.length);
                      for (i = 0; i < a.length; i++)
                        (r = a[i].flags),
                          (n[i + 4] =
                            (r.dependsOn << 4) |
                            (r.isDependedOn << 2) |
                            r.hasRedundancy);
                      return e.box(e.types.sdtp, n);
                    },
                  },
                  {
                    key: "stbl",
                    value: function (t) {
                      return e.box(
                        e.types.stbl,
                        e.stsd(t),
                        e.box(e.types.stts, e.STTS),
                        e.box(e.types.stsc, e.STSC),
                        e.box(e.types.stsz, e.STSZ),
                        e.box(e.types.stco, e.STCO)
                      );
                    },
                  },
                  {
                    key: "avc1",
                    value: function (t) {
                      var r,
                        i,
                        a,
                        n = [],
                        s = [];
                      for (r = 0; r < t.sps.length; r++)
                        (i = t.sps[r]),
                          (a = i.byteLength),
                          n.push((a >>> 8) & 255),
                          n.push(255 & a),
                          (n = n.concat(Array.prototype.slice.call(i)));
                      for (r = 0; r < t.pps.length; r++)
                        (i = t.pps[r]),
                          (a = i.byteLength),
                          s.push((a >>> 8) & 255),
                          s.push(255 & a),
                          (s = s.concat(Array.prototype.slice.call(i)));
                      var o = e.box(
                        e.types.avcC,
                        new Uint8Array(
                          [1, n[3], n[4], n[5], 255, 224 | t.sps.length]
                            .concat(n)
                            .concat([t.pps.length])
                            .concat(s)
                        )
                      ),
                        l = t.width,
                        u = t.height,
                        d = t.pixelRatio[0],
                        f = t.pixelRatio[1];
                      return e.box(
                        e.types.avc1,
                        new Uint8Array([
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          (l >> 8) & 255,
                          255 & l,
                          (u >> 8) & 255,
                          255 & u,
                          0,
                          72,
                          0,
                          0,
                          0,
                          72,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          18,
                          100,
                          97,
                          105,
                          108,
                          121,
                          109,
                          111,
                          116,
                          105,
                          111,
                          110,
                          47,
                          104,
                          108,
                          115,
                          46,
                          106,
                          115,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          24,
                          17,
                          17,
                        ]),
                        o,
                        e.box(
                          e.types.btrt,
                          new Uint8Array([
                            0, 28, 156, 128, 0, 45, 198, 192, 0, 45, 198, 192,
                          ])
                        ),
                        e.box(
                          e.types.pasp,
                          new Uint8Array([
                            d >> 24,
                            (d >> 16) & 255,
                            (d >> 8) & 255,
                            255 & d,
                            f >> 24,
                            (f >> 16) & 255,
                            (f >> 8) & 255,
                            255 & f,
                          ])
                        )
                      );
                    },
                  },
                  {
                    key: "esds",
                    value: function (e) {
                      var t = e.config.length;
                      return new Uint8Array(
                        [
                          0,
                          0,
                          0,
                          0,
                          3,
                          23 + t,
                          0,
                          1,
                          0,
                          4,
                          15 + t,
                          64,
                          21,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          5,
                        ]
                          .concat([t])
                          .concat(e.config)
                          .concat([6, 1, 2])
                      );
                    },
                  },
                  {
                    key: "mp4a",
                    value: function (t) {
                      var r = t.samplerate;
                      return e.box(
                        e.types.mp4a,
                        new Uint8Array([
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          t.channelCount,
                          0,
                          16,
                          0,
                          0,
                          0,
                          0,
                          (r >> 8) & 255,
                          255 & r,
                          0,
                          0,
                        ]),
                        e.box(e.types.esds, e.esds(t))
                      );
                    },
                  },
                  {
                    key: "mp3",
                    value: function (t) {
                      var r = t.samplerate;
                      return e.box(
                        e.types[".mp3"],
                        new Uint8Array([
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          t.channelCount,
                          0,
                          16,
                          0,
                          0,
                          0,
                          0,
                          (r >> 8) & 255,
                          255 & r,
                          0,
                          0,
                        ])
                      );
                    },
                  },
                  {
                    key: "stsd",
                    value: function (t) {
                      return "audio" === t.type
                        ? t.isAAC || "mp3" !== t.codec
                          ? e.box(e.types.stsd, e.STSD, e.mp4a(t))
                          : e.box(e.types.stsd, e.STSD, e.mp3(t))
                        : e.box(e.types.stsd, e.STSD, e.avc1(t));
                    },
                  },
                  {
                    key: "tkhd",
                    value: function (t) {
                      var r = t.id,
                        i = t.duration * t.timescale,
                        a = t.width,
                        s = t.height,
                        o = Math.floor(i / (n + 1)),
                        l = Math.floor(i % (n + 1));
                      return e.box(
                        e.types.tkhd,
                        new Uint8Array([
                          1,
                          0,
                          0,
                          7,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          2,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          3,
                          (r >> 24) & 255,
                          (r >> 16) & 255,
                          (r >> 8) & 255,
                          255 & r,
                          0,
                          0,
                          0,
                          0,
                          o >> 24,
                          (o >> 16) & 255,
                          (o >> 8) & 255,
                          255 & o,
                          l >> 24,
                          (l >> 16) & 255,
                          (l >> 8) & 255,
                          255 & l,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          64,
                          0,
                          0,
                          0,
                          (a >> 8) & 255,
                          255 & a,
                          0,
                          0,
                          (s >> 8) & 255,
                          255 & s,
                          0,
                          0,
                        ])
                      );
                    },
                  },
                  {
                    key: "traf",
                    value: function (t, r) {
                      var i = e.sdtp(t),
                        a = t.id,
                        s = Math.floor(r / (n + 1)),
                        o = Math.floor(r % (n + 1));
                      return e.box(
                        e.types.traf,
                        e.box(
                          e.types.tfhd,
                          new Uint8Array([
                            0,
                            0,
                            0,
                            0,
                            a >> 24,
                            (a >> 16) & 255,
                            (a >> 8) & 255,
                            255 & a,
                          ])
                        ),
                        e.box(
                          e.types.tfdt,
                          new Uint8Array([
                            1,
                            0,
                            0,
                            0,
                            s >> 24,
                            (s >> 16) & 255,
                            (s >> 8) & 255,
                            255 & s,
                            o >> 24,
                            (o >> 16) & 255,
                            (o >> 8) & 255,
                            255 & o,
                          ])
                        ),
                        e.trun(t, i.length + 16 + 20 + 8 + 16 + 8 + 8),
                        i
                      );
                    },
                  },
                  {
                    key: "trak",
                    value: function (t) {
                      return (
                        (t.duration = t.duration || 4294967295),
                        e.box(e.types.trak, e.tkhd(t), e.mdia(t))
                      );
                    },
                  },
                  {
                    key: "trex",
                    value: function (t) {
                      var r = t.id;
                      return e.box(
                        e.types.trex,
                        new Uint8Array([
                          0,
                          0,
                          0,
                          0,
                          r >> 24,
                          (r >> 16) & 255,
                          (r >> 8) & 255,
                          255 & r,
                          0,
                          0,
                          0,
                          1,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          0,
                          1,
                          0,
                          1,
                        ])
                      );
                    },
                  },
                  {
                    key: "trun",
                    value: function (t, r) {
                      var i,
                        a,
                        n,
                        s,
                        o,
                        l,
                        u = t.samples || [],
                        d = u.length,
                        f = 12 + 16 * d,
                        c = new Uint8Array(f);
                      for (
                        r += 8 + f,
                        c.set(
                          [
                            0,
                            0,
                            15,
                            1,
                            (d >>> 24) & 255,
                            (d >>> 16) & 255,
                            (d >>> 8) & 255,
                            255 & d,
                            (r >>> 24) & 255,
                            (r >>> 16) & 255,
                            (r >>> 8) & 255,
                            255 & r,
                          ],
                          0
                        ),
                        i = 0;
                        i < d;
                        i++
                      )
                        (a = u[i]),
                          (n = a.duration),
                          (s = a.size),
                          (o = a.flags),
                          (l = a.cts),
                          c.set(
                            [
                              (n >>> 24) & 255,
                              (n >>> 16) & 255,
                              (n >>> 8) & 255,
                              255 & n,
                              (s >>> 24) & 255,
                              (s >>> 16) & 255,
                              (s >>> 8) & 255,
                              255 & s,
                              (o.isLeading << 2) | o.dependsOn,
                              (o.isDependedOn << 6) |
                              (o.hasRedundancy << 4) |
                              (o.paddingValue << 1) |
                              o.isNonSync,
                              61440 & o.degradPrio,
                              15 & o.degradPrio,
                              (l >>> 24) & 255,
                              (l >>> 16) & 255,
                              (l >>> 8) & 255,
                              255 & l,
                            ],
                            12 + 16 * i
                          );
                      return e.box(e.types.trun, c);
                    },
                  },
                  {
                    key: "initSegment",
                    value: function (t) {
                      e.types || e.init();
                      var r,
                        i = e.moov(t);
                      return (
                        (r = new Uint8Array(e.FTYP.byteLength + i.byteLength)),
                        r.set(e.FTYP),
                        r.set(i, e.FTYP.byteLength),
                        r
                      );
                    },
                  },
                ]),
                e
              );
            })();
          r.default = s;
        },
        {},
      ],
      43: [
        function (e, t, r) {
          "use strict";
          function i(e) {
            return e && e.__esModule ? e : { default: e };
          }
          function a(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var n = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            s = e(34),
            o = i(s),
            l = e(33),
            u = i(l),
            d = e(51),
            f = e(42),
            c = i(f),
            h = e(31),
            g = (function () {
              function e(t, r, i, n) {
                a(this, e),
                  (this.observer = t),
                  (this.config = r),
                  (this.typeSupported = i);
                var s = navigator.userAgent;
                (this.isSafari =
                  n && n.indexOf("Apple") > -1 && s && !s.match("CriOS")),
                  (this.ISGenerated = !1);
              }
              return (
                n(e, [
                  { key: "destroy", value: function () { } },
                  {
                    key: "resetTimeStamp",
                    value: function (e) {
                      this._initPTS = this._initDTS = e;
                    },
                  },
                  {
                    key: "resetInitSegment",
                    value: function () {
                      this.ISGenerated = !1;
                    },
                  },
                  {
                    key: "remux",
                    value: function (e, t, r, i, a, n, s) {
                      if (
                        (this.ISGenerated || this.generateIS(e, t, a),
                          this.ISGenerated)
                      )
                        if (e.samples.length) {
                          e.timescale ||
                            (d.logger.warn(
                              "regenerate InitSegment as audio detected"
                            ),
                              this.generateIS(e, t, a));
                          var o = this.remuxAudio(e, a, n, s);
                          if (t.samples.length) {
                            var l = void 0;
                            o && (l = o.endPTS - o.startPTS),
                              t.timescale ||
                              (d.logger.warn(
                                "regenerate InitSegment as video detected"
                              ),
                                this.generateIS(e, t, a)),
                              this.remuxVideo(t, a, n, l);
                          }
                        } else {
                          var f = void 0;
                          t.samples.length && (f = this.remuxVideo(t, a, n)),
                            f && e.codec && this.remuxEmptyAudio(e, a, n, f);
                        }
                      r.samples.length && this.remuxID3(r, a),
                        i.samples.length && this.remuxText(i, a),
                        this.observer.trigger(u.default.FRAG_PARSED);
                    },
                  },
                  {
                    key: "generateIS",
                    value: function (e, t, r) {
                      var i,
                        a,
                        n = this.observer,
                        s = e.samples,
                        o = t.samples,
                        l = this.typeSupported,
                        f = "audio/mp4",
                        g = {},
                        v = { tracks: g },
                        p = void 0 === this._initPTS;
                      if (
                        (p && (i = a = 1 / 0),
                          e.config &&
                          s.length &&
                          ((e.timescale = e.samplerate),
                            d.logger.log("audio sampling rate : " + e.samplerate),
                            e.isAAC ||
                            (l.mpeg
                              ? ((f = "audio/mpeg"), (e.codec = ""))
                              : l.mp3 && (e.codec = "mp3")),
                            (g.audio = {
                              container: f,
                              codec: e.codec,
                              initSegment:
                                !e.isAAC && l.mpeg
                                  ? new Uint8Array()
                                  : c.default.initSegment([e]),
                              metadata: { channelCount: e.channelCount },
                            }),
                            p && (i = a = s[0].pts - e.inputTimeScale * r)),
                          t.sps && t.pps && o.length)
                      ) {
                        var y = t.inputTimeScale;
                        (t.timescale = y),
                          (g.video = {
                            container: "video/mp4",
                            codec: t.codec,
                            initSegment: c.default.initSegment([t]),
                            metadata: { width: t.width, height: t.height },
                          }),
                          p &&
                          ((i = Math.min(i, o[0].pts - y * r)),
                            (a = Math.min(a, o[0].dts - y * r)),
                            this.observer.trigger(u.default.INIT_PTS_FOUND, {
                              initPTS: i,
                            }));
                      }
                      Object.keys(g).length
                        ? (n.trigger(u.default.FRAG_PARSING_INIT_SEGMENT, v),
                          (this.ISGenerated = !0),
                          p && ((this._initPTS = i), (this._initDTS = a)))
                        : n.trigger(u.default.ERROR, {
                          type: h.ErrorTypes.MEDIA_ERROR,
                          details: h.ErrorDetails.FRAG_PARSING_ERROR,
                          fatal: !1,
                          reason: "no audio/video samples found",
                        });
                    },
                  },
                  {
                    key: "remuxVideo",
                    value: function (e, t, r, i) {
                      var a,
                        n,
                        s,
                        o,
                        l,
                        f,
                        g,
                        v = 8,
                        p = e.timescale,
                        y = e.samples,
                        m = [],
                        E = y.length,
                        b = this._PTSNormalize,
                        T = this._initDTS;
                      y.sort(function (e, t) {
                        var r = e.dts - t.dts,
                          i = e.pts - t.pts;
                        return r ? r : i ? i : e.id - t.id;
                      });
                      var _ = y.reduce(function (e, t) {
                        return Math.max(Math.min(e, t.pts - t.dts), -18e3);
                      }, 0);
                      if (_ < 0) {
                        d.logger.warn(
                          "PTS < DTS detected in video samples, shifting DTS by " +
                          Math.round(_ / 90) +
                          " ms to overcome this issue"
                        );
                        for (var k = 0; k < y.length; k++) y[k].dts += _;
                      }
                      var R = void 0;
                      R = r ? this.nextAvcDts : t * p;
                      var A = y[0];
                      (l = Math.max(b(A.dts - T, R), 0)),
                        (o = Math.max(b(A.pts - T, R), 0));
                      var S = Math.round((l - R) / 90);
                      r &&
                        S &&
                        (S > 1
                          ? d.logger.log(
                            "AVC:" +
                            S +
                            " ms hole between fragments detected,filling it"
                          )
                          : S < -1 &&
                          d.logger.log(
                            "AVC:" +
                            -S +
                            " ms overlapping between fragments detected"
                          ),
                          (l = R),
                          (y[0].dts = l + T),
                          (o = Math.max(o - S, R)),
                          (y[0].pts = o + T),
                          d.logger.log(
                            "Video/PTS/DTS adjusted: " +
                            Math.round(o / 90) +
                            "/" +
                            Math.round(l / 90) +
                            ",delta:" +
                            S +
                            " ms"
                          )),
                        (A = y[y.length - 1]),
                        (g = Math.max(b(A.dts - T, R), 0)),
                        (f = Math.max(b(A.pts - T, R), 0)),
                        (f = Math.max(f, g));
                      var L = this.isSafari;
                      L && (a = Math.round((g - l) / (y.length - 1)));
                      for (var w = 0, D = 0, O = 0; O < E; O++) {
                        for (
                          var I = y[O], P = I.units, C = P.length, x = 0, F = 0;
                          F < C;
                          F++
                        )
                          x += P[F].data.length;
                        (D += x),
                          (w += C),
                          (I.length = x),
                          (I.dts = L
                            ? l + O * a
                            : Math.max(b(I.dts - T, R), l)),
                          (I.pts = Math.max(b(I.pts - T, R), I.dts));
                      }
                      var M = D + 4 * w + 8;
                      try {
                        n = new Uint8Array(M);
                      } catch (e) {
                        return void this.observer.trigger(u.default.ERROR, {
                          type: h.ErrorTypes.MUX_ERROR,
                          details: h.ErrorDetails.REMUX_ALLOC_ERROR,
                          fatal: !1,
                          bytes: M,
                          reason: "fail allocating video mdat " + M,
                        });
                      }
                      var N = new DataView(n.buffer);
                      N.setUint32(0, M), n.set(c.default.types.mdat, 4);
                      for (var U = 0; U < E; U++) {
                        for (
                          var B = y[U],
                          G = B.units,
                          j = 0,
                          K = void 0,
                          W = 0,
                          H = G.length;
                          W < H;
                          W++
                        ) {
                          var V = G[W],
                            Y = V.data,
                            X = V.data.byteLength;
                          N.setUint32(v, X),
                            (v += 4),
                            n.set(Y, v),
                            (v += X),
                            (j += 4 + X);
                        }
                        if (L)
                          K = Math.max(0, a * Math.round((B.pts - B.dts) / a));
                        else {
                          if (U < E - 1) a = y[U + 1].dts - B.dts;
                          else {
                            var z = this.config,
                              q = B.dts - y[U > 0 ? U - 1 : U].dts;
                            if (z.stretchShortVideoTrack) {
                              var Q = z.maxBufferHole,
                                J = z.maxSeekHole,
                                Z = Math.floor(Math.min(Q, J) * p),
                                $ = (i ? o + i * p : this.nextAudioPts) - B.pts;
                              $ > Z
                                ? ((a = $ - q),
                                  a < 0 && (a = q),
                                  d.logger.log(
                                    "It is approximately " +
                                    $ / 90 +
                                    " ms to the next segment; using duration " +
                                    a / 90 +
                                    " ms for the last video frame."
                                  ))
                                : (a = q);
                            } else a = q;
                          }
                          K = Math.round(B.pts - B.dts);
                        }
                        m.push({
                          size: j,
                          duration: a,
                          cts: K,
                          flags: {
                            isLeading: 0,
                            isDependedOn: 0,
                            hasRedundancy: 0,
                            degradPrio: 0,
                            dependsOn: B.key ? 2 : 1,
                            isNonSync: B.key ? 0 : 1,
                          },
                        });
                      }
                      this.nextAvcDts = g + a;
                      var ee = e.dropped;
                      if (
                        ((e.len = 0),
                          (e.nbNalu = 0),
                          (e.dropped = 0),
                          m.length &&
                          navigator.userAgent.toLowerCase().indexOf("chrome") >
                          -1)
                      ) {
                        var te = m[0].flags;
                        (te.dependsOn = 2), (te.isNonSync = 0);
                      }
                      (e.samples = m),
                        (s = c.default.moof(e.sequenceNumber++, l, e)),
                        (e.samples = []);
                      var re = {
                        data1: s,
                        data2: n,
                        startPTS: o / p,
                        endPTS: (f + a) / p,
                        startDTS: l / p,
                        endDTS: this.nextAvcDts / p,
                        type: "video",
                        nb: m.length,
                        dropped: ee,
                      };
                      return (
                        this.observer.trigger(u.default.FRAG_PARSING_DATA, re),
                        re
                      );
                    },
                  },
                  {
                    key: "remuxAudio",
                    value: function (e, t, r, i) {
                      var a,
                        n,
                        s,
                        l,
                        f,
                        g,
                        v,
                        p,
                        y,
                        m,
                        E,
                        b,
                        T,
                        _,
                        k,
                        R,
                        A = e.inputTimeScale,
                        S = e.timescale,
                        L = A / S,
                        w = e.isAAC ? 1024 : 1152,
                        D = w * L,
                        O = this._PTSNormalize,
                        I = this._initDTS,
                        P = !e.isAAC && this.typeSupported.mpeg,
                        C = P ? 0 : 8,
                        x = [],
                        F = [];
                      if (
                        (e.samples.sort(function (e, t) {
                          return e.pts - t.pts;
                        }),
                          (F = e.samples),
                          (R = this.nextAudioPts),
                          (r |=
                            F.length &&
                            R &&
                            ((i && Math.abs(t - R / A) < 0.1) ||
                              Math.abs(F[0].pts - R - I) < 20 * D)),
                          r || (R = t * A),
                          i && e.isAAC)
                      )
                        for (var M = 0, N = R; M < F.length;) {
                          var U = F[M],
                            B = O(U.pts - I, R),
                            G = B - N;
                          if (G <= -D)
                            d.logger.warn(
                              "Dropping 1 audio frame @ " +
                              (N / A).toFixed(3) +
                              "s due to " +
                              Math.abs((1e3 * G) / A) +
                              " ms overlap."
                            ),
                              F.splice(M, 1),
                              (e.len -= U.unit.length);
                          else if (G >= D && N) {
                            var j = Math.round(G / D);
                            d.logger.warn(
                              "Injecting " +
                              j +
                              " audio frame @ " +
                              (N / A).toFixed(3) +
                              "s due to " +
                              (1e3 * G) / A +
                              " ms gap."
                            );
                            for (var K = 0; K < j; K++)
                              (k = N + I),
                                (k = Math.max(k, I)),
                                (_ = o.default.getSilentFrame(
                                  e.manifestCodec || e.codec,
                                  e.channelCount
                                )),
                                _ ||
                                (d.logger.log(
                                  "Unable to get silent frame for given audio codec; duplicating last frame instead."
                                ),
                                  (_ = U.unit.subarray())),
                                F.splice(M, 0, { unit: _, pts: k, dts: k }),
                                (e.len += _.length),
                                (N += D),
                                (M += 1);
                            (U.pts = U.dts = N + I), (N += D), (M += 1);
                          } else
                            Math.abs(G),
                              (N += D),
                              (U.pts = U.dts =
                                0 === M ? I + R : F[M - 1].pts + D),
                              (M += 1);
                        }
                      for (var W = 0, H = F.length; W < H; W++) {
                        if (
                          ((n = F[W]),
                            (l = n.unit),
                            (m = n.pts - I),
                            (E = n.dts - I),
                            void 0 !== y)
                        )
                          (b = O(m, y)),
                            (T = O(E, y)),
                            (s.duration = Math.round((T - y) / L));
                        else {
                          (b = O(m, R)), (T = O(E, R));
                          var V = Math.round((1e3 * (b - R)) / A),
                            Y = 0;
                          if (r && e.isAAC && V) {
                            if (V > 0)
                              (Y = Math.round((b - R) / D)),
                                d.logger.log(
                                  V +
                                  " ms hole between AAC samples detected,filling it"
                                ),
                                Y > 0 &&
                                ((_ = o.default.getSilentFrame(
                                  e.manifestCodec || e.codec,
                                  e.channelCount
                                )),
                                  _ || (_ = l.subarray()),
                                  (e.len += Y * _.length));
                            else if (V < -12) {
                              d.logger.log(
                                "drop overlapping AAC sample, expected/parsed/delta:" +
                                (R / A).toFixed(3) +
                                "s/" +
                                (b / A).toFixed(3) +
                                "s/" +
                                -V +
                                "ms"
                              ),
                                (e.len -= l.byteLength);
                              continue;
                            }
                            b = T = R;
                          }
                          if (
                            ((v = Math.max(0, b)),
                              (p = Math.max(0, T)),
                              !(e.len > 0))
                          )
                            return;
                          var X = P ? e.len : e.len + 8;
                          try {
                            f = new Uint8Array(X);
                          } catch (e) {
                            return void this.observer.trigger(u.default.ERROR, {
                              type: h.ErrorTypes.MUX_ERROR,
                              details: h.ErrorDetails.REMUX_ALLOC_ERROR,
                              fatal: !1,
                              bytes: X,
                              reason: "fail allocating audio mdat " + X,
                            });
                          }
                          P ||
                            ((a = new DataView(f.buffer)),
                              a.setUint32(0, X),
                              f.set(c.default.types.mdat, 4));
                          for (var z = 0; z < Y; z++)
                            (k = b - (Y - z) * D),
                              (_ = o.default.getSilentFrame(
                                e.manifestCodec || e.codec,
                                e.channelCount
                              )),
                              _ ||
                              (d.logger.log(
                                "Unable to get silent frame for given audio codec; duplicating this frame instead."
                              ),
                                (_ = l.subarray())),
                              f.set(_, C),
                              (C += _.byteLength),
                              (s = {
                                size: _.byteLength,
                                cts: 0,
                                duration: 1024,
                                flags: {
                                  isLeading: 0,
                                  isDependedOn: 0,
                                  hasRedundancy: 0,
                                  degradPrio: 0,
                                  dependsOn: 1,
                                },
                              }),
                              x.push(s);
                        }
                        f.set(l, C);
                        var q = l.byteLength;
                        (C += q),
                          (s = {
                            size: q,
                            cts: 0,
                            duration: 0,
                            flags: {
                              isLeading: 0,
                              isDependedOn: 0,
                              hasRedundancy: 0,
                              degradPrio: 0,
                              dependsOn: 1,
                            },
                          }),
                          x.push(s),
                          (y = T);
                      }
                      var Q = 0,
                        J = x.length;
                      if (
                        (J >= 2 && ((Q = x[J - 2].duration), (s.duration = Q)),
                          J)
                      ) {
                        (this.nextAudioPts = b + L * Q),
                          (e.len = 0),
                          (e.samples = x),
                          (g = P
                            ? new Uint8Array()
                            : c.default.moof(e.sequenceNumber++, p / L, e)),
                          (e.samples = []);
                        var Z = {
                          data1: g,
                          data2: f,
                          startPTS: v / A,
                          endPTS: this.nextAudioPts / A,
                          startDTS: p / A,
                          endDTS: (T + L * Q) / A,
                          type: "audio",
                          nb: J,
                        };
                        return (
                          this.observer.trigger(u.default.FRAG_PARSING_DATA, Z),
                          Z
                        );
                      }
                      return null;
                    },
                  },
                  {
                    key: "remuxEmptyAudio",
                    value: function (e, t, r, i) {
                      var a = e.inputTimeScale,
                        n = e.samplerate ? e.samplerate : a,
                        s = a / n,
                        l = this.nextAudioPts,
                        u = (void 0 !== l ? l : i.startDTS * a) + this._initDTS,
                        f = i.endDTS * a + this._initDTS,
                        c = 1024 * s,
                        h = Math.ceil((f - u) / c),
                        g = o.default.getSilentFrame(
                          e.manifestCodec || e.codec,
                          e.channelCount
                        );
                      if ((d.logger.warn("remux empty Audio"), !g))
                        return void d.logger.trace(
                          "Unable to remuxEmptyAudio since we were unable to get a silent frame for given audio codec!"
                        );
                      for (var v = [], p = 0; p < h; p++) {
                        var y = u + p * c;
                        v.push({ unit: g, pts: y, dts: y }),
                          (e.len += g.length);
                      }
                      (e.samples = v), this.remuxAudio(e, t, r);
                    },
                  },
                  {
                    key: "remuxID3",
                    value: function (e, t) {
                      var r,
                        i = e.samples.length,
                        a = e.inputTimeScale,
                        n = this._initPTS,
                        s = this._initDTS;
                      if (i) {
                        for (var o = 0; o < i; o++)
                          (r = e.samples[o]),
                            (r.pts = (r.pts - n) / a),
                            (r.dts = (r.dts - s) / a);
                        this.observer.trigger(u.default.FRAG_PARSING_METADATA, {
                          samples: e.samples,
                        });
                      }
                      (e.samples = []), (t = t);
                    },
                  },
                  {
                    key: "remuxText",
                    value: function (e, t) {
                      e.samples.sort(function (e, t) {
                        return e.pts - t.pts;
                      });
                      var r,
                        i = e.samples.length,
                        a = e.inputTimeScale,
                        n = this._initPTS;
                      if (i) {
                        for (var s = 0; s < i; s++)
                          (r = e.samples[s]), (r.pts = (r.pts - n) / a);
                        this.observer.trigger(u.default.FRAG_PARSING_USERDATA, {
                          samples: e.samples,
                        });
                      }
                      (e.samples = []), (t = t);
                    },
                  },
                  {
                    key: "_PTSNormalize",
                    value: function (e, t) {
                      var r;
                      if (void 0 === t) return e;
                      for (
                        r = t < e ? -8589934592 : 8589934592;
                        Math.abs(e - t) > 4294967296;

                      )
                        e += r;
                      return e;
                    },
                  },
                ]),
                e
              );
            })();
          r.default = g;
        },
        { 31: 31, 33: 33, 34: 34, 42: 42, 51: 51 },
      ],
      44: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(33),
            s = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(n),
            o = (function () {
              function e(t) {
                i(this, e), (this.observer = t);
              }
              return (
                a(e, [
                  { key: "destroy", value: function () { } },
                  { key: "resetTimeStamp", value: function () { } },
                  { key: "resetInitSegment", value: function () { } },
                  {
                    key: "remux",
                    value: function (e, t, r, i, a, n, o, l) {
                      var u = this.observer,
                        d = "";
                      e && (d += "audio"),
                        t && (d += "video"),
                        u.trigger(s.default.FRAG_PARSING_DATA, {
                          data1: l,
                          startPTS: a,
                          startDTS: a,
                          type: d,
                          nb: 1,
                          dropped: 0,
                        }),
                        u.trigger(s.default.FRAG_PARSED);
                    },
                  },
                ]),
                e
              );
            })();
          r.default = o;
        },
        { 33: 33 },
      ],
      45: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = /^(\d+)x(\d+)$/,
            s = /\s*(.+?)\s*=((?:\".*?\")|.*?)(?:,|$)/g,
            o = (function () {
              function e(t) {
                i(this, e), "string" == typeof t && (t = e.parseAttrList(t));
                for (var r in t) t.hasOwnProperty(r) && (this[r] = t[r]);
              }
              return (
                a(
                  e,
                  [
                    {
                      key: "decimalInteger",
                      value: function (e) {
                        var t = parseInt(this[e], 10);
                        return t > Number.MAX_SAFE_INTEGER ? 1 / 0 : t;
                      },
                    },
                    {
                      key: "hexadecimalInteger",
                      value: function (e) {
                        if (this[e]) {
                          var t = (this[e] || "0x").slice(2);
                          t = (1 & t.length ? "0" : "") + t;
                          for (
                            var r = new Uint8Array(t.length / 2), i = 0;
                            i < t.length / 2;
                            i++
                          )
                            r[i] = parseInt(t.slice(2 * i, 2 * i + 2), 16);
                          return r;
                        }
                        return null;
                      },
                    },
                    {
                      key: "hexadecimalIntegerAsNumber",
                      value: function (e) {
                        var t = parseInt(this[e], 16);
                        return t > Number.MAX_SAFE_INTEGER ? 1 / 0 : t;
                      },
                    },
                    {
                      key: "decimalFloatingPoint",
                      value: function (e) {
                        return parseFloat(this[e]);
                      },
                    },
                    {
                      key: "enumeratedString",
                      value: function (e) {
                        return this[e];
                      },
                    },
                    {
                      key: "decimalResolution",
                      value: function (e) {
                        var t = n.exec(this[e]);
                        if (null !== t)
                          return {
                            width: parseInt(t[1], 10),
                            height: parseInt(t[2], 10),
                          };
                      },
                    },
                  ],
                  [
                    {
                      key: "parseAttrList",
                      value: function (e) {
                        var t,
                          r = {};
                        for (s.lastIndex = 0; null !== (t = s.exec(e));) {
                          var i = t[2];
                          0 === i.indexOf('"') &&
                            i.lastIndexOf('"') === i.length - 1 &&
                            (i = i.slice(1, -1)),
                            (r[t[1]] = i);
                        }
                        return r;
                      },
                    },
                  ]
                ),
                e
              );
            })();
          r.default = o;
        },
        {},
      ],
      46: [
        function (e, t, r) {
          "use strict";
          var i = {
            search: function (e, t) {
              for (var r = 0, i = e.length - 1, a = null, n = null; r <= i;) {
                (a = ((r + i) / 2) | 0), (n = e[a]);
                var s = t(n);
                if (s > 0) r = a + 1;
                else {
                  if (!(s < 0)) return n;
                  i = a - 1;
                }
              }
              return null;
            },
          };
          t.exports = i;
        },
        {},
      ],
      47: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = {
              42: 225,
              92: 233,
              94: 237,
              95: 243,
              96: 250,
              123: 231,
              124: 247,
              125: 209,
              126: 241,
              127: 9608,
              128: 174,
              129: 176,
              130: 189,
              131: 191,
              132: 8482,
              133: 162,
              134: 163,
              135: 9834,
              136: 224,
              137: 32,
              138: 232,
              139: 226,
              140: 234,
              141: 238,
              142: 244,
              143: 251,
              144: 193,
              145: 201,
              146: 211,
              147: 218,
              148: 220,
              149: 252,
              150: 8216,
              151: 161,
              152: 42,
              153: 8217,
              154: 9473,
              155: 169,
              156: 8480,
              157: 8226,
              158: 8220,
              159: 8221,
              160: 192,
              161: 194,
              162: 199,
              163: 200,
              164: 202,
              165: 203,
              166: 235,
              167: 206,
              168: 207,
              169: 239,
              170: 212,
              171: 217,
              172: 249,
              173: 219,
              174: 171,
              175: 187,
              176: 195,
              177: 227,
              178: 205,
              179: 204,
              180: 236,
              181: 210,
              182: 242,
              183: 213,
              184: 245,
              185: 123,
              186: 125,
              187: 92,
              188: 94,
              189: 95,
              190: 124,
              191: 8764,
              192: 196,
              193: 228,
              194: 214,
              195: 246,
              196: 223,
              197: 165,
              198: 164,
              199: 9475,
              200: 197,
              201: 229,
              202: 216,
              203: 248,
              204: 9487,
              205: 9491,
              206: 9495,
              207: 9499,
            },
            s = function (e) {
              var t = e;
              return n.hasOwnProperty(e) && (t = n[e]), String.fromCharCode(t);
            },
            o = 15,
            l = 100,
            u = { 17: 1, 18: 3, 21: 5, 22: 7, 23: 9, 16: 11, 19: 12, 20: 14 },
            d = { 17: 2, 18: 4, 21: 6, 22: 8, 23: 10, 19: 13, 20: 15 },
            f = { 25: 1, 26: 3, 29: 5, 30: 7, 31: 9, 24: 11, 27: 12, 28: 14 },
            c = { 25: 2, 26: 4, 29: 6, 30: 8, 31: 10, 27: 13, 28: 15 },
            h = [
              "white",
              "green",
              "blue",
              "cyan",
              "red",
              "yellow",
              "magenta",
              "black",
              "transparent",
            ],
            g = {
              verboseFilter: {
                DATA: 3,
                DEBUG: 3,
                INFO: 2,
                WARNING: 2,
                TEXT: 1,
                ERROR: 0,
              },
              time: null,
              verboseLevel: 0,
              setTime: function (e) {
                this.time = e;
              },
              log: function (e, t) {
                this.verboseFilter[e];
                this.verboseLevel;
              },
            },
            v = function (e) {
              for (var t = [], r = 0; r < e.length; r++)
                t.push(e[r].toString(16));
              return t;
            },
            p = (function () {
              function e(t, r, a, n, s) {
                i(this, e),
                  (this.foreground = t || "white"),
                  (this.underline = r || !1),
                  (this.italics = a || !1),
                  (this.background = n || "black"),
                  (this.flash = s || !1);
              }
              return (
                a(e, [
                  {
                    key: "reset",
                    value: function () {
                      (this.foreground = "white"),
                        (this.underline = !1),
                        (this.italics = !1),
                        (this.background = "black"),
                        (this.flash = !1);
                    },
                  },
                  {
                    key: "setStyles",
                    value: function (e) {
                      for (
                        var t = [
                          "foreground",
                          "underline",
                          "italics",
                          "background",
                          "flash",
                        ],
                        r = 0;
                        r < t.length;
                        r++
                      ) {
                        var i = t[r];
                        e.hasOwnProperty(i) && (this[i] = e[i]);
                      }
                    },
                  },
                  {
                    key: "isDefault",
                    value: function () {
                      return (
                        "white" === this.foreground &&
                        !this.underline &&
                        !this.italics &&
                        "black" === this.background &&
                        !this.flash
                      );
                    },
                  },
                  {
                    key: "equals",
                    value: function (e) {
                      return (
                        this.foreground === e.foreground &&
                        this.underline === e.underline &&
                        this.italics === e.italics &&
                        this.background === e.background &&
                        this.flash === e.flash
                      );
                    },
                  },
                  {
                    key: "copy",
                    value: function (e) {
                      (this.foreground = e.foreground),
                        (this.underline = e.underline),
                        (this.italics = e.italics),
                        (this.background = e.background),
                        (this.flash = e.flash);
                    },
                  },
                  {
                    key: "toString",
                    value: function () {
                      return (
                        "color=" +
                        this.foreground +
                        ", underline=" +
                        this.underline +
                        ", italics=" +
                        this.italics +
                        ", background=" +
                        this.background +
                        ", flash=" +
                        this.flash
                      );
                    },
                  },
                ]),
                e
              );
            })(),
            y = (function () {
              function e(t, r, a, n, s, o) {
                i(this, e),
                  (this.uchar = t || " "),
                  (this.penState = new p(r, a, n, s, o));
              }
              return (
                a(e, [
                  {
                    key: "reset",
                    value: function () {
                      (this.uchar = " "), this.penState.reset();
                    },
                  },
                  {
                    key: "setChar",
                    value: function (e, t) {
                      (this.uchar = e), this.penState.copy(t);
                    },
                  },
                  {
                    key: "setPenState",
                    value: function (e) {
                      this.penState.copy(e);
                    },
                  },
                  {
                    key: "equals",
                    value: function (e) {
                      return (
                        this.uchar === e.uchar &&
                        this.penState.equals(e.penState)
                      );
                    },
                  },
                  {
                    key: "copy",
                    value: function (e) {
                      (this.uchar = e.uchar), this.penState.copy(e.penState);
                    },
                  },
                  {
                    key: "isEmpty",
                    value: function () {
                      return " " === this.uchar && this.penState.isDefault();
                    },
                  },
                ]),
                e
              );
            })(),
            m = (function () {
              function e() {
                i(this, e), (this.chars = []);
                for (var t = 0; t < l; t++) this.chars.push(new y());
                (this.pos = 0), (this.currPenState = new p());
              }
              return (
                a(e, [
                  {
                    key: "equals",
                    value: function (e) {
                      for (var t = !0, r = 0; r < l; r++)
                        if (!this.chars[r].equals(e.chars[r])) {
                          t = !1;
                          break;
                        }
                      return t;
                    },
                  },
                  {
                    key: "copy",
                    value: function (e) {
                      for (var t = 0; t < l; t++)
                        this.chars[t].copy(e.chars[t]);
                    },
                  },
                  {
                    key: "isEmpty",
                    value: function () {
                      for (var e = !0, t = 0; t < l; t++)
                        if (!this.chars[t].isEmpty()) {
                          e = !1;
                          break;
                        }
                      return e;
                    },
                  },
                  {
                    key: "setCursor",
                    value: function (e) {
                      this.pos !== e && (this.pos = e),
                        this.pos < 0
                          ? (g.log(
                            "ERROR",
                            "Negative cursor position " + this.pos
                          ),
                            (this.pos = 0))
                          : this.pos > l &&
                          (g.log(
                            "ERROR",
                            "Too large cursor position " + this.pos
                          ),
                            (this.pos = l));
                    },
                  },
                  {
                    key: "moveCursor",
                    value: function (e) {
                      var t = this.pos + e;
                      if (e > 1)
                        for (var r = this.pos + 1; r < t + 1; r++)
                          this.chars[r].setPenState(this.currPenState);
                      this.setCursor(t);
                    },
                  },
                  {
                    key: "backSpace",
                    value: function () {
                      this.moveCursor(-1),
                        this.chars[this.pos].setChar(" ", this.currPenState);
                    },
                  },
                  {
                    key: "insertChar",
                    value: function (e) {
                      e >= 144 && this.backSpace();
                      var t = s(e);
                      if (this.pos >= l)
                        return void g.log(
                          "ERROR",
                          "Cannot insert " +
                          e.toString(16) +
                          " (" +
                          t +
                          ") at position " +
                          this.pos +
                          ". Skipping it!"
                        );
                      this.chars[this.pos].setChar(t, this.currPenState),
                        this.moveCursor(1);
                    },
                  },
                  {
                    key: "clearFromPos",
                    value: function (e) {
                      var t;
                      for (t = e; t < l; t++) this.chars[t].reset();
                    },
                  },
                  {
                    key: "clear",
                    value: function () {
                      this.clearFromPos(0),
                        (this.pos = 0),
                        this.currPenState.reset();
                    },
                  },
                  {
                    key: "clearToEndOfRow",
                    value: function () {
                      this.clearFromPos(this.pos);
                    },
                  },
                  {
                    key: "getTextString",
                    value: function () {
                      for (var e = [], t = !0, r = 0; r < l; r++) {
                        var i = this.chars[r].uchar;
                        " " !== i && (t = !1), e.push(i);
                      }
                      return t ? "" : e.join("");
                    },
                  },
                  {
                    key: "setPenStyles",
                    value: function (e) {
                      this.currPenState.setStyles(e),
                        this.chars[this.pos].setPenState(this.currPenState);
                    },
                  },
                ]),
                e
              );
            })(),
            E = (function () {
              function e() {
                i(this, e), (this.rows = []);
                for (var t = 0; t < o; t++) this.rows.push(new m());
                (this.currRow = o - 1),
                  (this.nrRollUpRows = null),
                  this.reset();
              }
              return (
                a(e, [
                  {
                    key: "reset",
                    value: function () {
                      for (var e = 0; e < o; e++) this.rows[e].clear();
                      this.currRow = o - 1;
                    },
                  },
                  {
                    key: "equals",
                    value: function (e) {
                      for (var t = !0, r = 0; r < o; r++)
                        if (!this.rows[r].equals(e.rows[r])) {
                          t = !1;
                          break;
                        }
                      return t;
                    },
                  },
                  {
                    key: "copy",
                    value: function (e) {
                      for (var t = 0; t < o; t++) this.rows[t].copy(e.rows[t]);
                    },
                  },
                  {
                    key: "isEmpty",
                    value: function () {
                      for (var e = !0, t = 0; t < o; t++)
                        if (!this.rows[t].isEmpty()) {
                          e = !1;
                          break;
                        }
                      return e;
                    },
                  },
                  {
                    key: "backSpace",
                    value: function () {
                      this.rows[this.currRow].backSpace();
                    },
                  },
                  {
                    key: "clearToEndOfRow",
                    value: function () {
                      this.rows[this.currRow].clearToEndOfRow();
                    },
                  },
                  {
                    key: "insertChar",
                    value: function (e) {
                      this.rows[this.currRow].insertChar(e);
                    },
                  },
                  {
                    key: "setPen",
                    value: function (e) {
                      this.rows[this.currRow].setPenStyles(e);
                    },
                  },
                  {
                    key: "moveCursor",
                    value: function (e) {
                      this.rows[this.currRow].moveCursor(e);
                    },
                  },
                  {
                    key: "setCursor",
                    value: function (e) {
                      g.log("INFO", "setCursor: " + e),
                        this.rows[this.currRow].setCursor(e);
                    },
                  },
                  {
                    key: "setPAC",
                    value: function (e) {
                      g.log("INFO", "pacData = " + JSON.stringify(e));
                      var t = e.row - 1;
                      if (
                        (this.nrRollUpRows &&
                          t < this.nrRollUpRows - 1 &&
                          (t = this.nrRollUpRows - 1),
                          this.nrRollUpRows && this.currRow !== t)
                      ) {
                        for (var r = 0; r < o; r++) this.rows[r].clear();
                        var i = this.currRow + 1 - this.nrRollUpRows,
                          a = this.lastOutputScreen;
                        if (a) {
                          var n = a.rows[i].cueStartTime;
                          if (n && n < g.time)
                            for (var s = 0; s < this.nrRollUpRows; s++)
                              this.rows[t - this.nrRollUpRows + s + 1].copy(
                                a.rows[i + s]
                              );
                        }
                      }
                      this.currRow = t;
                      var l = this.rows[this.currRow];
                      if (null !== e.indent) {
                        var u = e.indent,
                          d = Math.max(u - 1, 0);
                        l.setCursor(e.indent),
                          (e.color = l.chars[d].penState.foreground);
                      }
                      var f = {
                        foreground: e.color,
                        underline: e.underline,
                        italics: e.italics,
                        background: "black",
                        flash: !1,
                      };
                      this.setPen(f);
                    },
                  },
                  {
                    key: "setBkgData",
                    value: function (e) {
                      g.log("INFO", "bkgData = " + JSON.stringify(e)),
                        this.backSpace(),
                        this.setPen(e),
                        this.insertChar(32);
                    },
                  },
                  {
                    key: "setRollUpRows",
                    value: function (e) {
                      this.nrRollUpRows = e;
                    },
                  },
                  {
                    key: "rollUp",
                    value: function () {
                      if (null === this.nrRollUpRows)
                        return void g.log(
                          "DEBUG",
                          "roll_up but nrRollUpRows not set yet"
                        );
                      g.log("TEXT", this.getDisplayText());
                      var e = this.currRow + 1 - this.nrRollUpRows,
                        t = this.rows.splice(e, 1)[0];
                      t.clear(),
                        this.rows.splice(this.currRow, 0, t),
                        g.log("INFO", "Rolling up");
                    },
                  },
                  {
                    key: "getDisplayText",
                    value: function (e) {
                      e = e || !1;
                      for (var t = [], r = "", i = -1, a = 0; a < o; a++) {
                        var n = this.rows[a].getTextString();
                        n &&
                          ((i = a + 1),
                            e
                              ? t.push("Row " + i + ": '" + n + "'")
                              : t.push(n.trim()));
                      }
                      return (
                        t.length > 0 &&
                        (r = e ? "[" + t.join(" | ") + "]" : t.join("\n")),
                        r
                      );
                    },
                  },
                  {
                    key: "getTextAndFormat",
                    value: function () {
                      return this.rows;
                    },
                  },
                ]),
                e
              );
            })(),
            b = (function () {
              function e(t, r) {
                i(this, e),
                  (this.chNr = t),
                  (this.outputFilter = r),
                  (this.mode = null),
                  (this.verbose = 0),
                  (this.displayedMemory = new E()),
                  (this.nonDisplayedMemory = new E()),
                  (this.lastOutputScreen = new E()),
                  (this.currRollUpRow = this.displayedMemory.rows[o - 1]),
                  (this.writeScreen = this.displayedMemory),
                  (this.mode = null),
                  (this.cueStartTime = null);
              }
              return (
                a(e, [
                  {
                    key: "reset",
                    value: function () {
                      (this.mode = null),
                        this.displayedMemory.reset(),
                        this.nonDisplayedMemory.reset(),
                        this.lastOutputScreen.reset(),
                        (this.currRollUpRow = this.displayedMemory.rows[o - 1]),
                        (this.writeScreen = this.displayedMemory),
                        (this.mode = null),
                        (this.cueStartTime = null),
                        (this.lastCueEndTime = null);
                    },
                  },
                  {
                    key: "getHandler",
                    value: function () {
                      return this.outputFilter;
                    },
                  },
                  {
                    key: "setHandler",
                    value: function (e) {
                      this.outputFilter = e;
                    },
                  },
                  {
                    key: "setPAC",
                    value: function (e) {
                      this.writeScreen.setPAC(e);
                    },
                  },
                  {
                    key: "setBkgData",
                    value: function (e) {
                      this.writeScreen.setBkgData(e);
                    },
                  },
                  {
                    key: "setMode",
                    value: function (e) {
                      e !== this.mode &&
                        ((this.mode = e),
                          g.log("INFO", "MODE=" + e),
                          "MODE_POP-ON" === this.mode
                            ? (this.writeScreen = this.nonDisplayedMemory)
                            : ((this.writeScreen = this.displayedMemory),
                              this.writeScreen.reset()),
                          "MODE_ROLL-UP" !== this.mode &&
                          ((this.displayedMemory.nrRollUpRows = null),
                            (this.nonDisplayedMemory.nrRollUpRows = null)),
                          (this.mode = e));
                    },
                  },
                  {
                    key: "insertChars",
                    value: function (e) {
                      for (var t = 0; t < e.length; t++)
                        this.writeScreen.insertChar(e[t]);
                      var r =
                        this.writeScreen === this.displayedMemory
                          ? "DISP"
                          : "NON_DISP";
                      g.log(
                        "INFO",
                        r + ": " + this.writeScreen.getDisplayText(!0)
                      ),
                        ("MODE_PAINT-ON" !== this.mode &&
                          "MODE_ROLL-UP" !== this.mode) ||
                        (g.log(
                          "TEXT",
                          "DISPLAYED: " +
                          this.displayedMemory.getDisplayText(!0)
                        ),
                          this.outputDataUpdate());
                    },
                  },
                  {
                    key: "ccRCL",
                    value: function () {
                      g.log("INFO", "RCL - Resume Caption Loading"),
                        this.setMode("MODE_POP-ON");
                    },
                  },
                  {
                    key: "ccBS",
                    value: function () {
                      g.log("INFO", "BS - BackSpace"),
                        "MODE_TEXT" !== this.mode &&
                        (this.writeScreen.backSpace(),
                          this.writeScreen === this.displayedMemory &&
                          this.outputDataUpdate());
                    },
                  },
                  { key: "ccAOF", value: function () { } },
                  { key: "ccAON", value: function () { } },
                  {
                    key: "ccDER",
                    value: function () {
                      g.log("INFO", "DER- Delete to End of Row"),
                        this.writeScreen.clearToEndOfRow(),
                        this.outputDataUpdate();
                    },
                  },
                  {
                    key: "ccRU",
                    value: function (e) {
                      g.log("INFO", "RU(" + e + ") - Roll Up"),
                        (this.writeScreen = this.displayedMemory),
                        this.setMode("MODE_ROLL-UP"),
                        this.writeScreen.setRollUpRows(e);
                    },
                  },
                  {
                    key: "ccFON",
                    value: function () {
                      g.log("INFO", "FON - Flash On"),
                        this.writeScreen.setPen({ flash: !0 });
                    },
                  },
                  {
                    key: "ccRDC",
                    value: function () {
                      g.log("INFO", "RDC - Resume Direct Captioning"),
                        this.setMode("MODE_PAINT-ON");
                    },
                  },
                  {
                    key: "ccTR",
                    value: function () {
                      g.log("INFO", "TR"), this.setMode("MODE_TEXT");
                    },
                  },
                  {
                    key: "ccRTD",
                    value: function () {
                      g.log("INFO", "RTD"), this.setMode("MODE_TEXT");
                    },
                  },
                  {
                    key: "ccEDM",
                    value: function () {
                      g.log("INFO", "EDM - Erase Displayed Memory"),
                        this.displayedMemory.reset(),
                        this.outputDataUpdate();
                    },
                  },
                  {
                    key: "ccCR",
                    value: function () {
                      g.log("CR - Carriage Return"),
                        this.writeScreen.rollUp(),
                        this.outputDataUpdate();
                    },
                  },
                  {
                    key: "ccENM",
                    value: function () {
                      g.log("INFO", "ENM - Erase Non-displayed Memory"),
                        this.nonDisplayedMemory.reset();
                    },
                  },
                  {
                    key: "ccEOC",
                    value: function () {
                      if (
                        (g.log("INFO", "EOC - End Of Caption"),
                          "MODE_POP-ON" === this.mode)
                      ) {
                        var e = this.displayedMemory;
                        (this.displayedMemory = this.nonDisplayedMemory),
                          (this.nonDisplayedMemory = e),
                          (this.writeScreen = this.nonDisplayedMemory),
                          g.log(
                            "TEXT",
                            "DISP: " + this.displayedMemory.getDisplayText()
                          );
                      }
                      this.outputDataUpdate();
                    },
                  },
                  {
                    key: "ccTO",
                    value: function (e) {
                      g.log("INFO", "TO(" + e + ") - Tab Offset"),
                        this.writeScreen.moveCursor(e);
                    },
                  },
                  {
                    key: "ccMIDROW",
                    value: function (e) {
                      var t = { flash: !1 };
                      if (
                        ((t.underline = e % 2 == 1),
                          (t.italics = e >= 46),
                          t.italics)
                      )
                        t.foreground = "white";
                      else {
                        var r = Math.floor(e / 2) - 16,
                          i = [
                            "white",
                            "green",
                            "blue",
                            "cyan",
                            "red",
                            "yellow",
                            "magenta",
                          ];
                        t.foreground = i[r];
                      }
                      g.log("INFO", "MIDROW: " + JSON.stringify(t)),
                        this.writeScreen.setPen(t);
                    },
                  },
                  {
                    key: "outputDataUpdate",
                    value: function () {
                      var e = g.time;
                      null !== e &&
                        this.outputFilter &&
                        (this.outputFilter.updateData &&
                          this.outputFilter.updateData(e, this.displayedMemory),
                          null !== this.cueStartTime ||
                            this.displayedMemory.isEmpty()
                            ? this.displayedMemory.equals(
                              this.lastOutputScreen
                            ) ||
                            (this.outputFilter.newCue &&
                              this.outputFilter.newCue(
                                this.cueStartTime,
                                e,
                                this.lastOutputScreen
                              ),
                              (this.cueStartTime = this.displayedMemory.isEmpty()
                                ? null
                                : e))
                            : (this.cueStartTime = e),
                          this.lastOutputScreen.copy(this.displayedMemory));
                    },
                  },
                  {
                    key: "cueSplitAtTime",
                    value: function (e) {
                      this.outputFilter &&
                        (this.displayedMemory.isEmpty() ||
                          (this.outputFilter.newCue &&
                            this.outputFilter.newCue(
                              this.cueStartTime,
                              e,
                              this.displayedMemory
                            ),
                            (this.cueStartTime = e)));
                    },
                  },
                ]),
                e
              );
            })(),
            T = (function () {
              function e(t, r, a) {
                i(this, e),
                  (this.field = t || 1),
                  (this.outputs = [r, a]),
                  (this.channels = [new b(1, r), new b(2, a)]),
                  (this.currChNr = -1),
                  (this.lastCmdA = null),
                  (this.lastCmdB = null),
                  (this.bufferedData = []),
                  (this.startTime = null),
                  (this.lastTime = null),
                  (this.dataCounters = {
                    padding: 0,
                    char: 0,
                    cmd: 0,
                    other: 0,
                  });
              }
              return (
                a(e, [
                  {
                    key: "getHandler",
                    value: function (e) {
                      return this.channels[e].getHandler();
                    },
                  },
                  {
                    key: "setHandler",
                    value: function (e, t) {
                      this.channels[e].setHandler(t);
                    },
                  },
                  {
                    key: "addData",
                    value: function (e, t) {
                      var r,
                        i,
                        a,
                        n = !1;
                      (this.lastTime = e), g.setTime(e);
                      for (var s = 0; s < t.length; s += 2)
                        if (
                          ((i = 127 & t[s]),
                            (a = 127 & t[s + 1]),
                            0 !== i || 0 !== a)
                        ) {
                          if (
                            (g.log(
                              "DATA",
                              "[" +
                              v([t[s], t[s + 1]]) +
                              "] -> (" +
                              v([i, a]) +
                              ")"
                            ),
                              (r = this.parseCmd(i, a)),
                              r || (r = this.parseMidrow(i, a)),
                              r || (r = this.parsePAC(i, a)),
                              r || (r = this.parseBackgroundAttributes(i, a)),
                              !r && (n = this.parseChars(i, a)))
                          )
                            if (this.currChNr && this.currChNr >= 0) {
                              var o = this.channels[this.currChNr - 1];
                              o.insertChars(n);
                            } else
                              g.log(
                                "WARNING",
                                "No channel found yet. TEXT-MODE?"
                              );
                          r
                            ? (this.dataCounters.cmd += 2)
                            : n
                              ? (this.dataCounters.char += 2)
                              : ((this.dataCounters.other += 2),
                                g.log(
                                  "WARNING",
                                  "Couldn't parse cleaned data " +
                                  v([i, a]) +
                                  " orig: " +
                                  v([t[s], t[s + 1]])
                                ));
                        } else this.dataCounters.padding += 2;
                    },
                  },
                  {
                    key: "parseCmd",
                    value: function (e, t) {
                      var r = null,
                        i = (20 === e || 28 === e) && 32 <= t && t <= 47,
                        a = (23 === e || 31 === e) && 33 <= t && t <= 35;
                      if (!i && !a) return !1;
                      if (e === this.lastCmdA && t === this.lastCmdB)
                        return (
                          (this.lastCmdA = null),
                          (this.lastCmdB = null),
                          g.log(
                            "DEBUG",
                            "Repeated command (" + v([e, t]) + ") is dropped"
                          ),
                          !0
                        );
                      r = 20 === e || 23 === e ? 1 : 2;
                      var n = this.channels[r - 1];
                      return (
                        20 === e || 28 === e
                          ? 32 === t
                            ? n.ccRCL()
                            : 33 === t
                              ? n.ccBS()
                              : 34 === t
                                ? n.ccAOF()
                                : 35 === t
                                  ? n.ccAON()
                                  : 36 === t
                                    ? n.ccDER()
                                    : 37 === t
                                      ? n.ccRU(2)
                                      : 38 === t
                                        ? n.ccRU(3)
                                        : 39 === t
                                          ? n.ccRU(4)
                                          : 40 === t
                                            ? n.ccFON()
                                            : 41 === t
                                              ? n.ccRDC()
                                              : 42 === t
                                                ? n.ccTR()
                                                : 43 === t
                                                  ? n.ccRTD()
                                                  : 44 === t
                                                    ? n.ccEDM()
                                                    : 45 === t
                                                      ? n.ccCR()
                                                      : 46 === t
                                                        ? n.ccENM()
                                                        : 47 === t && n.ccEOC()
                          : n.ccTO(t - 32),
                        (this.lastCmdA = e),
                        (this.lastCmdB = t),
                        (this.currChNr = r),
                        !0
                      );
                    },
                  },
                  {
                    key: "parseMidrow",
                    value: function (e, t) {
                      var r = null;
                      if ((17 === e || 25 === e) && 32 <= t && t <= 47) {
                        if ((r = 17 === e ? 1 : 2) !== this.currChNr)
                          return (
                            g.log(
                              "ERROR",
                              "Mismatch channel in midrow parsing"
                            ),
                            !1
                          );
                        return (
                          this.channels[r - 1].ccMIDROW(t),
                          g.log("DEBUG", "MIDROW (" + v([e, t]) + ")"),
                          !0
                        );
                      }
                      return !1;
                    },
                  },
                  {
                    key: "parsePAC",
                    value: function (e, t) {
                      var r = null,
                        i = null,
                        a =
                          ((17 <= e && e <= 23) || (25 <= e && e <= 31)) &&
                          64 <= t &&
                          t <= 127,
                        n = (16 === e || 24 === e) && 64 <= t && t <= 95;
                      if (!a && !n) return !1;
                      if (e === this.lastCmdA && t === this.lastCmdB)
                        return (
                          (this.lastCmdA = null), (this.lastCmdB = null), !0
                        );
                      (r = e <= 23 ? 1 : 2),
                        (i =
                          64 <= t && t <= 95
                            ? 1 === r
                              ? u[e]
                              : f[e]
                            : 1 === r
                              ? d[e]
                              : c[e]);
                      var s = this.interpretPAC(i, t);
                      return (
                        this.channels[r - 1].setPAC(s),
                        (this.lastCmdA = e),
                        (this.lastCmdB = t),
                        (this.currChNr = r),
                        !0
                      );
                    },
                  },
                  {
                    key: "interpretPAC",
                    value: function (e, t) {
                      var r = t,
                        i = {
                          color: null,
                          italics: !1,
                          indent: null,
                          underline: !1,
                          row: e,
                        };
                      return (
                        (r = t > 95 ? t - 96 : t - 64),
                        (i.underline = 1 == (1 & r)),
                        r <= 13
                          ? (i.color = [
                            "white",
                            "green",
                            "blue",
                            "cyan",
                            "red",
                            "yellow",
                            "magenta",
                            "white",
                          ][Math.floor(r / 2)])
                          : r <= 15
                            ? ((i.italics = !0), (i.color = "white"))
                            : (i.indent = 4 * Math.floor((r - 16) / 2)),
                        i
                      );
                    },
                  },
                  {
                    key: "parseChars",
                    value: function (e, t) {
                      var r = null,
                        i = null,
                        a = null;
                      if (
                        (e >= 25 ? ((r = 2), (a = e - 8)) : ((r = 1), (a = e)),
                          17 <= a && a <= 19)
                      ) {
                        var n = t;
                        (n = 17 === a ? t + 80 : 18 === a ? t + 112 : t + 144),
                          g.log(
                            "INFO",
                            "Special char '" + s(n) + "' in channel " + r
                          ),
                          (i = [n]);
                      } else
                        32 <= e && e <= 127 && (i = 0 === t ? [e] : [e, t]);
                      if (i) {
                        var o = v(i);
                        g.log("DEBUG", "Char codes =  " + o.join(",")),
                          (this.lastCmdA = null),
                          (this.lastCmdB = null);
                      }
                      return i;
                    },
                  },
                  {
                    key: "parseBackgroundAttributes",
                    value: function (e, t) {
                      var r,
                        i,
                        a,
                        n,
                        s = (16 === e || 24 === e) && 32 <= t && t <= 47,
                        o = (23 === e || 31 === e) && 45 <= t && t <= 47;
                      return (
                        !(!s && !o) &&
                        ((r = {}),
                          16 === e || 24 === e
                            ? ((i = Math.floor((t - 32) / 2)),
                              (r.background = h[i]),
                              t % 2 == 1 &&
                              (r.background = r.background + "_semi"))
                            : 45 === t
                              ? (r.background = "transparent")
                              : ((r.foreground = "black"),
                                47 === t && (r.underline = !0)),
                          (a = e < 24 ? 1 : 2),
                          (n = this.channels[a - 1]),
                          n.setBkgData(r),
                          (this.lastCmdA = null),
                          (this.lastCmdB = null),
                          !0)
                      );
                    },
                  },
                  {
                    key: "reset",
                    value: function () {
                      for (var e = 0; e < this.channels.length; e++)
                        this.channels[e] && this.channels[e].reset();
                      (this.lastCmdA = null), (this.lastCmdB = null);
                    },
                  },
                  {
                    key: "cueSplitAtTime",
                    value: function (e) {
                      for (var t = 0; t < this.channels.length; t++)
                        this.channels[t] && this.channels[t].cueSplitAtTime(e);
                    },
                  },
                ]),
                e
              );
            })();
          r.default = T;
        },
        {},
      ],
      48: [
        function (e, t, r) {
          "use strict";
          var i = e(54),
            a = {
              newCue: function (e, t, r, a) {
                for (
                  var n,
                  s,
                  o,
                  l,
                  u,
                  d = window.VTTCue || window.TextTrackCue,
                  f = 0;
                  f < a.rows.length;
                  f++
                )
                  if (
                    ((n = a.rows[f]), (o = !0), (l = 0), (u = ""), !n.isEmpty())
                  ) {
                    for (var c = 0; c < n.chars.length; c++)
                      n.chars[c].uchar.match(/\s/) && o
                        ? l++
                        : ((u += n.chars[c].uchar), (o = !1));
                    (n.cueStartTime = t),
                      t === r && (r += 1e-4),
                      (s = new d(t, r, (0, i.fixLineBreaks)(u.trim()))),
                      l >= 16 ? l-- : l++,
                      navigator.userAgent.match(/Firefox\//)
                        ? (s.line = f + 1)
                        : (s.line = f > 7 ? f - 2 : f + 1),
                      (s.align = "left"),
                      (s.position = Math.max(
                        0,
                        Math.min(
                          100,
                          (l / 32) * 100 +
                          (navigator.userAgent.match(/Firefox\//) ? 50 : 0)
                        )
                      )),
                      e.addCue(s);
                  }
              },
            };
          t.exports = a;
        },
        { 54: 54 },
      ],
      49: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(50),
            s = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(n),
            o = (function () {
              function e(t, r, a, n) {
                i(this, e),
                  (this.hls = t),
                  (this.defaultEstimate_ = n),
                  (this.minWeight_ = 0.001),
                  (this.minDelayMs_ = 50),
                  (this.slow_ = new s.default(r)),
                  (this.fast_ = new s.default(a));
              }
              return (
                a(e, [
                  {
                    key: "sample",
                    value: function (e, t) {
                      e = Math.max(e, this.minDelayMs_);
                      var r = (8e3 * t) / e,
                        i = e / 1e3;
                      this.fast_.sample(i, r), this.slow_.sample(i, r);
                    },
                  },
                  {
                    key: "canEstimate",
                    value: function () {
                      var e = this.fast_;
                      return e && e.getTotalWeight() >= this.minWeight_;
                    },
                  },
                  {
                    key: "getEstimate",
                    value: function () {
                      return this.canEstimate()
                        ? Math.min(
                          this.fast_.getEstimate(),
                          this.slow_.getEstimate()
                        )
                        : this.defaultEstimate_;
                    },
                  },
                  { key: "destroy", value: function () { } },
                ]),
                e
              );
            })();
          r.default = o;
        },
        { 50: 50 },
      ],
      50: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = (function () {
              function e(t) {
                i(this, e),
                  (this.alpha_ = t ? Math.exp(Math.log(0.5) / t) : 0),
                  (this.estimate_ = 0),
                  (this.totalWeight_ = 0);
              }
              return (
                a(e, [
                  {
                    key: "sample",
                    value: function (e, t) {
                      var r = Math.pow(this.alpha_, e);
                      (this.estimate_ = t * (1 - r) + r * this.estimate_),
                        (this.totalWeight_ += e);
                    },
                  },
                  {
                    key: "getTotalWeight",
                    value: function () {
                      return this.totalWeight_;
                    },
                  },
                  {
                    key: "getEstimate",
                    value: function () {
                      if (this.alpha_) {
                        var e = 1 - Math.pow(this.alpha_, this.totalWeight_);
                        return this.estimate_ / e;
                      }
                      return this.estimate_;
                    },
                  },
                ]),
                e
              );
            })();
          r.default = n;
        },
        {},
      ],
      51: [
        function (e, t, r) {
          "use strict";
          function i() { }
          function a(e, t) {
            return (t = "[" + e + "] > " + t);
          }
          function n(e) {
            var t = self.console[e];
            return t
              ? function () {
                for (
                  var r = arguments.length, i = Array(r), n = 0;
                  n < r;
                  n++
                )
                  i[n] = arguments[n];
                i[0] && (i[0] = a(e, i[0])), t.apply(self.console, i);
              }
              : i;
          }
          function s(e) {
            for (
              var t = arguments.length, r = Array(t > 1 ? t - 1 : 0), i = 1;
              i < t;
              i++
            )
              r[i - 1] = arguments[i];
            r.forEach(function (t) {
              u[t] = e[t] ? e[t].bind(e) : n(t);
            });
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var o =
            "function" == typeof Symbol && "symbol" == typeof Symbol.iterator
              ? function (e) {
                return typeof e;
              }
              : function (e) {
                return e &&
                  "function" == typeof Symbol &&
                  e.constructor === Symbol &&
                  e !== Symbol.prototype
                  ? "symbol"
                  : typeof e;
              },
            l = { trace: i, debug: i, log: i, warn: i, info: i, error: i },
            u = l;
          (r.enableLogs = function (e) {
            if (e === !0 || "object" === (void 0 === e ? "undefined" : o(e))) {
              s(e, "debug", "log", "info", "warn", "error");
              try {
                u.log();
              } catch (e) {
                u = l;
              }
            } else u = l;
          }),
            (r.logger = u);
        },
        {},
      ],
      52: [
        function (e, t, r) {
          "use strict";
          var i = {
            toString: function (e) {
              for (var t = "", r = e.length, i = 0; i < r; i++)
                t +=
                  "[" + e.start(i).toFixed(3) + "," + e.end(i).toFixed(3) + "]";
              return t;
            },
          };
          t.exports = i;
        },
        {},
      ],
      53: [
        function (e, t, r) {
          "use strict";
          Object.defineProperty(r, "__esModule", { value: !0 }),
            (r.default = (function () {
              function e(e) {
                return (
                  "string" == typeof e &&
                  !!n[e.toLowerCase()] &&
                  e.toLowerCase()
                );
              }
              function t(e) {
                return (
                  "string" == typeof e &&
                  !!s[e.toLowerCase()] &&
                  e.toLowerCase()
                );
              }
              function r(e) {
                for (var t = 1; t < arguments.length; t++) {
                  var r = arguments[t];
                  for (var i in r) e[i] = r[i];
                }
                return e;
              }
              function i(i, n, s) {
                var o = this,
                  l = (function () {
                    if ("undefined" != typeof navigator)
                      return /MSIE\s8\.0/.test(navigator.userAgent);
                  })(),
                  u = {};
                l
                  ? (o = document.createElement("custom"))
                  : (u.enumerable = !0),
                  (o.hasBeenReset = !1);
                var d = "",
                  f = !1,
                  c = i,
                  h = n,
                  g = s,
                  v = null,
                  p = "",
                  y = !0,
                  m = "auto",
                  E = "start",
                  b = 50,
                  T = "middle",
                  _ = 50,
                  k = "middle";
                if (
                  (Object.defineProperty(
                    o,
                    "id",
                    r({}, u, {
                      get: function () {
                        return d;
                      },
                      set: function (e) {
                        d = "" + e;
                      },
                    })
                  ),
                    Object.defineProperty(
                      o,
                      "pauseOnExit",
                      r({}, u, {
                        get: function () {
                          return f;
                        },
                        set: function (e) {
                          f = !!e;
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "startTime",
                      r({}, u, {
                        get: function () {
                          return c;
                        },
                        set: function (e) {
                          if ("number" != typeof e)
                            throw new TypeError(
                              "Start time must be set to a number."
                            );
                          (c = e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "endTime",
                      r({}, u, {
                        get: function () {
                          return h;
                        },
                        set: function (e) {
                          if ("number" != typeof e)
                            throw new TypeError(
                              "End time must be set to a number."
                            );
                          (h = e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "text",
                      r({}, u, {
                        get: function () {
                          return g;
                        },
                        set: function (e) {
                          (g = "" + e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "region",
                      r({}, u, {
                        get: function () {
                          return v;
                        },
                        set: function (e) {
                          (v = e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "vertical",
                      r({}, u, {
                        get: function () {
                          return p;
                        },
                        set: function (t) {
                          var r = e(t);
                          if (r === !1)
                            throw new SyntaxError(
                              "An invalid or illegal string was specified."
                            );
                          (p = r), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "snapToLines",
                      r({}, u, {
                        get: function () {
                          return y;
                        },
                        set: function (e) {
                          (y = !!e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "line",
                      r({}, u, {
                        get: function () {
                          return m;
                        },
                        set: function (e) {
                          if ("number" != typeof e && e !== a)
                            throw new SyntaxError(
                              "An invalid number or illegal string was specified."
                            );
                          (m = e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "lineAlign",
                      r({}, u, {
                        get: function () {
                          return E;
                        },
                        set: function (e) {
                          var r = t(e);
                          if (!r)
                            throw new SyntaxError(
                              "An invalid or illegal string was specified."
                            );
                          (E = r), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "position",
                      r({}, u, {
                        get: function () {
                          return b;
                        },
                        set: function (e) {
                          if (e < 0 || e > 100)
                            throw new Error(
                              "Position must be between 0 and 100."
                            );
                          (b = e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "positionAlign",
                      r({}, u, {
                        get: function () {
                          return T;
                        },
                        set: function (e) {
                          var r = t(e);
                          if (!r)
                            throw new SyntaxError(
                              "An invalid or illegal string was specified."
                            );
                          (T = r), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "size",
                      r({}, u, {
                        get: function () {
                          return _;
                        },
                        set: function (e) {
                          if (e < 0 || e > 100)
                            throw new Error("Size must be between 0 and 100.");
                          (_ = e), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    Object.defineProperty(
                      o,
                      "align",
                      r({}, u, {
                        get: function () {
                          return k;
                        },
                        set: function (e) {
                          var r = t(e);
                          if (!r)
                            throw new SyntaxError(
                              "An invalid or illegal string was specified."
                            );
                          (k = r), (this.hasBeenReset = !0);
                        },
                      })
                    ),
                    (o.displayState = void 0),
                    l)
                )
                  return o;
              }
              if ("undefined" != typeof window && window.VTTCue)
                return window.VTTCue;
              var a = "auto",
                n = { "": !0, lr: !0, rl: !0 },
                s = { start: !0, middle: !0, end: !0, left: !0, right: !0 };
              return (
                (i.prototype.getCueAsHTML = function () {
                  return window.WebVTT.convertCueToDOMTree(window, this.text);
                }),
                i
              );
            })());
        },
        {},
      ],
      54: [
        function (e, t, r) {
          "use strict";
          function i() {
            (this.window = window),
              (this.state = "INITIAL"),
              (this.buffer = ""),
              (this.decoder = new f()),
              (this.regionList = []);
          }
          function a(e) {
            function t(e, t, r, i) {
              return 3600 * (0 | e) + 60 * (0 | t) + (0 | r) + (0 | i) / 1e3;
            }
            var r = e.match(/^(\d+):(\d{2})(:\d{2})?\.(\d{3})/);
            return r
              ? r[3]
                ? t(r[1], r[2], r[3].replace(":", ""), r[4])
                : r[1] > 59
                  ? t(r[1], r[2], 0, r[4])
                  : t(0, r[1], r[2], r[4])
              : null;
          }
          function n() {
            this.values = Object.create(null);
          }
          function s(e, t, r, i) {
            var a = i ? e.split(i) : [e];
            for (var n in a)
              if ("string" == typeof a[n]) {
                var s = a[n].split(r);
                if (2 === s.length) {
                  var o = s[0],
                    l = s[1];
                  t(o, l);
                }
              }
          }
          function o(e, t, r) {
            function i() {
              var t = a(e);
              if (null === t) throw new Error("Malformed timestamp: " + l);
              return (e = e.replace(/^[^\sa-zA-Z-]+/, "")), t;
            }
            function o() {
              e = e.replace(/^\s+/, "");
            }
            var l = e;
            if ((o(), (t.startTime = i()), o(), "-->" !== e.substr(0, 3)))
              throw new Error(
                "Malformed time stamp (time stamps must be separated by '-->'): " +
                l
              );
            (e = e.substr(3)),
              o(),
              (t.endTime = i()),
              o(),
              (function (e, t) {
                var i = new n();
                s(
                  e,
                  function (e, t) {
                    switch (e) {
                      case "region":
                        for (var a = r.length - 1; a >= 0; a--)
                          if (r[a].id === t) {
                            i.set(e, r[a].region);
                            break;
                          }
                        break;
                      case "vertical":
                        i.alt(e, t, ["rl", "lr"]);
                        break;
                      case "line":
                        var n = t.split(","),
                          s = n[0];
                        i.integer(e, s),
                          i.percent(e, s) && i.set("snapToLines", !1),
                          i.alt(e, s, ["auto"]),
                          2 === n.length &&
                          i.alt("lineAlign", n[1], ["start", h, "end"]);
                        break;
                      case "position":
                        (n = t.split(",")),
                          i.percent(e, n[0]),
                          2 === n.length &&
                          i.alt("positionAlign", n[1], [
                            "start",
                            h,
                            "end",
                            "line-left",
                            "line-right",
                            "auto",
                          ]);
                        break;
                      case "size":
                        i.percent(e, t);
                        break;
                      case "align":
                        i.alt(e, t, ["start", h, "end", "left", "right"]);
                    }
                  },
                  /:/,
                  /\s/
                ),
                  (t.region = i.get("region", null)),
                  (t.vertical = i.get("vertical", ""));
                var a = i.get("line", "auto");
                "auto" === a && c.line === -1 && (a = -1),
                  (t.line = a),
                  (t.lineAlign = i.get("lineAlign", "start")),
                  (t.snapToLines = i.get("snapToLines", !0)),
                  (t.size = i.get("size", 100)),
                  (t.align = i.get("align", h));
                var o = i.get("position", "auto");
                "auto" === o &&
                  50 === c.position &&
                  (o =
                    "start" === t.align || "left" === t.align
                      ? 0
                      : "end" === t.align || "right" === t.align
                        ? 100
                        : 50),
                  (t.position = o);
              })(e, t);
          }
          function l(e) {
            return e.replace(/<br(?: \/)?>/gi, "\n");
          }
          Object.defineProperty(r, "__esModule", { value: !0 }),
            (r.fixLineBreaks = void 0);
          var u = e(53),
            d = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(u),
            f = function () {
              return {
                decode: function (e) {
                  if (!e) return "";
                  if ("string" != typeof e)
                    throw new Error("Error - expected string data.");
                  return decodeURIComponent(encodeURIComponent(e));
                },
              };
            };
          n.prototype = {
            set: function (e, t) {
              this.get(e) || "" === t || (this.values[e] = t);
            },
            get: function (e, t, r) {
              return r
                ? this.has(e)
                  ? this.values[e]
                  : t[r]
                : this.has(e)
                  ? this.values[e]
                  : t;
            },
            has: function (e) {
              return e in this.values;
            },
            alt: function (e, t, r) {
              for (var i = 0; i < r.length; ++i)
                if (t === r[i]) {
                  this.set(e, t);
                  break;
                }
            },
            integer: function (e, t) {
              /^-?\d+$/.test(t) && this.set(e, parseInt(t, 10));
            },
            percent: function (e, t) {
              return (
                !!(
                  t.match(/^([\d]{1,3})(\.[\d]*)?%$/) &&
                  (t = parseFloat(t)) >= 0 &&
                  t <= 100
                ) && (this.set(e, t), !0)
              );
            },
          };
          var c = new d.default(0, 0, 0),
            h = "middle" === c.align ? "middle" : "center";
          (i.prototype = {
            parse: function (e) {
              function t() {
                var e = r.buffer,
                  t = 0;
                for (e = l(e); t < e.length && "\r" !== e[t] && "\n" !== e[t];)
                  ++t;
                var i = e.substr(0, t);
                return (
                  "\r" === e[t] && ++t,
                  "\n" === e[t] && ++t,
                  (r.buffer = e.substr(t)),
                  i
                );
              }
              var r = this;
              e && (r.buffer += r.decoder.decode(e, { stream: !0 }));
              try {
                var i;
                if ("INITIAL" === r.state) {
                  if (!/\r\n|\n/.test(r.buffer)) return this;
                  i = t();
                  var a = i.match(/^WEBVTT([ \t].*)?$/);
                  if (!a || !a[0])
                    throw new Error("Malformed WebVTT signature.");
                  r.state = "HEADER";
                }
                for (var n = !1; r.buffer;) {
                  if (!/\r\n|\n/.test(r.buffer)) return this;
                  switch ((n ? (n = !1) : (i = t()), r.state)) {
                    case "HEADER":
                      /:/.test(i)
                        ? (function (e) {
                          s(
                            e,
                            function (e, t) {
                              switch (e) {
                                case "Region":
                              }
                            },
                            /:/
                          );
                        })(i)
                        : i || (r.state = "ID");
                      continue;
                    case "NOTE":
                      i || (r.state = "ID");
                      continue;
                    case "ID":
                      if (/^NOTE($|[ \t])/.test(i)) {
                        r.state = "NOTE";
                        break;
                      }
                      if (!i) continue;
                      if (
                        ((r.cue = new d.default(0, 0, "")),
                          (r.state = "CUE"),
                          i.indexOf("-->") === -1)
                      ) {
                        r.cue.id = i;
                        continue;
                      }
                    case "CUE":
                      try {
                        o(i, r.cue, r.regionList);
                      } catch (e) {
                        (r.cue = null), (r.state = "BADCUE");
                        continue;
                      }
                      r.state = "CUETEXT";
                      continue;
                    case "CUETEXT":
                      var u = i.indexOf("-->") !== -1;
                      if (!i || (u && (n = !0))) {
                        r.oncue && r.oncue(r.cue),
                          (r.cue = null),
                          (r.state = "ID");
                        continue;
                      }
                      r.cue.text && (r.cue.text += "\n"), (r.cue.text += i);
                      continue;
                    case "BADCUE":
                      i || (r.state = "ID");
                      continue;
                  }
                }
              } catch (e) {
                "CUETEXT" === r.state && r.cue && r.oncue && r.oncue(r.cue),
                  (r.cue = null),
                  (r.state = "INITIAL" === r.state ? "BADWEBVTT" : "BADCUE");
              }
              return this;
            },
            flush: function () {
              var e = this;
              try {
                if (
                  ((e.buffer += e.decoder.decode()),
                    (e.cue || "HEADER" === e.state) &&
                    ((e.buffer += "\n\n"), e.parse()),
                    "INITIAL" === e.state)
                )
                  throw new Error("Malformed WebVTT signature.");
              } catch (e) {
                throw e;
              }
              return e.onflush && e.onflush(), this;
            },
          }),
            (r.fixLineBreaks = l),
            (r.default = i);
        },
        { 53: 53 },
      ],
      55: [
        function (e, t, r) {
          "use strict";
          var i = e(54),
            a = (function (e) {
              return e && e.__esModule ? e : { default: e };
            })(i),
            n = function (e) {
              var t = parseInt(e.substr(-3)),
                r = parseInt(e.substr(-6, 2)),
                i = parseInt(e.substr(-9, 2)),
                a = e.length > 9 ? parseInt(e.substr(0, e.indexOf(":"))) : 0;
              return isNaN(t) || isNaN(r) || isNaN(i) || isNaN(a)
                ? -1
                : ((t += 1e3 * r), (t += 6e4 * i), (t += 36e5 * a));
            },
            s = function (e, t, r) {
              var i = e[t],
                a = e[i.prevCC];
              if (!a || (!a.new && i.new))
                return (
                  (e.ccOffset = e.presentationOffset = i.start),
                  void (i.new = !1)
                );
              for (; a && a.new;)
                (e.ccOffset += i.start - a.start),
                  (i.new = !1),
                  (i = a),
                  (a = e[i.prevCC]);
              e.presentationOffset = r;
            },
            o = {
              parse: function (e, t, r, i, o, l) {
                var u = String.fromCharCode
                  .apply(null, new Uint8Array(e))
                  .trim()
                  .replace(/\r\n|\n\r|\n|\r/g, "\n")
                  .split("\n"),
                  d = "00:00.000",
                  f = 0,
                  c = 0,
                  h = 0,
                  g = [],
                  v = void 0,
                  p = !0,
                  y = new a.default();
                (y.oncue = function (e) {
                  var t = r[i],
                    a = r.ccOffset;
                  t && t.new && (c ? (a = r.ccOffset = t.start) : s(r, i, h)),
                    h && !c && (a = h + r.ccOffset - r.presentationOffset),
                    (e.startTime += a - c),
                    (e.endTime += a - c),
                    (e.text = decodeURIComponent(escape(e.text))),
                    e.endTime > 0 && g.push(e);
                }),
                  (y.onparsingerror = function (e) {
                    v = e;
                  }),
                  (y.onflush = function () {
                    if (v && l) return void l(v);
                    o(g);
                  }),
                  u.forEach(function (e) {
                    if (p) {
                      if (e.startsWith("X-TIMESTAMP-MAP=")) {
                        (p = !1),
                          e
                            .substr(16)
                            .split(",")
                            .forEach(function (e) {
                              e.startsWith("LOCAL:")
                                ? (d = e.substr(6))
                                : e.startsWith("MPEGTS:") &&
                                (f = parseInt(e.substr(7)));
                            });
                        try {
                          (t = t < 0 ? t + 8589934592 : t),
                            (f -= t),
                            (c = n(d) / 1e3),
                            (h = f / 9e4),
                            c === -1 &&
                            (v = new Error(
                              "Malformed X-TIMESTAMP-MAP: " + e
                            ));
                        } catch (t) {
                          v = new Error("Malformed X-TIMESTAMP-MAP: " + e);
                        }
                        return;
                      }
                      "" === e && (p = !1);
                    }
                    y.parse(e + "\n");
                  }),
                  y.flush();
              },
            };
          t.exports = o;
        },
        { 54: 54 },
      ],
      56: [
        function (e, t, r) {
          "use strict";
          function i(e, t) {
            if (!(e instanceof t))
              throw new TypeError("Cannot call a class as a function");
          }
          Object.defineProperty(r, "__esModule", { value: !0 });
          var a = (function () {
            function e(e, t) {
              for (var r = 0; r < t.length; r++) {
                var i = t[r];
                (i.enumerable = i.enumerable || !1),
                  (i.configurable = !0),
                  "value" in i && (i.writable = !0),
                  Object.defineProperty(e, i.key, i);
              }
            }
            return function (t, r, i) {
              return r && e(t.prototype, r), i && e(t, i), t;
            };
          })(),
            n = e(51),
            s = (function () {
              function e(t) {
                i(this, e), t && t.xhrSetup && (this.xhrSetup = t.xhrSetup);
              }
              return (
                a(e, [
                  {
                    key: "destroy",
                    value: function () {
                      this.abort(), (this.loader = null);
                    },
                  },
                  {
                    key: "abort",
                    value: function () {
                      var e = this.loader;
                      e &&
                        4 !== e.readyState &&
                        ((this.stats.aborted = !0), e.abort()),
                        window.clearTimeout(this.requestTimeout),
                        (this.requestTimeout = null),
                        window.clearTimeout(this.retryTimeout),
                        (this.retryTimeout = null);
                    },
                  },
                  {
                    key: "load",
                    value: function (e, t, r) {
                      (this.context = e),
                        (this.config = t),
                        (this.callbacks = r),
                        (this.stats = {
                          trequest: performance.now(),
                          retry: 0,
                        }),
                        (this.retryDelay = t.retryDelay),
                        this.loadInternal();
                    },
                  },
                  {
                    key: "loadInternal",
                    value: function () {
                      var e,
                        t = this.context;
                      e =
                        "undefined" != typeof XDomainRequest
                          ? (this.loader = new XDomainRequest())
                          : (this.loader = new XMLHttpRequest());
                      var r = this.stats;
                      (r.tfirst = 0), (r.loaded = 0);
                      var i = this.xhrSetup;
                      if (i)
                        try {
                          i(e, t.url);
                        } catch (r) {
                          e.open("GET", t.url, !0), i(e, t.url);
                        }
                      e.readyState || e.open("GET", t.url, !0),
                        t.rangeEnd &&
                        e.setRequestHeader(
                          "Range",
                          "bytes=" + t.rangeStart + "-" + (t.rangeEnd - 1)
                        ),
                        (e.onreadystatechange =
                          this.readystatechange.bind(this)),
                        (e.onprogress = this.loadprogress.bind(this)),
                        (e.responseType = t.responseType),
                        (this.requestTimeout = window.setTimeout(
                          this.loadtimeout.bind(this),
                          this.config.timeout
                        )),
                        e.send();
                    },
                  },
                  {
                    key: "readystatechange",
                    value: function (e) {
                      var t = e.currentTarget,
                        r = t.readyState,
                        i = this.stats,
                        a = this.context,
                        s = this.config;
                      if (!i.aborted && r >= 2)
                        if (
                          (window.clearTimeout(this.requestTimeout),
                            0 === i.tfirst &&
                            (i.tfirst = Math.max(
                              performance.now(),
                              i.trequest
                            )),
                            4 === r)
                        ) {
                          var o = t.status;
                          if (o >= 200 && o < 300) {
                            i.tload = Math.max(i.tfirst, performance.now());
                            var l = void 0,
                              u = void 0;
                            "arraybuffer" === a.responseType
                              ? ((l = t.response), (u = l.byteLength))
                              : ((l = t.responseText), (u = l.length)),
                              (i.loaded = i.total = u);
                            var d = { url: t.responseURL, data: l };
                            this.callbacks.onSuccess(d, i, a);
                          } else
                            i.retry >= s.maxRetry || (o >= 400 && o < 499)
                              ? (n.logger.error(o + " while loading " + a.url),
                                this.callbacks.onError(
                                  { code: o, text: t.statusText },
                                  a
                                ))
                              : (n.logger.warn(
                                o +
                                " while loading " +
                                a.url +
                                ", retrying in " +
                                this.retryDelay +
                                "..."
                              ),
                                this.destroy(),
                                (this.retryTimeout = window.setTimeout(
                                  this.loadInternal.bind(this),
                                  this.retryDelay
                                )),
                                (this.retryDelay = Math.min(
                                  2 * this.retryDelay,
                                  s.maxRetryDelay
                                )),
                                i.retry++);
                        } else
                          this.requestTimeout = window.setTimeout(
                            this.loadtimeout.bind(this),
                            s.timeout
                          );
                    },
                  },
                  {
                    key: "loadtimeout",
                    value: function () {
                      n.logger.warn(
                        "timeout while loading " + this.context.url
                      ),
                        this.callbacks.onTimeout(this.stats, this.context);
                    },
                  },
                  {
                    key: "loadprogress",
                    value: function (e) {
                      var t = this.stats;
                      (t.loaded = e.loaded),
                        e.lengthComputable && (t.total = e.total);
                      var r = this.callbacks.onProgress;
                      r && r(t, this.context, null);
                    },
                  },
                ]),
                e
              );
            })();
          r.default = s;
        },
        { 51: 51 },
      ],
    },
    {},
    [38]
  )(38);
});
/**
 * Swiper 8.0.6
 * Most modern mobile touch slider and framework with hardware accelerated transitions
 * https://swiperjs.com
 *
 * Copyright 2014-2022 Vladimir Kharlampidi
 *
 * Released under the MIT License
 *
 * Released on: February 14, 2022
 */

!(function (e, t) {
  "object" == typeof exports && "undefined" != typeof module
    ? (module.exports = t())
    : "function" == typeof define && define.amd
      ? define(t)
      : ((e = "undefined" != typeof globalThis ? globalThis : e || self).Swiper =
        t());
})(this, function () {
  "use strict";
  function e(e) {
    return (
      null !== e &&
      "object" == typeof e &&
      "constructor" in e &&
      e.constructor === Object
    );
  }
  function t(s, a) {
    void 0 === s && (s = {}),
      void 0 === a && (a = {}),
      Object.keys(a).forEach((i) => {
        void 0 === s[i]
          ? (s[i] = a[i])
          : e(a[i]) && e(s[i]) && Object.keys(a[i]).length > 0 && t(s[i], a[i]);
      });
  }
  const s = {
    body: {},
    addEventListener() { },
    removeEventListener() { },
    activeElement: { blur() { }, nodeName: "" },
    querySelector: () => null,
    querySelectorAll: () => [],
    getElementById: () => null,
    createEvent: () => ({ initEvent() { } }),
    createElement: () => ({
      children: [],
      childNodes: [],
      style: {},
      setAttribute() { },
      getElementsByTagName: () => [],
    }),
    createElementNS: () => ({}),
    importNode: () => null,
    location: {
      hash: "",
      host: "",
      hostname: "",
      href: "",
      origin: "",
      pathname: "",
      protocol: "",
      search: "",
    },
  };
  function a() {
    const e = "undefined" != typeof document ? document : {};
    return t(e, s), e;
  }
  const i = {
    document: s,
    navigator: { userAgent: "" },
    location: {
      hash: "",
      host: "",
      hostname: "",
      href: "",
      origin: "",
      pathname: "",
      protocol: "",
      search: "",
    },
    history: { replaceState() { }, pushState() { }, go() { }, back() { } },
    CustomEvent: function () {
      return this;
    },
    addEventListener() { },
    removeEventListener() { },
    getComputedStyle: () => ({ getPropertyValue: () => "" }),
    Image() { },
    Date() { },
    screen: {},
    setTimeout() { },
    clearTimeout() { },
    matchMedia: () => ({}),
    requestAnimationFrame: (e) =>
      "undefined" == typeof setTimeout ? (e(), null) : setTimeout(e, 0),
    cancelAnimationFrame(e) {
      "undefined" != typeof setTimeout && clearTimeout(e);
    },
  };
  function r() {
    const e = "undefined" != typeof window ? window : {};
    return t(e, i), e;
  }
  class n extends Array {
    constructor(e) {
      "number" == typeof e
        ? super(e)
        : (super(...(e || [])),
          (function (e) {
            const t = e.__proto__;
            Object.defineProperty(e, "__proto__", {
              get: () => t,
              set(e) {
                t.__proto__ = e;
              },
            });
          })(this));
    }
  }
  function l(e) {
    void 0 === e && (e = []);
    const t = [];
    return (
      e.forEach((e) => {
        Array.isArray(e) ? t.push(...l(e)) : t.push(e);
      }),
      t
    );
  }
  function o(e, t) {
    return Array.prototype.filter.call(e, t);
  }
  function d(e, t) {
    const s = r(),
      i = a();
    let l = [];
    if (!t && e instanceof n) return e;
    if (!e) return new n(l);
    if ("string" == typeof e) {
      const s = e.trim();
      if (s.indexOf("<") >= 0 && s.indexOf(">") >= 0) {
        let e = "div";
        0 === s.indexOf("<li") && (e = "ul"),
          0 === s.indexOf("<tr") && (e = "tbody"),
          (0 !== s.indexOf("<td") && 0 !== s.indexOf("<th")) || (e = "tr"),
          0 === s.indexOf("<tbody") && (e = "table"),
          0 === s.indexOf("<option") && (e = "select");
        const t = i.createElement(e);
        t.innerHTML = s;
        for (let e = 0; e < t.childNodes.length; e += 1)
          l.push(t.childNodes[e]);
      } else
        l = (function (e, t) {
          if ("string" != typeof e) return [e];
          const s = [],
            a = t.querySelectorAll(e);
          for (let e = 0; e < a.length; e += 1) s.push(a[e]);
          return s;
        })(e.trim(), t || i);
    } else if (e.nodeType || e === s || e === i) l.push(e);
    else if (Array.isArray(e)) {
      if (e instanceof n) return e;
      l = e;
    }
    return new n(
      (function (e) {
        const t = [];
        for (let s = 0; s < e.length; s += 1)
          -1 === t.indexOf(e[s]) && t.push(e[s]);
        return t;
      })(l)
    );
  }
  d.fn = n.prototype;
  const c = {
    addClass: function () {
      for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++)
        t[s] = arguments[s];
      const a = l(t.map((e) => e.split(" ")));
      return (
        this.forEach((e) => {
          e.classList.add(...a);
        }),
        this
      );
    },
    removeClass: function () {
      for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++)
        t[s] = arguments[s];
      const a = l(t.map((e) => e.split(" ")));
      return (
        this.forEach((e) => {
          e.classList.remove(...a);
        }),
        this
      );
    },
    hasClass: function () {
      for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++)
        t[s] = arguments[s];
      const a = l(t.map((e) => e.split(" ")));
      return (
        o(this, (e) => a.filter((t) => e.classList.contains(t)).length > 0)
          .length > 0
      );
    },
    toggleClass: function () {
      for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++)
        t[s] = arguments[s];
      const a = l(t.map((e) => e.split(" ")));
      this.forEach((e) => {
        a.forEach((t) => {
          e.classList.toggle(t);
        });
      });
    },
    attr: function (e, t) {
      if (1 === arguments.length && "string" == typeof e)
        return this[0] ? this[0].getAttribute(e) : void 0;
      for (let s = 0; s < this.length; s += 1)
        if (2 === arguments.length) this[s].setAttribute(e, t);
        else
          for (const t in e) (this[s][t] = e[t]), this[s].setAttribute(t, e[t]);
      return this;
    },
    removeAttr: function (e) {
      for (let t = 0; t < this.length; t += 1) this[t].removeAttribute(e);
      return this;
    },
    transform: function (e) {
      for (let t = 0; t < this.length; t += 1) this[t].style.transform = e;
      return this;
    },
    transition: function (e) {
      for (let t = 0; t < this.length; t += 1)
        this[t].style.transitionDuration = "string" != typeof e ? `${e}ms` : e;
      return this;
    },
    on: function () {
      for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++)
        t[s] = arguments[s];
      let [a, i, r, n] = t;
      function l(e) {
        const t = e.target;
        if (!t) return;
        const s = e.target.dom7EventData || [];
        if ((s.indexOf(e) < 0 && s.unshift(e), d(t).is(i))) r.apply(t, s);
        else {
          const e = d(t).parents();
          for (let t = 0; t < e.length; t += 1)
            d(e[t]).is(i) && r.apply(e[t], s);
        }
      }
      function o(e) {
        const t = (e && e.target && e.target.dom7EventData) || [];
        t.indexOf(e) < 0 && t.unshift(e), r.apply(this, t);
      }
      "function" == typeof t[1] && (([a, r, n] = t), (i = void 0)),
        n || (n = !1);
      const c = a.split(" ");
      let p;
      for (let e = 0; e < this.length; e += 1) {
        const t = this[e];
        if (i)
          for (p = 0; p < c.length; p += 1) {
            const e = c[p];
            t.dom7LiveListeners || (t.dom7LiveListeners = {}),
              t.dom7LiveListeners[e] || (t.dom7LiveListeners[e] = []),
              t.dom7LiveListeners[e].push({ listener: r, proxyListener: l }),
              t.addEventListener(e, l, n);
          }
        else
          for (p = 0; p < c.length; p += 1) {
            const e = c[p];
            t.dom7Listeners || (t.dom7Listeners = {}),
              t.dom7Listeners[e] || (t.dom7Listeners[e] = []),
              t.dom7Listeners[e].push({ listener: r, proxyListener: o }),
              t.addEventListener(e, o, n);
          }
      }
      return this;
    },
    off: function () {
      for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++)
        t[s] = arguments[s];
      let [a, i, r, n] = t;
      "function" == typeof t[1] && (([a, r, n] = t), (i = void 0)),
        n || (n = !1);
      const l = a.split(" ");
      for (let e = 0; e < l.length; e += 1) {
        const t = l[e];
        for (let e = 0; e < this.length; e += 1) {
          const s = this[e];
          let a;
          if (
            (!i && s.dom7Listeners
              ? (a = s.dom7Listeners[t])
              : i && s.dom7LiveListeners && (a = s.dom7LiveListeners[t]),
              a && a.length)
          )
            for (let e = a.length - 1; e >= 0; e -= 1) {
              const i = a[e];
              (r && i.listener === r) ||
                (r &&
                  i.listener &&
                  i.listener.dom7proxy &&
                  i.listener.dom7proxy === r)
                ? (s.removeEventListener(t, i.proxyListener, n), a.splice(e, 1))
                : r ||
                (s.removeEventListener(t, i.proxyListener, n),
                  a.splice(e, 1));
            }
        }
      }
      return this;
    },
    trigger: function () {
      const e = r();
      for (var t = arguments.length, s = new Array(t), a = 0; a < t; a++)
        s[a] = arguments[a];
      const i = s[0].split(" "),
        n = s[1];
      for (let t = 0; t < i.length; t += 1) {
        const a = i[t];
        for (let t = 0; t < this.length; t += 1) {
          const i = this[t];
          if (e.CustomEvent) {
            const t = new e.CustomEvent(a, {
              detail: n,
              bubbles: !0,
              cancelable: !0,
            });
            (i.dom7EventData = s.filter((e, t) => t > 0)),
              i.dispatchEvent(t),
              (i.dom7EventData = []),
              delete i.dom7EventData;
          }
        }
      }
      return this;
    },
    transitionEnd: function (e) {
      const t = this;
      return (
        e &&
        t.on("transitionend", function s(a) {
          a.target === this && (e.call(this, a), t.off("transitionend", s));
        }),
        this
      );
    },
    outerWidth: function (e) {
      if (this.length > 0) {
        if (e) {
          const e = this.styles();
          return (
            this[0].offsetWidth +
            parseFloat(e.getPropertyValue("margin-right")) +
            parseFloat(e.getPropertyValue("margin-left"))
          );
        }
        return this[0].offsetWidth;
      }
      return null;
    },
    outerHeight: function (e) {
      if (this.length > 0) {
        if (e) {
          const e = this.styles();
          return (
            this[0].offsetHeight +
            parseFloat(e.getPropertyValue("margin-top")) +
            parseFloat(e.getPropertyValue("margin-bottom"))
          );
        }
        return this[0].offsetHeight;
      }
      return null;
    },
    styles: function () {
      const e = r();
      return this[0] ? e.getComputedStyle(this[0], null) : {};
    },
    offset: function () {
      if (this.length > 0) {
        const e = r(),
          t = a(),
          s = this[0],
          i = s.getBoundingClientRect(),
          n = t.body,
          l = s.clientTop || n.clientTop || 0,
          o = s.clientLeft || n.clientLeft || 0,
          d = s === e ? e.scrollY : s.scrollTop,
          c = s === e ? e.scrollX : s.scrollLeft;
        return { top: i.top + d - l, left: i.left + c - o };
      }
      return null;
    },
    css: function (e, t) {
      const s = r();
      let a;
      if (1 === arguments.length) {
        if ("string" != typeof e) {
          for (a = 0; a < this.length; a += 1)
            for (const t in e) this[a].style[t] = e[t];
          return this;
        }
        if (this[0])
          return s.getComputedStyle(this[0], null).getPropertyValue(e);
      }
      if (2 === arguments.length && "string" == typeof e) {
        for (a = 0; a < this.length; a += 1) this[a].style[e] = t;
        return this;
      }
      return this;
    },
    each: function (e) {
      return e
        ? (this.forEach((t, s) => {
          e.apply(t, [t, s]);
        }),
          this)
        : this;
    },
    html: function (e) {
      if (void 0 === e) return this[0] ? this[0].innerHTML : null;
      for (let t = 0; t < this.length; t += 1) this[t].innerHTML = e;
      return this;
    },
    text: function (e) {
      if (void 0 === e) return this[0] ? this[0].textContent.trim() : null;
      for (let t = 0; t < this.length; t += 1) this[t].textContent = e;
      return this;
    },
    is: function (e) {
      const t = r(),
        s = a(),
        i = this[0];
      let l, o;
      if (!i || void 0 === e) return !1;
      if ("string" == typeof e) {
        if (i.matches) return i.matches(e);
        if (i.webkitMatchesSelector) return i.webkitMatchesSelector(e);
        if (i.msMatchesSelector) return i.msMatchesSelector(e);
        for (l = d(e), o = 0; o < l.length; o += 1) if (l[o] === i) return !0;
        return !1;
      }
      if (e === s) return i === s;
      if (e === t) return i === t;
      if (e.nodeType || e instanceof n) {
        for (l = e.nodeType ? [e] : e, o = 0; o < l.length; o += 1)
          if (l[o] === i) return !0;
        return !1;
      }
      return !1;
    },
    index: function () {
      let e,
        t = this[0];
      if (t) {
        for (e = 0; null !== (t = t.previousSibling);)
          1 === t.nodeType && (e += 1);
        return e;
      }
    },
    eq: function (e) {
      if (void 0 === e) return this;
      const t = this.length;
      if (e > t - 1) return d([]);
      if (e < 0) {
        const s = t + e;
        return d(s < 0 ? [] : [this[s]]);
      }
      return d([this[e]]);
    },
    append: function () {
      let e;
      const t = a();
      for (let s = 0; s < arguments.length; s += 1) {
        e = s < 0 || arguments.length <= s ? void 0 : arguments[s];
        for (let s = 0; s < this.length; s += 1)
          if ("string" == typeof e) {
            const a = t.createElement("div");
            for (a.innerHTML = e; a.firstChild;)
              this[s].appendChild(a.firstChild);
          } else if (e instanceof n)
            for (let t = 0; t < e.length; t += 1) this[s].appendChild(e[t]);
          else this[s].appendChild(e);
      }
      return this;
    },
    prepend: function (e) {
      const t = a();
      let s, i;
      for (s = 0; s < this.length; s += 1)
        if ("string" == typeof e) {
          const a = t.createElement("div");
          for (a.innerHTML = e, i = a.childNodes.length - 1; i >= 0; i -= 1)
            this[s].insertBefore(a.childNodes[i], this[s].childNodes[0]);
        } else if (e instanceof n)
          for (i = 0; i < e.length; i += 1)
            this[s].insertBefore(e[i], this[s].childNodes[0]);
        else this[s].insertBefore(e, this[s].childNodes[0]);
      return this;
    },
    next: function (e) {
      return this.length > 0
        ? e
          ? this[0].nextElementSibling && d(this[0].nextElementSibling).is(e)
            ? d([this[0].nextElementSibling])
            : d([])
          : this[0].nextElementSibling
            ? d([this[0].nextElementSibling])
            : d([])
        : d([]);
    },
    nextAll: function (e) {
      const t = [];
      let s = this[0];
      if (!s) return d([]);
      for (; s.nextElementSibling;) {
        const a = s.nextElementSibling;
        e ? d(a).is(e) && t.push(a) : t.push(a), (s = a);
      }
      return d(t);
    },
    prev: function (e) {
      if (this.length > 0) {
        const t = this[0];
        return e
          ? t.previousElementSibling && d(t.previousElementSibling).is(e)
            ? d([t.previousElementSibling])
            : d([])
          : t.previousElementSibling
            ? d([t.previousElementSibling])
            : d([]);
      }
      return d([]);
    },
    prevAll: function (e) {
      const t = [];
      let s = this[0];
      if (!s) return d([]);
      for (; s.previousElementSibling;) {
        const a = s.previousElementSibling;
        e ? d(a).is(e) && t.push(a) : t.push(a), (s = a);
      }
      return d(t);
    },
    parent: function (e) {
      const t = [];
      for (let s = 0; s < this.length; s += 1)
        null !== this[s].parentNode &&
          (e
            ? d(this[s].parentNode).is(e) && t.push(this[s].parentNode)
            : t.push(this[s].parentNode));
      return d(t);
    },
    parents: function (e) {
      const t = [];
      for (let s = 0; s < this.length; s += 1) {
        let a = this[s].parentNode;
        for (; a;) e ? d(a).is(e) && t.push(a) : t.push(a), (a = a.parentNode);
      }
      return d(t);
    },
    closest: function (e) {
      let t = this;
      return void 0 === e ? d([]) : (t.is(e) || (t = t.parents(e).eq(0)), t);
    },
    find: function (e) {
      const t = [];
      for (let s = 0; s < this.length; s += 1) {
        const a = this[s].querySelectorAll(e);
        for (let e = 0; e < a.length; e += 1) t.push(a[e]);
      }
      return d(t);
    },
    children: function (e) {
      const t = [];
      for (let s = 0; s < this.length; s += 1) {
        const a = this[s].children;
        for (let s = 0; s < a.length; s += 1)
          (e && !d(a[s]).is(e)) || t.push(a[s]);
      }
      return d(t);
    },
    filter: function (e) {
      return d(o(this, e));
    },
    remove: function () {
      for (let e = 0; e < this.length; e += 1)
        this[e].parentNode && this[e].parentNode.removeChild(this[e]);
      return this;
    },
  };
  function p(e, t) {
    return void 0 === t && (t = 0), setTimeout(e, t);
  }
  function u() {
    return Date.now();
  }
  function h(e, t) {
    void 0 === t && (t = "x");
    const s = r();
    let a, i, n;
    const l = (function (e) {
      const t = r();
      let s;
      return (
        t.getComputedStyle && (s = t.getComputedStyle(e, null)),
        !s && e.currentStyle && (s = e.currentStyle),
        s || (s = e.style),
        s
      );
    })(e);
    return (
      s.WebKitCSSMatrix
        ? ((i = l.transform || l.webkitTransform),
          i.split(",").length > 6 &&
          (i = i
            .split(", ")
            .map((e) => e.replace(",", "."))
            .join(", ")),
          (n = new s.WebKitCSSMatrix("none" === i ? "" : i)))
        : ((n =
          l.MozTransform ||
          l.OTransform ||
          l.MsTransform ||
          l.msTransform ||
          l.transform ||
          l
            .getPropertyValue("transform")
            .replace("translate(", "matrix(1, 0, 0, 1,")),
          (a = n.toString().split(","))),
      "x" === t &&
      (i = s.WebKitCSSMatrix
        ? n.m41
        : 16 === a.length
          ? parseFloat(a[12])
          : parseFloat(a[4])),
      "y" === t &&
      (i = s.WebKitCSSMatrix
        ? n.m42
        : 16 === a.length
          ? parseFloat(a[13])
          : parseFloat(a[5])),
      i || 0
    );
  }
  function m(e) {
    return (
      "object" == typeof e &&
      null !== e &&
      e.constructor &&
      "Object" === Object.prototype.toString.call(e).slice(8, -1)
    );
  }
  function f(e) {
    return "undefined" != typeof window && void 0 !== window.HTMLElement
      ? e instanceof HTMLElement
      : e && (1 === e.nodeType || 11 === e.nodeType);
  }
  function g() {
    const e = Object(arguments.length <= 0 ? void 0 : arguments[0]),
      t = ["__proto__", "constructor", "prototype"];
    for (let s = 1; s < arguments.length; s += 1) {
      const a = s < 0 || arguments.length <= s ? void 0 : arguments[s];
      if (null != a && !f(a)) {
        const s = Object.keys(Object(a)).filter((e) => t.indexOf(e) < 0);
        for (let t = 0, i = s.length; t < i; t += 1) {
          const i = s[t],
            r = Object.getOwnPropertyDescriptor(a, i);
          void 0 !== r &&
            r.enumerable &&
            (m(e[i]) && m(a[i])
              ? a[i].__swiper__
                ? (e[i] = a[i])
                : g(e[i], a[i])
              : !m(e[i]) && m(a[i])
                ? ((e[i] = {}), a[i].__swiper__ ? (e[i] = a[i]) : g(e[i], a[i]))
                : (e[i] = a[i]));
        }
      }
    }
    return e;
  }
  function v(e, t, s) {
    e.style.setProperty(t, s);
  }
  function w(e) {
    let { swiper: t, targetPosition: s, side: a } = e;
    const i = r(),
      n = -t.translate;
    let l,
      o = null;
    const d = t.params.speed;
    (t.wrapperEl.style.scrollSnapType = "none"),
      i.cancelAnimationFrame(t.cssModeFrameID);
    const c = s > n ? "next" : "prev",
      p = (e, t) => ("next" === c && e >= t) || ("prev" === c && e <= t),
      u = () => {
        (l = new Date().getTime()), null === o && (o = l);
        const e = Math.max(Math.min((l - o) / d, 1), 0),
          r = 0.5 - Math.cos(e * Math.PI) / 2;
        let c = n + r * (s - n);
        if ((p(c, s) && (c = s), t.wrapperEl.scrollTo({ [a]: c }), p(c, s)))
          return (
            (t.wrapperEl.style.overflow = "hidden"),
            (t.wrapperEl.style.scrollSnapType = ""),
            setTimeout(() => {
              (t.wrapperEl.style.overflow = ""),
                t.wrapperEl.scrollTo({ [a]: c });
            }),
            void i.cancelAnimationFrame(t.cssModeFrameID)
          );
        t.cssModeFrameID = i.requestAnimationFrame(u);
      };
    u();
  }
  let b, x, y;
  function E() {
    return (
      b ||
      (b = (function () {
        const e = r(),
          t = a();
        return {
          smoothScroll:
            t.documentElement && "scrollBehavior" in t.documentElement.style,
          touch: !!(
            "ontouchstart" in e ||
            (e.DocumentTouch && t instanceof e.DocumentTouch)
          ),
          passiveListener: (function () {
            let t = !1;
            try {
              const s = Object.defineProperty({}, "passive", {
                get() {
                  t = !0;
                },
              });
              e.addEventListener("testPassiveListener", null, s);
            } catch (e) { }
            return t;
          })(),
          gestures: "ongesturestart" in e,
        };
      })()),
      b
    );
  }
  function T(e) {
    return (
      void 0 === e && (e = {}),
      x ||
      (x = (function (e) {
        let { userAgent: t } = void 0 === e ? {} : e;
        const s = E(),
          a = r(),
          i = a.navigator.platform,
          n = t || a.navigator.userAgent,
          l = { ios: !1, android: !1 },
          o = a.screen.width,
          d = a.screen.height,
          c = n.match(/(Android);?[\s\/]+([\d.]+)?/);
        let p = n.match(/(iPad).*OS\s([\d_]+)/);
        const u = n.match(/(iPod)(.*OS\s([\d_]+))?/),
          h = !p && n.match(/(iPhone\sOS|iOS)\s([\d_]+)/),
          m = "Win32" === i;
        let f = "MacIntel" === i;
        return (
          !p &&
          f &&
          s.touch &&
          [
            "1024x1366",
            "1366x1024",
            "834x1194",
            "1194x834",
            "834x1112",
            "1112x834",
            "768x1024",
            "1024x768",
            "820x1180",
            "1180x820",
            "810x1080",
            "1080x810",
          ].indexOf(`${o}x${d}`) >= 0 &&
          ((p = n.match(/(Version)\/([\d.]+)/)),
            p || (p = [0, 1, "13_0_0"]),
            (f = !1)),
          c && !m && ((l.os = "android"), (l.android = !0)),
          (p || h || u) && ((l.os = "ios"), (l.ios = !0)),
          l
        );
      })(e)),
      x
    );
  }
  function C() {
    return (
      y ||
      (y = (function () {
        const e = r();
        return {
          isSafari: (function () {
            const t = e.navigator.userAgent.toLowerCase();
            return (
              t.indexOf("safari") >= 0 &&
              t.indexOf("chrome") < 0 &&
              t.indexOf("android") < 0
            );
          })(),
          isWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(
            e.navigator.userAgent
          ),
        };
      })()),
      y
    );
  }
  Object.keys(c).forEach((e) => {
    Object.defineProperty(d.fn, e, { value: c[e], writable: !0 });
  });
  var $ = {
    on(e, t, s) {
      const a = this;
      if ("function" != typeof t) return a;
      const i = s ? "unshift" : "push";
      return (
        e.split(" ").forEach((e) => {
          a.eventsListeners[e] || (a.eventsListeners[e] = []),
            a.eventsListeners[e][i](t);
        }),
        a
      );
    },
    once(e, t, s) {
      const a = this;
      if ("function" != typeof t) return a;
      function i() {
        a.off(e, i), i.__emitterProxy && delete i.__emitterProxy;
        for (var s = arguments.length, r = new Array(s), n = 0; n < s; n++)
          r[n] = arguments[n];
        t.apply(a, r);
      }
      return (i.__emitterProxy = t), a.on(e, i, s);
    },
    onAny(e, t) {
      const s = this;
      if ("function" != typeof e) return s;
      const a = t ? "unshift" : "push";
      return (
        s.eventsAnyListeners.indexOf(e) < 0 && s.eventsAnyListeners[a](e), s
      );
    },
    offAny(e) {
      const t = this;
      if (!t.eventsAnyListeners) return t;
      const s = t.eventsAnyListeners.indexOf(e);
      return s >= 0 && t.eventsAnyListeners.splice(s, 1), t;
    },
    off(e, t) {
      const s = this;
      return s.eventsListeners
        ? (e.split(" ").forEach((e) => {
          void 0 === t
            ? (s.eventsListeners[e] = [])
            : s.eventsListeners[e] &&
            s.eventsListeners[e].forEach((a, i) => {
              (a === t || (a.__emitterProxy && a.__emitterProxy === t)) &&
                s.eventsListeners[e].splice(i, 1);
            });
        }),
          s)
        : s;
    },
    emit() {
      const e = this;
      if (!e.eventsListeners) return e;
      let t, s, a;
      for (var i = arguments.length, r = new Array(i), n = 0; n < i; n++)
        r[n] = arguments[n];
      "string" == typeof r[0] || Array.isArray(r[0])
        ? ((t = r[0]), (s = r.slice(1, r.length)), (a = e))
        : ((t = r[0].events), (s = r[0].data), (a = r[0].context || e)),
        s.unshift(a);
      return (
        (Array.isArray(t) ? t : t.split(" ")).forEach((t) => {
          e.eventsAnyListeners &&
            e.eventsAnyListeners.length &&
            e.eventsAnyListeners.forEach((e) => {
              e.apply(a, [t, ...s]);
            }),
            e.eventsListeners &&
            e.eventsListeners[t] &&
            e.eventsListeners[t].forEach((e) => {
              e.apply(a, s);
            });
        }),
        e
      );
    },
  };
  var S = {
    updateSize: function () {
      const e = this;
      let t, s;
      const a = e.$el;
      (t =
        void 0 !== e.params.width && null !== e.params.width
          ? e.params.width
          : a[0].clientWidth),
        (s =
          void 0 !== e.params.height && null !== e.params.height
            ? e.params.height
            : a[0].clientHeight),
        (0 === t && e.isHorizontal()) ||
        (0 === s && e.isVertical()) ||
        ((t =
          t -
          parseInt(a.css("padding-left") || 0, 10) -
          parseInt(a.css("padding-right") || 0, 10)),
          (s =
            s -
            parseInt(a.css("padding-top") || 0, 10) -
            parseInt(a.css("padding-bottom") || 0, 10)),
          Number.isNaN(t) && (t = 0),
          Number.isNaN(s) && (s = 0),
          Object.assign(e, {
            width: t,
            height: s,
            size: e.isHorizontal() ? t : s,
          }));
    },
    updateSlides: function () {
      const e = this;
      function t(t) {
        return e.isHorizontal()
          ? t
          : {
            width: "height",
            "margin-top": "margin-left",
            "margin-bottom ": "margin-right",
            "margin-left": "margin-top",
            "margin-right": "margin-bottom",
            "padding-left": "padding-top",
            "padding-right": "padding-bottom",
            marginRight: "marginBottom",
          }[t];
      }
      function s(e, s) {
        return parseFloat(e.getPropertyValue(t(s)) || 0);
      }
      const a = e.params,
        { $wrapperEl: i, size: r, rtlTranslate: n, wrongRTL: l } = e,
        o = e.virtual && a.virtual.enabled,
        d = o ? e.virtual.slides.length : e.slides.length,
        c = i.children(`.${e.params.slideClass}`),
        p = o ? e.virtual.slides.length : c.length;
      let u = [];
      const h = [],
        m = [];
      let f = a.slidesOffsetBefore;
      "function" == typeof f && (f = a.slidesOffsetBefore.call(e));
      let g = a.slidesOffsetAfter;
      "function" == typeof g && (g = a.slidesOffsetAfter.call(e));
      const w = e.snapGrid.length,
        b = e.slidesGrid.length;
      let x = a.spaceBetween,
        y = -f,
        E = 0,
        T = 0;
      if (void 0 === r) return;
      "string" == typeof x &&
        x.indexOf("%") >= 0 &&
        (x = (parseFloat(x.replace("%", "")) / 100) * r),
        (e.virtualSize = -x),
        n
          ? c.css({ marginLeft: "", marginBottom: "", marginTop: "" })
          : c.css({ marginRight: "", marginBottom: "", marginTop: "" }),
        a.centeredSlides &&
        a.cssMode &&
        (v(e.wrapperEl, "--swiper-centered-offset-before", ""),
          v(e.wrapperEl, "--swiper-centered-offset-after", ""));
      const C = a.grid && a.grid.rows > 1 && e.grid;
      let $;
      C && e.grid.initSlides(p);
      const S =
        "auto" === a.slidesPerView &&
        a.breakpoints &&
        Object.keys(a.breakpoints).filter(
          (e) => void 0 !== a.breakpoints[e].slidesPerView
        ).length > 0;
      for (let i = 0; i < p; i += 1) {
        $ = 0;
        const n = c.eq(i);
        if (
          (C && e.grid.updateSlide(i, n, p, t), "none" !== n.css("display"))
        ) {
          if ("auto" === a.slidesPerView) {
            S && (c[i].style[t("width")] = "");
            const r = getComputedStyle(n[0]),
              l = n[0].style.transform,
              o = n[0].style.webkitTransform;
            if (
              (l && (n[0].style.transform = "none"),
                o && (n[0].style.webkitTransform = "none"),
                a.roundLengths)
            )
              $ = e.isHorizontal() ? n.outerWidth(!0) : n.outerHeight(!0);
            else {
              const e = s(r, "width"),
                t = s(r, "padding-left"),
                a = s(r, "padding-right"),
                i = s(r, "margin-left"),
                l = s(r, "margin-right"),
                o = r.getPropertyValue("box-sizing");
              if (o && "border-box" === o) $ = e + i + l;
              else {
                const { clientWidth: s, offsetWidth: r } = n[0];
                $ = e + t + a + i + l + (r - s);
              }
            }
            l && (n[0].style.transform = l),
              o && (n[0].style.webkitTransform = o),
              a.roundLengths && ($ = Math.floor($));
          } else
            ($ = (r - (a.slidesPerView - 1) * x) / a.slidesPerView),
              a.roundLengths && ($ = Math.floor($)),
              c[i] && (c[i].style[t("width")] = `${$}px`);
          c[i] && (c[i].swiperSlideSize = $),
            m.push($),
            a.centeredSlides
              ? ((y = y + $ / 2 + E / 2 + x),
                0 === E && 0 !== i && (y = y - r / 2 - x),
                0 === i && (y = y - r / 2 - x),
                Math.abs(y) < 0.001 && (y = 0),
                a.roundLengths && (y = Math.floor(y)),
                T % a.slidesPerGroup == 0 && u.push(y),
                h.push(y))
              : (a.roundLengths && (y = Math.floor(y)),
                (T - Math.min(e.params.slidesPerGroupSkip, T)) %
                e.params.slidesPerGroup ==
                0 && u.push(y),
                h.push(y),
                (y = y + $ + x)),
            (e.virtualSize += $ + x),
            (E = $),
            (T += 1);
        }
      }
      if (
        ((e.virtualSize = Math.max(e.virtualSize, r) + g),
          n &&
          l &&
          ("slide" === a.effect || "coverflow" === a.effect) &&
          i.css({ width: `${e.virtualSize + a.spaceBetween}px` }),
          a.setWrapperSize &&
          i.css({ [t("width")]: `${e.virtualSize + a.spaceBetween}px` }),
          C && e.grid.updateWrapperSize($, u, t),
          !a.centeredSlides)
      ) {
        const t = [];
        for (let s = 0; s < u.length; s += 1) {
          let i = u[s];
          a.roundLengths && (i = Math.floor(i)),
            u[s] <= e.virtualSize - r && t.push(i);
        }
        (u = t),
          Math.floor(e.virtualSize - r) - Math.floor(u[u.length - 1]) > 1 &&
          u.push(e.virtualSize - r);
      }
      if ((0 === u.length && (u = [0]), 0 !== a.spaceBetween)) {
        const s = e.isHorizontal() && n ? "marginLeft" : t("marginRight");
        c.filter((e, t) => !a.cssMode || t !== c.length - 1).css({
          [s]: `${x}px`,
        });
      }
      if (a.centeredSlides && a.centeredSlidesBounds) {
        let e = 0;
        m.forEach((t) => {
          e += t + (a.spaceBetween ? a.spaceBetween : 0);
        }),
          (e -= a.spaceBetween);
        const t = e - r;
        u = u.map((e) => (e < 0 ? -f : e > t ? t + g : e));
      }
      if (a.centerInsufficientSlides) {
        let e = 0;
        if (
          (m.forEach((t) => {
            e += t + (a.spaceBetween ? a.spaceBetween : 0);
          }),
            (e -= a.spaceBetween),
            e < r)
        ) {
          const t = (r - e) / 2;
          u.forEach((e, s) => {
            u[s] = e - t;
          }),
            h.forEach((e, s) => {
              h[s] = e + t;
            });
        }
      }
      if (
        (Object.assign(e, {
          slides: c,
          snapGrid: u,
          slidesGrid: h,
          slidesSizesGrid: m,
        }),
          a.centeredSlides && a.cssMode && !a.centeredSlidesBounds)
      ) {
        v(e.wrapperEl, "--swiper-centered-offset-before", -u[0] + "px"),
          v(
            e.wrapperEl,
            "--swiper-centered-offset-after",
            e.size / 2 - m[m.length - 1] / 2 + "px"
          );
        const t = -e.snapGrid[0],
          s = -e.slidesGrid[0];
        (e.snapGrid = e.snapGrid.map((e) => e + t)),
          (e.slidesGrid = e.slidesGrid.map((e) => e + s));
      }
      if (
        (p !== d && e.emit("slidesLengthChange"),
          u.length !== w &&
          (e.params.watchOverflow && e.checkOverflow(),
            e.emit("snapGridLengthChange")),
          h.length !== b && e.emit("slidesGridLengthChange"),
          a.watchSlidesProgress && e.updateSlidesOffset(),
          !(o || a.cssMode || ("slide" !== a.effect && "fade" !== a.effect)))
      ) {
        const t = `${a.containerModifierClass}backface-hidden`,
          s = e.$el.hasClass(t);
        p <= a.maxBackfaceHiddenSlides
          ? s || e.$el.addClass(t)
          : s && e.$el.removeClass(t);
      }
    },
    updateAutoHeight: function (e) {
      const t = this,
        s = [],
        a = t.virtual && t.params.virtual.enabled;
      let i,
        r = 0;
      "number" == typeof e
        ? t.setTransition(e)
        : !0 === e && t.setTransition(t.params.speed);
      const n = (e) =>
        a
          ? t.slides.filter(
            (t) =>
              parseInt(t.getAttribute("data-swiper-slide-index"), 10) === e
          )[0]
          : t.slides.eq(e)[0];
      if ("auto" !== t.params.slidesPerView && t.params.slidesPerView > 1)
        if (t.params.centeredSlides)
          t.visibleSlides.each((e) => {
            s.push(e);
          });
        else
          for (i = 0; i < Math.ceil(t.params.slidesPerView); i += 1) {
            const e = t.activeIndex + i;
            if (e > t.slides.length && !a) break;
            s.push(n(e));
          }
      else s.push(n(t.activeIndex));
      for (i = 0; i < s.length; i += 1)
        if (void 0 !== s[i]) {
          const e = s[i].offsetHeight;
          r = e > r ? e : r;
        }
      (r || 0 === r) && t.$wrapperEl.css("height", `${r}px`);
    },
    updateSlidesOffset: function () {
      const e = this,
        t = e.slides;
      for (let s = 0; s < t.length; s += 1)
        t[s].swiperSlideOffset = e.isHorizontal()
          ? t[s].offsetLeft
          : t[s].offsetTop;
    },
    updateSlidesProgress: function (e) {
      void 0 === e && (e = (this && this.translate) || 0);
      const t = this,
        s = t.params,
        { slides: a, rtlTranslate: i, snapGrid: r } = t;
      if (0 === a.length) return;
      void 0 === a[0].swiperSlideOffset && t.updateSlidesOffset();
      let n = -e;
      i && (n = e),
        a.removeClass(s.slideVisibleClass),
        (t.visibleSlidesIndexes = []),
        (t.visibleSlides = []);
      for (let e = 0; e < a.length; e += 1) {
        const l = a[e];
        let o = l.swiperSlideOffset;
        s.cssMode && s.centeredSlides && (o -= a[0].swiperSlideOffset);
        const d =
          (n + (s.centeredSlides ? t.minTranslate() : 0) - o) /
          (l.swiperSlideSize + s.spaceBetween),
          c =
            (n - r[0] + (s.centeredSlides ? t.minTranslate() : 0) - o) /
            (l.swiperSlideSize + s.spaceBetween),
          p = -(n - o),
          u = p + t.slidesSizesGrid[e];
        ((p >= 0 && p < t.size - 1) ||
          (u > 1 && u <= t.size) ||
          (p <= 0 && u >= t.size)) &&
          (t.visibleSlides.push(l),
            t.visibleSlidesIndexes.push(e),
            a.eq(e).addClass(s.slideVisibleClass)),
          (l.progress = i ? -d : d),
          (l.originalProgress = i ? -c : c);
      }
      t.visibleSlides = d(t.visibleSlides);
    },
    updateProgress: function (e) {
      const t = this;
      if (void 0 === e) {
        const s = t.rtlTranslate ? -1 : 1;
        e = (t && t.translate && t.translate * s) || 0;
      }
      const s = t.params,
        a = t.maxTranslate() - t.minTranslate();
      let { progress: i, isBeginning: r, isEnd: n } = t;
      const l = r,
        o = n;
      0 === a
        ? ((i = 0), (r = !0), (n = !0))
        : ((i = (e - t.minTranslate()) / a), (r = i <= 0), (n = i >= 1)),
        Object.assign(t, { progress: i, isBeginning: r, isEnd: n }),
        (s.watchSlidesProgress || (s.centeredSlides && s.autoHeight)) &&
        t.updateSlidesProgress(e),
        r && !l && t.emit("reachBeginning toEdge"),
        n && !o && t.emit("reachEnd toEdge"),
        ((l && !r) || (o && !n)) && t.emit("fromEdge"),
        t.emit("progress", i);
    },
    updateSlidesClasses: function () {
      const e = this,
        {
          slides: t,
          params: s,
          $wrapperEl: a,
          activeIndex: i,
          realIndex: r,
        } = e,
        n = e.virtual && s.virtual.enabled;
      let l;
      t.removeClass(
        `${s.slideActiveClass} ${s.slideNextClass} ${s.slidePrevClass} ${s.slideDuplicateActiveClass} ${s.slideDuplicateNextClass} ${s.slideDuplicatePrevClass}`
      ),
        (l = n
          ? e.$wrapperEl.find(
            `.${s.slideClass}[data-swiper-slide-index="${i}"]`
          )
          : t.eq(i)),
        l.addClass(s.slideActiveClass),
        s.loop &&
        (l.hasClass(s.slideDuplicateClass)
          ? a
            .children(
              `.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${r}"]`
            )
            .addClass(s.slideDuplicateActiveClass)
          : a
            .children(
              `.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${r}"]`
            )
            .addClass(s.slideDuplicateActiveClass));
      let o = l.nextAll(`.${s.slideClass}`).eq(0).addClass(s.slideNextClass);
      s.loop && 0 === o.length && ((o = t.eq(0)), o.addClass(s.slideNextClass));
      let d = l.prevAll(`.${s.slideClass}`).eq(0).addClass(s.slidePrevClass);
      s.loop &&
        0 === d.length &&
        ((d = t.eq(-1)), d.addClass(s.slidePrevClass)),
        s.loop &&
        (o.hasClass(s.slideDuplicateClass)
          ? a
            .children(
              `.${s.slideClass}:not(.${s.slideDuplicateClass
              })[data-swiper-slide-index="${o.attr(
                "data-swiper-slide-index"
              )}"]`
            )
            .addClass(s.slideDuplicateNextClass)
          : a
            .children(
              `.${s.slideClass}.${s.slideDuplicateClass
              }[data-swiper-slide-index="${o.attr(
                "data-swiper-slide-index"
              )}"]`
            )
            .addClass(s.slideDuplicateNextClass),
          d.hasClass(s.slideDuplicateClass)
            ? a
              .children(
                `.${s.slideClass}:not(.${s.slideDuplicateClass
                })[data-swiper-slide-index="${d.attr(
                  "data-swiper-slide-index"
                )}"]`
              )
              .addClass(s.slideDuplicatePrevClass)
            : a
              .children(
                `.${s.slideClass}.${s.slideDuplicateClass
                }[data-swiper-slide-index="${d.attr(
                  "data-swiper-slide-index"
                )}"]`
              )
              .addClass(s.slideDuplicatePrevClass)),
        e.emitSlidesClasses();
    },
    updateActiveIndex: function (e) {
      const t = this,
        s = t.rtlTranslate ? t.translate : -t.translate,
        {
          slidesGrid: a,
          snapGrid: i,
          params: r,
          activeIndex: n,
          realIndex: l,
          snapIndex: o,
        } = t;
      let d,
        c = e;
      if (void 0 === c) {
        for (let e = 0; e < a.length; e += 1)
          void 0 !== a[e + 1]
            ? s >= a[e] && s < a[e + 1] - (a[e + 1] - a[e]) / 2
              ? (c = e)
              : s >= a[e] && s < a[e + 1] && (c = e + 1)
            : s >= a[e] && (c = e);
        r.normalizeSlideIndex && (c < 0 || void 0 === c) && (c = 0);
      }
      if (i.indexOf(s) >= 0) d = i.indexOf(s);
      else {
        const e = Math.min(r.slidesPerGroupSkip, c);
        d = e + Math.floor((c - e) / r.slidesPerGroup);
      }
      if ((d >= i.length && (d = i.length - 1), c === n))
        return void (d !== o && ((t.snapIndex = d), t.emit("snapIndexChange")));
      const p = parseInt(
        t.slides.eq(c).attr("data-swiper-slide-index") || c,
        10
      );
      Object.assign(t, {
        snapIndex: d,
        realIndex: p,
        previousIndex: n,
        activeIndex: c,
      }),
        t.emit("activeIndexChange"),
        t.emit("snapIndexChange"),
        l !== p && t.emit("realIndexChange"),
        (t.initialized || t.params.runCallbacksOnInit) && t.emit("slideChange");
    },
    updateClickedSlide: function (e) {
      const t = this,
        s = t.params,
        a = d(e).closest(`.${s.slideClass}`)[0];
      let i,
        r = !1;
      if (a)
        for (let e = 0; e < t.slides.length; e += 1)
          if (t.slides[e] === a) {
            (r = !0), (i = e);
            break;
          }
      if (!a || !r)
        return (t.clickedSlide = void 0), void (t.clickedIndex = void 0);
      (t.clickedSlide = a),
        t.virtual && t.params.virtual.enabled
          ? (t.clickedIndex = parseInt(
            d(a).attr("data-swiper-slide-index"),
            10
          ))
          : (t.clickedIndex = i),
        s.slideToClickedSlide &&
        void 0 !== t.clickedIndex &&
        t.clickedIndex !== t.activeIndex &&
        t.slideToClickedSlide();
    },
  };
  var M = {
    getTranslate: function (e) {
      void 0 === e && (e = this.isHorizontal() ? "x" : "y");
      const { params: t, rtlTranslate: s, translate: a, $wrapperEl: i } = this;
      if (t.virtualTranslate) return s ? -a : a;
      if (t.cssMode) return a;
      let r = h(i[0], e);
      return s && (r = -r), r || 0;
    },
    setTranslate: function (e, t) {
      const s = this,
        {
          rtlTranslate: a,
          params: i,
          $wrapperEl: r,
          wrapperEl: n,
          progress: l,
        } = s;
      let o,
        d = 0,
        c = 0;
      s.isHorizontal() ? (d = a ? -e : e) : (c = e),
        i.roundLengths && ((d = Math.floor(d)), (c = Math.floor(c))),
        i.cssMode
          ? (n[s.isHorizontal() ? "scrollLeft" : "scrollTop"] = s.isHorizontal()
            ? -d
            : -c)
          : i.virtualTranslate ||
          r.transform(`translate3d(${d}px, ${c}px, 0px)`),
        (s.previousTranslate = s.translate),
        (s.translate = s.isHorizontal() ? d : c);
      const p = s.maxTranslate() - s.minTranslate();
      (o = 0 === p ? 0 : (e - s.minTranslate()) / p),
        o !== l && s.updateProgress(e),
        s.emit("setTranslate", s.translate, t);
    },
    minTranslate: function () {
      return -this.snapGrid[0];
    },
    maxTranslate: function () {
      return -this.snapGrid[this.snapGrid.length - 1];
    },
    translateTo: function (e, t, s, a, i) {
      void 0 === e && (e = 0),
        void 0 === t && (t = this.params.speed),
        void 0 === s && (s = !0),
        void 0 === a && (a = !0);
      const r = this,
        { params: n, wrapperEl: l } = r;
      if (r.animating && n.preventInteractionOnTransition) return !1;
      const o = r.minTranslate(),
        d = r.maxTranslate();
      let c;
      if (
        ((c = a && e > o ? o : a && e < d ? d : e),
          r.updateProgress(c),
          n.cssMode)
      ) {
        const e = r.isHorizontal();
        if (0 === t) l[e ? "scrollLeft" : "scrollTop"] = -c;
        else {
          if (!r.support.smoothScroll)
            return (
              w({ swiper: r, targetPosition: -c, side: e ? "left" : "top" }), !0
            );
          l.scrollTo({ [e ? "left" : "top"]: -c, behavior: "smooth" });
        }
        return !0;
      }
      return (
        0 === t
          ? (r.setTransition(0),
            r.setTranslate(c),
            s &&
            (r.emit("beforeTransitionStart", t, i), r.emit("transitionEnd")))
          : (r.setTransition(t),
            r.setTranslate(c),
            s &&
            (r.emit("beforeTransitionStart", t, i),
              r.emit("transitionStart")),
            r.animating ||
            ((r.animating = !0),
              r.onTranslateToWrapperTransitionEnd ||
              (r.onTranslateToWrapperTransitionEnd = function (e) {
                r &&
                  !r.destroyed &&
                  e.target === this &&
                  (r.$wrapperEl[0].removeEventListener(
                    "transitionend",
                    r.onTranslateToWrapperTransitionEnd
                  ),
                    r.$wrapperEl[0].removeEventListener(
                      "webkitTransitionEnd",
                      r.onTranslateToWrapperTransitionEnd
                    ),
                    (r.onTranslateToWrapperTransitionEnd = null),
                    delete r.onTranslateToWrapperTransitionEnd,
                    s && r.emit("transitionEnd"));
              }),
              r.$wrapperEl[0].addEventListener(
                "transitionend",
                r.onTranslateToWrapperTransitionEnd
              ),
              r.$wrapperEl[0].addEventListener(
                "webkitTransitionEnd",
                r.onTranslateToWrapperTransitionEnd
              ))),
        !0
      );
    },
  };
  function P(e) {
    let { swiper: t, runCallbacks: s, direction: a, step: i } = e;
    const { activeIndex: r, previousIndex: n } = t;
    let l = a;
    if (
      (l || (l = r > n ? "next" : r < n ? "prev" : "reset"),
        t.emit(`transition${i}`),
        s && r !== n)
    ) {
      if ("reset" === l) return void t.emit(`slideResetTransition${i}`);
      t.emit(`slideChangeTransition${i}`),
        "next" === l
          ? t.emit(`slideNextTransition${i}`)
          : t.emit(`slidePrevTransition${i}`);
    }
  }
  var k = {
    slideTo: function (e, t, s, a, i) {
      if (
        (void 0 === e && (e = 0),
          void 0 === t && (t = this.params.speed),
          void 0 === s && (s = !0),
          "number" != typeof e && "string" != typeof e)
      )
        throw new Error(
          `The 'index' argument cannot have type other than 'number' or 'string'. [${typeof e}] given.`
        );
      if ("string" == typeof e) {
        const t = parseInt(e, 10);
        if (!isFinite(t))
          throw new Error(
            `The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.`
          );
        e = t;
      }
      const r = this;
      let n = e;
      n < 0 && (n = 0);
      const {
        params: l,
        snapGrid: o,
        slidesGrid: d,
        previousIndex: c,
        activeIndex: p,
        rtlTranslate: u,
        wrapperEl: h,
        enabled: m,
      } = r;
      if ((r.animating && l.preventInteractionOnTransition) || (!m && !a && !i))
        return !1;
      const f = Math.min(r.params.slidesPerGroupSkip, n);
      let g = f + Math.floor((n - f) / r.params.slidesPerGroup);
      g >= o.length && (g = o.length - 1),
        (p || l.initialSlide || 0) === (c || 0) &&
        s &&
        r.emit("beforeSlideChangeStart");
      const v = -o[g];
      if ((r.updateProgress(v), l.normalizeSlideIndex))
        for (let e = 0; e < d.length; e += 1) {
          const t = -Math.floor(100 * v),
            s = Math.floor(100 * d[e]),
            a = Math.floor(100 * d[e + 1]);
          void 0 !== d[e + 1]
            ? t >= s && t < a - (a - s) / 2
              ? (n = e)
              : t >= s && t < a && (n = e + 1)
            : t >= s && (n = e);
        }
      if (r.initialized && n !== p) {
        if (!r.allowSlideNext && v < r.translate && v < r.minTranslate())
          return !1;
        if (
          !r.allowSlidePrev &&
          v > r.translate &&
          v > r.maxTranslate() &&
          (p || 0) !== n
        )
          return !1;
      }
      let b;
      if (
        ((b = n > p ? "next" : n < p ? "prev" : "reset"),
          (u && -v === r.translate) || (!u && v === r.translate))
      )
        return (
          r.updateActiveIndex(n),
          l.autoHeight && r.updateAutoHeight(),
          r.updateSlidesClasses(),
          "slide" !== l.effect && r.setTranslate(v),
          "reset" !== b && (r.transitionStart(s, b), r.transitionEnd(s, b)),
          !1
        );
      if (l.cssMode) {
        const e = r.isHorizontal(),
          s = u ? v : -v;
        if (0 === t) {
          const t = r.virtual && r.params.virtual.enabled;
          t &&
            ((r.wrapperEl.style.scrollSnapType = "none"),
              (r._immediateVirtual = !0)),
            (h[e ? "scrollLeft" : "scrollTop"] = s),
            t &&
            requestAnimationFrame(() => {
              (r.wrapperEl.style.scrollSnapType = ""),
                (r._swiperImmediateVirtual = !1);
            });
        } else {
          if (!r.support.smoothScroll)
            return (
              w({ swiper: r, targetPosition: s, side: e ? "left" : "top" }), !0
            );
          h.scrollTo({ [e ? "left" : "top"]: s, behavior: "smooth" });
        }
        return !0;
      }
      return (
        r.setTransition(t),
        r.setTranslate(v),
        r.updateActiveIndex(n),
        r.updateSlidesClasses(),
        r.emit("beforeTransitionStart", t, a),
        r.transitionStart(s, b),
        0 === t
          ? r.transitionEnd(s, b)
          : r.animating ||
          ((r.animating = !0),
            r.onSlideToWrapperTransitionEnd ||
            (r.onSlideToWrapperTransitionEnd = function (e) {
              r &&
                !r.destroyed &&
                e.target === this &&
                (r.$wrapperEl[0].removeEventListener(
                  "transitionend",
                  r.onSlideToWrapperTransitionEnd
                ),
                  r.$wrapperEl[0].removeEventListener(
                    "webkitTransitionEnd",
                    r.onSlideToWrapperTransitionEnd
                  ),
                  (r.onSlideToWrapperTransitionEnd = null),
                  delete r.onSlideToWrapperTransitionEnd,
                  r.transitionEnd(s, b));
            }),
            r.$wrapperEl[0].addEventListener(
              "transitionend",
              r.onSlideToWrapperTransitionEnd
            ),
            r.$wrapperEl[0].addEventListener(
              "webkitTransitionEnd",
              r.onSlideToWrapperTransitionEnd
            )),
        !0
      );
    },
    slideToLoop: function (e, t, s, a) {
      void 0 === e && (e = 0),
        void 0 === t && (t = this.params.speed),
        void 0 === s && (s = !0);
      const i = this;
      let r = e;
      return i.params.loop && (r += i.loopedSlides), i.slideTo(r, t, s, a);
    },
    slideNext: function (e, t, s) {
      void 0 === e && (e = this.params.speed), void 0 === t && (t = !0);
      const a = this,
        { animating: i, enabled: r, params: n } = a;
      if (!r) return a;
      let l = n.slidesPerGroup;
      "auto" === n.slidesPerView &&
        1 === n.slidesPerGroup &&
        n.slidesPerGroupAuto &&
        (l = Math.max(a.slidesPerViewDynamic("current", !0), 1));
      const o = a.activeIndex < n.slidesPerGroupSkip ? 1 : l;
      if (n.loop) {
        if (i && n.loopPreventsSlide) return !1;
        a.loopFix(), (a._clientLeft = a.$wrapperEl[0].clientLeft);
      }
      return n.rewind && a.isEnd
        ? a.slideTo(0, e, t, s)
        : a.slideTo(a.activeIndex + o, e, t, s);
    },
    slidePrev: function (e, t, s) {
      void 0 === e && (e = this.params.speed), void 0 === t && (t = !0);
      const a = this,
        {
          params: i,
          animating: r,
          snapGrid: n,
          slidesGrid: l,
          rtlTranslate: o,
          enabled: d,
        } = a;
      if (!d) return a;
      if (i.loop) {
        if (r && i.loopPreventsSlide) return !1;
        a.loopFix(), (a._clientLeft = a.$wrapperEl[0].clientLeft);
      }
      function c(e) {
        return e < 0 ? -Math.floor(Math.abs(e)) : Math.floor(e);
      }
      const p = c(o ? a.translate : -a.translate),
        u = n.map((e) => c(e));
      let h = n[u.indexOf(p) - 1];
      if (void 0 === h && i.cssMode) {
        let e;
        n.forEach((t, s) => {
          p >= t && (e = s);
        }),
          void 0 !== e && (h = n[e > 0 ? e - 1 : e]);
      }
      let m = 0;
      if (
        (void 0 !== h &&
          ((m = l.indexOf(h)),
            m < 0 && (m = a.activeIndex - 1),
            "auto" === i.slidesPerView &&
            1 === i.slidesPerGroup &&
            i.slidesPerGroupAuto &&
            ((m = m - a.slidesPerViewDynamic("previous", !0) + 1),
              (m = Math.max(m, 0)))),
          i.rewind && a.isBeginning)
      ) {
        const i =
          a.params.virtual && a.params.virtual.enabled && a.virtual
            ? a.virtual.slides.length - 1
            : a.slides.length - 1;
        return a.slideTo(i, e, t, s);
      }
      return a.slideTo(m, e, t, s);
    },
    slideReset: function (e, t, s) {
      return (
        void 0 === e && (e = this.params.speed),
        void 0 === t && (t = !0),
        this.slideTo(this.activeIndex, e, t, s)
      );
    },
    slideToClosest: function (e, t, s, a) {
      void 0 === e && (e = this.params.speed),
        void 0 === t && (t = !0),
        void 0 === a && (a = 0.5);
      const i = this;
      let r = i.activeIndex;
      const n = Math.min(i.params.slidesPerGroupSkip, r),
        l = n + Math.floor((r - n) / i.params.slidesPerGroup),
        o = i.rtlTranslate ? i.translate : -i.translate;
      if (o >= i.snapGrid[l]) {
        const e = i.snapGrid[l];
        o - e > (i.snapGrid[l + 1] - e) * a && (r += i.params.slidesPerGroup);
      } else {
        const e = i.snapGrid[l - 1];
        o - e <= (i.snapGrid[l] - e) * a && (r -= i.params.slidesPerGroup);
      }
      return (
        (r = Math.max(r, 0)),
        (r = Math.min(r, i.slidesGrid.length - 1)),
        i.slideTo(r, e, t, s)
      );
    },
    slideToClickedSlide: function () {
      const e = this,
        { params: t, $wrapperEl: s } = e,
        a =
          "auto" === t.slidesPerView
            ? e.slidesPerViewDynamic()
            : t.slidesPerView;
      let i,
        r = e.clickedIndex;
      if (t.loop) {
        if (e.animating) return;
        (i = parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"), 10)),
          t.centeredSlides
            ? r < e.loopedSlides - a / 2 ||
              r > e.slides.length - e.loopedSlides + a / 2
              ? (e.loopFix(),
                (r = s
                  .children(
                    `.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})`
                  )
                  .eq(0)
                  .index()),
                p(() => {
                  e.slideTo(r);
                }))
              : e.slideTo(r)
            : r > e.slides.length - a
              ? (e.loopFix(),
                (r = s
                  .children(
                    `.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})`
                  )
                  .eq(0)
                  .index()),
                p(() => {
                  e.slideTo(r);
                }))
              : e.slideTo(r);
      } else e.slideTo(r);
    },
  };
  var z = {
    loopCreate: function () {
      const e = this,
        t = a(),
        { params: s, $wrapperEl: i } = e,
        r = i.children().length > 0 ? d(i.children()[0].parentNode) : i;
      r.children(`.${s.slideClass}.${s.slideDuplicateClass}`).remove();
      let n = r.children(`.${s.slideClass}`);
      if (s.loopFillGroupWithBlank) {
        const e = s.slidesPerGroup - (n.length % s.slidesPerGroup);
        if (e !== s.slidesPerGroup) {
          for (let a = 0; a < e; a += 1) {
            const e = d(t.createElement("div")).addClass(
              `${s.slideClass} ${s.slideBlankClass}`
            );
            r.append(e);
          }
          n = r.children(`.${s.slideClass}`);
        }
      }
      "auto" !== s.slidesPerView ||
        s.loopedSlides ||
        (s.loopedSlides = n.length),
        (e.loopedSlides = Math.ceil(
          parseFloat(s.loopedSlides || s.slidesPerView, 10)
        )),
        (e.loopedSlides += s.loopAdditionalSlides),
        e.loopedSlides > n.length && (e.loopedSlides = n.length);
      const l = [],
        o = [];
      n.each((t, s) => {
        const a = d(t);
        s < e.loopedSlides && o.push(t),
          s < n.length && s >= n.length - e.loopedSlides && l.push(t),
          a.attr("data-swiper-slide-index", s);
      });
      for (let e = 0; e < o.length; e += 1)
        r.append(d(o[e].cloneNode(!0)).addClass(s.slideDuplicateClass));
      for (let e = l.length - 1; e >= 0; e -= 1)
        r.prepend(d(l[e].cloneNode(!0)).addClass(s.slideDuplicateClass));
    },
    loopFix: function () {
      const e = this;
      e.emit("beforeLoopFix");
      const {
        activeIndex: t,
        slides: s,
        loopedSlides: a,
        allowSlidePrev: i,
        allowSlideNext: r,
        snapGrid: n,
        rtlTranslate: l,
      } = e;
      let o;
      (e.allowSlidePrev = !0), (e.allowSlideNext = !0);
      const d = -n[t] - e.getTranslate();
      if (t < a) {
        (o = s.length - 3 * a + t), (o += a);
        e.slideTo(o, 0, !1, !0) &&
          0 !== d &&
          e.setTranslate((l ? -e.translate : e.translate) - d);
      } else if (t >= s.length - a) {
        (o = -s.length + t + a), (o += a);
        e.slideTo(o, 0, !1, !0) &&
          0 !== d &&
          e.setTranslate((l ? -e.translate : e.translate) - d);
      }
      (e.allowSlidePrev = i), (e.allowSlideNext = r), e.emit("loopFix");
    },
    loopDestroy: function () {
      const { $wrapperEl: e, params: t, slides: s } = this;
      e
        .children(
          `.${t.slideClass}.${t.slideDuplicateClass},.${t.slideClass}.${t.slideBlankClass}`
        )
        .remove(),
        s.removeAttr("data-swiper-slide-index");
    },
  };
  function O(e) {
    const t = this,
      s = a(),
      i = r(),
      n = t.touchEventsData,
      { params: l, touches: o, enabled: c } = t;
    if (!c) return;
    if (t.animating && l.preventInteractionOnTransition) return;
    !t.animating && l.cssMode && l.loop && t.loopFix();
    let p = e;
    p.originalEvent && (p = p.originalEvent);
    let h = d(p.target);
    if ("wrapper" === l.touchEventsTarget && !h.closest(t.wrapperEl).length)
      return;
    if (
      ((n.isTouchEvent = "touchstart" === p.type),
        !n.isTouchEvent && "which" in p && 3 === p.which)
    )
      return;
    if (!n.isTouchEvent && "button" in p && p.button > 0) return;
    if (n.isTouched && n.isMoved) return;
    !!l.noSwipingClass &&
      "" !== l.noSwipingClass &&
      p.target &&
      p.target.shadowRoot &&
      e.path &&
      e.path[0] &&
      (h = d(e.path[0]));
    const m = l.noSwipingSelector
      ? l.noSwipingSelector
      : `.${l.noSwipingClass}`,
      f = !(!p.target || !p.target.shadowRoot);
    if (
      l.noSwiping &&
      (f
        ? (function (e, t) {
          return (
            void 0 === t && (t = this),
            (function t(s) {
              return s && s !== a() && s !== r()
                ? (s.assignedSlot && (s = s.assignedSlot),
                  s.closest(e) || t(s.getRootNode().host))
                : null;
            })(t)
          );
        })(m, p.target)
        : h.closest(m)[0])
    )
      return void (t.allowClick = !0);
    if (l.swipeHandler && !h.closest(l.swipeHandler)[0]) return;
    (o.currentX = "touchstart" === p.type ? p.targetTouches[0].pageX : p.pageX),
      (o.currentY =
        "touchstart" === p.type ? p.targetTouches[0].pageY : p.pageY);
    const g = o.currentX,
      v = o.currentY,
      w = l.edgeSwipeDetection || l.iOSEdgeSwipeDetection,
      b = l.edgeSwipeThreshold || l.iOSEdgeSwipeThreshold;
    if (w && (g <= b || g >= i.innerWidth - b)) {
      if ("prevent" !== w) return;
      e.preventDefault();
    }
    if (
      (Object.assign(n, {
        isTouched: !0,
        isMoved: !1,
        allowTouchCallbacks: !0,
        isScrolling: void 0,
        startMoving: void 0,
      }),
        (o.startX = g),
        (o.startY = v),
        (n.touchStartTime = u()),
        (t.allowClick = !0),
        t.updateSize(),
        (t.swipeDirection = void 0),
        l.threshold > 0 && (n.allowThresholdMove = !1),
        "touchstart" !== p.type)
    ) {
      let e = !0;
      h.is(n.focusableElements) &&
        ((e = !1), "SELECT" === h[0].nodeName && (n.isTouched = !1)),
        s.activeElement &&
        d(s.activeElement).is(n.focusableElements) &&
        s.activeElement !== h[0] &&
        s.activeElement.blur();
      const a = e && t.allowTouchMove && l.touchStartPreventDefault;
      (!l.touchStartForcePreventDefault && !a) ||
        h[0].isContentEditable ||
        p.preventDefault();
    }
    t.params.freeMode &&
      t.params.freeMode.enabled &&
      t.freeMode &&
      t.animating &&
      !l.cssMode &&
      t.freeMode.onTouchStart(),
      t.emit("touchStart", p);
  }
  function I(e) {
    const t = a(),
      s = this,
      i = s.touchEventsData,
      { params: r, touches: n, rtlTranslate: l, enabled: o } = s;
    if (!o) return;
    let c = e;
    if ((c.originalEvent && (c = c.originalEvent), !i.isTouched))
      return void (
        i.startMoving &&
        i.isScrolling &&
        s.emit("touchMoveOpposite", c)
      );
    if (i.isTouchEvent && "touchmove" !== c.type) return;
    const p =
      "touchmove" === c.type &&
      c.targetTouches &&
      (c.targetTouches[0] || c.changedTouches[0]),
      h = "touchmove" === c.type ? p.pageX : c.pageX,
      m = "touchmove" === c.type ? p.pageY : c.pageY;
    if (c.preventedByNestedSwiper) return (n.startX = h), void (n.startY = m);
    if (!s.allowTouchMove)
      return (
        d(c.target).is(i.focusableElements) || (s.allowClick = !1),
        void (
          i.isTouched &&
          (Object.assign(n, { startX: h, startY: m, currentX: h, currentY: m }),
            (i.touchStartTime = u()))
        )
      );
    if (i.isTouchEvent && r.touchReleaseOnEdges && !r.loop)
      if (s.isVertical()) {
        if (
          (m < n.startY && s.translate <= s.maxTranslate()) ||
          (m > n.startY && s.translate >= s.minTranslate())
        )
          return (i.isTouched = !1), void (i.isMoved = !1);
      } else if (
        (h < n.startX && s.translate <= s.maxTranslate()) ||
        (h > n.startX && s.translate >= s.minTranslate())
      )
        return;
    if (
      i.isTouchEvent &&
      t.activeElement &&
      c.target === t.activeElement &&
      d(c.target).is(i.focusableElements)
    )
      return (i.isMoved = !0), void (s.allowClick = !1);
    if (
      (i.allowTouchCallbacks && s.emit("touchMove", c),
        c.targetTouches && c.targetTouches.length > 1)
    )
      return;
    (n.currentX = h), (n.currentY = m);
    const f = n.currentX - n.startX,
      g = n.currentY - n.startY;
    if (s.params.threshold && Math.sqrt(f ** 2 + g ** 2) < s.params.threshold)
      return;
    if (void 0 === i.isScrolling) {
      let e;
      (s.isHorizontal() && n.currentY === n.startY) ||
        (s.isVertical() && n.currentX === n.startX)
        ? (i.isScrolling = !1)
        : f * f + g * g >= 25 &&
        ((e = (180 * Math.atan2(Math.abs(g), Math.abs(f))) / Math.PI),
          (i.isScrolling = s.isHorizontal()
            ? e > r.touchAngle
            : 90 - e > r.touchAngle));
    }
    if (
      (i.isScrolling && s.emit("touchMoveOpposite", c),
        void 0 === i.startMoving &&
        ((n.currentX === n.startX && n.currentY === n.startY) ||
          (i.startMoving = !0)),
        i.isScrolling)
    )
      return void (i.isTouched = !1);
    if (!i.startMoving) return;
    (s.allowClick = !1),
      !r.cssMode && c.cancelable && c.preventDefault(),
      r.touchMoveStopPropagation && !r.nested && c.stopPropagation(),
      i.isMoved ||
      (r.loop && !r.cssMode && s.loopFix(),
        (i.startTranslate = s.getTranslate()),
        s.setTransition(0),
        s.animating &&
        s.$wrapperEl.trigger("webkitTransitionEnd transitionend"),
        (i.allowMomentumBounce = !1),
        !r.grabCursor ||
        (!0 !== s.allowSlideNext && !0 !== s.allowSlidePrev) ||
        s.setGrabCursor(!0),
        s.emit("sliderFirstMove", c)),
      s.emit("sliderMove", c),
      (i.isMoved = !0);
    let v = s.isHorizontal() ? f : g;
    (n.diff = v),
      (v *= r.touchRatio),
      l && (v = -v),
      (s.swipeDirection = v > 0 ? "prev" : "next"),
      (i.currentTranslate = v + i.startTranslate);
    let w = !0,
      b = r.resistanceRatio;
    if (
      (r.touchReleaseOnEdges && (b = 0),
        v > 0 && i.currentTranslate > s.minTranslate()
          ? ((w = !1),
            r.resistance &&
            (i.currentTranslate =
              s.minTranslate() -
              1 +
              (-s.minTranslate() + i.startTranslate + v) ** b))
          : v < 0 &&
          i.currentTranslate < s.maxTranslate() &&
          ((w = !1),
            r.resistance &&
            (i.currentTranslate =
              s.maxTranslate() +
              1 -
              (s.maxTranslate() - i.startTranslate - v) ** b)),
        w && (c.preventedByNestedSwiper = !0),
        !s.allowSlideNext &&
        "next" === s.swipeDirection &&
        i.currentTranslate < i.startTranslate &&
        (i.currentTranslate = i.startTranslate),
        !s.allowSlidePrev &&
        "prev" === s.swipeDirection &&
        i.currentTranslate > i.startTranslate &&
        (i.currentTranslate = i.startTranslate),
        s.allowSlidePrev ||
        s.allowSlideNext ||
        (i.currentTranslate = i.startTranslate),
        r.threshold > 0)
    ) {
      if (!(Math.abs(v) > r.threshold || i.allowThresholdMove))
        return void (i.currentTranslate = i.startTranslate);
      if (!i.allowThresholdMove)
        return (
          (i.allowThresholdMove = !0),
          (n.startX = n.currentX),
          (n.startY = n.currentY),
          (i.currentTranslate = i.startTranslate),
          void (n.diff = s.isHorizontal()
            ? n.currentX - n.startX
            : n.currentY - n.startY)
        );
    }
    r.followFinger &&
      !r.cssMode &&
      (((r.freeMode && r.freeMode.enabled && s.freeMode) ||
        r.watchSlidesProgress) &&
        (s.updateActiveIndex(), s.updateSlidesClasses()),
        s.params.freeMode &&
        r.freeMode.enabled &&
        s.freeMode &&
        s.freeMode.onTouchMove(),
        s.updateProgress(i.currentTranslate),
        s.setTranslate(i.currentTranslate));
  }
  function L(e) {
    const t = this,
      s = t.touchEventsData,
      { params: a, touches: i, rtlTranslate: r, slidesGrid: n, enabled: l } = t;
    if (!l) return;
    let o = e;
    if (
      (o.originalEvent && (o = o.originalEvent),
        s.allowTouchCallbacks && t.emit("touchEnd", o),
        (s.allowTouchCallbacks = !1),
        !s.isTouched)
    )
      return (
        s.isMoved && a.grabCursor && t.setGrabCursor(!1),
        (s.isMoved = !1),
        void (s.startMoving = !1)
      );
    a.grabCursor &&
      s.isMoved &&
      s.isTouched &&
      (!0 === t.allowSlideNext || !0 === t.allowSlidePrev) &&
      t.setGrabCursor(!1);
    const d = u(),
      c = d - s.touchStartTime;
    if (t.allowClick) {
      const e = o.path || (o.composedPath && o.composedPath());
      t.updateClickedSlide((e && e[0]) || o.target),
        t.emit("tap click", o),
        c < 300 &&
        d - s.lastClickTime < 300 &&
        t.emit("doubleTap doubleClick", o);
    }
    if (
      ((s.lastClickTime = u()),
        p(() => {
          t.destroyed || (t.allowClick = !0);
        }),
        !s.isTouched ||
        !s.isMoved ||
        !t.swipeDirection ||
        0 === i.diff ||
        s.currentTranslate === s.startTranslate)
    )
      return (s.isTouched = !1), (s.isMoved = !1), void (s.startMoving = !1);
    let h;
    if (
      ((s.isTouched = !1),
        (s.isMoved = !1),
        (s.startMoving = !1),
        (h = a.followFinger
          ? r
            ? t.translate
            : -t.translate
          : -s.currentTranslate),
        a.cssMode)
    )
      return;
    if (t.params.freeMode && a.freeMode.enabled)
      return void t.freeMode.onTouchEnd({ currentPos: h });
    let m = 0,
      f = t.slidesSizesGrid[0];
    for (
      let e = 0;
      e < n.length;
      e += e < a.slidesPerGroupSkip ? 1 : a.slidesPerGroup
    ) {
      const t = e < a.slidesPerGroupSkip - 1 ? 1 : a.slidesPerGroup;
      void 0 !== n[e + t]
        ? h >= n[e] && h < n[e + t] && ((m = e), (f = n[e + t] - n[e]))
        : h >= n[e] && ((m = e), (f = n[n.length - 1] - n[n.length - 2]));
    }
    let g = null,
      v = null;
    a.rewind &&
      (t.isBeginning
        ? (v =
          t.params.virtual && t.params.virtual.enabled && t.virtual
            ? t.virtual.slides.length - 1
            : t.slides.length - 1)
        : t.isEnd && (g = 0));
    const w = (h - n[m]) / f,
      b = m < a.slidesPerGroupSkip - 1 ? 1 : a.slidesPerGroup;
    if (c > a.longSwipesMs) {
      if (!a.longSwipes) return void t.slideTo(t.activeIndex);
      "next" === t.swipeDirection &&
        (w >= a.longSwipesRatio
          ? t.slideTo(a.rewind && t.isEnd ? g : m + b)
          : t.slideTo(m)),
        "prev" === t.swipeDirection &&
        (w > 1 - a.longSwipesRatio
          ? t.slideTo(m + b)
          : null !== v && w < 0 && Math.abs(w) > a.longSwipesRatio
            ? t.slideTo(v)
            : t.slideTo(m));
    } else {
      if (!a.shortSwipes) return void t.slideTo(t.activeIndex);
      t.navigation &&
        (o.target === t.navigation.nextEl || o.target === t.navigation.prevEl)
        ? o.target === t.navigation.nextEl
          ? t.slideTo(m + b)
          : t.slideTo(m)
        : ("next" === t.swipeDirection && t.slideTo(null !== g ? g : m + b),
          "prev" === t.swipeDirection && t.slideTo(null !== v ? v : m));
    }
  }
  function A() {
    const e = this,
      { params: t, el: s } = e;
    if (s && 0 === s.offsetWidth) return;
    t.breakpoints && e.setBreakpoint();
    const { allowSlideNext: a, allowSlidePrev: i, snapGrid: r } = e;
    (e.allowSlideNext = !0),
      (e.allowSlidePrev = !0),
      e.updateSize(),
      e.updateSlides(),
      e.updateSlidesClasses(),
      ("auto" === t.slidesPerView || t.slidesPerView > 1) &&
        e.isEnd &&
        !e.isBeginning &&
        !e.params.centeredSlides
        ? e.slideTo(e.slides.length - 1, 0, !1, !0)
        : e.slideTo(e.activeIndex, 0, !1, !0),
      e.autoplay && e.autoplay.running && e.autoplay.paused && e.autoplay.run(),
      (e.allowSlidePrev = i),
      (e.allowSlideNext = a),
      e.params.watchOverflow && r !== e.snapGrid && e.checkOverflow();
  }
  function D(e) {
    const t = this;
    t.enabled &&
      (t.allowClick ||
        (t.params.preventClicks && e.preventDefault(),
          t.params.preventClicksPropagation &&
          t.animating &&
          (e.stopPropagation(), e.stopImmediatePropagation())));
  }
  function G() {
    const e = this,
      { wrapperEl: t, rtlTranslate: s, enabled: a } = e;
    if (!a) return;
    let i;
    (e.previousTranslate = e.translate),
      e.isHorizontal()
        ? (e.translate = -t.scrollLeft)
        : (e.translate = -t.scrollTop),
      -0 === e.translate && (e.translate = 0),
      e.updateActiveIndex(),
      e.updateSlidesClasses();
    const r = e.maxTranslate() - e.minTranslate();
    (i = 0 === r ? 0 : (e.translate - e.minTranslate()) / r),
      i !== e.progress && e.updateProgress(s ? -e.translate : e.translate),
      e.emit("setTranslate", e.translate, !1);
  }
  let B = !1;
  function N() { }
  const H = (e, t) => {
    const s = a(),
      {
        params: i,
        touchEvents: r,
        el: n,
        wrapperEl: l,
        device: o,
        support: d,
      } = e,
      c = !!i.nested,
      p = "on" === t ? "addEventListener" : "removeEventListener",
      u = t;
    if (d.touch) {
      const t = !(
        "touchstart" !== r.start ||
        !d.passiveListener ||
        !i.passiveListeners
      ) && { passive: !0, capture: !1 };
      n[p](r.start, e.onTouchStart, t),
        n[p](
          r.move,
          e.onTouchMove,
          d.passiveListener ? { passive: !1, capture: c } : c
        ),
        n[p](r.end, e.onTouchEnd, t),
        r.cancel && n[p](r.cancel, e.onTouchEnd, t);
    } else
      n[p](r.start, e.onTouchStart, !1),
        s[p](r.move, e.onTouchMove, c),
        s[p](r.end, e.onTouchEnd, !1);
    (i.preventClicks || i.preventClicksPropagation) &&
      n[p]("click", e.onClick, !0),
      i.cssMode && l[p]("scroll", e.onScroll),
      i.updateOnWindowResize
        ? e[u](
          o.ios || o.android
            ? "resize orientationchange observerUpdate"
            : "resize observerUpdate",
          A,
          !0
        )
        : e[u]("observerUpdate", A, !0);
  };
  var X = {
    attachEvents: function () {
      const e = this,
        t = a(),
        { params: s, support: i } = e;
      (e.onTouchStart = O.bind(e)),
        (e.onTouchMove = I.bind(e)),
        (e.onTouchEnd = L.bind(e)),
        s.cssMode && (e.onScroll = G.bind(e)),
        (e.onClick = D.bind(e)),
        i.touch && !B && (t.addEventListener("touchstart", N), (B = !0)),
        H(e, "on");
    },
    detachEvents: function () {
      H(this, "off");
    },
  };
  const Y = (e, t) => e.grid && t.grid && t.grid.rows > 1;
  var R = {
    addClasses: function () {
      const e = this,
        { classNames: t, params: s, rtl: a, $el: i, device: r, support: n } = e,
        l = (function (e, t) {
          const s = [];
          return (
            e.forEach((e) => {
              "object" == typeof e
                ? Object.keys(e).forEach((a) => {
                  e[a] && s.push(t + a);
                })
                : "string" == typeof e && s.push(t + e);
            }),
            s
          );
        })(
          [
            "initialized",
            s.direction,
            { "pointer-events": !n.touch },
            { "free-mode": e.params.freeMode && s.freeMode.enabled },
            { autoheight: s.autoHeight },
            { rtl: a },
            { grid: s.grid && s.grid.rows > 1 },
            {
              "grid-column":
                s.grid && s.grid.rows > 1 && "column" === s.grid.fill,
            },
            { android: r.android },
            { ios: r.ios },
            { "css-mode": s.cssMode },
            { centered: s.cssMode && s.centeredSlides },
          ],
          s.containerModifierClass
        );
      t.push(...l), i.addClass([...t].join(" ")), e.emitContainerClasses();
    },
    removeClasses: function () {
      const { $el: e, classNames: t } = this;
      e.removeClass(t.join(" ")), this.emitContainerClasses();
    },
  };
  var W = {
    init: !0,
    direction: "horizontal",
    touchEventsTarget: "wrapper",
    initialSlide: 0,
    speed: 300,
    cssMode: !1,
    updateOnWindowResize: !0,
    resizeObserver: !0,
    nested: !1,
    createElements: !1,
    enabled: !0,
    focusableElements: "input, select, option, textarea, button, video, label",
    width: null,
    height: null,
    preventInteractionOnTransition: !1,
    userAgent: null,
    url: null,
    edgeSwipeDetection: !1,
    edgeSwipeThreshold: 20,
    autoHeight: !1,
    setWrapperSize: !1,
    virtualTranslate: !1,
    effect: "slide",
    breakpoints: void 0,
    breakpointsBase: "window",
    spaceBetween: 0,
    slidesPerView: 1,
    slidesPerGroup: 1,
    slidesPerGroupSkip: 0,
    slidesPerGroupAuto: !1,
    centeredSlides: !1,
    centeredSlidesBounds: !1,
    slidesOffsetBefore: 0,
    slidesOffsetAfter: 0,
    normalizeSlideIndex: !0,
    centerInsufficientSlides: !1,
    watchOverflow: !1,
    roundLengths: !1,
    touchRatio: 1,
    touchAngle: 45,
    simulateTouch: !0,
    shortSwipes: !0,
    longSwipes: !0,
    longSwipesRatio: 0.5,
    longSwipesMs: 300,
    followFinger: !0,
    allowTouchMove: !0,
    threshold: 0,
    touchMoveStopPropagation: !1,
    touchStartPreventDefault: !0,
    touchStartForcePreventDefault: !1,
    touchReleaseOnEdges: !1,
    uniqueNavElements: !0,
    resistance: !0,
    resistanceRatio: 0.85,
    watchSlidesProgress: !1,
    grabCursor: !1,
    preventClicks: !0,
    preventClicksPropagation: !0,
    slideToClickedSlide: !1,
    preloadImages: !0,
    updateOnImagesReady: !0,
    loop: !1,
    loopAdditionalSlides: 0,
    loopedSlides: null,
    loopFillGroupWithBlank: !1,
    loopPreventsSlide: !0,
    rewind: !1,
    allowSlidePrev: !0,
    allowSlideNext: !0,
    swipeHandler: null,
    noSwiping: !0,
    noSwipingClass: "swiper-no-swiping",
    noSwipingSelector: null,
    passiveListeners: !0,
    maxBackfaceHiddenSlides: 10,
    containerModifierClass: "swiper-",
    slideClass: "swiper-slide",
    slideBlankClass: "swiper-slide-invisible-blank",
    slideActiveClass: "swiper-slide-active",
    slideDuplicateActiveClass: "swiper-slide-duplicate-active",
    slideVisibleClass: "swiper-slide-visible",
    slideDuplicateClass: "swiper-slide-duplicate",
    slideNextClass: "swiper-slide-next",
    slideDuplicateNextClass: "swiper-slide-duplicate-next",
    slidePrevClass: "swiper-slide-prev",
    slideDuplicatePrevClass: "swiper-slide-duplicate-prev",
    wrapperClass: "swiper-wrapper",
    runCallbacksOnInit: !0,
    _emitClasses: !1,
  };
  function j(e, t) {
    return function (s) {
      void 0 === s && (s = {});
      const a = Object.keys(s)[0],
        i = s[a];
      "object" == typeof i && null !== i
        ? (["navigation", "pagination", "scrollbar"].indexOf(a) >= 0 &&
          !0 === e[a] &&
          (e[a] = { auto: !0 }),
          a in e && "enabled" in i
            ? (!0 === e[a] && (e[a] = { enabled: !0 }),
              "object" != typeof e[a] ||
              "enabled" in e[a] ||
              (e[a].enabled = !0),
              e[a] || (e[a] = { enabled: !1 }),
              g(t, s))
            : g(t, s))
        : g(t, s);
    };
  }
  const _ = {
    eventsEmitter: $,
    update: S,
    translate: M,
    transition: {
      setTransition: function (e, t) {
        const s = this;
        s.params.cssMode || s.$wrapperEl.transition(e),
          s.emit("setTransition", e, t);
      },
      transitionStart: function (e, t) {
        void 0 === e && (e = !0);
        const s = this,
          { params: a } = s;
        a.cssMode ||
          (a.autoHeight && s.updateAutoHeight(),
            P({ swiper: s, runCallbacks: e, direction: t, step: "Start" }));
      },
      transitionEnd: function (e, t) {
        void 0 === e && (e = !0);
        const s = this,
          { params: a } = s;
        (s.animating = !1),
          a.cssMode ||
          (s.setTransition(0),
            P({ swiper: s, runCallbacks: e, direction: t, step: "End" }));
      },
    },
    slide: k,
    loop: z,
    grabCursor: {
      setGrabCursor: function (e) {
        const t = this;
        if (
          t.support.touch ||
          !t.params.simulateTouch ||
          (t.params.watchOverflow && t.isLocked) ||
          t.params.cssMode
        )
          return;
        const s =
          "container" === t.params.touchEventsTarget ? t.el : t.wrapperEl;
        (s.style.cursor = "move"),
          (s.style.cursor = e ? "-webkit-grabbing" : "-webkit-grab"),
          (s.style.cursor = e ? "-moz-grabbin" : "-moz-grab"),
          (s.style.cursor = e ? "grabbing" : "grab");
      },
      unsetGrabCursor: function () {
        const e = this;
        e.support.touch ||
          (e.params.watchOverflow && e.isLocked) ||
          e.params.cssMode ||
          (e[
            "container" === e.params.touchEventsTarget ? "el" : "wrapperEl"
          ].style.cursor = "");
      },
    },
    events: X,
    breakpoints: {
      setBreakpoint: function () {
        const e = this,
          {
            activeIndex: t,
            initialized: s,
            loopedSlides: a = 0,
            params: i,
            $el: r,
          } = e,
          n = i.breakpoints;
        if (!n || (n && 0 === Object.keys(n).length)) return;
        const l = e.getBreakpoint(n, e.params.breakpointsBase, e.el);
        if (!l || e.currentBreakpoint === l) return;
        const o = (l in n ? n[l] : void 0) || e.originalParams,
          d = Y(e, i),
          c = Y(e, o),
          p = i.enabled;
        d && !c
          ? (r.removeClass(
            `${i.containerModifierClass}grid ${i.containerModifierClass}grid-column`
          ),
            e.emitContainerClasses())
          : !d &&
          c &&
          (r.addClass(`${i.containerModifierClass}grid`),
            ((o.grid.fill && "column" === o.grid.fill) ||
              (!o.grid.fill && "column" === i.grid.fill)) &&
            r.addClass(`${i.containerModifierClass}grid-column`),
            e.emitContainerClasses());
        const u = o.direction && o.direction !== i.direction,
          h = i.loop && (o.slidesPerView !== i.slidesPerView || u);
        u && s && e.changeDirection(), g(e.params, o);
        const m = e.params.enabled;
        Object.assign(e, {
          allowTouchMove: e.params.allowTouchMove,
          allowSlideNext: e.params.allowSlideNext,
          allowSlidePrev: e.params.allowSlidePrev,
        }),
          p && !m ? e.disable() : !p && m && e.enable(),
          (e.currentBreakpoint = l),
          e.emit("_beforeBreakpoint", o),
          h &&
          s &&
          (e.loopDestroy(),
            e.loopCreate(),
            e.updateSlides(),
            e.slideTo(t - a + e.loopedSlides, 0, !1)),
          e.emit("breakpoint", o);
      },
      getBreakpoint: function (e, t, s) {
        if ((void 0 === t && (t = "window"), !e || ("container" === t && !s)))
          return;
        let a = !1;
        const i = r(),
          n = "window" === t ? i.innerHeight : s.clientHeight,
          l = Object.keys(e).map((e) => {
            if ("string" == typeof e && 0 === e.indexOf("@")) {
              const t = parseFloat(e.substr(1));
              return { value: n * t, point: e };
            }
            return { value: e, point: e };
          });
        l.sort((e, t) => parseInt(e.value, 10) - parseInt(t.value, 10));
        for (let e = 0; e < l.length; e += 1) {
          const { point: r, value: n } = l[e];
          "window" === t
            ? i.matchMedia(`(min-width: ${n}px)`).matches && (a = r)
            : n <= s.clientWidth && (a = r);
        }
        return a || "max";
      },
    },
    checkOverflow: {
      checkOverflow: function () {
        const e = this,
          { isLocked: t, params: s } = e,
          { slidesOffsetBefore: a } = s;
        if (a) {
          const t = e.slides.length - 1,
            s = e.slidesGrid[t] + e.slidesSizesGrid[t] + 2 * a;
          e.isLocked = e.size > s;
        } else e.isLocked = 1 === e.snapGrid.length;
        !0 === s.allowSlideNext && (e.allowSlideNext = !e.isLocked),
          !0 === s.allowSlidePrev && (e.allowSlidePrev = !e.isLocked),
          t && t !== e.isLocked && (e.isEnd = !1),
          t !== e.isLocked && e.emit(e.isLocked ? "lock" : "unlock");
      },
    },
    classes: R,
    images: {
      loadImage: function (e, t, s, a, i, n) {
        const l = r();
        let o;
        function c() {
          n && n();
        }
        d(e).parent("picture")[0] || (e.complete && i)
          ? c()
          : t
            ? ((o = new l.Image()),
              (o.onload = c),
              (o.onerror = c),
              a && (o.sizes = a),
              s && (o.srcset = s),
              t && (o.src = t))
            : c();
      },
      preloadImages: function () {
        const e = this;
        function t() {
          null != e &&
            e &&
            !e.destroyed &&
            (void 0 !== e.imagesLoaded && (e.imagesLoaded += 1),
              e.imagesLoaded === e.imagesToLoad.length &&
              (e.params.updateOnImagesReady && e.update(),
                e.emit("imagesReady")));
        }
        e.imagesToLoad = e.$el.find("img");
        for (let s = 0; s < e.imagesToLoad.length; s += 1) {
          const a = e.imagesToLoad[s];
          e.loadImage(
            a,
            a.currentSrc || a.getAttribute("src"),
            a.srcset || a.getAttribute("srcset"),
            a.sizes || a.getAttribute("sizes"),
            !0,
            t
          );
        }
      },
    },
  },
    V = {};
  class q {
    constructor() {
      let e, t;
      for (var s = arguments.length, a = new Array(s), i = 0; i < s; i++)
        a[i] = arguments[i];
      if (
        (1 === a.length &&
          a[0].constructor &&
          "Object" === Object.prototype.toString.call(a[0]).slice(8, -1)
          ? (t = a[0])
          : ([e, t] = a),
          t || (t = {}),
          (t = g({}, t)),
          e && !t.el && (t.el = e),
          t.el && d(t.el).length > 1)
      ) {
        const e = [];
        return (
          d(t.el).each((s) => {
            const a = g({}, t, { el: s });
            e.push(new q(a));
          }),
          e
        );
      }
      const r = this;
      (r.__swiper__ = !0),
        (r.support = E()),
        (r.device = T({ userAgent: t.userAgent })),
        (r.browser = C()),
        (r.eventsListeners = {}),
        (r.eventsAnyListeners = []),
        (r.modules = [...r.__modules__]),
        t.modules && Array.isArray(t.modules) && r.modules.push(...t.modules);
      const n = {};
      r.modules.forEach((e) => {
        e({
          swiper: r,
          extendParams: j(t, n),
          on: r.on.bind(r),
          once: r.once.bind(r),
          off: r.off.bind(r),
          emit: r.emit.bind(r),
        });
      });
      const l = g({}, W, n);
      return (
        (r.params = g({}, l, V, t)),
        (r.originalParams = g({}, r.params)),
        (r.passedParams = g({}, t)),
        r.params &&
        r.params.on &&
        Object.keys(r.params.on).forEach((e) => {
          r.on(e, r.params.on[e]);
        }),
        r.params && r.params.onAny && r.onAny(r.params.onAny),
        (r.$ = d),
        Object.assign(r, {
          enabled: r.params.enabled,
          el: e,
          classNames: [],
          slides: d(),
          slidesGrid: [],
          snapGrid: [],
          slidesSizesGrid: [],
          isHorizontal: () => "horizontal" === r.params.direction,
          isVertical: () => "vertical" === r.params.direction,
          activeIndex: 0,
          realIndex: 0,
          isBeginning: !0,
          isEnd: !1,
          translate: 0,
          previousTranslate: 0,
          progress: 0,
          velocity: 0,
          animating: !1,
          allowSlideNext: r.params.allowSlideNext,
          allowSlidePrev: r.params.allowSlidePrev,
          touchEvents: (function () {
            const e = ["touchstart", "touchmove", "touchend", "touchcancel"],
              t = ["pointerdown", "pointermove", "pointerup"];
            return (
              (r.touchEventsTouch = {
                start: e[0],
                move: e[1],
                end: e[2],
                cancel: e[3],
              }),
              (r.touchEventsDesktop = { start: t[0], move: t[1], end: t[2] }),
              r.support.touch || !r.params.simulateTouch
                ? r.touchEventsTouch
                : r.touchEventsDesktop
            );
          })(),
          touchEventsData: {
            isTouched: void 0,
            isMoved: void 0,
            allowTouchCallbacks: void 0,
            touchStartTime: void 0,
            isScrolling: void 0,
            currentTranslate: void 0,
            startTranslate: void 0,
            allowThresholdMove: void 0,
            focusableElements: r.params.focusableElements,
            lastClickTime: u(),
            clickTimeout: void 0,
            velocities: [],
            allowMomentumBounce: void 0,
            isTouchEvent: void 0,
            startMoving: void 0,
          },
          allowClick: !0,
          allowTouchMove: r.params.allowTouchMove,
          touches: { startX: 0, startY: 0, currentX: 0, currentY: 0, diff: 0 },
          imagesToLoad: [],
          imagesLoaded: 0,
        }),
        r.emit("_swiper"),
        r.params.init && r.init(),
        r
      );
    }
    enable() {
      const e = this;
      e.enabled ||
        ((e.enabled = !0),
          e.params.grabCursor && e.setGrabCursor(),
          e.emit("enable"));
    }
    disable() {
      const e = this;
      e.enabled &&
        ((e.enabled = !1),
          e.params.grabCursor && e.unsetGrabCursor(),
          e.emit("disable"));
    }
    setProgress(e, t) {
      const s = this;
      e = Math.min(Math.max(e, 0), 1);
      const a = s.minTranslate(),
        i = (s.maxTranslate() - a) * e + a;
      s.translateTo(i, void 0 === t ? 0 : t),
        s.updateActiveIndex(),
        s.updateSlidesClasses();
    }
    emitContainerClasses() {
      const e = this;
      if (!e.params._emitClasses || !e.el) return;
      const t = e.el.className
        .split(" ")
        .filter(
          (t) =>
            0 === t.indexOf("swiper") ||
            0 === t.indexOf(e.params.containerModifierClass)
        );
      e.emit("_containerClasses", t.join(" "));
    }
    getSlideClasses(e) {
      const t = this;
      return e.className
        .split(" ")
        .filter(
          (e) =>
            0 === e.indexOf("swiper-slide") ||
            0 === e.indexOf(t.params.slideClass)
        )
        .join(" ");
    }
    emitSlidesClasses() {
      const e = this;
      if (!e.params._emitClasses || !e.el) return;
      const t = [];
      e.slides.each((s) => {
        const a = e.getSlideClasses(s);
        t.push({ slideEl: s, classNames: a }), e.emit("_slideClass", s, a);
      }),
        e.emit("_slideClasses", t);
    }
    slidesPerViewDynamic(e, t) {
      void 0 === e && (e = "current"), void 0 === t && (t = !1);
      const {
        params: s,
        slides: a,
        slidesGrid: i,
        slidesSizesGrid: r,
        size: n,
        activeIndex: l,
      } = this;
      let o = 1;
      if (s.centeredSlides) {
        let e,
          t = a[l].swiperSlideSize;
        for (let s = l + 1; s < a.length; s += 1)
          a[s] &&
            !e &&
            ((t += a[s].swiperSlideSize), (o += 1), t > n && (e = !0));
        for (let s = l - 1; s >= 0; s -= 1)
          a[s] &&
            !e &&
            ((t += a[s].swiperSlideSize), (o += 1), t > n && (e = !0));
      } else if ("current" === e)
        for (let e = l + 1; e < a.length; e += 1) {
          (t ? i[e] + r[e] - i[l] < n : i[e] - i[l] < n) && (o += 1);
        }
      else
        for (let e = l - 1; e >= 0; e -= 1) {
          i[l] - i[e] < n && (o += 1);
        }
      return o;
    }
    update() {
      const e = this;
      if (!e || e.destroyed) return;
      const { snapGrid: t, params: s } = e;
      function a() {
        const t = e.rtlTranslate ? -1 * e.translate : e.translate,
          s = Math.min(Math.max(t, e.maxTranslate()), e.minTranslate());
        e.setTranslate(s), e.updateActiveIndex(), e.updateSlidesClasses();
      }
      let i;
      s.breakpoints && e.setBreakpoint(),
        e.updateSize(),
        e.updateSlides(),
        e.updateProgress(),
        e.updateSlidesClasses(),
        e.params.freeMode && e.params.freeMode.enabled
          ? (a(), e.params.autoHeight && e.updateAutoHeight())
          : ((i =
            ("auto" === e.params.slidesPerView ||
              e.params.slidesPerView > 1) &&
              e.isEnd &&
              !e.params.centeredSlides
              ? e.slideTo(e.slides.length - 1, 0, !1, !0)
              : e.slideTo(e.activeIndex, 0, !1, !0)),
            i || a()),
        s.watchOverflow && t !== e.snapGrid && e.checkOverflow(),
        e.emit("update");
    }
    changeDirection(e, t) {
      void 0 === t && (t = !0);
      const s = this,
        a = s.params.direction;
      return (
        e || (e = "horizontal" === a ? "vertical" : "horizontal"),
        e === a ||
        ("horizontal" !== e && "vertical" !== e) ||
        (s.$el
          .removeClass(`${s.params.containerModifierClass}${a}`)
          .addClass(`${s.params.containerModifierClass}${e}`),
          s.emitContainerClasses(),
          (s.params.direction = e),
          s.slides.each((t) => {
            "vertical" === e ? (t.style.width = "") : (t.style.height = "");
          }),
          s.emit("changeDirection"),
          t && s.update()),
        s
      );
    }
    mount(e) {
      const t = this;
      if (t.mounted) return !0;
      const s = d(e || t.params.el);
      if (!(e = s[0])) return !1;
      e.swiper = t;
      const i = () =>
        `.${(t.params.wrapperClass || "").trim().split(" ").join(".")}`;
      let r = (() => {
        if (e && e.shadowRoot && e.shadowRoot.querySelector) {
          const t = d(e.shadowRoot.querySelector(i()));
          return (t.children = (e) => s.children(e)), t;
        }
        return s.children(i());
      })();
      if (0 === r.length && t.params.createElements) {
        const e = a().createElement("div");
        (r = d(e)),
          (e.className = t.params.wrapperClass),
          s.append(e),
          s.children(`.${t.params.slideClass}`).each((e) => {
            r.append(e);
          });
      }
      return (
        Object.assign(t, {
          $el: s,
          el: e,
          $wrapperEl: r,
          wrapperEl: r[0],
          mounted: !0,
          rtl: "rtl" === e.dir.toLowerCase() || "rtl" === s.css("direction"),
          rtlTranslate:
            "horizontal" === t.params.direction &&
            ("rtl" === e.dir.toLowerCase() || "rtl" === s.css("direction")),
          wrongRTL: "-webkit-box" === r.css("display"),
        }),
        !0
      );
    }
    init(e) {
      const t = this;
      if (t.initialized) return t;
      return (
        !1 === t.mount(e) ||
        (t.emit("beforeInit"),
          t.params.breakpoints && t.setBreakpoint(),
          t.addClasses(),
          t.params.loop && t.loopCreate(),
          t.updateSize(),
          t.updateSlides(),
          t.params.watchOverflow && t.checkOverflow(),
          t.params.grabCursor && t.enabled && t.setGrabCursor(),
          t.params.preloadImages && t.preloadImages(),
          t.params.loop
            ? t.slideTo(
              t.params.initialSlide + t.loopedSlides,
              0,
              t.params.runCallbacksOnInit,
              !1,
              !0
            )
            : t.slideTo(
              t.params.initialSlide,
              0,
              t.params.runCallbacksOnInit,
              !1,
              !0
            ),
          t.attachEvents(),
          (t.initialized = !0),
          t.emit("init"),
          t.emit("afterInit")),
        t
      );
    }
    destroy(e, t) {
      void 0 === e && (e = !0), void 0 === t && (t = !0);
      const s = this,
        { params: a, $el: i, $wrapperEl: r, slides: n } = s;
      return (
        void 0 === s.params ||
        s.destroyed ||
        (s.emit("beforeDestroy"),
          (s.initialized = !1),
          s.detachEvents(),
          a.loop && s.loopDestroy(),
          t &&
          (s.removeClasses(),
            i.removeAttr("style"),
            r.removeAttr("style"),
            n &&
            n.length &&
            n
              .removeClass(
                [
                  a.slideVisibleClass,
                  a.slideActiveClass,
                  a.slideNextClass,
                  a.slidePrevClass,
                ].join(" ")
              )
              .removeAttr("style")
              .removeAttr("data-swiper-slide-index")),
          s.emit("destroy"),
          Object.keys(s.eventsListeners).forEach((e) => {
            s.off(e);
          }),
          !1 !== e &&
          ((s.$el[0].swiper = null),
            (function (e) {
              const t = e;
              Object.keys(t).forEach((e) => {
                try {
                  t[e] = null;
                } catch (e) { }
                try {
                  delete t[e];
                } catch (e) { }
              });
            })(s)),
          (s.destroyed = !0)),
        null
      );
    }
    static extendDefaults(e) {
      g(V, e);
    }
    static get extendedDefaults() {
      return V;
    }
    static get defaults() {
      return W;
    }
    static installModule(e) {
      q.prototype.__modules__ || (q.prototype.__modules__ = []);
      const t = q.prototype.__modules__;
      "function" == typeof e && t.indexOf(e) < 0 && t.push(e);
    }
    static use(e) {
      return Array.isArray(e)
        ? (e.forEach((e) => q.installModule(e)), q)
        : (q.installModule(e), q);
    }
  }
  function F(e, t, s, i) {
    const r = a();
    return (
      e.params.createElements &&
      Object.keys(i).forEach((a) => {
        if (!s[a] && !0 === s.auto) {
          let n = e.$el.children(`.${i[a]}`)[0];
          n ||
            ((n = r.createElement("div")),
              (n.className = i[a]),
              e.$el.append(n)),
            (s[a] = n),
            (t[a] = n);
        }
      }),
      s
    );
  }
  function U(e) {
    return (
      void 0 === e && (e = ""),
      `.${e
        .trim()
        .replace(/([\.:!\/])/g, "\\$1")
        .replace(/ /g, ".")}`
    );
  }
  function K(e) {
    const t = this,
      { $wrapperEl: s, params: a } = t;
    if ((a.loop && t.loopDestroy(), "object" == typeof e && "length" in e))
      for (let t = 0; t < e.length; t += 1) e[t] && s.append(e[t]);
    else s.append(e);
    a.loop && t.loopCreate(), a.observer || t.update();
  }
  function Z(e) {
    const t = this,
      { params: s, $wrapperEl: a, activeIndex: i } = t;
    s.loop && t.loopDestroy();
    let r = i + 1;
    if ("object" == typeof e && "length" in e) {
      for (let t = 0; t < e.length; t += 1) e[t] && a.prepend(e[t]);
      r = i + e.length;
    } else a.prepend(e);
    s.loop && t.loopCreate(), s.observer || t.update(), t.slideTo(r, 0, !1);
  }
  function J(e, t) {
    const s = this,
      { $wrapperEl: a, params: i, activeIndex: r } = s;
    let n = r;
    i.loop &&
      ((n -= s.loopedSlides),
        s.loopDestroy(),
        (s.slides = a.children(`.${i.slideClass}`)));
    const l = s.slides.length;
    if (e <= 0) return void s.prependSlide(t);
    if (e >= l) return void s.appendSlide(t);
    let o = n > e ? n + 1 : n;
    const d = [];
    for (let t = l - 1; t >= e; t -= 1) {
      const e = s.slides.eq(t);
      e.remove(), d.unshift(e);
    }
    if ("object" == typeof t && "length" in t) {
      for (let e = 0; e < t.length; e += 1) t[e] && a.append(t[e]);
      o = n > e ? n + t.length : n;
    } else a.append(t);
    for (let e = 0; e < d.length; e += 1) a.append(d[e]);
    i.loop && s.loopCreate(),
      i.observer || s.update(),
      i.loop ? s.slideTo(o + s.loopedSlides, 0, !1) : s.slideTo(o, 0, !1);
  }
  function Q(e) {
    const t = this,
      { params: s, $wrapperEl: a, activeIndex: i } = t;
    let r = i;
    s.loop &&
      ((r -= t.loopedSlides),
        t.loopDestroy(),
        (t.slides = a.children(`.${s.slideClass}`)));
    let n,
      l = r;
    if ("object" == typeof e && "length" in e) {
      for (let s = 0; s < e.length; s += 1)
        (n = e[s]), t.slides[n] && t.slides.eq(n).remove(), n < l && (l -= 1);
      l = Math.max(l, 0);
    } else (n = e), t.slides[n] && t.slides.eq(n).remove(), n < l && (l -= 1), (l = Math.max(l, 0));
    s.loop && t.loopCreate(),
      s.observer || t.update(),
      s.loop ? t.slideTo(l + t.loopedSlides, 0, !1) : t.slideTo(l, 0, !1);
  }
  function ee() {
    const e = this,
      t = [];
    for (let s = 0; s < e.slides.length; s += 1) t.push(s);
    e.removeSlide(t);
  }
  function te(e) {
    const {
      effect: t,
      swiper: s,
      on: a,
      setTranslate: i,
      setTransition: r,
      overwriteParams: n,
      perspective: l,
    } = e;
    a("beforeInit", () => {
      if (s.params.effect !== t) return;
      s.classNames.push(`${s.params.containerModifierClass}${t}`),
        l && l() && s.classNames.push(`${s.params.containerModifierClass}3d`);
      const e = n ? n() : {};
      Object.assign(s.params, e), Object.assign(s.originalParams, e);
    }),
      a("setTranslate", () => {
        s.params.effect === t && i();
      }),
      a("setTransition", (e, a) => {
        s.params.effect === t && r(a);
      });
  }
  function se(e, t) {
    return e.transformEl
      ? t.find(e.transformEl).css({
        "backface-visibility": "hidden",
        "-webkit-backface-visibility": "hidden",
      })
      : t;
  }
  function ae(e) {
    let { swiper: t, duration: s, transformEl: a, allSlides: i } = e;
    const { slides: r, activeIndex: n, $wrapperEl: l } = t;
    if (t.params.virtualTranslate && 0 !== s) {
      let e,
        s = !1;
      (e = i ? (a ? r.find(a) : r) : a ? r.eq(n).find(a) : r.eq(n)),
        e.transitionEnd(() => {
          if (s) return;
          if (!t || t.destroyed) return;
          (s = !0), (t.animating = !1);
          const e = ["webkitTransitionEnd", "transitionend"];
          for (let t = 0; t < e.length; t += 1) l.trigger(e[t]);
        });
    }
  }
  function ie(e, t, s) {
    const a = "swiper-slide-shadow" + (s ? `-${s}` : ""),
      i = e.transformEl ? t.find(e.transformEl) : t;
    let r = i.children(`.${a}`);
    return (
      r.length ||
      ((r = d(`<div class="swiper-slide-shadow${s ? `-${s}` : ""}"></div>`)),
        i.append(r)),
      r
    );
  }
  Object.keys(_).forEach((e) => {
    Object.keys(_[e]).forEach((t) => {
      q.prototype[t] = _[e][t];
    });
  }),
    q.use([
      function (e) {
        let { swiper: t, on: s, emit: a } = e;
        const i = r();
        let n = null,
          l = null;
        const o = () => {
          t &&
            !t.destroyed &&
            t.initialized &&
            (a("beforeResize"), a("resize"));
        },
          d = () => {
            t && !t.destroyed && t.initialized && a("orientationchange");
          };
        s("init", () => {
          t.params.resizeObserver && void 0 !== i.ResizeObserver
            ? t &&
            !t.destroyed &&
            t.initialized &&
            ((n = new ResizeObserver((e) => {
              l = i.requestAnimationFrame(() => {
                const { width: s, height: a } = t;
                let i = s,
                  r = a;
                e.forEach((e) => {
                  let { contentBoxSize: s, contentRect: a, target: n } = e;
                  (n && n !== t.el) ||
                    ((i = a ? a.width : (s[0] || s).inlineSize),
                      (r = a ? a.height : (s[0] || s).blockSize));
                }),
                  (i === s && r === a) || o();
              });
            })),
              n.observe(t.el))
            : (i.addEventListener("resize", o),
              i.addEventListener("orientationchange", d));
        }),
          s("destroy", () => {
            l && i.cancelAnimationFrame(l),
              n && n.unobserve && t.el && (n.unobserve(t.el), (n = null)),
              i.removeEventListener("resize", o),
              i.removeEventListener("orientationchange", d);
          });
      },
      function (e) {
        let { swiper: t, extendParams: s, on: a, emit: i } = e;
        const n = [],
          l = r(),
          o = function (e, t) {
            void 0 === t && (t = {});
            const s = new (l.MutationObserver || l.WebkitMutationObserver)(
              (e) => {
                if (1 === e.length) return void i("observerUpdate", e[0]);
                const t = function () {
                  i("observerUpdate", e[0]);
                };
                l.requestAnimationFrame
                  ? l.requestAnimationFrame(t)
                  : l.setTimeout(t, 0);
              }
            );
            s.observe(e, {
              attributes: void 0 === t.attributes || t.attributes,
              childList: void 0 === t.childList || t.childList,
              characterData: void 0 === t.characterData || t.characterData,
            }),
              n.push(s);
          };
        s({ observer: !1, observeParents: !1, observeSlideChildren: !1 }),
          a("init", () => {
            if (t.params.observer) {
              if (t.params.observeParents) {
                const e = t.$el.parents();
                for (let t = 0; t < e.length; t += 1) o(e[t]);
              }
              o(t.$el[0], { childList: t.params.observeSlideChildren }),
                o(t.$wrapperEl[0], { attributes: !1 });
            }
          }),
          a("destroy", () => {
            n.forEach((e) => {
              e.disconnect();
            }),
              n.splice(0, n.length);
          });
      },
    ]);
  const re = [
    function (e) {
      let t,
        { swiper: s, extendParams: a, on: i } = e;
      function r(e, t) {
        const a = s.params.virtual;
        if (a.cache && s.virtual.cache[t]) return s.virtual.cache[t];
        const i = a.renderSlide
          ? d(a.renderSlide.call(s, e, t))
          : d(
            `<div class="${s.params.slideClass}" data-swiper-slide-index="${t}">${e}</div>`
          );
        return (
          i.attr("data-swiper-slide-index") ||
          i.attr("data-swiper-slide-index", t),
          a.cache && (s.virtual.cache[t] = i),
          i
        );
      }
      function n(e) {
        const {
          slidesPerView: t,
          slidesPerGroup: a,
          centeredSlides: i,
        } = s.params,
          { addSlidesBefore: n, addSlidesAfter: l } = s.params.virtual,
          { from: o, to: d, slides: c, slidesGrid: p, offset: u } = s.virtual;
        s.params.cssMode || s.updateActiveIndex();
        const h = s.activeIndex || 0;
        let m, f, g;
        (m = s.rtlTranslate ? "right" : s.isHorizontal() ? "left" : "top"),
          i
            ? ((f = Math.floor(t / 2) + a + l), (g = Math.floor(t / 2) + a + n))
            : ((f = t + (a - 1) + l), (g = a + n));
        const v = Math.max((h || 0) - g, 0),
          w = Math.min((h || 0) + f, c.length - 1),
          b = (s.slidesGrid[v] || 0) - (s.slidesGrid[0] || 0);
        function x() {
          s.updateSlides(),
            s.updateProgress(),
            s.updateSlidesClasses(),
            s.lazy && s.params.lazy.enabled && s.lazy.load();
        }
        if (
          (Object.assign(s.virtual, {
            from: v,
            to: w,
            offset: b,
            slidesGrid: s.slidesGrid,
          }),
            o === v && d === w && !e)
        )
          return (
            s.slidesGrid !== p && b !== u && s.slides.css(m, `${b}px`),
            void s.updateProgress()
          );
        if (s.params.virtual.renderExternal)
          return (
            s.params.virtual.renderExternal.call(s, {
              offset: b,
              from: v,
              to: w,
              slides: (function () {
                const e = [];
                for (let t = v; t <= w; t += 1) e.push(c[t]);
                return e;
              })(),
            }),
            void (s.params.virtual.renderExternalUpdate && x())
          );
        const y = [],
          E = [];
        if (e) s.$wrapperEl.find(`.${s.params.slideClass}`).remove();
        else
          for (let e = o; e <= d; e += 1)
            (e < v || e > w) &&
              s.$wrapperEl
                .find(`.${s.params.slideClass}[data-swiper-slide-index="${e}"]`)
                .remove();
        for (let t = 0; t < c.length; t += 1)
          t >= v &&
            t <= w &&
            (void 0 === d || e
              ? E.push(t)
              : (t > d && E.push(t), t < o && y.push(t)));
        E.forEach((e) => {
          s.$wrapperEl.append(r(c[e], e));
        }),
          y
            .sort((e, t) => t - e)
            .forEach((e) => {
              s.$wrapperEl.prepend(r(c[e], e));
            }),
          s.$wrapperEl.children(".swiper-slide").css(m, `${b}px`),
          x();
      }
      a({
        virtual: {
          enabled: !1,
          slides: [],
          cache: !0,
          renderSlide: null,
          renderExternal: null,
          renderExternalUpdate: !0,
          addSlidesBefore: 0,
          addSlidesAfter: 0,
        },
      }),
        (s.virtual = {
          cache: {},
          from: void 0,
          to: void 0,
          slides: [],
          offset: 0,
          slidesGrid: [],
        }),
        i("beforeInit", () => {
          s.params.virtual.enabled &&
            ((s.virtual.slides = s.params.virtual.slides),
              s.classNames.push(`${s.params.containerModifierClass}virtual`),
              (s.params.watchSlidesProgress = !0),
              (s.originalParams.watchSlidesProgress = !0),
              s.params.initialSlide || n());
        }),
        i("setTranslate", () => {
          s.params.virtual.enabled &&
            (s.params.cssMode && !s._immediateVirtual
              ? (clearTimeout(t),
                (t = setTimeout(() => {
                  n();
                }, 100)))
              : n());
        }),
        i("init update resize", () => {
          s.params.virtual.enabled &&
            s.params.cssMode &&
            v(s.wrapperEl, "--swiper-virtual-size", `${s.virtualSize}px`);
        }),
        Object.assign(s.virtual, {
          appendSlide: function (e) {
            if ("object" == typeof e && "length" in e)
              for (let t = 0; t < e.length; t += 1)
                e[t] && s.virtual.slides.push(e[t]);
            else s.virtual.slides.push(e);
            n(!0);
          },
          prependSlide: function (e) {
            const t = s.activeIndex;
            let a = t + 1,
              i = 1;
            if (Array.isArray(e)) {
              for (let t = 0; t < e.length; t += 1)
                e[t] && s.virtual.slides.unshift(e[t]);
              (a = t + e.length), (i = e.length);
            } else s.virtual.slides.unshift(e);
            if (s.params.virtual.cache) {
              const e = s.virtual.cache,
                t = {};
              Object.keys(e).forEach((s) => {
                const a = e[s],
                  r = a.attr("data-swiper-slide-index");
                r && a.attr("data-swiper-slide-index", parseInt(r, 10) + i),
                  (t[parseInt(s, 10) + i] = a);
              }),
                (s.virtual.cache = t);
            }
            n(!0), s.slideTo(a, 0);
          },
          removeSlide: function (e) {
            if (null == e) return;
            let t = s.activeIndex;
            if (Array.isArray(e))
              for (let a = e.length - 1; a >= 0; a -= 1)
                s.virtual.slides.splice(e[a], 1),
                  s.params.virtual.cache && delete s.virtual.cache[e[a]],
                  e[a] < t && (t -= 1),
                  (t = Math.max(t, 0));
            else
              s.virtual.slides.splice(e, 1),
                s.params.virtual.cache && delete s.virtual.cache[e],
                e < t && (t -= 1),
                (t = Math.max(t, 0));
            n(!0), s.slideTo(t, 0);
          },
          removeAllSlides: function () {
            (s.virtual.slides = []),
              s.params.virtual.cache && (s.virtual.cache = {}),
              n(!0),
              s.slideTo(0, 0);
          },
          update: n,
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: i, emit: n } = e;
      const l = a(),
        o = r();
      function c(e) {
        if (!t.enabled) return;
        const { rtlTranslate: s } = t;
        let a = e;
        a.originalEvent && (a = a.originalEvent);
        const i = a.keyCode || a.charCode,
          r = t.params.keyboard.pageUpDown,
          d = r && 33 === i,
          c = r && 34 === i,
          p = 37 === i,
          u = 39 === i,
          h = 38 === i,
          m = 40 === i;
        if (
          !t.allowSlideNext &&
          ((t.isHorizontal() && u) || (t.isVertical() && m) || c)
        )
          return !1;
        if (
          !t.allowSlidePrev &&
          ((t.isHorizontal() && p) || (t.isVertical() && h) || d)
        )
          return !1;
        if (
          !(
            a.shiftKey ||
            a.altKey ||
            a.ctrlKey ||
            a.metaKey ||
            (l.activeElement &&
              l.activeElement.nodeName &&
              ("input" === l.activeElement.nodeName.toLowerCase() ||
                "textarea" === l.activeElement.nodeName.toLowerCase()))
          )
        ) {
          if (
            t.params.keyboard.onlyInViewport &&
            (d || c || p || u || h || m)
          ) {
            let e = !1;
            if (
              t.$el.parents(`.${t.params.slideClass}`).length > 0 &&
              0 === t.$el.parents(`.${t.params.slideActiveClass}`).length
            )
              return;
            const a = t.$el,
              i = a[0].clientWidth,
              r = a[0].clientHeight,
              n = o.innerWidth,
              l = o.innerHeight,
              d = t.$el.offset();
            s && (d.left -= t.$el[0].scrollLeft);
            const c = [
              [d.left, d.top],
              [d.left + i, d.top],
              [d.left, d.top + r],
              [d.left + i, d.top + r],
            ];
            for (let t = 0; t < c.length; t += 1) {
              const s = c[t];
              if (s[0] >= 0 && s[0] <= n && s[1] >= 0 && s[1] <= l) {
                if (0 === s[0] && 0 === s[1]) continue;
                e = !0;
              }
            }
            if (!e) return;
          }
          t.isHorizontal()
            ? ((d || c || p || u) &&
              (a.preventDefault ? a.preventDefault() : (a.returnValue = !1)),
              (((c || u) && !s) || ((d || p) && s)) && t.slideNext(),
              (((d || p) && !s) || ((c || u) && s)) && t.slidePrev())
            : ((d || c || h || m) &&
              (a.preventDefault ? a.preventDefault() : (a.returnValue = !1)),
              (c || m) && t.slideNext(),
              (d || h) && t.slidePrev()),
            n("keyPress", i);
        }
      }
      function p() {
        t.keyboard.enabled ||
          (d(l).on("keydown", c), (t.keyboard.enabled = !0));
      }
      function u() {
        t.keyboard.enabled &&
          (d(l).off("keydown", c), (t.keyboard.enabled = !1));
      }
      (t.keyboard = { enabled: !1 }),
        s({ keyboard: { enabled: !1, onlyInViewport: !0, pageUpDown: !0 } }),
        i("init", () => {
          t.params.keyboard.enabled && p();
        }),
        i("destroy", () => {
          t.keyboard.enabled && u();
        }),
        Object.assign(t.keyboard, { enable: p, disable: u });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a, emit: i } = e;
      const n = r();
      let l;
      s({
        mousewheel: {
          enabled: !1,
          releaseOnEdges: !1,
          invert: !1,
          forceToAxis: !1,
          sensitivity: 1,
          eventsTarget: "container",
          thresholdDelta: null,
          thresholdTime: null,
        },
      }),
        (t.mousewheel = { enabled: !1 });
      let o,
        c = u();
      const h = [];
      function m() {
        t.enabled && (t.mouseEntered = !0);
      }
      function f() {
        t.enabled && (t.mouseEntered = !1);
      }
      function g(e) {
        return (
          !(
            t.params.mousewheel.thresholdDelta &&
            e.delta < t.params.mousewheel.thresholdDelta
          ) &&
          !(
            t.params.mousewheel.thresholdTime &&
            u() - c < t.params.mousewheel.thresholdTime
          ) &&
          ((e.delta >= 6 && u() - c < 60) ||
            (e.direction < 0
              ? (t.isEnd && !t.params.loop) ||
              t.animating ||
              (t.slideNext(), i("scroll", e.raw))
              : (t.isBeginning && !t.params.loop) ||
              t.animating ||
              (t.slidePrev(), i("scroll", e.raw)),
              (c = new n.Date().getTime()),
              !1))
        );
      }
      function v(e) {
        let s = e,
          a = !0;
        if (!t.enabled) return;
        const r = t.params.mousewheel;
        t.params.cssMode && s.preventDefault();
        let n = t.$el;
        if (
          ("container" !== t.params.mousewheel.eventsTarget &&
            (n = d(t.params.mousewheel.eventsTarget)),
            !t.mouseEntered && !n[0].contains(s.target) && !r.releaseOnEdges)
        )
          return !0;
        s.originalEvent && (s = s.originalEvent);
        let c = 0;
        const m = t.rtlTranslate ? -1 : 1,
          f = (function (e) {
            let t = 0,
              s = 0,
              a = 0,
              i = 0;
            return (
              "detail" in e && (s = e.detail),
              "wheelDelta" in e && (s = -e.wheelDelta / 120),
              "wheelDeltaY" in e && (s = -e.wheelDeltaY / 120),
              "wheelDeltaX" in e && (t = -e.wheelDeltaX / 120),
              "axis" in e && e.axis === e.HORIZONTAL_AXIS && ((t = s), (s = 0)),
              (a = 10 * t),
              (i = 10 * s),
              "deltaY" in e && (i = e.deltaY),
              "deltaX" in e && (a = e.deltaX),
              e.shiftKey && !a && ((a = i), (i = 0)),
              (a || i) &&
              e.deltaMode &&
              (1 === e.deltaMode
                ? ((a *= 40), (i *= 40))
                : ((a *= 800), (i *= 800))),
              a && !t && (t = a < 1 ? -1 : 1),
              i && !s && (s = i < 1 ? -1 : 1),
              { spinX: t, spinY: s, pixelX: a, pixelY: i }
            );
          })(s);
        if (r.forceToAxis)
          if (t.isHorizontal()) {
            if (!(Math.abs(f.pixelX) > Math.abs(f.pixelY))) return !0;
            c = -f.pixelX * m;
          } else {
            if (!(Math.abs(f.pixelY) > Math.abs(f.pixelX))) return !0;
            c = -f.pixelY;
          }
        else
          c =
            Math.abs(f.pixelX) > Math.abs(f.pixelY) ? -f.pixelX * m : -f.pixelY;
        if (0 === c) return !0;
        r.invert && (c = -c);
        let v = t.getTranslate() + c * r.sensitivity;
        if (
          (v >= t.minTranslate() && (v = t.minTranslate()),
            v <= t.maxTranslate() && (v = t.maxTranslate()),
            (a =
              !!t.params.loop ||
              !(v === t.minTranslate() || v === t.maxTranslate())),
            a && t.params.nested && s.stopPropagation(),
            t.params.freeMode && t.params.freeMode.enabled)
        ) {
          const e = { time: u(), delta: Math.abs(c), direction: Math.sign(c) },
            a =
              o &&
              e.time < o.time + 500 &&
              e.delta <= o.delta &&
              e.direction === o.direction;
          if (!a) {
            (o = void 0), t.params.loop && t.loopFix();
            let n = t.getTranslate() + c * r.sensitivity;
            const d = t.isBeginning,
              u = t.isEnd;
            if (
              (n >= t.minTranslate() && (n = t.minTranslate()),
                n <= t.maxTranslate() && (n = t.maxTranslate()),
                t.setTransition(0),
                t.setTranslate(n),
                t.updateProgress(),
                t.updateActiveIndex(),
                t.updateSlidesClasses(),
                ((!d && t.isBeginning) || (!u && t.isEnd)) &&
                t.updateSlidesClasses(),
                t.params.freeMode.sticky)
            ) {
              clearTimeout(l), (l = void 0), h.length >= 15 && h.shift();
              const s = h.length ? h[h.length - 1] : void 0,
                a = h[0];
              if (
                (h.push(e),
                  s && (e.delta > s.delta || e.direction !== s.direction))
              )
                h.splice(0);
              else if (
                h.length >= 15 &&
                e.time - a.time < 500 &&
                a.delta - e.delta >= 1 &&
                e.delta <= 6
              ) {
                const s = c > 0 ? 0.8 : 0.2;
                (o = e),
                  h.splice(0),
                  (l = p(() => {
                    t.slideToClosest(t.params.speed, !0, void 0, s);
                  }, 0));
              }
              l ||
                (l = p(() => {
                  (o = e),
                    h.splice(0),
                    t.slideToClosest(t.params.speed, !0, void 0, 0.5);
                }, 500));
            }
            if (
              (a || i("scroll", s),
                t.params.autoplay &&
                t.params.autoplayDisableOnInteraction &&
                t.autoplay.stop(),
                n === t.minTranslate() || n === t.maxTranslate())
            )
              return !0;
          }
        } else {
          const s = {
            time: u(),
            delta: Math.abs(c),
            direction: Math.sign(c),
            raw: e,
          };
          h.length >= 2 && h.shift();
          const a = h.length ? h[h.length - 1] : void 0;
          if (
            (h.push(s),
              a
                ? (s.direction !== a.direction ||
                  s.delta > a.delta ||
                  s.time > a.time + 150) &&
                g(s)
                : g(s),
              (function (e) {
                const s = t.params.mousewheel;
                if (e.direction < 0) {
                  if (t.isEnd && !t.params.loop && s.releaseOnEdges) return !0;
                } else if (t.isBeginning && !t.params.loop && s.releaseOnEdges)
                  return !0;
                return !1;
              })(s))
          )
            return !0;
        }
        return s.preventDefault ? s.preventDefault() : (s.returnValue = !1), !1;
      }
      function w(e) {
        let s = t.$el;
        "container" !== t.params.mousewheel.eventsTarget &&
          (s = d(t.params.mousewheel.eventsTarget)),
          s[e]("mouseenter", m),
          s[e]("mouseleave", f),
          s[e]("wheel", v);
      }
      function b() {
        return t.params.cssMode
          ? (t.wrapperEl.removeEventListener("wheel", v), !0)
          : !t.mousewheel.enabled && (w("on"), (t.mousewheel.enabled = !0), !0);
      }
      function x() {
        return t.params.cssMode
          ? (t.wrapperEl.addEventListener(event, v), !0)
          : !!t.mousewheel.enabled &&
          (w("off"), (t.mousewheel.enabled = !1), !0);
      }
      a("init", () => {
        !t.params.mousewheel.enabled && t.params.cssMode && x(),
          t.params.mousewheel.enabled && b();
      }),
        a("destroy", () => {
          t.params.cssMode && b(), t.mousewheel.enabled && x();
        }),
        Object.assign(t.mousewheel, { enable: b, disable: x });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a, emit: i } = e;
      function r(e) {
        let s;
        return (
          e &&
          ((s = d(e)),
            t.params.uniqueNavElements &&
            "string" == typeof e &&
            s.length > 1 &&
            1 === t.$el.find(e).length &&
            (s = t.$el.find(e))),
          s
        );
      }
      function n(e, s) {
        const a = t.params.navigation;
        e &&
          e.length > 0 &&
          (e[s ? "addClass" : "removeClass"](a.disabledClass),
            e[0] && "BUTTON" === e[0].tagName && (e[0].disabled = s),
            t.params.watchOverflow &&
            t.enabled &&
            e[t.isLocked ? "addClass" : "removeClass"](a.lockClass));
      }
      function l() {
        if (t.params.loop) return;
        const { $nextEl: e, $prevEl: s } = t.navigation;
        n(s, t.isBeginning && !t.params.rewind),
          n(e, t.isEnd && !t.params.rewind);
      }
      function o(e) {
        e.preventDefault(),
          (!t.isBeginning || t.params.loop || t.params.rewind) && t.slidePrev();
      }
      function c(e) {
        e.preventDefault(),
          (!t.isEnd || t.params.loop || t.params.rewind) && t.slideNext();
      }
      function p() {
        const e = t.params.navigation;
        if (
          ((t.params.navigation = F(
            t,
            t.originalParams.navigation,
            t.params.navigation,
            { nextEl: "swiper-button-next", prevEl: "swiper-button-prev" }
          )),
            !e.nextEl && !e.prevEl)
        )
          return;
        const s = r(e.nextEl),
          a = r(e.prevEl);
        s && s.length > 0 && s.on("click", c),
          a && a.length > 0 && a.on("click", o),
          Object.assign(t.navigation, {
            $nextEl: s,
            nextEl: s && s[0],
            $prevEl: a,
            prevEl: a && a[0],
          }),
          t.enabled ||
          (s && s.addClass(e.lockClass), a && a.addClass(e.lockClass));
      }
      function u() {
        const { $nextEl: e, $prevEl: s } = t.navigation;
        e &&
          e.length &&
          (e.off("click", c), e.removeClass(t.params.navigation.disabledClass)),
          s &&
          s.length &&
          (s.off("click", o),
            s.removeClass(t.params.navigation.disabledClass));
      }
      s({
        navigation: {
          nextEl: null,
          prevEl: null,
          hideOnClick: !1,
          disabledClass: "swiper-button-disabled",
          hiddenClass: "swiper-button-hidden",
          lockClass: "swiper-button-lock",
        },
      }),
        (t.navigation = {
          nextEl: null,
          $nextEl: null,
          prevEl: null,
          $prevEl: null,
        }),
        a("init", () => {
          p(), l();
        }),
        a("toEdge fromEdge lock unlock", () => {
          l();
        }),
        a("destroy", () => {
          u();
        }),
        a("enable disable", () => {
          const { $nextEl: e, $prevEl: s } = t.navigation;
          e &&
            e[t.enabled ? "removeClass" : "addClass"](
              t.params.navigation.lockClass
            ),
            s &&
            s[t.enabled ? "removeClass" : "addClass"](
              t.params.navigation.lockClass
            );
        }),
        a("click", (e, s) => {
          const { $nextEl: a, $prevEl: r } = t.navigation,
            n = s.target;
          if (t.params.navigation.hideOnClick && !d(n).is(r) && !d(n).is(a)) {
            if (
              t.pagination &&
              t.params.pagination &&
              t.params.pagination.clickable &&
              (t.pagination.el === n || t.pagination.el.contains(n))
            )
              return;
            let e;
            a
              ? (e = a.hasClass(t.params.navigation.hiddenClass))
              : r && (e = r.hasClass(t.params.navigation.hiddenClass)),
              i(!0 === e ? "navigationShow" : "navigationHide"),
              a && a.toggleClass(t.params.navigation.hiddenClass),
              r && r.toggleClass(t.params.navigation.hiddenClass);
          }
        }),
        Object.assign(t.navigation, { update: l, init: p, destroy: u });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a, emit: i } = e;
      const r = "swiper-pagination";
      let n;
      s({
        pagination: {
          el: null,
          bulletElement: "span",
          clickable: !1,
          hideOnClick: !1,
          renderBullet: null,
          renderProgressbar: null,
          renderFraction: null,
          renderCustom: null,
          progressbarOpposite: !1,
          type: "bullets",
          dynamicBullets: !1,
          dynamicMainBullets: 1,
          formatFractionCurrent: (e) => e,
          formatFractionTotal: (e) => e,
          bulletClass: `${r}-bullet`,
          bulletActiveClass: `${r}-bullet-active`,
          modifierClass: `${r}-`,
          currentClass: `${r}-current`,
          totalClass: `${r}-total`,
          hiddenClass: `${r}-hidden`,
          progressbarFillClass: `${r}-progressbar-fill`,
          progressbarOppositeClass: `${r}-progressbar-opposite`,
          clickableClass: `${r}-clickable`,
          lockClass: `${r}-lock`,
          horizontalClass: `${r}-horizontal`,
          verticalClass: `${r}-vertical`,
        },
      }),
        (t.pagination = { el: null, $el: null, bullets: [] });
      let l = 0;
      function o() {
        return (
          !t.params.pagination.el ||
          !t.pagination.el ||
          !t.pagination.$el ||
          0 === t.pagination.$el.length
        );
      }
      function c(e, s) {
        const { bulletActiveClass: a } = t.params.pagination;
        e[s]().addClass(`${a}-${s}`)[s]().addClass(`${a}-${s}-${s}`);
      }
      function p() {
        const e = t.rtl,
          s = t.params.pagination;
        if (o()) return;
        const a =
          t.virtual && t.params.virtual.enabled
            ? t.virtual.slides.length
            : t.slides.length,
          r = t.pagination.$el;
        let p;
        const u = t.params.loop
          ? Math.ceil((a - 2 * t.loopedSlides) / t.params.slidesPerGroup)
          : t.snapGrid.length;
        if (
          (t.params.loop
            ? ((p = Math.ceil(
              (t.activeIndex - t.loopedSlides) / t.params.slidesPerGroup
            )),
              p > a - 1 - 2 * t.loopedSlides && (p -= a - 2 * t.loopedSlides),
              p > u - 1 && (p -= u),
              p < 0 && "bullets" !== t.params.paginationType && (p = u + p))
            : (p = void 0 !== t.snapIndex ? t.snapIndex : t.activeIndex || 0),
            "bullets" === s.type &&
            t.pagination.bullets &&
            t.pagination.bullets.length > 0)
        ) {
          const a = t.pagination.bullets;
          let i, o, u;
          if (
            (s.dynamicBullets &&
              ((n = a
                .eq(0)
              [t.isHorizontal() ? "outerWidth" : "outerHeight"](!0)),
                r.css(
                  t.isHorizontal() ? "width" : "height",
                  n * (s.dynamicMainBullets + 4) + "px"
                ),
                s.dynamicMainBullets > 1 &&
                void 0 !== t.previousIndex &&
                ((l += p - (t.previousIndex - t.loopedSlides || 0)),
                  l > s.dynamicMainBullets - 1
                    ? (l = s.dynamicMainBullets - 1)
                    : l < 0 && (l = 0)),
                (i = Math.max(p - l, 0)),
                (o = i + (Math.min(a.length, s.dynamicMainBullets) - 1)),
                (u = (o + i) / 2)),
              a.removeClass(
                ["", "-next", "-next-next", "-prev", "-prev-prev", "-main"]
                  .map((e) => `${s.bulletActiveClass}${e}`)
                  .join(" ")
              ),
              r.length > 1)
          )
            a.each((e) => {
              const t = d(e),
                a = t.index();
              a === p && t.addClass(s.bulletActiveClass),
                s.dynamicBullets &&
                (a >= i &&
                  a <= o &&
                  t.addClass(`${s.bulletActiveClass}-main`),
                  a === i && c(t, "prev"),
                  a === o && c(t, "next"));
            });
          else {
            const e = a.eq(p),
              r = e.index();
            if ((e.addClass(s.bulletActiveClass), s.dynamicBullets)) {
              const e = a.eq(i),
                n = a.eq(o);
              for (let e = i; e <= o; e += 1)
                a.eq(e).addClass(`${s.bulletActiveClass}-main`);
              if (t.params.loop)
                if (r >= a.length) {
                  for (let e = s.dynamicMainBullets; e >= 0; e -= 1)
                    a.eq(a.length - e).addClass(`${s.bulletActiveClass}-main`);
                  a.eq(a.length - s.dynamicMainBullets - 1).addClass(
                    `${s.bulletActiveClass}-prev`
                  );
                } else c(e, "prev"), c(n, "next");
              else c(e, "prev"), c(n, "next");
            }
          }
          if (s.dynamicBullets) {
            const i = Math.min(a.length, s.dynamicMainBullets + 4),
              r = (n * i - n) / 2 - u * n,
              l = e ? "right" : "left";
            a.css(t.isHorizontal() ? l : "top", `${r}px`);
          }
        }
        if (
          ("fraction" === s.type &&
            (r.find(U(s.currentClass)).text(s.formatFractionCurrent(p + 1)),
              r.find(U(s.totalClass)).text(s.formatFractionTotal(u))),
            "progressbar" === s.type)
        ) {
          let e;
          e = s.progressbarOpposite
            ? t.isHorizontal()
              ? "vertical"
              : "horizontal"
            : t.isHorizontal()
              ? "horizontal"
              : "vertical";
          const a = (p + 1) / u;
          let i = 1,
            n = 1;
          "horizontal" === e ? (i = a) : (n = a),
            r
              .find(U(s.progressbarFillClass))
              .transform(`translate3d(0,0,0) scaleX(${i}) scaleY(${n})`)
              .transition(t.params.speed);
        }
        "custom" === s.type && s.renderCustom
          ? (r.html(s.renderCustom(t, p + 1, u)), i("paginationRender", r[0]))
          : i("paginationUpdate", r[0]),
          t.params.watchOverflow &&
          t.enabled &&
          r[t.isLocked ? "addClass" : "removeClass"](s.lockClass);
      }
      function u() {
        const e = t.params.pagination;
        if (o()) return;
        const s =
          t.virtual && t.params.virtual.enabled
            ? t.virtual.slides.length
            : t.slides.length,
          a = t.pagination.$el;
        let r = "";
        if ("bullets" === e.type) {
          let i = t.params.loop
            ? Math.ceil((s - 2 * t.loopedSlides) / t.params.slidesPerGroup)
            : t.snapGrid.length;
          t.params.freeMode &&
            t.params.freeMode.enabled &&
            !t.params.loop &&
            i > s &&
            (i = s);
          for (let s = 0; s < i; s += 1)
            e.renderBullet
              ? (r += e.renderBullet.call(t, s, e.bulletClass))
              : (r += `<${e.bulletElement} class="${e.bulletClass}"></${e.bulletElement}>`);
          a.html(r), (t.pagination.bullets = a.find(U(e.bulletClass)));
        }
        "fraction" === e.type &&
          ((r = e.renderFraction
            ? e.renderFraction.call(t, e.currentClass, e.totalClass)
            : `<span class="${e.currentClass}"></span> / <span class="${e.totalClass}"></span>`),
            a.html(r)),
          "progressbar" === e.type &&
          ((r = e.renderProgressbar
            ? e.renderProgressbar.call(t, e.progressbarFillClass)
            : `<span class="${e.progressbarFillClass}"></span>`),
            a.html(r)),
          "custom" !== e.type && i("paginationRender", t.pagination.$el[0]);
      }
      function h() {
        t.params.pagination = F(
          t,
          t.originalParams.pagination,
          t.params.pagination,
          { el: "swiper-pagination" }
        );
        const e = t.params.pagination;
        if (!e.el) return;
        let s = d(e.el);
        0 !== s.length &&
          (t.params.uniqueNavElements &&
            "string" == typeof e.el &&
            s.length > 1 &&
            ((s = t.$el.find(e.el)),
              s.length > 1 &&
              (s = s.filter((e) => d(e).parents(".swiper")[0] === t.el))),
            "bullets" === e.type && e.clickable && s.addClass(e.clickableClass),
            s.addClass(e.modifierClass + e.type),
            s.addClass(e.modifierClass + t.params.direction),
            "bullets" === e.type &&
            e.dynamicBullets &&
            (s.addClass(`${e.modifierClass}${e.type}-dynamic`),
              (l = 0),
              e.dynamicMainBullets < 1 && (e.dynamicMainBullets = 1)),
            "progressbar" === e.type &&
            e.progressbarOpposite &&
            s.addClass(e.progressbarOppositeClass),
            e.clickable &&
            s.on("click", U(e.bulletClass), function (e) {
              e.preventDefault();
              let s = d(this).index() * t.params.slidesPerGroup;
              t.params.loop && (s += t.loopedSlides), t.slideTo(s);
            }),
            Object.assign(t.pagination, { $el: s, el: s[0] }),
            t.enabled || s.addClass(e.lockClass));
      }
      function m() {
        const e = t.params.pagination;
        if (o()) return;
        const s = t.pagination.$el;
        s.removeClass(e.hiddenClass),
          s.removeClass(e.modifierClass + e.type),
          s.removeClass(e.modifierClass + t.params.direction),
          t.pagination.bullets &&
          t.pagination.bullets.removeClass &&
          t.pagination.bullets.removeClass(e.bulletActiveClass),
          e.clickable && s.off("click", U(e.bulletClass));
      }
      a("init", () => {
        h(), u(), p();
      }),
        a("activeIndexChange", () => {
          (t.params.loop || void 0 === t.snapIndex) && p();
        }),
        a("snapIndexChange", () => {
          t.params.loop || p();
        }),
        a("slidesLengthChange", () => {
          t.params.loop && (u(), p());
        }),
        a("snapGridLengthChange", () => {
          t.params.loop || (u(), p());
        }),
        a("destroy", () => {
          m();
        }),
        a("enable disable", () => {
          const { $el: e } = t.pagination;
          e &&
            e[t.enabled ? "removeClass" : "addClass"](
              t.params.pagination.lockClass
            );
        }),
        a("lock unlock", () => {
          p();
        }),
        a("click", (e, s) => {
          const a = s.target,
            { $el: r } = t.pagination;
          if (
            t.params.pagination.el &&
            t.params.pagination.hideOnClick &&
            r.length > 0 &&
            !d(a).hasClass(t.params.pagination.bulletClass)
          ) {
            if (
              t.navigation &&
              ((t.navigation.nextEl && a === t.navigation.nextEl) ||
                (t.navigation.prevEl && a === t.navigation.prevEl))
            )
              return;
            const e = r.hasClass(t.params.pagination.hiddenClass);
            i(!0 === e ? "paginationShow" : "paginationHide"),
              r.toggleClass(t.params.pagination.hiddenClass);
          }
        }),
        Object.assign(t.pagination, {
          render: u,
          update: p,
          init: h,
          destroy: m,
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: i, emit: r } = e;
      const n = a();
      let l,
        o,
        c,
        u,
        h = !1,
        m = null,
        f = null;
      function g() {
        if (!t.params.scrollbar.el || !t.scrollbar.el) return;
        const { scrollbar: e, rtlTranslate: s, progress: a } = t,
          { $dragEl: i, $el: r } = e,
          n = t.params.scrollbar;
        let l = o,
          d = (c - o) * a;
        s
          ? ((d = -d),
            d > 0 ? ((l = o - d), (d = 0)) : -d + o > c && (l = c + d))
          : d < 0
            ? ((l = o + d), (d = 0))
            : d + o > c && (l = c - d),
          t.isHorizontal()
            ? (i.transform(`translate3d(${d}px, 0, 0)`),
              (i[0].style.width = `${l}px`))
            : (i.transform(`translate3d(0px, ${d}px, 0)`),
              (i[0].style.height = `${l}px`)),
          n.hide &&
          (clearTimeout(m),
            (r[0].style.opacity = 1),
            (m = setTimeout(() => {
              (r[0].style.opacity = 0), r.transition(400);
            }, 1e3)));
      }
      function v() {
        if (!t.params.scrollbar.el || !t.scrollbar.el) return;
        const { scrollbar: e } = t,
          { $dragEl: s, $el: a } = e;
        (s[0].style.width = ""),
          (s[0].style.height = ""),
          (c = t.isHorizontal() ? a[0].offsetWidth : a[0].offsetHeight),
          (u =
            t.size /
            (t.virtualSize +
              t.params.slidesOffsetBefore -
              (t.params.centeredSlides ? t.snapGrid[0] : 0))),
          (o =
            "auto" === t.params.scrollbar.dragSize
              ? c * u
              : parseInt(t.params.scrollbar.dragSize, 10)),
          t.isHorizontal()
            ? (s[0].style.width = `${o}px`)
            : (s[0].style.height = `${o}px`),
          (a[0].style.display = u >= 1 ? "none" : ""),
          t.params.scrollbar.hide && (a[0].style.opacity = 0),
          t.params.watchOverflow &&
          t.enabled &&
          e.$el[t.isLocked ? "addClass" : "removeClass"](
            t.params.scrollbar.lockClass
          );
      }
      function w(e) {
        return t.isHorizontal()
          ? "touchstart" === e.type || "touchmove" === e.type
            ? e.targetTouches[0].clientX
            : e.clientX
          : "touchstart" === e.type || "touchmove" === e.type
            ? e.targetTouches[0].clientY
            : e.clientY;
      }
      function b(e) {
        const { scrollbar: s, rtlTranslate: a } = t,
          { $el: i } = s;
        let r;
        (r =
          (w(e) -
            i.offset()[t.isHorizontal() ? "left" : "top"] -
            (null !== l ? l : o / 2)) /
          (c - o)),
          (r = Math.max(Math.min(r, 1), 0)),
          a && (r = 1 - r);
        const n = t.minTranslate() + (t.maxTranslate() - t.minTranslate()) * r;
        t.updateProgress(n),
          t.setTranslate(n),
          t.updateActiveIndex(),
          t.updateSlidesClasses();
      }
      function x(e) {
        const s = t.params.scrollbar,
          { scrollbar: a, $wrapperEl: i } = t,
          { $el: n, $dragEl: o } = a;
        (h = !0),
          (l =
            e.target === o[0] || e.target === o
              ? w(e) -
              e.target.getBoundingClientRect()[
              t.isHorizontal() ? "left" : "top"
              ]
              : null),
          e.preventDefault(),
          e.stopPropagation(),
          i.transition(100),
          o.transition(100),
          b(e),
          clearTimeout(f),
          n.transition(0),
          s.hide && n.css("opacity", 1),
          t.params.cssMode && t.$wrapperEl.css("scroll-snap-type", "none"),
          r("scrollbarDragStart", e);
      }
      function y(e) {
        const { scrollbar: s, $wrapperEl: a } = t,
          { $el: i, $dragEl: n } = s;
        h &&
          (e.preventDefault ? e.preventDefault() : (e.returnValue = !1),
            b(e),
            a.transition(0),
            i.transition(0),
            n.transition(0),
            r("scrollbarDragMove", e));
      }
      function E(e) {
        const s = t.params.scrollbar,
          { scrollbar: a, $wrapperEl: i } = t,
          { $el: n } = a;
        h &&
          ((h = !1),
            t.params.cssMode &&
            (t.$wrapperEl.css("scroll-snap-type", ""), i.transition("")),
            s.hide &&
            (clearTimeout(f),
              (f = p(() => {
                n.css("opacity", 0), n.transition(400);
              }, 1e3))),
            r("scrollbarDragEnd", e),
            s.snapOnRelease && t.slideToClosest());
      }
      function T(e) {
        const {
          scrollbar: s,
          touchEventsTouch: a,
          touchEventsDesktop: i,
          params: r,
          support: l,
        } = t,
          o = s.$el[0],
          d = !(!l.passiveListener || !r.passiveListeners) && {
            passive: !1,
            capture: !1,
          },
          c = !(!l.passiveListener || !r.passiveListeners) && {
            passive: !0,
            capture: !1,
          };
        if (!o) return;
        const p = "on" === e ? "addEventListener" : "removeEventListener";
        l.touch
          ? (o[p](a.start, x, d), o[p](a.move, y, d), o[p](a.end, E, c))
          : (o[p](i.start, x, d), n[p](i.move, y, d), n[p](i.end, E, c));
      }
      function C() {
        const { scrollbar: e, $el: s } = t;
        t.params.scrollbar = F(
          t,
          t.originalParams.scrollbar,
          t.params.scrollbar,
          { el: "swiper-scrollbar" }
        );
        const a = t.params.scrollbar;
        if (!a.el) return;
        let i = d(a.el);
        t.params.uniqueNavElements &&
          "string" == typeof a.el &&
          i.length > 1 &&
          1 === s.find(a.el).length &&
          (i = s.find(a.el));
        let r = i.find(`.${t.params.scrollbar.dragClass}`);
        0 === r.length &&
          ((r = d(`<div class="${t.params.scrollbar.dragClass}"></div>`)),
            i.append(r)),
          Object.assign(e, { $el: i, el: i[0], $dragEl: r, dragEl: r[0] }),
          a.draggable && t.params.scrollbar.el && T("on"),
          i &&
          i[t.enabled ? "removeClass" : "addClass"](
            t.params.scrollbar.lockClass
          );
      }
      function $() {
        t.params.scrollbar.el && T("off");
      }
      s({
        scrollbar: {
          el: null,
          dragSize: "auto",
          hide: !1,
          draggable: !1,
          snapOnRelease: !0,
          lockClass: "swiper-scrollbar-lock",
          dragClass: "swiper-scrollbar-drag",
        },
      }),
        (t.scrollbar = { el: null, dragEl: null, $el: null, $dragEl: null }),
        i("init", () => {
          C(), v(), g();
        }),
        i("update resize observerUpdate lock unlock", () => {
          v();
        }),
        i("setTranslate", () => {
          g();
        }),
        i("setTransition", (e, s) => {
          !(function (e) {
            t.params.scrollbar.el &&
              t.scrollbar.el &&
              t.scrollbar.$dragEl.transition(e);
          })(s);
        }),
        i("enable disable", () => {
          const { $el: e } = t.scrollbar;
          e &&
            e[t.enabled ? "removeClass" : "addClass"](
              t.params.scrollbar.lockClass
            );
        }),
        i("destroy", () => {
          $();
        }),
        Object.assign(t.scrollbar, {
          updateSize: v,
          setTranslate: g,
          init: C,
          destroy: $,
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({ parallax: { enabled: !1 } });
      const i = (e, s) => {
        const { rtl: a } = t,
          i = d(e),
          r = a ? -1 : 1,
          n = i.attr("data-swiper-parallax") || "0";
        let l = i.attr("data-swiper-parallax-x"),
          o = i.attr("data-swiper-parallax-y");
        const c = i.attr("data-swiper-parallax-scale"),
          p = i.attr("data-swiper-parallax-opacity");
        if (
          (l || o
            ? ((l = l || "0"), (o = o || "0"))
            : t.isHorizontal()
              ? ((l = n), (o = "0"))
              : ((o = n), (l = "0")),
            (l =
              l.indexOf("%") >= 0
                ? parseInt(l, 10) * s * r + "%"
                : l * s * r + "px"),
            (o =
              o.indexOf("%") >= 0 ? parseInt(o, 10) * s + "%" : o * s + "px"),
            null != p)
        ) {
          const e = p - (p - 1) * (1 - Math.abs(s));
          i[0].style.opacity = e;
        }
        if (null == c) i.transform(`translate3d(${l}, ${o}, 0px)`);
        else {
          const e = c - (c - 1) * (1 - Math.abs(s));
          i.transform(`translate3d(${l}, ${o}, 0px) scale(${e})`);
        }
      },
        r = () => {
          const { $el: e, slides: s, progress: a, snapGrid: r } = t;
          e
            .children(
              "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]"
            )
            .each((e) => {
              i(e, a);
            }),
            s.each((e, s) => {
              let n = e.progress;
              t.params.slidesPerGroup > 1 &&
                "auto" !== t.params.slidesPerView &&
                (n += Math.ceil(s / 2) - a * (r.length - 1)),
                (n = Math.min(Math.max(n, -1), 1)),
                d(e)
                  .find(
                    "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]"
                  )
                  .each((e) => {
                    i(e, n);
                  });
            });
        };
      a("beforeInit", () => {
        t.params.parallax.enabled &&
          ((t.params.watchSlidesProgress = !0),
            (t.originalParams.watchSlidesProgress = !0));
      }),
        a("init", () => {
          t.params.parallax.enabled && r();
        }),
        a("setTranslate", () => {
          t.params.parallax.enabled && r();
        }),
        a("setTransition", (e, s) => {
          t.params.parallax.enabled &&
            (function (e) {
              void 0 === e && (e = t.params.speed);
              const { $el: s } = t;
              s.find(
                "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]"
              ).each((t) => {
                const s = d(t);
                let a =
                  parseInt(s.attr("data-swiper-parallax-duration"), 10) || e;
                0 === e && (a = 0), s.transition(a);
              });
            })(s);
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a, emit: i } = e;
      const n = r();
      s({
        zoom: {
          enabled: !1,
          maxRatio: 3,
          minRatio: 1,
          toggle: !0,
          containerClass: "swiper-zoom-container",
          zoomedSlideClass: "swiper-slide-zoomed",
        },
      }),
        (t.zoom = { enabled: !1 });
      let l,
        o,
        c,
        p = 1,
        u = !1;
      const m = {
        $slideEl: void 0,
        slideWidth: void 0,
        slideHeight: void 0,
        $imageEl: void 0,
        $imageWrapEl: void 0,
        maxRatio: 3,
      },
        f = {
          isTouched: void 0,
          isMoved: void 0,
          currentX: void 0,
          currentY: void 0,
          minX: void 0,
          minY: void 0,
          maxX: void 0,
          maxY: void 0,
          width: void 0,
          height: void 0,
          startX: void 0,
          startY: void 0,
          touchesStart: {},
          touchesCurrent: {},
        },
        g = {
          x: void 0,
          y: void 0,
          prevPositionX: void 0,
          prevPositionY: void 0,
          prevTime: void 0,
        };
      let v = 1;
      function w(e) {
        if (e.targetTouches.length < 2) return 1;
        const t = e.targetTouches[0].pageX,
          s = e.targetTouches[0].pageY,
          a = e.targetTouches[1].pageX,
          i = e.targetTouches[1].pageY;
        return Math.sqrt((a - t) ** 2 + (i - s) ** 2);
      }
      function b(e) {
        const s = t.support,
          a = t.params.zoom;
        if (((o = !1), (c = !1), !s.gestures)) {
          if (
            "touchstart" !== e.type ||
            ("touchstart" === e.type && e.targetTouches.length < 2)
          )
            return;
          (o = !0), (m.scaleStart = w(e));
        }
        (m.$slideEl && m.$slideEl.length) ||
          ((m.$slideEl = d(e.target).closest(`.${t.params.slideClass}`)),
            0 === m.$slideEl.length && (m.$slideEl = t.slides.eq(t.activeIndex)),
            (m.$imageEl = m.$slideEl
              .find(`.${a.containerClass}`)
              .eq(0)
              .find("picture, img, svg, canvas, .swiper-zoom-target")
              .eq(0)),
            (m.$imageWrapEl = m.$imageEl.parent(`.${a.containerClass}`)),
            (m.maxRatio = m.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio),
            0 !== m.$imageWrapEl.length)
          ? (m.$imageEl && m.$imageEl.transition(0), (u = !0))
          : (m.$imageEl = void 0);
      }
      function x(e) {
        const s = t.support,
          a = t.params.zoom,
          i = t.zoom;
        if (!s.gestures) {
          if (
            "touchmove" !== e.type ||
            ("touchmove" === e.type && e.targetTouches.length < 2)
          )
            return;
          (c = !0), (m.scaleMove = w(e));
        }
        m.$imageEl && 0 !== m.$imageEl.length
          ? (s.gestures
            ? (i.scale = e.scale * p)
            : (i.scale = (m.scaleMove / m.scaleStart) * p),
            i.scale > m.maxRatio &&
            (i.scale = m.maxRatio - 1 + (i.scale - m.maxRatio + 1) ** 0.5),
            i.scale < a.minRatio &&
            (i.scale = a.minRatio + 1 - (a.minRatio - i.scale + 1) ** 0.5),
            m.$imageEl.transform(`translate3d(0,0,0) scale(${i.scale})`))
          : "gesturechange" === e.type && b(e);
      }
      function y(e) {
        const s = t.device,
          a = t.support,
          i = t.params.zoom,
          r = t.zoom;
        if (!a.gestures) {
          if (!o || !c) return;
          if (
            "touchend" !== e.type ||
            ("touchend" === e.type && e.changedTouches.length < 2 && !s.android)
          )
            return;
          (o = !1), (c = !1);
        }
        m.$imageEl &&
          0 !== m.$imageEl.length &&
          ((r.scale = Math.max(Math.min(r.scale, m.maxRatio), i.minRatio)),
            m.$imageEl
              .transition(t.params.speed)
              .transform(`translate3d(0,0,0) scale(${r.scale})`),
            (p = r.scale),
            (u = !1),
            1 === r.scale && (m.$slideEl = void 0));
      }
      function E(e) {
        const s = t.zoom;
        if (!m.$imageEl || 0 === m.$imageEl.length) return;
        if (((t.allowClick = !1), !f.isTouched || !m.$slideEl)) return;
        f.isMoved ||
          ((f.width = m.$imageEl[0].offsetWidth),
            (f.height = m.$imageEl[0].offsetHeight),
            (f.startX = h(m.$imageWrapEl[0], "x") || 0),
            (f.startY = h(m.$imageWrapEl[0], "y") || 0),
            (m.slideWidth = m.$slideEl[0].offsetWidth),
            (m.slideHeight = m.$slideEl[0].offsetHeight),
            m.$imageWrapEl.transition(0));
        const a = f.width * s.scale,
          i = f.height * s.scale;
        if (!(a < m.slideWidth && i < m.slideHeight)) {
          if (
            ((f.minX = Math.min(m.slideWidth / 2 - a / 2, 0)),
              (f.maxX = -f.minX),
              (f.minY = Math.min(m.slideHeight / 2 - i / 2, 0)),
              (f.maxY = -f.minY),
              (f.touchesCurrent.x =
                "touchmove" === e.type ? e.targetTouches[0].pageX : e.pageX),
              (f.touchesCurrent.y =
                "touchmove" === e.type ? e.targetTouches[0].pageY : e.pageY),
              !f.isMoved && !u)
          ) {
            if (
              t.isHorizontal() &&
              ((Math.floor(f.minX) === Math.floor(f.startX) &&
                f.touchesCurrent.x < f.touchesStart.x) ||
                (Math.floor(f.maxX) === Math.floor(f.startX) &&
                  f.touchesCurrent.x > f.touchesStart.x))
            )
              return void (f.isTouched = !1);
            if (
              !t.isHorizontal() &&
              ((Math.floor(f.minY) === Math.floor(f.startY) &&
                f.touchesCurrent.y < f.touchesStart.y) ||
                (Math.floor(f.maxY) === Math.floor(f.startY) &&
                  f.touchesCurrent.y > f.touchesStart.y))
            )
              return void (f.isTouched = !1);
          }
          e.cancelable && e.preventDefault(),
            e.stopPropagation(),
            (f.isMoved = !0),
            (f.currentX = f.touchesCurrent.x - f.touchesStart.x + f.startX),
            (f.currentY = f.touchesCurrent.y - f.touchesStart.y + f.startY),
            f.currentX < f.minX &&
            (f.currentX = f.minX + 1 - (f.minX - f.currentX + 1) ** 0.8),
            f.currentX > f.maxX &&
            (f.currentX = f.maxX - 1 + (f.currentX - f.maxX + 1) ** 0.8),
            f.currentY < f.minY &&
            (f.currentY = f.minY + 1 - (f.minY - f.currentY + 1) ** 0.8),
            f.currentY > f.maxY &&
            (f.currentY = f.maxY - 1 + (f.currentY - f.maxY + 1) ** 0.8),
            g.prevPositionX || (g.prevPositionX = f.touchesCurrent.x),
            g.prevPositionY || (g.prevPositionY = f.touchesCurrent.y),
            g.prevTime || (g.prevTime = Date.now()),
            (g.x =
              (f.touchesCurrent.x - g.prevPositionX) /
              (Date.now() - g.prevTime) /
              2),
            (g.y =
              (f.touchesCurrent.y - g.prevPositionY) /
              (Date.now() - g.prevTime) /
              2),
            Math.abs(f.touchesCurrent.x - g.prevPositionX) < 2 && (g.x = 0),
            Math.abs(f.touchesCurrent.y - g.prevPositionY) < 2 && (g.y = 0),
            (g.prevPositionX = f.touchesCurrent.x),
            (g.prevPositionY = f.touchesCurrent.y),
            (g.prevTime = Date.now()),
            m.$imageWrapEl.transform(
              `translate3d(${f.currentX}px, ${f.currentY}px,0)`
            );
        }
      }
      function T() {
        const e = t.zoom;
        m.$slideEl &&
          t.previousIndex !== t.activeIndex &&
          (m.$imageEl && m.$imageEl.transform("translate3d(0,0,0) scale(1)"),
            m.$imageWrapEl && m.$imageWrapEl.transform("translate3d(0,0,0)"),
            (e.scale = 1),
            (p = 1),
            (m.$slideEl = void 0),
            (m.$imageEl = void 0),
            (m.$imageWrapEl = void 0));
      }
      function C(e) {
        const s = t.zoom,
          a = t.params.zoom;
        if (
          (m.$slideEl ||
            (e &&
              e.target &&
              (m.$slideEl = d(e.target).closest(`.${t.params.slideClass}`)),
              m.$slideEl ||
              (t.params.virtual && t.params.virtual.enabled && t.virtual
                ? (m.$slideEl = t.$wrapperEl.children(
                  `.${t.params.slideActiveClass}`
                ))
                : (m.$slideEl = t.slides.eq(t.activeIndex))),
              (m.$imageEl = m.$slideEl
                .find(`.${a.containerClass}`)
                .eq(0)
                .find("picture, img, svg, canvas, .swiper-zoom-target")
                .eq(0)),
              (m.$imageWrapEl = m.$imageEl.parent(`.${a.containerClass}`))),
            !m.$imageEl ||
            0 === m.$imageEl.length ||
            !m.$imageWrapEl ||
            0 === m.$imageWrapEl.length)
        )
          return;
        let i, r, l, o, c, u, h, g, v, w, b, x, y, E, T, C, $, S;
        t.params.cssMode &&
          ((t.wrapperEl.style.overflow = "hidden"),
            (t.wrapperEl.style.touchAction = "none")),
          m.$slideEl.addClass(`${a.zoomedSlideClass}`),
          void 0 === f.touchesStart.x && e
            ? ((i =
              "touchend" === e.type ? e.changedTouches[0].pageX : e.pageX),
              (r = "touchend" === e.type ? e.changedTouches[0].pageY : e.pageY))
            : ((i = f.touchesStart.x), (r = f.touchesStart.y)),
          (s.scale = m.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio),
          (p = m.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio),
          e
            ? (($ = m.$slideEl[0].offsetWidth),
              (S = m.$slideEl[0].offsetHeight),
              (l = m.$slideEl.offset().left + n.scrollX),
              (o = m.$slideEl.offset().top + n.scrollY),
              (c = l + $ / 2 - i),
              (u = o + S / 2 - r),
              (v = m.$imageEl[0].offsetWidth),
              (w = m.$imageEl[0].offsetHeight),
              (b = v * s.scale),
              (x = w * s.scale),
              (y = Math.min($ / 2 - b / 2, 0)),
              (E = Math.min(S / 2 - x / 2, 0)),
              (T = -y),
              (C = -E),
              (h = c * s.scale),
              (g = u * s.scale),
              h < y && (h = y),
              h > T && (h = T),
              g < E && (g = E),
              g > C && (g = C))
            : ((h = 0), (g = 0)),
          m.$imageWrapEl
            .transition(300)
            .transform(`translate3d(${h}px, ${g}px,0)`),
          m.$imageEl
            .transition(300)
            .transform(`translate3d(0,0,0) scale(${s.scale})`);
      }
      function $() {
        const e = t.zoom,
          s = t.params.zoom;
        m.$slideEl ||
          (t.params.virtual && t.params.virtual.enabled && t.virtual
            ? (m.$slideEl = t.$wrapperEl.children(
              `.${t.params.slideActiveClass}`
            ))
            : (m.$slideEl = t.slides.eq(t.activeIndex)),
            (m.$imageEl = m.$slideEl
              .find(`.${s.containerClass}`)
              .eq(0)
              .find("picture, img, svg, canvas, .swiper-zoom-target")
              .eq(0)),
            (m.$imageWrapEl = m.$imageEl.parent(`.${s.containerClass}`))),
          m.$imageEl &&
          0 !== m.$imageEl.length &&
          m.$imageWrapEl &&
          0 !== m.$imageWrapEl.length &&
          (t.params.cssMode &&
            ((t.wrapperEl.style.overflow = ""),
              (t.wrapperEl.style.touchAction = "")),
            (e.scale = 1),
            (p = 1),
            m.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),
            m.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),
            m.$slideEl.removeClass(`${s.zoomedSlideClass}`),
            (m.$slideEl = void 0));
      }
      function S(e) {
        const s = t.zoom;
        s.scale && 1 !== s.scale ? $() : C(e);
      }
      function M() {
        const e = t.support;
        return {
          passiveListener: !(
            "touchstart" !== t.touchEvents.start ||
            !e.passiveListener ||
            !t.params.passiveListeners
          ) && { passive: !0, capture: !1 },
          activeListenerWithCapture: !e.passiveListener || {
            passive: !1,
            capture: !0,
          },
        };
      }
      function P() {
        return `.${t.params.slideClass}`;
      }
      function k(e) {
        const { passiveListener: s } = M(),
          a = P();
        t.$wrapperEl[e]("gesturestart", a, b, s),
          t.$wrapperEl[e]("gesturechange", a, x, s),
          t.$wrapperEl[e]("gestureend", a, y, s);
      }
      function z() {
        l || ((l = !0), k("on"));
      }
      function O() {
        l && ((l = !1), k("off"));
      }
      function I() {
        const e = t.zoom;
        if (e.enabled) return;
        e.enabled = !0;
        const s = t.support,
          { passiveListener: a, activeListenerWithCapture: i } = M(),
          r = P();
        s.gestures
          ? (t.$wrapperEl.on(t.touchEvents.start, z, a),
            t.$wrapperEl.on(t.touchEvents.end, O, a))
          : "touchstart" === t.touchEvents.start &&
          (t.$wrapperEl.on(t.touchEvents.start, r, b, a),
            t.$wrapperEl.on(t.touchEvents.move, r, x, i),
            t.$wrapperEl.on(t.touchEvents.end, r, y, a),
            t.touchEvents.cancel &&
            t.$wrapperEl.on(t.touchEvents.cancel, r, y, a)),
          t.$wrapperEl.on(
            t.touchEvents.move,
            `.${t.params.zoom.containerClass}`,
            E,
            i
          );
      }
      function L() {
        const e = t.zoom;
        if (!e.enabled) return;
        const s = t.support;
        e.enabled = !1;
        const { passiveListener: a, activeListenerWithCapture: i } = M(),
          r = P();
        s.gestures
          ? (t.$wrapperEl.off(t.touchEvents.start, z, a),
            t.$wrapperEl.off(t.touchEvents.end, O, a))
          : "touchstart" === t.touchEvents.start &&
          (t.$wrapperEl.off(t.touchEvents.start, r, b, a),
            t.$wrapperEl.off(t.touchEvents.move, r, x, i),
            t.$wrapperEl.off(t.touchEvents.end, r, y, a),
            t.touchEvents.cancel &&
            t.$wrapperEl.off(t.touchEvents.cancel, r, y, a)),
          t.$wrapperEl.off(
            t.touchEvents.move,
            `.${t.params.zoom.containerClass}`,
            E,
            i
          );
      }
      Object.defineProperty(t.zoom, "scale", {
        get: () => v,
        set(e) {
          if (v !== e) {
            const t = m.$imageEl ? m.$imageEl[0] : void 0,
              s = m.$slideEl ? m.$slideEl[0] : void 0;
            i("zoomChange", e, t, s);
          }
          v = e;
        },
      }),
        a("init", () => {
          t.params.zoom.enabled && I();
        }),
        a("destroy", () => {
          L();
        }),
        a("touchStart", (e, s) => {
          t.zoom.enabled &&
            (function (e) {
              const s = t.device;
              m.$imageEl &&
                0 !== m.$imageEl.length &&
                (f.isTouched ||
                  (s.android && e.cancelable && e.preventDefault(),
                    (f.isTouched = !0),
                    (f.touchesStart.x =
                      "touchstart" === e.type
                        ? e.targetTouches[0].pageX
                        : e.pageX),
                    (f.touchesStart.y =
                      "touchstart" === e.type
                        ? e.targetTouches[0].pageY
                        : e.pageY)));
            })(s);
        }),
        a("touchEnd", (e, s) => {
          t.zoom.enabled &&
            (function () {
              const e = t.zoom;
              if (!m.$imageEl || 0 === m.$imageEl.length) return;
              if (!f.isTouched || !f.isMoved)
                return (f.isTouched = !1), void (f.isMoved = !1);
              (f.isTouched = !1), (f.isMoved = !1);
              let s = 300,
                a = 300;
              const i = g.x * s,
                r = f.currentX + i,
                n = g.y * a,
                l = f.currentY + n;
              0 !== g.x && (s = Math.abs((r - f.currentX) / g.x)),
                0 !== g.y && (a = Math.abs((l - f.currentY) / g.y));
              const o = Math.max(s, a);
              (f.currentX = r), (f.currentY = l);
              const d = f.width * e.scale,
                c = f.height * e.scale;
              (f.minX = Math.min(m.slideWidth / 2 - d / 2, 0)),
                (f.maxX = -f.minX),
                (f.minY = Math.min(m.slideHeight / 2 - c / 2, 0)),
                (f.maxY = -f.minY),
                (f.currentX = Math.max(Math.min(f.currentX, f.maxX), f.minX)),
                (f.currentY = Math.max(Math.min(f.currentY, f.maxY), f.minY)),
                m.$imageWrapEl
                  .transition(o)
                  .transform(`translate3d(${f.currentX}px, ${f.currentY}px,0)`);
            })();
        }),
        a("doubleTap", (e, s) => {
          !t.animating &&
            t.params.zoom.enabled &&
            t.zoom.enabled &&
            t.params.zoom.toggle &&
            S(s);
        }),
        a("transitionEnd", () => {
          t.zoom.enabled && t.params.zoom.enabled && T();
        }),
        a("slideChange", () => {
          t.zoom.enabled && t.params.zoom.enabled && t.params.cssMode && T();
        }),
        Object.assign(t.zoom, {
          enable: I,
          disable: L,
          in: C,
          out: $,
          toggle: S,
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a, emit: i } = e;
      s({
        lazy: {
          checkInView: !1,
          enabled: !1,
          loadPrevNext: !1,
          loadPrevNextAmount: 1,
          loadOnTransitionStart: !1,
          scrollingElement: "",
          elementClass: "swiper-lazy",
          loadingClass: "swiper-lazy-loading",
          loadedClass: "swiper-lazy-loaded",
          preloaderClass: "swiper-lazy-preloader",
        },
      }),
        (t.lazy = {});
      let n = !1,
        l = !1;
      function o(e, s) {
        void 0 === s && (s = !0);
        const a = t.params.lazy;
        if (void 0 === e) return;
        if (0 === t.slides.length) return;
        const r =
          t.virtual && t.params.virtual.enabled
            ? t.$wrapperEl.children(
              `.${t.params.slideClass}[data-swiper-slide-index="${e}"]`
            )
            : t.slides.eq(e),
          n = r.find(
            `.${a.elementClass}:not(.${a.loadedClass}):not(.${a.loadingClass})`
          );
        !r.hasClass(a.elementClass) ||
          r.hasClass(a.loadedClass) ||
          r.hasClass(a.loadingClass) ||
          n.push(r[0]),
          0 !== n.length &&
          n.each((e) => {
            const n = d(e);
            n.addClass(a.loadingClass);
            const l = n.attr("data-background"),
              c = n.attr("data-src"),
              p = n.attr("data-srcset"),
              u = n.attr("data-sizes"),
              h = n.parent("picture");
            t.loadImage(n[0], c || l, p, u, !1, () => {
              if (null != t && t && (!t || t.params) && !t.destroyed) {
                if (
                  (l
                    ? (n.css("background-image", `url("${l}")`),
                      n.removeAttr("data-background"))
                    : (p &&
                      (n.attr("srcset", p), n.removeAttr("data-srcset")),
                      u && (n.attr("sizes", u), n.removeAttr("data-sizes")),
                      h.length &&
                      h.children("source").each((e) => {
                        const t = d(e);
                        t.attr("data-srcset") &&
                          (t.attr("srcset", t.attr("data-srcset")),
                            t.removeAttr("data-srcset"));
                      }),
                      c && (n.attr("src", c), n.removeAttr("data-src"))),
                    n.addClass(a.loadedClass).removeClass(a.loadingClass),
                    r.find(`.${a.preloaderClass}`).remove(),
                    t.params.loop && s)
                ) {
                  const e = r.attr("data-swiper-slide-index");
                  if (r.hasClass(t.params.slideDuplicateClass)) {
                    o(
                      t.$wrapperEl
                        .children(
                          `[data-swiper-slide-index="${e}"]:not(.${t.params.slideDuplicateClass})`
                        )
                        .index(),
                      !1
                    );
                  } else {
                    o(
                      t.$wrapperEl
                        .children(
                          `.${t.params.slideDuplicateClass}[data-swiper-slide-index="${e}"]`
                        )
                        .index(),
                      !1
                    );
                  }
                }
                i("lazyImageReady", r[0], n[0]),
                  t.params.autoHeight && t.updateAutoHeight();
              }
            }),
              i("lazyImageLoad", r[0], n[0]);
          });
      }
      function c() {
        const { $wrapperEl: e, params: s, slides: a, activeIndex: i } = t,
          r = t.virtual && s.virtual.enabled,
          n = s.lazy;
        let c = s.slidesPerView;
        function p(t) {
          if (r) {
            if (
              e.children(`.${s.slideClass}[data-swiper-slide-index="${t}"]`)
                .length
            )
              return !0;
          } else if (a[t]) return !0;
          return !1;
        }
        function u(e) {
          return r ? d(e).attr("data-swiper-slide-index") : d(e).index();
        }
        if (
          ("auto" === c && (c = 0), l || (l = !0), t.params.watchSlidesProgress)
        )
          e.children(`.${s.slideVisibleClass}`).each((e) => {
            o(r ? d(e).attr("data-swiper-slide-index") : d(e).index());
          });
        else if (c > 1) for (let e = i; e < i + c; e += 1) p(e) && o(e);
        else o(i);
        if (n.loadPrevNext)
          if (c > 1 || (n.loadPrevNextAmount && n.loadPrevNextAmount > 1)) {
            const e = n.loadPrevNextAmount,
              t = c,
              s = Math.min(i + t + Math.max(e, t), a.length),
              r = Math.max(i - Math.max(t, e), 0);
            for (let e = i + c; e < s; e += 1) p(e) && o(e);
            for (let e = r; e < i; e += 1) p(e) && o(e);
          } else {
            const t = e.children(`.${s.slideNextClass}`);
            t.length > 0 && o(u(t));
            const a = e.children(`.${s.slidePrevClass}`);
            a.length > 0 && o(u(a));
          }
      }
      function p() {
        const e = r();
        if (!t || t.destroyed) return;
        const s = t.params.lazy.scrollingElement
          ? d(t.params.lazy.scrollingElement)
          : d(e),
          a = s[0] === e,
          i = a ? e.innerWidth : s[0].offsetWidth,
          l = a ? e.innerHeight : s[0].offsetHeight,
          o = t.$el.offset(),
          { rtlTranslate: u } = t;
        let h = !1;
        u && (o.left -= t.$el[0].scrollLeft);
        const m = [
          [o.left, o.top],
          [o.left + t.width, o.top],
          [o.left, o.top + t.height],
          [o.left + t.width, o.top + t.height],
        ];
        for (let e = 0; e < m.length; e += 1) {
          const t = m[e];
          if (t[0] >= 0 && t[0] <= i && t[1] >= 0 && t[1] <= l) {
            if (0 === t[0] && 0 === t[1]) continue;
            h = !0;
          }
        }
        const f = !(
          "touchstart" !== t.touchEvents.start ||
          !t.support.passiveListener ||
          !t.params.passiveListeners
        ) && { passive: !0, capture: !1 };
        h
          ? (c(), s.off("scroll", p, f))
          : n || ((n = !0), s.on("scroll", p, f));
      }
      a("beforeInit", () => {
        t.params.lazy.enabled &&
          t.params.preloadImages &&
          (t.params.preloadImages = !1);
      }),
        a("init", () => {
          t.params.lazy.enabled && (t.params.lazy.checkInView ? p() : c());
        }),
        a("scroll", () => {
          t.params.freeMode &&
            t.params.freeMode.enabled &&
            !t.params.freeMode.sticky &&
            c();
        }),
        a("scrollbarDragMove resize _freeModeNoMomentumRelease", () => {
          t.params.lazy.enabled && (t.params.lazy.checkInView ? p() : c());
        }),
        a("transitionStart", () => {
          t.params.lazy.enabled &&
            (t.params.lazy.loadOnTransitionStart ||
              (!t.params.lazy.loadOnTransitionStart && !l)) &&
            (t.params.lazy.checkInView ? p() : c());
        }),
        a("transitionEnd", () => {
          t.params.lazy.enabled &&
            !t.params.lazy.loadOnTransitionStart &&
            (t.params.lazy.checkInView ? p() : c());
        }),
        a("slideChange", () => {
          const {
            lazy: e,
            cssMode: s,
            watchSlidesProgress: a,
            touchReleaseOnEdges: i,
            resistanceRatio: r,
          } = t.params;
          e.enabled && (s || (a && (i || 0 === r))) && c();
        }),
        Object.assign(t.lazy, { load: c, loadInSlide: o });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      function i(e, t) {
        const s = (function () {
          let e, t, s;
          return (a, i) => {
            for (t = -1, e = a.length; e - t > 1;)
              (s = (e + t) >> 1), a[s] <= i ? (t = s) : (e = s);
            return e;
          };
        })();
        let a, i;
        return (
          (this.x = e),
          (this.y = t),
          (this.lastIndex = e.length - 1),
          (this.interpolate = function (e) {
            return e
              ? ((i = s(this.x, e)),
                (a = i - 1),
                ((e - this.x[a]) * (this.y[i] - this.y[a])) /
                (this.x[i] - this.x[a]) +
                this.y[a])
              : 0;
          }),
          this
        );
      }
      function r() {
        t.controller.control &&
          t.controller.spline &&
          ((t.controller.spline = void 0), delete t.controller.spline);
      }
      s({ controller: { control: void 0, inverse: !1, by: "slide" } }),
        (t.controller = { control: void 0 }),
        a("beforeInit", () => {
          t.controller.control = t.params.controller.control;
        }),
        a("update", () => {
          r();
        }),
        a("resize", () => {
          r();
        }),
        a("observerUpdate", () => {
          r();
        }),
        a("setTranslate", (e, s, a) => {
          t.controller.control && t.controller.setTranslate(s, a);
        }),
        a("setTransition", (e, s, a) => {
          t.controller.control && t.controller.setTransition(s, a);
        }),
        Object.assign(t.controller, {
          setTranslate: function (e, s) {
            const a = t.controller.control;
            let r, n;
            const l = t.constructor;
            function o(e) {
              const s = t.rtlTranslate ? -t.translate : t.translate;
              "slide" === t.params.controller.by &&
                (!(function (e) {
                  t.controller.spline ||
                    (t.controller.spline = t.params.loop
                      ? new i(t.slidesGrid, e.slidesGrid)
                      : new i(t.snapGrid, e.snapGrid));
                })(e),
                  (n = -t.controller.spline.interpolate(-s))),
                (n && "container" !== t.params.controller.by) ||
                ((r =
                  (e.maxTranslate() - e.minTranslate()) /
                  (t.maxTranslate() - t.minTranslate())),
                  (n = (s - t.minTranslate()) * r + e.minTranslate())),
                t.params.controller.inverse && (n = e.maxTranslate() - n),
                e.updateProgress(n),
                e.setTranslate(n, t),
                e.updateActiveIndex(),
                e.updateSlidesClasses();
            }
            if (Array.isArray(a))
              for (let e = 0; e < a.length; e += 1)
                a[e] !== s && a[e] instanceof l && o(a[e]);
            else a instanceof l && s !== a && o(a);
          },
          setTransition: function (e, s) {
            const a = t.constructor,
              i = t.controller.control;
            let r;
            function n(s) {
              s.setTransition(e, t),
                0 !== e &&
                (s.transitionStart(),
                  s.params.autoHeight &&
                  p(() => {
                    s.updateAutoHeight();
                  }),
                  s.$wrapperEl.transitionEnd(() => {
                    i &&
                      (s.params.loop &&
                        "slide" === t.params.controller.by &&
                        s.loopFix(),
                        s.transitionEnd());
                  }));
            }
            if (Array.isArray(i))
              for (r = 0; r < i.length; r += 1)
                i[r] !== s && i[r] instanceof a && n(i[r]);
            else i instanceof a && s !== i && n(i);
          },
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        a11y: {
          enabled: !0,
          notificationClass: "swiper-notification",
          prevSlideMessage: "Previous slide",
          nextSlideMessage: "Next slide",
          firstSlideMessage: "This is the first slide",
          lastSlideMessage: "This is the last slide",
          paginationBulletMessage: "Go to slide {{index}}",
          slideLabelMessage: "{{index}} / {{slidesLength}}",
          containerMessage: null,
          containerRoleDescriptionMessage: null,
          itemRoleDescriptionMessage: null,
          slideRole: "group",
        },
      });
      let i = null;
      function r(e) {
        const t = i;
        0 !== t.length && (t.html(""), t.html(e));
      }
      function n(e) {
        e.attr("tabIndex", "0");
      }
      function l(e) {
        e.attr("tabIndex", "-1");
      }
      function o(e, t) {
        e.attr("role", t);
      }
      function c(e, t) {
        e.attr("aria-roledescription", t);
      }
      function p(e, t) {
        e.attr("aria-label", t);
      }
      function u(e) {
        e.attr("aria-disabled", !0);
      }
      function h(e) {
        e.attr("aria-disabled", !1);
      }
      function m(e) {
        if (13 !== e.keyCode && 32 !== e.keyCode) return;
        const s = t.params.a11y,
          a = d(e.target);
        t.navigation &&
          t.navigation.$nextEl &&
          a.is(t.navigation.$nextEl) &&
          ((t.isEnd && !t.params.loop) || t.slideNext(),
            t.isEnd ? r(s.lastSlideMessage) : r(s.nextSlideMessage)),
          t.navigation &&
          t.navigation.$prevEl &&
          a.is(t.navigation.$prevEl) &&
          ((t.isBeginning && !t.params.loop) || t.slidePrev(),
            t.isBeginning ? r(s.firstSlideMessage) : r(s.prevSlideMessage)),
          t.pagination &&
          a.is(U(t.params.pagination.bulletClass)) &&
          a[0].click();
      }
      function f() {
        return (
          t.pagination && t.pagination.bullets && t.pagination.bullets.length
        );
      }
      function g() {
        return f() && t.params.pagination.clickable;
      }
      const v = (e, t, s) => {
        n(e),
          "BUTTON" !== e[0].tagName && (o(e, "button"), e.on("keydown", m)),
          p(e, s),
          (function (e, t) {
            e.attr("aria-controls", t);
          })(e, t);
      },
        w = (e) => {
          const s = e.target.closest(`.${t.params.slideClass}`);
          if (!s || !t.slides.includes(s)) return;
          const a = t.slides.indexOf(s) === t.activeIndex,
            i =
              t.params.watchSlidesProgress &&
              t.visibleSlides &&
              t.visibleSlides.includes(s);
          a || i || t.slideTo(t.slides.indexOf(s), 0);
        };
      function b() {
        const e = t.params.a11y;
        t.$el.append(i);
        const s = t.$el;
        e.containerRoleDescriptionMessage &&
          c(s, e.containerRoleDescriptionMessage),
          e.containerMessage && p(s, e.containerMessage);
        const a = t.$wrapperEl,
          r =
            a.attr("id") ||
            `swiper-wrapper-${((n = 16),
              void 0 === n && (n = 16),
              "x"
                .repeat(n)
                .replace(/x/g, () =>
                  Math.round(16 * Math.random()).toString(16)
                ))
            }`;
        var n;
        const l =
          t.params.autoplay && t.params.autoplay.enabled ? "off" : "polite";
        var u;
        (u = r),
          a.attr("id", u),
          (function (e, t) {
            e.attr("aria-live", t);
          })(a, l),
          e.itemRoleDescriptionMessage &&
          c(d(t.slides), e.itemRoleDescriptionMessage),
          o(d(t.slides), e.slideRole);
        const h = t.params.loop
          ? t.slides.filter(
            (e) => !e.classList.contains(t.params.slideDuplicateClass)
          ).length
          : t.slides.length;
        let f, b;
        t.slides.each((s, a) => {
          const i = d(s),
            r = t.params.loop
              ? parseInt(i.attr("data-swiper-slide-index"), 10)
              : a;
          p(
            i,
            e.slideLabelMessage
              .replace(/\{\{index\}\}/, r + 1)
              .replace(/\{\{slidesLength\}\}/, h)
          );
        }),
          t.navigation && t.navigation.$nextEl && (f = t.navigation.$nextEl),
          t.navigation && t.navigation.$prevEl && (b = t.navigation.$prevEl),
          f && f.length && v(f, r, e.nextSlideMessage),
          b && b.length && v(b, r, e.prevSlideMessage),
          g() &&
          t.pagination.$el.on(
            "keydown",
            U(t.params.pagination.bulletClass),
            m
          ),
          t.$el.on("focus", w, !0);
      }
      a("beforeInit", () => {
        i = d(
          `<span class="${t.params.a11y.notificationClass}" aria-live="assertive" aria-atomic="true"></span>`
        );
      }),
        a("afterInit", () => {
          t.params.a11y.enabled && b();
        }),
        a("fromEdge toEdge afterInit lock unlock", () => {
          t.params.a11y.enabled &&
            (function () {
              if (t.params.loop || t.params.rewind || !t.navigation) return;
              const { $nextEl: e, $prevEl: s } = t.navigation;
              s &&
                s.length > 0 &&
                (t.isBeginning ? (u(s), l(s)) : (h(s), n(s))),
                e && e.length > 0 && (t.isEnd ? (u(e), l(e)) : (h(e), n(e)));
            })();
        }),
        a("paginationUpdate", () => {
          t.params.a11y.enabled &&
            (function () {
              const e = t.params.a11y;
              f() &&
                t.pagination.bullets.each((s) => {
                  const a = d(s);
                  t.params.pagination.clickable &&
                    (n(a),
                      t.params.pagination.renderBullet ||
                      (o(a, "button"),
                        p(
                          a,
                          e.paginationBulletMessage.replace(
                            /\{\{index\}\}/,
                            a.index() + 1
                          )
                        ))),
                    a.is(`.${t.params.pagination.bulletActiveClass}`)
                      ? a.attr("aria-current", "true")
                      : a.removeAttr("aria-current");
                });
            })();
        }),
        a("destroy", () => {
          t.params.a11y.enabled &&
            (function () {
              let e, s;
              i && i.length > 0 && i.remove(),
                t.navigation &&
                t.navigation.$nextEl &&
                (e = t.navigation.$nextEl),
                t.navigation &&
                t.navigation.$prevEl &&
                (s = t.navigation.$prevEl),
                e && e.off("keydown", m),
                s && s.off("keydown", m),
                g() &&
                t.pagination.$el.off(
                  "keydown",
                  U(t.params.pagination.bulletClass),
                  m
                ),
                t.$el.off("focus", w, !0);
            })();
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        history: { enabled: !1, root: "", replaceState: !1, key: "slides" },
      });
      let i = !1,
        n = {};
      const l = (e) =>
        e
          .toString()
          .replace(/\s+/g, "-")
          .replace(/[^\w-]+/g, "")
          .replace(/--+/g, "-")
          .replace(/^-+/, "")
          .replace(/-+$/, ""),
        o = (e) => {
          const t = r();
          let s;
          s = e ? new URL(e) : t.location;
          const a = s.pathname
            .slice(1)
            .split("/")
            .filter((e) => "" !== e),
            i = a.length;
          return { key: a[i - 2], value: a[i - 1] };
        },
        d = (e, s) => {
          const a = r();
          if (!i || !t.params.history.enabled) return;
          let n;
          n = t.params.url ? new URL(t.params.url) : a.location;
          const o = t.slides.eq(s);
          let d = l(o.attr("data-history"));
          if (t.params.history.root.length > 0) {
            let s = t.params.history.root;
            "/" === s[s.length - 1] && (s = s.slice(0, s.length - 1)),
              (d = `${s}/${e}/${d}`);
          } else n.pathname.includes(e) || (d = `${e}/${d}`);
          const c = a.history.state;
          (c && c.value === d) ||
            (t.params.history.replaceState
              ? a.history.replaceState({ value: d }, null, d)
              : a.history.pushState({ value: d }, null, d));
        },
        c = (e, s, a) => {
          if (s)
            for (let i = 0, r = t.slides.length; i < r; i += 1) {
              const r = t.slides.eq(i);
              if (
                l(r.attr("data-history")) === s &&
                !r.hasClass(t.params.slideDuplicateClass)
              ) {
                const s = r.index();
                t.slideTo(s, e, a);
              }
            }
          else t.slideTo(0, e, a);
        },
        p = () => {
          (n = o(t.params.url)), c(t.params.speed, t.paths.value, !1);
        };
      a("init", () => {
        t.params.history.enabled &&
          (() => {
            const e = r();
            if (t.params.history) {
              if (!e.history || !e.history.pushState)
                return (
                  (t.params.history.enabled = !1),
                  void (t.params.hashNavigation.enabled = !0)
                );
              (i = !0),
                (n = o(t.params.url)),
                (n.key || n.value) &&
                (c(0, n.value, t.params.runCallbacksOnInit),
                  t.params.history.replaceState ||
                  e.addEventListener("popstate", p));
            }
          })();
      }),
        a("destroy", () => {
          t.params.history.enabled &&
            (() => {
              const e = r();
              t.params.history.replaceState ||
                e.removeEventListener("popstate", p);
            })();
        }),
        a("transitionEnd _freeModeNoMomentumRelease", () => {
          i && d(t.params.history.key, t.activeIndex);
        }),
        a("slideChange", () => {
          i && t.params.cssMode && d(t.params.history.key, t.activeIndex);
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, emit: i, on: n } = e,
        l = !1;
      const o = a(),
        c = r();
      s({ hashNavigation: { enabled: !1, replaceState: !1, watchState: !1 } });
      const p = () => {
        i("hashChange");
        const e = o.location.hash.replace("#", "");
        if (e !== t.slides.eq(t.activeIndex).attr("data-hash")) {
          const s = t.$wrapperEl
            .children(`.${t.params.slideClass}[data-hash="${e}"]`)
            .index();
          if (void 0 === s) return;
          t.slideTo(s);
        }
      },
        u = () => {
          if (l && t.params.hashNavigation.enabled)
            if (
              t.params.hashNavigation.replaceState &&
              c.history &&
              c.history.replaceState
            )
              c.history.replaceState(
                null,
                null,
                `#${t.slides.eq(t.activeIndex).attr("data-hash")}` || ""
              ),
                i("hashSet");
            else {
              const e = t.slides.eq(t.activeIndex),
                s = e.attr("data-hash") || e.attr("data-history");
              (o.location.hash = s || ""), i("hashSet");
            }
        };
      n("init", () => {
        t.params.hashNavigation.enabled &&
          (() => {
            if (
              !t.params.hashNavigation.enabled ||
              (t.params.history && t.params.history.enabled)
            )
              return;
            l = !0;
            const e = o.location.hash.replace("#", "");
            if (e) {
              const s = 0;
              for (let a = 0, i = t.slides.length; a < i; a += 1) {
                const i = t.slides.eq(a);
                if (
                  (i.attr("data-hash") || i.attr("data-history")) === e &&
                  !i.hasClass(t.params.slideDuplicateClass)
                ) {
                  const e = i.index();
                  t.slideTo(e, s, t.params.runCallbacksOnInit, !0);
                }
              }
            }
            t.params.hashNavigation.watchState && d(c).on("hashchange", p);
          })();
      }),
        n("destroy", () => {
          t.params.hashNavigation.enabled &&
            t.params.hashNavigation.watchState &&
            d(c).off("hashchange", p);
        }),
        n("transitionEnd _freeModeNoMomentumRelease", () => {
          l && u();
        }),
        n("slideChange", () => {
          l && t.params.cssMode && u();
        });
    },
    function (e) {
      let t,
        { swiper: s, extendParams: i, on: r, emit: n } = e;
      function l() {
        const e = s.slides.eq(s.activeIndex);
        let a = s.params.autoplay.delay;
        e.attr("data-swiper-autoplay") &&
          (a = e.attr("data-swiper-autoplay") || s.params.autoplay.delay),
          clearTimeout(t),
          (t = p(() => {
            let e;
            s.params.autoplay.reverseDirection
              ? s.params.loop
                ? (s.loopFix(),
                  (e = s.slidePrev(s.params.speed, !0, !0)),
                  n("autoplay"))
                : s.isBeginning
                  ? s.params.autoplay.stopOnLastSlide
                    ? d()
                    : ((e = s.slideTo(
                      s.slides.length - 1,
                      s.params.speed,
                      !0,
                      !0
                    )),
                      n("autoplay"))
                  : ((e = s.slidePrev(s.params.speed, !0, !0)), n("autoplay"))
              : s.params.loop
                ? (s.loopFix(),
                  (e = s.slideNext(s.params.speed, !0, !0)),
                  n("autoplay"))
                : s.isEnd
                  ? s.params.autoplay.stopOnLastSlide
                    ? d()
                    : ((e = s.slideTo(0, s.params.speed, !0, !0)), n("autoplay"))
                  : ((e = s.slideNext(s.params.speed, !0, !0)), n("autoplay")),
              ((s.params.cssMode && s.autoplay.running) || !1 === e) && l();
          }, a));
      }
      function o() {
        return (
          void 0 === t &&
          !s.autoplay.running &&
          ((s.autoplay.running = !0), n("autoplayStart"), l(), !0)
        );
      }
      function d() {
        return (
          !!s.autoplay.running &&
          void 0 !== t &&
          (t && (clearTimeout(t), (t = void 0)),
            (s.autoplay.running = !1),
            n("autoplayStop"),
            !0)
        );
      }
      function c(e) {
        s.autoplay.running &&
          (s.autoplay.paused ||
            (t && clearTimeout(t),
              (s.autoplay.paused = !0),
              0 !== e && s.params.autoplay.waitForTransition
                ? ["transitionend", "webkitTransitionEnd"].forEach((e) => {
                  s.$wrapperEl[0].addEventListener(e, h);
                })
                : ((s.autoplay.paused = !1), l())));
      }
      function u() {
        const e = a();
        "hidden" === e.visibilityState && s.autoplay.running && c(),
          "visible" === e.visibilityState &&
          s.autoplay.paused &&
          (l(), (s.autoplay.paused = !1));
      }
      function h(e) {
        s &&
          !s.destroyed &&
          s.$wrapperEl &&
          e.target === s.$wrapperEl[0] &&
          (["transitionend", "webkitTransitionEnd"].forEach((e) => {
            s.$wrapperEl[0].removeEventListener(e, h);
          }),
            (s.autoplay.paused = !1),
            s.autoplay.running ? l() : d());
      }
      function m() {
        s.params.autoplay.disableOnInteraction
          ? d()
          : (n("autoplayPause"), c()),
          ["transitionend", "webkitTransitionEnd"].forEach((e) => {
            s.$wrapperEl[0].removeEventListener(e, h);
          });
      }
      function f() {
        s.params.autoplay.disableOnInteraction ||
          ((s.autoplay.paused = !1), n("autoplayResume"), l());
      }
      (s.autoplay = { running: !1, paused: !1 }),
        i({
          autoplay: {
            enabled: !1,
            delay: 3e3,
            waitForTransition: !0,
            disableOnInteraction: !0,
            stopOnLastSlide: !1,
            reverseDirection: !1,
            pauseOnMouseEnter: !1,
          },
        }),
        r("init", () => {
          if (s.params.autoplay.enabled) {
            o();
            a().addEventListener("visibilitychange", u),
              s.params.autoplay.pauseOnMouseEnter &&
              (s.$el.on("mouseenter", m), s.$el.on("mouseleave", f));
          }
        }),
        r("beforeTransitionStart", (e, t, a) => {
          s.autoplay.running &&
            (a || !s.params.autoplay.disableOnInteraction
              ? s.autoplay.pause(t)
              : d());
        }),
        r("sliderFirstMove", () => {
          s.autoplay.running &&
            (s.params.autoplay.disableOnInteraction ? d() : c());
        }),
        r("touchEnd", () => {
          s.params.cssMode &&
            s.autoplay.paused &&
            !s.params.autoplay.disableOnInteraction &&
            l();
        }),
        r("destroy", () => {
          s.$el.off("mouseenter", m),
            s.$el.off("mouseleave", f),
            s.autoplay.running && d();
          a().removeEventListener("visibilitychange", u);
        }),
        Object.assign(s.autoplay, { pause: c, run: l, start: o, stop: d });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        thumbs: {
          swiper: null,
          multipleActiveThumbs: !0,
          autoScrollOffset: 0,
          slideThumbActiveClass: "swiper-slide-thumb-active",
          thumbsContainerClass: "swiper-thumbs",
        },
      });
      let i = !1,
        r = !1;
      function n() {
        const e = t.thumbs.swiper;
        if (!e) return;
        const s = e.clickedIndex,
          a = e.clickedSlide;
        if (a && d(a).hasClass(t.params.thumbs.slideThumbActiveClass)) return;
        if (null == s) return;
        let i;
        if (
          ((i = e.params.loop
            ? parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"), 10)
            : s),
            t.params.loop)
        ) {
          let e = t.activeIndex;
          t.slides.eq(e).hasClass(t.params.slideDuplicateClass) &&
            (t.loopFix(),
              (t._clientLeft = t.$wrapperEl[0].clientLeft),
              (e = t.activeIndex));
          const s = t.slides
            .eq(e)
            .prevAll(`[data-swiper-slide-index="${i}"]`)
            .eq(0)
            .index(),
            a = t.slides
              .eq(e)
              .nextAll(`[data-swiper-slide-index="${i}"]`)
              .eq(0)
              .index();
          i = void 0 === s ? a : void 0 === a ? s : a - e < e - s ? a : s;
        }
        t.slideTo(i);
      }
      function l() {
        const { thumbs: e } = t.params;
        if (i) return !1;
        i = !0;
        const s = t.constructor;
        if (e.swiper instanceof s)
          (t.thumbs.swiper = e.swiper),
            Object.assign(t.thumbs.swiper.originalParams, {
              watchSlidesProgress: !0,
              slideToClickedSlide: !1,
            }),
            Object.assign(t.thumbs.swiper.params, {
              watchSlidesProgress: !0,
              slideToClickedSlide: !1,
            });
        else if (m(e.swiper)) {
          const a = Object.assign({}, e.swiper);
          Object.assign(a, {
            watchSlidesProgress: !0,
            slideToClickedSlide: !1,
          }),
            (t.thumbs.swiper = new s(a)),
            (r = !0);
        }
        return (
          t.thumbs.swiper.$el.addClass(t.params.thumbs.thumbsContainerClass),
          t.thumbs.swiper.on("tap", n),
          !0
        );
      }
      function o(e) {
        const s = t.thumbs.swiper;
        if (!s) return;
        const a =
          "auto" === s.params.slidesPerView
            ? s.slidesPerViewDynamic()
            : s.params.slidesPerView,
          i = t.params.thumbs.autoScrollOffset,
          r = i && !s.params.loop;
        if (t.realIndex !== s.realIndex || r) {
          let n,
            l,
            o = s.activeIndex;
          if (s.params.loop) {
            s.slides.eq(o).hasClass(s.params.slideDuplicateClass) &&
              (s.loopFix(),
                (s._clientLeft = s.$wrapperEl[0].clientLeft),
                (o = s.activeIndex));
            const e = s.slides
              .eq(o)
              .prevAll(`[data-swiper-slide-index="${t.realIndex}"]`)
              .eq(0)
              .index(),
              a = s.slides
                .eq(o)
                .nextAll(`[data-swiper-slide-index="${t.realIndex}"]`)
                .eq(0)
                .index();
            (n =
              void 0 === e
                ? a
                : void 0 === a
                  ? e
                  : a - o == o - e
                    ? s.params.slidesPerGroup > 1
                      ? a
                      : o
                    : a - o < o - e
                      ? a
                      : e),
              (l = t.activeIndex > t.previousIndex ? "next" : "prev");
          } else (n = t.realIndex), (l = n > t.previousIndex ? "next" : "prev");
          r && (n += "next" === l ? i : -1 * i),
            s.visibleSlidesIndexes &&
            s.visibleSlidesIndexes.indexOf(n) < 0 &&
            (s.params.centeredSlides
              ? (n =
                n > o
                  ? n - Math.floor(a / 2) + 1
                  : n + Math.floor(a / 2) - 1)
              : n > o && s.params.slidesPerGroup,
              s.slideTo(n, e ? 0 : void 0));
        }
        let n = 1;
        const l = t.params.thumbs.slideThumbActiveClass;
        if (
          (t.params.slidesPerView > 1 &&
            !t.params.centeredSlides &&
            (n = t.params.slidesPerView),
            t.params.thumbs.multipleActiveThumbs || (n = 1),
            (n = Math.floor(n)),
            s.slides.removeClass(l),
            s.params.loop || (s.params.virtual && s.params.virtual.enabled))
        )
          for (let e = 0; e < n; e += 1)
            s.$wrapperEl
              .children(`[data-swiper-slide-index="${t.realIndex + e}"]`)
              .addClass(l);
        else
          for (let e = 0; e < n; e += 1)
            s.slides.eq(t.realIndex + e).addClass(l);
      }
      (t.thumbs = { swiper: null }),
        a("beforeInit", () => {
          const { thumbs: e } = t.params;
          e && e.swiper && (l(), o(!0));
        }),
        a("slideChange update resize observerUpdate", () => {
          t.thumbs.swiper && o();
        }),
        a("setTransition", (e, s) => {
          const a = t.thumbs.swiper;
          a && a.setTransition(s);
        }),
        a("beforeDestroy", () => {
          const e = t.thumbs.swiper;
          e && r && e && e.destroy();
        }),
        Object.assign(t.thumbs, { init: l, update: o });
    },
    function (e) {
      let { swiper: t, extendParams: s, emit: a, once: i } = e;
      s({
        freeMode: {
          enabled: !1,
          momentum: !0,
          momentumRatio: 1,
          momentumBounce: !0,
          momentumBounceRatio: 1,
          momentumVelocityRatio: 1,
          sticky: !1,
          minimumVelocity: 0.02,
        },
      }),
        Object.assign(t, {
          freeMode: {
            onTouchStart: function () {
              const e = t.getTranslate();
              t.setTranslate(e),
                t.setTransition(0),
                (t.touchEventsData.velocities.length = 0),
                t.freeMode.onTouchEnd({
                  currentPos: t.rtl ? t.translate : -t.translate,
                });
            },
            onTouchMove: function () {
              const { touchEventsData: e, touches: s } = t;
              0 === e.velocities.length &&
                e.velocities.push({
                  position: s[t.isHorizontal() ? "startX" : "startY"],
                  time: e.touchStartTime,
                }),
                e.velocities.push({
                  position: s[t.isHorizontal() ? "currentX" : "currentY"],
                  time: u(),
                });
            },
            onTouchEnd: function (e) {
              let { currentPos: s } = e;
              const {
                params: r,
                $wrapperEl: n,
                rtlTranslate: l,
                snapGrid: o,
                touchEventsData: d,
              } = t,
                c = u() - d.touchStartTime;
              if (s < -t.minTranslate()) t.slideTo(t.activeIndex);
              else if (s > -t.maxTranslate())
                t.slides.length < o.length
                  ? t.slideTo(o.length - 1)
                  : t.slideTo(t.slides.length - 1);
              else {
                if (r.freeMode.momentum) {
                  if (d.velocities.length > 1) {
                    const e = d.velocities.pop(),
                      s = d.velocities.pop(),
                      a = e.position - s.position,
                      i = e.time - s.time;
                    (t.velocity = a / i),
                      (t.velocity /= 2),
                      Math.abs(t.velocity) < r.freeMode.minimumVelocity &&
                      (t.velocity = 0),
                      (i > 150 || u() - e.time > 300) && (t.velocity = 0);
                  } else t.velocity = 0;
                  (t.velocity *= r.freeMode.momentumVelocityRatio),
                    (d.velocities.length = 0);
                  let e = 1e3 * r.freeMode.momentumRatio;
                  const s = t.velocity * e;
                  let c = t.translate + s;
                  l && (c = -c);
                  let p,
                    h = !1;
                  const m =
                    20 * Math.abs(t.velocity) * r.freeMode.momentumBounceRatio;
                  let f;
                  if (c < t.maxTranslate())
                    r.freeMode.momentumBounce
                      ? (c + t.maxTranslate() < -m &&
                        (c = t.maxTranslate() - m),
                        (p = t.maxTranslate()),
                        (h = !0),
                        (d.allowMomentumBounce = !0))
                      : (c = t.maxTranslate()),
                      r.loop && r.centeredSlides && (f = !0);
                  else if (c > t.minTranslate())
                    r.freeMode.momentumBounce
                      ? (c - t.minTranslate() > m && (c = t.minTranslate() + m),
                        (p = t.minTranslate()),
                        (h = !0),
                        (d.allowMomentumBounce = !0))
                      : (c = t.minTranslate()),
                      r.loop && r.centeredSlides && (f = !0);
                  else if (r.freeMode.sticky) {
                    let e;
                    for (let t = 0; t < o.length; t += 1)
                      if (o[t] > -c) {
                        e = t;
                        break;
                      }
                    (c =
                      Math.abs(o[e] - c) < Math.abs(o[e - 1] - c) ||
                        "next" === t.swipeDirection
                        ? o[e]
                        : o[e - 1]),
                      (c = -c);
                  }
                  if (
                    (f &&
                      i("transitionEnd", () => {
                        t.loopFix();
                      }),
                      0 !== t.velocity)
                  ) {
                    if (
                      ((e = l
                        ? Math.abs((-c - t.translate) / t.velocity)
                        : Math.abs((c - t.translate) / t.velocity)),
                        r.freeMode.sticky)
                    ) {
                      const s = Math.abs((l ? -c : c) - t.translate),
                        a = t.slidesSizesGrid[t.activeIndex];
                      e =
                        s < a
                          ? r.speed
                          : s < 2 * a
                            ? 1.5 * r.speed
                            : 2.5 * r.speed;
                    }
                  } else if (r.freeMode.sticky) return void t.slideToClosest();
                  r.freeMode.momentumBounce && h
                    ? (t.updateProgress(p),
                      t.setTransition(e),
                      t.setTranslate(c),
                      t.transitionStart(!0, t.swipeDirection),
                      (t.animating = !0),
                      n.transitionEnd(() => {
                        t &&
                          !t.destroyed &&
                          d.allowMomentumBounce &&
                          (a("momentumBounce"),
                            t.setTransition(r.speed),
                            setTimeout(() => {
                              t.setTranslate(p),
                                n.transitionEnd(() => {
                                  t && !t.destroyed && t.transitionEnd();
                                });
                            }, 0));
                      }))
                    : t.velocity
                      ? (a("_freeModeNoMomentumRelease"),
                        t.updateProgress(c),
                        t.setTransition(e),
                        t.setTranslate(c),
                        t.transitionStart(!0, t.swipeDirection),
                        t.animating ||
                        ((t.animating = !0),
                          n.transitionEnd(() => {
                            t && !t.destroyed && t.transitionEnd();
                          })))
                      : t.updateProgress(c),
                    t.updateActiveIndex(),
                    t.updateSlidesClasses();
                } else {
                  if (r.freeMode.sticky) return void t.slideToClosest();
                  r.freeMode && a("_freeModeNoMomentumRelease");
                }
                (!r.freeMode.momentum || c >= r.longSwipesMs) &&
                  (t.updateProgress(),
                    t.updateActiveIndex(),
                    t.updateSlidesClasses());
              }
            },
          },
        });
    },
    function (e) {
      let t,
        s,
        a,
        { swiper: i, extendParams: r } = e;
      r({ grid: { rows: 1, fill: "column" } }),
        (i.grid = {
          initSlides: (e) => {
            const { slidesPerView: r } = i.params,
              { rows: n, fill: l } = i.params.grid;
            (s = t / n),
              (a = Math.floor(e / n)),
              (t = Math.floor(e / n) === e / n ? e : Math.ceil(e / n) * n),
              "auto" !== r && "row" === l && (t = Math.max(t, r * n));
          },
          updateSlide: (e, r, n, l) => {
            const { slidesPerGroup: o, spaceBetween: d } = i.params,
              { rows: c, fill: p } = i.params.grid;
            let u, h, m;
            if ("row" === p && o > 1) {
              const s = Math.floor(e / (o * c)),
                a = e - c * o * s,
                i = 0 === s ? o : Math.min(Math.ceil((n - s * c * o) / c), o);
              (m = Math.floor(a / i)),
                (h = a - m * i + s * o),
                (u = h + (m * t) / c),
                r.css({ "-webkit-order": u, order: u });
            } else
              "column" === p
                ? ((h = Math.floor(e / c)),
                  (m = e - h * c),
                  (h > a || (h === a && m === c - 1)) &&
                  ((m += 1), m >= c && ((m = 0), (h += 1))))
                : ((m = Math.floor(e / s)), (h = e - m * s));
            r.css(l("margin-top"), 0 !== m ? d && `${d}px` : "");
          },
          updateWrapperSize: (e, s, a) => {
            const {
              spaceBetween: r,
              centeredSlides: n,
              roundLengths: l,
            } = i.params,
              { rows: o } = i.params.grid;
            if (
              ((i.virtualSize = (e + r) * t),
                (i.virtualSize = Math.ceil(i.virtualSize / o) - r),
                i.$wrapperEl.css({ [a("width")]: `${i.virtualSize + r}px` }),
                n)
            ) {
              s.splice(0, s.length);
              const e = [];
              for (let t = 0; t < s.length; t += 1) {
                let a = s[t];
                l && (a = Math.floor(a)),
                  s[t] < i.virtualSize + s[0] && e.push(a);
              }
              s.push(...e);
            }
          },
        });
    },
    function (e) {
      let { swiper: t } = e;
      Object.assign(t, {
        appendSlide: K.bind(t),
        prependSlide: Z.bind(t),
        addSlide: J.bind(t),
        removeSlide: Q.bind(t),
        removeAllSlides: ee.bind(t),
      });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({ fadeEffect: { crossFade: !1, transformEl: null } }),
        te({
          effect: "fade",
          swiper: t,
          on: a,
          setTranslate: () => {
            const { slides: e } = t,
              s = t.params.fadeEffect;
            for (let a = 0; a < e.length; a += 1) {
              const e = t.slides.eq(a);
              let i = -e[0].swiperSlideOffset;
              t.params.virtualTranslate || (i -= t.translate);
              let r = 0;
              t.isHorizontal() || ((r = i), (i = 0));
              const n = t.params.fadeEffect.crossFade
                ? Math.max(1 - Math.abs(e[0].progress), 0)
                : 1 + Math.min(Math.max(e[0].progress, -1), 0);
              se(s, e)
                .css({ opacity: n })
                .transform(`translate3d(${i}px, ${r}px, 0px)`);
            }
          },
          setTransition: (e) => {
            const { transformEl: s } = t.params.fadeEffect;
            (s ? t.slides.find(s) : t.slides).transition(e),
              ae({ swiper: t, duration: e, transformEl: s, allSlides: !0 });
          },
          overwriteParams: () => ({
            slidesPerView: 1,
            slidesPerGroup: 1,
            watchSlidesProgress: !0,
            spaceBetween: 0,
            virtualTranslate: !t.params.cssMode,
          }),
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        cubeEffect: {
          slideShadows: !0,
          shadow: !0,
          shadowOffset: 20,
          shadowScale: 0.94,
        },
      }),
        te({
          effect: "cube",
          swiper: t,
          on: a,
          setTranslate: () => {
            const {
              $el: e,
              $wrapperEl: s,
              slides: a,
              width: i,
              height: r,
              rtlTranslate: n,
              size: l,
              browser: o,
            } = t,
              c = t.params.cubeEffect,
              p = t.isHorizontal(),
              u = t.virtual && t.params.virtual.enabled;
            let h,
              m = 0;
            c.shadow &&
              (p
                ? ((h = s.find(".swiper-cube-shadow")),
                  0 === h.length &&
                  ((h = d('<div class="swiper-cube-shadow"></div>')),
                    s.append(h)),
                  h.css({ height: `${i}px` }))
                : ((h = e.find(".swiper-cube-shadow")),
                  0 === h.length &&
                  ((h = d('<div class="swiper-cube-shadow"></div>')),
                    e.append(h))));
            for (let e = 0; e < a.length; e += 1) {
              const t = a.eq(e);
              let s = e;
              u && (s = parseInt(t.attr("data-swiper-slide-index"), 10));
              let i = 90 * s,
                r = Math.floor(i / 360);
              n && ((i = -i), (r = Math.floor(-i / 360)));
              const o = Math.max(Math.min(t[0].progress, 1), -1);
              let h = 0,
                f = 0,
                g = 0;
              s % 4 == 0
                ? ((h = 4 * -r * l), (g = 0))
                : (s - 1) % 4 == 0
                  ? ((h = 0), (g = 4 * -r * l))
                  : (s - 2) % 4 == 0
                    ? ((h = l + 4 * r * l), (g = l))
                    : (s - 3) % 4 == 0 && ((h = -l), (g = 3 * l + 4 * l * r)),
                n && (h = -h),
                p || ((f = h), (h = 0));
              const v = `rotateX(${p ? 0 : -i}deg) rotateY(${p ? i : 0
                }deg) translate3d(${h}px, ${f}px, ${g}px)`;
              if (
                (o <= 1 &&
                  o > -1 &&
                  ((m = 90 * s + 90 * o), n && (m = 90 * -s - 90 * o)),
                  t.transform(v),
                  c.slideShadows)
              ) {
                let e = p
                  ? t.find(".swiper-slide-shadow-left")
                  : t.find(".swiper-slide-shadow-top"),
                  s = p
                    ? t.find(".swiper-slide-shadow-right")
                    : t.find(".swiper-slide-shadow-bottom");
                0 === e.length &&
                  ((e = d(
                    `<div class="swiper-slide-shadow-${p ? "left" : "top"
                    }"></div>`
                  )),
                    t.append(e)),
                  0 === s.length &&
                  ((s = d(
                    `<div class="swiper-slide-shadow-${p ? "right" : "bottom"
                    }"></div>`
                  )),
                    t.append(s)),
                  e.length && (e[0].style.opacity = Math.max(-o, 0)),
                  s.length && (s[0].style.opacity = Math.max(o, 0));
              }
            }
            if (
              (s.css({
                "-webkit-transform-origin": `50% 50% -${l / 2}px`,
                "transform-origin": `50% 50% -${l / 2}px`,
              }),
                c.shadow)
            )
              if (p)
                h.transform(
                  `translate3d(0px, ${i / 2 + c.shadowOffset}px, ${-i / 2
                  }px) rotateX(90deg) rotateZ(0deg) scale(${c.shadowScale})`
                );
              else {
                const e = Math.abs(m) - 90 * Math.floor(Math.abs(m) / 90),
                  t =
                    1.5 -
                    (Math.sin((2 * e * Math.PI) / 360) / 2 +
                      Math.cos((2 * e * Math.PI) / 360) / 2),
                  s = c.shadowScale,
                  a = c.shadowScale / t,
                  i = c.shadowOffset;
                h.transform(
                  `scale3d(${s}, 1, ${a}) translate3d(0px, ${r / 2 + i}px, ${-r / 2 / a
                  }px) rotateX(-90deg)`
                );
              }
            const f = o.isSafari || o.isWebView ? -l / 2 : 0;
            s.transform(
              `translate3d(0px,0,${f}px) rotateX(${t.isHorizontal() ? 0 : m
              }deg) rotateY(${t.isHorizontal() ? -m : 0}deg)`
            );
          },
          setTransition: (e) => {
            const { $el: s, slides: a } = t;
            a
              .transition(e)
              .find(
                ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left"
              )
              .transition(e),
              t.params.cubeEffect.shadow &&
              !t.isHorizontal() &&
              s.find(".swiper-cube-shadow").transition(e);
          },
          perspective: () => !0,
          overwriteParams: () => ({
            slidesPerView: 1,
            slidesPerGroup: 1,
            watchSlidesProgress: !0,
            resistanceRatio: 0,
            spaceBetween: 0,
            centeredSlides: !1,
            virtualTranslate: !0,
          }),
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        flipEffect: { slideShadows: !0, limitRotation: !0, transformEl: null },
      }),
        te({
          effect: "flip",
          swiper: t,
          on: a,
          setTranslate: () => {
            const { slides: e, rtlTranslate: s } = t,
              a = t.params.flipEffect;
            for (let i = 0; i < e.length; i += 1) {
              const r = e.eq(i);
              let n = r[0].progress;
              t.params.flipEffect.limitRotation &&
                (n = Math.max(Math.min(r[0].progress, 1), -1));
              const l = r[0].swiperSlideOffset;
              let o = -180 * n,
                d = 0,
                c = t.params.cssMode ? -l - t.translate : -l,
                p = 0;
              if (
                (t.isHorizontal()
                  ? s && (o = -o)
                  : ((p = c), (c = 0), (d = -o), (o = 0)),
                  (r[0].style.zIndex = -Math.abs(Math.round(n)) + e.length),
                  a.slideShadows)
              ) {
                let e = t.isHorizontal()
                  ? r.find(".swiper-slide-shadow-left")
                  : r.find(".swiper-slide-shadow-top"),
                  s = t.isHorizontal()
                    ? r.find(".swiper-slide-shadow-right")
                    : r.find(".swiper-slide-shadow-bottom");
                0 === e.length &&
                  (e = ie(a, r, t.isHorizontal() ? "left" : "top")),
                  0 === s.length &&
                  (s = ie(a, r, t.isHorizontal() ? "right" : "bottom")),
                  e.length && (e[0].style.opacity = Math.max(-n, 0)),
                  s.length && (s[0].style.opacity = Math.max(n, 0));
              }
              const u = `translate3d(${c}px, ${p}px, 0px) rotateX(${d}deg) rotateY(${o}deg)`;
              se(a, r).transform(u);
            }
          },
          setTransition: (e) => {
            const { transformEl: s } = t.params.flipEffect;
            (s ? t.slides.find(s) : t.slides)
              .transition(e)
              .find(
                ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left"
              )
              .transition(e),
              ae({ swiper: t, duration: e, transformEl: s });
          },
          perspective: () => !0,
          overwriteParams: () => ({
            slidesPerView: 1,
            slidesPerGroup: 1,
            watchSlidesProgress: !0,
            spaceBetween: 0,
            virtualTranslate: !t.params.cssMode,
          }),
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        coverflowEffect: {
          rotate: 50,
          stretch: 0,
          depth: 100,
          scale: 1,
          modifier: 1,
          slideShadows: !0,
          transformEl: null,
        },
      }),
        te({
          effect: "coverflow",
          swiper: t,
          on: a,
          setTranslate: () => {
            const { width: e, height: s, slides: a, slidesSizesGrid: i } = t,
              r = t.params.coverflowEffect,
              n = t.isHorizontal(),
              l = t.translate,
              o = n ? e / 2 - l : s / 2 - l,
              d = n ? r.rotate : -r.rotate,
              c = r.depth;
            for (let e = 0, t = a.length; e < t; e += 1) {
              const t = a.eq(e),
                s = i[e],
                l = ((o - t[0].swiperSlideOffset - s / 2) / s) * r.modifier;
              let p = n ? d * l : 0,
                u = n ? 0 : d * l,
                h = -c * Math.abs(l),
                m = r.stretch;
              "string" == typeof m &&
                -1 !== m.indexOf("%") &&
                (m = (parseFloat(r.stretch) / 100) * s);
              let f = n ? 0 : m * l,
                g = n ? m * l : 0,
                v = 1 - (1 - r.scale) * Math.abs(l);
              Math.abs(g) < 0.001 && (g = 0),
                Math.abs(f) < 0.001 && (f = 0),
                Math.abs(h) < 0.001 && (h = 0),
                Math.abs(p) < 0.001 && (p = 0),
                Math.abs(u) < 0.001 && (u = 0),
                Math.abs(v) < 0.001 && (v = 0);
              const w = `translate3d(${g}px,${f}px,${h}px)  rotateX(${u}deg) rotateY(${p}deg) scale(${v})`;
              if (
                (se(r, t).transform(w),
                  (t[0].style.zIndex = 1 - Math.abs(Math.round(l))),
                  r.slideShadows)
              ) {
                let e = n
                  ? t.find(".swiper-slide-shadow-left")
                  : t.find(".swiper-slide-shadow-top"),
                  s = n
                    ? t.find(".swiper-slide-shadow-right")
                    : t.find(".swiper-slide-shadow-bottom");
                0 === e.length && (e = ie(r, t, n ? "left" : "top")),
                  0 === s.length && (s = ie(r, t, n ? "right" : "bottom")),
                  e.length && (e[0].style.opacity = l > 0 ? l : 0),
                  s.length && (s[0].style.opacity = -l > 0 ? -l : 0);
              }
            }
          },
          setTransition: (e) => {
            const { transformEl: s } = t.params.coverflowEffect;
            (s ? t.slides.find(s) : t.slides)
              .transition(e)
              .find(
                ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left"
              )
              .transition(e);
          },
          perspective: () => !0,
          overwriteParams: () => ({ watchSlidesProgress: !0 }),
        });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({
        creativeEffect: {
          transformEl: null,
          limitProgress: 1,
          shadowPerProgress: !1,
          progressMultiplier: 1,
          perspective: !0,
          prev: {
            translate: [0, 0, 0],
            rotate: [0, 0, 0],
            opacity: 1,
            scale: 1,
          },
          next: {
            translate: [0, 0, 0],
            rotate: [0, 0, 0],
            opacity: 1,
            scale: 1,
          },
        },
      });
      const i = (e) => ("string" == typeof e ? e : `${e}px`);
      te({
        effect: "creative",
        swiper: t,
        on: a,
        setTranslate: () => {
          const { slides: e, $wrapperEl: s, slidesSizesGrid: a } = t,
            r = t.params.creativeEffect,
            { progressMultiplier: n } = r,
            l = t.params.centeredSlides;
          if (l) {
            const e = a[0] / 2 - t.params.slidesOffsetBefore || 0;
            s.transform(`translateX(calc(50% - ${e}px))`);
          }
          for (let s = 0; s < e.length; s += 1) {
            const a = e.eq(s),
              o = a[0].progress,
              d = Math.min(
                Math.max(a[0].progress, -r.limitProgress),
                r.limitProgress
              );
            let c = d;
            l ||
              (c = Math.min(
                Math.max(a[0].originalProgress, -r.limitProgress),
                r.limitProgress
              ));
            const p = a[0].swiperSlideOffset,
              u = [t.params.cssMode ? -p - t.translate : -p, 0, 0],
              h = [0, 0, 0];
            let m = !1;
            t.isHorizontal() || ((u[1] = u[0]), (u[0] = 0));
            let f = {
              translate: [0, 0, 0],
              rotate: [0, 0, 0],
              scale: 1,
              opacity: 1,
            };
            d < 0
              ? ((f = r.next), (m = !0))
              : d > 0 && ((f = r.prev), (m = !0)),
              u.forEach((e, t) => {
                u[t] = `calc(${e}px + (${i(f.translate[t])} * ${Math.abs(
                  d * n
                )}))`;
              }),
              h.forEach((e, t) => {
                h[t] = f.rotate[t] * Math.abs(d * n);
              }),
              (a[0].style.zIndex = -Math.abs(Math.round(o)) + e.length);
            const g = u.join(", "),
              v = `rotateX(${h[0]}deg) rotateY(${h[1]}deg) rotateZ(${h[2]}deg)`,
              w =
                c < 0
                  ? `scale(${1 + (1 - f.scale) * c * n})`
                  : `scale(${1 - (1 - f.scale) * c * n})`,
              b =
                c < 0
                  ? 1 + (1 - f.opacity) * c * n
                  : 1 - (1 - f.opacity) * c * n,
              x = `translate3d(${g}) ${v} ${w}`;
            if ((m && f.shadow) || !m) {
              let e = a.children(".swiper-slide-shadow");
              if ((0 === e.length && f.shadow && (e = ie(r, a)), e.length)) {
                const t = r.shadowPerProgress ? d * (1 / r.limitProgress) : d;
                e[0].style.opacity = Math.min(Math.max(Math.abs(t), 0), 1);
              }
            }
            const y = se(r, a);
            y.transform(x).css({ opacity: b }),
              f.origin && y.css("transform-origin", f.origin);
          }
        },
        setTransition: (e) => {
          const { transformEl: s } = t.params.creativeEffect;
          (s ? t.slides.find(s) : t.slides)
            .transition(e)
            .find(".swiper-slide-shadow")
            .transition(e),
            ae({ swiper: t, duration: e, transformEl: s, allSlides: !0 });
        },
        perspective: () => t.params.creativeEffect.perspective,
        overwriteParams: () => ({
          watchSlidesProgress: !0,
          virtualTranslate: !t.params.cssMode,
        }),
      });
    },
    function (e) {
      let { swiper: t, extendParams: s, on: a } = e;
      s({ cardsEffect: { slideShadows: !0, transformEl: null } }),
        te({
          effect: "cards",
          swiper: t,
          on: a,
          setTranslate: () => {
            const { slides: e, activeIndex: s } = t,
              a = t.params.cardsEffect,
              { startTranslate: i, isTouched: r } = t.touchEventsData,
              n = t.translate;
            for (let l = 0; l < e.length; l += 1) {
              const o = e.eq(l),
                d = o[0].progress,
                c = Math.min(Math.max(d, -4), 4);
              let p = o[0].swiperSlideOffset;
              t.params.centeredSlides &&
                !t.params.cssMode &&
                t.$wrapperEl.transform(`translateX(${t.minTranslate()}px)`),
                t.params.centeredSlides &&
                t.params.cssMode &&
                (p -= e[0].swiperSlideOffset);
              let u = t.params.cssMode ? -p - t.translate : -p,
                h = 0;
              const m = -100 * Math.abs(c);
              let f = 1,
                g = -2 * c,
                v = 8 - 0.75 * Math.abs(c);
              const w =
                (l === s || l === s - 1) &&
                c > 0 &&
                c < 1 &&
                (r || t.params.cssMode) &&
                n < i,
                b =
                  (l === s || l === s + 1) &&
                  c < 0 &&
                  c > -1 &&
                  (r || t.params.cssMode) &&
                  n > i;
              if (w || b) {
                const e = (1 - Math.abs((Math.abs(c) - 0.5) / 0.5)) ** 0.5;
                (g += -28 * c * e),
                  (f += -0.5 * e),
                  (v += 96 * e),
                  (h = -25 * e * Math.abs(c) + "%");
              }
              if (
                ((u =
                  c < 0
                    ? `calc(${u}px + (${v * Math.abs(c)}%))`
                    : c > 0
                      ? `calc(${u}px + (-${v * Math.abs(c)}%))`
                      : `${u}px`),
                  !t.isHorizontal())
              ) {
                const e = h;
                (h = u), (u = e);
              }
              const x = `\n        translate3d(${u}, ${h}, ${m}px)\n        rotateZ(${g}deg)\n        scale(${c < 0 ? "" + (1 + (1 - f) * c) : "" + (1 - (1 - f) * c)
                })\n      `;
              if (a.slideShadows) {
                let e = o.find(".swiper-slide-shadow");
                0 === e.length && (e = ie(a, o)),
                  e.length &&
                  (e[0].style.opacity = Math.min(
                    Math.max((Math.abs(c) - 0.5) / 0.5, 0),
                    1
                  ));
              }
              o[0].style.zIndex = -Math.abs(Math.round(d)) + e.length;
              se(a, o).transform(x);
            }
          },
          setTransition: (e) => {
            const { transformEl: s } = t.params.cardsEffect;
            (s ? t.slides.find(s) : t.slides)
              .transition(e)
              .find(".swiper-slide-shadow")
              .transition(e),
              ae({ swiper: t, duration: e, transformEl: s });
          },
          perspective: () => !0,
          overwriteParams: () => ({
            watchSlidesProgress: !0,
            virtualTranslate: !t.params.cssMode,
          }),
        });
    },
  ];
  return q.use(re), q;
});
/*  jQuery Nice Select - v1.0
    https://github.com/hernansartorio/jquery-nice-select
    Made by Hernán Sartorio  */
!(function (e) {
  e.fn.niceSelect = function (t) {
    function s(t) {
      t.after(
        e("<div></div>")
          .addClass("nice-select")
          .addClass(t.attr("class") || "")
          .addClass(t.attr("disabled") ? "disabled" : "")
          .attr("tabindex", t.attr("disabled") ? null : "0")
          .html('<span class="current"></span><ul class="list"></ul>')
      );
      var s = t.next(),
        n = t.find("option"),
        i = t.find("option:selected");
      s.find(".current").html(i.data("display") || i.text()),
        n.each(function (t) {
          if (t != 0) {
            var n = e(this),
              i = n.data("display");
            s.find("ul").append(
              e("<li></li>")
                .attr("data-value", n.val())
                .attr("data-display", i || null)
                .addClass(
                  "option" +
                  (n.is(":selected") ? " selected" : "") +
                  (n.is(":disabled") ? " disabled" : "")
                )
                .html(n.text())
            );
          }
        });
    }
    if ("string" == typeof t)
      return (
        "update" == t
          ? this.each(function () {
            var t = e(this),
              n = e(this).next(".nice-select"),
              i = n.hasClass("open");
            n.length && (n.remove(), s(t), i && t.next().trigger("click"));
          })
          : "destroy" == t
            ? (this.each(function () {
              var t = e(this),
                s = e(this).next(".nice-select");
              s.length && (s.remove(), t.css("display", ""));
            }),
              0 == e(".nice-select").length && e(document).off(".nice_select"))
            : console.log('Method "' + t + '" does not exist.'),
        this
      );
    this.hide(),
      this.each(function () {
        var t = e(this);
        t.next().hasClass("nice-select") || s(t);
      }),
      e(document).off(".nice_select"),
      e(document).on("click.nice_select", ".nice-select", function (t) {
        var s = e(this);
        e(".nice-select").not(s).removeClass("open"),
          s.toggleClass("open"),
          s.hasClass("open")
            ? (s.find(".option"),
              s.find(".focus").removeClass("focus"),
              s.find(".selected").addClass("focus"))
            : s.focus();
      }),
      e(document).on("click.nice_select", function (t) {
        0 === e(t.target).closest(".nice-select").length &&
          e(".nice-select").removeClass("open").find(".option");
      }),
      e(document).on(
        "click.nice_select",
        ".nice-select .option:not(.disabled)",
        function (t) {
          var s = e(this),
            n = s.closest(".nice-select");
          n.find(".selected").removeClass("selected"), s.addClass("selected");
          var i = s.data("display") || s.text();
          n.find(".current").text(i),
            n.prev("select").val(s.data("value")).trigger("change");
        }
      ),
      e(document).on("keydown.nice_select", ".nice-select", function (t) {
        var s = e(this),
          n = e(s.find(".focus") || s.find(".list .option.selected"));
        if (32 == t.keyCode || 13 == t.keyCode)
          return (
            s.hasClass("open") ? n.trigger("click") : s.trigger("click"), !1
          );
        if (40 == t.keyCode) {
          if (s.hasClass("open")) {
            var i = n.nextAll(".option:not(.disabled)").first();
            i.length > 0 &&
              (s.find(".focus").removeClass("focus"), i.addClass("focus"));
          } else s.trigger("click");
          return !1;
        }
        if (38 == t.keyCode) {
          if (s.hasClass("open")) {
            var l = n.prevAll(".option:not(.disabled)").first();
            l.length > 0 &&
              (s.find(".focus").removeClass("focus"), l.addClass("focus"));
          } else s.trigger("click");
          return !1;
        }
        if (27 == t.keyCode) s.hasClass("open") && s.trigger("click");
        else if (9 == t.keyCode && s.hasClass("open")) return !1;
      });
    var n = document.createElement("a").style;
    return (
      (n.cssText = "pointer-events:auto"),
      "auto" !== n.pointerEvents && e("html").addClass("no-csspointerevents"),
      this
    );
  };
})(jQuery);
