H5PIntegration = {
  ajax: { setFinished: "", contentUserData: "" },
  ajaxPath: "/h5p/ajax?action=",
  contents: {
    "cid-3706082533": {
      displayOptions: {
        copy: false,
        copyright: false,
        embed: false,
        export: false,
        frame: false,
        icon: false,
      },
      fullScreen: "0",
      jsonContent:
        '{"mode":"normal","dialogs":[{"text":"<p style=\\"text-align:center\\">Τη συναντάμε σε χαμηλό υψόμετρο (0 - 600 μέτρα) και, κυρίως, στα νησιά και στις ακτές της Ελλάδας. Περιλαμβάνει θάμνους και γενικά χαμηλή βλάστηση με φυτά όπως το πουρνάρι, την κουμαριά, το θυμάρι, την αγριελιά, τη μυρτιά κ.ά.</p>\\n","answer":"<p style=\\"text-align:center\\">Μεσογειακή ζώνη (μακία)</p>\\n","tips":{},"image":{"path":"resources/image-mfy0ZpS5.jpg","mime":"image/jpeg","copyright":{"license":"U"},"width":472,"height":407},"imageAltText":"Μεσογειακή ζώνη (μακία)"},{"text":"<p>Τη συναντάμε σε υψόμετρο από 600μ. μέχρι 1200μ. και περιλαμβάνει φυλλοβόλα πλατύφυλλα δάση με δέντρα, όπως η βελανιδιά, η οξιά, η ιτιά κ.ά.</p>\\n","answer":"<p style=\\"text-align:center\\">Παραμεσογειακή ζώνη</p>\\n","tips":{},"image":{"path":"resources/image-WJWGRmi4.jpg","mime":"image/jpeg","copyright":{"license":"U"},"width":553,"height":468},"imageAltText":"Παραμεσογειακή ζώνη"},{"text":"<p style=\\"text-align:center\\">Τη συναντάμε σε υψόμετρο μεγαλύτερο από τα 800μ., κυρίως σε βουνά της βόρειας Ελλάδας, και περιλαμβάνει δάση με κωνοφόρα δέντρα, όπως η ελάτη, το πεύκο, ο κέδρος κ.ά.</p>\\n","answer":"<p style=\\"text-align:center\\">Ζώνη ψυχρόβιων κωνοφόρων</p>\\n","tips":{},"image":{"path":"resources/image-c0NDLAVZ.jpg","mime":"image/jpeg","copyright":{"license":"U"},"width":565,"height":330},"imageAltText":"Παραμεσογειακή ζώνη"},{"text":"<p>Τη συναντάμε σε υψόμετρο 1700 - 1800 μ., κυρίως σε ορεινές περιοχές της Πελοποννήσου και της Στερεάς Ελλάδας, και περιλαμβάνει δάση με δέντρα, όπως η οξιά, η καστανιά, η ελάτη, κ.ά.</p>\\n","answer":"<p style=\\"text-align:center\\">Ορεινή - Υπαλπική ζώνη</p>\\n","tips":{},"image":{"path":"resources/image-BBCU8b0R.jpg","mime":"image/jpeg","copyright":{"license":"U"},"width":672,"height":431},"imageAltText":"Ορεινή - υπαλπική ζώνη"},{"text":"<p style=\\"text-align:center\\">Τη συναντάμε σε υψόμετρο 1700 - 2900 μ. στα μεγάλα βουνά της Ελλάδας και περιλαμβάνει χαμηλά φυτά, θάμνους και αγριολούλουδα.</p>\\n","answer":"<p style=\\"text-align:center\\">Αλπική ζώνη</p>\\n","tips":{},"image":{"path":"resources/image-ZjtTljJV.jpg","mime":"image/jpeg","copyright":{"license":"U"},"width":461,"height":395},"imageAltText":"Αλπική ζώνη"}],"behaviour":{"enableRetry":true,"disableBackwardsNavigation":false,"scaleTextNotCard":false,"randomCards":false,"maxProficiency":5,"quickProgression":false},"answer":"Γύρισε","next":"Επόμενη","prev":"Προηγούμενη","retry":"Επανάληψη","correctAnswer":"Σωστά!","incorrectAnswer":"Λάθος","round":"Γύρος @round","cardsLeft":"Κάρτες που απομένουν: @number","nextRound":"Μετάβαση στο γύρο @round","startOver":"Επανάληψη","showSummary":"Επισκόπηση","summary":"Επισκόπηση","summaryCardsRight":"Κάρτες σωστά:","summaryCardsWrong":"Κάρτες λάθος:","summaryCardsNotShown":"Κάρτες που δεν προβλήθηκαν:","summaryOverallScore":"Συνολικοί Βαθμοί","summaryCardsCompleted":"Κάρτες (ολοκληρώθηκε η μάθησή τους):","summaryCompletedRounds":"Γύροι που ολοκληρώθηκαν:","summaryAllDone":"Συγχαρητήρια! Είχες όλες τις κάρτες (@cards) σωστά @max φορές στη σειρά!","progressText":"Κάρτα @card από @total","cardFrontLabel":"Μπροστινό μέρος κάρτας","cardBackLabel":"Πίσω μέρος κάρτας","tipButtonLabel":"Εμφάνιση επεξήγησης","audioNotSupported":"Ο φυλλομετρητής δεν υποστηρίζει το συγκεκριμένο αρχείο ήχου","confirmStartingOver":{"header":"Επανέναρξη;","body":"Όλη η τρέχουσα πρόοδος θα χαθεί. Είστε σίγουρος/η πως θέλετε να ξεκινήσετε ξανά;","cancelLabel":"Ακύρωση","confirmLabel":"Επανέναρξη"},"title":"","description":""}',
      library: "H5P.Dialogcards 1.9",
      metadata: {
        license: "U",
        title: "Ζώνες βλάστησης της Ελλάδας",
        defaultLanguage: "el",
      },
      scripts: [
        "/h5p/libraries/H5P.Transition-1.0/transition.js?version=1.0.4",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-help-dialog.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-message-dialog.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-progress-circle.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-simple-rounded-button.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-speech-bubble.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-throbber.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-tip.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-slider.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-score-bar.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-progressbar.js?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/js/joubel-ui.js?version=1.3.19",
        "/h5p/libraries/H5P.Audio-1.5/scripts/audio.js?version=1.5.9",
        "/h5p/libraries/H5P.Dialogcards-1.9/dist/h5p-dialogcards.js?version=1.9.7",
      ],
      styles: [
        "/h5p/libraries/FontAwesome-4.5/h5p-font-awesome.min.css?version=4.5.4",
        "/h5p/libraries/H5P.FontIcons-1.0/styles/h5p-font-icons.css?version=1.0.6",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-help-dialog.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-message-dialog.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-progress-circle.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-simple-rounded-button.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-speech-bubble.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-tip.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-slider.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-score-bar.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-progressbar.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-ui.css?version=1.3.19",
        "/h5p/libraries/H5P.JoubelUI-1.3/css/joubel-icon.css?version=1.3.19",
        "/h5p/libraries/H5P.Audio-1.5/styles/audio.css?version=1.5.9",
        "/h5p/libraries/H5P.Dialogcards-1.9/dist/h5p-dialogcards.css?version=1.9.7",
      ],
      url: "3706082533",
      exportUrl: "/h5p/download/3706082533",
    },
  },
  core: {
    scripts: [
      "/h5p/core/js/jquery.js?version=1.24-master",
      "/h5p/core/js/h5p.js?version=1.24-master",
      "/h5p/core/js/h5p-event-dispatcher.js?version=1.24-master",
      "/h5p/core/js/h5p-x-api-event.js?version=1.24-master",
      "/h5p/core/js/h5p-x-api.js?version=1.24-master",
      "/h5p/core/js/h5p-content-type.js?version=1.24-master",
      "/h5p/core/js/h5p-confirmation-dialog.js?version=1.24-master",
      "/h5p/core/js/h5p-action-bar.js?version=1.24-master",
      "/h5p/core/js/request-queue.js?version=1.24-master",
    ],
    styles: [
      "/h5p/core/styles/h5p.css?version=1.24-master",
      "/h5p/core/styles/h5p-confirmation-dialog.css?version=1.24-master",
      "/h5p/core/styles/h5p-core-button.css?version=1.24-master",
    ],
  },
  l10n: {
    H5P: {
      fullscreen: "Fullscreen",
      disableFullscreen: "Disable fullscreen",
      download: "Download",
      copyrights: "Rights of use",
      embed: "Embed",
      size: "Size",
      showAdvanced: "Show advanced",
      hideAdvanced: "Hide advanced",
      advancedHelp:
        "Include this script on your website if you want dynamic sizing of the embedded content:",
      copyrightInformation: "Rights of use",
      close: "Close",
      title: "Title",
      author: "Author",
      year: "Year",
      source: "Source",
      license: "License",
      thumbnail: "Thumbnail",
      noCopyrights: "No copyright information available for this content.",
      reuse: "Reuse",
      reuseContent: "Reuse Content",
      reuseDescription: "Reuse this content.",
      downloadDescription: "Download this content as a H5P file.",
      copyrightsDescription: "View copyright information for this content.",
      embedDescription: "View the embed code for this content.",
      h5pDescription: "Visit H5P.org to check out more cool content.",
      contentChanged: "This content has changed since you last used it.",
      startingOver: "You'll be starting over.",
      by: "by",
      showMore: "Show more",
      showLess: "Show less",
      subLevel: "Sublevel",
      confirmDialogHeader: "Confirm action",
      confirmDialogBody:
        "Please confirm that you wish to proceed. This action is not reversible.",
      cancelLabel: "Cancel",
      confirmLabel: "Confirm",
      licenseU: "Undisclosed",
      licenseCCBY: "Attribution",
      licenseCCBYSA: "Attribution-ShareAlike",
      licenseCCBYND: "Attribution-NoDerivs",
      licenseCCBYNC: "Attribution-NonCommercial",
      licenseCCBYNCSA: "Attribution-NonCommercial-ShareAlike",
      licenseCCBYNCND: "Attribution-NonCommercial-NoDerivs",
      licenseCC40: "4.0 International",
      licenseCC30: "3.0 Unported",
      licenseCC25: "2.5 Generic",
      licenseCC20: "2.0 Generic",
      licenseCC10: "1.0 Generic",
      licenseGPL: "General Public License",
      licenseV3: "Version 3",
      licenseV2: "Version 2",
      licenseV1: "Version 1",
      licensePD: "Public Domain",
      licenseCC010: "CC0 1.0 Universal (CC0 1.0) Public Domain Dedication",
      licensePDM: "Public Domain Mark",
      licenseC: "Copyright",
      contentType: "Content Type",
      licenseExtras: "License Extras",
      changes: "Changelog",
      contentCopied: "Content is copied to the clipboard",
      connectionLost:
        "Connection lost. Results will be stored and sent when you regain connection.",
      connectionReestablished: "Connection reestablished.",
      resubmitScores: "Attempting to submit stored results.",
      offlineDialogHeader: "Your connection to the server was lost",
      offlineDialogBody:
        "We were unable to send information about your completion of this task. Please check your internet connection.",
      offlineDialogRetryMessage: "Retrying in :num....",
      offlineDialogRetryButtonLabel: "Retry now",
      offlineSuccessfulSubmit: "Successfully submitted results.",
      mainTitle: "Sharing <strong>:title</strong>",
      editInfoTitle: "Edit info for <strong>:title</strong>",
      cancel: "Cancel",
      back: "Back",
      next: "Next",
      reviewInfo: "Review info",
      share: "Share",
      saveChanges: "Save changes",
      registerOnHub: "Register on the H5P Hub",
      updateRegistrationOnHub: "Save account settings",
      requiredInfo: "Required Info",
      optionalInfo: "Optional Info",
      reviewAndShare: "Review & Share",
      reviewAndSave: "Review & Save",
      shared: "Shared",
      currentStep: "Step :step of :total",
      sharingNote: "All content details can be edited after sharing",
      licenseDescription: "Select a license for your content",
      licenseVersion: "License Version",
      licenseVersionDescription: "Select a license version",
      disciplineLabel: "Disciplines",
      disciplineDescription: "You can select multiple disciplines",
      disciplineLimitReachedMessage:
        "You can select up to :numDisciplines disciplines",
      discipline: {
        searchPlaceholder: "Type to search for disciplines",
        in: "in",
        dropdownButton: "Dropdown button",
      },
      removeChip: "Remove :chip from the list",
      keywordsPlaceholder: "Add keywords",
      keywords: "Keywords",
      keywordsDescription:
        'You can add multiple keywords separated by commas. Press "Enter" or "Add" to confirm keywords',
      altText: "Alt text",
      reviewMessage: "Please review the info below before you share",
      subContentWarning:
        "Sub-content (images, questions etc.) will be shared under :license unless otherwise specified in the authoring tool",
      disciplines: "Disciplines",
      shortDescription: "Short description",
      longDescription: "Long description",
      icon: "Icon",
      screenshots: "Screenshots",
      helpChoosingLicense: "Help me choose a license",
      shareFailed: "Share failed.",
      editingFailed: "Editing failed.",
      shareTryAgain: "Something went wrong, please try to share again.",
      pleaseWait: "Please wait...",
      language: "Language",
      level: "Level",
      shortDescriptionPlaceholder: "Short description of your content",
      longDescriptionPlaceholder: "Long description of your content",
      description: "Description",
      iconDescription:
        "640x480px. If not selected content will use category icon",
      screenshotsDescription: "Add up to five screenshots of your content",
      submitted: "Submitted!",
      isNowSubmitted: "Is now submitted to H5P Hub",
      changeHasBeenSubmitted: "A change has been submited for",
      contentAvailable:
        "Your content will normally be available in the Hub within one business day.",
      contentUpdateSoon: "Your content will update soon",
      contentLicenseTitle: "Content License Info",
      licenseDialogDescription:
        "Click on a specific license to get info about proper usage",
      publisherFieldTitle: "Publisher",
      publisherFieldDescription:
        'This will display as the "Publisher name" on shared content',
      emailAddress: "Email Address",
      publisherDescription: "Publisher description",
      publisherDescriptionText:
        'This will be displayed under "Publisher info" on shared content',
      contactPerson: "Contact Person",
      phone: "Phone",
      address: "Address",
      city: "City",
      zip: "Zip",
      country: "Country",
      logoUploadText: "Organization logo or avatar",
      acceptTerms:
        "I accept the <a href=':url' target='_blank'>terms of use</a>",
      successfullyRegistred:
        "You have successfully registered an account on the H5P Hub",
      successfullyRegistredDescription: "You account details can be changed",
      successfullyUpdated:
        "Your H5P Hub account settings have successfully been changed",
      accountDetailsLinkText: "here",
      registrationTitle: "H5P Hub Registration",
      registrationFailed: "An error occurred",
      registrationFailedDescription:
        "We were not able to create an account at this point. Something went wrong. Try again later.",
      maxLength: ":length is the maximum number of characters",
      keywordExists: "Keyword already exists!",
      licenseDetails: "License details",
      remove: "Remove",
      removeImage: "Remove image",
      cancelPublishConfirmationDialogTitle: "Cancel sharing",
      cancelPublishConfirmationDialogDescription:
        "Are you sure you want to cancel the sharing process?",
      cancelPublishConfirmationDialogCancelButtonText: "No",
      cancelPublishConfirmationDialogConfirmButtonText: "Yes",
      add: "Add",
      age: "Typical age",
      ageDescription:
        'The target audience of this content. Possible input formats separated by commas: "1,34-45,-50,59-".',
      invalidAge:
        'Invalid input format for Typical age. Possible input formats separated by commas: "1, 34-45, -50, -59-".',
      contactPersonDescription:
        'H5P will reach out to the contact person in case there are any issues with the content shared by the publisher. The contact person"s name or other information will not be published or shared with third parties',
      emailAddressDescription:
        "The email address will be used by H5P to reach out to the publisher in case of any issues with the content or in case the publisher needs to recover their account. It will not be published or shared with any third parties",
      copyrightWarning:
        "Copyrighted material cannot be shared in the H5P Content Hub. If the content is licensed with a OER friendly license like Creative Commons, please choose the appropriate license. If not this content cannot be shared.",
      keywordsExits: "Keywords already exists!",
      someKeywordsExits: "Some of these keywords already exist",
    },
  },
  postUserStatistics: false,
  saveFreq: false,
  url: ".",
  hubIsEnabled: true,
  fullscreenDisabled: 0,
  user: { name: "Firstname Surname", id: "1" },
  baseUrl: ".",
  libraryUrl: "",
};

if (new URLSearchParams(window.location.search).get("embed") == "true") {
  H5PIntegration.contents["cid-" + "3706082533"].displayOptions.embed = false;
} else {
  H5PIntegration.contents["cid-" + "3706082533"].embedCode =
    '<iframe src="' +
    window.location.protocol +
    "//" +
    window.location.host +
    window.location.pathname +
    "?embed=true" +
    '" width=":w" height=":h" frameborder="0" allowfullscreen="allowfullscreen"></iframe>';
  H5PIntegration.contents["cid-" + "3706082533"].resizeCode = "";
}

/*!@license js/jquery.js by Joubel and other contributors, licensed under GNU GENERAL PUBLIC LICENSE Version 3*/
!(function (e, t) {
  "use strict";
  "object" == typeof module && "object" == typeof module.exports
    ? (module.exports = e.document
        ? t(e, !0)
        : function (e) {
            if (!e.document)
              throw new Error("jQuery requires a window with a document");
            return t(e);
          })
    : t(e);
})("undefined" != typeof window ? window : this, function (w, e) {
  "use strict";
  function g(e) {
    return "function" == typeof e && "number" != typeof e.nodeType;
  }
  function m(e) {
    return null != e && e === e.window;
  }
  var t = [],
    n = Object.getPrototypeOf,
    s = t.slice,
    v = t.flat
      ? function (e) {
          return t.flat.call(e);
        }
      : function (e) {
          return t.concat.apply([], e);
        },
    c = t.push,
    i = t.indexOf,
    r = {},
    o = r.toString,
    y = r.hasOwnProperty,
    a = y.toString,
    d = a.call(Object),
    b = {},
    H = w.document,
    l = { type: !0, src: !0, nonce: !0, noModule: !0 };
  function P(e, t, n) {
    var r,
      i,
      o = (n = n || H).createElement("script");
    if (((o.text = e), t))
      for (r in l)
        (i = t[r] || (t.getAttribute && t.getAttribute(r))) &&
          o.setAttribute(r, i);
    n.head.appendChild(o).parentNode.removeChild(o);
  }
  function f(e) {
    return null == e
      ? e + ""
      : "object" == typeof e || "function" == typeof e
        ? r[o.call(e)] || "object"
        : typeof e;
  }
  var u = "3.5.1",
    C = function (e, t) {
      return new C.fn.init(e, t);
    };
  function h(e) {
    var t = !!e && "length" in e && e.length,
      n = f(e);
    return (
      !g(e) &&
      !m(e) &&
      ("array" === n ||
        0 === t ||
        ("number" == typeof t && 0 < t && t - 1 in e))
    );
  }
  ((C.fn = C.prototype =
    {
      jquery: u,
      constructor: C,
      length: 0,
      toArray: function () {
        return s.call(this);
      },
      get: function (e) {
        return null == e
          ? s.call(this)
          : e < 0
            ? this[e + this.length]
            : this[e];
      },
      pushStack: function (e) {
        e = C.merge(this.constructor(), e);
        return ((e.prevObject = this), e);
      },
      each: function (e) {
        return C.each(this, e);
      },
      map: function (n) {
        return this.pushStack(
          C.map(this, function (e, t) {
            return n.call(e, t, e);
          }),
        );
      },
      slice: function () {
        return this.pushStack(s.apply(this, arguments));
      },
      first: function () {
        return this.eq(0);
      },
      last: function () {
        return this.eq(-1);
      },
      even: function () {
        return this.pushStack(
          C.grep(this, function (e, t) {
            return (t + 1) % 2;
          }),
        );
      },
      odd: function () {
        return this.pushStack(
          C.grep(this, function (e, t) {
            return t % 2;
          }),
        );
      },
      eq: function (e) {
        var t = this.length,
          e = +e + (e < 0 ? t : 0);
        return this.pushStack(0 <= e && e < t ? [this[e]] : []);
      },
      end: function () {
        return this.prevObject || this.constructor();
      },
      push: c,
      sort: t.sort,
      splice: t.splice,
    }),
    (C.extend = C.fn.extend =
      function () {
        var e,
          t,
          n,
          r,
          i,
          o = arguments[0] || {},
          a = 1,
          s = arguments.length,
          c = !1;
        for (
          "boolean" == typeof o && ((c = o), (o = arguments[a] || {}), a++),
            "object" == typeof o || g(o) || (o = {}),
            a === s && ((o = this), a--);
          a < s;
          a++
        )
          if (null != (e = arguments[a]))
            for (t in e)
              ((n = e[t]),
                "__proto__" !== t &&
                  o !== n &&
                  (c && n && (C.isPlainObject(n) || (r = Array.isArray(n)))
                    ? ((i = o[t]),
                      (i =
                        r && !Array.isArray(i)
                          ? []
                          : r || C.isPlainObject(i)
                            ? i
                            : {}),
                      (r = !1),
                      (o[t] = C.extend(c, i, n)))
                    : void 0 !== n && (o[t] = n)));
        return o;
      }),
    C.extend({
      expando: "jQuery" + (u + Math.random()).replace(/\D/g, ""),
      isReady: !0,
      error: function (e) {
        throw new Error(e);
      },
      noop: function () {},
      isPlainObject: function (e) {
        return !(
          !e ||
          "[object Object]" !== o.call(e) ||
          ((e = n(e)) &&
            ("function" !=
              typeof (e = y.call(e, "constructor") && e.constructor) ||
              a.call(e) !== d))
        );
      },
      isEmptyObject: function (e) {
        for (var t in e) return !1;
        return !0;
      },
      globalEval: function (e, t, n) {
        P(e, { nonce: t && t.nonce }, n);
      },
      each: function (e, t) {
        var n,
          r = 0;
        if (h(e))
          for (n = e.length; r < n && !1 !== t.call(e[r], r, e[r]); r++);
        else for (r in e) if (!1 === t.call(e[r], r, e[r])) break;
        return e;
      },
      makeArray: function (e, t) {
        t = t || [];
        return (
          null != e &&
            (h(Object(e))
              ? C.merge(t, "string" == typeof e ? [e] : e)
              : c.call(t, e)),
          t
        );
      },
      inArray: function (e, t, n) {
        return null == t ? -1 : i.call(t, e, n);
      },
      merge: function (e, t) {
        for (var n = +t.length, r = 0, i = e.length; r < n; r++) e[i++] = t[r];
        return ((e.length = i), e);
      },
      grep: function (e, t, n) {
        for (var r = [], i = 0, o = e.length, a = !n; i < o; i++)
          !t(e[i], i) != a && r.push(e[i]);
        return r;
      },
      map: function (e, t, n) {
        var r,
          i,
          o = 0,
          a = [];
        if (h(e))
          for (r = e.length; o < r; o++)
            null != (i = t(e[o], o, n)) && a.push(i);
        else for (o in e) null != (i = t(e[o], o, n)) && a.push(i);
        return v(a);
      },
      guid: 1,
      support: b,
    }),
    "function" == typeof Symbol && (C.fn[Symbol.iterator] = t[Symbol.iterator]),
    C.each(
      "Boolean Number String Function Array Date RegExp Object Error Symbol".split(
        " ",
      ),
      function (e, t) {
        r["[object " + t + "]"] = t.toLowerCase();
      },
    ));
  var p = (function (n) {
    function u(e, t) {
      return (
        (e = "0x" + e.slice(1) - 65536),
        t ||
          (e < 0
            ? String.fromCharCode(65536 + e)
            : String.fromCharCode((e >> 10) | 55296, (1023 & e) | 56320))
      );
    }
    function h(e, t) {
      return t
        ? "\0" === e
          ? "�"
          : e.slice(0, -1) +
            "\\" +
            e.charCodeAt(e.length - 1).toString(16) +
            " "
        : "\\" + e;
    }
    function r() {
      w();
    }
    var e,
      p,
      P,
      o,
      i,
      f,
      g,
      m,
      x,
      c,
      d,
      w,
      H,
      a,
      C,
      v,
      s,
      l,
      y,
      T = "sizzle" + +new Date(),
      b = n.document,
      S = 0,
      E = 0,
      I = ce(),
      A = ce(),
      k = ce(),
      D = ce(),
      L = function (e, t) {
        return (e === t && (d = !0), 0);
      },
      j = {}.hasOwnProperty,
      t = [],
      N = t.pop,
      $ = t.push,
      M = t.push,
      O = t.slice,
      B = function (e, t) {
        for (var n = 0, r = e.length; n < r; n++) if (e[n] === t) return n;
        return -1;
      },
      R =
        "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",
      q = "[\\x20\\t\\r\\n\\f]",
      F =
        "(?:\\\\[\\da-fA-F]{1,6}" +
        q +
        "?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",
      z =
        "\\[" +
        q +
        "*(" +
        F +
        ")(?:" +
        q +
        "*([*^$|!~]?=)" +
        q +
        "*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" +
        F +
        "))|)" +
        q +
        "*\\]",
      Q =
        ":(" +
        F +
        ")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|" +
        z +
        ")*)|.*)\\)|)",
      U = new RegExp(q + "+", "g"),
      W = new RegExp("^" + q + "+|((?:^|[^\\\\])(?:\\\\.)*)" + q + "+$", "g"),
      V = new RegExp("^" + q + "*," + q + "*"),
      X = new RegExp("^" + q + "*([>+~]|" + q + ")" + q + "*"),
      _ = new RegExp(q + "|>"),
      J = new RegExp(Q),
      Y = new RegExp("^" + F + "$"),
      G = {
        ID: new RegExp("^#(" + F + ")"),
        CLASS: new RegExp("^\\.(" + F + ")"),
        TAG: new RegExp("^(" + F + "|[*])"),
        ATTR: new RegExp("^" + z),
        PSEUDO: new RegExp("^" + Q),
        CHILD: new RegExp(
          "^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" +
            q +
            "*(even|odd|(([+-]|)(\\d*)n|)" +
            q +
            "*(?:([+-]|)" +
            q +
            "*(\\d+)|))" +
            q +
            "*\\)|)",
          "i",
        ),
        bool: new RegExp("^(?:" + R + ")$", "i"),
        needsContext: new RegExp(
          "^" +
            q +
            "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" +
            q +
            "*((?:-\\d)?\\d*)" +
            q +
            "*\\)|)(?=[^-]|$)",
          "i",
        ),
      },
      K = /HTML$/i,
      Z = /^(?:input|select|textarea|button)$/i,
      ee = /^h\d$/i,
      te = /^[^{]+\{\s*\[native \w/,
      ne = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,
      re = /[+~]/,
      ie = new RegExp("\\\\[\\da-fA-F]{1,6}" + q + "?|\\\\([^\\r\\n\\f])", "g"),
      oe = /([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,
      ae = ye(
        function (e) {
          return !0 === e.disabled && "fieldset" === e.nodeName.toLowerCase();
        },
        { dir: "parentNode", next: "legend" },
      );
    try {
      (M.apply((t = O.call(b.childNodes)), b.childNodes),
        t[b.childNodes.length].nodeType);
    } catch (e) {
      M = {
        apply: t.length
          ? function (e, t) {
              $.apply(e, O.call(t));
            }
          : function (e, t) {
              for (var n = e.length, r = 0; (e[n++] = t[r++]); );
              e.length = n - 1;
            },
      };
    }
    function se(e, t, n, r) {
      var i,
        o,
        a,
        s,
        c,
        d,
        l = t && t.ownerDocument,
        u = t ? t.nodeType : 9;
      if (
        ((n = n || []),
        "string" != typeof e || !e || (1 !== u && 9 !== u && 11 !== u))
      )
        return n;
      if (!r && (w(t), (t = t || H), C)) {
        if (11 !== u && (s = ne.exec(e)))
          if ((d = s[1])) {
            if (9 === u) {
              if (!(o = t.getElementById(d))) return n;
              if (o.id === d) return (n.push(o), n);
            } else if (l && (o = l.getElementById(d)) && y(t, o) && o.id === d)
              return (n.push(o), n);
          } else {
            if (s[2]) return (M.apply(n, t.getElementsByTagName(e)), n);
            if (
              (d = s[3]) &&
              p.getElementsByClassName &&
              t.getElementsByClassName
            )
              return (M.apply(n, t.getElementsByClassName(d)), n);
          }
        if (
          p.qsa &&
          !D[e + " "] &&
          (!v || !v.test(e)) &&
          (1 !== u || "object" !== t.nodeName.toLowerCase())
        ) {
          if (((d = e), (l = t), 1 === u && (_.test(e) || X.test(e)))) {
            for (
              ((l = (re.test(e) && ge(t.parentNode)) || t) === t && p.scope) ||
                ((a = t.getAttribute("id"))
                  ? (a = a.replace(oe, h))
                  : t.setAttribute("id", (a = T))),
                i = (c = f(e)).length;
              i--;
            )
              c[i] = (a ? "#" + a : ":scope") + " " + ve(c[i]);
            d = c.join(",");
          }
          try {
            return (M.apply(n, l.querySelectorAll(d)), n);
          } catch (t) {
            D(e, !0);
          } finally {
            a === T && t.removeAttribute("id");
          }
        }
      }
      return m(e.replace(W, "$1"), t, n, r);
    }
    function ce() {
      var r = [];
      return function e(t, n) {
        return (
          r.push(t + " ") > P.cacheLength && delete e[r.shift()],
          (e[t + " "] = n)
        );
      };
    }
    function de(e) {
      return ((e[T] = !0), e);
    }
    function le(e) {
      var t = H.createElement("fieldset");
      try {
        return !!e(t);
      } catch (e) {
        return !1;
      } finally {
        t.parentNode && t.parentNode.removeChild(t);
      }
    }
    function ue(e, t) {
      for (var n = e.split("|"), r = n.length; r--; ) P.attrHandle[n[r]] = t;
    }
    function he(e, t) {
      var n = t && e,
        r =
          n &&
          1 === e.nodeType &&
          1 === t.nodeType &&
          e.sourceIndex - t.sourceIndex;
      if (r) return r;
      if (n) for (; (n = n.nextSibling); ) if (n === t) return -1;
      return e ? 1 : -1;
    }
    function pe(t) {
      return function (e) {
        return "form" in e
          ? e.parentNode && !1 === e.disabled
            ? "label" in e
              ? "label" in e.parentNode
                ? e.parentNode.disabled === t
                : e.disabled === t
              : e.isDisabled === t || (e.isDisabled !== !t && ae(e) === t)
            : e.disabled === t
          : "label" in e && e.disabled === t;
      };
    }
    function fe(a) {
      return de(function (o) {
        return (
          (o = +o),
          de(function (e, t) {
            for (var n, r = a([], e.length, o), i = r.length; i--; )
              e[(n = r[i])] && (e[n] = !(t[n] = e[n]));
          })
        );
      });
    }
    function ge(e) {
      return e && void 0 !== e.getElementsByTagName && e;
    }
    for (e in ((p = se.support = {}),
    (i = se.isXML =
      function (e) {
        var t = e.namespaceURI,
          e = (e.ownerDocument || e).documentElement;
        return !K.test(t || (e && e.nodeName) || "HTML");
      }),
    (w = se.setDocument =
      function (e) {
        var t,
          e = e ? e.ownerDocument || e : b;
        return (
          e != H &&
            9 === e.nodeType &&
            e.documentElement &&
            ((a = (H = e).documentElement),
            (C = !i(H)),
            b != H &&
              (t = H.defaultView) &&
              t.top !== t &&
              (t.addEventListener
                ? t.addEventListener("unload", r, !1)
                : t.attachEvent && t.attachEvent("onunload", r)),
            (p.scope = le(function (e) {
              return (
                a.appendChild(e).appendChild(H.createElement("div")),
                void 0 !== e.querySelectorAll &&
                  !e.querySelectorAll(":scope fieldset div").length
              );
            })),
            (p.attributes = le(function (e) {
              return ((e.className = "i"), !e.getAttribute("className"));
            })),
            (p.getElementsByTagName = le(function (e) {
              return (
                e.appendChild(H.createComment("")),
                !e.getElementsByTagName("*").length
              );
            })),
            (p.getElementsByClassName = te.test(H.getElementsByClassName)),
            (p.getById = le(function (e) {
              return (
                (a.appendChild(e).id = T),
                !H.getElementsByName || !H.getElementsByName(T).length
              );
            })),
            p.getById
              ? ((P.filter.ID = function (e) {
                  var t = e.replace(ie, u);
                  return function (e) {
                    return e.getAttribute("id") === t;
                  };
                }),
                (P.find.ID = function (e, t) {
                  if (void 0 !== t.getElementById && C) {
                    e = t.getElementById(e);
                    return e ? [e] : [];
                  }
                }))
              : ((P.filter.ID = function (e) {
                  var t = e.replace(ie, u);
                  return function (e) {
                    e =
                      void 0 !== e.getAttributeNode && e.getAttributeNode("id");
                    return e && e.value === t;
                  };
                }),
                (P.find.ID = function (e, t) {
                  if (void 0 !== t.getElementById && C) {
                    var n,
                      r,
                      i,
                      o = t.getElementById(e);
                    if (o) {
                      if ((n = o.getAttributeNode("id")) && n.value === e)
                        return [o];
                      for (i = t.getElementsByName(e), r = 0; (o = i[r++]); )
                        if ((n = o.getAttributeNode("id")) && n.value === e)
                          return [o];
                    }
                    return [];
                  }
                })),
            (P.find.TAG = p.getElementsByTagName
              ? function (e, t) {
                  return void 0 !== t.getElementsByTagName
                    ? t.getElementsByTagName(e)
                    : p.qsa
                      ? t.querySelectorAll(e)
                      : void 0;
                }
              : function (e, t) {
                  var n,
                    r = [],
                    i = 0,
                    o = t.getElementsByTagName(e);
                  if ("*" !== e) return o;
                  for (; (n = o[i++]); ) 1 === n.nodeType && r.push(n);
                  return r;
                }),
            (P.find.CLASS =
              p.getElementsByClassName &&
              function (e, t) {
                if (void 0 !== t.getElementsByClassName && C)
                  return t.getElementsByClassName(e);
              }),
            (s = []),
            (v = []),
            (p.qsa = te.test(H.querySelectorAll)) &&
              (le(function (e) {
                var t;
                ((a.appendChild(e).innerHTML =
                  "<a id='" +
                  T +
                  "'></a><select id='" +
                  T +
                  "-\r\\' msallowcapture=''><option selected=''></option></select>"),
                  e.querySelectorAll("[msallowcapture^='']").length &&
                    v.push("[*^$]=" + q + "*(?:''|\"\")"),
                  e.querySelectorAll("[selected]").length ||
                    v.push("\\[" + q + "*(?:value|" + R + ")"),
                  e.querySelectorAll("[id~=" + T + "-]").length || v.push("~="),
                  (t = H.createElement("input")).setAttribute("name", ""),
                  e.appendChild(t),
                  e.querySelectorAll("[name='']").length ||
                    v.push("\\[" + q + "*name" + q + "*=" + q + "*(?:''|\"\")"),
                  e.querySelectorAll(":checked").length || v.push(":checked"),
                  e.querySelectorAll("a#" + T + "+*").length ||
                    v.push(".#.+[+~]"),
                  e.querySelectorAll("\\\f"),
                  v.push("[\\r\\n\\f]"));
              }),
              le(function (e) {
                e.innerHTML =
                  "<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";
                var t = H.createElement("input");
                (t.setAttribute("type", "hidden"),
                  e.appendChild(t).setAttribute("name", "D"),
                  e.querySelectorAll("[name=d]").length &&
                    v.push("name" + q + "*[*^$|!~]?="),
                  2 !== e.querySelectorAll(":enabled").length &&
                    v.push(":enabled", ":disabled"),
                  (a.appendChild(e).disabled = !0),
                  2 !== e.querySelectorAll(":disabled").length &&
                    v.push(":enabled", ":disabled"),
                  e.querySelectorAll("*,:x"),
                  v.push(",.*:"));
              })),
            (p.matchesSelector = te.test(
              (l =
                a.matches ||
                a.webkitMatchesSelector ||
                a.mozMatchesSelector ||
                a.oMatchesSelector ||
                a.msMatchesSelector),
            )) &&
              le(function (e) {
                ((p.disconnectedMatch = l.call(e, "*")),
                  l.call(e, "[s!='']:x"),
                  s.push("!=", Q));
              }),
            (v = v.length && new RegExp(v.join("|"))),
            (s = s.length && new RegExp(s.join("|"))),
            (t = te.test(a.compareDocumentPosition)),
            (y =
              t || te.test(a.contains)
                ? function (e, t) {
                    var n = 9 === e.nodeType ? e.documentElement : e,
                      t = t && t.parentNode;
                    return (
                      e === t ||
                      !(
                        !t ||
                        1 !== t.nodeType ||
                        !(n.contains
                          ? n.contains(t)
                          : e.compareDocumentPosition &&
                            16 & e.compareDocumentPosition(t))
                      )
                    );
                  }
                : function (e, t) {
                    if (t) for (; (t = t.parentNode); ) if (t === e) return !0;
                    return !1;
                  }),
            (L = t
              ? function (e, t) {
                  return e === t
                    ? ((d = !0), 0)
                    : (n =
                        !e.compareDocumentPosition -
                        !t.compareDocumentPosition) ||
                        (1 &
                          (n =
                            (e.ownerDocument || e) == (t.ownerDocument || t)
                              ? e.compareDocumentPosition(t)
                              : 1) ||
                        (!p.sortDetached && t.compareDocumentPosition(e) === n)
                          ? e == H || (e.ownerDocument == b && y(b, e))
                            ? -1
                            : t == H || (t.ownerDocument == b && y(b, t))
                              ? 1
                              : c
                                ? B(c, e) - B(c, t)
                                : 0
                          : 4 & n
                            ? -1
                            : 1);
                  var n;
                }
              : function (e, t) {
                  if (e === t) return ((d = !0), 0);
                  var n,
                    r = 0,
                    i = e.parentNode,
                    o = t.parentNode,
                    a = [e],
                    s = [t];
                  if (!i || !o)
                    return e == H
                      ? -1
                      : t == H
                        ? 1
                        : i
                          ? -1
                          : o
                            ? 1
                            : c
                              ? B(c, e) - B(c, t)
                              : 0;
                  if (i === o) return he(e, t);
                  for (n = e; (n = n.parentNode); ) a.unshift(n);
                  for (n = t; (n = n.parentNode); ) s.unshift(n);
                  for (; a[r] === s[r]; ) r++;
                  return r
                    ? he(a[r], s[r])
                    : a[r] == b
                      ? -1
                      : s[r] == b
                        ? 1
                        : 0;
                })),
          H
        );
      }),
    (se.matches = function (e, t) {
      return se(e, null, null, t);
    }),
    (se.matchesSelector = function (e, t) {
      if (
        (w(e),
        p.matchesSelector &&
          C &&
          !D[t + " "] &&
          (!s || !s.test(t)) &&
          (!v || !v.test(t)))
      )
        try {
          var n = l.call(e, t);
          if (
            n ||
            p.disconnectedMatch ||
            (e.document && 11 !== e.document.nodeType)
          )
            return n;
        } catch (e) {
          D(t, !0);
        }
      return 0 < se(t, H, null, [e]).length;
    }),
    (se.contains = function (e, t) {
      return ((e.ownerDocument || e) != H && w(e), y(e, t));
    }),
    (se.attr = function (e, t) {
      (e.ownerDocument || e) != H && w(e);
      var n = P.attrHandle[t.toLowerCase()],
        n = n && j.call(P.attrHandle, t.toLowerCase()) ? n(e, t, !C) : void 0;
      return void 0 !== n
        ? n
        : p.attributes || !C
          ? e.getAttribute(t)
          : (n = e.getAttributeNode(t)) && n.specified
            ? n.value
            : null;
    }),
    (se.escape = function (e) {
      return (e + "").replace(oe, h);
    }),
    (se.error = function (e) {
      throw new Error("Syntax error, unrecognized expression: " + e);
    }),
    (se.uniqueSort = function (e) {
      var t,
        n = [],
        r = 0,
        i = 0;
      if (
        ((d = !p.detectDuplicates),
        (c = !p.sortStable && e.slice(0)),
        e.sort(L),
        d)
      ) {
        for (; (t = e[i++]); ) t === e[i] && (r = n.push(i));
        for (; r--; ) e.splice(n[r], 1);
      }
      return ((c = null), e);
    }),
    (o = se.getText =
      function (e) {
        var t,
          n = "",
          r = 0,
          i = e.nodeType;
        if (i) {
          if (1 === i || 9 === i || 11 === i) {
            if ("string" == typeof e.textContent) return e.textContent;
            for (e = e.firstChild; e; e = e.nextSibling) n += o(e);
          } else if (3 === i || 4 === i) return e.nodeValue;
        } else for (; (t = e[r++]); ) n += o(t);
        return n;
      }),
    ((P = se.selectors =
      {
        cacheLength: 50,
        createPseudo: de,
        match: G,
        attrHandle: {},
        find: {},
        relative: {
          ">": { dir: "parentNode", first: !0 },
          " ": { dir: "parentNode" },
          "+": { dir: "previousSibling", first: !0 },
          "~": { dir: "previousSibling" },
        },
        preFilter: {
          ATTR: function (e) {
            return (
              (e[1] = e[1].replace(ie, u)),
              (e[3] = (e[3] || e[4] || e[5] || "").replace(ie, u)),
              "~=" === e[2] && (e[3] = " " + e[3] + " "),
              e.slice(0, 4)
            );
          },
          CHILD: function (e) {
            return (
              (e[1] = e[1].toLowerCase()),
              "nth" === e[1].slice(0, 3)
                ? (e[3] || se.error(e[0]),
                  (e[4] = +(e[4]
                    ? e[5] + (e[6] || 1)
                    : 2 * ("even" === e[3] || "odd" === e[3]))),
                  (e[5] = +(e[7] + e[8] || "odd" === e[3])))
                : e[3] && se.error(e[0]),
              e
            );
          },
          PSEUDO: function (e) {
            var t,
              n = !e[6] && e[2];
            return G.CHILD.test(e[0])
              ? null
              : (e[3]
                  ? (e[2] = e[4] || e[5] || "")
                  : n &&
                    J.test(n) &&
                    (t = f(n, !0)) &&
                    (t = n.indexOf(")", n.length - t) - n.length) &&
                    ((e[0] = e[0].slice(0, t)), (e[2] = n.slice(0, t))),
                e.slice(0, 3));
          },
        },
        filter: {
          TAG: function (e) {
            var t = e.replace(ie, u).toLowerCase();
            return "*" === e
              ? function () {
                  return !0;
                }
              : function (e) {
                  return e.nodeName && e.nodeName.toLowerCase() === t;
                };
          },
          CLASS: function (e) {
            var t = I[e + " "];
            return (
              t ||
              ((t = new RegExp("(^|" + q + ")" + e + "(" + q + "|$)")) &&
                I(e, function (e) {
                  return t.test(
                    ("string" == typeof e.className && e.className) ||
                      (void 0 !== e.getAttribute && e.getAttribute("class")) ||
                      "",
                  );
                }))
            );
          },
          ATTR: function (t, n, r) {
            return function (e) {
              e = se.attr(e, t);
              return null == e
                ? "!=" === n
                : !n ||
                    ((e += ""),
                    "=" === n
                      ? e === r
                      : "!=" === n
                        ? e !== r
                        : "^=" === n
                          ? r && 0 === e.indexOf(r)
                          : "*=" === n
                            ? r && -1 < e.indexOf(r)
                            : "$=" === n
                              ? r && e.slice(-r.length) === r
                              : "~=" === n
                                ? -1 <
                                  (" " + e.replace(U, " ") + " ").indexOf(r)
                                : "|=" === n &&
                                  (e === r ||
                                    e.slice(0, r.length + 1) === r + "-"));
            };
          },
          CHILD: function (f, e, t, g, m) {
            var v = "nth" !== f.slice(0, 3),
              y = "last" !== f.slice(-4),
              b = "of-type" === e;
            return 1 === g && 0 === m
              ? function (e) {
                  return !!e.parentNode;
                }
              : function (e, t, n) {
                  var r,
                    i,
                    o,
                    a,
                    s,
                    c,
                    d = v != y ? "nextSibling" : "previousSibling",
                    l = e.parentNode,
                    u = b && e.nodeName.toLowerCase(),
                    h = !n && !b,
                    p = !1;
                  if (l) {
                    if (v) {
                      for (; d; ) {
                        for (a = e; (a = a[d]); )
                          if (
                            b
                              ? a.nodeName.toLowerCase() === u
                              : 1 === a.nodeType
                          )
                            return !1;
                        c = d = "only" === f && !c && "nextSibling";
                      }
                      return !0;
                    }
                    if (((c = [y ? l.firstChild : l.lastChild]), y && h)) {
                      for (
                        p =
                          (s =
                            (r =
                              (i =
                                (o = (a = l)[T] || (a[T] = {}))[a.uniqueID] ||
                                (o[a.uniqueID] = {}))[f] || [])[0] === S &&
                            r[1]) && r[2],
                          a = s && l.childNodes[s];
                        (a = (++s && a && a[d]) || (p = s = 0) || c.pop());
                      )
                        if (1 === a.nodeType && ++p && a === e) {
                          i[f] = [S, s, p];
                          break;
                        }
                    } else if (
                      !1 ===
                      (p = h
                        ? (s =
                            (r =
                              (i =
                                (o = (a = e)[T] || (a[T] = {}))[a.uniqueID] ||
                                (o[a.uniqueID] = {}))[f] || [])[0] === S &&
                            r[1])
                        : p)
                    )
                      for (
                        ;
                        (a = (++s && a && a[d]) || (p = s = 0) || c.pop()) &&
                        ((b
                          ? a.nodeName.toLowerCase() !== u
                          : 1 !== a.nodeType) ||
                          !++p ||
                          (h &&
                            ((i =
                              (o = a[T] || (a[T] = {}))[a.uniqueID] ||
                              (o[a.uniqueID] = {}))[f] = [S, p]),
                          a !== e));
                      );
                    return (p -= m) === g || (p % g == 0 && 0 <= p / g);
                  }
                };
          },
          PSEUDO: function (e, o) {
            var t,
              a =
                P.pseudos[e] ||
                P.setFilters[e.toLowerCase()] ||
                se.error("unsupported pseudo: " + e);
            return a[T]
              ? a(o)
              : 1 < a.length
                ? ((t = [e, e, "", o]),
                  P.setFilters.hasOwnProperty(e.toLowerCase())
                    ? de(function (e, t) {
                        for (var n, r = a(e, o), i = r.length; i--; )
                          e[(n = B(e, r[i]))] = !(t[n] = r[i]);
                      })
                    : function (e) {
                        return a(e, 0, t);
                      })
                : a;
          },
        },
        pseudos: {
          not: de(function (e) {
            var r = [],
              i = [],
              s = g(e.replace(W, "$1"));
            return s[T]
              ? de(function (e, t, n, r) {
                  for (var i, o = s(e, null, r, []), a = e.length; a--; )
                    (i = o[a]) && (e[a] = !(t[a] = i));
                })
              : function (e, t, n) {
                  return (
                    (r[0] = e),
                    s(r, null, n, i),
                    (r[0] = null),
                    !i.pop()
                  );
                };
          }),
          has: de(function (t) {
            return function (e) {
              return 0 < se(t, e).length;
            };
          }),
          contains: de(function (t) {
            return (
              (t = t.replace(ie, u)),
              function (e) {
                return -1 < (e.textContent || o(e)).indexOf(t);
              }
            );
          }),
          lang: de(function (n) {
            return (
              Y.test(n || "") || se.error("unsupported lang: " + n),
              (n = n.replace(ie, u).toLowerCase()),
              function (e) {
                var t;
                do {
                  if (
                    (t = C
                      ? e.lang
                      : e.getAttribute("xml:lang") || e.getAttribute("lang"))
                  )
                    return (
                      (t = t.toLowerCase()) === n || 0 === t.indexOf(n + "-")
                    );
                } while ((e = e.parentNode) && 1 === e.nodeType);
                return !1;
              }
            );
          }),
          target: function (e) {
            var t = n.location && n.location.hash;
            return t && t.slice(1) === e.id;
          },
          root: function (e) {
            return e === a;
          },
          focus: function (e) {
            return (
              e === H.activeElement &&
              (!H.hasFocus || H.hasFocus()) &&
              !!(e.type || e.href || ~e.tabIndex)
            );
          },
          enabled: pe(!1),
          disabled: pe(!0),
          checked: function (e) {
            var t = e.nodeName.toLowerCase();
            return (
              ("input" === t && !!e.checked) || ("option" === t && !!e.selected)
            );
          },
          selected: function (e) {
            return (
              e.parentNode && e.parentNode.selectedIndex,
              !0 === e.selected
            );
          },
          empty: function (e) {
            for (e = e.firstChild; e; e = e.nextSibling)
              if (e.nodeType < 6) return !1;
            return !0;
          },
          parent: function (e) {
            return !P.pseudos.empty(e);
          },
          header: function (e) {
            return ee.test(e.nodeName);
          },
          input: function (e) {
            return Z.test(e.nodeName);
          },
          button: function (e) {
            var t = e.nodeName.toLowerCase();
            return ("input" === t && "button" === e.type) || "button" === t;
          },
          text: function (e) {
            return (
              "input" === e.nodeName.toLowerCase() &&
              "text" === e.type &&
              (null == (e = e.getAttribute("type")) ||
                "text" === e.toLowerCase())
            );
          },
          first: fe(function () {
            return [0];
          }),
          last: fe(function (e, t) {
            return [t - 1];
          }),
          eq: fe(function (e, t, n) {
            return [n < 0 ? n + t : n];
          }),
          even: fe(function (e, t) {
            for (var n = 0; n < t; n += 2) e.push(n);
            return e;
          }),
          odd: fe(function (e, t) {
            for (var n = 1; n < t; n += 2) e.push(n);
            return e;
          }),
          lt: fe(function (e, t, n) {
            for (var r = n < 0 ? n + t : t < n ? t : n; 0 <= --r; ) e.push(r);
            return e;
          }),
          gt: fe(function (e, t, n) {
            for (var r = n < 0 ? n + t : n; ++r < t; ) e.push(r);
            return e;
          }),
        },
      }).pseudos.nth = P.pseudos.eq),
    { radio: !0, checkbox: !0, file: !0, password: !0, image: !0 }))
      P.pseudos[e] = (function (t) {
        return function (e) {
          return "input" === e.nodeName.toLowerCase() && e.type === t;
        };
      })(e);
    for (e in { submit: !0, reset: !0 })
      P.pseudos[e] = (function (n) {
        return function (e) {
          var t = e.nodeName.toLowerCase();
          return ("input" === t || "button" === t) && e.type === n;
        };
      })(e);
    function me() {}
    function ve(e) {
      for (var t = 0, n = e.length, r = ""; t < n; t++) r += e[t].value;
      return r;
    }
    function ye(a, e, t) {
      var s = e.dir,
        c = e.next,
        d = c || s,
        l = t && "parentNode" === d,
        u = E++;
      return e.first
        ? function (e, t, n) {
            for (; (e = e[s]); ) if (1 === e.nodeType || l) return a(e, t, n);
            return !1;
          }
        : function (e, t, n) {
            var r,
              i,
              o = [S, u];
            if (n) {
              for (; (e = e[s]); )
                if ((1 === e.nodeType || l) && a(e, t, n)) return !0;
            } else
              for (; (e = e[s]); )
                if (1 === e.nodeType || l)
                  if (
                    ((r =
                      (i = e[T] || (e[T] = {}))[e.uniqueID] ||
                      (i[e.uniqueID] = {})),
                    c && c === e.nodeName.toLowerCase())
                  )
                    e = e[s] || e;
                  else {
                    if ((i = r[d]) && i[0] === S && i[1] === u)
                      return (o[2] = i[2]);
                    if (((r[d] = o)[2] = a(e, t, n))) return !0;
                  }
            return !1;
          };
    }
    function be(i) {
      return 1 < i.length
        ? function (e, t, n) {
            for (var r = i.length; r--; ) if (!i[r](e, t, n)) return !1;
            return !0;
          }
        : i[0];
    }
    function Pe(e, t, n, r, i) {
      for (var o, a = [], s = 0, c = e.length, d = null != t; s < c; s++)
        (o = e[s]) && ((n && !n(o, r, i)) || (a.push(o), d && t.push(s)));
      return a;
    }
    function xe(e) {
      for (
        var r,
          t,
          n,
          i = e.length,
          o = P.relative[e[0].type],
          a = o || P.relative[" "],
          s = o ? 1 : 0,
          c = ye(
            function (e) {
              return e === r;
            },
            a,
            !0,
          ),
          d = ye(
            function (e) {
              return -1 < B(r, e);
            },
            a,
            !0,
          ),
          l = [
            function (e, t, n) {
              n = (!o && (n || t !== x)) || ((r = t).nodeType ? c : d)(e, t, n);
              return ((r = null), n);
            },
          ];
        s < i;
        s++
      )
        if ((t = P.relative[e[s].type])) l = [ye(be(l), t)];
        else {
          if ((t = P.filter[e[s].type].apply(null, e[s].matches))[T]) {
            for (n = ++s; n < i && !P.relative[e[n].type]; n++);
            return (function e(p, f, g, m, v, t) {
              return (
                m && !m[T] && (m = e(m)),
                v && !v[T] && (v = e(v, t)),
                de(function (e, t, n, r) {
                  var i,
                    o,
                    a,
                    s = [],
                    c = [],
                    d = t.length,
                    l =
                      e ||
                      (function (e, t, n) {
                        for (var r = 0, i = t.length; r < i; r++)
                          se(e, t[r], n);
                        return n;
                      })(f || "*", n.nodeType ? [n] : n, []),
                    u = !p || (!e && f) ? l : Pe(l, s, p, n, r),
                    h = g ? (v || (e ? p : d || m) ? [] : t) : u;
                  if ((g && g(u, h, n, r), m))
                    for (i = Pe(h, c), m(i, [], n, r), o = i.length; o--; )
                      (a = i[o]) && (h[c[o]] = !(u[c[o]] = a));
                  if (e) {
                    if (v || p) {
                      if (v) {
                        for (i = [], o = h.length; o--; )
                          (a = h[o]) && i.push((u[o] = a));
                        v(null, (h = []), i, r);
                      }
                      for (o = h.length; o--; )
                        (a = h[o]) &&
                          -1 < (i = v ? B(e, a) : s[o]) &&
                          (e[i] = !(t[i] = a));
                    }
                  } else
                    ((h = Pe(h === t ? h.splice(d, h.length) : h)),
                      v ? v(null, t, h, r) : M.apply(t, h));
                })
              );
            })(
              1 < s && be(l),
              1 < s &&
                ve(
                  e
                    .slice(0, s - 1)
                    .concat({ value: " " === e[s - 2].type ? "*" : "" }),
                ).replace(W, "$1"),
              t,
              s < n && xe(e.slice(s, n)),
              n < i && xe((e = e.slice(n))),
              n < i && ve(e),
            );
          }
          l.push(t);
        }
      return be(l);
    }
    return (
      (me.prototype = P.filters = P.pseudos),
      (P.setFilters = new me()),
      (f = se.tokenize =
        function (e, t) {
          var n,
            r,
            i,
            o,
            a,
            s,
            c,
            d = A[e + " "];
          if (d) return t ? 0 : d.slice(0);
          for (a = e, s = [], c = P.preFilter; a; ) {
            for (o in ((n && !(r = V.exec(a))) ||
              (r && (a = a.slice(r[0].length) || a), s.push((i = []))),
            (n = !1),
            (r = X.exec(a)) &&
              ((n = r.shift()),
              i.push({ value: n, type: r[0].replace(W, " ") }),
              (a = a.slice(n.length))),
            P.filter))
              !(r = G[o].exec(a)) ||
                (c[o] && !(r = c[o](r))) ||
                ((n = r.shift()),
                i.push({ value: n, type: o, matches: r }),
                (a = a.slice(n.length)));
            if (!n) break;
          }
          return t ? a.length : a ? se.error(e) : A(e, s).slice(0);
        }),
      (g = se.compile =
        function (e, t) {
          var n,
            m,
            v,
            y,
            b,
            r,
            i = [],
            o = [],
            a = k[e + " "];
          if (!a) {
            for (n = (t = t || f(e)).length; n--; )
              ((a = xe(t[n]))[T] ? i : o).push(a);
            (a = k(
              e,
              ((y = 0 < (v = i).length),
              (b = 0 < (m = o).length),
              (r = function (e, t, n, r, i) {
                var o,
                  a,
                  s,
                  c = 0,
                  d = "0",
                  l = e && [],
                  u = [],
                  h = x,
                  p = e || (b && P.find.TAG("*", i)),
                  f = (S += null == h ? 1 : Math.random() || 0.1),
                  g = p.length;
                for (
                  i && (x = t == H || t || i);
                  d !== g && null != (o = p[d]);
                  d++
                ) {
                  if (b && o) {
                    for (
                      a = 0, t || o.ownerDocument == H || (w(o), (n = !C));
                      (s = m[a++]);
                    )
                      if (s(o, t || H, n)) {
                        r.push(o);
                        break;
                      }
                    i && (S = f);
                  }
                  y && ((o = !s && o) && c--, e && l.push(o));
                }
                if (((c += d), y && d !== c)) {
                  for (a = 0; (s = v[a++]); ) s(l, u, t, n);
                  if (e) {
                    if (0 < c) for (; d--; ) l[d] || u[d] || (u[d] = N.call(r));
                    u = Pe(u);
                  }
                  (M.apply(r, u),
                    i &&
                      !e &&
                      0 < u.length &&
                      1 < c + v.length &&
                      se.uniqueSort(r));
                }
                return (i && ((S = f), (x = h)), l);
              }),
              y ? de(r) : r),
            )).selector = e;
          }
          return a;
        }),
      (m = se.select =
        function (e, t, n, r) {
          var i,
            o,
            a,
            s,
            c,
            d = "function" == typeof e && e,
            l = !r && f((e = d.selector || e));
          if (((n = n || []), 1 === l.length)) {
            if (
              2 < (o = l[0] = l[0].slice(0)).length &&
              "ID" === (a = o[0]).type &&
              9 === t.nodeType &&
              C &&
              P.relative[o[1].type]
            ) {
              if (!(t = (P.find.ID(a.matches[0].replace(ie, u), t) || [])[0]))
                return n;
              (d && (t = t.parentNode), (e = e.slice(o.shift().value.length)));
            }
            for (
              i = G.needsContext.test(e) ? 0 : o.length;
              i-- && ((a = o[i]), !P.relative[(s = a.type)]);
            )
              if (
                (c = P.find[s]) &&
                (r = c(
                  a.matches[0].replace(ie, u),
                  (re.test(o[0].type) && ge(t.parentNode)) || t,
                ))
              ) {
                if ((o.splice(i, 1), !(e = r.length && ve(o))))
                  return (M.apply(n, r), n);
                break;
              }
          }
          return (
            (d || g(e, l))(
              r,
              t,
              !C,
              n,
              !t || (re.test(e) && ge(t.parentNode)) || t,
            ),
            n
          );
        }),
      (p.sortStable = T.split("").sort(L).join("") === T),
      (p.detectDuplicates = !!d),
      w(),
      (p.sortDetached = le(function (e) {
        return 1 & e.compareDocumentPosition(H.createElement("fieldset"));
      })),
      le(function (e) {
        return (
          (e.innerHTML = "<a href='#'></a>"),
          "#" === e.firstChild.getAttribute("href")
        );
      }) ||
        ue("type|href|height|width", function (e, t, n) {
          if (!n) return e.getAttribute(t, "type" === t.toLowerCase() ? 1 : 2);
        }),
      (p.attributes &&
        le(function (e) {
          return (
            (e.innerHTML = "<input/>"),
            e.firstChild.setAttribute("value", ""),
            "" === e.firstChild.getAttribute("value")
          );
        })) ||
        ue("value", function (e, t, n) {
          if (!n && "input" === e.nodeName.toLowerCase()) return e.defaultValue;
        }),
      le(function (e) {
        return null == e.getAttribute("disabled");
      }) ||
        ue(R, function (e, t, n) {
          if (!n)
            return !0 === e[t]
              ? t.toLowerCase()
              : (t = e.getAttributeNode(t)) && t.specified
                ? t.value
                : null;
        }),
      se
    );
  })(w);
  ((C.find = p),
    (C.expr = p.selectors),
    (C.expr[":"] = C.expr.pseudos),
    (C.uniqueSort = C.unique = p.uniqueSort),
    (C.text = p.getText),
    (C.isXMLDoc = p.isXML),
    (C.contains = p.contains),
    (C.escapeSelector = p.escape));
  function x(e, t, n) {
    for (var r = [], i = void 0 !== n; (e = e[t]) && 9 !== e.nodeType; )
      if (1 === e.nodeType) {
        if (i && C(e).is(n)) break;
        r.push(e);
      }
    return r;
  }
  function T(e, t) {
    for (var n = []; e; e = e.nextSibling)
      1 === e.nodeType && e !== t && n.push(e);
    return n;
  }
  var S = C.expr.match.needsContext;
  function E(e, t) {
    return e.nodeName && e.nodeName.toLowerCase() === t.toLowerCase();
  }
  var I = /^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;
  function A(e, n, r) {
    return g(n)
      ? C.grep(e, function (e, t) {
          return !!n.call(e, t, e) !== r;
        })
      : n.nodeType
        ? C.grep(e, function (e) {
            return (e === n) !== r;
          })
        : "string" != typeof n
          ? C.grep(e, function (e) {
              return -1 < i.call(n, e) !== r;
            })
          : C.filter(n, e, r);
  }
  ((C.filter = function (e, t, n) {
    var r = t[0];
    return (
      n && (e = ":not(" + e + ")"),
      1 === t.length && 1 === r.nodeType
        ? C.find.matchesSelector(r, e)
          ? [r]
          : []
        : C.find.matches(
            e,
            C.grep(t, function (e) {
              return 1 === e.nodeType;
            }),
          )
    );
  }),
    C.fn.extend({
      find: function (e) {
        var t,
          n,
          r = this.length,
          i = this;
        if ("string" != typeof e)
          return this.pushStack(
            C(e).filter(function () {
              for (t = 0; t < r; t++) if (C.contains(i[t], this)) return !0;
            }),
          );
        for (n = this.pushStack([]), t = 0; t < r; t++) C.find(e, i[t], n);
        return 1 < r ? C.uniqueSort(n) : n;
      },
      filter: function (e) {
        return this.pushStack(A(this, e || [], !1));
      },
      not: function (e) {
        return this.pushStack(A(this, e || [], !0));
      },
      is: function (e) {
        return !!A(this, "string" == typeof e && S.test(e) ? C(e) : e || [], !1)
          .length;
      },
    }));
  var k = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;
  (C.fn.init = function (e, t, n) {
    if (!e) return this;
    if (((n = n || D), "string" != typeof e))
      return e.nodeType
        ? ((this[0] = e), (this.length = 1), this)
        : g(e)
          ? void 0 !== n.ready
            ? n.ready(e)
            : e(C)
          : C.makeArray(e, this);
    if (
      !(r =
        "<" === e[0] && ">" === e[e.length - 1] && 3 <= e.length
          ? [null, e, null]
          : k.exec(e)) ||
      (!r[1] && t)
    )
      return (!t || t.jquery ? t || n : this.constructor(t)).find(e);
    if (r[1]) {
      if (
        ((t = t instanceof C ? t[0] : t),
        C.merge(
          this,
          C.parseHTML(r[1], t && t.nodeType ? t.ownerDocument || t : H, !0),
        ),
        I.test(r[1]) && C.isPlainObject(t))
      )
        for (var r in t) g(this[r]) ? this[r](t[r]) : this.attr(r, t[r]);
      return this;
    }
    return (
      (e = H.getElementById(r[2])) && ((this[0] = e), (this.length = 1)),
      this
    );
  }).prototype = C.fn;
  var D = C(H),
    L = /^(?:parents|prev(?:Until|All))/,
    j = { children: !0, contents: !0, next: !0, prev: !0 };
  function N(e, t) {
    for (; (e = e[t]) && 1 !== e.nodeType; );
    return e;
  }
  (C.fn.extend({
    has: function (e) {
      var t = C(e, this),
        n = t.length;
      return this.filter(function () {
        for (var e = 0; e < n; e++) if (C.contains(this, t[e])) return !0;
      });
    },
    closest: function (e, t) {
      var n,
        r = 0,
        i = this.length,
        o = [],
        a = "string" != typeof e && C(e);
      if (!S.test(e))
        for (; r < i; r++)
          for (n = this[r]; n && n !== t; n = n.parentNode)
            if (
              n.nodeType < 11 &&
              (a
                ? -1 < a.index(n)
                : 1 === n.nodeType && C.find.matchesSelector(n, e))
            ) {
              o.push(n);
              break;
            }
      return this.pushStack(1 < o.length ? C.uniqueSort(o) : o);
    },
    index: function (e) {
      return e
        ? "string" == typeof e
          ? i.call(C(e), this[0])
          : i.call(this, e.jquery ? e[0] : e)
        : this[0] && this[0].parentNode
          ? this.first().prevAll().length
          : -1;
    },
    add: function (e, t) {
      return this.pushStack(C.uniqueSort(C.merge(this.get(), C(e, t))));
    },
    addBack: function (e) {
      return this.add(null == e ? this.prevObject : this.prevObject.filter(e));
    },
  }),
    C.each(
      {
        parent: function (e) {
          e = e.parentNode;
          return e && 11 !== e.nodeType ? e : null;
        },
        parents: function (e) {
          return x(e, "parentNode");
        },
        parentsUntil: function (e, t, n) {
          return x(e, "parentNode", n);
        },
        next: function (e) {
          return N(e, "nextSibling");
        },
        prev: function (e) {
          return N(e, "previousSibling");
        },
        nextAll: function (e) {
          return x(e, "nextSibling");
        },
        prevAll: function (e) {
          return x(e, "previousSibling");
        },
        nextUntil: function (e, t, n) {
          return x(e, "nextSibling", n);
        },
        prevUntil: function (e, t, n) {
          return x(e, "previousSibling", n);
        },
        siblings: function (e) {
          return T((e.parentNode || {}).firstChild, e);
        },
        children: function (e) {
          return T(e.firstChild);
        },
        contents: function (e) {
          return null != e.contentDocument && n(e.contentDocument)
            ? e.contentDocument
            : (E(e, "template") && (e = e.content || e),
              C.merge([], e.childNodes));
        },
      },
      function (r, i) {
        C.fn[r] = function (e, t) {
          var n = C.map(this, i, e);
          return (
            (t = "Until" !== r.slice(-5) ? e : t) &&
              "string" == typeof t &&
              (n = C.filter(t, n)),
            1 < this.length &&
              (j[r] || C.uniqueSort(n), L.test(r) && n.reverse()),
            this.pushStack(n)
          );
        };
      },
    ));
  var $ = /[^\x20\t\r\n\f]+/g;
  function M(e) {
    return e;
  }
  function O(e) {
    throw e;
  }
  function B(e, t, n, r) {
    var i;
    try {
      e && g((i = e.promise))
        ? i.call(e).done(t).fail(n)
        : e && g((i = e.then))
          ? i.call(e, t, n)
          : t.apply(void 0, [e].slice(r));
    } catch (e) {
      n.apply(void 0, [e]);
    }
  }
  ((C.Callbacks = function (r) {
    var e, n;
    r =
      "string" == typeof r
        ? ((e = r),
          (n = {}),
          C.each(e.match($) || [], function (e, t) {
            n[t] = !0;
          }),
          n)
        : C.extend({}, r);
    function i() {
      for (s = s || r.once, a = o = !0; d.length; l = -1)
        for (t = d.shift(); ++l < c.length; )
          !1 === c[l].apply(t[0], t[1]) &&
            r.stopOnFalse &&
            ((l = c.length), (t = !1));
      (r.memory || (t = !1), (o = !1), s && (c = t ? [] : ""));
    }
    var o,
      t,
      a,
      s,
      c = [],
      d = [],
      l = -1,
      u = {
        add: function () {
          return (
            c &&
              (t && !o && ((l = c.length - 1), d.push(t)),
              (function n(e) {
                C.each(e, function (e, t) {
                  g(t)
                    ? (r.unique && u.has(t)) || c.push(t)
                    : t && t.length && "string" !== f(t) && n(t);
                });
              })(arguments),
              t && !o && i()),
            this
          );
        },
        remove: function () {
          return (
            C.each(arguments, function (e, t) {
              for (var n; -1 < (n = C.inArray(t, c, n)); )
                (c.splice(n, 1), n <= l && l--);
            }),
            this
          );
        },
        has: function (e) {
          return e ? -1 < C.inArray(e, c) : 0 < c.length;
        },
        empty: function () {
          return ((c = c && []), this);
        },
        disable: function () {
          return ((s = d = []), (c = t = ""), this);
        },
        disabled: function () {
          return !c;
        },
        lock: function () {
          return ((s = d = []), t || o || (c = t = ""), this);
        },
        locked: function () {
          return !!s;
        },
        fireWith: function (e, t) {
          return (
            s ||
              ((t = [e, (t = t || []).slice ? t.slice() : t]),
              d.push(t),
              o || i()),
            this
          );
        },
        fire: function () {
          return (u.fireWith(this, arguments), this);
        },
        fired: function () {
          return !!a;
        },
      };
    return u;
  }),
    C.extend({
      Deferred: function (e) {
        var o = [
            [
              "notify",
              "progress",
              C.Callbacks("memory"),
              C.Callbacks("memory"),
              2,
            ],
            [
              "resolve",
              "done",
              C.Callbacks("once memory"),
              C.Callbacks("once memory"),
              0,
              "resolved",
            ],
            [
              "reject",
              "fail",
              C.Callbacks("once memory"),
              C.Callbacks("once memory"),
              1,
              "rejected",
            ],
          ],
          i = "pending",
          a = {
            state: function () {
              return i;
            },
            always: function () {
              return (s.done(arguments).fail(arguments), this);
            },
            catch: function (e) {
              return a.then(null, e);
            },
            pipe: function () {
              var i = arguments;
              return C.Deferred(function (r) {
                (C.each(o, function (e, t) {
                  var n = g(i[t[4]]) && i[t[4]];
                  s[t[1]](function () {
                    var e = n && n.apply(this, arguments);
                    e && g(e.promise)
                      ? e
                          .promise()
                          .progress(r.notify)
                          .done(r.resolve)
                          .fail(r.reject)
                      : r[t[0] + "With"](this, n ? [e] : arguments);
                  });
                }),
                  (i = null));
              }).promise();
            },
            then: function (t, n, r) {
              var c = 0;
              function d(i, o, a, s) {
                return function () {
                  function e() {
                    var e, t;
                    if (!(i < c)) {
                      if ((e = a.apply(n, r)) === o.promise())
                        throw new TypeError("Thenable self-resolution");
                      ((t =
                        e &&
                        ("object" == typeof e || "function" == typeof e) &&
                        e.then),
                        g(t)
                          ? s
                            ? t.call(e, d(c, o, M, s), d(c, o, O, s))
                            : (c++,
                              t.call(
                                e,
                                d(c, o, M, s),
                                d(c, o, O, s),
                                d(c, o, M, o.notifyWith),
                              ))
                          : (a !== M && ((n = void 0), (r = [e])),
                            (s || o.resolveWith)(n, r)));
                    }
                  }
                  var n = this,
                    r = arguments,
                    t = s
                      ? e
                      : function () {
                          try {
                            e();
                          } catch (e) {
                            (C.Deferred.exceptionHook &&
                              C.Deferred.exceptionHook(e, t.stackTrace),
                              c <= i + 1 &&
                                (a !== O && ((n = void 0), (r = [e])),
                                o.rejectWith(n, r)));
                          }
                        };
                  i
                    ? t()
                    : (C.Deferred.getStackHook &&
                        (t.stackTrace = C.Deferred.getStackHook()),
                      w.setTimeout(t));
                };
              }
              return C.Deferred(function (e) {
                (o[0][3].add(d(0, e, g(r) ? r : M, e.notifyWith)),
                  o[1][3].add(d(0, e, g(t) ? t : M)),
                  o[2][3].add(d(0, e, g(n) ? n : O)));
              }).promise();
            },
            promise: function (e) {
              return null != e ? C.extend(e, a) : a;
            },
          },
          s = {};
        return (
          C.each(o, function (e, t) {
            var n = t[2],
              r = t[5];
            ((a[t[1]] = n.add),
              r &&
                n.add(
                  function () {
                    i = r;
                  },
                  o[3 - e][2].disable,
                  o[3 - e][3].disable,
                  o[0][2].lock,
                  o[0][3].lock,
                ),
              n.add(t[3].fire),
              (s[t[0]] = function () {
                return (
                  s[t[0] + "With"](this === s ? void 0 : this, arguments),
                  this
                );
              }),
              (s[t[0] + "With"] = n.fireWith));
          }),
          a.promise(s),
          e && e.call(s, s),
          s
        );
      },
      when: function (e) {
        function t(t) {
          return function (e) {
            ((i[t] = this),
              (o[t] = 1 < arguments.length ? s.call(arguments) : e),
              --n || a.resolveWith(i, o));
          };
        }
        var n = arguments.length,
          r = n,
          i = Array(r),
          o = s.call(arguments),
          a = C.Deferred();
        if (
          n <= 1 &&
          (B(e, a.done(t(r)).resolve, a.reject, !n),
          "pending" === a.state() || g(o[r] && o[r].then))
        )
          return a.then();
        for (; r--; ) B(o[r], t(r), a.reject);
        return a.promise();
      },
    }));
  var R = /^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;
  ((C.Deferred.exceptionHook = function (e, t) {
    w.console &&
      w.console.warn &&
      e &&
      R.test(e.name) &&
      w.console.warn("jQuery.Deferred exception: " + e.message, e.stack, t);
  }),
    (C.readyException = function (e) {
      w.setTimeout(function () {
        throw e;
      });
    }));
  var q = C.Deferred();
  function F() {
    (H.removeEventListener("DOMContentLoaded", F),
      w.removeEventListener("load", F),
      C.ready());
  }
  ((C.fn.ready = function (e) {
    return (
      q.then(e).catch(function (e) {
        C.readyException(e);
      }),
      this
    );
  }),
    C.extend({
      isReady: !1,
      readyWait: 1,
      ready: function (e) {
        (!0 === e ? --C.readyWait : C.isReady) ||
          ((C.isReady = !0) !== e && 0 < --C.readyWait) ||
          q.resolveWith(H, [C]);
      },
    }),
    (C.ready.then = q.then),
    "complete" === H.readyState ||
    ("loading" !== H.readyState && !H.documentElement.doScroll)
      ? w.setTimeout(C.ready)
      : (H.addEventListener("DOMContentLoaded", F),
        w.addEventListener("load", F)));
  function z(e, t, n, r, i, o, a) {
    var s = 0,
      c = e.length,
      d = null == n;
    if ("object" === f(n)) for (s in ((i = !0), n)) z(e, t, s, n[s], !0, o, a);
    else if (
      void 0 !== r &&
      ((i = !0),
      g(r) || (a = !0),
      (t = d
        ? a
          ? (t.call(e, r), null)
          : ((d = t),
            function (e, t, n) {
              return d.call(C(e), n);
            })
        : t))
    )
      for (; s < c; s++) t(e[s], n, a ? r : r.call(e[s], s, t(e[s], n)));
    return i ? e : d ? t.call(e) : c ? t(e[0], n) : o;
  }
  var Q = /^-ms-/,
    U = /-([a-z])/g;
  function W(e, t) {
    return t.toUpperCase();
  }
  function V(e) {
    return e.replace(Q, "ms-").replace(U, W);
  }
  function X(e) {
    return 1 === e.nodeType || 9 === e.nodeType || !+e.nodeType;
  }
  function _() {
    this.expando = C.expando + _.uid++;
  }
  ((_.uid = 1),
    (_.prototype = {
      cache: function (e) {
        var t = e[this.expando];
        return (
          t ||
            ((t = {}),
            X(e) &&
              (e.nodeType
                ? (e[this.expando] = t)
                : Object.defineProperty(e, this.expando, {
                    value: t,
                    configurable: !0,
                  }))),
          t
        );
      },
      set: function (e, t, n) {
        var r,
          i = this.cache(e);
        if ("string" == typeof t) i[V(t)] = n;
        else for (r in t) i[V(r)] = t[r];
        return i;
      },
      get: function (e, t) {
        return void 0 === t
          ? this.cache(e)
          : e[this.expando] && e[this.expando][V(t)];
      },
      access: function (e, t, n) {
        return void 0 === t || (t && "string" == typeof t && void 0 === n)
          ? this.get(e, t)
          : (this.set(e, t, n), void 0 !== n ? n : t);
      },
      remove: function (e, t) {
        var n,
          r = e[this.expando];
        if (void 0 !== r) {
          if (void 0 !== t) {
            n = (t = Array.isArray(t)
              ? t.map(V)
              : (t = V(t)) in r
                ? [t]
                : t.match($) || []).length;
            for (; n--; ) delete r[t[n]];
          }
          (void 0 !== t && !C.isEmptyObject(r)) ||
            (e.nodeType ? (e[this.expando] = void 0) : delete e[this.expando]);
        }
      },
      hasData: function (e) {
        e = e[this.expando];
        return void 0 !== e && !C.isEmptyObject(e);
      },
    }));
  var J = new _(),
    Y = new _(),
    G = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,
    K = /[A-Z]/g;
  function Z(e, t, n) {
    var r, i;
    if (void 0 === n && 1 === e.nodeType)
      if (
        ((r = "data-" + t.replace(K, "-$&").toLowerCase()),
        "string" == typeof (n = e.getAttribute(r)))
      ) {
        try {
          n =
            "true" === (i = n) ||
            ("false" !== i &&
              ("null" === i
                ? null
                : i === +i + ""
                  ? +i
                  : G.test(i)
                    ? JSON.parse(i)
                    : i));
        } catch (e) {}
        Y.set(e, t, n);
      } else n = void 0;
    return n;
  }
  (C.extend({
    hasData: function (e) {
      return Y.hasData(e) || J.hasData(e);
    },
    data: function (e, t, n) {
      return Y.access(e, t, n);
    },
    removeData: function (e, t) {
      Y.remove(e, t);
    },
    _data: function (e, t, n) {
      return J.access(e, t, n);
    },
    _removeData: function (e, t) {
      J.remove(e, t);
    },
  }),
    C.fn.extend({
      data: function (n, e) {
        var t,
          r,
          i,
          o = this[0],
          a = o && o.attributes;
        if (void 0 !== n)
          return "object" == typeof n
            ? this.each(function () {
                Y.set(this, n);
              })
            : z(
                this,
                function (e) {
                  var t;
                  return o && void 0 === e
                    ? void 0 !== (t = Y.get(o, n)) || void 0 !== (t = Z(o, n))
                      ? t
                      : void 0
                    : void this.each(function () {
                        Y.set(this, n, e);
                      });
                },
                null,
                e,
                1 < arguments.length,
                null,
                !0,
              );
        if (
          this.length &&
          ((i = Y.get(o)), 1 === o.nodeType && !J.get(o, "hasDataAttrs"))
        ) {
          for (t = a.length; t--; )
            a[t] &&
              0 === (r = a[t].name).indexOf("data-") &&
              ((r = V(r.slice(5))), Z(o, r, i[r]));
          J.set(o, "hasDataAttrs", !0);
        }
        return i;
      },
      removeData: function (e) {
        return this.each(function () {
          Y.remove(this, e);
        });
      },
    }),
    C.extend({
      queue: function (e, t, n) {
        var r;
        if (e)
          return (
            (r = J.get(e, (t = (t || "fx") + "queue"))),
            n &&
              (!r || Array.isArray(n)
                ? (r = J.access(e, t, C.makeArray(n)))
                : r.push(n)),
            r || []
          );
      },
      dequeue: function (e, t) {
        t = t || "fx";
        var n = C.queue(e, t),
          r = n.length,
          i = n.shift(),
          o = C._queueHooks(e, t);
        ("inprogress" === i && ((i = n.shift()), r--),
          i &&
            ("fx" === t && n.unshift("inprogress"),
            delete o.stop,
            i.call(
              e,
              function () {
                C.dequeue(e, t);
              },
              o,
            )),
          !r && o && o.empty.fire());
      },
      _queueHooks: function (e, t) {
        var n = t + "queueHooks";
        return (
          J.get(e, n) ||
          J.access(e, n, {
            empty: C.Callbacks("once memory").add(function () {
              J.remove(e, [t + "queue", n]);
            }),
          })
        );
      },
    }),
    C.fn.extend({
      queue: function (t, n) {
        var e = 2;
        return (
          "string" != typeof t && ((n = t), (t = "fx"), e--),
          arguments.length < e
            ? C.queue(this[0], t)
            : void 0 === n
              ? this
              : this.each(function () {
                  var e = C.queue(this, t, n);
                  (C._queueHooks(this, t),
                    "fx" === t && "inprogress" !== e[0] && C.dequeue(this, t));
                })
        );
      },
      dequeue: function (e) {
        return this.each(function () {
          C.dequeue(this, e);
        });
      },
      clearQueue: function (e) {
        return this.queue(e || "fx", []);
      },
      promise: function (e, t) {
        function n() {
          --i || o.resolveWith(a, [a]);
        }
        var r,
          i = 1,
          o = C.Deferred(),
          a = this,
          s = this.length;
        for (
          "string" != typeof e && ((t = e), (e = void 0)), e = e || "fx";
          s--;
        )
          (r = J.get(a[s], e + "queueHooks")) &&
            r.empty &&
            (i++, r.empty.add(n));
        return (n(), o.promise(t));
      },
    }));
  var ee = /[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,
    te = new RegExp("^(?:([+-])=|)(" + ee + ")([a-z%]*)$", "i"),
    ne = ["Top", "Right", "Bottom", "Left"],
    re = H.documentElement,
    ie = function (e) {
      return C.contains(e.ownerDocument, e);
    },
    oe = { composed: !0 };
  re.getRootNode &&
    (ie = function (e) {
      return (
        C.contains(e.ownerDocument, e) || e.getRootNode(oe) === e.ownerDocument
      );
    });
  function ae(e, t) {
    return (
      "none" === (e = t || e).style.display ||
      ("" === e.style.display && ie(e) && "none" === C.css(e, "display"))
    );
  }
  function se(e, t, n, r) {
    var i,
      o,
      a = 20,
      s = r
        ? function () {
            return r.cur();
          }
        : function () {
            return C.css(e, t, "");
          },
      c = s(),
      d = (n && n[3]) || (C.cssNumber[t] ? "" : "px"),
      l =
        e.nodeType &&
        (C.cssNumber[t] || ("px" !== d && +c)) &&
        te.exec(C.css(e, t));
    if (l && l[3] !== d) {
      for (d = d || l[3], l = +(c /= 2) || 1; a--; )
        (C.style(e, t, l + d),
          (1 - o) * (1 - (o = s() / c || 0.5)) <= 0 && (a = 0),
          (l /= o));
      (C.style(e, t, (l *= 2) + d), (n = n || []));
    }
    return (
      n &&
        ((l = +l || +c || 0),
        (i = n[1] ? l + (n[1] + 1) * n[2] : +n[2]),
        r && ((r.unit = d), (r.start = l), (r.end = i))),
      i
    );
  }
  var ce = {};
  function de(e, t) {
    for (var n, r, i, o, a, s, c = [], d = 0, l = e.length; d < l; d++)
      (r = e[d]).style &&
        ((n = r.style.display),
        t
          ? ("none" === n &&
              ((c[d] = J.get(r, "display") || null),
              c[d] || (r.style.display = "")),
            "" === r.style.display &&
              ae(r) &&
              (c[d] =
                ((s = o = i = void 0),
                (o = r.ownerDocument),
                (a = r.nodeName),
                (s = ce[a]) ||
                  ((i = o.body.appendChild(o.createElement(a))),
                  (s = C.css(i, "display")),
                  i.parentNode.removeChild(i),
                  (ce[a] = s = "none" === s ? "block" : s)))))
          : "none" !== n && ((c[d] = "none"), J.set(r, "display", n)));
    for (d = 0; d < l; d++) null != c[d] && (e[d].style.display = c[d]);
    return e;
  }
  C.fn.extend({
    show: function () {
      return de(this, !0);
    },
    hide: function () {
      return de(this);
    },
    toggle: function (e) {
      return "boolean" == typeof e
        ? e
          ? this.show()
          : this.hide()
        : this.each(function () {
            ae(this) ? C(this).show() : C(this).hide();
          });
    },
  });
  var le = /^(?:checkbox|radio)$/i,
    ue = /<([a-z][^\/\0>\x20\t\r\n\f]*)/i,
    he = /^$|^module$|\/(?:java|ecma)script/i,
    u = H.createDocumentFragment().appendChild(H.createElement("div"));
  ((p = H.createElement("input")).setAttribute("type", "radio"),
    p.setAttribute("checked", "checked"),
    p.setAttribute("name", "t"),
    u.appendChild(p),
    (b.checkClone = u.cloneNode(!0).cloneNode(!0).lastChild.checked),
    (u.innerHTML = "<textarea>x</textarea>"),
    (b.noCloneChecked = !!u.cloneNode(!0).lastChild.defaultValue),
    (u.innerHTML = "<option></option>"),
    (b.option = !!u.lastChild));
  var pe = {
    thead: [1, "<table>", "</table>"],
    col: [2, "<table><colgroup>", "</colgroup></table>"],
    tr: [2, "<table><tbody>", "</tbody></table>"],
    td: [3, "<table><tbody><tr>", "</tr></tbody></table>"],
    _default: [0, "", ""],
  };
  function fe(e, t) {
    var n =
      void 0 !== e.getElementsByTagName
        ? e.getElementsByTagName(t || "*")
        : void 0 !== e.querySelectorAll
          ? e.querySelectorAll(t || "*")
          : [];
    return void 0 === t || (t && E(e, t)) ? C.merge([e], n) : n;
  }
  function ge(e, t) {
    for (var n = 0, r = e.length; n < r; n++)
      J.set(e[n], "globalEval", !t || J.get(t[n], "globalEval"));
  }
  ((pe.tbody = pe.tfoot = pe.colgroup = pe.caption = pe.thead),
    (pe.th = pe.td),
    b.option ||
      (pe.optgroup = pe.option =
        [1, "<select multiple='multiple'>", "</select>"]));
  var me = /<|&#?\w+;/;
  function ve(e, t, n, r, i) {
    for (
      var o,
        a,
        s,
        c,
        d,
        l = t.createDocumentFragment(),
        u = [],
        h = 0,
        p = e.length;
      h < p;
      h++
    )
      if ((o = e[h]) || 0 === o)
        if ("object" === f(o)) C.merge(u, o.nodeType ? [o] : o);
        else if (me.test(o)) {
          for (
            a = a || l.appendChild(t.createElement("div")),
              s = (ue.exec(o) || ["", ""])[1].toLowerCase(),
              s = pe[s] || pe._default,
              a.innerHTML = s[1] + C.htmlPrefilter(o) + s[2],
              d = s[0];
            d--;
          )
            a = a.lastChild;
          (C.merge(u, a.childNodes), ((a = l.firstChild).textContent = ""));
        } else u.push(t.createTextNode(o));
    for (l.textContent = "", h = 0; (o = u[h++]); )
      if (r && -1 < C.inArray(o, r)) i && i.push(o);
      else if (
        ((c = ie(o)), (a = fe(l.appendChild(o), "script")), c && ge(a), n)
      )
        for (d = 0; (o = a[d++]); ) he.test(o.type || "") && n.push(o);
    return l;
  }
  var ye = /^key/,
    be = /^(?:mouse|pointer|contextmenu|drag|drop)|click/,
    Pe = /^([^.]*)(?:\.(.+)|)/;
  function xe() {
    return !0;
  }
  function we() {
    return !1;
  }
  function He(e, t) {
    return (
      (e ===
        (function () {
          try {
            return H.activeElement;
          } catch (e) {}
        })()) ==
      ("focus" === t)
    );
  }
  function Ce(e, t, n, r, i, o) {
    var a, s;
    if ("object" == typeof t) {
      for (s in ("string" != typeof n && ((r = r || n), (n = void 0)), t))
        Ce(e, s, n, r, t[s], o);
      return e;
    }
    if (
      (null == r && null == i
        ? ((i = n), (r = n = void 0))
        : null == i &&
          ("string" == typeof n
            ? ((i = r), (r = void 0))
            : ((i = r), (r = n), (n = void 0))),
      !1 === i)
    )
      i = we;
    else if (!i) return e;
    return (
      1 === o &&
        ((a = i),
        ((i = function (e) {
          return (C().off(e), a.apply(this, arguments));
        }).guid = a.guid || (a.guid = C.guid++))),
      e.each(function () {
        C.event.add(this, t, i, r, n);
      })
    );
  }
  function Te(e, i, o) {
    o
      ? (J.set(e, i, !1),
        C.event.add(e, i, {
          namespace: !1,
          handler: function (e) {
            var t,
              n,
              r = J.get(this, i);
            if (1 & e.isTrigger && this[i]) {
              if (r.length)
                (C.event.special[i] || {}).delegateType && e.stopPropagation();
              else if (
                ((r = s.call(arguments)),
                J.set(this, i, r),
                (t = o(this, i)),
                this[i](),
                r !== (n = J.get(this, i)) || t ? J.set(this, i, !1) : (n = {}),
                r !== n)
              )
                return (
                  e.stopImmediatePropagation(),
                  e.preventDefault(),
                  n.value
                );
            } else
              r.length &&
                (J.set(this, i, {
                  value: C.event.trigger(
                    C.extend(r[0], C.Event.prototype),
                    r.slice(1),
                    this,
                  ),
                }),
                e.stopImmediatePropagation());
          },
        }))
      : void 0 === J.get(e, i) && C.event.add(e, i, xe);
  }
  ((C.event = {
    global: {},
    add: function (t, e, n, r, i) {
      var o,
        a,
        s,
        c,
        d,
        l,
        u,
        h,
        p,
        f = J.get(t);
      if (X(t))
        for (
          n.handler && ((n = (o = n).handler), (i = o.selector)),
            i && C.find.matchesSelector(re, i),
            n.guid || (n.guid = C.guid++),
            (s = f.events) || (s = f.events = Object.create(null)),
            (a = f.handle) ||
              (a = f.handle =
                function (e) {
                  return void 0 !== C && C.event.triggered !== e.type
                    ? C.event.dispatch.apply(t, arguments)
                    : void 0;
                }),
            c = (e = (e || "").match($) || [""]).length;
          c--;
        )
          ((u = p = (d = Pe.exec(e[c]) || [])[1]),
            (h = (d[2] || "").split(".").sort()),
            u &&
              ((l = C.event.special[u] || {}),
              (u = (i ? l.delegateType : l.bindType) || u),
              (l = C.event.special[u] || {}),
              (d = C.extend(
                {
                  type: u,
                  origType: p,
                  data: r,
                  handler: n,
                  guid: n.guid,
                  selector: i,
                  needsContext: i && C.expr.match.needsContext.test(i),
                  namespace: h.join("."),
                },
                o,
              )),
              (p = s[u]) ||
                (((p = s[u] = []).delegateCount = 0),
                (l.setup && !1 !== l.setup.call(t, r, h, a)) ||
                  (t.addEventListener && t.addEventListener(u, a))),
              l.add &&
                (l.add.call(t, d), d.handler.guid || (d.handler.guid = n.guid)),
              i ? p.splice(p.delegateCount++, 0, d) : p.push(d),
              (C.event.global[u] = !0)));
    },
    remove: function (e, t, n, r, i) {
      var o,
        a,
        s,
        c,
        d,
        l,
        u,
        h,
        p,
        f,
        g,
        m = J.hasData(e) && J.get(e);
      if (m && (c = m.events)) {
        for (d = (t = (t || "").match($) || [""]).length; d--; )
          if (
            ((p = g = (s = Pe.exec(t[d]) || [])[1]),
            (f = (s[2] || "").split(".").sort()),
            p)
          ) {
            for (
              u = C.event.special[p] || {},
                h = c[(p = (r ? u.delegateType : u.bindType) || p)] || [],
                s =
                  s[2] &&
                  new RegExp("(^|\\.)" + f.join("\\.(?:.*\\.|)") + "(\\.|$)"),
                a = o = h.length;
              o--;
            )
              ((l = h[o]),
                (!i && g !== l.origType) ||
                  (n && n.guid !== l.guid) ||
                  (s && !s.test(l.namespace)) ||
                  (r && r !== l.selector && ("**" !== r || !l.selector)) ||
                  (h.splice(o, 1),
                  l.selector && h.delegateCount--,
                  u.remove && u.remove.call(e, l)));
            a &&
              !h.length &&
              ((u.teardown && !1 !== u.teardown.call(e, f, m.handle)) ||
                C.removeEvent(e, p, m.handle),
              delete c[p]);
          } else for (p in c) C.event.remove(e, p + t[d], n, r, !0);
        C.isEmptyObject(c) && J.remove(e, "handle events");
      }
    },
    dispatch: function (e) {
      var t,
        n,
        r,
        i,
        o,
        a = new Array(arguments.length),
        s = C.event.fix(e),
        c = (J.get(this, "events") || Object.create(null))[s.type] || [],
        e = C.event.special[s.type] || {};
      for (a[0] = s, t = 1; t < arguments.length; t++) a[t] = arguments[t];
      if (
        ((s.delegateTarget = this),
        !e.preDispatch || !1 !== e.preDispatch.call(this, s))
      ) {
        for (
          o = C.event.handlers.call(this, s, c), t = 0;
          (r = o[t++]) && !s.isPropagationStopped();
        )
          for (
            s.currentTarget = r.elem, n = 0;
            (i = r.handlers[n++]) && !s.isImmediatePropagationStopped();
          )
            (s.rnamespace &&
              !1 !== i.namespace &&
              !s.rnamespace.test(i.namespace)) ||
              ((s.handleObj = i),
              (s.data = i.data),
              void 0 !==
                (i = (
                  (C.event.special[i.origType] || {}).handle || i.handler
                ).apply(r.elem, a)) &&
                !1 === (s.result = i) &&
                (s.preventDefault(), s.stopPropagation()));
        return (e.postDispatch && e.postDispatch.call(this, s), s.result);
      }
    },
    handlers: function (e, t) {
      var n,
        r,
        i,
        o,
        a,
        s = [],
        c = t.delegateCount,
        d = e.target;
      if (c && d.nodeType && !("click" === e.type && 1 <= e.button))
        for (; d !== this; d = d.parentNode || this)
          if (1 === d.nodeType && ("click" !== e.type || !0 !== d.disabled)) {
            for (o = [], a = {}, n = 0; n < c; n++)
              (void 0 === a[(i = (r = t[n]).selector + " ")] &&
                (a[i] = r.needsContext
                  ? -1 < C(i, this).index(d)
                  : C.find(i, this, null, [d]).length),
                a[i] && o.push(r));
            o.length && s.push({ elem: d, handlers: o });
          }
      return (
        (d = this),
        c < t.length && s.push({ elem: d, handlers: t.slice(c) }),
        s
      );
    },
    addProp: function (t, e) {
      Object.defineProperty(C.Event.prototype, t, {
        enumerable: !0,
        configurable: !0,
        get: g(e)
          ? function () {
              if (this.originalEvent) return e(this.originalEvent);
            }
          : function () {
              if (this.originalEvent) return this.originalEvent[t];
            },
        set: function (e) {
          Object.defineProperty(this, t, {
            enumerable: !0,
            configurable: !0,
            writable: !0,
            value: e,
          });
        },
      });
    },
    fix: function (e) {
      return e[C.expando] ? e : new C.Event(e);
    },
    special: {
      load: { noBubble: !0 },
      click: {
        setup: function (e) {
          e = this || e;
          return (
            le.test(e.type) && e.click && E(e, "input") && Te(e, "click", xe),
            !1
          );
        },
        trigger: function (e) {
          e = this || e;
          return (
            le.test(e.type) && e.click && E(e, "input") && Te(e, "click"),
            !0
          );
        },
        _default: function (e) {
          e = e.target;
          return (
            (le.test(e.type) &&
              e.click &&
              E(e, "input") &&
              J.get(e, "click")) ||
            E(e, "a")
          );
        },
      },
      beforeunload: {
        postDispatch: function (e) {
          void 0 !== e.result &&
            e.originalEvent &&
            (e.originalEvent.returnValue = e.result);
        },
      },
    },
  }),
    (C.removeEvent = function (e, t, n) {
      e.removeEventListener && e.removeEventListener(t, n);
    }),
    (C.Event = function (e, t) {
      if (!(this instanceof C.Event)) return new C.Event(e, t);
      (e && e.type
        ? ((this.originalEvent = e),
          (this.type = e.type),
          (this.isDefaultPrevented =
            e.defaultPrevented ||
            (void 0 === e.defaultPrevented && !1 === e.returnValue)
              ? xe
              : we),
          (this.target =
            e.target && 3 === e.target.nodeType
              ? e.target.parentNode
              : e.target),
          (this.currentTarget = e.currentTarget),
          (this.relatedTarget = e.relatedTarget))
        : (this.type = e),
        t && C.extend(this, t),
        (this.timeStamp = (e && e.timeStamp) || Date.now()),
        (this[C.expando] = !0));
    }),
    (C.Event.prototype = {
      constructor: C.Event,
      isDefaultPrevented: we,
      isPropagationStopped: we,
      isImmediatePropagationStopped: we,
      isSimulated: !1,
      preventDefault: function () {
        var e = this.originalEvent;
        ((this.isDefaultPrevented = xe),
          e && !this.isSimulated && e.preventDefault());
      },
      stopPropagation: function () {
        var e = this.originalEvent;
        ((this.isPropagationStopped = xe),
          e && !this.isSimulated && e.stopPropagation());
      },
      stopImmediatePropagation: function () {
        var e = this.originalEvent;
        ((this.isImmediatePropagationStopped = xe),
          e && !this.isSimulated && e.stopImmediatePropagation(),
          this.stopPropagation());
      },
    }),
    C.each(
      {
        altKey: !0,
        bubbles: !0,
        cancelable: !0,
        changedTouches: !0,
        ctrlKey: !0,
        detail: !0,
        eventPhase: !0,
        metaKey: !0,
        pageX: !0,
        pageY: !0,
        shiftKey: !0,
        view: !0,
        char: !0,
        code: !0,
        charCode: !0,
        key: !0,
        keyCode: !0,
        button: !0,
        buttons: !0,
        clientX: !0,
        clientY: !0,
        offsetX: !0,
        offsetY: !0,
        pointerId: !0,
        pointerType: !0,
        screenX: !0,
        screenY: !0,
        targetTouches: !0,
        toElement: !0,
        touches: !0,
        which: function (e) {
          var t = e.button;
          return null == e.which && ye.test(e.type)
            ? null != e.charCode
              ? e.charCode
              : e.keyCode
            : !e.which && void 0 !== t && be.test(e.type)
              ? 1 & t
                ? 1
                : 2 & t
                  ? 3
                  : 4 & t
                    ? 2
                    : 0
              : e.which;
        },
      },
      C.event.addProp,
    ),
    C.each({ focus: "focusin", blur: "focusout" }, function (e, t) {
      C.event.special[e] = {
        setup: function () {
          return (Te(this, e, He), !1);
        },
        trigger: function () {
          return (Te(this, e), !0);
        },
        delegateType: t,
      };
    }),
    C.each(
      {
        mouseenter: "mouseover",
        mouseleave: "mouseout",
        pointerenter: "pointerover",
        pointerleave: "pointerout",
      },
      function (e, i) {
        C.event.special[e] = {
          delegateType: i,
          bindType: i,
          handle: function (e) {
            var t,
              n = e.relatedTarget,
              r = e.handleObj;
            return (
              (n && (n === this || C.contains(this, n))) ||
                ((e.type = r.origType),
                (t = r.handler.apply(this, arguments)),
                (e.type = i)),
              t
            );
          },
        };
      },
    ),
    C.fn.extend({
      on: function (e, t, n, r) {
        return Ce(this, e, t, n, r);
      },
      one: function (e, t, n, r) {
        return Ce(this, e, t, n, r, 1);
      },
      off: function (e, t, n) {
        var r, i;
        if (e && e.preventDefault && e.handleObj)
          return (
            (r = e.handleObj),
            C(e.delegateTarget).off(
              r.namespace ? r.origType + "." + r.namespace : r.origType,
              r.selector,
              r.handler,
            ),
            this
          );
        if ("object" != typeof e)
          return (
            (!1 !== t && "function" != typeof t) || ((n = t), (t = void 0)),
            !1 === n && (n = we),
            this.each(function () {
              C.event.remove(this, e, n, t);
            })
          );
        for (i in e) this.off(i, t, e[i]);
        return this;
      },
    }));
  var Se = /<script|<style|<link/i,
    Ee = /checked\s*(?:[^=]|=\s*.checked.)/i,
    Ie = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;
  function Ae(e, t) {
    return (
      (E(e, "table") &&
        E(11 !== t.nodeType ? t : t.firstChild, "tr") &&
        C(e).children("tbody")[0]) ||
      e
    );
  }
  function ke(e) {
    return ((e.type = (null !== e.getAttribute("type")) + "/" + e.type), e);
  }
  function De(e) {
    return (
      "true/" === (e.type || "").slice(0, 5)
        ? (e.type = e.type.slice(5))
        : e.removeAttribute("type"),
      e
    );
  }
  function Le(e, t) {
    var n, r, i, o;
    if (1 === t.nodeType) {
      if (J.hasData(e) && (o = J.get(e).events))
        for (i in (J.remove(t, "handle events"), o))
          for (n = 0, r = o[i].length; n < r; n++) C.event.add(t, i, o[i][n]);
      Y.hasData(e) && ((e = Y.access(e)), (e = C.extend({}, e)), Y.set(t, e));
    }
  }
  function je(n, r, i, o) {
    r = v(r);
    var e,
      t,
      a,
      s,
      c,
      d,
      l = 0,
      u = n.length,
      h = u - 1,
      p = r[0],
      f = g(p);
    if (f || (1 < u && "string" == typeof p && !b.checkClone && Ee.test(p)))
      return n.each(function (e) {
        var t = n.eq(e);
        (f && (r[0] = p.call(this, e, t.html())), je(t, r, i, o));
      });
    if (
      u &&
      ((t = (e = ve(r, n[0].ownerDocument, !1, n, o)).firstChild),
      1 === e.childNodes.length && (e = t),
      t || o)
    ) {
      for (s = (a = C.map(fe(e, "script"), ke)).length; l < u; l++)
        ((c = e),
          l !== h &&
            ((c = C.clone(c, !0, !0)), s && C.merge(a, fe(c, "script"))),
          i.call(n[l], c, l));
      if (s)
        for (d = a[a.length - 1].ownerDocument, C.map(a, De), l = 0; l < s; l++)
          ((c = a[l]),
            he.test(c.type || "") &&
              !J.access(c, "globalEval") &&
              C.contains(d, c) &&
              (c.src && "module" !== (c.type || "").toLowerCase()
                ? C._evalUrl &&
                  !c.noModule &&
                  C._evalUrl(
                    c.src,
                    { nonce: c.nonce || c.getAttribute("nonce") },
                    d,
                  )
                : P(c.textContent.replace(Ie, ""), c, d)));
    }
    return n;
  }
  function Ne(e, t, n) {
    for (var r, i = t ? C.filter(t, e) : e, o = 0; null != (r = i[o]); o++)
      (n || 1 !== r.nodeType || C.cleanData(fe(r)),
        r.parentNode &&
          (n && ie(r) && ge(fe(r, "script")), r.parentNode.removeChild(r)));
    return e;
  }
  (C.extend({
    htmlPrefilter: function (e) {
      return e;
    },
    clone: function (e, t, n) {
      var r,
        i,
        o,
        a,
        s,
        c,
        d,
        l = e.cloneNode(!0),
        u = ie(e);
      if (
        !(
          b.noCloneChecked ||
          (1 !== e.nodeType && 11 !== e.nodeType) ||
          C.isXMLDoc(e)
        )
      )
        for (a = fe(l), r = 0, i = (o = fe(e)).length; r < i; r++)
          ((s = o[r]),
            "input" === (d = (c = a[r]).nodeName.toLowerCase()) &&
            le.test(s.type)
              ? (c.checked = s.checked)
              : ("input" !== d && "textarea" !== d) ||
                (c.defaultValue = s.defaultValue));
      if (t)
        if (n)
          for (o = o || fe(e), a = a || fe(l), r = 0, i = o.length; r < i; r++)
            Le(o[r], a[r]);
        else Le(e, l);
      return (
        0 < (a = fe(l, "script")).length && ge(a, !u && fe(e, "script")),
        l
      );
    },
    cleanData: function (e) {
      for (var t, n, r, i = C.event.special, o = 0; void 0 !== (n = e[o]); o++)
        if (X(n)) {
          if ((t = n[J.expando])) {
            if (t.events)
              for (r in t.events)
                i[r] ? C.event.remove(n, r) : C.removeEvent(n, r, t.handle);
            n[J.expando] = void 0;
          }
          n[Y.expando] && (n[Y.expando] = void 0);
        }
    },
  }),
    C.fn.extend({
      detach: function (e) {
        return Ne(this, e, !0);
      },
      remove: function (e) {
        return Ne(this, e);
      },
      text: function (e) {
        return z(
          this,
          function (e) {
            return void 0 === e
              ? C.text(this)
              : this.empty().each(function () {
                  (1 !== this.nodeType &&
                    11 !== this.nodeType &&
                    9 !== this.nodeType) ||
                    (this.textContent = e);
                });
          },
          null,
          e,
          arguments.length,
        );
      },
      append: function () {
        return je(this, arguments, function (e) {
          (1 !== this.nodeType &&
            11 !== this.nodeType &&
            9 !== this.nodeType) ||
            Ae(this, e).appendChild(e);
        });
      },
      prepend: function () {
        return je(this, arguments, function (e) {
          var t;
          (1 !== this.nodeType &&
            11 !== this.nodeType &&
            9 !== this.nodeType) ||
            (t = Ae(this, e)).insertBefore(e, t.firstChild);
        });
      },
      before: function () {
        return je(this, arguments, function (e) {
          this.parentNode && this.parentNode.insertBefore(e, this);
        });
      },
      after: function () {
        return je(this, arguments, function (e) {
          this.parentNode && this.parentNode.insertBefore(e, this.nextSibling);
        });
      },
      empty: function () {
        for (var e, t = 0; null != (e = this[t]); t++)
          1 === e.nodeType && (C.cleanData(fe(e, !1)), (e.textContent = ""));
        return this;
      },
      clone: function (e, t) {
        return (
          (e = null != e && e),
          (t = null == t ? e : t),
          this.map(function () {
            return C.clone(this, e, t);
          })
        );
      },
      html: function (e) {
        return z(
          this,
          function (e) {
            var t = this[0] || {},
              n = 0,
              r = this.length;
            if (void 0 === e && 1 === t.nodeType) return t.innerHTML;
            if (
              "string" == typeof e &&
              !Se.test(e) &&
              !pe[(ue.exec(e) || ["", ""])[1].toLowerCase()]
            ) {
              e = C.htmlPrefilter(e);
              try {
                for (; n < r; n++)
                  1 === (t = this[n] || {}).nodeType &&
                    (C.cleanData(fe(t, !1)), (t.innerHTML = e));
                t = 0;
              } catch (e) {}
            }
            t && this.empty().append(e);
          },
          null,
          e,
          arguments.length,
        );
      },
      replaceWith: function () {
        var n = [];
        return je(
          this,
          arguments,
          function (e) {
            var t = this.parentNode;
            C.inArray(this, n) < 0 &&
              (C.cleanData(fe(this)), t && t.replaceChild(e, this));
          },
          n,
        );
      },
    }),
    C.each(
      {
        appendTo: "append",
        prependTo: "prepend",
        insertBefore: "before",
        insertAfter: "after",
        replaceAll: "replaceWith",
      },
      function (e, a) {
        C.fn[e] = function (e) {
          for (var t, n = [], r = C(e), i = r.length - 1, o = 0; o <= i; o++)
            ((t = o === i ? this : this.clone(!0)),
              C(r[o])[a](t),
              c.apply(n, t.get()));
          return this.pushStack(n);
        };
      },
    ));
  function $e(e) {
    var t = e.ownerDocument.defaultView;
    return (t = !t || !t.opener ? w : t).getComputedStyle(e);
  }
  function Me(e, t, n) {
    var r,
      i = {};
    for (r in t) ((i[r] = e.style[r]), (e.style[r] = t[r]));
    for (r in ((n = n.call(e)), t)) e.style[r] = i[r];
    return n;
  }
  var Oe,
    Be,
    Re,
    qe,
    Fe,
    ze,
    Qe,
    Ue,
    We = new RegExp("^(" + ee + ")(?!px)[a-z%]+$", "i"),
    Ve = new RegExp(ne.join("|"), "i");
  function Xe(e, t, n) {
    var r,
      i,
      o = e.style;
    return (
      (n = n || $e(e)) &&
        ("" !== (i = n.getPropertyValue(t) || n[t]) ||
          ie(e) ||
          (i = C.style(e, t)),
        !b.pixelBoxStyles() &&
          We.test(i) &&
          Ve.test(t) &&
          ((r = o.width),
          (e = o.minWidth),
          (t = o.maxWidth),
          (o.minWidth = o.maxWidth = o.width = i),
          (i = n.width),
          (o.width = r),
          (o.minWidth = e),
          (o.maxWidth = t))),
      void 0 !== i ? i + "" : i
    );
  }
  function _e(e, t) {
    return {
      get: function () {
        if (!e()) return (this.get = t).apply(this, arguments);
        delete this.get;
      },
    };
  }
  function Je() {
    var e;
    Ue &&
      ((Qe.style.cssText =
        "position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0"),
      (Ue.style.cssText =
        "position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%"),
      re.appendChild(Qe).appendChild(Ue),
      (e = w.getComputedStyle(Ue)),
      (Oe = "1%" !== e.top),
      (ze = 12 === Ye(e.marginLeft)),
      (Ue.style.right = "60%"),
      (qe = 36 === Ye(e.right)),
      (Be = 36 === Ye(e.width)),
      (Ue.style.position = "absolute"),
      (Re = 12 === Ye(Ue.offsetWidth / 3)),
      re.removeChild(Qe),
      (Ue = null));
  }
  function Ye(e) {
    return Math.round(parseFloat(e));
  }
  ((Qe = H.createElement("div")),
    (Ue = H.createElement("div")).style &&
      ((Ue.style.backgroundClip = "content-box"),
      (Ue.cloneNode(!0).style.backgroundClip = ""),
      (b.clearCloneStyle = "content-box" === Ue.style.backgroundClip),
      C.extend(b, {
        boxSizingReliable: function () {
          return (Je(), Be);
        },
        pixelBoxStyles: function () {
          return (Je(), qe);
        },
        pixelPosition: function () {
          return (Je(), Oe);
        },
        reliableMarginLeft: function () {
          return (Je(), ze);
        },
        scrollboxSize: function () {
          return (Je(), Re);
        },
        reliableTrDimensions: function () {
          var e, t, n;
          return (
            null == Fe &&
              ((e = H.createElement("table")),
              (n = H.createElement("tr")),
              (t = H.createElement("div")),
              (e.style.cssText = "position:absolute;left:-11111px"),
              (n.style.height = "1px"),
              (t.style.height = "9px"),
              re.appendChild(e).appendChild(n).appendChild(t),
              (n = w.getComputedStyle(n)),
              (Fe = 3 < parseInt(n.height)),
              re.removeChild(e)),
            Fe
          );
        },
      })));
  var Ge = ["Webkit", "Moz", "ms"],
    Ke = H.createElement("div").style,
    Ze = {};
  function et(e) {
    return (
      C.cssProps[e] ||
      Ze[e] ||
      (e in Ke
        ? e
        : (Ze[e] =
            (function (e) {
              for (
                var t = e[0].toUpperCase() + e.slice(1), n = Ge.length;
                n--;
              )
                if ((e = Ge[n] + t) in Ke) return e;
            })(e) || e))
    );
  }
  var tt = /^(none|table(?!-c[ea]).+)/,
    nt = /^--/,
    rt = { position: "absolute", visibility: "hidden", display: "block" },
    it = { letterSpacing: "0", fontWeight: "400" };
  function ot(e, t, n) {
    var r = te.exec(t);
    return r ? Math.max(0, r[2] - (n || 0)) + (r[3] || "px") : t;
  }
  function at(e, t, n, r, i, o) {
    var a = "width" === t ? 1 : 0,
      s = 0,
      c = 0;
    if (n === (r ? "border" : "content")) return 0;
    for (; a < 4; a += 2)
      ("margin" === n && (c += C.css(e, n + ne[a], !0, i)),
        r
          ? ("content" === n && (c -= C.css(e, "padding" + ne[a], !0, i)),
            "margin" !== n &&
              (c -= C.css(e, "border" + ne[a] + "Width", !0, i)))
          : ((c += C.css(e, "padding" + ne[a], !0, i)),
            "padding" !== n
              ? (c += C.css(e, "border" + ne[a] + "Width", !0, i))
              : (s += C.css(e, "border" + ne[a] + "Width", !0, i))));
    return (
      !r &&
        0 <= o &&
        (c +=
          Math.max(
            0,
            Math.ceil(
              e["offset" + t[0].toUpperCase() + t.slice(1)] - o - c - s - 0.5,
            ),
          ) || 0),
      c
    );
  }
  function st(e, t, n) {
    var r = $e(e),
      i =
        (!b.boxSizingReliable() || n) &&
        "border-box" === C.css(e, "boxSizing", !1, r),
      o = i,
      a = Xe(e, t, r),
      s = "offset" + t[0].toUpperCase() + t.slice(1);
    if (We.test(a)) {
      if (!n) return a;
      a = "auto";
    }
    return (
      ((!b.boxSizingReliable() && i) ||
        (!b.reliableTrDimensions() && E(e, "tr")) ||
        "auto" === a ||
        (!parseFloat(a) && "inline" === C.css(e, "display", !1, r))) &&
        e.getClientRects().length &&
        ((i = "border-box" === C.css(e, "boxSizing", !1, r)),
        (o = s in e) && (a = e[s])),
      (a = parseFloat(a) || 0) +
        at(e, t, n || (i ? "border" : "content"), o, r, a) +
        "px"
    );
  }
  function ct(e, t, n, r, i) {
    return new ct.prototype.init(e, t, n, r, i);
  }
  (C.extend({
    cssHooks: {
      opacity: {
        get: function (e, t) {
          if (t) {
            e = Xe(e, "opacity");
            return "" === e ? "1" : e;
          }
        },
      },
    },
    cssNumber: {
      animationIterationCount: !0,
      columnCount: !0,
      fillOpacity: !0,
      flexGrow: !0,
      flexShrink: !0,
      fontWeight: !0,
      gridArea: !0,
      gridColumn: !0,
      gridColumnEnd: !0,
      gridColumnStart: !0,
      gridRow: !0,
      gridRowEnd: !0,
      gridRowStart: !0,
      lineHeight: !0,
      opacity: !0,
      order: !0,
      orphans: !0,
      widows: !0,
      zIndex: !0,
      zoom: !0,
    },
    cssProps: {},
    style: function (e, t, n, r) {
      if (e && 3 !== e.nodeType && 8 !== e.nodeType && e.style) {
        var i,
          o,
          a,
          s = V(t),
          c = nt.test(t),
          d = e.style;
        if (
          (c || (t = et(s)), (a = C.cssHooks[t] || C.cssHooks[s]), void 0 === n)
        )
          return a && "get" in a && void 0 !== (i = a.get(e, !1, r)) ? i : d[t];
        ("string" == (o = typeof n) &&
          (i = te.exec(n)) &&
          i[1] &&
          ((n = se(e, t, i)), (o = "number")),
          null != n &&
            n == n &&
            ("number" !== o ||
              c ||
              (n += (i && i[3]) || (C.cssNumber[s] ? "" : "px")),
            b.clearCloneStyle ||
              "" !== n ||
              0 !== t.indexOf("background") ||
              (d[t] = "inherit"),
            (a && "set" in a && void 0 === (n = a.set(e, n, r))) ||
              (c ? d.setProperty(t, n) : (d[t] = n))));
      }
    },
    css: function (e, t, n, r) {
      var i,
        o = V(t);
      return (
        nt.test(t) || (t = et(o)),
        "normal" ===
          (i =
            void 0 ===
            (i =
              (o = C.cssHooks[t] || C.cssHooks[o]) && "get" in o
                ? o.get(e, !0, n)
                : i)
              ? Xe(e, t, r)
              : i) &&
          t in it &&
          (i = it[t]),
        "" === n || n
          ? ((t = parseFloat(i)), !0 === n || isFinite(t) ? t || 0 : i)
          : i
      );
    },
  }),
    C.each(["height", "width"], function (e, s) {
      C.cssHooks[s] = {
        get: function (e, t, n) {
          if (t)
            return !tt.test(C.css(e, "display")) ||
              (e.getClientRects().length && e.getBoundingClientRect().width)
              ? st(e, s, n)
              : Me(e, rt, function () {
                  return st(e, s, n);
                });
        },
        set: function (e, t, n) {
          var r,
            i = $e(e),
            o = !b.scrollboxSize() && "absolute" === i.position,
            a = (o || n) && "border-box" === C.css(e, "boxSizing", !1, i),
            n = n ? at(e, s, n, a, i) : 0;
          return (
            a &&
              o &&
              (n -= Math.ceil(
                e["offset" + s[0].toUpperCase() + s.slice(1)] -
                  parseFloat(i[s]) -
                  at(e, s, "border", !1, i) -
                  0.5,
              )),
            n &&
              (r = te.exec(t)) &&
              "px" !== (r[3] || "px") &&
              ((e.style[s] = t), (t = C.css(e, s))),
            ot(0, t, n)
          );
        },
      };
    }),
    (C.cssHooks.marginLeft = _e(b.reliableMarginLeft, function (e, t) {
      if (t)
        return (
          (parseFloat(Xe(e, "marginLeft")) ||
            e.getBoundingClientRect().left -
              Me(e, { marginLeft: 0 }, function () {
                return e.getBoundingClientRect().left;
              })) + "px"
        );
    })),
    C.each({ margin: "", padding: "", border: "Width" }, function (i, o) {
      ((C.cssHooks[i + o] = {
        expand: function (e) {
          for (
            var t = 0, n = {}, r = "string" == typeof e ? e.split(" ") : [e];
            t < 4;
            t++
          )
            n[i + ne[t] + o] = r[t] || r[t - 2] || r[0];
          return n;
        },
      }),
        "margin" !== i && (C.cssHooks[i + o].set = ot));
    }),
    C.fn.extend({
      css: function (e, t) {
        return z(
          this,
          function (e, t, n) {
            var r,
              i,
              o = {},
              a = 0;
            if (Array.isArray(t)) {
              for (r = $e(e), i = t.length; a < i; a++)
                o[t[a]] = C.css(e, t[a], !1, r);
              return o;
            }
            return void 0 !== n ? C.style(e, t, n) : C.css(e, t);
          },
          e,
          t,
          1 < arguments.length,
        );
      },
    }),
    (((C.Tween = ct).prototype = {
      constructor: ct,
      init: function (e, t, n, r, i, o) {
        ((this.elem = e),
          (this.prop = n),
          (this.easing = i || C.easing._default),
          (this.options = t),
          (this.start = this.now = this.cur()),
          (this.end = r),
          (this.unit = o || (C.cssNumber[n] ? "" : "px")));
      },
      cur: function () {
        var e = ct.propHooks[this.prop];
        return (e && e.get ? e : ct.propHooks._default).get(this);
      },
      run: function (e) {
        var t,
          n = ct.propHooks[this.prop];
        return (
          this.options.duration
            ? (this.pos = t =
                C.easing[this.easing](
                  e,
                  this.options.duration * e,
                  0,
                  1,
                  this.options.duration,
                ))
            : (this.pos = t = e),
          (this.now = (this.end - this.start) * t + this.start),
          this.options.step &&
            this.options.step.call(this.elem, this.now, this),
          (n && n.set ? n : ct.propHooks._default).set(this),
          this
        );
      },
    }).init.prototype = ct.prototype),
    ((ct.propHooks = {
      _default: {
        get: function (e) {
          return 1 !== e.elem.nodeType ||
            (null != e.elem[e.prop] && null == e.elem.style[e.prop])
            ? e.elem[e.prop]
            : (e = C.css(e.elem, e.prop, "")) && "auto" !== e
              ? e
              : 0;
        },
        set: function (e) {
          C.fx.step[e.prop]
            ? C.fx.step[e.prop](e)
            : 1 !== e.elem.nodeType ||
                (!C.cssHooks[e.prop] && null == e.elem.style[et(e.prop)])
              ? (e.elem[e.prop] = e.now)
              : C.style(e.elem, e.prop, e.now + e.unit);
        },
      },
    }).scrollTop = ct.propHooks.scrollLeft =
      {
        set: function (e) {
          e.elem.nodeType && e.elem.parentNode && (e.elem[e.prop] = e.now);
        },
      }),
    (C.easing = {
      linear: function (e) {
        return e;
      },
      swing: function (e) {
        return 0.5 - Math.cos(e * Math.PI) / 2;
      },
      _default: "swing",
    }),
    (C.fx = ct.prototype.init),
    (C.fx.step = {}));
  var dt,
    lt,
    ut = /^(?:toggle|show|hide)$/,
    ht = /queueHooks$/;
  function pt() {
    lt &&
      (!1 === H.hidden && w.requestAnimationFrame
        ? w.requestAnimationFrame(pt)
        : w.setTimeout(pt, C.fx.interval),
      C.fx.tick());
  }
  function ft() {
    return (
      w.setTimeout(function () {
        dt = void 0;
      }),
      (dt = Date.now())
    );
  }
  function gt(e, t) {
    var n,
      r = 0,
      i = { height: e };
    for (t = t ? 1 : 0; r < 4; r += 2 - t)
      i["margin" + (n = ne[r])] = i["padding" + n] = e;
    return (t && (i.opacity = i.width = e), i);
  }
  function mt(e, t, n) {
    for (
      var r,
        i = (vt.tweeners[t] || []).concat(vt.tweeners["*"]),
        o = 0,
        a = i.length;
      o < a;
      o++
    )
      if ((r = i[o].call(n, t, e))) return r;
  }
  function vt(i, e, t) {
    var n,
      o,
      r = 0,
      a = vt.prefilters.length,
      s = C.Deferred().always(function () {
        delete c.elem;
      }),
      c = function () {
        if (o) return !1;
        for (
          var e = dt || ft(),
            e = Math.max(0, d.startTime + d.duration - e),
            t = 1 - (e / d.duration || 0),
            n = 0,
            r = d.tweens.length;
          n < r;
          n++
        )
          d.tweens[n].run(t);
        return (
          s.notifyWith(i, [d, t, e]),
          t < 1 && r
            ? e
            : (r || s.notifyWith(i, [d, 1, 0]), s.resolveWith(i, [d]), !1)
        );
      },
      d = s.promise({
        elem: i,
        props: C.extend({}, e),
        opts: C.extend(!0, { specialEasing: {}, easing: C.easing._default }, t),
        originalProperties: e,
        originalOptions: t,
        startTime: dt || ft(),
        duration: t.duration,
        tweens: [],
        createTween: function (e, t) {
          e = C.Tween(
            i,
            d.opts,
            e,
            t,
            d.opts.specialEasing[e] || d.opts.easing,
          );
          return (d.tweens.push(e), e);
        },
        stop: function (e) {
          var t = 0,
            n = e ? d.tweens.length : 0;
          if (o) return this;
          for (o = !0; t < n; t++) d.tweens[t].run(1);
          return (
            e
              ? (s.notifyWith(i, [d, 1, 0]), s.resolveWith(i, [d, e]))
              : s.rejectWith(i, [d, e]),
            this
          );
        },
      }),
      l = d.props;
    for (
      (function (e, t) {
        var n, r, i, o, a;
        for (n in e)
          if (
            ((i = t[(r = V(n))]),
            (o = e[n]),
            Array.isArray(o) && ((i = o[1]), (o = e[n] = o[0])),
            n !== r && ((e[r] = o), delete e[n]),
            (a = C.cssHooks[r]) && ("expand" in a))
          )
            for (n in ((o = a.expand(o)), delete e[r], o))
              (n in e) || ((e[n] = o[n]), (t[n] = i));
          else t[r] = i;
      })(l, d.opts.specialEasing);
      r < a;
      r++
    )
      if ((n = vt.prefilters[r].call(d, i, l, d.opts)))
        return (
          g(n.stop) &&
            (C._queueHooks(d.elem, d.opts.queue).stop = n.stop.bind(n)),
          n
        );
    return (
      C.map(l, mt, d),
      g(d.opts.start) && d.opts.start.call(i, d),
      d
        .progress(d.opts.progress)
        .done(d.opts.done, d.opts.complete)
        .fail(d.opts.fail)
        .always(d.opts.always),
      C.fx.timer(C.extend(c, { elem: i, anim: d, queue: d.opts.queue })),
      d
    );
  }
  ((C.Animation = C.extend(vt, {
    tweeners: {
      "*": [
        function (e, t) {
          var n = this.createTween(e, t);
          return (se(n.elem, e, te.exec(t), n), n);
        },
      ],
    },
    tweener: function (e, t) {
      for (
        var n, r = 0, i = (e = g(e) ? ((t = e), ["*"]) : e.match($)).length;
        r < i;
        r++
      )
        ((n = e[r]),
          (vt.tweeners[n] = vt.tweeners[n] || []),
          vt.tweeners[n].unshift(t));
    },
    prefilters: [
      function (e, t, n) {
        var r,
          i,
          o,
          a,
          s,
          c,
          d,
          l = "width" in t || "height" in t,
          u = this,
          h = {},
          p = e.style,
          f = e.nodeType && ae(e),
          g = J.get(e, "fxshow");
        for (r in (n.queue ||
          (null == (a = C._queueHooks(e, "fx")).unqueued &&
            ((a.unqueued = 0),
            (s = a.empty.fire),
            (a.empty.fire = function () {
              a.unqueued || s();
            })),
          a.unqueued++,
          u.always(function () {
            u.always(function () {
              (a.unqueued--, C.queue(e, "fx").length || a.empty.fire());
            });
          })),
        t))
          if (((i = t[r]), ut.test(i))) {
            if (
              (delete t[r],
              (o = o || "toggle" === i),
              i === (f ? "hide" : "show"))
            ) {
              if ("show" !== i || !g || void 0 === g[r]) continue;
              f = !0;
            }
            h[r] = (g && g[r]) || C.style(e, r);
          }
        if ((c = !C.isEmptyObject(t)) || !C.isEmptyObject(h))
          for (r in (l &&
            1 === e.nodeType &&
            ((n.overflow = [p.overflow, p.overflowX, p.overflowY]),
            null == (d = g && g.display) && (d = J.get(e, "display")),
            "none" === (l = C.css(e, "display")) &&
              (d
                ? (l = d)
                : (de([e], !0),
                  (d = e.style.display || d),
                  (l = C.css(e, "display")),
                  de([e]))),
            ("inline" === l || ("inline-block" === l && null != d)) &&
              "none" === C.css(e, "float") &&
              (c ||
                (u.done(function () {
                  p.display = d;
                }),
                null == d && ((l = p.display), (d = "none" === l ? "" : l))),
              (p.display = "inline-block"))),
          n.overflow &&
            ((p.overflow = "hidden"),
            u.always(function () {
              ((p.overflow = n.overflow[0]),
                (p.overflowX = n.overflow[1]),
                (p.overflowY = n.overflow[2]));
            })),
          (c = !1),
          h))
            (c ||
              (g
                ? "hidden" in g && (f = g.hidden)
                : (g = J.access(e, "fxshow", { display: d })),
              o && (g.hidden = !f),
              f && de([e], !0),
              u.done(function () {
                for (r in (f || de([e]), J.remove(e, "fxshow"), h))
                  C.style(e, r, h[r]);
              })),
              (c = mt(f ? g[r] : 0, r, u)),
              r in g ||
                ((g[r] = c.start), f && ((c.end = c.start), (c.start = 0))));
      },
    ],
    prefilter: function (e, t) {
      t ? vt.prefilters.unshift(e) : vt.prefilters.push(e);
    },
  })),
    (C.speed = function (e, t, n) {
      var r =
        e && "object" == typeof e
          ? C.extend({}, e)
          : {
              complete: n || (!n && t) || (g(e) && e),
              duration: e,
              easing: (n && t) || (t && !g(t) && t),
            };
      return (
        C.fx.off
          ? (r.duration = 0)
          : "number" != typeof r.duration &&
            (r.duration in C.fx.speeds
              ? (r.duration = C.fx.speeds[r.duration])
              : (r.duration = C.fx.speeds._default)),
        (null != r.queue && !0 !== r.queue) || (r.queue = "fx"),
        (r.old = r.complete),
        (r.complete = function () {
          (g(r.old) && r.old.call(this), r.queue && C.dequeue(this, r.queue));
        }),
        r
      );
    }),
    C.fn.extend({
      fadeTo: function (e, t, n, r) {
        return this.filter(ae)
          .css("opacity", 0)
          .show()
          .end()
          .animate({ opacity: t }, e, n, r);
      },
      animate: function (t, e, n, r) {
        function i() {
          var e = vt(this, C.extend({}, t), a);
          (o || J.get(this, "finish")) && e.stop(!0);
        }
        var o = C.isEmptyObject(t),
          a = C.speed(e, n, r);
        return (
          (i.finish = i),
          o || !1 === a.queue ? this.each(i) : this.queue(a.queue, i)
        );
      },
      stop: function (i, e, o) {
        function a(e) {
          var t = e.stop;
          (delete e.stop, t(o));
        }
        return (
          "string" != typeof i && ((o = e), (e = i), (i = void 0)),
          e && this.queue(i || "fx", []),
          this.each(function () {
            var e = !0,
              t = null != i && i + "queueHooks",
              n = C.timers,
              r = J.get(this);
            if (t) r[t] && r[t].stop && a(r[t]);
            else for (t in r) r[t] && r[t].stop && ht.test(t) && a(r[t]);
            for (t = n.length; t--; )
              n[t].elem !== this ||
                (null != i && n[t].queue !== i) ||
                (n[t].anim.stop(o), (e = !1), n.splice(t, 1));
            (!e && o) || C.dequeue(this, i);
          })
        );
      },
      finish: function (a) {
        return (
          !1 !== a && (a = a || "fx"),
          this.each(function () {
            var e,
              t = J.get(this),
              n = t[a + "queue"],
              r = t[a + "queueHooks"],
              i = C.timers,
              o = n ? n.length : 0;
            for (
              t.finish = !0,
                C.queue(this, a, []),
                r && r.stop && r.stop.call(this, !0),
                e = i.length;
              e--;
            )
              i[e].elem === this &&
                i[e].queue === a &&
                (i[e].anim.stop(!0), i.splice(e, 1));
            for (e = 0; e < o; e++)
              n[e] && n[e].finish && n[e].finish.call(this);
            delete t.finish;
          })
        );
      },
    }),
    C.each(["toggle", "show", "hide"], function (e, r) {
      var i = C.fn[r];
      C.fn[r] = function (e, t, n) {
        return null == e || "boolean" == typeof e
          ? i.apply(this, arguments)
          : this.animate(gt(r, !0), e, t, n);
      };
    }),
    C.each(
      {
        slideDown: gt("show"),
        slideUp: gt("hide"),
        slideToggle: gt("toggle"),
        fadeIn: { opacity: "show" },
        fadeOut: { opacity: "hide" },
        fadeToggle: { opacity: "toggle" },
      },
      function (e, r) {
        C.fn[e] = function (e, t, n) {
          return this.animate(r, e, t, n);
        };
      },
    ),
    (C.timers = []),
    (C.fx.tick = function () {
      var e,
        t = 0,
        n = C.timers;
      for (dt = Date.now(); t < n.length; t++)
        (e = n[t])() || n[t] !== e || n.splice(t--, 1);
      (n.length || C.fx.stop(), (dt = void 0));
    }),
    (C.fx.timer = function (e) {
      (C.timers.push(e), C.fx.start());
    }),
    (C.fx.interval = 13),
    (C.fx.start = function () {
      lt || ((lt = !0), pt());
    }),
    (C.fx.stop = function () {
      lt = null;
    }),
    (C.fx.speeds = { slow: 600, fast: 200, _default: 400 }),
    (C.fn.delay = function (r, e) {
      return (
        (r = (C.fx && C.fx.speeds[r]) || r),
        this.queue((e = e || "fx"), function (e, t) {
          var n = w.setTimeout(e, r);
          t.stop = function () {
            w.clearTimeout(n);
          };
        })
      );
    }),
    (u = H.createElement("input")),
    (ee = H.createElement("select").appendChild(H.createElement("option"))),
    (u.type = "checkbox"),
    (b.checkOn = "" !== u.value),
    (b.optSelected = ee.selected),
    ((u = H.createElement("input")).value = "t"),
    (u.type = "radio"),
    (b.radioValue = "t" === u.value));
  var yt,
    bt = C.expr.attrHandle;
  (C.fn.extend({
    attr: function (e, t) {
      return z(this, C.attr, e, t, 1 < arguments.length);
    },
    removeAttr: function (e) {
      return this.each(function () {
        C.removeAttr(this, e);
      });
    },
  }),
    C.extend({
      attr: function (e, t, n) {
        var r,
          i,
          o = e.nodeType;
        if (3 !== o && 8 !== o && 2 !== o)
          return void 0 === e.getAttribute
            ? C.prop(e, t, n)
            : ((1 === o && C.isXMLDoc(e)) ||
                (i =
                  C.attrHooks[t.toLowerCase()] ||
                  (C.expr.match.bool.test(t) ? yt : void 0)),
              void 0 !== n
                ? null === n
                  ? void C.removeAttr(e, t)
                  : i && "set" in i && void 0 !== (r = i.set(e, n, t))
                    ? r
                    : (e.setAttribute(t, n + ""), n)
                : !(i && "get" in i && null !== (r = i.get(e, t))) &&
                    null == (r = C.find.attr(e, t))
                  ? void 0
                  : r);
      },
      attrHooks: {
        type: {
          set: function (e, t) {
            if (!b.radioValue && "radio" === t && E(e, "input")) {
              var n = e.value;
              return (e.setAttribute("type", t), n && (e.value = n), t);
            }
          },
        },
      },
      removeAttr: function (e, t) {
        var n,
          r = 0,
          i = t && t.match($);
        if (i && 1 === e.nodeType) for (; (n = i[r++]); ) e.removeAttribute(n);
      },
    }),
    (yt = {
      set: function (e, t, n) {
        return (!1 === t ? C.removeAttr(e, n) : e.setAttribute(n, n), n);
      },
    }),
    C.each(C.expr.match.bool.source.match(/\w+/g), function (e, t) {
      var a = bt[t] || C.find.attr;
      bt[t] = function (e, t, n) {
        var r,
          i,
          o = t.toLowerCase();
        return (
          n ||
            ((i = bt[o]),
            (bt[o] = r),
            (r = null != a(e, t, n) ? o : null),
            (bt[o] = i)),
          r
        );
      };
    }));
  var Pt = /^(?:input|select|textarea|button)$/i,
    xt = /^(?:a|area)$/i;
  function wt(e) {
    return (e.match($) || []).join(" ");
  }
  function Ht(e) {
    return (e.getAttribute && e.getAttribute("class")) || "";
  }
  function Ct(e) {
    return Array.isArray(e) ? e : ("string" == typeof e && e.match($)) || [];
  }
  (C.fn.extend({
    prop: function (e, t) {
      return z(this, C.prop, e, t, 1 < arguments.length);
    },
    removeProp: function (e) {
      return this.each(function () {
        delete this[C.propFix[e] || e];
      });
    },
  }),
    C.extend({
      prop: function (e, t, n) {
        var r,
          i,
          o = e.nodeType;
        if (3 !== o && 8 !== o && 2 !== o)
          return (
            (1 === o && C.isXMLDoc(e)) ||
              ((t = C.propFix[t] || t), (i = C.propHooks[t])),
            void 0 !== n
              ? i && "set" in i && void 0 !== (r = i.set(e, n, t))
                ? r
                : (e[t] = n)
              : i && "get" in i && null !== (r = i.get(e, t))
                ? r
                : e[t]
          );
      },
      propHooks: {
        tabIndex: {
          get: function (e) {
            var t = C.find.attr(e, "tabindex");
            return t
              ? parseInt(t, 10)
              : Pt.test(e.nodeName) || (xt.test(e.nodeName) && e.href)
                ? 0
                : -1;
          },
        },
      },
      propFix: { for: "htmlFor", class: "className" },
    }),
    b.optSelected ||
      (C.propHooks.selected = {
        get: function (e) {
          e = e.parentNode;
          return (e && e.parentNode && e.parentNode.selectedIndex, null);
        },
        set: function (e) {
          e = e.parentNode;
          e && (e.selectedIndex, e.parentNode && e.parentNode.selectedIndex);
        },
      }),
    C.each(
      [
        "tabIndex",
        "readOnly",
        "maxLength",
        "cellSpacing",
        "cellPadding",
        "rowSpan",
        "colSpan",
        "useMap",
        "frameBorder",
        "contentEditable",
      ],
      function () {
        C.propFix[this.toLowerCase()] = this;
      },
    ),
    C.fn.extend({
      addClass: function (t) {
        var e,
          n,
          r,
          i,
          o,
          a,
          s = 0;
        if (g(t))
          return this.each(function (e) {
            C(this).addClass(t.call(this, e, Ht(this)));
          });
        if ((e = Ct(t)).length)
          for (; (n = this[s++]); )
            if (((a = Ht(n)), (r = 1 === n.nodeType && " " + wt(a) + " "))) {
              for (o = 0; (i = e[o++]); )
                r.indexOf(" " + i + " ") < 0 && (r += i + " ");
              a !== (a = wt(r)) && n.setAttribute("class", a);
            }
        return this;
      },
      removeClass: function (t) {
        var e,
          n,
          r,
          i,
          o,
          a,
          s = 0;
        if (g(t))
          return this.each(function (e) {
            C(this).removeClass(t.call(this, e, Ht(this)));
          });
        if (!arguments.length) return this.attr("class", "");
        if ((e = Ct(t)).length)
          for (; (n = this[s++]); )
            if (((a = Ht(n)), (r = 1 === n.nodeType && " " + wt(a) + " "))) {
              for (o = 0; (i = e[o++]); )
                for (; -1 < r.indexOf(" " + i + " "); )
                  r = r.replace(" " + i + " ", " ");
              a !== (a = wt(r)) && n.setAttribute("class", a);
            }
        return this;
      },
      toggleClass: function (i, t) {
        var o = typeof i,
          a = "string" == o || Array.isArray(i);
        return "boolean" == typeof t && a
          ? t
            ? this.addClass(i)
            : this.removeClass(i)
          : g(i)
            ? this.each(function (e) {
                C(this).toggleClass(i.call(this, e, Ht(this), t), t);
              })
            : this.each(function () {
                var e, t, n, r;
                if (a)
                  for (t = 0, n = C(this), r = Ct(i); (e = r[t++]); )
                    n.hasClass(e) ? n.removeClass(e) : n.addClass(e);
                else
                  (void 0 !== i && "boolean" != o) ||
                    ((e = Ht(this)) && J.set(this, "__className__", e),
                    this.setAttribute &&
                      this.setAttribute(
                        "class",
                        (!e && !1 !== i && J.get(this, "__className__")) || "",
                      ));
              });
      },
      hasClass: function (e) {
        for (var t, n = 0, r = " " + e + " "; (t = this[n++]); )
          if (1 === t.nodeType && -1 < (" " + wt(Ht(t)) + " ").indexOf(r))
            return !0;
        return !1;
      },
    }));
  var Tt = /\r/g;
  (C.fn.extend({
    val: function (t) {
      var n,
        e,
        r,
        i = this[0];
      return arguments.length
        ? ((r = g(t)),
          this.each(function (e) {
            1 === this.nodeType &&
              (null == (e = r ? t.call(this, e, C(this).val()) : t)
                ? (e = "")
                : "number" == typeof e
                  ? (e += "")
                  : Array.isArray(e) &&
                    (e = C.map(e, function (e) {
                      return null == e ? "" : e + "";
                    })),
              ((n =
                C.valHooks[this.type] ||
                C.valHooks[this.nodeName.toLowerCase()]) &&
                "set" in n &&
                void 0 !== n.set(this, e, "value")) ||
                (this.value = e));
          }))
        : i
          ? (n = C.valHooks[i.type] || C.valHooks[i.nodeName.toLowerCase()]) &&
            "get" in n &&
            void 0 !== (e = n.get(i, "value"))
            ? e
            : "string" == typeof (e = i.value)
              ? e.replace(Tt, "")
              : null == e
                ? ""
                : e
          : void 0;
    },
  }),
    C.extend({
      valHooks: {
        option: {
          get: function (e) {
            var t = C.find.attr(e, "value");
            return null != t ? t : wt(C.text(e));
          },
        },
        select: {
          get: function (e) {
            for (
              var t,
                n = e.options,
                r = e.selectedIndex,
                i = "select-one" === e.type,
                o = i ? null : [],
                a = i ? r + 1 : n.length,
                s = r < 0 ? a : i ? r : 0;
              s < a;
              s++
            )
              if (
                ((t = n[s]).selected || s === r) &&
                !t.disabled &&
                (!t.parentNode.disabled || !E(t.parentNode, "optgroup"))
              ) {
                if (((t = C(t).val()), i)) return t;
                o.push(t);
              }
            return o;
          },
          set: function (e, t) {
            for (
              var n, r, i = e.options, o = C.makeArray(t), a = i.length;
              a--;
            )
              ((r = i[a]).selected =
                -1 < C.inArray(C.valHooks.option.get(r), o)) && (n = !0);
            return (n || (e.selectedIndex = -1), o);
          },
        },
      },
    }),
    C.each(["radio", "checkbox"], function () {
      ((C.valHooks[this] = {
        set: function (e, t) {
          if (Array.isArray(t))
            return (e.checked = -1 < C.inArray(C(e).val(), t));
        },
      }),
        b.checkOn ||
          (C.valHooks[this].get = function (e) {
            return null === e.getAttribute("value") ? "on" : e.value;
          }));
    }),
    (b.focusin = "onfocusin" in w));
  function St(e) {
    e.stopPropagation();
  }
  var Et = /^(?:focusinfocus|focusoutblur)$/;
  (C.extend(C.event, {
    trigger: function (e, t, n, r) {
      var i,
        o,
        a,
        s,
        c,
        d,
        l,
        u = [n || H],
        h = y.call(e, "type") ? e.type : e,
        p = y.call(e, "namespace") ? e.namespace.split(".") : [],
        f = (l = o = n = n || H);
      if (
        3 !== n.nodeType &&
        8 !== n.nodeType &&
        !Et.test(h + C.event.triggered) &&
        (-1 < h.indexOf(".") && ((h = (p = h.split(".")).shift()), p.sort()),
        (s = h.indexOf(":") < 0 && "on" + h),
        ((e = e[C.expando]
          ? e
          : new C.Event(h, "object" == typeof e && e)).isTrigger = r ? 2 : 3),
        (e.namespace = p.join(".")),
        (e.rnamespace = e.namespace
          ? new RegExp("(^|\\.)" + p.join("\\.(?:.*\\.|)") + "(\\.|$)")
          : null),
        (e.result = void 0),
        e.target || (e.target = n),
        (t = null == t ? [e] : C.makeArray(t, [e])),
        (d = C.event.special[h] || {}),
        r || !d.trigger || !1 !== d.trigger.apply(n, t))
      ) {
        if (!r && !d.noBubble && !m(n)) {
          for (
            a = d.delegateType || h, Et.test(a + h) || (f = f.parentNode);
            f;
            f = f.parentNode
          )
            (u.push(f), (o = f));
          o === (n.ownerDocument || H) &&
            u.push(o.defaultView || o.parentWindow || w);
        }
        for (i = 0; (f = u[i++]) && !e.isPropagationStopped(); )
          ((l = f),
            (e.type = 1 < i ? a : d.bindType || h),
            (c =
              (J.get(f, "events") || Object.create(null))[e.type] &&
              J.get(f, "handle")) && c.apply(f, t),
            (c = s && f[s]) &&
              c.apply &&
              X(f) &&
              ((e.result = c.apply(f, t)),
              !1 === e.result && e.preventDefault()));
        return (
          (e.type = h),
          r ||
            e.isDefaultPrevented() ||
            (d._default && !1 !== d._default.apply(u.pop(), t)) ||
            !X(n) ||
            (s &&
              g(n[h]) &&
              !m(n) &&
              ((o = n[s]) && (n[s] = null),
              (C.event.triggered = h),
              e.isPropagationStopped() && l.addEventListener(h, St),
              n[h](),
              e.isPropagationStopped() && l.removeEventListener(h, St),
              (C.event.triggered = void 0),
              o && (n[s] = o))),
          e.result
        );
      }
    },
    simulate: function (e, t, n) {
      e = C.extend(new C.Event(), n, { type: e, isSimulated: !0 });
      C.event.trigger(e, null, t);
    },
  }),
    C.fn.extend({
      trigger: function (e, t) {
        return this.each(function () {
          C.event.trigger(e, t, this);
        });
      },
      triggerHandler: function (e, t) {
        var n = this[0];
        if (n) return C.event.trigger(e, t, n, !0);
      },
    }),
    b.focusin ||
      C.each({ focus: "focusin", blur: "focusout" }, function (n, r) {
        function i(e) {
          C.event.simulate(r, e.target, C.event.fix(e));
        }
        C.event.special[r] = {
          setup: function () {
            var e = this.ownerDocument || this.document || this,
              t = J.access(e, r);
            (t || e.addEventListener(n, i, !0), J.access(e, r, (t || 0) + 1));
          },
          teardown: function () {
            var e = this.ownerDocument || this.document || this,
              t = J.access(e, r) - 1;
            t
              ? J.access(e, r, t)
              : (e.removeEventListener(n, i, !0), J.remove(e, r));
          },
        };
      }));
  var It = w.location,
    At = { guid: Date.now() },
    kt = /\?/;
  C.parseXML = function (e) {
    var t;
    if (!e || "string" != typeof e) return null;
    try {
      t = new w.DOMParser().parseFromString(e, "text/xml");
    } catch (e) {
      t = void 0;
    }
    return (
      (t && !t.getElementsByTagName("parsererror").length) ||
        C.error("Invalid XML: " + e),
      t
    );
  };
  var Dt = /\[\]$/,
    Lt = /\r?\n/g,
    jt = /^(?:submit|button|image|reset|file)$/i,
    Nt = /^(?:input|select|textarea|keygen)/i;
  ((C.param = function (e, t) {
    function n(e, t) {
      ((t = g(t) ? t() : t),
        (i[i.length] =
          encodeURIComponent(e) +
          "=" +
          encodeURIComponent(null == t ? "" : t)));
    }
    var r,
      i = [];
    if (null == e) return "";
    if (Array.isArray(e) || (e.jquery && !C.isPlainObject(e)))
      C.each(e, function () {
        n(this.name, this.value);
      });
    else
      for (r in e)
        !(function n(r, e, i, o) {
          if (Array.isArray(e))
            C.each(e, function (e, t) {
              i || Dt.test(r)
                ? o(r, t)
                : n(
                    r +
                      "[" +
                      ("object" == typeof t && null != t ? e : "") +
                      "]",
                    t,
                    i,
                    o,
                  );
            });
          else if (i || "object" !== f(e)) o(r, e);
          else for (var t in e) n(r + "[" + t + "]", e[t], i, o);
        })(r, e[r], t, n);
    return i.join("&");
  }),
    C.fn.extend({
      serialize: function () {
        return C.param(this.serializeArray());
      },
      serializeArray: function () {
        return this.map(function () {
          var e = C.prop(this, "elements");
          return e ? C.makeArray(e) : this;
        })
          .filter(function () {
            var e = this.type;
            return (
              this.name &&
              !C(this).is(":disabled") &&
              Nt.test(this.nodeName) &&
              !jt.test(e) &&
              (this.checked || !le.test(e))
            );
          })
          .map(function (e, t) {
            var n = C(this).val();
            return null == n
              ? null
              : Array.isArray(n)
                ? C.map(n, function (e) {
                    return { name: t.name, value: e.replace(Lt, "\r\n") };
                  })
                : { name: t.name, value: n.replace(Lt, "\r\n") };
          })
          .get();
      },
    }));
  var $t = /%20/g,
    Mt = /#.*$/,
    Ot = /([?&])_=[^&]*/,
    Bt = /^(.*?):[ \t]*([^\r\n]*)$/gm,
    Rt = /^(?:GET|HEAD)$/,
    qt = /^\/\//,
    Ft = {},
    zt = {},
    Qt = "*/".concat("*"),
    Ut = H.createElement("a");
  function Wt(o) {
    return function (e, t) {
      "string" != typeof e && ((t = e), (e = "*"));
      var n,
        r = 0,
        i = e.toLowerCase().match($) || [];
      if (g(t))
        for (; (n = i[r++]); )
          "+" === n[0]
            ? ((n = n.slice(1) || "*"), (o[n] = o[n] || []).unshift(t))
            : (o[n] = o[n] || []).push(t);
    };
  }
  function Vt(t, r, i, o) {
    var a = {},
      s = t === zt;
    function c(e) {
      var n;
      return (
        (a[e] = !0),
        C.each(t[e] || [], function (e, t) {
          t = t(r, i, o);
          return "string" != typeof t || s || a[t]
            ? s
              ? !(n = t)
              : void 0
            : (r.dataTypes.unshift(t), c(t), !1);
        }),
        n
      );
    }
    return c(r.dataTypes[0]) || (!a["*"] && c("*"));
  }
  function Xt(e, t) {
    var n,
      r,
      i = C.ajaxSettings.flatOptions || {};
    for (n in t) void 0 !== t[n] && ((i[n] ? e : (r = r || {}))[n] = t[n]);
    return (r && C.extend(!0, e, r), e);
  }
  ((Ut.href = It.href),
    C.extend({
      active: 0,
      lastModified: {},
      etag: {},
      ajaxSettings: {
        url: It.href,
        type: "GET",
        isLocal:
          /^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(
            It.protocol,
          ),
        global: !0,
        processData: !0,
        async: !0,
        contentType: "application/x-www-form-urlencoded; charset=UTF-8",
        accepts: {
          "*": Qt,
          text: "text/plain",
          html: "text/html",
          xml: "application/xml, text/xml",
          json: "application/json, text/javascript",
        },
        contents: { xml: /\bxml\b/, html: /\bhtml/, json: /\bjson\b/ },
        responseFields: {
          xml: "responseXML",
          text: "responseText",
          json: "responseJSON",
        },
        converters: {
          "* text": String,
          "text html": !0,
          "text json": JSON.parse,
          "text xml": C.parseXML,
        },
        flatOptions: { url: !0, context: !0 },
      },
      ajaxSetup: function (e, t) {
        return t ? Xt(Xt(e, C.ajaxSettings), t) : Xt(C.ajaxSettings, e);
      },
      ajaxPrefilter: Wt(Ft),
      ajaxTransport: Wt(zt),
      ajax: function (e, t) {
        "object" == typeof e && ((t = e), (e = void 0));
        var c,
          d,
          l,
          n,
          u,
          h,
          p,
          r,
          i,
          f = C.ajaxSetup({}, (t = t || {})),
          g = f.context || f,
          m = f.context && (g.nodeType || g.jquery) ? C(g) : C.event,
          v = C.Deferred(),
          y = C.Callbacks("once memory"),
          b = f.statusCode || {},
          o = {},
          a = {},
          s = "canceled",
          P = {
            readyState: 0,
            getResponseHeader: function (e) {
              var t;
              if (h) {
                if (!n)
                  for (n = {}; (t = Bt.exec(l)); )
                    n[t[1].toLowerCase() + " "] = (
                      n[t[1].toLowerCase() + " "] || []
                    ).concat(t[2]);
                t = n[e.toLowerCase() + " "];
              }
              return null == t ? null : t.join(", ");
            },
            getAllResponseHeaders: function () {
              return h ? l : null;
            },
            setRequestHeader: function (e, t) {
              return (
                null == h &&
                  ((e = a[e.toLowerCase()] = a[e.toLowerCase()] || e),
                  (o[e] = t)),
                this
              );
            },
            overrideMimeType: function (e) {
              return (null == h && (f.mimeType = e), this);
            },
            statusCode: function (e) {
              if (e)
                if (h) P.always(e[P.status]);
                else for (var t in e) b[t] = [b[t], e[t]];
              return this;
            },
            abort: function (e) {
              e = e || s;
              return (c && c.abort(e), x(0, e), this);
            },
          };
        if (
          (v.promise(P),
          (f.url = ((e || f.url || It.href) + "").replace(
            qt,
            It.protocol + "//",
          )),
          (f.type = t.method || t.type || f.method || f.type),
          (f.dataTypes = (f.dataType || "*").toLowerCase().match($) || [""]),
          null == f.crossDomain)
        ) {
          i = H.createElement("a");
          try {
            ((i.href = f.url),
              (i.href = i.href),
              (f.crossDomain =
                Ut.protocol + "//" + Ut.host != i.protocol + "//" + i.host));
          } catch (e) {
            f.crossDomain = !0;
          }
        }
        if (
          (f.data &&
            f.processData &&
            "string" != typeof f.data &&
            (f.data = C.param(f.data, f.traditional)),
          Vt(Ft, f, t, P),
          h)
        )
          return P;
        for (r in ((p = C.event && f.global) &&
          0 == C.active++ &&
          C.event.trigger("ajaxStart"),
        (f.type = f.type.toUpperCase()),
        (f.hasContent = !Rt.test(f.type)),
        (d = f.url.replace(Mt, "")),
        f.hasContent
          ? f.data &&
            f.processData &&
            0 ===
              (f.contentType || "").indexOf(
                "application/x-www-form-urlencoded",
              ) &&
            (f.data = f.data.replace($t, "+"))
          : ((i = f.url.slice(d.length)),
            f.data &&
              (f.processData || "string" == typeof f.data) &&
              ((d += (kt.test(d) ? "&" : "?") + f.data), delete f.data),
            !1 === f.cache &&
              ((d = d.replace(Ot, "$1")),
              (i = (kt.test(d) ? "&" : "?") + "_=" + At.guid++ + i)),
            (f.url = d + i)),
        f.ifModified &&
          (C.lastModified[d] &&
            P.setRequestHeader("If-Modified-Since", C.lastModified[d]),
          C.etag[d] && P.setRequestHeader("If-None-Match", C.etag[d])),
        ((f.data && f.hasContent && !1 !== f.contentType) || t.contentType) &&
          P.setRequestHeader("Content-Type", f.contentType),
        P.setRequestHeader(
          "Accept",
          f.dataTypes[0] && f.accepts[f.dataTypes[0]]
            ? f.accepts[f.dataTypes[0]] +
                ("*" !== f.dataTypes[0] ? ", " + Qt + "; q=0.01" : "")
            : f.accepts["*"],
        ),
        f.headers))
          P.setRequestHeader(r, f.headers[r]);
        if (f.beforeSend && (!1 === f.beforeSend.call(g, P, f) || h))
          return P.abort();
        if (
          ((s = "abort"),
          y.add(f.complete),
          P.done(f.success),
          P.fail(f.error),
          (c = Vt(zt, f, t, P)))
        ) {
          if (((P.readyState = 1), p && m.trigger("ajaxSend", [P, f]), h))
            return P;
          f.async &&
            0 < f.timeout &&
            (u = w.setTimeout(function () {
              P.abort("timeout");
            }, f.timeout));
          try {
            ((h = !1), c.send(o, x));
          } catch (e) {
            if (h) throw e;
            x(-1, e);
          }
        } else x(-1, "No Transport");
        function x(e, t, n, r) {
          var i,
            o,
            a,
            s = t;
          h ||
            ((h = !0),
            u && w.clearTimeout(u),
            (c = void 0),
            (l = r || ""),
            (P.readyState = 0 < e ? 4 : 0),
            (r = (200 <= e && e < 300) || 304 === e),
            n &&
              (a = (function (e, t, n) {
                for (
                  var r, i, o, a, s = e.contents, c = e.dataTypes;
                  "*" === c[0];
                )
                  (c.shift(),
                    void 0 === r &&
                      (r = e.mimeType || t.getResponseHeader("Content-Type")));
                if (r)
                  for (i in s)
                    if (s[i] && s[i].test(r)) {
                      c.unshift(i);
                      break;
                    }
                if (c[0] in n) o = c[0];
                else {
                  for (i in n) {
                    if (!c[0] || e.converters[i + " " + c[0]]) {
                      o = i;
                      break;
                    }
                    a = a || i;
                  }
                  o = o || a;
                }
                if (o) return (o !== c[0] && c.unshift(o), n[o]);
              })(f, P, n)),
            !r &&
              -1 < C.inArray("script", f.dataTypes) &&
              (f.converters["text script"] = function () {}),
            (a = (function (e, t, n, r) {
              var i,
                o,
                a,
                s,
                c,
                d = {},
                l = e.dataTypes.slice();
              if (l[1])
                for (a in e.converters) d[a.toLowerCase()] = e.converters[a];
              for (o = l.shift(); o; )
                if (
                  (e.responseFields[o] && (n[e.responseFields[o]] = t),
                  !c && r && e.dataFilter && (t = e.dataFilter(t, e.dataType)),
                  (c = o),
                  (o = l.shift()))
                )
                  if ("*" === o) o = c;
                  else if ("*" !== c && c !== o) {
                    if (!(a = d[c + " " + o] || d["* " + o]))
                      for (i in d)
                        if (
                          (s = i.split(" "))[1] === o &&
                          (a = d[c + " " + s[0]] || d["* " + s[0]])
                        ) {
                          !0 === a
                            ? (a = d[i])
                            : !0 !== d[i] && ((o = s[0]), l.unshift(s[1]));
                          break;
                        }
                    if (!0 !== a)
                      if (a && e.throws) t = a(t);
                      else
                        try {
                          t = a(t);
                        } catch (e) {
                          return {
                            state: "parsererror",
                            error: a
                              ? e
                              : "No conversion from " + c + " to " + o,
                          };
                        }
                  }
              return { state: "success", data: t };
            })(f, a, P, r)),
            r
              ? (f.ifModified &&
                  ((n = P.getResponseHeader("Last-Modified")) &&
                    (C.lastModified[d] = n),
                  (n = P.getResponseHeader("etag")) && (C.etag[d] = n)),
                204 === e || "HEAD" === f.type
                  ? (s = "nocontent")
                  : 304 === e
                    ? (s = "notmodified")
                    : ((s = a.state), (i = a.data), (r = !(o = a.error))))
              : ((o = s), (!e && s) || ((s = "error"), e < 0 && (e = 0))),
            (P.status = e),
            (P.statusText = (t || s) + ""),
            r ? v.resolveWith(g, [i, s, P]) : v.rejectWith(g, [P, s, o]),
            P.statusCode(b),
            (b = void 0),
            p && m.trigger(r ? "ajaxSuccess" : "ajaxError", [P, f, r ? i : o]),
            y.fireWith(g, [P, s]),
            p &&
              (m.trigger("ajaxComplete", [P, f]),
              --C.active || C.event.trigger("ajaxStop")));
        }
        return P;
      },
      getJSON: function (e, t, n) {
        return C.get(e, t, n, "json");
      },
      getScript: function (e, t) {
        return C.get(e, void 0, t, "script");
      },
    }),
    C.each(["get", "post"], function (e, i) {
      C[i] = function (e, t, n, r) {
        return (
          g(t) && ((r = r || n), (n = t), (t = void 0)),
          C.ajax(
            C.extend(
              { url: e, type: i, dataType: r, data: t, success: n },
              C.isPlainObject(e) && e,
            ),
          )
        );
      };
    }),
    C.ajaxPrefilter(function (e) {
      for (var t in e.headers)
        "content-type" === t.toLowerCase() &&
          (e.contentType = e.headers[t] || "");
    }),
    (C._evalUrl = function (e, t, n) {
      return C.ajax({
        url: e,
        type: "GET",
        dataType: "script",
        cache: !0,
        async: !1,
        global: !1,
        converters: { "text script": function () {} },
        dataFilter: function (e) {
          C.globalEval(e, t, n);
        },
      });
    }),
    C.fn.extend({
      wrapAll: function (e) {
        return (
          this[0] &&
            (g(e) && (e = e.call(this[0])),
            (e = C(e, this[0].ownerDocument).eq(0).clone(!0)),
            this[0].parentNode && e.insertBefore(this[0]),
            e
              .map(function () {
                for (var e = this; e.firstElementChild; )
                  e = e.firstElementChild;
                return e;
              })
              .append(this)),
          this
        );
      },
      wrapInner: function (n) {
        return g(n)
          ? this.each(function (e) {
              C(this).wrapInner(n.call(this, e));
            })
          : this.each(function () {
              var e = C(this),
                t = e.contents();
              t.length ? t.wrapAll(n) : e.append(n);
            });
      },
      wrap: function (t) {
        var n = g(t);
        return this.each(function (e) {
          C(this).wrapAll(n ? t.call(this, e) : t);
        });
      },
      unwrap: function (e) {
        return (
          this.parent(e)
            .not("body")
            .each(function () {
              C(this).replaceWith(this.childNodes);
            }),
          this
        );
      },
    }),
    (C.expr.pseudos.hidden = function (e) {
      return !C.expr.pseudos.visible(e);
    }),
    (C.expr.pseudos.visible = function (e) {
      return !!(e.offsetWidth || e.offsetHeight || e.getClientRects().length);
    }),
    (C.ajaxSettings.xhr = function () {
      try {
        return new w.XMLHttpRequest();
      } catch (e) {}
    }));
  var _t = { 0: 200, 1223: 204 },
    Jt = C.ajaxSettings.xhr();
  ((b.cors = !!Jt && "withCredentials" in Jt),
    (b.ajax = Jt = !!Jt),
    C.ajaxTransport(function (i) {
      var o, a;
      if (b.cors || (Jt && !i.crossDomain))
        return {
          send: function (e, t) {
            var n,
              r = i.xhr();
            if (
              (r.open(i.type, i.url, i.async, i.username, i.password),
              i.xhrFields)
            )
              for (n in i.xhrFields) r[n] = i.xhrFields[n];
            for (n in (i.mimeType &&
              r.overrideMimeType &&
              r.overrideMimeType(i.mimeType),
            i.crossDomain ||
              e["X-Requested-With"] ||
              (e["X-Requested-With"] = "XMLHttpRequest"),
            e))
              r.setRequestHeader(n, e[n]);
            ((o = function (e) {
              return function () {
                o &&
                  ((o =
                    a =
                    r.onload =
                    r.onerror =
                    r.onabort =
                    r.ontimeout =
                    r.onreadystatechange =
                      null),
                  "abort" === e
                    ? r.abort()
                    : "error" === e
                      ? "number" != typeof r.status
                        ? t(0, "error")
                        : t(r.status, r.statusText)
                      : t(
                          _t[r.status] || r.status,
                          r.statusText,
                          "text" !== (r.responseType || "text") ||
                            "string" != typeof r.responseText
                            ? { binary: r.response }
                            : { text: r.responseText },
                          r.getAllResponseHeaders(),
                        ));
              };
            }),
              (r.onload = o()),
              (a = r.onerror = r.ontimeout = o("error")),
              void 0 !== r.onabort
                ? (r.onabort = a)
                : (r.onreadystatechange = function () {
                    4 === r.readyState &&
                      w.setTimeout(function () {
                        o && a();
                      });
                  }),
              (o = o("abort")));
            try {
              r.send((i.hasContent && i.data) || null);
            } catch (e) {
              if (o) throw e;
            }
          },
          abort: function () {
            o && o();
          },
        };
    }),
    C.ajaxPrefilter(function (e) {
      e.crossDomain && (e.contents.script = !1);
    }),
    C.ajaxSetup({
      accepts: {
        script:
          "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript",
      },
      contents: { script: /\b(?:java|ecma)script\b/ },
      converters: {
        "text script": function (e) {
          return (C.globalEval(e), e);
        },
      },
    }),
    C.ajaxPrefilter("script", function (e) {
      (void 0 === e.cache && (e.cache = !1), e.crossDomain && (e.type = "GET"));
    }),
    C.ajaxTransport("script", function (n) {
      var r, i;
      if (n.crossDomain || n.scriptAttrs)
        return {
          send: function (e, t) {
            ((r = C("<script>")
              .attr(n.scriptAttrs || {})
              .prop({ charset: n.scriptCharset, src: n.url })
              .on(
                "load error",
                (i = function (e) {
                  (r.remove(),
                    (i = null),
                    e && t("error" === e.type ? 404 : 200, e.type));
                }),
              )),
              H.head.appendChild(r[0]));
          },
          abort: function () {
            i && i();
          },
        };
    }));
  var Yt = [],
    Gt = /(=)\?(?=&|$)|\?\?/;
  (C.ajaxSetup({
    jsonp: "callback",
    jsonpCallback: function () {
      var e = Yt.pop() || C.expando + "_" + At.guid++;
      return ((this[e] = !0), e);
    },
  }),
    C.ajaxPrefilter("json jsonp", function (e, t, n) {
      var r,
        i,
        o,
        a =
          !1 !== e.jsonp &&
          (Gt.test(e.url)
            ? "url"
            : "string" == typeof e.data &&
              0 ===
                (e.contentType || "").indexOf(
                  "application/x-www-form-urlencoded",
                ) &&
              Gt.test(e.data) &&
              "data");
      if (a || "jsonp" === e.dataTypes[0])
        return (
          (r = e.jsonpCallback =
            g(e.jsonpCallback) ? e.jsonpCallback() : e.jsonpCallback),
          a
            ? (e[a] = e[a].replace(Gt, "$1" + r))
            : !1 !== e.jsonp &&
              (e.url += (kt.test(e.url) ? "&" : "?") + e.jsonp + "=" + r),
          (e.converters["script json"] = function () {
            return (o || C.error(r + " was not called"), o[0]);
          }),
          (e.dataTypes[0] = "json"),
          (i = w[r]),
          (w[r] = function () {
            o = arguments;
          }),
          n.always(function () {
            (void 0 === i ? C(w).removeProp(r) : (w[r] = i),
              e[r] && ((e.jsonpCallback = t.jsonpCallback), Yt.push(r)),
              o && g(i) && i(o[0]),
              (o = i = void 0));
          }),
          "script"
        );
    }),
    (b.createHTMLDocument =
      (((u = H.implementation.createHTMLDocument("").body).innerHTML =
        "<form></form><form></form>"),
      2 === u.childNodes.length)),
    (C.parseHTML = function (e, t, n) {
      return "string" != typeof e
        ? []
        : ("boolean" == typeof t && ((n = t), (t = !1)),
          t ||
            (b.createHTMLDocument
              ? (((r = (t =
                  H.implementation.createHTMLDocument("")).createElement(
                  "base",
                )).href = H.location.href),
                t.head.appendChild(r))
              : (t = H)),
          (r = !n && []),
          (n = I.exec(e))
            ? [t.createElement(n[1])]
            : ((n = ve([e], t, r)),
              r && r.length && C(r).remove(),
              C.merge([], n.childNodes)));
      var r;
    }),
    (C.fn.load = function (e, t, n) {
      var r,
        i,
        o,
        a = this,
        s = e.indexOf(" ");
      return (
        -1 < s && ((r = wt(e.slice(s))), (e = e.slice(0, s))),
        g(t)
          ? ((n = t), (t = void 0))
          : t && "object" == typeof t && (i = "POST"),
        0 < a.length &&
          C.ajax({ url: e, type: i || "GET", dataType: "html", data: t })
            .done(function (e) {
              ((o = arguments),
                a.html(r ? C("<div>").append(C.parseHTML(e)).find(r) : e));
            })
            .always(
              n &&
                function (e, t) {
                  a.each(function () {
                    n.apply(this, o || [e.responseText, t, e]);
                  });
                },
            ),
        this
      );
    }),
    (C.expr.pseudos.animated = function (t) {
      return C.grep(C.timers, function (e) {
        return t === e.elem;
      }).length;
    }),
    (C.offset = {
      setOffset: function (e, t, n) {
        var r,
          i,
          o,
          a,
          s = C.css(e, "position"),
          c = C(e),
          d = {};
        ("static" === s && (e.style.position = "relative"),
          (o = c.offset()),
          (r = C.css(e, "top")),
          (a = C.css(e, "left")),
          (a =
            ("absolute" === s || "fixed" === s) && -1 < (r + a).indexOf("auto")
              ? ((i = (s = c.position()).top), s.left)
              : ((i = parseFloat(r) || 0), parseFloat(a) || 0)),
          null != (t = g(t) ? t.call(e, n, C.extend({}, o)) : t).top &&
            (d.top = t.top - o.top + i),
          null != t.left && (d.left = t.left - o.left + a),
          "using" in t
            ? t.using.call(e, d)
            : ("number" == typeof d.top && (d.top += "px"),
              "number" == typeof d.left && (d.left += "px"),
              c.css(d)));
      },
    }),
    C.fn.extend({
      offset: function (t) {
        if (arguments.length)
          return void 0 === t
            ? this
            : this.each(function (e) {
                C.offset.setOffset(this, t, e);
              });
        var e,
          n = this[0];
        return n
          ? n.getClientRects().length
            ? ((e = n.getBoundingClientRect()),
              (n = n.ownerDocument.defaultView),
              { top: e.top + n.pageYOffset, left: e.left + n.pageXOffset })
            : { top: 0, left: 0 }
          : void 0;
      },
      position: function () {
        if (this[0]) {
          var e,
            t,
            n,
            r = this[0],
            i = { top: 0, left: 0 };
          if ("fixed" === C.css(r, "position")) t = r.getBoundingClientRect();
          else {
            for (
              t = this.offset(),
                n = r.ownerDocument,
                e = r.offsetParent || n.documentElement;
              e &&
              (e === n.body || e === n.documentElement) &&
              "static" === C.css(e, "position");
            )
              e = e.parentNode;
            e &&
              e !== r &&
              1 === e.nodeType &&
              (((i = C(e).offset()).top += C.css(e, "borderTopWidth", !0)),
              (i.left += C.css(e, "borderLeftWidth", !0)));
          }
          return {
            top: t.top - i.top - C.css(r, "marginTop", !0),
            left: t.left - i.left - C.css(r, "marginLeft", !0),
          };
        }
      },
      offsetParent: function () {
        return this.map(function () {
          for (
            var e = this.offsetParent;
            e && "static" === C.css(e, "position");
          )
            e = e.offsetParent;
          return e || re;
        });
      },
    }),
    C.each(
      { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" },
      function (t, i) {
        var o = "pageYOffset" === i;
        C.fn[t] = function (e) {
          return z(
            this,
            function (e, t, n) {
              var r;
              return (
                m(e) ? (r = e) : 9 === e.nodeType && (r = e.defaultView),
                void 0 === n
                  ? r
                    ? r[i]
                    : e[t]
                  : void (r
                      ? r.scrollTo(o ? r.pageXOffset : n, o ? n : r.pageYOffset)
                      : (e[t] = n))
              );
            },
            t,
            e,
            arguments.length,
          );
        };
      },
    ),
    C.each(["top", "left"], function (e, n) {
      C.cssHooks[n] = _e(b.pixelPosition, function (e, t) {
        if (t)
          return ((t = Xe(e, n)), We.test(t) ? C(e).position()[n] + "px" : t);
      });
    }),
    C.each({ Height: "height", Width: "width" }, function (a, s) {
      C.each(
        { padding: "inner" + a, content: s, "": "outer" + a },
        function (r, o) {
          C.fn[o] = function (e, t) {
            var n = arguments.length && (r || "boolean" != typeof e),
              i = r || (!0 === e || !0 === t ? "margin" : "border");
            return z(
              this,
              function (e, t, n) {
                var r;
                return m(e)
                  ? 0 === o.indexOf("outer")
                    ? e["inner" + a]
                    : e.document.documentElement["client" + a]
                  : 9 === e.nodeType
                    ? ((r = e.documentElement),
                      Math.max(
                        e.body["scroll" + a],
                        r["scroll" + a],
                        e.body["offset" + a],
                        r["offset" + a],
                        r["client" + a],
                      ))
                    : void 0 === n
                      ? C.css(e, t, i)
                      : C.style(e, t, n, i);
              },
              s,
              n ? e : void 0,
              n,
            );
          };
        },
      );
    }),
    C.each(
      [
        "ajaxStart",
        "ajaxStop",
        "ajaxComplete",
        "ajaxError",
        "ajaxSuccess",
        "ajaxSend",
      ],
      function (e, t) {
        C.fn[t] = function (e) {
          return this.on(t, e);
        };
      },
    ),
    C.fn.extend({
      bind: function (e, t, n) {
        return this.on(e, null, t, n);
      },
      unbind: function (e, t) {
        return this.off(e, null, t);
      },
      delegate: function (e, t, n, r) {
        return this.on(t, e, n, r);
      },
      undelegate: function (e, t, n) {
        return 1 === arguments.length
          ? this.off(e, "**")
          : this.off(t, e || "**", n);
      },
      hover: function (e, t) {
        return this.mouseenter(e).mouseleave(t || e);
      },
    }),
    C.each(
      "blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(
        " ",
      ),
      function (e, n) {
        C.fn[n] = function (e, t) {
          return 0 < arguments.length
            ? this.on(n, null, e, t)
            : this.trigger(n);
        };
      },
    ));
  var Kt = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;
  ((C.proxy = function (e, t) {
    var n, r;
    if (("string" == typeof t && ((r = e[t]), (t = e), (e = r)), g(e)))
      return (
        (n = s.call(arguments, 2)),
        ((r = function () {
          return e.apply(t || this, n.concat(s.call(arguments)));
        }).guid = e.guid =
          e.guid || C.guid++),
        r
      );
  }),
    (C.holdReady = function (e) {
      e ? C.readyWait++ : C.ready(!0);
    }),
    (C.isArray = Array.isArray),
    (C.parseJSON = JSON.parse),
    (C.nodeName = E),
    (C.isFunction = g),
    (C.isWindow = m),
    (C.camelCase = V),
    (C.type = f),
    (C.now = Date.now),
    (C.isNumeric = function (e) {
      var t = C.type(e);
      return ("number" === t || "string" === t) && !isNaN(e - parseFloat(e));
    }),
    (C.trim = function (e) {
      return null == e ? "" : (e + "").replace(Kt, "");
    }),
    "function" == typeof define &&
      define.amd &&
      define("jquery", [], function () {
        return C;
      }));
  var Zt = w.jQuery,
    en = w.$;
  return (
    (C.noConflict = function (e) {
      return (
        w.$ === C && (w.$ = en),
        e && w.jQuery === C && (w.jQuery = Zt),
        C
      );
    }),
    void 0 === e && (w.jQuery = w.$ = C),
    C
  );
});
var H5P = (window.H5P = window.H5P || {});
((H5P.jQuery = jQuery.noConflict(!0)),
  (H5P.jQuery.fn.__originalLoad = H5P.jQuery.load),
  (H5P.jQuery.fn.load = function (e, t, n) {
    if ("function" != typeof e)
      return H5P.jQuery.fn.__originalLoad.apply(this, arguments);
    {
      console.warn("You are using a deprecated H5P library. Please upgrade!");
      let e = Array.prototype.slice.call(arguments);
      return (e.unshift("load"), H5P.jQuery.fn.on.apply(this, e));
    }
  }),
  ((H5P = window.H5P = window.H5P || {}).isFramed =
    window.self !== window.parent),
  (H5P.$window = H5P.jQuery(window)),
  (H5P.instances = []),
  document.documentElement.requestFullScreen
    ? (H5P.fullScreenBrowserPrefix = "")
    : document.documentElement.webkitRequestFullScreen
      ? ((H5P.safariBrowser = navigator.userAgent.match(/version\/([.\d]+)/i)),
        (H5P.safariBrowser =
          null === H5P.safariBrowser ? 0 : parseInt(H5P.safariBrowser[1])),
        (0 === H5P.safariBrowser || 6 < H5P.safariBrowser) &&
          (H5P.fullScreenBrowserPrefix = "webkit"))
      : document.documentElement.mozRequestFullScreen
        ? (H5P.fullScreenBrowserPrefix = "moz")
        : document.documentElement.msRequestFullscreen &&
          (H5P.fullScreenBrowserPrefix = "ms"),
  (H5P.opened = {}),
  (H5P.init = function (e) {
    (void 0 === H5P.$body && (H5P.$body = H5P.jQuery(document.body)),
      void 0 === H5P.fullscreenSupported &&
        (H5P.fullscreenSupported = !(
          H5PIntegration.fullscreenDisabled ||
          H5P.fullscreenDisabled ||
          (H5P.isFramed &&
            !1 !== H5P.externalEmbed &&
            !(
              document.fullscreenEnabled ||
              document.webkitFullscreenEnabled ||
              document.mozFullScreenEnabled
            ))
        )),
      void 0 === H5P.canHasFullScreen &&
        (H5P.canHasFullScreen = H5P.fullscreenSupported),
      H5P.jQuery(".h5p-content:not(.h5p-initialized)", e).each(function () {
        var t = H5P.jQuery(this).addClass("h5p-initialized"),
          n = H5P.jQuery('<div class="h5p-container"></div>').appendTo(t),
          i = t.data("content-id"),
          o = H5PIntegration.contents["cid-" + i];
        if (void 0 === o)
          return H5P.error(
            "No data for content id " + i + ". Perhaps the library is gone?",
          );
        var a = {
          library: o.library,
          params: JSON.parse(o.jsonContent),
          metadata: o.metadata,
        };
        H5P.getUserData(i, "state", function (e, t) {
          var r;
          t
            ? (a.userDatas = { state: t })
            : null === t &&
              H5PIntegration.saveFreq &&
              (delete o.contentUserData,
              (r = new H5P.Dialog(
                "content-user-data-reset",
                "Data Reset",
                "<p>" +
                  H5P.t("contentChanged") +
                  "</p><p>" +
                  H5P.t("startingOver") +
                  '</p><div class="h5p-dialog-ok-button" tabIndex="0" role="button">OK</div>',
                n,
              )),
              H5P.jQuery(r)
                .on("dialog-opened", function (e, t) {
                  function n(e) {
                    ("click" !== e.type && 32 !== e.which) ||
                      (r.close(), H5P.deleteUserData(i, "state", 0));
                  }
                  (t.find(".h5p-dialog-ok-button").click(n).keypress(n),
                    H5P.trigger(s, "resize"));
                })
                .on("dialog-closed", function () {
                  H5P.trigger(s, "resize");
                }),
              r.open());
        });
        var s = H5P.newRunnable(a, i, n, !0, { standalone: !0 });
        ((H5P.offlineRequestQueue = new H5P.OfflineRequestQueue({
          instance: s,
        })),
          1 == o.fullScreen &&
            H5P.fullscreenSupported &&
            H5P.jQuery(
              '<div class="h5p-content-controls"><div role="button" tabindex="0" class="h5p-enable-fullscreen" aria-label="' +
                H5P.t("fullscreen") +
                '" title="' +
                H5P.t("fullscreen") +
                '"></div></div>',
            )
              .prependTo(n)
              .children()
              .click(function () {
                H5P.fullScreen(n, s);
              })
              .keydown(function (e) {
                if (32 === e.which || 13 === e.which)
                  return (H5P.fullScreen(n, s), !1);
              }));
        var e,
          r,
          c,
          d,
          l,
          u,
          h,
          p = o.displayOptions,
          f = !1;
        (p.frame &&
          (p.copyright &&
            ((e = H5P.getCopyrights(s, a.params, i, a.metadata)) ||
              (p.copyright = !1)),
          (p = new H5P.ActionBar(p)),
          (r = p.getDOMElement()),
          p.on("reuse", function () {
            (H5P.openReuseDialog(r, o, a, s, i),
              s.triggerXAPI("accessed-reuse"));
          }),
          p.on("copyrights", function () {
            (new H5P.Dialog(
              "copyrights",
              H5P.t("copyrightInformation"),
              e,
              n,
            ).open(!0),
              s.triggerXAPI("accessed-copyright"));
          }),
          p.on("embed", function () {
            (H5P.openEmbedDialog(
              r,
              o.embedCode,
              o.resizeCode,
              { width: t.width(), height: t.height() },
              s,
            ),
              s.triggerXAPI("accessed-embed"));
          }),
          p.hasActions() && ((f = !0), r.insertAfter(n))),
          t.addClass(f ? "h5p-frame" : "h5p-no-frame"),
          (H5P.opened[i] = new Date()),
          H5P.on(s, "finish", function (e) {
            void 0 !== e.data &&
              H5P.setFinished(i, e.data.score, e.data.maxScore, e.data.time);
          }),
          H5P.on(s, "xAPI", H5P.xAPICompletedListener),
          !1 !== H5PIntegration.saveFreq &&
            (s.getCurrentState instanceof Function ||
              "function" == typeof s.getCurrentState) &&
            ((d = function () {
              var e = s.getCurrentState();
              (void 0 !== e &&
                H5P.setUserData(i, "state", e, { deleteOnChange: !0 }),
                H5PIntegration.saveFreq &&
                  (c = setTimeout(d, 1e3 * H5PIntegration.saveFreq)));
            }),
            H5PIntegration.saveFreq &&
              (c = setTimeout(d, 1e3 * H5PIntegration.saveFreq)),
            H5P.on(s, "xAPI", function (e) {
              e = e.getVerb();
              ("completed" !== e && "progressed" !== e) ||
                (clearTimeout(c), (c = setTimeout(d, 3e3)));
            })),
          H5P.isFramed &&
            (!1 === H5P.externalEmbed
              ? ((u = window.frameElement),
                H5P.on(s, "resize", function () {
                  (clearTimeout(l),
                    (l = setTimeout(function () {
                      var e;
                      window.parent.H5P.isFullscreen ||
                        ((e = u.parentElement.style.height),
                        (u.parentElement.style.height =
                          u.parentElement.clientHeight + "px"),
                        u.getBoundingClientRect(),
                        (u.style.height = "1px"),
                        (u.style.height =
                          u.contentDocument.body.scrollHeight + "px"),
                        (u.parentElement.style.height = e));
                    }, 1)));
                }))
              : H5P.communicator &&
                ((h = !1),
                H5P.communicator.on("ready", function () {
                  H5P.communicator.send("hello");
                }),
                H5P.communicator.on("hello", function () {
                  ((h = !0),
                    (document.body.style.height = "auto"),
                    (document.body.style.overflow = "hidden"),
                    H5P.trigger(s, "resize"));
                }),
                H5P.communicator.on("resizePrepared", function () {
                  H5P.communicator.send("resize", {
                    scrollHeight: document.body.scrollHeight,
                  });
                }),
                H5P.communicator.on("resize", function () {
                  H5P.trigger(s, "resize");
                }),
                H5P.on(s, "resize", function () {
                  H5P.isFullscreen ||
                    (clearTimeout(l),
                    (l = setTimeout(function () {
                      h
                        ? H5P.communicator.send("prepareResize", {
                            scrollHeight: document.body.scrollHeight,
                            clientHeight: document.body.clientHeight,
                          })
                        : H5P.communicator.send("hello");
                    }, 0)));
                }))),
          (H5P.isFramed && !1 !== H5P.externalEmbed) ||
            H5P.jQuery(window.parent).resize(function () {
              (window.parent.H5P.isFullscreen, H5P.trigger(s, "resize"));
            }),
          H5P.instances.push(s),
          H5P.trigger(s, "resize"),
          t.addClass("using-mouse"),
          t.on("mousedown keydown keyup", function (e) {
            t.toggleClass("using-mouse", "mousedown" === e.type);
          }),
          H5P.externalDispatcher &&
            H5P.externalDispatcher.trigger("initialized"));
      }),
      H5P.jQuery("iframe.h5p-iframe:not(.h5p-initialized)", e).each(
        function () {
          var e = H5P.jQuery(this)
              .addClass("h5p-initialized")
              .data("content-id"),
            t = H5PIntegration.contents["cid-" + e],
            t =
              t && t.metadata && t.metadata.defaultLanguage
                ? t.metadata.defaultLanguage
                : "en";
          (this.contentDocument.open(),
            this.contentDocument.write(
              '<!doctype html><html class="h5p-iframe" lang="' +
                t +
                '"><head>' +
                H5P.getHeadTags(e) +
                '</head><body><div class="h5p-content" data-content-id="' +
                e +
                '"/></body></html>',
            ),
            this.contentDocument.close());
        },
      ));
  }),
  (H5P.getHeadTags = function (e) {
    function t(e) {
      for (var t = "", n = 0; n < e.length; n++)
        t += '<link rel="stylesheet" href="' + e[n] + '">';
      return t;
    }
    function n(e) {
      for (var t = "", n = 0; n < e.length; n++)
        t += '<script src="' + e[n] + '"><\/script>';
      return t;
    }
    return (
      '<base target="_parent">' +
      t(H5PIntegration.core.styles) +
      t(H5PIntegration.contents["cid-" + e].styles) +
      n(H5PIntegration.core.scripts) +
      n(H5PIntegration.contents["cid-" + e].scripts) +
      "<script>H5PIntegration = window.parent.H5PIntegration; var H5P = H5P || {}; H5P.externalEmbed = false;<\/script>"
    );
  }),
  (H5P.communicator =
    window.postMessage && window.addEventListener
      ? new (function () {
          var n = {};
          (window.addEventListener(
            "message",
            function (e) {
              window.parent === e.source &&
                "h5p" === e.data.context &&
                void 0 !== n[e.data.action] &&
                n[e.data.action](e.data);
            },
            !1,
          ),
            (this.on = function (e, t) {
              n[e] = t;
            }),
            (this.send = function (e, t) {
              (((t = void 0 === t ? {} : t).context = "h5p"),
                (t.action = e),
                window.parent.postMessage(t, "*"));
            }));
        })()
      : void 0),
  (H5P.semiFullScreen = function (e, t, n, r) {
    H5P.fullScreen(e, t, n, r, !0);
  }),
  (H5P.fullScreen = function (e, t, n, r, i) {
    if (void 0 === H5P.exitFullScreen) {
      if (H5P.isFramed && !1 === H5P.externalEmbed)
        return (
          window.parent.H5P.fullScreen(e, t, n, H5P.$body.get(), i),
          (H5P.isFullscreen = !0),
          (H5P.exitFullScreen = function () {
            window.parent.H5P.exitFullScreen();
          }),
          void H5P.on(t, "exitFullScreen", function () {
            ((H5P.isFullscreen = !1), (H5P.exitFullScreen = void 0));
          })
        );
      var o,
        a,
        s,
        c = e;
      (void 0 === r
        ? (o = H5P.$body)
        : ((a = (o = H5P.jQuery(r)).add(e.get())),
          (r = "#h5p-iframe-" + e.parent().data("content-id")),
          (e = (s = H5P.jQuery(r)).parent())),
        (a = e.add(H5P.$body).add(a)));
      function d(e) {
        (a.addClass(e), void 0 !== s && s.css("height", ""));
      }
      function l() {
        (H5P.trigger(t, "resize"),
          H5P.trigger(t, "focus"),
          H5P.trigger(t, "enterFullScreen"));
      }
      function u(e) {
        ((H5P.isFullscreen = !1),
          a.removeClass(e),
          H5P.trigger(t, "resize"),
          H5P.trigger(t, "focus"),
          (H5P.exitFullScreen = void 0) !== n && n(),
          H5P.trigger(t, "exitFullScreen"));
      }
      if (
        ((H5P.isFullscreen = !0),
        void 0 === H5P.fullScreenBrowserPrefix || !0 === i)
      ) {
        if (!H5P.isFramed) {
          d("h5p-semi-fullscreen");
          var h,
            p,
            f = H5P.jQuery(
              '<div role="button" tabindex="0" class="h5p-disable-fullscreen" title="' +
                H5P.t("disableFullscreen") +
                '" aria-label="' +
                H5P.t("disableFullscreen") +
                '"></div>',
            ).appendTo(c.find(".h5p-content-controls")),
            g = (H5P.exitFullScreen = function () {
              (h ? (p.content = h) : v.removeChild(p),
                f.remove(),
                o.unbind("keyup", m),
                u("h5p-semi-fullscreen"));
            }),
            m = function (e) {
              27 === e.keyCode && g();
            };
          (f.click(g), o.keyup(m));
          for (
            var v, y = document.getElementsByTagName("meta"), b = 0;
            b < y.length;
            b++
          )
            if ("viewport" === y[b].name) {
              ((p = y[b]), (h = p.content));
              break;
            }
          (h || ((p = document.createElement("meta")).name = "viewport"),
            (p.content =
              "width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"),
            h || (v = document.getElementsByTagName("head")[0]).appendChild(p),
            l());
        }
      } else {
        d("h5p-fullscreen");
        var P,
          x =
            "ms" === H5P.fullScreenBrowserPrefix
              ? "MSFullscreenChange"
              : H5P.fullScreenBrowserPrefix + "fullscreenchange";
        (document.addEventListener(x, function () {
          return void 0 === P
            ? ((P = !1), void l())
            : (u("h5p-fullscreen"),
              void document.removeEventListener(x, arguments.callee, !1));
        }),
          "" === H5P.fullScreenBrowserPrefix
            ? e[0].requestFullScreen()
            : ((i =
                "ms" === H5P.fullScreenBrowserPrefix
                  ? "msRequestFullscreen"
                  : H5P.fullScreenBrowserPrefix + "RequestFullScreen"),
              (c =
                "webkit" === H5P.fullScreenBrowserPrefix &&
                0 === H5P.safariBrowser
                  ? Element.ALLOW_KEYBOARD_INPUT
                  : void 0),
              e[0][i](c)),
          (H5P.exitFullScreen = function () {
            "" === H5P.fullScreenBrowserPrefix
              ? document.exitFullscreen()
              : "moz" === H5P.fullScreenBrowserPrefix
                ? document.mozCancelFullScreen()
                : document[H5P.fullScreenBrowserPrefix + "ExitFullscreen"]();
          }));
      }
    }
  }),
  (function () {
    ((H5P.addQueryParameter = function (e, t) {
      let n, r;
      const i = e.split("?");
      return (
        (n = i[1]
          ? ((r = i[1].split("#")), i[0] + "?" + r[0] + "&")
          : ((r = i[0].split("#")), r[0] + "?")),
        (n += t),
        r[1] && (n += "#" + r[1]),
        n
      );
    }),
      (H5P.setSource = function (e, t, n) {
        let r = t.path;
        t = H5P.getCrossOrigin(t);
        (t
          ? ((e.crossOrigin = t),
            H5PIntegration.crossoriginCacheBuster &&
              (r = H5P.addQueryParameter(
                r,
                H5PIntegration.crossoriginCacheBuster,
              )))
          : e.removeAttribute("crossorigin"),
          (e.src = H5P.getPath(r, n)));
      }));
    function i(e) {
      return e.match(/^[a-z0-9]+:\/\//i);
    }
    ((H5P.getCrossOrigin = function (e) {
      return "object" != typeof e
        ? H5PIntegration.crossorigin &&
          H5PIntegration.crossoriginRegex &&
          e.match(H5PIntegration.crossoriginRegex)
          ? H5PIntegration.crossorigin
          : null
        : H5PIntegration.crossorigin && !i(e.path)
          ? H5PIntegration.crossorigin
          : void 0;
    }),
      (H5P.getPath = function (e, t) {
        if (i(e)) return e;
        var n,
          r = "#tmp" === e.substr(-4, 4);
        if (void 0 === t || r) {
          if (void 0 === window.H5PEditor) return;
          n = H5PEditor.filesPath;
        } else
          n =
            (n =
              void 0 !== H5PIntegration.contents &&
              H5PIntegration.contents["cid-" + t]
                ? H5PIntegration.contents["cid-" + t].contentUrl
                : n) || H5PIntegration.url + "/content/" + t;
        return (
          (n = !i(n)
            ? window.location.protocol + "//" + window.location.host + n
            : n) +
          "/" +
          e
        );
      }));
  })(),
  (H5P.getContentPath = function (e) {
    return H5PIntegration.url + "/content/" + e;
  }),
  (H5P.classFromName = function (e) {
    e = e.split(".");
    return this[e[e.length - 1]];
  }),
  (H5P.newRunnable = function (t, e, n, r, i) {
    var o, a;
    try {
      ((a = (s = t.library.split(" ", 2))[0]), (o = s[1].split(".", 2)));
    } catch (e) {
      return H5P.error("Invalid library string: " + t.library);
    }
    if (t.params instanceof Object != !0 || t.params instanceof Array == !0)
      return (
        H5P.error("Invalid library params for: " + t.library),
        H5P.error(t.params)
      );
    try {
      for (var s = s[0].split("."), c = window, d = 0; d < s.length; d++)
        c = c[s[d]];
      if ("function" != typeof c) throw null;
    } catch (e) {
      return H5P.error("Unable to find constructor for: " + t.library);
    }
    (void 0 === i && (i = {}),
      t.subContentId && (i.subContentId = t.subContentId),
      t.userDatas &&
        t.userDatas.state &&
        H5PIntegration.saveFreq &&
        (i.previousState = t.userDatas.state),
      t.metadata && (i.metadata = t.metadata));
    var l,
      u = i.standalone || !1;
    return (
      (c.prototype = H5P.jQuery.extend(
        {},
        H5P.ContentType(u).prototype,
        c.prototype,
      )),
      void 0 ===
        (l =
          -1 <
          H5P.jQuery.inArray(t.library, [
            "H5P.CoursePresentation 1.0",
            "H5P.CoursePresentation 1.1",
            "H5P.CoursePresentation 1.2",
            "H5P.CoursePresentation 1.3",
          ])
            ? new c(t.params, e)
            : new c(t.params, e, i)).$ && (l.$ = H5P.jQuery(l)),
      void 0 === l.contentId && (l.contentId = e),
      void 0 === l.subContentId &&
        t.subContentId &&
        (l.subContentId = t.subContentId),
      void 0 === l.parent && i && i.parent && (l.parent = i.parent),
      void 0 === l.libraryInfo &&
        (l.libraryInfo = {
          versionedName: t.library,
          versionedNameNoSpaces: a + "-" + o[0] + "." + o[1],
          machineName: a,
          majorVersion: o[0],
          minorVersion: o[1],
        }),
      void 0 !== n &&
        (n.toggleClass("h5p-standalone", u),
        l.attach(n),
        H5P.trigger(
          l,
          "domChanged",
          { $target: n, library: a, key: "newLibrary" },
          { bubbles: !0, external: !0 },
        ),
        (void 0 !== r && r) || H5P.trigger(l, "resize")),
      l
    );
  }),
  (H5P.error = function (e) {
    void 0 !== window.console &&
      void 0 !== console.error &&
      console.error(e.stack || e);
  }),
  (H5P.t = function (e, t, n) {
    if ((void 0 === n && (n = "H5P"), void 0 === H5PIntegration.l10n[n]))
      return '[Missing translation namespace "' + n + '"]';
    if (void 0 === H5PIntegration.l10n[n][e])
      return '[Missing translation "' + e + '" in "' + n + '"]';
    var r = H5PIntegration.l10n[n][e];
    if (void 0 !== t) for (var i in t) r = r.replace(i, t[i]);
    return r;
  }),
  (H5P.Dialog = function (e, t, n, r) {
    var i = this,
      o = H5P.jQuery(
        '<div class="h5p-popup-dialog h5p-' +
          e +
          '-dialog" role="dialog" tabindex="-1">                              <div class="h5p-inner">                                <h2>' +
          t +
          '</h2>                                <div class="h5p-scroll-content">' +
          n +
          '</div>                                <div class="h5p-close" role="button" tabindex="0" aria-label="' +
          H5P.t("close") +
          '" title="' +
          H5P.t("close") +
          '"></div>                              </div>                            </div>',
      )
        .insertAfter(r)
        .click(function (e) {
          (e && e.originalEvent && e.originalEvent.preventClosing) || i.close();
        })
        .children(".h5p-inner")
        .click(function (e) {
          e.originalEvent.preventClosing = !0;
        })
        .find(".h5p-close")
        .click(function () {
          i.close();
        })
        .keypress(function (e) {
          if (13 === e.which || 32 === e.which) return (i.close(), !1);
        })
        .end()
        .find("a")
        .click(function (e) {
          e.stopPropagation();
        })
        .end()
        .end();
    ((i.open = function (e) {
      (e && o.css("height", "100%"),
        setTimeout(function () {
          (o.addClass("h5p-open"),
            H5P.jQuery(i).trigger("dialog-opened", [o]),
            o.focus());
        }, 1));
    }),
      (i.close = function () {
        (o.removeClass("h5p-open"),
          setTimeout(function () {
            (o.remove(),
              H5P.jQuery(i).trigger("dialog-closed", [o]),
              r.attr("tabindex", "-1"),
              r.focus());
          }, 200));
      }));
  }),
  (H5P.getCopyrights = function (e, t, n, r) {
    var i;
    if (void 0 !== e.getCopyrights)
      try {
        i = e.getCopyrights();
      } catch (e) {}
    void 0 === i &&
      ((i = new H5P.ContentCopyrights()), H5P.findCopyrights(i, t, n));
    e = H5P.buildMetadataCopyrights(r, e.libraryInfo.machineName);
    return (
      void 0 !== e && i.addMediaInFront(e),
      (i = void 0 !== i ? i.toString() : i)
    );
  }),
  (H5P.findCopyrights = function (o, e, t, n) {
    var r, i, a, s;
    for (i in (n && ((n.params = e), c(n, n.machineName, t)), e))
      e.hasOwnProperty(i) &&
        ("overrideSettings" !== i
          ? ((a = e[i]) && a.library && "string" == typeof a.library
              ? (r = a.library.split(" ")[0])
              : a &&
                a.library &&
                "object" == typeof a.library &&
                (r =
                  a.library.library && "string" == typeof a.library.library
                    ? a.library.library.split(" ")[0]
                    : r),
            a instanceof Array
              ? H5P.findCopyrights(o, a, t)
              : a instanceof Object &&
                (c(a, r, t),
                void 0 === a.copyright ||
                void 0 === a.copyright.license ||
                void 0 === a.path ||
                void 0 === a.mime
                  ? H5P.findCopyrights(o, a, t)
                  : ((s = new H5P.MediaCopyright(a.copyright)),
                    void 0 !== a.width &&
                      void 0 !== a.height &&
                      s.setThumbnail(
                        new H5P.Thumbnail(
                          H5P.getPath(a.path, t),
                          a.width,
                          a.height,
                        ),
                      ),
                    o.addMedia(s))))
          : (console.warn(
              "The semantics field 'overrideSettings' is DEPRECATED and should not be used.",
            ),
            console.warn(e)));
    function c(e, t, n) {
      if (e.metadata) {
        const i = H5P.buildMetadataCopyrights(e.metadata, t);
        var r;
        void 0 !== i &&
          (e.params &&
            "Image" === e.params.contentName &&
            e.params.file &&
            ((r = e.params.file.path),
            (t = e.params.file.width),
            (e = e.params.file.height),
            i.setThumbnail(new H5P.Thumbnail(H5P.getPath(r, n), t, e))),
          o.addMedia(i));
      }
    }
  }),
  (H5P.buildMetadataCopyrights = function (e) {
    if (e && void 0 !== e.license && "U" !== e.license) {
      e = {
        contentType: e.contentType,
        title: e.title,
        author:
          e.authors && 0 < e.authors.length
            ? e.authors
                .map(function (e) {
                  return e.role ? e.name + " (" + e.role + ")" : e.name;
                })
                .join(", ")
            : void 0,
        source: e.source,
        year: e.yearFrom
          ? e.yearFrom + (e.yearTo ? "-" + e.yearTo : "")
          : void 0,
        license: e.license,
        version: e.licenseVersion,
        licenseExtras: e.licenseExtras,
        changes:
          e.changes && 0 < e.changes.length
            ? e.changes
                .map(function (e) {
                  return (
                    e.log +
                    (e.author ? ", " + e.author : "") +
                    (e.date ? ", " + e.date : "")
                  );
                })
                .join(" / ")
            : void 0,
      };
      return new H5P.MediaCopyright(e);
    }
  }),
  (H5P.openReuseDialog = function (e, n, r, i, o) {
    let t = "";
    (n.displayOptions.export &&
      (t +=
        '<button type="button" class="h5p-big-button h5p-download-button"><div class="h5p-button-title">Download as an .h5p file</div><div class="h5p-button-description">.h5p files may be uploaded to any web-site where H5P content may be created.</div></button>'),
      n.displayOptions.export &&
        n.displayOptions.copy &&
        (t += '<div class="h5p-horizontal-line-text"><span>or</span></div>'),
      n.displayOptions.copy &&
        (t +=
          '<button type="button" class="h5p-big-button h5p-copy-button"><div class="h5p-button-title">Copy content</div><div class="h5p-button-description">Copied content may be pasted anywhere this content type is supported on this website.</div></button>'));
    const a = new H5P.Dialog("reuse", H5P.t("reuseContent"), t, e);
    (H5P.jQuery(a)
      .on("dialog-opened", function (e, t) {
        (H5P.jQuery(
          '<a href="https://h5p.org/node/442225" target="_blank">More Info</a>',
        )
          .click(function (e) {
            e.stopPropagation();
          })
          .appendTo(t.find("h2")),
          t.find(".h5p-download-button").click(function () {
            ((window.location.href = n.exportUrl),
              i.triggerXAPI("downloaded"),
              a.close());
          }),
          t.find(".h5p-copy-button").click(function () {
            const e = new H5P.ClipboardItem(r);
            ((e.contentId = o),
              H5P.setClipboard(e),
              i.triggerXAPI("copied"),
              a.close(),
              H5P.attachToastTo(
                H5P.jQuery(".h5p-content:first")[0],
                H5P.t("contentCopied"),
                {
                  position: {
                    horizontal: "centered",
                    vertical: "centered",
                    noOverflowX: !0,
                  },
                },
              ));
          }),
          H5P.trigger(i, "resize"));
      })
      .on("dialog-closed", function () {
        H5P.trigger(i, "resize");
      }),
      a.open());
  }),
  (H5P.openEmbedDialog = function (e, t, n, d, l) {
    var u = t + n,
      e = new H5P.Dialog(
        "embed",
        H5P.t("embed"),
        '<textarea class="h5p-embed-code-container" autocorrect="off" autocapitalize="off" spellcheck="false"></textarea>' +
          H5P.t("size") +
          ': <input type="text" value="' +
          Math.ceil(d.width) +
          '" class="h5p-embed-size"/> × <input type="text" value="' +
          Math.ceil(d.height) +
          '" class="h5p-embed-size"/> px<br/><div role="button" tabindex="0" class="h5p-expander">' +
          H5P.t("showAdvanced") +
          '</div><div class="h5p-expander-content"><p>' +
          H5P.t("advancedHelp") +
          '</p><textarea class="h5p-embed-code-container" autocorrect="off" autocapitalize="off" spellcheck="false">' +
          n +
          "</textarea></div>",
        e,
      );
    (H5P.jQuery(e)
      .on("dialog-opened", function (e, n) {
        function r() {
          H5P.trigger(l, "resize");
        }
        function t(e, t) {
          return ((e = parseFloat(e.val())), isNaN(e) ? t : Math.ceil(e));
        }
        function i() {
          n.find(".h5p-embed-code-container:first").val(
            u.replace(":w", t(a, d.width)).replace(":h", t(s, d.height)),
          );
        }
        var o = n.find(".h5p-inner").find(".h5p-scroll-content"),
          a =
            (o.outerHeight(), o.innerHeight(), n.find(".h5p-embed-size:eq(0)")),
          s = n.find(".h5p-embed-size:eq(1)");
        (a.change(i),
          s.change(i),
          i(),
          n.find(".h5p-embed-code-container").each(function () {
            H5P.jQuery(this)
              .css("height", this.scrollHeight + "px")
              .focus(function () {
                H5P.jQuery(this).select();
              });
          }),
          n.find(".h5p-embed-code-container").eq(0).select(),
          r());
        function c() {
          var e = H5P.jQuery(this),
            t = e.next();
          (t.is(":visible")
            ? (e
                .removeClass("h5p-open")
                .text(H5P.t("showAdvanced"))
                .attr("aria-expanded", "true"),
              t.hide())
            : (e
                .addClass("h5p-open")
                .text(H5P.t("hideAdvanced"))
                .attr("aria-expanded", "false"),
              t.show()),
            n.find(".h5p-embed-code-container").each(function () {
              H5P.jQuery(this).css("height", this.scrollHeight + "px");
            }),
            r());
        }
        n.find(".h5p-expander")
          .click(c)
          .keypress(function (e) {
            if (32 === e.keyCode) return (c.apply(this), !1);
          });
      })
      .on("dialog-closed", function () {
        H5P.trigger(l, "resize");
      }),
      e.open());
  }),
  (H5P.attachToastTo = function (t, e, n) {
    if (void 0 === t || void 0 === e) return;
    function r(e) {
      -1 === i(e).indexOf(t) && (clearTimeout(c), o());
    }
    const i = function (e) {
        var t = (e.composedPath && e.composedPath()) || e.path,
          e = e.target;
        return null != t
          ? t.indexOf(window) < 0
            ? t.concat(window)
            : t
          : e === window
            ? [window]
            : [e].concat(
                (function e(t, n) {
                  n = n || [];
                  t = t.parentNode;
                  return t ? e(t, n.concat(t)) : n;
                })(e),
                window,
              );
      },
      o = function () {
        (document.removeEventListener("click", r),
          a.parentNode && a.parentNode.removeChild(a));
      };
    (((n = n || {}).style = n.style || "h5p-toast"),
      (n.duration = n.duration || 3e3));
    const a = document.createElement("div");
    (a.setAttribute("id", n.style),
      a.classList.add("h5p-toast-disabled"),
      a.classList.add(n.style));
    const s = document.createElement("span");
    ((s.innerHTML = e), a.appendChild(s), document.body.appendChild(a));
    e = (function (e, t, n) {
      (((n = n || {}).offsetHorizontal = n.offsetHorizontal || 0),
        (n.offsetVertical = n.offsetVertical || 0));
      var r = t.getBoundingClientRect(),
        i = e.getBoundingClientRect();
      let o = 0,
        a = 0;
      switch (n.horizontal) {
        case "before":
          o = i.left - r.width - n.offsetHorizontal;
          break;
        case "after":
          o = i.left + i.width + n.offsetHorizontal;
          break;
        case "left":
          o = i.left + n.offsetHorizontal;
          break;
        case "right":
          o = i.left + i.width - r.width - n.offsetHorizontal;
          break;
        default:
          o = i.left + i.width / 2 - r.width / 2 + n.offsetHorizontal;
      }
      switch (n.vertical) {
        case "above":
          a = i.top - r.height - n.offsetVertical;
          break;
        case "below":
          a = i.top + i.height + n.offsetVertical;
          break;
        case "top":
          a = i.top + n.offsetVertical;
          break;
        case "bottom":
          a = i.top + i.height - r.height - n.offsetVertical;
          break;
        case "centered":
          a = i.top + i.height / 2 - r.height / 2 + n.offsetVertical;
          break;
        default:
          a = i.top + i.height + n.offsetVertical;
      }
      const s = document.body;
      e = s.getBoundingClientRect();
      return (
        (n.noOverflowLeft || n.noOverflowX) && o < e.x && (o = e.x),
        (n.noOverflowRight || n.noOverflowX) &&
          o + r.width > e.x + e.width &&
          (o = e.x + e.width - r.width),
        (n.noOverflowTop || n.noOverflowY) && a < e.y && (a = e.y),
        (n.noOverflowBottom || n.noOverflowY) &&
          a + r.height > e.y + e.height &&
          (o = e.y + e.height - r.height),
        { left: o, top: a }
      );
    })(t, a, n.position);
    ((a.style.left = Math.round(e.left) + "px"),
      (a.style.top = Math.round(e.top) + "px"),
      a.classList.remove("h5p-toast-disabled"));
    const c = setTimeout(o, n.duration);
    document.addEventListener("click", r);
  }),
  (H5P.ContentCopyrights = function () {
    var n,
      r = [],
      i = [];
    ((this.setLabel = function (e) {
      n = e;
    }),
      (this.addMedia = function (e) {
        void 0 !== e && r.push(e);
      }),
      (this.addMediaInFront = function (e) {
        void 0 !== e && r.unshift(e);
      }),
      (this.addContent = function (e) {
        void 0 !== e && i.push(e);
      }),
      (this.toString = function () {
        for (var e = "", t = 0; t < r.length; t++) e += r[t];
        for (t = 0; t < i.length; t++) e += i[t];
        return (e =
          "" !== e
            ? '<div class="h5p-content-copyrights">' +
              (e = void 0 !== n ? "<h3>" + n + "</h3>" + e : e) +
              "</div>"
            : e);
      }));
  }),
  (H5P.MediaCopyright = function (e, t, n, r) {
    function i(e) {
      return void 0 === t || void 0 === t[e] ? H5P.t(e) : t[e];
    }
    function o(e, t) {
      var n,
        r = H5P.copyrightLicenses[e],
        i = "";
      (("PD" === e && t) || (i += r.hasOwnProperty("label") ? r.label : r),
        (n =
          r.versions &&
          (t =
            !r.versions.default || (t && r.versions[t])
              ? t
              : r.versions.default) &&
          r.versions[t]
            ? r.versions[t]
            : n) &&
          (i && (i += " "), (i += n.hasOwnProperty("label") ? n.label : n)),
        r.hasOwnProperty("link")
          ? (o = r.link.replace(
              ":version",
              r.linkVersions ? r.linkVersions[t] : t,
            ))
          : n && r.hasOwnProperty("link") && (o = n.link),
        o && (i = '<a href="' + o + '" target="_blank">' + i + "</a>"));
      var o = "";
      return (
        "PD" !== e && "C" !== e && (o += e),
        t && "CC0 1.0" !== t && (o && "GNU GPL" !== e && (o += " "), (o += t)),
        o && (i += " (" + o + ")"),
        "C" === e && (i += " &copy;"),
        i
      );
    }
    var a,
      s = new H5P.DefinitionList();
    if (void 0 !== e) {
      for (var c in r) r.hasOwnProperty(c) && (e[c] = r[c]);
      void 0 === n &&
        (n = [
          "contentType",
          "title",
          "license",
          "author",
          "year",
          "source",
          "licenseExtras",
          "changes",
        ]);
      for (var d = 0; d < n.length; d++) {
        var l,
          u = n[d];
        void 0 !== e[u] &&
          "" !== e[u] &&
          ((l = e[u]),
          "license" === u && (l = o(e.license, e.version)),
          "source" === u &&
            (l = l
              ? '<a href="' + l + '" target="_blank">' + l + "</a>"
              : void 0),
          s.add(new H5P.Field(i(u), l)));
      }
    }
    ((this.setThumbnail = function (e) {
      a = e;
    }),
      (this.undisclosed = function () {
        if (1 === s.size()) {
          var e = s.get(0);
          if (e.getLabel() === i("license") && e.getValue() === o("U"))
            return !0;
        }
        return !1;
      }),
      (this.toString = function () {
        var e = "";
        return this.undisclosed()
          ? e
          : (void 0 !== a && (e += a),
            "" !== (e += s)
              ? '<div class="h5p-media-copyright">' + e + "</div>"
              : e);
      }));
  }),
  (H5P.Thumbnail = function (e, t, n) {
    var r;
    (void 0 !== t && (r = Math.round((t / n) * 100)),
      (this.toString = function () {
        return (
          '<img src="' +
          e +
          '" alt="' +
          H5P.t("thumbnail") +
          '" class="h5p-thumbnail" height="100"' +
          (void 0 === r ? "" : ' width="' + r + '"') +
          "/>"
        );
      }));
  }),
  (H5P.Field = function (e, t) {
    ((this.getLabel = function () {
      return e;
    }),
      (this.getValue = function () {
        return t;
      }));
  }),
  (H5P.DefinitionList = function () {
    var r = [];
    ((this.add = function (e) {
      r.push(e);
    }),
      (this.size = function () {
        return r.length;
      }),
      (this.get = function (e) {
        return r[e];
      }),
      (this.toString = function () {
        for (var e = "", t = 0; t < r.length; t++) {
          var n = r[t];
          e += "<dt>" + n.getLabel() + "</dt><dd>" + n.getValue() + "</dd>";
        }
        return "" === e ? e : '<dl class="h5p-definition-list">' + e + "</dl>";
      }));
  }),
  (H5P.Coords = function (e, t, n, r) {
    return this instanceof H5P.Coords
      ? ((this.x = 0),
        (this.y = 0),
        (this.w = 1),
        (this.h = 1),
        "object" == typeof e
          ? ((this.x = e.x), (this.y = e.y), (this.w = e.w), (this.h = e.h))
          : (void 0 !== e && (this.x = e),
            void 0 !== t && (this.y = t),
            void 0 !== n && (this.w = n),
            void 0 !== r && (this.h = r)),
        this)
      : new H5P.Coords(e, t, n, r);
  }),
  (H5P.libraryFromString = function (e) {
    e = /(.+)\s(\d+)\.(\d+)$/g.exec(e);
    return (
      null !== e && {
        machineName: e[1],
        majorVersion: parseInt(e[2]),
        minorVersion: parseInt(e[3]),
      }
    );
  }),
  (H5P.getLibraryPath = function (e) {
    return void 0 !== H5PIntegration.urlLibraries
      ? H5PIntegration.urlLibraries + "/" + e
      : H5PIntegration.url + "/libraries/" + e;
  }),
  (H5P.cloneObject = function (e, t) {
    var n,
      r = e instanceof Array ? [] : {};
    for (n in e)
      e.hasOwnProperty(n) &&
        (void 0 !== t && t && "object" == typeof e[n]
          ? (r[n] = H5P.cloneObject(e[n], t))
          : (r[n] = e[n]));
    return r;
  }),
  (H5P.trim = function (e) {
    return e.replace(/^\s+|\s+$/g, "");
  }),
  (H5P.jsLoaded = function (e) {
    return (
      (H5PIntegration.loadedJs = H5PIntegration.loadedJs || []),
      -1 !== H5P.jQuery.inArray(e, H5PIntegration.loadedJs)
    );
  }),
  (H5P.cssLoaded = function (e) {
    return (
      (H5PIntegration.loadedCss = H5PIntegration.loadedCss || []),
      -1 !== H5P.jQuery.inArray(e, H5PIntegration.loadedCss)
    );
  }),
  (H5P.shuffleArray = function (e) {
    if (e instanceof Array) {
      var t,
        n,
        r,
        i = e.length;
      if (0 === i) return !1;
      for (; --i; )
        ((t = Math.floor(Math.random() * (i + 1))),
          (n = e[i]),
          (r = e[t]),
          (e[i] = r),
          (e[t] = n));
      return e;
    }
  }),
  (H5P.setFinished = function (e, t, n, r) {
    if (
      ("number" == typeof t || t instanceof Number) &&
      !0 === H5PIntegration.postUserStatistics
    ) {
      function i(e) {
        return Math.round(e.getTime() / 1e3);
      }
      const o = {
        contentId: e,
        score: t,
        maxScore: n,
        opened: i(H5P.opened[e]),
        finished: i(new Date()),
        time: r,
      };
      H5P.jQuery.post(H5PIntegration.ajax.setFinished, o).fail(function () {
        H5P.offlineRequestQueue.add(H5PIntegration.ajax.setFinished, o);
      });
    }
  }),
  Array.prototype.indexOf ||
    (Array.prototype.indexOf = function (e) {
      for (var t = 0; t < this.length; t++) if (this[t] === e) return t;
      return -1;
    }),
  void 0 === String.prototype.trim &&
    (String.prototype.trim = function () {
      return H5P.trim(this);
    }),
  (H5P.trigger = function (e, t, n, r) {
    void 0 !== e.trigger
      ? e.trigger(t, n, r)
      : void 0 !== e.$ && void 0 !== e.$.trigger && e.$.trigger(t);
  }),
  (H5P.on = function (e, t, n) {
    void 0 !== e.on
      ? e.on(t, n)
      : void 0 !== e.$ && void 0 !== e.$.on && e.$.on(t, n);
  }),
  (H5P.createUUID = function () {
    return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(
      /[xy]/g,
      function (e) {
        var t = (16 * Math.random()) | 0;
        return ("x" === e ? t : (3 & t) | 8).toString(16);
      },
    );
  }),
  (H5P.createTitle = function (e, t) {
    if (!e) return "";
    void 0 === t && (t = 60);
    e = H5P.jQuery("<div></div>")
      .text(e.replace(/(<([^>]+)>)/gi, ""))
      .text();
    return (e = e.length > t ? e.substr(0, t - 3) + "..." : e);
  }),
  (function (c) {
    function s(e, t, n, r, i, o, a, s) {
      void 0 !== H5PIntegration.user
        ? ((s = {
            url: H5PIntegration.ajax.contentUserData
              .replace(":contentId", e)
              .replace(":dataType", t)
              .replace(":subContentId", n || 0),
            dataType: "json",
            async: void 0 === s || s,
          }),
          void 0 !== i
            ? ((s.type = "POST"),
              (s.data = {
                data: null === i ? 0 : i,
                preload: o ? 1 : 0,
                invalidate: a ? 1 : 0,
              }))
            : (s.type = "GET"),
          void 0 !== r &&
            ((s.error = function (e, t) {
              r(t);
            }),
            (s.success = function (e) {
              e.success
                ? !1 !== e.data && void 0 !== e.data
                  ? r(void 0, e.data)
                  : r()
                : r(e.message);
            })),
          c.ajax(s))
        : r("Not signed in.");
    }
    ((H5P.getUserData = function (e, n, r, i) {
      ((i = i || 0), (H5PIntegration.contents = H5PIntegration.contents || {}));
      var o = H5PIntegration.contents["cid-" + e] || {},
        a = o.contentUserData;
      if (a && a[i] && void 0 !== a[i][n])
        if ("RESET" !== a[i][n])
          try {
            r(void 0, JSON.parse(a[i][n]));
          } catch (e) {
            r(e);
          }
        else r(void 0, null);
      else
        s(e, n, i, function (e, t) {
          if (e || void 0 === t) r(e, t);
          else {
            (void 0 === o.contentUserData && (o.contentUserData = a = {}),
              void 0 === a[i] && (a[i] = {}),
              (a[i][n] = t));
            try {
              r(void 0, JSON.parse(t));
            } catch (e) {
              r(e);
            }
          }
        });
    }),
      (H5P.setUserData = function (e, t, n, r) {
        var i = H5P.jQuery.extend(
          !0,
          {},
          { subContentId: 0, preloaded: !0, deleteOnChange: !1, async: !0 },
          r,
        );
        try {
          n = JSON.stringify(n);
        } catch (e) {
          return void (i.errorCallback && i.errorCallback(e));
        }
        r = H5PIntegration.contents["cid-" + e];
        (r = void 0 === r ? (H5PIntegration.contents["cid-" + e] = {}) : r)
          .contentUserData || (r.contentUserData = {});
        r = r.contentUserData;
        (void 0 === r[i.subContentId] && (r[i.subContentId] = {}),
          n !== r[i.subContentId][t] &&
            ((r[i.subContentId][t] = n),
            s(
              e,
              t,
              i.subContentId,
              function (e) {
                i.errorCallback && e && i.errorCallback(e);
              },
              n,
              i.preloaded,
              i.deleteOnChange,
              i.async,
            )));
      }),
      (H5P.deleteUserData = function (e, t, n) {
        n = n || 0;
        var r = H5PIntegration.contents["cid-" + e].contentUserData;
        (r && r[n] && r[n][t] && delete r[n][t], s(e, t, n, void 0, null));
      }),
      (H5P.getContentForInstance = function (e) {
        e = "cid-" + e;
        return H5PIntegration &&
          H5PIntegration.contents &&
          H5PIntegration.contents[e]
          ? H5PIntegration.contents[e]
          : void 0;
      }),
      (H5P.ClipboardItem = function (e, t, n) {
        var r = this;
        (t || ((t = "action"), (e = { action: e })),
          (r.specific = e),
          t && e[t] && (r.generic = t),
          n && (r.from = n),
          window.H5PEditor &&
            H5PEditor.contentId &&
            (r.contentId = H5PEditor.contentId),
          r.specific.width ||
            r.specific.height ||
            !r.generic ||
            ((n = r.specific[r.generic]).params.file &&
              n.params.file.width &&
              n.params.file.height &&
              ((r.width = 20),
              (r.height =
                (n.params.file.height / n.params.file.width) * r.width))));
      }),
      (H5P.clipboardify = function (e) {
        (e instanceof H5P.ClipboardItem || (e = new H5P.ClipboardItem(e)),
          H5P.setClipboard(e));
      }),
      (H5P.getClipboard = function () {
        return e();
      }),
      (H5P.setClipboard = function (e) {
        (localStorage.setItem("h5pClipboard", JSON.stringify(e)),
          H5P.externalDispatcher.trigger("datainclipboard", { reset: !1 }));
      }),
      (H5P.getLibraryConfig = function (e) {
        return H5PIntegration.libraryConfig && H5PIntegration.libraryConfig[e]
          ? H5PIntegration.libraryConfig[e]
          : {};
      }));
    var e = function () {
        var t = localStorage.getItem("h5pClipboard");
        if (t) {
          try {
            t = JSON.parse(t);
          } catch (e) {
            return void console.error(
              "Unable to parse JSON from clipboard.",
              e,
            );
          }
          return (
            r(t.specific, function (e) {
              return "#tmp" === e.substr(-4, 4) ||
                !t.contentId ||
                e.match(/^https?:\/\//i)
                ? e
                : H5PEditor.contentId
                  ? "../" + t.contentId + "/" + e
                  : (H5PEditor.contentRelUrl || "../content/") +
                    t.contentId +
                    "/" +
                    e;
            }),
            t.generic && (t.generic = t.specific[t.generic]),
            t
          );
        }
      },
      r = function (e, t) {
        for (var n in e)
          e.hasOwnProperty(n) &&
            e[n] instanceof Object &&
            (void 0 !== (n = e[n]).path && void 0 !== n.mime
              ? (n.path = t(n.path))
              : (void 0 !== n.library &&
                  void 0 !== n.subContentId &&
                  delete n.subContentId,
                r(n, t)));
      };
    c(document).ready(function () {
      window.addEventListener("storage", function (e) {
        "h5pClipboard" === e.key &&
          H5P.externalDispatcher.trigger("datainclipboard", {
            reset: null === e.newValue,
          });
      });
      var i,
        e,
        t = {
          default: "4.0",
          "4.0": H5P.t("licenseCC40"),
          "3.0": H5P.t("licenseCC30"),
          2.5: H5P.t("licenseCC25"),
          "2.0": H5P.t("licenseCC20"),
          "1.0": H5P.t("licenseCC10"),
        };
      ((H5P.copyrightLicenses = {
        U: H5P.t("licenseU"),
        "CC BY": {
          label: H5P.t("licenseCCBY"),
          link: "http://creativecommons.org/licenses/by/:version",
          versions: t,
        },
        "CC BY-SA": {
          label: H5P.t("licenseCCBYSA"),
          link: "http://creativecommons.org/licenses/by-sa/:version",
          versions: t,
        },
        "CC BY-ND": {
          label: H5P.t("licenseCCBYND"),
          link: "http://creativecommons.org/licenses/by-nd/:version",
          versions: t,
        },
        "CC BY-NC": {
          label: H5P.t("licenseCCBYNC"),
          link: "http://creativecommons.org/licenses/by-nc/:version",
          versions: t,
        },
        "CC BY-NC-SA": {
          label: H5P.t("licenseCCBYNCSA"),
          link: "http://creativecommons.org/licenses/by-nc-sa/:version",
          versions: t,
        },
        "CC BY-NC-ND": {
          label: H5P.t("licenseCCBYNCND"),
          link: "http://creativecommons.org/licenses/by-nc-nd/:version",
          versions: t,
        },
        "CC0 1.0": {
          label: H5P.t("licenseCC010"),
          link: "https://creativecommons.org/publicdomain/zero/1.0/",
        },
        "GNU GPL": {
          label: H5P.t("licenseGPL"),
          link: "http://www.gnu.org/licenses/gpl-:version-standalone.html",
          linkVersions: { v3: "3.0", v2: "2.0", v1: "1.0" },
          versions: {
            default: "v3",
            v3: H5P.t("licenseV3"),
            v2: H5P.t("licenseV2"),
            v1: H5P.t("licenseV1"),
          },
        },
        PD: {
          label: H5P.t("licensePD"),
          versions: {
            "CC0 1.0": {
              label: H5P.t("licenseCC010"),
              link: "https://creativecommons.org/publicdomain/zero/1.0/",
            },
            "CC PDM": {
              label: H5P.t("licensePDM"),
              link: "https://creativecommons.org/publicdomain/mark/1.0/",
            },
          },
        },
        "ODC PDDL":
          '<a href="http://opendatacommons.org/licenses/pddl/1.0/" target="_blank">Public Domain Dedication and Licence</a>',
        "CC PDM": {
          label: H5P.t("licensePDM"),
          link: "https://creativecommons.org/publicdomain/mark/1.0/",
        },
        C: H5P.t("licenseC"),
      }),
        H5P.isFramed &&
          !1 === H5P.externalEmbed &&
          H5P.externalDispatcher.on("*", function (e) {
            window.parent.H5P.externalDispatcher.trigger.call(this, e);
          }),
        H5P.preventInit || H5P.init(document.body),
        !1 !== H5PIntegration.saveFreq &&
          ((i = 0),
          (e = function () {
            var e = new Date().getTime();
            if (250 < e - i) {
              i = e;
              for (var t = 0; t < H5P.instances.length; t++) {
                var n,
                  r = H5P.instances[t];
                !(
                  r.getCurrentState instanceof Function ||
                  "function" == typeof r.getCurrentState
                ) ||
                  (void 0 !== (n = r.getCurrentState()) &&
                    H5P.setUserData(r.contentId, "state", n, {
                      deleteOnChange: !0,
                      async: !1,
                    }));
              }
            }
          }),
          H5P.$window.one("beforeunload unload", function () {
            (H5P.$window.off("pagehide beforeunload unload"), e());
          }),
          H5P.$window.on("pagehide", e)));
    });
  })(H5P.jQuery),
  ((H5P = window.H5P = window.H5P || {}).Event = function (e, t, n) {
    ((this.type = e), (this.data = t));
    var r = !1,
      i = !1,
      o = !1;
    (!0 === (n = void 0 === n ? {} : n).bubbles && (r = !0),
      !0 === n.external && (i = !0),
      (this.preventBubbling = function () {
        r = !1;
      }),
      (this.getBubbles = function () {
        return r;
      }),
      (this.scheduleForExternal = function () {
        return !(!i || o) && (o = !0);
      }));
  }),
  (H5P.EventDispatcher = function () {
    var i = this,
      a = {};
    function r(e, t) {
      if (void 0 !== a[e])
        for (var n = a[e].slice(), r = 0; r < n.length; r++) {
          var i = n[r],
            o = i.thisArg || this;
          i.listener.call(o, t);
        }
    }
    ((this.on = function (e, t, n) {
      if ("function" != typeof t)
        throw TypeError("listener must be a function");
      i.trigger("newListener", { type: e, listener: t });
      n = { listener: t, thisArg: n };
      a[e] ? a[e].push(n) : (a[e] = [n]);
    }),
      (this.once = function (e, t, n) {
        if (!(t instanceof Function))
          throw TypeError("listener must be a function");
        var r = function (e) {
          (i.off(e.type, r), t.call(this, e));
        };
        i.on(e, r, n);
      }),
      (this.off = function (e, t) {
        if (void 0 !== t && !(t instanceof Function))
          throw TypeError("listener must be a function");
        if (void 0 !== a[e]) {
          if (void 0 === t)
            return (delete a[e], void i.trigger("removeListener", e));
          for (var n = 0; n < a[e].length; n++)
            if (a[e][n].listener === t) {
              (a[e].splice(n, 1),
                i.trigger("removeListener", e, { listener: t }));
              break;
            }
          a[e].length || delete a[e];
        }
      }),
      (this.trigger = function (e, t, n) {
        void 0 !== e &&
          (e instanceof String || "string" == typeof e
            ? (e = new H5P.Event(e, t, n))
            : void 0 !== t && (e.data = t),
          (t = e.scheduleForExternal()),
          r.call(this, e.type, e),
          r.call(this, "*", e),
          e.getBubbles() &&
            i.parent instanceof H5P.EventDispatcher &&
            (i.parent.trigger instanceof Function ||
              "function" == typeof i.parent.trigger) &&
            i.parent.trigger(e),
          t && H5P.externalDispatcher.trigger.call(this, e));
      }));
  }),
  ((H5P = window.H5P = window.H5P || {}).XAPIEvent = function () {
    H5P.Event.call(
      this,
      "xAPI",
      { statement: {} },
      { bubbles: !0, external: !0 },
    );
  }),
  (H5P.XAPIEvent.prototype = Object.create(H5P.Event.prototype)),
  (H5P.XAPIEvent.prototype.constructor = H5P.XAPIEvent),
  (H5P.XAPIEvent.prototype.setScoredResult = function (e, t, n, r, i) {
    ((this.data.statement.result = {}),
      void 0 !== e &&
        (void 0 === t
          ? (this.data.statement.result.score = { raw: e })
          : ((this.data.statement.result.score = { min: 0, max: t, raw: e }),
            0 < t &&
              (this.data.statement.result.score.scaled =
                Math.round((e / t) * 1e4) / 1e4))),
      (this.data.statement.result.completion =
        void 0 === r
          ? "completed" === this.getVerb() || "answered" === this.getVerb()
          : r),
      void 0 !== i && (this.data.statement.result.success = i),
      n &&
        n.activityStartTime &&
        ((n = Math.round((Date.now() - n.activityStartTime) / 10) / 100),
        (this.data.statement.result.duration = "PT" + n + "S")));
  }),
  (H5P.XAPIEvent.prototype.setVerb = function (e) {
    -1 !== H5P.jQuery.inArray(e, H5P.XAPIEvent.allowedXAPIVerbs)
      ? (this.data.statement.verb = {
          id: "http://adlnet.gov/expapi/verbs/" + e,
          display: { "en-US": e },
        })
      : void 0 !== e.id && (this.data.statement.verb = e);
  }),
  (H5P.XAPIEvent.prototype.getVerb = function (e) {
    var t = this.data.statement;
    return "verb" in t ? (!0 === e ? t.verb : t.verb.id.slice(31)) : null;
  }),
  (H5P.XAPIEvent.prototype.setObject = function (e) {
    e.contentId
      ? ((this.data.statement.object = {
          id: this.getContentXAPIId(e),
          objectType: "Activity",
          definition: {
            extensions: {
              "http://h5p.org/x-api/h5p-local-content-id": e.contentId,
            },
          },
        }),
        e.subContentId
          ? ((this.data.statement.object.definition.extensions[
              "http://h5p.org/x-api/h5p-subContentId"
            ] = e.subContentId),
            "function" == typeof e.getTitle &&
              (this.data.statement.object.definition.name = {
                "en-US": e.getTitle(),
              }))
          : (e = H5P.getContentForInstance(e.contentId)) &&
            e.metadata &&
            e.metadata.title &&
            (this.data.statement.object.definition.name = {
              "en-US": H5P.createTitle(e.metadata.title),
            }))
      : (this.data.statement.object = { definition: {} });
  }),
  (H5P.XAPIEvent.prototype.setContext = function (e) {
    (e.parent &&
      (e.parent.contentId || e.parent.subContentId) &&
      (this.data.statement.context = {
        contextActivities: {
          parent: [
            { id: this.getContentXAPIId(e.parent), objectType: "Activity" },
          ],
        },
      }),
      e.libraryInfo &&
        (void 0 === this.data.statement.context &&
          (this.data.statement.context = { contextActivities: {} }),
        (this.data.statement.context.contextActivities.category = [
          {
            id:
              "http://h5p.org/libraries/" + e.libraryInfo.versionedNameNoSpaces,
            objectType: "Activity",
          },
        ])));
  }),
  (H5P.XAPIEvent.prototype.setActor = function () {
    if (void 0 !== H5PIntegration.user)
      this.data.statement.actor = {
        name: H5PIntegration.user.name,
        mbox: "mailto:" + H5PIntegration.user.mail,
        objectType: "Agent",
      };
    else {
      var t;
      try {
        localStorage.H5PUserUUID
          ? (t = localStorage.H5PUserUUID)
          : ((t = H5P.createUUID()), (localStorage.H5PUserUUID = t));
      } catch (e) {
        t = "not-trackable-" + H5P.createUUID();
      }
      this.data.statement.actor = {
        account: { name: t, homePage: H5PIntegration.siteUrl },
        objectType: "Agent",
      };
    }
  }),
  (H5P.XAPIEvent.prototype.getMaxScore = function () {
    return this.getVerifiedStatementValue(["result", "score", "max"]);
  }),
  (H5P.XAPIEvent.prototype.getScore = function () {
    return this.getVerifiedStatementValue(["result", "score", "raw"]);
  }),
  (H5P.XAPIEvent.prototype.getContentXAPIId = function (e) {
    var t;
    return (
      e.contentId &&
        H5PIntegration &&
        H5PIntegration.contents &&
        H5PIntegration.contents["cid-" + e.contentId] &&
        ((t = H5PIntegration.contents["cid-" + e.contentId].url),
        e.subContentId && (t += "?subContentId=" + e.subContentId)),
      t
    );
  }),
  (H5P.XAPIEvent.prototype.isFromChild = function () {
    var e = this.getVerifiedStatementValue([
      "context",
      "contextActivities",
      "parent",
      0,
      "id",
    ]);
    return !e || -1 === e.indexOf("subContentId");
  }),
  (H5P.XAPIEvent.prototype.getVerifiedStatementValue = function (e) {
    for (var t = this.data.statement, n = 0; n < e.length; n++) {
      if (void 0 === t[e[n]]) return null;
      t = t[e[n]];
    }
    return t;
  }),
  (H5P.XAPIEvent.allowedXAPIVerbs = [
    "answered",
    "asked",
    "attempted",
    "attended",
    "commented",
    "completed",
    "exited",
    "experienced",
    "failed",
    "imported",
    "initialized",
    "interacted",
    "launched",
    "mastered",
    "passed",
    "preferred",
    "progressed",
    "registered",
    "responded",
    "resumed",
    "scored",
    "shared",
    "suspended",
    "terminated",
    "voided",
    "downloaded",
    "copied",
    "accessed-reuse",
    "accessed-embed",
    "accessed-copyright",
  ]),
  ((H5P = window.H5P = window.H5P || {}).externalDispatcher =
    new H5P.EventDispatcher()),
  (H5P.EventDispatcher.prototype.triggerXAPI = function (e, t) {
    this.trigger(this.createXAPIEventTemplate(e, t));
  }),
  (H5P.EventDispatcher.prototype.createXAPIEventTemplate = function (e, t) {
    var n = new H5P.XAPIEvent();
    if ((n.setActor(), n.setVerb(e), void 0 !== t))
      for (var r in t) n.data.statement[r] = t[r];
    return (
      "object" in n.data.statement || n.setObject(this),
      "context" in n.data.statement || n.setContext(this),
      n
    );
  }),
  (H5P.EventDispatcher.prototype.triggerXAPICompleted = function (e, t, n) {
    this.triggerXAPIScored(e, t, "completed", !0, n);
  }),
  (H5P.EventDispatcher.prototype.triggerXAPIScored = function (e, t, n, r, i) {
    n = this.createXAPIEventTemplate(n);
    (n.setScoredResult(e, t, this, r, i), this.trigger(n));
  }),
  (H5P.EventDispatcher.prototype.setActivityStarted = function () {
    void 0 === this.activityStartTime &&
      (void 0 !== this.contentId &&
        void 0 !== H5PIntegration.contents &&
        void 0 !== H5PIntegration.contents["cid-" + this.contentId] &&
        this.triggerXAPI("attempted"),
      (this.activityStartTime = Date.now()));
  }),
  (H5P.xAPICompletedListener = function (e) {
    var t, n;
    ("completed" !== e.getVerb() && "answered" !== e.getVerb()) ||
      e.getVerifiedStatementValue(["context", "contextActivities", "parent"]) ||
      ((t = e.getScore()),
      (n = e.getMaxScore()),
      (e = e.getVerifiedStatementValue([
        "object",
        "definition",
        "extensions",
        "http://h5p.org/x-api/h5p-local-content-id",
      ])),
      H5P.setFinished(e, t, n));
  }) /*!@license js/h5p-content-type.js by Joubel and other contributors, licensed under GNU GENERAL PUBLIC LICENSE Version 3*/,
  (H5P.ContentType = function (e) {
    function t() {}
    return (
      ((t.prototype = new H5P.EventDispatcher()).isRoot = function () {
        return e;
      }),
      (t.prototype.getLibraryFilePath = function (e) {
        return (
          H5P.getLibraryPath(this.libraryInfo.versionedNameNoSpaces) + "/" + e
        );
      }),
      t
    );
  }) /*!@license js/h5p-confirmation-dialog.js by Joubel and other contributors, licensed under GNU GENERAL PUBLIC LICENSE Version 3*/,
  (H5P.ConfirmationDialog = (function (H) {
    "use strict";
    function e(n) {
      H.call(this);
      var r = this;
      H5P.ConfirmationDialog.uniqueId += 1;
      var e = H5P.ConfirmationDialog.uniqueId;
      function t(e) {
        (r.hide(), r.trigger("confirmed"), e.preventDefault());
      }
      function i(e) {
        (r.hide(), r.trigger("canceled"), e.preventDefault());
      }
      function o(e, t) {
        (e.focus(), t.preventDefault());
      }
      (((n = n || {}).headerText =
        n.headerText || H5P.t("confirmDialogHeader")),
        (n.dialogText = n.dialogText || H5P.t("confirmDialogBody")),
        (n.cancelText = n.cancelText || H5P.t("cancelLabel")),
        (n.confirmText = n.confirmText || H5P.t("confirmLabel")));
      var a = 32,
        s = 8,
        c = !1,
        d = document.createElement("div");
      d.classList.add("h5p-confirmation-dialog-background", "hidden", "hiding");
      var l = document.createElement("div");
      (l.classList.add("h5p-confirmation-dialog-popup", "hidden"),
        n.classes &&
          n.classes.forEach(function (e) {
            l.classList.add(e);
          }),
        l.setAttribute("role", "dialog"),
        l.setAttribute(
          "aria-labelledby",
          "h5p-confirmation-dialog-dialog-text-" + e,
        ),
        d.appendChild(l),
        l.addEventListener("keydown", function (e) {
          27 === e.which && i(e);
        }));
      var u = document.createElement("div");
      (u.classList.add("h5p-confirmation-dialog-header"), l.appendChild(u));
      var h = document.createElement("div");
      (h.classList.add("h5p-confirmation-dialog-header-text"),
        (h.innerHTML = n.headerText),
        u.appendChild(h));
      u = document.createElement("div");
      (u.classList.add("h5p-confirmation-dialog-body"), l.appendChild(u));
      h = document.createElement("div");
      (h.classList.add("h5p-confirmation-dialog-text"),
        (h.innerHTML = n.dialogText),
        (h.id = "h5p-confirmation-dialog-dialog-text-" + e),
        u.appendChild(h));
      h = document.createElement("div");
      (h.classList.add("h5p-confirmation-dialog-buttons"), u.appendChild(h));
      var p = document.createElement("button");
      (p.classList.add("h5p-core-cancel-button"),
        (p.textContent = n.cancelText));
      var f = document.createElement("button");
      (f.classList.add("h5p-core-button"),
        f.classList.add("h5p-confirmation-dialog-confirm-button"),
        (f.textContent = n.confirmText));
      var g,
        m,
        u = document.createElement("button");
      (u.classList.add("h5p-confirmation-dialog-exit"),
        u.setAttribute("aria-hidden", "true"),
        (u.tabIndex = -1),
        (u.title = n.cancelText),
        p.addEventListener("click", i),
        p.addEventListener("keydown", function (e) {
          32 === e.which ? i(e) : 9 === e.which && e.shiftKey && o(f, e);
        }),
        n.hideCancel ? h.classList.add("center") : h.appendChild(p),
        f.addEventListener("click", t),
        f.addEventListener("keydown", function (e) {
          32 === e.which
            ? t(e)
            : 9 !== e.which || e.shiftKey || o(n.hideCancel ? f : p, e);
        }),
        h.appendChild(f),
        u.addEventListener("click", i),
        u.addEventListener("keydown", function (e) {
          32 === e.which && i(e);
        }),
        n.hideExit || l.appendChild(u));
      var v,
        y = [],
        b = [];
      this.appendTo = function (e) {
        return ((g = e), this);
      };
      var P = function (e) {
          d.contains(e.target) || (e.preventDefault(), f.focus());
        },
        x = function (e) {
          for (
            var t = [], n = e.parentNode.children, r = 0;
            r < n.length;
            r += 1
          )
            ((t[r] = !!n[r].getAttribute("aria-hidden")),
              n[r] !== e && n[r].setAttribute("aria-hidden", !0));
          return t;
        },
        w = function (e, t) {
          for (var n = e.parentNode.children, r = 0; r < n.length; r += 1)
            n[r] === e || t[r] || n[r].removeAttribute("aria-hidden");
        };
      ((this.show = function (e) {
        var t;
        return (
          (v = document.activeElement),
          g.appendChild(d),
          (m = g.parentNode || g).addEventListener("focus", P, !0),
          (y = x(g)),
          (b = x(d)),
          d.classList.remove("hidden"),
          (t = e),
          (e = parseInt(l.style.top, 10)),
          (e =
            (e = (e = void 0 !== t ? t : e) || 0) + l.offsetHeight >
            g.offsetHeight
              ? g.offsetHeight - l.offsetHeight - s
              : e) -
            a <=
            0 && ((e = a + s), (c = !0)),
          (l.style.top = e + "px"),
          setTimeout(function () {
            (l.classList.remove("hidden"),
              d.classList.remove("hiding"),
              setTimeout(function () {
                var e;
                (f.focus(),
                  c &&
                    n.instance &&
                    ((e = parseInt(l.offsetHeight, 10) + a + 2 * s),
                    r.setViewPortMinimumHeight(e),
                    n.instance.trigger("resize"),
                    (c = !1)));
              }, 100));
          }, 0),
          this
        );
      }),
        (this.hide = function () {
          return (
            d.classList.add("hiding"),
            l.classList.add("hidden"),
            m.removeAttribute("aria-hidden"),
            m.removeEventListener("focus", P, !0),
            n.skipRestoreFocus || v.focus(),
            w(g, y),
            w(d, b),
            setTimeout(function () {
              (d.classList.add("hidden"),
                g.removeChild(d),
                r.setViewPortMinimumHeight(null));
            }, 100),
            this
          );
        }),
        (this.getElement = function () {
          return l;
        }),
        (this.getPreviouslyFocused = function () {
          return v;
        }),
        (this.setViewPortMinimumHeight = function (e) {
          (
            document.querySelector(".h5p-container") || document.body
          ).style.minHeight = "number" == typeof e ? e + "px" : e;
        }));
    }
    return ((e.prototype = Object.create(H.prototype)).constructor = e);
  })(H5P.EventDispatcher)),
  (H5P.ConfirmationDialog.uniqueId =
    -1) /*!@license js/h5p-action-bar.js by Joubel and other contributors, licensed under GNU GENERAL PUBLIC LICENSE Version 3*/,
  (H5P.ActionBar = (function (n) {
    "use strict";
    function e(e) {
      n.call(this);
      function t(e, t) {
        function n() {
          r.trigger(e);
        }
        (H5P.jQuery("<li/>", {
          class: "h5p-button h5p-noselect h5p-" + (t || e),
          role: "button",
          tabindex: 0,
          title: H5P.t(e + "Description"),
          html: H5P.t(e),
          on: {
            click: n,
            keypress: function (e) {
              32 === e.which && (n(), e.preventDefault());
            },
          },
          appendTo: o,
        }),
          (i = !0));
      }
      var r = this,
        i = !1,
        o = H5P.jQuery('<ul class="h5p-actions"></ul>');
      ((e.export || e.copy) && t("reuse", "export"),
        e.copyright && t("copyrights"),
        e.embed && t("embed"),
        e.icon &&
          (H5P.jQuery(
            '<li><a class="h5p-link" href="http://h5p.org" target="_blank" title="' +
              H5P.t("h5pDescription") +
              '"></a></li>',
          ).appendTo(o),
          (i = !0)),
        (r.getDOMElement = function () {
          return o;
        }),
        (r.hasActions = function () {
          return i;
        }));
    }
    return ((e.prototype = Object.create(n.prototype)).constructor = e);
  })(
    (H5P.jQuery, H5P.EventDispatcher),
  )) /*!@license js/request-queue.js by Joubel and other contributors, licensed under GNU GENERAL PUBLIC LICENSE Version 3*/,
  (H5P.RequestQueue = (function (n, t) {
    function e(e) {
      (t.call(this),
        (this.processingQueue = !1),
        (this.showToast = (e = e || {}).showToast),
        (this.itemName = "requestQueue"));
    }
    return (
      (e.prototype.add = function (e, t) {
        if (!window.localStorage) return !1;
        let n = this.getStoredRequests();
        return (
          (n = n || []),
          n.push({ url: e, data: t }),
          window.localStorage.setItem(this.itemName, JSON.stringify(n)),
          this.trigger("requestQueued", {
            storedStatements: n,
            processingQueue: this.processingQueue,
          }),
          !0
        );
      }),
      (e.prototype.getStoredRequests = function () {
        if (!window.localStorage) return !1;
        var e = window.localStorage.getItem(this.itemName);
        return e ? JSON.parse(e) : [];
      }),
      (e.prototype.clearQueue = function () {
        return (
          !!window.localStorage &&
          (window.localStorage.removeItem(this.itemName), !0)
        );
      }),
      (e.prototype.resumeQueue = function () {
        if (!H5PIntegration || !window.navigator || !window.localStorage)
          return !1;
        if (this.processingQueue) return !1;
        var e = this.getStoredRequests(),
          t = e.length;
        return (
          this.clearQueue(),
          t
            ? ((this.processingQueue = !0), this.processQueue(e))
            : this.trigger("emptiedQueue", e),
          !0
        );
      }),
      (e.prototype.processQueue = function (e) {
        var t;
        e.length &&
          (this.trigger("processingQueue"),
          (t = e.shift()),
          n
            .post(t.url, t.data)
            .fail(this.onQueuedRequestFail.bind(this, t))
            .always(this.onQueuedRequestProcessed.bind(this, e)));
      }),
      (e.prototype.onQueuedRequestFail = function (e) {
        window.navigator.onLine || this.add(e.url, e.data);
      }),
      (e.prototype.onQueuedRequestProcessed = function (e) {
        e.length
          ? this.processQueue(e)
          : ((this.processingQueue = !1),
            (e = this.getStoredRequests()),
            this.trigger("queueEmptied", e));
      }),
      (e.prototype.displayToastMessage = function (e, t, n) {
        (this.showToast || t) &&
          ((n = H5P.jQuery.extend(
            !0,
            {},
            {
              position: {
                horizontal: "centered",
                vertical: "centered",
                noOverflowX: !0,
              },
            },
            n,
          )),
          H5P.attachToastTo(H5P.jQuery(".h5p-content:first")[0], e, n));
      }),
      e
    );
  })(H5P.jQuery, H5P.EventDispatcher)),
  (H5P.OfflineRequestQueue = (function (P, x) {
    return function (e) {
      const n = new P();
      n.clearQueue();
      let r = null;
      const i = [10, 20, 40, 60, 120, 300, 600];
      let o = -1,
        t = null,
        a = !1,
        s = !1,
        c = !1;
      e = e.instance;
      const d = new x({
          headerText: H5P.t("offlineDialogHeader"),
          dialogText: H5P.t("offlineDialogBody"),
          confirmText: H5P.t("offlineDialogRetryButtonLabel"),
          hideCancel: !0,
          hideExit: !0,
          classes: ["offline"],
          instance: e,
          skipRestoreFocus: !0,
        }),
        l = d.getElement(),
        u = document.createElement("div");
      (u.classList.add("count-down"),
        (u.innerHTML = H5P.t("offlineDialogRetryMessage").replace(
          ":num",
          '<span class="count-down-num">0</span>',
        )),
        l.querySelector(".h5p-confirmation-dialog-text").appendChild(u));
      const h = u.querySelector(".count-down-num"),
        p = document.createElement("div");
      p.classList.add("throbber-wrapper");
      const f = document.createElement("div");
      (f.classList.add("sending-requests-throbber"),
        p.appendChild(f),
        n.on(
          "requestQueued",
          function (e) {
            if (!e.data || !e.data.processingQueue) {
              if (!a) {
                const t = document.body.querySelector(".h5p-content");
                if (!t) return;
                (d.appendTo(t), t.appendChild(p), (a = !0));
              }
              y();
            }
          }.bind(this),
        ),
        n.on(
          "queueEmptied",
          function (e) {
            e.data && e.data.length
              ? y(!0)
              : (clearInterval(t),
                g(!1),
                (o = -1),
                s && (d.hide(), (s = !1)),
                n.displayToastMessage(H5P.t("offlineSuccessfulSubmit"), !0, {
                  position: { vertical: "top", offsetVertical: "100" },
                }));
          }.bind(this),
        ),
        d.on(
          "confirmed",
          function () {
            ((s = !1),
              setTimeout(function () {
                m();
              }, 100));
          }.bind(this),
        ),
        window.addEventListener(
          "online",
          function () {
            m();
          }.bind(this),
        ),
        window.addEventListener(
          "message",
          function (e) {
            window.parent === e.source &&
              "h5p" === e.data.context &&
              "queueRequest" === e.data.action &&
              this.add(e.data.url, e.data.data);
          }.bind(this),
        ));
      const g = function (e) {
          ((c = !c),
            void 0 !== e && (c = e),
            c && s && (d.hide(), (s = !1)),
            c ? p.classList.add("show") : p.classList.remove("show"));
        },
        m = function () {
          (clearInterval(t), g(!0), n.resumeQueue());
        },
        v = function () {
          ((o += 1), o >= i.length && (o = i.length - 1));
        },
        y = function (e) {
          s ||
            (g(!1),
            s ||
              (e
                ? setTimeout(function () {
                    d.show(0);
                  }, 100)
                : d.show(0)),
            (s = !0),
            (r = new Date().getTime()),
            v(),
            clearInterval(t),
            (t = setInterval(b, 100)));
        },
        b = function () {
          var e = new Date().getTime(),
            e = Math.floor((e - r) / 1e3);
          const t = i[o] - e;
          ((h.textContent = t.toString()), t <= 0 && m());
        };
      this.add = function (e, t) {
        if (window.navigator.onLine) return !1;
        n.add(e, t);
      };
    };
  })(H5P.RequestQueue, H5P.ConfirmationDialog)),
  ((H5P = H5P || {}).Transition = (function () {
    Transition = {
      transitionEndEventNames: {
        WebkitTransition: "webkitTransitionEnd",
        transition: "transitionend",
        MozTransition: "transitionend",
        OTransition: "oTransitionEnd",
        msTransition: "MSTransitionEnd",
      },
      cache: [],
      getVendorPropertyName: function (e) {
        if (void 0 !== Transition.cache[e]) return Transition.cache[e];
        var t = document.createElement("div");
        if (e in t.style) Transition.cache[e] = e;
        else {
          var n = ["Moz", "Webkit", "O", "ms"],
            r = e.charAt(0).toUpperCase() + e.substr(1);
          if (e in t.style) Transition.cache[e] = e;
          else
            for (var i = 0; i < n.length; ++i) {
              var o = n[i] + r;
              if (o in t.style) {
                Transition.cache[e] = o;
                break;
              }
            }
        }
        return Transition.cache[e];
      },
      getTransitionEndEventName: function () {
        return (
          Transition.transitionEndEventNames[
            Transition.getVendorPropertyName("transition")
          ] || void 0
        );
      },
      onTransitionEnd: function (e, t, n) {
        ((n = n || 1e3),
          (Transition.transitionEndEventName =
            Transition.transitionEndEventName ||
            Transition.getTransitionEndEventName()));
        function r() {
          i ||
            (e.off(Transition.transitionEndEventName, t),
            (i = !0),
            clearTimeout(o),
            t());
        }
        var i = !1,
          o = setTimeout(function () {
            r();
          }, n);
        e.on(Transition.transitionEndEventName, function () {
          r();
        });
      },
    };
    function r(e, t) {
      var n;
      t >= e.length ||
        ((n = e[t]),
        H5P.Transition.onTransitionEnd(
          n.$element,
          function () {
            (n.end && n.end(), !0 !== n.break && r(e, t + 1));
          },
          n.timeout || void 0,
        ));
    }
    return (
      (Transition.sequence = function (e) {
        r(e, 0);
      }),
      Transition
    );
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelHelpTextDialog = (function (l) {
    var u = 0;
    function e(e, t, n) {
      H5P.EventDispatcher.call(this);
      var r = this,
        i = "joubel-help-text-header-" + ++u,
        o = "joubel-help-text-body-" + u,
        a = l("<div>", {
          class: "joubel-help-text-dialog-box",
          role: "dialog",
          "aria-labelledby": i,
          "aria-describedby": o,
        });
      l("<div>", { class: "joubel-help-text-dialog-background" }).appendTo(a);
      var s = l("<div>", {
        class: "joubel-help-text-dialog-container",
      }).appendTo(a);
      (l("<div>", {
        class: "joubel-help-text-header",
        id: i,
        role: "header",
        html: e,
      }).appendTo(s),
        l("<div>", {
          class: "joubel-help-text-body",
          id: o,
          html: t,
          role: "document",
          tabindex: 0,
        }).appendTo(s));
      function c() {
        (a.remove(), r.trigger("closed"));
      }
      var d = l("<div>", {
        class: "joubel-help-text-remove",
        role: "button",
        title: n,
        tabindex: 1,
        click: c,
        keydown: function (e) {
          -1 !== [32, 13].indexOf(e.which) && (e.preventDefault(), c());
        },
      }).appendTo(s);
      ((r.getElement = function () {
        return a;
      }),
        (r.focus = function () {
          d.focus();
        }));
    }
    return ((e.prototype = Object.create(
      H5P.EventDispatcher.prototype,
    )).constructor = e);
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelMessageDialog = (function (o) {
    return function (e, t) {
      function n() {
        (r.remove(), clearTimeout(i), e.off("click.messageDialog"));
      }
      var r = o("<div/>", { class: "joubel-message-dialog", text: t }).appendTo(
          e,
        ),
        i = setTimeout(n, 3e3);
      return (e.on("click.messageDialog", n), r);
    };
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelProgressCircle = (function (s) {
    function e(t, e, n, r) {
      ((n = n || "#f0f0f0"), (r = r || "#ffffff"));
      var i = this.hexToRgb((e = e || "#1a73d9"));
      try {
        if ("" === (t = Number(t))) throw "is empty";
        if (isNaN(t)) throw "is not a number";
      } catch (e) {
        t = "err";
      }
      100 < t && (t = 100);
      var o =
          "rgb(" +
          parseInt(i.r, 10) +
          "," +
          parseInt(i.g, 10) +
          "," +
          parseInt(i.b, 10) +
          ")",
        a = s("<div/>", { class: "joubel-progress-circle-wrapper" }),
        e = s("<div/>", {
          class: "joubel-progress-circle-active-border",
        }).appendTo(a),
        i = s("<div/>", { class: "joubel-progress-circle-circle" }).appendTo(e);
      s("<span/>", {
        text: t + "%",
        class: "joubel-progress-circle-percentage",
      }).appendTo(i);
      t *= 3.6;
      return (
        (t <= 180
          ? e.css(
              "background-image",
              "linear-gradient(" +
                (90 + t) +
                "deg, transparent 50%, " +
                n +
                " 50%),linear-gradient(90deg, " +
                n +
                " 50%, transparent 50%)",
            )
          : e.css(
              "background-image",
              "linear-gradient(" +
                (t - 90) +
                "deg, transparent 50%, " +
                o +
                " 50%),linear-gradient(90deg, " +
                n +
                " 50%, transparent 50%)",
            )
        )
          .css("border", "2px solid" + r)
          .css("background-color", o),
        (this.$activeBorder = e),
        (this.$backgroundCircle = i),
        (this.$wrapper = a),
        this.initResizeFunctionality(),
        a
      );
    }
    return (
      (e.prototype.initResizeFunctionality = function () {
        var e = this;
        (s(window).resize(function () {
          setTimeout(function () {
            e.resize();
          });
        }),
          setTimeout(function () {
            e.resize();
          }, 0));
      }),
      (e.prototype.resize = function () {
        var e,
          t,
          n,
          r = this.$wrapper.parent();
        void 0 !== r &&
          r &&
          ((n = parseInt(r.css("font-size"), 10)),
          (t =
            (e =
              parseInt(n / 4.5, 10) % 2 == 0
                ? parseInt(n / 4.5, 10) + 4
                : parseInt(n / 4.5, 10) + 5) / 2),
          this.$activeBorder.css({
            width: (r = 3.75 * n),
            height: (n = 3.75 * n),
          }),
          this.$backgroundCircle.css({
            width: r - e,
            height: n - e,
            top: t,
            left: t,
          }));
      }),
      (e.prototype.hexToRgb = function (e) {
        e = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);
        return e
          ? {
              r: parseInt(e[1], 16),
              g: parseInt(e[2], 16),
              b: parseInt(e[3], 16),
            }
          : null;
      }),
      e
    );
  })(H5P.jQuery)),
  ((H5P = H5P || {}).SimpleRoundedButton = (function (n) {
    return function (e) {
      var t = n("<div>", {
        class: "joubel-simple-rounded-button",
        title: e,
        role: "button",
        tabindex: "0",
      }).keydown(function (e) {
        -1 !== [32, 13].indexOf(e.which) &&
          (n(this).click(), e.preventDefault());
      });
      return (
        n("<span>", {
          class: "joubel-simple-rounded-button-text",
          html: e,
        }).appendTo(t),
        t
      );
    };
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelSpeechBubble = (function (o) {
    var a,
      s,
      c,
      d,
      l,
      u,
      h = !!navigator.userAgent.match(/iPod|iPhone|iPad/g);
    function p(e) {
      var t = e.closest(".h5p-frame");
      return (t = !t.length ? e.closest(".h5p-container") : t);
    }
    function f() {
      g(a, s, u, c, d);
    }
    function g(e, t, n, r, i) {
      var o = (function (e, t) {
          ((e = e[0].getBoundingClientRect()),
            (t = t[0].getBoundingClientRect()));
          return {
            top: t.top - e.top,
            right: e.right - t.right,
            bottom: e.bottom - t.bottom,
            left: t.left - e.left,
            innerWidth: t.width,
            innerHeight: t.height,
            outerWidth: e.width,
            outerHeight: e.height,
          };
        })(p(t), t),
        a = o.bottom > o.top ? "bottom" : "top",
        s = 0.9 * o.outerWidth,
        n = n < s ? n : s,
        s = (function (e, t) {
          var n = {},
            r = e / 2;
          ((n.top = t.top + t.innerHeight),
            (n.bottom = t.bottom + t.innerHeight + 9),
            t.left < r
              ? (n.left = 3)
              : t.left + r > t.outerWidth
                ? (n.left = t.outerWidth - e - 3)
                : (n.left = t.left - r + t.innerWidth / 2));
          return n;
        })(n, o),
        t = (function (e, t, n, r) {
          var i = {},
            e = e - 20;
          ((i.left = n.left - t.left + r / 2 - 6), i.left < 9 && (i.left = 9));
          i.left > e && (i.left = e);
          return ((i.top = -6), (i.bottom = -6), i);
        })(n, s, o, t.width());
      e.css(
        ((e = n),
        (n = s),
        (s = 16),
        "top" === a
          ? {
              width: e + "px",
              bottom: n.bottom + "px",
              left: n.left + "px",
              fontSize: s + "px",
              top: "",
            }
          : {
              width: e + "px",
              top: n.top + "px",
              left: n.left + "px",
              fontSize: s + "px",
              bottom: "",
            }),
      );
      ((t = t),
        (t =
          "top" === a
            ? { bottom: t.bottom + "px", left: t.left + "px", top: "" }
            : { top: t.top + "px", left: t.left + "px", bottom: "" }));
      (r.css(t), i.css(t));
    }
    H5P.externalDispatcher.on("domHidden", function (e) {
      void 0 !== a && 0 !== e.data.$dom.find(s).length && m();
    });
    var m = function () {
      (H5P.$body.off("mousedown.speechBubble"),
        H5P.$window.off("resize", "", f),
        s.parents(".h5p-dialog").off("mousedown.speechBubble"),
        h && H5P.$body.css("cursor", ""),
        void 0 !== a &&
          (a.removeClass("show"),
          clearTimeout(l),
          (l = setTimeout(function () {
            (a.remove(), (a = void 0));
          }, 500))));
    };
    function v(e) {
      e.target !== s[0] && (m(), (s = void 0));
    }
    return function (e, t, n) {
      ((u = n = n || 400),
        (s = e),
        (this.isCurrent = function (e) {
          return e.is(s);
        }),
        (this.remove = function () {
          m();
        }),
        void 0 !== a && m());
      var r,
        i = p(e);
      return (
        (r = a) &&
          (clearTimeout(l),
          r.removeClass("show"),
          setTimeout(function () {
            r && (r.remove(), (r = void 0));
          }, 500)),
        (c = o('<div class="joubel-speech-bubble-tail"></div>')),
        (d = o('<div class="joubel-speech-bubble-inner-tail"></div>')),
        (t = o(
          '<div class="joubel-speech-bubble-inner"><div class="joubel-speech-bubble-text">' +
            t +
            "</div></div>",
        ).prepend(d)),
        (a = o('<div class="joubel-speech-bubble" aria-live="assertive">')
          .append([c, t])
          .appendTo(i)),
        setTimeout(function () {
          a.addClass("show");
        }, 0),
        g(a, s, n, c, d),
        H5P.$body.on("mousedown.speechBubble", v),
        H5P.$window.on("resize", "", f),
        e.parents(".h5p-dialog").on("mousedown.speechBubble", v),
        h && H5P.$body.css("cursor", "pointer"),
        this
      );
    };
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelThrobber = (function (e) {
    return function () {
      return e("<div/>", { class: "h5p-throbber" });
    };
  })(H5P.jQuery)),
  /*!@license H5P.JoubelUI-1.3/js/joubel-tip.js by Joubel licensed under unknown license*/ (H5P.JoubelTip =
    (function (s) {
      var c = s("<div/>");
      return function (t, n) {
        var r,
          e = c.html(t).text().trim();
        if ("" !== e) {
          n = s.extend(
            { tipLabel: e, helpIcon: !1, showSpeechBubble: !0, tabcontrol: !1 },
            n,
          );
          var i = s("<div/>", {
            class:
              "joubel-tip-container" + (n.showSpeechBubble ? "" : " be-quiet"),
            "aria-label": n.tipLabel,
            "aria-expanded": !1,
            role: "button",
            tabindex: n.tabcontrol ? -1 : 0,
            click: function (e) {
              (o(), e.preventDefault());
            },
            keydown: function (e) {
              32 === e.which || 13 === e.which
                ? (o(), e.stopPropagation(), e.preventDefault())
                : o(!1);
            },
            html:
              '<span class="joubel-icon-tip-normal ' +
              (n.helpIcon ? " help-icon" : "") +
              '"><span class="h5p-icon-shadow"></span><span class="h5p-icon-speech-bubble"></span><span class="h5p-icon-info"></span></span>',
          });
          const a = s("<div>", {
            class: "hidden-but-read",
            "aria-live": "polite",
            appendTo: i,
          });
          var o = function (e) {
            void 0 !== r && r.isCurrent(i)
              ? (r.remove(),
                (r = void 0),
                i.attr("aria-expanded", !1),
                a.html(""))
              : !1 !== e &&
                n.showSpeechBubble &&
                ((r = H5P.JoubelSpeechBubble(i, t)),
                i.attr("aria-expanded", !0),
                a.html(t));
          };
          return i;
        }
      };
    })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelSlider = (function (t) {
    function e(e) {
      (H5P.EventDispatcher.call(this),
        (this.$slider = t(
          "<div>",
          t.extend({ class: "h5p-joubel-ui-slider" }, e),
        )),
        (this.$slides = []),
        (this.currentIndex = 0),
        (this.numSlides = 0));
    }
    return (
      (((e.prototype = Object.create(
        H5P.EventDispatcher.prototype,
      )).constructor = e).prototype.addSlide = function (e) {
        (e
          .addClass("h5p-joubel-ui-slide")
          .css({ left: 100 * this.numSlides + "%" }),
          this.$slider.append(e),
          this.$slides.push(e),
          this.numSlides++,
          1 === this.numSlides && e.addClass("current"));
      }),
      (e.prototype.attach = function (e) {
        e.append(this.$slider);
      }),
      (e.prototype.move = function (e) {
        var t = this;
        (0 === e && t.trigger("first-slide"),
          e + 1 === t.numSlides && t.trigger("last-slide"),
          t.trigger("move"));
        var n = t.$slides[this.currentIndex];
        (H5P.Transition.onTransitionEnd(this.$slider, function () {
          (n.removeClass("current"), t.trigger("moved"));
        }),
          this.$slides[e].addClass("current"));
        var r = "translateX(" + 100 * -e + "%)";
        (this.$slider.css({
          "-webkit-transform": r,
          "-moz-transform": r,
          "-ms-transform": r,
          transform: r,
        }),
          (this.currentIndex = e));
      }),
      (e.prototype.remove = function () {
        this.$slider.remove();
      }),
      (e.prototype.next = function () {
        this.currentIndex + 1 >= this.numSlides ||
          this.move(this.currentIndex + 1);
      }),
      (e.prototype.previous = function () {
        this.move(this.currentIndex - 1);
      }),
      (e.prototype.first = function () {
        this.move(0);
      }),
      (e.prototype.last = function () {
        this.move(this.numSlides - 1);
      }),
      e
    );
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelScoreBar = (function (a) {
    var s = 0;
    return function (e, t, n, r) {
      var i = this;
      function o(e) {
        return t ? t.replace(":num", e).replace(":total", i.maxScore) : "";
      }
      ((i.maxScore = e),
        (i.score = 0),
        s++,
        (i.STAR_MARKUP =
          '<svg tabindex="-1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 63.77 53.87" aria-hidden="true" focusable="false"><title>star</title><filter tabindex="-1" id="h5p-joubelui-score-bar-star-inner-shadow-' +
          s +
          '" x0="-50%" y0="-50%" width="200%" height="200%"><feGaussianBlur in="SourceAlpha" stdDeviation="3" result="blur"></feGaussianBlur><feOffset dy="2" dx="4"></feOffset><feComposite in2="SourceAlpha" operator="arithmetic" k2="-1" k3="1" result="shadowDiff"></feComposite><feFlood flood-color="#ffe95c" flood-opacity="1"></feFlood><feComposite in2="shadowDiff" operator="in"></feComposite><feComposite in2="SourceGraphic" operator="over" result="firstfilter"></feComposite><feGaussianBlur in="firstfilter" stdDeviation="3" result="blur2"></feGaussianBlur><feOffset dy="-2" dx="-4"></feOffset><feComposite in2="firstfilter" operator="arithmetic" k2="-1" k3="1" result="shadowDiff"></feComposite><feFlood flood-color="#ffe95c" flood-opacity="1"></feFlood><feComposite in2="shadowDiff" operator="in"></feComposite><feComposite in2="firstfilter" operator="over"></feComposite></filter><path tabindex="-1" class="h5p-joubelui-score-bar-star-shadow" d="M35.08,43.41V9.16H20.91v0L9.51,10.85,9,10.93C2.8,12.18,0,17,0,21.25a11.22,11.22,0,0,0,3,7.48l8.73,8.53-1.07,6.16Z"/><g tabindex="-1"><path tabindex="-1" class="h5p-joubelui-score-bar-star-border" d="M61.36,22.8,49.72,34.11l2.78,16a2.6,2.6,0,0,1,.05.64c0,.85-.37,1.6-1.33,1.6A2.74,2.74,0,0,1,49.94,52L35.58,44.41,21.22,52a2.93,2.93,0,0,1-1.28.37c-.91,0-1.33-.75-1.33-1.6,0-.21.05-.43.05-.64l2.78-16L9.8,22.8A2.57,2.57,0,0,1,9,21.25c0-1,1-1.33,1.81-1.49l16.07-2.35L34.09,2.83c.27-.59.85-1.33,1.55-1.33s1.28.69,1.55,1.33l7.21,14.57,16.07,2.35c.75.11,1.81.53,1.81,1.49A3.07,3.07,0,0,1,61.36,22.8Z"/><path tabindex="-1" class="h5p-joubelui-score-bar-star-fill" d="M61.36,22.8,49.72,34.11l2.78,16a2.6,2.6,0,0,1,.05.64c0,.85-.37,1.6-1.33,1.6A2.74,2.74,0,0,1,49.94,52L35.58,44.41,21.22,52a2.93,2.93,0,0,1-1.28.37c-.91,0-1.33-.75-1.33-1.6,0-.21.05-.43.05-.64l2.78-16L9.8,22.8A2.57,2.57,0,0,1,9,21.25c0-1,1-1.33,1.81-1.49l16.07-2.35L34.09,2.83c.27-.59.85-1.33,1.55-1.33s1.28.69,1.55,1.33l7.21,14.57,16.07,2.35c.75.11,1.81.53,1.81,1.49A3.07,3.07,0,0,1,61.36,22.8Z"/><path tabindex="-1" filter="url(#h5p-joubelui-score-bar-star-inner-shadow-' +
          s +
          ')" class="h5p-joubelui-score-bar-star-fill-full-score" d="M61.36,22.8,49.72,34.11l2.78,16a2.6,2.6,0,0,1,.05.64c0,.85-.37,1.6-1.33,1.6A2.74,2.74,0,0,1,49.94,52L35.58,44.41,21.22,52a2.93,2.93,0,0,1-1.28.37c-.91,0-1.33-.75-1.33-1.6,0-.21.05-.43.05-.64l2.78-16L9.8,22.8A2.57,2.57,0,0,1,9,21.25c0-1,1-1.33,1.81-1.49l16.07-2.35L34.09,2.83c.27-.59.85-1.33,1.55-1.33s1.28.69,1.55,1.33l7.21,14.57,16.07,2.35c.75.11,1.81.53,1.81,1.49A3.07,3.07,0,0,1,61.36,22.8Z"/></g></svg>'),
        (i.appendTo = function (e) {
          i.$scoreBar.appendTo(e);
        }),
        (i.setScore = function (e) {
          e !== i.score &&
            ((i.score = e > i.maxScore ? i.maxScore : e), i.updateVisuals());
        }),
        (i.incrementScore = function (e) {
          i.setScore(i.score + (e || 1));
        }),
        (i.setMaxScore = function (e) {
          i.maxScore = e;
        }),
        (i.updateVisuals = function () {
          (i.$progress.html(o(i.score)),
            i.$scoreCounter.text(i.score),
            i.$maxScore.text(i.maxScore),
            setTimeout(function () {
              (i.$progress.css({ width: (i.score / i.maxScore) * 100 + "%" }),
                H5P.Transition.onTransitionEnd(
                  i.$progress,
                  function () {
                    (i.$scoreBar.toggleClass(
                      "h5p-joubelui-score-bar-full-score",
                      i.score === i.maxScore,
                    ),
                      i.$scoreBar.toggleClass(
                        "h5p-joubelui-score-bar-animation-active",
                        i.score === i.maxScore,
                      ),
                      i.$scoreBar.one("animationend", function () {
                        i.$scoreBar.removeClass(
                          "h5p-joubelui-score-bar-animation-active",
                        );
                      }));
                  },
                  600,
                ));
            }, 300));
        }),
        (i.reset = function () {
          i.$scoreBar.removeClass("h5p-joubelui-score-bar-full-score");
        }),
        (function () {
          i.$scoreBar = a("<div>", { class: "h5p-joubelui-score-bar" });
          var e = a("<div>", {
            class: "h5p-joubelui-score-bar-visuals",
            appendTo: i.$scoreBar,
          });
          ((i.$progressWrapper = a("<div>", {
            class: "h5p-joubelui-score-bar-progress-wrapper",
            appendTo: e,
          })),
            (i.$progress = a("<div>", {
              class: "h5p-joubelui-score-bar-progress",
              html: o(i.score),
              appendTo: i.$progressWrapper,
            })),
            a("<div>", {
              class: "h5p-joubelui-score-bar-star",
              html: i.STAR_MARKUP,
            }).appendTo(e));
          e = a("<div>", {
            class: "h5p-joubelui-score-numeric",
            appendTo: i.$scoreBar,
            "aria-hidden": !0,
          });
          ((i.$scoreCounter = a("<span>", {
            class:
              "h5p-joubelui-score-number h5p-joubelui-score-number-counter",
            text: 0,
            appendTo: e,
          })),
            a("<span>", {
              class: "h5p-joubelui-score-number-separator",
              text: "/",
              appendTo: e,
            }),
            (i.$maxScore = a("<span>", {
              class: "h5p-joubelui-score-number h5p-joubelui-score-max",
              text: i.maxScore,
              appendTo: e,
            })),
            n &&
              (H5P.JoubelUI.createTip(n, {
                tipLabel: r || n,
                helpIcon: !0,
              }).appendTo(i.$scoreBar),
              i.$scoreBar.addClass("h5p-score-bar-has-help")));
        })());
    };
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelProgressbar = (function (n) {
    function e(e, t) {
      H5P.EventDispatcher.call(this);
      ((this.options = n.extend({ progressText: "Slide :num of :total" }, t)),
        (this.currentStep = 0),
        (this.steps = e),
        (this.$progressbar = n("<div>", { class: "h5p-joubelui-progressbar" })),
        (this.$background = n("<div>", {
          class: "h5p-joubelui-progressbar-background",
        }).appendTo(this.$progressbar)));
    }
    return (
      (((e.prototype = Object.create(
        H5P.EventDispatcher.prototype,
      )).constructor = e).prototype.updateAria = function () {
        var e;
        this.options.disableAria ||
          (this.$currentStatus ||
            (this.$currentStatus = n("<div>", {
              class: "h5p-joubelui-progressbar-slide-status-text",
              "aria-live": "assertive",
            }).appendTo(this.$progressbar)),
          (e = this.options.progressText
            .replace(":num", this.currentStep)
            .replace(":total", this.steps)),
          this.$currentStatus.html(e));
      }),
      (e.prototype.appendTo = function (e) {
        this.$progressbar.appendTo(e);
      }),
      (e.prototype.setProgress = function (e) {
        e > this.steps ||
          e < 0 ||
          ((this.currentStep = e),
          this.$background.css({
            width: (this.currentStep / this.steps) * 100 + "%",
          }),
          this.updateAria());
      }),
      (e.prototype.next = function () {
        this.setProgress(this.currentStep + 1);
      }),
      (e.prototype.reset = function () {
        this.setProgress(0);
      }),
      (e.prototype.isLastStep = function () {
        return this.steps === this.currentStep;
      }),
      e
    );
  })(H5P.jQuery)),
  ((H5P = H5P || {}).JoubelUI = (function (n) {
    function e() {}
    var t;
    return (
      (e.createTip = function (e, t) {
        return new H5P.JoubelTip(e, t);
      }),
      (e.createMessageDialog = function (e, t) {
        return new H5P.JoubelMessageDialog(e, t);
      }),
      (e.createHelpTextDialog = function (e, t, n) {
        return new H5P.JoubelHelpTextDialog(e, t, n);
      }),
      (e.createProgressCircle = function (e, t, n, r) {
        return new H5P.JoubelProgressCircle(e, t, n, r);
      }),
      (e.createThrobber = function () {
        return new H5P.JoubelThrobber();
      }),
      (e.createSimpleRoundedButton = function (e) {
        return new H5P.SimpleRoundedButton(e);
      }),
      (e.createSlider = function (e) {
        return new H5P.JoubelSlider(e);
      }),
      (e.createScoreBar = function (e, t, n, r) {
        return new H5P.JoubelScoreBar(e, t, n, r);
      }),
      (e.createProgressbar = function (e, t) {
        return new H5P.JoubelProgressbar(e, t);
      }),
      (e.createButton = function (e) {
        var t = "button";
        return (
          e.href ? (t = "a") : (e.type = "button"),
          e.class
            ? (e.class += " h5p-joubelui-button")
            : (e.class = "h5p-joubelui-button"),
          n("<" + t + "/>", e)
        );
      }),
      H5P.isFramed &&
        !H5P.hasiOSiframeScrollFix &&
        /iPad|iPhone|iPod/.test(navigator.userAgent) &&
        ((H5P.hasiOSiframeScrollFix = !0),
        (t = HTMLElement.prototype.focus),
        (HTMLElement.prototype.focus = function () {
          (this instanceof HTMLAnchorElement ||
            this instanceof HTMLInputElement ||
            this instanceof HTMLSelectElement ||
            this instanceof HTMLTextAreaElement ||
            this instanceof HTMLButtonElement ||
            this instanceof HTMLIFrameElement ||
            this instanceof HTMLAreaElement) &&
            !this.getAttribute("role") &&
            t.call(this);
        })),
      e
    );
  })(H5P.jQuery)),
  ((H5P = H5P || {}).Audio = (function (c) {
    function e(e, t, n) {
      (H5P.EventDispatcher.call(this),
        (this.contentId = t),
        (this.params = e),
        (this.extras = n),
        (this.toggleButtonEnabled = !0),
        n &&
          void 0 !== n.previousState &&
          (this.oldTime = n.previousState.currentTime),
        (this.params = c.extend(
          {},
          {
            playerMode: "minimalistic",
            fitToWrapper: !1,
            controls: !0,
            autoplay: !1,
            audioNotSupported: "Your browser does not support this audio",
            playAudio: "Play audio",
            pauseAudio: "Pause audio",
          },
          e,
        )),
        "transparent" === this.params.playerMode &&
          (this.params.fitToWrapper = !0),
        this.on("resize", this.resize, this));
    }
    return (
      (((e.prototype = Object.create(
        H5P.EventDispatcher.prototype,
      )).constructor = e).prototype.addMinimalAudioPlayer = function (e, t) {
        var n = "h5p-audio-minimal-button",
          r = "h5p-audio-minimal-play",
          i = "h5p-audio-minimal-play-paused",
          o = "h5p-audio-minimal-pause",
          a = this;
        ((this.$container = e),
          (a.$inner = c("<div/>", {
            class: "h5p-audio-inner" + (t ? " h5p-audio-transparent" : ""),
          }).appendTo(e)));
        var s = c("<button/>", {
          class: n + " " + r,
          "aria-label": this.params.playAudio,
        })
          .appendTo(a.$inner)
          .click(function () {
            a.isEnabledToggleButton() &&
              (this.setAttribute("aria-hidden", "true"),
              a.audio.paused ? a.play() : a.pause());
          })
          .on("focusout", function () {
            this.setAttribute("aria-hidden", "false");
          });
        (this.params.fitToWrapper && s.css({ width: "100%", height: "100%" }),
          a.audio.addEventListener("ended", function () {
            s.attr("aria-hidden", !1)
              .attr("aria-label", a.params.playAudio)
              .removeClass(o)
              .removeClass(i)
              .addClass(r);
          }),
          a.audio.addEventListener("play", function () {
            s.attr("aria-label", a.params.pauseAudio)
              .removeClass(r)
              .removeClass(i)
              .addClass(o);
          }),
          a.audio.addEventListener("pause", function () {
            s.hasClass(r) ||
              s
                .attr("aria-hidden", !1)
                .attr("aria-label", a.params.playAudio)
                .removeClass(o)
                .addClass(i);
          }),
          (H5P.Audio.MINIMAL_BUTTON = n + " " + r),
          (H5P.Audio.MINIMAL_BUTTON_PAUSED = n + " " + i),
          (this.$audioButton = s),
          a.resize());
      }),
      (e.prototype.resize = function () {
        var e, t;
        this.params.fitToWrapper &&
          this.$container &&
          this.$container.width() &&
          ((e = this.$container.width()) < (t = this.$container.height())
            ? this.$audioButton.css({ "font-size": e / 2 + "px" })
            : this.$audioButton.css({ "font-size": t / 2 + "px" }));
      }),
      e
    );
  })(H5P.jQuery)),
  (H5P.Audio.prototype.attach = function (e) {
    const t = this;
    e.addClass("h5p-audio-wrapper");
    var n = document.createElement("audio");
    if (void 0 !== n.canPlayType) {
      if (void 0 !== this.params.files && this.params.files instanceof Object)
        for (var r = 0; r < this.params.files.length; r++) {
          var i,
            o = this.params.files[r];
          n.canPlayType(o.mime) &&
            (((i = document.createElement("source")).src = H5P.getPath(
              o.path,
              this.contentId,
            )),
            (i.type = o.mime),
            n.appendChild(i));
        }
      n.children.length
        ? (void 0 !== this.endedCallback &&
            n.addEventListener("ended", this.endedCallback, !1),
          (n.className = "h5p-audio"),
          (n.controls =
            void 0 === this.params.controls || this.params.controls),
          n.setAttribute("controlsList", "nodownload noplaybackrate"),
          (n.preload = "auto"),
          (n.style.display = "block"),
          (void 0 !== this.params.fitToWrapper && !this.params.fitToWrapper) ||
            ((n.style.width = "100%"),
            this.isRoot() || (n.style.height = "100%")),
          (this.audio = n),
          "minimalistic" === this.params.playerMode
            ? ((n.controls = !1), this.addMinimalAudioPlayer(e, !1))
            : "transparent" === this.params.playerMode
              ? ((n.controls = !1), this.addMinimalAudioPlayer(e, !0))
              : e.html(n),
          n.controls && e.addClass("h5p-audio-controls"),
          this.oldTime &&
            (this.$audioButton &&
              this.$audioButton.attr("class", H5P.Audio.MINIMAL_BUTTON_PAUSED),
            this.seekTo(this.oldTime)),
          void 0 === window.H5PEditor &&
            ((t.autoPaused = !0),
            new IntersectionObserver(
              function (e) {
                0 == e[0].intersectionRatio
                  ? t.audio.paused || ((t.autoPaused = !0), t.audio.pause())
                  : t.params.autoplay &&
                    t.autoPaused &&
                    ((t.autoPaused = !1), t.play());
              },
              { root: document.documentElement, threshold: [0, 1] },
            ).observe(e.get(0))))
        : this.attachNotSupportedMessage(e);
    } else this.attachNotSupportedMessage(e);
  }),
  (H5P.Audio.prototype.attachNotSupportedMessage = function (e) {
    (e.addClass("h5p-audio-not-supported"),
      e.html(
        '<div class="h5p-audio-inner"><div class="h5p-audio-not-supported-icon"><span/></div><span>' +
          this.params.audioNotSupported +
          "</span></div>",
      ),
      void 0 !== this.endedCallback && this.endedCallback());
  }),
  (H5P.Audio.prototype.resetTask = function () {
    (this.stop(),
      this.seekTo(0),
      this.$audioButton &&
        this.$audioButton.attr("class", H5P.Audio.MINIMAL_BUTTON));
  }),
  (H5P.Audio.prototype.stop = function () {
    void 0 !== this.audio && this.audio.pause();
  }),
  (H5P.Audio.prototype.play = function () {
    void 0 !== this.audio &&
      this.audio.play().catch((e) => {
        console.warn(e);
      });
  }),
  (H5P.Audio.prototype.pause = function () {
    void 0 !== this.audio && this.audio.pause();
  }),
  (H5P.Audio.prototype.seekTo = function (e) {
    void 0 !== this.audio && (this.audio.currentTime = e);
  }),
  (H5P.Audio.prototype.getCurrentState = function () {
    if (void 0 !== this.audio && 0 < this.audio.currentTime)
      return { currentTime: this.audio.ended ? 0 : this.audio.currentTime };
  }),
  (H5P.Audio.prototype.disableToggleButton = function () {
    ((this.toggleButtonEnabled = !1),
      this.$audioButton &&
        this.$audioButton.addClass(H5P.Audio.BUTTON_DISABLED));
  }),
  (H5P.Audio.prototype.enableToggleButton = function () {
    ((this.toggleButtonEnabled = !0),
      this.$audioButton &&
        this.$audioButton.removeClass(H5P.Audio.BUTTON_DISABLED));
  }),
  (H5P.Audio.prototype.isEnabledToggleButton = function () {
    return this.toggleButtonEnabled;
  }),
  (H5P.Audio.BUTTON_DISABLED = "h5p-audio-disabled"),
  /*!@license H5P.Dialogcards-1.9/dist/h5p-dialogcards.js by Joubel licensed under MIT*/ (() => {
    "use strict";
    const a = H5P.jQuery;
    class c {
      constructor(e, t, n, r, i = {}, o) {
        return (
          (this.card = e),
          (this.params = t || {}),
          (this.id = n),
          (this.contentId = r),
          (this.callbacks = i),
          (this.$cardWrapper = a("<div>", {
            class: "h5p-dialogcards-cardwrap",
            role: "group",
            tabindex: "-1",
          })),
          this.$cardWrapper.addClass(
            "h5p-dialogcards-mode-" + this.params.mode,
          ),
          "repetition" !== this.params.mode &&
            this.$cardWrapper.attr(
              "aria-labelledby",
              "h5p-dialogcards-progress-" + o,
            ),
          (this.$cardHolder = a("<div>", {
            class: "h5p-dialogcards-cardholder",
          }).appendTo(this.$cardWrapper)),
          this.createCardContent(e).appendTo(this.$cardHolder),
          this
        );
      }
      createCardContent(e) {
        var t = a("<div>", { class: "h5p-dialogcards-card-content" });
        this.createCardImage(e).appendTo(t);
        var n = a("<div>", {
            class: "h5p-dialogcards-card-text-wrapper",
          }).appendTo(t),
          r = a("<div>", { class: "h5p-dialogcards-card-text-inner" }).appendTo(
            n,
          ),
          r = a("<div>", {
            class: "h5p-dialogcards-card-text-inner-content",
          }).appendTo(r);
        this.createCardAudio(e).appendTo(r);
        const i = a("<div>", { class: "h5p-dialogcards-card-text" }).appendTo(
          r,
        );
        return (
          (this.$cardTextArea = a("<div>", {
            class: "h5p-dialogcards-card-text-area",
            tabindex: "-1",
            html: e.text,
          }).appendTo(i)),
          (e.text && e.text.length) || i.addClass("hide"),
          this.createCardFooter().appendTo(n),
          t
        );
      }
      createCardImage(e) {
        this.$image;
        var t = a("<div>", { class: "h5p-dialogcards-image-wrapper" });
        return (
          void 0 !== e.image
            ? ((this.image = e.image),
              (this.$image = a(
                '<img class="h5p-dialogcards-image" src="' +
                  H5P.getPath(e.image.path, this.contentId) +
                  '"/>',
              )),
              e.imageAltText && this.$image.attr("alt", e.imageAltText))
            : (this.$image = a('<div class="h5p-dialogcards-image"></div>')),
          this.$image.appendTo(t),
          t
        );
      }
      createCardAudio(e) {
        if (
          (this.audio,
          (this.$audioWrapper = a("<div>", {
            class: "h5p-dialogcards-audio-wrapper",
          })),
          void 0 !== e.audio)
        ) {
          const a = {
            files: e.audio,
            audioNotSupported: this.params.audioNotSupported,
          };
          ((this.audio = new H5P.Audio(a, this.contentId)),
            this.audio.attach(this.$audioWrapper),
            this.audio.audio &&
              this.audio.audio.preload &&
              (this.audio.audio.preload = "none"));
        } else this.$audioWrapper.addClass("hide");
        return this.$audioWrapper;
      }
      createCardFooter() {
        var e = a("<div>", { class: "h5p-dialogcards-card-footer" });
        let t = "h5p-dialogcards-button-hidden",
          n = "-1";
        return (
          "repetition" === this.params.mode &&
            ((t = ""),
            this.params.behaviour.quickProgression &&
              ((t = "h5p-dialogcards-quick-progression"), (n = "0"))),
          (this.$buttonTurn = H5P.JoubelUI.createButton({
            class: "h5p-dialogcards-turn",
            html: this.params.answer,
          }).appendTo(e)),
          "repetition" === this.params.mode &&
            ((this.$buttonShowSummary = H5P.JoubelUI.createButton({
              class: "h5p-dialogcards-show-summary h5p-dialogcards-button-gone",
              html: this.params.showSummary,
            }).appendTo(e)),
            (this.$buttonIncorrect = H5P.JoubelUI.createButton({
              class: "h5p-dialogcards-answer-button",
              html: this.params.incorrectAnswer,
            })
              .addClass("incorrect")
              .addClass(t)
              .attr("tabindex", n)
              .appendTo(e)),
            (this.$buttonCorrect = H5P.JoubelUI.createButton({
              class: "h5p-dialogcards-answer-button",
              html: this.params.correctAnswer,
            })
              .addClass("correct")
              .addClass(t)
              .attr("tabindex", n)
              .appendTo(e))),
          e
        );
      }
      createButtonListeners() {
        (this.$buttonTurn.unbind("click").click(() => {
          this.turnCard();
        }),
          "repetition" === this.params.mode &&
            (this.$buttonIncorrect.unbind("click").click((e) => {
              e.target.classList.contains(
                "h5p-dialogcards-quick-progression",
              ) && this.callbacks.onNextCard({ cardId: this.id, result: !1 });
            }),
            this.$buttonCorrect.unbind("click").click((e) => {
              e.target.classList.contains(
                "h5p-dialogcards-quick-progression",
              ) && this.callbacks.onNextCard({ cardId: this.id, result: !0 });
            })));
      }
      showSummaryButton(e) {
        (this.getDOM()
          .find(".h5p-dialogcards-answer-button")
          .addClass("h5p-dialogcards-button-hidden")
          .attr("tabindex", "-1"),
          this.$buttonTurn.addClass("h5p-dialogcards-button-gone"),
          this.$buttonShowSummary
            .click(() => e())
            .removeClass("h5p-dialogcards-button-gone")
            .focus());
      }
      hideSummaryButton() {
        "normal" !== this.params.mode &&
          (this.getDOM()
            .find(".h5p-dialogcards-answer-button")
            .removeClass("h5p-dialogcards-button-hidden")
            .attr("tabindex", "0"),
          this.$buttonTurn.removeClass("h5p-dialogcards-button-gone"),
          this.$buttonShowSummary
            .addClass("h5p-dialogcards-button-gone")
            .off("click"));
      }
      turnCard() {
        const e = this.getDOM(),
          t = e.find(".h5p-dialogcards-card-content"),
          n = e
            .find(".h5p-dialogcards-cardholder")
            .addClass("h5p-dialogcards-collapse");
        t.find(".joubel-tip-container").remove();
        const r = t.hasClass("h5p-dialogcards-turned");
        (t.toggleClass("h5p-dialogcards-turned", !r),
          setTimeout(() => {
            if (
              (n.removeClass("h5p-dialogcards-collapse"),
              this.changeText(r ? this.getText() : this.getAnswer()),
              r
                ? n.find(".h5p-audio-inner").removeClass("hide")
                : this.removeAudio(n),
              "repetition" === this.params.mode &&
                !this.params.behaviour.quickProgression)
            ) {
              const t = e.find(".h5p-dialogcards-answer-button");
              !1 === t.hasClass("h5p-dialogcards-quick-progression") &&
                t
                  .addClass("h5p-dialogcards-quick-progression")
                  .attr("tabindex", 0);
            }
            (setTimeout(() => {
              (this.addTipToCard(t, r ? "front" : "back"),
                "function" == typeof this.callbacks.onCardTurned &&
                  this.callbacks.onCardTurned(r));
            }, 200),
              this.resizeOverflowingText(),
              this.$cardTextArea.focus());
          }, 200));
      }
      changeText(e) {
        (this.$cardTextArea.html(e),
          this.$cardTextArea.toggleClass("hide", !e || !e.length));
      }
      setProgressText(e, t) {
        "repetition" === this.params.mode &&
          ((t = this.params.progressText
            .replace("@card", e.toString())
            .replace("@total", t.toString())),
          this.$cardWrapper.attr("aria-label", t));
      }
      resizeOverflowingText() {
        if (this.params.behaviour.scaleTextNotCard) {
          const e = this.getDOM().find(".h5p-dialogcards-card-text"),
            t = e.children();
          this.resizeTextToFitContainer(e, t);
        }
      }
      resizeTextToFitContainer(e, t) {
        t.css("font-size", "");
        var n = e.get(0).getBoundingClientRect().height;
        let r = t.get(0).getBoundingClientRect().height;
        var i = parseFloat(e.css("font-size"));
        let o = parseFloat(t.css("font-size"));
        const a = this.getDOM().closest(".h5p-container"),
          s = parseFloat(a.css("font-size"));
        if (r > n) {
          let e = !0;
          for (; e; ) {
            if (((o -= c.SCALEINTERVAL), o < c.MINSCALE)) {
              e = !1;
              break;
            }
            (t.css("font-size", o / i + "em"),
              (r = t.get(0).getBoundingClientRect().height),
              r <= n && (e = !1));
          }
        } else {
          let e = !0;
          for (; e; ) {
            if (((o += c.SCALEINTERVAL), o > s)) {
              e = !1;
              break;
            }
            (t.css("font-size", o / i + "em"),
              (r = t.get(0).getBoundingClientRect().height),
              r >= n &&
                ((e = !1),
                (o -= c.SCALEINTERVAL),
                t.css("font-size", o / i + "em")));
          }
        }
      }
      addTipToCard(e, t, n) {
        ("back" !== t && (t = "front"),
          void 0 === n && (n = this.id),
          e.find(".joubel-tip-container").remove());
        const r = this.card.tips;
        if (void 0 !== r && void 0 !== r[t]) {
          const n = r[t].trim();
          n.length &&
            e
              .find(
                ".h5p-dialogcards-card-text-wrapper .h5p-dialogcards-card-text-inner",
              )
              .after(
                H5P.JoubelUI.createTip(n, {
                  tipLabel: this.params.tipButtonLabel,
                }),
              );
        }
      }
      setCardFocus(e) {
        if (!0 === e) this.$cardTextArea.focus();
        else {
          const e = this.getDOM();
          e.one("transitionend", () => {
            e.focus();
          });
        }
      }
      stopAudio() {
        var e;
        this.audio &&
          this.audio.audio &&
          (0 < (e = this.audio.audio.duration) &&
            e < Number.MAX_SAFE_INTEGER &&
            this.audio.seekTo(e),
          this.audio.audio.load &&
            setTimeout(() => {
              this.audio.audio.load();
            }, 100));
      }
      removeAudio() {
        (this.stopAudio(),
          this.getDOM().find(".h5p-audio-inner").addClass("hide"));
      }
      getDOM() {
        return this.$cardWrapper;
      }
      getText() {
        return this.card.text;
      }
      getAnswer() {
        return this.card.answer;
      }
      getImage() {
        return this.$image;
      }
      getImageSize() {
        return (
          this.image && { width: this.image.width, height: this.image.height }
        );
      }
      getAudio() {
        return this.$audioWrapper;
      }
      reset() {
        const e = this.getDOM();
        (e.removeClass("h5p-dialogcards-previous"),
          e.removeClass("h5p-dialogcards-current"),
          this.changeText(this.getText()));
        const t = e.find(".h5p-dialogcards-card-content");
        (t.removeClass("h5p-dialogcards-turned"),
          this.addTipToCard(t, "front", this.id),
          this.params.behaviour.quickProgression ||
            e
              .find(".h5p-dialogcards-answer-button")
              .removeClass("h5p-dialogcards-quick-progression"),
          this.hideSummaryButton());
      }
    }
    ((c.SCALEINTERVAL = 0.2), (c.MAXSCALE = 16), (c.MINSCALE = 4));
    const t = c,
      i = class {
        constructor(e, t, n, r) {
          return (
            (this.params = e),
            (this.contentId = t),
            (this.callbacks = n),
            (this.idCounter = r),
            (this.cards = []),
            this.params.dialogs.forEach((e, t) => {
              ((e.id = t), this.cards.push(t));
            }),
            this
          );
        }
        getCard(e) {
          if (!(e < 0 || e > this.cards.length))
            return (
              "number" == typeof this.cards[e] && this.loadCard(e),
              this.cards[e]
            );
        }
        getCardIds() {
          return this.cards.map((e, t) => t);
        }
        loadCard(e) {
          e < 0 ||
            e > this.cards.length ||
            ("number" == typeof this.cards[e] &&
              (this.cards[e] = new t(
                this.params.dialogs[e],
                this.params,
                e,
                this.contentId,
                this.callbacks,
                this.idCounter,
              )));
        }
      },
      n = class {
        constructor(n = []) {
          return ((this.cards = n.filter((e, t) => n.indexOf(e) >= t)), this);
        }
        getCards() {
          return this.cards;
        }
        peek(e, t = 1) {
          return (
            (t = Math.max(0, t)),
            (e =
              "bottom" === (e = "top" === e ? 0 : e)
                ? this.cards.length - t
                : e) < 0 || e > this.cards.length - 1
              ? []
              : this.cards.slice(e, e + t)
          );
        }
        add(t, n = "top") {
          (t = "number" == typeof t ? [t] : t).forEach((e) => {
            -1 === this.cards.indexOf(e) &&
              ("top" === n
                ? (n = 0)
                : "bottom" === n
                  ? (n = this.cards.length)
                  : "random" === n &&
                    (n = Math.floor(Math.random() * this.cards.length)),
              this.cards.splice(n, 0, ...t));
          });
        }
        push(e) {
          this.add(e, "top");
        }
        pull(e = 1, t = "top") {
          return (
            (e = Math.max(1, Math.min(e, this.cards.length))),
            "bottom" === (t = "top" === t ? 0 : t) && (t = -e),
            (t = Math.max(0, Math.min(t, this.cards.length - 1))),
            this.cards.splice(t, e)
          );
        }
        remove(e) {
          (e = "number" == typeof e ? [e] : e).forEach((e) => {
            e = this.cards.indexOf(e);
            -1 < e && this.cards.splice(e, 1);
          });
        }
        shuffle() {
          for (let e = this.cards.length - 1; 0 < e; e--) {
            var t = Math.floor(Math.random() * (e + 1));
            [this.cards[e], this.cards[t]] = [this.cards[t], this.cards[e]];
          }
          return this.cards;
        }
        contains(e) {
          return -1 !== this.cards.indexOf(e);
        }
        length() {
          return this.cards.length;
        }
      },
      r = class {
        constructor(e, t, n, r) {
          return (
            (this.params = e),
            (this.cardPool = new i(e, t, n, r)),
            this.reset(e.cardPiles),
            this
          );
        }
        createSelection() {
          let e = [];
          return (
            (e =
              "repetition" === this.params.mode
                ? this.createSelectionRepetition()
                : this.cardPool.getCardIds()),
            e
          );
        }
        createPiles(e) {
          if (e) this.cardPiles = e.map((e) => new n(e.cards));
          else {
            this.cardPiles = [];
            var t = this.cardPool.getCardIds();
            switch (this.params.mode) {
              case "repetition":
                for (
                  let e = 0;
                  e < this.params.behaviour.maxProficiency + 1;
                  e++
                )
                  0 === e
                    ? this.cardPiles.push(new n(t))
                    : this.cardPiles.push(new n());
                break;
              case "normal":
                this.cardPiles.push(new n(t));
            }
          }
        }
        updatePiles(e) {
          return (
            e.forEach((e) => {
              var t,
                n = this.find(e.cardId);
              -1 !== n &&
                ((t = !0 === e.result ? n + 1 : 0),
                (t = Math.max(0, Math.min(t, this.cardPiles.length - 1))),
                this.cardPiles[n].remove(e.cardId),
                this.cardPiles[t].add(e.cardId, "bottom"));
            }),
            this.getPileSizes()
          );
        }
        createSelectionRepetition() {
          let t = [],
            n = null;
          for (let e = 0; e < this.cardPiles.length - 1; e++) {
            var r = this.cardPiles[e].length();
            (null === n && 0 === r) ||
              (null === n && (n = e),
              (r = Math.ceil(+r / (1 + e - n))),
              (r = this.cardPiles[e].peek(0, r)),
              (t = t.concat(...r)));
          }
          return ((t = this.shuffle(t)), t);
        }
        shuffle(e) {
          const t = e.slice();
          for (let e = t.length - 1; 0 < e; e--) {
            var n = Math.floor(Math.random() * (e + 1));
            [t[e], t[n]] = [t[n], t[e]];
          }
          return t;
        }
        find(n) {
          let r = -1;
          return (
            this.cardPiles.forEach((e, t) =>
              -1 !== r ? r : void (e.contains(n) && (r = t)),
            ),
            r
          );
        }
        reset(e) {
          this.createPiles(e);
        }
        getCard(e) {
          return this.cardPool.getCard(e);
        }
        getSize() {
          return this.cardPool.getCardIds().length;
        }
        getPiles() {
          return this.cardPiles;
        }
        getPileSizes() {
          return this.cardPiles.map((e) => e.length());
        }
      },
      o = class {
        constructor(e, t) {
          ((this.params = e),
            (this.callbacks = t),
            (this.currentCallback = t.nextRound),
            (this.fields = []),
            (this.container = document.createElement("div")),
            this.container.classList.add("h5p-dialogcards-summary-screen"));
          const n = this.createContainerDOM(e.summary);
          ((this.fields.round = n.getElementsByClassName(
            "h5p-dialogcards-summary-subheader",
          )[0]),
            (this.fields["h5p-dialogcards-round-cards-right"] =
              this.addTableRow(n, {
                category: this.params.summaryCardsRight,
                symbol: "h5p-dialogcards-check",
              })),
            (this.fields["h5p-dialogcards-round-cards-wrong"] =
              this.addTableRow(n, {
                category: this.params.summaryCardsWrong,
                symbol: "h5p-dialogcards-times",
              })),
            (this.fields["h5p-dialogcards-round-cards-not-shown"] =
              this.addTableRow(n, {
                category: this.params.summaryCardsNotShown,
              })));
          t = this.createContainerDOM(e.summaryOverallScore);
          ((this.fields["h5p-dialogcards-overall-cards-completed"] =
            this.addTableRow(t, {
              category: this.params.summaryCardsCompleted,
              symbol: "h5p-dialogcards-check",
            })),
            (this.fields["h5p-dialogcards-overall-completed-rounds"] =
              this.addTableRow(t, {
                category: this.params.summaryCompletedRounds,
                symbol: "",
              })));
          const r = document.createElement("div");
          (r.classList.add("h5p-dialogcards-summary-message"),
            (this.fields.message = r));
          e = H5P.JoubelUI.createButton({
            class: "h5p-dialogcards-buttonNextRound",
            title: this.params.nextRound.replace("@round", 2),
            html: this.params.nextRound.replace("@round", 2),
          })
            .click(this.currentCallback)
            .get(0);
          this.fields.button = e;
          const i = H5P.JoubelUI.createButton({
              class: "h5p-dialogcards-button-restart",
              title: this.params.startOver,
              html: this.params.startOver,
            }).get(0),
            o = this.createConfirmationDialog(
              { l10n: this.params.confirmStartingOver, instance: this },
              () => {
                setTimeout(() => {
                  this.callbacks.retry();
                }, 100);
              },
            );
          (i.addEventListener("click", (e) => {
            o.show(e.target.offsetTop);
          }),
            (this.fields.buttonStartOver = i));
          const a = document.createElement("div");
          return (
            a.classList.add("h5p-dialogcards-summary-footer"),
            a.appendChild(i),
            a.appendChild(e),
            this.container.appendChild(n),
            this.container.appendChild(t),
            this.container.appendChild(r),
            this.container.appendChild(a),
            this.hide(),
            this
          );
        }
        getDOM() {
          return this.container;
        }
        createContainerDOM(e, t = "") {
          const n = document.createElement("div");
          n.classList.add("h5p-dialogcards-summary-container");
          const r = document.createElement("div");
          (r.classList.add("h5p-dialogcards-summary-header"),
            (r.innerHTML = e),
            n.appendChild(r));
          const i = document.createElement("div");
          (i.classList.add("h5p-dialogcards-summary-subheader"),
            (i.innerHTML = t),
            n.appendChild(i));
          const o = document.createElement("table");
          return (
            o.classList.add("h5p-dialogcards-summary-table"),
            n.appendChild(o),
            n
          );
        }
        addTableRow(e, t) {
          const n = e.getElementsByClassName(
              "h5p-dialogcards-summary-table",
            )[0],
            r = document.createElement("tr"),
            i = document.createElement("td");
          (i.classList.add("h5p-dialogcards-summary-table-row-category"),
            (i.innerHTML = t.category),
            r.appendChild(i));
          const o = document.createElement("td");
          (o.classList.add("h5p-dialogcards-summary-table-row-symbol"),
            void 0 !== t.symbol && "" !== t.symbol && o.classList.add(t.symbol),
            r.appendChild(o));
          const a = document.createElement("td");
          return (
            a.classList.add("h5p-dialogcards-summary-table-row-score"),
            r.appendChild(a),
            n.appendChild(r),
            a
          );
        }
        update({ done: e = !1, round: t, message: n, results: r = [] } = {}) {
          (!0 === e
            ? (this.fields.buttonStartOver.classList.add(
                "h5p-dialogcards-button-gone",
              ),
              this.params.behaviour.enableRetry
                ? (this.fields.button.classList.remove(
                    "h5p-dialogcards-button-next-round",
                  ),
                  this.fields.button.classList.add(
                    "h5p-dialogcards-button-restart",
                  ),
                  (this.fields.button.innerHTML = this.params.retry),
                  (this.fields.button.title = this.params.retry),
                  (this.currentCallback = this.callbacks.retry))
                : this.fields.button.classList.add(
                    "h5p-dialogcards-button-gone",
                  ))
            : (this.fields.buttonStartOver.classList.remove(
                "h5p-dialogcards-button-gone",
              ),
              this.fields.button.classList.add(
                "h5p-dialogcards-button-next-round",
              ),
              this.fields.button.classList.remove(
                "h5p-dialogcards-button-restart",
              ),
              (this.fields.button.innerHTML = this.params.nextRound),
              (this.fields.button.title = this.params.nextRound),
              (this.currentCallback = this.callbacks.nextRound)),
            H5P.jQuery(this.fields.button)
              .unbind("click")
              .click(this.currentCallback),
            (this.fields.round.innerHTML = this.params.round.replace(
              "@round",
              t,
            )),
            e ||
              void 0 === t ||
              ((this.fields.button.innerHTML = this.params.nextRound.replace(
                "@round",
                t + 1,
              )),
              (this.fields.button.title = this.params.nextRound.replace(
                "@round",
                t + 1,
              ))),
            e && void 0 !== n && "" !== n
              ? (this.fields.message.classList.remove("h5p-dialogcards-gone"),
                (this.fields.message.innerHTML = n))
              : this.fields.message.classList.add("h5p-dialogcards-gone"),
            r.forEach((e) => {
              let t = void 0 !== e.score.value ? e.score.value : "";
              (void 0 !== e.score.max &&
                (t =
                  t +
                  '&nbsp;<span class="h5p-dialogcards-summary-table-row-score-divider">/</span>&nbsp;' +
                  e.score.max),
                (this.fields[e.field].innerHTML = t));
            }));
        }
        show() {
          (this.container.classList.remove("h5p-dialogcards-gone"),
            setTimeout(() => {
              this.fields.button.focus();
            }, 0));
        }
        hide() {
          this.container.classList.add("h5p-dialogcards-gone");
        }
        createConfirmationDialog(e, t) {
          e = new H5P.ConfirmationDialog({
            instance: (e = e || {}).instance,
            headerText: e.l10n.header,
            dialogText: e.l10n.body,
            cancelText: e.l10n.cancelLabel,
            confirmText: e.l10n.confirmLabel,
          });
          return (
            e.on("confirmed", () => {
              t();
            }),
            e.appendTo(this.getContainer()),
            e
          );
        }
        getContainer() {
          const e = H5P.jQuery(
              '[data-content-id="' + self.contentId + '"].h5p-content',
            ),
            t = e.parents(".h5p-container");
          let n;
          return (
            (n =
              0 !== t.length
                ? t.last()
                : 0 !== e.length
                  ? e
                  : H5P.jQuery(document.body)),
            n.get(0)
          );
        }
      },
      d = H5P.jQuery,
      s = H5P.JoubelUI;
    class l extends H5P.EventDispatcher {
      constructor(e, t, n) {
        (super(),
          (this.idCounter = l.idCounter++),
          (this.contentId = this.id = t),
          (this.previousState = n.previousState || {}),
          (this.contentData = n || {}),
          (this.params = d.extend(
            {
              title: "",
              mode: "normal",
              description:
                "Sit in pairs and make up sentences where you include the expressions below.<br/>Example: I should have said yes, HOWEVER I kept my mouth shut.",
              next: "Next",
              prev: "Previous",
              retry: "Retry",
              answer: "Turn",
              correctAnswer: "I got it right!",
              incorrectAnswer: "I got it wrong",
              round: "Round @round",
              cardsLeft: "Cards left: @number",
              nextRound: "Proceed to round @round",
              startOver: "Start over",
              showSummary: "Next",
              summary: "Summary",
              summaryCardsRight: "Cards you got right:",
              summaryCardsWrong: "Cards you got wrong:",
              summaryCardsNotShown: "Cards in pool not shown:",
              summaryOverallScore: "Overall Score",
              summaryCardsCompleted: "Cards you have completed learning:",
              summaryCompletedRounds: "Completed rounds:",
              summaryAllDone:
                "Well done! You have mastered all @cards cards by getting them correct @max times!",
              progressText: "Card @card of @total",
              cardFrontLabel: "Card front",
              cardBackLabel: "Card back",
              tipButtonLabel: "Show tip",
              audioNotSupported: "Your browser does not support this audio",
              confirmStartingOver: {
                header: "Start over?",
                body: "All progress will be lost. Are you sure you want to start over?",
                cancelLabel: "Cancel",
                confirmLabel: "Start over",
              },
              dialogs: [
                { text: "Horse", answer: "Hest" },
                { text: "Cow", answer: "Ku" },
              ],
              behaviour: {
                enableRetry: !0,
                disableBackwardsNavigation: !1,
                scaleTextNotCard: !1,
                randomCards: !1,
                maxProficiency: 5,
                quickProgression: !1,
              },
            },
            e,
          )),
          (this.cards = []),
          (this.currentCardId = 0),
          (this.round = 0),
          (this.results = this.previousState.results || []),
          (this.attach = (e) => {
            ((this.$inner = e.addClass("h5p-dialogcards")),
              this.params.behaviour.scaleTextNotCard &&
                e.addClass("h5p-text-scaling"));
            e = {
              mode: this.params.mode,
              dialogs: this.params.dialogs,
              audioNotSupported: this.params.audioNotSupported,
              answer: this.params.answer,
              showSummary: this.params.showSummary,
              incorrectAnswer: this.params.incorrectAnswer,
              correctAnswer: this.params.correctAnswer,
              progressText: this.params.progressText,
              tipButtonLabel: this.params.tipButtonLabel,
              behaviour: {
                scaleTextNotCard: this.params.behaviour.scaleTextNotCard,
                maxProficiency: this.params.behaviour.maxProficiency,
                quickProgression: this.params.behaviour.quickProgression,
              },
              cardPiles: this.previousState.cardPiles,
            };
            ((this.cardManager = new r(
              e,
              this.id,
              {
                onCardTurned: this.handleCardTurned,
                onNextCard: this.nextCard,
              },
              this.idCounter,
            )),
              this.createDOM(0 === this.round),
              void 0 !== this.previousState.currentCardId &&
                (this.gotoCard(this.previousState.currentCardId),
                "repetition" === this.params.mode &&
                  this.results.length === this.cardIds.length &&
                  this.showSummary(!0)),
              this.updateNavigation(),
              this.trigger("resize"));
          }),
          (this.createDOM = (e) => {
            if (
              ((this.cardIds =
                e && this.previousState.cardIds
                  ? this.previousState.cardIds
                  : this.cardManager.createSelection()),
              (this.cardPoolSize =
                this.cardPoolSize || this.cardManager.getSize()),
              !0 === e)
            ) {
              const e = d("<div>" + this.params.title + "</div>")
                .text()
                .trim();
              ((this.$header = d(
                (e
                  ? '<div class="h5p-dialogcards-title"><div class="h5p-dialogcards-title-inner">' +
                    this.params.title +
                    "</div></div>"
                  : "") +
                  '<div class="h5p-dialogcards-description">' +
                  this.params.description +
                  "</div>",
              )),
                (this.summaryScreen = new o(this.params, {
                  nextRound: this.nextRound,
                  retry: this.restartRepetition,
                })));
            }
            (!0 === e
              ? (this.$cardwrapperSet = this.initCards(this.cardIds))
              : (this.$cardwrapperSet.detach(),
                (this.$cardwrapperSet = this.initCards(this.cardIds)),
                this.$cardSideAnnouncer.before(this.$cardwrapperSet)),
              this.$cardwrapperSet.prepend(this.summaryScreen.getDOM()),
              !0 === e &&
                ((this.$cardSideAnnouncer = d("<div>", {
                  html: this.params.cardFrontLabel,
                  class: "h5p-dialogcards-card-side-announcer",
                  "aria-live": "polite",
                })),
                (this.$footer = this.createFooter()),
                (this.$mainContent = d("<div>")
                  .append(this.$header)
                  .append(this.$cardwrapperSet)
                  .append(this.$cardSideAnnouncer)
                  .append(this.$footer)
                  .appendTo(this.$inner)),
                this.on("reset", function () {
                  this.reset();
                }),
                this.on("resize", this.resize),
                (this.round =
                  void 0 !== this.previousState.round
                    ? this.previousState.round
                    : 1)));
          }),
          (this.createFooter = () => {
            function t(e, t) {
              (d(e).append('<span class="button-tooltip">' + t + "</span>"),
                d(e).find(".button-tooltip").hide().fadeIn("fast"));
            }
            function e(e) {
              d(e).find(".button-tooltip").remove();
            }
            const n = d("<nav>", {
              class: "h5p-dialogcards-footer",
              role: "navigation",
            });
            if ("normal" === this.params.mode) {
              const r = this;
              ((this.$prev = s
                .createButton({
                  class:
                    "h5p-dialogcards-footer-button h5p-dialogcards-prev truncated",
                  "aria-label": this.params.prev,
                })
                .click(() => {
                  this.prevCard();
                })
                .appendTo(n)),
                this.$prev.hover(
                  function (e) {
                    t(r.$prev, r.params.prev);
                  },
                  function () {
                    e(r.$prev);
                  },
                ),
                (this.$next = s
                  .createButton({
                    class:
                      "h5p-dialogcards-footer-button h5p-dialogcards-next truncated",
                    "aria-label": this.params.next,
                  })
                  .click(() => {
                    this.nextCard();
                  })
                  .appendTo(n)),
                this.$next.hover(
                  function (e) {
                    t(r.$next, r.params.next);
                  },
                  function () {
                    e(r.$next);
                  },
                ),
                (this.$retry = s
                  .createButton({
                    class:
                      "h5p-dialogcards-footer-button h5p-dialogcards-retry h5p-dialogcards-disabled",
                    html: this.params.retry,
                  })
                  .click(() => {
                    this.trigger("reset");
                  })
                  .appendTo(n)),
                this.$retry.hover(
                  function (e) {
                    t(r.$retry, r.params.retry);
                  },
                  function () {
                    e(r.$retry);
                  },
                ),
                (this.$progress = d("<div>", {
                  id: "h5p-dialogcards-progress-" + this.idCounter,
                  class: "h5p-dialogcards-progress",
                  "aria-live": "assertive",
                }).appendTo(n)));
            } else
              ((this.$round = d("<div>", {
                class: "h5p-dialogcards-round",
              }).appendTo(n)),
                (this.$progress = d("<div>", {
                  class: "h5p-dialogcards-cards-left",
                  "aria-live": "assertive",
                }).appendTo(n)));
            return n;
          }),
          (this.updateImageSize = () => {
            let n = 0;
            const t = this.cards[this.currentCardId]
              .getDOM()
              .find(".h5p-dialogcards-card-content");
            if (
              (this.params.dialogs.forEach((e) => {
                !e.image ||
                  ((e =
                    (e.image.height / e.image.width) *
                    t.get(0).getBoundingClientRect().width) > n &&
                    (n = e));
              }),
              0 < n)
            ) {
              let t = n / parseFloat(this.$inner.css("font-size"));
              (15 < t && (t = 15),
                this.cards.forEach((e) => {
                  e.getImage()
                    .parent()
                    .css("height", t + "em");
                }));
            }
          }),
          (this.initCards = (t) => {
            ((this.cards = []),
              (this.currentCardId = 0),
              this.params.behaviour.randomCards && (t = H5P.shuffleArray(t)));
            const n = d("<div>", { class: "h5p-dialogcards-cardwrap-set" });
            for (let e = 0; e < t.length && !(2 <= e); e++) {
              const r = this.getCard(t[e]);
              (r.setProgressText(e + 1, t.length), this.cards.push(r));
              const i = r.getDOM();
              (e === this.currentCardId &&
                (i.addClass("h5p-dialogcards-current"), (this.$current = i)),
                r.addTipToCard(
                  i.find(".h5p-dialogcards-card-content"),
                  "front",
                  e,
                ),
                n.append(i));
            }
            return n;
          }),
          (this.handleCardTurned = (e) => {
            (this.$cardSideAnnouncer.html(
              e ? this.params.cardFrontLabel : this.params.cardBackLabel,
            ),
              this.params.behaviour.enableRetry &&
                this.currentCardId + 1 === this.cardIds.length &&
                this.$retry &&
                (this.$retry.removeClass("h5p-dialogcards-disabled"),
                this.truncateRetryButton()));
          }),
          (this.updateNavigation = () => {
            var e;
            ("normal" === this.params.mode
              ? (this.getCurrentSelectionIndex() < this.cardIds.length - 1
                  ? (this.$next.removeClass("h5p-dialogcards-disabled"),
                    this.$retry.addClass("h5p-dialogcards-disabled"))
                  : this.$next.addClass("h5p-dialogcards-disabled"),
                0 < this.currentCardId &&
                !this.params.behaviour.disableBackwardsNavigation
                  ? this.$prev.removeClass("h5p-dialogcards-disabled")
                  : this.$prev.addClass("h5p-dialogcards-disabled"),
                this.$progress.text(
                  this.params.progressText
                    .replace("@card", this.getCurrentSelectionIndex() + 1)
                    .replace("@total", this.cardIds.length),
                ),
                this.cards[
                  this.findCardPosition(this.cards[this.currentCardId].id)
                ].resizeOverflowingText())
              : (this.$round.text(
                  this.params.round.replace("@round", this.round),
                ),
                (e = this.getCurrentSelectionIndex()),
                this.$progress.text(
                  this.params.cardsLeft.replace(
                    "@number",
                    this.cardIds.length - e,
                  ),
                )),
              this.trigger("resize"));
          }),
          (this.showSummary = (e = !1) => {
            const t = e
                ? this.cardManager.getPileSizes()
                : this.cardManager.updatePiles(this.results),
              n = this.results.filter((e) => !0 === e.result).length,
              r = this.results.length - n,
              i = this.cardPoolSize - n - r,
              o = t.slice(-1)[0],
              a = o === this.cardPoolSize,
              s = {
                round: this.round,
                results: [
                  {
                    field: "h5p-dialogcards-round-cards-right",
                    score: { value: n, max: r + n },
                  },
                  {
                    field: "h5p-dialogcards-round-cards-wrong",
                    score: { value: r, max: r + n },
                  },
                  {
                    field: "h5p-dialogcards-round-cards-not-shown",
                    score: { value: i },
                  },
                  {
                    field: "h5p-dialogcards-overall-cards-completed",
                    score: { value: o, max: this.cardPoolSize },
                  },
                  {
                    field: "h5p-dialogcards-overall-completed-rounds",
                    score: { value: this.round },
                  },
                ],
              };
            (a &&
              ((s.done = !0),
              (s.message = this.params.summaryAllDone
                .replace("@cards", this.cardPoolSize)
                .replace("@max", this.params.behaviour.maxProficiency))),
              this.summaryScreen.update(s),
              this.summaryScreen.show(),
              this.hideCards(),
              this.trigger("resize"));
          }),
          (this.showCards = () => {
            (this.$cardwrapperSet
              .find(".h5p-dialogcards-cardwrap")
              .removeClass("h5p-dialogcards-gone"),
              this.$footer.removeClass("h5p-dialogcards-gone"),
              (this.cardsShown = !0));
          }),
          (this.hideCards = () => {
            (this.$cardwrapperSet
              .find(".h5p-dialogcards-cardwrap")
              .addClass("h5p-dialogcards-gone"),
              this.$footer.addClass("h5p-dialogcards-gone"),
              (this.cardsShown = !1));
          }),
          (this.nextCard = (e) => {
            (void 0 !== e && this.results.push(e),
              this.cards[this.currentCardId].stopAudio(),
              this.cardIds.length - this.getCurrentSelectionIndex() != 1
                ? this.gotoCard(this.getCurrentSelectionIndex() + 1)
                : "repetition" === this.params.mode &&
                  (this.$progress.text(
                    this.params.cardsLeft.replace("@number", 0),
                  ),
                  this.cards[this.currentCardId].showSummaryButton(
                    this.showSummary,
                  )));
          }),
          (this.getCard = (e) => {
            const t = this.cardManager.getCard(e);
            return (t.createButtonListeners(), t);
          }),
          (this.findCardPosition = (n) => {
            let r;
            return (
              this.cards.forEach((e, t) => {
                r || e.id !== n || (r = t);
              }),
              r
            );
          }),
          (this.insertCardToDOM = (e, t) => {
            const n = e.getDOM();
            (void 0 === t
              ? n.appendTo(this.$cardwrapperSet)
              : 0 === t
                ? this.$cardwrapperSet.prepend(n)
                : this.$cardwrapperSet.children().eq(t).after(n),
              e.addTipToCard(
                n.find(".h5p-dialogcards-card-content"),
                "front",
                t,
              ));
          }),
          (this.gotoCard = (n) => {
            if (!(n < 0 || n >= this.cardIds.length)) {
              const e = this.cards[this.currentCardId];
              (e.stopAudio(),
                e.getDOM().removeClass("h5p-dialogcards-current"));
              const t = [];
              (0 < n && t.push(n - 1),
                t.push(n),
                n + 1 < this.cardIds.length && t.push(n + 1),
                t.forEach((e) => {
                  if (void 0 === this.findCardPosition(this.cardIds[e])) {
                    const t = this.getCard(this.cardIds[e]);
                    t.setProgressText(e + 1, this.cardIds.length);
                    ((e = Math.min(e + 1, this.cardIds.length - 1)),
                      (e =
                        this.findCardPosition(this.cardIds[e]) ||
                        this.cards.length));
                    (this.cards.splice(e, 0, t), this.insertCardToDOM(t, e));
                  }
                }),
                this.resize(),
                (n = this.findCardPosition(this.cardIds[n])),
                this.cards.forEach((e, t) => {
                  t < n
                    ? e.getDOM().addClass("h5p-dialogcards-previous")
                    : (e.getDOM().removeClass("h5p-dialogcards-previous"),
                      t === n &&
                        e.getDOM().addClass("h5p-dialogcards-current"));
                }),
                (this.currentCardId = n),
                this.updateNavigation(),
                this.cards[this.currentCardId].setCardFocus());
            }
          }),
          (this.prevCard = () => {
            this.gotoCard(this.getCurrentSelectionIndex() - 1);
          }),
          (this.showAllAudio = () => {
            this.$cardwrapperSet.find(".h5p-audio-inner").removeClass("hide");
          }),
          (this.restartRepetition = () => {
            (this.cardManager.reset(), (this.round = 0), this.nextRound());
          }),
          (this.nextRound = () => {
            (this.round++,
              this.summaryScreen.hide(),
              this.showCards(),
              this.reset(),
              this.createDOM(),
              this.updateNavigation(),
              this.cards[this.currentCardId].setCardFocus(!0),
              this.trigger("resize"));
          }),
          (this.reset = () => {
            ((this.results = []),
              this.cards[this.currentCardId].stopAudio(this.$current.index()),
              this.cards.forEach((e) => {
                e.reset();
              }),
              (this.currentCardId = 0),
              "normal" === this.params.mode &&
                this.cards[this.currentCardId]
                  .getDOM()
                  .addClass("h5p-dialogcards-current"),
              this.updateNavigation(),
              this.$retry && this.$retry.addClass("h5p-dialogcards-disabled"),
              this.showAllAudio(),
              this.cards[this.currentCardId].resizeOverflowingText(),
              this.cards[this.currentCardId].setCardFocus());
          }),
          (this.resize = () => {
            let t = 0;
            (this.updateImageSize(),
              this.params.behaviour.scaleTextNotCard ||
                !1 === this.cardsShown ||
                this.determineCardSizes(),
              this.$cardwrapperSet.css("height", "auto"),
              this.$cardwrapperSet
                .children(":not(.h5p-dialogcards-gone)")
                .each(function () {
                  const e = d(this).css("height", "initial").outerHeight();
                  if (
                    (d(this).css("height", "inherit"),
                    (t = e > t ? e : t),
                    !d(this).next(".h5p-dialogcards-cardwrap").length)
                  ) {
                    const e = d(this)
                      .find(".h5p-dialogcards-cardholder")
                      .css("height", "initial")
                      .outerHeight();
                    ((t = e > t ? e : t),
                      d(this)
                        .find(".h5p-dialogcards-cardholder")
                        .css("height", "inherit"));
                  }
                }));
            var e = t / parseFloat(this.$cardwrapperSet.css("font-size"));
            (this.$cardwrapperSet.css("height", e + "em"),
              this.scaleToFitHeight(),
              this.truncateRetryButton(),
              this.cards[this.currentCardId].resizeOverflowingText());
          }),
          (this.determineCardSizes = () => {
            const s = this;
            (void 0 === this.cardSizeDetermined &&
              (this.cardSizeDetermined = []),
              this.$cardwrapperSet.children(":visible").each(function (t) {
                var n = s.cards[t].id;
                if (-1 === s.cardSizeDetermined.indexOf(n)) {
                  s.cardSizeDetermined.push(n);
                  const r = d(".h5p-dialogcards-card-content", this),
                    i = d(".h5p-dialogcards-card-text-inner-content", r),
                    o = i[0].getBoundingClientRect().height,
                    a = s.cards[t];
                  a.changeText(a.getAnswer());
                  t = i[0].getBoundingClientRect().height;
                  let e = t < o ? o : t;
                  t = parseFloat(i.parent().parent().css("minHeight"));
                  (e < t && (e = t),
                    (e /= parseFloat(r.css("fontSize"))),
                    i.parent().css("height", e + "em"),
                    a.changeText(a.getText()));
                }
              }));
          }),
          (this.scaleToFitHeight = () => {
            if (
              this.$cardwrapperSet &&
              this.$cardwrapperSet.is(":visible") &&
              this.params.behaviour.scaleTextNotCard
            )
              if (this.$inner.parents(".h5p-course-presentation").length) {
                let e = this.$inner.parent();
                this.$inner.parents(".h5p-popup-container").length &&
                  (e = this.$inner.parents(".h5p-popup-container"));
                var r = e.get(0).getBoundingClientRect().height,
                  i = () => {
                    let t = 0;
                    return (
                      this.$inner.children().each(function () {
                        const e = d(this);
                        t +=
                          this.getBoundingClientRect().height +
                          parseFloat(e.css("margin-top")) +
                          parseFloat(e.css("margin-bottom"));
                      }),
                      t
                    );
                  };
                let t = i();
                var o = parseFloat(this.$inner.parent().css("font-size"));
                let n = parseFloat(this.$inner.css("font-size"));
                if (r < t)
                  for (; r < t && ((n -= l.SCALEINTERVAL), !(n < l.MINSCALE)); )
                    (this.$inner.css("font-size", n / o + "em"), (t = i()));
                else {
                  let e = !0;
                  for (; e; ) {
                    if (((n += l.SCALEINTERVAL), n > l.MAXSCALE)) {
                      e = !1;
                      break;
                    }
                    var a = n / o;
                    (this.$inner.css("font-size", a + "em"),
                      (t = i()),
                      r <= t &&
                        ((e = !1),
                        (a = (n - l.SCALEINTERVAL) / o),
                        this.$inner.css("font-size", a + "em")));
                  }
                }
              } else this.cards[this.currentCardId].resizeOverflowingText();
          }),
          (this.truncateRetryButton = () => {
            this.$retry &&
              (this.$retry.removeClass("truncated"),
              this.$retry.html(this.params.retry),
              0.3 <
                (this.$retry.get(0).getBoundingClientRect().width +
                  parseFloat(this.$retry.css("margin-left")) +
                  parseFloat(this.$retry.css("margin-right"))) /
                  this.$retry.parent().get(0).getBoundingClientRect().width &&
                (this.$retry.addClass("truncated"), this.$retry.html("")));
          }),
          (this.getCurrentSelectionIndex = () =>
            this.cardIds.indexOf(this.cards[this.currentCardId].id)),
          (this.getTitle = () =>
            H5P.createTitle(
              this.contentData &&
                this.contentData.metadata &&
                this.contentData.metadata.title
                ? this.contentData.metadata.title
                : "Dialog Cards",
            )),
          (this.getCurrentState = () => {
            if (this.cardManager)
              return {
                cardPiles: this.cardManager.getPiles(),
                cardIds: this.cardIds,
                round: this.round,
                currentCardId: this.getCurrentSelectionIndex(),
                results: this.results,
              };
          }));
      }
    }
    ((l.idCounter = 0),
      (l.SCALEINTERVAL = 0.2),
      (l.MAXSCALE = 16),
      (l.MINSCALE = 4));
    var e = l;
    H5P.Dialogcards = e;
  })());
const realH5PGetPath = H5P.getPath;
H5P.getPath = function (e, t) {
  return e.startsWith("data:") ? e : realH5PGetPath(e, t);
};
H5P.getPath = function (t, n) {
  return t;
};
