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AAM,gCAAiC8lB,EACjD,CACF,EAqCA,YGlgDA,M","sources":["webpack://gleap/webpack/bootstrap","webpack://gleap/webpack/runtime/define property getters","webpack://gleap/webpack/runtime/hasOwnProperty shorthand","webpack://gleap/./src/GleapFeedbackButtonManager.js","webpack://gleap/./src/UI.js","webpack://gleap/./src/GleapNetworkIntercepter.js","webpack://gleap/./src/GleapHelper.js","webpack://gleap/./src/ChecklistNetworkManager.js","webpack://gleap/./src/GleapSSEParser.js","webpack://gleap/./src/AgentNetworkManager.js","webpack://gleap/./node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs","webpack://gleap/./node_modules/@floating-ui/core/dist/floating-ui.core.mjs","webpack://gleap/./node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs","webpack://gleap/./node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs","webpack://gleap/./src/GleapPageFilter.js","webpack://gleap/./src/GleapTooltipManager.js","webpack://gleap/./src/GleapSession.js","webpack://gleap/./src/GleapStreamedEvent.js","webpack://gleap/./src/GleapConfigManager.js","webpack://gleap/./src/ScreenCapture.js","webpack://gleap/./src/ResourceExclusionList.js","webpack://gleap/./src/GleapScreenRecorder.js","webpack://gleap/./src/GleapFeedback.js","webpack://gleap/./src/GleapEventManager.js","webpack://gleap/./src/GleapAgentToolManager.js","webpack://gleap/./src/GleapFrameManager.js","webpack://gleap/./src/GleapMetaDataManager.js","webpack://gleap/./src/GleapConsoleLogManager.js","webpack://gleap/./src/GleapClickListener.js","webpack://gleap/./src/GleapCustomDataManager.js","webpack://gleap/./src/GleapCustomActionManager.js","webpack://gleap/./node_modules/@rrweb/record/dist/record.js","webpack://gleap/./src/GleapReplayRecorder.js","webpack://gleap/./src/ScreenDrawer.js","webpack://gleap/./src/GleapScrollStopper.js","webpack://gleap/./src/GleapMarkerManager.js","webpack://gleap/./src/GleapTranslationManager.js","webpack://gleap/./src/GleapShortcutListener.js","webpack://gleap/./src/GleapPreFillManager.js","webpack://gleap/./src/GleapNotificationManager.js","webpack://gleap/./src/GleapAiChatbarManager.js","webpack://gleap/./src/GleapBannerManager.js","webpack://gleap/./src/GleapModalManager.js","webpack://gleap/./src/GleapAudioManager.js","webpack://gleap/./src/GleapTagManager.js","webpack://gleap/./src/unique-selector/src/getID.js","webpack://gleap/./src/unique-selector/src/getClasses.js","webpack://gleap/./src/unique-selector/src/getCombinations.js","webpack://gleap/./src/unique-selector/src/isElement.js","webpack://gleap/./src/unique-selector/src/getNthChild.js","webpack://gleap/./src/unique-selector/src/getTag.js","webpack://gleap/./src/unique-selector/src/isUnique.js","webpack://gleap/./src/unique-selector/src/unique-selector.js","webpack://gleap/./src/unique-selector/src/getAttributes.js","webpack://gleap/./src/unique-selector/src/getParents.js","webpack://gleap/./src/ElementPicker.js","webpack://gleap/./src/GleapAdminHelper.js","webpack://gleap/./src/GleapAdminManager.js","webpack://gleap/./src/GleapTours.js","webpack://gleap/./src/GleapCopilotTours.js","webpack://gleap/./src/GleapProductTours.js","webpack://gleap/./src/GleapAgentChat.js","webpack://gleap/./src/Gleap.js","webpack://gleap/./src/GleapChecklist.js","webpack://gleap/./src/GleapAgentConversation.js","webpack://gleap/./src/index.js"],"sourcesContent":["// The require scope\nvar __webpack_require__ = {};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","import {\n  GleapFrameManager,\n  GleapConfigManager,\n  GleapNotificationManager,\n  GleapTranslationManager,\n  GleapAiChatbarManager,\n  GleapSession,\n} from './Gleap';\nimport { loadIcon } from './UI';\n\nexport default class GleapFeedbackButtonManager {\n  feedbackButton = null;\n  injectedFeedbackButton = false;\n  buttonHidden = null;\n  lastButtonIcon = null;\n  showingRedDot = false;\n\n  // Feedback button types\n  static FEEDBACK_BUTTON_BOTTOM_RIGHT = 'BOTTOM_RIGHT';\n  static FEEDBACK_BUTTON_BOTTOM_LEFT = 'BOTTOM_LEFT';\n  static FEEDBACK_BUTTON_CLASSIC = 'BUTTON_CLASSIC';\n  static FEEDBACK_BUTTON_CLASSIC_LEFT = 'BUTTON_CLASSIC_LEFT';\n  static FEEDBACK_BUTTON_CLASSIC_BOTTOM = 'BUTTON_CLASSIC_BOTTOM';\n  static FEEDBACK_BUTTON_NONE = 'BUTTON_NONE';\n\n  // GleapFeedbackButtonManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapFeedbackButtonManager();\n    }\n    return this.instance;\n  }\n\n  destroy() {\n    if (this.feedbackButton) {\n      this.feedbackButton.remove();\n      this.feedbackButton = null;\n    }\n\n    this.buttonHidden = null;\n    this.lastButtonIcon = null;\n    this.injectedFeedbackButton = false;\n    this.instance = null;\n  }\n\n  /**\n   * Toggles the feedback button visibility.\n   * @param {*} show\n   * @returns\n   */\n  toggleFeedbackButton(show) {\n    this.buttonHidden = !show;\n\n    GleapFeedbackButtonManager.getInstance().updateFeedbackButtonState();\n    GleapNotificationManager.getInstance().updateContainerStyle();\n  }\n\n  updateRedDot(show) {\n    var frameManager = GleapFrameManager.getInstance();\n    if (!this.feedbackButton || this.buttonHidden || frameManager.isOpened()) {\n      return;\n    }\n\n    const redDotClass = 'bb-feedback-button--red-dot';\n    const existingDot = this.feedbackButton.querySelector(`.${redDotClass}`);\n\n    if (show) {\n      if (!existingDot) {\n        const dot = document.createElement('div');\n        dot.className = redDotClass;\n        this.feedbackButton.appendChild(dot);\n      }\n    } else {\n      if (existingDot) {\n        existingDot.remove();\n      }\n    }\n  }\n\n  feedbackButtonPressed() {\n    var frameManager = GleapFrameManager.getInstance();\n    if (frameManager.isOpened()) {\n      frameManager.hideWidget();\n      this.updateRedDot(this.showingRedDot);\n    } else {\n      frameManager.setAppMode('widget');\n      frameManager.showWidget();\n      this.updateRedDot(false);\n    }\n  }\n\n  /**\n   * Injects the feedback button into the current DOM.\n   */\n  injectFeedbackButton() {\n    if (this.injectedFeedbackButton) {\n      return;\n    }\n    this.injectedFeedbackButton = true;\n\n    var elem = document.createElement('div');\n    elem.addEventListener('click', () => {\n      this.feedbackButtonPressed();\n    });\n    document.body.appendChild(elem);\n    this.feedbackButton = elem;\n\n    this.updateFeedbackButtonState();\n  }\n\n  updateNotificationBadge(count) {\n    const notificationBadge = document.querySelector('.bb-notification-bubble');\n    if (!notificationBadge) {\n      return;\n    }\n\n    const notificationHiddenClass = 'bb-notification-bubble--hidden';\n    if (count > 0 && !GleapFrameManager.getInstance().isOpened()) {\n      notificationBadge.classList.remove(notificationHiddenClass);\n      notificationBadge.innerText = count;\n    } else {\n      notificationBadge.classList.add(notificationHiddenClass);\n    }\n  }\n\n  refresh() {\n    const feedbackButton = document.querySelector('.bb-feedback-button');\n    if (feedbackButton) {\n      this.updateFeedbackButtonText();\n      this.updateFeedbackButtonState();\n    } else {\n      this.injectedFeedbackButton = false;\n      this.feedbackButton = null;\n      this.buttonHidden = null;\n      this.lastButtonIcon = null;\n      this.injectFeedbackButton();\n    }\n  }\n\n  updateFeedbackButtonText() {\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n\n    if (\n      !(\n        flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC ||\n        flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_BOTTOM ||\n        flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_LEFT\n      )\n    ) {\n      return;\n    }\n\n    const feedbackButton = document.querySelector('.bb-feedback-button-classic');\n    if (!feedbackButton) {\n      return;\n    }\n\n    feedbackButton.innerText = flowConfig.widgetButtonText;\n  }\n\n  /**\n   * Updates the feedback button state\n   * @returns\n   */\n  updateFeedbackButtonState() {\n    GleapAiChatbarManager.getInstance().updateUIVisibility();\n\n    if (this.feedbackButton === null) {\n      return;\n    }\n\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n\n    var buttonIcon = '';\n    if (flowConfig.buttonLogo) {\n      buttonIcon = `<img class=\"bb-logo-logo\" src=\"${flowConfig.buttonLogo}\" alt=\"Feedback Button\" />`;\n    } else {\n      buttonIcon = loadIcon('button', '#fff');\n    }\n\n    this.feedbackButton.className = 'bb-feedback-button gleap-font gl-block';\n    this.feedbackButton.setAttribute('dir', GleapTranslationManager.getInstance().isRTLLayout ? 'rtl' : 'ltr');\n\n    if (\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC ||\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_BOTTOM ||\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_LEFT\n    ) {\n      this.feedbackButton.classList.add('bb-feedback-button--classic-button-style');\n\n      this.feedbackButton.innerHTML = `<div class=\"bb-feedback-button-classic ${\n        flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_LEFT\n          ? 'bb-feedback-button-classic--left'\n          : ''\n      }${\n        flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_BOTTOM\n          ? 'bb-feedback-button-classic--bottom'\n          : ''\n      }\">${flowConfig.widgetButtonText}</div>`;\n    } else {\n      if (buttonIcon !== this.lastButtonIcon) {\n        this.feedbackButton.innerHTML = `<div class=\"bb-feedback-button-icon\">${buttonIcon}${loadIcon(\n          'arrowdown',\n          '#fff'\n        )}</div><div class=\"bb-notification-bubble bb-notification-bubble--hidden\"></div>`;\n      }\n    }\n\n    // Prevent dom update if not needed.\n    this.lastButtonIcon = buttonIcon;\n\n    var hideButton = false;\n    if (GleapFeedbackButtonManager.getInstance().buttonHidden === null) {\n      if (flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_NONE) {\n        hideButton = true;\n      }\n    } else {\n      if (GleapFeedbackButtonManager.getInstance().buttonHidden) {\n        hideButton = true;\n      }\n    }\n    if (hideButton) {\n      this.feedbackButton.classList.add('bb-feedback-button--disabled');\n    }\n\n    if (flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_BOTTOM_LEFT) {\n      this.feedbackButton.classList.add('bb-feedback-button--bottomleft');\n    }\n\n    if (GleapFrameManager.getInstance().isOpened()) {\n      this.feedbackButton.classList.add('bb-feedback-button--open');\n    }\n\n    const appMode = GleapFrameManager.getInstance().appMode;\n    if (appMode === 'survey' || appMode === 'survey_full' || appMode === 'survey_web') {\n      this.feedbackButton.classList.add('bb-feedback-button--survey');\n    }\n\n    if (flowConfig.hideForGuests === true && !GleapSession.getInstance().isUser()) {\n      this.feedbackButton.classList.add('bb-feedback-button--hidden');\n    }\n  }\n}\n","import GleapFeedbackButtonManager from './GleapFeedbackButtonManager';\n\nconst calculateShadeColor = function (col, amt) {\n  col = col.replace(/^#/, '');\n  if (col.length === 3) col = col[0] + col[0] + col[1] + col[1] + col[2] + col[2];\n\n  let [r, g, b] = col.match(/.{2}/g);\n  [r, g, b] = [parseInt(r, 16) + amt, parseInt(g, 16) + amt, parseInt(b, 16) + amt];\n\n  r = Math.max(Math.min(255, r), 0).toString(16);\n  g = Math.max(Math.min(255, g), 0).toString(16);\n  b = Math.max(Math.min(255, b), 0).toString(16);\n\n  const rr = (r.length < 2 ? '0' : '') + r;\n  const gg = (g.length < 2 ? '0' : '') + g;\n  const bb = (b.length < 2 ? '0' : '') + b;\n\n  return `#${rr}${gg}${bb}`;\n};\n\nexport const calculateContrast = (hex) => {\n  var r = parseInt(hex.substr(1, 2), 16),\n    g = parseInt(hex.substr(3, 2), 16),\n    b = parseInt(hex.substr(5, 2), 16),\n    yiq = (r * 299 + g * 587 + b * 114) / 1000;\n  return yiq >= 160 ? '#000000' : '#ffffff';\n};\n\nexport const widgetMaxHeight = 700;\n\nexport const injectStyledCSS = (\n  primaryColor,\n  headerColor,\n  buttonColor,\n  borderRadius,\n  backgroundColor,\n  buttonX,\n  buttonY,\n  buttonStyle\n) => {\n  const contrastColor = calculateContrast(primaryColor);\n  const contrastButtonColor = calculateContrast(buttonColor);\n  const contrastBackgroundColor = calculateContrast(backgroundColor);\n  const contrastHeaderColor = calculateContrast(headerColor);\n  const isDarkMode = contrastBackgroundColor === '#ffffff';\n  const headerDarkColor = calculateShadeColor(headerColor, contrastHeaderColor === '#ffffff' ? -35 : -15);\n  const subTextColor = isDarkMode ? calculateShadeColor(backgroundColor, 100) : calculateShadeColor(backgroundColor, -120);\n  const backgroundColorHover = isDarkMode\n    ? calculateShadeColor(backgroundColor, 30)\n    : calculateShadeColor(backgroundColor, -12);\n  const hoverHoverColor = isDarkMode ? calculateShadeColor(backgroundColor, 80) : calculateShadeColor(backgroundColor, -30);\n\n  var borderRadius = parseInt(borderRadius, 10);\n  const buttonBorderRadius = Math.round(borderRadius * 1.05);\n  const containerRadius = Math.round(borderRadius * 0.8);\n  const chatRadius = Math.round(borderRadius * 0.6);\n  const formItemBorderRadius = Math.round(borderRadius * 0.4);\n  const formItemSmallBorderRadius = Math.round(borderRadius * 0.25);\n  const zIndexBase = 2147483600;\n\n  var bottomInfoOffset = 57 + buttonY;\n  if (buttonStyle === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_BOTTOM) {\n    bottomInfoOffset = buttonY + 15;\n  } else if (buttonStyle && buttonStyle.includes('CLASSIC')) {\n    bottomInfoOffset = buttonY;\n  } else if (buttonStyle === GleapFeedbackButtonManager.FEEDBACK_BUTTON_NONE) {\n    bottomInfoOffset = buttonY;\n  }\n\n  const colorStyleSheet = `\n    .gleap-font, .gleap-font * {\n      font-style: normal;\n      font-variant-caps: normal;\n      font-variant-ligatures: normal;\n      font-variant-numeric: normal;\n      font-variant-east-asian: normal;\n      font-weight: normal;\n      font-stretch: normal;\n      font-size: 100%;\n      line-height: 1;\n      font-family: system-ui, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";\n    }\n    .gleap-ai-ui-widget {\n      display: none;\n    }\n    .gleap-input-highlight {\n      box-shadow: 0 0 0 3px ${primaryColor} !important;\n    }\n    .gleap-frame-container {\n      right: ${buttonX}px;\n      bottom: ${61 + buttonY}px;\n      width: calc(100% - 40px);\n      max-width: 410px;\n      position: fixed;\n      z-index: ${zIndexBase + 31};\n      visibility: visible;\n      box-shadow: 0px 5px 30px rgba(0, 0, 0, 0.16);\n      border-radius: ${containerRadius}px;\n      overflow: hidden;\n      animation-duration: .3s;\n      animation-fill-mode: both;\n      animation-name: gleapFadeInUp;\n      user-select: none;\n      pointer-events: none;\n      transition: max-width 0.3s ease-out;\n    }\n\n    .gleap-admin-highlight {\n      box-shadow: 0px 0px 0px 4px red;\n    }\n\n    :root {\n      --gleap-margin-top: 50px;\n    }\n\n    .gleap-tooltip-anchor {\n      position: relative;\n      display: inline-block;\n      float: left;\n      max-width: 0px;\n      width: 17px;\n    }\n\n    .gleap-tooltip-hotspot {\n      position: absolute;\n      display: block;\n      width: 17px;\n      height: 17px;\n      cursor: pointer;\n      top: 0px;\n      left: 0px;\n    }\n\n    @keyframes gleap-pulse {\n      0% {\n        transform: scale(0);\n        opacity: 0.25;\n      }\n      45% {\n        transform: scale(2.5);\n        opacity: 0;\n      }\n      100% {\n        transform: scale(0);\n        opacity: 0;\n      }\n    }\n\n    .gleap-tooltip-hotspot-animation {\n      position: absolute;\n      border-radius: 17px;\n      opacity: 0.25;\n      display: block;\n      width: 17px;\n      height: 17px;\n      cursor: pointer;\n      top: 0px;\n      left: 0px;\n      animation: gleap-pulse 5s infinite;\n    }\n\n    .gleap-tooltip-hotspot svg {\n      width: 17px;\n      height: 17px;\n      object-fit: contain;\n      display: block;\n    }\n\n    .gleap-tooltip-inner {\n      position: relative;\n      overflow: visible;\n      font-size: 14px;\n      font-weight: normal;\n      color: #000;\n      line-height: 1.3;\n    }\n\n    .gleap-tooltip {\n      position: absolute;\n      background-color: #fff;\n      color: #000;\n      font-size: 15px;\n      line-height: 18px;\n      padding: 16px;\n      padding-top: 8px;\n      padding-bottom: 8px;\n      border-radius: 4px;\n      max-width: min(350px, 80vw);\n      box-shadow: 0px 5px 30px rgba(0, 0, 0, 0.2);\n      opacity: 0;\n      visibility: hidden;\n      transition: opacity 0.2s, visibility 0.2s;\n      z-index: ${zIndexBase + 100};\n    }\n\n    .gleap-tooltip a {\n      color: ${primaryColor};\n      text-decoration: underline;\n      display: inline !important;\n      margin: 0px !important;\n      padding: 0px !important;\n      word-break: break-word;\n    }\n\n    .gleap-tooltip ul {\n      padding-left: 16px;\n    }\n\n    .gleap-tooltip b {\n      font-weight: 600;\n    }\n\n    .gleap-tooltip h2 {\n      font-size: 18px;\n      line-height: 20px;\n      font-weight: 600;\n      margin-top: 8px;\n      margin-bottom: 8px;\n    }\n\n    .gleap-tooltip h3 {\n      font-size: 16px;\n      line-height: 18px;\n      font-weight: 600;\n      margin-top: 8px;\n      margin-bottom: 8px;\n    }\n\n    .gleap-tooltip p {\n      padding: 0px;\n      margin-top: 8px;\n      margin-bottom: 8px;\n    }\n\n    .gleap-tooltip img {\n      max-width: 100%;\n      max-height: 300px;\n      width: 100%;\n      height: auto;\n      object-fit: cover;\n      margin-top: 8px;\n      margin-bottom: 8px;\n      border-radius: 4px;\n    }\n\n    .gleap-tooltip iframe,\n    .gleap-tooltip video {\n      max-width: 100%;\n      width: 100%;\n      height: auto;\n      min-height: 200px;\n      display: block;\n      border: none;\n      outline: none;\n      padding: 0px;\n      margin-top: 8px;\n      margin-bottom: 8px;\n      border-radius: 4px;\n    }\n\n    .gleap-tooltip-arrow {\n      position: absolute;\n      width: 20px;\n      height: 20px;\n    }\n\n    .gleap-tooltip-arrow svg {\n      width: 20px;\n      height: 20px;\n      object-fit: contain;\n    }\n\n    .gleap-b-frame {\n      width: 100%;\n      height: 100%;\n      border: none;\n      pointer-events: auto;\n      padding: 0px;\n      margin: 0px;\n    }\n\n    .gleap-b-shown {\n      transition: margin 0.3s ease-out;\n      margin-top: var(--gleap-margin-top);\n      position: relative;\n      z-index: 10000;\n    }\n\n    .gleap-b-f {\n      margin-top: 0px;\n    }\n\n    .gleap-b {\n      display: none;\n      position: absolute;\n      top: calc(-1 * var(--gleap-margin-top));\n      left: 0px;\n      width: 100vw;\n      height: var(--gleap-margin-top);\n      z-index: ${zIndexBase + 99};\n    }\n\n    @keyframes gleapSlideIn {\n      from {\n          top: calc(-1 * var(--gleap-margin-top));\n      }\n      to {\n          top: 10px;\n      }\n    }\n\n    .gleap-b-f .gleap-b {\n      position: fixed;\n      top: 10px;\n      animation: gleapSlideIn .25s ease-out forwards;\n      max-width: 800px;\n      width: calc(100% - 20px);\n      left: 50%;\n      z-index: ${zIndexBase + 99};\n      transform: translateX(-50%);\n      border-radius: ${formItemBorderRadius}px;\n      overflow: hidden;\n      box-shadow: 0px 10px 20px rgba(0, 0, 0, 0.15), 0px 5px 5px rgba(0, 0, 0, 0.05);\n    }\n\n    .gleap-b-shown .gleap-b {\n      display: block;\n    }\n\n    .gleap-image-view {\n      position: fixed;\n      top: 0px;\n      left: 0px;\n      width: 100vw;\n      height: 100vh;\n      z-index: ${zIndexBase + 99};\n      background-color: ${contrastBackgroundColor}cc;\n      display: flex;\n      align-items: center;\n      justify-content: center;\n    }\n\n    .gleap-image-view-image {\n      width: 90%;\n      height: auto;\n      max-width: 90%;\n      max-height: 90%;\n      object-fit: contain;\n    }\n\n    .gleap-image-view-close {\n      position: fixed;\n      top: 20px;\n      right: 20px;\n      width: 32px;\n      height: 32px;\n      opacity: 0.8;\n      z-index: ${zIndexBase + 140};\n      box-shadow: 0px 5px 18px rgba(0, 0, 0, 0.16);\n      cursor: pointer;\n    }\n\n    .gleap-image-view-close:hover {\n      opacity: 1;\n    }\n\n    .gleap-image-view-close svg path {\n      fill: ${backgroundColor};\n    }\n\n    [dir=rtl].gleap-frame-container {\n      right: auto;\n      left: ${buttonX}px;\n      bottom: ${61 + buttonY}px;\n    }\n\n    .gleap-frame-container--loading iframe {\n      opacity: 0;\n    }\n\n    .gleap-frame-container--loading::before {\n      content: \" \";\n      position: fixed;\n      top: 0px;\n      left: 0px;\n      right: 0px;\n      height: 100%;\n      max-height: 380px;\n      background: linear-gradient(\n        130deg,\n        ${headerDarkColor} 0%,\n        ${headerColor} 100%\n      );\n    }\n    \n    .gleap-frame-container--loading::after {\n      content: \" \";\n      position: fixed;\n      top: 0px;\n      left: 0px;\n      right: 0px;\n      height: 100%;\n      height: 100%;\n      max-height: 380px;\n      background: linear-gradient(\n        180deg,\n        transparent 60%,\n        ${backgroundColor}1A 70%,\n        ${backgroundColor} 100%\n      );\n    }\n\n    .gleap-frame-container--loading-nogradient::before {\n      max-height: 340px;\n      background: ${headerColor} !important;\n    }\n\n    .gleap-frame-container--loading-nofade::after {\n      display: none !important;\n    }\n\n    .gleap-frame-container--survey {\n      bottom: ${buttonY}px !important;\n    }\n\n    .gleap-frame-container--extended {\n      max-width: 690px !important;\n    }\n\n    .gleap-frame-container--survey-full {\n      position: fixed;\n      top: 0 !important;\n      left: 0 !important;\n      bottom: 0 !important;\n      right: 0 !important;\n      width: 100vw !important;\n      max-width: 100vw !important;\n      height: 100vh;\n      height: 100dvh !important;\n      background-color: rgba(0, 0, 0, 0.5);\n      backdrop-filter: blur(6px);\n      display: flex !important;\n      justify-content: center !important;\n      align-items: center !important;\n      max-height: 100vh;\n      max-height: 100dvh !important;\n      border-radius: 0 !important;\n      animation-name: none !important;\n    }\n\n    .gleap-frame-container--survey-full .gleap-frame-container-inner {\n      max-width: 640px !important;\n      width: calc(100% - 24px);\n      border-radius: ${containerRadius}px;\n      overflow: hidden;\n    }\n\n    .gleap-frame-container--classic {\n      right: ${buttonX}px;\n      bottom: ${buttonY}px;\n    }\n\n    [dir=rtl].gleap-frame-container--classic {\n      right: auto;\n      left: ${buttonX}px;\n      bottom: ${buttonY}px;\n    }\n\n    .gleap-frame-container--no-button {\n      bottom: ${buttonY}px;\n    }\n\n    [dir=rtl].gleap-frame-container--classic-left {\n      bottom: ${buttonY}px;\n    }\n\n    .gleap-frame-container--classic-left {\n      right: auto;\n      left: ${buttonX}px;\n      bottom: ${buttonY}px;\n    }\n\n    [dir=rtl].gleap-frame-container--classic-left {\n      left: auto;\n      right: ${buttonX}px;\n      bottom: ${buttonY}px;\n    }\n\n    .gleap-frame-container--modern-left {\n      right: auto;\n      left: ${buttonX}px;\n      bottom: ${61 + buttonY}px;\n    }\n\n    [dir=rtl].gleap-frame-container--modern-left {\n      left: auto;\n      right: ${buttonX}px;\n      bottom: ${61 + buttonY}px;\n    }\n\n    .gleap-frame-container--animate {\n      pointer-events: auto !important;\n    }\n\n    @keyframes gleapFadeInUp {\n      from {\n          opacity: 0;\n          transform: translate3d(0, 100%, 0);\n      }\n      to {\n          opacity: 1;\n          transform: translate3d(0, 0, 0);\n      }\n    }\n\n    @keyframes gleapFadeInUpMobile {\n      from {\n          opacity: 0;\n          transform: translate3d(0, 10%, 0);\n      }\n      to {\n          opacity: 1;\n          transform: translate3d(0, 0, 0);\n      }\n    }\n\n    .gleap-notification-container {\n      position: fixed;\n      bottom: ${bottomInfoOffset}px;\n      right: ${buttonX}px;\n      z-index: ${zIndexBase + 30};\n      display: flex;\n      flex-direction: column;\n      align-items: flex-end;\n      width: 100%;\n      max-width: min(340px, 80vw);\n    }\n\n    .gleap-notification-container--left {\n      left: ${4 + buttonX}px;\n      right: initial !important;\n    }\n\n    [dir=rtl].gleap-notification-container {\n      left: ${4 + buttonX}px;\n      right: initial !important;\n    }\n\n    [dir=rtl].gleap-notification-container--left {\n      left: initial !important;\n      right: ${buttonX}px !important;\n      align-items: flex-start !important;\n    }\n\n    .gleap-notification-container--no-button {\n      bottom: ${buttonY}px;\n    }\n\n    .gleap-notification-item {\n      animation-duration: 0.7s;\n      animation-fill-mode: both;\n      animation-name: bbFadeInOpacity;\n    }\n\n    .gleap-notification-close {\n      border-radius: 100%;\n      width: 28px;\n      height: 28px;\n      background-color: ${subTextColor};\n      display: flex;\n      justify-content: center;\n      align-items: center;\n      margin-bottom: 8px;\n      cursor: pointer;\n      visibility: hidden;\n      pointer-events: none;\n    }\n\n    .gleap-notification-container:hover .gleap-notification-close {\n      visibility: visible;\n      pointer-events: auto;\n      animation-duration: 0.7s;\n      animation-fill-mode: both;\n      animation-name: bbFadeInOpacity;\n    }\n\n    @media only screen and (max-width: 450px) {\n      .gleap-notification-close {\n        visibility: visible;\n        pointer-events: auto;\n        animation-duration: 0.7s;\n        animation-fill-mode: both;\n        animation-name: bbFadeInOpacity;\n      }\n    }\n\n    .gleap-notification-close svg {\n      width: 45%;\n      height: 45%;\n      object-fit: contain;\n      fill: ${backgroundColor};\n    }\n\n    .gleap-notification-item-checklist-container {\n      display: flex;\n      animation: fadeIn;\n      animation-duration: .45s;\n      background-color: ${backgroundColor};\n      border-radius: ${subTextColor};\n      box-sizing: border-box;\n      cursor: pointer;\n      flex-direction: column;\n      overflow: hidden;\n      box-shadow: 0px 5px 30px rgba(0, 0, 0, 0.2);\n      border-radius: ${chatRadius}px;\n      margin-bottom: 12px;\n    }\n\n    .gleap-notification-item-checklist-content {\n      align-items: flex-start;\n      display: flex;\n      flex-direction: column;\n      padding: 15px;\n      width: 100%;\n      width: min(310px, 70vw);\n      max-width: min(310px, 70vw);\n    }\n\n    .gleap-notification-item-checklist-content-title {\n      color: ${contrastBackgroundColor};\n      font-size: 15px;\n      font-weight: 500;\n      line-height: 21px;\n      margin-bottom: 10px;\n      max-width: 100%;\n      -webkit-line-clamp: 3;\n      -webkit-box-orient: vertical;\n      overflow: hidden;\n    }\n\n    .gleap-notification-item-checklist-content-progress {\n      width: 100%;\n      height: 8px;\n      border-radius: 8px;\n      background-color: ${backgroundColorHover};\n    }\n\n    .gleap-notification-item-checklist-content-progress-inner {\n      height: 100%;\n      border-radius: 8px;\n      background-color: ${primaryColor};\n    }\n\n    .gleap-notification-item-checklist-content-next {\n      color: ${subTextColor};\n      font-size: 15px;\n      font-weight: normal;\n      line-height: 21px;\n      margin-top: 10px;\n      max-width: 100%;\n      white-space: nowrap;\n      overflow: hidden;\n      text-overflow: ellipsis;\n      display: flex;\n      align-items: center;\n    }\n\n    .gleap-notification-item-checklist-content-next svg {\n      height: 18px;\n      margin-right: 5px;\n      width: auto;\n    }\n\n    .gleap-notification-item-checklist-content-next b {\n      font-size: 15px;\n      font-weight: normal;\n      color: ${contrastBackgroundColor};\n    }\n\n    .gleap-notification-item-news {\n      width: 100%;\n    }\n\n    .gleap-news-pagination {\n      display: flex;\n      justify-content: space-between;\n      align-items: center;\n      margin-top: 10px;\n      width: 100%;\n    }\n\n    .gleap-news-page-indicator {\n      font-size: 12px;\n      color: ${subTextColor};\n    }\n\n    .gleap-news-next-button {\n      background-color: ${primaryColor};\n      color: ${contrastColor};\n      border-radius: ${formItemSmallBorderRadius}px;\n      box-sizing: border-box;\n      padding: 5px 10px;\n      font-size: 14px;\n      font-weight: bold;\n      line-height: 21px;\n      border: none;\n      text-align: center;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      display: flex;\n      justify-content: center;\n      align-items: center;\n      box-shadow: none !important;\n      outline: none !important;^\n    }\n\n    .gleap-notification-item-news-content {\n      align-items: flex-start;\n      display: flex;\n      flex-direction: column;\n      padding: 15px;\n    }\n\n    .gleap-notification-item-news-preview {\n      color: ${subTextColor};\n      font-size: 14px;\n      line-height: 21px;\n      font-weight: 400;\n      overflow-wrap: break-word;\n      word-break: break-word;\n      display: block;\n      display: -webkit-box;\n      -webkit-line-clamp: 2;\n      -webkit-box-orient: vertical;\n      overflow: hidden;\n    }\n\n    .gleap-notification-item-news-sender {\n      display: flex;\n      align-items: center;\n      color: ${subTextColor};\n      font-size: 15px;\n      line-height: 21px;\n      font-weight: 400;\n    }\n    \n    .gleap-notification-item-news-content-title {\n      color: ${contrastBackgroundColor};\n      font-size: 15px;\n      font-weight: 500;\n      line-height: 21px;\n      margin-bottom: 6px;\n      max-width: 100%;\n      -webkit-line-clamp: 3;\n      -webkit-box-orient: vertical;\n      overflow: hidden;\n      cursor: pointer;\n    }\n\n    .gleap-notification-item-news-sender img {\n      border-radius: 100%;\n      height: 20px;\n      margin-right: 8px;\n      object-fit: cover;\n      width: 20px;\n    }\n\n    [dir=rtl] .gleap-notification-item-news-sender img {\n      margin-left: 8px;\n      margin-right: 0px !important;\n    }\n\n    .gleap-notification-item-news-container {\n      display: flex;\n      animation: fadeIn;\n      animation-duration: .45s;\n      background-color: ${backgroundColor};\n      border-radius: ${subTextColor};\n      box-sizing: border-box;\n      flex-direction: column;\n      overflow: hidden;\n      box-shadow: 0px 5px 30px rgba(0, 0, 0, 0.2);\n      border-radius: ${chatRadius}px;\n      margin-bottom: 12px;\n    }\n\n    .gleap-notification-item-news-image {\n      background-color: ${subTextColor};\n      height: 170px;\n      max-height: 170px;\n      object-fit: cover;\n      width: 100%;\n      cursor: pointer;\n    }\n      \n    .gleap-notification-item-news-content-title:hover {\n      color: ${primaryColor};\n    }\n\n    .gleap-notification-item {\n      display: flex;\n      align-items: flex-end;\n      cursor: pointer;\n    }\n\n    .gleap-notification-item img {\n      width: 32px;\n      height: 32px;\n      min-width: 32px;\n      border-radius: 100%;\n      object-fit: cover;\n      margin-right: 8px;\n      margin-bottom: 12px;\n      cursor: pointer;\n    }\n\n    [dir=rtl] .gleap-notification-item img {\n      margin-left: 8px;\n      margin-right: 0px !important;\n    }\n\n    .gleap-notification-item-container {\n      box-shadow: 0px 5px 30px rgba(0, 0, 0, 0.2);\n      border-radius: ${chatRadius}px;\n      border-bottom-left-radius: 0px;\n      padding: 20px;\n      background-color: ${backgroundColor};\n      margin-bottom: 12px;\n      cursor: pointer;\n      font-size: 15px;\n      line-height: 21px;\n      color: ${contrastBackgroundColor};\n      position: relative;\n    }\n\n    .gleap-notification-item-container::after {\n      content: \" \";\n      position: absolute;\n      bottom: 0px;\n      width: 0px;\n      height: 0px;\n      left: -6px;\n      border-style: solid;\n      border-width: 0px 0px 10px 6px;\n      border-color: transparent transparent ${backgroundColor};\n    }\n\n    .gleap-notification-item-sender {\n      color: ${subTextColor};\n      line-height: 20px;\n    }\n\n    .gleap-notification-item-content {\n      line-height: 20px;\n      color: ${contrastBackgroundColor};\n      margin-top: 4px;\n      min-width: min(200px, 50vw);\n      word-wrap: break-word;\n      word-break: break-word;\n    }\n\n    .gleap-frame-container-inner {\n      position: relative;\n      width: 100%;\n      height: calc(100vh - ${84 + buttonY}px);\n      max-height: ${widgetMaxHeight}px;\n    }\n\n    .gleap-frame-container--survey .gleap-frame-container-inner {\n      height: calc(100vh - 40px);\n    }\n    \n    .gleap-frame-container-inner:before {\n      content: \" \";\n      position: absolute;\n      width: 100%;\n      height: calc(100% - ${containerRadius}px);\n      top: ${containerRadius}px;\n      background-color: ${backgroundColor};\n      z-index: -1;\n    }\n    \n    .gleap-frame-container iframe {\n      height: 100% !important;\n      width: 100% !important;\n      max-width: 100% !important;\n      display: block !important;\n      pointer-events: auto !important;\n    }\n    \n    .gleap-frame-container--hidden {\n      display: none !important;\n      pointer-events: none;\n      animation: none !important;\n    }\n    \n    .bb-feedback-button {\n      margin: 0px;\n      position: fixed;\n      bottom: ${buttonY}px;\n      right: ${buttonX}px;\n      border-radius: 30px;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      background-color: transparent;\n      color: #000000;\n      z-index: ${zIndexBase + 30};\n      box-sizing: border-box;\n      display: flex;\n      align-items: center;\n      padding: 0px;\n    }\n\n    @keyframes bbRedDotPulse {\n      0% {\n        opacity: 1;\n      }\n      50% {\n        opacity: 0.8;\n      }\n      100% {\n        opacity: 1;\n      }\n    }\n\n    .bb-feedback-button--red-dot {\n      position: absolute;\n      top: 0px;\n      right: 0px;\n      width: 14px;\n      height: 14px;\n      border-radius: 50%;\n      background-color: #ff3b30;\n      box-shadow: 0 2px 4px rgba(0,0,0,0.2);\n      z-index: ${zIndexBase + 31};\n      animation: bbRedDotPulse 2s ease-in-out infinite;\n    }\n\n    [dir=rtl].bb-feedback-button {\n      bottom: ${buttonY}px;\n      right: auto;\n      left: ${buttonX}px;\n    }\n    \n    .bb-feedback-button--bottomleft {\n      bottom: ${buttonY}px;\n      right: auto;\n      left: ${buttonX}px;\n    }\n\n    [dir=rtl].bb-feedback-button--bottomleft {\n      bottom: ${buttonY}px;\n      right: ${buttonX}px;\n      left: auto;\n    }\n    \n    .bb-feedback-button--disabled {\n      display: none !important;\n    }\n\n    .bb-feedback-button--hidden {\n      display: none !important;\n    }\n    \n    .bb-feedback-button-text {\n      padding: 8px 12px;\n      display: flex;\n      flex-direction: column;\n      align-items: flex-start;\n      justify-content: center;\n      background-color: #fff;\n      border-radius: 8px;\n      box-shadow: 0px 0px 14px 0px rgba(0, 0, 0, 0.15);\n      position: relative;\n      z-index: 99;\n    }\n    \n    .bb-feedback-button-text:before {\n      content: \"\";\n      position: absolute;\n      box-shadow: rgba(0, 0, 0, 0.04) 6px 6px 5px;\n      transform: rotate(315deg);\n      bottom: 16px;\n      right: -4px;\n      border-width: 10px;\n      border-style: solid;\n      border-color: transparent #fff #fff transparent;\n    }\n    \n    .bb-feedback-button--bottomleft .bb-feedback-button-text:before {\n      display: none;\n    }\n    \n    .bb-feedback-button-text:after {\n      content: \"\";\n      position: absolute;\n      bottom: 12px;\n      right: 0px;\n      background-color: #fff;\n      width: 5px;\n      height: 30px;\n    }\n    \n    .bb-feedback-button-text-title {\n      font-family: sans-serif;\n      font-size: 14px;\n      color: #666;\n      line-height: 18px;\n      max-width: 220px;\n    }\n    \n    .bb-feedback-button-text-title b {\n      color: #000000;\n      font-weight: 600;\n    }\n\n    .bb-notification-bubble {\n      position: absolute;\n      top: -5px;\n      right: -5px;\n      min-width: 12px;\n      padding: 0px 4px;\n      height: 20px;\n      min-width: 20px;\n      border-radius: 20px;\n      background-color: red;\n      color: #fff;\n      font-size: 11px;\n      font-family: sans-serif;\n      text-align: center;\n      line-height: 20px;\n    }\n\n    .bb-notification-bubble--hidden {\n      display: none;\n    }\n    \n    .bb-feedback-button-icon {\n      width: 48px;\n      height: 48px;\n      border-radius: 48px;\n      background-color: #485bff;\n      transition: box-shadow, transform 0.2s ease-in-out;\n      box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.15), 0px 0px 20px rgba(0, 0, 0, 0.1);\n      position: relative;\n    }\n    \n    .bb-feedback-button-classic {\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      top: 50%;\n      right: 0px;\n      position: fixed;\n      transform: rotate(-90deg) translate(50%, -50%);\n      transform-origin: 100% 50%;\n      padding: 9px 20px;\n      text-align: center;\n      background-color: #485bff;\n      border-top-left-radius: 8px;\n      border-top-right-radius: 8px;\n      font-family: sans-serif;\n      font-size: 16px;\n      color: #fff;\n      box-shadow: 0px 0px 14px 0px rgba(0, 0, 0, 0.25);\n    }\n\n    [dir=rtl].bb-feedback-button .bb-feedback-button-classic {\n      top: 50%;\n      left: 0px;\n      right: auto;\n      transform: rotate(90deg) translate(-50%, -100%);\n      transform-origin: 0% 0%;\n    }\n    \n    .bb-feedback-button-classic--left {\n      top: 50%;\n      left: 0px;\n      right: auto;\n      transform: rotate(90deg) translate(-50%, -100%);\n      transform-origin: 0% 0%;\n    }\n\n    [dir=rtl].bb-feedback-button .bb-feedback-button-classic--left {\n      top: 50%;\n      right: 0px;\n      left: auto;\n      transform: rotate(-90deg) translate(50%, -50%);\n      transform-origin: 100% 50%;\n    }\n    \n    .bb-feedback-button-classic--bottom {\n      top: auto;\n      bottom: 0px;\n      transform: none;\n      right: ${buttonX}px;\n      left: auto;\n    }\n    \n    [dir=rtl].bb-feedback-button .bb-feedback-button-classic--bottom {\n      top: auto;\n      bottom: 0px;\n      transform: none;\n      left: ${buttonX}px;\n      right: auto;\n    }\n\n    .bb-feedback-button--classic-button-style {\n      animation-duration: 0.2s;\n      animation-fill-mode: both;\n      animation-name: bbFadeInOpacity;\n    }\n    \n    .bb-feedback-button--open.bb-feedback-button--classic-button-style {\n      animation-duration: 0.2s;\n      animation-fill-mode: both;\n      animation-name: bbFadeOutRight;\n    }\n    \n    .bb-feedback-button .bb-logo-logo {\n      position: absolute;\n      width: 30px;\n      height: 30px;\n      top: 9px;\n      left: 9px;\n      object-fit: contain;\n      animation-duration: 0.3s;\n      animation-fill-mode: both;\n      animation-name: bbZoomIn;\n    }\n    \n    .bb-feedback-button .bb-logo-arrowdown {\n      position: absolute;\n      width: 14px;\n      height: 14px;\n      top: 17px;\n      left: 17px;\n      object-fit: contain;\n      animation-duration: 0.3s;\n      animation-fill-mode: both;\n    }\n    \n    .bb-feedback-button .bb-logo-arrowdown {\n      animation-name: bbZoomOut;\n    }\n    \n    .bb-feedback-button--open .bb-logo-arrowdown {\n      animation-name: bbZoomIn;\n    }\n    \n    .bb-feedback-button--open .bb-logo-logo {\n      animation-name: bbZoomOut;\n    }\n    \n    .bb-feedback-button-icon:hover {\n      box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.25), 0px 0px 20px rgba(0, 0, 0, 0.2);\n      transform: scale(1.1);\n    }\n    \n    .bb-feedback-button--open .bb-feedback-button-text {\n      animation-name: bbFadeOutDown;\n    }\n    \n    .bb-feedback-button--open .bb-feedback-button-icon {\n      display: flex;\n    }\n    \n    .bb-capture-svg {\n      position: fixed;\n      z-index: ${zIndexBase + 14};\n      top: 0px;\n      left: 0px;\n      right: 0px;\n      width: 100%;\n      height: 100%;\n      padding: 0px;\n      margin: 0px;\n      cursor: crosshair;\n    }\n\n    .bb-capture-svg--preview {\n      cursor: auto !important;\n    }\n    \n    .bb-rec-on-circle {\n      animation-name: bbRecIconFade;\n      animation-duration: 2s;\n      animation-iteration-count: infinite;\n      animation-direction: alternate;\n    }\n    \n    .bb-rec-on-cont {\n      animation-name: bbRecIconContFade;\n      animation-duration: 2s;\n      animation-iteration-count: infinite;\n      animation-direction: alternate;\n    }\n    \n    .bb-capture-editor-drag-info {\n      position: fixed;\n      top: -200px;\n      left: 0px;\n      z-index: ${zIndexBase + 16};\n      transition: opacity 0.3s ease-in-out;\n    }\n    \n    .bb-capture-editor-drag-info svg {\n      width: 24px;\n      height: 24px;\n    }\n    \n    .bb-capture-editor-borderlayer {\n      position: fixed;\n      top: 0px;\n      left: 0px;\n      width: 100vw;\n      height: 100vh;\n      border: 4px solid ${primaryColor};\n      cursor: crosshair;\n      z-index: ${zIndexBase + 10};\n      box-sizing: border-box;\n      pointer-events: none;\n    }\n    \n    .bb-capture-editor-notrecording .bb-capture-editor-borderlayer {\n      background-color: rgba(0, 0, 0, 0.8);\n    }\n\n    .bb-capture-editor-recording .bb-capture-editor-borderlayer {\n      border: 4px solid #eb144c !important;\n    }\n    \n    .bb-capture-editor-recording .bb-capture-dismiss {\n      display: none;\n    }\n    \n    .bb-capture-editor-item-inactive {\n      opacity: 0.3;\n      cursor: not-allowed !important;\n    }\n    \n    .bb-capture-editor-notrecording .bb-capture-toolbar-drawingitem {\n      opacity: 0.3;\n      cursor: not-allowed !important;\n    }\n    \n    .bb-capture-editor-notrecording .bb-capture-editor-drag-info {\n      display: none;\n    }\n    \n    .bb-capture-editor-notrecording .bb-capture-svg {\n      pointer-events: none !important;\n    }\n    \n    .bb-capture-toolbar {\n      position: fixed;\n      top: 20px;\n      left: 50%;\n      transform: translateX(-50%);\n      z-index: ${zIndexBase + 18};\n      background-color: #fff;\n      padding: 5px;\n      display: flex;\n      align-items: center;\n      border-radius: 8px;\n      box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.15), 0px 0px 20px rgba(0, 0, 0, 0.1);\n      transition: opacity 0.3s ease-in-out;\n    }\n    \n    .bb-capture-dismiss {\n      position: fixed;\n      top: 0px;\n      right: 0px;\n      z-index: ${zIndexBase + 18};\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      width: 36px;\n      height: 36px;\n      display: flex;\n      justify-content: center;\n      align-items: center;\n      background-color: ${primaryColor};\n      border-bottom-left-radius: ${formItemSmallBorderRadius}px;\n    }\n\n    [dir=rtl] .bb-capture-dismiss {\n      top: 0px;\n      left: 0px;\n      right: auto;\n      border-bottom-left-radius: 0px !important;\n      border-bottom-right-radius: ${formItemSmallBorderRadius}px;\n    }\n    \n    .bb-capture-dismiss svg path {\n      fill: ${contrastColor};\n    }\n    \n    .bb-capture-dismiss svg {\n      width: 20px;\n      height: 20px;\n      object-fit: contain;\n    }\n    \n    .bb-capture-button-next {\n      font-family: sans-serif;\n      box-sizing: border-box;\n      font-weight: 600;\n      text-align: center;\n      width: auto;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      margin: 0px;\n      line-height: 36px;\n      padding: 0px 12px;\n      font-size: 15px;\n      margin-left: 12px;\n    }\n\n    [dir=rtl].bb-capture-editor .bb-capture-button-next {\n      margin-left: auto;\n      margin-right: 12px;\n    }\n    \n    .bb-capture-toolbar-item-spacer {\n      width: 1px;\n      height: 38px;\n      min-width: 1px;\n      margin: 0px 5px;\n    }\n    \n    .bb-capture-toolbar-item {\n      width: 42px;\n      height: 38px;\n      min-width: 42px;\n      display: flex;\n      align-items: center;\n      justify-content: center;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      position: relative;\n      margin-right: 5px;\n    }\n\n    .drag-handle-item {\n      cursor: grab !important;\n      width: 34px;\n      min-width: 34px;\n    }\n\n    .drag-handle-item svg {\n      width: 18px !important;\n      height: 18px !important;\n    }\n    \n    .bb-capture-toolbar-item svg {\n      width: 23px;\n      height: 23px;\n      object-fit: contain;\n    }\n    \n    .bb-capture-toolbar-item-selectedcolor {\n      border-radius: 100%;\n      width: 20px;\n      height: 20px;\n      background-color: #db4035;\n    }\n    \n    .bb-capture-toolbar-item[data-type=\"undo\"] svg {\n      width: 18px;\n      height: 18px;\n    }\n    \n    .bb-capture-toolbar-item[data-active=\"true\"] {\n      position: relative;\n    }\n    \n    .bb-capture-preview {\n      display: none;\n      background-color: rgba(0, 0, 0, 0.6);\n      position: fixed;\n      top: 0px;\n      left: 0px;\n      width: 100vw;\n      height: 100vh;\n      justify-content: center;\n      align-items: center;\n      z-index: ${zIndexBase + 20};\n    }\n    \n    .bb-capture-preview-inner {\n      background-color: #fff;\n      padding: 0px;\n      box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.15), 0px 0px 20px rgba(0, 0, 0, 0.1);\n      border-radius: 8px;\n      flex-direction: column;\n      max-width: 640px;\n      width: 100%;\n      margin: 20px;\n    }\n    \n    .bb-capture-preview-inner video {\n      border-radius: 8px 8px 0px 0px;\n      display: block;\n      border: 0px;\n      outline: none;\n      width: 100%;\n      max-height: 60vh;\n    }\n    \n    .bb-capture-preview-buttons {\n      display: flex;\n      justify-content: space-between;\n      padding: 14px;\n    }\n    \n    .bb-capture-preview-retrybutton {\n      font-family: sans-serif;\n      border-radius: 21px;\n      box-sizing: border-box;\n      padding: 12px 26px;\n      font-size: 16px;\n      line-height: 19px;\n      font-weight: 600;\n      text-align: center;\n      margin-top: 0px;\n      margin-bottom: 0px;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n    }\n    \n    .bb-capture-preview-sendbutton {\n      font-family: sans-serif;\n      border-radius: 21px;\n      box-sizing: border-box;\n      padding: 12px 26px;\n      font-size: 16px;\n      line-height: 19px;\n      font-weight: 600;\n      text-align: center;\n      margin-top: 0px;\n      margin-bottom: 0px;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n    }\n    \n    .bb-capture-preview-retrybutton:hover,\n    .bb-capture-preview-sendbutton:hover {\n      opacity: 0.9;\n    }\n    \n    .bb-capture-toolbar-item-recording {\n      margin-right: 0px;\n    }\n    \n    .bb-capture-toolbar-item-recording svg {\n      width: 33px;\n      height: 33px;\n    }\n    \n    .bb-capture-toolbar-item-colorpicker {\n      position: fixed;\n      top: 70px;\n      left: 50%;\n      transform: translateX(-50%);\n      z-index: ${zIndexBase + 18};\n      background-color: #fff;\n      display: none;\n      padding: 10px;\n      box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.15), 0px 0px 20px rgba(0, 0, 0, 0.1);\n      border-radius: 8px;\n    }\n    \n    .bb-capture-toolbar-item-color {\n      width: 20px;\n      height: 20px;\n      border-radius: 100%;\n      margin-right: 12px;\n      box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.15);\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n    }\n    \n    .bb-capture-toolbar-item-color:hover {\n      box-shadow: 0px 0px 6px rgba(0, 0, 0, 0.25);\n    }\n    \n    .bb-capture-toolbar-item-color:last-of-type {\n      margin-right: 0px;\n    }\n    \n    [dir=rtl].bb-capture-editor .bb-capture-toolbar-item-color {\n      margin-right: auto;\n      margin-left: 12px;\n    }\n    \n    [dir=rtl].bb-capture-editor .bb-capture-toolbar-item-color:last-of-type {\n      margin-right: auto;\n      margin-left: 0px;\n    }\n    \n    .bb-capture-toolbar-item-recording[data-active=\"true\"] svg:first-of-type {\n      display: none;\n    }\n    \n    .bb-capture-toolbar-item-recording[data-active=\"true\"] svg:nth-of-type(2) {\n      display: block;\n    }\n    \n    .bb-capture-toolbar-item-recording[data-active=\"false\"] svg:first-of-type {\n      display: block;\n    }\n    \n    .bb-capture-toolbar-item-recording[data-active=\"false\"] svg:nth-of-type(2) {\n      display: none;\n    }\n    \n    .bb-capture-toolbar-item--active {\n      background-color: #eee;\n    }\n    \n    .bb-capture-toolbar-item:hover svg {\n      opacity: 1;\n    }\n    \n    .bb-capture-toolbar-item--active {\n      background-color: #f8f8f8;\n    }\n    \n    .bb-capture-toolbar-item--active svg {\n      opacity: 1;\n    }\n    \n    .bb-capture-toolbar-item--inactivecross::before {\n      content: \"\";\n      position: absolute;\n      top: 0;\n      right: 0;\n      bottom: 0;\n      left: 0;\n      height: 3px;\n      width: 26px;\n      margin: auto;\n      border-radius: 4px;\n      background-color: #e80000;\n      transform: rotate(45deg);\n    }\n    \n    .bb-capture-toolbar-item--inactivecross svg {\n      fill: #eee;\n    }\n    \n    .bb-capture-toolbar-item-timer {\n      text-align: left;\n      line-height: 32px;\n      font-size: 14px;\n      font-family: sans-serif;\n      margin: 5px;\n      min-width: 40px;\n      display: none;\n    }\n    \n    .bb-capture-toolbar-item .bb-tooltip {\n      background-color: #555;\n      color: #fff;\n      visibility: hidden;\n      font-size: 14px;\n      font-family: sans-serif;\n      text-align: center;\n      padding: 5px 10px;\n      position: absolute;\n      z-index: 1;\n      top: 45px;\n      left: 0px;\n      transform: translateX(calc(-50% + 21px));\n      opacity: 0;\n      transition: opacity 0.3s;\n      white-space: nowrap;\n    }\n    \n    .bb-capture-toolbar-item .bb-tooltip::after {\n      content: \"\";\n      position: absolute;\n      bottom: 100%;\n      left: 50%;\n      margin-left: -5px;\n      border-width: 5px;\n      border-style: solid;\n      transform: rotate(180deg);\n      border-color: #555 transparent transparent transparent;\n    }\n    \n    .bb-capture-toolbar-item:hover .bb-tooltip {\n      visibility: visible;\n      opacity: 1;\n    }\n    \n    .bb-capture-options {\n      display: none;\n    }\n    \n    .bb-capture-options--active {\n      display: flex;\n    }\n\n    @keyframes bbFadeOutRight {\n      from {\n        opacity: 1;\n      }\n    \n      to {\n        opacity: 0;\n      }\n    }\n    \n    @keyframes bbFadeOutDown {\n      from {\n        opacity: 1;\n      }\n    \n      to {\n        opacity: 0;\n        transform: translate3d(0, 100%, 0);\n      }\n    }\n    \n    @keyframes bbFadeInOpacity {\n      from {\n        opacity: 0;\n      }\n    \n      to {\n        opacity: 1;\n      }\n    }\n    \n    @keyframes bbZoomOut {\n      from {\n        opacity: 1;\n      }\n    \n      50% {\n        opacity: 0;\n        transform: scale3d(0.3, 0.3, 0.3);\n      }\n    \n      to {\n        opacity: 0;\n      }\n    }\n    \n    @keyframes bbZoomIn {\n      from {\n        opacity: 0;\n        transform: scale3d(0.3, 0.3, 0.3);\n      }\n    \n      50% {\n        opacity: 1;\n      }\n    }\n    \n    @keyframes bbRecIconContFade {\n      0% {\n        fill: #b10802;\n      }\n      50% {\n        fill: #ff0000;\n      }\n      100% {\n        fill: #b10802;\n      }\n    }  \n    .bb-capture-preview-retrybutton {\n      color: ${contrastBackgroundColor};\n      border-radius: ${buttonBorderRadius}px;\n      background-color: ${backgroundColorHover};\n    }\n    .bb-capture-preview-retrybutton:hover {\n      background-color: ${hoverHoverColor};\n    }\n    @keyframes bb-suc-fill {\n      100% {\n        box-shadow: inset 0px 0px 0px 30px ${primaryColor};\n      }\n    }\n    .bb-capture-toolbar-item-spacer {\n      background-color: ${backgroundColorHover};\n    }\n    .bb-tooltip {\n      border-radius: ${formItemBorderRadius}px;\n    }\n    @keyframes bbRecIconFade {\n      0% {\n        fill: transparent;\n      }\n      50% {\n        fill: ${hoverHoverColor};\n      }\n      100% {\n        fill: transparent;\n      }\n    }\n    .bb-capture-preview-sendbutton {\n      color: ${contrastColor};\n      background-color: ${primaryColor};\n      border-radius: ${buttonBorderRadius}px;\n    }\n    .bb-capture-button-next {\n      color: ${contrastColor};\n      background-color: ${primaryColor};\n      border-radius: ${formItemSmallBorderRadius}px;\n    }\n    .bb-capture-preview-inner {\n      background-color: ${backgroundColor};\n      border-radius: ${formItemBorderRadius}px;\n    }\n    .bb-capture-toolbar-item-timer {\n      color: ${subTextColor};\n    }\n    .bb-svg-path {\n      fill: ${contrastBackgroundColor};\n    }\n    .bb-capture-toolbar-item {\n      border-radius: ${formItemBorderRadius}px;\n    }\n    .bb-capture-toolbar {\n      background-color: ${backgroundColor};\n      border-radius: ${formItemBorderRadius}px;\n    }\n    .bb-capture-toolbar-item-colorpicker {\n      background-color: ${backgroundColor};\n    }\n    .bb-capture-toolbar-item--active {\n      background-color: ${backgroundColorHover};\n    }\n    .bb-feedback-button-classic {\n      border-top-left-radius: ${formItemBorderRadius}px;\n      border-top-right-radius: ${formItemBorderRadius}px;\n    }\n    .bb-logo-logo--default path {\n      fill: ${contrastButtonColor};\n    }\n    .bb-logo-arrowdown {\n      fill: ${contrastButtonColor};\n    }\n    .bb-feedback-button-icon {\n        background-color: ${buttonColor};\n    }\n    .bb-feedback-button-classic {\n      background-color: ${buttonColor};\n      color: ${contrastButtonColor};\n    }\n\n    @media only screen and (max-width: 450px) {\n      [dir=rtl].gleap-frame-container,\n      .gleap-frame-container {\n        left: 0px;\n        right: 0px;\n        width: 100vw;\n        max-width: 100vw;\n        min-height: 100vh;\n        max-height: 100vh;\n        min-height: 100dvh !important;\n        max-height: 100dvh !important;\n        top: 0px;\n        bottom: 0px;\n        border-radius: 0px;\n        animation-name: gleapFadeInUpMobile;\n      }\n\n      .gleap-frame-container-inner {\n        width: 100vw;\n        height: 100%;\n      }\n\n      .gleap-frame-container:not(.gleap-frame-container--survey):not(.gleap-frame-container--survey-full) .gleap-frame-container-inner {\n        max-height: calc(var(--glvh, 1vh) * 100) !important;\n      }\n\n      .gleap-frame-container--survey {\n        height: auto !important;\n        top: initial !important;\n        bottom: 0px !important;\n        min-height: initial !important;\n      }\n\n      .gleap-frame-container--survey .gleap-frame-container-inner {\n        height: 100vh !important;\n      }\n\n      .bb-tooltip {\n        display: none !important;\n      }\n    \n      .bb-capture-toolbar-item-colorpicker {\n        top: 75px;\n      }\n    \n      .bb-capture-button-next {\n        margin-left: auto;\n      }\n    \n      .bb-capture-dismiss {\n        display: none;\n      }\n    \n      .bb-capture-toolbar {\n        top: 15px;\n        right: 15px;\n        left: 15px;\n        width: auto;\n        transform: none;\n      }\n\n      .bb-capture-editor-drag-info {\n        display: none;\n      }\n    \n      .bb-capture-editor-borderlayer {\n        border-width: 4px;\n      }\n    }\n    \n    @media print {\n      .bb-feedback-button {\n        display: none !important;\n      }\n      \n      .gleap-frame-container {\n        display: none !important;\n      }\n    }\n\n    .gleap-tour-sender {\n      display: flex;\n      align-items: center;\n      justify-content: flex-start;\n      margin-bottom: 10px;\n    }\n\n    .gleap-tour-sender-image {\n      width: 32px;\n      height: 32px;\n      border-radius: 32px;\n      margin-right: 10px;\n      background-size: cover;\n      background-repeat: no-repeat;\n    }\n\n    .gleap-tour-popover.gleap-tour-popover-post {\n      min-width: 550px;\n      max-width: 550px;\n    }\n\n    @media only screen and (max-width: 450px) {\n      .gleap-tour-popover.gleap-tour-popover-post {\n        min-width: calc(100vw - 40px);\n        max-width: calc(100vw - 40px);\n      }\n    }\n\n    .gleap-tour-message,\n    .gleap-tour-message p,\n    .gleap-tour-message ul {\n      color: ${contrastBackgroundColor};\n    }\n\n    .gleap-tour-message h2 {\n      font-weight: 600;\n      font-size: 22px;\n    }\n\n    .gleap-tour-message h3 {\n      font-weight: 600;\n      font-size: 18px;\n    }\n\n    .gleap-tour-message p {\n      line-height: 1.3;\n      margin-bottom: 10px !important;\n      margin-top: 10px !important;\n    }\n\n    .gleap-tour-message ul {\n      line-height: 1.3;\n      padding-left: 20px;\n      margin-top: 10px !important;\n      margin-bottom: 10px !important;\n    }\n\n    .gleap-tour-message {\n      max-height: calc(80vh - 100px) !important;\n      overflow-y: auto;\n      min-width: 270px;\n    }\n\n    .gleap-tour-message::-webkit-scrollbar {\n      width: 5px;\n    }\n\n    .gleap-tour-message::-webkit-scrollbar-track {\n      border-radius: 0px;\n    }\n    \n    .gleap-tour-message::-webkit-scrollbar-thumb {\n      background: ${hoverHoverColor}; \n      border-radius: 5px;\n    }\n\n    .gleap-tour-message::-webkit-scrollbar-thumb:hover {\n      background: ${subTextColor};\n    }\n\n    @media only screen and (max-width: 450px) {\n      .gleap-tour-message {\n        min-width: auto !important;\n      }\n    }\n\n    .gleap-tour-message iframe {\n      width: 100%;\n      height: 300px;\n      margin-top: 10px;\n      margin-bottom: 10px;\n      border: none;\n      outline: none;\n      display: block;\n    }\n\n    .gleap-tour-sender-name {\n      font-size: 15px;\n    }\n\n    .gleap-tour-video {\n      width: 100%;\n      max-width: 100%;\n    }\n\n    .gleap-tour-video-svg--fullscreen {\n      width: 100% !important;\n      height: 100% !important;\n      top: 0px !important;\n      left: 0px !important;\n      right: 0px !important;\n      bottom: 0px !important;\n    }\n\n    .gleap-tour-video--playing .gleap-tour-video-playpause {\n      opacity: 0;\n    }\n    \n    .gleap-tour-video--playing:hover .gleap-tour-video-playpause {\n      opacity: 1;\n    }\n\n    .gleap-tour-popover-video-pointer {\n      padding: 0px !important;\n      border-radius: 8px;\n      position: relative;\n      background-color: transparent !important;\n    }\n\n    .gleap-tour-popover-video-pointer .gleap-tour-popover-footer {\n      position: absolute;\n      top: 0px;\n      left: 20px;\n      right: 20px;\n      opacity: 0;\n      transition: opacity 200ms ease-in-out;\n    }\n\n    .gleap-tour-popover-video-pointer .gleap-tour-popover-footer button {\n      padding: 5px 12px;\n    }\n\n    .gleap-tour-popover-video-pointer.gleap-tour-popover-can-close .gleap-tour-popover-footer {\n      right: 40px !important;\n    }\n\n    .gleap-tour-popover-video-pointer:hover .gleap-tour-popover-footer {\n      opacity: 1;\n    }\n\n    .gleap-tour-popover-pointer.gleap-tour-popover-no-sender .gleap-tour-message {\n      padding-right: 20px;\n    }\n\n    .gleap-tour-video video {\n      width: 100%;\n      max-width: 100%;\n      height: auto;\n      border: none;\n      outline: none;\n      display: block;\n      border-radius: 8px;\n    }\n\n    .gleap-admin-collapse-ui {\n      z-index: ${zIndexBase + 35};\n      cursor: pointer;\n      position: fixed;\n      bottom: 75px;\n      right: 20px;\n      width: 32px;\n      height: 32px;\n      border-radius: 100%;\n      background-color: #fff;\n      display: flex;\n      justify-content: center;\n      align-items: center;\n      box-shadow: rgba(0, 0, 0, 0.16) 0px 10px 36px 0px, rgba(0, 0, 0, 0.06) 0px 0px 0px 1px;\n    }\n\n    .gleap-admin-collapse-ui svg {\n      width: 20px;\n      height: 14px;\n      fill: #000 !important;\n    }\n\n    .gleap-admin-collapse-ui-active {\n      bottom: 20px !important;\n    }\n\n    .gleap-admin-collapse-ui-active svg {\n      transform: rotate(180deg);\n    }\n\n    .gleap-admin-frame-container-active {\n      display: none !important;\n    }\n\n    .gleap-admin-frame-container {\n      position: fixed;\n      bottom: 0px;\n      left: 0px;\n      right: 0px;\n      width: 100vw;\n      z-index: ${zIndexBase + 40};\n    }\n\n    .gleap-admin-frame {\n      width: 100%;\n      height: 100% !important;\n      border: none;\n      outline: none;\n      display: block;\n    }\n    \n    .gleap-tour-message .linktype-link {\n      display: inline-block !important;\n      background-color: transparent !important;\n      color: ${buttonColor} !important;\n    }\n\n    .gleap-tooltip .linktype-button,\n    .gleap-tour-message .linktype-button {\n      display: inline-block !important;\n      border-radius: 5px;\n      box-sizing: border-box;\n      padding: 10px 20px !important;\n      text-decoration: none !important;\n      background-color: ${buttonColor} !important;\n      color: ${contrastButtonColor} !important;\n    }\n\n    .gleap-tour-message img {\n      width: 100%;\n      max-width: 100%;\n      min-height: 260px;\n      height: auto;\n      margin-top: 10px;\n      margin-bottom: 10px;\n      object-fit: cover;\n    }\n\n    .gleap-tour-active .gleap-tour-overlay {\n      pointer-events: none;\n    }\n    \n    .gleap-tour-active * {\n      pointer-events: none;\n    }\n    \n    .gleap-tour-active .gleap-tour-active-element,\n    .gleap-tour-active .gleap-tour-active-element *,\n    .gleap-tour-popover,\n    .gleap-tour-popover * {\n      pointer-events: auto;\n    }\n    \n    @keyframes animate-fade-in {\n      0% {\n        opacity: 0;\n      }\n    \n      to {\n        opacity: 1;\n      }\n    }\n    \n    .gleap-tour-fade .gleap-tour-overlay {\n      animation: animate-fade-in 200ms ease-in-out;\n    }\n    \n    .gleap-tour-fade .gleap-tour-popover {\n      animation: animate-fade-in 200ms;\n    }\n\n    .gleap-tour-video-playpause {\n      position: absolute;\n      bottom: 8px;\n      left: 8px;\n      width: 32px;\n      height: 32px;\n      padding: 4px;\n      background-color: rgba(0,0,0,0.5);\n      display: flex;\n      align-items: center;\n      justify-content: center;\n      cursor: pointer;\n      border-radius: 8px;\n      transition: opacity 200ms ease-in-out;\n    }\n\n    .gleap-tour-popover-video-pointer .gleap-tour-popover-arrow {\n      display: none !important;\n    }\n\n    .gleap-tour-video-playpause svg {\n      width: 34px;\n      height: auto;\n      fill: #fff;\n    }\n    \n    /* Popover styles */\n    .gleap-tour-popover {\n      all: unset;\n      box-sizing: border-box;\n      color: #2d2d2d;\n      margin: 0;\n      padding: 15px;\n      border-radius: ${formItemBorderRadius}px;\n      min-width: 250px;\n      max-width: 300px;\n      box-shadow: 0 1px 10px #0006;\n      z-index: 1000000000;\n      position: fixed;\n      top: 0;\n      right: 0;\n      background-color: #fff;\n    }\n    \n    .gleap-tour-popover * {\n      font-family: \"Helvetica Neue\", Inter, ui-sans-serif, \"Apple Color Emoji\", Helvetica, Arial, sans-serif;\n    }\n    \n    .gleap-tour-popover-title {\n      font: 19px / normal sans-serif;\n      font-weight: 700;\n      display: block;\n      position: relative;\n      line-height: 1.5;\n      zoom: 1;\n      margin: 0;\n    }\n    \n    .gleap-tour-popover-close-btn {\n      all: unset;\n      position: absolute;\n      top: 5px;\n      right: 5px;\n      width: 32px;\n      height: 32px;\n      cursor: pointer;\n      font-size: 30px;\n      font-weight: 500;\n      line-height: 32px;\n      color: #d2d2d2;\n      z-index: 1;\n      text-align: center;\n      transition: color;\n      transition-duration: 200ms;\n    }\n    \n    .gleap-tour-popover-close-btn:hover,\n    .gleap-tour-popover-close-btn:focus {\n      color: #2d2d2d;\n    }\n    \n    .gleap-tour-popover-title[style*=\"block\"] + .gleap-tour-popover-description {\n      margin-top: 5px;\n    }\n    \n    .gleap-tour-popover-description {\n      margin-bottom: 0;\n      font: 15px / normal sans-serif;\n      line-height: 1.5;\n      font-weight: 400;\n      zoom: 1;\n    }\n    \n    .gleap-tour-popover-footer {\n      margin-top: 15px;\n      text-align: right;\n      zoom: 1;\n      display: flex;\n      align-items: center;\n      justify-content: space-between;\n    }\n    \n    .gleap-tour-popover-progress-text {\n      font-size: 13px;\n      font-weight: 400;\n      color: #727272;\n      zoom: 1;\n    }\n    \n    .gleap-tour-popover-footer button {\n      background-color: ${primaryColor};\n      color: ${contrastColor};\n      border-radius: ${formItemSmallBorderRadius}px;\n      box-sizing: border-box;\n      padding: 10px 20px;\n      font-size: 14px;\n      font-weight: bold;\n      line-height: 21px;\n      border: none;\n      text-align: center;\n      cursor: pointer;\n      -webkit-tap-highlight-color: transparent;\n      display: flex;\n      justify-content: center;\n      align-items: center;\n      box-shadow: none !important;\n      outline: none !important;\n    }\n\n    .gleap-tour-popover-prev-btn {\n      color: ${contrastBackgroundColor} !important;\n      background-color: ${backgroundColorHover} !important;\n      margin-right: 3px;\n    }\n\n    .gleap-tour-popover-prev-btn:hover {\n      background-color: ${primaryColor}22 !important;\n      color: ${primaryColor} !important;\n    }\n    \n    .gleap-tour-popover-footer .gleap-tour-popover-btn-disabled {\n      opacity: 0.5;\n      pointer-events: none;\n    }\n    \n    .gleap-tour-no-interaction, .gleap-tour-no-interaction * {\n      pointer-events: none !important;\n    }\n    \n    .gleap-tour-popover-navigation-btns {\n      display: flex;\n      flex-grow: 1;\n      justify-content: flex-end;\n    }\n    \n    .gleap-tour-popover-navigation-btns button + button {\n      margin-left: 4px;\n    }\n    \n    .gleap-tour-popover-arrow {\n      content: \"\";\n      position: absolute;\n      border: 5px solid #fff;\n    }\n    \n    .gleap-tour-popover-arrow-side-over {\n      display: none;\n    }\n    \n    /** Popover Arrow Sides **/\n    .gleap-tour-popover-arrow-side-left {\n      left: 100%;\n      border-right-color: transparent;\n      border-bottom-color: transparent;\n      border-top-color: transparent;\n    }\n    \n    .gleap-tour-popover-arrow-side-right {\n      right: 100%;\n      border-left-color: transparent;\n      border-bottom-color: transparent;\n      border-top-color: transparent;\n    }\n    \n    .gleap-tour-popover-arrow-side-top {\n      top: 100%;\n      border-right-color: transparent;\n      border-bottom-color: transparent;\n      border-left-color: transparent;\n    }\n    \n    .gleap-tour-popover-arrow-side-bottom {\n      bottom: 100%;\n      border-left-color: transparent;\n      border-top-color: transparent;\n      border-right-color: transparent;\n    }\n    \n    .gleap-tour-popover-arrow-side-center {\n      display: none;\n    }\n    \n    /* Left/Start + Right/Start */\n    .gleap-tour-popover-arrow-side-left.gleap-tour-popover-arrow-align-start,\n    .gleap-tour-popover-arrow-side-right.gleap-tour-popover-arrow-align-start {\n      top: 15px;\n    }\n    \n    /* Top/Start + Bottom/Start */\n    .gleap-tour-popover-arrow-side-top.gleap-tour-popover-arrow-align-start,\n    .gleap-tour-popover-arrow-side-bottom.gleap-tour-popover-arrow-align-start {\n      left: 15px;\n    }\n    \n    /* End/Left + End/Right */\n    .gleap-tour-popover-arrow-align-end.gleap-tour-popover-arrow-side-left,\n    .gleap-tour-popover-arrow-align-end.gleap-tour-popover-arrow-side-right {\n      bottom: 15px;\n    }\n    \n    /* Top/End + Bottom/End */\n    .gleap-tour-popover-arrow-side-top.gleap-tour-popover-arrow-align-end,\n    .gleap-tour-popover-arrow-side-bottom.gleap-tour-popover-arrow-align-end {\n      right: 15px;\n    }\n    \n    /* Left/Center + Right/Center */\n    .gleap-tour-popover-arrow-side-left.gleap-tour-popover-arrow-align-center,\n    .gleap-tour-popover-arrow-side-right.gleap-tour-popover-arrow-align-center {\n      top: 50%;\n      margin-top: -5px;\n    }\n    \n    /* Top/Center + Bottom/Center */\n    .gleap-tour-popover-arrow-side-top.gleap-tour-popover-arrow-align-center,\n    .gleap-tour-popover-arrow-side-bottom.gleap-tour-popover-arrow-align-center {\n      left: 50%;\n      margin-left: -5px;\n    }\n    \n    /* No arrow */\n    .gleap-tour-popover-arrow-none {\n      display: none;\n    }    \n\n    /* Modal styles */\n    .gleap-modal-wrapper {\n      position: fixed;\n      top: 0;\n      left: 0;\n      width: 100%;\n      height: 100%;\n      z-index: ${zIndexBase + 40};\n      display: flex;\n      align-items: center;\n      justify-content: center;\n    }\n\n    .gleap-modal-backdrop {\n      position: absolute;\n      top: 0;\n      left: 0;\n      width: 100%;\n      height: 100%;\n      background-color: rgba(0, 0, 0, 0.5);\n      z-index: ${zIndexBase + 41};\n    }\n\n    .gleap-modal {\n      position: relative;\n      width: 90%;\n      max-width: 600px;\n      max-height: 90vh;\n      z-index: ${zIndexBase + 100};\n      background-color: ${backgroundColor};\n      border-radius: ${containerRadius}px;\n      overflow: hidden;\n      box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);\n      animation-duration: 0.3s;\n      animation-fill-mode: both;\n      animation-name: gleapFadeInUp;\n    }\n\n    .gleap-modal-frame {\n      width: 100%;\n      border: none;\n      display: block;\n      outline: none;\n    }\n\n    body.gleap-modal-open {\n      overflow: hidden;\n    }\n\n    /* Agent Popup styles */\n    .gleap-agent-popup-wrapper {\n      position: fixed;\n      top: 0;\n      left: 0;\n      width: 100%;\n      height: 100%;\n      z-index: ${zIndexBase + 40};\n      display: flex;\n      align-items: center;\n      justify-content: center;\n    }\n\n    .gleap-agent-popup-backdrop {\n      position: absolute;\n      top: 0;\n      left: 0;\n      width: 100%;\n      height: 100%;\n      background-color: rgba(0, 0, 0, 0.5);\n      z-index: ${zIndexBase + 41};\n    }\n\n    .gleap-agent-popup {\n      position: relative;\n      width: 95%;\n      max-width: 700px;\n      height: 85vh;\n      max-height: 800px;\n      z-index: ${zIndexBase + 100};\n      background-color: ${backgroundColor};\n      border-radius: ${containerRadius}px;\n      overflow: hidden;\n      box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);\n      animation-duration: 0.3s;\n      animation-fill-mode: both;\n      animation-name: gleapFadeInUp;\n    }\n\n    .gleap-agent-popup-frame {\n      width: 100%;\n      height: 100%;\n      border: none;\n      display: block;\n      outline: none;\n    }\n\n    body.gleap-agent-popup-open {\n      overflow: hidden;\n    }\n\n    @keyframes gleapFadeInUp {\n      from {\n        opacity: 0;\n        transform: translate3d(0, 20px, 0);\n      }\n      to {\n        opacity: 1;\n        transform: translate3d(0, 0, 0);\n      }\n    }\n\n    .gleap-admin-frame-container,\n    .gleap-frame-container,\n    .bb-feedback-button,\n    .gleap-notification-container,\n    .gleap-tooltip,\n    .gleap-ai-ui-widget {\n      pointer-events: auto !important;\n    }\n    `;\n\n  const oldNode = document.querySelector('.gleap-styles');\n  if (oldNode) {\n    oldNode.remove();\n  }\n  const node = document.createElement('style');\n  node.innerHTML = colorStyleSheet;\n  node.className = 'gleap-styles';\n  document.body.appendChild(node);\n};\n\nexport const loadIcon = function (name, color) {\n  if (name === 'button') {\n    return `<svg class=\"bb-logo-logo bb-logo-logo--default\" width=\"145\" height=\"144\" viewBox=\"0 0 145 144\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n    <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M38.9534 15H105.047C113.857 15 121 22.1426 121 30.9534L121 89.5238L121 96.015L121 125.541C121 128.759 117.393 130.66 114.739 128.84L90.1188 111.968H38.9534C30.1426 111.968 23 104.826 23 96.015V30.9534C23 22.1426 30.1426 15 38.9534 15Z\" fill=\"white\"/>\n    </svg>`;\n  }\n\n  if (name === 'drag') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 256 512\"><!--!Font Awesome Pro 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2025 Fonticons, Inc.--><path d=\"M64 128a32 32 0 1 0 0-64 32 32 0 1 0 0 64zm0 160a32 32 0 1 0 0-64 32 32 0 1 0 0 64zM96 416a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zm96-288a32 32 0 1 0 0-64 32 32 0 1 0 0 64zm32 128a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zM192 448a32 32 0 1 0 0-64 32 32 0 1 0 0 64z\"/></svg>`;\n  }\n\n  if (name === 'unmute') {\n    return `<svg id=\"tooltip-svg-unmute\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 640 512\"><path id=\"tooltip-svg-unmute-path\" d=\"M38.8 5.1C28.4-3.1 13.3-1.2 5.1 9.2S-1.2 34.7 9.2 42.9l592 464c10.4 8.2 25.5 6.3 33.7-4.1s6.3-25.5-4.1-33.7L525.1 386.2C556.7 352 576 306.3 576 256c0-60.1-27.7-113.8-70.9-149c-10.3-8.4-25.4-6.8-33.8 3.5s-6.8 25.4 3.5 33.8C507.3 170.7 528 210.9 528 256c0 39.1-15.6 74.5-40.9 100.5L449 326.6c19-17.5 31-42.7 31-70.6c0-30.1-13.9-56.9-35.4-74.5c-10.3-8.4-25.4-6.8-33.8 3.5s-6.8 25.4 3.5 33.8C425.1 227.6 432 241 432 256s-6.9 28.4-17.7 37.3c-1.3 1-2.4 2.2-3.4 3.4L352 250.6V64c0-12.6-7.4-24-18.9-29.2s-25-3.1-34.4 5.3L197.8 129.8 38.8 5.1zM352 373.3L82.9 161.3C53.8 167.4 32 193.1 32 224v64c0 35.3 28.7 64 64 64h67.8L298.7 471.9c9.4 8.4 22.9 10.4 34.4 5.3S352 460.6 352 448V373.3z\"/></svg>`;\n  }\n\n  if (name === 'mute') {\n    return `<svg id=\"tooltip-svg-mute\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 640 512\"><path id=\"tooltip-svg-mute-path\" d=\"M533.6 32.5C598.5 85.3 640 165.8 640 256s-41.5 170.8-106.4 223.5c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C557.5 398.2 592 331.2 592 256s-34.5-142.2-88.7-186.3c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zM473.1 107c43.2 35.2 70.9 88.9 70.9 149s-27.7 113.8-70.9 149c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C475.3 341.3 496 301.1 496 256s-20.7-85.3-53.2-111.8c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zm-60.5 74.5C434.1 199.1 448 225.9 448 256s-13.9 56.9-35.4 74.5c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C393.1 284.4 400 271 400 256s-6.9-28.4-17.7-37.3c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zM301.1 34.8C312.6 40 320 51.4 320 64V448c0 12.6-7.4 24-18.9 29.2s-25 3.1-34.4-5.3L131.8 352H64c-35.3 0-64-28.7-64-64V224c0-35.3 28.7-64 64-64h67.8L266.7 40.1c9.4-8.4 22.9-10.4 34.4-5.3z\"/></svg>`;\n  }\n\n  if (name === 'replay') {\n    return `<svg id=\"tooltip-svg-replay\" width=\"512\" height=\"512\" viewBox=\"0 0 512 512\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n    <path id=\"tooltip-svg-replay-path\" d=\"M48.5 224H40C26.7 224 16 213.3 16 200V72C16 62.3 21.8 53.5 30.8 49.8C39.8 46.1 50.1 48.1 57 55L98.6 96.6C186.2 10.1 327.3 10.4 414.4 97.6C501.9 185.1 501.9 326.9 414.4 414.4C326.9 501.9 185.1 501.9 97.6 414.4C85.1 401.9 85.1 381.6 97.6 369.1C110.1 356.6 130.4 356.6 142.9 369.1C205.4 431.6 306.7 431.6 369.2 369.1C431.7 306.6 431.7 205.3 369.2 142.8C307 80.6 206.5 80.3 143.9 141.8L185 183C191.9 189.9 193.9 200.2 190.2 209.2C186.5 218.2 177.7 224 168 224H48.5Z\" />\n    </svg>`;\n  }\n\n  if (name === 'dismiss') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 320 512\"><path d=\"M294.6 166.6L317.3 144 272 98.7l-22.6 22.6L160 210.7 70.6 121.4 48 98.7 2.7 144l22.6 22.6L114.7 256 25.4 345.4 2.7 368 48 413.3l22.6-22.6L160 301.3l89.4 89.4L272 413.3 317.3 368l-22.6-22.6L205.3 256l89.4-89.4z\"/></svg>`;\n  }\n\n  if (name === 'blur') {\n    return `<svg width=\"1200pt\" height=\"1200pt\" version=\"1.1\" viewBox=\"0 0 1200 1200\" xmlns=\"http://www.w3.org/2000/svg\">\n <path class=\"bb-svg-path\" d=\"m602.25 1200c238.2 0 435.95-193.26 435.95-435.95 0-269.66-220.23-615.73-435.95-764.05-220.23 161.8-440.45 485.39-440.45 764.05 0 242.7 197.75 435.95 440.45 435.95zm-260.68-382.02c0 112.36 89.887 206.74 206.74 206.74v62.922c-148.32 0-274.16-121.35-274.16-269.66z\" fill=\"#333\"/>\n</svg>`;\n  }\n\n  if (name === 'pen') {\n    return `<svg width=\"1072px\" height=\"1034px\" viewBox=\"0 0 1072 1034\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n    <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n        <g transform=\"translate(-907.000000, -217.000000)\" fill-rule=\"nonzero\">\n            <g transform=\"translate(907.268457, 217.009827)\">\n                <g transform=\"translate(132.335119, 0.000000)\" fill=\"#000\" class=\"bb-svg-path\">\n                    <path d=\"M20.3764235,730.530173 L10.1884235,720.342173 C-0.791576454,709.362173 -3.16357645,692.432173 4.37592355,678.858173 L83.1809235,537.018173 C71.7589235,502.979173 82.3098335,463.998173 112.254924,440.706173 L655.334924,18.3161733 C689.951924,-8.6058267 739.197924,-5.5388267 770.214924,25.4684733 L913.774924,169.028473 C944.782924,200.040473 947.848924,249.286473 920.927224,283.908473 L498.537224,826.988473 C496.322424,829.836173 493.935624,832.543173 491.384924,835.090073 C467.271924,859.207073 432.513924,866.195073 402.232924,856.063073 L260.382924,934.868073 C246.804924,942.407173 229.874924,940.036073 218.894924,929.055573 L208.706924,918.867573 L20.3764235,730.530173 Z M866.006424,241.190173 C871.393124,234.264373 870.779824,224.417173 864.576724,218.213173 L721.016724,74.6531733 C714.813624,68.4500733 704.965724,67.8367733 698.043724,73.2234733 L154.963724,495.613473 C147.381724,501.507973 146.018424,512.433473 151.912924,520.015473 C152.358234,520.585783 152.834804,521.128773 153.346524,521.636573 L417.586524,785.886573 C424.379524,792.675673 435.391524,792.675673 442.180524,785.886573 C442.692244,785.374853 443.168804,784.831873 443.610224,784.265473 L866.006424,241.190173 Z M342.796424,809.480173 L129.746424,596.430173 L77.9264235,689.707173 L249.516424,861.297173 L342.796424,809.480173 Z\"></path>\n                </g>\n                <g transform=\"translate(-0.000000, 755.530173)\" fill=\"#EB144C\">\n                    <path d=\"M124.711543,0 L313.042043,188.3374 L233.288043,268.0914 C222.003043,279.3764 204.483043,281.5324 190.800043,273.3219 L16.8900429,168.9719 C-2.51595711,157.3309 -5.80895711,130.5499 10.1908429,114.5499 L124.711543,0 Z\" class=\"bb-pen-tip\"></path>\n                </g>\n            </g>\n        </g>\n    </g>\n</svg>`;\n  }\n\n  if (name === 'rect') {\n    return `<svg width=\"339px\" height=\"241px\" viewBox=\"0 0 339 241\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n    <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n        <g transform=\"translate(-0.000865, 0.000000)\" fill-rule=\"nonzero\">\n            <g transform=\"translate(0.000865, 0.000000)\" fill=\"#000000\" class=\"bb-svg-path\">\n                <path d=\"M339,0 L339,241 L0,241 L0,0 L339,0 Z M312.826351,26.168387 L26.1855674,26.168387 L26.1855674,214.41156 L312.826351,214.41156 L312.826351,26.168387 Z\"></path>\n            </g>\n            <g transform=\"translate(0.000000, 83.206095)\" fill=\"#EB144C\" class=\"bb-pen-tip\">\n                <path d=\"M0,0 L26.186,26.186 L26.1864325,131.205465 L131.204,131.205 L157.792,157.793 L0.000865118243,157.793905 L0,0 Z\"></path>\n            </g>\n        </g>\n    </g>\n</svg>`;\n  }\n\n  if (name === 'pointer') {\n    return `<svg width=\"1200pt\" height=\"1200pt\" version=\"1.1\" viewBox=\"0 0 1200 1200\" xmlns=\"http://www.w3.org/2000/svg\">\n    <path d=\"m1050.7 508.95-225.94 157.5 160.31 160.31c4.4531 4.4531 6.9141 10.43 6.9141 16.758s-2.4609 12.305-6.9141 16.758l-126.09 126.09c-4.4531 4.4531-10.43 6.9141-16.758 6.9141-6.3281 0-12.188-2.4609-16.758-6.9141l-160.2-160.43-157.62 225.94c-3.3984 4.9219-9.0234 7.8516-14.883 7.8516-0.70313 0-1.5234 0-2.2266-0.11719-6.7969-0.82031-12.422-5.2734-14.766-11.719l-333.16-880.55c-2.5781-6.6797-0.9375-14.297 4.2188-19.336 5.0391-5.0391 12.656-6.6797 19.336-4.2188l880.66 333.05c6.3281 2.3438 10.781 8.0859 11.602 14.766 0.82031 6.7969-2.1094 13.359-7.7344 17.344z\" fill=\"#333\"/>\n   </svg>`;\n  }\n\n  if (name === 'clip') {\n    return `<svg width=\"600px\" height=\"1126px\" viewBox=\"0 0 600 1126\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n    <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n        <g transform=\"translate(-0.002000, 0.501000)\" fill=\"#333333\" fill-rule=\"nonzero\">\n            <path d=\"M225.002,1124.999 C165.33,1124.999 108.102,1101.292 65.902,1059.097 C23.707,1016.902 5.68434189e-14,959.671 5.68434189e-14,899.997 L5.68434189e-14,299.997 C5.68434189e-14,220.431 31.605,144.127 87.867,87.867 C144.129,31.605 220.437,-4.26325641e-14 299.997,-4.26325641e-14 C379.557,-4.26325641e-14 455.867,31.605 512.127,87.867 C568.389,144.129 599.994,220.437 599.994,299.997 L599.994,1012.497 C599.994,1025.895 592.8456,1038.274 581.244,1044.974 C569.642,1051.6732 555.346,1051.6732 543.744,1044.974 C532.142,1038.2748 524.994,1025.896 524.994,1012.497 L524.994,299.997 C524.994,240.325 501.287,183.097 459.092,140.897 C416.897,98.702 359.666,74.995 299.992,74.995 C240.318,74.995 183.092,98.702 140.892,140.897 C98.697,183.092 74.99,240.323 74.99,299.997 L74.99,899.997 C74.99,953.587 103.58,1003.107 149.99,1029.897 C196.4,1056.694 253.58,1056.694 299.99,1029.897 C346.4,1003.104 374.99,953.585 374.99,899.997 L374.99,337.497 C374.99,310.704 360.697,285.942 337.49,272.544 C314.283,259.149 285.697,259.149 262.49,272.544 C239.283,285.942 224.99,310.704 224.99,337.497 L224.99,824.997 C224.99,838.395 217.8416,850.774 206.24,857.474 C194.638,864.1732 180.342,864.1732 168.74,857.474 C157.138,850.7748 149.99,838.396 149.99,824.997 L149.99,337.497 C149.99,283.907 178.58,234.387 224.99,207.597 C271.4,180.8 328.58,180.8 374.99,207.597 C421.4,234.39 449.99,283.909 449.99,337.497 L449.99,899.997 C449.99,959.669 426.283,1016.897 384.088,1059.097 C341.893,1101.292 284.662,1124.999 224.988,1124.999 L225.002,1124.999 Z\" id=\"Path\"></path>\n        </g>\n    </g>\n</svg>`;\n  }\n\n  if (name === 'mic') {\n    return `<svg\n    width=\"1200pt\"\n    height=\"1200pt\"\n    version=\"1.1\"\n    viewBox=\"0 0 1200 1200\"\n    xmlns=\"http://www.w3.org/2000/svg\"\n  >\n    <g class=\"bb-svg-path\">\n      <path\n        d=\"m600 862.5c144.75 0 262.5-117.75 262.5-262.5v-300c0-144.75-117.75-262.5-262.5-262.5s-262.5 117.75-262.5 262.5v300c0 144.75 117.75 262.5 262.5 262.5z\"\n      />\n      <path\n        d=\"m1012.5 600c0-20.707-16.793-37.5-37.5-37.5s-37.5 16.793-37.5 37.5c0 186.11-151.41 337.5-337.5 337.5s-337.5-151.39-337.5-337.5c0-20.707-16.793-37.5-37.5-37.5s-37.5 16.793-37.5 37.5c0 214.8 165.08 391.57 375 410.6v114.4c0 20.727 16.793 37.5 37.5 37.5s37.5-16.773 37.5-37.5v-114.4c209.92-19.031 375-195.8 375-410.6z\"\n      />\n    </g>\n  </svg>`;\n  }\n\n  if (name === 'camera') {\n    return `<svg width=\"1155px\" height=\"1004px\" viewBox=\"0 0 1155 1004\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n    <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n        <g fill=\"#333333\" fill-rule=\"nonzero\">\n            <g transform=\"translate(128.324095, 0.000000)\">\n                <path d=\"M42.7803063,0.00413459787 C31.4357421,0.00413459787 20.5549853,4.41399115 12.5336107,12.2572687 C4.51223664,20.1005462 0.00420584816,30.741831 0.00420584816,41.8370305 L0.00420584816,251.00151 C-0.156199045,262.200455 4.27736739,272.989996 12.315738,280.963903 C20.3585574,288.938257 31.3288589,293.431222 42.7803063,293.431222 C54.2317532,293.431222 65.2018267,288.938592 73.2448746,280.963903 C81.2832452,272.989549 85.7172445,262.200455 85.5564062,251.00151 L85.5564062,83.6699265 L256.660808,83.6699265 C268.112255,83.8267939 279.145066,79.4909873 287.298762,71.6298611 C295.452913,63.7643845 300.04718,53.0359758 300.04718,41.8370305 C300.04718,30.6380854 295.453255,19.9098998 287.298762,12.0441998 C279.144611,4.18307356 268.112255,-0.153157091 256.660808,0.00413459787 L42.7803063,0.00413459787 Z\"></path>\n                <path d=\"M983.227131,710.59444 C971.895913,710.764382 961.099907,715.326799 953.20401,723.279287 C945.312674,731.227538 940.964345,741.91668 941.119476,752.99849 L941.119476,920.330075 L770.015075,920.330075 C758.563631,920.173205 747.530815,924.509015 739.377123,932.370139 C731.222968,940.235615 726.628705,950.964028 726.628705,962.16297 C726.628705,973.361918 731.222627,984.090105 739.377123,991.955802 C747.531272,999.816926 758.563631,1004.15316 770.015075,1003.99587 L983.895579,1003.99587 C995.24014,1003.99587 1006.1209,999.586011 1014.14227,991.742733 C1022.16365,983.899455 1026.67168,973.258169 1026.67168,962.16297 L1026.67168,752.99849 C1026.83208,741.690223 1022.30053,730.801401 1014.11489,722.812989 C1005.93394,714.825472 994.790363,710.415949 983.227131,710.59444 L983.227131,710.59444 Z\"></path>\n                <path d=\"M983.227131,375.93127 C971.895913,376.101212 961.099907,380.66363 953.20401,388.61612 C945.312674,396.56437 940.964345,407.253512 941.119476,418.335325 L941.119476,585.66691 C940.959072,596.865853 945.39264,607.655394 953.431008,615.629303 C961.47383,623.603658 972.444131,628.096618 983.895579,628.096618 C995.347023,628.096618 1006.3171,623.603989 1014.36015,615.629303 C1022.39852,607.654947 1026.83251,596.865853 1026.67168,585.66691 L1026.67168,418.335325 C1026.83208,407.027056 1022.30053,396.138232 1014.11489,388.149822 C1005.93394,380.162305 994.790363,375.752783 983.227131,375.93127 L983.227131,375.93127 Z\"></path>\n                <path d=\"M769.974012,0.00413459787 C758.522563,-0.152733184 747.489752,4.18307356 739.336055,12.0441998 C731.181906,19.9096767 726.587637,30.6380854 726.587637,41.8370305 C726.587637,53.0359758 731.181564,63.7641611 739.336055,71.6298611 C747.490209,79.4909873 758.522563,83.8272181 769.974012,83.6699265 L941.078414,83.6699265 L941.078414,251.00151 C940.918009,262.200455 945.351572,272.989996 953.389945,280.963903 C961.432763,288.938257 972.403063,293.431222 983.854512,293.431222 C995.30596,293.431222 1006.27603,288.938592 1014.31908,280.963903 C1022.35745,272.989549 1026.79145,262.200455 1026.63061,251.00151 L1026.63061,41.8370305 C1026.63061,30.7426118 1022.12133,20.1017733 1014.10121,12.2572687 C1006.08109,4.41276405 995.199876,0.00413459787 983.854512,0.00413459787 L769.974012,0.00413459787 Z\"></path>\n                <path d=\"M427.765208,0.00413459787 C416.31376,-0.152733184 405.280949,4.18307356 397.127256,12.0441998 C388.973102,19.9096767 384.378838,30.6380854 384.378838,41.8370305 C384.378838,53.0359758 388.972761,63.7641611 397.127256,71.6298611 C405.281406,79.4909873 416.31376,83.8272181 427.765208,83.6699265 L598.86961,83.6699265 C610.321058,83.8267939 621.35387,79.4909873 629.507562,71.6298611 C637.661716,63.7643845 642.255985,53.0359758 642.255985,41.8370305 C642.255985,30.6380854 637.662058,19.9098998 629.507562,12.0441998 C621.353413,4.18307356 610.321058,-0.153157091 598.86961,0.00413459787 L427.765208,0.00413459787 Z\"></path>\n            </g>\n            <g transform=\"translate(0.000000, 427.000000)\">\n                <path d=\"M768.516184,22.1826583 C752.659627,13.73125 732.573775,13.73125 717.773442,24.29375 L562.379192,124.6375 L562.379192,31.6875 C562.379192,13.7330104 548.635081,0 530.666079,0 L31.7131123,0 C13.7441105,0 0,13.7330104 0,31.6875 L0,475.3125 C0,493.26699 13.7441105,507 31.7131123,507 L530.666079,507 C548.635081,507 562.379192,493.26699 562.379192,475.3125 L562.379192,382.3625 L717.773442,482.70625 C726.231681,487.9875 735.742444,491.157658 745.257258,491.157658 C753.715498,491.157658 761.113815,489.046567 769.572406,484.820862 C786.485185,475.313732 796,458.414612 796,439.400352 L796,68.6566021 C794.943601,48.5869719 785.428963,31.6878521 768.516184,22.1807219 L768.516184,22.1826583 Z\"></path>\n            </g>\n        </g>\n    </g>\n</svg>`;\n  }\n\n  if (name === 'recorderon') {\n    return `<svg width=\"1251px\" height=\"1251px\" viewBox=\"0 0 1251 1251\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n    <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n        <g>\n            <circle fill=\"#E31810\" cx=\"625.5\" cy=\"625.5\" r=\"625.5\"></circle>\n            <circle fill=\"#F71008\" cx=\"625\" cy=\"625\" r=\"507\"></circle>\n            <g transform=\"translate(175.000000, 449.000000)\" fill=\"#FFFFFF\" fill-rule=\"nonzero\">\n                <path d=\"M0,347.097493 L0,4.90250696 L135.528311,4.90250696 C161.471024,4.90250696 183.639743,9.49741034 202.034469,18.6872171 C220.429194,27.8770239 234.46286,40.8541449 244.135466,57.6185803 C253.808072,74.3830156 258.644376,94.0714804 258.644376,116.683975 C258.644376,139.40786 253.724206,158.929238 243.883867,175.248107 C234.043527,191.566976 219.814173,204.070682 201.195803,212.759227 C182.577434,221.447772 160.073248,225.792044 133.683247,225.792044 L42.9396629,225.792044 L42.9396629,167.64563 L121.941933,167.64563 C135.807866,167.64563 147.325536,165.751973 156.494943,161.964659 C165.66435,158.177344 172.51345,152.496373 177.042243,144.921744 C181.571035,137.347116 183.835432,127.934526 183.835432,116.683975 C183.835432,105.322032 181.571035,95.7423543 177.042243,87.9449425 C172.51345,80.1475308 165.636395,74.2159282 156.411077,70.1501349 C147.185759,66.0843416 135.584222,64.051445 121.606467,64.051445 L72.6284142,64.051445 L72.6284142,347.097493 L0,347.097493 Z M185.512762,191.37204 L270.888889,347.097493 L190.712487,347.097493 L107.181424,191.37204 L185.512762,191.37204 Z\"></path>\n                <polygon points=\"309.166667 347.097493 309.166667 4.90250696 540.126846 4.90250696 540.126846 64.5527072 381.634607 64.5527072 381.634607 146.091356 528.244113 146.091356 528.244113 205.741556 381.634607 205.741556 381.634607 287.447293 540.796296 287.447293 540.796296 347.097493\"></polygon>\n                <path d=\"M901,124.638783 L827.757943,124.638783 C826.420189,115.158428 823.68894,106.709759 819.564197,99.2927757 C815.439454,91.8757921 810.144176,85.5462611 803.678363,80.3041825 C797.212549,75.0621039 789.77129,71.0468948 781.354585,68.2585551 C772.93788,65.4702155 763.824427,64.0760456 754.014228,64.0760456 C736.288981,64.0760456 720.849065,68.4537389 707.69448,77.2091255 C694.539894,85.964512 684.339516,98.6793409 677.093346,115.353612 C669.847176,132.027883 666.224091,152.243346 666.224091,176 C666.224091,200.425856 669.875046,220.948035 677.176956,237.56654 C684.478866,254.185044 694.707113,266.732573 707.861699,275.209125 C721.016285,283.685678 736.233242,287.923954 753.51257,287.923954 C763.21129,287.923954 772.213263,286.641318 780.518488,284.076046 C788.823714,281.510773 796.209233,277.746515 802.675047,272.78327 C809.14086,267.820025 814.519748,261.769328 818.81171,254.631179 C823.103672,247.493029 826.08575,239.351077 827.757943,230.205323 L901,230.539924 C899.104848,246.26616 894.394837,261.406844 886.869968,275.961977 C879.3451,290.51711 869.256201,303.510773 856.603274,314.942966 C843.950346,326.375158 828.900608,335.409379 811.45406,342.045627 C794.007513,348.681876 774.303504,352 752.342035,352 C721.796641,352 694.512024,345.084918 670.488184,331.254753 C646.464343,317.424588 627.512821,297.404309 613.633619,271.193916 C599.754416,244.983523 592.814815,213.252218 592.814815,176 C592.814815,138.636248 599.838026,106.849176 613.884448,80.6387833 C627.93087,54.4283904 646.993871,34.4359949 671.073451,20.661597 C695.153031,6.88719899 722.242559,0 752.342035,0 C772.185393,0 790.607387,2.78833967 807.608016,8.36501901 C824.608646,13.9416984 839.686254,22.0557668 852.840839,32.7072243 C865.995425,43.3586819 876.72533,56.3802281 885.030556,71.7718631 C893.335782,87.1634981 898.65893,104.785805 901,124.638783 Z\"></path>\n            </g>\n        </g>\n    </g>\n</svg>`;\n  }\n\n  if (name === 'recorderoff') {\n    return `<svg width=\"1251px\" height=\"1251px\" viewBox=\"0 0 1251 1251\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n      <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n          <g class=\"bb-rec-on-circle\" fill=\"#EEEEEE\" fill-rule=\"nonzero\">\n              <path d=\"M625.5,0 C970.954111,0 1251,280.045889 1251,625.5 C1251,970.954111 970.954111,1251 625.5,1251 C280.045889,1251 0,970.954111 0,625.5 C0,280.045889 280.045889,0 625.5,0 Z M626,124 C348.753056,124 124,348.753056 124,626 C124,903.246944 348.753056,1128 626,1128 C903.246944,1128 1128,903.246944 1128,626 C1128,348.753056 903.246944,124 626,124 Z\"></path>\n          </g>\n          <g class=\"bb-rec-on-cont\" fill=\"#E31810\" transform=\"translate(86.000000, 86.000000)\" fill-rule=\"nonzero\">\n              <path d=\"M540,0 C241.2,0 0,241.2 0,540 C0,838.8 241.2,1080 540,1080 C838.8,1080 1080,838.8 1080,540 C1080,241.2 838.8,0 540,0 Z M777.6,741.6 C777.6,761.998 761.998,777.6 741.6,777.6 L338.4,777.6 C318.002,777.6 302.4,761.998 302.4,741.6 L302.4,338.4 C302.4,318.002 318.002,302.4 338.4,302.4 L741.6,302.4 C761.998,302.4 777.6,318.002 777.6,338.4 L777.6,741.6 Z\"></path>\n          </g>\n      </g>\n  </svg>`;\n  }\n\n  if (name === 'arrowdown') {\n    return `<svg class=\"bb-logo-arrowdown\" fill=\"${color}\" width=\"100pt\" height=\"100pt\" version=\"1.1\" viewBox=\"0 0 100 100\" xmlns=\"http://www.w3.org/2000/svg\">\n    <path d=\"m50 77.637c-1.3477 0-2.6953-0.51562-3.7266-1.543l-44.73-44.73c-2.0586-2.0586-2.0586-5.3945 0-7.4531 2.0586-2.0586 5.3945-2.0586 7.4531 0l41.004 41 41.004-41c2.0586-2.0586 5.3945-2.0586 7.4531 0 2.0586 2.0586 2.0586 5.3945 0 7.4531l-44.73 44.727c-1.0312 1.0312-2.3789 1.5469-3.7266 1.5469z\"/>\n   </svg>`;\n  }\n\n  if (name === 'arrowleft') {\n    return `<svg fill=\"${color}\" width=\"100pt\" height=\"100pt\" version=\"1.1\" viewBox=\"0 0 100 100\" xmlns=\"http://www.w3.org/2000/svg\">\n    <path d=\"m70.988 1.6211c2.1875-2.168 5.7344-2.168 7.9297 0 2.1836 2.168 2.1836 5.7227 0 7.8906l-46.016 40.445 46.016 40.5c2.1836 2.168 2.1836 5.668 0 7.8906-2.1953 2.168-5.7383 2.168-7.9297 0l-50.039-44.109c-1.168-1.168-1.668-2.7227-1.5898-4.2773-0.078125-1.5 0.42188-3.0547 1.5898-4.2227l50.039-44.109z\" fill-rule=\"evenodd\"/>\n   </svg>`;\n  }\n\n  if (name === 'close') {\n    return `<svg fill=\"${color}\" width=\"100pt\" height=\"100pt\" version=\"1.1\" viewBox=\"0 0 100 100\" xmlns=\"http://www.w3.org/2000/svg\">\n    <path d=\"m72.812 33.02l-5.832-5.832-16.98 16.875-16.98-16.875-5.832 5.832 16.875 16.98-16.875 16.98 5.832 5.832 16.98-16.875 16.98 16.875 5.832-5.832-16.875-16.98z\"/>\n   </svg>`;\n  }\n\n  if (name === 'undo') {\n    return `<svg width=\"62px\" height=\"60px\" viewBox=\"0 0 62 60\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n    <g stroke=\"none\" stroke-width=\"1\" fill=\"none\" fill-rule=\"evenodd\">\n      <g class=\"bb-svg-path\" transform=\"translate(-0.000500, 0.001926)\" fill-rule=\"nonzero\">\n        <path d=\"M28.0005,51.6270739 C24.9653,51.0684839 22.0825,49.8731739 19.5396,48.1192739 L13.8208,53.8380739 C17.9536,57.0060739 22.8403,59.0333739 28.0008,59.7286739 L28.0005,51.6270739 Z\" id=\"Path\"></path>\n        <path d=\"M2.2705,33.9980739 C2.96581,39.1582739 4.9932,44.0450739 8.1611,48.1780739 L13.8799,42.4592739 C12.126,39.9162739 10.9307,37.0334739 10.3721,33.9983739 L2.2705,33.9980739 Z\" id=\"Path\"></path>\n        <path d=\"M61.7305,33.9980739 L53.6289,33.9980739 C53.07031,37.0332739 51.875,39.9160739 50.1211,42.4589739 L55.8399,48.1777739 C59.0079,44.0449739 61.0352,39.1582739 61.7305,33.9977739 L61.7305,33.9980739 Z\" id=\"Path\"></path>\n        <path d=\"M4.0005,24.9980739 L24.0005,24.9980739 L24.0005,16.9980739 L14.27,16.9980739 C17.6762,12.3613739 22.7622,9.24417393 28.442,8.31057393 C34.1178,7.38088393 39.934,8.70901393 44.645,12.0175739 C49.352,15.3222739 52.5786,20.3417739 53.6294,25.9975739 L61.731,25.9975739 C60.6646,18.0834739 56.4888,10.9235739 50.129,6.09957393 C43.7657,1.27147393 35.746,-0.818426068 27.836,0.290973932 C19.9298,1.39647393 12.793,5.61127393 8,11.9979739 L8,0.997973932 L-3.55271368e-15,0.997973932 L-3.55271368e-15,20.9979739 C-3.55271368e-15,22.0604739 0.42188,23.0760739 1.1719,23.8260739 C1.92192,24.5760739 2.9375,24.9979739 4,24.9979739 L4.0005,24.9980739 Z\" id=\"Path\"></path>\n        <path d=\"M36.0005,51.6270739 L36.0005,59.7286739 C41.1607,59.0333639 46.0475,57.0059739 50.1805,53.8380739 L44.4617,48.1192739 C41.9187,49.8731739 39.0359,51.0684739 36.0008,51.6270739 L36.0005,51.6270739 Z\" id=\"Path\"></path>\n      </g>\n    </g>\n  </svg>`;\n  }\n\n  if (name === 'circle-dot') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"${color}\" d=\"M464 256A208 208 0 1 0 48 256a208 208 0 1 0 416 0zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zm256-96a96 96 0 1 1 0 192 96 96 0 1 1 0-192z\"/></svg>`;\n  }\n\n  if (name === 'circle-question') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"${color}\" d=\"M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM169.8 165.3c7.9-22.3 29.1-37.3 52.8-37.3h58.3c34.9 0 63.1 28.3 63.1 63.1c0 22.6-12.1 43.5-31.7 54.8L280 264.4c-.2 13-10.9 23.6-24 23.6c-13.3 0-24-10.7-24-24V250.5c0-8.6 4.6-16.5 12.1-20.8l44.3-25.4c4.7-2.7 7.6-7.7 7.6-13.1c0-8.4-6.8-15.1-15.1-15.1H222.6c-3.4 0-6.4 2.1-7.5 5.3l-.4 1.2c-4.4 12.5-18.2 19-30.6 14.6s-19-18.2-14.6-30.6l.4-1.2zM224 352a32 32 0 1 1 64 0 32 32 0 1 1 -64 0z\"/></svg>`;\n  }\n\n  if (name === 'circle-info') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"${color}\" d=\"M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM216 336h24V272H216 192V224h24 48 24v24 88h8 24v48H296 216 192V336h24zm72-144H224V128h64v64z\"/></svg>`;\n  }\n\n  if (name === 'circle-exclamation') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"${color}\" d=\"M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm24-384v24V264v24H232V264 152 128h48zM232 368V320h48v48H232z\"/></svg>`;\n  }\n\n  if (name === 'circle-up') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"${color}\" d=\"M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM384 256H304V384H208V256H128V224L256 96 384 224v32z\"/></svg>`;\n  }\n\n  if (name === 'circle-right') {\n    return `<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"${color}\" d=\"M0 256a256 256 0 1 0 512 0A256 256 0 1 0 0 256zM256 384l0-80-128 0 0-96 128 0 0-80 32 0L416 256 288 384l-32 0z\"/></svg>`;\n  }\n\n  return '';\n};\n","class GleapNetworkIntercepter {\n  startTimestamp = Date.now();\n  requestId = 0;\n  requests = {};\n  externalRequests = [];\n  maxRequests = 30;\n  filters = [];\n  defaultBlacklist = ['gleap.io'];\n  blacklist = [];\n  initialized = false;\n  stopped = false;\n  loadAllResources = false;\n\n  // GleapNetworkIntercepter singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapNetworkIntercepter();\n    }\n    return this.instance;\n  }\n\n  setLoadAllResources(loadAllResources) {\n    this.loadAllResources = loadAllResources;\n  }\n\n  isContentTypeSupported(contentType) {\n    if (typeof contentType !== 'string') {\n      return false;\n    }\n\n    if (contentType === '') {\n      return true;\n    }\n\n    contentType = contentType.toLocaleLowerCase();\n\n    const supportedContentTypes = ['text/', 'xml', 'json'];\n    for (var i = 0; i < supportedContentTypes.length; i++) {\n      if (contentType.includes(supportedContentTypes[i])) {\n        return true;\n      }\n    }\n\n    return false;\n  }\n\n  getRequests() {\n    var requests = JSON.parse(JSON.stringify(Object.values(this.requests)));\n\n    // Merge external requests into internal requests.\n    if (this.externalRequests && this.externalRequests.length > 0) {\n      requests = requests.concat(this.externalRequests);\n    }\n\n    if (this.filters && this.filters.length > 0) {\n      // Perform network log filtering.\n      for (var i = 0; i < requests.length; i++) {\n        var request = requests[i];\n\n        // Headers\n        if (request && request.request && request.request.headers) {\n          for (var j = 0; j < this.filters.length; j++) {\n            delete request.request.headers[this.filters[j]];\n          }\n        }\n\n        // Payload\n        if (request && request.request && request.request.payload) {\n          var payloadObj = request.request.payload;\n          try {\n            payloadObj = JSON.parse(request.request.payload);\n          } catch (e) {}\n\n          if (payloadObj) {\n            for (var j = 0; j < this.filters.length; j++) {\n              delete payloadObj[this.filters[j]];\n            }\n            request.request.payload = JSON.stringify(payloadObj);\n          }\n        }\n\n        // Response\n        if (request && request.response && request.response.responseText) {\n          try {\n            var data = JSON.parse(request.response.responseText);\n            for (var j = 0; j < this.filters.length; j++) {\n              delete data[this.filters[j]];\n            }\n            request.response.responseText = JSON.stringify(data);\n          } catch (e) {}\n        }\n      }\n    }\n\n    // Get static resources from performance.\n    try {\n      if (typeof window !== 'undefined' && window.performance) {\n        var resources = window.performance.getEntriesByType('resource');\n        for (var i = 0; i < resources.length; i++) {\n          var resource = resources[i];\n          if (resource && resource.name) {\n            if (\n              (this.loadAllResources || ['xmlhttprequest', 'fetch'].indexOf(resource.initiatorType) > -1) &&\n              !requests.find((request) => request.url === resource.name)\n            ) {\n              requests.push({\n                type: 'RESOURCE',\n                date: new Date(this.startTimestamp + resource.startTime),\n                url: resource.name,\n                duration: Math.round(resource.duration),\n                initiatorType: resource.initiatorType,\n              });\n            }\n          }\n        }\n      }\n    } catch (exp) {}\n\n    var blacklist = this.blacklist.concat(this.defaultBlacklist);\n    if (blacklist && blacklist.length > 0) {\n      try {\n        requests = requests.filter((request) => {\n          for (var i = 0; i < blacklist.length; i++) {\n            if (request && request.url && request.url.includes(blacklist[i])) {\n              return false;\n            }\n          }\n          return true;\n        });\n      } catch (exp) {}\n    }\n\n    return requests;\n  }\n\n  setMaxRequests(maxRequests) {\n    if (maxRequests > 70) {\n      maxRequests = 70;\n    }\n    this.maxRequests = maxRequests;\n  }\n\n  setStopped(stopped) {\n    this.stopped = stopped;\n  }\n\n  setFilters(filters) {\n    this.filters = this.filters.concat(filters ? filters : []);\n  }\n\n  setBlacklist(blacklist) {\n    this.blacklist = this.blacklist.concat(blacklist ? blacklist : []);\n  }\n\n  cleanRequests() {\n    var keys = Object.keys(this.requests);\n    if (keys.length > this.maxRequests) {\n      var keysToRemove = keys.slice(0, keys.length - this.maxRequests);\n      for (var i = 0; i < keysToRemove.length; i++) {\n        delete this.requests[keysToRemove[i]];\n      }\n    }\n  }\n\n  calcRequestTime(bbRequestId) {\n    if (!bbRequestId || !this.requests || !this.requests[bbRequestId]) {\n      return;\n    }\n\n    var startDate = this.requests[bbRequestId]['date'];\n    if (startDate) {\n      this.requests[bbRequestId]['duration'] = new Date().getTime() - startDate.getTime();\n    }\n  }\n\n  getTextContentSize(text) {\n    var size = 0;\n    try {\n      size = new TextEncoder().encode(text).length;\n    } catch (exp) {\n      try {\n        size = encodeURI(s).split(/%..|./).length - 1;\n      } catch (exp) {\n        try {\n          size = new Blob([text]).size;\n        } catch (exp) {\n          size = text.length;\n        }\n      }\n    }\n\n    const kiloBytes = size / 1024;\n    const megaBytes = kiloBytes / 1024;\n    return megaBytes;\n  }\n\n  cleanupContentSize(text) {\n    const contentSize = this.getTextContentSize(text);\n    if (contentSize > 0.15) {\n      return '<content_too_large>';\n    }\n\n    return text;\n  }\n\n  cleanupPayload(payload) {\n    if (payload === undefined || payload === null) {\n      return '{}';\n    }\n\n    try {\n      if (typeof TextDecoder !== undefined && ArrayBuffer.isView(payload)) {\n        let value = new TextDecoder().decode(payload);\n        return value;\n      }\n    } catch (exp) {}\n\n    return payload;\n  }\n\n  preparePayload(payload) {\n    var payloadText = this.cleanupPayload(payload);\n    return this.cleanupContentSize(payloadText);\n  }\n\n  start() {\n    if (this.initialized) {\n      return;\n    }\n\n    this.initialized = true;\n    const self = this;\n    this.interceptNetworkRequests({\n      onFetch: (params, bbRequestId) => {\n        if (this.stopped || !bbRequestId || !this.requests) {\n          return;\n        }\n\n        if (params.length > 0 && typeof params[0] !== 'undefined' && typeof params[0].url !== 'undefined') {\n          this.requests[bbRequestId] = {\n            url: params[0].url,\n            date: new Date(),\n            request: {\n              payload: '',\n              headers: typeof params[0].headers !== 'undefined' ? Object.fromEntries(params[0].headers.entries()) : {},\n            },\n            type: typeof params[0].method !== 'undefined' ? params[0].method : '',\n          };\n        } else {\n          if (params.length >= 2 && params[1]) {\n            var method = params[1] && params[1].method ? params[1].method : 'GET';\n            this.requests[bbRequestId] = {\n              request: {\n                payload: self.preparePayload(params[1].body),\n                headers: params[1].headers,\n              },\n              type: method,\n              url: params[0],\n              date: new Date(),\n            };\n          } else {\n            this.requests[bbRequestId] = {\n              url: params[0],\n              date: new Date(),\n            };\n          }\n        }\n\n        this.cleanRequests();\n      },\n      onFetchLoad: (req, bbRequestId) => {\n        if (this.stopped || !bbRequestId || !this.requests || !this.requests[bbRequestId]) {\n          return;\n        }\n\n        try {\n          this.requests[bbRequestId]['success'] = true;\n          this.requests[bbRequestId]['response'] = {\n            status: req.status,\n            statusText: '',\n            responseText: '<request_still_open>',\n          };\n          this.calcRequestTime(bbRequestId);\n        } catch (exp) {}\n\n        try {\n          var contentType = '';\n          if (req.headers && typeof req.headers.get !== 'undefined') {\n            contentType = req.headers.get('content-type');\n          }\n\n          if (this.isContentTypeSupported(contentType)) {\n            req\n              .text()\n              .then((responseText) => {\n                if (this.requests[bbRequestId]) {\n                  this.requests[bbRequestId]['success'] = true;\n                  this.requests[bbRequestId]['response'] = {\n                    status: req.status,\n                    statusText: req.statusText,\n                    responseText: self.cleanupContentSize(responseText),\n                  };\n                }\n                this.calcRequestTime(bbRequestId);\n                this.cleanRequests();\n              })\n              .catch((err) => {\n                this.cleanRequests();\n              });\n          } else {\n            if (this.requests[bbRequestId]) {\n              this.requests[bbRequestId]['success'] = true;\n              this.requests[bbRequestId]['response'] = {\n                status: req.status,\n                statusText: req.statusText,\n                responseText: '<content_type_not_supported>',\n              };\n            }\n            this.calcRequestTime(bbRequestId);\n            this.cleanRequests();\n          }\n        } catch (exp) {}\n      },\n      onFetchFailed: (err, bbRequestId) => {\n        if (this.stopped || !bbRequestId || !this.requests || !this.requests[bbRequestId]) {\n          return;\n        }\n\n        this.requests[bbRequestId]['success'] = false;\n        this.calcRequestTime(bbRequestId);\n        this.cleanRequests();\n      },\n      onOpen: (request, args) => {\n        if (this.stopped) {\n          return;\n        }\n\n        if (request && request.bbRequestId && args.length >= 2 && this.requests) {\n          this.requests[request.bbRequestId] = {\n            type: args[0],\n            url: args[1],\n            date: new Date(),\n          };\n        }\n\n        this.cleanRequests();\n      },\n      onSend: (request, args) => {\n        if (this.stopped) {\n          return;\n        }\n\n        if (request && request.bbRequestId && this.requests && this.requests[request.bbRequestId]) {\n          this.requests[request.bbRequestId]['request'] = {\n            payload: this.preparePayload(args.length > 0 ? args[0] : '{}'),\n            headers: request.requestHeaders,\n          };\n        }\n\n        this.cleanRequests();\n      },\n      onError: (request, args) => {\n        if (\n          !this.stopped &&\n          this.requests &&\n          request &&\n          request.currentTarget &&\n          request.currentTarget.bbRequestId &&\n          this.requests[request.currentTarget.bbRequestId]\n        ) {\n          this.requests[request.currentTarget.bbRequestId]['success'] = false;\n          this.calcRequestTime(request.bbRequestId);\n        }\n\n        this.cleanRequests();\n      },\n      onLoad: (request, args) => {\n        if (this.stopped) {\n          return;\n        }\n\n        if (\n          request &&\n          request.currentTarget &&\n          request.currentTarget.bbRequestId &&\n          this.requests &&\n          this.requests[request.currentTarget.bbRequestId]\n        ) {\n          var target = request.currentTarget;\n          var responseType = target.responseType;\n          var responseText = '<' + responseType + '>';\n          if (responseType === '' || responseType === 'text') {\n            responseText = this.cleanupContentSize(target.responseText);\n          }\n\n          this.requests[target.bbRequestId]['success'] = true;\n          this.requests[target.bbRequestId]['response'] = {\n            status: target.status,\n            statusText: target.statusText,\n            responseText: responseText,\n          };\n\n          this.calcRequestTime(target.bbRequestId);\n        }\n\n        this.cleanRequests();\n      },\n    });\n  }\n\n  interceptNetworkRequests(callback) {\n    var self = this;\n    const open = XMLHttpRequest.prototype.open;\n    const send = XMLHttpRequest.prototype.send;\n\n    // Only override open and send if they haven't been overridden already.\n    if (XMLHttpRequest.prototype.gleapSetRequestHeader === undefined) {\n      XMLHttpRequest.prototype.gleapSetRequestHeader = XMLHttpRequest.prototype.setRequestHeader;\n    }\n\n    if (XMLHttpRequest.prototype.gleapSetRequestHeader) {\n      XMLHttpRequest.prototype.setRequestHeader = function (header, value) {\n        if (!this.requestHeaders) {\n          this.requestHeaders = {};\n        }\n\n        if (this.requestHeaders && this.requestHeaders.hasOwnProperty(header)) {\n          return;\n        }\n\n        if (!this.requestHeaders[header]) {\n          this.requestHeaders[header] = [];\n        }\n\n        this.requestHeaders[header].push(value);\n        this.gleapSetRequestHeader(header, value);\n      };\n    }\n\n    XMLHttpRequest.prototype.open = function () {\n      this['bbRequestId'] = ++self.requestId;\n      callback.onOpen && callback.onOpen(this, arguments);\n      if (callback.onLoad) {\n        this.addEventListener('load', callback.onLoad.bind(callback));\n      }\n      if (callback.onError) {\n        this.addEventListener('error', callback.onError.bind(callback));\n      }\n      return open.apply(this, arguments);\n    };\n    XMLHttpRequest.prototype.send = function () {\n      callback.onSend && callback.onSend(this, arguments);\n      return send.apply(this, arguments);\n    };\n\n    if (window.fetch) {\n      (function () {\n        var originalFetch = window.fetch;\n        window.fetch = function () {\n          var bbRequestId = ++self.requestId;\n          callback.onFetch(arguments, bbRequestId);\n\n          return originalFetch\n            .apply(this, arguments)\n            .then(function (response) {\n              if (response && typeof response.clone === 'function') {\n                const data = response.clone();\n                callback.onFetchLoad(data, bbRequestId);\n              }\n\n              return response;\n            })\n            .catch((err) => {\n              callback.onFetchFailed(err, bbRequestId);\n              throw err;\n            });\n        };\n      })();\n    }\n\n    return callback;\n  }\n\n  blobToTextPromise(blob) {\n    return new Promise(function (resolve, reject) {\n      var fr = new FileReader();\n      fr.onload = function (evt) {\n        if (evt && evt.target && evt.target.result) {\n          resolve(evt.target.result);\n        } else {\n          reject();\n        }\n      };\n      fr.onerror = function (err) {\n        reject(err);\n      };\n      fr.readAsText(blob);\n    });\n  }\n}\n\nexport default GleapNetworkIntercepter;\n","export const resizeImage = (base64Str, maxWidth = 400, maxHeight = 400) => {\n  return new Promise((resolve, reject) => {\n    var isJPEG = base64Str.indexOf('data:image/jpeg') === 0;\n    var img = new Image();\n    img.src = base64Str;\n    img.onerror = () => {\n      reject();\n    };\n    img.onload = () => {\n      var canvas = document.createElement('canvas');\n      var MAX_WIDTH = maxWidth;\n      var MAX_HEIGHT = maxHeight;\n\n      // Adjust max width / height based on image props\n      if (maxWidth > img.width / 1.5) {\n        MAX_WIDTH = img.width / 1.5;\n      }\n\n      if (maxHeight > img.height / 1.5) {\n        MAX_HEIGHT = img.height / 1.5;\n      }\n\n      var width = img.width;\n      var height = img.height;\n\n      if (width > height) {\n        if (width > MAX_WIDTH) {\n          height *= MAX_WIDTH / width;\n          width = MAX_WIDTH;\n        }\n      } else {\n        if (height > MAX_HEIGHT) {\n          width *= MAX_HEIGHT / height;\n          height = MAX_HEIGHT;\n        }\n      }\n      canvas.width = width;\n      canvas.height = height;\n      var ctx = canvas.getContext('2d');\n      ctx.drawImage(img, 0, 0, width, height);\n\n      if (isJPEG) {\n        resolve(canvas.toDataURL('image/jpeg', 0.7));\n      } else {\n        resolve(canvas.toDataURL());\n      }\n    };\n  });\n};\n\nconst MOBILE_UA_REGEX = /(android|iphone|ipod|ipad|blackberry|iemobile|opera mini|webos)/i;\n\nexport const getDeviceType = () => {\n  return isMobile() ? 'mobile' : 'desktop';\n};\n\nexport const isMobile = () => {\n  if (typeof window === 'undefined') {\n    return false;\n  }\n\n  try {\n    const nav = typeof navigator !== 'undefined' ? navigator : undefined;\n\n    if (nav?.userAgentData && typeof nav.userAgentData.mobile === 'boolean' && nav.userAgentData.mobile !== null) {\n      return nav.userAgentData.mobile;\n    }\n\n    if (nav && MOBILE_UA_REGEX.test(nav.userAgent || nav.vendor || '')) {\n      return true;\n    }\n\n    if (nav?.maxTouchPoints > 1 && window.matchMedia) {\n      const coarsePointer = window.matchMedia('(hover: none) and (pointer: coarse)');\n      if (coarsePointer?.matches) {\n        return true;\n      }\n    }\n  } catch (exp) {\n    // Swallow errors and treat as desktop fallback.\n  }\n\n  return false;\n};\n\nexport const gleapDataParser = function (data) {\n  if (!data) {\n    return {};\n  }\n  if (typeof data === 'string' || data instanceof String) {\n    try {\n      return JSON.parse(data);\n    } catch (e) {\n      return {};\n    }\n  }\n  return data;\n};\n\nexport const truncateString = (str, num) => {\n  if (str.length > num) {\n    return str.slice(0, num) + '...';\n  } else {\n    return str;\n  }\n};\n\nconst removeSubDomain = (v) => {\n  try {\n    var parts = v.split('.');\n    var is2ndLevelDomain = false;\n    const secondLevel = parts[parts.length - 2];\n    if (\n      secondLevel === 'co' ||\n      secondLevel === 'com' ||\n      secondLevel === 'gv' ||\n      secondLevel === 'ac' ||\n      secondLevel === 'edu' ||\n      secondLevel === 'gov' ||\n      secondLevel === 'mil' ||\n      secondLevel === 'net' ||\n      secondLevel === 'org'\n    ) {\n      is2ndLevelDomain = true;\n    }\n    parts = parts.slice(is2ndLevelDomain ? -3 : -2);\n    return parts.join('.');\n  } catch (exp) {}\n  return v;\n};\n\nexport const loadFromGleapCache = (key) => {\n  try {\n    const cachedData = localStorage.getItem(`gleap-widget-${key}`);\n    if (cachedData) {\n      const config = JSON.parse(cachedData);\n      return config;\n    }\n  } catch (exp) {}\n  return null;\n};\n\nexport const saveToGleapCache = (key, data) => {\n  const k = `gleap-widget-${key}`;\n  if (data) {\n    try {\n      localStorage.setItem(k, JSON.stringify(data));\n    } catch (exp) {}\n  } else {\n    localStorage.removeItem(k);\n  }\n};\n\nexport const clearGleapCache = (key) => {\n  try {\n    const k = `gleap-widget-${key}`;\n    localStorage.removeItem(k);\n  } catch {}\n};\n\nexport const setGleapCookie = (name, value, days) => {\n  try {\n    var expires = '';\n    if (days) {\n      var date = new Date();\n      date.setTime(date.getTime() + days * 24 * 60 * 60 * 1000);\n      expires = '; expires=' + date.toUTCString();\n    }\n    const host = removeSubDomain(window.location.host.split(':')[0]);\n    document.cookie = name + '=' + (value || '') + expires + '; path=/; domain=' + host;\n  } catch (exp) {}\n};\n\nexport const getGleapCookie = (name) => {\n  try {\n    var nameEQ = name + '=';\n    var ca = document.cookie.split(';');\n    for (var i = 0; i < ca.length; i++) {\n      var c = ca[i];\n      while (c.charAt(0) == ' ') c = c.substring(1, c.length);\n      if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length, c.length);\n    }\n  } catch (exp) {}\n  return null;\n};\n\nexport const eraseGleapCookie = (name) => {\n  try {\n    const host = removeSubDomain(window.location.host.split(':')[0]);\n    document.cookie = name + '=; Path=/; Expires=Thu, 01 Jan 1970 00:00:01 GMT; Domain=' + host;\n  } catch (exp) {}\n};\n\nexport const getDOMElementDescription = (element, html = true) => {\n  var innerText = truncateString(element.innerText || '', 40)\n    .replace(/(\\r\\n|\\n|\\r)/gm, '')\n    .replace(/ +(?= )/g, '');\n  var elementId = '';\n  var elementClass = '';\n  if (typeof element.getAttribute !== 'undefined') {\n    const elemId = element.getAttribute('id');\n    if (elemId) {\n      elementId = ` id=\"${elemId}\"`;\n    }\n    const elemClass = element.getAttribute('class');\n    if (elemClass) {\n      elementClass = ` class=\"${elemClass}\"`;\n    }\n  }\n  const elementTag = (element.tagName || '').toLowerCase();\n\n  var htmlPre = '<';\n  var htmlPost = '>';\n  if (!html) {\n    htmlPre = '[';\n    htmlPost = ']';\n  }\n\n  return `${htmlPre}${elementTag}${elementId}${elementClass}${htmlPost}${innerText}${htmlPre}/${elementTag}${htmlPost}`;\n};\n\nexport const runFunctionWhenDomIsReady = (callback) => {\n  if (document.readyState === 'complete' || document.readyState === 'loaded' || document.readyState === 'interactive') {\n    callback();\n  } else {\n    document.addEventListener('DOMContentLoaded', () => {\n      callback();\n    });\n  }\n};\n\nexport const fixGleapHeight = () => {\n  try {\n    if ('visualViewport' in window && /iPad|iPhone|iPod/.test(navigator.userAgent)) {\n      let initialHeight = window.innerHeight;\n\n      function updateContainerHeight() {\n        try {\n          const gleapFrameContainer = document.querySelector('.gleap-frame-container-inner iframe');\n\n          if (!gleapFrameContainer) {\n            return;\n          }\n\n          // Check if the keyboard is open\n          if (window.visualViewport.height < initialHeight) {\n            gleapFrameContainer.style.setProperty('max-height', window.visualViewport.height + 'px', 'important');\n          } else {\n            // Remove the padding bottom\n            gleapFrameContainer.style.removeProperty('max-height');\n          }\n        } catch (error) {}\n      }\n\n      function handleOrientationChange() {\n        try {\n          // Update initial dimensions\n          initialHeight = window.innerHeight;\n          updateContainerHeight();\n        } catch (error) {}\n      }\n\n      // Update on resize (keyboard show/hide and viewport resize)\n      window.visualViewport.addEventListener('resize', updateContainerHeight);\n\n      // Handle orientation changes\n      window.addEventListener('orientationchange', handleOrientationChange);\n\n      // Update initially\n      updateContainerHeight();\n    }\n  } catch (error) {}\n};\n","import { GleapSession, GleapTranslationManager } from './Gleap'; // Adjust path if needed\n\n// Enum for request states\nconst RequestStatus = {\n  PENDING: 'pending',\n  SUCCESS: 'success',\n  ERROR: 'error',\n};\n\nclass ChecklistNetworkManager {\n  static instance = null;\n\n  /** @private {Map<string, Promise<string>>} outboundId -> Promise<internalId> */\n  validationRequests = new Map();\n  /** @private {Map<string, { status: RequestStatus, internalId?: string, error?: any }>} */\n  validationCache = new Map(); // Caches final results (success/error)\n\n  /** @private {Map<string, Promise<any>>} internalId -> Promise<checklistData> */\n  fetchRequests = new Map();\n  /** @private {Map<string, { status: RequestStatus, data?: any, error?: any }>} */\n  fetchCache = new Map(); // Caches final results (success/error)\n\n  // Private constructor for Singleton\n  constructor() {\n    if (ChecklistNetworkManager.instance) {\n      return ChecklistNetworkManager.instance;\n    }\n    ChecklistNetworkManager.instance = this;\n  }\n\n  /**\n   * Gets the singleton instance of the ChecklistNetworkManager.\n   * @returns {ChecklistNetworkManager} The singleton instance.\n   */\n  static getInstance() {\n    if (!ChecklistNetworkManager.instance) {\n      ChecklistNetworkManager.instance = new ChecklistNetworkManager();\n    }\n    return ChecklistNetworkManager.instance;\n  }\n\n  clearCache() {\n    this.validationCache.clear();\n    this.fetchCache.clear();\n    this.validationRequests.clear();\n    this.fetchRequests.clear();\n  }\n\n  /**\n   * @private\n   * Gets common query parameters for API requests.\n   * @returns {string} Query parameter string.\n   */\n  _getQueryParams() {\n    const gleapSessionInstance = GleapSession.getInstance();\n    const session = gleapSessionInstance?.session;\n    const lang = GleapTranslationManager.getInstance().getActiveLanguage() || 'en';\n    return `gleapId=${session?.gleapId || ''}&gleapHash=${session?.gleapHash || ''}&lang=${lang}`;\n  }\n\n  /**\n   * @private\n   * Gets the API base URL.\n   * @returns {string | null} The API URL or null if not configured.\n   */\n  _getApiUrl() {\n    const gleapSessionInstance = GleapSession.getInstance();\n    return gleapSessionInstance?.apiUrl || null;\n  }\n\n  /**\n   * @private\n   * Makes an XMLHttpRequest and returns a Promise.\n   * @param {string} method - HTTP method.\n   * @param {string} url - The request URL.\n   * @param {object|null} data - Data to send in the request body.\n   * @returns {Promise<any>} Promise resolving with parsed JSON response on success, rejecting on error.\n   */\n  _makeRequest(method, url, data) {\n    return new Promise((resolve, reject) => {\n      const xhr = new XMLHttpRequest();\n      xhr.open(method, url);\n\n      const gleapSessionInstance = GleapSession.getInstance();\n      gleapSessionInstance?.injectSession(xhr); // Inject session headers\n\n      if (data) {\n        xhr.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n      }\n\n      xhr.onreadystatechange = () => {\n        if (xhr.readyState === 4) {\n          if (xhr.status >= 200 && xhr.status < 300) {\n            try {\n              // Handle potential empty success responses (e.g., 204)\n              const responseData = xhr.responseText ? JSON.parse(xhr.responseText) : null;\n              resolve(responseData);\n            } catch (err) {\n              reject({\n                status: xhr.status,\n                statusText: 'JSON Parse Error',\n                responseText: xhr.responseText,\n                error: err,\n              });\n            }\n          } else {\n            reject({\n              status: xhr.status,\n              statusText: xhr.statusText,\n              responseText: xhr.responseText,\n            });\n          }\n        }\n      };\n\n      xhr.onerror = () => {\n        reject({ status: 0, statusText: 'Network Error', responseText: null });\n      };\n\n      xhr.send(data ? JSON.stringify(data) : null);\n    });\n  }\n\n  /**\n   * @private\n   * Creates a cache key from outboundId and sharedKey\n   * @param {string} outboundId - The public/outbound checklist ID.\n   * @param {string|undefined} sharedKey - Optional shared key.\n   * @returns {string} Combined cache key.\n   */\n  _createCacheKey(outboundId, sharedKey) {\n    return sharedKey ? `${outboundId}::${sharedKey}` : outboundId;\n  }\n\n  /**\n   * Validates an outbound checklist ID, returning a Promise for the internal ID.\n   * Manages caching and deduplicates requests.\n   * @param {string} outboundId - The public/outbound checklist ID.\n   * @param {string} [sharedKey] - Optional shared key for the checklist.\n   * @returns {Promise<string>} A promise that resolves with the internal checklist ID.\n   */\n  validateChecklist(outboundId, sharedKey) {\n    const cacheKey = this._createCacheKey(outboundId, sharedKey);\n\n    // 1. Check cache for final result (success or error)\n    const cachedResult = this.validationCache.get(cacheKey);\n    if (cachedResult) {\n      if (cachedResult.status === RequestStatus.SUCCESS) {\n        return Promise.resolve(cachedResult.internalId);\n      } else {\n        return Promise.reject(cachedResult.error);\n      }\n    }\n\n    // 2. Check for an ongoing request\n    if (this.validationRequests.has(cacheKey)) {\n      return this.validationRequests.get(cacheKey);\n    }\n\n    // 3. Start a new request\n    const apiUrl = this._getApiUrl();\n    if (!apiUrl) {\n      const error = new Error('ChecklistNetworkManager: Gleap API URL not configured.');\n      this.validationCache.set(cacheKey, {\n        status: RequestStatus.ERROR,\n        error,\n      });\n      return Promise.reject(error);\n    }\n\n    const url = `${apiUrl}/outbound/checklists?${this._getQueryParams()}`;\n    const requestPromise = this._makeRequest('POST', url, {\n      outboundId,\n      sharedKey,\n    })\n      .then((responseData) => {\n        if (responseData && responseData.id) {\n          this.validationCache.set(cacheKey, {\n            status: RequestStatus.SUCCESS,\n            internalId: responseData.id,\n          });\n          return responseData.id;\n        } else {\n          const error = new Error('Validation response missing checklist ID.');\n          this.validationCache.set(cacheKey, {\n            status: RequestStatus.ERROR,\n            error: responseData || error,\n          });\n          throw error; // Rethrow to be caught by catch block\n        }\n      })\n      .catch((error) => {\n        // Store the error object itself in the cache\n        this.validationCache.set(cacheKey, {\n          status: RequestStatus.ERROR,\n          error,\n        });\n        throw error; // Re-throw so callers can catch it\n      })\n      .finally(() => {\n        // Remove from pending requests map once done (success or fail)\n        this.validationRequests.delete(cacheKey);\n      });\n\n    // Store the promise for potential concurrent requests\n    this.validationRequests.set(cacheKey, requestPromise);\n    return requestPromise;\n  }\n\n  /**\n   * Fetches the full checklist data using the internal ID, returning a Promise.\n   * Manages caching and deduplicates requests.\n   * @param {string} internalId - The internal checklist ID.\n   * @returns {Promise<object>} A promise that resolves with the full checklist data.\n   */\n  fetchChecklist(internalId) {\n    // 1. Check cache for final result (success or error)\n    const cachedResult = this.fetchCache.get(internalId);\n    if (cachedResult) {\n      if (cachedResult.status === RequestStatus.SUCCESS) {\n        // Return a deep copy to prevent mutation issues if multiple components use it\n        return Promise.resolve(JSON.parse(JSON.stringify(cachedResult.data)));\n      } else {\n        return Promise.reject(cachedResult.error);\n      }\n    }\n\n    // 2. Check for an ongoing request\n    if (this.fetchRequests.has(internalId)) {\n      // Return a promise that resolves with a deep copy\n      return this.fetchRequests.get(internalId).then((data) => JSON.parse(JSON.stringify(data)));\n    }\n\n    // 3. Start a new request\n    const apiUrl = this._getApiUrl();\n    if (!apiUrl) {\n      const error = new Error('ChecklistNetworkManager: Gleap API URL not configured.');\n      this.fetchCache.set(internalId, { status: RequestStatus.ERROR, error });\n      return Promise.reject(error);\n    }\n\n    const url = `${apiUrl}/outbound/checklists/${internalId}?convertTipTap=true&${this._getQueryParams()}`;\n    const requestPromise = this._makeRequest('GET', url, null)\n      .then((responseData) => {\n        if (responseData) {\n          // Cache the successful data\n          this.fetchCache.set(internalId, {\n            status: RequestStatus.SUCCESS,\n            data: responseData,\n          });\n          // Return a deep copy of the data\n          return JSON.parse(JSON.stringify(responseData));\n        } else {\n          // Should not happen with successful GET usually, but handle defensively\n          const error = new Error('Empty response received for checklist fetch.');\n          this.fetchCache.set(internalId, {\n            status: RequestStatus.ERROR,\n            error: responseData || error,\n          });\n          throw error;\n        }\n      })\n      .catch((error) => {\n        this.fetchCache.set(internalId, { status: RequestStatus.ERROR, error });\n        throw error; // Re-throw so callers can catch it\n      })\n      .finally(() => {\n        // Remove from pending requests map once done (success or fail)\n        this.fetchRequests.delete(internalId);\n      });\n\n    this.fetchRequests.set(internalId, requestPromise);\n    // Return a promise that resolves with a deep copy\n    return requestPromise.then((data) => JSON.parse(JSON.stringify(data)));\n  }\n}\n\nexport default ChecklistNetworkManager;\n","/**\n * Shared SSE (Server-Sent Events) stream parser.\n *\n * Reads a fetch Response body as an SSE stream and dispatches\n * parsed events to callbacks. Used by both the JavaScript SDK\n * and the Gleap Frontend dashboard.\n *\n * @example\n * import { parseSSEStream, dispatchSSEEvent } from 'gleap/sse'; // or from './GleapSSEParser'\n *\n * const response = await fetch(url, { method: 'POST', ... });\n * await parseSSEStream(response, {\n *   onMeta: (data) => { ... },\n *   onToken: (data) => { ... },\n *   onDone: (data) => { ... },\n *   onError: (data) => { ... },\n * });\n */\n\n/**\n * Dispatch a single parsed SSE event to the appropriate callback.\n *\n * @param {string} event - Event type: 'meta', 'token', 'tool_start', 'tool_end', 'done', 'error'\n * @param {object} data - Parsed JSON data\n * @param {object} callbacks - { onMeta, onToken, onToolStart?, onToolEnd?, onDone, onError }\n */\nexport const dispatchSSEEvent = (event, data, callbacks) => {\n  switch (event) {\n    case 'meta': callbacks.onMeta?.(data); break;\n    case 'token': callbacks.onToken?.(data); break;\n    case 'tool_start': callbacks.onToolStart?.(data); break;\n    case 'tool_end': callbacks.onToolEnd?.(data); break;\n    case 'done': callbacks.onDone?.(data); break;\n    case 'error': callbacks.onError?.(data); break;\n    case 'handoff': callbacks.onHandoff?.(data); break;\n  }\n};\n\n/**\n * Parse an SSE stream from a fetch Response and dispatch events to callbacks.\n *\n * @param {Response} response - A fetch Response with a readable body (text/event-stream).\n * @param {object} callbacks - { onMeta, onToken, onToolStart?, onToolEnd?, onDone, onError }\n * @returns {Promise<void>}\n */\nexport const parseSSEStream = async (response, callbacks) => {\n  if (!response.body) {\n    callbacks.onError?.({ message: 'No response body.' });\n    return;\n  }\n\n  const reader = response.body.getReader();\n  const decoder = new TextDecoder();\n  let buffer = '';\n  let currentEvent = '';\n  let currentData = '';\n\n  try {\n    while (true) {\n      const { done, value } = await reader.read();\n      if (done) break;\n\n      buffer += decoder.decode(value, { stream: true });\n      const lines = buffer.split('\\n');\n      buffer = lines.pop() ?? '';\n\n      for (const line of lines) {\n        const trimmed = line.replace(/\\r$/, '');\n\n        if (trimmed.startsWith('event: ')) {\n          currentEvent = trimmed.slice(7).trim();\n        } else if (trimmed.startsWith('data: ')) {\n          currentData += (currentData ? '\\n' : '') + trimmed.slice(6);\n        } else if (trimmed === '') {\n          if (currentEvent && currentData) {\n            try {\n              const parsed = JSON.parse(currentData);\n              dispatchSSEEvent(currentEvent, parsed, callbacks);\n            } catch { /* skip malformed event */ }\n          }\n          currentEvent = '';\n          currentData = '';\n        }\n      }\n    }\n\n    // Flush any remaining buffered event\n    if (currentEvent && currentData) {\n      try {\n        const parsed = JSON.parse(currentData);\n        dispatchSSEEvent(currentEvent, parsed, callbacks);\n      } catch { /* skip */ }\n    }\n  } catch (err) {\n    if (err?.name !== 'AbortError') {\n      callbacks.onError?.({ message: 'Stream interrupted.' });\n    }\n  }\n};\n","import { GleapSession, GleapTranslationManager } from './Gleap';\nimport { parseSSEStream } from './GleapSSEParser';\n\nconst RequestStatus = {\n  PENDING: 'pending',\n  SUCCESS: 'success',\n  ERROR: 'error',\n};\n\nclass AgentNetworkManager {\n  static instance = null;\n\n  /** @private {Map<string, boolean>} agentId -> true if currently executing */\n  executeInFlight = new Map();\n\n  /** @private {Map<string, { status, data?, error? }>} */\n  messagesCache = new Map();\n  /** @private {Map<string, Promise>} */\n  messagesRequests = new Map();\n\n  constructor() {\n    if (AgentNetworkManager.instance) {\n      return AgentNetworkManager.instance;\n    }\n    AgentNetworkManager.instance = this;\n  }\n\n  static getInstance() {\n    if (!AgentNetworkManager.instance) {\n      AgentNetworkManager.instance = new AgentNetworkManager();\n    }\n    return AgentNetworkManager.instance;\n  }\n\n  clearCache() {\n    this.messagesCache.clear();\n    this.messagesRequests.clear();\n    this.executeInFlight.clear();\n  }\n\n  /** @private */\n  _getApiUrl() {\n    const s = GleapSession.getInstance();\n    return s?.apiUrl || null;\n  }\n\n  /** @private — build auth headers for fetch */\n  _getHeaders() {\n    const s = GleapSession.getInstance();\n    const headers = { 'Content-Type': 'application/json' };\n    if (s?.sdkKey) headers['Api-Token'] = s.sdkKey;\n    if (s?.session?.gleapId) headers['Gleap-Id'] = s.session.gleapId;\n    if (s?.session?.gleapHash) headers['Gleap-Hash'] = s.session.gleapHash;\n    return headers;\n  }\n\n  /** @private — XHR for non-streaming requests */\n  _makeRequest(method, url, data) {\n    return new Promise((resolve, reject) => {\n      const xhr = new XMLHttpRequest();\n      xhr.open(method, url);\n      const s = GleapSession.getInstance();\n      s?.injectSession(xhr);\n      if (data) xhr.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n\n      xhr.onreadystatechange = () => {\n        if (xhr.readyState === 4) {\n          if (xhr.status >= 200 && xhr.status < 300) {\n            try {\n              resolve(xhr.responseText ? JSON.parse(xhr.responseText) : null);\n            } catch (err) {\n              reject({ status: xhr.status, statusText: 'JSON Parse Error', error: err });\n            }\n          } else {\n            reject({ status: xhr.status, statusText: xhr.statusText, responseText: xhr.responseText });\n          }\n        }\n      };\n      xhr.onerror = () => reject({ status: 0, statusText: 'Network Error' });\n      xhr.send(data ? JSON.stringify(data) : null);\n    });\n  }\n\n  /**\n   * Stream an agent execution via SSE.\n   *\n   * @param {string} agentId\n   * @param {object} body - { messages, conversationId?, additionalContext? }\n   * @param {object} callbacks - { onMeta, onToken, onDone, onError, onToolStart?, onToolEnd? }\n   * @param {AbortSignal} [signal] - optional abort signal\n   * @returns {Promise<void>}\n   */\n  async streamAgent(agentId, body, callbacks, signal) {\n    if (this.executeInFlight.get(agentId)) return;\n    this.executeInFlight.set(agentId, true);\n\n    const apiUrl = this._getApiUrl();\n    if (!apiUrl) {\n      this.executeInFlight.delete(agentId);\n      callbacks.onError?.({ message: 'Gleap API URL not configured.' });\n      return;\n    }\n\n    const url = `${apiUrl}/v3/shared/agents/${agentId}/stream`;\n    const headers = { ...this._getHeaders(), Accept: 'text/event-stream' };\n\n    let response;\n    try {\n      response = await fetch(url, {\n        method: 'POST',\n        headers,\n        body: JSON.stringify(body),\n        signal,\n      });\n    } catch (err) {\n      this.executeInFlight.delete(agentId);\n      if (err?.name === 'AbortError') return;\n      callbacks.onError?.({ message: 'Failed to connect to agent.' });\n      return;\n    }\n\n    if (!response.ok) {\n      this.executeInFlight.delete(agentId);\n      callbacks.onError?.({ message: `Server error: ${response.status}` });\n      return;\n    }\n\n    // Use shared SSE parser\n    await parseSSEStream(response, callbacks);\n\n    // Invalidate caches\n    if (body.conversationId) this._invalidateMessagesCache(body.conversationId);\n    this.executeInFlight.delete(agentId);\n  }\n\n  /**\n   * Non-streaming execute (fallback).\n   */\n  executeAgent(agentId, body) {\n    if (this.executeInFlight.get(agentId)) {\n      return Promise.reject(new Error('Agent execution already in progress.'));\n    }\n\n    const apiUrl = this._getApiUrl();\n    if (!apiUrl) return Promise.reject(new Error('AgentNetworkManager: Gleap API URL not configured.'));\n\n    this.executeInFlight.set(agentId, true);\n    const url = `${apiUrl}/v3/shared/agents/${agentId}/execute`;\n    return this._makeRequest('POST', url, body)\n      .then((responseData) => {\n        if (body.conversationId) this._invalidateMessagesCache(body.conversationId);\n        if (responseData?.conversationId) this._invalidateMessagesCache(responseData.conversationId);\n        return responseData;\n      })\n      .finally(() => { this.executeInFlight.delete(agentId); });\n  }\n\n  getConversationMessages(agentId, conversationId, limit = 50, skip = 0) {\n    if (agentId === 'kai') return Promise.resolve({ messages: [] });\n\n    const cacheKey = `${conversationId}:${limit}:${skip}`;\n    const cached = this.messagesCache.get(cacheKey);\n    if (cached) {\n      return cached.status === RequestStatus.SUCCESS\n        ? Promise.resolve(JSON.parse(JSON.stringify(cached.data)))\n        : Promise.reject(cached.error);\n    }\n    if (this.messagesRequests.has(cacheKey)) {\n      return this.messagesRequests.get(cacheKey).then((d) => JSON.parse(JSON.stringify(d)));\n    }\n\n    const apiUrl = this._getApiUrl();\n    if (!apiUrl) return Promise.reject(new Error('AgentNetworkManager: Gleap API URL not configured.'));\n\n    const url = `${apiUrl}/v3/shared/agents/${agentId}/conversations/${conversationId}/messages?limit=${limit}&skip=${skip}`;\n    const p = this._makeRequest('GET', url, null)\n      .then((d) => { this.messagesCache.set(cacheKey, { status: RequestStatus.SUCCESS, data: d }); return JSON.parse(JSON.stringify(d)); })\n      .catch((e) => { this.messagesCache.set(cacheKey, { status: RequestStatus.ERROR, error: e }); throw e; })\n      .finally(() => { this.messagesRequests.delete(cacheKey); });\n\n    this.messagesRequests.set(cacheKey, p);\n    return p.then((d) => JSON.parse(JSON.stringify(d)));\n  }\n\n  getConversations(agentId, limit = 10, skip = 0) {\n    if (agentId === 'kai') return Promise.resolve({ conversations: [] });\n\n    const apiUrl = this._getApiUrl();\n    if (!apiUrl) return Promise.reject(new Error('AgentNetworkManager: Gleap API URL not configured.'));\n    return this._makeRequest('GET', `${apiUrl}/v3/shared/agents/${agentId}/conversations?limit=${limit}&skip=${skip}`, null);\n  }\n\n  /** @private */\n  _invalidateMessagesCache(conversationId) {\n    for (const key of this.messagesCache.keys()) {\n      if (key.startsWith(conversationId + ':')) this.messagesCache.delete(key);\n    }\n    for (const key of this.messagesRequests.keys()) {\n      if (key.startsWith(conversationId + ':')) this.messagesRequests.delete(key);\n    }\n  }\n}\n\nexport default AgentNetworkManager;\n","/**\n * Custom positioning reference element.\n * @see https://floating-ui.com/docs/virtual-elements\n */\n\nconst sides = ['top', 'right', 'bottom', 'left'];\nconst alignments = ['start', 'end'];\nconst placements = /*#__PURE__*/sides.reduce((acc, side) => acc.concat(side, side + \"-\" + alignments[0], side + \"-\" + alignments[1]), []);\nconst min = Math.min;\nconst max = Math.max;\nconst round = Math.round;\nconst floor = Math.floor;\nconst createCoords = v => ({\n  x: v,\n  y: v\n});\nconst oppositeSideMap = {\n  left: 'right',\n  right: 'left',\n  bottom: 'top',\n  top: 'bottom'\n};\nconst oppositeAlignmentMap = {\n  start: 'end',\n  end: 'start'\n};\nfunction clamp(start, value, end) {\n  return max(start, min(value, end));\n}\nfunction evaluate(value, param) {\n  return typeof value === 'function' ? value(param) : value;\n}\nfunction getSide(placement) {\n  return placement.split('-')[0];\n}\nfunction getAlignment(placement) {\n  return placement.split('-')[1];\n}\nfunction getOppositeAxis(axis) {\n  return axis === 'x' ? 'y' : 'x';\n}\nfunction getAxisLength(axis) {\n  return axis === 'y' ? 'height' : 'width';\n}\nconst yAxisSides = /*#__PURE__*/new Set(['top', 'bottom']);\nfunction getSideAxis(placement) {\n  return yAxisSides.has(getSide(placement)) ? 'y' : 'x';\n}\nfunction getAlignmentAxis(placement) {\n  return getOppositeAxis(getSideAxis(placement));\n}\nfunction getAlignmentSides(placement, rects, rtl) {\n  if (rtl === void 0) {\n    rtl = false;\n  }\n  const alignment = getAlignment(placement);\n  const alignmentAxis = getAlignmentAxis(placement);\n  const length = getAxisLength(alignmentAxis);\n  let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';\n  if (rects.reference[length] > rects.floating[length]) {\n    mainAlignmentSide = getOppositePlacement(mainAlignmentSide);\n  }\n  return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];\n}\nfunction getExpandedPlacements(placement) {\n  const oppositePlacement = getOppositePlacement(placement);\n  return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];\n}\nfunction getOppositeAlignmentPlacement(placement) {\n  return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);\n}\nconst lrPlacement = ['left', 'right'];\nconst rlPlacement = ['right', 'left'];\nconst tbPlacement = ['top', 'bottom'];\nconst btPlacement = ['bottom', 'top'];\nfunction getSideList(side, isStart, rtl) {\n  switch (side) {\n    case 'top':\n    case 'bottom':\n      if (rtl) return isStart ? rlPlacement : lrPlacement;\n      return isStart ? lrPlacement : rlPlacement;\n    case 'left':\n    case 'right':\n      return isStart ? tbPlacement : btPlacement;\n    default:\n      return [];\n  }\n}\nfunction getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {\n  const alignment = getAlignment(placement);\n  let list = getSideList(getSide(placement), direction === 'start', rtl);\n  if (alignment) {\n    list = list.map(side => side + \"-\" + alignment);\n    if (flipAlignment) {\n      list = list.concat(list.map(getOppositeAlignmentPlacement));\n    }\n  }\n  return list;\n}\nfunction getOppositePlacement(placement) {\n  return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);\n}\nfunction expandPaddingObject(padding) {\n  return {\n    top: 0,\n    right: 0,\n    bottom: 0,\n    left: 0,\n    ...padding\n  };\n}\nfunction getPaddingObject(padding) {\n  return typeof padding !== 'number' ? expandPaddingObject(padding) : {\n    top: padding,\n    right: padding,\n    bottom: padding,\n    left: padding\n  };\n}\nfunction rectToClientRect(rect) {\n  const {\n    x,\n    y,\n    width,\n    height\n  } = rect;\n  return {\n    width,\n    height,\n    top: y,\n    left: x,\n    right: x + width,\n    bottom: y + height,\n    x,\n    y\n  };\n}\n\nexport { alignments, clamp, createCoords, evaluate, expandPaddingObject, floor, getAlignment, getAlignmentAxis, getAlignmentSides, getAxisLength, getExpandedPlacements, getOppositeAlignmentPlacement, getOppositeAxis, getOppositeAxisPlacements, getOppositePlacement, getPaddingObject, getSide, getSideAxis, max, min, placements, rectToClientRect, round, sides };\n","import { getSideAxis, getAlignmentAxis, getAxisLength, getSide, getAlignment, evaluate, getPaddingObject, rectToClientRect, min, clamp, placements, getAlignmentSides, getOppositeAlignmentPlacement, getOppositePlacement, getExpandedPlacements, getOppositeAxisPlacements, sides, max, getOppositeAxis } from '@floating-ui/utils';\nexport { rectToClientRect } from '@floating-ui/utils';\n\nfunction computeCoordsFromPlacement(_ref, placement, rtl) {\n  let {\n    reference,\n    floating\n  } = _ref;\n  const sideAxis = getSideAxis(placement);\n  const alignmentAxis = getAlignmentAxis(placement);\n  const alignLength = getAxisLength(alignmentAxis);\n  const side = getSide(placement);\n  const isVertical = sideAxis === 'y';\n  const commonX = reference.x + reference.width / 2 - floating.width / 2;\n  const commonY = reference.y + reference.height / 2 - floating.height / 2;\n  const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;\n  let coords;\n  switch (side) {\n    case 'top':\n      coords = {\n        x: commonX,\n        y: reference.y - floating.height\n      };\n      break;\n    case 'bottom':\n      coords = {\n        x: commonX,\n        y: reference.y + reference.height\n      };\n      break;\n    case 'right':\n      coords = {\n        x: reference.x + reference.width,\n        y: commonY\n      };\n      break;\n    case 'left':\n      coords = {\n        x: reference.x - floating.width,\n        y: commonY\n      };\n      break;\n    default:\n      coords = {\n        x: reference.x,\n        y: reference.y\n      };\n  }\n  switch (getAlignment(placement)) {\n    case 'start':\n      coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);\n      break;\n    case 'end':\n      coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);\n      break;\n  }\n  return coords;\n}\n\n/**\n * Resolves with an object of overflow side offsets that determine how much the\n * element is overflowing a given clipping boundary on each side.\n * - positive = overflowing the boundary by that number of pixels\n * - negative = how many pixels left before it will overflow\n * - 0 = lies flush with the boundary\n * @see https://floating-ui.com/docs/detectOverflow\n */\nasync function detectOverflow(state, options) {\n  var _await$platform$isEle;\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    x,\n    y,\n    platform,\n    rects,\n    elements,\n    strategy\n  } = state;\n  const {\n    boundary = 'clippingAncestors',\n    rootBoundary = 'viewport',\n    elementContext = 'floating',\n    altBoundary = false,\n    padding = 0\n  } = evaluate(options, state);\n  const paddingObject = getPaddingObject(padding);\n  const altContext = elementContext === 'floating' ? 'reference' : 'floating';\n  const element = elements[altBoundary ? altContext : elementContext];\n  const clippingClientRect = rectToClientRect(await platform.getClippingRect({\n    element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || (await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating))),\n    boundary,\n    rootBoundary,\n    strategy\n  }));\n  const rect = elementContext === 'floating' ? {\n    x,\n    y,\n    width: rects.floating.width,\n    height: rects.floating.height\n  } : rects.reference;\n  const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));\n  const offsetScale = (await (platform.isElement == null ? void 0 : platform.isElement(offsetParent))) ? (await (platform.getScale == null ? void 0 : platform.getScale(offsetParent))) || {\n    x: 1,\n    y: 1\n  } : {\n    x: 1,\n    y: 1\n  };\n  const elementClientRect = rectToClientRect(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({\n    elements,\n    rect,\n    offsetParent,\n    strategy\n  }) : rect);\n  return {\n    top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,\n    bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,\n    left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,\n    right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x\n  };\n}\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a given reference element.\n *\n * This export does not have any `platform` interface logic. You will need to\n * write one for the platform you are using Floating UI with.\n */\nconst computePosition = async (reference, floating, config) => {\n  const {\n    placement = 'bottom',\n    strategy = 'absolute',\n    middleware = [],\n    platform\n  } = config;\n  const validMiddleware = middleware.filter(Boolean);\n  const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));\n  let rects = await platform.getElementRects({\n    reference,\n    floating,\n    strategy\n  });\n  let {\n    x,\n    y\n  } = computeCoordsFromPlacement(rects, placement, rtl);\n  let statefulPlacement = placement;\n  let middlewareData = {};\n  let resetCount = 0;\n  for (let i = 0; i < validMiddleware.length; i++) {\n    var _platform$detectOverf;\n    const {\n      name,\n      fn\n    } = validMiddleware[i];\n    const {\n      x: nextX,\n      y: nextY,\n      data,\n      reset\n    } = await fn({\n      x,\n      y,\n      initialPlacement: placement,\n      placement: statefulPlacement,\n      strategy,\n      middlewareData,\n      rects,\n      platform: {\n        ...platform,\n        detectOverflow: (_platform$detectOverf = platform.detectOverflow) != null ? _platform$detectOverf : detectOverflow\n      },\n      elements: {\n        reference,\n        floating\n      }\n    });\n    x = nextX != null ? nextX : x;\n    y = nextY != null ? nextY : y;\n    middlewareData = {\n      ...middlewareData,\n      [name]: {\n        ...middlewareData[name],\n        ...data\n      }\n    };\n    if (reset && resetCount <= 50) {\n      resetCount++;\n      if (typeof reset === 'object') {\n        if (reset.placement) {\n          statefulPlacement = reset.placement;\n        }\n        if (reset.rects) {\n          rects = reset.rects === true ? await platform.getElementRects({\n            reference,\n            floating,\n            strategy\n          }) : reset.rects;\n        }\n        ({\n          x,\n          y\n        } = computeCoordsFromPlacement(rects, statefulPlacement, rtl));\n      }\n      i = -1;\n    }\n  }\n  return {\n    x,\n    y,\n    placement: statefulPlacement,\n    strategy,\n    middlewareData\n  };\n};\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = options => ({\n  name: 'arrow',\n  options,\n  async fn(state) {\n    const {\n      x,\n      y,\n      placement,\n      rects,\n      platform,\n      elements,\n      middlewareData\n    } = state;\n    // Since `element` is required, we don't Partial<> the type.\n    const {\n      element,\n      padding = 0\n    } = evaluate(options, state) || {};\n    if (element == null) {\n      return {};\n    }\n    const paddingObject = getPaddingObject(padding);\n    const coords = {\n      x,\n      y\n    };\n    const axis = getAlignmentAxis(placement);\n    const length = getAxisLength(axis);\n    const arrowDimensions = await platform.getDimensions(element);\n    const isYAxis = axis === 'y';\n    const minProp = isYAxis ? 'top' : 'left';\n    const maxProp = isYAxis ? 'bottom' : 'right';\n    const clientProp = isYAxis ? 'clientHeight' : 'clientWidth';\n    const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];\n    const startDiff = coords[axis] - rects.reference[axis];\n    const arrowOffsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(element));\n    let clientSize = arrowOffsetParent ? arrowOffsetParent[clientProp] : 0;\n\n    // DOM platform can return `window` as the `offsetParent`.\n    if (!clientSize || !(await (platform.isElement == null ? void 0 : platform.isElement(arrowOffsetParent)))) {\n      clientSize = elements.floating[clientProp] || rects.floating[length];\n    }\n    const centerToReference = endDiff / 2 - startDiff / 2;\n\n    // If the padding is large enough that it causes the arrow to no longer be\n    // centered, modify the padding so that it is centered.\n    const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;\n    const minPadding = min(paddingObject[minProp], largestPossiblePadding);\n    const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);\n\n    // Make sure the arrow doesn't overflow the floating element if the center\n    // point is outside the floating element's bounds.\n    const min$1 = minPadding;\n    const max = clientSize - arrowDimensions[length] - maxPadding;\n    const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;\n    const offset = clamp(min$1, center, max);\n\n    // If the reference is small enough that the arrow's padding causes it to\n    // to point to nothing for an aligned placement, adjust the offset of the\n    // floating element itself. To ensure `shift()` continues to take action,\n    // a single reset is performed when this is true.\n    const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset && rects.reference[length] / 2 - (center < min$1 ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;\n    const alignmentOffset = shouldAddOffset ? center < min$1 ? center - min$1 : center - max : 0;\n    return {\n      [axis]: coords[axis] + alignmentOffset,\n      data: {\n        [axis]: offset,\n        centerOffset: center - offset - alignmentOffset,\n        ...(shouldAddOffset && {\n          alignmentOffset\n        })\n      },\n      reset: shouldAddOffset\n    };\n  }\n});\n\nfunction getPlacementList(alignment, autoAlignment, allowedPlacements) {\n  const allowedPlacementsSortedByAlignment = alignment ? [...allowedPlacements.filter(placement => getAlignment(placement) === alignment), ...allowedPlacements.filter(placement => getAlignment(placement) !== alignment)] : allowedPlacements.filter(placement => getSide(placement) === placement);\n  return allowedPlacementsSortedByAlignment.filter(placement => {\n    if (alignment) {\n      return getAlignment(placement) === alignment || (autoAlignment ? getOppositeAlignmentPlacement(placement) !== placement : false);\n    }\n    return true;\n  });\n}\n/**\n * Optimizes the visibility of the floating element by choosing the placement\n * that has the most space available automatically, without needing to specify a\n * preferred placement. Alternative to `flip`.\n * @see https://floating-ui.com/docs/autoPlacement\n */\nconst autoPlacement = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'autoPlacement',\n    options,\n    async fn(state) {\n      var _middlewareData$autoP, _middlewareData$autoP2, _placementsThatFitOnE;\n      const {\n        rects,\n        middlewareData,\n        placement,\n        platform,\n        elements\n      } = state;\n      const {\n        crossAxis = false,\n        alignment,\n        allowedPlacements = placements,\n        autoAlignment = true,\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      const placements$1 = alignment !== undefined || allowedPlacements === placements ? getPlacementList(alignment || null, autoAlignment, allowedPlacements) : allowedPlacements;\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const currentIndex = ((_middlewareData$autoP = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP.index) || 0;\n      const currentPlacement = placements$1[currentIndex];\n      if (currentPlacement == null) {\n        return {};\n      }\n      const alignmentSides = getAlignmentSides(currentPlacement, rects, await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating)));\n\n      // Make `computeCoords` start from the right place.\n      if (placement !== currentPlacement) {\n        return {\n          reset: {\n            placement: placements$1[0]\n          }\n        };\n      }\n      const currentOverflows = [overflow[getSide(currentPlacement)], overflow[alignmentSides[0]], overflow[alignmentSides[1]]];\n      const allOverflows = [...(((_middlewareData$autoP2 = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP2.overflows) || []), {\n        placement: currentPlacement,\n        overflows: currentOverflows\n      }];\n      const nextPlacement = placements$1[currentIndex + 1];\n\n      // There are more placements to check.\n      if (nextPlacement) {\n        return {\n          data: {\n            index: currentIndex + 1,\n            overflows: allOverflows\n          },\n          reset: {\n            placement: nextPlacement\n          }\n        };\n      }\n      const placementsSortedByMostSpace = allOverflows.map(d => {\n        const alignment = getAlignment(d.placement);\n        return [d.placement, alignment && crossAxis ?\n        // Check along the mainAxis and main crossAxis side.\n        d.overflows.slice(0, 2).reduce((acc, v) => acc + v, 0) :\n        // Check only the mainAxis.\n        d.overflows[0], d.overflows];\n      }).sort((a, b) => a[1] - b[1]);\n      const placementsThatFitOnEachSide = placementsSortedByMostSpace.filter(d => d[2].slice(0,\n      // Aligned placements should not check their opposite crossAxis\n      // side.\n      getAlignment(d[0]) ? 2 : 3).every(v => v <= 0));\n      const resetPlacement = ((_placementsThatFitOnE = placementsThatFitOnEachSide[0]) == null ? void 0 : _placementsThatFitOnE[0]) || placementsSortedByMostSpace[0][0];\n      if (resetPlacement !== placement) {\n        return {\n          data: {\n            index: currentIndex + 1,\n            overflows: allOverflows\n          },\n          reset: {\n            placement: resetPlacement\n          }\n        };\n      }\n      return {};\n    }\n  };\n};\n\n/**\n * Optimizes the visibility of the floating element by flipping the `placement`\n * in order to keep it in view when the preferred placement(s) will overflow the\n * clipping boundary. Alternative to `autoPlacement`.\n * @see https://floating-ui.com/docs/flip\n */\nconst flip = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'flip',\n    options,\n    async fn(state) {\n      var _middlewareData$arrow, _middlewareData$flip;\n      const {\n        placement,\n        middlewareData,\n        rects,\n        initialPlacement,\n        platform,\n        elements\n      } = state;\n      const {\n        mainAxis: checkMainAxis = true,\n        crossAxis: checkCrossAxis = true,\n        fallbackPlacements: specifiedFallbackPlacements,\n        fallbackStrategy = 'bestFit',\n        fallbackAxisSideDirection = 'none',\n        flipAlignment = true,\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n\n      // If a reset by the arrow was caused due to an alignment offset being\n      // added, we should skip any logic now since `flip()` has already done its\n      // work.\n      // https://github.com/floating-ui/floating-ui/issues/2549#issuecomment-1719601643\n      if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {\n        return {};\n      }\n      const side = getSide(placement);\n      const initialSideAxis = getSideAxis(initialPlacement);\n      const isBasePlacement = getSide(initialPlacement) === initialPlacement;\n      const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));\n      const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));\n      const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== 'none';\n      if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {\n        fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));\n      }\n      const placements = [initialPlacement, ...fallbackPlacements];\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const overflows = [];\n      let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];\n      if (checkMainAxis) {\n        overflows.push(overflow[side]);\n      }\n      if (checkCrossAxis) {\n        const sides = getAlignmentSides(placement, rects, rtl);\n        overflows.push(overflow[sides[0]], overflow[sides[1]]);\n      }\n      overflowsData = [...overflowsData, {\n        placement,\n        overflows\n      }];\n\n      // One or more sides is overflowing.\n      if (!overflows.every(side => side <= 0)) {\n        var _middlewareData$flip2, _overflowsData$filter;\n        const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;\n        const nextPlacement = placements[nextIndex];\n        if (nextPlacement) {\n          const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;\n          if (!ignoreCrossAxisOverflow ||\n          // We leave the current main axis only if every placement on that axis\n          // overflows the main axis.\n          overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {\n            // Try next placement and re-run the lifecycle.\n            return {\n              data: {\n                index: nextIndex,\n                overflows: overflowsData\n              },\n              reset: {\n                placement: nextPlacement\n              }\n            };\n          }\n        }\n\n        // First, find the candidates that fit on the mainAxis side of overflow,\n        // then find the placement that fits the best on the main crossAxis side.\n        let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;\n\n        // Otherwise fallback.\n        if (!resetPlacement) {\n          switch (fallbackStrategy) {\n            case 'bestFit':\n              {\n                var _overflowsData$filter2;\n                const placement = (_overflowsData$filter2 = overflowsData.filter(d => {\n                  if (hasFallbackAxisSideDirection) {\n                    const currentSideAxis = getSideAxis(d.placement);\n                    return currentSideAxis === initialSideAxis ||\n                    // Create a bias to the `y` side axis due to horizontal\n                    // reading directions favoring greater width.\n                    currentSideAxis === 'y';\n                  }\n                  return true;\n                }).map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];\n                if (placement) {\n                  resetPlacement = placement;\n                }\n                break;\n              }\n            case 'initialPlacement':\n              resetPlacement = initialPlacement;\n              break;\n          }\n        }\n        if (placement !== resetPlacement) {\n          return {\n            reset: {\n              placement: resetPlacement\n            }\n          };\n        }\n      }\n      return {};\n    }\n  };\n};\n\nfunction getSideOffsets(overflow, rect) {\n  return {\n    top: overflow.top - rect.height,\n    right: overflow.right - rect.width,\n    bottom: overflow.bottom - rect.height,\n    left: overflow.left - rect.width\n  };\n}\nfunction isAnySideFullyClipped(overflow) {\n  return sides.some(side => overflow[side] >= 0);\n}\n/**\n * Provides data to hide the floating element in applicable situations, such as\n * when it is not in the same clipping context as the reference element.\n * @see https://floating-ui.com/docs/hide\n */\nconst hide = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'hide',\n    options,\n    async fn(state) {\n      const {\n        rects,\n        platform\n      } = state;\n      const {\n        strategy = 'referenceHidden',\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      switch (strategy) {\n        case 'referenceHidden':\n          {\n            const overflow = await platform.detectOverflow(state, {\n              ...detectOverflowOptions,\n              elementContext: 'reference'\n            });\n            const offsets = getSideOffsets(overflow, rects.reference);\n            return {\n              data: {\n                referenceHiddenOffsets: offsets,\n                referenceHidden: isAnySideFullyClipped(offsets)\n              }\n            };\n          }\n        case 'escaped':\n          {\n            const overflow = await platform.detectOverflow(state, {\n              ...detectOverflowOptions,\n              altBoundary: true\n            });\n            const offsets = getSideOffsets(overflow, rects.floating);\n            return {\n              data: {\n                escapedOffsets: offsets,\n                escaped: isAnySideFullyClipped(offsets)\n              }\n            };\n          }\n        default:\n          {\n            return {};\n          }\n      }\n    }\n  };\n};\n\nfunction getBoundingRect(rects) {\n  const minX = min(...rects.map(rect => rect.left));\n  const minY = min(...rects.map(rect => rect.top));\n  const maxX = max(...rects.map(rect => rect.right));\n  const maxY = max(...rects.map(rect => rect.bottom));\n  return {\n    x: minX,\n    y: minY,\n    width: maxX - minX,\n    height: maxY - minY\n  };\n}\nfunction getRectsByLine(rects) {\n  const sortedRects = rects.slice().sort((a, b) => a.y - b.y);\n  const groups = [];\n  let prevRect = null;\n  for (let i = 0; i < sortedRects.length; i++) {\n    const rect = sortedRects[i];\n    if (!prevRect || rect.y - prevRect.y > prevRect.height / 2) {\n      groups.push([rect]);\n    } else {\n      groups[groups.length - 1].push(rect);\n    }\n    prevRect = rect;\n  }\n  return groups.map(rect => rectToClientRect(getBoundingRect(rect)));\n}\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'inline',\n    options,\n    async fn(state) {\n      const {\n        placement,\n        elements,\n        rects,\n        platform,\n        strategy\n      } = state;\n      // A MouseEvent's client{X,Y} coords can be up to 2 pixels off a\n      // ClientRect's bounds, despite the event listener being triggered. A\n      // padding of 2 seems to handle this issue.\n      const {\n        padding = 2,\n        x,\n        y\n      } = evaluate(options, state);\n      const nativeClientRects = Array.from((await (platform.getClientRects == null ? void 0 : platform.getClientRects(elements.reference))) || []);\n      const clientRects = getRectsByLine(nativeClientRects);\n      const fallback = rectToClientRect(getBoundingRect(nativeClientRects));\n      const paddingObject = getPaddingObject(padding);\n      function getBoundingClientRect() {\n        // There are two rects and they are disjoined.\n        if (clientRects.length === 2 && clientRects[0].left > clientRects[1].right && x != null && y != null) {\n          // Find the first rect in which the point is fully inside.\n          return clientRects.find(rect => x > rect.left - paddingObject.left && x < rect.right + paddingObject.right && y > rect.top - paddingObject.top && y < rect.bottom + paddingObject.bottom) || fallback;\n        }\n\n        // There are 2 or more connected rects.\n        if (clientRects.length >= 2) {\n          if (getSideAxis(placement) === 'y') {\n            const firstRect = clientRects[0];\n            const lastRect = clientRects[clientRects.length - 1];\n            const isTop = getSide(placement) === 'top';\n            const top = firstRect.top;\n            const bottom = lastRect.bottom;\n            const left = isTop ? firstRect.left : lastRect.left;\n            const right = isTop ? firstRect.right : lastRect.right;\n            const width = right - left;\n            const height = bottom - top;\n            return {\n              top,\n              bottom,\n              left,\n              right,\n              width,\n              height,\n              x: left,\n              y: top\n            };\n          }\n          const isLeftSide = getSide(placement) === 'left';\n          const maxRight = max(...clientRects.map(rect => rect.right));\n          const minLeft = min(...clientRects.map(rect => rect.left));\n          const measureRects = clientRects.filter(rect => isLeftSide ? rect.left === minLeft : rect.right === maxRight);\n          const top = measureRects[0].top;\n          const bottom = measureRects[measureRects.length - 1].bottom;\n          const left = minLeft;\n          const right = maxRight;\n          const width = right - left;\n          const height = bottom - top;\n          return {\n            top,\n            bottom,\n            left,\n            right,\n            width,\n            height,\n            x: left,\n            y: top\n          };\n        }\n        return fallback;\n      }\n      const resetRects = await platform.getElementRects({\n        reference: {\n          getBoundingClientRect\n        },\n        floating: elements.floating,\n        strategy\n      });\n      if (rects.reference.x !== resetRects.reference.x || rects.reference.y !== resetRects.reference.y || rects.reference.width !== resetRects.reference.width || rects.reference.height !== resetRects.reference.height) {\n        return {\n          reset: {\n            rects: resetRects\n          }\n        };\n      }\n      return {};\n    }\n  };\n};\n\nconst originSides = /*#__PURE__*/new Set(['left', 'top']);\n\n// For type backwards-compatibility, the `OffsetOptions` type was also\n// Derivable.\n\nasync function convertValueToCoords(state, options) {\n  const {\n    placement,\n    platform,\n    elements\n  } = state;\n  const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));\n  const side = getSide(placement);\n  const alignment = getAlignment(placement);\n  const isVertical = getSideAxis(placement) === 'y';\n  const mainAxisMulti = originSides.has(side) ? -1 : 1;\n  const crossAxisMulti = rtl && isVertical ? -1 : 1;\n  const rawValue = evaluate(options, state);\n\n  // eslint-disable-next-line prefer-const\n  let {\n    mainAxis,\n    crossAxis,\n    alignmentAxis\n  } = typeof rawValue === 'number' ? {\n    mainAxis: rawValue,\n    crossAxis: 0,\n    alignmentAxis: null\n  } : {\n    mainAxis: rawValue.mainAxis || 0,\n    crossAxis: rawValue.crossAxis || 0,\n    alignmentAxis: rawValue.alignmentAxis\n  };\n  if (alignment && typeof alignmentAxis === 'number') {\n    crossAxis = alignment === 'end' ? alignmentAxis * -1 : alignmentAxis;\n  }\n  return isVertical ? {\n    x: crossAxis * crossAxisMulti,\n    y: mainAxis * mainAxisMulti\n  } : {\n    x: mainAxis * mainAxisMulti,\n    y: crossAxis * crossAxisMulti\n  };\n}\n\n/**\n * Modifies the placement by translating the floating element along the\n * specified axes.\n * A number (shorthand for `mainAxis` or distance), or an axes configuration\n * object may be passed.\n * @see https://floating-ui.com/docs/offset\n */\nconst offset = function (options) {\n  if (options === void 0) {\n    options = 0;\n  }\n  return {\n    name: 'offset',\n    options,\n    async fn(state) {\n      var _middlewareData$offse, _middlewareData$arrow;\n      const {\n        x,\n        y,\n        placement,\n        middlewareData\n      } = state;\n      const diffCoords = await convertValueToCoords(state, options);\n\n      // If the placement is the same and the arrow caused an alignment offset\n      // then we don't need to change the positioning coordinates.\n      if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {\n        return {};\n      }\n      return {\n        x: x + diffCoords.x,\n        y: y + diffCoords.y,\n        data: {\n          ...diffCoords,\n          placement\n        }\n      };\n    }\n  };\n};\n\n/**\n * Optimizes the visibility of the floating element by shifting it in order to\n * keep it in view when it will overflow the clipping boundary.\n * @see https://floating-ui.com/docs/shift\n */\nconst shift = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'shift',\n    options,\n    async fn(state) {\n      const {\n        x,\n        y,\n        placement,\n        platform\n      } = state;\n      const {\n        mainAxis: checkMainAxis = true,\n        crossAxis: checkCrossAxis = false,\n        limiter = {\n          fn: _ref => {\n            let {\n              x,\n              y\n            } = _ref;\n            return {\n              x,\n              y\n            };\n          }\n        },\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      const coords = {\n        x,\n        y\n      };\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const crossAxis = getSideAxis(getSide(placement));\n      const mainAxis = getOppositeAxis(crossAxis);\n      let mainAxisCoord = coords[mainAxis];\n      let crossAxisCoord = coords[crossAxis];\n      if (checkMainAxis) {\n        const minSide = mainAxis === 'y' ? 'top' : 'left';\n        const maxSide = mainAxis === 'y' ? 'bottom' : 'right';\n        const min = mainAxisCoord + overflow[minSide];\n        const max = mainAxisCoord - overflow[maxSide];\n        mainAxisCoord = clamp(min, mainAxisCoord, max);\n      }\n      if (checkCrossAxis) {\n        const minSide = crossAxis === 'y' ? 'top' : 'left';\n        const maxSide = crossAxis === 'y' ? 'bottom' : 'right';\n        const min = crossAxisCoord + overflow[minSide];\n        const max = crossAxisCoord - overflow[maxSide];\n        crossAxisCoord = clamp(min, crossAxisCoord, max);\n      }\n      const limitedCoords = limiter.fn({\n        ...state,\n        [mainAxis]: mainAxisCoord,\n        [crossAxis]: crossAxisCoord\n      });\n      return {\n        ...limitedCoords,\n        data: {\n          x: limitedCoords.x - x,\n          y: limitedCoords.y - y,\n          enabled: {\n            [mainAxis]: checkMainAxis,\n            [crossAxis]: checkCrossAxis\n          }\n        }\n      };\n    }\n  };\n};\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    options,\n    fn(state) {\n      const {\n        x,\n        y,\n        placement,\n        rects,\n        middlewareData\n      } = state;\n      const {\n        offset = 0,\n        mainAxis: checkMainAxis = true,\n        crossAxis: checkCrossAxis = true\n      } = evaluate(options, state);\n      const coords = {\n        x,\n        y\n      };\n      const crossAxis = getSideAxis(placement);\n      const mainAxis = getOppositeAxis(crossAxis);\n      let mainAxisCoord = coords[mainAxis];\n      let crossAxisCoord = coords[crossAxis];\n      const rawOffset = evaluate(offset, state);\n      const computedOffset = typeof rawOffset === 'number' ? {\n        mainAxis: rawOffset,\n        crossAxis: 0\n      } : {\n        mainAxis: 0,\n        crossAxis: 0,\n        ...rawOffset\n      };\n      if (checkMainAxis) {\n        const len = mainAxis === 'y' ? 'height' : 'width';\n        const limitMin = rects.reference[mainAxis] - rects.floating[len] + computedOffset.mainAxis;\n        const limitMax = rects.reference[mainAxis] + rects.reference[len] - computedOffset.mainAxis;\n        if (mainAxisCoord < limitMin) {\n          mainAxisCoord = limitMin;\n        } else if (mainAxisCoord > limitMax) {\n          mainAxisCoord = limitMax;\n        }\n      }\n      if (checkCrossAxis) {\n        var _middlewareData$offse, _middlewareData$offse2;\n        const len = mainAxis === 'y' ? 'width' : 'height';\n        const isOriginSide = originSides.has(getSide(placement));\n        const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);\n        const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);\n        if (crossAxisCoord < limitMin) {\n          crossAxisCoord = limitMin;\n        } else if (crossAxisCoord > limitMax) {\n          crossAxisCoord = limitMax;\n        }\n      }\n      return {\n        [mainAxis]: mainAxisCoord,\n        [crossAxis]: crossAxisCoord\n      };\n    }\n  };\n};\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'size',\n    options,\n    async fn(state) {\n      var _state$middlewareData, _state$middlewareData2;\n      const {\n        placement,\n        rects,\n        platform,\n        elements\n      } = state;\n      const {\n        apply = () => {},\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const side = getSide(placement);\n      const alignment = getAlignment(placement);\n      const isYAxis = getSideAxis(placement) === 'y';\n      const {\n        width,\n        height\n      } = rects.floating;\n      let heightSide;\n      let widthSide;\n      if (side === 'top' || side === 'bottom') {\n        heightSide = side;\n        widthSide = alignment === ((await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating))) ? 'start' : 'end') ? 'left' : 'right';\n      } else {\n        widthSide = side;\n        heightSide = alignment === 'end' ? 'top' : 'bottom';\n      }\n      const maximumClippingHeight = height - overflow.top - overflow.bottom;\n      const maximumClippingWidth = width - overflow.left - overflow.right;\n      const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);\n      const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);\n      const noShift = !state.middlewareData.shift;\n      let availableHeight = overflowAvailableHeight;\n      let availableWidth = overflowAvailableWidth;\n      if ((_state$middlewareData = state.middlewareData.shift) != null && _state$middlewareData.enabled.x) {\n        availableWidth = maximumClippingWidth;\n      }\n      if ((_state$middlewareData2 = state.middlewareData.shift) != null && _state$middlewareData2.enabled.y) {\n        availableHeight = maximumClippingHeight;\n      }\n      if (noShift && !alignment) {\n        const xMin = max(overflow.left, 0);\n        const xMax = max(overflow.right, 0);\n        const yMin = max(overflow.top, 0);\n        const yMax = max(overflow.bottom, 0);\n        if (isYAxis) {\n          availableWidth = width - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));\n        } else {\n          availableHeight = height - 2 * (yMin !== 0 || yMax !== 0 ? yMin + yMax : max(overflow.top, overflow.bottom));\n        }\n      }\n      await apply({\n        ...state,\n        availableWidth,\n        availableHeight\n      });\n      const nextDimensions = await platform.getDimensions(elements.floating);\n      if (width !== nextDimensions.width || height !== nextDimensions.height) {\n        return {\n          reset: {\n            rects: true\n          }\n        };\n      }\n      return {};\n    }\n  };\n};\n\nexport { arrow, autoPlacement, computePosition, detectOverflow, flip, hide, inline, limitShift, offset, shift, size };\n","function hasWindow() {\n  return typeof window !== 'undefined';\n}\nfunction getNodeName(node) {\n  if (isNode(node)) {\n    return (node.nodeName || '').toLowerCase();\n  }\n  // Mocked nodes in testing environments may not be instances of Node. By\n  // returning `#document` an infinite loop won't occur.\n  // https://github.com/floating-ui/floating-ui/issues/2317\n  return '#document';\n}\nfunction getWindow(node) {\n  var _node$ownerDocument;\n  return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;\n}\nfunction getDocumentElement(node) {\n  var _ref;\n  return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;\n}\nfunction isNode(value) {\n  if (!hasWindow()) {\n    return false;\n  }\n  return value instanceof Node || value instanceof getWindow(value).Node;\n}\nfunction isElement(value) {\n  if (!hasWindow()) {\n    return false;\n  }\n  return value instanceof Element || value instanceof getWindow(value).Element;\n}\nfunction isHTMLElement(value) {\n  if (!hasWindow()) {\n    return false;\n  }\n  return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;\n}\nfunction isShadowRoot(value) {\n  if (!hasWindow() || typeof ShadowRoot === 'undefined') {\n    return false;\n  }\n  return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;\n}\nconst invalidOverflowDisplayValues = /*#__PURE__*/new Set(['inline', 'contents']);\nfunction isOverflowElement(element) {\n  const {\n    overflow,\n    overflowX,\n    overflowY,\n    display\n  } = getComputedStyle(element);\n  return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);\n}\nconst tableElements = /*#__PURE__*/new Set(['table', 'td', 'th']);\nfunction isTableElement(element) {\n  return tableElements.has(getNodeName(element));\n}\nconst topLayerSelectors = [':popover-open', ':modal'];\nfunction isTopLayer(element) {\n  return topLayerSelectors.some(selector => {\n    try {\n      return element.matches(selector);\n    } catch (_e) {\n      return false;\n    }\n  });\n}\nconst transformProperties = ['transform', 'translate', 'scale', 'rotate', 'perspective'];\nconst willChangeValues = ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'];\nconst containValues = ['paint', 'layout', 'strict', 'content'];\nfunction isContainingBlock(elementOrCss) {\n  const webkit = isWebKit();\n  const css = isElement(elementOrCss) ? getComputedStyle(elementOrCss) : elementOrCss;\n\n  // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n  // https://drafts.csswg.org/css-transforms-2/#individual-transforms\n  return transformProperties.some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || willChangeValues.some(value => (css.willChange || '').includes(value)) || containValues.some(value => (css.contain || '').includes(value));\n}\nfunction getContainingBlock(element) {\n  let currentNode = getParentNode(element);\n  while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {\n    if (isContainingBlock(currentNode)) {\n      return currentNode;\n    } else if (isTopLayer(currentNode)) {\n      return null;\n    }\n    currentNode = getParentNode(currentNode);\n  }\n  return null;\n}\nfunction isWebKit() {\n  if (typeof CSS === 'undefined' || !CSS.supports) return false;\n  return CSS.supports('-webkit-backdrop-filter', 'none');\n}\nconst lastTraversableNodeNames = /*#__PURE__*/new Set(['html', 'body', '#document']);\nfunction isLastTraversableNode(node) {\n  return lastTraversableNodeNames.has(getNodeName(node));\n}\nfunction getComputedStyle(element) {\n  return getWindow(element).getComputedStyle(element);\n}\nfunction getNodeScroll(element) {\n  if (isElement(element)) {\n    return {\n      scrollLeft: element.scrollLeft,\n      scrollTop: element.scrollTop\n    };\n  }\n  return {\n    scrollLeft: element.scrollX,\n    scrollTop: element.scrollY\n  };\n}\nfunction getParentNode(node) {\n  if (getNodeName(node) === 'html') {\n    return node;\n  }\n  const result =\n  // Step into the shadow DOM of the parent of a slotted node.\n  node.assignedSlot ||\n  // DOM Element detected.\n  node.parentNode ||\n  // ShadowRoot detected.\n  isShadowRoot(node) && node.host ||\n  // Fallback.\n  getDocumentElement(node);\n  return isShadowRoot(result) ? result.host : result;\n}\nfunction getNearestOverflowAncestor(node) {\n  const parentNode = getParentNode(node);\n  if (isLastTraversableNode(parentNode)) {\n    return node.ownerDocument ? node.ownerDocument.body : node.body;\n  }\n  if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {\n    return parentNode;\n  }\n  return getNearestOverflowAncestor(parentNode);\n}\nfunction getOverflowAncestors(node, list, traverseIframes) {\n  var _node$ownerDocument2;\n  if (list === void 0) {\n    list = [];\n  }\n  if (traverseIframes === void 0) {\n    traverseIframes = true;\n  }\n  const scrollableAncestor = getNearestOverflowAncestor(node);\n  const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);\n  const win = getWindow(scrollableAncestor);\n  if (isBody) {\n    const frameElement = getFrameElement(win);\n    return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);\n  }\n  return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));\n}\nfunction getFrameElement(win) {\n  return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;\n}\n\nexport { getComputedStyle, getContainingBlock, getDocumentElement, getFrameElement, getNearestOverflowAncestor, getNodeName, getNodeScroll, getOverflowAncestors, getParentNode, getWindow, isContainingBlock, isElement, isHTMLElement, isLastTraversableNode, isNode, isOverflowElement, isShadowRoot, isTableElement, isTopLayer, isWebKit };\n","import { rectToClientRect, arrow as arrow$1, autoPlacement as autoPlacement$1, detectOverflow as detectOverflow$1, flip as flip$1, hide as hide$1, inline as inline$1, limitShift as limitShift$1, offset as offset$1, shift as shift$1, size as size$1, computePosition as computePosition$1 } from '@floating-ui/core';\nimport { round, createCoords, max, min, floor } from '@floating-ui/utils';\nimport { getComputedStyle as getComputedStyle$1, isHTMLElement, isElement, getWindow, isWebKit, getFrameElement, getNodeScroll, getDocumentElement, isTopLayer, getNodeName, isOverflowElement, getOverflowAncestors, getParentNode, isLastTraversableNode, isContainingBlock, isTableElement, getContainingBlock } from '@floating-ui/utils/dom';\nexport { getOverflowAncestors } from '@floating-ui/utils/dom';\n\nfunction getCssDimensions(element) {\n  const css = getComputedStyle$1(element);\n  // In testing environments, the `width` and `height` properties are empty\n  // strings for SVG elements, returning NaN. Fallback to `0` in this case.\n  let width = parseFloat(css.width) || 0;\n  let height = parseFloat(css.height) || 0;\n  const hasOffset = isHTMLElement(element);\n  const offsetWidth = hasOffset ? element.offsetWidth : width;\n  const offsetHeight = hasOffset ? element.offsetHeight : height;\n  const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;\n  if (shouldFallback) {\n    width = offsetWidth;\n    height = offsetHeight;\n  }\n  return {\n    width,\n    height,\n    $: shouldFallback\n  };\n}\n\nfunction unwrapElement(element) {\n  return !isElement(element) ? element.contextElement : element;\n}\n\nfunction getScale(element) {\n  const domElement = unwrapElement(element);\n  if (!isHTMLElement(domElement)) {\n    return createCoords(1);\n  }\n  const rect = domElement.getBoundingClientRect();\n  const {\n    width,\n    height,\n    $\n  } = getCssDimensions(domElement);\n  let x = ($ ? round(rect.width) : rect.width) / width;\n  let y = ($ ? round(rect.height) : rect.height) / height;\n\n  // 0, NaN, or Infinity should always fallback to 1.\n\n  if (!x || !Number.isFinite(x)) {\n    x = 1;\n  }\n  if (!y || !Number.isFinite(y)) {\n    y = 1;\n  }\n  return {\n    x,\n    y\n  };\n}\n\nconst noOffsets = /*#__PURE__*/createCoords(0);\nfunction getVisualOffsets(element) {\n  const win = getWindow(element);\n  if (!isWebKit() || !win.visualViewport) {\n    return noOffsets;\n  }\n  return {\n    x: win.visualViewport.offsetLeft,\n    y: win.visualViewport.offsetTop\n  };\n}\nfunction shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {\n  if (isFixed === void 0) {\n    isFixed = false;\n  }\n  if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {\n    return false;\n  }\n  return isFixed;\n}\n\nfunction getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {\n  if (includeScale === void 0) {\n    includeScale = false;\n  }\n  if (isFixedStrategy === void 0) {\n    isFixedStrategy = false;\n  }\n  const clientRect = element.getBoundingClientRect();\n  const domElement = unwrapElement(element);\n  let scale = createCoords(1);\n  if (includeScale) {\n    if (offsetParent) {\n      if (isElement(offsetParent)) {\n        scale = getScale(offsetParent);\n      }\n    } else {\n      scale = getScale(element);\n    }\n  }\n  const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);\n  let x = (clientRect.left + visualOffsets.x) / scale.x;\n  let y = (clientRect.top + visualOffsets.y) / scale.y;\n  let width = clientRect.width / scale.x;\n  let height = clientRect.height / scale.y;\n  if (domElement) {\n    const win = getWindow(domElement);\n    const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;\n    let currentWin = win;\n    let currentIFrame = getFrameElement(currentWin);\n    while (currentIFrame && offsetParent && offsetWin !== currentWin) {\n      const iframeScale = getScale(currentIFrame);\n      const iframeRect = currentIFrame.getBoundingClientRect();\n      const css = getComputedStyle$1(currentIFrame);\n      const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;\n      const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;\n      x *= iframeScale.x;\n      y *= iframeScale.y;\n      width *= iframeScale.x;\n      height *= iframeScale.y;\n      x += left;\n      y += top;\n      currentWin = getWindow(currentIFrame);\n      currentIFrame = getFrameElement(currentWin);\n    }\n  }\n  return rectToClientRect({\n    width,\n    height,\n    x,\n    y\n  });\n}\n\n// If <html> has a CSS width greater than the viewport, then this will be\n// incorrect for RTL.\nfunction getWindowScrollBarX(element, rect) {\n  const leftScroll = getNodeScroll(element).scrollLeft;\n  if (!rect) {\n    return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;\n  }\n  return rect.left + leftScroll;\n}\n\nfunction getHTMLOffset(documentElement, scroll) {\n  const htmlRect = documentElement.getBoundingClientRect();\n  const x = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);\n  const y = htmlRect.top + scroll.scrollTop;\n  return {\n    x,\n    y\n  };\n}\n\nfunction convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {\n  let {\n    elements,\n    rect,\n    offsetParent,\n    strategy\n  } = _ref;\n  const isFixed = strategy === 'fixed';\n  const documentElement = getDocumentElement(offsetParent);\n  const topLayer = elements ? isTopLayer(elements.floating) : false;\n  if (offsetParent === documentElement || topLayer && isFixed) {\n    return rect;\n  }\n  let scroll = {\n    scrollLeft: 0,\n    scrollTop: 0\n  };\n  let scale = createCoords(1);\n  const offsets = createCoords(0);\n  const isOffsetParentAnElement = isHTMLElement(offsetParent);\n  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n    if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n      scroll = getNodeScroll(offsetParent);\n    }\n    if (isHTMLElement(offsetParent)) {\n      const offsetRect = getBoundingClientRect(offsetParent);\n      scale = getScale(offsetParent);\n      offsets.x = offsetRect.x + offsetParent.clientLeft;\n      offsets.y = offsetRect.y + offsetParent.clientTop;\n    }\n  }\n  const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);\n  return {\n    width: rect.width * scale.x,\n    height: rect.height * scale.y,\n    x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,\n    y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y\n  };\n}\n\nfunction getClientRects(element) {\n  return Array.from(element.getClientRects());\n}\n\n// Gets the entire size of the scrollable document area, even extending outside\n// of the `<html>` and `<body>` rect bounds if horizontally scrollable.\nfunction getDocumentRect(element) {\n  const html = getDocumentElement(element);\n  const scroll = getNodeScroll(element);\n  const body = element.ownerDocument.body;\n  const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);\n  const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);\n  let x = -scroll.scrollLeft + getWindowScrollBarX(element);\n  const y = -scroll.scrollTop;\n  if (getComputedStyle$1(body).direction === 'rtl') {\n    x += max(html.clientWidth, body.clientWidth) - width;\n  }\n  return {\n    width,\n    height,\n    x,\n    y\n  };\n}\n\n// Safety check: ensure the scrollbar space is reasonable in case this\n// calculation is affected by unusual styles.\n// Most scrollbars leave 15-18px of space.\nconst SCROLLBAR_MAX = 25;\nfunction getViewportRect(element, strategy) {\n  const win = getWindow(element);\n  const html = getDocumentElement(element);\n  const visualViewport = win.visualViewport;\n  let width = html.clientWidth;\n  let height = html.clientHeight;\n  let x = 0;\n  let y = 0;\n  if (visualViewport) {\n    width = visualViewport.width;\n    height = visualViewport.height;\n    const visualViewportBased = isWebKit();\n    if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {\n      x = visualViewport.offsetLeft;\n      y = visualViewport.offsetTop;\n    }\n  }\n  const windowScrollbarX = getWindowScrollBarX(html);\n  // <html> `overflow: hidden` + `scrollbar-gutter: stable` reduces the\n  // visual width of the <html> but this is not considered in the size\n  // of `html.clientWidth`.\n  if (windowScrollbarX <= 0) {\n    const doc = html.ownerDocument;\n    const body = doc.body;\n    const bodyStyles = getComputedStyle(body);\n    const bodyMarginInline = doc.compatMode === 'CSS1Compat' ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;\n    const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);\n    if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {\n      width -= clippingStableScrollbarWidth;\n    }\n  } else if (windowScrollbarX <= SCROLLBAR_MAX) {\n    // If the <body> scrollbar is on the left, the width needs to be extended\n    // by the scrollbar amount so there isn't extra space on the right.\n    width += windowScrollbarX;\n  }\n  return {\n    width,\n    height,\n    x,\n    y\n  };\n}\n\nconst absoluteOrFixed = /*#__PURE__*/new Set(['absolute', 'fixed']);\n// Returns the inner client rect, subtracting scrollbars if present.\nfunction getInnerBoundingClientRect(element, strategy) {\n  const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');\n  const top = clientRect.top + element.clientTop;\n  const left = clientRect.left + element.clientLeft;\n  const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);\n  const width = element.clientWidth * scale.x;\n  const height = element.clientHeight * scale.y;\n  const x = left * scale.x;\n  const y = top * scale.y;\n  return {\n    width,\n    height,\n    x,\n    y\n  };\n}\nfunction getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {\n  let rect;\n  if (clippingAncestor === 'viewport') {\n    rect = getViewportRect(element, strategy);\n  } else if (clippingAncestor === 'document') {\n    rect = getDocumentRect(getDocumentElement(element));\n  } else if (isElement(clippingAncestor)) {\n    rect = getInnerBoundingClientRect(clippingAncestor, strategy);\n  } else {\n    const visualOffsets = getVisualOffsets(element);\n    rect = {\n      x: clippingAncestor.x - visualOffsets.x,\n      y: clippingAncestor.y - visualOffsets.y,\n      width: clippingAncestor.width,\n      height: clippingAncestor.height\n    };\n  }\n  return rectToClientRect(rect);\n}\nfunction hasFixedPositionAncestor(element, stopNode) {\n  const parentNode = getParentNode(element);\n  if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {\n    return false;\n  }\n  return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);\n}\n\n// A \"clipping ancestor\" is an `overflow` element with the characteristic of\n// clipping (or hiding) child elements. This returns all clipping ancestors\n// of the given element up the tree.\nfunction getClippingElementAncestors(element, cache) {\n  const cachedResult = cache.get(element);\n  if (cachedResult) {\n    return cachedResult;\n  }\n  let result = getOverflowAncestors(element, [], false).filter(el => isElement(el) && getNodeName(el) !== 'body');\n  let currentContainingBlockComputedStyle = null;\n  const elementIsFixed = getComputedStyle$1(element).position === 'fixed';\n  let currentNode = elementIsFixed ? getParentNode(element) : element;\n\n  // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n  while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {\n    const computedStyle = getComputedStyle$1(currentNode);\n    const currentNodeIsContaining = isContainingBlock(currentNode);\n    if (!currentNodeIsContaining && computedStyle.position === 'fixed') {\n      currentContainingBlockComputedStyle = null;\n    }\n    const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);\n    if (shouldDropCurrentNode) {\n      // Drop non-containing blocks.\n      result = result.filter(ancestor => ancestor !== currentNode);\n    } else {\n      // Record last containing block for next iteration.\n      currentContainingBlockComputedStyle = computedStyle;\n    }\n    currentNode = getParentNode(currentNode);\n  }\n  cache.set(element, result);\n  return result;\n}\n\n// Gets the maximum area that the element is visible in due to any number of\n// clipping ancestors.\nfunction getClippingRect(_ref) {\n  let {\n    element,\n    boundary,\n    rootBoundary,\n    strategy\n  } = _ref;\n  const elementClippingAncestors = boundary === 'clippingAncestors' ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);\n  const clippingAncestors = [...elementClippingAncestors, rootBoundary];\n  const firstClippingAncestor = clippingAncestors[0];\n  const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {\n    const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);\n    accRect.top = max(rect.top, accRect.top);\n    accRect.right = min(rect.right, accRect.right);\n    accRect.bottom = min(rect.bottom, accRect.bottom);\n    accRect.left = max(rect.left, accRect.left);\n    return accRect;\n  }, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));\n  return {\n    width: clippingRect.right - clippingRect.left,\n    height: clippingRect.bottom - clippingRect.top,\n    x: clippingRect.left,\n    y: clippingRect.top\n  };\n}\n\nfunction getDimensions(element) {\n  const {\n    width,\n    height\n  } = getCssDimensions(element);\n  return {\n    width,\n    height\n  };\n}\n\nfunction getRectRelativeToOffsetParent(element, offsetParent, strategy) {\n  const isOffsetParentAnElement = isHTMLElement(offsetParent);\n  const documentElement = getDocumentElement(offsetParent);\n  const isFixed = strategy === 'fixed';\n  const rect = getBoundingClientRect(element, true, isFixed, offsetParent);\n  let scroll = {\n    scrollLeft: 0,\n    scrollTop: 0\n  };\n  const offsets = createCoords(0);\n\n  // If the <body> scrollbar appears on the left (e.g. RTL systems). Use\n  // Firefox with layout.scrollbar.side = 3 in about:config to test this.\n  function setLeftRTLScrollbarOffset() {\n    offsets.x = getWindowScrollBarX(documentElement);\n  }\n  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n    if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n      scroll = getNodeScroll(offsetParent);\n    }\n    if (isOffsetParentAnElement) {\n      const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);\n      offsets.x = offsetRect.x + offsetParent.clientLeft;\n      offsets.y = offsetRect.y + offsetParent.clientTop;\n    } else if (documentElement) {\n      setLeftRTLScrollbarOffset();\n    }\n  }\n  if (isFixed && !isOffsetParentAnElement && documentElement) {\n    setLeftRTLScrollbarOffset();\n  }\n  const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);\n  const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;\n  const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;\n  return {\n    x,\n    y,\n    width: rect.width,\n    height: rect.height\n  };\n}\n\nfunction isStaticPositioned(element) {\n  return getComputedStyle$1(element).position === 'static';\n}\n\nfunction getTrueOffsetParent(element, polyfill) {\n  if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {\n    return null;\n  }\n  if (polyfill) {\n    return polyfill(element);\n  }\n  let rawOffsetParent = element.offsetParent;\n\n  // Firefox returns the <html> element as the offsetParent if it's non-static,\n  // while Chrome and Safari return the <body> element. The <body> element must\n  // be used to perform the correct calculations even if the <html> element is\n  // non-static.\n  if (getDocumentElement(element) === rawOffsetParent) {\n    rawOffsetParent = rawOffsetParent.ownerDocument.body;\n  }\n  return rawOffsetParent;\n}\n\n// Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\nfunction getOffsetParent(element, polyfill) {\n  const win = getWindow(element);\n  if (isTopLayer(element)) {\n    return win;\n  }\n  if (!isHTMLElement(element)) {\n    let svgOffsetParent = getParentNode(element);\n    while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {\n      if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {\n        return svgOffsetParent;\n      }\n      svgOffsetParent = getParentNode(svgOffsetParent);\n    }\n    return win;\n  }\n  let offsetParent = getTrueOffsetParent(element, polyfill);\n  while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {\n    offsetParent = getTrueOffsetParent(offsetParent, polyfill);\n  }\n  if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {\n    return win;\n  }\n  return offsetParent || getContainingBlock(element) || win;\n}\n\nconst getElementRects = async function (data) {\n  const getOffsetParentFn = this.getOffsetParent || getOffsetParent;\n  const getDimensionsFn = this.getDimensions;\n  const floatingDimensions = await getDimensionsFn(data.floating);\n  return {\n    reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),\n    floating: {\n      x: 0,\n      y: 0,\n      width: floatingDimensions.width,\n      height: floatingDimensions.height\n    }\n  };\n};\n\nfunction isRTL(element) {\n  return getComputedStyle$1(element).direction === 'rtl';\n}\n\nconst platform = {\n  convertOffsetParentRelativeRectToViewportRelativeRect,\n  getDocumentElement,\n  getClippingRect,\n  getOffsetParent,\n  getElementRects,\n  getClientRects,\n  getDimensions,\n  getScale,\n  isElement,\n  isRTL\n};\n\nfunction rectsAreEqual(a, b) {\n  return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;\n}\n\n// https://samthor.au/2021/observing-dom/\nfunction observeMove(element, onMove) {\n  let io = null;\n  let timeoutId;\n  const root = getDocumentElement(element);\n  function cleanup() {\n    var _io;\n    clearTimeout(timeoutId);\n    (_io = io) == null || _io.disconnect();\n    io = null;\n  }\n  function refresh(skip, threshold) {\n    if (skip === void 0) {\n      skip = false;\n    }\n    if (threshold === void 0) {\n      threshold = 1;\n    }\n    cleanup();\n    const elementRectForRootMargin = element.getBoundingClientRect();\n    const {\n      left,\n      top,\n      width,\n      height\n    } = elementRectForRootMargin;\n    if (!skip) {\n      onMove();\n    }\n    if (!width || !height) {\n      return;\n    }\n    const insetTop = floor(top);\n    const insetRight = floor(root.clientWidth - (left + width));\n    const insetBottom = floor(root.clientHeight - (top + height));\n    const insetLeft = floor(left);\n    const rootMargin = -insetTop + \"px \" + -insetRight + \"px \" + -insetBottom + \"px \" + -insetLeft + \"px\";\n    const options = {\n      rootMargin,\n      threshold: max(0, min(1, threshold)) || 1\n    };\n    let isFirstUpdate = true;\n    function handleObserve(entries) {\n      const ratio = entries[0].intersectionRatio;\n      if (ratio !== threshold) {\n        if (!isFirstUpdate) {\n          return refresh();\n        }\n        if (!ratio) {\n          // If the reference is clipped, the ratio is 0. Throttle the refresh\n          // to prevent an infinite loop of updates.\n          timeoutId = setTimeout(() => {\n            refresh(false, 1e-7);\n          }, 1000);\n        } else {\n          refresh(false, ratio);\n        }\n      }\n      if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {\n        // It's possible that even though the ratio is reported as 1, the\n        // element is not actually fully within the IntersectionObserver's root\n        // area anymore. This can happen under performance constraints. This may\n        // be a bug in the browser's IntersectionObserver implementation. To\n        // work around this, we compare the element's bounding rect now with\n        // what it was at the time we created the IntersectionObserver. If they\n        // are not equal then the element moved, so we refresh.\n        refresh();\n      }\n      isFirstUpdate = false;\n    }\n\n    // Older browsers don't support a `document` as the root and will throw an\n    // error.\n    try {\n      io = new IntersectionObserver(handleObserve, {\n        ...options,\n        // Handle <iframe>s\n        root: root.ownerDocument\n      });\n    } catch (_e) {\n      io = new IntersectionObserver(handleObserve, options);\n    }\n    io.observe(element);\n  }\n  refresh(true);\n  return cleanup;\n}\n\n/**\n * Automatically updates the position of the floating element when necessary.\n * Should only be called when the floating element is mounted on the DOM or\n * visible on the screen.\n * @returns cleanup function that should be invoked when the floating element is\n * removed from the DOM or hidden from the screen.\n * @see https://floating-ui.com/docs/autoUpdate\n */\nfunction autoUpdate(reference, floating, update, options) {\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    ancestorScroll = true,\n    ancestorResize = true,\n    elementResize = typeof ResizeObserver === 'function',\n    layoutShift = typeof IntersectionObserver === 'function',\n    animationFrame = false\n  } = options;\n  const referenceEl = unwrapElement(reference);\n  const ancestors = ancestorScroll || ancestorResize ? [...(referenceEl ? getOverflowAncestors(referenceEl) : []), ...getOverflowAncestors(floating)] : [];\n  ancestors.forEach(ancestor => {\n    ancestorScroll && ancestor.addEventListener('scroll', update, {\n      passive: true\n    });\n    ancestorResize && ancestor.addEventListener('resize', update);\n  });\n  const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update) : null;\n  let reobserveFrame = -1;\n  let resizeObserver = null;\n  if (elementResize) {\n    resizeObserver = new ResizeObserver(_ref => {\n      let [firstEntry] = _ref;\n      if (firstEntry && firstEntry.target === referenceEl && resizeObserver) {\n        // Prevent update loops when using the `size` middleware.\n        // https://github.com/floating-ui/floating-ui/issues/1740\n        resizeObserver.unobserve(floating);\n        cancelAnimationFrame(reobserveFrame);\n        reobserveFrame = requestAnimationFrame(() => {\n          var _resizeObserver;\n          (_resizeObserver = resizeObserver) == null || _resizeObserver.observe(floating);\n        });\n      }\n      update();\n    });\n    if (referenceEl && !animationFrame) {\n      resizeObserver.observe(referenceEl);\n    }\n    resizeObserver.observe(floating);\n  }\n  let frameId;\n  let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;\n  if (animationFrame) {\n    frameLoop();\n  }\n  function frameLoop() {\n    const nextRefRect = getBoundingClientRect(reference);\n    if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) {\n      update();\n    }\n    prevRefRect = nextRefRect;\n    frameId = requestAnimationFrame(frameLoop);\n  }\n  update();\n  return () => {\n    var _resizeObserver2;\n    ancestors.forEach(ancestor => {\n      ancestorScroll && ancestor.removeEventListener('scroll', update);\n      ancestorResize && ancestor.removeEventListener('resize', update);\n    });\n    cleanupIo == null || cleanupIo();\n    (_resizeObserver2 = resizeObserver) == null || _resizeObserver2.disconnect();\n    resizeObserver = null;\n    if (animationFrame) {\n      cancelAnimationFrame(frameId);\n    }\n  };\n}\n\n/**\n * Resolves with an object of overflow side offsets that determine how much the\n * element is overflowing a given clipping boundary on each side.\n * - positive = overflowing the boundary by that number of pixels\n * - negative = how many pixels left before it will overflow\n * - 0 = lies flush with the boundary\n * @see https://floating-ui.com/docs/detectOverflow\n */\nconst detectOverflow = detectOverflow$1;\n\n/**\n * Modifies the placement by translating the floating element along the\n * specified axes.\n * A number (shorthand for `mainAxis` or distance), or an axes configuration\n * object may be passed.\n * @see https://floating-ui.com/docs/offset\n */\nconst offset = offset$1;\n\n/**\n * Optimizes the visibility of the floating element by choosing the placement\n * that has the most space available automatically, without needing to specify a\n * preferred placement. Alternative to `flip`.\n * @see https://floating-ui.com/docs/autoPlacement\n */\nconst autoPlacement = autoPlacement$1;\n\n/**\n * Optimizes the visibility of the floating element by shifting it in order to\n * keep it in view when it will overflow the clipping boundary.\n * @see https://floating-ui.com/docs/shift\n */\nconst shift = shift$1;\n\n/**\n * Optimizes the visibility of the floating element by flipping the `placement`\n * in order to keep it in view when the preferred placement(s) will overflow the\n * clipping boundary. Alternative to `autoPlacement`.\n * @see https://floating-ui.com/docs/flip\n */\nconst flip = flip$1;\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = size$1;\n\n/**\n * Provides data to hide the floating element in applicable situations, such as\n * when it is not in the same clipping context as the reference element.\n * @see https://floating-ui.com/docs/hide\n */\nconst hide = hide$1;\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = arrow$1;\n\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = inline$1;\n\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = limitShift$1;\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a given reference element.\n */\nconst computePosition = (reference, floating, options) => {\n  // This caches the expensive `getClippingElementAncestors` function so that\n  // multiple lifecycle resets re-use the same result. It only lives for a\n  // single call. If other functions become expensive, we can add them as well.\n  const cache = new Map();\n  const mergedOptions = {\n    platform,\n    ...options\n  };\n  const platformWithCache = {\n    ...mergedOptions.platform,\n    _c: cache\n  };\n  return computePosition$1(reference, floating, {\n    ...mergedOptions,\n    platform: platformWithCache\n  });\n};\n\nexport { arrow, autoPlacement, autoUpdate, computePosition, detectOverflow, flip, hide, inline, limitShift, offset, platform, shift, size };\n","export const checkPageFilter = (currentUrl, pageFilter, pageFilterType) => {\n  // If any parameter is missing, consider the filter passed.\n  if (!currentUrl || !pageFilter || !pageFilterType) {\n    return true;\n  }\n\n  // Helper to remove trailing slashes.\n  const removeTrailingSlash = (url) => url.replace(/\\/$/, '');\n\n  // Generates a regex from a match string by replacing dynamic segments (e.g., {id}).\n  const generateRegex = (match) => {\n    if (!match) return null;\n    try {\n      // If match starts with \"/\", remove it to work with Regex\n      if (match.startsWith('/')) {\n        match = match.substring(1);\n      }\n\n      // Replace dynamic patterns {anything} with a placeholder first\n      var dynamicPattern = /{\\w+}/g;\n      var regexPattern = match.replace(dynamicPattern, '___PLACEHOLDER___');\n\n      // Escape special regex characters in the URL pattern\n      regexPattern = regexPattern.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\$&');\n\n      // Replace our placeholder with the actual regex pattern\n      regexPattern = regexPattern.replace(/___PLACEHOLDER___/g, '[^&?]+');\n      var pattern = new RegExp(regexPattern, 'i');\n\n      return pattern;\n    } catch (e) {\n      return null;\n    }\n  };\n\n  // Checks if the provided URL matches the given match string.\n  const isMatchingUrl = (url, match) => {\n    if (!url || !match) return false;\n    try {\n      // First, a simple substring check.\n      if (url.includes(match)) {\n        return true;\n      }\n    } catch (e) {\n      // Continue to regex matching.\n    }\n    const regex = generateRegex(match);\n    if (!regex) return false;\n    try {\n      return regex.test(url);\n    } catch (e) {\n      return false;\n    }\n  };\n\n  let matched = false;\n\n  // Check matching based on the provided pageFilterType.\n  switch (pageFilterType) {\n    case 'is':\n      matched = removeTrailingSlash(currentUrl) === removeTrailingSlash(pageFilter);\n      break;\n    case 'isnot':\n      matched = removeTrailingSlash(currentUrl) !== removeTrailingSlash(pageFilter);\n      break;\n    case 'contains':\n      matched = isMatchingUrl(currentUrl, pageFilter);\n      break;\n    case 'startswith':\n      matched = currentUrl.startsWith(pageFilter);\n      break;\n    case 'endswith':\n      matched = currentUrl.endsWith(pageFilter);\n      break;\n    case 'notcontains':\n      matched = !isMatchingUrl(currentUrl, pageFilter);\n      break;\n    default:\n      matched = false;\n  }\n\n  return matched;\n};\n\nexport const checkPageRules = (currentUrl, action) => {\n  const rules = action.pageRules && action.pageRules.length > 0\n    ? action.pageRules\n    : (action.pageFilter ? [{ pageFilter: action.pageFilter, pageFilterType: action.pageFilterType }] : []);\n  if (rules.length === 0) return true;\n  return rules.some(r => checkPageFilter(currentUrl, r.pageFilter, r.pageFilterType));\n};\n","import { arrow, autoUpdate, computePosition, flip, offset, shift } from '@floating-ui/dom';\nimport { GleapSession } from './Gleap';\nimport { loadIcon } from './UI';\nimport { checkPageFilter, checkPageRules } from './GleapPageFilter';\n\nexport default class GleapTooltipManager {\n  tooltips = [];\n  filteredTooltips = [];\n  lastUrl = null;\n  elementToFloatingUIMap = new WeakMap();\n  elementToTooltipMap = new WeakMap();\n  nextId = 0;\n\n  // GleapTooltipManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapTooltipManager();\n      this.instance.start();\n    }\n    return this.instance;\n  }\n\n  // Recursive function to process each node and its children\n  processNodeInsertion(node) {\n    if (node.nodeType === Node.ELEMENT_NODE) {\n      // Check the node itself\n      this.checkNodeTooltip(node);\n\n      // Check all children of the node recursively\n      if (node.childNodes) {\n        node.childNodes.forEach((childNode) => {\n          this.processNodeInsertion(childNode);\n        });\n      }\n    }\n  }\n\n  // Function to check a single node against the filtered tooltips\n  checkNodeTooltip(node) {\n    if (this.filteredTooltips.length > 0) {\n      this.filteredTooltips.forEach((tooltip) => {\n        if (tooltip.selector && node.matches(tooltip.selector)) {\n          this.linkTooltip(node, tooltip);\n        }\n      });\n    }\n  }\n\n  start() {\n    const self = this;\n\n    if (!window) {\n      return;\n    }\n\n    const throttle = (fn, time) => {\n      let timeout = null;\n      return function () {\n        if (timeout) return;\n        const context = this;\n        const args = arguments;\n        const later = () => {\n          fn.call(context, ...args);\n          timeout = null;\n        };\n        timeout = setTimeout(later, time);\n      };\n    };\n\n    const handleResizeThrottled = throttle(self.updateHotspotPositions.bind(self), 250);\n    window.addEventListener('resize', handleResizeThrottled);\n\n    window.requestAnimationFrame(() => {\n      this.observer = new MutationObserver((mutations) => {\n        if (self.lastUrl !== window.location.href) {\n          self.lastUrl = window.location.href;\n          self.filteredTooltips = self.getFilteredTooltips();\n        }\n\n        mutations.forEach((mutation) => {\n          // Check for attribute changes that might affect hotspot positioning\n          if (mutation.type === 'attributes') {\n            const target = mutation.target;\n            if (target.nodeType === Node.ELEMENT_NODE) {\n              // Check if the changed element has tooltip hotspots or is a parent of tooltip elements\n              const hasTooltipHotspots =\n                target.querySelector('[data-gleap-tooltip-hotspot]') || target.hasAttribute('data-gleap-tooltip-mode');\n\n              if (hasTooltipHotspots || target.hasAttribute('data-gleap-tooltip')) {\n                self.updateHotspotPositions();\n              }\n            }\n          }\n\n          // Check for added nodes\n          mutation.addedNodes.forEach((node) => {\n            if (node.nodeType === Node.ELEMENT_NODE) {\n              self.processNodeInsertion(node);\n            }\n          });\n\n          // Check for removed nodes\n          mutation.removedNodes.forEach((node) => {\n            if (node.nodeType === Node.ELEMENT_NODE && this.elementToFloatingUIMap.has(node)) {\n              const floatingUI = this.elementToFloatingUIMap.get(node);\n              if (floatingUI) {\n                if (floatingUI.tooltip) {\n                  floatingUI.tooltip.remove();\n                }\n                floatingUI.cleanup();\n\n                this.elementToFloatingUIMap.delete(node);\n              }\n            }\n\n            if (this.elementToTooltipMap.has(node)) {\n              this.elementToTooltipMap.delete(node);\n            }\n          });\n        });\n      });\n\n      // Start observing the document for changes.\n      this.observer.observe(document.body, {\n        childList: true,\n        subtree: true,\n        attributes: true,\n        attributeFilter: ['style', 'class'],\n      });\n    });\n  }\n\n  updateHotspotPositions() {\n    const elements = document.querySelectorAll(`[data-gleap-tooltip-mode='hotspot']`);\n    elements.forEach((element) => {\n      const tooltip = this.elementToTooltipMap.get(element);\n      if (tooltip) {\n        this.repositionHotspot(element, tooltip);\n      }\n    });\n  }\n\n  createTooltip(element, tooltipText, tooltipData) {\n    // Create tooltip element\n    const tooltip = document.createElement('div');\n    tooltip.className = 'gleap-tooltip';\n    tooltip.innerHTML = `<div class=\"gleap-tooltip-inner\">\n            ${tooltipText}\n            <div class=\"gleap-tooltip-arrow\">\n                <svg width=\"116\" height=\"56\" viewBox=\"0 0 116 56\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n                    <path d=\"M57.75 0.74998L115.5 0.680177L66.8726 49.3076C61.7958 54.3844 53.5646 54.3844 48.4878 49.3076L4.05618e-05 0.819784L57.75 0.74998Z\" fill=\"white\"/>\n                </svg>\n            </div>\n        </div>`;\n    document.body.appendChild(tooltip);\n\n    // Create a Popper instance with arrow and offset\n\n    const arrowEl = tooltip.querySelector('.gleap-tooltip-arrow');\n    const cleanup = autoUpdate(element, tooltip, () => {\n      computePosition(element, tooltip, {\n        placement: tooltipData.posX === 'left' ? 'left' : 'right',\n        middleware: [offset(10), flip(), shift(), arrow({ element: arrowEl })],\n      }).then(({ x, y, middlewareData, placement }) => {\n        try {\n          Object.assign(tooltip.style, {\n            left: `${x}px`,\n            top: `${y}px`,\n          });\n\n          if (middlewareData.arrow) {\n            let arrowSize = 20; // Arrow size should be consistent with the border width used in CSS\n            let arrowPos = { left: '', top: '', transform: '' };\n\n            if (middlewareData.arrow.x != null) {\n              arrowPos.left = `${middlewareData.arrow.x}px`;\n              if (placement === 'bottom') {\n                arrowPos.transform = 'translateY(-7px) rotate(180deg)';\n                arrowPos.top = `${-arrowSize}px`; // Move arrow outside the tooltip\n              } else if (placement === 'top') {\n                arrowPos.transform = 'translateY(7px) rotate(0deg)';\n                arrowPos.top = `100%`; // Adjust based on the tooltip's height\n              }\n            }\n            if (middlewareData.arrow.y != null) {\n              arrowPos.top = `${middlewareData.arrow.y}px`;\n              if (placement === 'right') {\n                arrowPos.transform = 'translateX(-7px) rotate(90deg)';\n                arrowPos.left = `${-arrowSize}px`; // Move arrow outside the tooltip\n              } else if (placement === 'left') {\n                arrowPos.transform = 'translateX(7px) rotate(270deg)';\n                arrowPos.left = `100%`; // Adjust based on the tooltip's width\n              }\n            }\n            // Apply the computed styles to the arrow\n            Object.assign(arrowEl.style, arrowPos);\n          }\n        } catch (exp) {}\n      });\n    });\n\n    let hideTimeout;\n\n    function show() {\n      clearTimeout(hideTimeout);\n      tooltip.style.visibility = 'visible';\n      tooltip.style.opacity = '1';\n      tooltip.style.pointerEvents = 'auto';\n    }\n\n    function hide() {\n      hideTimeout = setTimeout(() => {\n        tooltip.style.opacity = '0';\n\n        setTimeout(() => {\n          tooltip.style.visibility = 'hidden';\n          tooltip.style.pointerEvents = 'none';\n        }, 200);\n      }, 500);\n    }\n\n    // Event listeners to show/hide the tooltip\n    element.addEventListener('mouseenter', show);\n    element.addEventListener('mouseleave', hide);\n    tooltip.addEventListener('mouseenter', show);\n    tooltip.addEventListener('mouseleave', hide);\n\n    element.addEventListener('click', hide);\n    tooltip.addEventListener('click', hide);\n\n    return {\n      cleanup,\n      tooltip,\n    };\n  }\n\n  canEmbed(element) {\n    const voidElements = new Set(['area', 'base', 'br', 'embed', 'hr', 'img', 'input', 'source', 'track', 'wbr', 'canvas']);\n\n    return element && !voidElements.has(element.tagName.toLowerCase());\n  }\n\n  linkTooltip = (element, tooltip) => {\n    if (element.hasAttribute('data-gleap-tooltip')) {\n      return;\n    }\n\n    const nextId = this.nextId++;\n    element.setAttribute('data-gleap-tooltip', nextId);\n    if (element) {\n      var tooltipElem = null;\n\n      if (tooltip.mode === 'hotspot') {\n        // Create hotspot container.\n        const hotspotContainer = document.createElement('div');\n        hotspotContainer.setAttribute('data-gleap-tooltip-anchor', nextId);\n        hotspotContainer.classList.add('gleap-tooltip-anchor');\n        element.setAttribute('data-gleap-tooltip-mode', 'hotspot');\n\n        if (this.canEmbed(element)) {\n          if (element.firstChild) {\n            element.insertBefore(hotspotContainer, element.firstChild);\n          } else {\n            element.appendChild(hotspotContainer);\n          }\n        } else {\n          element.parentNode.insertBefore(hotspotContainer, element.nextSibling);\n        }\n\n        // Create hotspot.\n        const hotspot = document.createElement('div');\n        hotspot.classList.add('gleap-tooltip-hotspot');\n        hotspot.setAttribute('data-gleap-tooltip-hotspot', nextId);\n\n        hotspot.innerHTML = `${loadIcon(tooltip.icon, tooltip.color)}${\n          tooltip.animated\n            ? `<div style=\"background-color: ${tooltip.color}\" class=\"gleap-tooltip-hotspot-animation\"></div>`\n            : ''\n        }`;\n        hotspotContainer.appendChild(hotspot);\n\n        // Update hotspot position.\n        this.repositionHotspot(element, tooltip);\n\n        tooltipElem = hotspot;\n        this.elementToTooltipMap.set(element, tooltip);\n      } else {\n        tooltipElem = element;\n      }\n\n      const floatingUIInstance = this.createTooltip(tooltipElem, tooltip.html, tooltip);\n\n      this.elementToFloatingUIMap.set(element, floatingUIInstance);\n    }\n  };\n\n  destroy() {\n    // Disconnect the MutationObserver if it exists.\n    if (this.observer) {\n      this.observer.disconnect();\n      this.observer = null;\n    }\n\n    // Remove the window resize event listener if it was stored.\n    // (In start() you can assign the listener to a class property, e.g., this.resizeListener.)\n    if (this.resizeListener) {\n      window.removeEventListener('resize', this.resizeListener);\n      this.resizeListener = null;\n    }\n\n    // Remove all tooltip elements created by Gleap.\n    const tooltipElements = document.querySelectorAll('.gleap-tooltip');\n    tooltipElements.forEach((tooltip) => tooltip.remove());\n\n    // Remove any tooltip anchors and hotspots.\n    const anchors = document.querySelectorAll('[data-gleap-tooltip-anchor]');\n    anchors.forEach((anchor) => anchor.remove());\n    const hotspots = document.querySelectorAll('[data-gleap-tooltip-hotspot]');\n    hotspots.forEach((hotspot) => hotspot.remove());\n\n    // Remove all attributes from elements.\n    const elements = document.querySelectorAll('[data-gleap-tooltip]');\n    elements.forEach((element) => element.removeAttribute('data-gleap-tooltip'));\n\n    // Remove all attributes from elements.\n    const modeElements = document.querySelectorAll('[data-gleap-tooltip-mode]');\n    modeElements.forEach((element) => element.removeAttribute('data-gleap-tooltip-mode'));\n\n    // Clear internal references.\n    this.elementToFloatingUIMap = new WeakMap();\n    this.elementToTooltipMap = new WeakMap();\n    this.tooltips = [];\n    this.filteredTooltips = [];\n  }\n\n  repositionHotspot(element, tooltip) {\n    if (!element || !tooltip) {\n      return;\n    }\n\n    const tooltipId = element.getAttribute('data-gleap-tooltip');\n    if (!tooltipId) {\n      return;\n    }\n\n    const hotspot = document.querySelector(`[data-gleap-tooltip-hotspot=\"${tooltipId}\"]`);\n    if (!hotspot) {\n      return;\n    }\n\n    if (!tooltip.posX) {\n      tooltip.posX = 'right';\n    }\n    if (!tooltip.posY) {\n      tooltip.posY = 'center';\n    }\n    if (!tooltip.offsetX) {\n      tooltip.offsetX = 4;\n    }\n    if (!tooltip.offsetY) {\n      tooltip.offsetY = 0;\n    }\n\n    var elementRect = element.getBoundingClientRect();\n\n    try {\n      // Improve width calculation for text elements.\n      var range = document.createRange();\n      range.selectNodeContents(element);\n      const style = window.getComputedStyle(element);\n      const fixedWidth = range.getBoundingClientRect().width + parseFloat(style.paddingLeft);\n      if (fixedWidth < elementRect.width) {\n        elementRect.width = fixedWidth;\n      }\n    } catch (exp) {}\n\n    const anchorElement = document.querySelector(`[data-gleap-tooltip-anchor=\"${tooltipId}\"]`);\n    const anchorRect = anchorElement.getBoundingClientRect();\n\n    // Offset calculation for hotspot position.\n    const offsetX = anchorRect.left - elementRect.left;\n    const offsetY = anchorRect.top - elementRect.top;\n\n    let top = 0;\n    let left = 0;\n    let tooltipSize = 17 / 2;\n\n    switch (tooltip.posX) {\n      case 'left':\n        left = (tooltip.offsetX + tooltipSize * 2) * -1;\n        break;\n      case 'right':\n        left = elementRect.width + tooltip.offsetX;\n        break;\n    }\n\n    switch (tooltip.posY) {\n      case 'top':\n        top = 0 + tooltip.offsetY;\n        break;\n      case 'bottom':\n        top = elementRect.height - tooltipSize * 2 + tooltip.offsetY;\n        break;\n      case 'center':\n        top = elementRect.height / 2 - tooltipSize + tooltip.offsetY;\n        break;\n    }\n\n    if (hotspot) {\n      hotspot.style.position = 'absolute';\n      hotspot.style.top = top - offsetY + 'px';\n      hotspot.style.left = left - offsetX + 'px';\n    }\n  }\n\n  updateFilteredTooltips = () => {\n    this.filteredTooltips = this.getFilteredTooltips();\n    this.checkForTooltips();\n  };\n\n  getFilteredTooltips = () => {\n    if (!this.tooltips) {\n      return [];\n    }\n\n    const currentUrl = window.location.href;\n\n    return this.tooltips.filter((tooltip) => {\n      if (tooltip.pageRules && tooltip.pageRules.length > 0) {\n        return checkPageRules(currentUrl, { pageRules: tooltip.pageRules });\n      }\n\n      if (!tooltip.page || tooltip.page.length === 0) {\n        return true;\n      }\n\n      const passed = checkPageFilter(currentUrl, tooltip.page, tooltip.pageType);\n\n      if (!passed) {\n        return false;\n      }\n      return true;\n    });\n  };\n\n  checkForTooltips = () => {\n    for (let i = 0; i < this.filteredTooltips.length; i++) {\n      const tooltip = this.filteredTooltips[i];\n\n      try {\n        const elements = document.querySelectorAll(tooltip.selector);\n\n        for (let j = 0; j < elements.length; j++) {\n          const element = elements[j];\n\n          if (element) {\n            this.linkTooltip(element, tooltip);\n          }\n        }\n      } catch (exp) {}\n    }\n  };\n\n  load = () => {\n    const self = this;\n    const sessionInstance = GleapSession.getInstance();\n\n    const http = new XMLHttpRequest();\n    http.open('GET', sessionInstance.apiUrl + '/config/' + sessionInstance.sdkKey + '/tooltips');\n    http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n    http.setRequestHeader('Api-Token', sessionInstance.sdkKey);\n    try {\n      http.setRequestHeader('Gleap-Id', sessionInstance.session.gleapId);\n      http.setRequestHeader('Gleap-Hash', sessionInstance.session.gleapHash);\n    } catch (exp) {}\n\n    http.onerror = () => {\n      console.error('Failed to fetch tooltips');\n    };\n    http.onreadystatechange = function (e) {\n      if (http.readyState === 4) {\n        if (http.status === 200) {\n          try {\n            self.tooltips = JSON.parse(http.responseText);\n            self.updateFilteredTooltips();\n          } catch (exp) {\n            console.error('Failed to parse tooltips', exp);\n          }\n        }\n      }\n    };\n\n    http.send();\n  };\n}\n","import ChecklistNetworkManager from './ChecklistNetworkManager';\nimport AgentNetworkManager from './AgentNetworkManager';\nimport {\n  GleapBannerManager,\n  GleapEventManager,\n  GleapFrameManager,\n  GleapModalManager,\n  GleapNotificationManager,\n  GleapStreamedEvent,\n  GleapTranslationManager,\n} from './Gleap';\nimport {\n  eraseGleapCookie,\n  getDeviceType,\n  getGleapCookie,\n  loadFromGleapCache,\n  saveToGleapCache,\n  setGleapCookie,\n} from './GleapHelper';\nimport GleapTooltipManager from './GleapTooltipManager';\n\nexport default class GleapSession {\n  apiUrl = 'https://api.gleap.io';\n  wsApiUrl = 'wss://ws.gleap.io';\n  sdkKey = null;\n  updatingSession = false;\n  useCookies = true;\n  localStorageDisabled = false;\n  session = {\n    gleapId: null,\n    gleapHash: null,\n    name: '',\n    email: '',\n    userId: '',\n    phone: '',\n    value: 0,\n  };\n  ready = false;\n  onSessionReadyListener = [];\n\n  // GleapSession singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapSession();\n      return this.instance;\n    } else {\n      return this.instance;\n    }\n  }\n\n  /**\n   * Returns the current session name.\n   * @returns string\n   */\n  getName() {\n    try {\n      return this.session.name ? this.session.name.split(' ')[0].split('@')[0].split('.')[0].split('+')[0] : '';\n    } catch (exp) {\n      return this.session.name;\n    }\n  }\n\n  /**\n   * Returns the Gleap session object.\n   * @returns\n   */\n  getSession() {\n    return this.session;\n  }\n\n  /**\n   * Returns the Gleap session object.\n   * @returns\n   */\n  getGleapId() {\n    if (this.session && this.session.gleapId) {\n      return this.session.gleapId;\n    }\n\n    return null;\n  }\n\n  /**\n   * Determines if the current session is a identified user.\n   * @returns boolean\n   */\n  isUser() {\n    if (this.session && this.session.userId) {\n      return true;\n    }\n    return false;\n  }\n\n  constructor() {}\n\n  setOnSessionReady = (onSessionReady) => {\n    if (this.ready) {\n      onSessionReady();\n    } else {\n      this.onSessionReadyListener.push(onSessionReady);\n    }\n  };\n\n  injectSession = (http) => {\n    if (http && this.session) {\n      http.setRequestHeader('Api-Token', this.sdkKey);\n      http.setRequestHeader('Gleap-Id', this.session.gleapId);\n      http.setRequestHeader('Gleap-Hash', this.session.gleapHash);\n    }\n  };\n\n  clearSession = (attemp = 0, retry = true) => {\n    if (this.session && this.session.gleapHash) {\n      GleapEventManager.notifyEvent('unregister-pushmessage-group', `gleapuser-${this.session.gleapHash}`);\n    }\n\n    try {\n      saveToGleapCache(`session-${this.sdkKey}`, null);\n    } catch (exp) {}\n\n    if (this.useCookies) {\n      try {\n        eraseGleapCookie(`session-${this.sdkKey}`);\n      } catch (exp) {}\n    }\n\n    this.ready = false;\n    this.session = {\n      gleapId: null,\n      gleapHash: null,\n      name: '',\n      email: '',\n      userId: '',\n      phone: '',\n      value: 0,\n    };\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'session-cleared',\n      },\n      true\n    );\n    GleapNotificationManager.getInstance().clearAllNotifications(false);\n    GleapNotificationManager.getInstance().setNotificationCount(0);\n    GleapBannerManager.getInstance().removeBannerUI();\n    GleapModalManager.getInstance().hideModal();\n\n    if (retry) {\n      if (!isNaN(attemp)) {\n        // Exponentially retry to renew session.\n        const newTimeout = Math.pow(attemp, 2) * 10;\n        setTimeout(() => {\n          this.startSession(attemp + 1);\n        }, newTimeout * 1000);\n      }\n    }\n  };\n\n  validateSession = (session) => {\n    if (!session || !session.gleapId) {\n      return;\n    }\n\n    let sessionChanged = false;\n    if (this.session?.gleapId !== session?.gleapId) {\n      sessionChanged = true;\n    }\n\n    // Unregister previous group.\n    if (this.session && this.session.gleapHash) {\n      GleapEventManager.notifyEvent('unregister-pushmessage-group', `gleapuser-${this.session.gleapHash}`);\n    }\n\n    if (!this.localStorageDisabled) {\n      saveToGleapCache(`session-${this.sdkKey}`, session);\n    }\n    if (this.useCookies) {\n      setGleapCookie(`session-${this.sdkKey}`, encodeURIComponent(JSON.stringify(session)), 365);\n    }\n\n    this.session = session;\n    this.ready = true;\n\n    // Register new push group.\n    if (this.session && this.session.gleapHash) {\n      GleapEventManager.notifyEvent('register-pushmessage-group', `gleapuser-${this.session.gleapHash}`);\n    }\n\n    if (sessionChanged) {\n      // Load tooltips.\n      setTimeout(() => {\n        // Clear cache first, as the session context has changed.\n        ChecklistNetworkManager.getInstance().clearCache();\n        AgentNetworkManager.getInstance().clearCache();\n\n        // Initially track.\n        GleapStreamedEvent.getInstance().restart();\n\n        const tooltipManager = GleapTooltipManager.getInstance();\n        if (tooltipManager) {\n          try {\n            tooltipManager.destroy();\n          } catch (exp) {}\n\n          tooltipManager.load();\n        }\n      }, 0);\n\n      if (typeof window.dispatchEvent === 'function') {\n        window.dispatchEvent(new CustomEvent('session-updated'));\n      }\n    }\n\n    this.notifySessionReady();\n  };\n\n  startSession = (attemp = 0) => {\n    // Check if we already have a session cookie.\n    try {\n      if (this.useCookies) {\n        const sessionCookie = getGleapCookie(`session-${this.sdkKey}`);\n        if (sessionCookie) {\n          const sessionData = JSON.parse(decodeURIComponent(sessionCookie));\n          this.validateSession(sessionData);\n        }\n      }\n    } catch (exp) {}\n\n    // Try to load session from local storage, if not already loaded.\n    if (!this.localStorageDisabled && !(this.session && this.session.gleapId && this.session.gleapId.length > 0)) {\n      const cachedSession = loadFromGleapCache(`session-${this.sdkKey}`);\n      if (cachedSession) {\n        this.validateSession(cachedSession);\n      }\n    }\n\n    const self = this;\n    const http = new XMLHttpRequest();\n    http.open('POST', self.apiUrl + '/sessions');\n    http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n    http.setRequestHeader('Api-Token', self.sdkKey);\n    try {\n      if (this.session && this.session.gleapId && this.session.gleapHash) {\n        http.setRequestHeader('Gleap-Id', this.session.gleapId);\n        http.setRequestHeader('Gleap-Hash', this.session.gleapHash);\n      }\n    } catch (exp) {}\n    http.onreadystatechange = function (e) {\n      if (http.readyState === 4) {\n        if (http.status === 200 || http.status === 201) {\n          try {\n            const sessionData = JSON.parse(http.responseText);\n            self.validateSession(sessionData);\n          } catch (exp) {}\n        } else {\n          if (http.status !== 429) {\n            self.clearSession(attemp, true);\n          }\n        }\n      }\n    };\n    http.send(\n      JSON.stringify({\n        lang: GleapTranslationManager.getInstance().getActiveLanguage(),\n        deviceType: getDeviceType(),\n        platform: 'web',\n      })\n    );\n  };\n\n  notifySessionReady() {\n    if (this.onSessionReadyListener.length > 0) {\n      for (var i = 0; i < this.onSessionReadyListener.length; i++) {\n        this.onSessionReadyListener[i]();\n      }\n    }\n    this.onSessionReadyListener = [];\n\n    // Send session update to frame.\n    GleapFrameManager.getInstance().sendSessionUpdate();\n  }\n\n  checkIfSessionNeedsUpdate = (userId, userData) => {\n    if (!this.session || !this.session.userId || !userId) {\n      return true;\n    }\n\n    try {\n      if (this.session.userId.toString() !== userId.toString()) {\n        return true;\n      }\n    } catch (exp) {}\n\n    return this.checkIfSessionDataNeedsUpdate(userData);\n  };\n\n  checkIfSessionDataNeedsUpdate = (userData) => {\n    if (userData) {\n      var userDataKeys = Object.keys(userData);\n      for (var i = 0; i < userDataKeys.length; i++) {\n        var userDataKey = userDataKeys[i];\n        if (JSON.stringify(this.session[userDataKey]) !== JSON.stringify(userData[userDataKey])) {\n          // Check custom data for a match.\n          if (\n            !(\n              this.session.customData &&\n              JSON.stringify(this.session.customData[userDataKey]) === JSON.stringify(userData[userDataKey])\n            )\n          ) {\n            return true;\n          }\n        }\n      }\n    }\n\n    return false;\n  };\n\n  updateSession = (userData) => {\n    // Check if session needs update.\n    const sessionNeedsUpdate = this.checkIfSessionDataNeedsUpdate(userData);\n    if (!sessionNeedsUpdate) {\n      return;\n    }\n\n    const self = this;\n    return new Promise((resolve, reject) => {\n      // Wait for gleap session to be ready.\n      this.setOnSessionReady(function () {\n        if (!self.session.gleapId || !self.session.gleapHash) {\n          return reject('Session not ready yet.');\n        }\n\n        const http = new XMLHttpRequest();\n        http.open('POST', self.apiUrl + '/sessions/partialupdate');\n        http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n        http.setRequestHeader('Api-Token', self.sdkKey);\n        try {\n          http.setRequestHeader('Gleap-Id', self.session.gleapId);\n          http.setRequestHeader('Gleap-Hash', self.session.gleapHash);\n        } catch (exp) {}\n\n        http.onerror = () => {\n          reject();\n        };\n        http.onreadystatechange = function (e) {\n          if (http.readyState === 4) {\n            if (http.status === 200 || http.status === 201) {\n              try {\n                const sessionData = JSON.parse(http.responseText);\n                self.validateSession(sessionData);\n                resolve(sessionData);\n              } catch (exp) {\n                reject(exp);\n              }\n            } else {\n              reject();\n            }\n          }\n        };\n\n        http.send(\n          JSON.stringify({\n            data: {\n              ...userData,\n              lang: GleapTranslationManager.getInstance().getActiveLanguage(),\n              deviceType: getDeviceType(),\n              platform: 'web',\n            },\n            type: 'js',\n            sdkVersion: SDK_VERSION,\n            ws: true,\n          })\n        );\n      });\n    });\n  };\n\n  identifySession = (userId, userData, userHash) => {\n    const sessionNeedsUpdate = this.checkIfSessionNeedsUpdate(userId, userData);\n    if (!sessionNeedsUpdate) {\n      return;\n    }\n\n    const self = this;\n    return new Promise((resolve, reject) => {\n      // Wait for gleap session to be ready.\n      this.setOnSessionReady(function () {\n        if (!self.session.gleapId || !self.session.gleapHash) {\n          return reject('Session not ready yet.');\n        }\n\n        const http = new XMLHttpRequest();\n        http.open('POST', self.apiUrl + '/sessions/identify');\n        http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n        http.setRequestHeader('Api-Token', self.sdkKey);\n        try {\n          http.setRequestHeader('Gleap-Id', self.session.gleapId);\n          http.setRequestHeader('Gleap-Hash', self.session.gleapHash);\n        } catch (exp) {}\n\n        http.onerror = () => {\n          reject();\n        };\n        http.onreadystatechange = function (e) {\n          if (http.readyState === 4) {\n            if (http.status === 200 || http.status === 201) {\n              try {\n                const sessionData = JSON.parse(http.responseText);\n                self.validateSession(sessionData);\n                resolve(sessionData);\n              } catch (exp) {\n                reject(exp);\n              }\n            } else {\n              reject();\n            }\n          }\n        };\n\n        var dataToSend = {\n          ...userData,\n        };\n\n        if (userData.customData) {\n          delete dataToSend['customData'];\n          dataToSend = {\n            ...dataToSend,\n            ...userData.customData,\n          };\n        }\n\n        http.send(\n          JSON.stringify({\n            ...dataToSend,\n            userId,\n            userHash,\n            lang: GleapTranslationManager.getInstance().getActiveLanguage(),\n            deviceType: getDeviceType(),\n            platform: 'web',\n          })\n        );\n      });\n    });\n  };\n\n  startProductTourConfig = (tourId) => {\n    const self = this;\n    return new Promise((resolve, reject) => {\n      this.setOnSessionReady(function () {\n        if (!self.session.gleapId || !self.session.gleapHash) {\n          return reject('Session not ready yet.');\n        }\n\n        const http = new XMLHttpRequest();\n        http.open('POST', self.apiUrl + '/outbound/producttours');\n        http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n        http.setRequestHeader('Api-Token', self.sdkKey);\n        try {\n          http.setRequestHeader('Gleap-Id', self.session.gleapId);\n          http.setRequestHeader('Gleap-Hash', self.session.gleapHash);\n        } catch (exp) {}\n\n        http.onerror = () => {\n          reject();\n        };\n        http.onreadystatechange = function (e) {\n          if (http.readyState === 4) {\n            if (http.status === 200 || http.status === 201) {\n              try {\n                const tourData = JSON.parse(http.responseText);\n                if (tourData && tourData.config) {\n                  resolve(tourData.config);\n                }\n              } catch (exp) {\n                reject(exp);\n              }\n            } else {\n              reject();\n            }\n          }\n        };\n        http.send(\n          JSON.stringify({\n            outboundId: tourId,\n          })\n        );\n      });\n    });\n  };\n\n  validateProductTour = (tourId) => {\n    const self = this;\n    return new Promise((resolve, reject) => {\n      this.setOnSessionReady(function () {\n        if (!self.session.gleapId || !self.session.gleapHash) {\n          return reject('Session not ready yet.');\n        }\n\n        const http = new XMLHttpRequest();\n        http.open('POST', self.apiUrl + '/outbound/producttourvalidation');\n        http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n        http.setRequestHeader('Api-Token', self.sdkKey);\n        try {\n          http.setRequestHeader('Gleap-Id', self.session.gleapId);\n          http.setRequestHeader('Gleap-Hash', self.session.gleapHash);\n        } catch (exp) {}\n\n        http.onerror = () => {\n          reject();\n        };\n        http.onreadystatechange = function (e) {\n          if (http.readyState === 4) {\n            if (http.status === 200 || http.status === 201) {\n              try {\n                const tourData = JSON.parse(http.responseText);\n                if (tourData && tourData.status === 'live' && tourData.passedPageFilter) {\n                  resolve(tourData.config);\n                } else {\n                  reject();\n                }\n              } catch (exp) {\n                reject(exp);\n              }\n            } else {\n              reject();\n            }\n          }\n        };\n        http.send(\n          JSON.stringify({\n            outboundId: tourId,\n            currentUrl: window?.location?.href,\n          })\n        );\n      });\n    });\n  };\n}\n","import Gleap, {\n  GleapFrameManager,\n  GleapMetaDataManager,\n  GleapAiChatbarManager,\n  GleapNotificationManager,\n  GleapSession,\n  GleapAdminManager,\n  GleapEventManager,\n} from './Gleap';\nimport { gleapDataParser } from './GleapHelper';\n\nexport default class GleapStreamedEvent {\n  eventArray = [];\n  streamedEventArray = [];\n  eventMaxLength = 500;\n  errorCount = 0;\n  streamingEvents = false;\n  lastUrl = undefined;\n  mainLoopTimeout = null;\n  socket = null;\n  connectedWebSocketGleapId = null;\n  connectionTimeout = null;\n  pingWS = null;\n  handleOpenBound = null;\n  handleErrorBound = null;\n  handleMessageBound = null;\n  handleCloseBound = null;\n\n  // GleapStreamedEvent singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapStreamedEvent();\n      return this.instance;\n    } else {\n      return this.instance;\n    }\n  }\n\n  constructor() {\n    this.handleOpenBound = this.handleOpen.bind(this);\n    this.handleErrorBound = this.handleError.bind(this);\n    this.handleMessageBound = this.handleMessage.bind(this);\n    this.handleCloseBound = this.handleClose.bind(this);\n  }\n\n  cleanupWebSocket() {\n    if (this.connectionTimeout) {\n      clearTimeout(this.connectionTimeout);\n      this.connectionTimeout = null;\n    }\n\n    if (this.pingWS) {\n      clearInterval(this.pingWS);\n    }\n\n    if (this.socket) {\n      this.socket.removeEventListener('open', this.handleOpenBound);\n      this.socket.removeEventListener('error', this.handleErrorBound);\n      this.socket.removeEventListener('message', this.handleMessageBound);\n      this.socket.removeEventListener('close', this.handleCloseBound);\n      this.socket.close();\n      this.socket = null;\n    }\n  }\n\n  initWebSocket() {\n    this.cleanupWebSocket();\n\n    this.connectedWebSocketGleapId = GleapSession.getInstance().session.gleapId;\n\n    if (!GleapSession.getInstance().session || !GleapSession.getInstance().sdkKey) {\n      return;\n    }\n\n    this.socket = new WebSocket(\n      `${GleapSession.getInstance().wsApiUrl}?gleapId=${\n        GleapSession.getInstance().session.gleapId\n      }&gleapHash=${GleapSession.getInstance().session.gleapHash}&apiKey=${\n        GleapSession.getInstance().sdkKey\n      }&sdkVersion=${SDK_VERSION}`\n    );\n    this.socket.addEventListener('open', this.handleOpenBound);\n    this.socket.addEventListener('message', this.handleMessageBound);\n    this.socket.addEventListener('error', this.handleErrorBound);\n    this.socket.addEventListener('close', this.handleCloseBound);\n  }\n\n  handleOpen(event) {\n    this.pingWS = setInterval(() => {\n      if (this.socket.readyState === this.socket.OPEN) {\n        this.socket.send('PING');\n        this.socket.send(0x9);\n      }\n    }, 10000);\n\n    if (this.connectionTimeout) {\n      clearTimeout(this.connectionTimeout);\n      this.connectionTimeout = null;\n    }\n  }\n\n  handleMessage(event) {\n    this.processMessage(JSON.parse(event.data));\n  }\n\n  handleError(error) {}\n\n  handleClose(event) {\n    setTimeout(() => {\n      this.initWebSocket();\n    }, 5000);\n  }\n\n  processMessage(message) {\n    try {\n      if (GleapAdminManager.getInstance().initialized) {\n        return;\n      }\n\n      if (message.name === 'update') {\n        const { a, u, ai } = message.data;\n\n        const isOpened = GleapFrameManager.getInstance().isOpened();\n\n        if (a) {\n          const listOfActionsWhereIgnoreOpened = ['banner', 'modal'];\n          const filteredActions = a.filter(\n            (action) => !isOpened || listOfActionsWhereIgnoreOpened.includes(action?.actionType?.toLowerCase())\n          );\n\n          Gleap.getInstance().performActions(filteredActions);\n        }\n\n        if (ai) {\n          GleapAiChatbarManager.getInstance().setConfig({\n            enabled: ai.e ?? false,\n            placeholder: ai.p,\n            quickActions: ai.a,\n            style: ai.s,\n            agentId: ai.g,\n            agentName: ai.n,\n          });\n        }\n\n        if (u != null) {\n          GleapNotificationManager.getInstance().setNotificationCount(u);\n        }\n      }\n\n      if (message.name === 'checklist' && message?.data && window) {\n        const checklistData = message.data;\n        const completedSteps = checklistData.completedSteps ?? [];\n        const completedStepsBefore = checklistData.completedStepsBefore ?? [];\n        if (completedSteps.length > completedStepsBefore.length) {\n          for (let i = 0; i < completedSteps.length; i++) {\n            const step = checklistData?.steps?.find((step) => step.id === completedSteps[i]);\n            if (!step) {\n              continue;\n            }\n            const stepIndex = i;\n            if (!completedStepsBefore.includes(step)) {\n              GleapEventManager.notifyEvent('checklist-step-completed', {\n                checklistId: checklistData.id,\n                outboundId: checklistData.outboundId,\n                stepId: step.id,\n                stepIndex: stepIndex,\n                step: step,\n                completedSteps: checklistData.completedSteps,\n                status: checklistData.status,\n                data: checklistData,\n              });\n            }\n          }\n        }\n        if (checklistData.status === 'done') {\n          GleapEventManager.notifyEvent('checklist-completed', {\n            checklistId: checklistData.id,\n            outboundId: checklistData.outboundId,\n            completedSteps: checklistData.completedSteps,\n            status: checklistData.status,\n            data: checklistData,\n          });\n        }\n        if (typeof window.dispatchEvent === 'function') {\n          window.dispatchEvent(new CustomEvent('checkListUpdate', { detail: message.data }));\n        }\n      }\n    } catch (exp) {}\n  }\n\n  getEventArray() {\n    return this.eventArray;\n  }\n\n  stop() {\n    this.cleanupMainLoop();\n  }\n\n  resetErrorCountLoop() {\n    setInterval(() => {\n      this.errorCount = 0;\n    }, 60000);\n  }\n\n  cleanupMainLoop() {\n    if (this.mainLoopTimeout) {\n      clearInterval(this.mainLoopTimeout);\n      this.mainLoopTimeout = null;\n    }\n  }\n\n  restart() {\n    // Only reconnect websockets when needed.\n    if (this.connectedWebSocketGleapId !== GleapSession.getInstance().session.gleapId) {\n      this.initWebSocket();\n    }\n\n    this.cleanupMainLoop();\n    this.trackInitialEvents();\n    this.runEventStreamLoop();\n  }\n\n  start() {\n    this.startPageListener();\n    this.resetErrorCountLoop();\n  }\n\n  trackInitialEvents() {\n    GleapStreamedEvent.getInstance().logEvent('sessionStarted');\n    GleapStreamedEvent.getInstance().logCurrentPage();\n  }\n\n  logCurrentPage() {\n    if (Gleap.getInstance().disablePageTracking) {\n      return;\n    }\n\n    const currentUrl = window.location.href;\n    if (currentUrl && currentUrl !== this.lastUrl) {\n      this.lastUrl = currentUrl;\n      this.logEvent('pageView', {\n        page: currentUrl,\n      });\n    }\n  }\n\n  startPageListener() {\n    const self = this;\n    setInterval(function () {\n      self.logCurrentPage();\n    }, 1000);\n  }\n\n  logEvent(name, data) {\n    var log = {\n      name,\n      date: new Date(),\n    };\n    if (data) {\n      log.data = gleapDataParser(data);\n    }\n    this.eventArray.push(log);\n    this.streamedEventArray.push(log);\n\n    // Check max size of event log\n    if (this.eventArray.length > this.eventMaxLength) {\n      this.eventArray.shift();\n    }\n\n    // Check max size of streamed event log\n    if (this.streamedEventArray.length > this.eventMaxLength) {\n      this.streamedEventArray.shift();\n    }\n  }\n\n  runEventStreamLoop = () => {\n    const self = this;\n    this.streamEvents();\n\n    this.mainLoopTimeout = setTimeout(function () {\n      self.runEventStreamLoop();\n    }, 2500);\n  };\n\n  streamEvents = () => {\n    if (!GleapSession.getInstance().ready || this.streamingEvents || this.errorCount > 2) {\n      return;\n    }\n\n    // Nothing to stream.\n    if (this.streamedEventArray.length === 0) {\n      return;\n    }\n\n    // Sockets not connected.\n    if (!this.socket || this.socket.readyState !== this.socket.OPEN) {\n      return;\n    }\n\n    const self = this;\n    this.streamingEvents = true;\n\n    const http = new XMLHttpRequest();\n    http.open('POST', GleapSession.getInstance().apiUrl + '/sessions/events');\n    http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n    GleapSession.getInstance().injectSession(http);\n    http.onerror = () => {\n      self.errorCount++;\n      self.streamingEvents = false;\n    };\n    http.onreadystatechange = function (e) {\n      if (http.readyState === 4) {\n        if (http.status === 200 || http.status === 201) {\n          self.errorCount = 0;\n        } else {\n          self.errorCount++;\n        }\n\n        self.streamingEvents = false;\n      }\n    };\n\n    const sessionDuration = GleapMetaDataManager.getInstance().getSessionDuration();\n    http.send(\n      JSON.stringify({\n        time: sessionDuration,\n        events: this.streamedEventArray,\n        opened: GleapFrameManager.getInstance().isOpened(),\n        type: 'js',\n        sdkVersion: SDK_VERSION,\n        ws: true,\n      })\n    );\n\n    this.streamedEventArray = [];\n  };\n}\n","import { loadFromGleapCache, saveToGleapCache, clearGleapCache } from './GleapHelper';\nimport Gleap, {\n  GleapFrameManager,\n  GleapFeedbackButtonManager,\n  GleapTranslationManager,\n  GleapNetworkIntercepter,\n  GleapSession,\n  GleapReplayRecorder,\n  GleapNotificationManager,\n  GleapAiChatbarManager,\n} from './Gleap';\n\nconst parseIntWithDefault = (val, def) => {\n  const parsed = parseInt(val);\n  if (isNaN(parsed)) {\n    return def;\n  }\n  return parsed;\n};\n\nexport default class GleapConfigManager {\n  flowConfig = null;\n  projectActions = null;\n  onConfigLoadedListener = [];\n  onConfigLoaded = (onConfigLoaded) => {\n    if (this.flowConfig !== null) {\n      onConfigLoaded();\n    } else {\n      this.onConfigLoadedListener.push(onConfigLoaded);\n    }\n  };\n\n  // GleapConfigManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapConfigManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Returns the loaded flow config.\n   * @returns\n   */\n  getFlowConfig() {\n    return this.flowConfig;\n  }\n\n  /**\n   * Load config.\n   * @returns {string}\n   */\n  start = () => {\n    const session = GleapSession.getInstance();\n    const cachedConfig = loadFromGleapCache(\n      `config-${session.sdkKey}-${GleapTranslationManager.getInstance().getActiveLanguage()}`\n    );\n    if (cachedConfig) {\n      this.applyConfig(cachedConfig);\n      this.loadConfigFromServer().catch(function (e) {});\n      return Promise.resolve();\n    }\n\n    return this.loadConfigFromServer();\n  };\n\n  loadConfigFromServer = () => {\n    const self = this;\n    return new Promise(function (resolve, reject) {\n      const session = GleapSession.getInstance();\n      const http = new XMLHttpRequest();\n      const lang = GleapTranslationManager.getInstance().getActiveLanguage();\n      http.open('GET', session.apiUrl + '/config/' + session.sdkKey + '?lang=' + lang);\n      http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n      session.injectSession(http);\n      http.onerror = function () {\n        reject();\n      };\n      http.onreadystatechange = function (e) {\n        if (http.readyState === 4) {\n          if (http.status === 403) {\n            clearGleapCache(`config-${session.sdkKey}-${lang}`);\n            Gleap.destroy();\n          }\n          if (http.status === 200 || http.status === 201) {\n            try {\n              const config = JSON.parse(http.responseText);\n              try {\n                saveToGleapCache(`config-${session.sdkKey}-${lang}`, config);\n              } catch (exp) {}\n              self.applyConfig(config);\n              return resolve();\n            } catch (e) {}\n          }\n          reject();\n        }\n      };\n      http.send();\n    });\n  };\n\n  applyStylesFromConfig() {\n    const flowConfig = this.flowConfig;\n\n    Gleap.setStyles(\n      flowConfig.color ? flowConfig.color : '#485BFF',\n      flowConfig.headerColor ? flowConfig.headerColor : '#485BFF',\n      flowConfig.buttonColor ? flowConfig.buttonColor : '#485BFF',\n      flowConfig.backgroundColor ? flowConfig.backgroundColor : '#FFFFFF',\n      parseIntWithDefault(flowConfig.borderRadius, 20),\n      parseIntWithDefault(flowConfig.buttonX, 20),\n      parseIntWithDefault(flowConfig.buttonY, 20),\n      flowConfig.feedbackButtonPosition\n    );\n  }\n\n  notifyConfigLoaded() {\n    if (this.onConfigLoadedListener.length > 0) {\n      for (var i = 0; i < this.onConfigLoadedListener.length; i++) {\n        this.onConfigLoadedListener[i]();\n      }\n    }\n    this.onConfigLoadedListener = [];\n  }\n\n  /**\n   * Applies the Gleap config.\n   * @param {*} config\n   */\n  applyConfig(config) {\n    try {\n      const flowConfig = config.flowConfig;\n      this.flowConfig = flowConfig;\n\n      // Update styles.\n      this.applyStylesFromConfig();\n\n      // Send config update.\n      GleapFrameManager.getInstance().sendConfigUpdate();\n      GleapFeedbackButtonManager.getInstance().updateFeedbackButtonState();\n      GleapNotificationManager.getInstance().updateContainerStyle();\n\n      if (flowConfig.enableWebReplays) {\n        GleapReplayRecorder.getInstance().start();\n      } else {\n        GleapReplayRecorder.getInstance().stop();\n      }\n\n      if (flowConfig.enableNetworkLogs) {\n        GleapNetworkIntercepter.getInstance().start();\n      }\n\n      GleapNetworkIntercepter.getInstance().setLoadAllResources(flowConfig.sendNetworkResources ? true : false);\n\n      if (flowConfig.networkLogPropsToIgnore) {\n        GleapNetworkIntercepter.getInstance().setFilters(flowConfig.networkLogPropsToIgnore);\n      }\n\n      if (flowConfig.networkLogBlacklist) {\n        GleapNetworkIntercepter.getInstance().setBlacklist(flowConfig.networkLogBlacklist);\n      }\n\n      GleapTranslationManager.getInstance().updateRTLSupport();\n\n      Gleap.enableShortcuts(flowConfig.enableShortcuts ? true : false);\n\n      if (config.aiBar) {\n        GleapAiChatbarManager.getInstance().setConfig(config.aiBar);\n      }\n\n      this.notifyConfigLoaded();\n    } catch (e) {}\n  }\n}\n","import { isMobile, resizeImage } from './GleapHelper';\nimport { isBlacklisted } from './ResourceExclusionList';\n\nexport const startScreenCapture = (isLiveSite) => {\n  return prepareScreenshotData(isLiveSite);\n};\n\nconst documentToHTML = (clone) => {\n  var html = '';\n  var node = window.document.doctype;\n  if (node) {\n    html =\n      '<!DOCTYPE ' +\n      node.name +\n      (node.publicId ? ' PUBLIC \"' + node.publicId + '\"' : '') +\n      (!node.publicId && node.systemId ? ' SYSTEM' : '') +\n      (node.systemId ? ' \"' + node.systemId + '\"' : '') +\n      '>';\n  }\n\n  if (clone && clone.childNodes && clone.childNodes.length > 0) {\n    for (var i = 0; i < clone.childNodes.length; i++) {\n      if (clone.childNodes[i]) {\n        html += clone.childNodes[i].outerHTML;\n      }\n    }\n  }\n\n  return html;\n};\n\nconst replaceAsync = (str, regex, asyncFn) => {\n  return new Promise((resolve, reject) => {\n    const promises = [];\n    str.replace(regex, (match, ...args) => {\n      const promise = asyncFn(match, ...args);\n      promises.push(promise);\n    });\n    Promise.all(promises)\n      .then((data) => {\n        resolve(str.replace(regex, () => data.shift()));\n      })\n      .catch(() => {\n        reject();\n      });\n  });\n};\n\nconst loadCSSUrlResources = (data, basePath, remote) => {\n  return replaceAsync(\n    data,\n    /url\\((.*?)\\)/g,\n    (matchedData) =>\n      new Promise((resolve, reject) => {\n        if (!matchedData) {\n          return resolve(matchedData);\n        }\n\n        var matchedUrl = matchedData\n          .substr(4, matchedData.length - 5)\n          .replaceAll(\"'\", '')\n          .replaceAll('\"', '');\n\n        // Remote file or data\n        if (matchedUrl.indexOf('http') === 0 || matchedUrl.indexOf('//') === 0 || matchedUrl.indexOf('data') === 0) {\n          return resolve(matchedData);\n        }\n\n        try {\n          var resourcePath = matchedUrl;\n          if (basePath) {\n            resourcePath = new URL(matchedUrl, basePath + '/').href;\n          }\n\n          // Try to fetch external resource.\n          if (!remote) {\n            return fetchCSSResource(resourcePath).then((resourceData) => {\n              return resolve('url(' + resourceData + ')');\n            });\n          } else {\n            return resolve('url(' + resourcePath + ')');\n          }\n        } catch (exp) {\n          return resolve(matchedData);\n        }\n      })\n  );\n};\n\nconst fetchCSSResource = (url) => {\n  return new Promise((resolve, reject) => {\n    if (url) {\n      var xhr = new XMLHttpRequest();\n      xhr.onload = function () {\n        var reader = new FileReader();\n        reader.onloadend = function () {\n          resolve(reader.result);\n        };\n        reader.onerror = function () {\n          reject();\n        };\n        reader.readAsDataURL(xhr.response);\n      };\n      xhr.onerror = function (err) {\n        resolve();\n      };\n      xhr.open('GET', url);\n      xhr.responseType = 'blob';\n      xhr.send();\n    } else {\n      resolve();\n    }\n  });\n};\n\nconst progressResource = (data, elem, resolve, reject) => {\n  resizeImage(data, 500, 500)\n    .then((data) => {\n      elem.src = data;\n      resolve();\n    })\n    .catch(() => {\n      console.warn('BB: Image resize failed.');\n      resolve();\n    });\n};\n\nconst fetchItemResource = (elem) => {\n  return new Promise((resolve, reject) => {\n    if (elem && elem.src) {\n      if (isBlacklisted(elem.src)) {\n        return resolve();\n      }\n\n      var xhr = new XMLHttpRequest();\n      xhr.onload = function () {\n        var reader = new FileReader();\n        reader.onloadend = function () {\n          progressResource(reader.result, elem, resolve, reject);\n        };\n        reader.onerror = function () {\n          resolve();\n        };\n        reader.readAsDataURL(xhr.response);\n      };\n      xhr.onerror = function (err) {\n        resolve();\n      };\n      var url = elem.src;\n      xhr.open('GET', url);\n      xhr.responseType = 'blob';\n      xhr.send();\n    } else {\n      resolve();\n    }\n  });\n};\n\nconst downloadAllImages = (dom) => {\n  const imgItems = dom.querySelectorAll('img');\n  const imgItemsPromises = [];\n  for (var i = 0; i < imgItems.length; i++) {\n    const item = imgItems[i];\n    imgItemsPromises.push(fetchItemResource(item));\n  }\n\n  return Promise.all(imgItemsPromises);\n};\n\nconst replaceStyleNodes = (clone, styleSheet, cssTextContent, styleId) => {\n  {\n    var cloneTargetNode = null;\n    if (styleSheet.ownerNode) {\n      cloneTargetNode = clone.querySelector('[bb-styleid=\"' + styleId + '\"]');\n    }\n\n    try {\n      if (cloneTargetNode) {\n        var replacementNode = null;\n        if (cssTextContent != '') {\n          // Create node.\n          const head = clone.querySelector('head');\n          var styleNode = window.document.createElement('style');\n          head.appendChild(styleNode);\n          styleNode.type = 'text/css';\n          if (styleNode.styleSheet) {\n            styleNode.styleSheet.cssText = cssTextContent;\n          } else {\n            styleNode.appendChild(window.document.createTextNode(cssTextContent));\n          }\n          replacementNode = styleNode;\n        } else {\n          var linkNode = window.document.createElement('link');\n          linkNode.rel = 'stylesheet';\n          linkNode.type = styleSheet.type;\n          linkNode.href = styleSheet.href;\n          linkNode.media = styleSheet.media;\n          replacementNode = linkNode;\n        }\n\n        if (replacementNode) {\n          cloneTargetNode.parentNode.insertBefore(replacementNode, cloneTargetNode);\n          cloneTargetNode.remove();\n        }\n      }\n    } catch (exp) {}\n  }\n};\n\nconst sanitizeCSSBraces = (css) => {\n  var result = '';\n  var depth = 0;\n  for (var i = 0; i < css.length; i++) {\n    if (css[i] === '{') {\n      depth++;\n      result += css[i];\n    } else if (css[i] === '}') {\n      if (depth > 0) {\n        depth--;\n        result += css[i];\n      }\n      // Skip stray closing braces at depth 0\n    } else {\n      result += css[i];\n    }\n  }\n  return result;\n};\n\nconst getTextContentFromStyleSheet = (styleSheet) => {\n  var cssRules = null;\n  try {\n    if (styleSheet.cssRules) {\n      cssRules = styleSheet.cssRules;\n    } else if (styleSheet.rules) {\n      cssRules = styleSheet.rules;\n    }\n  } catch (exp) {}\n\n  var cssTextContent = '';\n  if (cssRules) {\n    for (var cssRuleItem in cssRules) {\n      if (cssRules[cssRuleItem].cssText) {\n        cssTextContent += cssRules[cssRuleItem].cssText + '\\n';\n      }\n    }\n  }\n\n  return sanitizeCSSBraces(cssTextContent);\n};\n\nconst downloadAllCSSUrlResources = (clone, remote) => {\n  var promises = [];\n  for (var i = 0; i < document.styleSheets.length; i++) {\n    const styleSheet = document.styleSheets[i];\n\n    // Skip if the stylesheet is meant for print\n    if (styleSheet.media && styleSheet.media.mediaText === 'print') {\n      continue;\n    }\n\n    const cssTextContent = getTextContentFromStyleSheet(styleSheet);\n    if (styleSheet && styleSheet.ownerNode) {\n      if (cssTextContent != '') {\n        // Resolve resources.\n        const baseTags = document.getElementsByTagName('base');\n        var basePathURL = baseTags.length\n          ? baseTags[0].href.substr(location.origin.length, 999)\n          : window.location.href.split(/[?#]/)[0];\n\n        if (styleSheet.href) {\n          basePathURL = styleSheet.href;\n        }\n\n        const basePath = basePathURL.substring(0, basePathURL.lastIndexOf('/'));\n\n        promises.push(\n          loadCSSUrlResources(cssTextContent, basePath, remote).then((replacedStyle) => {\n            return {\n              styletext: replacedStyle,\n              stylesheet: styleSheet,\n              styleId: styleSheet.ownerNode.getAttribute('bb-styleid'),\n            };\n          })\n        );\n      } else {\n        promises.push(\n          Promise.resolve({\n            styletext: cssTextContent,\n            stylesheet: styleSheet,\n            styleId: styleSheet.ownerNode.getAttribute('bb-styleid'),\n          })\n        );\n      }\n    }\n  }\n\n  return Promise.all(promises).then((results) => {\n    if (results) {\n      for (var i = 0; i < results.length; i++) {\n        replaceStyleNodes(clone, results[i].stylesheet, results[i].styletext, results[i].styleId);\n      }\n    }\n    return true;\n  });\n};\n\nconst prepareRemoteData = (clone, remote) => {\n  return new Promise((resolve, reject) => {\n    if (remote) {\n      // Always download CSS.\n      return downloadAllCSSUrlResources(clone, remote)\n        .then(() => {\n          resolve();\n        })\n        .catch(() => {\n          resolve();\n        });\n    } else {\n      return downloadAllImages(clone)\n        .then(() => {\n          return downloadAllCSSUrlResources(clone, remote).then(() => {\n            resolve();\n          });\n        })\n        .catch(() => {\n          console.warn('Gleap: Failed with resolving local resources. Please contact the Gleap support team.');\n          resolve();\n        });\n    }\n  });\n};\n\nconst handleAdoptedStyleSheets = (doc, clone, shadowNodeId) => {\n  if (typeof doc.adoptedStyleSheets !== 'undefined') {\n    for (let i = 0; i < doc.adoptedStyleSheets.length; i++) {\n      const styleSheet = doc.adoptedStyleSheets[i];\n      const cssTextContent = getTextContentFromStyleSheet(styleSheet);\n\n      var shadowStyleNode = window.document.createElement('style');\n      shadowStyleNode.type = 'text/css';\n      if (shadowStyleNode.styleSheet) {\n        shadowStyleNode.styleSheet.cssText = cssTextContent;\n      } else {\n        shadowStyleNode.appendChild(window.document.createTextNode(cssTextContent));\n      }\n\n      if (shadowNodeId) {\n        shadowStyleNode.setAttribute('bb-shadow-child', shadowNodeId);\n      }\n\n      clone.insertBefore(shadowStyleNode, clone.firstElementChild);\n    }\n  }\n};\n\nconst extractFinalCSSState = (element) => {\n  if (element && typeof element.getAnimations === 'function') {\n    const animations = element.getAnimations();\n    const finalCSSState = {};\n\n    animations.forEach((animation) => {\n      const keyframes = animation.effect?.getKeyframes() || [];\n      const finalKeyframe = keyframes[keyframes.length - 1] || {};\n\n      // Extract only the keys (CSS properties) from the final keyframe\n      Object.keys(finalKeyframe).forEach((property) => {\n        if (property !== 'offset') {\n          // Store the computed style for each animated property\n          finalCSSState[property] = getComputedStyle(element)[property];\n        }\n      });\n    });\n\n    if (Object.keys(finalCSSState).length === 0) {\n      return null;\n    }\n\n    return JSON.stringify(finalCSSState);\n  }\n\n  return null;\n};\n\nconst deepClone = async (host) => {\n  let shadowNodeId = 1;\n\n  const cloneNode = async (node, parent, shadowRoot) => {\n    const walkTree = async (nextn, nextp, innerShadowRoot) => {\n      while (nextn) {\n        try {\n          await cloneNode(nextn, nextp, innerShadowRoot);\n        } catch (exp) { }\n\n        // Fix missing element nodes.\n        if (\n          nextn.nextElementSibling &&\n          (nextn.nextElementSibling.nextSibling === nextn.nextSibling || nextn.nextSibling === null)\n        ) {\n          nextn = nextn.nextElementSibling;\n        } else {\n          nextn = nextn.nextSibling;\n        }\n      }\n    };\n\n    const clone = node.cloneNode();\n\n    const webAnimations = extractFinalCSSState(node);\n    if (webAnimations != null) {\n      clone.setAttribute('bb-web-animations', webAnimations);\n    }\n\n    if (typeof clone.setAttribute !== 'undefined') {\n      if (shadowRoot) {\n        clone.setAttribute('bb-shadow-child', shadowRoot);\n      }\n\n      if (node instanceof HTMLCanvasElement) {\n        try {\n          const boundingRect = node.getBoundingClientRect();\n          const resizedImage = await resizeImage(node.toDataURL(), 1400, 1400);\n\n          clone.setAttribute('bb-canvas-data', resizedImage);\n          clone.setAttribute('bb-canvas-height', boundingRect.height);\n          clone.setAttribute('bb-canvas-width', boundingRect.width);\n        } catch (exp) {\n          console.warn('Gleap: Failed to clone canvas data.', exp);\n        }\n      }\n    }\n\n    if (node.nodeType == Node.ELEMENT_NODE) {\n      const tagName = node.tagName ? node.tagName.toUpperCase() : node.tagName;\n      if (tagName == 'IFRAME' || tagName == 'VIDEO' || tagName == 'EMBED' || tagName == 'IMG' || tagName == 'SVG') {\n        const boundingRect = node.getBoundingClientRect();\n        clone.setAttribute('bb-element', true);\n        clone.setAttribute('bb-height', boundingRect.height);\n        clone.setAttribute('bb-width', boundingRect.width);\n      }\n\n      if (node.scrollTop > 0 || node.scrollLeft > 0) {\n        clone.setAttribute('bb-scrollpos', true);\n        clone.setAttribute('bb-scrolltop', node.scrollTop);\n        clone.setAttribute('bb-scrollleft', node.scrollLeft);\n      }\n\n      if (tagName === 'SELECT' || tagName === 'TEXTAREA' || tagName === 'INPUT') {\n        var val = node.value;\n        if (node.getAttribute('gleap-ignore') === 'value' || node.classList.contains('gl-mask')) {\n          val = new Array(val.length + 1).join('*');\n        }\n\n        clone.setAttribute('bb-data-value', val);\n        if ((node.type === 'checkbox' || node.type === 'radio') && node.checked) {\n          clone.setAttribute('bb-data-checked', true);\n        }\n      }\n    }\n\n    parent.appendChild(clone);\n\n    if (node.shadowRoot) {\n      var rootShadowNodeId = shadowNodeId;\n      shadowNodeId++;\n      await walkTree(node.shadowRoot.firstChild, clone, rootShadowNodeId);\n      handleAdoptedStyleSheets(node.shadowRoot, clone, rootShadowNodeId);\n\n      if (typeof clone.setAttribute !== 'undefined') {\n        clone.setAttribute('bb-shadow-parent', rootShadowNodeId);\n      }\n    }\n\n    await walkTree(node.firstChild, clone);\n  };\n\n  const fragment = document.createDocumentFragment();\n  await cloneNode(host, fragment);\n\n  // Work on adopted stylesheets.\n  var clonedHead = fragment.querySelector('head');\n  if (!clonedHead) {\n    clonedHead = fragment;\n  }\n  handleAdoptedStyleSheets(window.document, clonedHead);\n\n  return fragment;\n};\n\nconst prepareScreenshotData = (remote) => {\n  return new Promise(async (resolve, reject) => {\n    try {\n    const styleTags = window.document.querySelectorAll('style, link');\n    for (var i = 0; i < styleTags.length; ++i) {\n      styleTags[i].setAttribute('bb-styleid', i);\n    }\n\n    const clone = await deepClone(window.document.documentElement);\n\n    // Fix for web imports (depracted).\n    const linkImportElems = clone.querySelectorAll('link[rel=import]');\n    for (var i = 0; i < linkImportElems.length; ++i) {\n      const referenceNode = linkImportElems[i];\n      if (referenceNode && referenceNode.childNodes && referenceNode.childNodes.length > 0) {\n        const childNodes = referenceNode.childNodes;\n        while (childNodes.length > 0) {\n          referenceNode.parentNode.insertBefore(childNodes[0], referenceNode);\n        }\n        referenceNode.remove();\n      }\n    }\n\n    // Remove all scripts & style\n    const scriptElems = clone.querySelectorAll('script, noscript');\n    for (var i = 0; i < scriptElems.length; ++i) {\n      scriptElems[i].remove();\n    }\n\n    // Cleanup base path\n    var existingBasePath = '';\n    const baseElems = clone.querySelectorAll('base');\n    for (var i = 0; i < baseElems.length; ++i) {\n      if (baseElems[i].href) {\n        existingBasePath = baseElems[i].href;\n      }\n      baseElems[i].remove();\n    }\n\n    // Adjust the base node\n    const baseUrl = window.location.href.substring(0, window.location.href.lastIndexOf('/'));\n    var newBaseUrl = baseUrl + '/';\n    if (existingBasePath) {\n      if (existingBasePath.startsWith('http')) {\n        // Absolute path.\n        newBaseUrl = existingBasePath;\n      } else {\n        // Relative path.\n        newBaseUrl = baseUrl + existingBasePath;\n        if (!newBaseUrl.endsWith('/')) {\n          newBaseUrl += '/';\n        }\n      }\n    }\n\n    const baseNode = window.document.createElement('base');\n    baseNode.href = newBaseUrl;\n    const head = clone.querySelector('head');\n    head.insertBefore(baseNode, head.firstChild);\n\n    // Do further cleanup.\n    const dialogElems = clone.querySelectorAll('.bb-feedback-dialog-container, .bb-capture-editor-borderlayer');\n    for (var i = 0; i < dialogElems.length; ++i) {\n      dialogElems[i].remove();\n    }\n\n    // Calculate heights\n    const bbElems = clone.querySelectorAll('[bb-element=true]');\n    for (var i = 0; i < bbElems.length; ++i) {\n      if (bbElems[i]) {\n        bbElems[i].style.height = bbElems[i].getAttribute('bb-height') + 'px';\n      }\n    }\n\n    prepareRemoteData(clone, remote).then(() => {\n      const html = documentToHTML(clone);\n\n      resolve({\n        html: html,\n        baseUrl: baseUrl,\n        width: window.innerWidth,\n        height: window.innerHeight,\n        isMobile: isMobile(),\n      });\n    });\n    } catch (exp) {\n      console.warn('Gleap: Failed to capture screenshot', exp);\n      resolve(null);\n    }\n  });\n};\n","export const isBlacklisted = function (url) {\n  const blacklist = [\n    '//fonts.googleapis.com',\n    '//cdn.jsdelivr.net',\n    '//cdnjs.cloudflare.com',\n    '//ajax.googleapis.com',\n    '//use.typekit.net',\n    '.amazonaws.com',\n    '//jssdk.gleap.io',\n    '.gstatic.com',\n  ];\n\n  if (!url) {\n    return false;\n  }\n\n  for (var i = 0; i < blacklist.length; i++) {\n    if (url.indexOf(blacklist[i]) !== -1) {\n      return true;\n    }\n  }\n  return false;\n};\n","import GleapSession from './GleapSession';\n\nexport class GleapScreenRecorder {\n  // Constants\n  static MAX_RECORD_TIME = 120; // 2 minutes\n  static MAX_WIDTH = 3072;\n  static MAX_HEIGHT = 1728;\n  static IDEAL_FRAME_RATE = 10;\n  static MAX_FRAME_RATE = 24;\n  static CHUNK_INTERVAL = 200; // milliseconds\n  static TIMER_UPDATE_INTERVAL = 1000; // milliseconds\n  static RERENDER_DELAY = 100; // milliseconds\n\n  // MIME types in order of preference\n  static MIME_TYPES = [\n    'video/webm;codecs=vp9,opus',\n    'video/webm;codecs=vp8,opus',\n    'video/webm;codecs=vp9',\n    'video/webm;codecs=vp8',\n    'video/webm',\n    'video/mp4',\n  ];\n\n  // CSS selectors\n  static SELECTORS = {\n    PREVIEW_VIDEO: '.bb-capture-preview video',\n    TIMER_LABEL: '.bb-capture-toolbar-item-timer',\n  };\n\n  // Instance properties\n  rerender;\n  stream;\n  mediaRecorder;\n  audioMuted = false;\n  audioAvailable = true;\n  available = true;\n  isRecording = false;\n  file = null;\n  maxRecordTime = GleapScreenRecorder.MAX_RECORD_TIME;\n  recordTime = 0;\n  recordingTimer = null;\n  permissionErrorText = '';\n\n  // Internals for composed capture\n  _displayVideoTrack = null;\n  _displayStream = null;\n  _micStream = null;\n\n  constructor(rerender, permissionErrorText) {\n    this.rerender = rerender;\n    this.permissionErrorText = permissionErrorText;\n    if (!navigator.mediaDevices || !navigator.mediaDevices.getDisplayMedia) {\n      this.available = false;\n    }\n\n    setTimeout(() => {\n      this.rerender();\n    }, GleapScreenRecorder.RERENDER_DELAY);\n  }\n\n  getSupportedMimeType() {\n    // Prefer explicit audio+video codecs to ensure audio gets muxed.\n    for (const type of GleapScreenRecorder.MIME_TYPES) {\n      if (window.MediaRecorder && MediaRecorder.isTypeSupported(type)) {\n        return type;\n      }\n    }\n\n    return 'video/webm';\n  }\n\n  formatTime(s) {\n    return (s - (s %= 60)) / 60 + (9 < s ? ':' : ':0') + s;\n  }\n\n  stopStreamTracks(stream) {\n    if (!stream) return;\n    try {\n      stream.getTracks().forEach((track) => track.stop());\n    } catch (_) {}\n  }\n\n  createMediaStream(tracks) {\n    const validTracks = tracks.filter((track) => track !== null);\n    return new MediaStream(validTracks);\n  }\n\n  getFirstVideoTrack(stream) {\n    if (!stream) return null;\n    const videoTracks = stream.getVideoTracks();\n    return videoTracks.length > 0 ? videoTracks[0] : null;\n  }\n\n  getFirstAudioTrack(stream) {\n    if (!stream) return null;\n    const audioTracks = stream.getAudioTracks();\n    return audioTracks.length > 0 ? audioTracks[0] : null;\n  }\n\n  async startScreenRecording() {\n    if (!navigator.mediaDevices || !navigator.mediaDevices.getDisplayMedia || this.isRecording) {\n      this.available = false;\n      this.rerender();\n      return;\n    }\n\n    try {\n      const displayStream = await navigator.mediaDevices.getDisplayMedia({\n        video: {\n          width: {\n            ideal: Math.min(window.screen.width, GleapScreenRecorder.MAX_WIDTH),\n          },\n          height: {\n            ideal: Math.min(window.screen.height, GleapScreenRecorder.MAX_HEIGHT),\n          },\n          frameRate: {\n            ideal: GleapScreenRecorder.IDEAL_FRAME_RATE,\n            max: GleapScreenRecorder.MAX_FRAME_RATE,\n          },\n          displaySurface: 'monitor',\n        },\n        audio: false,\n        selfBrowserSurface: 'include',\n      });\n\n      // Keep references to both the original stream and video track\n      this._displayStream = displayStream;\n      this._displayVideoTrack = this.getFirstVideoTrack(displayStream);\n\n      // If user wants audio and permissions allow it, get mic, else continue with video-only\n      if (!this.audioMuted) {\n        await this.startAudioRecording();\n      } else {\n        this.audioAvailable = false;\n        const composed = this.createMediaStream([this._displayVideoTrack]);\n        this.stream = composed;\n        this.handleRecord({ stream: composed });\n      }\n\n      this.rerender();\n    } catch (error) {\n      window.alert(this.permissionErrorText);\n      this.rerender();\n    }\n  }\n\n  stopScreenRecording() {\n    if (!this.mediaRecorder || !this.stream || !this.isRecording) {\n      return;\n    }\n\n    if (this.recordingTimer) {\n      clearInterval(this.recordingTimer);\n      this.recordingTimer = null;\n    }\n\n    try {\n      this.mediaRecorder.stop();\n    } catch (_) {}\n\n    // Stop composed stream tracks\n    this.stopStreamTracks(this.stream);\n\n    // Stop original display stream tracks (this is what Chrome uses for the recording indicator)\n    if (this._displayStream) {\n      this.stopStreamTracks(this._displayStream);\n      this._displayStream = null;\n    }\n\n    // Also stop original mic stream tracks if present\n    if (this._micStream) {\n      this.stopStreamTracks(this._micStream);\n      this._micStream = null;\n    }\n\n    this._displayVideoTrack = null;\n\n    this.rerender();\n  }\n\n  async startAudioRecording() {\n    if (!this._displayVideoTrack) {\n      return;\n    }\n\n    try {\n      const voiceStream = await navigator.mediaDevices.getUserMedia({\n        audio: {\n          echoCancellation: true,\n          noiseSuppression: true,\n          autoGainControl: true,\n        },\n        video: false,\n      });\n\n      this._micStream = voiceStream;\n      const micTrack = this.getFirstAudioTrack(voiceStream);\n\n      this.audioMuted = false;\n      this.audioAvailable = !!micTrack;\n\n      // Compose a NEW stream with exactly one video track + (optional) one mic track\n      const composed = this.createMediaStream([this._displayVideoTrack, micTrack]);\n\n      this.stream = composed;\n      this.handleRecord({ stream: composed });\n      this.rerender();\n    } catch (error) {\n      this.audioAvailable = false;\n\n      // Fallback to video-only if mic fails\n      const composed = this.createMediaStream([this._displayVideoTrack]);\n\n      this.stream = composed;\n      this.handleRecord({ stream: composed });\n      this.rerender();\n    }\n  }\n\n  toggleAudio() {\n    this.audioMuted = !this.audioMuted;\n    this.rerender();\n\n    if (!this.stream) {\n      return;\n    }\n\n    const audioTracks = this.stream.getAudioTracks();\n    for (let i = 0; i < audioTracks.length; i++) {\n      const audioTrack = audioTracks[i];\n      audioTrack.enabled = !this.audioMuted;\n    }\n  }\n\n  static async uploadScreenRecording(screenRecordingData) {\n    if (screenRecordingData == null) {\n      return null;\n    }\n\n    return new Promise((resolve, reject) => {\n      const xhr = new XMLHttpRequest();\n      xhr.open('POST', GleapSession.getInstance().apiUrl + '/uploads/sdk');\n      GleapSession.getInstance().injectSession(xhr);\n\n      const formData = new FormData();\n      formData.append('file', screenRecordingData);\n\n      xhr.onerror = function () {\n        reject(new Error('Network error during file upload'));\n      };\n      xhr.onreadystatechange = function () {\n        if (xhr.readyState == 4) {\n          if (xhr.status == 200) {\n            resolve(JSON.parse(xhr.response).fileUrl);\n          } else {\n            reject(new Error(`Upload failed with status ${xhr.status}`));\n          }\n        }\n      };\n      xhr.send(formData);\n    });\n  }\n\n  clearPreview() {\n    const videoEl = document.querySelector(GleapScreenRecorder.SELECTORS.PREVIEW_VIDEO);\n    if (videoEl) {\n      videoEl.src = null;\n    }\n    this.file = null;\n    this.rerender();\n  }\n\n  handleRecord({ stream }) {\n    const self = this;\n\n    const recordedChunks = [];\n    this.mediaRecorder = new MediaRecorder(stream, {\n      mimeType: this.getSupportedMimeType(),\n    });\n    this.isRecording = true;\n    this.recordTime = 0;\n\n    // Set timer (guard if label isn't present)\n    const timerLabel = document.querySelector(GleapScreenRecorder.SELECTORS.TIMER_LABEL);\n    if (this.recordingTimer) {\n      clearInterval(this.recordingTimer);\n      this.recordingTimer = null;\n    }\n    this.recordingTimer = setInterval(() => {\n      self.recordTime++;\n      const remainingTime = self.maxRecordTime - self.recordTime;\n      if (timerLabel) {\n        if (remainingTime > 0) {\n          timerLabel.innerHTML = self.formatTime(remainingTime);\n        } else {\n          timerLabel.innerHTML = '2:00';\n          self.stopScreenRecording();\n        }\n      } else if (remainingTime <= 0) {\n        self.stopScreenRecording();\n      }\n    }, GleapScreenRecorder.TIMER_UPDATE_INTERVAL);\n\n    this.mediaRecorder.ondataavailable = function (e) {\n      if (e.data && e.data.size > 0) {\n        recordedChunks.push(e.data);\n      }\n    };\n\n    const videoTrack = this.getFirstVideoTrack(stream);\n    if (videoTrack) {\n      videoTrack.onended = function () {\n        self.prepareRecording(recordedChunks);\n      };\n    }\n\n    this.mediaRecorder.onstop = function () {\n      self.prepareRecording(recordedChunks);\n    };\n\n    // Start recording with configured chunk interval\n    this.mediaRecorder.start(GleapScreenRecorder.CHUNK_INTERVAL);\n\n    self.rerender();\n  }\n\n  prepareRecording(recordedChunks) {\n    const mimeType = this.getSupportedMimeType();\n    const completeBlob = new Blob(recordedChunks, { type: mimeType });\n\n    const extension = mimeType.includes('mp4') ? 'mp4' : 'webm';\n    this.file = new File([completeBlob], `screen-recording.${extension}`, {\n      type: mimeType,\n    });\n\n    const previewVideoElement = document.querySelector(GleapScreenRecorder.SELECTORS.PREVIEW_VIDEO);\n    if (previewVideoElement) {\n      previewVideoElement.src = URL.createObjectURL(completeBlob);\n      this.audioAvailable = this.stream ? this.stream.getAudioTracks().length > 0 : this.audioAvailable;\n      this.isRecording = false;\n      this.rerender();\n    }\n  }\n}\n","import { startScreenCapture } from './ScreenCapture';\nimport { GleapScreenRecorder } from './GleapScreenRecorder';\nimport Gleap, {\n  GleapConsoleLogManager,\n  GleapStreamedEvent,\n  GleapSession,\n  GleapCustomDataManager,\n  GleapMetaDataManager,\n  GleapNetworkIntercepter,\n  GleapTagManager,\n} from './Gleap';\n\nexport default class GleapFeedback {\n  excludeData = {};\n  type = 'BUG';\n  priority = 'LOW';\n  customData = {};\n  ticketAttributes = {};\n  metaData = {};\n  consoleLog = [];\n  networkLogs = [];\n  customEventLog = [];\n  formData = {};\n  isSilent = false;\n  outboundId = undefined;\n  screenshotData = undefined;\n  webReplay = undefined;\n  screenRecordingUrl = undefined;\n  spamToken = undefined;\n\n  constructor(type, priority, formData, isSilent, excludeData, outboundId, spamToken) {\n    this.type = type;\n    this.priority = priority;\n    this.formData = formData;\n    this.isSilent = isSilent;\n    this.excludeData = excludeData;\n    this.outboundId = outboundId;\n    this.spamToken = spamToken;\n  }\n\n  takeSnapshot() {\n    const gleapInstance = Gleap.getInstance();\n    this.customData = GleapCustomDataManager.getInstance().getCustomData();\n    this.metaData = GleapMetaDataManager.getInstance().getMetaData();\n    this.consoleLog = GleapConsoleLogManager.getInstance().getLogs();\n    this.networkLogs = GleapNetworkIntercepter.getInstance().getRequests();\n    this.customEventLog = GleapStreamedEvent.getInstance().getEventArray();\n    this.ticketAttributes = GleapCustomDataManager.getInstance().getTicketAttributes();\n\n    var dataPromises = [];\n\n    // Assign replays\n    var webReplay = gleapInstance.getGlobalDataItem('webReplay');\n    if (webReplay !== null) {\n      this.webReplay = webReplay;\n    }\n\n    // Prepare screen recording\n    var screenRecordingData = gleapInstance.getGlobalDataItem('screenRecordingData');\n    if (screenRecordingData != null) {\n      var recordingUrlPromise = GleapScreenRecorder.uploadScreenRecording(screenRecordingData).then((recordingUrl) => {\n        if (recordingUrl) {\n          this.screenRecordingUrl = recordingUrl;\n        }\n      });\n      dataPromises.push(recordingUrlPromise);\n    }\n\n    // Prepare screenshot\n    if (!(this.excludeData && this.excludeData.screenshot)) {\n      var screenshotDataPromise = startScreenCapture(gleapInstance.isLiveMode()).then((screenshotData) => {\n        if (screenshotData) {\n          const snapshotPosition = gleapInstance.getGlobalDataItem('snapshotPosition');\n          screenshotData['x'] = snapshotPosition.x;\n          screenshotData['y'] = snapshotPosition.y;\n          this.screenshotData = screenshotData;\n        }\n      });\n      dataPromises.push(screenshotDataPromise);\n    }\n\n    return Promise.all(dataPromises);\n  }\n\n  getData() {\n    var feedbackData = {\n      type: this.type,\n      priority: this.priority,\n      customData: this.customData,\n      metaData: this.metaData,\n      consoleLog: this.consoleLog,\n      networkLogs: this.networkLogs,\n      customEventLog: this.customEventLog,\n      // Merge ticket attributes and form data.\n      formData: {\n        ...this.ticketAttributes,\n        ...this.formData,\n      },\n      isSilent: this.isSilent,\n      outbound: this.outboundId,\n      screenshotData: this.screenshotData,\n      webReplay: this.webReplay,\n      screenRecordingUrl: this.screenRecordingUrl,\n      spamToken: this.spamToken,\n    };\n\n    const tags = GleapTagManager.getInstance().getTags();\n    if (tags && tags.length > 0) {\n      feedbackData.tags = tags;\n    }\n\n    if (this.excludeData) {\n      const keysToExclude = Object.keys(this.excludeData);\n      for (let i = 0; i < keysToExclude.length; i++) {\n        const keyToExclude = keysToExclude[i];\n        if (this.excludeData[keyToExclude] === true) {\n          if (feedbackData[keyToExclude]) {\n            delete feedbackData[keyToExclude];\n          }\n\n          if (keyToExclude === 'screenshot') {\n            delete feedbackData.screenshotData;\n          }\n\n          if (keyToExclude === 'replays') {\n            delete feedbackData.webReplay;\n          }\n        }\n      }\n    }\n\n    return feedbackData;\n  }\n\n  getTicketData() {\n    return new Promise((resolve, reject) => {\n      this.takeSnapshot()\n        .then(() => {\n          const dataToSend = this.getData();\n          resolve(dataToSend);\n        })\n        .catch((exp) => {\n          console.log('Failed to take snapshot', exp);\n          reject();\n        });\n    });\n  }\n\n  sendFeedback() {\n    return new Promise((resolve, reject) => {\n      this.takeSnapshot()\n        .then(() => {\n          const dataToSend = this.getData();\n\n          const http = new XMLHttpRequest();\n          http.open('POST', GleapSession.getInstance().apiUrl + '/bugs/v2');\n          http.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n          GleapSession.getInstance().injectSession(http);\n          http.onerror = (error) => {\n            reject();\n          };\n          http.onreadystatechange = function (e) {\n            if (http.readyState === 4) {\n              if (http.status === 200 || http.status === 201) {\n                try {\n                  const feedback = JSON.parse(http.responseText);\n                  resolve(feedback);\n                } catch (exp) {\n                  reject();\n                }\n              } else {\n                reject();\n              }\n            }\n          };\n          http.send(JSON.stringify(dataToSend));\n        })\n        .catch((exp) => {\n          console.log('Failed to take snapshot', exp);\n          reject();\n        });\n    });\n  }\n}\n","import Gleap from './Gleap';\n\nexport default class GleapEventManager {\n  eventListeners = {};\n\n  // GleapEventManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapEventManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Notify all registrants for event.\n   */\n  static notifyEvent(event, data = {}) {\n    if (event === 'flow-started') {\n      const gleapInstance = Gleap.getInstance();\n      gleapInstance.setGlobalDataItem('webReplay', null);\n      gleapInstance.setGlobalDataItem('screenRecordingData', null);\n      gleapInstance.takeCurrentReplay();\n    }\n\n    const eventListeners = this.getInstance().eventListeners[event];\n    if (eventListeners) {\n      for (var i = 0; i < eventListeners.length; i++) {\n        const eventListener = eventListeners[i];\n        if (eventListener) {\n          eventListener(data);\n        }\n      }\n    }\n  }\n\n  /**\n   * Register events for Gleap.\n   * @param {*} eventName\n   * @param {*} callback\n   */\n  static on(eventName, callback) {\n    const instance = this.getInstance();\n    if (!instance.eventListeners[eventName]) {\n      instance.eventListeners[eventName] = [];\n    }\n    instance.eventListeners[eventName].push(callback);\n  }\n}\n","import GleapEventManager from './GleapEventManager';\n\n/**\n * Manages agent tool definitions and tool execution callbacks.\n * Shared across chatbar, messenger, and any future agent surface.\n */\nexport default class GleapAgentToolManager {\n  agentTools = [];\n  agentToolCallbacks = [];\n\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapAgentToolManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Set frontend-side tool definitions for AI agents.\n   */\n  setAgentTools(tools) {\n    this.agentTools = tools || [];\n  }\n\n  /**\n   * Get the current tool definitions.\n   */\n  getAgentTools() {\n    return this.agentTools;\n  }\n\n  /**\n   * Register a callback for agent tool executions.\n   */\n  registerAgentToolAction(callback) {\n    if (callback) {\n      this.agentToolCallbacks.push(callback);\n    }\n  }\n\n  /**\n   * Called when a tool execution event is received from any surface\n   * (chatbar, messenger, etc.). Emits the event and triggers all callbacks.\n   */\n  triggerToolAction(data) {\n    if (!data) return;\n\n    GleapEventManager.notifyEvent('agent-tool-executed', data);\n\n    for (const cb of this.agentToolCallbacks) {\n      try {\n        cb(data);\n      } catch (e) {}\n    }\n  }\n}\n","import Gleap, {\n  GleapAudioManager,\n  GleapBannerManager,\n  GleapConfigManager,\n  GleapConsoleLogManager,\n  GleapCustomActionManager,\n  GleapCustomDataManager,\n  GleapEventManager,\n  GleapFeedback,\n  GleapFeedbackButtonManager,\n  GleapMarkerManager,\n  GleapMetaDataManager,\n  GleapNetworkIntercepter,\n  GleapNotificationManager,\n  GleapSession,\n  GleapStreamedEvent,\n  GleapTagManager,\n  GleapTranslationManager,\n} from './Gleap';\nimport GleapAgentToolManager from './GleapAgentToolManager';\nimport { runFunctionWhenDomIsReady } from './GleapHelper';\nimport { widgetMaxHeight } from './UI';\n\nexport default class GleapFrameManager {\n  frameUrl = 'https://messenger-app.gleap.io';\n  gleapFrameContainer = null;\n  gleapFrame = null;\n  comReady = false;\n  injectedFrame = false;\n  widgetOpened = false;\n  listeners = [];\n  appMode = 'widget';\n  markerManager = undefined;\n  escListener = undefined;\n  frameHeight = 0;\n  sendingFeedback = false;\n  queue = [];\n  urlHandler = function (url, newTab) {\n    if (url && url.length > 0) {\n      if (newTab) {\n        const newWindow = window.open(url, '_blank');\n        if (newWindow) {\n          newWindow.focus();\n        }\n      } else {\n        window.location.href = url;\n      }\n    }\n  };\n\n  // GleapFrameManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapFrameManager();\n    }\n    return this.instance;\n  }\n\n  constructor() {\n    this.startCommunication();\n    if (typeof window !== 'undefined') {\n      function appHeight() {\n        try {\n          const doc = document.documentElement;\n          doc.style.setProperty('--glvh', window.innerHeight * 0.01 + 'px');\n        } catch (e) {}\n      }\n\n      try {\n        window.addEventListener('resize', appHeight);\n        appHeight();\n      } catch (e) {}\n    }\n  }\n\n  setUrlHandler(handler) {\n    this.urlHandler = handler;\n  }\n\n  isSurvey() {\n    return this.appMode === 'survey' || this.appMode === 'survey_full' || this.appMode === 'survey_web';\n  }\n\n  setAppMode(appMode) {\n    this.appMode = appMode;\n    this.updateFrameStyle();\n\n    const innerContainer = document.querySelector('.gleap-frame-container-inner');\n    if ((this.appMode === 'widget' || this.appMode === 'survey_full' || this.appMode === 'survey_web') && innerContainer) {\n      innerContainer.style.maxHeight = `${widgetMaxHeight}px`;\n    }\n  }\n\n  registerEscListener() {\n    if (this.escListener) {\n      return;\n    }\n\n    this.escListener = (evt) => {\n      evt = evt || window.event;\n      if (evt.key === 'Escape') {\n        this.hideWidget();\n      }\n    };\n    document.addEventListener('keydown', this.escListener);\n  }\n\n  unregisterEscListener() {\n    if (this.escListener) {\n      document.removeEventListener('keydown', this.escListener);\n      this.escListener = null;\n    }\n  }\n\n  destroy() {\n    if (this.gleapFrame) {\n      this.gleapFrame.remove();\n    }\n    if (this.gleapFrameContainer) {\n      this.gleapFrameContainer.remove();\n    }\n    this.injectedFrame = false;\n    this.widgetOpened = false;\n    this.markerManager = undefined;\n    this.gleapFrameContainer = null;\n    this.gleapFrame = null;\n  }\n\n  isOpened() {\n    return this.widgetOpened || this.markerManager != null;\n  }\n\n  autoWhiteListCookieManager = () => {\n    if (window && window.cmp_block_ignoredomains) {\n      window.cmp_block_ignoredomains.concat(['messenger-app.gleap.io']);\n    }\n  };\n\n  injectFrame = () => {\n    if (this.injectedFrame) {\n      return;\n    }\n    this.injectedFrame = true;\n\n    this.autoWhiteListCookieManager();\n\n    // Inject the frame manager after it has been loaded.\n    runFunctionWhenDomIsReady(() => {\n      GleapConfigManager.getInstance().onConfigLoaded(() => {\n        // Apply CSS.\n        GleapConfigManager.getInstance().applyStylesFromConfig();\n\n        // Inject widget HTML.\n        var elem = document.createElement('div');\n        elem.className = 'gleap-frame-container gleap-frame-container--hidden gl-block';\n        elem.innerHTML = `<div class=\"gleap-frame-container-inner\"><iframe src=\"${this.frameUrl}\" class=\"gleap-frame\" scrolling=\"yes\" allow=\"autoplay; encrypted-media; fullscreen; microphone *; display-capture *; camera *;\" frameborder=\"0\"></iframe></div>`;\n        document.body.appendChild(elem);\n\n        this.gleapFrameContainer = elem;\n        this.gleapFrame = document.querySelector('.gleap-frame');\n\n        this.updateFrameStyle();\n\n        // Show loading preview for widget app mode.\n        if (this.appMode === 'widget') {\n          this.showFrameContainer(true);\n        }\n      });\n    });\n  };\n\n  showImage = (url) => {\n    runFunctionWhenDomIsReady(() => {\n      var elem = document.createElement('div');\n      elem.className = 'gleap-image-view';\n      elem.innerHTML = `<div class=\"gleap-image-view-close\">\n      <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path d=\"M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm97.9-320l-17 17-47 47 47 47 17 17L320 353.9l-17-17-47-47-47 47-17 17L158.1 320l17-17 47-47-47-47-17-17L192 158.1l17 17 47 47 47-47 17-17L353.9 192z\"/></svg>\n      </div><img class=\"gleap-image-view-image\" src=\"${url}\" />`;\n      document.body.appendChild(elem);\n\n      const closeElement = () => {\n        elem.remove();\n      };\n\n      const close = elem.querySelector('.gleap-image-view-close');\n      close.addEventListener('click', () => {\n        closeElement();\n      });\n\n      elem.addEventListener('click', (e) => {\n        if (e.target === elem) {\n          closeElement();\n        }\n      });\n    });\n  };\n\n  updateFrameStyle = () => {\n    if (!this.gleapFrameContainer) {\n      return;\n    }\n\n    const surveyStyle = 'gleap-frame-container--survey';\n    const extendedStyle = 'gleap-frame-container--extended';\n    const surveyFullStyle = 'gleap-frame-container--survey-full';\n    const classicStyle = 'gleap-frame-container--classic';\n    const classicStyleLeft = 'gleap-frame-container--classic-left';\n    const modernStyleLeft = 'gleap-frame-container--modern-left';\n    const noButtonStyleLeft = 'gleap-frame-container--no-button';\n    const allStyles = [\n      classicStyle,\n      classicStyleLeft,\n      extendedStyle,\n      modernStyleLeft,\n      noButtonStyleLeft,\n      surveyStyle,\n      surveyFullStyle,\n    ];\n    for (let i = 0; i < allStyles.length; i++) {\n      this.gleapFrameContainer.classList.remove(allStyles[i]);\n    }\n\n    var styleToApply = undefined;\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n    if (\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC ||\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_BOTTOM\n    ) {\n      styleToApply = classicStyle;\n    }\n    if (flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_LEFT) {\n      styleToApply = classicStyleLeft;\n    }\n    if (flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_BOTTOM_LEFT) {\n      styleToApply = modernStyleLeft;\n    }\n    if (GleapFeedbackButtonManager.getInstance().buttonHidden === null) {\n      if (flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_NONE) {\n        styleToApply = noButtonStyleLeft;\n      }\n    } else {\n      if (GleapFeedbackButtonManager.getInstance().buttonHidden) {\n        styleToApply = noButtonStyleLeft;\n      }\n    }\n    if (styleToApply) {\n      this.gleapFrameContainer.classList.add(styleToApply);\n    }\n\n    if (this.appMode === 'survey') {\n      this.gleapFrameContainer.classList.add(surveyStyle);\n    }\n    if (this.appMode === 'survey_full' || this.appMode === 'survey_web') {\n      this.gleapFrameContainer.classList.add(surveyFullStyle);\n    }\n    if (this.appMode === 'extended') {\n      this.gleapFrameContainer.classList.add(extendedStyle);\n    }\n\n    this.gleapFrameContainer.setAttribute('dir', GleapTranslationManager.getInstance().isRTLLayout ? 'rtl' : 'ltr');\n  };\n\n  showFrameContainer(showLoader) {\n    if (!this.gleapFrameContainer) {\n      return;\n    }\n\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n    const loadingClass = 'gleap-frame-container--loading';\n    if (this.gleapFrameContainer?.classList) {\n      this.gleapFrameContainer.classList.remove('gleap-frame-container--hidden');\n      if (showLoader) {\n        this.gleapFrameContainer.classList.add(loadingClass);\n\n        if (flowConfig && flowConfig.disableBGFade) {\n          this.gleapFrameContainer.classList.add('gleap-frame-container--loading-nofade');\n        }\n        if (flowConfig && flowConfig.disableBGGradient) {\n          this.gleapFrameContainer.classList.add('gleap-frame-container--loading-nogradient');\n        }\n      } else {\n        this.gleapFrameContainer.classList.remove(loadingClass);\n      }\n\n      setTimeout(() => {\n        this.gleapFrameContainer?.classList.add('gleap-frame-container--animate');\n      }, 500);\n    }\n\n    this.widgetOpened = true;\n    this.updateUI();\n  }\n\n  runWidgetShouldOpenCallback() {\n    if (!this.gleapFrameContainer) {\n      return;\n    }\n\n    this.workThroughQueue();\n\n    Gleap.getInstance().setGlobalDataItem('snapshotPosition', {\n      x: window.scrollX,\n      y: window.scrollY,\n    });\n\n    this.showFrameContainer(false);\n    this.updateWidgetStatus();\n\n    GleapEventManager.notifyEvent('open');\n    this.registerEscListener();\n  }\n\n  updateUI() {\n    // Clear notifications only when not opening a survey.\n    GleapNotificationManager.getInstance().clearAllNotifications(this.isSurvey());\n\n    GleapFeedbackButtonManager.getInstance().updateNotificationBadge(0);\n    GleapFeedbackButtonManager.getInstance().updateFeedbackButtonState();\n  }\n\n  showWidget() {\n    setTimeout(() => {\n      if (this.gleapFrameContainer) {\n        this.runWidgetShouldOpenCallback();\n      } else {\n        GleapFrameManager.getInstance().injectFrame();\n      }\n      this.updateUI();\n    }, 0);\n  }\n\n  updateWidgetStatus() {\n    this.sendMessage({\n      name: 'widget-status-update',\n      data: {\n        isWidgetOpen: this.widgetOpened,\n      },\n    });\n  }\n\n  hideMarkerManager() {\n    if (this.markerManager) {\n      this.markerManager.clear();\n      this.markerManager = null;\n    }\n  }\n\n  hideWidget(resetRoutes = false) {\n    // Prevent for survey web.\n    if (this.appMode === 'survey_web') {\n      return;\n    }\n\n    this.hideMarkerManager();\n    if (this.gleapFrameContainer) {\n      this.gleapFrameContainer.classList.add('gleap-frame-container--hidden');\n      this.gleapFrameContainer.classList.remove('gleap-frame-container--animate');\n    }\n    if (resetRoutes) {\n      this.sendMessage({\n        name: 'reset-routes',\n        data: {},\n      });\n    }\n    this.widgetOpened = false;\n    this.updateWidgetStatus();\n    GleapFeedbackButtonManager.getInstance().updateFeedbackButtonState();\n    GleapEventManager.notifyEvent('close');\n    GleapNotificationManager.getInstance().reloadNotificationsFromCache();\n\n    this.unregisterEscListener();\n\n    if (typeof window !== 'undefined' && typeof window.focus !== 'undefined') {\n      window.focus();\n    }\n  }\n\n  sendMessage(data, queue = false) {\n    try {\n      this.gleapFrame = document.querySelector('.gleap-frame');\n      if (this.comReady && this.gleapFrame && this.gleapFrame.contentWindow) {\n        this.gleapFrame.contentWindow.postMessage(JSON.stringify(data), '*');\n      } else {\n        if (queue) {\n          this.queue.push(data);\n        }\n      }\n    } catch (e) {}\n  }\n\n  sendSessionUpdate() {\n    this.sendMessage({\n      name: 'session-update',\n      data: {\n        sessionData: GleapSession.getInstance().getSession(),\n        apiUrl: GleapSession.getInstance().apiUrl,\n        sdkKey: GleapSession.getInstance().sdkKey,\n      },\n    });\n  }\n\n  sendConfigUpdate() {\n    if (!this.comReady) {\n      return;\n    }\n\n    this.sendMessage({\n      name: 'config-update',\n      data: {\n        config: GleapConfigManager.getInstance().getFlowConfig(),\n        aiTools: GleapAgentToolManager.getInstance().getAgentTools(),\n        agentTools: GleapAgentToolManager.getInstance().getAgentTools(),\n        overrideLanguage: GleapTranslationManager.getInstance().getOverrideLanguage(),\n      },\n    });\n\n    this.updateFrameStyle();\n  }\n\n  showDrawingScreen(type) {\n    this.hideWidget();\n\n    // Show screen drawing.\n    this.markerManager = new GleapMarkerManager(type);\n    this.markerManager.show((success) => {\n      if (!success) {\n        this.hideMarkerManager();\n      }\n      this.showWidget();\n    });\n  }\n\n  workThroughQueue() {\n    const workQueue = [...this.queue];\n    this.queue = [];\n    for (let i = 0; i < workQueue.length; i++) {\n      this.sendMessage(workQueue[i], true);\n    }\n  }\n\n  startCommunication() {\n    // Listen for messages.\n    this.addMessageListener((data) => {\n      if (data.name === 'ping') {\n        this.comReady = true;\n        this.sendConfigUpdate();\n        this.sendSessionUpdate();\n        this.workThroughQueue();\n        setTimeout(() => {\n          this.runWidgetShouldOpenCallback();\n        }, 300);\n      }\n\n      if (data.name === 'play-ping') {\n        GleapAudioManager.ping();\n      }\n\n      if (data.name === 'open-image') {\n        this.showImage(data.data.url);\n      }\n\n      if (data.name === 'page-changed') {\n        if (data.data && (data.data.name === 'newsdetails' || data.data.name === 'appextended')) {\n          this.setAppMode('extended');\n        } else {\n          if (this.appMode === 'extended') {\n            this.setAppMode('widget');\n          }\n        }\n      }\n\n      if (data.name === 'collect-ticket-data') {\n        var ticketData = {\n          customData: GleapCustomDataManager.getInstance().getCustomData(),\n          metaData: GleapMetaDataManager.getInstance().getMetaData(),\n          consoleLog: GleapConsoleLogManager.getInstance().getLogs(),\n          networkLogs: GleapNetworkIntercepter.getInstance().getRequests(),\n          customEventLog: GleapStreamedEvent.getInstance().getEventArray(),\n          formData: GleapCustomDataManager.getInstance().getTicketAttributes(),\n        };\n\n        // Add tags\n        const tags = GleapTagManager.getInstance().getTags();\n        if (tags && tags.length > 0) {\n          ticketData.tags = tags;\n        }\n\n        this.sendMessage({\n          name: 'collect-ticket-data',\n          data: ticketData,\n        });\n      }\n\n      if (data.name === 'height-update') {\n        this.frameHeight = data.data;\n\n        const innerContainer = document.querySelector('.gleap-frame-container-inner');\n        if (\n          (this.appMode === 'survey' || this.appMode === 'survey_full' || this.appMode === 'survey_web') &&\n          innerContainer\n        ) {\n          innerContainer.style.maxHeight = `${this.frameHeight}px`;\n        }\n      }\n\n      if (data.name === 'notify-event') {\n        GleapEventManager.notifyEvent(data.data.type, data.data.data);\n      }\n\n      if (data.name === 'cleanup-drawings') {\n        this.hideMarkerManager();\n      }\n\n      if (data.name === 'open-url') {\n        const url = data.data;\n        const newTab = data.newTab ? true : false;\n        this.urlHandler(url, newTab);\n      }\n\n      if (data.name === 'start-product-tour') {\n        Gleap.startProductTour(data.data?.tourId, true);\n      }\n\n      if (data.name === 'run-custom-action') {\n        GleapCustomActionManager.triggerCustomAction(data.data, {\n          shareToken: data.shareToken,\n        });\n      }\n\n      if (data.name === 'close-widget') {\n        this.hideWidget();\n      }\n\n      if (data.name === 'video-call-joined') {\n        GleapFeedbackButtonManager.getInstance().showingRedDot = true;\n        GleapFeedbackButtonManager.getInstance().updateRedDot(true);\n      }\n\n      if (data.name === 'video-call-left') {\n        GleapFeedbackButtonManager.getInstance().showingRedDot = false;\n        GleapFeedbackButtonManager.getInstance().updateRedDot(false);\n      }\n\n      if (data.name === 'tool-execution') {\n        GleapEventManager.notifyEvent('tool-execution', data.data);\n        GleapAgentToolManager.getInstance().triggerToolAction(data.data);\n      }\n\n      if (data.name === 'checklist-loaded') {\n        const checklistData = data.data;\n        GleapEventManager.notifyEvent('checklist-loaded', {\n          checklistId: checklistData.id,\n          outboundId: checklistData.outbound?.id,\n          completedSteps: checklistData.completedSteps,\n          status: checklistData.status,\n          data: checklistData,\n        });\n      }\n\n      if (data.name === 'checklist-step-completed') {\n        const { checklistData, step, index } = data.data;\n        GleapEventManager.notifyEvent('checklist-step-completed', {\n          checklistId: checklistData.id,\n          outboundId: checklistData.outbound?.id,\n          stepId: step.id,\n          stepIndex: index,\n          step: step,\n          completedSteps: checklistData.completedSteps,\n          status: checklistData.status,\n          data: checklistData,\n        });\n      }\n\n      if (data.name === 'checklist-completed') {\n        const checklistData = data.data;\n        GleapEventManager.notifyEvent('checklist-completed', {\n          checklistId: checklistData.id,\n          outboundId: checklistData.outbound?.id,\n          completedSteps: checklistData.completedSteps,\n          status: checklistData.status,\n          data: checklistData,\n        });\n      }\n\n      if (data.name === 'send-feedback') {\n        if (this.sendingFeedback) {\n          return;\n        }\n\n        this.sendingFeedback = true;\n\n        const formData = data.data.formData;\n        const action = data.data.action;\n        const outboundId = data.data.outboundId;\n        const spamToken = data.data.spamToken;\n\n        const feedback = new GleapFeedback(\n          action.feedbackType,\n          'MEDIUM',\n          formData,\n          false,\n          action.excludeData,\n          outboundId,\n          spamToken\n        );\n        feedback\n          .sendFeedback()\n          .then((feedbackData) => {\n            setTimeout(() => {\n              this.sendingFeedback = false;\n            }, 1000);\n\n            this.sendMessage({\n              name: 'feedback-sent',\n              data: feedbackData,\n            });\n            GleapEventManager.notifyEvent('feedback-sent', formData);\n\n            if (outboundId && outboundId.length > 0) {\n              GleapEventManager.notifyEvent('outbound-sent', {\n                outboundId: outboundId,\n                outbound: action,\n                formData: formData,\n              });\n\n              try {\n                delete formData.reportedBy;\n              } catch (e) {}\n              Gleap.trackEvent(`outbound-${outboundId}-submitted`, formData);\n            }\n          })\n          .catch((error) => {\n            setTimeout(() => {\n              this.sendingFeedback = false;\n\n              this.sendMessage({\n                name: 'feedback-sending-failed',\n                data: 'Something went wrong, please try again.',\n              });\n              GleapEventManager.notifyEvent('error-while-sending');\n            }, 1000);\n          });\n      }\n\n      if (data.name === 'start-screen-drawing') {\n        this.showDrawingScreen(data.data);\n      }\n    });\n\n    // Add window message listener.\n    window.addEventListener('message', (event) => {\n      if (event.origin !== this.frameUrl && event.origin !== GleapBannerManager.getInstance().bannerUrl) {\n        return;\n      }\n\n      try {\n        const data = JSON.parse(event.data);\n        for (var i = 0; i < this.listeners.length; i++) {\n          if (this.listeners[i]) {\n            this.listeners[i](data);\n          }\n        }\n      } catch (exp) {}\n    });\n  }\n\n  addMessageListener(callback) {\n    this.listeners.push(callback);\n  }\n}\n","import { isMobile } from './GleapHelper';\n\nexport default class GleapMetaDataManager {\n  sessionStart = new Date();\n  appBuildNumber = '';\n  appVersionCode = '';\n  environment = 'prod';\n\n  // GleapMetaDataManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapMetaDataManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Sets the app version code.\n   * @param {string} appVersionCode\n   */\n  static setAppVersionCode(appVersionCode) {\n    this.getInstance().appVersionCode = appVersionCode;\n  }\n\n  /**\n   * Sets the app version code.\n   * @param {string} appVersionCode\n   */\n  static setAppBuildNumber(appBuildNumber) {\n    this.getInstance().appBuildNumber = appBuildNumber;\n  }\n\n  getSessionDuration() {\n    const now = new Date();\n    return Math.round((now.getTime() - this.sessionStart.getTime()) / 1000);\n  }\n\n  getMetaData() {\n    var nAgt = navigator.userAgent;\n    var browserName = navigator.appName;\n    var fullVersion = '' + parseFloat(navigator.appVersion);\n    var majorVersion = parseInt(navigator.appVersion, 10);\n    var nameOffset, verOffset, ix;\n\n    // In Opera, the true version is after \"Opera\" or after \"Version\"\n    if ((verOffset = nAgt.indexOf('Opera')) !== -1) {\n      browserName = 'Opera';\n      fullVersion = nAgt.substring(verOffset + 6);\n      if ((verOffset = nAgt.indexOf('Version')) !== -1) fullVersion = nAgt.substring(verOffset + 8);\n    }\n    // In MSIE, the true version is after \"MSIE\" in userAgent\n    else if ((verOffset = nAgt.indexOf('MSIE')) !== -1) {\n      browserName = 'Microsoft Internet Explorer';\n      fullVersion = nAgt.substring(verOffset + 5);\n    }\n    // In Chrome, the true version is after \"Chrome\"\n    else if ((verOffset = nAgt.indexOf('Chrome')) !== -1) {\n      browserName = 'Chrome';\n      fullVersion = nAgt.substring(verOffset + 7);\n    }\n    // In Safari, the true version is after \"Safari\" or after \"Version\"\n    else if ((verOffset = nAgt.indexOf('Safari')) !== -1) {\n      browserName = 'Safari';\n      fullVersion = nAgt.substring(verOffset + 7);\n      if ((verOffset = nAgt.indexOf('Version')) !== -1) fullVersion = nAgt.substring(verOffset + 8);\n    }\n    // In Firefox, the true version is after \"Firefox\"\n    else if ((verOffset = nAgt.indexOf('Firefox')) !== -1) {\n      browserName = 'Firefox';\n      fullVersion = nAgt.substring(verOffset + 8);\n    }\n    // In most other browsers, \"name/version\" is at the end of userAgent\n    else if ((nameOffset = nAgt.lastIndexOf(' ') + 1) < (verOffset = nAgt.lastIndexOf('/'))) {\n      browserName = nAgt.substring(nameOffset, verOffset);\n      fullVersion = nAgt.substring(verOffset + 1);\n      if (browserName.toLowerCase() === browserName.toUpperCase()) {\n        browserName = navigator.appName;\n      }\n    }\n    // trim the fullVersion string at semicolon/space if present\n    if ((ix = fullVersion.indexOf(';')) !== -1) fullVersion = fullVersion.substring(0, ix);\n    if ((ix = fullVersion.indexOf(' ')) !== -1) fullVersion = fullVersion.substring(0, ix);\n\n    majorVersion = parseInt('' + fullVersion, 10);\n    if (isNaN(majorVersion)) {\n      fullVersion = '' + parseFloat(navigator.appVersion);\n      majorVersion = parseInt(navigator.appVersion, 10);\n    }\n\n    var OSName = 'Unknown OS';\n    if (navigator.appVersion.indexOf('Win') !== -1) OSName = 'Windows';\n    if (navigator.appVersion.indexOf('Mac') !== -1) OSName = 'MacOS';\n    if (navigator.appVersion.indexOf('X11') !== -1) OSName = 'UNIX';\n    if (navigator.appVersion.indexOf('Linux') !== -1) OSName = 'Linux';\n    if (navigator.appVersion.indexOf('iPad') !== -1) OSName = 'iPad';\n    if (navigator.appVersion.indexOf('iPhone') !== -1) OSName = 'iPhone';\n    if (navigator.appVersion.indexOf('Android') !== -1) OSName = 'Android';\n\n    return {\n      browserName: browserName + '(' + fullVersion + ')',\n      userAgent: nAgt,\n      browser: browserName,\n      systemName: OSName,\n      buildVersionNumber: this.appBuildNumber,\n      releaseVersionNumber: this.appVersionCode,\n      sessionDuration: this.getSessionDuration(),\n      devicePixelRatio: window.devicePixelRatio,\n      screenWidth: window.screen.width,\n      screenHeight: window.screen.height,\n      innerWidth: window.innerWidth,\n      innerHeight: window.innerHeight,\n      currentUrl: window.location.href,\n      language: navigator.language || navigator.userLanguage,\n      mobile: isMobile(),\n      sdkVersion: SDK_VERSION,\n      sdkType: 'javascript',\n      environment: this.environment,\n    };\n  }\n}\n","import { truncateString } from './GleapHelper';\n\nexport default class GleapConsoleLogManager {\n  logArray = [];\n  disabled = false;\n  originalConsoleLog;\n  logMaxLength = 500;\n\n  // GleapConsoleLogManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapConsoleLogManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Return the console logs\n   * @returns {any[]} logs\n   */\n  getLogs() {\n    return this.logArray;\n  }\n\n  /**\n   * Revert console log overwrite.\n   */\n  stop() {\n    this.disabled = true;\n    if (this.originalConsoleLog) {\n      window.console = this.originalConsoleLog;\n    }\n  }\n\n  /**\n   * Add message with log level to logs.\n   * @param {*} message\n   * @param {*} logLevel\n   * @returns\n   */\n  addLog(message, logLevel = 'INFO') {\n    if (!message || message.length <= 0) {\n      return;\n    }\n\n    this.logArray.push({\n      log: truncateString(message, 1000),\n      date: new Date(),\n      priority: logLevel,\n    });\n\n    if (this.logArray.length > this.logMaxLength) {\n      this.logArray.shift();\n    }\n  }\n\n  /**\n   * Add entry to logs.\n   * @param {*} args\n   * @param {*} logLevel\n   * @returns\n   */\n  addLogWithArgs(args, logLevel) {\n    if (!args || args.length <= 0) {\n      return;\n    }\n\n    var log = '';\n    try {\n      for (var i = 0; i < args.length; i++) {\n        log += args[i] + ' ';\n      }\n    } catch (exp) {}\n\n    this.addLog(log, logLevel);\n  }\n\n  /**\n   * Start console log overwrite.\n   */\n  start() {\n    if (this.disabled) {\n      return;\n    }\n\n    const self = this;\n    window.console = (function (origConsole) {\n      if (!window.console || !origConsole) {\n        origConsole = {};\n      }\n\n      self.originalConsoleLog = origConsole;\n\n      return {\n        ...origConsole,\n        log: function () {\n          self.addLogWithArgs(arguments, 'INFO');\n          origConsole.log && origConsole.log.apply(origConsole, arguments);\n        },\n        warn: function () {\n          self.addLogWithArgs(arguments, 'WARNING');\n          origConsole.warn && origConsole.warn.apply(origConsole, arguments);\n        },\n        error: function () {\n          self.addLogWithArgs(arguments, 'ERROR');\n          origConsole.error && origConsole.error.apply(origConsole, arguments);\n        },\n        info: function (v) {\n          self.addLogWithArgs(arguments, 'INFO');\n          origConsole.info && origConsole.info.apply(origConsole, arguments);\n        },\n      };\n    })(window.console);\n  }\n}\n","import { GleapConsoleLogManager, GleapFrameManager, handleGleapLink } from './Gleap';\nimport { getDOMElementDescription } from './GleapHelper';\n\nexport default class GleapClickListener {\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapClickListener();\n    }\n    return this.instance;\n  }\n\n  start() {\n    document.addEventListener('click', (e) => {\n      if (!e.target) {\n        return;\n      }\n\n      if (e.target.tagName === 'A' && e.target.protocol === 'gleap:') {\n        e.preventDefault();\n\n        const href = e.target.href;\n        handleGleapLink(href);\n      }\n\n      if (!GleapFrameManager.getInstance().isOpened()) {\n        GleapConsoleLogManager.getInstance().addLog(getDOMElementDescription(e.target), 'CLICK');\n      }\n    });\n  }\n}\n","import { gleapDataParser } from './GleapHelper';\n\nexport default class GleapCustomDataManager {\n  customData = {};\n  ticketAttributes = {};\n\n  // GleapCustomDataManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapCustomDataManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Returns the custom data object\n   * @returns {*}\n   */\n  getCustomData() {\n    return this.customData;\n  }\n\n  /**\n   * Set custom data that will be attached to the bug-report.\n   * @param {*} data\n   */\n  attachCustomData(data) {\n    this.customData = Object.assign(this.customData, gleapDataParser(data));\n  }\n\n  /**\n   * Add one key value pair to the custom data object\n   * @param {*} key The key of the custom data entry you want to add.\n   * @param {*} value The custom data you want to add.\n   */\n  setCustomData(key, value) {\n    this.customData[key] = value;\n  }\n\n  /**\n   * Remove one key value pair of the custom data object\n   * @param {*} key The key of the custom data entry you want to remove.\n   */\n  removeCustomData(key) {\n    delete this.customData[key];\n  }\n\n  /**\n   * Clear the custom data\n   */\n  clearCustomData() {\n    this.customData = {};\n  }\n\n  /**\n   * This method is used to set ticket attributes programmatically.\n   * @param {*} key The key of the attribute you want to add.\n   * @param {*} value The value to set.\n   */\n  setTicketAttribute(key, value) {\n    this.ticketAttributes[key] = value;\n  }\n\n  /**\n   * This method is used to unset ticket attributes programmatically.\n   * @param {*} key The key of the attribute you want to unset.\n   */\n  unsetTicketAttribute(key) {\n    delete this.ticketAttributes[key];\n  }\n\n  /**\n   * This method is used to clear ticket attributes programmatically.\n   */\n  clearTicketAttributes() {\n    this.ticketAttributes = {};\n  }\n\n  getTicketAttributes() {\n    return this.ticketAttributes;\n  }\n}\n","export default class GleapCustomActionManager {\n  customActionCallbacks = [];\n\n  // GleapCustomActionManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapCustomActionManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Register custom action\n   */\n  static registerCustomAction(customAction) {\n    const instance = this.getInstance();\n    if (instance.customActionCallbacks) {\n      instance.customActionCallbacks.push(customAction);\n    }\n  }\n\n  /**\n   * Triggers a custom action\n   */\n  static triggerCustomAction(name, data) {\n    const instance = this.getInstance();\n    if (instance.customActionCallbacks) {\n      for (var i = 0; i < instance.customActionCallbacks.length; i++) {\n        var callback = instance.customActionCallbacks[i];\n        if (callback) {\n          callback({\n            name,\n            ...(data ? data : {}),\n          });\n        }\n      }\n    }\n  }\n}\n","var __defProp = Object.defineProperty;\nvar __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== \"symbol\" ? key + \"\" : key, value);\nvar _a;\nvar __defProp$1 = Object.defineProperty;\nvar __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __publicField$1 = (obj, key, value) => __defNormalProp$1(obj, typeof key !== \"symbol\" ? key + \"\" : key, value);\nvar NodeType$3 = /* @__PURE__ */ ((NodeType2) => {\n  NodeType2[NodeType2[\"Document\"] = 0] = \"Document\";\n  NodeType2[NodeType2[\"DocumentType\"] = 1] = \"DocumentType\";\n  NodeType2[NodeType2[\"Element\"] = 2] = \"Element\";\n  NodeType2[NodeType2[\"Text\"] = 3] = \"Text\";\n  NodeType2[NodeType2[\"CDATA\"] = 4] = \"CDATA\";\n  NodeType2[NodeType2[\"Comment\"] = 5] = \"Comment\";\n  return NodeType2;\n})(NodeType$3 || {});\nconst testableAccessors$1 = {\n  Node: [\n    \"childNodes\",\n    \"parentNode\",\n    \"parentElement\",\n    \"textContent\",\n    \"ownerDocument\"\n  ],\n  ShadowRoot: [\"host\", \"styleSheets\"],\n  Element: [\"shadowRoot\", \"querySelector\", \"querySelectorAll\"],\n  MutationObserver: []\n};\nconst testableMethods$1 = {\n  Node: [\"contains\", \"getRootNode\"],\n  ShadowRoot: [\"getSelection\"],\n  Element: [],\n  MutationObserver: [\"constructor\"]\n};\nconst untaintedBasePrototype$1 = {};\nconst isAngularZonePresent$1 = () => {\n  return !!globalThis.Zone;\n};\nfunction getUntaintedPrototype$1(key) {\n  if (untaintedBasePrototype$1[key])\n    return untaintedBasePrototype$1[key];\n  const defaultObj = globalThis[key];\n  const defaultPrototype = defaultObj.prototype;\n  const accessorNames = key in testableAccessors$1 ? testableAccessors$1[key] : void 0;\n  const isUntaintedAccessors = Boolean(\n    accessorNames && // @ts-expect-error 2345\n    accessorNames.every(\n      (accessor) => {\n        var _a2, _b;\n        return Boolean(\n          (_b = (_a2 = Object.getOwnPropertyDescriptor(defaultPrototype, accessor)) == null ? void 0 : _a2.get) == null ? void 0 : _b.toString().includes(\"[native code]\")\n        );\n      }\n    )\n  );\n  const methodNames = key in testableMethods$1 ? testableMethods$1[key] : void 0;\n  const isUntaintedMethods = Boolean(\n    methodNames && methodNames.every(\n      // @ts-expect-error 2345\n      (method) => {\n        var _a2;\n        return typeof defaultPrototype[method] === \"function\" && ((_a2 = defaultPrototype[method]) == null ? void 0 : _a2.toString().includes(\"[native code]\"));\n      }\n    )\n  );\n  if (isUntaintedAccessors && isUntaintedMethods && !isAngularZonePresent$1()) {\n    untaintedBasePrototype$1[key] = defaultObj.prototype;\n    return defaultObj.prototype;\n  }\n  try {\n    const iframeEl = document.createElement(\"iframe\");\n    document.body.appendChild(iframeEl);\n    const win = iframeEl.contentWindow;\n    if (!win) return defaultObj.prototype;\n    const untaintedObject = win[key].prototype;\n    document.body.removeChild(iframeEl);\n    if (!untaintedObject) return defaultPrototype;\n    return untaintedBasePrototype$1[key] = untaintedObject;\n  } catch {\n    return defaultPrototype;\n  }\n}\nconst untaintedAccessorCache$1 = {};\nfunction getUntaintedAccessor$1(key, instance, accessor) {\n  var _a2;\n  const cacheKey = `${key}.${String(accessor)}`;\n  if (untaintedAccessorCache$1[cacheKey])\n    return untaintedAccessorCache$1[cacheKey].call(\n      instance\n    );\n  const untaintedPrototype = getUntaintedPrototype$1(key);\n  const untaintedAccessor = (_a2 = Object.getOwnPropertyDescriptor(\n    untaintedPrototype,\n    accessor\n  )) == null ? void 0 : _a2.get;\n  if (!untaintedAccessor) return instance[accessor];\n  untaintedAccessorCache$1[cacheKey] = untaintedAccessor;\n  return untaintedAccessor.call(instance);\n}\nconst untaintedMethodCache$1 = {};\nfunction getUntaintedMethod$1(key, instance, method) {\n  const cacheKey = `${key}.${String(method)}`;\n  if (untaintedMethodCache$1[cacheKey])\n    return untaintedMethodCache$1[cacheKey].bind(\n      instance\n    );\n  const untaintedPrototype = getUntaintedPrototype$1(key);\n  const untaintedMethod = untaintedPrototype[method];\n  if (typeof untaintedMethod !== \"function\") return instance[method];\n  untaintedMethodCache$1[cacheKey] = untaintedMethod;\n  return untaintedMethod.bind(instance);\n}\nfunction ownerDocument$1(n2) {\n  return getUntaintedAccessor$1(\"Node\", n2, \"ownerDocument\");\n}\nfunction childNodes$1(n2) {\n  return getUntaintedAccessor$1(\"Node\", n2, \"childNodes\");\n}\nfunction parentNode$1(n2) {\n  return getUntaintedAccessor$1(\"Node\", n2, \"parentNode\");\n}\nfunction parentElement$1(n2) {\n  return getUntaintedAccessor$1(\"Node\", n2, \"parentElement\");\n}\nfunction textContent$1(n2) {\n  return getUntaintedAccessor$1(\"Node\", n2, \"textContent\");\n}\nfunction contains$1(n2, other) {\n  return getUntaintedMethod$1(\"Node\", n2, \"contains\")(other);\n}\nfunction getRootNode$1(n2) {\n  return getUntaintedMethod$1(\"Node\", n2, \"getRootNode\")();\n}\nfunction host$1(n2) {\n  if (!n2 || !(\"host\" in n2)) return null;\n  return getUntaintedAccessor$1(\"ShadowRoot\", n2, \"host\");\n}\nfunction styleSheets$1(n2) {\n  return n2.styleSheets;\n}\nfunction shadowRoot$1(n2) {\n  if (!n2 || !(\"shadowRoot\" in n2)) return null;\n  return getUntaintedAccessor$1(\"Element\", n2, \"shadowRoot\");\n}\nfunction querySelector$1(n2, selectors) {\n  return getUntaintedAccessor$1(\"Element\", n2, \"querySelector\")(selectors);\n}\nfunction querySelectorAll$1(n2, selectors) {\n  return getUntaintedAccessor$1(\"Element\", n2, \"querySelectorAll\")(selectors);\n}\nfunction mutationObserverCtor$1() {\n  return getUntaintedPrototype$1(\"MutationObserver\").constructor;\n}\nfunction patch$1(source, name, replacement) {\n  try {\n    if (!(name in source)) {\n      return () => {\n      };\n    }\n    const original = source[name];\n    const wrapped = replacement(original);\n    if (typeof wrapped === \"function\") {\n      wrapped.prototype = wrapped.prototype || {};\n      Object.defineProperties(wrapped, {\n        __rrweb_original__: {\n          enumerable: false,\n          value: original\n        }\n      });\n    }\n    source[name] = wrapped;\n    return () => {\n      source[name] = original;\n    };\n  } catch {\n    return () => {\n    };\n  }\n}\nconst index$1 = {\n  ownerDocument: ownerDocument$1,\n  childNodes: childNodes$1,\n  parentNode: parentNode$1,\n  parentElement: parentElement$1,\n  textContent: textContent$1,\n  contains: contains$1,\n  getRootNode: getRootNode$1,\n  host: host$1,\n  styleSheets: styleSheets$1,\n  shadowRoot: shadowRoot$1,\n  querySelector: querySelector$1,\n  querySelectorAll: querySelectorAll$1,\n  mutationObserver: mutationObserverCtor$1,\n  patch: patch$1\n};\nfunction isElement(n2) {\n  return n2.nodeType === n2.ELEMENT_NODE;\n}\nfunction isShadowRoot(n2) {\n  const hostEl = (\n    // anchor and textarea elements also have a `host` property\n    // but only shadow roots have a `mode` property\n    n2 && \"host\" in n2 && \"mode\" in n2 && index$1.host(n2) || null\n  );\n  return Boolean(\n    hostEl && \"shadowRoot\" in hostEl && index$1.shadowRoot(hostEl) === n2\n  );\n}\nfunction isNativeShadowDom(shadowRoot2) {\n  return Object.prototype.toString.call(shadowRoot2) === \"[object ShadowRoot]\";\n}\nfunction fixBrowserCompatibilityIssuesInCSS(cssText) {\n  if (cssText.includes(\" background-clip: text;\") && !cssText.includes(\" -webkit-background-clip: text;\")) {\n    cssText = cssText.replace(\n      /\\sbackground-clip:\\s*text;/g,\n      \" -webkit-background-clip: text; background-clip: text;\"\n    );\n  }\n  return cssText;\n}\nfunction escapeImportStatement(rule2) {\n  const { cssText } = rule2;\n  if (cssText.split('\"').length < 3) return cssText;\n  const statement = [\"@import\", `url(${JSON.stringify(rule2.href)})`];\n  if (rule2.layerName === \"\") {\n    statement.push(`layer`);\n  } else if (rule2.layerName) {\n    statement.push(`layer(${rule2.layerName})`);\n  }\n  if (rule2.supportsText) {\n    statement.push(`supports(${rule2.supportsText})`);\n  }\n  if (rule2.media.length) {\n    statement.push(rule2.media.mediaText);\n  }\n  return statement.join(\" \") + \";\";\n}\nfunction stringifyStylesheet(s2) {\n  try {\n    const rules2 = s2.rules || s2.cssRules;\n    if (!rules2) {\n      return null;\n    }\n    let sheetHref = s2.href;\n    if (!sheetHref && s2.ownerNode) {\n      sheetHref = s2.ownerNode.baseURI;\n    }\n    const stringifiedRules = Array.from(\n      rules2,\n      (rule2) => stringifyRule(rule2, sheetHref)\n    ).join(\"\");\n    return fixBrowserCompatibilityIssuesInCSS(stringifiedRules);\n  } catch (error) {\n    return null;\n  }\n}\nfunction stringifyRule(rule2, sheetHref) {\n  if (isCSSImportRule(rule2)) {\n    let importStringified;\n    try {\n      importStringified = // for same-origin stylesheets,\n      // we can access the imported stylesheet rules directly\n      stringifyStylesheet(rule2.styleSheet) || // work around browser issues with the raw string `@import url(...)` statement\n      escapeImportStatement(rule2);\n    } catch (error) {\n      importStringified = rule2.cssText;\n    }\n    if (rule2.styleSheet.href) {\n      return absolutifyURLs(importStringified, rule2.styleSheet.href);\n    }\n    return importStringified;\n  } else {\n    let ruleStringified = rule2.cssText;\n    if (isCSSStyleRule(rule2) && rule2.selectorText.includes(\":\")) {\n      ruleStringified = fixSafariColons(ruleStringified);\n    }\n    if (sheetHref) {\n      return absolutifyURLs(ruleStringified, sheetHref);\n    }\n    return ruleStringified;\n  }\n}\nfunction fixSafariColons(cssStringified) {\n  const regex = /(\\[(?:[\\w-]+)[^\\\\])(:(?:[\\w-]+)\\])/gm;\n  return cssStringified.replace(regex, \"$1\\\\$2\");\n}\nfunction isCSSImportRule(rule2) {\n  return \"styleSheet\" in rule2;\n}\nfunction isCSSStyleRule(rule2) {\n  return \"selectorText\" in rule2;\n}\nclass Mirror {\n  constructor() {\n    __publicField$1(this, \"idNodeMap\", /* @__PURE__ */ new Map());\n    __publicField$1(this, \"nodeMetaMap\", /* @__PURE__ */ new WeakMap());\n  }\n  getId(n2) {\n    var _a2;\n    if (!n2) return -1;\n    const id = (_a2 = this.getMeta(n2)) == null ? void 0 : _a2.id;\n    return id ?? -1;\n  }\n  getNode(id) {\n    return this.idNodeMap.get(id) || null;\n  }\n  getIds() {\n    return Array.from(this.idNodeMap.keys());\n  }\n  getMeta(n2) {\n    return this.nodeMetaMap.get(n2) || null;\n  }\n  // removes the node from idNodeMap\n  // doesn't remove the node from nodeMetaMap\n  removeNodeFromMap(n2) {\n    const id = this.getId(n2);\n    this.idNodeMap.delete(id);\n    if (n2.childNodes) {\n      n2.childNodes.forEach(\n        (childNode) => this.removeNodeFromMap(childNode)\n      );\n    }\n  }\n  has(id) {\n    return this.idNodeMap.has(id);\n  }\n  hasNode(node2) {\n    return this.nodeMetaMap.has(node2);\n  }\n  add(n2, meta) {\n    const id = meta.id;\n    this.idNodeMap.set(id, n2);\n    this.nodeMetaMap.set(n2, meta);\n  }\n  replace(id, n2) {\n    const oldNode = this.getNode(id);\n    if (oldNode) {\n      const meta = this.nodeMetaMap.get(oldNode);\n      if (meta) this.nodeMetaMap.set(n2, meta);\n    }\n    this.idNodeMap.set(id, n2);\n  }\n  reset() {\n    this.idNodeMap = /* @__PURE__ */ new Map();\n    this.nodeMetaMap = /* @__PURE__ */ new WeakMap();\n  }\n}\nfunction createMirror$2() {\n  return new Mirror();\n}\nfunction maskInputValue({\n  element,\n  maskInputOptions,\n  tagName,\n  type,\n  value,\n  maskInputFn\n}) {\n  let text = value || \"\";\n  const actualType = type && toLowerCase(type);\n  if (maskInputOptions[tagName.toLowerCase()] || actualType && maskInputOptions[actualType]) {\n    if (maskInputFn) {\n      text = maskInputFn(text, element);\n    } else {\n      text = \"*\".repeat(text.length);\n    }\n  }\n  return text;\n}\nfunction toLowerCase(str) {\n  return str.toLowerCase();\n}\nconst ORIGINAL_ATTRIBUTE_NAME = \"__rrweb_original__\";\nfunction is2DCanvasBlank(canvas) {\n  const ctx = canvas.getContext(\"2d\");\n  if (!ctx) return true;\n  const chunkSize = 50;\n  for (let x2 = 0; x2 < canvas.width; x2 += chunkSize) {\n    for (let y = 0; y < canvas.height; y += chunkSize) {\n      const getImageData = ctx.getImageData;\n      const originalGetImageData = ORIGINAL_ATTRIBUTE_NAME in getImageData ? getImageData[ORIGINAL_ATTRIBUTE_NAME] : getImageData;\n      const pixelBuffer = new Uint32Array(\n        // eslint-disable-next-line @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-unsafe-member-access\n        originalGetImageData.call(\n          ctx,\n          x2,\n          y,\n          Math.min(chunkSize, canvas.width - x2),\n          Math.min(chunkSize, canvas.height - y)\n        ).data.buffer\n      );\n      if (pixelBuffer.some((pixel) => pixel !== 0)) return false;\n    }\n  }\n  return true;\n}\nfunction getInputType(element) {\n  const type = element.type;\n  return element.hasAttribute(\"data-rr-is-password\") ? \"password\" : type ? (\n    // eslint-disable-next-line @typescript-eslint/no-unnecessary-type-assertion\n    toLowerCase(type)\n  ) : null;\n}\nfunction extractFileExtension(path, baseURL) {\n  let url;\n  try {\n    url = new URL(path, baseURL ?? window.location.href);\n  } catch (err) {\n    return null;\n  }\n  const regex = /\\.([0-9a-z]+)(?:$)/i;\n  const match = url.pathname.match(regex);\n  return (match == null ? void 0 : match[1]) ?? null;\n}\nfunction extractOrigin(url) {\n  let origin = \"\";\n  if (url.indexOf(\"//\") > -1) {\n    origin = url.split(\"/\").slice(0, 3).join(\"/\");\n  } else {\n    origin = url.split(\"/\")[0];\n  }\n  origin = origin.split(\"?\")[0];\n  return origin;\n}\nconst URL_IN_CSS_REF = /url\\((?:(')([^']*)'|(\")(.*?)\"|([^)]*))\\)/gm;\nconst URL_PROTOCOL_MATCH = /^(?:[a-z+]+:)?\\/\\//i;\nconst URL_WWW_MATCH = /^www\\..*/i;\nconst DATA_URI = /^(data:)([^,]*),(.*)/i;\nfunction absolutifyURLs(cssText, href) {\n  return (cssText || \"\").replace(\n    URL_IN_CSS_REF,\n    (origin, quote1, path1, quote2, path2, path3) => {\n      const filePath = path1 || path2 || path3;\n      const maybeQuote = quote1 || quote2 || \"\";\n      if (!filePath) {\n        return origin;\n      }\n      if (URL_PROTOCOL_MATCH.test(filePath) || URL_WWW_MATCH.test(filePath)) {\n        return `url(${maybeQuote}${filePath}${maybeQuote})`;\n      }\n      if (DATA_URI.test(filePath)) {\n        return `url(${maybeQuote}${filePath}${maybeQuote})`;\n      }\n      if (filePath[0] === \"/\") {\n        return `url(${maybeQuote}${extractOrigin(href) + filePath}${maybeQuote})`;\n      }\n      const stack = href.split(\"/\");\n      const parts = filePath.split(\"/\");\n      stack.pop();\n      for (const part of parts) {\n        if (part === \".\") {\n          continue;\n        } else if (part === \"..\") {\n          stack.pop();\n        } else {\n          stack.push(part);\n        }\n      }\n      return `url(${maybeQuote}${stack.join(\"/\")}${maybeQuote})`;\n    }\n  );\n}\nfunction normalizeCssString(cssText, _testNoPxNorm = false) {\n  if (_testNoPxNorm) {\n    return cssText.replace(/(\\/\\*[^*]*\\*\\/)|[\\s;]/g, \"\");\n  } else {\n    return cssText.replace(/(\\/\\*[^*]*\\*\\/)|[\\s;]/g, \"\").replace(/0px/g, \"0\");\n  }\n}\nfunction splitCssText(cssText, style, _testNoPxNorm = false) {\n  const childNodes2 = Array.from(style.childNodes);\n  const splits = [];\n  let iterCount = 0;\n  if (childNodes2.length > 1 && cssText && typeof cssText === \"string\") {\n    let cssTextNorm = normalizeCssString(cssText, _testNoPxNorm);\n    const normFactor = cssTextNorm.length / cssText.length;\n    for (let i2 = 1; i2 < childNodes2.length; i2++) {\n      if (childNodes2[i2].textContent && typeof childNodes2[i2].textContent === \"string\") {\n        const textContentNorm = normalizeCssString(\n          childNodes2[i2].textContent,\n          _testNoPxNorm\n        );\n        const jLimit = 100;\n        let j = 3;\n        for (; j < textContentNorm.length; j++) {\n          if (\n            // keep consuming css identifiers (to get a decent chunk more quickly)\n            textContentNorm[j].match(/[a-zA-Z0-9]/) || // substring needs to be unique to this section\n            textContentNorm.indexOf(textContentNorm.substring(0, j), 1) !== -1\n          ) {\n            continue;\n          }\n          break;\n        }\n        for (; j < textContentNorm.length; j++) {\n          let startSubstring = textContentNorm.substring(0, j);\n          let cssNormSplits = cssTextNorm.split(startSubstring);\n          let splitNorm = -1;\n          if (cssNormSplits.length === 2) {\n            splitNorm = cssNormSplits[0].length;\n          } else if (cssNormSplits.length > 2 && cssNormSplits[0] === \"\" && childNodes2[i2 - 1].textContent !== \"\") {\n            splitNorm = cssTextNorm.indexOf(startSubstring, 1);\n          } else if (cssNormSplits.length === 1) {\n            startSubstring = startSubstring.substring(\n              0,\n              startSubstring.length - 1\n            );\n            cssNormSplits = cssTextNorm.split(startSubstring);\n            if (cssNormSplits.length <= 1) {\n              splits.push(cssText);\n              return splits;\n            }\n            j = jLimit + 1;\n          } else if (j === textContentNorm.length - 1) {\n            splitNorm = cssTextNorm.indexOf(startSubstring);\n          }\n          if (cssNormSplits.length >= 2 && j > jLimit) {\n            const prevTextContent = childNodes2[i2 - 1].textContent;\n            if (prevTextContent && typeof prevTextContent === \"string\") {\n              const prevMinLength = normalizeCssString(prevTextContent).length;\n              splitNorm = cssTextNorm.indexOf(startSubstring, prevMinLength);\n            }\n            if (splitNorm === -1) {\n              splitNorm = cssNormSplits[0].length;\n            }\n          }\n          if (splitNorm !== -1) {\n            let k = Math.floor(splitNorm / normFactor);\n            for (; k > 0 && k < cssText.length; ) {\n              iterCount += 1;\n              if (iterCount > 50 * childNodes2.length) {\n                splits.push(cssText);\n                return splits;\n              }\n              const normPart = normalizeCssString(\n                cssText.substring(0, k),\n                _testNoPxNorm\n              );\n              if (normPart.length === splitNorm) {\n                splits.push(cssText.substring(0, k));\n                cssText = cssText.substring(k);\n                cssTextNorm = cssTextNorm.substring(splitNorm);\n                break;\n              } else if (normPart.length < splitNorm) {\n                k += Math.max(\n                  1,\n                  Math.floor((splitNorm - normPart.length) / normFactor)\n                );\n              } else {\n                k -= Math.max(\n                  1,\n                  Math.floor((normPart.length - splitNorm) * normFactor)\n                );\n              }\n            }\n            break;\n          }\n        }\n      }\n    }\n  }\n  splits.push(cssText);\n  return splits;\n}\nfunction markCssSplits(cssText, style) {\n  return splitCssText(cssText, style).join(\"/* rr_split */\");\n}\nlet _id = 1;\nconst tagNameRegex = new RegExp(\"[^a-z0-9-_:]\");\nconst IGNORED_NODE = -2;\nfunction genId() {\n  return _id++;\n}\nfunction getValidTagName$1(element) {\n  if (element instanceof HTMLFormElement) {\n    return \"form\";\n  }\n  const processedTagName = toLowerCase(element.tagName);\n  if (tagNameRegex.test(processedTagName)) {\n    return \"div\";\n  }\n  return processedTagName;\n}\nlet canvasService;\nlet canvasCtx;\nconst SRCSET_NOT_SPACES = /^[^ \\t\\n\\r\\u000c]+/;\nconst SRCSET_COMMAS_OR_SPACES = /^[, \\t\\n\\r\\u000c]+/;\nfunction getAbsoluteSrcsetString(doc, attributeValue) {\n  if (attributeValue.trim() === \"\") {\n    return attributeValue;\n  }\n  let pos = 0;\n  function collectCharacters(regEx) {\n    let chars2;\n    const match = regEx.exec(attributeValue.substring(pos));\n    if (match) {\n      chars2 = match[0];\n      pos += chars2.length;\n      return chars2;\n    }\n    return \"\";\n  }\n  const output = [];\n  while (true) {\n    collectCharacters(SRCSET_COMMAS_OR_SPACES);\n    if (pos >= attributeValue.length) {\n      break;\n    }\n    let url = collectCharacters(SRCSET_NOT_SPACES);\n    if (url.slice(-1) === \",\") {\n      url = absoluteToDoc(doc, url.substring(0, url.length - 1));\n      output.push(url);\n    } else {\n      let descriptorsStr = \"\";\n      url = absoluteToDoc(doc, url);\n      let inParens = false;\n      while (true) {\n        const c2 = attributeValue.charAt(pos);\n        if (c2 === \"\") {\n          output.push((url + descriptorsStr).trim());\n          break;\n        } else if (!inParens) {\n          if (c2 === \",\") {\n            pos += 1;\n            output.push((url + descriptorsStr).trim());\n            break;\n          } else if (c2 === \"(\") {\n            inParens = true;\n          }\n        } else {\n          if (c2 === \")\") {\n            inParens = false;\n          }\n        }\n        descriptorsStr += c2;\n        pos += 1;\n      }\n    }\n  }\n  return output.join(\", \");\n}\nconst cachedDocument = /* @__PURE__ */ new WeakMap();\nfunction absoluteToDoc(doc, attributeValue) {\n  if (!attributeValue || attributeValue.trim() === \"\") {\n    return attributeValue;\n  }\n  return getHref(doc, attributeValue);\n}\nfunction isSVGElement(el) {\n  return Boolean(el.tagName === \"svg\" || el.ownerSVGElement);\n}\nfunction getHref(doc, customHref) {\n  let a2 = cachedDocument.get(doc);\n  if (!a2) {\n    a2 = doc.createElement(\"a\");\n    cachedDocument.set(doc, a2);\n  }\n  if (!customHref) {\n    customHref = \"\";\n  } else if (customHref.startsWith(\"blob:\") || customHref.startsWith(\"data:\")) {\n    return customHref;\n  }\n  a2.setAttribute(\"href\", customHref);\n  return a2.href;\n}\nfunction transformAttribute(doc, tagName, name, value) {\n  if (!value) {\n    return value;\n  }\n  if (name === \"src\" || name === \"href\" && !(tagName === \"use\" && value[0] === \"#\")) {\n    return absoluteToDoc(doc, value);\n  } else if (name === \"xlink:href\" && value[0] !== \"#\") {\n    return absoluteToDoc(doc, value);\n  } else if (name === \"background\" && [\"table\", \"td\", \"th\"].includes(tagName)) {\n    return absoluteToDoc(doc, value);\n  } else if (name === \"srcset\") {\n    return getAbsoluteSrcsetString(doc, value);\n  } else if (name === \"style\") {\n    return absolutifyURLs(value, getHref(doc));\n  } else if (tagName === \"object\" && name === \"data\") {\n    return absoluteToDoc(doc, value);\n  }\n  return value;\n}\nfunction ignoreAttribute(tagName, name, _value) {\n  return [\"video\", \"audio\"].includes(tagName) && name === \"autoplay\";\n}\nfunction _isBlockedElement(element, blockClass, blockSelector) {\n  try {\n    if (typeof blockClass === \"string\") {\n      if (element.classList.contains(blockClass)) {\n        return true;\n      }\n    } else {\n      for (let eIndex = element.classList.length; eIndex--; ) {\n        const className = element.classList[eIndex];\n        if (blockClass.test(className)) {\n          return true;\n        }\n      }\n    }\n    if (blockSelector) {\n      return element.matches(blockSelector);\n    }\n  } catch (e2) {\n  }\n  return false;\n}\nfunction classMatchesRegex(node2, regex, checkAncestors) {\n  if (!node2) return false;\n  if (node2.nodeType !== node2.ELEMENT_NODE) {\n    if (!checkAncestors) return false;\n    return classMatchesRegex(index$1.parentNode(node2), regex, checkAncestors);\n  }\n  for (let eIndex = node2.classList.length; eIndex--; ) {\n    const className = node2.classList[eIndex];\n    if (regex.test(className)) {\n      return true;\n    }\n  }\n  if (!checkAncestors) return false;\n  return classMatchesRegex(index$1.parentNode(node2), regex, checkAncestors);\n}\nfunction needMaskingText(node2, maskTextClass, maskTextSelector, checkAncestors) {\n  let el;\n  if (isElement(node2)) {\n    el = node2;\n    if (!index$1.childNodes(el).length) {\n      return false;\n    }\n  } else if (index$1.parentElement(node2) === null) {\n    return false;\n  } else {\n    el = index$1.parentElement(node2);\n  }\n  try {\n    if (typeof maskTextClass === \"string\") {\n      if (checkAncestors) {\n        if (el.closest(`.${maskTextClass}`)) return true;\n      } else {\n        if (el.classList.contains(maskTextClass)) return true;\n      }\n    } else {\n      if (classMatchesRegex(el, maskTextClass, checkAncestors)) return true;\n    }\n    if (maskTextSelector) {\n      if (checkAncestors) {\n        if (el.closest(maskTextSelector)) return true;\n      } else {\n        if (el.matches(maskTextSelector)) return true;\n      }\n    }\n  } catch (e2) {\n  }\n  return false;\n}\nfunction onceIframeLoaded(iframeEl, listener, iframeLoadTimeout) {\n  const win = iframeEl.contentWindow;\n  if (!win) {\n    return;\n  }\n  let fired = false;\n  let readyState;\n  try {\n    readyState = win.document.readyState;\n  } catch (error) {\n    return;\n  }\n  if (readyState !== \"complete\") {\n    const timer = setTimeout(() => {\n      if (!fired) {\n        listener();\n        fired = true;\n      }\n    }, iframeLoadTimeout);\n    iframeEl.addEventListener(\"load\", () => {\n      clearTimeout(timer);\n      fired = true;\n      listener();\n    });\n    return;\n  }\n  const blankUrl = \"about:blank\";\n  if (win.location.href !== blankUrl || iframeEl.src === blankUrl || iframeEl.src === \"\") {\n    setTimeout(listener, 0);\n    return iframeEl.addEventListener(\"load\", listener);\n  }\n  iframeEl.addEventListener(\"load\", listener);\n}\nfunction onceStylesheetLoaded(link, listener, styleSheetLoadTimeout) {\n  let fired = false;\n  let styleSheetLoaded;\n  try {\n    styleSheetLoaded = link.sheet;\n  } catch (error) {\n    return;\n  }\n  if (styleSheetLoaded) return;\n  const timer = setTimeout(() => {\n    if (!fired) {\n      listener();\n      fired = true;\n    }\n  }, styleSheetLoadTimeout);\n  link.addEventListener(\"load\", () => {\n    clearTimeout(timer);\n    fired = true;\n    listener();\n  });\n}\nfunction serializeNode(n2, options) {\n  const {\n    doc,\n    mirror: mirror2,\n    blockClass,\n    blockSelector,\n    needsMask,\n    inlineStylesheet,\n    maskInputOptions = {},\n    maskTextFn,\n    maskInputFn,\n    dataURLOptions = {},\n    inlineImages,\n    recordCanvas,\n    keepIframeSrcFn,\n    newlyAddedElement = false,\n    cssCaptured = false\n  } = options;\n  const rootId = getRootId(doc, mirror2);\n  switch (n2.nodeType) {\n    case n2.DOCUMENT_NODE:\n      if (n2.compatMode !== \"CSS1Compat\") {\n        return {\n          type: NodeType$3.Document,\n          childNodes: [],\n          compatMode: n2.compatMode\n          // probably \"BackCompat\"\n        };\n      } else {\n        return {\n          type: NodeType$3.Document,\n          childNodes: []\n        };\n      }\n    case n2.DOCUMENT_TYPE_NODE:\n      return {\n        type: NodeType$3.DocumentType,\n        name: n2.name,\n        publicId: n2.publicId,\n        systemId: n2.systemId,\n        rootId\n      };\n    case n2.ELEMENT_NODE:\n      return serializeElementNode(n2, {\n        doc,\n        blockClass,\n        blockSelector,\n        inlineStylesheet,\n        maskInputOptions,\n        maskInputFn,\n        dataURLOptions,\n        inlineImages,\n        recordCanvas,\n        keepIframeSrcFn,\n        newlyAddedElement,\n        rootId\n      });\n    case n2.TEXT_NODE:\n      return serializeTextNode(n2, {\n        doc,\n        needsMask,\n        maskTextFn,\n        rootId,\n        cssCaptured\n      });\n    case n2.CDATA_SECTION_NODE:\n      return {\n        type: NodeType$3.CDATA,\n        textContent: \"\",\n        rootId\n      };\n    case n2.COMMENT_NODE:\n      return {\n        type: NodeType$3.Comment,\n        textContent: index$1.textContent(n2) || \"\",\n        rootId\n      };\n    default:\n      return false;\n  }\n}\nfunction getRootId(doc, mirror2) {\n  if (!mirror2.hasNode(doc)) return void 0;\n  const docId = mirror2.getId(doc);\n  return docId === 1 ? void 0 : docId;\n}\nfunction serializeTextNode(n2, options) {\n  const { needsMask, maskTextFn, rootId, cssCaptured } = options;\n  const parent = index$1.parentNode(n2);\n  const parentTagName = parent && parent.tagName;\n  let textContent2 = \"\";\n  const isStyle = parentTagName === \"STYLE\" ? true : void 0;\n  const isScript = parentTagName === \"SCRIPT\" ? true : void 0;\n  if (isScript) {\n    textContent2 = \"SCRIPT_PLACEHOLDER\";\n  } else if (!cssCaptured) {\n    textContent2 = index$1.textContent(n2);\n    if (isStyle && textContent2) {\n      textContent2 = absolutifyURLs(textContent2, getHref(options.doc));\n    }\n  }\n  if (!isStyle && !isScript && textContent2 && needsMask) {\n    textContent2 = maskTextFn ? maskTextFn(textContent2, index$1.parentElement(n2)) : textContent2.replace(/[\\S]/g, \"*\");\n  }\n  return {\n    type: NodeType$3.Text,\n    textContent: textContent2 || \"\",\n    rootId\n  };\n}\nfunction serializeElementNode(n2, options) {\n  const {\n    doc,\n    blockClass,\n    blockSelector,\n    inlineStylesheet,\n    maskInputOptions = {},\n    maskInputFn,\n    dataURLOptions = {},\n    inlineImages,\n    recordCanvas,\n    keepIframeSrcFn,\n    newlyAddedElement = false,\n    rootId\n  } = options;\n  const needBlock = _isBlockedElement(n2, blockClass, blockSelector);\n  const tagName = getValidTagName$1(n2);\n  let attributes = {};\n  const len = n2.attributes.length;\n  for (let i2 = 0; i2 < len; i2++) {\n    const attr = n2.attributes[i2];\n    if (!ignoreAttribute(tagName, attr.name, attr.value)) {\n      attributes[attr.name] = transformAttribute(\n        doc,\n        tagName,\n        toLowerCase(attr.name),\n        attr.value\n      );\n    }\n  }\n  if (tagName === \"link\" && inlineStylesheet) {\n    const stylesheet = Array.from(doc.styleSheets).find((s2) => {\n      return s2.href === n2.href;\n    });\n    let cssText = null;\n    if (stylesheet) {\n      cssText = stringifyStylesheet(stylesheet);\n    }\n    if (cssText) {\n      delete attributes.rel;\n      delete attributes.href;\n      attributes._cssText = cssText;\n    }\n  }\n  if (tagName === \"style\" && n2.sheet) {\n    let cssText = stringifyStylesheet(\n      n2.sheet\n    );\n    if (cssText) {\n      if (n2.childNodes.length > 1) {\n        cssText = markCssSplits(cssText, n2);\n      }\n      attributes._cssText = cssText;\n    }\n  }\n  if ([\"input\", \"textarea\", \"select\"].includes(tagName)) {\n    const value = n2.value;\n    const checked = n2.checked;\n    if (attributes.type !== \"radio\" && attributes.type !== \"checkbox\" && attributes.type !== \"submit\" && attributes.type !== \"button\" && value) {\n      attributes.value = maskInputValue({\n        element: n2,\n        type: getInputType(n2),\n        tagName,\n        value,\n        maskInputOptions,\n        maskInputFn\n      });\n    } else if (checked) {\n      attributes.checked = checked;\n    }\n  }\n  if (tagName === \"option\") {\n    if (n2.selected && !maskInputOptions[\"select\"]) {\n      attributes.selected = true;\n    } else {\n      delete attributes.selected;\n    }\n  }\n  if (tagName === \"dialog\" && n2.open) {\n    attributes.rr_open_mode = n2.matches(\"dialog:modal\") ? \"modal\" : \"non-modal\";\n  }\n  if (tagName === \"canvas\" && recordCanvas) {\n    if (n2.__context === \"2d\") {\n      if (!is2DCanvasBlank(n2)) {\n        attributes.rr_dataURL = n2.toDataURL(\n          dataURLOptions.type,\n          dataURLOptions.quality\n        );\n      }\n    } else if (!(\"__context\" in n2)) {\n      const canvasDataURL = n2.toDataURL(\n        dataURLOptions.type,\n        dataURLOptions.quality\n      );\n      const blankCanvas = doc.createElement(\"canvas\");\n      blankCanvas.width = n2.width;\n      blankCanvas.height = n2.height;\n      const blankCanvasDataURL = blankCanvas.toDataURL(\n        dataURLOptions.type,\n        dataURLOptions.quality\n      );\n      if (canvasDataURL !== blankCanvasDataURL) {\n        attributes.rr_dataURL = canvasDataURL;\n      }\n    }\n  }\n  if (tagName === \"img\" && inlineImages) {\n    if (!canvasService) {\n      canvasService = doc.createElement(\"canvas\");\n      canvasCtx = canvasService.getContext(\"2d\");\n    }\n    const image = n2;\n    const imageSrc = image.currentSrc || image.getAttribute(\"src\") || \"<unknown-src>\";\n    const priorCrossOrigin = image.crossOrigin;\n    const recordInlineImage = () => {\n      image.removeEventListener(\"load\", recordInlineImage);\n      try {\n        canvasService.width = image.naturalWidth;\n        canvasService.height = image.naturalHeight;\n        canvasCtx.drawImage(image, 0, 0);\n        attributes.rr_dataURL = canvasService.toDataURL(\n          dataURLOptions.type,\n          dataURLOptions.quality\n        );\n      } catch (err) {\n        if (image.crossOrigin !== \"anonymous\") {\n          image.crossOrigin = \"anonymous\";\n          if (image.complete && image.naturalWidth !== 0)\n            recordInlineImage();\n          else image.addEventListener(\"load\", recordInlineImage);\n          return;\n        } else {\n          console.warn(\n            `Cannot inline img src=${imageSrc}! Error: ${err}`\n          );\n        }\n      }\n      if (image.crossOrigin === \"anonymous\") {\n        priorCrossOrigin ? attributes.crossOrigin = priorCrossOrigin : image.removeAttribute(\"crossorigin\");\n      }\n    };\n    if (image.complete && image.naturalWidth !== 0) recordInlineImage();\n    else image.addEventListener(\"load\", recordInlineImage);\n  }\n  if ([\"audio\", \"video\"].includes(tagName)) {\n    const mediaAttributes = attributes;\n    mediaAttributes.rr_mediaState = n2.paused ? \"paused\" : \"played\";\n    mediaAttributes.rr_mediaCurrentTime = n2.currentTime;\n    mediaAttributes.rr_mediaPlaybackRate = n2.playbackRate;\n    mediaAttributes.rr_mediaMuted = n2.muted;\n    mediaAttributes.rr_mediaLoop = n2.loop;\n    mediaAttributes.rr_mediaVolume = n2.volume;\n  }\n  if (!newlyAddedElement) {\n    if (n2.scrollLeft) {\n      attributes.rr_scrollLeft = n2.scrollLeft;\n    }\n    if (n2.scrollTop) {\n      attributes.rr_scrollTop = n2.scrollTop;\n    }\n  }\n  if (needBlock) {\n    const { width, height } = n2.getBoundingClientRect();\n    attributes = {\n      class: attributes.class,\n      rr_width: `${width}px`,\n      rr_height: `${height}px`\n    };\n  }\n  if (tagName === \"iframe\" && !keepIframeSrcFn(attributes.src)) {\n    if (!n2.contentDocument) {\n      attributes.rr_src = attributes.src;\n    }\n    delete attributes.src;\n  }\n  let isCustomElement;\n  try {\n    if (customElements.get(tagName)) isCustomElement = true;\n  } catch (e2) {\n  }\n  return {\n    type: NodeType$3.Element,\n    tagName,\n    attributes,\n    childNodes: [],\n    isSVG: isSVGElement(n2) || void 0,\n    needBlock,\n    rootId,\n    isCustom: isCustomElement\n  };\n}\nfunction lowerIfExists(maybeAttr) {\n  if (maybeAttr === void 0 || maybeAttr === null) {\n    return \"\";\n  } else {\n    return maybeAttr.toLowerCase();\n  }\n}\nfunction slimDOMDefaults(_slimDOMOptions) {\n  if (_slimDOMOptions === true || _slimDOMOptions === \"all\") {\n    return {\n      script: true,\n      comment: true,\n      headFavicon: true,\n      headWhitespace: true,\n      headMetaSocial: true,\n      headMetaRobots: true,\n      headMetaHttpEquiv: true,\n      headMetaVerification: true,\n      // the following are off for slimDOMOptions === true,\n      // as they destroy some (hidden) info:\n      headMetaAuthorship: _slimDOMOptions === \"all\",\n      headMetaDescKeywords: _slimDOMOptions === \"all\",\n      headTitleMutations: _slimDOMOptions === \"all\"\n    };\n  } else if (_slimDOMOptions) {\n    return _slimDOMOptions;\n  }\n  return {};\n}\nfunction slimDOMExcluded(sn, slimDOMOptions) {\n  if (slimDOMOptions.comment && sn.type === NodeType$3.Comment) {\n    return true;\n  } else if (sn.type === NodeType$3.Element) {\n    if (slimDOMOptions.script && // script tag\n    (sn.tagName === \"script\" || // (module)preload link\n    sn.tagName === \"link\" && (sn.attributes.rel === \"preload\" && sn.attributes.as === \"script\" || sn.attributes.rel === \"modulepreload\") || // prefetch link\n    sn.tagName === \"link\" && sn.attributes.rel === \"prefetch\" && typeof sn.attributes.href === \"string\" && extractFileExtension(sn.attributes.href) === \"js\")) {\n      return true;\n    } else if (slimDOMOptions.headFavicon && (sn.tagName === \"link\" && sn.attributes.rel === \"shortcut icon\" || sn.tagName === \"meta\" && (lowerIfExists(sn.attributes.name).match(\n      /^msapplication-tile(image|color)$/\n    ) || lowerIfExists(sn.attributes.name) === \"application-name\" || lowerIfExists(sn.attributes.rel) === \"icon\" || lowerIfExists(sn.attributes.rel) === \"apple-touch-icon\" || lowerIfExists(sn.attributes.rel) === \"shortcut icon\"))) {\n      return true;\n    } else if (sn.tagName === \"meta\") {\n      if (slimDOMOptions.headMetaDescKeywords && lowerIfExists(sn.attributes.name).match(/^description|keywords$/)) {\n        return true;\n      } else if (slimDOMOptions.headMetaSocial && (lowerIfExists(sn.attributes.property).match(/^(og|twitter|fb):/) || // og = opengraph (facebook)\n      lowerIfExists(sn.attributes.name).match(/^(og|twitter):/) || lowerIfExists(sn.attributes.name) === \"pinterest\")) {\n        return true;\n      } else if (slimDOMOptions.headMetaRobots && (lowerIfExists(sn.attributes.name) === \"robots\" || lowerIfExists(sn.attributes.name) === \"googlebot\" || lowerIfExists(sn.attributes.name) === \"bingbot\")) {\n        return true;\n      } else if (slimDOMOptions.headMetaHttpEquiv && sn.attributes[\"http-equiv\"] !== void 0) {\n        return true;\n      } else if (slimDOMOptions.headMetaAuthorship && (lowerIfExists(sn.attributes.name) === \"author\" || lowerIfExists(sn.attributes.name) === \"generator\" || lowerIfExists(sn.attributes.name) === \"framework\" || lowerIfExists(sn.attributes.name) === \"publisher\" || lowerIfExists(sn.attributes.name) === \"progid\" || lowerIfExists(sn.attributes.property).match(/^article:/) || lowerIfExists(sn.attributes.property).match(/^product:/))) {\n        return true;\n      } else if (slimDOMOptions.headMetaVerification && (lowerIfExists(sn.attributes.name) === \"google-site-verification\" || lowerIfExists(sn.attributes.name) === \"yandex-verification\" || lowerIfExists(sn.attributes.name) === \"csrf-token\" || lowerIfExists(sn.attributes.name) === \"p:domain_verify\" || lowerIfExists(sn.attributes.name) === \"verify-v1\" || lowerIfExists(sn.attributes.name) === \"verification\" || lowerIfExists(sn.attributes.name) === \"shopify-checkout-api-token\")) {\n        return true;\n      }\n    }\n  }\n  return false;\n}\nfunction serializeNodeWithId(n2, options) {\n  const {\n    doc,\n    mirror: mirror2,\n    blockClass,\n    blockSelector,\n    maskTextClass,\n    maskTextSelector,\n    skipChild = false,\n    inlineStylesheet = true,\n    maskInputOptions = {},\n    maskTextFn,\n    maskInputFn,\n    slimDOMOptions,\n    dataURLOptions = {},\n    inlineImages = false,\n    recordCanvas = false,\n    onSerialize,\n    onIframeLoad,\n    iframeLoadTimeout = 5e3,\n    onStylesheetLoad,\n    stylesheetLoadTimeout = 5e3,\n    keepIframeSrcFn = () => false,\n    newlyAddedElement = false,\n    cssCaptured = false\n  } = options;\n  let { needsMask } = options;\n  let { preserveWhiteSpace = true } = options;\n  if (!needsMask) {\n    const checkAncestors = needsMask === void 0;\n    needsMask = needMaskingText(\n      n2,\n      maskTextClass,\n      maskTextSelector,\n      checkAncestors\n    );\n  }\n  const _serializedNode = serializeNode(n2, {\n    doc,\n    mirror: mirror2,\n    blockClass,\n    blockSelector,\n    needsMask,\n    inlineStylesheet,\n    maskInputOptions,\n    maskTextFn,\n    maskInputFn,\n    dataURLOptions,\n    inlineImages,\n    recordCanvas,\n    keepIframeSrcFn,\n    newlyAddedElement,\n    cssCaptured\n  });\n  if (!_serializedNode) {\n    console.warn(n2, \"not serialized\");\n    return null;\n  }\n  let id;\n  if (mirror2.hasNode(n2)) {\n    id = mirror2.getId(n2);\n  } else if (slimDOMExcluded(_serializedNode, slimDOMOptions) || !preserveWhiteSpace && _serializedNode.type === NodeType$3.Text && !_serializedNode.textContent.replace(/^\\s+|\\s+$/gm, \"\").length) {\n    id = IGNORED_NODE;\n  } else {\n    id = genId();\n  }\n  const serializedNode = Object.assign(_serializedNode, { id });\n  mirror2.add(n2, serializedNode);\n  if (id === IGNORED_NODE) {\n    return null;\n  }\n  if (onSerialize) {\n    onSerialize(n2);\n  }\n  let recordChild = !skipChild;\n  if (serializedNode.type === NodeType$3.Element) {\n    recordChild = recordChild && !serializedNode.needBlock;\n    delete serializedNode.needBlock;\n    const shadowRootEl = index$1.shadowRoot(n2);\n    if (shadowRootEl && isNativeShadowDom(shadowRootEl))\n      serializedNode.isShadowHost = true;\n  }\n  if ((serializedNode.type === NodeType$3.Document || serializedNode.type === NodeType$3.Element) && recordChild) {\n    if (slimDOMOptions.headWhitespace && serializedNode.type === NodeType$3.Element && serializedNode.tagName === \"head\") {\n      preserveWhiteSpace = false;\n    }\n    const bypassOptions = {\n      doc,\n      mirror: mirror2,\n      blockClass,\n      blockSelector,\n      needsMask,\n      maskTextClass,\n      maskTextSelector,\n      skipChild,\n      inlineStylesheet,\n      maskInputOptions,\n      maskTextFn,\n      maskInputFn,\n      slimDOMOptions,\n      dataURLOptions,\n      inlineImages,\n      recordCanvas,\n      preserveWhiteSpace,\n      onSerialize,\n      onIframeLoad,\n      iframeLoadTimeout,\n      onStylesheetLoad,\n      stylesheetLoadTimeout,\n      keepIframeSrcFn,\n      cssCaptured: false\n    };\n    if (serializedNode.type === NodeType$3.Element && serializedNode.tagName === \"textarea\" && serializedNode.attributes.value !== void 0) ;\n    else {\n      if (serializedNode.type === NodeType$3.Element && serializedNode.attributes._cssText !== void 0 && typeof serializedNode.attributes._cssText === \"string\") {\n        bypassOptions.cssCaptured = true;\n      }\n      for (const childN of Array.from(index$1.childNodes(n2))) {\n        const serializedChildNode = serializeNodeWithId(childN, bypassOptions);\n        if (serializedChildNode) {\n          serializedNode.childNodes.push(serializedChildNode);\n        }\n      }\n    }\n    let shadowRootEl = null;\n    if (isElement(n2) && (shadowRootEl = index$1.shadowRoot(n2))) {\n      for (const childN of Array.from(index$1.childNodes(shadowRootEl))) {\n        const serializedChildNode = serializeNodeWithId(childN, bypassOptions);\n        if (serializedChildNode) {\n          isNativeShadowDom(shadowRootEl) && (serializedChildNode.isShadow = true);\n          serializedNode.childNodes.push(serializedChildNode);\n        }\n      }\n    }\n  }\n  const parent = index$1.parentNode(n2);\n  if (parent && isShadowRoot(parent) && isNativeShadowDom(parent)) {\n    serializedNode.isShadow = true;\n  }\n  if (serializedNode.type === NodeType$3.Element && serializedNode.tagName === \"iframe\") {\n    onceIframeLoaded(\n      n2,\n      () => {\n        const iframeDoc = n2.contentDocument;\n        if (iframeDoc && onIframeLoad) {\n          const serializedIframeNode = serializeNodeWithId(iframeDoc, {\n            doc: iframeDoc,\n            mirror: mirror2,\n            blockClass,\n            blockSelector,\n            needsMask,\n            maskTextClass,\n            maskTextSelector,\n            skipChild: false,\n            inlineStylesheet,\n            maskInputOptions,\n            maskTextFn,\n            maskInputFn,\n            slimDOMOptions,\n            dataURLOptions,\n            inlineImages,\n            recordCanvas,\n            preserveWhiteSpace,\n            onSerialize,\n            onIframeLoad,\n            iframeLoadTimeout,\n            onStylesheetLoad,\n            stylesheetLoadTimeout,\n            keepIframeSrcFn\n          });\n          if (serializedIframeNode) {\n            onIframeLoad(\n              n2,\n              serializedIframeNode\n            );\n          }\n        }\n      },\n      iframeLoadTimeout\n    );\n  }\n  if (serializedNode.type === NodeType$3.Element && serializedNode.tagName === \"link\" && typeof serializedNode.attributes.rel === \"string\" && (serializedNode.attributes.rel === \"stylesheet\" || serializedNode.attributes.rel === \"preload\" && typeof serializedNode.attributes.href === \"string\" && extractFileExtension(serializedNode.attributes.href) === \"css\")) {\n    onceStylesheetLoaded(\n      n2,\n      () => {\n        if (onStylesheetLoad) {\n          const serializedLinkNode = serializeNodeWithId(n2, {\n            doc,\n            mirror: mirror2,\n            blockClass,\n            blockSelector,\n            needsMask,\n            maskTextClass,\n            maskTextSelector,\n            skipChild: false,\n            inlineStylesheet,\n            maskInputOptions,\n            maskTextFn,\n            maskInputFn,\n            slimDOMOptions,\n            dataURLOptions,\n            inlineImages,\n            recordCanvas,\n            preserveWhiteSpace,\n            onSerialize,\n            onIframeLoad,\n            iframeLoadTimeout,\n            onStylesheetLoad,\n            stylesheetLoadTimeout,\n            keepIframeSrcFn\n          });\n          if (serializedLinkNode) {\n            onStylesheetLoad(\n              n2,\n              serializedLinkNode\n            );\n          }\n        }\n      },\n      stylesheetLoadTimeout\n    );\n  }\n  return serializedNode;\n}\nfunction snapshot(n2, options) {\n  const {\n    mirror: mirror2 = new Mirror(),\n    blockClass = \"rr-block\",\n    blockSelector = null,\n    maskTextClass = \"rr-mask\",\n    maskTextSelector = null,\n    inlineStylesheet = true,\n    inlineImages = false,\n    recordCanvas = false,\n    maskAllInputs = false,\n    maskTextFn,\n    maskInputFn,\n    slimDOM = false,\n    dataURLOptions,\n    preserveWhiteSpace,\n    onSerialize,\n    onIframeLoad,\n    iframeLoadTimeout,\n    onStylesheetLoad,\n    stylesheetLoadTimeout,\n    keepIframeSrcFn = () => false\n  } = options || {};\n  const maskInputOptions = maskAllInputs === true ? {\n    color: true,\n    date: true,\n    \"datetime-local\": true,\n    email: true,\n    month: true,\n    number: true,\n    range: true,\n    search: true,\n    tel: true,\n    text: true,\n    time: true,\n    url: true,\n    week: true,\n    textarea: true,\n    select: true,\n    password: true\n  } : maskAllInputs === false ? {\n    password: true\n  } : maskAllInputs;\n  const slimDOMOptions = slimDOMDefaults(slimDOM);\n  return serializeNodeWithId(n2, {\n    doc: n2,\n    mirror: mirror2,\n    blockClass,\n    blockSelector,\n    maskTextClass,\n    maskTextSelector,\n    skipChild: false,\n    inlineStylesheet,\n    maskInputOptions,\n    maskTextFn,\n    maskInputFn,\n    slimDOMOptions,\n    dataURLOptions,\n    inlineImages,\n    recordCanvas,\n    preserveWhiteSpace,\n    onSerialize,\n    onIframeLoad,\n    iframeLoadTimeout,\n    onStylesheetLoad,\n    stylesheetLoadTimeout,\n    keepIframeSrcFn,\n    newlyAddedElement: false\n  });\n}\nfunction getDefaultExportFromCjs$1(x2) {\n  return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, \"default\") ? x2[\"default\"] : x2;\n}\nfunction getAugmentedNamespace$1(n2) {\n  if (n2.__esModule) return n2;\n  var f2 = n2.default;\n  if (typeof f2 == \"function\") {\n    var a2 = function a22() {\n      if (this instanceof a22) {\n        return Reflect.construct(f2, arguments, this.constructor);\n      }\n      return f2.apply(this, arguments);\n    };\n    a2.prototype = f2.prototype;\n  } else a2 = {};\n  Object.defineProperty(a2, \"__esModule\", { value: true });\n  Object.keys(n2).forEach(function(k) {\n    var d = Object.getOwnPropertyDescriptor(n2, k);\n    Object.defineProperty(a2, k, d.get ? d : {\n      enumerable: true,\n      get: function() {\n        return n2[k];\n      }\n    });\n  });\n  return a2;\n}\nvar picocolors_browser$1 = { exports: {} };\nvar x$1 = String;\nvar create$1 = function() {\n  return { isColorSupported: false, reset: x$1, bold: x$1, dim: x$1, italic: x$1, underline: x$1, inverse: x$1, hidden: x$1, strikethrough: x$1, black: x$1, red: x$1, green: x$1, yellow: x$1, blue: x$1, magenta: x$1, cyan: x$1, white: x$1, gray: x$1, bgBlack: x$1, bgRed: x$1, bgGreen: x$1, bgYellow: x$1, bgBlue: x$1, bgMagenta: x$1, bgCyan: x$1, bgWhite: x$1 };\n};\npicocolors_browser$1.exports = create$1();\npicocolors_browser$1.exports.createColors = create$1;\nvar picocolors_browserExports$1 = picocolors_browser$1.exports;\nconst __viteBrowserExternal$2 = {};\nconst __viteBrowserExternal$1$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({\n  __proto__: null,\n  default: __viteBrowserExternal$2\n}, Symbol.toStringTag, { value: \"Module\" }));\nconst require$$2$1 = /* @__PURE__ */ getAugmentedNamespace$1(__viteBrowserExternal$1$1);\nlet pico$1 = picocolors_browserExports$1;\nlet terminalHighlight$1$1 = require$$2$1;\nlet CssSyntaxError$3$1 = class CssSyntaxError extends Error {\n  constructor(message, line, column, source, file, plugin22) {\n    super(message);\n    this.name = \"CssSyntaxError\";\n    this.reason = message;\n    if (file) {\n      this.file = file;\n    }\n    if (source) {\n      this.source = source;\n    }\n    if (plugin22) {\n      this.plugin = plugin22;\n    }\n    if (typeof line !== \"undefined\" && typeof column !== \"undefined\") {\n      if (typeof line === \"number\") {\n        this.line = line;\n        this.column = column;\n      } else {\n        this.line = line.line;\n        this.column = line.column;\n        this.endLine = column.line;\n        this.endColumn = column.column;\n      }\n    }\n    this.setMessage();\n    if (Error.captureStackTrace) {\n      Error.captureStackTrace(this, CssSyntaxError);\n    }\n  }\n  setMessage() {\n    this.message = this.plugin ? this.plugin + \": \" : \"\";\n    this.message += this.file ? this.file : \"<css input>\";\n    if (typeof this.line !== \"undefined\") {\n      this.message += \":\" + this.line + \":\" + this.column;\n    }\n    this.message += \": \" + this.reason;\n  }\n  showSourceCode(color) {\n    if (!this.source) return \"\";\n    let css = this.source;\n    if (color == null) color = pico$1.isColorSupported;\n    if (terminalHighlight$1$1) {\n      if (color) css = terminalHighlight$1$1(css);\n    }\n    let lines = css.split(/\\r?\\n/);\n    let start = Math.max(this.line - 3, 0);\n    let end = Math.min(this.line + 2, lines.length);\n    let maxWidth = String(end).length;\n    let mark, aside;\n    if (color) {\n      let { bold, gray, red } = pico$1.createColors(true);\n      mark = (text) => bold(red(text));\n      aside = (text) => gray(text);\n    } else {\n      mark = aside = (str) => str;\n    }\n    return lines.slice(start, end).map((line, index2) => {\n      let number = start + 1 + index2;\n      let gutter = \" \" + (\" \" + number).slice(-maxWidth) + \" | \";\n      if (number === this.line) {\n        let spacing = aside(gutter.replace(/\\d/g, \" \")) + line.slice(0, this.column - 1).replace(/[^\\t]/g, \" \");\n        return mark(\">\") + aside(gutter) + line + \"\\n \" + spacing + mark(\"^\");\n      }\n      return \" \" + aside(gutter) + line;\n    }).join(\"\\n\");\n  }\n  toString() {\n    let code = this.showSourceCode();\n    if (code) {\n      code = \"\\n\\n\" + code + \"\\n\";\n    }\n    return this.name + \": \" + this.message + code;\n  }\n};\nvar cssSyntaxError$1 = CssSyntaxError$3$1;\nCssSyntaxError$3$1.default = CssSyntaxError$3$1;\nvar symbols$1 = {};\nsymbols$1.isClean = Symbol(\"isClean\");\nsymbols$1.my = Symbol(\"my\");\nconst DEFAULT_RAW$1 = {\n  after: \"\\n\",\n  beforeClose: \"\\n\",\n  beforeComment: \"\\n\",\n  beforeDecl: \"\\n\",\n  beforeOpen: \" \",\n  beforeRule: \"\\n\",\n  colon: \": \",\n  commentLeft: \" \",\n  commentRight: \" \",\n  emptyBody: \"\",\n  indent: \"    \",\n  semicolon: false\n};\nfunction capitalize$1(str) {\n  return str[0].toUpperCase() + str.slice(1);\n}\nlet Stringifier$2$1 = class Stringifier {\n  constructor(builder) {\n    this.builder = builder;\n  }\n  atrule(node2, semicolon) {\n    let name = \"@\" + node2.name;\n    let params = node2.params ? this.rawValue(node2, \"params\") : \"\";\n    if (typeof node2.raws.afterName !== \"undefined\") {\n      name += node2.raws.afterName;\n    } else if (params) {\n      name += \" \";\n    }\n    if (node2.nodes) {\n      this.block(node2, name + params);\n    } else {\n      let end = (node2.raws.between || \"\") + (semicolon ? \";\" : \"\");\n      this.builder(name + params + end, node2);\n    }\n  }\n  beforeAfter(node2, detect) {\n    let value;\n    if (node2.type === \"decl\") {\n      value = this.raw(node2, null, \"beforeDecl\");\n    } else if (node2.type === \"comment\") {\n      value = this.raw(node2, null, \"beforeComment\");\n    } else if (detect === \"before\") {\n      value = this.raw(node2, null, \"beforeRule\");\n    } else {\n      value = this.raw(node2, null, \"beforeClose\");\n    }\n    let buf = node2.parent;\n    let depth = 0;\n    while (buf && buf.type !== \"root\") {\n      depth += 1;\n      buf = buf.parent;\n    }\n    if (value.includes(\"\\n\")) {\n      let indent = this.raw(node2, null, \"indent\");\n      if (indent.length) {\n        for (let step = 0; step < depth; step++) value += indent;\n      }\n    }\n    return value;\n  }\n  block(node2, start) {\n    let between = this.raw(node2, \"between\", \"beforeOpen\");\n    this.builder(start + between + \"{\", node2, \"start\");\n    let after;\n    if (node2.nodes && node2.nodes.length) {\n      this.body(node2);\n      after = this.raw(node2, \"after\");\n    } else {\n      after = this.raw(node2, \"after\", \"emptyBody\");\n    }\n    if (after) this.builder(after);\n    this.builder(\"}\", node2, \"end\");\n  }\n  body(node2) {\n    let last = node2.nodes.length - 1;\n    while (last > 0) {\n      if (node2.nodes[last].type !== \"comment\") break;\n      last -= 1;\n    }\n    let semicolon = this.raw(node2, \"semicolon\");\n    for (let i2 = 0; i2 < node2.nodes.length; i2++) {\n      let child = node2.nodes[i2];\n      let before = this.raw(child, \"before\");\n      if (before) this.builder(before);\n      this.stringify(child, last !== i2 || semicolon);\n    }\n  }\n  comment(node2) {\n    let left = this.raw(node2, \"left\", \"commentLeft\");\n    let right = this.raw(node2, \"right\", \"commentRight\");\n    this.builder(\"/*\" + left + node2.text + right + \"*/\", node2);\n  }\n  decl(node2, semicolon) {\n    let between = this.raw(node2, \"between\", \"colon\");\n    let string = node2.prop + between + this.rawValue(node2, \"value\");\n    if (node2.important) {\n      string += node2.raws.important || \" !important\";\n    }\n    if (semicolon) string += \";\";\n    this.builder(string, node2);\n  }\n  document(node2) {\n    this.body(node2);\n  }\n  raw(node2, own, detect) {\n    let value;\n    if (!detect) detect = own;\n    if (own) {\n      value = node2.raws[own];\n      if (typeof value !== \"undefined\") return value;\n    }\n    let parent = node2.parent;\n    if (detect === \"before\") {\n      if (!parent || parent.type === \"root\" && parent.first === node2) {\n        return \"\";\n      }\n      if (parent && parent.type === \"document\") {\n        return \"\";\n      }\n    }\n    if (!parent) return DEFAULT_RAW$1[detect];\n    let root2 = node2.root();\n    if (!root2.rawCache) root2.rawCache = {};\n    if (typeof root2.rawCache[detect] !== \"undefined\") {\n      return root2.rawCache[detect];\n    }\n    if (detect === \"before\" || detect === \"after\") {\n      return this.beforeAfter(node2, detect);\n    } else {\n      let method = \"raw\" + capitalize$1(detect);\n      if (this[method]) {\n        value = this[method](root2, node2);\n      } else {\n        root2.walk((i2) => {\n          value = i2.raws[own];\n          if (typeof value !== \"undefined\") return false;\n        });\n      }\n    }\n    if (typeof value === \"undefined\") value = DEFAULT_RAW$1[detect];\n    root2.rawCache[detect] = value;\n    return value;\n  }\n  rawBeforeClose(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && i2.nodes.length > 0) {\n        if (typeof i2.raws.after !== \"undefined\") {\n          value = i2.raws.after;\n          if (value.includes(\"\\n\")) {\n            value = value.replace(/[^\\n]+$/, \"\");\n          }\n          return false;\n        }\n      }\n    });\n    if (value) value = value.replace(/\\S/g, \"\");\n    return value;\n  }\n  rawBeforeComment(root2, node2) {\n    let value;\n    root2.walkComments((i2) => {\n      if (typeof i2.raws.before !== \"undefined\") {\n        value = i2.raws.before;\n        if (value.includes(\"\\n\")) {\n          value = value.replace(/[^\\n]+$/, \"\");\n        }\n        return false;\n      }\n    });\n    if (typeof value === \"undefined\") {\n      value = this.raw(node2, null, \"beforeDecl\");\n    } else if (value) {\n      value = value.replace(/\\S/g, \"\");\n    }\n    return value;\n  }\n  rawBeforeDecl(root2, node2) {\n    let value;\n    root2.walkDecls((i2) => {\n      if (typeof i2.raws.before !== \"undefined\") {\n        value = i2.raws.before;\n        if (value.includes(\"\\n\")) {\n          value = value.replace(/[^\\n]+$/, \"\");\n        }\n        return false;\n      }\n    });\n    if (typeof value === \"undefined\") {\n      value = this.raw(node2, null, \"beforeRule\");\n    } else if (value) {\n      value = value.replace(/\\S/g, \"\");\n    }\n    return value;\n  }\n  rawBeforeOpen(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.type !== \"decl\") {\n        value = i2.raws.between;\n        if (typeof value !== \"undefined\") return false;\n      }\n    });\n    return value;\n  }\n  rawBeforeRule(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && (i2.parent !== root2 || root2.first !== i2)) {\n        if (typeof i2.raws.before !== \"undefined\") {\n          value = i2.raws.before;\n          if (value.includes(\"\\n\")) {\n            value = value.replace(/[^\\n]+$/, \"\");\n          }\n          return false;\n        }\n      }\n    });\n    if (value) value = value.replace(/\\S/g, \"\");\n    return value;\n  }\n  rawColon(root2) {\n    let value;\n    root2.walkDecls((i2) => {\n      if (typeof i2.raws.between !== \"undefined\") {\n        value = i2.raws.between.replace(/[^\\s:]/g, \"\");\n        return false;\n      }\n    });\n    return value;\n  }\n  rawEmptyBody(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && i2.nodes.length === 0) {\n        value = i2.raws.after;\n        if (typeof value !== \"undefined\") return false;\n      }\n    });\n    return value;\n  }\n  rawIndent(root2) {\n    if (root2.raws.indent) return root2.raws.indent;\n    let value;\n    root2.walk((i2) => {\n      let p = i2.parent;\n      if (p && p !== root2 && p.parent && p.parent === root2) {\n        if (typeof i2.raws.before !== \"undefined\") {\n          let parts = i2.raws.before.split(\"\\n\");\n          value = parts[parts.length - 1];\n          value = value.replace(/\\S/g, \"\");\n          return false;\n        }\n      }\n    });\n    return value;\n  }\n  rawSemicolon(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && i2.nodes.length && i2.last.type === \"decl\") {\n        value = i2.raws.semicolon;\n        if (typeof value !== \"undefined\") return false;\n      }\n    });\n    return value;\n  }\n  rawValue(node2, prop) {\n    let value = node2[prop];\n    let raw = node2.raws[prop];\n    if (raw && raw.value === value) {\n      return raw.raw;\n    }\n    return value;\n  }\n  root(node2) {\n    this.body(node2);\n    if (node2.raws.after) this.builder(node2.raws.after);\n  }\n  rule(node2) {\n    this.block(node2, this.rawValue(node2, \"selector\"));\n    if (node2.raws.ownSemicolon) {\n      this.builder(node2.raws.ownSemicolon, node2, \"end\");\n    }\n  }\n  stringify(node2, semicolon) {\n    if (!this[node2.type]) {\n      throw new Error(\n        \"Unknown AST node type \" + node2.type + \". Maybe you need to change PostCSS stringifier.\"\n      );\n    }\n    this[node2.type](node2, semicolon);\n  }\n};\nvar stringifier$1 = Stringifier$2$1;\nStringifier$2$1.default = Stringifier$2$1;\nlet Stringifier$1$1 = stringifier$1;\nfunction stringify$4$1(node2, builder) {\n  let str = new Stringifier$1$1(builder);\n  str.stringify(node2);\n}\nvar stringify_1$1 = stringify$4$1;\nstringify$4$1.default = stringify$4$1;\nlet { isClean: isClean$2$1, my: my$2$1 } = symbols$1;\nlet CssSyntaxError$2$1 = cssSyntaxError$1;\nlet Stringifier2$1 = stringifier$1;\nlet stringify$3$1 = stringify_1$1;\nfunction cloneNode$1(obj, parent) {\n  let cloned = new obj.constructor();\n  for (let i2 in obj) {\n    if (!Object.prototype.hasOwnProperty.call(obj, i2)) {\n      continue;\n    }\n    if (i2 === \"proxyCache\") continue;\n    let value = obj[i2];\n    let type = typeof value;\n    if (i2 === \"parent\" && type === \"object\") {\n      if (parent) cloned[i2] = parent;\n    } else if (i2 === \"source\") {\n      cloned[i2] = value;\n    } else if (Array.isArray(value)) {\n      cloned[i2] = value.map((j) => cloneNode$1(j, cloned));\n    } else {\n      if (type === \"object\" && value !== null) value = cloneNode$1(value);\n      cloned[i2] = value;\n    }\n  }\n  return cloned;\n}\nlet Node$4$1 = class Node2 {\n  constructor(defaults = {}) {\n    this.raws = {};\n    this[isClean$2$1] = false;\n    this[my$2$1] = true;\n    for (let name in defaults) {\n      if (name === \"nodes\") {\n        this.nodes = [];\n        for (let node2 of defaults[name]) {\n          if (typeof node2.clone === \"function\") {\n            this.append(node2.clone());\n          } else {\n            this.append(node2);\n          }\n        }\n      } else {\n        this[name] = defaults[name];\n      }\n    }\n  }\n  addToError(error) {\n    error.postcssNode = this;\n    if (error.stack && this.source && /\\n\\s{4}at /.test(error.stack)) {\n      let s2 = this.source;\n      error.stack = error.stack.replace(\n        /\\n\\s{4}at /,\n        `$&${s2.input.from}:${s2.start.line}:${s2.start.column}$&`\n      );\n    }\n    return error;\n  }\n  after(add) {\n    this.parent.insertAfter(this, add);\n    return this;\n  }\n  assign(overrides = {}) {\n    for (let name in overrides) {\n      this[name] = overrides[name];\n    }\n    return this;\n  }\n  before(add) {\n    this.parent.insertBefore(this, add);\n    return this;\n  }\n  cleanRaws(keepBetween) {\n    delete this.raws.before;\n    delete this.raws.after;\n    if (!keepBetween) delete this.raws.between;\n  }\n  clone(overrides = {}) {\n    let cloned = cloneNode$1(this);\n    for (let name in overrides) {\n      cloned[name] = overrides[name];\n    }\n    return cloned;\n  }\n  cloneAfter(overrides = {}) {\n    let cloned = this.clone(overrides);\n    this.parent.insertAfter(this, cloned);\n    return cloned;\n  }\n  cloneBefore(overrides = {}) {\n    let cloned = this.clone(overrides);\n    this.parent.insertBefore(this, cloned);\n    return cloned;\n  }\n  error(message, opts = {}) {\n    if (this.source) {\n      let { end, start } = this.rangeBy(opts);\n      return this.source.input.error(\n        message,\n        { column: start.column, line: start.line },\n        { column: end.column, line: end.line },\n        opts\n      );\n    }\n    return new CssSyntaxError$2$1(message);\n  }\n  getProxyProcessor() {\n    return {\n      get(node2, prop) {\n        if (prop === \"proxyOf\") {\n          return node2;\n        } else if (prop === \"root\") {\n          return () => node2.root().toProxy();\n        } else {\n          return node2[prop];\n        }\n      },\n      set(node2, prop, value) {\n        if (node2[prop] === value) return true;\n        node2[prop] = value;\n        if (prop === \"prop\" || prop === \"value\" || prop === \"name\" || prop === \"params\" || prop === \"important\" || /* c8 ignore next */\n        prop === \"text\") {\n          node2.markDirty();\n        }\n        return true;\n      }\n    };\n  }\n  markDirty() {\n    if (this[isClean$2$1]) {\n      this[isClean$2$1] = false;\n      let next = this;\n      while (next = next.parent) {\n        next[isClean$2$1] = false;\n      }\n    }\n  }\n  next() {\n    if (!this.parent) return void 0;\n    let index2 = this.parent.index(this);\n    return this.parent.nodes[index2 + 1];\n  }\n  positionBy(opts, stringRepresentation) {\n    let pos = this.source.start;\n    if (opts.index) {\n      pos = this.positionInside(opts.index, stringRepresentation);\n    } else if (opts.word) {\n      stringRepresentation = this.toString();\n      let index2 = stringRepresentation.indexOf(opts.word);\n      if (index2 !== -1) pos = this.positionInside(index2, stringRepresentation);\n    }\n    return pos;\n  }\n  positionInside(index2, stringRepresentation) {\n    let string = stringRepresentation || this.toString();\n    let column = this.source.start.column;\n    let line = this.source.start.line;\n    for (let i2 = 0; i2 < index2; i2++) {\n      if (string[i2] === \"\\n\") {\n        column = 1;\n        line += 1;\n      } else {\n        column += 1;\n      }\n    }\n    return { column, line };\n  }\n  prev() {\n    if (!this.parent) return void 0;\n    let index2 = this.parent.index(this);\n    return this.parent.nodes[index2 - 1];\n  }\n  rangeBy(opts) {\n    let start = {\n      column: this.source.start.column,\n      line: this.source.start.line\n    };\n    let end = this.source.end ? {\n      column: this.source.end.column + 1,\n      line: this.source.end.line\n    } : {\n      column: start.column + 1,\n      line: start.line\n    };\n    if (opts.word) {\n      let stringRepresentation = this.toString();\n      let index2 = stringRepresentation.indexOf(opts.word);\n      if (index2 !== -1) {\n        start = this.positionInside(index2, stringRepresentation);\n        end = this.positionInside(index2 + opts.word.length, stringRepresentation);\n      }\n    } else {\n      if (opts.start) {\n        start = {\n          column: opts.start.column,\n          line: opts.start.line\n        };\n      } else if (opts.index) {\n        start = this.positionInside(opts.index);\n      }\n      if (opts.end) {\n        end = {\n          column: opts.end.column,\n          line: opts.end.line\n        };\n      } else if (typeof opts.endIndex === \"number\") {\n        end = this.positionInside(opts.endIndex);\n      } else if (opts.index) {\n        end = this.positionInside(opts.index + 1);\n      }\n    }\n    if (end.line < start.line || end.line === start.line && end.column <= start.column) {\n      end = { column: start.column + 1, line: start.line };\n    }\n    return { end, start };\n  }\n  raw(prop, defaultType) {\n    let str = new Stringifier2$1();\n    return str.raw(this, prop, defaultType);\n  }\n  remove() {\n    if (this.parent) {\n      this.parent.removeChild(this);\n    }\n    this.parent = void 0;\n    return this;\n  }\n  replaceWith(...nodes) {\n    if (this.parent) {\n      let bookmark = this;\n      let foundSelf = false;\n      for (let node2 of nodes) {\n        if (node2 === this) {\n          foundSelf = true;\n        } else if (foundSelf) {\n          this.parent.insertAfter(bookmark, node2);\n          bookmark = node2;\n        } else {\n          this.parent.insertBefore(bookmark, node2);\n        }\n      }\n      if (!foundSelf) {\n        this.remove();\n      }\n    }\n    return this;\n  }\n  root() {\n    let result2 = this;\n    while (result2.parent && result2.parent.type !== \"document\") {\n      result2 = result2.parent;\n    }\n    return result2;\n  }\n  toJSON(_, inputs) {\n    let fixed = {};\n    let emitInputs = inputs == null;\n    inputs = inputs || /* @__PURE__ */ new Map();\n    let inputsNextIndex = 0;\n    for (let name in this) {\n      if (!Object.prototype.hasOwnProperty.call(this, name)) {\n        continue;\n      }\n      if (name === \"parent\" || name === \"proxyCache\") continue;\n      let value = this[name];\n      if (Array.isArray(value)) {\n        fixed[name] = value.map((i2) => {\n          if (typeof i2 === \"object\" && i2.toJSON) {\n            return i2.toJSON(null, inputs);\n          } else {\n            return i2;\n          }\n        });\n      } else if (typeof value === \"object\" && value.toJSON) {\n        fixed[name] = value.toJSON(null, inputs);\n      } else if (name === \"source\") {\n        let inputId = inputs.get(value.input);\n        if (inputId == null) {\n          inputId = inputsNextIndex;\n          inputs.set(value.input, inputsNextIndex);\n          inputsNextIndex++;\n        }\n        fixed[name] = {\n          end: value.end,\n          inputId,\n          start: value.start\n        };\n      } else {\n        fixed[name] = value;\n      }\n    }\n    if (emitInputs) {\n      fixed.inputs = [...inputs.keys()].map((input2) => input2.toJSON());\n    }\n    return fixed;\n  }\n  toProxy() {\n    if (!this.proxyCache) {\n      this.proxyCache = new Proxy(this, this.getProxyProcessor());\n    }\n    return this.proxyCache;\n  }\n  toString(stringifier2 = stringify$3$1) {\n    if (stringifier2.stringify) stringifier2 = stringifier2.stringify;\n    let result2 = \"\";\n    stringifier2(this, (i2) => {\n      result2 += i2;\n    });\n    return result2;\n  }\n  warn(result2, text, opts) {\n    let data = { node: this };\n    for (let i2 in opts) data[i2] = opts[i2];\n    return result2.warn(text, data);\n  }\n  get proxyOf() {\n    return this;\n  }\n};\nvar node$1 = Node$4$1;\nNode$4$1.default = Node$4$1;\nlet Node$3$1 = node$1;\nlet Declaration$4$1 = class Declaration extends Node$3$1 {\n  constructor(defaults) {\n    if (defaults && typeof defaults.value !== \"undefined\" && typeof defaults.value !== \"string\") {\n      defaults = { ...defaults, value: String(defaults.value) };\n    }\n    super(defaults);\n    this.type = \"decl\";\n  }\n  get variable() {\n    return this.prop.startsWith(\"--\") || this.prop[0] === \"$\";\n  }\n};\nvar declaration$1 = Declaration$4$1;\nDeclaration$4$1.default = Declaration$4$1;\nlet urlAlphabet$1 = \"useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict\";\nlet customAlphabet$1 = (alphabet, defaultSize = 21) => {\n  return (size = defaultSize) => {\n    let id = \"\";\n    let i2 = size;\n    while (i2--) {\n      id += alphabet[Math.random() * alphabet.length | 0];\n    }\n    return id;\n  };\n};\nlet nanoid$1$1 = (size = 21) => {\n  let id = \"\";\n  let i2 = size;\n  while (i2--) {\n    id += urlAlphabet$1[Math.random() * 64 | 0];\n  }\n  return id;\n};\nvar nonSecure$1 = { nanoid: nanoid$1$1, customAlphabet: customAlphabet$1 };\nlet { SourceMapConsumer: SourceMapConsumer$2$1, SourceMapGenerator: SourceMapGenerator$2$1 } = require$$2$1;\nlet { existsSync: existsSync$1, readFileSync: readFileSync$1 } = require$$2$1;\nlet { dirname: dirname$1$1, join: join$1 } = require$$2$1;\nfunction fromBase64$1(str) {\n  if (Buffer) {\n    return Buffer.from(str, \"base64\").toString();\n  } else {\n    return window.atob(str);\n  }\n}\nlet PreviousMap$2$1 = class PreviousMap {\n  constructor(css, opts) {\n    if (opts.map === false) return;\n    this.loadAnnotation(css);\n    this.inline = this.startWith(this.annotation, \"data:\");\n    let prev = opts.map ? opts.map.prev : void 0;\n    let text = this.loadMap(opts.from, prev);\n    if (!this.mapFile && opts.from) {\n      this.mapFile = opts.from;\n    }\n    if (this.mapFile) this.root = dirname$1$1(this.mapFile);\n    if (text) this.text = text;\n  }\n  consumer() {\n    if (!this.consumerCache) {\n      this.consumerCache = new SourceMapConsumer$2$1(this.text);\n    }\n    return this.consumerCache;\n  }\n  decodeInline(text) {\n    let baseCharsetUri = /^data:application\\/json;charset=utf-?8;base64,/;\n    let baseUri = /^data:application\\/json;base64,/;\n    let charsetUri = /^data:application\\/json;charset=utf-?8,/;\n    let uri = /^data:application\\/json,/;\n    if (charsetUri.test(text) || uri.test(text)) {\n      return decodeURIComponent(text.substr(RegExp.lastMatch.length));\n    }\n    if (baseCharsetUri.test(text) || baseUri.test(text)) {\n      return fromBase64$1(text.substr(RegExp.lastMatch.length));\n    }\n    let encoding = text.match(/data:application\\/json;([^,]+),/)[1];\n    throw new Error(\"Unsupported source map encoding \" + encoding);\n  }\n  getAnnotationURL(sourceMapString) {\n    return sourceMapString.replace(/^\\/\\*\\s*# sourceMappingURL=/, \"\").trim();\n  }\n  isMap(map) {\n    if (typeof map !== \"object\") return false;\n    return typeof map.mappings === \"string\" || typeof map._mappings === \"string\" || Array.isArray(map.sections);\n  }\n  loadAnnotation(css) {\n    let comments = css.match(/\\/\\*\\s*# sourceMappingURL=/gm);\n    if (!comments) return;\n    let start = css.lastIndexOf(comments.pop());\n    let end = css.indexOf(\"*/\", start);\n    if (start > -1 && end > -1) {\n      this.annotation = this.getAnnotationURL(css.substring(start, end));\n    }\n  }\n  loadFile(path) {\n    this.root = dirname$1$1(path);\n    if (existsSync$1(path)) {\n      this.mapFile = path;\n      return readFileSync$1(path, \"utf-8\").toString().trim();\n    }\n  }\n  loadMap(file, prev) {\n    if (prev === false) return false;\n    if (prev) {\n      if (typeof prev === \"string\") {\n        return prev;\n      } else if (typeof prev === \"function\") {\n        let prevPath = prev(file);\n        if (prevPath) {\n          let map = this.loadFile(prevPath);\n          if (!map) {\n            throw new Error(\n              \"Unable to load previous source map: \" + prevPath.toString()\n            );\n          }\n          return map;\n        }\n      } else if (prev instanceof SourceMapConsumer$2$1) {\n        return SourceMapGenerator$2$1.fromSourceMap(prev).toString();\n      } else if (prev instanceof SourceMapGenerator$2$1) {\n        return prev.toString();\n      } else if (this.isMap(prev)) {\n        return JSON.stringify(prev);\n      } else {\n        throw new Error(\n          \"Unsupported previous source map format: \" + prev.toString()\n        );\n      }\n    } else if (this.inline) {\n      return this.decodeInline(this.annotation);\n    } else if (this.annotation) {\n      let map = this.annotation;\n      if (file) map = join$1(dirname$1$1(file), map);\n      return this.loadFile(map);\n    }\n  }\n  startWith(string, start) {\n    if (!string) return false;\n    return string.substr(0, start.length) === start;\n  }\n  withContent() {\n    return !!(this.consumer().sourcesContent && this.consumer().sourcesContent.length > 0);\n  }\n};\nvar previousMap$1 = PreviousMap$2$1;\nPreviousMap$2$1.default = PreviousMap$2$1;\nlet { SourceMapConsumer: SourceMapConsumer$1$1, SourceMapGenerator: SourceMapGenerator$1$1 } = require$$2$1;\nlet { fileURLToPath: fileURLToPath$1, pathToFileURL: pathToFileURL$1$1 } = require$$2$1;\nlet { isAbsolute: isAbsolute$1, resolve: resolve$1$1 } = require$$2$1;\nlet { nanoid: nanoid$2 } = nonSecure$1;\nlet terminalHighlight$2 = require$$2$1;\nlet CssSyntaxError$1$1 = cssSyntaxError$1;\nlet PreviousMap$1$1 = previousMap$1;\nlet fromOffsetCache$1 = Symbol(\"fromOffsetCache\");\nlet sourceMapAvailable$1$1 = Boolean(SourceMapConsumer$1$1 && SourceMapGenerator$1$1);\nlet pathAvailable$1$1 = Boolean(resolve$1$1 && isAbsolute$1);\nlet Input$4$1 = class Input {\n  constructor(css, opts = {}) {\n    if (css === null || typeof css === \"undefined\" || typeof css === \"object\" && !css.toString) {\n      throw new Error(`PostCSS received ${css} instead of CSS string`);\n    }\n    this.css = css.toString();\n    if (this.css[0] === \"\\uFEFF\" || this.css[0] === \"￾\") {\n      this.hasBOM = true;\n      this.css = this.css.slice(1);\n    } else {\n      this.hasBOM = false;\n    }\n    if (opts.from) {\n      if (!pathAvailable$1$1 || /^\\w+:\\/\\//.test(opts.from) || isAbsolute$1(opts.from)) {\n        this.file = opts.from;\n      } else {\n        this.file = resolve$1$1(opts.from);\n      }\n    }\n    if (pathAvailable$1$1 && sourceMapAvailable$1$1) {\n      let map = new PreviousMap$1$1(this.css, opts);\n      if (map.text) {\n        this.map = map;\n        let file = map.consumer().file;\n        if (!this.file && file) this.file = this.mapResolve(file);\n      }\n    }\n    if (!this.file) {\n      this.id = \"<input css \" + nanoid$2(6) + \">\";\n    }\n    if (this.map) this.map.file = this.from;\n  }\n  error(message, line, column, opts = {}) {\n    let result2, endLine, endColumn;\n    if (line && typeof line === \"object\") {\n      let start = line;\n      let end = column;\n      if (typeof start.offset === \"number\") {\n        let pos = this.fromOffset(start.offset);\n        line = pos.line;\n        column = pos.col;\n      } else {\n        line = start.line;\n        column = start.column;\n      }\n      if (typeof end.offset === \"number\") {\n        let pos = this.fromOffset(end.offset);\n        endLine = pos.line;\n        endColumn = pos.col;\n      } else {\n        endLine = end.line;\n        endColumn = end.column;\n      }\n    } else if (!column) {\n      let pos = this.fromOffset(line);\n      line = pos.line;\n      column = pos.col;\n    }\n    let origin = this.origin(line, column, endLine, endColumn);\n    if (origin) {\n      result2 = new CssSyntaxError$1$1(\n        message,\n        origin.endLine === void 0 ? origin.line : { column: origin.column, line: origin.line },\n        origin.endLine === void 0 ? origin.column : { column: origin.endColumn, line: origin.endLine },\n        origin.source,\n        origin.file,\n        opts.plugin\n      );\n    } else {\n      result2 = new CssSyntaxError$1$1(\n        message,\n        endLine === void 0 ? line : { column, line },\n        endLine === void 0 ? column : { column: endColumn, line: endLine },\n        this.css,\n        this.file,\n        opts.plugin\n      );\n    }\n    result2.input = { column, endColumn, endLine, line, source: this.css };\n    if (this.file) {\n      if (pathToFileURL$1$1) {\n        result2.input.url = pathToFileURL$1$1(this.file).toString();\n      }\n      result2.input.file = this.file;\n    }\n    return result2;\n  }\n  fromOffset(offset) {\n    let lastLine, lineToIndex;\n    if (!this[fromOffsetCache$1]) {\n      let lines = this.css.split(\"\\n\");\n      lineToIndex = new Array(lines.length);\n      let prevIndex = 0;\n      for (let i2 = 0, l2 = lines.length; i2 < l2; i2++) {\n        lineToIndex[i2] = prevIndex;\n        prevIndex += lines[i2].length + 1;\n      }\n      this[fromOffsetCache$1] = lineToIndex;\n    } else {\n      lineToIndex = this[fromOffsetCache$1];\n    }\n    lastLine = lineToIndex[lineToIndex.length - 1];\n    let min = 0;\n    if (offset >= lastLine) {\n      min = lineToIndex.length - 1;\n    } else {\n      let max = lineToIndex.length - 2;\n      let mid;\n      while (min < max) {\n        mid = min + (max - min >> 1);\n        if (offset < lineToIndex[mid]) {\n          max = mid - 1;\n        } else if (offset >= lineToIndex[mid + 1]) {\n          min = mid + 1;\n        } else {\n          min = mid;\n          break;\n        }\n      }\n    }\n    return {\n      col: offset - lineToIndex[min] + 1,\n      line: min + 1\n    };\n  }\n  mapResolve(file) {\n    if (/^\\w+:\\/\\//.test(file)) {\n      return file;\n    }\n    return resolve$1$1(this.map.consumer().sourceRoot || this.map.root || \".\", file);\n  }\n  origin(line, column, endLine, endColumn) {\n    if (!this.map) return false;\n    let consumer = this.map.consumer();\n    let from = consumer.originalPositionFor({ column, line });\n    if (!from.source) return false;\n    let to;\n    if (typeof endLine === \"number\") {\n      to = consumer.originalPositionFor({ column: endColumn, line: endLine });\n    }\n    let fromUrl;\n    if (isAbsolute$1(from.source)) {\n      fromUrl = pathToFileURL$1$1(from.source);\n    } else {\n      fromUrl = new URL(\n        from.source,\n        this.map.consumer().sourceRoot || pathToFileURL$1$1(this.map.mapFile)\n      );\n    }\n    let result2 = {\n      column: from.column,\n      endColumn: to && to.column,\n      endLine: to && to.line,\n      line: from.line,\n      url: fromUrl.toString()\n    };\n    if (fromUrl.protocol === \"file:\") {\n      if (fileURLToPath$1) {\n        result2.file = fileURLToPath$1(fromUrl);\n      } else {\n        throw new Error(`file: protocol is not available in this PostCSS build`);\n      }\n    }\n    let source = consumer.sourceContentFor(from.source);\n    if (source) result2.source = source;\n    return result2;\n  }\n  toJSON() {\n    let json = {};\n    for (let name of [\"hasBOM\", \"css\", \"file\", \"id\"]) {\n      if (this[name] != null) {\n        json[name] = this[name];\n      }\n    }\n    if (this.map) {\n      json.map = { ...this.map };\n      if (json.map.consumerCache) {\n        json.map.consumerCache = void 0;\n      }\n    }\n    return json;\n  }\n  get from() {\n    return this.file || this.id;\n  }\n};\nvar input$1 = Input$4$1;\nInput$4$1.default = Input$4$1;\nif (terminalHighlight$2 && terminalHighlight$2.registerInput) {\n  terminalHighlight$2.registerInput(Input$4$1);\n}\nlet { SourceMapConsumer: SourceMapConsumer$3, SourceMapGenerator: SourceMapGenerator$3 } = require$$2$1;\nlet { dirname: dirname$2, relative: relative$1, resolve: resolve$2, sep: sep$1 } = require$$2$1;\nlet { pathToFileURL: pathToFileURL$2 } = require$$2$1;\nlet Input$3$1 = input$1;\nlet sourceMapAvailable$2 = Boolean(SourceMapConsumer$3 && SourceMapGenerator$3);\nlet pathAvailable$2 = Boolean(dirname$2 && resolve$2 && relative$1 && sep$1);\nlet MapGenerator$2$1 = class MapGenerator {\n  constructor(stringify2, root2, opts, cssString) {\n    this.stringify = stringify2;\n    this.mapOpts = opts.map || {};\n    this.root = root2;\n    this.opts = opts;\n    this.css = cssString;\n    this.originalCSS = cssString;\n    this.usesFileUrls = !this.mapOpts.from && this.mapOpts.absolute;\n    this.memoizedFileURLs = /* @__PURE__ */ new Map();\n    this.memoizedPaths = /* @__PURE__ */ new Map();\n    this.memoizedURLs = /* @__PURE__ */ new Map();\n  }\n  addAnnotation() {\n    let content;\n    if (this.isInline()) {\n      content = \"data:application/json;base64,\" + this.toBase64(this.map.toString());\n    } else if (typeof this.mapOpts.annotation === \"string\") {\n      content = this.mapOpts.annotation;\n    } else if (typeof this.mapOpts.annotation === \"function\") {\n      content = this.mapOpts.annotation(this.opts.to, this.root);\n    } else {\n      content = this.outputFile() + \".map\";\n    }\n    let eol = \"\\n\";\n    if (this.css.includes(\"\\r\\n\")) eol = \"\\r\\n\";\n    this.css += eol + \"/*# sourceMappingURL=\" + content + \" */\";\n  }\n  applyPrevMaps() {\n    for (let prev of this.previous()) {\n      let from = this.toUrl(this.path(prev.file));\n      let root2 = prev.root || dirname$2(prev.file);\n      let map;\n      if (this.mapOpts.sourcesContent === false) {\n        map = new SourceMapConsumer$3(prev.text);\n        if (map.sourcesContent) {\n          map.sourcesContent = null;\n        }\n      } else {\n        map = prev.consumer();\n      }\n      this.map.applySourceMap(map, from, this.toUrl(this.path(root2)));\n    }\n  }\n  clearAnnotation() {\n    if (this.mapOpts.annotation === false) return;\n    if (this.root) {\n      let node2;\n      for (let i2 = this.root.nodes.length - 1; i2 >= 0; i2--) {\n        node2 = this.root.nodes[i2];\n        if (node2.type !== \"comment\") continue;\n        if (node2.text.indexOf(\"# sourceMappingURL=\") === 0) {\n          this.root.removeChild(i2);\n        }\n      }\n    } else if (this.css) {\n      this.css = this.css.replace(/\\n*?\\/\\*#[\\S\\s]*?\\*\\/$/gm, \"\");\n    }\n  }\n  generate() {\n    this.clearAnnotation();\n    if (pathAvailable$2 && sourceMapAvailable$2 && this.isMap()) {\n      return this.generateMap();\n    } else {\n      let result2 = \"\";\n      this.stringify(this.root, (i2) => {\n        result2 += i2;\n      });\n      return [result2];\n    }\n  }\n  generateMap() {\n    if (this.root) {\n      this.generateString();\n    } else if (this.previous().length === 1) {\n      let prev = this.previous()[0].consumer();\n      prev.file = this.outputFile();\n      this.map = SourceMapGenerator$3.fromSourceMap(prev, {\n        ignoreInvalidMapping: true\n      });\n    } else {\n      this.map = new SourceMapGenerator$3({\n        file: this.outputFile(),\n        ignoreInvalidMapping: true\n      });\n      this.map.addMapping({\n        generated: { column: 0, line: 1 },\n        original: { column: 0, line: 1 },\n        source: this.opts.from ? this.toUrl(this.path(this.opts.from)) : \"<no source>\"\n      });\n    }\n    if (this.isSourcesContent()) this.setSourcesContent();\n    if (this.root && this.previous().length > 0) this.applyPrevMaps();\n    if (this.isAnnotation()) this.addAnnotation();\n    if (this.isInline()) {\n      return [this.css];\n    } else {\n      return [this.css, this.map];\n    }\n  }\n  generateString() {\n    this.css = \"\";\n    this.map = new SourceMapGenerator$3({\n      file: this.outputFile(),\n      ignoreInvalidMapping: true\n    });\n    let line = 1;\n    let column = 1;\n    let noSource = \"<no source>\";\n    let mapping = {\n      generated: { column: 0, line: 0 },\n      original: { column: 0, line: 0 },\n      source: \"\"\n    };\n    let lines, last;\n    this.stringify(this.root, (str, node2, type) => {\n      this.css += str;\n      if (node2 && type !== \"end\") {\n        mapping.generated.line = line;\n        mapping.generated.column = column - 1;\n        if (node2.source && node2.source.start) {\n          mapping.source = this.sourcePath(node2);\n          mapping.original.line = node2.source.start.line;\n          mapping.original.column = node2.source.start.column - 1;\n          this.map.addMapping(mapping);\n        } else {\n          mapping.source = noSource;\n          mapping.original.line = 1;\n          mapping.original.column = 0;\n          this.map.addMapping(mapping);\n        }\n      }\n      lines = str.match(/\\n/g);\n      if (lines) {\n        line += lines.length;\n        last = str.lastIndexOf(\"\\n\");\n        column = str.length - last;\n      } else {\n        column += str.length;\n      }\n      if (node2 && type !== \"start\") {\n        let p = node2.parent || { raws: {} };\n        let childless = node2.type === \"decl\" || node2.type === \"atrule\" && !node2.nodes;\n        if (!childless || node2 !== p.last || p.raws.semicolon) {\n          if (node2.source && node2.source.end) {\n            mapping.source = this.sourcePath(node2);\n            mapping.original.line = node2.source.end.line;\n            mapping.original.column = node2.source.end.column - 1;\n            mapping.generated.line = line;\n            mapping.generated.column = column - 2;\n            this.map.addMapping(mapping);\n          } else {\n            mapping.source = noSource;\n            mapping.original.line = 1;\n            mapping.original.column = 0;\n            mapping.generated.line = line;\n            mapping.generated.column = column - 1;\n            this.map.addMapping(mapping);\n          }\n        }\n      }\n    });\n  }\n  isAnnotation() {\n    if (this.isInline()) {\n      return true;\n    }\n    if (typeof this.mapOpts.annotation !== \"undefined\") {\n      return this.mapOpts.annotation;\n    }\n    if (this.previous().length) {\n      return this.previous().some((i2) => i2.annotation);\n    }\n    return true;\n  }\n  isInline() {\n    if (typeof this.mapOpts.inline !== \"undefined\") {\n      return this.mapOpts.inline;\n    }\n    let annotation = this.mapOpts.annotation;\n    if (typeof annotation !== \"undefined\" && annotation !== true) {\n      return false;\n    }\n    if (this.previous().length) {\n      return this.previous().some((i2) => i2.inline);\n    }\n    return true;\n  }\n  isMap() {\n    if (typeof this.opts.map !== \"undefined\") {\n      return !!this.opts.map;\n    }\n    return this.previous().length > 0;\n  }\n  isSourcesContent() {\n    if (typeof this.mapOpts.sourcesContent !== \"undefined\") {\n      return this.mapOpts.sourcesContent;\n    }\n    if (this.previous().length) {\n      return this.previous().some((i2) => i2.withContent());\n    }\n    return true;\n  }\n  outputFile() {\n    if (this.opts.to) {\n      return this.path(this.opts.to);\n    } else if (this.opts.from) {\n      return this.path(this.opts.from);\n    } else {\n      return \"to.css\";\n    }\n  }\n  path(file) {\n    if (this.mapOpts.absolute) return file;\n    if (file.charCodeAt(0) === 60) return file;\n    if (/^\\w+:\\/\\//.test(file)) return file;\n    let cached = this.memoizedPaths.get(file);\n    if (cached) return cached;\n    let from = this.opts.to ? dirname$2(this.opts.to) : \".\";\n    if (typeof this.mapOpts.annotation === \"string\") {\n      from = dirname$2(resolve$2(from, this.mapOpts.annotation));\n    }\n    let path = relative$1(from, file);\n    this.memoizedPaths.set(file, path);\n    return path;\n  }\n  previous() {\n    if (!this.previousMaps) {\n      this.previousMaps = [];\n      if (this.root) {\n        this.root.walk((node2) => {\n          if (node2.source && node2.source.input.map) {\n            let map = node2.source.input.map;\n            if (!this.previousMaps.includes(map)) {\n              this.previousMaps.push(map);\n            }\n          }\n        });\n      } else {\n        let input2 = new Input$3$1(this.originalCSS, this.opts);\n        if (input2.map) this.previousMaps.push(input2.map);\n      }\n    }\n    return this.previousMaps;\n  }\n  setSourcesContent() {\n    let already = {};\n    if (this.root) {\n      this.root.walk((node2) => {\n        if (node2.source) {\n          let from = node2.source.input.from;\n          if (from && !already[from]) {\n            already[from] = true;\n            let fromUrl = this.usesFileUrls ? this.toFileUrl(from) : this.toUrl(this.path(from));\n            this.map.setSourceContent(fromUrl, node2.source.input.css);\n          }\n        }\n      });\n    } else if (this.css) {\n      let from = this.opts.from ? this.toUrl(this.path(this.opts.from)) : \"<no source>\";\n      this.map.setSourceContent(from, this.css);\n    }\n  }\n  sourcePath(node2) {\n    if (this.mapOpts.from) {\n      return this.toUrl(this.mapOpts.from);\n    } else if (this.usesFileUrls) {\n      return this.toFileUrl(node2.source.input.from);\n    } else {\n      return this.toUrl(this.path(node2.source.input.from));\n    }\n  }\n  toBase64(str) {\n    if (Buffer) {\n      return Buffer.from(str).toString(\"base64\");\n    } else {\n      return window.btoa(unescape(encodeURIComponent(str)));\n    }\n  }\n  toFileUrl(path) {\n    let cached = this.memoizedFileURLs.get(path);\n    if (cached) return cached;\n    if (pathToFileURL$2) {\n      let fileURL = pathToFileURL$2(path).toString();\n      this.memoizedFileURLs.set(path, fileURL);\n      return fileURL;\n    } else {\n      throw new Error(\n        \"`map.absolute` option is not available in this PostCSS build\"\n      );\n    }\n  }\n  toUrl(path) {\n    let cached = this.memoizedURLs.get(path);\n    if (cached) return cached;\n    if (sep$1 === \"\\\\\") {\n      path = path.replace(/\\\\/g, \"/\");\n    }\n    let url = encodeURI(path).replace(/[#?]/g, encodeURIComponent);\n    this.memoizedURLs.set(path, url);\n    return url;\n  }\n};\nvar mapGenerator$1 = MapGenerator$2$1;\nlet Node$2$1 = node$1;\nlet Comment$4$1 = class Comment extends Node$2$1 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"comment\";\n  }\n};\nvar comment$1 = Comment$4$1;\nComment$4$1.default = Comment$4$1;\nlet { isClean: isClean$1$1, my: my$1$1 } = symbols$1;\nlet Declaration$3$1 = declaration$1;\nlet Comment$3$1 = comment$1;\nlet Node$1$1 = node$1;\nlet parse$4$1, Rule$4$1, AtRule$4$1, Root$6$1;\nfunction cleanSource$1(nodes) {\n  return nodes.map((i2) => {\n    if (i2.nodes) i2.nodes = cleanSource$1(i2.nodes);\n    delete i2.source;\n    return i2;\n  });\n}\nfunction markDirtyUp$1(node2) {\n  node2[isClean$1$1] = false;\n  if (node2.proxyOf.nodes) {\n    for (let i2 of node2.proxyOf.nodes) {\n      markDirtyUp$1(i2);\n    }\n  }\n}\nlet Container$7$1 = class Container extends Node$1$1 {\n  append(...children) {\n    for (let child of children) {\n      let nodes = this.normalize(child, this.last);\n      for (let node2 of nodes) this.proxyOf.nodes.push(node2);\n    }\n    this.markDirty();\n    return this;\n  }\n  cleanRaws(keepBetween) {\n    super.cleanRaws(keepBetween);\n    if (this.nodes) {\n      for (let node2 of this.nodes) node2.cleanRaws(keepBetween);\n    }\n  }\n  each(callback) {\n    if (!this.proxyOf.nodes) return void 0;\n    let iterator = this.getIterator();\n    let index2, result2;\n    while (this.indexes[iterator] < this.proxyOf.nodes.length) {\n      index2 = this.indexes[iterator];\n      result2 = callback(this.proxyOf.nodes[index2], index2);\n      if (result2 === false) break;\n      this.indexes[iterator] += 1;\n    }\n    delete this.indexes[iterator];\n    return result2;\n  }\n  every(condition) {\n    return this.nodes.every(condition);\n  }\n  getIterator() {\n    if (!this.lastEach) this.lastEach = 0;\n    if (!this.indexes) this.indexes = {};\n    this.lastEach += 1;\n    let iterator = this.lastEach;\n    this.indexes[iterator] = 0;\n    return iterator;\n  }\n  getProxyProcessor() {\n    return {\n      get(node2, prop) {\n        if (prop === \"proxyOf\") {\n          return node2;\n        } else if (!node2[prop]) {\n          return node2[prop];\n        } else if (prop === \"each\" || typeof prop === \"string\" && prop.startsWith(\"walk\")) {\n          return (...args) => {\n            return node2[prop](\n              ...args.map((i2) => {\n                if (typeof i2 === \"function\") {\n                  return (child, index2) => i2(child.toProxy(), index2);\n                } else {\n                  return i2;\n                }\n              })\n            );\n          };\n        } else if (prop === \"every\" || prop === \"some\") {\n          return (cb) => {\n            return node2[prop](\n              (child, ...other) => cb(child.toProxy(), ...other)\n            );\n          };\n        } else if (prop === \"root\") {\n          return () => node2.root().toProxy();\n        } else if (prop === \"nodes\") {\n          return node2.nodes.map((i2) => i2.toProxy());\n        } else if (prop === \"first\" || prop === \"last\") {\n          return node2[prop].toProxy();\n        } else {\n          return node2[prop];\n        }\n      },\n      set(node2, prop, value) {\n        if (node2[prop] === value) return true;\n        node2[prop] = value;\n        if (prop === \"name\" || prop === \"params\" || prop === \"selector\") {\n          node2.markDirty();\n        }\n        return true;\n      }\n    };\n  }\n  index(child) {\n    if (typeof child === \"number\") return child;\n    if (child.proxyOf) child = child.proxyOf;\n    return this.proxyOf.nodes.indexOf(child);\n  }\n  insertAfter(exist, add) {\n    let existIndex = this.index(exist);\n    let nodes = this.normalize(add, this.proxyOf.nodes[existIndex]).reverse();\n    existIndex = this.index(exist);\n    for (let node2 of nodes) this.proxyOf.nodes.splice(existIndex + 1, 0, node2);\n    let index2;\n    for (let id in this.indexes) {\n      index2 = this.indexes[id];\n      if (existIndex < index2) {\n        this.indexes[id] = index2 + nodes.length;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  insertBefore(exist, add) {\n    let existIndex = this.index(exist);\n    let type = existIndex === 0 ? \"prepend\" : false;\n    let nodes = this.normalize(add, this.proxyOf.nodes[existIndex], type).reverse();\n    existIndex = this.index(exist);\n    for (let node2 of nodes) this.proxyOf.nodes.splice(existIndex, 0, node2);\n    let index2;\n    for (let id in this.indexes) {\n      index2 = this.indexes[id];\n      if (existIndex <= index2) {\n        this.indexes[id] = index2 + nodes.length;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  normalize(nodes, sample) {\n    if (typeof nodes === \"string\") {\n      nodes = cleanSource$1(parse$4$1(nodes).nodes);\n    } else if (typeof nodes === \"undefined\") {\n      nodes = [];\n    } else if (Array.isArray(nodes)) {\n      nodes = nodes.slice(0);\n      for (let i2 of nodes) {\n        if (i2.parent) i2.parent.removeChild(i2, \"ignore\");\n      }\n    } else if (nodes.type === \"root\" && this.type !== \"document\") {\n      nodes = nodes.nodes.slice(0);\n      for (let i2 of nodes) {\n        if (i2.parent) i2.parent.removeChild(i2, \"ignore\");\n      }\n    } else if (nodes.type) {\n      nodes = [nodes];\n    } else if (nodes.prop) {\n      if (typeof nodes.value === \"undefined\") {\n        throw new Error(\"Value field is missed in node creation\");\n      } else if (typeof nodes.value !== \"string\") {\n        nodes.value = String(nodes.value);\n      }\n      nodes = [new Declaration$3$1(nodes)];\n    } else if (nodes.selector) {\n      nodes = [new Rule$4$1(nodes)];\n    } else if (nodes.name) {\n      nodes = [new AtRule$4$1(nodes)];\n    } else if (nodes.text) {\n      nodes = [new Comment$3$1(nodes)];\n    } else {\n      throw new Error(\"Unknown node type in node creation\");\n    }\n    let processed = nodes.map((i2) => {\n      if (!i2[my$1$1]) Container.rebuild(i2);\n      i2 = i2.proxyOf;\n      if (i2.parent) i2.parent.removeChild(i2);\n      if (i2[isClean$1$1]) markDirtyUp$1(i2);\n      if (typeof i2.raws.before === \"undefined\") {\n        if (sample && typeof sample.raws.before !== \"undefined\") {\n          i2.raws.before = sample.raws.before.replace(/\\S/g, \"\");\n        }\n      }\n      i2.parent = this.proxyOf;\n      return i2;\n    });\n    return processed;\n  }\n  prepend(...children) {\n    children = children.reverse();\n    for (let child of children) {\n      let nodes = this.normalize(child, this.first, \"prepend\").reverse();\n      for (let node2 of nodes) this.proxyOf.nodes.unshift(node2);\n      for (let id in this.indexes) {\n        this.indexes[id] = this.indexes[id] + nodes.length;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  push(child) {\n    child.parent = this;\n    this.proxyOf.nodes.push(child);\n    return this;\n  }\n  removeAll() {\n    for (let node2 of this.proxyOf.nodes) node2.parent = void 0;\n    this.proxyOf.nodes = [];\n    this.markDirty();\n    return this;\n  }\n  removeChild(child) {\n    child = this.index(child);\n    this.proxyOf.nodes[child].parent = void 0;\n    this.proxyOf.nodes.splice(child, 1);\n    let index2;\n    for (let id in this.indexes) {\n      index2 = this.indexes[id];\n      if (index2 >= child) {\n        this.indexes[id] = index2 - 1;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  replaceValues(pattern, opts, callback) {\n    if (!callback) {\n      callback = opts;\n      opts = {};\n    }\n    this.walkDecls((decl) => {\n      if (opts.props && !opts.props.includes(decl.prop)) return;\n      if (opts.fast && !decl.value.includes(opts.fast)) return;\n      decl.value = decl.value.replace(pattern, callback);\n    });\n    this.markDirty();\n    return this;\n  }\n  some(condition) {\n    return this.nodes.some(condition);\n  }\n  walk(callback) {\n    return this.each((child, i2) => {\n      let result2;\n      try {\n        result2 = callback(child, i2);\n      } catch (e2) {\n        throw child.addToError(e2);\n      }\n      if (result2 !== false && child.walk) {\n        result2 = child.walk(callback);\n      }\n      return result2;\n    });\n  }\n  walkAtRules(name, callback) {\n    if (!callback) {\n      callback = name;\n      return this.walk((child, i2) => {\n        if (child.type === \"atrule\") {\n          return callback(child, i2);\n        }\n      });\n    }\n    if (name instanceof RegExp) {\n      return this.walk((child, i2) => {\n        if (child.type === \"atrule\" && name.test(child.name)) {\n          return callback(child, i2);\n        }\n      });\n    }\n    return this.walk((child, i2) => {\n      if (child.type === \"atrule\" && child.name === name) {\n        return callback(child, i2);\n      }\n    });\n  }\n  walkComments(callback) {\n    return this.walk((child, i2) => {\n      if (child.type === \"comment\") {\n        return callback(child, i2);\n      }\n    });\n  }\n  walkDecls(prop, callback) {\n    if (!callback) {\n      callback = prop;\n      return this.walk((child, i2) => {\n        if (child.type === \"decl\") {\n          return callback(child, i2);\n        }\n      });\n    }\n    if (prop instanceof RegExp) {\n      return this.walk((child, i2) => {\n        if (child.type === \"decl\" && prop.test(child.prop)) {\n          return callback(child, i2);\n        }\n      });\n    }\n    return this.walk((child, i2) => {\n      if (child.type === \"decl\" && child.prop === prop) {\n        return callback(child, i2);\n      }\n    });\n  }\n  walkRules(selector, callback) {\n    if (!callback) {\n      callback = selector;\n      return this.walk((child, i2) => {\n        if (child.type === \"rule\") {\n          return callback(child, i2);\n        }\n      });\n    }\n    if (selector instanceof RegExp) {\n      return this.walk((child, i2) => {\n        if (child.type === \"rule\" && selector.test(child.selector)) {\n          return callback(child, i2);\n        }\n      });\n    }\n    return this.walk((child, i2) => {\n      if (child.type === \"rule\" && child.selector === selector) {\n        return callback(child, i2);\n      }\n    });\n  }\n  get first() {\n    if (!this.proxyOf.nodes) return void 0;\n    return this.proxyOf.nodes[0];\n  }\n  get last() {\n    if (!this.proxyOf.nodes) return void 0;\n    return this.proxyOf.nodes[this.proxyOf.nodes.length - 1];\n  }\n};\nContainer$7$1.registerParse = (dependant) => {\n  parse$4$1 = dependant;\n};\nContainer$7$1.registerRule = (dependant) => {\n  Rule$4$1 = dependant;\n};\nContainer$7$1.registerAtRule = (dependant) => {\n  AtRule$4$1 = dependant;\n};\nContainer$7$1.registerRoot = (dependant) => {\n  Root$6$1 = dependant;\n};\nvar container$1 = Container$7$1;\nContainer$7$1.default = Container$7$1;\nContainer$7$1.rebuild = (node2) => {\n  if (node2.type === \"atrule\") {\n    Object.setPrototypeOf(node2, AtRule$4$1.prototype);\n  } else if (node2.type === \"rule\") {\n    Object.setPrototypeOf(node2, Rule$4$1.prototype);\n  } else if (node2.type === \"decl\") {\n    Object.setPrototypeOf(node2, Declaration$3$1.prototype);\n  } else if (node2.type === \"comment\") {\n    Object.setPrototypeOf(node2, Comment$3$1.prototype);\n  } else if (node2.type === \"root\") {\n    Object.setPrototypeOf(node2, Root$6$1.prototype);\n  }\n  node2[my$1$1] = true;\n  if (node2.nodes) {\n    node2.nodes.forEach((child) => {\n      Container$7$1.rebuild(child);\n    });\n  }\n};\nlet Container$6$1 = container$1;\nlet LazyResult$4$1, Processor$3$1;\nlet Document$3$1 = class Document2 extends Container$6$1 {\n  constructor(defaults) {\n    super({ type: \"document\", ...defaults });\n    if (!this.nodes) {\n      this.nodes = [];\n    }\n  }\n  toResult(opts = {}) {\n    let lazy = new LazyResult$4$1(new Processor$3$1(), this, opts);\n    return lazy.stringify();\n  }\n};\nDocument$3$1.registerLazyResult = (dependant) => {\n  LazyResult$4$1 = dependant;\n};\nDocument$3$1.registerProcessor = (dependant) => {\n  Processor$3$1 = dependant;\n};\nvar document$1$1 = Document$3$1;\nDocument$3$1.default = Document$3$1;\nlet printed$1 = {};\nvar warnOnce$2$1 = function warnOnce(message) {\n  if (printed$1[message]) return;\n  printed$1[message] = true;\n  if (typeof console !== \"undefined\" && console.warn) {\n    console.warn(message);\n  }\n};\nlet Warning$2$1 = class Warning {\n  constructor(text, opts = {}) {\n    this.type = \"warning\";\n    this.text = text;\n    if (opts.node && opts.node.source) {\n      let range = opts.node.rangeBy(opts);\n      this.line = range.start.line;\n      this.column = range.start.column;\n      this.endLine = range.end.line;\n      this.endColumn = range.end.column;\n    }\n    for (let opt in opts) this[opt] = opts[opt];\n  }\n  toString() {\n    if (this.node) {\n      return this.node.error(this.text, {\n        index: this.index,\n        plugin: this.plugin,\n        word: this.word\n      }).message;\n    }\n    if (this.plugin) {\n      return this.plugin + \": \" + this.text;\n    }\n    return this.text;\n  }\n};\nvar warning$1 = Warning$2$1;\nWarning$2$1.default = Warning$2$1;\nlet Warning$1$1 = warning$1;\nlet Result$3$1 = class Result {\n  constructor(processor2, root2, opts) {\n    this.processor = processor2;\n    this.messages = [];\n    this.root = root2;\n    this.opts = opts;\n    this.css = void 0;\n    this.map = void 0;\n  }\n  toString() {\n    return this.css;\n  }\n  warn(text, opts = {}) {\n    if (!opts.plugin) {\n      if (this.lastPlugin && this.lastPlugin.postcssPlugin) {\n        opts.plugin = this.lastPlugin.postcssPlugin;\n      }\n    }\n    let warning2 = new Warning$1$1(text, opts);\n    this.messages.push(warning2);\n    return warning2;\n  }\n  warnings() {\n    return this.messages.filter((i2) => i2.type === \"warning\");\n  }\n  get content() {\n    return this.css;\n  }\n};\nvar result$1 = Result$3$1;\nResult$3$1.default = Result$3$1;\nconst SINGLE_QUOTE$1 = \"'\".charCodeAt(0);\nconst DOUBLE_QUOTE$1 = '\"'.charCodeAt(0);\nconst BACKSLASH$1 = \"\\\\\".charCodeAt(0);\nconst SLASH$1 = \"/\".charCodeAt(0);\nconst NEWLINE$1 = \"\\n\".charCodeAt(0);\nconst SPACE$1 = \" \".charCodeAt(0);\nconst FEED$1 = \"\\f\".charCodeAt(0);\nconst TAB$1 = \"\t\".charCodeAt(0);\nconst CR$1 = \"\\r\".charCodeAt(0);\nconst OPEN_SQUARE$1 = \"[\".charCodeAt(0);\nconst CLOSE_SQUARE$1 = \"]\".charCodeAt(0);\nconst OPEN_PARENTHESES$1 = \"(\".charCodeAt(0);\nconst CLOSE_PARENTHESES$1 = \")\".charCodeAt(0);\nconst OPEN_CURLY$1 = \"{\".charCodeAt(0);\nconst CLOSE_CURLY$1 = \"}\".charCodeAt(0);\nconst SEMICOLON$1 = \";\".charCodeAt(0);\nconst ASTERISK$1 = \"*\".charCodeAt(0);\nconst COLON$1 = \":\".charCodeAt(0);\nconst AT$1 = \"@\".charCodeAt(0);\nconst RE_AT_END$1 = /[\\t\\n\\f\\r \"#'()/;[\\\\\\]{}]/g;\nconst RE_WORD_END$1 = /[\\t\\n\\f\\r !\"#'():;@[\\\\\\]{}]|\\/(?=\\*)/g;\nconst RE_BAD_BRACKET$1 = /.[\\r\\n\"'(/\\\\]/;\nconst RE_HEX_ESCAPE$1 = /[\\da-f]/i;\nvar tokenize$1 = function tokenizer(input2, options = {}) {\n  let css = input2.css.valueOf();\n  let ignore = options.ignoreErrors;\n  let code, next, quote, content, escape;\n  let escaped, escapePos, prev, n2, currentToken;\n  let length = css.length;\n  let pos = 0;\n  let buffer = [];\n  let returned = [];\n  function position() {\n    return pos;\n  }\n  function unclosed(what) {\n    throw input2.error(\"Unclosed \" + what, pos);\n  }\n  function endOfFile() {\n    return returned.length === 0 && pos >= length;\n  }\n  function nextToken(opts) {\n    if (returned.length) return returned.pop();\n    if (pos >= length) return;\n    let ignoreUnclosed = opts ? opts.ignoreUnclosed : false;\n    code = css.charCodeAt(pos);\n    switch (code) {\n      case NEWLINE$1:\n      case SPACE$1:\n      case TAB$1:\n      case CR$1:\n      case FEED$1: {\n        next = pos;\n        do {\n          next += 1;\n          code = css.charCodeAt(next);\n        } while (code === SPACE$1 || code === NEWLINE$1 || code === TAB$1 || code === CR$1 || code === FEED$1);\n        currentToken = [\"space\", css.slice(pos, next)];\n        pos = next - 1;\n        break;\n      }\n      case OPEN_SQUARE$1:\n      case CLOSE_SQUARE$1:\n      case OPEN_CURLY$1:\n      case CLOSE_CURLY$1:\n      case COLON$1:\n      case SEMICOLON$1:\n      case CLOSE_PARENTHESES$1: {\n        let controlChar = String.fromCharCode(code);\n        currentToken = [controlChar, controlChar, pos];\n        break;\n      }\n      case OPEN_PARENTHESES$1: {\n        prev = buffer.length ? buffer.pop()[1] : \"\";\n        n2 = css.charCodeAt(pos + 1);\n        if (prev === \"url\" && n2 !== SINGLE_QUOTE$1 && n2 !== DOUBLE_QUOTE$1 && n2 !== SPACE$1 && n2 !== NEWLINE$1 && n2 !== TAB$1 && n2 !== FEED$1 && n2 !== CR$1) {\n          next = pos;\n          do {\n            escaped = false;\n            next = css.indexOf(\")\", next + 1);\n            if (next === -1) {\n              if (ignore || ignoreUnclosed) {\n                next = pos;\n                break;\n              } else {\n                unclosed(\"bracket\");\n              }\n            }\n            escapePos = next;\n            while (css.charCodeAt(escapePos - 1) === BACKSLASH$1) {\n              escapePos -= 1;\n              escaped = !escaped;\n            }\n          } while (escaped);\n          currentToken = [\"brackets\", css.slice(pos, next + 1), pos, next];\n          pos = next;\n        } else {\n          next = css.indexOf(\")\", pos + 1);\n          content = css.slice(pos, next + 1);\n          if (next === -1 || RE_BAD_BRACKET$1.test(content)) {\n            currentToken = [\"(\", \"(\", pos];\n          } else {\n            currentToken = [\"brackets\", content, pos, next];\n            pos = next;\n          }\n        }\n        break;\n      }\n      case SINGLE_QUOTE$1:\n      case DOUBLE_QUOTE$1: {\n        quote = code === SINGLE_QUOTE$1 ? \"'\" : '\"';\n        next = pos;\n        do {\n          escaped = false;\n          next = css.indexOf(quote, next + 1);\n          if (next === -1) {\n            if (ignore || ignoreUnclosed) {\n              next = pos + 1;\n              break;\n            } else {\n              unclosed(\"string\");\n            }\n          }\n          escapePos = next;\n          while (css.charCodeAt(escapePos - 1) === BACKSLASH$1) {\n            escapePos -= 1;\n            escaped = !escaped;\n          }\n        } while (escaped);\n        currentToken = [\"string\", css.slice(pos, next + 1), pos, next];\n        pos = next;\n        break;\n      }\n      case AT$1: {\n        RE_AT_END$1.lastIndex = pos + 1;\n        RE_AT_END$1.test(css);\n        if (RE_AT_END$1.lastIndex === 0) {\n          next = css.length - 1;\n        } else {\n          next = RE_AT_END$1.lastIndex - 2;\n        }\n        currentToken = [\"at-word\", css.slice(pos, next + 1), pos, next];\n        pos = next;\n        break;\n      }\n      case BACKSLASH$1: {\n        next = pos;\n        escape = true;\n        while (css.charCodeAt(next + 1) === BACKSLASH$1) {\n          next += 1;\n          escape = !escape;\n        }\n        code = css.charCodeAt(next + 1);\n        if (escape && code !== SLASH$1 && code !== SPACE$1 && code !== NEWLINE$1 && code !== TAB$1 && code !== CR$1 && code !== FEED$1) {\n          next += 1;\n          if (RE_HEX_ESCAPE$1.test(css.charAt(next))) {\n            while (RE_HEX_ESCAPE$1.test(css.charAt(next + 1))) {\n              next += 1;\n            }\n            if (css.charCodeAt(next + 1) === SPACE$1) {\n              next += 1;\n            }\n          }\n        }\n        currentToken = [\"word\", css.slice(pos, next + 1), pos, next];\n        pos = next;\n        break;\n      }\n      default: {\n        if (code === SLASH$1 && css.charCodeAt(pos + 1) === ASTERISK$1) {\n          next = css.indexOf(\"*/\", pos + 2) + 1;\n          if (next === 0) {\n            if (ignore || ignoreUnclosed) {\n              next = css.length;\n            } else {\n              unclosed(\"comment\");\n            }\n          }\n          currentToken = [\"comment\", css.slice(pos, next + 1), pos, next];\n          pos = next;\n        } else {\n          RE_WORD_END$1.lastIndex = pos + 1;\n          RE_WORD_END$1.test(css);\n          if (RE_WORD_END$1.lastIndex === 0) {\n            next = css.length - 1;\n          } else {\n            next = RE_WORD_END$1.lastIndex - 2;\n          }\n          currentToken = [\"word\", css.slice(pos, next + 1), pos, next];\n          buffer.push(currentToken);\n          pos = next;\n        }\n        break;\n      }\n    }\n    pos++;\n    return currentToken;\n  }\n  function back(token) {\n    returned.push(token);\n  }\n  return {\n    back,\n    endOfFile,\n    nextToken,\n    position\n  };\n};\nlet Container$5$1 = container$1;\nlet AtRule$3$1 = class AtRule extends Container$5$1 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"atrule\";\n  }\n  append(...children) {\n    if (!this.proxyOf.nodes) this.nodes = [];\n    return super.append(...children);\n  }\n  prepend(...children) {\n    if (!this.proxyOf.nodes) this.nodes = [];\n    return super.prepend(...children);\n  }\n};\nvar atRule$1 = AtRule$3$1;\nAtRule$3$1.default = AtRule$3$1;\nContainer$5$1.registerAtRule(AtRule$3$1);\nlet Container$4$1 = container$1;\nlet LazyResult$3$1, Processor$2$1;\nlet Root$5$1 = class Root extends Container$4$1 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"root\";\n    if (!this.nodes) this.nodes = [];\n  }\n  normalize(child, sample, type) {\n    let nodes = super.normalize(child);\n    if (sample) {\n      if (type === \"prepend\") {\n        if (this.nodes.length > 1) {\n          sample.raws.before = this.nodes[1].raws.before;\n        } else {\n          delete sample.raws.before;\n        }\n      } else if (this.first !== sample) {\n        for (let node2 of nodes) {\n          node2.raws.before = sample.raws.before;\n        }\n      }\n    }\n    return nodes;\n  }\n  removeChild(child, ignore) {\n    let index2 = this.index(child);\n    if (!ignore && index2 === 0 && this.nodes.length > 1) {\n      this.nodes[1].raws.before = this.nodes[index2].raws.before;\n    }\n    return super.removeChild(child);\n  }\n  toResult(opts = {}) {\n    let lazy = new LazyResult$3$1(new Processor$2$1(), this, opts);\n    return lazy.stringify();\n  }\n};\nRoot$5$1.registerLazyResult = (dependant) => {\n  LazyResult$3$1 = dependant;\n};\nRoot$5$1.registerProcessor = (dependant) => {\n  Processor$2$1 = dependant;\n};\nvar root$1 = Root$5$1;\nRoot$5$1.default = Root$5$1;\nContainer$4$1.registerRoot(Root$5$1);\nlet list$2$1 = {\n  comma(string) {\n    return list$2$1.split(string, [\",\"], true);\n  },\n  space(string) {\n    let spaces = [\" \", \"\\n\", \"\t\"];\n    return list$2$1.split(string, spaces);\n  },\n  split(string, separators, last) {\n    let array = [];\n    let current = \"\";\n    let split = false;\n    let func = 0;\n    let inQuote = false;\n    let prevQuote = \"\";\n    let escape = false;\n    for (let letter of string) {\n      if (escape) {\n        escape = false;\n      } else if (letter === \"\\\\\") {\n        escape = true;\n      } else if (inQuote) {\n        if (letter === prevQuote) {\n          inQuote = false;\n        }\n      } else if (letter === '\"' || letter === \"'\") {\n        inQuote = true;\n        prevQuote = letter;\n      } else if (letter === \"(\") {\n        func += 1;\n      } else if (letter === \")\") {\n        if (func > 0) func -= 1;\n      } else if (func === 0) {\n        if (separators.includes(letter)) split = true;\n      }\n      if (split) {\n        if (current !== \"\") array.push(current.trim());\n        current = \"\";\n        split = false;\n      } else {\n        current += letter;\n      }\n    }\n    if (last || current !== \"\") array.push(current.trim());\n    return array;\n  }\n};\nvar list_1$1 = list$2$1;\nlist$2$1.default = list$2$1;\nlet Container$3$1 = container$1;\nlet list$1$1 = list_1$1;\nlet Rule$3$1 = class Rule extends Container$3$1 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"rule\";\n    if (!this.nodes) this.nodes = [];\n  }\n  get selectors() {\n    return list$1$1.comma(this.selector);\n  }\n  set selectors(values) {\n    let match = this.selector ? this.selector.match(/,\\s*/) : null;\n    let sep2 = match ? match[0] : \",\" + this.raw(\"between\", \"beforeOpen\");\n    this.selector = values.join(sep2);\n  }\n};\nvar rule$1 = Rule$3$1;\nRule$3$1.default = Rule$3$1;\nContainer$3$1.registerRule(Rule$3$1);\nlet Declaration$2$1 = declaration$1;\nlet tokenizer2$1 = tokenize$1;\nlet Comment$2$1 = comment$1;\nlet AtRule$2$1 = atRule$1;\nlet Root$4$1 = root$1;\nlet Rule$2$1 = rule$1;\nconst SAFE_COMMENT_NEIGHBOR$1 = {\n  empty: true,\n  space: true\n};\nfunction findLastWithPosition$1(tokens) {\n  for (let i2 = tokens.length - 1; i2 >= 0; i2--) {\n    let token = tokens[i2];\n    let pos = token[3] || token[2];\n    if (pos) return pos;\n  }\n}\nlet Parser$1$1 = class Parser {\n  constructor(input2) {\n    this.input = input2;\n    this.root = new Root$4$1();\n    this.current = this.root;\n    this.spaces = \"\";\n    this.semicolon = false;\n    this.createTokenizer();\n    this.root.source = { input: input2, start: { column: 1, line: 1, offset: 0 } };\n  }\n  atrule(token) {\n    let node2 = new AtRule$2$1();\n    node2.name = token[1].slice(1);\n    if (node2.name === \"\") {\n      this.unnamedAtrule(node2, token);\n    }\n    this.init(node2, token[2]);\n    let type;\n    let prev;\n    let shift;\n    let last = false;\n    let open = false;\n    let params = [];\n    let brackets = [];\n    while (!this.tokenizer.endOfFile()) {\n      token = this.tokenizer.nextToken();\n      type = token[0];\n      if (type === \"(\" || type === \"[\") {\n        brackets.push(type === \"(\" ? \")\" : \"]\");\n      } else if (type === \"{\" && brackets.length > 0) {\n        brackets.push(\"}\");\n      } else if (type === brackets[brackets.length - 1]) {\n        brackets.pop();\n      }\n      if (brackets.length === 0) {\n        if (type === \";\") {\n          node2.source.end = this.getPosition(token[2]);\n          node2.source.end.offset++;\n          this.semicolon = true;\n          break;\n        } else if (type === \"{\") {\n          open = true;\n          break;\n        } else if (type === \"}\") {\n          if (params.length > 0) {\n            shift = params.length - 1;\n            prev = params[shift];\n            while (prev && prev[0] === \"space\") {\n              prev = params[--shift];\n            }\n            if (prev) {\n              node2.source.end = this.getPosition(prev[3] || prev[2]);\n              node2.source.end.offset++;\n            }\n          }\n          this.end(token);\n          break;\n        } else {\n          params.push(token);\n        }\n      } else {\n        params.push(token);\n      }\n      if (this.tokenizer.endOfFile()) {\n        last = true;\n        break;\n      }\n    }\n    node2.raws.between = this.spacesAndCommentsFromEnd(params);\n    if (params.length) {\n      node2.raws.afterName = this.spacesAndCommentsFromStart(params);\n      this.raw(node2, \"params\", params);\n      if (last) {\n        token = params[params.length - 1];\n        node2.source.end = this.getPosition(token[3] || token[2]);\n        node2.source.end.offset++;\n        this.spaces = node2.raws.between;\n        node2.raws.between = \"\";\n      }\n    } else {\n      node2.raws.afterName = \"\";\n      node2.params = \"\";\n    }\n    if (open) {\n      node2.nodes = [];\n      this.current = node2;\n    }\n  }\n  checkMissedSemicolon(tokens) {\n    let colon = this.colon(tokens);\n    if (colon === false) return;\n    let founded = 0;\n    let token;\n    for (let j = colon - 1; j >= 0; j--) {\n      token = tokens[j];\n      if (token[0] !== \"space\") {\n        founded += 1;\n        if (founded === 2) break;\n      }\n    }\n    throw this.input.error(\n      \"Missed semicolon\",\n      token[0] === \"word\" ? token[3] + 1 : token[2]\n    );\n  }\n  colon(tokens) {\n    let brackets = 0;\n    let token, type, prev;\n    for (let [i2, element] of tokens.entries()) {\n      token = element;\n      type = token[0];\n      if (type === \"(\") {\n        brackets += 1;\n      }\n      if (type === \")\") {\n        brackets -= 1;\n      }\n      if (brackets === 0 && type === \":\") {\n        if (!prev) {\n          this.doubleColon(token);\n        } else if (prev[0] === \"word\" && prev[1] === \"progid\") {\n          continue;\n        } else {\n          return i2;\n        }\n      }\n      prev = token;\n    }\n    return false;\n  }\n  comment(token) {\n    let node2 = new Comment$2$1();\n    this.init(node2, token[2]);\n    node2.source.end = this.getPosition(token[3] || token[2]);\n    node2.source.end.offset++;\n    let text = token[1].slice(2, -2);\n    if (/^\\s*$/.test(text)) {\n      node2.text = \"\";\n      node2.raws.left = text;\n      node2.raws.right = \"\";\n    } else {\n      let match = text.match(/^(\\s*)([^]*\\S)(\\s*)$/);\n      node2.text = match[2];\n      node2.raws.left = match[1];\n      node2.raws.right = match[3];\n    }\n  }\n  createTokenizer() {\n    this.tokenizer = tokenizer2$1(this.input);\n  }\n  decl(tokens, customProperty) {\n    let node2 = new Declaration$2$1();\n    this.init(node2, tokens[0][2]);\n    let last = tokens[tokens.length - 1];\n    if (last[0] === \";\") {\n      this.semicolon = true;\n      tokens.pop();\n    }\n    node2.source.end = this.getPosition(\n      last[3] || last[2] || findLastWithPosition$1(tokens)\n    );\n    node2.source.end.offset++;\n    while (tokens[0][0] !== \"word\") {\n      if (tokens.length === 1) this.unknownWord(tokens);\n      node2.raws.before += tokens.shift()[1];\n    }\n    node2.source.start = this.getPosition(tokens[0][2]);\n    node2.prop = \"\";\n    while (tokens.length) {\n      let type = tokens[0][0];\n      if (type === \":\" || type === \"space\" || type === \"comment\") {\n        break;\n      }\n      node2.prop += tokens.shift()[1];\n    }\n    node2.raws.between = \"\";\n    let token;\n    while (tokens.length) {\n      token = tokens.shift();\n      if (token[0] === \":\") {\n        node2.raws.between += token[1];\n        break;\n      } else {\n        if (token[0] === \"word\" && /\\w/.test(token[1])) {\n          this.unknownWord([token]);\n        }\n        node2.raws.between += token[1];\n      }\n    }\n    if (node2.prop[0] === \"_\" || node2.prop[0] === \"*\") {\n      node2.raws.before += node2.prop[0];\n      node2.prop = node2.prop.slice(1);\n    }\n    let firstSpaces = [];\n    let next;\n    while (tokens.length) {\n      next = tokens[0][0];\n      if (next !== \"space\" && next !== \"comment\") break;\n      firstSpaces.push(tokens.shift());\n    }\n    this.precheckMissedSemicolon(tokens);\n    for (let i2 = tokens.length - 1; i2 >= 0; i2--) {\n      token = tokens[i2];\n      if (token[1].toLowerCase() === \"!important\") {\n        node2.important = true;\n        let string = this.stringFrom(tokens, i2);\n        string = this.spacesFromEnd(tokens) + string;\n        if (string !== \" !important\") node2.raws.important = string;\n        break;\n      } else if (token[1].toLowerCase() === \"important\") {\n        let cache = tokens.slice(0);\n        let str = \"\";\n        for (let j = i2; j > 0; j--) {\n          let type = cache[j][0];\n          if (str.trim().indexOf(\"!\") === 0 && type !== \"space\") {\n            break;\n          }\n          str = cache.pop()[1] + str;\n        }\n        if (str.trim().indexOf(\"!\") === 0) {\n          node2.important = true;\n          node2.raws.important = str;\n          tokens = cache;\n        }\n      }\n      if (token[0] !== \"space\" && token[0] !== \"comment\") {\n        break;\n      }\n    }\n    let hasWord = tokens.some((i2) => i2[0] !== \"space\" && i2[0] !== \"comment\");\n    if (hasWord) {\n      node2.raws.between += firstSpaces.map((i2) => i2[1]).join(\"\");\n      firstSpaces = [];\n    }\n    this.raw(node2, \"value\", firstSpaces.concat(tokens), customProperty);\n    if (node2.value.includes(\":\") && !customProperty) {\n      this.checkMissedSemicolon(tokens);\n    }\n  }\n  doubleColon(token) {\n    throw this.input.error(\n      \"Double colon\",\n      { offset: token[2] },\n      { offset: token[2] + token[1].length }\n    );\n  }\n  emptyRule(token) {\n    let node2 = new Rule$2$1();\n    this.init(node2, token[2]);\n    node2.selector = \"\";\n    node2.raws.between = \"\";\n    this.current = node2;\n  }\n  end(token) {\n    if (this.current.nodes && this.current.nodes.length) {\n      this.current.raws.semicolon = this.semicolon;\n    }\n    this.semicolon = false;\n    this.current.raws.after = (this.current.raws.after || \"\") + this.spaces;\n    this.spaces = \"\";\n    if (this.current.parent) {\n      this.current.source.end = this.getPosition(token[2]);\n      this.current.source.end.offset++;\n      this.current = this.current.parent;\n    } else {\n      this.unexpectedClose(token);\n    }\n  }\n  endFile() {\n    if (this.current.parent) this.unclosedBlock();\n    if (this.current.nodes && this.current.nodes.length) {\n      this.current.raws.semicolon = this.semicolon;\n    }\n    this.current.raws.after = (this.current.raws.after || \"\") + this.spaces;\n    this.root.source.end = this.getPosition(this.tokenizer.position());\n  }\n  freeSemicolon(token) {\n    this.spaces += token[1];\n    if (this.current.nodes) {\n      let prev = this.current.nodes[this.current.nodes.length - 1];\n      if (prev && prev.type === \"rule\" && !prev.raws.ownSemicolon) {\n        prev.raws.ownSemicolon = this.spaces;\n        this.spaces = \"\";\n      }\n    }\n  }\n  // Helpers\n  getPosition(offset) {\n    let pos = this.input.fromOffset(offset);\n    return {\n      column: pos.col,\n      line: pos.line,\n      offset\n    };\n  }\n  init(node2, offset) {\n    this.current.push(node2);\n    node2.source = {\n      input: this.input,\n      start: this.getPosition(offset)\n    };\n    node2.raws.before = this.spaces;\n    this.spaces = \"\";\n    if (node2.type !== \"comment\") this.semicolon = false;\n  }\n  other(start) {\n    let end = false;\n    let type = null;\n    let colon = false;\n    let bracket = null;\n    let brackets = [];\n    let customProperty = start[1].startsWith(\"--\");\n    let tokens = [];\n    let token = start;\n    while (token) {\n      type = token[0];\n      tokens.push(token);\n      if (type === \"(\" || type === \"[\") {\n        if (!bracket) bracket = token;\n        brackets.push(type === \"(\" ? \")\" : \"]\");\n      } else if (customProperty && colon && type === \"{\") {\n        if (!bracket) bracket = token;\n        brackets.push(\"}\");\n      } else if (brackets.length === 0) {\n        if (type === \";\") {\n          if (colon) {\n            this.decl(tokens, customProperty);\n            return;\n          } else {\n            break;\n          }\n        } else if (type === \"{\") {\n          this.rule(tokens);\n          return;\n        } else if (type === \"}\") {\n          this.tokenizer.back(tokens.pop());\n          end = true;\n          break;\n        } else if (type === \":\") {\n          colon = true;\n        }\n      } else if (type === brackets[brackets.length - 1]) {\n        brackets.pop();\n        if (brackets.length === 0) bracket = null;\n      }\n      token = this.tokenizer.nextToken();\n    }\n    if (this.tokenizer.endOfFile()) end = true;\n    if (brackets.length > 0) this.unclosedBracket(bracket);\n    if (end && colon) {\n      if (!customProperty) {\n        while (tokens.length) {\n          token = tokens[tokens.length - 1][0];\n          if (token !== \"space\" && token !== \"comment\") break;\n          this.tokenizer.back(tokens.pop());\n        }\n      }\n      this.decl(tokens, customProperty);\n    } else {\n      this.unknownWord(tokens);\n    }\n  }\n  parse() {\n    let token;\n    while (!this.tokenizer.endOfFile()) {\n      token = this.tokenizer.nextToken();\n      switch (token[0]) {\n        case \"space\":\n          this.spaces += token[1];\n          break;\n        case \";\":\n          this.freeSemicolon(token);\n          break;\n        case \"}\":\n          this.end(token);\n          break;\n        case \"comment\":\n          this.comment(token);\n          break;\n        case \"at-word\":\n          this.atrule(token);\n          break;\n        case \"{\":\n          this.emptyRule(token);\n          break;\n        default:\n          this.other(token);\n          break;\n      }\n    }\n    this.endFile();\n  }\n  precheckMissedSemicolon() {\n  }\n  raw(node2, prop, tokens, customProperty) {\n    let token, type;\n    let length = tokens.length;\n    let value = \"\";\n    let clean = true;\n    let next, prev;\n    for (let i2 = 0; i2 < length; i2 += 1) {\n      token = tokens[i2];\n      type = token[0];\n      if (type === \"space\" && i2 === length - 1 && !customProperty) {\n        clean = false;\n      } else if (type === \"comment\") {\n        prev = tokens[i2 - 1] ? tokens[i2 - 1][0] : \"empty\";\n        next = tokens[i2 + 1] ? tokens[i2 + 1][0] : \"empty\";\n        if (!SAFE_COMMENT_NEIGHBOR$1[prev] && !SAFE_COMMENT_NEIGHBOR$1[next]) {\n          if (value.slice(-1) === \",\") {\n            clean = false;\n          } else {\n            value += token[1];\n          }\n        } else {\n          clean = false;\n        }\n      } else {\n        value += token[1];\n      }\n    }\n    if (!clean) {\n      let raw = tokens.reduce((all, i2) => all + i2[1], \"\");\n      node2.raws[prop] = { raw, value };\n    }\n    node2[prop] = value;\n  }\n  rule(tokens) {\n    tokens.pop();\n    let node2 = new Rule$2$1();\n    this.init(node2, tokens[0][2]);\n    node2.raws.between = this.spacesAndCommentsFromEnd(tokens);\n    this.raw(node2, \"selector\", tokens);\n    this.current = node2;\n  }\n  spacesAndCommentsFromEnd(tokens) {\n    let lastTokenType;\n    let spaces = \"\";\n    while (tokens.length) {\n      lastTokenType = tokens[tokens.length - 1][0];\n      if (lastTokenType !== \"space\" && lastTokenType !== \"comment\") break;\n      spaces = tokens.pop()[1] + spaces;\n    }\n    return spaces;\n  }\n  // Errors\n  spacesAndCommentsFromStart(tokens) {\n    let next;\n    let spaces = \"\";\n    while (tokens.length) {\n      next = tokens[0][0];\n      if (next !== \"space\" && next !== \"comment\") break;\n      spaces += tokens.shift()[1];\n    }\n    return spaces;\n  }\n  spacesFromEnd(tokens) {\n    let lastTokenType;\n    let spaces = \"\";\n    while (tokens.length) {\n      lastTokenType = tokens[tokens.length - 1][0];\n      if (lastTokenType !== \"space\") break;\n      spaces = tokens.pop()[1] + spaces;\n    }\n    return spaces;\n  }\n  stringFrom(tokens, from) {\n    let result2 = \"\";\n    for (let i2 = from; i2 < tokens.length; i2++) {\n      result2 += tokens[i2][1];\n    }\n    tokens.splice(from, tokens.length - from);\n    return result2;\n  }\n  unclosedBlock() {\n    let pos = this.current.source.start;\n    throw this.input.error(\"Unclosed block\", pos.line, pos.column);\n  }\n  unclosedBracket(bracket) {\n    throw this.input.error(\n      \"Unclosed bracket\",\n      { offset: bracket[2] },\n      { offset: bracket[2] + 1 }\n    );\n  }\n  unexpectedClose(token) {\n    throw this.input.error(\n      \"Unexpected }\",\n      { offset: token[2] },\n      { offset: token[2] + 1 }\n    );\n  }\n  unknownWord(tokens) {\n    throw this.input.error(\n      \"Unknown word\",\n      { offset: tokens[0][2] },\n      { offset: tokens[0][2] + tokens[0][1].length }\n    );\n  }\n  unnamedAtrule(node2, token) {\n    throw this.input.error(\n      \"At-rule without name\",\n      { offset: token[2] },\n      { offset: token[2] + token[1].length }\n    );\n  }\n};\nvar parser$1 = Parser$1$1;\nlet Container$2$1 = container$1;\nlet Parser2$1 = parser$1;\nlet Input$2$1 = input$1;\nfunction parse$3$1(css, opts) {\n  let input2 = new Input$2$1(css, opts);\n  let parser2 = new Parser2$1(input2);\n  try {\n    parser2.parse();\n  } catch (e2) {\n    if (process.env.NODE_ENV !== \"production\") {\n      if (e2.name === \"CssSyntaxError\" && opts && opts.from) {\n        if (/\\.scss$/i.test(opts.from)) {\n          e2.message += \"\\nYou tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser\";\n        } else if (/\\.sass/i.test(opts.from)) {\n          e2.message += \"\\nYou tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser\";\n        } else if (/\\.less$/i.test(opts.from)) {\n          e2.message += \"\\nYou tried to parse Less with the standard CSS parser; try again with the postcss-less parser\";\n        }\n      }\n    }\n    throw e2;\n  }\n  return parser2.root;\n}\nvar parse_1$1 = parse$3$1;\nparse$3$1.default = parse$3$1;\nContainer$2$1.registerParse(parse$3$1);\nlet { isClean: isClean$3, my: my$3 } = symbols$1;\nlet MapGenerator$1$1 = mapGenerator$1;\nlet stringify$2$1 = stringify_1$1;\nlet Container$1$1 = container$1;\nlet Document$2$1 = document$1$1;\nlet warnOnce$1$1 = warnOnce$2$1;\nlet Result$2$1 = result$1;\nlet parse$2$1 = parse_1$1;\nlet Root$3$1 = root$1;\nconst TYPE_TO_CLASS_NAME$1 = {\n  atrule: \"AtRule\",\n  comment: \"Comment\",\n  decl: \"Declaration\",\n  document: \"Document\",\n  root: \"Root\",\n  rule: \"Rule\"\n};\nconst PLUGIN_PROPS$1 = {\n  AtRule: true,\n  AtRuleExit: true,\n  Comment: true,\n  CommentExit: true,\n  Declaration: true,\n  DeclarationExit: true,\n  Document: true,\n  DocumentExit: true,\n  Once: true,\n  OnceExit: true,\n  postcssPlugin: true,\n  prepare: true,\n  Root: true,\n  RootExit: true,\n  Rule: true,\n  RuleExit: true\n};\nconst NOT_VISITORS$1 = {\n  Once: true,\n  postcssPlugin: true,\n  prepare: true\n};\nconst CHILDREN$1 = 0;\nfunction isPromise$1(obj) {\n  return typeof obj === \"object\" && typeof obj.then === \"function\";\n}\nfunction getEvents$1(node2) {\n  let key = false;\n  let type = TYPE_TO_CLASS_NAME$1[node2.type];\n  if (node2.type === \"decl\") {\n    key = node2.prop.toLowerCase();\n  } else if (node2.type === \"atrule\") {\n    key = node2.name.toLowerCase();\n  }\n  if (key && node2.append) {\n    return [\n      type,\n      type + \"-\" + key,\n      CHILDREN$1,\n      type + \"Exit\",\n      type + \"Exit-\" + key\n    ];\n  } else if (key) {\n    return [type, type + \"-\" + key, type + \"Exit\", type + \"Exit-\" + key];\n  } else if (node2.append) {\n    return [type, CHILDREN$1, type + \"Exit\"];\n  } else {\n    return [type, type + \"Exit\"];\n  }\n}\nfunction toStack$1(node2) {\n  let events;\n  if (node2.type === \"document\") {\n    events = [\"Document\", CHILDREN$1, \"DocumentExit\"];\n  } else if (node2.type === \"root\") {\n    events = [\"Root\", CHILDREN$1, \"RootExit\"];\n  } else {\n    events = getEvents$1(node2);\n  }\n  return {\n    eventIndex: 0,\n    events,\n    iterator: 0,\n    node: node2,\n    visitorIndex: 0,\n    visitors: []\n  };\n}\nfunction cleanMarks$1(node2) {\n  node2[isClean$3] = false;\n  if (node2.nodes) node2.nodes.forEach((i2) => cleanMarks$1(i2));\n  return node2;\n}\nlet postcss$2$1 = {};\nlet LazyResult$2$1 = class LazyResult {\n  constructor(processor2, css, opts) {\n    this.stringified = false;\n    this.processed = false;\n    let root2;\n    if (typeof css === \"object\" && css !== null && (css.type === \"root\" || css.type === \"document\")) {\n      root2 = cleanMarks$1(css);\n    } else if (css instanceof LazyResult || css instanceof Result$2$1) {\n      root2 = cleanMarks$1(css.root);\n      if (css.map) {\n        if (typeof opts.map === \"undefined\") opts.map = {};\n        if (!opts.map.inline) opts.map.inline = false;\n        opts.map.prev = css.map;\n      }\n    } else {\n      let parser2 = parse$2$1;\n      if (opts.syntax) parser2 = opts.syntax.parse;\n      if (opts.parser) parser2 = opts.parser;\n      if (parser2.parse) parser2 = parser2.parse;\n      try {\n        root2 = parser2(css, opts);\n      } catch (error) {\n        this.processed = true;\n        this.error = error;\n      }\n      if (root2 && !root2[my$3]) {\n        Container$1$1.rebuild(root2);\n      }\n    }\n    this.result = new Result$2$1(processor2, root2, opts);\n    this.helpers = { ...postcss$2$1, postcss: postcss$2$1, result: this.result };\n    this.plugins = this.processor.plugins.map((plugin22) => {\n      if (typeof plugin22 === \"object\" && plugin22.prepare) {\n        return { ...plugin22, ...plugin22.prepare(this.result) };\n      } else {\n        return plugin22;\n      }\n    });\n  }\n  async() {\n    if (this.error) return Promise.reject(this.error);\n    if (this.processed) return Promise.resolve(this.result);\n    if (!this.processing) {\n      this.processing = this.runAsync();\n    }\n    return this.processing;\n  }\n  catch(onRejected) {\n    return this.async().catch(onRejected);\n  }\n  finally(onFinally) {\n    return this.async().then(onFinally, onFinally);\n  }\n  getAsyncError() {\n    throw new Error(\"Use process(css).then(cb) to work with async plugins\");\n  }\n  handleError(error, node2) {\n    let plugin22 = this.result.lastPlugin;\n    try {\n      if (node2) node2.addToError(error);\n      this.error = error;\n      if (error.name === \"CssSyntaxError\" && !error.plugin) {\n        error.plugin = plugin22.postcssPlugin;\n        error.setMessage();\n      } else if (plugin22.postcssVersion) {\n        if (process.env.NODE_ENV !== \"production\") {\n          let pluginName = plugin22.postcssPlugin;\n          let pluginVer = plugin22.postcssVersion;\n          let runtimeVer = this.result.processor.version;\n          let a2 = pluginVer.split(\".\");\n          let b = runtimeVer.split(\".\");\n          if (a2[0] !== b[0] || parseInt(a2[1]) > parseInt(b[1])) {\n            console.error(\n              \"Unknown error from PostCSS plugin. Your current PostCSS version is \" + runtimeVer + \", but \" + pluginName + \" uses \" + pluginVer + \". Perhaps this is the source of the error below.\"\n            );\n          }\n        }\n      }\n    } catch (err) {\n      if (console && console.error) console.error(err);\n    }\n    return error;\n  }\n  prepareVisitors() {\n    this.listeners = {};\n    let add = (plugin22, type, cb) => {\n      if (!this.listeners[type]) this.listeners[type] = [];\n      this.listeners[type].push([plugin22, cb]);\n    };\n    for (let plugin22 of this.plugins) {\n      if (typeof plugin22 === \"object\") {\n        for (let event in plugin22) {\n          if (!PLUGIN_PROPS$1[event] && /^[A-Z]/.test(event)) {\n            throw new Error(\n              `Unknown event ${event} in ${plugin22.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`\n            );\n          }\n          if (!NOT_VISITORS$1[event]) {\n            if (typeof plugin22[event] === \"object\") {\n              for (let filter in plugin22[event]) {\n                if (filter === \"*\") {\n                  add(plugin22, event, plugin22[event][filter]);\n                } else {\n                  add(\n                    plugin22,\n                    event + \"-\" + filter.toLowerCase(),\n                    plugin22[event][filter]\n                  );\n                }\n              }\n            } else if (typeof plugin22[event] === \"function\") {\n              add(plugin22, event, plugin22[event]);\n            }\n          }\n        }\n      }\n    }\n    this.hasListener = Object.keys(this.listeners).length > 0;\n  }\n  async runAsync() {\n    this.plugin = 0;\n    for (let i2 = 0; i2 < this.plugins.length; i2++) {\n      let plugin22 = this.plugins[i2];\n      let promise = this.runOnRoot(plugin22);\n      if (isPromise$1(promise)) {\n        try {\n          await promise;\n        } catch (error) {\n          throw this.handleError(error);\n        }\n      }\n    }\n    this.prepareVisitors();\n    if (this.hasListener) {\n      let root2 = this.result.root;\n      while (!root2[isClean$3]) {\n        root2[isClean$3] = true;\n        let stack = [toStack$1(root2)];\n        while (stack.length > 0) {\n          let promise = this.visitTick(stack);\n          if (isPromise$1(promise)) {\n            try {\n              await promise;\n            } catch (e2) {\n              let node2 = stack[stack.length - 1].node;\n              throw this.handleError(e2, node2);\n            }\n          }\n        }\n      }\n      if (this.listeners.OnceExit) {\n        for (let [plugin22, visitor] of this.listeners.OnceExit) {\n          this.result.lastPlugin = plugin22;\n          try {\n            if (root2.type === \"document\") {\n              let roots = root2.nodes.map(\n                (subRoot) => visitor(subRoot, this.helpers)\n              );\n              await Promise.all(roots);\n            } else {\n              await visitor(root2, this.helpers);\n            }\n          } catch (e2) {\n            throw this.handleError(e2);\n          }\n        }\n      }\n    }\n    this.processed = true;\n    return this.stringify();\n  }\n  runOnRoot(plugin22) {\n    this.result.lastPlugin = plugin22;\n    try {\n      if (typeof plugin22 === \"object\" && plugin22.Once) {\n        if (this.result.root.type === \"document\") {\n          let roots = this.result.root.nodes.map(\n            (root2) => plugin22.Once(root2, this.helpers)\n          );\n          if (isPromise$1(roots[0])) {\n            return Promise.all(roots);\n          }\n          return roots;\n        }\n        return plugin22.Once(this.result.root, this.helpers);\n      } else if (typeof plugin22 === \"function\") {\n        return plugin22(this.result.root, this.result);\n      }\n    } catch (error) {\n      throw this.handleError(error);\n    }\n  }\n  stringify() {\n    if (this.error) throw this.error;\n    if (this.stringified) return this.result;\n    this.stringified = true;\n    this.sync();\n    let opts = this.result.opts;\n    let str = stringify$2$1;\n    if (opts.syntax) str = opts.syntax.stringify;\n    if (opts.stringifier) str = opts.stringifier;\n    if (str.stringify) str = str.stringify;\n    let map = new MapGenerator$1$1(str, this.result.root, this.result.opts);\n    let data = map.generate();\n    this.result.css = data[0];\n    this.result.map = data[1];\n    return this.result;\n  }\n  sync() {\n    if (this.error) throw this.error;\n    if (this.processed) return this.result;\n    this.processed = true;\n    if (this.processing) {\n      throw this.getAsyncError();\n    }\n    for (let plugin22 of this.plugins) {\n      let promise = this.runOnRoot(plugin22);\n      if (isPromise$1(promise)) {\n        throw this.getAsyncError();\n      }\n    }\n    this.prepareVisitors();\n    if (this.hasListener) {\n      let root2 = this.result.root;\n      while (!root2[isClean$3]) {\n        root2[isClean$3] = true;\n        this.walkSync(root2);\n      }\n      if (this.listeners.OnceExit) {\n        if (root2.type === \"document\") {\n          for (let subRoot of root2.nodes) {\n            this.visitSync(this.listeners.OnceExit, subRoot);\n          }\n        } else {\n          this.visitSync(this.listeners.OnceExit, root2);\n        }\n      }\n    }\n    return this.result;\n  }\n  then(onFulfilled, onRejected) {\n    if (process.env.NODE_ENV !== \"production\") {\n      if (!(\"from\" in this.opts)) {\n        warnOnce$1$1(\n          \"Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.\"\n        );\n      }\n    }\n    return this.async().then(onFulfilled, onRejected);\n  }\n  toString() {\n    return this.css;\n  }\n  visitSync(visitors, node2) {\n    for (let [plugin22, visitor] of visitors) {\n      this.result.lastPlugin = plugin22;\n      let promise;\n      try {\n        promise = visitor(node2, this.helpers);\n      } catch (e2) {\n        throw this.handleError(e2, node2.proxyOf);\n      }\n      if (node2.type !== \"root\" && node2.type !== \"document\" && !node2.parent) {\n        return true;\n      }\n      if (isPromise$1(promise)) {\n        throw this.getAsyncError();\n      }\n    }\n  }\n  visitTick(stack) {\n    let visit2 = stack[stack.length - 1];\n    let { node: node2, visitors } = visit2;\n    if (node2.type !== \"root\" && node2.type !== \"document\" && !node2.parent) {\n      stack.pop();\n      return;\n    }\n    if (visitors.length > 0 && visit2.visitorIndex < visitors.length) {\n      let [plugin22, visitor] = visitors[visit2.visitorIndex];\n      visit2.visitorIndex += 1;\n      if (visit2.visitorIndex === visitors.length) {\n        visit2.visitors = [];\n        visit2.visitorIndex = 0;\n      }\n      this.result.lastPlugin = plugin22;\n      try {\n        return visitor(node2.toProxy(), this.helpers);\n      } catch (e2) {\n        throw this.handleError(e2, node2);\n      }\n    }\n    if (visit2.iterator !== 0) {\n      let iterator = visit2.iterator;\n      let child;\n      while (child = node2.nodes[node2.indexes[iterator]]) {\n        node2.indexes[iterator] += 1;\n        if (!child[isClean$3]) {\n          child[isClean$3] = true;\n          stack.push(toStack$1(child));\n          return;\n        }\n      }\n      visit2.iterator = 0;\n      delete node2.indexes[iterator];\n    }\n    let events = visit2.events;\n    while (visit2.eventIndex < events.length) {\n      let event = events[visit2.eventIndex];\n      visit2.eventIndex += 1;\n      if (event === CHILDREN$1) {\n        if (node2.nodes && node2.nodes.length) {\n          node2[isClean$3] = true;\n          visit2.iterator = node2.getIterator();\n        }\n        return;\n      } else if (this.listeners[event]) {\n        visit2.visitors = this.listeners[event];\n        return;\n      }\n    }\n    stack.pop();\n  }\n  walkSync(node2) {\n    node2[isClean$3] = true;\n    let events = getEvents$1(node2);\n    for (let event of events) {\n      if (event === CHILDREN$1) {\n        if (node2.nodes) {\n          node2.each((child) => {\n            if (!child[isClean$3]) this.walkSync(child);\n          });\n        }\n      } else {\n        let visitors = this.listeners[event];\n        if (visitors) {\n          if (this.visitSync(visitors, node2.toProxy())) return;\n        }\n      }\n    }\n  }\n  warnings() {\n    return this.sync().warnings();\n  }\n  get content() {\n    return this.stringify().content;\n  }\n  get css() {\n    return this.stringify().css;\n  }\n  get map() {\n    return this.stringify().map;\n  }\n  get messages() {\n    return this.sync().messages;\n  }\n  get opts() {\n    return this.result.opts;\n  }\n  get processor() {\n    return this.result.processor;\n  }\n  get root() {\n    return this.sync().root;\n  }\n  get [Symbol.toStringTag]() {\n    return \"LazyResult\";\n  }\n};\nLazyResult$2$1.registerPostcss = (dependant) => {\n  postcss$2$1 = dependant;\n};\nvar lazyResult$1 = LazyResult$2$1;\nLazyResult$2$1.default = LazyResult$2$1;\nRoot$3$1.registerLazyResult(LazyResult$2$1);\nDocument$2$1.registerLazyResult(LazyResult$2$1);\nlet MapGenerator2$1 = mapGenerator$1;\nlet stringify$1$1 = stringify_1$1;\nlet warnOnce2$1 = warnOnce$2$1;\nlet parse$1$1 = parse_1$1;\nconst Result$1$1 = result$1;\nlet NoWorkResult$1$1 = class NoWorkResult {\n  constructor(processor2, css, opts) {\n    css = css.toString();\n    this.stringified = false;\n    this._processor = processor2;\n    this._css = css;\n    this._opts = opts;\n    this._map = void 0;\n    let root2;\n    let str = stringify$1$1;\n    this.result = new Result$1$1(this._processor, root2, this._opts);\n    this.result.css = css;\n    let self = this;\n    Object.defineProperty(this.result, \"root\", {\n      get() {\n        return self.root;\n      }\n    });\n    let map = new MapGenerator2$1(str, root2, this._opts, css);\n    if (map.isMap()) {\n      let [generatedCSS, generatedMap] = map.generate();\n      if (generatedCSS) {\n        this.result.css = generatedCSS;\n      }\n      if (generatedMap) {\n        this.result.map = generatedMap;\n      }\n    } else {\n      map.clearAnnotation();\n      this.result.css = map.css;\n    }\n  }\n  async() {\n    if (this.error) return Promise.reject(this.error);\n    return Promise.resolve(this.result);\n  }\n  catch(onRejected) {\n    return this.async().catch(onRejected);\n  }\n  finally(onFinally) {\n    return this.async().then(onFinally, onFinally);\n  }\n  sync() {\n    if (this.error) throw this.error;\n    return this.result;\n  }\n  then(onFulfilled, onRejected) {\n    if (process.env.NODE_ENV !== \"production\") {\n      if (!(\"from\" in this._opts)) {\n        warnOnce2$1(\n          \"Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.\"\n        );\n      }\n    }\n    return this.async().then(onFulfilled, onRejected);\n  }\n  toString() {\n    return this._css;\n  }\n  warnings() {\n    return [];\n  }\n  get content() {\n    return this.result.css;\n  }\n  get css() {\n    return this.result.css;\n  }\n  get map() {\n    return this.result.map;\n  }\n  get messages() {\n    return [];\n  }\n  get opts() {\n    return this.result.opts;\n  }\n  get processor() {\n    return this.result.processor;\n  }\n  get root() {\n    if (this._root) {\n      return this._root;\n    }\n    let root2;\n    let parser2 = parse$1$1;\n    try {\n      root2 = parser2(this._css, this._opts);\n    } catch (error) {\n      this.error = error;\n    }\n    if (this.error) {\n      throw this.error;\n    } else {\n      this._root = root2;\n      return root2;\n    }\n  }\n  get [Symbol.toStringTag]() {\n    return \"NoWorkResult\";\n  }\n};\nvar noWorkResult$1 = NoWorkResult$1$1;\nNoWorkResult$1$1.default = NoWorkResult$1$1;\nlet NoWorkResult2$1 = noWorkResult$1;\nlet LazyResult$1$1 = lazyResult$1;\nlet Document$1$1 = document$1$1;\nlet Root$2$1 = root$1;\nlet Processor$1$1 = class Processor {\n  constructor(plugins = []) {\n    this.version = \"8.4.38\";\n    this.plugins = this.normalize(plugins);\n  }\n  normalize(plugins) {\n    let normalized = [];\n    for (let i2 of plugins) {\n      if (i2.postcss === true) {\n        i2 = i2();\n      } else if (i2.postcss) {\n        i2 = i2.postcss;\n      }\n      if (typeof i2 === \"object\" && Array.isArray(i2.plugins)) {\n        normalized = normalized.concat(i2.plugins);\n      } else if (typeof i2 === \"object\" && i2.postcssPlugin) {\n        normalized.push(i2);\n      } else if (typeof i2 === \"function\") {\n        normalized.push(i2);\n      } else if (typeof i2 === \"object\" && (i2.parse || i2.stringify)) {\n        if (process.env.NODE_ENV !== \"production\") {\n          throw new Error(\n            \"PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.\"\n          );\n        }\n      } else {\n        throw new Error(i2 + \" is not a PostCSS plugin\");\n      }\n    }\n    return normalized;\n  }\n  process(css, opts = {}) {\n    if (!this.plugins.length && !opts.parser && !opts.stringifier && !opts.syntax) {\n      return new NoWorkResult2$1(this, css, opts);\n    } else {\n      return new LazyResult$1$1(this, css, opts);\n    }\n  }\n  use(plugin22) {\n    this.plugins = this.plugins.concat(this.normalize([plugin22]));\n    return this;\n  }\n};\nvar processor$1 = Processor$1$1;\nProcessor$1$1.default = Processor$1$1;\nRoot$2$1.registerProcessor(Processor$1$1);\nDocument$1$1.registerProcessor(Processor$1$1);\nlet Declaration$1$1 = declaration$1;\nlet PreviousMap2$1 = previousMap$1;\nlet Comment$1$1 = comment$1;\nlet AtRule$1$1 = atRule$1;\nlet Input$1$1 = input$1;\nlet Root$1$1 = root$1;\nlet Rule$1$1 = rule$1;\nfunction fromJSON$1$1(json, inputs) {\n  if (Array.isArray(json)) return json.map((n2) => fromJSON$1$1(n2));\n  let { inputs: ownInputs, ...defaults } = json;\n  if (ownInputs) {\n    inputs = [];\n    for (let input2 of ownInputs) {\n      let inputHydrated = { ...input2, __proto__: Input$1$1.prototype };\n      if (inputHydrated.map) {\n        inputHydrated.map = {\n          ...inputHydrated.map,\n          __proto__: PreviousMap2$1.prototype\n        };\n      }\n      inputs.push(inputHydrated);\n    }\n  }\n  if (defaults.nodes) {\n    defaults.nodes = json.nodes.map((n2) => fromJSON$1$1(n2, inputs));\n  }\n  if (defaults.source) {\n    let { inputId, ...source } = defaults.source;\n    defaults.source = source;\n    if (inputId != null) {\n      defaults.source.input = inputs[inputId];\n    }\n  }\n  if (defaults.type === \"root\") {\n    return new Root$1$1(defaults);\n  } else if (defaults.type === \"decl\") {\n    return new Declaration$1$1(defaults);\n  } else if (defaults.type === \"rule\") {\n    return new Rule$1$1(defaults);\n  } else if (defaults.type === \"comment\") {\n    return new Comment$1$1(defaults);\n  } else if (defaults.type === \"atrule\") {\n    return new AtRule$1$1(defaults);\n  } else {\n    throw new Error(\"Unknown node type: \" + json.type);\n  }\n}\nvar fromJSON_1$1 = fromJSON$1$1;\nfromJSON$1$1.default = fromJSON$1$1;\nlet CssSyntaxError2$1 = cssSyntaxError$1;\nlet Declaration2$1 = declaration$1;\nlet LazyResult2$1 = lazyResult$1;\nlet Container2$1 = container$1;\nlet Processor2$1 = processor$1;\nlet stringify$5 = stringify_1$1;\nlet fromJSON$2 = fromJSON_1$1;\nlet Document22 = document$1$1;\nlet Warning2$1 = warning$1;\nlet Comment2$1 = comment$1;\nlet AtRule2$1 = atRule$1;\nlet Result2$1 = result$1;\nlet Input2$1 = input$1;\nlet parse$5 = parse_1$1;\nlet list$3 = list_1$1;\nlet Rule2$1 = rule$1;\nlet Root2$1 = root$1;\nlet Node2$1 = node$1;\nfunction postcss$3(...plugins) {\n  if (plugins.length === 1 && Array.isArray(plugins[0])) {\n    plugins = plugins[0];\n  }\n  return new Processor2$1(plugins);\n}\npostcss$3.plugin = function plugin(name, initializer) {\n  let warningPrinted = false;\n  function creator(...args) {\n    if (console && console.warn && !warningPrinted) {\n      warningPrinted = true;\n      console.warn(\n        name + \": postcss.plugin was deprecated. Migration guide:\\nhttps://evilmartians.com/chronicles/postcss-8-plugin-migration\"\n      );\n      if (process.env.LANG && process.env.LANG.startsWith(\"cn\")) {\n        console.warn(\n          name + \": 里面 postcss.plugin 被弃用. 迁移指南:\\nhttps://www.w3ctech.com/topic/2226\"\n        );\n      }\n    }\n    let transformer = initializer(...args);\n    transformer.postcssPlugin = name;\n    transformer.postcssVersion = new Processor2$1().version;\n    return transformer;\n  }\n  let cache;\n  Object.defineProperty(creator, \"postcss\", {\n    get() {\n      if (!cache) cache = creator();\n      return cache;\n    }\n  });\n  creator.process = function(css, processOpts, pluginOpts) {\n    return postcss$3([creator(pluginOpts)]).process(css, processOpts);\n  };\n  return creator;\n};\npostcss$3.stringify = stringify$5;\npostcss$3.parse = parse$5;\npostcss$3.fromJSON = fromJSON$2;\npostcss$3.list = list$3;\npostcss$3.comment = (defaults) => new Comment2$1(defaults);\npostcss$3.atRule = (defaults) => new AtRule2$1(defaults);\npostcss$3.decl = (defaults) => new Declaration2$1(defaults);\npostcss$3.rule = (defaults) => new Rule2$1(defaults);\npostcss$3.root = (defaults) => new Root2$1(defaults);\npostcss$3.document = (defaults) => new Document22(defaults);\npostcss$3.CssSyntaxError = CssSyntaxError2$1;\npostcss$3.Declaration = Declaration2$1;\npostcss$3.Container = Container2$1;\npostcss$3.Processor = Processor2$1;\npostcss$3.Document = Document22;\npostcss$3.Comment = Comment2$1;\npostcss$3.Warning = Warning2$1;\npostcss$3.AtRule = AtRule2$1;\npostcss$3.Result = Result2$1;\npostcss$3.Input = Input2$1;\npostcss$3.Rule = Rule2$1;\npostcss$3.Root = Root2$1;\npostcss$3.Node = Node2$1;\nLazyResult2$1.registerPostcss(postcss$3);\nvar postcss_1$1 = postcss$3;\npostcss$3.default = postcss$3;\nconst postcss$1$1 = /* @__PURE__ */ getDefaultExportFromCjs$1(postcss_1$1);\npostcss$1$1.stringify;\npostcss$1$1.fromJSON;\npostcss$1$1.plugin;\npostcss$1$1.parse;\npostcss$1$1.list;\npostcss$1$1.document;\npostcss$1$1.comment;\npostcss$1$1.atRule;\npostcss$1$1.rule;\npostcss$1$1.decl;\npostcss$1$1.root;\npostcss$1$1.CssSyntaxError;\npostcss$1$1.Declaration;\npostcss$1$1.Container;\npostcss$1$1.Processor;\npostcss$1$1.Document;\npostcss$1$1.Comment;\npostcss$1$1.Warning;\npostcss$1$1.AtRule;\npostcss$1$1.Result;\npostcss$1$1.Input;\npostcss$1$1.Rule;\npostcss$1$1.Root;\npostcss$1$1.Node;\nvar __defProp2 = Object.defineProperty;\nvar __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __publicField2 = (obj, key, value) => __defNormalProp2(obj, typeof key !== \"symbol\" ? key + \"\" : key, value);\nfunction getDefaultExportFromCjs(x2) {\n  return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, \"default\") ? x2[\"default\"] : x2;\n}\nfunction getAugmentedNamespace(n2) {\n  if (n2.__esModule) return n2;\n  var f2 = n2.default;\n  if (typeof f2 == \"function\") {\n    var a2 = function a22() {\n      if (this instanceof a22) {\n        return Reflect.construct(f2, arguments, this.constructor);\n      }\n      return f2.apply(this, arguments);\n    };\n    a2.prototype = f2.prototype;\n  } else a2 = {};\n  Object.defineProperty(a2, \"__esModule\", { value: true });\n  Object.keys(n2).forEach(function(k) {\n    var d = Object.getOwnPropertyDescriptor(n2, k);\n    Object.defineProperty(a2, k, d.get ? d : {\n      enumerable: true,\n      get: function() {\n        return n2[k];\n      }\n    });\n  });\n  return a2;\n}\nvar picocolors_browser = { exports: {} };\nvar x = String;\nvar create = function() {\n  return { isColorSupported: false, reset: x, bold: x, dim: x, italic: x, underline: x, inverse: x, hidden: x, strikethrough: x, black: x, red: x, green: x, yellow: x, blue: x, magenta: x, cyan: x, white: x, gray: x, bgBlack: x, bgRed: x, bgGreen: x, bgYellow: x, bgBlue: x, bgMagenta: x, bgCyan: x, bgWhite: x };\n};\npicocolors_browser.exports = create();\npicocolors_browser.exports.createColors = create;\nvar picocolors_browserExports = picocolors_browser.exports;\nconst __viteBrowserExternal = {};\nconst __viteBrowserExternal$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({\n  __proto__: null,\n  default: __viteBrowserExternal\n}, Symbol.toStringTag, { value: \"Module\" }));\nconst require$$2 = /* @__PURE__ */ getAugmentedNamespace(__viteBrowserExternal$1);\nlet pico = picocolors_browserExports;\nlet terminalHighlight$1 = require$$2;\nlet CssSyntaxError$3 = class CssSyntaxError2 extends Error {\n  constructor(message, line, column, source, file, plugin22) {\n    super(message);\n    this.name = \"CssSyntaxError\";\n    this.reason = message;\n    if (file) {\n      this.file = file;\n    }\n    if (source) {\n      this.source = source;\n    }\n    if (plugin22) {\n      this.plugin = plugin22;\n    }\n    if (typeof line !== \"undefined\" && typeof column !== \"undefined\") {\n      if (typeof line === \"number\") {\n        this.line = line;\n        this.column = column;\n      } else {\n        this.line = line.line;\n        this.column = line.column;\n        this.endLine = column.line;\n        this.endColumn = column.column;\n      }\n    }\n    this.setMessage();\n    if (Error.captureStackTrace) {\n      Error.captureStackTrace(this, CssSyntaxError2);\n    }\n  }\n  setMessage() {\n    this.message = this.plugin ? this.plugin + \": \" : \"\";\n    this.message += this.file ? this.file : \"<css input>\";\n    if (typeof this.line !== \"undefined\") {\n      this.message += \":\" + this.line + \":\" + this.column;\n    }\n    this.message += \": \" + this.reason;\n  }\n  showSourceCode(color) {\n    if (!this.source) return \"\";\n    let css = this.source;\n    if (color == null) color = pico.isColorSupported;\n    if (terminalHighlight$1) {\n      if (color) css = terminalHighlight$1(css);\n    }\n    let lines = css.split(/\\r?\\n/);\n    let start = Math.max(this.line - 3, 0);\n    let end = Math.min(this.line + 2, lines.length);\n    let maxWidth = String(end).length;\n    let mark, aside;\n    if (color) {\n      let { bold, gray, red } = pico.createColors(true);\n      mark = (text) => bold(red(text));\n      aside = (text) => gray(text);\n    } else {\n      mark = aside = (str) => str;\n    }\n    return lines.slice(start, end).map((line, index2) => {\n      let number = start + 1 + index2;\n      let gutter = \" \" + (\" \" + number).slice(-maxWidth) + \" | \";\n      if (number === this.line) {\n        let spacing = aside(gutter.replace(/\\d/g, \" \")) + line.slice(0, this.column - 1).replace(/[^\\t]/g, \" \");\n        return mark(\">\") + aside(gutter) + line + \"\\n \" + spacing + mark(\"^\");\n      }\n      return \" \" + aside(gutter) + line;\n    }).join(\"\\n\");\n  }\n  toString() {\n    let code = this.showSourceCode();\n    if (code) {\n      code = \"\\n\\n\" + code + \"\\n\";\n    }\n    return this.name + \": \" + this.message + code;\n  }\n};\nvar cssSyntaxError = CssSyntaxError$3;\nCssSyntaxError$3.default = CssSyntaxError$3;\nvar symbols = {};\nsymbols.isClean = Symbol(\"isClean\");\nsymbols.my = Symbol(\"my\");\nconst DEFAULT_RAW = {\n  after: \"\\n\",\n  beforeClose: \"\\n\",\n  beforeComment: \"\\n\",\n  beforeDecl: \"\\n\",\n  beforeOpen: \" \",\n  beforeRule: \"\\n\",\n  colon: \": \",\n  commentLeft: \" \",\n  commentRight: \" \",\n  emptyBody: \"\",\n  indent: \"    \",\n  semicolon: false\n};\nfunction capitalize(str) {\n  return str[0].toUpperCase() + str.slice(1);\n}\nlet Stringifier$2 = class Stringifier2 {\n  constructor(builder) {\n    this.builder = builder;\n  }\n  atrule(node2, semicolon) {\n    let name = \"@\" + node2.name;\n    let params = node2.params ? this.rawValue(node2, \"params\") : \"\";\n    if (typeof node2.raws.afterName !== \"undefined\") {\n      name += node2.raws.afterName;\n    } else if (params) {\n      name += \" \";\n    }\n    if (node2.nodes) {\n      this.block(node2, name + params);\n    } else {\n      let end = (node2.raws.between || \"\") + (semicolon ? \";\" : \"\");\n      this.builder(name + params + end, node2);\n    }\n  }\n  beforeAfter(node2, detect) {\n    let value;\n    if (node2.type === \"decl\") {\n      value = this.raw(node2, null, \"beforeDecl\");\n    } else if (node2.type === \"comment\") {\n      value = this.raw(node2, null, \"beforeComment\");\n    } else if (detect === \"before\") {\n      value = this.raw(node2, null, \"beforeRule\");\n    } else {\n      value = this.raw(node2, null, \"beforeClose\");\n    }\n    let buf = node2.parent;\n    let depth = 0;\n    while (buf && buf.type !== \"root\") {\n      depth += 1;\n      buf = buf.parent;\n    }\n    if (value.includes(\"\\n\")) {\n      let indent = this.raw(node2, null, \"indent\");\n      if (indent.length) {\n        for (let step = 0; step < depth; step++) value += indent;\n      }\n    }\n    return value;\n  }\n  block(node2, start) {\n    let between = this.raw(node2, \"between\", \"beforeOpen\");\n    this.builder(start + between + \"{\", node2, \"start\");\n    let after;\n    if (node2.nodes && node2.nodes.length) {\n      this.body(node2);\n      after = this.raw(node2, \"after\");\n    } else {\n      after = this.raw(node2, \"after\", \"emptyBody\");\n    }\n    if (after) this.builder(after);\n    this.builder(\"}\", node2, \"end\");\n  }\n  body(node2) {\n    let last = node2.nodes.length - 1;\n    while (last > 0) {\n      if (node2.nodes[last].type !== \"comment\") break;\n      last -= 1;\n    }\n    let semicolon = this.raw(node2, \"semicolon\");\n    for (let i2 = 0; i2 < node2.nodes.length; i2++) {\n      let child = node2.nodes[i2];\n      let before = this.raw(child, \"before\");\n      if (before) this.builder(before);\n      this.stringify(child, last !== i2 || semicolon);\n    }\n  }\n  comment(node2) {\n    let left = this.raw(node2, \"left\", \"commentLeft\");\n    let right = this.raw(node2, \"right\", \"commentRight\");\n    this.builder(\"/*\" + left + node2.text + right + \"*/\", node2);\n  }\n  decl(node2, semicolon) {\n    let between = this.raw(node2, \"between\", \"colon\");\n    let string = node2.prop + between + this.rawValue(node2, \"value\");\n    if (node2.important) {\n      string += node2.raws.important || \" !important\";\n    }\n    if (semicolon) string += \";\";\n    this.builder(string, node2);\n  }\n  document(node2) {\n    this.body(node2);\n  }\n  raw(node2, own, detect) {\n    let value;\n    if (!detect) detect = own;\n    if (own) {\n      value = node2.raws[own];\n      if (typeof value !== \"undefined\") return value;\n    }\n    let parent = node2.parent;\n    if (detect === \"before\") {\n      if (!parent || parent.type === \"root\" && parent.first === node2) {\n        return \"\";\n      }\n      if (parent && parent.type === \"document\") {\n        return \"\";\n      }\n    }\n    if (!parent) return DEFAULT_RAW[detect];\n    let root2 = node2.root();\n    if (!root2.rawCache) root2.rawCache = {};\n    if (typeof root2.rawCache[detect] !== \"undefined\") {\n      return root2.rawCache[detect];\n    }\n    if (detect === \"before\" || detect === \"after\") {\n      return this.beforeAfter(node2, detect);\n    } else {\n      let method = \"raw\" + capitalize(detect);\n      if (this[method]) {\n        value = this[method](root2, node2);\n      } else {\n        root2.walk((i2) => {\n          value = i2.raws[own];\n          if (typeof value !== \"undefined\") return false;\n        });\n      }\n    }\n    if (typeof value === \"undefined\") value = DEFAULT_RAW[detect];\n    root2.rawCache[detect] = value;\n    return value;\n  }\n  rawBeforeClose(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && i2.nodes.length > 0) {\n        if (typeof i2.raws.after !== \"undefined\") {\n          value = i2.raws.after;\n          if (value.includes(\"\\n\")) {\n            value = value.replace(/[^\\n]+$/, \"\");\n          }\n          return false;\n        }\n      }\n    });\n    if (value) value = value.replace(/\\S/g, \"\");\n    return value;\n  }\n  rawBeforeComment(root2, node2) {\n    let value;\n    root2.walkComments((i2) => {\n      if (typeof i2.raws.before !== \"undefined\") {\n        value = i2.raws.before;\n        if (value.includes(\"\\n\")) {\n          value = value.replace(/[^\\n]+$/, \"\");\n        }\n        return false;\n      }\n    });\n    if (typeof value === \"undefined\") {\n      value = this.raw(node2, null, \"beforeDecl\");\n    } else if (value) {\n      value = value.replace(/\\S/g, \"\");\n    }\n    return value;\n  }\n  rawBeforeDecl(root2, node2) {\n    let value;\n    root2.walkDecls((i2) => {\n      if (typeof i2.raws.before !== \"undefined\") {\n        value = i2.raws.before;\n        if (value.includes(\"\\n\")) {\n          value = value.replace(/[^\\n]+$/, \"\");\n        }\n        return false;\n      }\n    });\n    if (typeof value === \"undefined\") {\n      value = this.raw(node2, null, \"beforeRule\");\n    } else if (value) {\n      value = value.replace(/\\S/g, \"\");\n    }\n    return value;\n  }\n  rawBeforeOpen(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.type !== \"decl\") {\n        value = i2.raws.between;\n        if (typeof value !== \"undefined\") return false;\n      }\n    });\n    return value;\n  }\n  rawBeforeRule(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && (i2.parent !== root2 || root2.first !== i2)) {\n        if (typeof i2.raws.before !== \"undefined\") {\n          value = i2.raws.before;\n          if (value.includes(\"\\n\")) {\n            value = value.replace(/[^\\n]+$/, \"\");\n          }\n          return false;\n        }\n      }\n    });\n    if (value) value = value.replace(/\\S/g, \"\");\n    return value;\n  }\n  rawColon(root2) {\n    let value;\n    root2.walkDecls((i2) => {\n      if (typeof i2.raws.between !== \"undefined\") {\n        value = i2.raws.between.replace(/[^\\s:]/g, \"\");\n        return false;\n      }\n    });\n    return value;\n  }\n  rawEmptyBody(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && i2.nodes.length === 0) {\n        value = i2.raws.after;\n        if (typeof value !== \"undefined\") return false;\n      }\n    });\n    return value;\n  }\n  rawIndent(root2) {\n    if (root2.raws.indent) return root2.raws.indent;\n    let value;\n    root2.walk((i2) => {\n      let p = i2.parent;\n      if (p && p !== root2 && p.parent && p.parent === root2) {\n        if (typeof i2.raws.before !== \"undefined\") {\n          let parts = i2.raws.before.split(\"\\n\");\n          value = parts[parts.length - 1];\n          value = value.replace(/\\S/g, \"\");\n          return false;\n        }\n      }\n    });\n    return value;\n  }\n  rawSemicolon(root2) {\n    let value;\n    root2.walk((i2) => {\n      if (i2.nodes && i2.nodes.length && i2.last.type === \"decl\") {\n        value = i2.raws.semicolon;\n        if (typeof value !== \"undefined\") return false;\n      }\n    });\n    return value;\n  }\n  rawValue(node2, prop) {\n    let value = node2[prop];\n    let raw = node2.raws[prop];\n    if (raw && raw.value === value) {\n      return raw.raw;\n    }\n    return value;\n  }\n  root(node2) {\n    this.body(node2);\n    if (node2.raws.after) this.builder(node2.raws.after);\n  }\n  rule(node2) {\n    this.block(node2, this.rawValue(node2, \"selector\"));\n    if (node2.raws.ownSemicolon) {\n      this.builder(node2.raws.ownSemicolon, node2, \"end\");\n    }\n  }\n  stringify(node2, semicolon) {\n    if (!this[node2.type]) {\n      throw new Error(\n        \"Unknown AST node type \" + node2.type + \". Maybe you need to change PostCSS stringifier.\"\n      );\n    }\n    this[node2.type](node2, semicolon);\n  }\n};\nvar stringifier = Stringifier$2;\nStringifier$2.default = Stringifier$2;\nlet Stringifier$1 = stringifier;\nfunction stringify$4(node2, builder) {\n  let str = new Stringifier$1(builder);\n  str.stringify(node2);\n}\nvar stringify_1 = stringify$4;\nstringify$4.default = stringify$4;\nlet { isClean: isClean$2, my: my$2 } = symbols;\nlet CssSyntaxError$2 = cssSyntaxError;\nlet Stringifier22 = stringifier;\nlet stringify$3 = stringify_1;\nfunction cloneNode(obj, parent) {\n  let cloned = new obj.constructor();\n  for (let i2 in obj) {\n    if (!Object.prototype.hasOwnProperty.call(obj, i2)) {\n      continue;\n    }\n    if (i2 === \"proxyCache\") continue;\n    let value = obj[i2];\n    let type = typeof value;\n    if (i2 === \"parent\" && type === \"object\") {\n      if (parent) cloned[i2] = parent;\n    } else if (i2 === \"source\") {\n      cloned[i2] = value;\n    } else if (Array.isArray(value)) {\n      cloned[i2] = value.map((j) => cloneNode(j, cloned));\n    } else {\n      if (type === \"object\" && value !== null) value = cloneNode(value);\n      cloned[i2] = value;\n    }\n  }\n  return cloned;\n}\nlet Node$4 = class Node3 {\n  constructor(defaults = {}) {\n    this.raws = {};\n    this[isClean$2] = false;\n    this[my$2] = true;\n    for (let name in defaults) {\n      if (name === \"nodes\") {\n        this.nodes = [];\n        for (let node2 of defaults[name]) {\n          if (typeof node2.clone === \"function\") {\n            this.append(node2.clone());\n          } else {\n            this.append(node2);\n          }\n        }\n      } else {\n        this[name] = defaults[name];\n      }\n    }\n  }\n  addToError(error) {\n    error.postcssNode = this;\n    if (error.stack && this.source && /\\n\\s{4}at /.test(error.stack)) {\n      let s2 = this.source;\n      error.stack = error.stack.replace(\n        /\\n\\s{4}at /,\n        `$&${s2.input.from}:${s2.start.line}:${s2.start.column}$&`\n      );\n    }\n    return error;\n  }\n  after(add) {\n    this.parent.insertAfter(this, add);\n    return this;\n  }\n  assign(overrides = {}) {\n    for (let name in overrides) {\n      this[name] = overrides[name];\n    }\n    return this;\n  }\n  before(add) {\n    this.parent.insertBefore(this, add);\n    return this;\n  }\n  cleanRaws(keepBetween) {\n    delete this.raws.before;\n    delete this.raws.after;\n    if (!keepBetween) delete this.raws.between;\n  }\n  clone(overrides = {}) {\n    let cloned = cloneNode(this);\n    for (let name in overrides) {\n      cloned[name] = overrides[name];\n    }\n    return cloned;\n  }\n  cloneAfter(overrides = {}) {\n    let cloned = this.clone(overrides);\n    this.parent.insertAfter(this, cloned);\n    return cloned;\n  }\n  cloneBefore(overrides = {}) {\n    let cloned = this.clone(overrides);\n    this.parent.insertBefore(this, cloned);\n    return cloned;\n  }\n  error(message, opts = {}) {\n    if (this.source) {\n      let { end, start } = this.rangeBy(opts);\n      return this.source.input.error(\n        message,\n        { column: start.column, line: start.line },\n        { column: end.column, line: end.line },\n        opts\n      );\n    }\n    return new CssSyntaxError$2(message);\n  }\n  getProxyProcessor() {\n    return {\n      get(node2, prop) {\n        if (prop === \"proxyOf\") {\n          return node2;\n        } else if (prop === \"root\") {\n          return () => node2.root().toProxy();\n        } else {\n          return node2[prop];\n        }\n      },\n      set(node2, prop, value) {\n        if (node2[prop] === value) return true;\n        node2[prop] = value;\n        if (prop === \"prop\" || prop === \"value\" || prop === \"name\" || prop === \"params\" || prop === \"important\" || /* c8 ignore next */\n        prop === \"text\") {\n          node2.markDirty();\n        }\n        return true;\n      }\n    };\n  }\n  markDirty() {\n    if (this[isClean$2]) {\n      this[isClean$2] = false;\n      let next = this;\n      while (next = next.parent) {\n        next[isClean$2] = false;\n      }\n    }\n  }\n  next() {\n    if (!this.parent) return void 0;\n    let index2 = this.parent.index(this);\n    return this.parent.nodes[index2 + 1];\n  }\n  positionBy(opts, stringRepresentation) {\n    let pos = this.source.start;\n    if (opts.index) {\n      pos = this.positionInside(opts.index, stringRepresentation);\n    } else if (opts.word) {\n      stringRepresentation = this.toString();\n      let index2 = stringRepresentation.indexOf(opts.word);\n      if (index2 !== -1) pos = this.positionInside(index2, stringRepresentation);\n    }\n    return pos;\n  }\n  positionInside(index2, stringRepresentation) {\n    let string = stringRepresentation || this.toString();\n    let column = this.source.start.column;\n    let line = this.source.start.line;\n    for (let i2 = 0; i2 < index2; i2++) {\n      if (string[i2] === \"\\n\") {\n        column = 1;\n        line += 1;\n      } else {\n        column += 1;\n      }\n    }\n    return { column, line };\n  }\n  prev() {\n    if (!this.parent) return void 0;\n    let index2 = this.parent.index(this);\n    return this.parent.nodes[index2 - 1];\n  }\n  rangeBy(opts) {\n    let start = {\n      column: this.source.start.column,\n      line: this.source.start.line\n    };\n    let end = this.source.end ? {\n      column: this.source.end.column + 1,\n      line: this.source.end.line\n    } : {\n      column: start.column + 1,\n      line: start.line\n    };\n    if (opts.word) {\n      let stringRepresentation = this.toString();\n      let index2 = stringRepresentation.indexOf(opts.word);\n      if (index2 !== -1) {\n        start = this.positionInside(index2, stringRepresentation);\n        end = this.positionInside(index2 + opts.word.length, stringRepresentation);\n      }\n    } else {\n      if (opts.start) {\n        start = {\n          column: opts.start.column,\n          line: opts.start.line\n        };\n      } else if (opts.index) {\n        start = this.positionInside(opts.index);\n      }\n      if (opts.end) {\n        end = {\n          column: opts.end.column,\n          line: opts.end.line\n        };\n      } else if (typeof opts.endIndex === \"number\") {\n        end = this.positionInside(opts.endIndex);\n      } else if (opts.index) {\n        end = this.positionInside(opts.index + 1);\n      }\n    }\n    if (end.line < start.line || end.line === start.line && end.column <= start.column) {\n      end = { column: start.column + 1, line: start.line };\n    }\n    return { end, start };\n  }\n  raw(prop, defaultType) {\n    let str = new Stringifier22();\n    return str.raw(this, prop, defaultType);\n  }\n  remove() {\n    if (this.parent) {\n      this.parent.removeChild(this);\n    }\n    this.parent = void 0;\n    return this;\n  }\n  replaceWith(...nodes) {\n    if (this.parent) {\n      let bookmark = this;\n      let foundSelf = false;\n      for (let node2 of nodes) {\n        if (node2 === this) {\n          foundSelf = true;\n        } else if (foundSelf) {\n          this.parent.insertAfter(bookmark, node2);\n          bookmark = node2;\n        } else {\n          this.parent.insertBefore(bookmark, node2);\n        }\n      }\n      if (!foundSelf) {\n        this.remove();\n      }\n    }\n    return this;\n  }\n  root() {\n    let result2 = this;\n    while (result2.parent && result2.parent.type !== \"document\") {\n      result2 = result2.parent;\n    }\n    return result2;\n  }\n  toJSON(_, inputs) {\n    let fixed = {};\n    let emitInputs = inputs == null;\n    inputs = inputs || /* @__PURE__ */ new Map();\n    let inputsNextIndex = 0;\n    for (let name in this) {\n      if (!Object.prototype.hasOwnProperty.call(this, name)) {\n        continue;\n      }\n      if (name === \"parent\" || name === \"proxyCache\") continue;\n      let value = this[name];\n      if (Array.isArray(value)) {\n        fixed[name] = value.map((i2) => {\n          if (typeof i2 === \"object\" && i2.toJSON) {\n            return i2.toJSON(null, inputs);\n          } else {\n            return i2;\n          }\n        });\n      } else if (typeof value === \"object\" && value.toJSON) {\n        fixed[name] = value.toJSON(null, inputs);\n      } else if (name === \"source\") {\n        let inputId = inputs.get(value.input);\n        if (inputId == null) {\n          inputId = inputsNextIndex;\n          inputs.set(value.input, inputsNextIndex);\n          inputsNextIndex++;\n        }\n        fixed[name] = {\n          end: value.end,\n          inputId,\n          start: value.start\n        };\n      } else {\n        fixed[name] = value;\n      }\n    }\n    if (emitInputs) {\n      fixed.inputs = [...inputs.keys()].map((input2) => input2.toJSON());\n    }\n    return fixed;\n  }\n  toProxy() {\n    if (!this.proxyCache) {\n      this.proxyCache = new Proxy(this, this.getProxyProcessor());\n    }\n    return this.proxyCache;\n  }\n  toString(stringifier2 = stringify$3) {\n    if (stringifier2.stringify) stringifier2 = stringifier2.stringify;\n    let result2 = \"\";\n    stringifier2(this, (i2) => {\n      result2 += i2;\n    });\n    return result2;\n  }\n  warn(result2, text, opts) {\n    let data = { node: this };\n    for (let i2 in opts) data[i2] = opts[i2];\n    return result2.warn(text, data);\n  }\n  get proxyOf() {\n    return this;\n  }\n};\nvar node = Node$4;\nNode$4.default = Node$4;\nlet Node$3 = node;\nlet Declaration$4 = class Declaration2 extends Node$3 {\n  constructor(defaults) {\n    if (defaults && typeof defaults.value !== \"undefined\" && typeof defaults.value !== \"string\") {\n      defaults = { ...defaults, value: String(defaults.value) };\n    }\n    super(defaults);\n    this.type = \"decl\";\n  }\n  get variable() {\n    return this.prop.startsWith(\"--\") || this.prop[0] === \"$\";\n  }\n};\nvar declaration = Declaration$4;\nDeclaration$4.default = Declaration$4;\nlet urlAlphabet = \"useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict\";\nlet customAlphabet = (alphabet, defaultSize = 21) => {\n  return (size = defaultSize) => {\n    let id = \"\";\n    let i2 = size;\n    while (i2--) {\n      id += alphabet[Math.random() * alphabet.length | 0];\n    }\n    return id;\n  };\n};\nlet nanoid$1 = (size = 21) => {\n  let id = \"\";\n  let i2 = size;\n  while (i2--) {\n    id += urlAlphabet[Math.random() * 64 | 0];\n  }\n  return id;\n};\nvar nonSecure = { nanoid: nanoid$1, customAlphabet };\nlet { SourceMapConsumer: SourceMapConsumer$2, SourceMapGenerator: SourceMapGenerator$2 } = require$$2;\nlet { existsSync, readFileSync } = require$$2;\nlet { dirname: dirname$1, join } = require$$2;\nfunction fromBase64(str) {\n  if (Buffer) {\n    return Buffer.from(str, \"base64\").toString();\n  } else {\n    return window.atob(str);\n  }\n}\nlet PreviousMap$2 = class PreviousMap2 {\n  constructor(css, opts) {\n    if (opts.map === false) return;\n    this.loadAnnotation(css);\n    this.inline = this.startWith(this.annotation, \"data:\");\n    let prev = opts.map ? opts.map.prev : void 0;\n    let text = this.loadMap(opts.from, prev);\n    if (!this.mapFile && opts.from) {\n      this.mapFile = opts.from;\n    }\n    if (this.mapFile) this.root = dirname$1(this.mapFile);\n    if (text) this.text = text;\n  }\n  consumer() {\n    if (!this.consumerCache) {\n      this.consumerCache = new SourceMapConsumer$2(this.text);\n    }\n    return this.consumerCache;\n  }\n  decodeInline(text) {\n    let baseCharsetUri = /^data:application\\/json;charset=utf-?8;base64,/;\n    let baseUri = /^data:application\\/json;base64,/;\n    let charsetUri = /^data:application\\/json;charset=utf-?8,/;\n    let uri = /^data:application\\/json,/;\n    if (charsetUri.test(text) || uri.test(text)) {\n      return decodeURIComponent(text.substr(RegExp.lastMatch.length));\n    }\n    if (baseCharsetUri.test(text) || baseUri.test(text)) {\n      return fromBase64(text.substr(RegExp.lastMatch.length));\n    }\n    let encoding = text.match(/data:application\\/json;([^,]+),/)[1];\n    throw new Error(\"Unsupported source map encoding \" + encoding);\n  }\n  getAnnotationURL(sourceMapString) {\n    return sourceMapString.replace(/^\\/\\*\\s*# sourceMappingURL=/, \"\").trim();\n  }\n  isMap(map) {\n    if (typeof map !== \"object\") return false;\n    return typeof map.mappings === \"string\" || typeof map._mappings === \"string\" || Array.isArray(map.sections);\n  }\n  loadAnnotation(css) {\n    let comments = css.match(/\\/\\*\\s*# sourceMappingURL=/gm);\n    if (!comments) return;\n    let start = css.lastIndexOf(comments.pop());\n    let end = css.indexOf(\"*/\", start);\n    if (start > -1 && end > -1) {\n      this.annotation = this.getAnnotationURL(css.substring(start, end));\n    }\n  }\n  loadFile(path) {\n    this.root = dirname$1(path);\n    if (existsSync(path)) {\n      this.mapFile = path;\n      return readFileSync(path, \"utf-8\").toString().trim();\n    }\n  }\n  loadMap(file, prev) {\n    if (prev === false) return false;\n    if (prev) {\n      if (typeof prev === \"string\") {\n        return prev;\n      } else if (typeof prev === \"function\") {\n        let prevPath = prev(file);\n        if (prevPath) {\n          let map = this.loadFile(prevPath);\n          if (!map) {\n            throw new Error(\n              \"Unable to load previous source map: \" + prevPath.toString()\n            );\n          }\n          return map;\n        }\n      } else if (prev instanceof SourceMapConsumer$2) {\n        return SourceMapGenerator$2.fromSourceMap(prev).toString();\n      } else if (prev instanceof SourceMapGenerator$2) {\n        return prev.toString();\n      } else if (this.isMap(prev)) {\n        return JSON.stringify(prev);\n      } else {\n        throw new Error(\n          \"Unsupported previous source map format: \" + prev.toString()\n        );\n      }\n    } else if (this.inline) {\n      return this.decodeInline(this.annotation);\n    } else if (this.annotation) {\n      let map = this.annotation;\n      if (file) map = join(dirname$1(file), map);\n      return this.loadFile(map);\n    }\n  }\n  startWith(string, start) {\n    if (!string) return false;\n    return string.substr(0, start.length) === start;\n  }\n  withContent() {\n    return !!(this.consumer().sourcesContent && this.consumer().sourcesContent.length > 0);\n  }\n};\nvar previousMap = PreviousMap$2;\nPreviousMap$2.default = PreviousMap$2;\nlet { SourceMapConsumer: SourceMapConsumer$1, SourceMapGenerator: SourceMapGenerator$1 } = require$$2;\nlet { fileURLToPath, pathToFileURL: pathToFileURL$1 } = require$$2;\nlet { isAbsolute, resolve: resolve$1 } = require$$2;\nlet { nanoid } = nonSecure;\nlet terminalHighlight = require$$2;\nlet CssSyntaxError$1 = cssSyntaxError;\nlet PreviousMap$1 = previousMap;\nlet fromOffsetCache = Symbol(\"fromOffsetCache\");\nlet sourceMapAvailable$1 = Boolean(SourceMapConsumer$1 && SourceMapGenerator$1);\nlet pathAvailable$1 = Boolean(resolve$1 && isAbsolute);\nlet Input$4 = class Input2 {\n  constructor(css, opts = {}) {\n    if (css === null || typeof css === \"undefined\" || typeof css === \"object\" && !css.toString) {\n      throw new Error(`PostCSS received ${css} instead of CSS string`);\n    }\n    this.css = css.toString();\n    if (this.css[0] === \"\\uFEFF\" || this.css[0] === \"￾\") {\n      this.hasBOM = true;\n      this.css = this.css.slice(1);\n    } else {\n      this.hasBOM = false;\n    }\n    if (opts.from) {\n      if (!pathAvailable$1 || /^\\w+:\\/\\//.test(opts.from) || isAbsolute(opts.from)) {\n        this.file = opts.from;\n      } else {\n        this.file = resolve$1(opts.from);\n      }\n    }\n    if (pathAvailable$1 && sourceMapAvailable$1) {\n      let map = new PreviousMap$1(this.css, opts);\n      if (map.text) {\n        this.map = map;\n        let file = map.consumer().file;\n        if (!this.file && file) this.file = this.mapResolve(file);\n      }\n    }\n    if (!this.file) {\n      this.id = \"<input css \" + nanoid(6) + \">\";\n    }\n    if (this.map) this.map.file = this.from;\n  }\n  error(message, line, column, opts = {}) {\n    let result2, endLine, endColumn;\n    if (line && typeof line === \"object\") {\n      let start = line;\n      let end = column;\n      if (typeof start.offset === \"number\") {\n        let pos = this.fromOffset(start.offset);\n        line = pos.line;\n        column = pos.col;\n      } else {\n        line = start.line;\n        column = start.column;\n      }\n      if (typeof end.offset === \"number\") {\n        let pos = this.fromOffset(end.offset);\n        endLine = pos.line;\n        endColumn = pos.col;\n      } else {\n        endLine = end.line;\n        endColumn = end.column;\n      }\n    } else if (!column) {\n      let pos = this.fromOffset(line);\n      line = pos.line;\n      column = pos.col;\n    }\n    let origin = this.origin(line, column, endLine, endColumn);\n    if (origin) {\n      result2 = new CssSyntaxError$1(\n        message,\n        origin.endLine === void 0 ? origin.line : { column: origin.column, line: origin.line },\n        origin.endLine === void 0 ? origin.column : { column: origin.endColumn, line: origin.endLine },\n        origin.source,\n        origin.file,\n        opts.plugin\n      );\n    } else {\n      result2 = new CssSyntaxError$1(\n        message,\n        endLine === void 0 ? line : { column, line },\n        endLine === void 0 ? column : { column: endColumn, line: endLine },\n        this.css,\n        this.file,\n        opts.plugin\n      );\n    }\n    result2.input = { column, endColumn, endLine, line, source: this.css };\n    if (this.file) {\n      if (pathToFileURL$1) {\n        result2.input.url = pathToFileURL$1(this.file).toString();\n      }\n      result2.input.file = this.file;\n    }\n    return result2;\n  }\n  fromOffset(offset) {\n    let lastLine, lineToIndex;\n    if (!this[fromOffsetCache]) {\n      let lines = this.css.split(\"\\n\");\n      lineToIndex = new Array(lines.length);\n      let prevIndex = 0;\n      for (let i2 = 0, l2 = lines.length; i2 < l2; i2++) {\n        lineToIndex[i2] = prevIndex;\n        prevIndex += lines[i2].length + 1;\n      }\n      this[fromOffsetCache] = lineToIndex;\n    } else {\n      lineToIndex = this[fromOffsetCache];\n    }\n    lastLine = lineToIndex[lineToIndex.length - 1];\n    let min = 0;\n    if (offset >= lastLine) {\n      min = lineToIndex.length - 1;\n    } else {\n      let max = lineToIndex.length - 2;\n      let mid;\n      while (min < max) {\n        mid = min + (max - min >> 1);\n        if (offset < lineToIndex[mid]) {\n          max = mid - 1;\n        } else if (offset >= lineToIndex[mid + 1]) {\n          min = mid + 1;\n        } else {\n          min = mid;\n          break;\n        }\n      }\n    }\n    return {\n      col: offset - lineToIndex[min] + 1,\n      line: min + 1\n    };\n  }\n  mapResolve(file) {\n    if (/^\\w+:\\/\\//.test(file)) {\n      return file;\n    }\n    return resolve$1(this.map.consumer().sourceRoot || this.map.root || \".\", file);\n  }\n  origin(line, column, endLine, endColumn) {\n    if (!this.map) return false;\n    let consumer = this.map.consumer();\n    let from = consumer.originalPositionFor({ column, line });\n    if (!from.source) return false;\n    let to;\n    if (typeof endLine === \"number\") {\n      to = consumer.originalPositionFor({ column: endColumn, line: endLine });\n    }\n    let fromUrl;\n    if (isAbsolute(from.source)) {\n      fromUrl = pathToFileURL$1(from.source);\n    } else {\n      fromUrl = new URL(\n        from.source,\n        this.map.consumer().sourceRoot || pathToFileURL$1(this.map.mapFile)\n      );\n    }\n    let result2 = {\n      column: from.column,\n      endColumn: to && to.column,\n      endLine: to && to.line,\n      line: from.line,\n      url: fromUrl.toString()\n    };\n    if (fromUrl.protocol === \"file:\") {\n      if (fileURLToPath) {\n        result2.file = fileURLToPath(fromUrl);\n      } else {\n        throw new Error(`file: protocol is not available in this PostCSS build`);\n      }\n    }\n    let source = consumer.sourceContentFor(from.source);\n    if (source) result2.source = source;\n    return result2;\n  }\n  toJSON() {\n    let json = {};\n    for (let name of [\"hasBOM\", \"css\", \"file\", \"id\"]) {\n      if (this[name] != null) {\n        json[name] = this[name];\n      }\n    }\n    if (this.map) {\n      json.map = { ...this.map };\n      if (json.map.consumerCache) {\n        json.map.consumerCache = void 0;\n      }\n    }\n    return json;\n  }\n  get from() {\n    return this.file || this.id;\n  }\n};\nvar input = Input$4;\nInput$4.default = Input$4;\nif (terminalHighlight && terminalHighlight.registerInput) {\n  terminalHighlight.registerInput(Input$4);\n}\nlet { SourceMapConsumer, SourceMapGenerator } = require$$2;\nlet { dirname, relative, resolve, sep } = require$$2;\nlet { pathToFileURL } = require$$2;\nlet Input$3 = input;\nlet sourceMapAvailable = Boolean(SourceMapConsumer && SourceMapGenerator);\nlet pathAvailable = Boolean(dirname && resolve && relative && sep);\nlet MapGenerator$2 = class MapGenerator2 {\n  constructor(stringify2, root2, opts, cssString) {\n    this.stringify = stringify2;\n    this.mapOpts = opts.map || {};\n    this.root = root2;\n    this.opts = opts;\n    this.css = cssString;\n    this.originalCSS = cssString;\n    this.usesFileUrls = !this.mapOpts.from && this.mapOpts.absolute;\n    this.memoizedFileURLs = /* @__PURE__ */ new Map();\n    this.memoizedPaths = /* @__PURE__ */ new Map();\n    this.memoizedURLs = /* @__PURE__ */ new Map();\n  }\n  addAnnotation() {\n    let content;\n    if (this.isInline()) {\n      content = \"data:application/json;base64,\" + this.toBase64(this.map.toString());\n    } else if (typeof this.mapOpts.annotation === \"string\") {\n      content = this.mapOpts.annotation;\n    } else if (typeof this.mapOpts.annotation === \"function\") {\n      content = this.mapOpts.annotation(this.opts.to, this.root);\n    } else {\n      content = this.outputFile() + \".map\";\n    }\n    let eol = \"\\n\";\n    if (this.css.includes(\"\\r\\n\")) eol = \"\\r\\n\";\n    this.css += eol + \"/*# sourceMappingURL=\" + content + \" */\";\n  }\n  applyPrevMaps() {\n    for (let prev of this.previous()) {\n      let from = this.toUrl(this.path(prev.file));\n      let root2 = prev.root || dirname(prev.file);\n      let map;\n      if (this.mapOpts.sourcesContent === false) {\n        map = new SourceMapConsumer(prev.text);\n        if (map.sourcesContent) {\n          map.sourcesContent = null;\n        }\n      } else {\n        map = prev.consumer();\n      }\n      this.map.applySourceMap(map, from, this.toUrl(this.path(root2)));\n    }\n  }\n  clearAnnotation() {\n    if (this.mapOpts.annotation === false) return;\n    if (this.root) {\n      let node2;\n      for (let i2 = this.root.nodes.length - 1; i2 >= 0; i2--) {\n        node2 = this.root.nodes[i2];\n        if (node2.type !== \"comment\") continue;\n        if (node2.text.indexOf(\"# sourceMappingURL=\") === 0) {\n          this.root.removeChild(i2);\n        }\n      }\n    } else if (this.css) {\n      this.css = this.css.replace(/\\n*?\\/\\*#[\\S\\s]*?\\*\\/$/gm, \"\");\n    }\n  }\n  generate() {\n    this.clearAnnotation();\n    if (pathAvailable && sourceMapAvailable && this.isMap()) {\n      return this.generateMap();\n    } else {\n      let result2 = \"\";\n      this.stringify(this.root, (i2) => {\n        result2 += i2;\n      });\n      return [result2];\n    }\n  }\n  generateMap() {\n    if (this.root) {\n      this.generateString();\n    } else if (this.previous().length === 1) {\n      let prev = this.previous()[0].consumer();\n      prev.file = this.outputFile();\n      this.map = SourceMapGenerator.fromSourceMap(prev, {\n        ignoreInvalidMapping: true\n      });\n    } else {\n      this.map = new SourceMapGenerator({\n        file: this.outputFile(),\n        ignoreInvalidMapping: true\n      });\n      this.map.addMapping({\n        generated: { column: 0, line: 1 },\n        original: { column: 0, line: 1 },\n        source: this.opts.from ? this.toUrl(this.path(this.opts.from)) : \"<no source>\"\n      });\n    }\n    if (this.isSourcesContent()) this.setSourcesContent();\n    if (this.root && this.previous().length > 0) this.applyPrevMaps();\n    if (this.isAnnotation()) this.addAnnotation();\n    if (this.isInline()) {\n      return [this.css];\n    } else {\n      return [this.css, this.map];\n    }\n  }\n  generateString() {\n    this.css = \"\";\n    this.map = new SourceMapGenerator({\n      file: this.outputFile(),\n      ignoreInvalidMapping: true\n    });\n    let line = 1;\n    let column = 1;\n    let noSource = \"<no source>\";\n    let mapping = {\n      generated: { column: 0, line: 0 },\n      original: { column: 0, line: 0 },\n      source: \"\"\n    };\n    let lines, last;\n    this.stringify(this.root, (str, node2, type) => {\n      this.css += str;\n      if (node2 && type !== \"end\") {\n        mapping.generated.line = line;\n        mapping.generated.column = column - 1;\n        if (node2.source && node2.source.start) {\n          mapping.source = this.sourcePath(node2);\n          mapping.original.line = node2.source.start.line;\n          mapping.original.column = node2.source.start.column - 1;\n          this.map.addMapping(mapping);\n        } else {\n          mapping.source = noSource;\n          mapping.original.line = 1;\n          mapping.original.column = 0;\n          this.map.addMapping(mapping);\n        }\n      }\n      lines = str.match(/\\n/g);\n      if (lines) {\n        line += lines.length;\n        last = str.lastIndexOf(\"\\n\");\n        column = str.length - last;\n      } else {\n        column += str.length;\n      }\n      if (node2 && type !== \"start\") {\n        let p = node2.parent || { raws: {} };\n        let childless = node2.type === \"decl\" || node2.type === \"atrule\" && !node2.nodes;\n        if (!childless || node2 !== p.last || p.raws.semicolon) {\n          if (node2.source && node2.source.end) {\n            mapping.source = this.sourcePath(node2);\n            mapping.original.line = node2.source.end.line;\n            mapping.original.column = node2.source.end.column - 1;\n            mapping.generated.line = line;\n            mapping.generated.column = column - 2;\n            this.map.addMapping(mapping);\n          } else {\n            mapping.source = noSource;\n            mapping.original.line = 1;\n            mapping.original.column = 0;\n            mapping.generated.line = line;\n            mapping.generated.column = column - 1;\n            this.map.addMapping(mapping);\n          }\n        }\n      }\n    });\n  }\n  isAnnotation() {\n    if (this.isInline()) {\n      return true;\n    }\n    if (typeof this.mapOpts.annotation !== \"undefined\") {\n      return this.mapOpts.annotation;\n    }\n    if (this.previous().length) {\n      return this.previous().some((i2) => i2.annotation);\n    }\n    return true;\n  }\n  isInline() {\n    if (typeof this.mapOpts.inline !== \"undefined\") {\n      return this.mapOpts.inline;\n    }\n    let annotation = this.mapOpts.annotation;\n    if (typeof annotation !== \"undefined\" && annotation !== true) {\n      return false;\n    }\n    if (this.previous().length) {\n      return this.previous().some((i2) => i2.inline);\n    }\n    return true;\n  }\n  isMap() {\n    if (typeof this.opts.map !== \"undefined\") {\n      return !!this.opts.map;\n    }\n    return this.previous().length > 0;\n  }\n  isSourcesContent() {\n    if (typeof this.mapOpts.sourcesContent !== \"undefined\") {\n      return this.mapOpts.sourcesContent;\n    }\n    if (this.previous().length) {\n      return this.previous().some((i2) => i2.withContent());\n    }\n    return true;\n  }\n  outputFile() {\n    if (this.opts.to) {\n      return this.path(this.opts.to);\n    } else if (this.opts.from) {\n      return this.path(this.opts.from);\n    } else {\n      return \"to.css\";\n    }\n  }\n  path(file) {\n    if (this.mapOpts.absolute) return file;\n    if (file.charCodeAt(0) === 60) return file;\n    if (/^\\w+:\\/\\//.test(file)) return file;\n    let cached = this.memoizedPaths.get(file);\n    if (cached) return cached;\n    let from = this.opts.to ? dirname(this.opts.to) : \".\";\n    if (typeof this.mapOpts.annotation === \"string\") {\n      from = dirname(resolve(from, this.mapOpts.annotation));\n    }\n    let path = relative(from, file);\n    this.memoizedPaths.set(file, path);\n    return path;\n  }\n  previous() {\n    if (!this.previousMaps) {\n      this.previousMaps = [];\n      if (this.root) {\n        this.root.walk((node2) => {\n          if (node2.source && node2.source.input.map) {\n            let map = node2.source.input.map;\n            if (!this.previousMaps.includes(map)) {\n              this.previousMaps.push(map);\n            }\n          }\n        });\n      } else {\n        let input2 = new Input$3(this.originalCSS, this.opts);\n        if (input2.map) this.previousMaps.push(input2.map);\n      }\n    }\n    return this.previousMaps;\n  }\n  setSourcesContent() {\n    let already = {};\n    if (this.root) {\n      this.root.walk((node2) => {\n        if (node2.source) {\n          let from = node2.source.input.from;\n          if (from && !already[from]) {\n            already[from] = true;\n            let fromUrl = this.usesFileUrls ? this.toFileUrl(from) : this.toUrl(this.path(from));\n            this.map.setSourceContent(fromUrl, node2.source.input.css);\n          }\n        }\n      });\n    } else if (this.css) {\n      let from = this.opts.from ? this.toUrl(this.path(this.opts.from)) : \"<no source>\";\n      this.map.setSourceContent(from, this.css);\n    }\n  }\n  sourcePath(node2) {\n    if (this.mapOpts.from) {\n      return this.toUrl(this.mapOpts.from);\n    } else if (this.usesFileUrls) {\n      return this.toFileUrl(node2.source.input.from);\n    } else {\n      return this.toUrl(this.path(node2.source.input.from));\n    }\n  }\n  toBase64(str) {\n    if (Buffer) {\n      return Buffer.from(str).toString(\"base64\");\n    } else {\n      return window.btoa(unescape(encodeURIComponent(str)));\n    }\n  }\n  toFileUrl(path) {\n    let cached = this.memoizedFileURLs.get(path);\n    if (cached) return cached;\n    if (pathToFileURL) {\n      let fileURL = pathToFileURL(path).toString();\n      this.memoizedFileURLs.set(path, fileURL);\n      return fileURL;\n    } else {\n      throw new Error(\n        \"`map.absolute` option is not available in this PostCSS build\"\n      );\n    }\n  }\n  toUrl(path) {\n    let cached = this.memoizedURLs.get(path);\n    if (cached) return cached;\n    if (sep === \"\\\\\") {\n      path = path.replace(/\\\\/g, \"/\");\n    }\n    let url = encodeURI(path).replace(/[#?]/g, encodeURIComponent);\n    this.memoizedURLs.set(path, url);\n    return url;\n  }\n};\nvar mapGenerator = MapGenerator$2;\nlet Node$2 = node;\nlet Comment$4 = class Comment2 extends Node$2 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"comment\";\n  }\n};\nvar comment = Comment$4;\nComment$4.default = Comment$4;\nlet { isClean: isClean$1, my: my$1 } = symbols;\nlet Declaration$3 = declaration;\nlet Comment$3 = comment;\nlet Node$1 = node;\nlet parse$4, Rule$4, AtRule$4, Root$6;\nfunction cleanSource(nodes) {\n  return nodes.map((i2) => {\n    if (i2.nodes) i2.nodes = cleanSource(i2.nodes);\n    delete i2.source;\n    return i2;\n  });\n}\nfunction markDirtyUp(node2) {\n  node2[isClean$1] = false;\n  if (node2.proxyOf.nodes) {\n    for (let i2 of node2.proxyOf.nodes) {\n      markDirtyUp(i2);\n    }\n  }\n}\nlet Container$7 = class Container2 extends Node$1 {\n  append(...children) {\n    for (let child of children) {\n      let nodes = this.normalize(child, this.last);\n      for (let node2 of nodes) this.proxyOf.nodes.push(node2);\n    }\n    this.markDirty();\n    return this;\n  }\n  cleanRaws(keepBetween) {\n    super.cleanRaws(keepBetween);\n    if (this.nodes) {\n      for (let node2 of this.nodes) node2.cleanRaws(keepBetween);\n    }\n  }\n  each(callback) {\n    if (!this.proxyOf.nodes) return void 0;\n    let iterator = this.getIterator();\n    let index2, result2;\n    while (this.indexes[iterator] < this.proxyOf.nodes.length) {\n      index2 = this.indexes[iterator];\n      result2 = callback(this.proxyOf.nodes[index2], index2);\n      if (result2 === false) break;\n      this.indexes[iterator] += 1;\n    }\n    delete this.indexes[iterator];\n    return result2;\n  }\n  every(condition) {\n    return this.nodes.every(condition);\n  }\n  getIterator() {\n    if (!this.lastEach) this.lastEach = 0;\n    if (!this.indexes) this.indexes = {};\n    this.lastEach += 1;\n    let iterator = this.lastEach;\n    this.indexes[iterator] = 0;\n    return iterator;\n  }\n  getProxyProcessor() {\n    return {\n      get(node2, prop) {\n        if (prop === \"proxyOf\") {\n          return node2;\n        } else if (!node2[prop]) {\n          return node2[prop];\n        } else if (prop === \"each\" || typeof prop === \"string\" && prop.startsWith(\"walk\")) {\n          return (...args) => {\n            return node2[prop](\n              ...args.map((i2) => {\n                if (typeof i2 === \"function\") {\n                  return (child, index2) => i2(child.toProxy(), index2);\n                } else {\n                  return i2;\n                }\n              })\n            );\n          };\n        } else if (prop === \"every\" || prop === \"some\") {\n          return (cb) => {\n            return node2[prop](\n              (child, ...other) => cb(child.toProxy(), ...other)\n            );\n          };\n        } else if (prop === \"root\") {\n          return () => node2.root().toProxy();\n        } else if (prop === \"nodes\") {\n          return node2.nodes.map((i2) => i2.toProxy());\n        } else if (prop === \"first\" || prop === \"last\") {\n          return node2[prop].toProxy();\n        } else {\n          return node2[prop];\n        }\n      },\n      set(node2, prop, value) {\n        if (node2[prop] === value) return true;\n        node2[prop] = value;\n        if (prop === \"name\" || prop === \"params\" || prop === \"selector\") {\n          node2.markDirty();\n        }\n        return true;\n      }\n    };\n  }\n  index(child) {\n    if (typeof child === \"number\") return child;\n    if (child.proxyOf) child = child.proxyOf;\n    return this.proxyOf.nodes.indexOf(child);\n  }\n  insertAfter(exist, add) {\n    let existIndex = this.index(exist);\n    let nodes = this.normalize(add, this.proxyOf.nodes[existIndex]).reverse();\n    existIndex = this.index(exist);\n    for (let node2 of nodes) this.proxyOf.nodes.splice(existIndex + 1, 0, node2);\n    let index2;\n    for (let id in this.indexes) {\n      index2 = this.indexes[id];\n      if (existIndex < index2) {\n        this.indexes[id] = index2 + nodes.length;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  insertBefore(exist, add) {\n    let existIndex = this.index(exist);\n    let type = existIndex === 0 ? \"prepend\" : false;\n    let nodes = this.normalize(add, this.proxyOf.nodes[existIndex], type).reverse();\n    existIndex = this.index(exist);\n    for (let node2 of nodes) this.proxyOf.nodes.splice(existIndex, 0, node2);\n    let index2;\n    for (let id in this.indexes) {\n      index2 = this.indexes[id];\n      if (existIndex <= index2) {\n        this.indexes[id] = index2 + nodes.length;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  normalize(nodes, sample) {\n    if (typeof nodes === \"string\") {\n      nodes = cleanSource(parse$4(nodes).nodes);\n    } else if (typeof nodes === \"undefined\") {\n      nodes = [];\n    } else if (Array.isArray(nodes)) {\n      nodes = nodes.slice(0);\n      for (let i2 of nodes) {\n        if (i2.parent) i2.parent.removeChild(i2, \"ignore\");\n      }\n    } else if (nodes.type === \"root\" && this.type !== \"document\") {\n      nodes = nodes.nodes.slice(0);\n      for (let i2 of nodes) {\n        if (i2.parent) i2.parent.removeChild(i2, \"ignore\");\n      }\n    } else if (nodes.type) {\n      nodes = [nodes];\n    } else if (nodes.prop) {\n      if (typeof nodes.value === \"undefined\") {\n        throw new Error(\"Value field is missed in node creation\");\n      } else if (typeof nodes.value !== \"string\") {\n        nodes.value = String(nodes.value);\n      }\n      nodes = [new Declaration$3(nodes)];\n    } else if (nodes.selector) {\n      nodes = [new Rule$4(nodes)];\n    } else if (nodes.name) {\n      nodes = [new AtRule$4(nodes)];\n    } else if (nodes.text) {\n      nodes = [new Comment$3(nodes)];\n    } else {\n      throw new Error(\"Unknown node type in node creation\");\n    }\n    let processed = nodes.map((i2) => {\n      if (!i2[my$1]) Container2.rebuild(i2);\n      i2 = i2.proxyOf;\n      if (i2.parent) i2.parent.removeChild(i2);\n      if (i2[isClean$1]) markDirtyUp(i2);\n      if (typeof i2.raws.before === \"undefined\") {\n        if (sample && typeof sample.raws.before !== \"undefined\") {\n          i2.raws.before = sample.raws.before.replace(/\\S/g, \"\");\n        }\n      }\n      i2.parent = this.proxyOf;\n      return i2;\n    });\n    return processed;\n  }\n  prepend(...children) {\n    children = children.reverse();\n    for (let child of children) {\n      let nodes = this.normalize(child, this.first, \"prepend\").reverse();\n      for (let node2 of nodes) this.proxyOf.nodes.unshift(node2);\n      for (let id in this.indexes) {\n        this.indexes[id] = this.indexes[id] + nodes.length;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  push(child) {\n    child.parent = this;\n    this.proxyOf.nodes.push(child);\n    return this;\n  }\n  removeAll() {\n    for (let node2 of this.proxyOf.nodes) node2.parent = void 0;\n    this.proxyOf.nodes = [];\n    this.markDirty();\n    return this;\n  }\n  removeChild(child) {\n    child = this.index(child);\n    this.proxyOf.nodes[child].parent = void 0;\n    this.proxyOf.nodes.splice(child, 1);\n    let index2;\n    for (let id in this.indexes) {\n      index2 = this.indexes[id];\n      if (index2 >= child) {\n        this.indexes[id] = index2 - 1;\n      }\n    }\n    this.markDirty();\n    return this;\n  }\n  replaceValues(pattern, opts, callback) {\n    if (!callback) {\n      callback = opts;\n      opts = {};\n    }\n    this.walkDecls((decl) => {\n      if (opts.props && !opts.props.includes(decl.prop)) return;\n      if (opts.fast && !decl.value.includes(opts.fast)) return;\n      decl.value = decl.value.replace(pattern, callback);\n    });\n    this.markDirty();\n    return this;\n  }\n  some(condition) {\n    return this.nodes.some(condition);\n  }\n  walk(callback) {\n    return this.each((child, i2) => {\n      let result2;\n      try {\n        result2 = callback(child, i2);\n      } catch (e2) {\n        throw child.addToError(e2);\n      }\n      if (result2 !== false && child.walk) {\n        result2 = child.walk(callback);\n      }\n      return result2;\n    });\n  }\n  walkAtRules(name, callback) {\n    if (!callback) {\n      callback = name;\n      return this.walk((child, i2) => {\n        if (child.type === \"atrule\") {\n          return callback(child, i2);\n        }\n      });\n    }\n    if (name instanceof RegExp) {\n      return this.walk((child, i2) => {\n        if (child.type === \"atrule\" && name.test(child.name)) {\n          return callback(child, i2);\n        }\n      });\n    }\n    return this.walk((child, i2) => {\n      if (child.type === \"atrule\" && child.name === name) {\n        return callback(child, i2);\n      }\n    });\n  }\n  walkComments(callback) {\n    return this.walk((child, i2) => {\n      if (child.type === \"comment\") {\n        return callback(child, i2);\n      }\n    });\n  }\n  walkDecls(prop, callback) {\n    if (!callback) {\n      callback = prop;\n      return this.walk((child, i2) => {\n        if (child.type === \"decl\") {\n          return callback(child, i2);\n        }\n      });\n    }\n    if (prop instanceof RegExp) {\n      return this.walk((child, i2) => {\n        if (child.type === \"decl\" && prop.test(child.prop)) {\n          return callback(child, i2);\n        }\n      });\n    }\n    return this.walk((child, i2) => {\n      if (child.type === \"decl\" && child.prop === prop) {\n        return callback(child, i2);\n      }\n    });\n  }\n  walkRules(selector, callback) {\n    if (!callback) {\n      callback = selector;\n      return this.walk((child, i2) => {\n        if (child.type === \"rule\") {\n          return callback(child, i2);\n        }\n      });\n    }\n    if (selector instanceof RegExp) {\n      return this.walk((child, i2) => {\n        if (child.type === \"rule\" && selector.test(child.selector)) {\n          return callback(child, i2);\n        }\n      });\n    }\n    return this.walk((child, i2) => {\n      if (child.type === \"rule\" && child.selector === selector) {\n        return callback(child, i2);\n      }\n    });\n  }\n  get first() {\n    if (!this.proxyOf.nodes) return void 0;\n    return this.proxyOf.nodes[0];\n  }\n  get last() {\n    if (!this.proxyOf.nodes) return void 0;\n    return this.proxyOf.nodes[this.proxyOf.nodes.length - 1];\n  }\n};\nContainer$7.registerParse = (dependant) => {\n  parse$4 = dependant;\n};\nContainer$7.registerRule = (dependant) => {\n  Rule$4 = dependant;\n};\nContainer$7.registerAtRule = (dependant) => {\n  AtRule$4 = dependant;\n};\nContainer$7.registerRoot = (dependant) => {\n  Root$6 = dependant;\n};\nvar container = Container$7;\nContainer$7.default = Container$7;\nContainer$7.rebuild = (node2) => {\n  if (node2.type === \"atrule\") {\n    Object.setPrototypeOf(node2, AtRule$4.prototype);\n  } else if (node2.type === \"rule\") {\n    Object.setPrototypeOf(node2, Rule$4.prototype);\n  } else if (node2.type === \"decl\") {\n    Object.setPrototypeOf(node2, Declaration$3.prototype);\n  } else if (node2.type === \"comment\") {\n    Object.setPrototypeOf(node2, Comment$3.prototype);\n  } else if (node2.type === \"root\") {\n    Object.setPrototypeOf(node2, Root$6.prototype);\n  }\n  node2[my$1] = true;\n  if (node2.nodes) {\n    node2.nodes.forEach((child) => {\n      Container$7.rebuild(child);\n    });\n  }\n};\nlet Container$6 = container;\nlet LazyResult$4, Processor$3;\nlet Document$3 = class Document23 extends Container$6 {\n  constructor(defaults) {\n    super({ type: \"document\", ...defaults });\n    if (!this.nodes) {\n      this.nodes = [];\n    }\n  }\n  toResult(opts = {}) {\n    let lazy = new LazyResult$4(new Processor$3(), this, opts);\n    return lazy.stringify();\n  }\n};\nDocument$3.registerLazyResult = (dependant) => {\n  LazyResult$4 = dependant;\n};\nDocument$3.registerProcessor = (dependant) => {\n  Processor$3 = dependant;\n};\nvar document$1 = Document$3;\nDocument$3.default = Document$3;\nlet printed = {};\nvar warnOnce$2 = function warnOnce2(message) {\n  if (printed[message]) return;\n  printed[message] = true;\n  if (typeof console !== \"undefined\" && console.warn) {\n    console.warn(message);\n  }\n};\nlet Warning$2 = class Warning2 {\n  constructor(text, opts = {}) {\n    this.type = \"warning\";\n    this.text = text;\n    if (opts.node && opts.node.source) {\n      let range = opts.node.rangeBy(opts);\n      this.line = range.start.line;\n      this.column = range.start.column;\n      this.endLine = range.end.line;\n      this.endColumn = range.end.column;\n    }\n    for (let opt in opts) this[opt] = opts[opt];\n  }\n  toString() {\n    if (this.node) {\n      return this.node.error(this.text, {\n        index: this.index,\n        plugin: this.plugin,\n        word: this.word\n      }).message;\n    }\n    if (this.plugin) {\n      return this.plugin + \": \" + this.text;\n    }\n    return this.text;\n  }\n};\nvar warning = Warning$2;\nWarning$2.default = Warning$2;\nlet Warning$1 = warning;\nlet Result$3 = class Result2 {\n  constructor(processor2, root2, opts) {\n    this.processor = processor2;\n    this.messages = [];\n    this.root = root2;\n    this.opts = opts;\n    this.css = void 0;\n    this.map = void 0;\n  }\n  toString() {\n    return this.css;\n  }\n  warn(text, opts = {}) {\n    if (!opts.plugin) {\n      if (this.lastPlugin && this.lastPlugin.postcssPlugin) {\n        opts.plugin = this.lastPlugin.postcssPlugin;\n      }\n    }\n    let warning2 = new Warning$1(text, opts);\n    this.messages.push(warning2);\n    return warning2;\n  }\n  warnings() {\n    return this.messages.filter((i2) => i2.type === \"warning\");\n  }\n  get content() {\n    return this.css;\n  }\n};\nvar result = Result$3;\nResult$3.default = Result$3;\nconst SINGLE_QUOTE = \"'\".charCodeAt(0);\nconst DOUBLE_QUOTE = '\"'.charCodeAt(0);\nconst BACKSLASH = \"\\\\\".charCodeAt(0);\nconst SLASH = \"/\".charCodeAt(0);\nconst NEWLINE = \"\\n\".charCodeAt(0);\nconst SPACE = \" \".charCodeAt(0);\nconst FEED = \"\\f\".charCodeAt(0);\nconst TAB = \"\t\".charCodeAt(0);\nconst CR = \"\\r\".charCodeAt(0);\nconst OPEN_SQUARE = \"[\".charCodeAt(0);\nconst CLOSE_SQUARE = \"]\".charCodeAt(0);\nconst OPEN_PARENTHESES = \"(\".charCodeAt(0);\nconst CLOSE_PARENTHESES = \")\".charCodeAt(0);\nconst OPEN_CURLY = \"{\".charCodeAt(0);\nconst CLOSE_CURLY = \"}\".charCodeAt(0);\nconst SEMICOLON = \";\".charCodeAt(0);\nconst ASTERISK = \"*\".charCodeAt(0);\nconst COLON = \":\".charCodeAt(0);\nconst AT = \"@\".charCodeAt(0);\nconst RE_AT_END = /[\\t\\n\\f\\r \"#'()/;[\\\\\\]{}]/g;\nconst RE_WORD_END = /[\\t\\n\\f\\r !\"#'():;@[\\\\\\]{}]|\\/(?=\\*)/g;\nconst RE_BAD_BRACKET = /.[\\r\\n\"'(/\\\\]/;\nconst RE_HEX_ESCAPE = /[\\da-f]/i;\nvar tokenize = function tokenizer2(input2, options = {}) {\n  let css = input2.css.valueOf();\n  let ignore = options.ignoreErrors;\n  let code, next, quote, content, escape;\n  let escaped, escapePos, prev, n2, currentToken;\n  let length = css.length;\n  let pos = 0;\n  let buffer = [];\n  let returned = [];\n  function position() {\n    return pos;\n  }\n  function unclosed(what) {\n    throw input2.error(\"Unclosed \" + what, pos);\n  }\n  function endOfFile() {\n    return returned.length === 0 && pos >= length;\n  }\n  function nextToken(opts) {\n    if (returned.length) return returned.pop();\n    if (pos >= length) return;\n    let ignoreUnclosed = opts ? opts.ignoreUnclosed : false;\n    code = css.charCodeAt(pos);\n    switch (code) {\n      case NEWLINE:\n      case SPACE:\n      case TAB:\n      case CR:\n      case FEED: {\n        next = pos;\n        do {\n          next += 1;\n          code = css.charCodeAt(next);\n        } while (code === SPACE || code === NEWLINE || code === TAB || code === CR || code === FEED);\n        currentToken = [\"space\", css.slice(pos, next)];\n        pos = next - 1;\n        break;\n      }\n      case OPEN_SQUARE:\n      case CLOSE_SQUARE:\n      case OPEN_CURLY:\n      case CLOSE_CURLY:\n      case COLON:\n      case SEMICOLON:\n      case CLOSE_PARENTHESES: {\n        let controlChar = String.fromCharCode(code);\n        currentToken = [controlChar, controlChar, pos];\n        break;\n      }\n      case OPEN_PARENTHESES: {\n        prev = buffer.length ? buffer.pop()[1] : \"\";\n        n2 = css.charCodeAt(pos + 1);\n        if (prev === \"url\" && n2 !== SINGLE_QUOTE && n2 !== DOUBLE_QUOTE && n2 !== SPACE && n2 !== NEWLINE && n2 !== TAB && n2 !== FEED && n2 !== CR) {\n          next = pos;\n          do {\n            escaped = false;\n            next = css.indexOf(\")\", next + 1);\n            if (next === -1) {\n              if (ignore || ignoreUnclosed) {\n                next = pos;\n                break;\n              } else {\n                unclosed(\"bracket\");\n              }\n            }\n            escapePos = next;\n            while (css.charCodeAt(escapePos - 1) === BACKSLASH) {\n              escapePos -= 1;\n              escaped = !escaped;\n            }\n          } while (escaped);\n          currentToken = [\"brackets\", css.slice(pos, next + 1), pos, next];\n          pos = next;\n        } else {\n          next = css.indexOf(\")\", pos + 1);\n          content = css.slice(pos, next + 1);\n          if (next === -1 || RE_BAD_BRACKET.test(content)) {\n            currentToken = [\"(\", \"(\", pos];\n          } else {\n            currentToken = [\"brackets\", content, pos, next];\n            pos = next;\n          }\n        }\n        break;\n      }\n      case SINGLE_QUOTE:\n      case DOUBLE_QUOTE: {\n        quote = code === SINGLE_QUOTE ? \"'\" : '\"';\n        next = pos;\n        do {\n          escaped = false;\n          next = css.indexOf(quote, next + 1);\n          if (next === -1) {\n            if (ignore || ignoreUnclosed) {\n              next = pos + 1;\n              break;\n            } else {\n              unclosed(\"string\");\n            }\n          }\n          escapePos = next;\n          while (css.charCodeAt(escapePos - 1) === BACKSLASH) {\n            escapePos -= 1;\n            escaped = !escaped;\n          }\n        } while (escaped);\n        currentToken = [\"string\", css.slice(pos, next + 1), pos, next];\n        pos = next;\n        break;\n      }\n      case AT: {\n        RE_AT_END.lastIndex = pos + 1;\n        RE_AT_END.test(css);\n        if (RE_AT_END.lastIndex === 0) {\n          next = css.length - 1;\n        } else {\n          next = RE_AT_END.lastIndex - 2;\n        }\n        currentToken = [\"at-word\", css.slice(pos, next + 1), pos, next];\n        pos = next;\n        break;\n      }\n      case BACKSLASH: {\n        next = pos;\n        escape = true;\n        while (css.charCodeAt(next + 1) === BACKSLASH) {\n          next += 1;\n          escape = !escape;\n        }\n        code = css.charCodeAt(next + 1);\n        if (escape && code !== SLASH && code !== SPACE && code !== NEWLINE && code !== TAB && code !== CR && code !== FEED) {\n          next += 1;\n          if (RE_HEX_ESCAPE.test(css.charAt(next))) {\n            while (RE_HEX_ESCAPE.test(css.charAt(next + 1))) {\n              next += 1;\n            }\n            if (css.charCodeAt(next + 1) === SPACE) {\n              next += 1;\n            }\n          }\n        }\n        currentToken = [\"word\", css.slice(pos, next + 1), pos, next];\n        pos = next;\n        break;\n      }\n      default: {\n        if (code === SLASH && css.charCodeAt(pos + 1) === ASTERISK) {\n          next = css.indexOf(\"*/\", pos + 2) + 1;\n          if (next === 0) {\n            if (ignore || ignoreUnclosed) {\n              next = css.length;\n            } else {\n              unclosed(\"comment\");\n            }\n          }\n          currentToken = [\"comment\", css.slice(pos, next + 1), pos, next];\n          pos = next;\n        } else {\n          RE_WORD_END.lastIndex = pos + 1;\n          RE_WORD_END.test(css);\n          if (RE_WORD_END.lastIndex === 0) {\n            next = css.length - 1;\n          } else {\n            next = RE_WORD_END.lastIndex - 2;\n          }\n          currentToken = [\"word\", css.slice(pos, next + 1), pos, next];\n          buffer.push(currentToken);\n          pos = next;\n        }\n        break;\n      }\n    }\n    pos++;\n    return currentToken;\n  }\n  function back(token) {\n    returned.push(token);\n  }\n  return {\n    back,\n    endOfFile,\n    nextToken,\n    position\n  };\n};\nlet Container$5 = container;\nlet AtRule$3 = class AtRule2 extends Container$5 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"atrule\";\n  }\n  append(...children) {\n    if (!this.proxyOf.nodes) this.nodes = [];\n    return super.append(...children);\n  }\n  prepend(...children) {\n    if (!this.proxyOf.nodes) this.nodes = [];\n    return super.prepend(...children);\n  }\n};\nvar atRule = AtRule$3;\nAtRule$3.default = AtRule$3;\nContainer$5.registerAtRule(AtRule$3);\nlet Container$4 = container;\nlet LazyResult$3, Processor$2;\nlet Root$5 = class Root2 extends Container$4 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"root\";\n    if (!this.nodes) this.nodes = [];\n  }\n  normalize(child, sample, type) {\n    let nodes = super.normalize(child);\n    if (sample) {\n      if (type === \"prepend\") {\n        if (this.nodes.length > 1) {\n          sample.raws.before = this.nodes[1].raws.before;\n        } else {\n          delete sample.raws.before;\n        }\n      } else if (this.first !== sample) {\n        for (let node2 of nodes) {\n          node2.raws.before = sample.raws.before;\n        }\n      }\n    }\n    return nodes;\n  }\n  removeChild(child, ignore) {\n    let index2 = this.index(child);\n    if (!ignore && index2 === 0 && this.nodes.length > 1) {\n      this.nodes[1].raws.before = this.nodes[index2].raws.before;\n    }\n    return super.removeChild(child);\n  }\n  toResult(opts = {}) {\n    let lazy = new LazyResult$3(new Processor$2(), this, opts);\n    return lazy.stringify();\n  }\n};\nRoot$5.registerLazyResult = (dependant) => {\n  LazyResult$3 = dependant;\n};\nRoot$5.registerProcessor = (dependant) => {\n  Processor$2 = dependant;\n};\nvar root = Root$5;\nRoot$5.default = Root$5;\nContainer$4.registerRoot(Root$5);\nlet list$2 = {\n  comma(string) {\n    return list$2.split(string, [\",\"], true);\n  },\n  space(string) {\n    let spaces = [\" \", \"\\n\", \"\t\"];\n    return list$2.split(string, spaces);\n  },\n  split(string, separators, last) {\n    let array = [];\n    let current = \"\";\n    let split = false;\n    let func = 0;\n    let inQuote = false;\n    let prevQuote = \"\";\n    let escape = false;\n    for (let letter of string) {\n      if (escape) {\n        escape = false;\n      } else if (letter === \"\\\\\") {\n        escape = true;\n      } else if (inQuote) {\n        if (letter === prevQuote) {\n          inQuote = false;\n        }\n      } else if (letter === '\"' || letter === \"'\") {\n        inQuote = true;\n        prevQuote = letter;\n      } else if (letter === \"(\") {\n        func += 1;\n      } else if (letter === \")\") {\n        if (func > 0) func -= 1;\n      } else if (func === 0) {\n        if (separators.includes(letter)) split = true;\n      }\n      if (split) {\n        if (current !== \"\") array.push(current.trim());\n        current = \"\";\n        split = false;\n      } else {\n        current += letter;\n      }\n    }\n    if (last || current !== \"\") array.push(current.trim());\n    return array;\n  }\n};\nvar list_1 = list$2;\nlist$2.default = list$2;\nlet Container$3 = container;\nlet list$1 = list_1;\nlet Rule$3 = class Rule2 extends Container$3 {\n  constructor(defaults) {\n    super(defaults);\n    this.type = \"rule\";\n    if (!this.nodes) this.nodes = [];\n  }\n  get selectors() {\n    return list$1.comma(this.selector);\n  }\n  set selectors(values) {\n    let match = this.selector ? this.selector.match(/,\\s*/) : null;\n    let sep2 = match ? match[0] : \",\" + this.raw(\"between\", \"beforeOpen\");\n    this.selector = values.join(sep2);\n  }\n};\nvar rule = Rule$3;\nRule$3.default = Rule$3;\nContainer$3.registerRule(Rule$3);\nlet Declaration$2 = declaration;\nlet tokenizer22 = tokenize;\nlet Comment$2 = comment;\nlet AtRule$2 = atRule;\nlet Root$4 = root;\nlet Rule$2 = rule;\nconst SAFE_COMMENT_NEIGHBOR = {\n  empty: true,\n  space: true\n};\nfunction findLastWithPosition(tokens) {\n  for (let i2 = tokens.length - 1; i2 >= 0; i2--) {\n    let token = tokens[i2];\n    let pos = token[3] || token[2];\n    if (pos) return pos;\n  }\n}\nlet Parser$1 = class Parser2 {\n  constructor(input2) {\n    this.input = input2;\n    this.root = new Root$4();\n    this.current = this.root;\n    this.spaces = \"\";\n    this.semicolon = false;\n    this.createTokenizer();\n    this.root.source = { input: input2, start: { column: 1, line: 1, offset: 0 } };\n  }\n  atrule(token) {\n    let node2 = new AtRule$2();\n    node2.name = token[1].slice(1);\n    if (node2.name === \"\") {\n      this.unnamedAtrule(node2, token);\n    }\n    this.init(node2, token[2]);\n    let type;\n    let prev;\n    let shift;\n    let last = false;\n    let open = false;\n    let params = [];\n    let brackets = [];\n    while (!this.tokenizer.endOfFile()) {\n      token = this.tokenizer.nextToken();\n      type = token[0];\n      if (type === \"(\" || type === \"[\") {\n        brackets.push(type === \"(\" ? \")\" : \"]\");\n      } else if (type === \"{\" && brackets.length > 0) {\n        brackets.push(\"}\");\n      } else if (type === brackets[brackets.length - 1]) {\n        brackets.pop();\n      }\n      if (brackets.length === 0) {\n        if (type === \";\") {\n          node2.source.end = this.getPosition(token[2]);\n          node2.source.end.offset++;\n          this.semicolon = true;\n          break;\n        } else if (type === \"{\") {\n          open = true;\n          break;\n        } else if (type === \"}\") {\n          if (params.length > 0) {\n            shift = params.length - 1;\n            prev = params[shift];\n            while (prev && prev[0] === \"space\") {\n              prev = params[--shift];\n            }\n            if (prev) {\n              node2.source.end = this.getPosition(prev[3] || prev[2]);\n              node2.source.end.offset++;\n            }\n          }\n          this.end(token);\n          break;\n        } else {\n          params.push(token);\n        }\n      } else {\n        params.push(token);\n      }\n      if (this.tokenizer.endOfFile()) {\n        last = true;\n        break;\n      }\n    }\n    node2.raws.between = this.spacesAndCommentsFromEnd(params);\n    if (params.length) {\n      node2.raws.afterName = this.spacesAndCommentsFromStart(params);\n      this.raw(node2, \"params\", params);\n      if (last) {\n        token = params[params.length - 1];\n        node2.source.end = this.getPosition(token[3] || token[2]);\n        node2.source.end.offset++;\n        this.spaces = node2.raws.between;\n        node2.raws.between = \"\";\n      }\n    } else {\n      node2.raws.afterName = \"\";\n      node2.params = \"\";\n    }\n    if (open) {\n      node2.nodes = [];\n      this.current = node2;\n    }\n  }\n  checkMissedSemicolon(tokens) {\n    let colon = this.colon(tokens);\n    if (colon === false) return;\n    let founded = 0;\n    let token;\n    for (let j = colon - 1; j >= 0; j--) {\n      token = tokens[j];\n      if (token[0] !== \"space\") {\n        founded += 1;\n        if (founded === 2) break;\n      }\n    }\n    throw this.input.error(\n      \"Missed semicolon\",\n      token[0] === \"word\" ? token[3] + 1 : token[2]\n    );\n  }\n  colon(tokens) {\n    let brackets = 0;\n    let token, type, prev;\n    for (let [i2, element] of tokens.entries()) {\n      token = element;\n      type = token[0];\n      if (type === \"(\") {\n        brackets += 1;\n      }\n      if (type === \")\") {\n        brackets -= 1;\n      }\n      if (brackets === 0 && type === \":\") {\n        if (!prev) {\n          this.doubleColon(token);\n        } else if (prev[0] === \"word\" && prev[1] === \"progid\") {\n          continue;\n        } else {\n          return i2;\n        }\n      }\n      prev = token;\n    }\n    return false;\n  }\n  comment(token) {\n    let node2 = new Comment$2();\n    this.init(node2, token[2]);\n    node2.source.end = this.getPosition(token[3] || token[2]);\n    node2.source.end.offset++;\n    let text = token[1].slice(2, -2);\n    if (/^\\s*$/.test(text)) {\n      node2.text = \"\";\n      node2.raws.left = text;\n      node2.raws.right = \"\";\n    } else {\n      let match = text.match(/^(\\s*)([^]*\\S)(\\s*)$/);\n      node2.text = match[2];\n      node2.raws.left = match[1];\n      node2.raws.right = match[3];\n    }\n  }\n  createTokenizer() {\n    this.tokenizer = tokenizer22(this.input);\n  }\n  decl(tokens, customProperty) {\n    let node2 = new Declaration$2();\n    this.init(node2, tokens[0][2]);\n    let last = tokens[tokens.length - 1];\n    if (last[0] === \";\") {\n      this.semicolon = true;\n      tokens.pop();\n    }\n    node2.source.end = this.getPosition(\n      last[3] || last[2] || findLastWithPosition(tokens)\n    );\n    node2.source.end.offset++;\n    while (tokens[0][0] !== \"word\") {\n      if (tokens.length === 1) this.unknownWord(tokens);\n      node2.raws.before += tokens.shift()[1];\n    }\n    node2.source.start = this.getPosition(tokens[0][2]);\n    node2.prop = \"\";\n    while (tokens.length) {\n      let type = tokens[0][0];\n      if (type === \":\" || type === \"space\" || type === \"comment\") {\n        break;\n      }\n      node2.prop += tokens.shift()[1];\n    }\n    node2.raws.between = \"\";\n    let token;\n    while (tokens.length) {\n      token = tokens.shift();\n      if (token[0] === \":\") {\n        node2.raws.between += token[1];\n        break;\n      } else {\n        if (token[0] === \"word\" && /\\w/.test(token[1])) {\n          this.unknownWord([token]);\n        }\n        node2.raws.between += token[1];\n      }\n    }\n    if (node2.prop[0] === \"_\" || node2.prop[0] === \"*\") {\n      node2.raws.before += node2.prop[0];\n      node2.prop = node2.prop.slice(1);\n    }\n    let firstSpaces = [];\n    let next;\n    while (tokens.length) {\n      next = tokens[0][0];\n      if (next !== \"space\" && next !== \"comment\") break;\n      firstSpaces.push(tokens.shift());\n    }\n    this.precheckMissedSemicolon(tokens);\n    for (let i2 = tokens.length - 1; i2 >= 0; i2--) {\n      token = tokens[i2];\n      if (token[1].toLowerCase() === \"!important\") {\n        node2.important = true;\n        let string = this.stringFrom(tokens, i2);\n        string = this.spacesFromEnd(tokens) + string;\n        if (string !== \" !important\") node2.raws.important = string;\n        break;\n      } else if (token[1].toLowerCase() === \"important\") {\n        let cache = tokens.slice(0);\n        let str = \"\";\n        for (let j = i2; j > 0; j--) {\n          let type = cache[j][0];\n          if (str.trim().indexOf(\"!\") === 0 && type !== \"space\") {\n            break;\n          }\n          str = cache.pop()[1] + str;\n        }\n        if (str.trim().indexOf(\"!\") === 0) {\n          node2.important = true;\n          node2.raws.important = str;\n          tokens = cache;\n        }\n      }\n      if (token[0] !== \"space\" && token[0] !== \"comment\") {\n        break;\n      }\n    }\n    let hasWord = tokens.some((i2) => i2[0] !== \"space\" && i2[0] !== \"comment\");\n    if (hasWord) {\n      node2.raws.between += firstSpaces.map((i2) => i2[1]).join(\"\");\n      firstSpaces = [];\n    }\n    this.raw(node2, \"value\", firstSpaces.concat(tokens), customProperty);\n    if (node2.value.includes(\":\") && !customProperty) {\n      this.checkMissedSemicolon(tokens);\n    }\n  }\n  doubleColon(token) {\n    throw this.input.error(\n      \"Double colon\",\n      { offset: token[2] },\n      { offset: token[2] + token[1].length }\n    );\n  }\n  emptyRule(token) {\n    let node2 = new Rule$2();\n    this.init(node2, token[2]);\n    node2.selector = \"\";\n    node2.raws.between = \"\";\n    this.current = node2;\n  }\n  end(token) {\n    if (this.current.nodes && this.current.nodes.length) {\n      this.current.raws.semicolon = this.semicolon;\n    }\n    this.semicolon = false;\n    this.current.raws.after = (this.current.raws.after || \"\") + this.spaces;\n    this.spaces = \"\";\n    if (this.current.parent) {\n      this.current.source.end = this.getPosition(token[2]);\n      this.current.source.end.offset++;\n      this.current = this.current.parent;\n    } else {\n      this.unexpectedClose(token);\n    }\n  }\n  endFile() {\n    if (this.current.parent) this.unclosedBlock();\n    if (this.current.nodes && this.current.nodes.length) {\n      this.current.raws.semicolon = this.semicolon;\n    }\n    this.current.raws.after = (this.current.raws.after || \"\") + this.spaces;\n    this.root.source.end = this.getPosition(this.tokenizer.position());\n  }\n  freeSemicolon(token) {\n    this.spaces += token[1];\n    if (this.current.nodes) {\n      let prev = this.current.nodes[this.current.nodes.length - 1];\n      if (prev && prev.type === \"rule\" && !prev.raws.ownSemicolon) {\n        prev.raws.ownSemicolon = this.spaces;\n        this.spaces = \"\";\n      }\n    }\n  }\n  // Helpers\n  getPosition(offset) {\n    let pos = this.input.fromOffset(offset);\n    return {\n      column: pos.col,\n      line: pos.line,\n      offset\n    };\n  }\n  init(node2, offset) {\n    this.current.push(node2);\n    node2.source = {\n      input: this.input,\n      start: this.getPosition(offset)\n    };\n    node2.raws.before = this.spaces;\n    this.spaces = \"\";\n    if (node2.type !== \"comment\") this.semicolon = false;\n  }\n  other(start) {\n    let end = false;\n    let type = null;\n    let colon = false;\n    let bracket = null;\n    let brackets = [];\n    let customProperty = start[1].startsWith(\"--\");\n    let tokens = [];\n    let token = start;\n    while (token) {\n      type = token[0];\n      tokens.push(token);\n      if (type === \"(\" || type === \"[\") {\n        if (!bracket) bracket = token;\n        brackets.push(type === \"(\" ? \")\" : \"]\");\n      } else if (customProperty && colon && type === \"{\") {\n        if (!bracket) bracket = token;\n        brackets.push(\"}\");\n      } else if (brackets.length === 0) {\n        if (type === \";\") {\n          if (colon) {\n            this.decl(tokens, customProperty);\n            return;\n          } else {\n            break;\n          }\n        } else if (type === \"{\") {\n          this.rule(tokens);\n          return;\n        } else if (type === \"}\") {\n          this.tokenizer.back(tokens.pop());\n          end = true;\n          break;\n        } else if (type === \":\") {\n          colon = true;\n        }\n      } else if (type === brackets[brackets.length - 1]) {\n        brackets.pop();\n        if (brackets.length === 0) bracket = null;\n      }\n      token = this.tokenizer.nextToken();\n    }\n    if (this.tokenizer.endOfFile()) end = true;\n    if (brackets.length > 0) this.unclosedBracket(bracket);\n    if (end && colon) {\n      if (!customProperty) {\n        while (tokens.length) {\n          token = tokens[tokens.length - 1][0];\n          if (token !== \"space\" && token !== \"comment\") break;\n          this.tokenizer.back(tokens.pop());\n        }\n      }\n      this.decl(tokens, customProperty);\n    } else {\n      this.unknownWord(tokens);\n    }\n  }\n  parse() {\n    let token;\n    while (!this.tokenizer.endOfFile()) {\n      token = this.tokenizer.nextToken();\n      switch (token[0]) {\n        case \"space\":\n          this.spaces += token[1];\n          break;\n        case \";\":\n          this.freeSemicolon(token);\n          break;\n        case \"}\":\n          this.end(token);\n          break;\n        case \"comment\":\n          this.comment(token);\n          break;\n        case \"at-word\":\n          this.atrule(token);\n          break;\n        case \"{\":\n          this.emptyRule(token);\n          break;\n        default:\n          this.other(token);\n          break;\n      }\n    }\n    this.endFile();\n  }\n  precheckMissedSemicolon() {\n  }\n  raw(node2, prop, tokens, customProperty) {\n    let token, type;\n    let length = tokens.length;\n    let value = \"\";\n    let clean = true;\n    let next, prev;\n    for (let i2 = 0; i2 < length; i2 += 1) {\n      token = tokens[i2];\n      type = token[0];\n      if (type === \"space\" && i2 === length - 1 && !customProperty) {\n        clean = false;\n      } else if (type === \"comment\") {\n        prev = tokens[i2 - 1] ? tokens[i2 - 1][0] : \"empty\";\n        next = tokens[i2 + 1] ? tokens[i2 + 1][0] : \"empty\";\n        if (!SAFE_COMMENT_NEIGHBOR[prev] && !SAFE_COMMENT_NEIGHBOR[next]) {\n          if (value.slice(-1) === \",\") {\n            clean = false;\n          } else {\n            value += token[1];\n          }\n        } else {\n          clean = false;\n        }\n      } else {\n        value += token[1];\n      }\n    }\n    if (!clean) {\n      let raw = tokens.reduce((all, i2) => all + i2[1], \"\");\n      node2.raws[prop] = { raw, value };\n    }\n    node2[prop] = value;\n  }\n  rule(tokens) {\n    tokens.pop();\n    let node2 = new Rule$2();\n    this.init(node2, tokens[0][2]);\n    node2.raws.between = this.spacesAndCommentsFromEnd(tokens);\n    this.raw(node2, \"selector\", tokens);\n    this.current = node2;\n  }\n  spacesAndCommentsFromEnd(tokens) {\n    let lastTokenType;\n    let spaces = \"\";\n    while (tokens.length) {\n      lastTokenType = tokens[tokens.length - 1][0];\n      if (lastTokenType !== \"space\" && lastTokenType !== \"comment\") break;\n      spaces = tokens.pop()[1] + spaces;\n    }\n    return spaces;\n  }\n  // Errors\n  spacesAndCommentsFromStart(tokens) {\n    let next;\n    let spaces = \"\";\n    while (tokens.length) {\n      next = tokens[0][0];\n      if (next !== \"space\" && next !== \"comment\") break;\n      spaces += tokens.shift()[1];\n    }\n    return spaces;\n  }\n  spacesFromEnd(tokens) {\n    let lastTokenType;\n    let spaces = \"\";\n    while (tokens.length) {\n      lastTokenType = tokens[tokens.length - 1][0];\n      if (lastTokenType !== \"space\") break;\n      spaces = tokens.pop()[1] + spaces;\n    }\n    return spaces;\n  }\n  stringFrom(tokens, from) {\n    let result2 = \"\";\n    for (let i2 = from; i2 < tokens.length; i2++) {\n      result2 += tokens[i2][1];\n    }\n    tokens.splice(from, tokens.length - from);\n    return result2;\n  }\n  unclosedBlock() {\n    let pos = this.current.source.start;\n    throw this.input.error(\"Unclosed block\", pos.line, pos.column);\n  }\n  unclosedBracket(bracket) {\n    throw this.input.error(\n      \"Unclosed bracket\",\n      { offset: bracket[2] },\n      { offset: bracket[2] + 1 }\n    );\n  }\n  unexpectedClose(token) {\n    throw this.input.error(\n      \"Unexpected }\",\n      { offset: token[2] },\n      { offset: token[2] + 1 }\n    );\n  }\n  unknownWord(tokens) {\n    throw this.input.error(\n      \"Unknown word\",\n      { offset: tokens[0][2] },\n      { offset: tokens[0][2] + tokens[0][1].length }\n    );\n  }\n  unnamedAtrule(node2, token) {\n    throw this.input.error(\n      \"At-rule without name\",\n      { offset: token[2] },\n      { offset: token[2] + token[1].length }\n    );\n  }\n};\nvar parser = Parser$1;\nlet Container$2 = container;\nlet Parser22 = parser;\nlet Input$2 = input;\nfunction parse$3(css, opts) {\n  let input2 = new Input$2(css, opts);\n  let parser2 = new Parser22(input2);\n  try {\n    parser2.parse();\n  } catch (e2) {\n    if (process.env.NODE_ENV !== \"production\") {\n      if (e2.name === \"CssSyntaxError\" && opts && opts.from) {\n        if (/\\.scss$/i.test(opts.from)) {\n          e2.message += \"\\nYou tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser\";\n        } else if (/\\.sass/i.test(opts.from)) {\n          e2.message += \"\\nYou tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser\";\n        } else if (/\\.less$/i.test(opts.from)) {\n          e2.message += \"\\nYou tried to parse Less with the standard CSS parser; try again with the postcss-less parser\";\n        }\n      }\n    }\n    throw e2;\n  }\n  return parser2.root;\n}\nvar parse_1 = parse$3;\nparse$3.default = parse$3;\nContainer$2.registerParse(parse$3);\nlet { isClean, my } = symbols;\nlet MapGenerator$1 = mapGenerator;\nlet stringify$2 = stringify_1;\nlet Container$1 = container;\nlet Document$2 = document$1;\nlet warnOnce$1 = warnOnce$2;\nlet Result$2 = result;\nlet parse$2 = parse_1;\nlet Root$3 = root;\nconst TYPE_TO_CLASS_NAME = {\n  atrule: \"AtRule\",\n  comment: \"Comment\",\n  decl: \"Declaration\",\n  document: \"Document\",\n  root: \"Root\",\n  rule: \"Rule\"\n};\nconst PLUGIN_PROPS = {\n  AtRule: true,\n  AtRuleExit: true,\n  Comment: true,\n  CommentExit: true,\n  Declaration: true,\n  DeclarationExit: true,\n  Document: true,\n  DocumentExit: true,\n  Once: true,\n  OnceExit: true,\n  postcssPlugin: true,\n  prepare: true,\n  Root: true,\n  RootExit: true,\n  Rule: true,\n  RuleExit: true\n};\nconst NOT_VISITORS = {\n  Once: true,\n  postcssPlugin: true,\n  prepare: true\n};\nconst CHILDREN = 0;\nfunction isPromise(obj) {\n  return typeof obj === \"object\" && typeof obj.then === \"function\";\n}\nfunction getEvents(node2) {\n  let key = false;\n  let type = TYPE_TO_CLASS_NAME[node2.type];\n  if (node2.type === \"decl\") {\n    key = node2.prop.toLowerCase();\n  } else if (node2.type === \"atrule\") {\n    key = node2.name.toLowerCase();\n  }\n  if (key && node2.append) {\n    return [\n      type,\n      type + \"-\" + key,\n      CHILDREN,\n      type + \"Exit\",\n      type + \"Exit-\" + key\n    ];\n  } else if (key) {\n    return [type, type + \"-\" + key, type + \"Exit\", type + \"Exit-\" + key];\n  } else if (node2.append) {\n    return [type, CHILDREN, type + \"Exit\"];\n  } else {\n    return [type, type + \"Exit\"];\n  }\n}\nfunction toStack(node2) {\n  let events;\n  if (node2.type === \"document\") {\n    events = [\"Document\", CHILDREN, \"DocumentExit\"];\n  } else if (node2.type === \"root\") {\n    events = [\"Root\", CHILDREN, \"RootExit\"];\n  } else {\n    events = getEvents(node2);\n  }\n  return {\n    eventIndex: 0,\n    events,\n    iterator: 0,\n    node: node2,\n    visitorIndex: 0,\n    visitors: []\n  };\n}\nfunction cleanMarks(node2) {\n  node2[isClean] = false;\n  if (node2.nodes) node2.nodes.forEach((i2) => cleanMarks(i2));\n  return node2;\n}\nlet postcss$2 = {};\nlet LazyResult$2 = class LazyResult2 {\n  constructor(processor2, css, opts) {\n    this.stringified = false;\n    this.processed = false;\n    let root2;\n    if (typeof css === \"object\" && css !== null && (css.type === \"root\" || css.type === \"document\")) {\n      root2 = cleanMarks(css);\n    } else if (css instanceof LazyResult2 || css instanceof Result$2) {\n      root2 = cleanMarks(css.root);\n      if (css.map) {\n        if (typeof opts.map === \"undefined\") opts.map = {};\n        if (!opts.map.inline) opts.map.inline = false;\n        opts.map.prev = css.map;\n      }\n    } else {\n      let parser2 = parse$2;\n      if (opts.syntax) parser2 = opts.syntax.parse;\n      if (opts.parser) parser2 = opts.parser;\n      if (parser2.parse) parser2 = parser2.parse;\n      try {\n        root2 = parser2(css, opts);\n      } catch (error) {\n        this.processed = true;\n        this.error = error;\n      }\n      if (root2 && !root2[my]) {\n        Container$1.rebuild(root2);\n      }\n    }\n    this.result = new Result$2(processor2, root2, opts);\n    this.helpers = { ...postcss$2, postcss: postcss$2, result: this.result };\n    this.plugins = this.processor.plugins.map((plugin22) => {\n      if (typeof plugin22 === \"object\" && plugin22.prepare) {\n        return { ...plugin22, ...plugin22.prepare(this.result) };\n      } else {\n        return plugin22;\n      }\n    });\n  }\n  async() {\n    if (this.error) return Promise.reject(this.error);\n    if (this.processed) return Promise.resolve(this.result);\n    if (!this.processing) {\n      this.processing = this.runAsync();\n    }\n    return this.processing;\n  }\n  catch(onRejected) {\n    return this.async().catch(onRejected);\n  }\n  finally(onFinally) {\n    return this.async().then(onFinally, onFinally);\n  }\n  getAsyncError() {\n    throw new Error(\"Use process(css).then(cb) to work with async plugins\");\n  }\n  handleError(error, node2) {\n    let plugin22 = this.result.lastPlugin;\n    try {\n      if (node2) node2.addToError(error);\n      this.error = error;\n      if (error.name === \"CssSyntaxError\" && !error.plugin) {\n        error.plugin = plugin22.postcssPlugin;\n        error.setMessage();\n      } else if (plugin22.postcssVersion) {\n        if (process.env.NODE_ENV !== \"production\") {\n          let pluginName = plugin22.postcssPlugin;\n          let pluginVer = plugin22.postcssVersion;\n          let runtimeVer = this.result.processor.version;\n          let a2 = pluginVer.split(\".\");\n          let b = runtimeVer.split(\".\");\n          if (a2[0] !== b[0] || parseInt(a2[1]) > parseInt(b[1])) {\n            console.error(\n              \"Unknown error from PostCSS plugin. Your current PostCSS version is \" + runtimeVer + \", but \" + pluginName + \" uses \" + pluginVer + \". Perhaps this is the source of the error below.\"\n            );\n          }\n        }\n      }\n    } catch (err) {\n      if (console && console.error) console.error(err);\n    }\n    return error;\n  }\n  prepareVisitors() {\n    this.listeners = {};\n    let add = (plugin22, type, cb) => {\n      if (!this.listeners[type]) this.listeners[type] = [];\n      this.listeners[type].push([plugin22, cb]);\n    };\n    for (let plugin22 of this.plugins) {\n      if (typeof plugin22 === \"object\") {\n        for (let event in plugin22) {\n          if (!PLUGIN_PROPS[event] && /^[A-Z]/.test(event)) {\n            throw new Error(\n              `Unknown event ${event} in ${plugin22.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`\n            );\n          }\n          if (!NOT_VISITORS[event]) {\n            if (typeof plugin22[event] === \"object\") {\n              for (let filter in plugin22[event]) {\n                if (filter === \"*\") {\n                  add(plugin22, event, plugin22[event][filter]);\n                } else {\n                  add(\n                    plugin22,\n                    event + \"-\" + filter.toLowerCase(),\n                    plugin22[event][filter]\n                  );\n                }\n              }\n            } else if (typeof plugin22[event] === \"function\") {\n              add(plugin22, event, plugin22[event]);\n            }\n          }\n        }\n      }\n    }\n    this.hasListener = Object.keys(this.listeners).length > 0;\n  }\n  async runAsync() {\n    this.plugin = 0;\n    for (let i2 = 0; i2 < this.plugins.length; i2++) {\n      let plugin22 = this.plugins[i2];\n      let promise = this.runOnRoot(plugin22);\n      if (isPromise(promise)) {\n        try {\n          await promise;\n        } catch (error) {\n          throw this.handleError(error);\n        }\n      }\n    }\n    this.prepareVisitors();\n    if (this.hasListener) {\n      let root2 = this.result.root;\n      while (!root2[isClean]) {\n        root2[isClean] = true;\n        let stack = [toStack(root2)];\n        while (stack.length > 0) {\n          let promise = this.visitTick(stack);\n          if (isPromise(promise)) {\n            try {\n              await promise;\n            } catch (e2) {\n              let node2 = stack[stack.length - 1].node;\n              throw this.handleError(e2, node2);\n            }\n          }\n        }\n      }\n      if (this.listeners.OnceExit) {\n        for (let [plugin22, visitor] of this.listeners.OnceExit) {\n          this.result.lastPlugin = plugin22;\n          try {\n            if (root2.type === \"document\") {\n              let roots = root2.nodes.map(\n                (subRoot) => visitor(subRoot, this.helpers)\n              );\n              await Promise.all(roots);\n            } else {\n              await visitor(root2, this.helpers);\n            }\n          } catch (e2) {\n            throw this.handleError(e2);\n          }\n        }\n      }\n    }\n    this.processed = true;\n    return this.stringify();\n  }\n  runOnRoot(plugin22) {\n    this.result.lastPlugin = plugin22;\n    try {\n      if (typeof plugin22 === \"object\" && plugin22.Once) {\n        if (this.result.root.type === \"document\") {\n          let roots = this.result.root.nodes.map(\n            (root2) => plugin22.Once(root2, this.helpers)\n          );\n          if (isPromise(roots[0])) {\n            return Promise.all(roots);\n          }\n          return roots;\n        }\n        return plugin22.Once(this.result.root, this.helpers);\n      } else if (typeof plugin22 === \"function\") {\n        return plugin22(this.result.root, this.result);\n      }\n    } catch (error) {\n      throw this.handleError(error);\n    }\n  }\n  stringify() {\n    if (this.error) throw this.error;\n    if (this.stringified) return this.result;\n    this.stringified = true;\n    this.sync();\n    let opts = this.result.opts;\n    let str = stringify$2;\n    if (opts.syntax) str = opts.syntax.stringify;\n    if (opts.stringifier) str = opts.stringifier;\n    if (str.stringify) str = str.stringify;\n    let map = new MapGenerator$1(str, this.result.root, this.result.opts);\n    let data = map.generate();\n    this.result.css = data[0];\n    this.result.map = data[1];\n    return this.result;\n  }\n  sync() {\n    if (this.error) throw this.error;\n    if (this.processed) return this.result;\n    this.processed = true;\n    if (this.processing) {\n      throw this.getAsyncError();\n    }\n    for (let plugin22 of this.plugins) {\n      let promise = this.runOnRoot(plugin22);\n      if (isPromise(promise)) {\n        throw this.getAsyncError();\n      }\n    }\n    this.prepareVisitors();\n    if (this.hasListener) {\n      let root2 = this.result.root;\n      while (!root2[isClean]) {\n        root2[isClean] = true;\n        this.walkSync(root2);\n      }\n      if (this.listeners.OnceExit) {\n        if (root2.type === \"document\") {\n          for (let subRoot of root2.nodes) {\n            this.visitSync(this.listeners.OnceExit, subRoot);\n          }\n        } else {\n          this.visitSync(this.listeners.OnceExit, root2);\n        }\n      }\n    }\n    return this.result;\n  }\n  then(onFulfilled, onRejected) {\n    if (process.env.NODE_ENV !== \"production\") {\n      if (!(\"from\" in this.opts)) {\n        warnOnce$1(\n          \"Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.\"\n        );\n      }\n    }\n    return this.async().then(onFulfilled, onRejected);\n  }\n  toString() {\n    return this.css;\n  }\n  visitSync(visitors, node2) {\n    for (let [plugin22, visitor] of visitors) {\n      this.result.lastPlugin = plugin22;\n      let promise;\n      try {\n        promise = visitor(node2, this.helpers);\n      } catch (e2) {\n        throw this.handleError(e2, node2.proxyOf);\n      }\n      if (node2.type !== \"root\" && node2.type !== \"document\" && !node2.parent) {\n        return true;\n      }\n      if (isPromise(promise)) {\n        throw this.getAsyncError();\n      }\n    }\n  }\n  visitTick(stack) {\n    let visit2 = stack[stack.length - 1];\n    let { node: node2, visitors } = visit2;\n    if (node2.type !== \"root\" && node2.type !== \"document\" && !node2.parent) {\n      stack.pop();\n      return;\n    }\n    if (visitors.length > 0 && visit2.visitorIndex < visitors.length) {\n      let [plugin22, visitor] = visitors[visit2.visitorIndex];\n      visit2.visitorIndex += 1;\n      if (visit2.visitorIndex === visitors.length) {\n        visit2.visitors = [];\n        visit2.visitorIndex = 0;\n      }\n      this.result.lastPlugin = plugin22;\n      try {\n        return visitor(node2.toProxy(), this.helpers);\n      } catch (e2) {\n        throw this.handleError(e2, node2);\n      }\n    }\n    if (visit2.iterator !== 0) {\n      let iterator = visit2.iterator;\n      let child;\n      while (child = node2.nodes[node2.indexes[iterator]]) {\n        node2.indexes[iterator] += 1;\n        if (!child[isClean]) {\n          child[isClean] = true;\n          stack.push(toStack(child));\n          return;\n        }\n      }\n      visit2.iterator = 0;\n      delete node2.indexes[iterator];\n    }\n    let events = visit2.events;\n    while (visit2.eventIndex < events.length) {\n      let event = events[visit2.eventIndex];\n      visit2.eventIndex += 1;\n      if (event === CHILDREN) {\n        if (node2.nodes && node2.nodes.length) {\n          node2[isClean] = true;\n          visit2.iterator = node2.getIterator();\n        }\n        return;\n      } else if (this.listeners[event]) {\n        visit2.visitors = this.listeners[event];\n        return;\n      }\n    }\n    stack.pop();\n  }\n  walkSync(node2) {\n    node2[isClean] = true;\n    let events = getEvents(node2);\n    for (let event of events) {\n      if (event === CHILDREN) {\n        if (node2.nodes) {\n          node2.each((child) => {\n            if (!child[isClean]) this.walkSync(child);\n          });\n        }\n      } else {\n        let visitors = this.listeners[event];\n        if (visitors) {\n          if (this.visitSync(visitors, node2.toProxy())) return;\n        }\n      }\n    }\n  }\n  warnings() {\n    return this.sync().warnings();\n  }\n  get content() {\n    return this.stringify().content;\n  }\n  get css() {\n    return this.stringify().css;\n  }\n  get map() {\n    return this.stringify().map;\n  }\n  get messages() {\n    return this.sync().messages;\n  }\n  get opts() {\n    return this.result.opts;\n  }\n  get processor() {\n    return this.result.processor;\n  }\n  get root() {\n    return this.sync().root;\n  }\n  get [Symbol.toStringTag]() {\n    return \"LazyResult\";\n  }\n};\nLazyResult$2.registerPostcss = (dependant) => {\n  postcss$2 = dependant;\n};\nvar lazyResult = LazyResult$2;\nLazyResult$2.default = LazyResult$2;\nRoot$3.registerLazyResult(LazyResult$2);\nDocument$2.registerLazyResult(LazyResult$2);\nlet MapGenerator22 = mapGenerator;\nlet stringify$1 = stringify_1;\nlet warnOnce22 = warnOnce$2;\nlet parse$1 = parse_1;\nconst Result$1 = result;\nlet NoWorkResult$1 = class NoWorkResult2 {\n  constructor(processor2, css, opts) {\n    css = css.toString();\n    this.stringified = false;\n    this._processor = processor2;\n    this._css = css;\n    this._opts = opts;\n    this._map = void 0;\n    let root2;\n    let str = stringify$1;\n    this.result = new Result$1(this._processor, root2, this._opts);\n    this.result.css = css;\n    let self = this;\n    Object.defineProperty(this.result, \"root\", {\n      get() {\n        return self.root;\n      }\n    });\n    let map = new MapGenerator22(str, root2, this._opts, css);\n    if (map.isMap()) {\n      let [generatedCSS, generatedMap] = map.generate();\n      if (generatedCSS) {\n        this.result.css = generatedCSS;\n      }\n      if (generatedMap) {\n        this.result.map = generatedMap;\n      }\n    } else {\n      map.clearAnnotation();\n      this.result.css = map.css;\n    }\n  }\n  async() {\n    if (this.error) return Promise.reject(this.error);\n    return Promise.resolve(this.result);\n  }\n  catch(onRejected) {\n    return this.async().catch(onRejected);\n  }\n  finally(onFinally) {\n    return this.async().then(onFinally, onFinally);\n  }\n  sync() {\n    if (this.error) throw this.error;\n    return this.result;\n  }\n  then(onFulfilled, onRejected) {\n    if (process.env.NODE_ENV !== \"production\") {\n      if (!(\"from\" in this._opts)) {\n        warnOnce22(\n          \"Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.\"\n        );\n      }\n    }\n    return this.async().then(onFulfilled, onRejected);\n  }\n  toString() {\n    return this._css;\n  }\n  warnings() {\n    return [];\n  }\n  get content() {\n    return this.result.css;\n  }\n  get css() {\n    return this.result.css;\n  }\n  get map() {\n    return this.result.map;\n  }\n  get messages() {\n    return [];\n  }\n  get opts() {\n    return this.result.opts;\n  }\n  get processor() {\n    return this.result.processor;\n  }\n  get root() {\n    if (this._root) {\n      return this._root;\n    }\n    let root2;\n    let parser2 = parse$1;\n    try {\n      root2 = parser2(this._css, this._opts);\n    } catch (error) {\n      this.error = error;\n    }\n    if (this.error) {\n      throw this.error;\n    } else {\n      this._root = root2;\n      return root2;\n    }\n  }\n  get [Symbol.toStringTag]() {\n    return \"NoWorkResult\";\n  }\n};\nvar noWorkResult = NoWorkResult$1;\nNoWorkResult$1.default = NoWorkResult$1;\nlet NoWorkResult22 = noWorkResult;\nlet LazyResult$1 = lazyResult;\nlet Document$1 = document$1;\nlet Root$2 = root;\nlet Processor$1 = class Processor2 {\n  constructor(plugins = []) {\n    this.version = \"8.4.38\";\n    this.plugins = this.normalize(plugins);\n  }\n  normalize(plugins) {\n    let normalized = [];\n    for (let i2 of plugins) {\n      if (i2.postcss === true) {\n        i2 = i2();\n      } else if (i2.postcss) {\n        i2 = i2.postcss;\n      }\n      if (typeof i2 === \"object\" && Array.isArray(i2.plugins)) {\n        normalized = normalized.concat(i2.plugins);\n      } else if (typeof i2 === \"object\" && i2.postcssPlugin) {\n        normalized.push(i2);\n      } else if (typeof i2 === \"function\") {\n        normalized.push(i2);\n      } else if (typeof i2 === \"object\" && (i2.parse || i2.stringify)) {\n        if (process.env.NODE_ENV !== \"production\") {\n          throw new Error(\n            \"PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.\"\n          );\n        }\n      } else {\n        throw new Error(i2 + \" is not a PostCSS plugin\");\n      }\n    }\n    return normalized;\n  }\n  process(css, opts = {}) {\n    if (!this.plugins.length && !opts.parser && !opts.stringifier && !opts.syntax) {\n      return new NoWorkResult22(this, css, opts);\n    } else {\n      return new LazyResult$1(this, css, opts);\n    }\n  }\n  use(plugin22) {\n    this.plugins = this.plugins.concat(this.normalize([plugin22]));\n    return this;\n  }\n};\nvar processor = Processor$1;\nProcessor$1.default = Processor$1;\nRoot$2.registerProcessor(Processor$1);\nDocument$1.registerProcessor(Processor$1);\nlet Declaration$1 = declaration;\nlet PreviousMap22 = previousMap;\nlet Comment$1 = comment;\nlet AtRule$1 = atRule;\nlet Input$1 = input;\nlet Root$1 = root;\nlet Rule$1 = rule;\nfunction fromJSON$1(json, inputs) {\n  if (Array.isArray(json)) return json.map((n2) => fromJSON$1(n2));\n  let { inputs: ownInputs, ...defaults } = json;\n  if (ownInputs) {\n    inputs = [];\n    for (let input2 of ownInputs) {\n      let inputHydrated = { ...input2, __proto__: Input$1.prototype };\n      if (inputHydrated.map) {\n        inputHydrated.map = {\n          ...inputHydrated.map,\n          __proto__: PreviousMap22.prototype\n        };\n      }\n      inputs.push(inputHydrated);\n    }\n  }\n  if (defaults.nodes) {\n    defaults.nodes = json.nodes.map((n2) => fromJSON$1(n2, inputs));\n  }\n  if (defaults.source) {\n    let { inputId, ...source } = defaults.source;\n    defaults.source = source;\n    if (inputId != null) {\n      defaults.source.input = inputs[inputId];\n    }\n  }\n  if (defaults.type === \"root\") {\n    return new Root$1(defaults);\n  } else if (defaults.type === \"decl\") {\n    return new Declaration$1(defaults);\n  } else if (defaults.type === \"rule\") {\n    return new Rule$1(defaults);\n  } else if (defaults.type === \"comment\") {\n    return new Comment$1(defaults);\n  } else if (defaults.type === \"atrule\") {\n    return new AtRule$1(defaults);\n  } else {\n    throw new Error(\"Unknown node type: \" + json.type);\n  }\n}\nvar fromJSON_1 = fromJSON$1;\nfromJSON$1.default = fromJSON$1;\nlet CssSyntaxError22 = cssSyntaxError;\nlet Declaration22 = declaration;\nlet LazyResult22 = lazyResult;\nlet Container22 = container;\nlet Processor22 = processor;\nlet stringify = stringify_1;\nlet fromJSON = fromJSON_1;\nlet Document222 = document$1;\nlet Warning22 = warning;\nlet Comment22 = comment;\nlet AtRule22 = atRule;\nlet Result22 = result;\nlet Input22 = input;\nlet parse = parse_1;\nlet list = list_1;\nlet Rule22 = rule;\nlet Root22 = root;\nlet Node22 = node;\nfunction postcss(...plugins) {\n  if (plugins.length === 1 && Array.isArray(plugins[0])) {\n    plugins = plugins[0];\n  }\n  return new Processor22(plugins);\n}\npostcss.plugin = function plugin2(name, initializer) {\n  let warningPrinted = false;\n  function creator(...args) {\n    if (console && console.warn && !warningPrinted) {\n      warningPrinted = true;\n      console.warn(\n        name + \": postcss.plugin was deprecated. Migration guide:\\nhttps://evilmartians.com/chronicles/postcss-8-plugin-migration\"\n      );\n      if (process.env.LANG && process.env.LANG.startsWith(\"cn\")) {\n        console.warn(\n          name + \": 里面 postcss.plugin 被弃用. 迁移指南:\\nhttps://www.w3ctech.com/topic/2226\"\n        );\n      }\n    }\n    let transformer = initializer(...args);\n    transformer.postcssPlugin = name;\n    transformer.postcssVersion = new Processor22().version;\n    return transformer;\n  }\n  let cache;\n  Object.defineProperty(creator, \"postcss\", {\n    get() {\n      if (!cache) cache = creator();\n      return cache;\n    }\n  });\n  creator.process = function(css, processOpts, pluginOpts) {\n    return postcss([creator(pluginOpts)]).process(css, processOpts);\n  };\n  return creator;\n};\npostcss.stringify = stringify;\npostcss.parse = parse;\npostcss.fromJSON = fromJSON;\npostcss.list = list;\npostcss.comment = (defaults) => new Comment22(defaults);\npostcss.atRule = (defaults) => new AtRule22(defaults);\npostcss.decl = (defaults) => new Declaration22(defaults);\npostcss.rule = (defaults) => new Rule22(defaults);\npostcss.root = (defaults) => new Root22(defaults);\npostcss.document = (defaults) => new Document222(defaults);\npostcss.CssSyntaxError = CssSyntaxError22;\npostcss.Declaration = Declaration22;\npostcss.Container = Container22;\npostcss.Processor = Processor22;\npostcss.Document = Document222;\npostcss.Comment = Comment22;\npostcss.Warning = Warning22;\npostcss.AtRule = AtRule22;\npostcss.Result = Result22;\npostcss.Input = Input22;\npostcss.Rule = Rule22;\npostcss.Root = Root22;\npostcss.Node = Node22;\nLazyResult22.registerPostcss(postcss);\nvar postcss_1 = postcss;\npostcss.default = postcss;\nconst postcss$1 = /* @__PURE__ */ getDefaultExportFromCjs(postcss_1);\npostcss$1.stringify;\npostcss$1.fromJSON;\npostcss$1.plugin;\npostcss$1.parse;\npostcss$1.list;\npostcss$1.document;\npostcss$1.comment;\npostcss$1.atRule;\npostcss$1.rule;\npostcss$1.decl;\npostcss$1.root;\npostcss$1.CssSyntaxError;\npostcss$1.Declaration;\npostcss$1.Container;\npostcss$1.Processor;\npostcss$1.Document;\npostcss$1.Comment;\npostcss$1.Warning;\npostcss$1.AtRule;\npostcss$1.Result;\npostcss$1.Input;\npostcss$1.Rule;\npostcss$1.Root;\npostcss$1.Node;\nclass BaseRRNode {\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any\n  constructor(..._args) {\n    __publicField2(this, \"parentElement\", null);\n    __publicField2(this, \"parentNode\", null);\n    __publicField2(this, \"ownerDocument\");\n    __publicField2(this, \"firstChild\", null);\n    __publicField2(this, \"lastChild\", null);\n    __publicField2(this, \"previousSibling\", null);\n    __publicField2(this, \"nextSibling\", null);\n    __publicField2(this, \"ELEMENT_NODE\", 1);\n    __publicField2(this, \"TEXT_NODE\", 3);\n    __publicField2(this, \"nodeType\");\n    __publicField2(this, \"nodeName\");\n    __publicField2(this, \"RRNodeType\");\n  }\n  get childNodes() {\n    const childNodes2 = [];\n    let childIterator = this.firstChild;\n    while (childIterator) {\n      childNodes2.push(childIterator);\n      childIterator = childIterator.nextSibling;\n    }\n    return childNodes2;\n  }\n  contains(node2) {\n    if (!(node2 instanceof BaseRRNode)) return false;\n    else if (node2.ownerDocument !== this.ownerDocument) return false;\n    else if (node2 === this) return true;\n    while (node2.parentNode) {\n      if (node2.parentNode === this) return true;\n      node2 = node2.parentNode;\n    }\n    return false;\n  }\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  appendChild(_newChild) {\n    throw new Error(\n      `RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.`\n    );\n  }\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  insertBefore(_newChild, _refChild) {\n    throw new Error(\n      `RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.`\n    );\n  }\n  // eslint-disable-next-line @typescript-eslint/no-unused-vars\n  removeChild(_node) {\n    throw new Error(\n      `RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.`\n    );\n  }\n  toString() {\n    return \"RRNode\";\n  }\n}\nconst testableAccessors = {\n  Node: [\n    \"childNodes\",\n    \"parentNode\",\n    \"parentElement\",\n    \"textContent\",\n    \"ownerDocument\"\n  ],\n  ShadowRoot: [\"host\", \"styleSheets\"],\n  Element: [\"shadowRoot\", \"querySelector\", \"querySelectorAll\"],\n  MutationObserver: []\n};\nconst testableMethods = {\n  Node: [\"contains\", \"getRootNode\"],\n  ShadowRoot: [\"getSelection\"],\n  Element: [],\n  MutationObserver: [\"constructor\"]\n};\nconst untaintedBasePrototype = {};\nconst isAngularZonePresent = () => {\n  return !!globalThis.Zone;\n};\nfunction getUntaintedPrototype(key) {\n  if (untaintedBasePrototype[key])\n    return untaintedBasePrototype[key];\n  const defaultObj = globalThis[key];\n  const defaultPrototype = defaultObj.prototype;\n  const accessorNames = key in testableAccessors ? testableAccessors[key] : void 0;\n  const isUntaintedAccessors = Boolean(\n    accessorNames && // @ts-expect-error 2345\n    accessorNames.every(\n      (accessor) => {\n        var _a2, _b;\n        return Boolean(\n          (_b = (_a2 = Object.getOwnPropertyDescriptor(defaultPrototype, accessor)) == null ? void 0 : _a2.get) == null ? void 0 : _b.toString().includes(\"[native code]\")\n        );\n      }\n    )\n  );\n  const methodNames = key in testableMethods ? testableMethods[key] : void 0;\n  const isUntaintedMethods = Boolean(\n    methodNames && methodNames.every(\n      // @ts-expect-error 2345\n      (method) => {\n        var _a2;\n        return typeof defaultPrototype[method] === \"function\" && ((_a2 = defaultPrototype[method]) == null ? void 0 : _a2.toString().includes(\"[native code]\"));\n      }\n    )\n  );\n  if (isUntaintedAccessors && isUntaintedMethods && !isAngularZonePresent()) {\n    untaintedBasePrototype[key] = defaultObj.prototype;\n    return defaultObj.prototype;\n  }\n  try {\n    const iframeEl = document.createElement(\"iframe\");\n    document.body.appendChild(iframeEl);\n    const win = iframeEl.contentWindow;\n    if (!win) return defaultObj.prototype;\n    const untaintedObject = win[key].prototype;\n    document.body.removeChild(iframeEl);\n    if (!untaintedObject) return defaultPrototype;\n    return untaintedBasePrototype[key] = untaintedObject;\n  } catch {\n    return defaultPrototype;\n  }\n}\nconst untaintedAccessorCache = {};\nfunction getUntaintedAccessor(key, instance, accessor) {\n  var _a2;\n  const cacheKey = `${key}.${String(accessor)}`;\n  if (untaintedAccessorCache[cacheKey])\n    return untaintedAccessorCache[cacheKey].call(\n      instance\n    );\n  const untaintedPrototype = getUntaintedPrototype(key);\n  const untaintedAccessor = (_a2 = Object.getOwnPropertyDescriptor(\n    untaintedPrototype,\n    accessor\n  )) == null ? void 0 : _a2.get;\n  if (!untaintedAccessor) return instance[accessor];\n  untaintedAccessorCache[cacheKey] = untaintedAccessor;\n  return untaintedAccessor.call(instance);\n}\nconst untaintedMethodCache = {};\nfunction getUntaintedMethod(key, instance, method) {\n  const cacheKey = `${key}.${String(method)}`;\n  if (untaintedMethodCache[cacheKey])\n    return untaintedMethodCache[cacheKey].bind(\n      instance\n    );\n  const untaintedPrototype = getUntaintedPrototype(key);\n  const untaintedMethod = untaintedPrototype[method];\n  if (typeof untaintedMethod !== \"function\") return instance[method];\n  untaintedMethodCache[cacheKey] = untaintedMethod;\n  return untaintedMethod.bind(instance);\n}\nfunction ownerDocument(n2) {\n  return getUntaintedAccessor(\"Node\", n2, \"ownerDocument\");\n}\nfunction childNodes(n2) {\n  return getUntaintedAccessor(\"Node\", n2, \"childNodes\");\n}\nfunction parentNode(n2) {\n  return getUntaintedAccessor(\"Node\", n2, \"parentNode\");\n}\nfunction parentElement(n2) {\n  return getUntaintedAccessor(\"Node\", n2, \"parentElement\");\n}\nfunction textContent(n2) {\n  return getUntaintedAccessor(\"Node\", n2, \"textContent\");\n}\nfunction contains(n2, other) {\n  return getUntaintedMethod(\"Node\", n2, \"contains\")(other);\n}\nfunction getRootNode(n2) {\n  return getUntaintedMethod(\"Node\", n2, \"getRootNode\")();\n}\nfunction host(n2) {\n  if (!n2 || !(\"host\" in n2)) return null;\n  return getUntaintedAccessor(\"ShadowRoot\", n2, \"host\");\n}\nfunction styleSheets(n2) {\n  return n2.styleSheets;\n}\nfunction shadowRoot(n2) {\n  if (!n2 || !(\"shadowRoot\" in n2)) return null;\n  return getUntaintedAccessor(\"Element\", n2, \"shadowRoot\");\n}\nfunction querySelector(n2, selectors) {\n  return getUntaintedAccessor(\"Element\", n2, \"querySelector\")(selectors);\n}\nfunction querySelectorAll(n2, selectors) {\n  return getUntaintedAccessor(\"Element\", n2, \"querySelectorAll\")(selectors);\n}\nfunction mutationObserverCtor() {\n  return getUntaintedPrototype(\"MutationObserver\").constructor;\n}\nfunction patch(source, name, replacement) {\n  try {\n    if (!(name in source)) {\n      return () => {\n      };\n    }\n    const original = source[name];\n    const wrapped = replacement(original);\n    if (typeof wrapped === \"function\") {\n      wrapped.prototype = wrapped.prototype || {};\n      Object.defineProperties(wrapped, {\n        __rrweb_original__: {\n          enumerable: false,\n          value: original\n        }\n      });\n    }\n    source[name] = wrapped;\n    return () => {\n      source[name] = original;\n    };\n  } catch {\n    return () => {\n    };\n  }\n}\nconst index = {\n  ownerDocument,\n  childNodes,\n  parentNode,\n  parentElement,\n  textContent,\n  contains,\n  getRootNode,\n  host,\n  styleSheets,\n  shadowRoot,\n  querySelector,\n  querySelectorAll,\n  mutationObserver: mutationObserverCtor,\n  patch\n};\nfunction on(type, fn, target = document) {\n  const options = { capture: true, passive: true };\n  target.addEventListener(type, fn, options);\n  return () => target.removeEventListener(type, fn, options);\n}\nconst DEPARTED_MIRROR_ACCESS_WARNING = \"Please stop import mirror directly. Instead of that,\\r\\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\\r\\nor you can use record.mirror to access the mirror instance during recording.\";\nlet _mirror = {\n  map: {},\n  getId() {\n    console.error(DEPARTED_MIRROR_ACCESS_WARNING);\n    return -1;\n  },\n  getNode() {\n    console.error(DEPARTED_MIRROR_ACCESS_WARNING);\n    return null;\n  },\n  removeNodeFromMap() {\n    console.error(DEPARTED_MIRROR_ACCESS_WARNING);\n  },\n  has() {\n    console.error(DEPARTED_MIRROR_ACCESS_WARNING);\n    return false;\n  },\n  reset() {\n    console.error(DEPARTED_MIRROR_ACCESS_WARNING);\n  }\n};\nif (typeof window !== \"undefined\" && window.Proxy && window.Reflect) {\n  _mirror = new Proxy(_mirror, {\n    get(target, prop, receiver) {\n      if (prop === \"map\") {\n        console.error(DEPARTED_MIRROR_ACCESS_WARNING);\n      }\n      return Reflect.get(target, prop, receiver);\n    }\n  });\n}\nfunction throttle(func, wait, options = {}) {\n  let timeout = null;\n  let previous = 0;\n  return function(...args) {\n    const now = Date.now();\n    if (!previous && options.leading === false) {\n      previous = now;\n    }\n    const remaining = wait - (now - previous);\n    const context = this;\n    if (remaining <= 0 || remaining > wait) {\n      if (timeout) {\n        clearTimeout(timeout);\n        timeout = null;\n      }\n      previous = now;\n      func.apply(context, args);\n    } else if (!timeout && options.trailing !== false) {\n      timeout = setTimeout(() => {\n        previous = options.leading === false ? 0 : Date.now();\n        timeout = null;\n        func.apply(context, args);\n      }, remaining);\n    }\n  };\n}\nfunction hookSetter(target, key, d, isRevoked, win = window) {\n  const original = win.Object.getOwnPropertyDescriptor(target, key);\n  win.Object.defineProperty(\n    target,\n    key,\n    isRevoked ? d : {\n      set(value) {\n        setTimeout(() => {\n          d.set.call(this, value);\n        }, 0);\n        if (original && original.set) {\n          original.set.call(this, value);\n        }\n      }\n    }\n  );\n  return () => hookSetter(target, key, original || {}, true);\n}\nlet nowTimestamp = Date.now;\nif (!/* @__PURE__ */ /[1-9][0-9]{12}/.test(Date.now().toString())) {\n  nowTimestamp = () => (/* @__PURE__ */ new Date()).getTime();\n}\nfunction getWindowScroll(win) {\n  var _a2, _b, _c, _d;\n  const doc = win.document;\n  return {\n    left: doc.scrollingElement ? doc.scrollingElement.scrollLeft : win.pageXOffset !== void 0 ? win.pageXOffset : doc.documentElement.scrollLeft || (doc == null ? void 0 : doc.body) && ((_a2 = index.parentElement(doc.body)) == null ? void 0 : _a2.scrollLeft) || ((_b = doc == null ? void 0 : doc.body) == null ? void 0 : _b.scrollLeft) || 0,\n    top: doc.scrollingElement ? doc.scrollingElement.scrollTop : win.pageYOffset !== void 0 ? win.pageYOffset : (doc == null ? void 0 : doc.documentElement.scrollTop) || (doc == null ? void 0 : doc.body) && ((_c = index.parentElement(doc.body)) == null ? void 0 : _c.scrollTop) || ((_d = doc == null ? void 0 : doc.body) == null ? void 0 : _d.scrollTop) || 0\n  };\n}\nfunction getWindowHeight() {\n  return window.innerHeight || document.documentElement && document.documentElement.clientHeight || document.body && document.body.clientHeight;\n}\nfunction getWindowWidth() {\n  return window.innerWidth || document.documentElement && document.documentElement.clientWidth || document.body && document.body.clientWidth;\n}\nfunction closestElementOfNode(node2) {\n  if (!node2) {\n    return null;\n  }\n  const el = node2.nodeType === node2.ELEMENT_NODE ? node2 : index.parentElement(node2);\n  return el;\n}\nfunction isBlocked(node2, blockClass, blockSelector, checkAncestors) {\n  if (!node2) {\n    return false;\n  }\n  const el = closestElementOfNode(node2);\n  if (!el) {\n    return false;\n  }\n  try {\n    if (typeof blockClass === \"string\") {\n      if (el.classList.contains(blockClass)) return true;\n      if (checkAncestors && el.closest(\".\" + blockClass) !== null) return true;\n    } else {\n      if (classMatchesRegex(el, blockClass, checkAncestors)) return true;\n    }\n  } catch (e2) {\n  }\n  if (blockSelector) {\n    if (el.matches(blockSelector)) return true;\n    if (checkAncestors && el.closest(blockSelector) !== null) return true;\n  }\n  return false;\n}\nfunction isSerialized(n2, mirror2) {\n  return mirror2.getId(n2) !== -1;\n}\nfunction isIgnored(n2, mirror2, slimDOMOptions) {\n  if (n2.tagName === \"TITLE\" && slimDOMOptions.headTitleMutations) {\n    return true;\n  }\n  return mirror2.getId(n2) === IGNORED_NODE;\n}\nfunction isAncestorRemoved(target, mirror2) {\n  if (isShadowRoot(target)) {\n    return false;\n  }\n  const id = mirror2.getId(target);\n  if (!mirror2.has(id)) {\n    return true;\n  }\n  const parent = index.parentNode(target);\n  if (parent && parent.nodeType === target.DOCUMENT_NODE) {\n    return false;\n  }\n  if (!parent) {\n    return true;\n  }\n  return isAncestorRemoved(parent, mirror2);\n}\nfunction legacy_isTouchEvent(event) {\n  return Boolean(event.changedTouches);\n}\nfunction polyfill$1(win = window) {\n  if (\"NodeList\" in win && !win.NodeList.prototype.forEach) {\n    win.NodeList.prototype.forEach = Array.prototype.forEach;\n  }\n  if (\"DOMTokenList\" in win && !win.DOMTokenList.prototype.forEach) {\n    win.DOMTokenList.prototype.forEach = Array.prototype.forEach;\n  }\n}\nfunction isSerializedIframe(n2, mirror2) {\n  return Boolean(n2.nodeName === \"IFRAME\" && mirror2.getMeta(n2));\n}\nfunction isSerializedStylesheet(n2, mirror2) {\n  return Boolean(\n    n2.nodeName === \"LINK\" && n2.nodeType === n2.ELEMENT_NODE && n2.getAttribute && n2.getAttribute(\"rel\") === \"stylesheet\" && mirror2.getMeta(n2)\n  );\n}\nfunction hasShadowRoot(n2) {\n  if (!n2) return false;\n  if (n2 instanceof BaseRRNode && \"shadowRoot\" in n2) {\n    return Boolean(n2.shadowRoot);\n  }\n  return Boolean(index.shadowRoot(n2));\n}\nclass StyleSheetMirror {\n  constructor() {\n    __publicField(this, \"id\", 1);\n    __publicField(this, \"styleIDMap\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"idStyleMap\", /* @__PURE__ */ new Map());\n  }\n  getId(stylesheet) {\n    return this.styleIDMap.get(stylesheet) ?? -1;\n  }\n  has(stylesheet) {\n    return this.styleIDMap.has(stylesheet);\n  }\n  /**\n   * @returns If the stylesheet is in the mirror, returns the id of the stylesheet. If not, return the new assigned id.\n   */\n  add(stylesheet, id) {\n    if (this.has(stylesheet)) return this.getId(stylesheet);\n    let newId;\n    if (id === void 0) {\n      newId = this.id++;\n    } else newId = id;\n    this.styleIDMap.set(stylesheet, newId);\n    this.idStyleMap.set(newId, stylesheet);\n    return newId;\n  }\n  getStyle(id) {\n    return this.idStyleMap.get(id) || null;\n  }\n  reset() {\n    this.styleIDMap = /* @__PURE__ */ new WeakMap();\n    this.idStyleMap = /* @__PURE__ */ new Map();\n    this.id = 1;\n  }\n  generateId() {\n    return this.id++;\n  }\n}\nfunction getShadowHost(n2) {\n  var _a2;\n  let shadowHost = null;\n  if (\"getRootNode\" in n2 && ((_a2 = index.getRootNode(n2)) == null ? void 0 : _a2.nodeType) === Node.DOCUMENT_FRAGMENT_NODE && index.host(index.getRootNode(n2)))\n    shadowHost = index.host(index.getRootNode(n2));\n  return shadowHost;\n}\nfunction getRootShadowHost(n2) {\n  let rootShadowHost = n2;\n  let shadowHost;\n  while (shadowHost = getShadowHost(rootShadowHost))\n    rootShadowHost = shadowHost;\n  return rootShadowHost;\n}\nfunction shadowHostInDom(n2) {\n  const doc = index.ownerDocument(n2);\n  if (!doc) return false;\n  const shadowHost = getRootShadowHost(n2);\n  return index.contains(doc, shadowHost);\n}\nfunction inDom(n2) {\n  const doc = index.ownerDocument(n2);\n  if (!doc) return false;\n  return index.contains(doc, n2) || shadowHostInDom(n2);\n}\nvar EventType = /* @__PURE__ */ ((EventType2) => {\n  EventType2[EventType2[\"DomContentLoaded\"] = 0] = \"DomContentLoaded\";\n  EventType2[EventType2[\"Load\"] = 1] = \"Load\";\n  EventType2[EventType2[\"FullSnapshot\"] = 2] = \"FullSnapshot\";\n  EventType2[EventType2[\"IncrementalSnapshot\"] = 3] = \"IncrementalSnapshot\";\n  EventType2[EventType2[\"Meta\"] = 4] = \"Meta\";\n  EventType2[EventType2[\"Custom\"] = 5] = \"Custom\";\n  EventType2[EventType2[\"Plugin\"] = 6] = \"Plugin\";\n  return EventType2;\n})(EventType || {});\nvar IncrementalSource = /* @__PURE__ */ ((IncrementalSource2) => {\n  IncrementalSource2[IncrementalSource2[\"Mutation\"] = 0] = \"Mutation\";\n  IncrementalSource2[IncrementalSource2[\"MouseMove\"] = 1] = \"MouseMove\";\n  IncrementalSource2[IncrementalSource2[\"MouseInteraction\"] = 2] = \"MouseInteraction\";\n  IncrementalSource2[IncrementalSource2[\"Scroll\"] = 3] = \"Scroll\";\n  IncrementalSource2[IncrementalSource2[\"ViewportResize\"] = 4] = \"ViewportResize\";\n  IncrementalSource2[IncrementalSource2[\"Input\"] = 5] = \"Input\";\n  IncrementalSource2[IncrementalSource2[\"TouchMove\"] = 6] = \"TouchMove\";\n  IncrementalSource2[IncrementalSource2[\"MediaInteraction\"] = 7] = \"MediaInteraction\";\n  IncrementalSource2[IncrementalSource2[\"StyleSheetRule\"] = 8] = \"StyleSheetRule\";\n  IncrementalSource2[IncrementalSource2[\"CanvasMutation\"] = 9] = \"CanvasMutation\";\n  IncrementalSource2[IncrementalSource2[\"Font\"] = 10] = \"Font\";\n  IncrementalSource2[IncrementalSource2[\"Log\"] = 11] = \"Log\";\n  IncrementalSource2[IncrementalSource2[\"Drag\"] = 12] = \"Drag\";\n  IncrementalSource2[IncrementalSource2[\"StyleDeclaration\"] = 13] = \"StyleDeclaration\";\n  IncrementalSource2[IncrementalSource2[\"Selection\"] = 14] = \"Selection\";\n  IncrementalSource2[IncrementalSource2[\"AdoptedStyleSheet\"] = 15] = \"AdoptedStyleSheet\";\n  IncrementalSource2[IncrementalSource2[\"CustomElement\"] = 16] = \"CustomElement\";\n  return IncrementalSource2;\n})(IncrementalSource || {});\nvar MouseInteractions = /* @__PURE__ */ ((MouseInteractions2) => {\n  MouseInteractions2[MouseInteractions2[\"MouseUp\"] = 0] = \"MouseUp\";\n  MouseInteractions2[MouseInteractions2[\"MouseDown\"] = 1] = \"MouseDown\";\n  MouseInteractions2[MouseInteractions2[\"Click\"] = 2] = \"Click\";\n  MouseInteractions2[MouseInteractions2[\"ContextMenu\"] = 3] = \"ContextMenu\";\n  MouseInteractions2[MouseInteractions2[\"DblClick\"] = 4] = \"DblClick\";\n  MouseInteractions2[MouseInteractions2[\"Focus\"] = 5] = \"Focus\";\n  MouseInteractions2[MouseInteractions2[\"Blur\"] = 6] = \"Blur\";\n  MouseInteractions2[MouseInteractions2[\"TouchStart\"] = 7] = \"TouchStart\";\n  MouseInteractions2[MouseInteractions2[\"TouchMove_Departed\"] = 8] = \"TouchMove_Departed\";\n  MouseInteractions2[MouseInteractions2[\"TouchEnd\"] = 9] = \"TouchEnd\";\n  MouseInteractions2[MouseInteractions2[\"TouchCancel\"] = 10] = \"TouchCancel\";\n  return MouseInteractions2;\n})(MouseInteractions || {});\nvar PointerTypes = /* @__PURE__ */ ((PointerTypes2) => {\n  PointerTypes2[PointerTypes2[\"Mouse\"] = 0] = \"Mouse\";\n  PointerTypes2[PointerTypes2[\"Pen\"] = 1] = \"Pen\";\n  PointerTypes2[PointerTypes2[\"Touch\"] = 2] = \"Touch\";\n  return PointerTypes2;\n})(PointerTypes || {});\nvar CanvasContext = /* @__PURE__ */ ((CanvasContext2) => {\n  CanvasContext2[CanvasContext2[\"2D\"] = 0] = \"2D\";\n  CanvasContext2[CanvasContext2[\"WebGL\"] = 1] = \"WebGL\";\n  CanvasContext2[CanvasContext2[\"WebGL2\"] = 2] = \"WebGL2\";\n  return CanvasContext2;\n})(CanvasContext || {});\nvar MediaInteractions = /* @__PURE__ */ ((MediaInteractions2) => {\n  MediaInteractions2[MediaInteractions2[\"Play\"] = 0] = \"Play\";\n  MediaInteractions2[MediaInteractions2[\"Pause\"] = 1] = \"Pause\";\n  MediaInteractions2[MediaInteractions2[\"Seeked\"] = 2] = \"Seeked\";\n  MediaInteractions2[MediaInteractions2[\"VolumeChange\"] = 3] = \"VolumeChange\";\n  MediaInteractions2[MediaInteractions2[\"RateChange\"] = 4] = \"RateChange\";\n  return MediaInteractions2;\n})(MediaInteractions || {});\nvar NodeType = /* @__PURE__ */ ((NodeType2) => {\n  NodeType2[NodeType2[\"Document\"] = 0] = \"Document\";\n  NodeType2[NodeType2[\"DocumentType\"] = 1] = \"DocumentType\";\n  NodeType2[NodeType2[\"Element\"] = 2] = \"Element\";\n  NodeType2[NodeType2[\"Text\"] = 3] = \"Text\";\n  NodeType2[NodeType2[\"CDATA\"] = 4] = \"CDATA\";\n  NodeType2[NodeType2[\"Comment\"] = 5] = \"Comment\";\n  return NodeType2;\n})(NodeType || {});\nfunction isNodeInLinkedList(n2) {\n  return \"__ln\" in n2;\n}\nclass DoubleLinkedList {\n  constructor() {\n    __publicField(this, \"length\", 0);\n    __publicField(this, \"head\", null);\n    __publicField(this, \"tail\", null);\n  }\n  get(position) {\n    if (position >= this.length) {\n      throw new Error(\"Position outside of list range\");\n    }\n    let current = this.head;\n    for (let index2 = 0; index2 < position; index2++) {\n      current = (current == null ? void 0 : current.next) || null;\n    }\n    return current;\n  }\n  addNode(n2) {\n    const node2 = {\n      value: n2,\n      previous: null,\n      next: null\n    };\n    n2.__ln = node2;\n    if (n2.previousSibling && isNodeInLinkedList(n2.previousSibling)) {\n      const current = n2.previousSibling.__ln.next;\n      node2.next = current;\n      node2.previous = n2.previousSibling.__ln;\n      n2.previousSibling.__ln.next = node2;\n      if (current) {\n        current.previous = node2;\n      }\n    } else if (n2.nextSibling && isNodeInLinkedList(n2.nextSibling) && n2.nextSibling.__ln.previous) {\n      const current = n2.nextSibling.__ln.previous;\n      node2.previous = current;\n      node2.next = n2.nextSibling.__ln;\n      n2.nextSibling.__ln.previous = node2;\n      if (current) {\n        current.next = node2;\n      }\n    } else {\n      if (this.head) {\n        this.head.previous = node2;\n      }\n      node2.next = this.head;\n      this.head = node2;\n    }\n    if (node2.next === null) {\n      this.tail = node2;\n    }\n    this.length++;\n  }\n  removeNode(n2) {\n    const current = n2.__ln;\n    if (!this.head) {\n      return;\n    }\n    if (!current.previous) {\n      this.head = current.next;\n      if (this.head) {\n        this.head.previous = null;\n      } else {\n        this.tail = null;\n      }\n    } else {\n      current.previous.next = current.next;\n      if (current.next) {\n        current.next.previous = current.previous;\n      } else {\n        this.tail = current.previous;\n      }\n    }\n    if (n2.__ln) {\n      delete n2.__ln;\n    }\n    this.length--;\n  }\n}\nconst moveKey = (id, parentId) => `${id}@${parentId}`;\nclass MutationBuffer {\n  constructor() {\n    __publicField(this, \"frozen\", false);\n    __publicField(this, \"locked\", false);\n    __publicField(this, \"texts\", []);\n    __publicField(this, \"attributes\", []);\n    __publicField(this, \"attributeMap\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"removes\", []);\n    __publicField(this, \"mapRemoves\", []);\n    __publicField(this, \"movedMap\", {});\n    __publicField(this, \"addedSet\", /* @__PURE__ */ new Set());\n    __publicField(this, \"movedSet\", /* @__PURE__ */ new Set());\n    __publicField(this, \"droppedSet\", /* @__PURE__ */ new Set());\n    __publicField(this, \"removesSubTreeCache\", /* @__PURE__ */ new Set());\n    __publicField(this, \"mutationCb\");\n    __publicField(this, \"blockClass\");\n    __publicField(this, \"blockSelector\");\n    __publicField(this, \"maskTextClass\");\n    __publicField(this, \"maskTextSelector\");\n    __publicField(this, \"inlineStylesheet\");\n    __publicField(this, \"maskInputOptions\");\n    __publicField(this, \"maskTextFn\");\n    __publicField(this, \"maskInputFn\");\n    __publicField(this, \"keepIframeSrcFn\");\n    __publicField(this, \"recordCanvas\");\n    __publicField(this, \"inlineImages\");\n    __publicField(this, \"slimDOMOptions\");\n    __publicField(this, \"dataURLOptions\");\n    __publicField(this, \"doc\");\n    __publicField(this, \"mirror\");\n    __publicField(this, \"iframeManager\");\n    __publicField(this, \"stylesheetManager\");\n    __publicField(this, \"shadowDomManager\");\n    __publicField(this, \"canvasManager\");\n    __publicField(this, \"processedNodeManager\");\n    __publicField(this, \"unattachedDoc\");\n    __publicField(this, \"processMutations\", (mutations) => {\n      mutations.forEach(this.processMutation);\n      this.emit();\n    });\n    __publicField(this, \"emit\", () => {\n      if (this.frozen || this.locked) {\n        return;\n      }\n      const adds = [];\n      const addedIds = /* @__PURE__ */ new Set();\n      const addList = new DoubleLinkedList();\n      const getNextId = (n2) => {\n        let ns = n2;\n        let nextId = IGNORED_NODE;\n        while (nextId === IGNORED_NODE) {\n          ns = ns && ns.nextSibling;\n          nextId = ns && this.mirror.getId(ns);\n        }\n        return nextId;\n      };\n      const pushAdd = (n2) => {\n        const parent = index.parentNode(n2);\n        if (!parent || !inDom(n2)) {\n          return;\n        }\n        let cssCaptured = false;\n        if (n2.nodeType === Node.TEXT_NODE) {\n          const parentTag = parent.tagName;\n          if (parentTag === \"TEXTAREA\") {\n            return;\n          } else if (parentTag === \"STYLE\" && this.addedSet.has(parent)) {\n            cssCaptured = true;\n          }\n        }\n        const parentId = isShadowRoot(parent) ? this.mirror.getId(getShadowHost(n2)) : this.mirror.getId(parent);\n        const nextId = getNextId(n2);\n        if (parentId === -1 || nextId === -1) {\n          return addList.addNode(n2);\n        }\n        const sn = serializeNodeWithId(n2, {\n          doc: this.doc,\n          mirror: this.mirror,\n          blockClass: this.blockClass,\n          blockSelector: this.blockSelector,\n          maskTextClass: this.maskTextClass,\n          maskTextSelector: this.maskTextSelector,\n          skipChild: true,\n          newlyAddedElement: true,\n          inlineStylesheet: this.inlineStylesheet,\n          maskInputOptions: this.maskInputOptions,\n          maskTextFn: this.maskTextFn,\n          maskInputFn: this.maskInputFn,\n          slimDOMOptions: this.slimDOMOptions,\n          dataURLOptions: this.dataURLOptions,\n          recordCanvas: this.recordCanvas,\n          inlineImages: this.inlineImages,\n          onSerialize: (currentN) => {\n            if (isSerializedIframe(currentN, this.mirror)) {\n              this.iframeManager.addIframe(currentN);\n            }\n            if (isSerializedStylesheet(currentN, this.mirror)) {\n              this.stylesheetManager.trackLinkElement(\n                currentN\n              );\n            }\n            if (hasShadowRoot(n2)) {\n              this.shadowDomManager.addShadowRoot(index.shadowRoot(n2), this.doc);\n            }\n          },\n          onIframeLoad: (iframe, childSn) => {\n            this.iframeManager.attachIframe(iframe, childSn);\n            this.shadowDomManager.observeAttachShadow(iframe);\n          },\n          onStylesheetLoad: (link, childSn) => {\n            this.stylesheetManager.attachLinkElement(link, childSn);\n          },\n          cssCaptured\n        });\n        if (sn) {\n          adds.push({\n            parentId,\n            nextId,\n            node: sn\n          });\n          addedIds.add(sn.id);\n        }\n      };\n      while (this.mapRemoves.length) {\n        this.mirror.removeNodeFromMap(this.mapRemoves.shift());\n      }\n      for (const n2 of this.movedSet) {\n        if (isParentRemoved(this.removesSubTreeCache, n2, this.mirror) && !this.movedSet.has(index.parentNode(n2))) {\n          continue;\n        }\n        pushAdd(n2);\n      }\n      for (const n2 of this.addedSet) {\n        if (!isAncestorInSet(this.droppedSet, n2) && !isParentRemoved(this.removesSubTreeCache, n2, this.mirror)) {\n          pushAdd(n2);\n        } else if (isAncestorInSet(this.movedSet, n2)) {\n          pushAdd(n2);\n        } else {\n          this.droppedSet.add(n2);\n        }\n      }\n      let candidate = null;\n      while (addList.length) {\n        let node2 = null;\n        if (candidate) {\n          const parentId = this.mirror.getId(index.parentNode(candidate.value));\n          const nextId = getNextId(candidate.value);\n          if (parentId !== -1 && nextId !== -1) {\n            node2 = candidate;\n          }\n        }\n        if (!node2) {\n          let tailNode = addList.tail;\n          while (tailNode) {\n            const _node = tailNode;\n            tailNode = tailNode.previous;\n            if (_node) {\n              const parentId = this.mirror.getId(index.parentNode(_node.value));\n              const nextId = getNextId(_node.value);\n              if (nextId === -1) continue;\n              else if (parentId !== -1) {\n                node2 = _node;\n                break;\n              } else {\n                const unhandledNode = _node.value;\n                const parent = index.parentNode(unhandledNode);\n                if (parent && parent.nodeType === Node.DOCUMENT_FRAGMENT_NODE) {\n                  const shadowHost = index.host(parent);\n                  const parentId2 = this.mirror.getId(shadowHost);\n                  if (parentId2 !== -1) {\n                    node2 = _node;\n                    break;\n                  }\n                }\n              }\n            }\n          }\n        }\n        if (!node2) {\n          while (addList.head) {\n            addList.removeNode(addList.head.value);\n          }\n          break;\n        }\n        candidate = node2.previous;\n        addList.removeNode(node2.value);\n        pushAdd(node2.value);\n      }\n      const payload = {\n        texts: this.texts.map((text) => {\n          const n2 = text.node;\n          const parent = index.parentNode(n2);\n          if (parent && parent.tagName === \"TEXTAREA\") {\n            this.genTextAreaValueMutation(parent);\n          }\n          return {\n            id: this.mirror.getId(n2),\n            value: text.value\n          };\n        }).filter((text) => !addedIds.has(text.id)).filter((text) => this.mirror.has(text.id)),\n        attributes: this.attributes.map((attribute) => {\n          const { attributes } = attribute;\n          if (typeof attributes.style === \"string\") {\n            const diffAsStr = JSON.stringify(attribute.styleDiff);\n            const unchangedAsStr = JSON.stringify(attribute._unchangedStyles);\n            if (diffAsStr.length < attributes.style.length) {\n              if ((diffAsStr + unchangedAsStr).split(\"var(\").length === attributes.style.split(\"var(\").length) {\n                attributes.style = attribute.styleDiff;\n              }\n            }\n          }\n          return {\n            id: this.mirror.getId(attribute.node),\n            attributes\n          };\n        }).filter((attribute) => !addedIds.has(attribute.id)).filter((attribute) => this.mirror.has(attribute.id)),\n        removes: this.removes,\n        adds\n      };\n      if (!payload.texts.length && !payload.attributes.length && !payload.removes.length && !payload.adds.length) {\n        return;\n      }\n      this.texts = [];\n      this.attributes = [];\n      this.attributeMap = /* @__PURE__ */ new WeakMap();\n      this.removes = [];\n      this.addedSet = /* @__PURE__ */ new Set();\n      this.movedSet = /* @__PURE__ */ new Set();\n      this.droppedSet = /* @__PURE__ */ new Set();\n      this.removesSubTreeCache = /* @__PURE__ */ new Set();\n      this.movedMap = {};\n      this.mutationCb(payload);\n    });\n    __publicField(this, \"genTextAreaValueMutation\", (textarea) => {\n      let item = this.attributeMap.get(textarea);\n      if (!item) {\n        item = {\n          node: textarea,\n          attributes: {},\n          styleDiff: {},\n          _unchangedStyles: {}\n        };\n        this.attributes.push(item);\n        this.attributeMap.set(textarea, item);\n      }\n      const value = Array.from(\n        index.childNodes(textarea),\n        (cn) => index.textContent(cn) || \"\"\n      ).join(\"\");\n      item.attributes.value = maskInputValue({\n        element: textarea,\n        maskInputOptions: this.maskInputOptions,\n        tagName: textarea.tagName,\n        type: getInputType(textarea),\n        value,\n        maskInputFn: this.maskInputFn\n      });\n    });\n    __publicField(this, \"processMutation\", (m) => {\n      if (isIgnored(m.target, this.mirror, this.slimDOMOptions)) {\n        return;\n      }\n      switch (m.type) {\n        case \"characterData\": {\n          const value = index.textContent(m.target);\n          if (!isBlocked(m.target, this.blockClass, this.blockSelector, false) && value !== m.oldValue) {\n            this.texts.push({\n              value: needMaskingText(\n                m.target,\n                this.maskTextClass,\n                this.maskTextSelector,\n                true\n                // checkAncestors\n              ) && value ? this.maskTextFn ? this.maskTextFn(value, closestElementOfNode(m.target)) : value.replace(/[\\S]/g, \"*\") : value,\n              node: m.target\n            });\n          }\n          break;\n        }\n        case \"attributes\": {\n          const target = m.target;\n          let attributeName = m.attributeName;\n          let value = m.target.getAttribute(attributeName);\n          if (attributeName === \"value\") {\n            const type = getInputType(target);\n            value = maskInputValue({\n              element: target,\n              maskInputOptions: this.maskInputOptions,\n              tagName: target.tagName,\n              type,\n              value,\n              maskInputFn: this.maskInputFn\n            });\n          }\n          if (isBlocked(m.target, this.blockClass, this.blockSelector, false) || value === m.oldValue) {\n            return;\n          }\n          let item = this.attributeMap.get(m.target);\n          if (target.tagName === \"IFRAME\" && attributeName === \"src\" && !this.keepIframeSrcFn(value)) {\n            if (!target.contentDocument) {\n              attributeName = \"rr_src\";\n            } else {\n              return;\n            }\n          }\n          if (!item) {\n            item = {\n              node: m.target,\n              attributes: {},\n              styleDiff: {},\n              _unchangedStyles: {}\n            };\n            this.attributes.push(item);\n            this.attributeMap.set(m.target, item);\n          }\n          if (attributeName === \"type\" && target.tagName === \"INPUT\" && (m.oldValue || \"\").toLowerCase() === \"password\") {\n            target.setAttribute(\"data-rr-is-password\", \"true\");\n          }\n          if (!ignoreAttribute(target.tagName, attributeName)) {\n            item.attributes[attributeName] = transformAttribute(\n              this.doc,\n              toLowerCase(target.tagName),\n              toLowerCase(attributeName),\n              value\n            );\n            if (attributeName === \"style\") {\n              if (!this.unattachedDoc) {\n                try {\n                  this.unattachedDoc = document.implementation.createHTMLDocument();\n                } catch (e2) {\n                  this.unattachedDoc = this.doc;\n                }\n              }\n              const old = this.unattachedDoc.createElement(\"span\");\n              if (m.oldValue) {\n                old.setAttribute(\"style\", m.oldValue);\n              }\n              for (const pname of Array.from(target.style)) {\n                const newValue = target.style.getPropertyValue(pname);\n                const newPriority = target.style.getPropertyPriority(pname);\n                if (newValue !== old.style.getPropertyValue(pname) || newPriority !== old.style.getPropertyPriority(pname)) {\n                  if (newPriority === \"\") {\n                    item.styleDiff[pname] = newValue;\n                  } else {\n                    item.styleDiff[pname] = [newValue, newPriority];\n                  }\n                } else {\n                  item._unchangedStyles[pname] = [newValue, newPriority];\n                }\n              }\n              for (const pname of Array.from(old.style)) {\n                if (target.style.getPropertyValue(pname) === \"\") {\n                  item.styleDiff[pname] = false;\n                }\n              }\n            } else if (attributeName === \"open\" && target.tagName === \"DIALOG\") {\n              if (target.matches(\"dialog:modal\")) {\n                item.attributes[\"rr_open_mode\"] = \"modal\";\n              } else {\n                item.attributes[\"rr_open_mode\"] = \"non-modal\";\n              }\n            }\n          }\n          break;\n        }\n        case \"childList\": {\n          if (isBlocked(m.target, this.blockClass, this.blockSelector, true))\n            return;\n          if (m.target.tagName === \"TEXTAREA\") {\n            this.genTextAreaValueMutation(m.target);\n            return;\n          }\n          m.addedNodes.forEach((n2) => this.genAdds(n2, m.target));\n          m.removedNodes.forEach((n2) => {\n            const nodeId = this.mirror.getId(n2);\n            const parentId = isShadowRoot(m.target) ? this.mirror.getId(index.host(m.target)) : this.mirror.getId(m.target);\n            if (isBlocked(m.target, this.blockClass, this.blockSelector, false) || isIgnored(n2, this.mirror, this.slimDOMOptions) || !isSerialized(n2, this.mirror)) {\n              return;\n            }\n            if (this.addedSet.has(n2)) {\n              deepDelete(this.addedSet, n2);\n              this.droppedSet.add(n2);\n            } else if (this.addedSet.has(m.target) && nodeId === -1) ;\n            else if (isAncestorRemoved(m.target, this.mirror)) ;\n            else if (this.movedSet.has(n2) && this.movedMap[moveKey(nodeId, parentId)]) {\n              deepDelete(this.movedSet, n2);\n            } else {\n              this.removes.push({\n                parentId,\n                id: nodeId,\n                isShadow: isShadowRoot(m.target) && isNativeShadowDom(m.target) ? true : void 0\n              });\n              processRemoves(n2, this.removesSubTreeCache);\n            }\n            this.mapRemoves.push(n2);\n          });\n          break;\n        }\n      }\n    });\n    __publicField(this, \"genAdds\", (n2, target) => {\n      if (this.processedNodeManager.inOtherBuffer(n2, this)) return;\n      if (this.addedSet.has(n2) || this.movedSet.has(n2)) return;\n      if (this.mirror.hasNode(n2)) {\n        if (isIgnored(n2, this.mirror, this.slimDOMOptions)) {\n          return;\n        }\n        this.movedSet.add(n2);\n        let targetId = null;\n        if (target && this.mirror.hasNode(target)) {\n          targetId = this.mirror.getId(target);\n        }\n        if (targetId && targetId !== -1) {\n          this.movedMap[moveKey(this.mirror.getId(n2), targetId)] = true;\n        }\n      } else {\n        this.addedSet.add(n2);\n        this.droppedSet.delete(n2);\n      }\n      if (!isBlocked(n2, this.blockClass, this.blockSelector, false)) {\n        index.childNodes(n2).forEach((childN) => this.genAdds(childN));\n        if (hasShadowRoot(n2)) {\n          index.childNodes(index.shadowRoot(n2)).forEach((childN) => {\n            this.processedNodeManager.add(childN, this);\n            this.genAdds(childN, n2);\n          });\n        }\n      }\n    });\n  }\n  init(options) {\n    [\n      \"mutationCb\",\n      \"blockClass\",\n      \"blockSelector\",\n      \"maskTextClass\",\n      \"maskTextSelector\",\n      \"inlineStylesheet\",\n      \"maskInputOptions\",\n      \"maskTextFn\",\n      \"maskInputFn\",\n      \"keepIframeSrcFn\",\n      \"recordCanvas\",\n      \"inlineImages\",\n      \"slimDOMOptions\",\n      \"dataURLOptions\",\n      \"doc\",\n      \"mirror\",\n      \"iframeManager\",\n      \"stylesheetManager\",\n      \"shadowDomManager\",\n      \"canvasManager\",\n      \"processedNodeManager\"\n    ].forEach((key) => {\n      this[key] = options[key];\n    });\n  }\n  freeze() {\n    this.frozen = true;\n    this.canvasManager.freeze();\n  }\n  unfreeze() {\n    this.frozen = false;\n    this.canvasManager.unfreeze();\n    this.emit();\n  }\n  isFrozen() {\n    return this.frozen;\n  }\n  lock() {\n    this.locked = true;\n    this.canvasManager.lock();\n  }\n  unlock() {\n    this.locked = false;\n    this.canvasManager.unlock();\n    this.emit();\n  }\n  reset() {\n    this.shadowDomManager.reset();\n    this.canvasManager.reset();\n  }\n}\nfunction deepDelete(addsSet, n2) {\n  addsSet.delete(n2);\n  index.childNodes(n2).forEach((childN) => deepDelete(addsSet, childN));\n}\nfunction processRemoves(n2, cache) {\n  const queue = [n2];\n  while (queue.length) {\n    const next = queue.pop();\n    if (cache.has(next)) continue;\n    cache.add(next);\n    index.childNodes(next).forEach((n22) => queue.push(n22));\n  }\n  return;\n}\nfunction isParentRemoved(removes, n2, mirror2) {\n  if (removes.size === 0) return false;\n  return _isParentRemoved(removes, n2);\n}\nfunction _isParentRemoved(removes, n2, _mirror2) {\n  const node2 = index.parentNode(n2);\n  if (!node2) return false;\n  return removes.has(node2);\n}\nfunction isAncestorInSet(set, n2) {\n  if (set.size === 0) return false;\n  return _isAncestorInSet(set, n2);\n}\nfunction _isAncestorInSet(set, n2) {\n  const parent = index.parentNode(n2);\n  if (!parent) {\n    return false;\n  }\n  if (set.has(parent)) {\n    return true;\n  }\n  return _isAncestorInSet(set, parent);\n}\nlet errorHandler;\nfunction registerErrorHandler(handler) {\n  errorHandler = handler;\n}\nfunction unregisterErrorHandler() {\n  errorHandler = void 0;\n}\nconst callbackWrapper = (cb) => {\n  if (!errorHandler) {\n    return cb;\n  }\n  const rrwebWrapped = (...rest) => {\n    try {\n      return cb(...rest);\n    } catch (error) {\n      if (errorHandler && errorHandler(error) === true) {\n        return;\n      }\n      throw error;\n    }\n  };\n  return rrwebWrapped;\n};\nconst mutationBuffers = [];\nfunction getEventTarget(event) {\n  try {\n    if (\"composedPath\" in event) {\n      const path = event.composedPath();\n      if (path.length) {\n        return path[0];\n      }\n    } else if (\"path\" in event && event.path.length) {\n      return event.path[0];\n    }\n  } catch {\n  }\n  return event && event.target;\n}\nfunction initMutationObserver(options, rootEl) {\n  const mutationBuffer = new MutationBuffer();\n  mutationBuffers.push(mutationBuffer);\n  mutationBuffer.init(options);\n  const observer = new (mutationObserverCtor())(\n    callbackWrapper(mutationBuffer.processMutations.bind(mutationBuffer))\n  );\n  observer.observe(rootEl, {\n    attributes: true,\n    attributeOldValue: true,\n    characterData: true,\n    characterDataOldValue: true,\n    childList: true,\n    subtree: true\n  });\n  return observer;\n}\nfunction initMoveObserver({\n  mousemoveCb,\n  sampling,\n  doc,\n  mirror: mirror2\n}) {\n  if (sampling.mousemove === false) {\n    return () => {\n    };\n  }\n  const threshold = typeof sampling.mousemove === \"number\" ? sampling.mousemove : 50;\n  const callbackThreshold = typeof sampling.mousemoveCallback === \"number\" ? sampling.mousemoveCallback : 500;\n  let positions = [];\n  let timeBaseline;\n  const wrappedCb = throttle(\n    callbackWrapper(\n      (source) => {\n        const totalOffset = Date.now() - timeBaseline;\n        mousemoveCb(\n          positions.map((p) => {\n            p.timeOffset -= totalOffset;\n            return p;\n          }),\n          source\n        );\n        positions = [];\n        timeBaseline = null;\n      }\n    ),\n    callbackThreshold\n  );\n  const updatePosition = callbackWrapper(\n    throttle(\n      callbackWrapper((evt) => {\n        const target = getEventTarget(evt);\n        const { clientX, clientY } = legacy_isTouchEvent(evt) ? evt.changedTouches[0] : evt;\n        if (!timeBaseline) {\n          timeBaseline = nowTimestamp();\n        }\n        positions.push({\n          x: clientX,\n          y: clientY,\n          id: mirror2.getId(target),\n          timeOffset: nowTimestamp() - timeBaseline\n        });\n        wrappedCb(\n          typeof DragEvent !== \"undefined\" && evt instanceof DragEvent ? IncrementalSource.Drag : evt instanceof MouseEvent ? IncrementalSource.MouseMove : IncrementalSource.TouchMove\n        );\n      }),\n      threshold,\n      {\n        trailing: false\n      }\n    )\n  );\n  const handlers = [\n    on(\"mousemove\", updatePosition, doc),\n    on(\"touchmove\", updatePosition, doc),\n    on(\"drag\", updatePosition, doc)\n  ];\n  return callbackWrapper(() => {\n    handlers.forEach((h) => h());\n  });\n}\nfunction initMouseInteractionObserver({\n  mouseInteractionCb,\n  doc,\n  mirror: mirror2,\n  blockClass,\n  blockSelector,\n  sampling\n}) {\n  if (sampling.mouseInteraction === false) {\n    return () => {\n    };\n  }\n  const disableMap = sampling.mouseInteraction === true || sampling.mouseInteraction === void 0 ? {} : sampling.mouseInteraction;\n  const handlers = [];\n  let currentPointerType = null;\n  const getHandler = (eventKey) => {\n    return (event) => {\n      const target = getEventTarget(event);\n      if (isBlocked(target, blockClass, blockSelector, true)) {\n        return;\n      }\n      let pointerType = null;\n      let thisEventKey = eventKey;\n      if (\"pointerType\" in event) {\n        switch (event.pointerType) {\n          case \"mouse\":\n            pointerType = PointerTypes.Mouse;\n            break;\n          case \"touch\":\n            pointerType = PointerTypes.Touch;\n            break;\n          case \"pen\":\n            pointerType = PointerTypes.Pen;\n            break;\n        }\n        if (pointerType === PointerTypes.Touch) {\n          if (MouseInteractions[eventKey] === MouseInteractions.MouseDown) {\n            thisEventKey = \"TouchStart\";\n          } else if (MouseInteractions[eventKey] === MouseInteractions.MouseUp) {\n            thisEventKey = \"TouchEnd\";\n          }\n        } else if (pointerType === PointerTypes.Pen) ;\n      } else if (legacy_isTouchEvent(event)) {\n        pointerType = PointerTypes.Touch;\n      }\n      if (pointerType !== null) {\n        currentPointerType = pointerType;\n        if (thisEventKey.startsWith(\"Touch\") && pointerType === PointerTypes.Touch || thisEventKey.startsWith(\"Mouse\") && pointerType === PointerTypes.Mouse) {\n          pointerType = null;\n        }\n      } else if (MouseInteractions[eventKey] === MouseInteractions.Click) {\n        pointerType = currentPointerType;\n        currentPointerType = null;\n      }\n      const e2 = legacy_isTouchEvent(event) ? event.changedTouches[0] : event;\n      if (!e2) {\n        return;\n      }\n      const id = mirror2.getId(target);\n      const { clientX, clientY } = e2;\n      callbackWrapper(mouseInteractionCb)({\n        type: MouseInteractions[thisEventKey],\n        id,\n        x: clientX,\n        y: clientY,\n        ...pointerType !== null && { pointerType }\n      });\n    };\n  };\n  Object.keys(MouseInteractions).filter(\n    (key) => Number.isNaN(Number(key)) && !key.endsWith(\"_Departed\") && disableMap[key] !== false\n  ).forEach((eventKey) => {\n    let eventName = toLowerCase(eventKey);\n    const handler = getHandler(eventKey);\n    if (window.PointerEvent) {\n      switch (MouseInteractions[eventKey]) {\n        case MouseInteractions.MouseDown:\n        case MouseInteractions.MouseUp:\n          eventName = eventName.replace(\n            \"mouse\",\n            \"pointer\"\n          );\n          break;\n        case MouseInteractions.TouchStart:\n        case MouseInteractions.TouchEnd:\n          return;\n      }\n    }\n    handlers.push(on(eventName, handler, doc));\n  });\n  return callbackWrapper(() => {\n    handlers.forEach((h) => h());\n  });\n}\nfunction initScrollObserver({\n  scrollCb,\n  doc,\n  mirror: mirror2,\n  blockClass,\n  blockSelector,\n  sampling\n}) {\n  const updatePosition = callbackWrapper(\n    throttle(\n      callbackWrapper((evt) => {\n        const target = getEventTarget(evt);\n        if (!target || isBlocked(target, blockClass, blockSelector, true)) {\n          return;\n        }\n        const id = mirror2.getId(target);\n        if (target === doc && doc.defaultView) {\n          const scrollLeftTop = getWindowScroll(doc.defaultView);\n          scrollCb({\n            id,\n            x: scrollLeftTop.left,\n            y: scrollLeftTop.top\n          });\n        } else {\n          scrollCb({\n            id,\n            x: target.scrollLeft,\n            y: target.scrollTop\n          });\n        }\n      }),\n      sampling.scroll || 100\n    )\n  );\n  return on(\"scroll\", updatePosition, doc);\n}\nfunction initViewportResizeObserver({ viewportResizeCb }, { win }) {\n  let lastH = -1;\n  let lastW = -1;\n  const updateDimension = callbackWrapper(\n    throttle(\n      callbackWrapper(() => {\n        const height = getWindowHeight();\n        const width = getWindowWidth();\n        if (lastH !== height || lastW !== width) {\n          viewportResizeCb({\n            width: Number(width),\n            height: Number(height)\n          });\n          lastH = height;\n          lastW = width;\n        }\n      }),\n      200\n    )\n  );\n  return on(\"resize\", updateDimension, win);\n}\nconst INPUT_TAGS = [\"INPUT\", \"TEXTAREA\", \"SELECT\"];\nconst lastInputValueMap = /* @__PURE__ */ new WeakMap();\nfunction initInputObserver({\n  inputCb,\n  doc,\n  mirror: mirror2,\n  blockClass,\n  blockSelector,\n  ignoreClass,\n  ignoreSelector,\n  maskInputOptions,\n  maskInputFn,\n  sampling,\n  userTriggeredOnInput\n}) {\n  function eventHandler(event) {\n    let target = getEventTarget(event);\n    const userTriggered = event.isTrusted;\n    const tagName = target && target.tagName;\n    if (target && tagName === \"OPTION\") {\n      target = index.parentElement(target);\n    }\n    if (!target || !tagName || INPUT_TAGS.indexOf(tagName) < 0 || isBlocked(target, blockClass, blockSelector, true)) {\n      return;\n    }\n    if (target.classList.contains(ignoreClass) || ignoreSelector && target.matches(ignoreSelector)) {\n      return;\n    }\n    let text = target.value;\n    let isChecked = false;\n    const type = getInputType(target) || \"\";\n    if (type === \"radio\" || type === \"checkbox\") {\n      isChecked = target.checked;\n    } else if (maskInputOptions[tagName.toLowerCase()] || maskInputOptions[type]) {\n      text = maskInputValue({\n        element: target,\n        maskInputOptions,\n        tagName,\n        type,\n        value: text,\n        maskInputFn\n      });\n    }\n    cbWithDedup(\n      target,\n      userTriggeredOnInput ? { text, isChecked, userTriggered } : { text, isChecked }\n    );\n    const name = target.name;\n    if (type === \"radio\" && name && isChecked) {\n      doc.querySelectorAll(`input[type=\"radio\"][name=\"${name}\"]`).forEach((el) => {\n        if (el !== target) {\n          const text2 = el.value;\n          cbWithDedup(\n            el,\n            userTriggeredOnInput ? { text: text2, isChecked: !isChecked, userTriggered: false } : { text: text2, isChecked: !isChecked }\n          );\n        }\n      });\n    }\n  }\n  function cbWithDedup(target, v2) {\n    const lastInputValue = lastInputValueMap.get(target);\n    if (!lastInputValue || lastInputValue.text !== v2.text || lastInputValue.isChecked !== v2.isChecked) {\n      lastInputValueMap.set(target, v2);\n      const id = mirror2.getId(target);\n      callbackWrapper(inputCb)({\n        ...v2,\n        id\n      });\n    }\n  }\n  const events = sampling.input === \"last\" ? [\"change\"] : [\"input\", \"change\"];\n  const handlers = events.map(\n    (eventName) => on(eventName, callbackWrapper(eventHandler), doc)\n  );\n  const currentWindow = doc.defaultView;\n  if (!currentWindow) {\n    return () => {\n      handlers.forEach((h) => h());\n    };\n  }\n  const propertyDescriptor = currentWindow.Object.getOwnPropertyDescriptor(\n    currentWindow.HTMLInputElement.prototype,\n    \"value\"\n  );\n  const hookProperties = [\n    [currentWindow.HTMLInputElement.prototype, \"value\"],\n    [currentWindow.HTMLInputElement.prototype, \"checked\"],\n    [currentWindow.HTMLSelectElement.prototype, \"value\"],\n    [currentWindow.HTMLTextAreaElement.prototype, \"value\"],\n    // Some UI library use selectedIndex to set select value\n    [currentWindow.HTMLSelectElement.prototype, \"selectedIndex\"],\n    [currentWindow.HTMLOptionElement.prototype, \"selected\"]\n  ];\n  if (propertyDescriptor && propertyDescriptor.set) {\n    handlers.push(\n      ...hookProperties.map(\n        (p) => hookSetter(\n          p[0],\n          p[1],\n          {\n            set() {\n              callbackWrapper(eventHandler)({\n                target: this,\n                isTrusted: false\n                // userTriggered to false as this could well be programmatic\n              });\n            }\n          },\n          false,\n          currentWindow\n        )\n      )\n    );\n  }\n  return callbackWrapper(() => {\n    handlers.forEach((h) => h());\n  });\n}\nfunction getNestedCSSRulePositions(rule2) {\n  const positions = [];\n  function recurse(childRule, pos) {\n    if (hasNestedCSSRule(\"CSSGroupingRule\") && childRule.parentRule instanceof CSSGroupingRule || hasNestedCSSRule(\"CSSMediaRule\") && childRule.parentRule instanceof CSSMediaRule || hasNestedCSSRule(\"CSSSupportsRule\") && childRule.parentRule instanceof CSSSupportsRule || hasNestedCSSRule(\"CSSConditionRule\") && childRule.parentRule instanceof CSSConditionRule) {\n      const rules2 = Array.from(\n        childRule.parentRule.cssRules\n      );\n      const index2 = rules2.indexOf(childRule);\n      pos.unshift(index2);\n    } else if (childRule.parentStyleSheet) {\n      const rules2 = Array.from(childRule.parentStyleSheet.cssRules);\n      const index2 = rules2.indexOf(childRule);\n      pos.unshift(index2);\n    }\n    return pos;\n  }\n  return recurse(rule2, positions);\n}\nfunction getIdAndStyleId(sheet, mirror2, styleMirror) {\n  let id, styleId;\n  if (!sheet) return {};\n  if (sheet.ownerNode) id = mirror2.getId(sheet.ownerNode);\n  else styleId = styleMirror.getId(sheet);\n  return {\n    styleId,\n    id\n  };\n}\nfunction initStyleSheetObserver({ styleSheetRuleCb, mirror: mirror2, stylesheetManager }, { win }) {\n  if (!win.CSSStyleSheet || !win.CSSStyleSheet.prototype) {\n    return () => {\n    };\n  }\n  const insertRule = win.CSSStyleSheet.prototype.insertRule;\n  win.CSSStyleSheet.prototype.insertRule = new Proxy(insertRule, {\n    apply: callbackWrapper(\n      (target, thisArg, argumentsList) => {\n        const [rule2, index2] = argumentsList;\n        const { id, styleId } = getIdAndStyleId(\n          thisArg,\n          mirror2,\n          stylesheetManager.styleMirror\n        );\n        if (id && id !== -1 || styleId && styleId !== -1) {\n          styleSheetRuleCb({\n            id,\n            styleId,\n            adds: [{ rule: rule2, index: index2 }]\n          });\n        }\n        return target.apply(thisArg, argumentsList);\n      }\n    )\n  });\n  win.CSSStyleSheet.prototype.addRule = function(selector, styleBlock, index2 = this.cssRules.length) {\n    const rule2 = `${selector} { ${styleBlock} }`;\n    return win.CSSStyleSheet.prototype.insertRule.apply(this, [rule2, index2]);\n  };\n  const deleteRule = win.CSSStyleSheet.prototype.deleteRule;\n  win.CSSStyleSheet.prototype.deleteRule = new Proxy(deleteRule, {\n    apply: callbackWrapper(\n      (target, thisArg, argumentsList) => {\n        const [index2] = argumentsList;\n        const { id, styleId } = getIdAndStyleId(\n          thisArg,\n          mirror2,\n          stylesheetManager.styleMirror\n        );\n        if (id && id !== -1 || styleId && styleId !== -1) {\n          styleSheetRuleCb({\n            id,\n            styleId,\n            removes: [{ index: index2 }]\n          });\n        }\n        return target.apply(thisArg, argumentsList);\n      }\n    )\n  });\n  win.CSSStyleSheet.prototype.removeRule = function(index2) {\n    return win.CSSStyleSheet.prototype.deleteRule.apply(this, [index2]);\n  };\n  let replace;\n  if (win.CSSStyleSheet.prototype.replace) {\n    replace = win.CSSStyleSheet.prototype.replace;\n    win.CSSStyleSheet.prototype.replace = new Proxy(replace, {\n      apply: callbackWrapper(\n        (target, thisArg, argumentsList) => {\n          const [text] = argumentsList;\n          const { id, styleId } = getIdAndStyleId(\n            thisArg,\n            mirror2,\n            stylesheetManager.styleMirror\n          );\n          if (id && id !== -1 || styleId && styleId !== -1) {\n            styleSheetRuleCb({\n              id,\n              styleId,\n              replace: text\n            });\n          }\n          return target.apply(thisArg, argumentsList);\n        }\n      )\n    });\n  }\n  let replaceSync;\n  if (win.CSSStyleSheet.prototype.replaceSync) {\n    replaceSync = win.CSSStyleSheet.prototype.replaceSync;\n    win.CSSStyleSheet.prototype.replaceSync = new Proxy(replaceSync, {\n      apply: callbackWrapper(\n        (target, thisArg, argumentsList) => {\n          const [text] = argumentsList;\n          const { id, styleId } = getIdAndStyleId(\n            thisArg,\n            mirror2,\n            stylesheetManager.styleMirror\n          );\n          if (id && id !== -1 || styleId && styleId !== -1) {\n            styleSheetRuleCb({\n              id,\n              styleId,\n              replaceSync: text\n            });\n          }\n          return target.apply(thisArg, argumentsList);\n        }\n      )\n    });\n  }\n  const supportedNestedCSSRuleTypes = {};\n  if (canMonkeyPatchNestedCSSRule(\"CSSGroupingRule\")) {\n    supportedNestedCSSRuleTypes.CSSGroupingRule = win.CSSGroupingRule;\n  } else {\n    if (canMonkeyPatchNestedCSSRule(\"CSSMediaRule\")) {\n      supportedNestedCSSRuleTypes.CSSMediaRule = win.CSSMediaRule;\n    }\n    if (canMonkeyPatchNestedCSSRule(\"CSSConditionRule\")) {\n      supportedNestedCSSRuleTypes.CSSConditionRule = win.CSSConditionRule;\n    }\n    if (canMonkeyPatchNestedCSSRule(\"CSSSupportsRule\")) {\n      supportedNestedCSSRuleTypes.CSSSupportsRule = win.CSSSupportsRule;\n    }\n  }\n  const unmodifiedFunctions = {};\n  Object.entries(supportedNestedCSSRuleTypes).forEach(([typeKey, type]) => {\n    unmodifiedFunctions[typeKey] = {\n      // eslint-disable-next-line @typescript-eslint/unbound-method\n      insertRule: type.prototype.insertRule,\n      // eslint-disable-next-line @typescript-eslint/unbound-method\n      deleteRule: type.prototype.deleteRule\n    };\n    type.prototype.insertRule = new Proxy(\n      unmodifiedFunctions[typeKey].insertRule,\n      {\n        apply: callbackWrapper(\n          (target, thisArg, argumentsList) => {\n            const [rule2, index2] = argumentsList;\n            const { id, styleId } = getIdAndStyleId(\n              thisArg.parentStyleSheet,\n              mirror2,\n              stylesheetManager.styleMirror\n            );\n            if (id && id !== -1 || styleId && styleId !== -1) {\n              styleSheetRuleCb({\n                id,\n                styleId,\n                adds: [\n                  {\n                    rule: rule2,\n                    index: [\n                      ...getNestedCSSRulePositions(thisArg),\n                      index2 || 0\n                      // defaults to 0\n                    ]\n                  }\n                ]\n              });\n            }\n            return target.apply(thisArg, argumentsList);\n          }\n        )\n      }\n    );\n    type.prototype.deleteRule = new Proxy(\n      unmodifiedFunctions[typeKey].deleteRule,\n      {\n        apply: callbackWrapper(\n          (target, thisArg, argumentsList) => {\n            const [index2] = argumentsList;\n            const { id, styleId } = getIdAndStyleId(\n              thisArg.parentStyleSheet,\n              mirror2,\n              stylesheetManager.styleMirror\n            );\n            if (id && id !== -1 || styleId && styleId !== -1) {\n              styleSheetRuleCb({\n                id,\n                styleId,\n                removes: [\n                  { index: [...getNestedCSSRulePositions(thisArg), index2] }\n                ]\n              });\n            }\n            return target.apply(thisArg, argumentsList);\n          }\n        )\n      }\n    );\n  });\n  return callbackWrapper(() => {\n    win.CSSStyleSheet.prototype.insertRule = insertRule;\n    win.CSSStyleSheet.prototype.deleteRule = deleteRule;\n    replace && (win.CSSStyleSheet.prototype.replace = replace);\n    replaceSync && (win.CSSStyleSheet.prototype.replaceSync = replaceSync);\n    Object.entries(supportedNestedCSSRuleTypes).forEach(([typeKey, type]) => {\n      type.prototype.insertRule = unmodifiedFunctions[typeKey].insertRule;\n      type.prototype.deleteRule = unmodifiedFunctions[typeKey].deleteRule;\n    });\n  });\n}\nfunction initAdoptedStyleSheetObserver({\n  mirror: mirror2,\n  stylesheetManager\n}, host2) {\n  var _a2, _b, _c;\n  let hostId = null;\n  if (host2.nodeName === \"#document\") hostId = mirror2.getId(host2);\n  else hostId = mirror2.getId(index.host(host2));\n  const patchTarget = host2.nodeName === \"#document\" ? (_a2 = host2.defaultView) == null ? void 0 : _a2.Document : (_c = (_b = host2.ownerDocument) == null ? void 0 : _b.defaultView) == null ? void 0 : _c.ShadowRoot;\n  const originalPropertyDescriptor = (patchTarget == null ? void 0 : patchTarget.prototype) ? Object.getOwnPropertyDescriptor(\n    patchTarget == null ? void 0 : patchTarget.prototype,\n    \"adoptedStyleSheets\"\n  ) : void 0;\n  if (hostId === null || hostId === -1 || !patchTarget || !originalPropertyDescriptor)\n    return () => {\n    };\n  Object.defineProperty(host2, \"adoptedStyleSheets\", {\n    configurable: originalPropertyDescriptor.configurable,\n    enumerable: originalPropertyDescriptor.enumerable,\n    get() {\n      var _a3;\n      return (_a3 = originalPropertyDescriptor.get) == null ? void 0 : _a3.call(this);\n    },\n    set(sheets) {\n      var _a3;\n      const result2 = (_a3 = originalPropertyDescriptor.set) == null ? void 0 : _a3.call(this, sheets);\n      if (hostId !== null && hostId !== -1) {\n        try {\n          stylesheetManager.adoptStyleSheets(sheets, hostId);\n        } catch (e2) {\n        }\n      }\n      return result2;\n    }\n  });\n  return callbackWrapper(() => {\n    Object.defineProperty(host2, \"adoptedStyleSheets\", {\n      configurable: originalPropertyDescriptor.configurable,\n      enumerable: originalPropertyDescriptor.enumerable,\n      // eslint-disable-next-line @typescript-eslint/unbound-method\n      get: originalPropertyDescriptor.get,\n      // eslint-disable-next-line @typescript-eslint/unbound-method\n      set: originalPropertyDescriptor.set\n    });\n  });\n}\nfunction initStyleDeclarationObserver({\n  styleDeclarationCb,\n  mirror: mirror2,\n  ignoreCSSAttributes,\n  stylesheetManager\n}, { win }) {\n  const setProperty = win.CSSStyleDeclaration.prototype.setProperty;\n  win.CSSStyleDeclaration.prototype.setProperty = new Proxy(setProperty, {\n    apply: callbackWrapper(\n      (target, thisArg, argumentsList) => {\n        var _a2;\n        const [property, value, priority] = argumentsList;\n        if (ignoreCSSAttributes.has(property)) {\n          return setProperty.apply(thisArg, [property, value, priority]);\n        }\n        const { id, styleId } = getIdAndStyleId(\n          (_a2 = thisArg.parentRule) == null ? void 0 : _a2.parentStyleSheet,\n          mirror2,\n          stylesheetManager.styleMirror\n        );\n        if (id && id !== -1 || styleId && styleId !== -1) {\n          styleDeclarationCb({\n            id,\n            styleId,\n            set: {\n              property,\n              value,\n              priority\n            },\n            // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n            index: getNestedCSSRulePositions(thisArg.parentRule)\n          });\n        }\n        return target.apply(thisArg, argumentsList);\n      }\n    )\n  });\n  const removeProperty = win.CSSStyleDeclaration.prototype.removeProperty;\n  win.CSSStyleDeclaration.prototype.removeProperty = new Proxy(removeProperty, {\n    apply: callbackWrapper(\n      (target, thisArg, argumentsList) => {\n        var _a2;\n        const [property] = argumentsList;\n        if (ignoreCSSAttributes.has(property)) {\n          return removeProperty.apply(thisArg, [property]);\n        }\n        const { id, styleId } = getIdAndStyleId(\n          (_a2 = thisArg.parentRule) == null ? void 0 : _a2.parentStyleSheet,\n          mirror2,\n          stylesheetManager.styleMirror\n        );\n        if (id && id !== -1 || styleId && styleId !== -1) {\n          styleDeclarationCb({\n            id,\n            styleId,\n            remove: {\n              property\n            },\n            // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n            index: getNestedCSSRulePositions(thisArg.parentRule)\n          });\n        }\n        return target.apply(thisArg, argumentsList);\n      }\n    )\n  });\n  return callbackWrapper(() => {\n    win.CSSStyleDeclaration.prototype.setProperty = setProperty;\n    win.CSSStyleDeclaration.prototype.removeProperty = removeProperty;\n  });\n}\nfunction initMediaInteractionObserver({\n  mediaInteractionCb,\n  blockClass,\n  blockSelector,\n  mirror: mirror2,\n  sampling,\n  doc\n}) {\n  const handler = callbackWrapper(\n    (type) => throttle(\n      callbackWrapper((event) => {\n        const target = getEventTarget(event);\n        if (!target || isBlocked(target, blockClass, blockSelector, true)) {\n          return;\n        }\n        const { currentTime, volume, muted, playbackRate, loop } = target;\n        mediaInteractionCb({\n          type,\n          id: mirror2.getId(target),\n          currentTime,\n          volume,\n          muted,\n          playbackRate,\n          loop\n        });\n      }),\n      sampling.media || 500\n    )\n  );\n  const handlers = [\n    on(\"play\", handler(MediaInteractions.Play), doc),\n    on(\"pause\", handler(MediaInteractions.Pause), doc),\n    on(\"seeked\", handler(MediaInteractions.Seeked), doc),\n    on(\"volumechange\", handler(MediaInteractions.VolumeChange), doc),\n    on(\"ratechange\", handler(MediaInteractions.RateChange), doc)\n  ];\n  return callbackWrapper(() => {\n    handlers.forEach((h) => h());\n  });\n}\nfunction initFontObserver({ fontCb, doc }) {\n  const win = doc.defaultView;\n  if (!win) {\n    return () => {\n    };\n  }\n  const handlers = [];\n  const fontMap = /* @__PURE__ */ new WeakMap();\n  const originalFontFace = win.FontFace;\n  win.FontFace = function FontFace2(family, source, descriptors) {\n    const fontFace = new originalFontFace(family, source, descriptors);\n    fontMap.set(fontFace, {\n      family,\n      buffer: typeof source !== \"string\",\n      descriptors,\n      fontSource: typeof source === \"string\" ? source : JSON.stringify(Array.from(new Uint8Array(source)))\n    });\n    return fontFace;\n  };\n  const restoreHandler = patch(\n    doc.fonts,\n    \"add\",\n    function(original) {\n      return function(fontFace) {\n        setTimeout(\n          callbackWrapper(() => {\n            const p = fontMap.get(fontFace);\n            if (p) {\n              fontCb(p);\n              fontMap.delete(fontFace);\n            }\n          }),\n          0\n        );\n        return original.apply(this, [fontFace]);\n      };\n    }\n  );\n  handlers.push(() => {\n    win.FontFace = originalFontFace;\n  });\n  handlers.push(restoreHandler);\n  return callbackWrapper(() => {\n    handlers.forEach((h) => h());\n  });\n}\nfunction initSelectionObserver(param) {\n  const { doc, mirror: mirror2, blockClass, blockSelector, selectionCb } = param;\n  let collapsed = true;\n  const updateSelection = callbackWrapper(() => {\n    const selection = doc.getSelection();\n    if (!selection || collapsed && (selection == null ? void 0 : selection.isCollapsed)) return;\n    collapsed = selection.isCollapsed || false;\n    const ranges = [];\n    const count = selection.rangeCount || 0;\n    for (let i2 = 0; i2 < count; i2++) {\n      const range = selection.getRangeAt(i2);\n      const { startContainer, startOffset, endContainer, endOffset } = range;\n      const blocked = isBlocked(startContainer, blockClass, blockSelector, true) || isBlocked(endContainer, blockClass, blockSelector, true);\n      if (blocked) continue;\n      ranges.push({\n        start: mirror2.getId(startContainer),\n        startOffset,\n        end: mirror2.getId(endContainer),\n        endOffset\n      });\n    }\n    selectionCb({ ranges });\n  });\n  updateSelection();\n  return on(\"selectionchange\", updateSelection);\n}\nfunction initCustomElementObserver({\n  doc,\n  customElementCb\n}) {\n  const win = doc.defaultView;\n  if (!win || !win.customElements) return () => {\n  };\n  const restoreHandler = patch(\n    win.customElements,\n    \"define\",\n    function(original) {\n      return function(name, constructor, options) {\n        try {\n          customElementCb({\n            define: {\n              name\n            }\n          });\n        } catch (e2) {\n          console.warn(`Custom element callback failed for ${name}`);\n        }\n        return original.apply(this, [name, constructor, options]);\n      };\n    }\n  );\n  return restoreHandler;\n}\nfunction mergeHooks(o2, hooks) {\n  const {\n    mutationCb,\n    mousemoveCb,\n    mouseInteractionCb,\n    scrollCb,\n    viewportResizeCb,\n    inputCb,\n    mediaInteractionCb,\n    styleSheetRuleCb,\n    styleDeclarationCb,\n    canvasMutationCb,\n    fontCb,\n    selectionCb,\n    customElementCb\n  } = o2;\n  o2.mutationCb = (...p) => {\n    if (hooks.mutation) {\n      hooks.mutation(...p);\n    }\n    mutationCb(...p);\n  };\n  o2.mousemoveCb = (...p) => {\n    if (hooks.mousemove) {\n      hooks.mousemove(...p);\n    }\n    mousemoveCb(...p);\n  };\n  o2.mouseInteractionCb = (...p) => {\n    if (hooks.mouseInteraction) {\n      hooks.mouseInteraction(...p);\n    }\n    mouseInteractionCb(...p);\n  };\n  o2.scrollCb = (...p) => {\n    if (hooks.scroll) {\n      hooks.scroll(...p);\n    }\n    scrollCb(...p);\n  };\n  o2.viewportResizeCb = (...p) => {\n    if (hooks.viewportResize) {\n      hooks.viewportResize(...p);\n    }\n    viewportResizeCb(...p);\n  };\n  o2.inputCb = (...p) => {\n    if (hooks.input) {\n      hooks.input(...p);\n    }\n    inputCb(...p);\n  };\n  o2.mediaInteractionCb = (...p) => {\n    if (hooks.mediaInteaction) {\n      hooks.mediaInteaction(...p);\n    }\n    mediaInteractionCb(...p);\n  };\n  o2.styleSheetRuleCb = (...p) => {\n    if (hooks.styleSheetRule) {\n      hooks.styleSheetRule(...p);\n    }\n    styleSheetRuleCb(...p);\n  };\n  o2.styleDeclarationCb = (...p) => {\n    if (hooks.styleDeclaration) {\n      hooks.styleDeclaration(...p);\n    }\n    styleDeclarationCb(...p);\n  };\n  o2.canvasMutationCb = (...p) => {\n    if (hooks.canvasMutation) {\n      hooks.canvasMutation(...p);\n    }\n    canvasMutationCb(...p);\n  };\n  o2.fontCb = (...p) => {\n    if (hooks.font) {\n      hooks.font(...p);\n    }\n    fontCb(...p);\n  };\n  o2.selectionCb = (...p) => {\n    if (hooks.selection) {\n      hooks.selection(...p);\n    }\n    selectionCb(...p);\n  };\n  o2.customElementCb = (...c2) => {\n    if (hooks.customElement) {\n      hooks.customElement(...c2);\n    }\n    customElementCb(...c2);\n  };\n}\nfunction initObservers(o2, hooks = {}) {\n  const currentWindow = o2.doc.defaultView;\n  if (!currentWindow) {\n    return () => {\n    };\n  }\n  mergeHooks(o2, hooks);\n  let mutationObserver;\n  if (o2.recordDOM) {\n    mutationObserver = initMutationObserver(o2, o2.doc);\n  }\n  const mousemoveHandler = initMoveObserver(o2);\n  const mouseInteractionHandler = initMouseInteractionObserver(o2);\n  const scrollHandler = initScrollObserver(o2);\n  const viewportResizeHandler = initViewportResizeObserver(o2, {\n    win: currentWindow\n  });\n  const inputHandler = initInputObserver(o2);\n  const mediaInteractionHandler = initMediaInteractionObserver(o2);\n  let styleSheetObserver = () => {\n  };\n  let adoptedStyleSheetObserver = () => {\n  };\n  let styleDeclarationObserver = () => {\n  };\n  let fontObserver = () => {\n  };\n  if (o2.recordDOM) {\n    styleSheetObserver = initStyleSheetObserver(o2, { win: currentWindow });\n    adoptedStyleSheetObserver = initAdoptedStyleSheetObserver(o2, o2.doc);\n    styleDeclarationObserver = initStyleDeclarationObserver(o2, {\n      win: currentWindow\n    });\n    if (o2.collectFonts) {\n      fontObserver = initFontObserver(o2);\n    }\n  }\n  const selectionObserver = initSelectionObserver(o2);\n  const customElementObserver = initCustomElementObserver(o2);\n  const pluginHandlers = [];\n  for (const plugin3 of o2.plugins) {\n    pluginHandlers.push(\n      plugin3.observer(plugin3.callback, currentWindow, plugin3.options)\n    );\n  }\n  return callbackWrapper(() => {\n    mutationBuffers.forEach((b) => b.reset());\n    mutationObserver == null ? void 0 : mutationObserver.disconnect();\n    mousemoveHandler();\n    mouseInteractionHandler();\n    scrollHandler();\n    viewportResizeHandler();\n    inputHandler();\n    mediaInteractionHandler();\n    styleSheetObserver();\n    adoptedStyleSheetObserver();\n    styleDeclarationObserver();\n    fontObserver();\n    selectionObserver();\n    customElementObserver();\n    pluginHandlers.forEach((h) => h());\n  });\n}\nfunction hasNestedCSSRule(prop) {\n  return typeof window[prop] !== \"undefined\";\n}\nfunction canMonkeyPatchNestedCSSRule(prop) {\n  return Boolean(\n    typeof window[prop] !== \"undefined\" && // Note: Generally, this check _shouldn't_ be necessary\n    // However, in some scenarios (e.g. jsdom) this can sometimes fail, so we check for it here\n    window[prop].prototype && \"insertRule\" in window[prop].prototype && \"deleteRule\" in window[prop].prototype\n  );\n}\nclass CrossOriginIframeMirror {\n  constructor(generateIdFn) {\n    __publicField(this, \"iframeIdToRemoteIdMap\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"iframeRemoteIdToIdMap\", /* @__PURE__ */ new WeakMap());\n    this.generateIdFn = generateIdFn;\n  }\n  getId(iframe, remoteId, idToRemoteMap, remoteToIdMap) {\n    const idToRemoteIdMap = idToRemoteMap || this.getIdToRemoteIdMap(iframe);\n    const remoteIdToIdMap = remoteToIdMap || this.getRemoteIdToIdMap(iframe);\n    let id = idToRemoteIdMap.get(remoteId);\n    if (!id) {\n      id = this.generateIdFn();\n      idToRemoteIdMap.set(remoteId, id);\n      remoteIdToIdMap.set(id, remoteId);\n    }\n    return id;\n  }\n  getIds(iframe, remoteId) {\n    const idToRemoteIdMap = this.getIdToRemoteIdMap(iframe);\n    const remoteIdToIdMap = this.getRemoteIdToIdMap(iframe);\n    return remoteId.map(\n      (id) => this.getId(iframe, id, idToRemoteIdMap, remoteIdToIdMap)\n    );\n  }\n  getRemoteId(iframe, id, map) {\n    const remoteIdToIdMap = map || this.getRemoteIdToIdMap(iframe);\n    if (typeof id !== \"number\") return id;\n    const remoteId = remoteIdToIdMap.get(id);\n    if (!remoteId) return -1;\n    return remoteId;\n  }\n  getRemoteIds(iframe, ids) {\n    const remoteIdToIdMap = this.getRemoteIdToIdMap(iframe);\n    return ids.map((id) => this.getRemoteId(iframe, id, remoteIdToIdMap));\n  }\n  reset(iframe) {\n    if (!iframe) {\n      this.iframeIdToRemoteIdMap = /* @__PURE__ */ new WeakMap();\n      this.iframeRemoteIdToIdMap = /* @__PURE__ */ new WeakMap();\n      return;\n    }\n    this.iframeIdToRemoteIdMap.delete(iframe);\n    this.iframeRemoteIdToIdMap.delete(iframe);\n  }\n  getIdToRemoteIdMap(iframe) {\n    let idToRemoteIdMap = this.iframeIdToRemoteIdMap.get(iframe);\n    if (!idToRemoteIdMap) {\n      idToRemoteIdMap = /* @__PURE__ */ new Map();\n      this.iframeIdToRemoteIdMap.set(iframe, idToRemoteIdMap);\n    }\n    return idToRemoteIdMap;\n  }\n  getRemoteIdToIdMap(iframe) {\n    let remoteIdToIdMap = this.iframeRemoteIdToIdMap.get(iframe);\n    if (!remoteIdToIdMap) {\n      remoteIdToIdMap = /* @__PURE__ */ new Map();\n      this.iframeRemoteIdToIdMap.set(iframe, remoteIdToIdMap);\n    }\n    return remoteIdToIdMap;\n  }\n}\nclass IframeManager {\n  constructor(options) {\n    __publicField(this, \"iframes\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"crossOriginIframeMap\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"crossOriginIframeMirror\", new CrossOriginIframeMirror(genId));\n    __publicField(this, \"crossOriginIframeStyleMirror\");\n    __publicField(this, \"crossOriginIframeRootIdMap\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"mirror\");\n    __publicField(this, \"mutationCb\");\n    __publicField(this, \"wrappedEmit\");\n    __publicField(this, \"loadListener\");\n    __publicField(this, \"stylesheetManager\");\n    __publicField(this, \"recordCrossOriginIframes\");\n    this.mutationCb = options.mutationCb;\n    this.wrappedEmit = options.wrappedEmit;\n    this.stylesheetManager = options.stylesheetManager;\n    this.recordCrossOriginIframes = options.recordCrossOriginIframes;\n    this.crossOriginIframeStyleMirror = new CrossOriginIframeMirror(\n      this.stylesheetManager.styleMirror.generateId.bind(\n        this.stylesheetManager.styleMirror\n      )\n    );\n    this.mirror = options.mirror;\n    if (this.recordCrossOriginIframes) {\n      window.addEventListener(\"message\", this.handleMessage.bind(this));\n    }\n  }\n  addIframe(iframeEl) {\n    this.iframes.set(iframeEl, true);\n    if (iframeEl.contentWindow)\n      this.crossOriginIframeMap.set(iframeEl.contentWindow, iframeEl);\n  }\n  addLoadListener(cb) {\n    this.loadListener = cb;\n  }\n  attachIframe(iframeEl, childSn) {\n    var _a2, _b;\n    this.mutationCb({\n      adds: [\n        {\n          parentId: this.mirror.getId(iframeEl),\n          nextId: null,\n          node: childSn\n        }\n      ],\n      removes: [],\n      texts: [],\n      attributes: [],\n      isAttachIframe: true\n    });\n    if (this.recordCrossOriginIframes)\n      (_a2 = iframeEl.contentWindow) == null ? void 0 : _a2.addEventListener(\n        \"message\",\n        this.handleMessage.bind(this)\n      );\n    (_b = this.loadListener) == null ? void 0 : _b.call(this, iframeEl);\n    if (iframeEl.contentDocument && iframeEl.contentDocument.adoptedStyleSheets && iframeEl.contentDocument.adoptedStyleSheets.length > 0)\n      this.stylesheetManager.adoptStyleSheets(\n        iframeEl.contentDocument.adoptedStyleSheets,\n        this.mirror.getId(iframeEl.contentDocument)\n      );\n  }\n  handleMessage(message) {\n    const crossOriginMessageEvent = message;\n    if (crossOriginMessageEvent.data.type !== \"rrweb\" || // To filter out the rrweb messages which are forwarded by some sites.\n    crossOriginMessageEvent.origin !== crossOriginMessageEvent.data.origin)\n      return;\n    const iframeSourceWindow = message.source;\n    if (!iframeSourceWindow) return;\n    const iframeEl = this.crossOriginIframeMap.get(message.source);\n    if (!iframeEl) return;\n    const transformedEvent = this.transformCrossOriginEvent(\n      iframeEl,\n      crossOriginMessageEvent.data.event\n    );\n    if (transformedEvent)\n      this.wrappedEmit(\n        transformedEvent,\n        crossOriginMessageEvent.data.isCheckout\n      );\n  }\n  transformCrossOriginEvent(iframeEl, e2) {\n    var _a2;\n    switch (e2.type) {\n      case EventType.FullSnapshot: {\n        this.crossOriginIframeMirror.reset(iframeEl);\n        this.crossOriginIframeStyleMirror.reset(iframeEl);\n        this.replaceIdOnNode(e2.data.node, iframeEl);\n        const rootId = e2.data.node.id;\n        this.crossOriginIframeRootIdMap.set(iframeEl, rootId);\n        this.patchRootIdOnNode(e2.data.node, rootId);\n        return {\n          timestamp: e2.timestamp,\n          type: EventType.IncrementalSnapshot,\n          data: {\n            source: IncrementalSource.Mutation,\n            adds: [\n              {\n                parentId: this.mirror.getId(iframeEl),\n                nextId: null,\n                node: e2.data.node\n              }\n            ],\n            removes: [],\n            texts: [],\n            attributes: [],\n            isAttachIframe: true\n          }\n        };\n      }\n      case EventType.Meta:\n      case EventType.Load:\n      case EventType.DomContentLoaded: {\n        return false;\n      }\n      case EventType.Plugin: {\n        return e2;\n      }\n      case EventType.Custom: {\n        this.replaceIds(\n          e2.data.payload,\n          iframeEl,\n          [\"id\", \"parentId\", \"previousId\", \"nextId\"]\n        );\n        return e2;\n      }\n      case EventType.IncrementalSnapshot: {\n        switch (e2.data.source) {\n          case IncrementalSource.Mutation: {\n            e2.data.adds.forEach((n2) => {\n              this.replaceIds(n2, iframeEl, [\n                \"parentId\",\n                \"nextId\",\n                \"previousId\"\n              ]);\n              this.replaceIdOnNode(n2.node, iframeEl);\n              const rootId = this.crossOriginIframeRootIdMap.get(iframeEl);\n              rootId && this.patchRootIdOnNode(n2.node, rootId);\n            });\n            e2.data.removes.forEach((n2) => {\n              this.replaceIds(n2, iframeEl, [\"parentId\", \"id\"]);\n            });\n            e2.data.attributes.forEach((n2) => {\n              this.replaceIds(n2, iframeEl, [\"id\"]);\n            });\n            e2.data.texts.forEach((n2) => {\n              this.replaceIds(n2, iframeEl, [\"id\"]);\n            });\n            return e2;\n          }\n          case IncrementalSource.Drag:\n          case IncrementalSource.TouchMove:\n          case IncrementalSource.MouseMove: {\n            e2.data.positions.forEach((p) => {\n              this.replaceIds(p, iframeEl, [\"id\"]);\n            });\n            return e2;\n          }\n          case IncrementalSource.ViewportResize: {\n            return false;\n          }\n          case IncrementalSource.MediaInteraction:\n          case IncrementalSource.MouseInteraction:\n          case IncrementalSource.Scroll:\n          case IncrementalSource.CanvasMutation:\n          case IncrementalSource.Input: {\n            this.replaceIds(e2.data, iframeEl, [\"id\"]);\n            return e2;\n          }\n          case IncrementalSource.StyleSheetRule:\n          case IncrementalSource.StyleDeclaration: {\n            this.replaceIds(e2.data, iframeEl, [\"id\"]);\n            this.replaceStyleIds(e2.data, iframeEl, [\"styleId\"]);\n            return e2;\n          }\n          case IncrementalSource.Font: {\n            return e2;\n          }\n          case IncrementalSource.Selection: {\n            e2.data.ranges.forEach((range) => {\n              this.replaceIds(range, iframeEl, [\"start\", \"end\"]);\n            });\n            return e2;\n          }\n          case IncrementalSource.AdoptedStyleSheet: {\n            this.replaceIds(e2.data, iframeEl, [\"id\"]);\n            this.replaceStyleIds(e2.data, iframeEl, [\"styleIds\"]);\n            (_a2 = e2.data.styles) == null ? void 0 : _a2.forEach((style) => {\n              this.replaceStyleIds(style, iframeEl, [\"styleId\"]);\n            });\n            return e2;\n          }\n        }\n      }\n    }\n    return false;\n  }\n  replace(iframeMirror, obj, iframeEl, keys) {\n    for (const key of keys) {\n      if (!Array.isArray(obj[key]) && typeof obj[key] !== \"number\") continue;\n      if (Array.isArray(obj[key])) {\n        obj[key] = iframeMirror.getIds(\n          iframeEl,\n          obj[key]\n        );\n      } else {\n        obj[key] = iframeMirror.getId(iframeEl, obj[key]);\n      }\n    }\n    return obj;\n  }\n  replaceIds(obj, iframeEl, keys) {\n    return this.replace(this.crossOriginIframeMirror, obj, iframeEl, keys);\n  }\n  replaceStyleIds(obj, iframeEl, keys) {\n    return this.replace(this.crossOriginIframeStyleMirror, obj, iframeEl, keys);\n  }\n  replaceIdOnNode(node2, iframeEl) {\n    this.replaceIds(node2, iframeEl, [\"id\", \"rootId\"]);\n    if (\"childNodes\" in node2) {\n      node2.childNodes.forEach((child) => {\n        this.replaceIdOnNode(child, iframeEl);\n      });\n    }\n  }\n  patchRootIdOnNode(node2, rootId) {\n    if (node2.type !== NodeType.Document && !node2.rootId) node2.rootId = rootId;\n    if (\"childNodes\" in node2) {\n      node2.childNodes.forEach((child) => {\n        this.patchRootIdOnNode(child, rootId);\n      });\n    }\n  }\n}\nclass ShadowDomManager {\n  constructor(options) {\n    __publicField(this, \"shadowDoms\", /* @__PURE__ */ new WeakSet());\n    __publicField(this, \"mutationCb\");\n    __publicField(this, \"scrollCb\");\n    __publicField(this, \"bypassOptions\");\n    __publicField(this, \"mirror\");\n    __publicField(this, \"restoreHandlers\", []);\n    this.mutationCb = options.mutationCb;\n    this.scrollCb = options.scrollCb;\n    this.bypassOptions = options.bypassOptions;\n    this.mirror = options.mirror;\n    this.init();\n  }\n  init() {\n    this.reset();\n    this.patchAttachShadow(Element, document);\n  }\n  addShadowRoot(shadowRoot2, doc) {\n    if (!isNativeShadowDom(shadowRoot2)) return;\n    if (this.shadowDoms.has(shadowRoot2)) return;\n    this.shadowDoms.add(shadowRoot2);\n    const observer = initMutationObserver(\n      {\n        ...this.bypassOptions,\n        doc,\n        mutationCb: this.mutationCb,\n        mirror: this.mirror,\n        shadowDomManager: this\n      },\n      shadowRoot2\n    );\n    this.restoreHandlers.push(() => observer.disconnect());\n    this.restoreHandlers.push(\n      initScrollObserver({\n        ...this.bypassOptions,\n        scrollCb: this.scrollCb,\n        // https://gist.github.com/praveenpuglia/0832da687ed5a5d7a0907046c9ef1813\n        // scroll is not allowed to pass the boundary, so we need to listen the shadow document\n        doc: shadowRoot2,\n        mirror: this.mirror\n      })\n    );\n    setTimeout(() => {\n      if (shadowRoot2.adoptedStyleSheets && shadowRoot2.adoptedStyleSheets.length > 0)\n        this.bypassOptions.stylesheetManager.adoptStyleSheets(\n          shadowRoot2.adoptedStyleSheets,\n          this.mirror.getId(index.host(shadowRoot2))\n        );\n      this.restoreHandlers.push(\n        initAdoptedStyleSheetObserver(\n          {\n            mirror: this.mirror,\n            stylesheetManager: this.bypassOptions.stylesheetManager\n          },\n          shadowRoot2\n        )\n      );\n    }, 0);\n  }\n  /**\n   * Monkey patch 'attachShadow' of an IFrameElement to observe newly added shadow doms.\n   */\n  observeAttachShadow(iframeElement) {\n    if (!iframeElement.contentWindow || !iframeElement.contentDocument) return;\n    this.patchAttachShadow(\n      iframeElement.contentWindow.Element,\n      iframeElement.contentDocument\n    );\n  }\n  /**\n   * Patch 'attachShadow' to observe newly added shadow doms.\n   */\n  patchAttachShadow(element, doc) {\n    const manager = this;\n    this.restoreHandlers.push(\n      patch(\n        element.prototype,\n        \"attachShadow\",\n        function(original) {\n          return function(option) {\n            const sRoot = original.call(this, option);\n            const shadowRootEl = index.shadowRoot(this);\n            if (shadowRootEl && inDom(this))\n              manager.addShadowRoot(shadowRootEl, doc);\n            return sRoot;\n          };\n        }\n      )\n    );\n  }\n  reset() {\n    this.restoreHandlers.forEach((handler) => {\n      try {\n        handler();\n      } catch (e2) {\n      }\n    });\n    this.restoreHandlers = [];\n    this.shadowDoms = /* @__PURE__ */ new WeakSet();\n  }\n}\nvar chars = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\";\nvar lookup = typeof Uint8Array === \"undefined\" ? [] : new Uint8Array(256);\nfor (var i$1 = 0; i$1 < chars.length; i$1++) {\n  lookup[chars.charCodeAt(i$1)] = i$1;\n}\nvar encode = function(arraybuffer) {\n  var bytes = new Uint8Array(arraybuffer), i2, len = bytes.length, base64 = \"\";\n  for (i2 = 0; i2 < len; i2 += 3) {\n    base64 += chars[bytes[i2] >> 2];\n    base64 += chars[(bytes[i2] & 3) << 4 | bytes[i2 + 1] >> 4];\n    base64 += chars[(bytes[i2 + 1] & 15) << 2 | bytes[i2 + 2] >> 6];\n    base64 += chars[bytes[i2 + 2] & 63];\n  }\n  if (len % 3 === 2) {\n    base64 = base64.substring(0, base64.length - 1) + \"=\";\n  } else if (len % 3 === 1) {\n    base64 = base64.substring(0, base64.length - 2) + \"==\";\n  }\n  return base64;\n};\nconst canvasVarMap = /* @__PURE__ */ new Map();\nfunction variableListFor$1(ctx, ctor) {\n  let contextMap = canvasVarMap.get(ctx);\n  if (!contextMap) {\n    contextMap = /* @__PURE__ */ new Map();\n    canvasVarMap.set(ctx, contextMap);\n  }\n  if (!contextMap.has(ctor)) {\n    contextMap.set(ctor, []);\n  }\n  return contextMap.get(ctor);\n}\nconst saveWebGLVar = (value, win, ctx) => {\n  if (!value || !(isInstanceOfWebGLObject(value, win) || typeof value === \"object\"))\n    return;\n  const name = value.constructor.name;\n  const list2 = variableListFor$1(ctx, name);\n  let index2 = list2.indexOf(value);\n  if (index2 === -1) {\n    index2 = list2.length;\n    list2.push(value);\n  }\n  return index2;\n};\nfunction serializeArg(value, win, ctx) {\n  if (value instanceof Array) {\n    return value.map((arg) => serializeArg(arg, win, ctx));\n  } else if (value === null) {\n    return value;\n  } else if (value instanceof Float32Array || value instanceof Float64Array || value instanceof Int32Array || value instanceof Uint32Array || value instanceof Uint8Array || value instanceof Uint16Array || value instanceof Int16Array || value instanceof Int8Array || value instanceof Uint8ClampedArray) {\n    const name = value.constructor.name;\n    return {\n      rr_type: name,\n      args: [Object.values(value)]\n    };\n  } else if (\n    // SharedArrayBuffer disabled on most browsers due to spectre.\n    // More info: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer/SharedArrayBuffer\n    // value instanceof SharedArrayBuffer ||\n    value instanceof ArrayBuffer\n  ) {\n    const name = value.constructor.name;\n    const base64 = encode(value);\n    return {\n      rr_type: name,\n      base64\n    };\n  } else if (value instanceof DataView) {\n    const name = value.constructor.name;\n    return {\n      rr_type: name,\n      args: [\n        serializeArg(value.buffer, win, ctx),\n        value.byteOffset,\n        value.byteLength\n      ]\n    };\n  } else if (value instanceof HTMLImageElement) {\n    const name = value.constructor.name;\n    const { src } = value;\n    return {\n      rr_type: name,\n      src\n    };\n  } else if (value instanceof HTMLCanvasElement) {\n    const name = \"HTMLImageElement\";\n    const src = value.toDataURL();\n    return {\n      rr_type: name,\n      src\n    };\n  } else if (value instanceof ImageData) {\n    const name = value.constructor.name;\n    return {\n      rr_type: name,\n      args: [serializeArg(value.data, win, ctx), value.width, value.height]\n    };\n  } else if (isInstanceOfWebGLObject(value, win) || typeof value === \"object\") {\n    const name = value.constructor.name;\n    const index2 = saveWebGLVar(value, win, ctx);\n    return {\n      rr_type: name,\n      index: index2\n    };\n  }\n  return value;\n}\nconst serializeArgs = (args, win, ctx) => {\n  return args.map((arg) => serializeArg(arg, win, ctx));\n};\nconst isInstanceOfWebGLObject = (value, win) => {\n  const webGLConstructorNames = [\n    \"WebGLActiveInfo\",\n    \"WebGLBuffer\",\n    \"WebGLFramebuffer\",\n    \"WebGLProgram\",\n    \"WebGLRenderbuffer\",\n    \"WebGLShader\",\n    \"WebGLShaderPrecisionFormat\",\n    \"WebGLTexture\",\n    \"WebGLUniformLocation\",\n    \"WebGLVertexArrayObject\",\n    // In old Chrome versions, value won't be an instanceof WebGLVertexArrayObject.\n    \"WebGLVertexArrayObjectOES\"\n  ];\n  const supportedWebGLConstructorNames = webGLConstructorNames.filter(\n    (name) => typeof win[name] === \"function\"\n  );\n  return Boolean(\n    supportedWebGLConstructorNames.find(\n      (name) => value instanceof win[name]\n    )\n  );\n};\nfunction initCanvas2DMutationObserver(cb, win, blockClass, blockSelector) {\n  const handlers = [];\n  const props2D = Object.getOwnPropertyNames(\n    win.CanvasRenderingContext2D.prototype\n  );\n  for (const prop of props2D) {\n    try {\n      if (typeof win.CanvasRenderingContext2D.prototype[prop] !== \"function\") {\n        continue;\n      }\n      const restoreHandler = patch(\n        win.CanvasRenderingContext2D.prototype,\n        prop,\n        function(original) {\n          return function(...args) {\n            if (!isBlocked(this.canvas, blockClass, blockSelector, true)) {\n              setTimeout(() => {\n                const recordArgs = serializeArgs(args, win, this);\n                cb(this.canvas, {\n                  type: CanvasContext[\"2D\"],\n                  property: prop,\n                  args: recordArgs\n                });\n              }, 0);\n            }\n            return original.apply(this, args);\n          };\n        }\n      );\n      handlers.push(restoreHandler);\n    } catch {\n      const hookHandler = hookSetter(\n        win.CanvasRenderingContext2D.prototype,\n        prop,\n        {\n          set(v2) {\n            cb(this.canvas, {\n              type: CanvasContext[\"2D\"],\n              property: prop,\n              args: [v2],\n              setter: true\n            });\n          }\n        }\n      );\n      handlers.push(hookHandler);\n    }\n  }\n  return () => {\n    handlers.forEach((h) => h());\n  };\n}\nfunction getNormalizedContextName(contextType) {\n  return contextType === \"experimental-webgl\" ? \"webgl\" : contextType;\n}\nfunction initCanvasContextObserver(win, blockClass, blockSelector, setPreserveDrawingBufferToTrue) {\n  const handlers = [];\n  try {\n    const restoreHandler = patch(\n      win.HTMLCanvasElement.prototype,\n      \"getContext\",\n      function(original) {\n        return function(contextType, ...args) {\n          if (!isBlocked(this, blockClass, blockSelector, true)) {\n            const ctxName = getNormalizedContextName(contextType);\n            if (!(\"__context\" in this)) this.__context = ctxName;\n            if (setPreserveDrawingBufferToTrue && [\"webgl\", \"webgl2\"].includes(ctxName)) {\n              if (args[0] && typeof args[0] === \"object\") {\n                const contextAttributes = args[0];\n                if (!contextAttributes.preserveDrawingBuffer) {\n                  contextAttributes.preserveDrawingBuffer = true;\n                }\n              } else {\n                args.splice(0, 1, {\n                  preserveDrawingBuffer: true\n                });\n              }\n            }\n          }\n          return original.apply(this, [contextType, ...args]);\n        };\n      }\n    );\n    handlers.push(restoreHandler);\n  } catch {\n    console.error(\"failed to patch HTMLCanvasElement.prototype.getContext\");\n  }\n  return () => {\n    handlers.forEach((h) => h());\n  };\n}\nfunction patchGLPrototype(prototype, type, cb, blockClass, blockSelector, win) {\n  const handlers = [];\n  const props = Object.getOwnPropertyNames(prototype);\n  for (const prop of props) {\n    if (\n      //prop.startsWith('get') ||  // e.g. getProgramParameter, but too risky\n      [\n        \"isContextLost\",\n        \"canvas\",\n        \"drawingBufferWidth\",\n        \"drawingBufferHeight\"\n      ].includes(prop)\n    ) {\n      continue;\n    }\n    try {\n      if (typeof prototype[prop] !== \"function\") {\n        continue;\n      }\n      const restoreHandler = patch(\n        prototype,\n        prop,\n        function(original) {\n          return function(...args) {\n            const result2 = original.apply(this, args);\n            saveWebGLVar(result2, win, this);\n            if (\"tagName\" in this.canvas && !isBlocked(this.canvas, blockClass, blockSelector, true)) {\n              const recordArgs = serializeArgs(args, win, this);\n              const mutation = {\n                type,\n                property: prop,\n                args: recordArgs\n              };\n              cb(this.canvas, mutation);\n            }\n            return result2;\n          };\n        }\n      );\n      handlers.push(restoreHandler);\n    } catch {\n      const hookHandler = hookSetter(prototype, prop, {\n        set(v2) {\n          cb(this.canvas, {\n            type,\n            property: prop,\n            args: [v2],\n            setter: true\n          });\n        }\n      });\n      handlers.push(hookHandler);\n    }\n  }\n  return handlers;\n}\nfunction initCanvasWebGLMutationObserver(cb, win, blockClass, blockSelector) {\n  const handlers = [];\n  handlers.push(\n    ...patchGLPrototype(\n      win.WebGLRenderingContext.prototype,\n      CanvasContext.WebGL,\n      cb,\n      blockClass,\n      blockSelector,\n      win\n    )\n  );\n  if (typeof win.WebGL2RenderingContext !== \"undefined\") {\n    handlers.push(\n      ...patchGLPrototype(\n        win.WebGL2RenderingContext.prototype,\n        CanvasContext.WebGL2,\n        cb,\n        blockClass,\n        blockSelector,\n        win\n      )\n    );\n  }\n  return () => {\n    handlers.forEach((h) => h());\n  };\n}\nconst encodedJs = \"KGZ1bmN0aW9uKCkgewogICJ1c2Ugc3RyaWN0IjsKICB2YXIgY2hhcnMgPSAiQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLyI7CiAgdmFyIGxvb2t1cCA9IHR5cGVvZiBVaW50OEFycmF5ID09PSAidW5kZWZpbmVkIiA/IFtdIDogbmV3IFVpbnQ4QXJyYXkoMjU2KTsKICBmb3IgKHZhciBpID0gMDsgaSA8IGNoYXJzLmxlbmd0aDsgaSsrKSB7CiAgICBsb29rdXBbY2hhcnMuY2hhckNvZGVBdChpKV0gPSBpOwogIH0KICB2YXIgZW5jb2RlID0gZnVuY3Rpb24oYXJyYXlidWZmZXIpIHsKICAgIHZhciBieXRlcyA9IG5ldyBVaW50OEFycmF5KGFycmF5YnVmZmVyKSwgaTIsIGxlbiA9IGJ5dGVzLmxlbmd0aCwgY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29uc3QgYmxvYiA9IGF3YWl0IG9mZnNjcmVlbi5jb252ZXJ0VG9CbG9iKGRhdGFVUkxPcHRpb25zKTsKICAgICAgY29uc3QgdHlwZSA9IGJsb2IudHlwZTsKICAgICAgY29uc3QgYXJyYXlCdWZmZXIgPSBhd2FpdCBibG9iLmFycmF5QnVmZmVyKCk7CiAgICAgIGNvbnN0IGJhc2U2NCA9IGVuY29kZShhcnJheUJ1ZmZlcik7CiAgICAgIGlmICghbGFzdEJsb2JNYXAuaGFzKGlkKSAmJiBhd2FpdCB0cmFuc3BhcmVudEJhc2U2NCA9PT0gYmFzZTY0KSB7CiAgICAgICAgbGFzdEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICAgIHJldHVybiB3b3JrZXIucG9zdE1lc3NhZ2UoeyBpZCB9KTsKICAgICAgfQogICAgICBpZiAobGFzdEJsb2JNYXAuZ2V0KGlkKSA9PT0gYmFzZTY0KSByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQgfSk7CiAgICAgIHdvcmtlci5wb3N0TWVzc2FnZSh7CiAgICAgICAgaWQsCiAgICAgICAgdHlwZSwKICAgICAgICBiYXNlNjQsCiAgICAgICAgd2lkdGgsCiAgICAgICAgaGVpZ2h0CiAgICAgIH0pOwogICAgICBsYXN0QmxvYk1hcC5zZXQoaWQsIGJhc2U2NCk7CiAgICB9IGVsc2UgewogICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQ6IGUuZGF0YS5pZCB9KTsKICAgIH0KICB9Owp9KSgpOwovLyMgc291cmNlTWFwcGluZ1VSTD1pbWFnZS1iaXRtYXAtZGF0YS11cmwtd29ya2VyLUlKcEM3Z19iLmpzLm1hcAo=\";\nconst decodeBase64 = (base64) => Uint8Array.from(atob(base64), (c2) => c2.charCodeAt(0));\nconst blob = typeof window !== \"undefined\" && window.Blob && new Blob([decodeBase64(encodedJs)], { type: \"text/javascript;charset=utf-8\" });\nfunction WorkerWrapper(options) {\n  let objURL;\n  try {\n    objURL = blob && (window.URL || window.webkitURL).createObjectURL(blob);\n    if (!objURL) throw \"\";\n    const worker = new Worker(objURL, {\n      name: options == null ? void 0 : options.name\n    });\n    worker.addEventListener(\"error\", () => {\n      (window.URL || window.webkitURL).revokeObjectURL(objURL);\n    });\n    return worker;\n  } catch (e2) {\n    return new Worker(\n      \"data:text/javascript;base64,\" + encodedJs,\n      {\n        name: options == null ? void 0 : options.name\n      }\n    );\n  } finally {\n    objURL && (window.URL || window.webkitURL).revokeObjectURL(objURL);\n  }\n}\nclass CanvasManager {\n  constructor(options) {\n    __publicField(this, \"pendingCanvasMutations\", /* @__PURE__ */ new Map());\n    __publicField(this, \"rafStamps\", { latestId: 0, invokeId: null });\n    __publicField(this, \"mirror\");\n    __publicField(this, \"mutationCb\");\n    __publicField(this, \"resetObservers\");\n    __publicField(this, \"frozen\", false);\n    __publicField(this, \"locked\", false);\n    __publicField(this, \"processMutation\", (target, mutation) => {\n      const newFrame = this.rafStamps.invokeId && this.rafStamps.latestId !== this.rafStamps.invokeId;\n      if (newFrame || !this.rafStamps.invokeId)\n        this.rafStamps.invokeId = this.rafStamps.latestId;\n      if (!this.pendingCanvasMutations.has(target)) {\n        this.pendingCanvasMutations.set(target, []);\n      }\n      this.pendingCanvasMutations.get(target).push(mutation);\n    });\n    const {\n      sampling = \"all\",\n      win,\n      blockClass,\n      blockSelector,\n      recordCanvas,\n      dataURLOptions\n    } = options;\n    this.mutationCb = options.mutationCb;\n    this.mirror = options.mirror;\n    if (recordCanvas && sampling === \"all\")\n      this.initCanvasMutationObserver(win, blockClass, blockSelector);\n    if (recordCanvas && typeof sampling === \"number\")\n      this.initCanvasFPSObserver(sampling, win, blockClass, blockSelector, {\n        dataURLOptions\n      });\n  }\n  reset() {\n    this.pendingCanvasMutations.clear();\n    this.resetObservers && this.resetObservers();\n  }\n  freeze() {\n    this.frozen = true;\n  }\n  unfreeze() {\n    this.frozen = false;\n  }\n  lock() {\n    this.locked = true;\n  }\n  unlock() {\n    this.locked = false;\n  }\n  initCanvasFPSObserver(fps, win, blockClass, blockSelector, options) {\n    const canvasContextReset = initCanvasContextObserver(\n      win,\n      blockClass,\n      blockSelector,\n      true\n    );\n    const snapshotInProgressMap = /* @__PURE__ */ new Map();\n    const worker = new WorkerWrapper();\n    worker.onmessage = (e2) => {\n      const { id } = e2.data;\n      snapshotInProgressMap.set(id, false);\n      if (!(\"base64\" in e2.data)) return;\n      const { base64, type, width, height } = e2.data;\n      this.mutationCb({\n        id,\n        type: CanvasContext[\"2D\"],\n        commands: [\n          {\n            property: \"clearRect\",\n            // wipe canvas\n            args: [0, 0, width, height]\n          },\n          {\n            property: \"drawImage\",\n            // draws (semi-transparent) image\n            args: [\n              {\n                rr_type: \"ImageBitmap\",\n                args: [\n                  {\n                    rr_type: \"Blob\",\n                    data: [{ rr_type: \"ArrayBuffer\", base64 }],\n                    type\n                  }\n                ]\n              },\n              0,\n              0\n            ]\n          }\n        ]\n      });\n    };\n    const timeBetweenSnapshots = 1e3 / fps;\n    let lastSnapshotTime = 0;\n    let rafId;\n    const getCanvas = () => {\n      const matchedCanvas = [];\n      win.document.querySelectorAll(\"canvas\").forEach((canvas) => {\n        if (!isBlocked(canvas, blockClass, blockSelector, true)) {\n          matchedCanvas.push(canvas);\n        }\n      });\n      return matchedCanvas;\n    };\n    const takeCanvasSnapshots = (timestamp) => {\n      if (lastSnapshotTime && timestamp - lastSnapshotTime < timeBetweenSnapshots) {\n        rafId = requestAnimationFrame(takeCanvasSnapshots);\n        return;\n      }\n      lastSnapshotTime = timestamp;\n      getCanvas().forEach(async (canvas) => {\n        var _a2;\n        const id = this.mirror.getId(canvas);\n        if (snapshotInProgressMap.get(id)) return;\n        if (canvas.width === 0 || canvas.height === 0) return;\n        snapshotInProgressMap.set(id, true);\n        if ([\"webgl\", \"webgl2\"].includes(canvas.__context)) {\n          const context = canvas.getContext(canvas.__context);\n          if (((_a2 = context == null ? void 0 : context.getContextAttributes()) == null ? void 0 : _a2.preserveDrawingBuffer) === false) {\n            context.clear(context.COLOR_BUFFER_BIT);\n          }\n        }\n        const bitmap = await createImageBitmap(canvas);\n        worker.postMessage(\n          {\n            id,\n            bitmap,\n            width: canvas.width,\n            height: canvas.height,\n            dataURLOptions: options.dataURLOptions\n          },\n          [bitmap]\n        );\n      });\n      rafId = requestAnimationFrame(takeCanvasSnapshots);\n    };\n    rafId = requestAnimationFrame(takeCanvasSnapshots);\n    this.resetObservers = () => {\n      canvasContextReset();\n      cancelAnimationFrame(rafId);\n    };\n  }\n  initCanvasMutationObserver(win, blockClass, blockSelector) {\n    this.startRAFTimestamping();\n    this.startPendingCanvasMutationFlusher();\n    const canvasContextReset = initCanvasContextObserver(\n      win,\n      blockClass,\n      blockSelector,\n      false\n    );\n    const canvas2DReset = initCanvas2DMutationObserver(\n      this.processMutation.bind(this),\n      win,\n      blockClass,\n      blockSelector\n    );\n    const canvasWebGL1and2Reset = initCanvasWebGLMutationObserver(\n      this.processMutation.bind(this),\n      win,\n      blockClass,\n      blockSelector\n    );\n    this.resetObservers = () => {\n      canvasContextReset();\n      canvas2DReset();\n      canvasWebGL1and2Reset();\n    };\n  }\n  startPendingCanvasMutationFlusher() {\n    requestAnimationFrame(() => this.flushPendingCanvasMutations());\n  }\n  startRAFTimestamping() {\n    const setLatestRAFTimestamp = (timestamp) => {\n      this.rafStamps.latestId = timestamp;\n      requestAnimationFrame(setLatestRAFTimestamp);\n    };\n    requestAnimationFrame(setLatestRAFTimestamp);\n  }\n  flushPendingCanvasMutations() {\n    this.pendingCanvasMutations.forEach(\n      (_values, canvas) => {\n        const id = this.mirror.getId(canvas);\n        this.flushPendingCanvasMutationFor(canvas, id);\n      }\n    );\n    requestAnimationFrame(() => this.flushPendingCanvasMutations());\n  }\n  flushPendingCanvasMutationFor(canvas, id) {\n    if (this.frozen || this.locked) {\n      return;\n    }\n    const valuesWithType = this.pendingCanvasMutations.get(canvas);\n    if (!valuesWithType || id === -1) return;\n    const values = valuesWithType.map((value) => {\n      const { type: type2, ...rest } = value;\n      return rest;\n    });\n    const { type } = valuesWithType[0];\n    this.mutationCb({ id, type, commands: values });\n    this.pendingCanvasMutations.delete(canvas);\n  }\n}\nclass StylesheetManager {\n  constructor(options) {\n    __publicField(this, \"trackedLinkElements\", /* @__PURE__ */ new WeakSet());\n    __publicField(this, \"mutationCb\");\n    __publicField(this, \"adoptedStyleSheetCb\");\n    __publicField(this, \"styleMirror\", new StyleSheetMirror());\n    this.mutationCb = options.mutationCb;\n    this.adoptedStyleSheetCb = options.adoptedStyleSheetCb;\n  }\n  attachLinkElement(linkEl, childSn) {\n    if (\"_cssText\" in childSn.attributes)\n      this.mutationCb({\n        adds: [],\n        removes: [],\n        texts: [],\n        attributes: [\n          {\n            id: childSn.id,\n            attributes: childSn.attributes\n          }\n        ]\n      });\n    this.trackLinkElement(linkEl);\n  }\n  trackLinkElement(linkEl) {\n    if (this.trackedLinkElements.has(linkEl)) return;\n    this.trackedLinkElements.add(linkEl);\n    this.trackStylesheetInLinkElement(linkEl);\n  }\n  adoptStyleSheets(sheets, hostId) {\n    if (sheets.length === 0) return;\n    const adoptedStyleSheetData = {\n      id: hostId,\n      styleIds: []\n    };\n    const styles = [];\n    for (const sheet of sheets) {\n      let styleId;\n      if (!this.styleMirror.has(sheet)) {\n        styleId = this.styleMirror.add(sheet);\n        styles.push({\n          styleId,\n          rules: Array.from(sheet.rules || CSSRule, (r2, index2) => ({\n            rule: stringifyRule(r2, sheet.href),\n            index: index2\n          }))\n        });\n      } else styleId = this.styleMirror.getId(sheet);\n      adoptedStyleSheetData.styleIds.push(styleId);\n    }\n    if (styles.length > 0) adoptedStyleSheetData.styles = styles;\n    this.adoptedStyleSheetCb(adoptedStyleSheetData);\n  }\n  reset() {\n    this.styleMirror.reset();\n    this.trackedLinkElements = /* @__PURE__ */ new WeakSet();\n  }\n  // TODO: take snapshot on stylesheet reload by applying event listener\n  trackStylesheetInLinkElement(_linkEl) {\n  }\n}\nclass ProcessedNodeManager {\n  constructor() {\n    __publicField(this, \"nodeMap\", /* @__PURE__ */ new WeakMap());\n    __publicField(this, \"active\", false);\n  }\n  inOtherBuffer(node2, thisBuffer) {\n    const buffers = this.nodeMap.get(node2);\n    return buffers && Array.from(buffers).some((buffer) => buffer !== thisBuffer);\n  }\n  add(node2, buffer) {\n    if (!this.active) {\n      this.active = true;\n      requestAnimationFrame(() => {\n        this.nodeMap = /* @__PURE__ */ new WeakMap();\n        this.active = false;\n      });\n    }\n    this.nodeMap.set(node2, (this.nodeMap.get(node2) || /* @__PURE__ */ new Set()).add(buffer));\n  }\n  destroy() {\n  }\n}\nlet wrappedEmit;\nlet takeFullSnapshot$1;\nlet canvasManager;\nlet recording = false;\ntry {\n  if (Array.from([1], (x2) => x2 * 2)[0] !== 2) {\n    const cleanFrame = document.createElement(\"iframe\");\n    document.body.appendChild(cleanFrame);\n    Array.from = ((_a = cleanFrame.contentWindow) == null ? void 0 : _a.Array.from) || Array.from;\n    document.body.removeChild(cleanFrame);\n  }\n} catch (err) {\n  console.debug(\"Unable to override Array.from\", err);\n}\nconst mirror = createMirror$2();\nfunction record(options = {}) {\n  const {\n    emit,\n    checkoutEveryNms,\n    checkoutEveryNth,\n    blockClass = \"rr-block\",\n    blockSelector = null,\n    ignoreClass = \"rr-ignore\",\n    ignoreSelector = null,\n    maskTextClass = \"rr-mask\",\n    maskTextSelector = null,\n    inlineStylesheet = true,\n    maskAllInputs,\n    maskInputOptions: _maskInputOptions,\n    slimDOMOptions: _slimDOMOptions,\n    maskInputFn,\n    maskTextFn,\n    hooks,\n    packFn,\n    sampling = {},\n    dataURLOptions = {},\n    mousemoveWait,\n    recordDOM = true,\n    recordCanvas = false,\n    recordCrossOriginIframes = false,\n    recordAfter = options.recordAfter === \"DOMContentLoaded\" ? options.recordAfter : \"load\",\n    userTriggeredOnInput = false,\n    collectFonts = false,\n    inlineImages = false,\n    plugins,\n    keepIframeSrcFn = () => false,\n    ignoreCSSAttributes = /* @__PURE__ */ new Set([]),\n    errorHandler: errorHandler2\n  } = options;\n  registerErrorHandler(errorHandler2);\n  const inEmittingFrame = recordCrossOriginIframes ? window.parent === window : true;\n  let passEmitsToParent = false;\n  if (!inEmittingFrame) {\n    try {\n      if (window.parent.document) {\n        passEmitsToParent = false;\n      }\n    } catch (e2) {\n      passEmitsToParent = true;\n    }\n  }\n  if (inEmittingFrame && !emit) {\n    throw new Error(\"emit function is required\");\n  }\n  if (!inEmittingFrame && !passEmitsToParent) {\n    return () => {\n    };\n  }\n  if (mousemoveWait !== void 0 && sampling.mousemove === void 0) {\n    sampling.mousemove = mousemoveWait;\n  }\n  mirror.reset();\n  const maskInputOptions = maskAllInputs === true ? {\n    color: true,\n    date: true,\n    \"datetime-local\": true,\n    email: true,\n    month: true,\n    number: true,\n    range: true,\n    search: true,\n    tel: true,\n    text: true,\n    time: true,\n    url: true,\n    week: true,\n    textarea: true,\n    select: true,\n    password: true\n  } : _maskInputOptions !== void 0 ? _maskInputOptions : { password: true };\n  const slimDOMOptions = slimDOMDefaults(_slimDOMOptions);\n  polyfill$1();\n  let lastFullSnapshotEvent;\n  let incrementalSnapshotCount = 0;\n  const eventProcessor = (e2) => {\n    for (const plugin3 of plugins || []) {\n      if (plugin3.eventProcessor) {\n        e2 = plugin3.eventProcessor(e2);\n      }\n    }\n    if (packFn && // Disable packing events which will be emitted to parent frames.\n    !passEmitsToParent) {\n      e2 = packFn(e2);\n    }\n    return e2;\n  };\n  wrappedEmit = (r2, isCheckout) => {\n    var _a2;\n    const e2 = r2;\n    e2.timestamp = nowTimestamp();\n    if (((_a2 = mutationBuffers[0]) == null ? void 0 : _a2.isFrozen()) && e2.type !== EventType.FullSnapshot && !(e2.type === EventType.IncrementalSnapshot && e2.data.source === IncrementalSource.Mutation)) {\n      mutationBuffers.forEach((buf) => buf.unfreeze());\n    }\n    if (inEmittingFrame) {\n      emit == null ? void 0 : emit(eventProcessor(e2), isCheckout);\n    } else if (passEmitsToParent) {\n      const message = {\n        type: \"rrweb\",\n        event: eventProcessor(e2),\n        origin: window.location.origin,\n        isCheckout\n      };\n      window.parent.postMessage(message, \"*\");\n    }\n    if (e2.type === EventType.FullSnapshot) {\n      lastFullSnapshotEvent = e2;\n      incrementalSnapshotCount = 0;\n    } else if (e2.type === EventType.IncrementalSnapshot) {\n      if (e2.data.source === IncrementalSource.Mutation && e2.data.isAttachIframe) {\n        return;\n      }\n      incrementalSnapshotCount++;\n      const exceedCount = checkoutEveryNth && incrementalSnapshotCount >= checkoutEveryNth;\n      const exceedTime = checkoutEveryNms && e2.timestamp - lastFullSnapshotEvent.timestamp > checkoutEveryNms;\n      if (exceedCount || exceedTime) {\n        takeFullSnapshot$1(true);\n      }\n    }\n  };\n  const wrappedMutationEmit = (m) => {\n    wrappedEmit({\n      type: EventType.IncrementalSnapshot,\n      data: {\n        source: IncrementalSource.Mutation,\n        ...m\n      }\n    });\n  };\n  const wrappedScrollEmit = (p) => wrappedEmit({\n    type: EventType.IncrementalSnapshot,\n    data: {\n      source: IncrementalSource.Scroll,\n      ...p\n    }\n  });\n  const wrappedCanvasMutationEmit = (p) => wrappedEmit({\n    type: EventType.IncrementalSnapshot,\n    data: {\n      source: IncrementalSource.CanvasMutation,\n      ...p\n    }\n  });\n  const wrappedAdoptedStyleSheetEmit = (a2) => wrappedEmit({\n    type: EventType.IncrementalSnapshot,\n    data: {\n      source: IncrementalSource.AdoptedStyleSheet,\n      ...a2\n    }\n  });\n  const stylesheetManager = new StylesheetManager({\n    mutationCb: wrappedMutationEmit,\n    adoptedStyleSheetCb: wrappedAdoptedStyleSheetEmit\n  });\n  const iframeManager = new IframeManager({\n    mirror,\n    mutationCb: wrappedMutationEmit,\n    stylesheetManager,\n    recordCrossOriginIframes,\n    wrappedEmit\n  });\n  for (const plugin3 of plugins || []) {\n    if (plugin3.getMirror)\n      plugin3.getMirror({\n        nodeMirror: mirror,\n        crossOriginIframeMirror: iframeManager.crossOriginIframeMirror,\n        crossOriginIframeStyleMirror: iframeManager.crossOriginIframeStyleMirror\n      });\n  }\n  const processedNodeManager = new ProcessedNodeManager();\n  canvasManager = new CanvasManager({\n    recordCanvas,\n    mutationCb: wrappedCanvasMutationEmit,\n    win: window,\n    blockClass,\n    blockSelector,\n    mirror,\n    sampling: sampling.canvas,\n    dataURLOptions\n  });\n  const shadowDomManager = new ShadowDomManager({\n    mutationCb: wrappedMutationEmit,\n    scrollCb: wrappedScrollEmit,\n    bypassOptions: {\n      blockClass,\n      blockSelector,\n      maskTextClass,\n      maskTextSelector,\n      inlineStylesheet,\n      maskInputOptions,\n      dataURLOptions,\n      maskTextFn,\n      maskInputFn,\n      recordCanvas,\n      inlineImages,\n      sampling,\n      slimDOMOptions,\n      iframeManager,\n      stylesheetManager,\n      canvasManager,\n      keepIframeSrcFn,\n      processedNodeManager\n    },\n    mirror\n  });\n  takeFullSnapshot$1 = (isCheckout = false) => {\n    if (!recordDOM) {\n      return;\n    }\n    wrappedEmit(\n      {\n        type: EventType.Meta,\n        data: {\n          href: window.location.href,\n          width: getWindowWidth(),\n          height: getWindowHeight()\n        }\n      },\n      isCheckout\n    );\n    stylesheetManager.reset();\n    shadowDomManager.init();\n    mutationBuffers.forEach((buf) => buf.lock());\n    const node2 = snapshot(document, {\n      mirror,\n      blockClass,\n      blockSelector,\n      maskTextClass,\n      maskTextSelector,\n      inlineStylesheet,\n      maskAllInputs: maskInputOptions,\n      maskTextFn,\n      maskInputFn,\n      slimDOM: slimDOMOptions,\n      dataURLOptions,\n      recordCanvas,\n      inlineImages,\n      onSerialize: (n2) => {\n        if (isSerializedIframe(n2, mirror)) {\n          iframeManager.addIframe(n2);\n        }\n        if (isSerializedStylesheet(n2, mirror)) {\n          stylesheetManager.trackLinkElement(n2);\n        }\n        if (hasShadowRoot(n2)) {\n          shadowDomManager.addShadowRoot(index.shadowRoot(n2), document);\n        }\n      },\n      onIframeLoad: (iframe, childSn) => {\n        iframeManager.attachIframe(iframe, childSn);\n        shadowDomManager.observeAttachShadow(iframe);\n      },\n      onStylesheetLoad: (linkEl, childSn) => {\n        stylesheetManager.attachLinkElement(linkEl, childSn);\n      },\n      keepIframeSrcFn\n    });\n    if (!node2) {\n      return console.warn(\"Failed to snapshot the document\");\n    }\n    wrappedEmit(\n      {\n        type: EventType.FullSnapshot,\n        data: {\n          node: node2,\n          initialOffset: getWindowScroll(window)\n        }\n      },\n      isCheckout\n    );\n    mutationBuffers.forEach((buf) => buf.unlock());\n    if (document.adoptedStyleSheets && document.adoptedStyleSheets.length > 0)\n      stylesheetManager.adoptStyleSheets(\n        document.adoptedStyleSheets,\n        mirror.getId(document)\n      );\n  };\n  try {\n    const handlers = [];\n    const observe = (doc) => {\n      var _a2;\n      return callbackWrapper(initObservers)(\n        {\n          mutationCb: wrappedMutationEmit,\n          mousemoveCb: (positions, source) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source,\n              positions\n            }\n          }),\n          mouseInteractionCb: (d) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.MouseInteraction,\n              ...d\n            }\n          }),\n          scrollCb: wrappedScrollEmit,\n          viewportResizeCb: (d) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.ViewportResize,\n              ...d\n            }\n          }),\n          inputCb: (v2) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.Input,\n              ...v2\n            }\n          }),\n          mediaInteractionCb: (p) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.MediaInteraction,\n              ...p\n            }\n          }),\n          styleSheetRuleCb: (r2) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.StyleSheetRule,\n              ...r2\n            }\n          }),\n          styleDeclarationCb: (r2) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.StyleDeclaration,\n              ...r2\n            }\n          }),\n          canvasMutationCb: wrappedCanvasMutationEmit,\n          fontCb: (p) => wrappedEmit({\n            type: EventType.IncrementalSnapshot,\n            data: {\n              source: IncrementalSource.Font,\n              ...p\n            }\n          }),\n          selectionCb: (p) => {\n            wrappedEmit({\n              type: EventType.IncrementalSnapshot,\n              data: {\n                source: IncrementalSource.Selection,\n                ...p\n              }\n            });\n          },\n          customElementCb: (c2) => {\n            wrappedEmit({\n              type: EventType.IncrementalSnapshot,\n              data: {\n                source: IncrementalSource.CustomElement,\n                ...c2\n              }\n            });\n          },\n          blockClass,\n          ignoreClass,\n          ignoreSelector,\n          maskTextClass,\n          maskTextSelector,\n          maskInputOptions,\n          inlineStylesheet,\n          sampling,\n          recordDOM,\n          recordCanvas,\n          inlineImages,\n          userTriggeredOnInput,\n          collectFonts,\n          doc,\n          maskInputFn,\n          maskTextFn,\n          keepIframeSrcFn,\n          blockSelector,\n          slimDOMOptions,\n          dataURLOptions,\n          mirror,\n          iframeManager,\n          stylesheetManager,\n          shadowDomManager,\n          processedNodeManager,\n          canvasManager,\n          ignoreCSSAttributes,\n          plugins: ((_a2 = plugins == null ? void 0 : plugins.filter((p) => p.observer)) == null ? void 0 : _a2.map((p) => ({\n            observer: p.observer,\n            options: p.options,\n            callback: (payload) => wrappedEmit({\n              type: EventType.Plugin,\n              data: {\n                plugin: p.name,\n                payload\n              }\n            })\n          }))) || []\n        },\n        hooks\n      );\n    };\n    iframeManager.addLoadListener((iframeEl) => {\n      try {\n        handlers.push(observe(iframeEl.contentDocument));\n      } catch (error) {\n        console.warn(error);\n      }\n    });\n    const init = () => {\n      takeFullSnapshot$1();\n      handlers.push(observe(document));\n      recording = true;\n    };\n    if ([\"interactive\", \"complete\"].includes(document.readyState)) {\n      init();\n    } else {\n      handlers.push(\n        on(\"DOMContentLoaded\", () => {\n          wrappedEmit({\n            type: EventType.DomContentLoaded,\n            data: {}\n          });\n          if (recordAfter === \"DOMContentLoaded\") init();\n        })\n      );\n      handlers.push(\n        on(\n          \"load\",\n          () => {\n            wrappedEmit({\n              type: EventType.Load,\n              data: {}\n            });\n            if (recordAfter === \"load\") init();\n          },\n          window\n        )\n      );\n    }\n    return () => {\n      handlers.forEach((handler) => {\n        try {\n          handler();\n        } catch (error) {\n          const msg = String(error).toLowerCase();\n          if (!msg.includes(\"cross-origin\")) {\n            console.warn(error);\n          }\n        }\n      });\n      processedNodeManager.destroy();\n      recording = false;\n      unregisterErrorHandler();\n    };\n  } catch (error) {\n    console.warn(error);\n  }\n}\nrecord.addCustomEvent = (tag, payload) => {\n  if (!recording) {\n    throw new Error(\"please add custom event after start recording\");\n  }\n  wrappedEmit({\n    type: EventType.Custom,\n    data: {\n      tag,\n      payload\n    }\n  });\n};\nrecord.freezePage = () => {\n  mutationBuffers.forEach((buf) => buf.freeze());\n};\nrecord.takeFullSnapshot = (isCheckout) => {\n  if (!recording) {\n    throw new Error(\"please take full snapshot after start recording\");\n  }\n  takeFullSnapshot$1(isCheckout);\n};\nrecord.mirror = mirror;\nvar n;\n!function(t2) {\n  t2[t2.NotStarted = 0] = \"NotStarted\", t2[t2.Running = 1] = \"Running\", t2[t2.Stopped = 2] = \"Stopped\";\n}(n || (n = {}));\nexport {\n  record\n};\n//# sourceMappingURL=record.js.map\n","import { isMobile } from './GleapHelper';\nimport { record } from '@rrweb/record';\n\nexport default class GleapReplayRecorder {\n  startDate = undefined;\n  events = [];\n  bufferSize = 0;\n  stopFunction = undefined;\n  customOptions = {};\n\n  // GleapReplayRecorder singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapReplayRecorder();\n      return this.instance;\n    } else {\n      return this.instance;\n    }\n  }\n\n  constructor() {}\n\n  setOptions(options) {\n    this.customOptions = options;\n  }\n\n  /**\n   * Start replays\n   * @returns\n   */\n  start() {\n    this.stop();\n\n    this.startDate = Date.now();\n    var events = this.events;\n\n    var options = {\n      inlineStylesheet: true,\n      blockClass: 'gl-block',\n      ignoreClass: 'gl-ignore',\n      maskTextClass: 'gl-mask',\n      dataURLOptions: {\n        quality: 0.7,\n      },\n      recordCanvas: false,\n      sampling: {\n        scroll: 150,\n        mouseInteraction: {\n          MouseUp: false,\n          MouseDown: false,\n          Click: true,\n          ContextMenu: true,\n          DblClick: true,\n          Focus: true,\n          Blur: true,\n          TouchStart: true,\n          TouchEnd: false,\n        },\n      },\n      collectFonts: false,\n      recordCrossOriginIframes: false,\n    };\n\n    try {\n      this.stopFunction = record({\n        ...options,\n        ...this.customOptions,\n        emit(rrwebEvent) {\n          const { event } = ensureMaxMessageSize(rrwebEvent);\n          events.push(event);\n        },\n      });\n    } catch (e) {\n      console.error(e);\n    }\n  }\n\n  /**\n   * Stop replays\n   * @returns\n   */\n  stop() {\n    if (this.stopFunction) {\n      this.stopFunction();\n    }\n\n    this.startDate = undefined;\n    this.events = [];\n    this.bufferSize = 0;\n  }\n\n  /**\n   * Get the current replay data\n   * @returns {Promise<void>}\n   */\n  getReplayData() {\n    const replayResult = {\n      startDate: this.startDate,\n      events: this.events,\n      baseUrl: window.location.origin,\n      width: window.innerWidth,\n      height: window.innerHeight,\n      isMobile: isMobile(),\n      type: 'rrweb',\n    };\n\n    return replayResult;\n  }\n}\n\nexport function ensureMaxMessageSize(data) {\n  let stringifiedData = JSON.stringify(data);\n  if (stringifiedData.length > 4000000) {\n    const dataURIRegex = /data:([\\w\\/\\-\\.]+);(\\w+),([^)\"]*)/gim;\n    const matches = stringifiedData.matchAll(dataURIRegex);\n    for (const match of matches) {\n      if (match[1].toLocaleLowerCase().slice(0, 6) === 'image/') {\n        stringifiedData = stringifiedData.replace(\n          match[0],\n          'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAQSURBVHgBAQUA+v8ABRg5/wHSAVZN1mnaAAAAAElFTkSuQmCC'\n        );\n      } else {\n        stringifiedData = stringifiedData.replace(match[0], '');\n      }\n    }\n  }\n  return { event: JSON.parse(stringifiedData), size: stringifiedData.length };\n}\n","export class ScreenDrawer {\n  rerender;\n  svgElement = null;\n  path = null;\n  strPath;\n  strokeWidth = 12;\n  strokeWidthRect = 6;\n  bufferSize = 4;\n  buffer = [];\n  startPoint = null;\n  tool = 'rect';\n  color = '#EB144C';\n  mouseDown = null;\n  mouseMove = null;\n  mouseUp = null;\n  resizeListener = null;\n  pathBuffer = [];\n\n  constructor(rerender) {\n    const self = this;\n\n    this.rerender = rerender;\n\n    this.svgElement = document.querySelector('.bb-capture-svg');\n    this.svgElement.style.minHeight = `${document.documentElement.scrollHeight}px`;\n\n    // Window resize listener.\n    this.resizeListener = function (e) {\n      self.svgElement.style.minHeight = `${document.documentElement.scrollHeight}px`;\n    };\n    window.addEventListener('resize', this.resizeListener, true);\n\n    this.mouseDown = function (e) {\n      e.preventDefault();\n\n      const colorpicker = document.querySelector('.bb-capture-toolbar-item-colorpicker');\n      if (colorpicker) {\n        colorpicker.style.display = 'none';\n      }\n\n      self.fadeOutToolbar();\n      if (self.tool === 'pen' || self.tool === 'blur') {\n        self.mouseDownPen(e);\n      }\n      if (self.tool === 'rect') {\n        self.mouseDownRect(e);\n      }\n    };\n\n    this.mouseMove = function (e) {\n      e.preventDefault();\n      if (self.tool === 'pen' || self.tool === 'blur') {\n        self.mouseMovePen(e);\n      }\n      if (self.tool === 'rect') {\n        self.mouseMoveRect(e);\n      }\n    };\n\n    this.mouseUp = function (e) {\n      e.preventDefault();\n      self.fadeInToolbar();\n      if (self.tool === 'pen' || self.tool === 'blur') {\n        self.mouseUpPen(e);\n      }\n      if (self.tool === 'rect') {\n        self.mouseUpRect(e);\n      }\n    };\n\n    this.svgElement.addEventListener('mousedown', this.mouseDown);\n    this.svgElement.addEventListener('mousemove', this.mouseMove);\n    this.svgElement.addEventListener('mouseup', this.mouseUp);\n    this.svgElement.addEventListener('touchstart', this.mouseDown, false);\n    this.svgElement.addEventListener('touchmove', this.mouseMove, false);\n    this.svgElement.addEventListener('touchend', this.mouseUp, false);\n\n    setTimeout(() => {\n      this.rerender();\n    }, 100);\n  }\n\n  clear() {\n    if (this.svgElement) {\n      while (this.svgElement.firstChild) {\n        this.svgElement.firstChild.remove();\n      }\n    }\n  }\n\n  destroy() {\n    this.svgElement.removeEventListener('mousedown', this.mouseDown);\n    this.svgElement.removeEventListener('mousemove', this.mouseMove);\n    this.svgElement.removeEventListener('mouseup', this.mouseUp);\n    this.svgElement.removeEventListener('touchstart', this.mouseDown);\n    this.svgElement.removeEventListener('touchmove', this.mouseMove);\n    this.svgElement.removeEventListener('touchend', this.mouseUp);\n    window.removeEventListener('resize', this.resizeListener);\n  }\n\n  mouseUpPen() {\n    if (this.path) {\n      this.path = null;\n    }\n  }\n\n  mouseUpRect() {\n    if (this.path) {\n      this.path = null;\n    }\n  }\n\n  mouseMovePen(e) {\n    if (this.path) {\n      this.appendToBuffer(this.getMousePosition(e));\n      this.updateSvgPath();\n    }\n  }\n\n  mouseMoveRect(e) {\n    if (this.path) {\n      var p = this.getMousePosition(e);\n      var w = Math.abs(p.x - this.startPoint.x);\n      var h = Math.abs(p.y - this.startPoint.y);\n      var x = p.x;\n      var y = p.y;\n      if (p.x > this.startPoint.x) {\n        x = this.startPoint.x;\n      }\n      if (p.y > this.startPoint.y) {\n        y = this.startPoint.y;\n      }\n\n      this.path.setAttributeNS(null, 'x', x);\n      this.path.setAttributeNS(null, 'y', y);\n      this.path.setAttributeNS(null, 'width', w);\n      this.path.setAttributeNS(null, 'height', h);\n    }\n  }\n\n  mouseDownRect(e) {\n    this.path = document.createElementNS('http://www.w3.org/2000/svg', 'rect');\n    this.path.setAttribute('fill', 'none');\n    this.path.setAttribute('stroke', this.color);\n    this.path.setAttribute('stroke-linecap', 'round');\n    this.path.setAttribute('stroke-width', this.strokeWidthRect);\n\n    this.startPoint = this.getMousePosition(e);\n    this.appendPathToSvg(this.path);\n  }\n\n  mouseDownPen(e) {\n    var color = this.color + 'AA';\n    var strokeWidth = this.strokeWidth;\n\n    if (this.tool === 'blur') {\n      color = '#000000';\n      strokeWidth = 40;\n    }\n\n    this.path = document.createElementNS('http://www.w3.org/2000/svg', 'path');\n    this.path.setAttribute('fill', 'none');\n    this.path.setAttribute('stroke', color);\n    this.path.setAttribute('stroke-linecap', 'round');\n    this.path.setAttribute('stroke-width', strokeWidth);\n    this.buffer = [];\n    var pt = this.getMousePosition(e);\n    this.appendToBuffer(pt);\n    this.strPath = 'M' + pt.x + ' ' + pt.y;\n    this.path.setAttribute('d', this.strPath);\n    this.appendPathToSvg(this.path);\n  }\n\n  setTool(tool) {\n    this.tool = tool;\n  }\n\n  setColor(color) {\n    this.color = color;\n  }\n\n  getMousePosition(e) {\n    if (e.touches && e.touches.length > 0) {\n      return {\n        x: e.touches[0].clientX,\n        y: e.touches[0].clientY,\n      };\n    }\n\n    return {\n      x: e.clientX,\n      y: e.clientY,\n    };\n  }\n\n  // Calculate the average point, starting at offset in the buffer\n  getAveragePoint(offset) {\n    var len = this.buffer.length;\n    if (len % 2 === 1 || len >= this.bufferSize) {\n      var totalX = 0;\n      var totalY = 0;\n      var pt, i;\n      var count = 0;\n      for (i = offset; i < len; i++) {\n        count++;\n        pt = this.buffer[i];\n        totalX += pt.x;\n        totalY += pt.y;\n      }\n      return {\n        x: totalX / count,\n        y: totalY / count,\n      };\n    }\n    return null;\n  }\n\n  updateSvgPath() {\n    var pt = this.getAveragePoint(0);\n\n    if (pt) {\n      // Get the smoothed part of the path that will not change\n      this.strPath += ' L' + pt.x + ' ' + pt.y;\n\n      // Get the last part of the path (close to the current mouse position)\n      // This part will change if the mouse moves again\n      var tmpPath = '';\n      for (var offset = 2; offset < this.buffer.length; offset += 2) {\n        pt = this.getAveragePoint(offset);\n        tmpPath += ' L' + pt.x + ' ' + pt.y;\n      }\n\n      // Set the complete current path coordinates\n      this.path.setAttribute('d', this.strPath + tmpPath);\n    }\n  }\n\n  appendToBuffer(pt) {\n    this.buffer.push(pt);\n    while (this.buffer.length > this.bufferSize) {\n      this.buffer.shift();\n    }\n  }\n\n  appendPathToSvg(path) {\n    this.svgElement.appendChild(path);\n    this.pathBuffer.push(path);\n    this.rerender();\n  }\n\n  removeLastAddedPathFromSvg() {\n    if (this.pathBuffer.length <= 0 || !this.svgElement) {\n      return;\n    }\n\n    this.svgElement.removeChild(this.pathBuffer[this.pathBuffer.length - 1]);\n\n    this.pathBuffer.pop();\n\n    this.rerender();\n  }\n\n  fadeOutToolbar() {\n    var fadeTarget = document.querySelector('.bb-capture-toolbar');\n    if (fadeTarget) {\n      fadeTarget.style.opacity = 0;\n      fadeTarget.style.pointerEvents = 'none';\n    }\n  }\n\n  fadeInToolbar() {\n    var fadeTarget = document.querySelector('.bb-capture-toolbar');\n    if (fadeTarget) {\n      fadeTarget.style.opacity = 1;\n      fadeTarget.style.pointerEvents = 'auto';\n    }\n  }\n}\n","export class GleapScrollStopper {\n  keys = { 37: 1, 38: 1, 39: 1, 40: 1 };\n  supportsPassive = false;\n  wheelOpt = this.supportsPassive ? { passive: false } : false;\n  wheelEvent = 'onwheel' in document.createElement('div') ? 'wheel' : 'mousewheel';\n  scrollDisabled = false;\n\n  // GleapScrollStopper singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapScrollStopper();\n      return this.instance;\n    } else {\n      return this.instance;\n    }\n  }\n\n  constructor() {\n    const self = this;\n    try {\n      window.addEventListener(\n        'test',\n        null,\n        Object.defineProperty({}, 'passive', {\n          get: function () {\n            self.supportsPassive = true;\n            self.wheelOpt = self.supportsPassive ? { passive: false } : false;\n          },\n        })\n      );\n    } catch (e) {}\n  }\n\n  preventDefault(e) {\n    e.preventDefault();\n  }\n\n  preventDefaultForScrollKeys(e) {\n    if (this.keys && this.keys[e.keyCode]) {\n      this.preventDefault(e);\n      return false;\n    }\n  }\n\n  static disableScroll() {\n    const instance = this.getInstance();\n    if (instance.scrollDisabled) {\n      return;\n    }\n\n    instance.scrollDisabled = true;\n\n    window.addEventListener('DOMMouseScroll', instance.preventDefault, false); // older FF\n    window.addEventListener(instance.wheelEvent, instance.preventDefault, instance.wheelOpt); // modern desktop\n    window.addEventListener('touchmove', instance.preventDefault, instance.wheelOpt); // mobile\n    window.addEventListener('keydown', instance.preventDefaultForScrollKeys, false);\n  }\n\n  static enableScroll() {\n    const instance = this.getInstance();\n    if (!instance.scrollDisabled) {\n      return;\n    }\n\n    instance.scrollDisabled = false;\n    window.removeEventListener('DOMMouseScroll', instance.preventDefault, false);\n    window.removeEventListener(instance.wheelEvent, instance.preventDefault, instance.wheelOpt);\n    window.removeEventListener('touchmove', instance.preventDefault, instance.wheelOpt);\n    window.removeEventListener('keydown', instance.preventDefaultForScrollKeys, false);\n  }\n}\n","import Gleap, { GleapTranslationManager, GleapFrameManager } from './Gleap';\nimport { ScreenDrawer } from './ScreenDrawer';\nimport { GleapScrollStopper } from './GleapScrollStopper';\nimport { GleapScreenRecorder } from './GleapScreenRecorder';\nimport { loadIcon } from './UI';\n\nexport default class GleapMarkerManager {\n  type = 'screenshot';\n  dragCursor = null;\n  screenRecorder = null;\n  callback = null;\n  screenDrawer = null;\n  escListener = null;\n  pageLeaveListener = null;\n  overrideLanguage = Gleap.getInstance().overrideLanguage;\n\n  constructor(type) {\n    this.type = type;\n  }\n\n  hideWidgetUI() {\n    const feedbackButton = document.querySelector('.bb-feedback-button');\n    if (feedbackButton) {\n      feedbackButton.style.display = 'none';\n    }\n\n    const dialogUI = document.querySelector('.bb-feedback-dialog-container');\n    if (dialogUI) {\n      dialogUI.style.display = 'none';\n    }\n  }\n\n  showWidgetUI() {\n    if (this.type === 'screenshot') {\n      GleapScrollStopper.enableScroll();\n    }\n\n    // Stop screenrecording.\n    if (this.screenRecorder) {\n      this.screenRecorder.stopScreenRecording();\n    }\n\n    // Unregister ESC listener\n    this.unregisterListeners();\n\n    // Cleanup mouse pointer\n    this.cleanupMousePointer();\n\n    if (this.screenDrawer) {\n      this.screenDrawer.destroy();\n    }\n\n    // Remove the toolbar UI\n    const dialog = document.querySelector('.bb-capture-toolbar');\n    if (dialog) {\n      dialog.remove();\n    }\n\n    // Capture SVG ref\n    const captureSVG = document.querySelector('.bb-capture-svg');\n    if (captureSVG) {\n      captureSVG.classList.add('bb-capture-svg--preview');\n    }\n\n    // Remove the preview UI\n    const videoPreviewContainer = document.querySelector('.bb-capture-preview');\n    if (videoPreviewContainer) {\n      videoPreviewContainer.remove();\n    }\n\n    // Feedback button\n    const feedbackButton = document.querySelector('.bb-feedback-button');\n    if (feedbackButton) {\n      feedbackButton.style.display = 'flex';\n    }\n\n    // Feedback dialog container\n    const dialogUI = document.querySelector('.bb-feedback-dialog-container');\n    if (dialogUI) {\n      dialogUI.style.display = 'block';\n    }\n\n    // Dismiss button\n    const dismissUI = document.querySelector('.bb-capture-dismiss');\n    if (dismissUI) {\n      dismissUI.style.display = 'none';\n    }\n\n    // Hide the color picker\n    const colorPicker = document.querySelector('.bb-capture-toolbar-item-colorpicker');\n    if (colorPicker) {\n      colorPicker.style.display = 'none';\n    }\n\n    // Border layer\n    const borderLayer = document.querySelector('.bb-capture-editor-borderlayer');\n    if (borderLayer) {\n      borderLayer.style.display = 'none';\n    }\n  }\n\n  clear() {\n    const captureEditor = document.querySelector('.bb-capture-editor');\n    if (captureEditor) {\n      captureEditor.remove();\n    }\n  }\n\n  setMouseMove(x, y) {\n    if (!this.dragCursor) {\n      return;\n    }\n\n    this.dragCursor.style.left = `${x + 6}px`;\n    this.dragCursor.style.top = `${y - 26}px`;\n    this.dragCursor.style.right = null;\n  }\n\n  mouseMoveEventHandler(e) {\n    const x = e.clientX;\n    const y = e.clientY;\n    this.setMouseMove(x, y);\n  }\n\n  touchMoveEventHandler(e) {\n    const x = e.touches[0].clientX;\n    const y = e.touches[0].clientY;\n    this.setMouseMove(x, y);\n  }\n\n  setupMousePointer() {\n    const self = this;\n    this.dragCursor = document.querySelector('.bb-capture-editor-drag-info');\n    const captureSVG = document.querySelector('.bb-capture-svg');\n    captureSVG.addEventListener('mouseenter', (e) => {\n      self.dragCursor.style.opacity = 1;\n    });\n\n    captureSVG.addEventListener('mouseleave', (e) => {\n      self.dragCursor.style.opacity = 0;\n    });\n\n    document.documentElement.addEventListener('mousemove', this.mouseMoveEventHandler.bind(this));\n    document.documentElement.addEventListener('touchmove', this.touchMoveEventHandler.bind(this));\n  }\n\n  cleanupMousePointer() {\n    document.documentElement.removeEventListener('mousemove', this.mouseMoveEventHandler);\n    document.documentElement.removeEventListener('touchmove', this.touchMoveEventHandler);\n\n    // Clean up toolbar drag listeners\n    const dragHandle = document.querySelector(\".bb-capture-toolbar-item[data-type='drag']\");\n    if (dragHandle) {\n      dragHandle.removeEventListener('mousedown', this.dragStart);\n      dragHandle.removeEventListener('touchstart', this.dragStart);\n      document.removeEventListener('mousemove', this.drag);\n      document.removeEventListener('touchmove', this.drag);\n      document.removeEventListener('mouseup', this.dragEnd);\n      document.removeEventListener('touchend', this.dragEnd);\n    }\n\n    if (this.dragCursor) {\n      this.dragCursor.remove();\n    }\n  }\n\n  createEditorUI() {\n    // Add HTML for drawing and recording\n    var bugReportingEditor = document.createElement('div');\n    bugReportingEditor.className = 'bb-capture-editor';\n    bugReportingEditor.innerHTML = `\n          <div class=\"bb-capture-editor-borderlayer\"></div>\n          <svg class=\"bb-capture-svg\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" version=\"1.1\" xml:space=\"preserve\"></svg>\n          <div class=\"bb-capture-dismiss\">${loadIcon('dismiss')}</div>\n          <div class='bb-capture-editor-drag-info'>${loadIcon('rect')}</div>\n          <div class=\"bb-capture-toolbar\">\n            <div class=\"bb-capture-toolbar-item bb-capture-item-rec bb-capture-toolbar-item-tool drag-handle-item\" data-type=\"drag\">\n              ${loadIcon('drag')}\n            </div>\n            ${\n              this.type === 'capture'\n                ? `<div class=\"bb-capture-toolbar-item bb-capture-item-rec bb-capture-toolbar-item-recording\" data-type=\"recording\">\n                  ${loadIcon('recorderon')}\n                  ${loadIcon('recorderoff')}\n                  <span class=\"bb-tooltip bb-tooltip-screen-recording\"></span>\n                </div>\n                <div class=\"bb-capture-toolbar-item bb-capture-item-rec\" data-type=\"mic\">\n                  ${loadIcon('mic')}\n                  <span class=\"bb-tooltip bb-tooltip-audio-recording\"></span>\n                </div>\n                <div class=\"bb-capture-toolbar-item-timer bb-capture-item-rec\">2:00</div>\n                <div class=\"bb-capture-toolbar-item-spacer\"></div>\n                <div class=\"bb-capture-toolbar-item bb-capture-toolbar-drawingitem bb-capture-toolbar-item-tool\" data-type=\"pointer\">\n                  ${loadIcon('pointer')}\n                </div>`\n                : ''\n            }\n            <div class=\"bb-capture-toolbar-item bb-capture-toolbar-drawingitem bb-capture-toolbar-item-tool bb-capture-toolbar-item--active\" data-type=\"rect\">\n              ${loadIcon('rect')}\n            </div>\n            <div class=\"bb-capture-toolbar-item bb-capture-toolbar-drawingitem bb-capture-toolbar-item-tool\" data-type=\"pen\">\n              ${loadIcon('pen')}\n            </div>\n            <div class=\"bb-capture-toolbar-item bb-capture-toolbar-drawingitem bb-capture-toolbar-item-tool\" data-type=\"blur\">\n              ${loadIcon('blur')}\n            </div>\n            <div class=\"bb-capture-toolbar-item bb-capture-toolbar-drawingitem\" data-type=\"colorpicker\">\n              <div class=\"bb-capture-toolbar-item-selectedcolor\"></div>\n              <span class=\"bb-tooltip\">${GleapTranslationManager.translateText(`pickAColor`)}</span>\n            </div>\n            <div class=\"bb-capture-toolbar-item bb-capture-toolbar-drawingitem bb-capture-toolbar-item-tool\" data-type=\"undo\">\n              ${loadIcon('undo')}\n              <span class=\"bb-tooltip\">${GleapTranslationManager.translateText(`undo`)}</span>\n            </div>\n            ${\n              this.type !== 'capture'\n                ? `<div class=\"bb-capture-button-next\">${GleapTranslationManager.translateText(`next`)}</div>`\n                : ''\n            }\n          </div>\n          <div class=\"bb-capture-toolbar-item-colorpicker\">\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#EB144C\"></div>\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#FF6705\"></div>\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#FDB903\"></div>\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#9900EE\"></div>\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#00D082\"></div>\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#0A93E4\"></div>\n            <div class=\"bb-capture-toolbar-item-color\" data-color=\"#CCCCCC\"></div>\n          </div>\n          <div class=\"bb-capture-preview\">\n            <div class=\"bb-capture-preview-inner\">\n              <video controls muted autoplay></video>\n              <div class=\"bb-capture-preview-buttons\">\n                <div class=\"bb-capture-preview-retrybutton\">${GleapTranslationManager.translateText(`retry`)}</div>\n                <div class=\"bb-capture-preview-sendbutton\">${GleapTranslationManager.translateText(`next`)}</div>\n              </div>\n            </div>\n          </div>\n        `;\n    document.body.appendChild(bugReportingEditor);\n\n    // Set RTL layout\n    bugReportingEditor.setAttribute('dir', GleapTranslationManager.getInstance().isRTLLayout ? 'rtl' : 'ltr');\n  }\n\n  showNextStep = function () {\n    // Adapt the UI\n    this.showWidgetUI();\n\n    if (this.callback) {\n      GleapFrameManager.getInstance().sendMessage({\n        name: 'set-form-data',\n        data: {\n          formKey: 'capture',\n          data: {\n            value: this.type,\n            dirty: true,\n          },\n        },\n      });\n      this.callback(true);\n    }\n  };\n\n  unregisterListeners() {\n    if (this.escListener) {\n      document.removeEventListener('keydown', this.escListener);\n    }\n\n    if (this.pageLeaveListener) {\n      window.removeEventListener('beforeunload', this.pageLeaveListener);\n    }\n  }\n\n  registerListeners() {\n    const self = this;\n\n    // Esc listener\n    this.escListener = function (evt) {\n      evt = evt || window.event;\n      var isEscape = false;\n      var isEnter = false;\n      if ('key' in evt) {\n        isEscape = evt.key === 'Escape';\n        isEnter = evt.key === 'Enter';\n      }\n      if (isEscape) {\n        self.dismiss();\n      }\n      if (self.type === 'screenshot' && isEnter) {\n        self.showNextStep();\n      }\n    };\n    document.addEventListener('keydown', this.escListener);\n\n    // Page leave listener\n    this.pageLeaveListener = function (event) {\n      event.preventDefault();\n      event.returnValue = '';\n    };\n    window.addEventListener('beforeunload', this.pageLeaveListener);\n  }\n\n  show(callback) {\n    this.callback = callback;\n    const self = this;\n\n    // Register for listeners\n    this.registerListeners();\n\n    // Hide widget UI\n    this.hideWidgetUI();\n\n    // Create the editor UI\n    this.createEditorUI();\n\n    // Setup the mouse pointer\n    this.setupMousePointer();\n\n    // Setup screenshot data\n    if (this.type === 'screenshot') {\n      // Overwrite snapshot position\n      Gleap.getInstance().setGlobalDataItem('snapshotPosition', {\n        x: window.scrollX,\n        y: window.scrollY,\n      });\n\n      // Disable scroll\n      GleapScrollStopper.disableScroll();\n    } else {\n      // Setup screen recording\n      this.setupScreenRecording();\n    }\n\n    // Hook up the drawing.\n    this.screenDrawer = new ScreenDrawer(this.captureScreenDrawerRerender.bind(this));\n\n    this.setupColorPicker();\n    this.setupToolbar();\n  }\n\n  setupColorPicker() {\n    const self = this;\n    const selectedColor = document.querySelector('.bb-capture-toolbar-item-selectedcolor');\n    const colorItems = document.querySelectorAll('.bb-capture-toolbar-item-color');\n    const colorpicker = document.querySelector('.bb-capture-toolbar-item-colorpicker');\n\n    for (var i = 0; i < colorItems.length; i++) {\n      const colorItem = colorItems[i];\n      const hexColor = colorItem.getAttribute('data-color');\n      colorItem.style.backgroundColor = hexColor;\n      colorItem.onclick = function () {\n        if (colorItem) {\n          self.screenDrawer.setColor(hexColor);\n          if (colorpicker) {\n            colorpicker.style.display = 'none';\n          }\n          selectedColor.style.backgroundColor = colorItem.style.backgroundColor;\n          GleapMarkerManager.setPenColor(hexColor);\n        }\n      };\n    }\n  }\n\n  static setPenColor(hexColor) {\n    const penTips = document.querySelectorAll('.bb-pen-tip');\n    for (var j = 0; j < penTips.length; j++) {\n      penTips[j].style.fill = hexColor;\n    }\n  }\n\n  dismiss() {\n    this.showWidgetUI();\n\n    if (this.callback) {\n      this.callback(false);\n    }\n  }\n\n  setupToolbar() {\n    const self = this;\n    const toolbar = document.querySelector('.bb-capture-toolbar');\n    let isDragging = false;\n    let currentX;\n    let currentY;\n    let initialX;\n    let initialY;\n    let xOffset = 0;\n    let yOffset = 0;\n\n    const getTransformValues = () => {\n      const transform = window.getComputedStyle(toolbar).transform;\n      if (transform === 'none') return { x: 0, y: 0 };\n      const matrix = new DOMMatrix(transform);\n      return { x: matrix.m41, y: matrix.m42 };\n    };\n\n    this.dragStart = (e) => {\n      const { x, y } = getTransformValues();\n      xOffset = x;\n      yOffset = y;\n\n      if (e.type === 'mousedown') {\n        initialX = e.clientX - xOffset;\n        initialY = e.clientY - yOffset;\n      } else {\n        initialX = e.touches[0].clientX - xOffset;\n        initialY = e.touches[0].clientY - yOffset;\n      }\n      isDragging = true;\n    };\n\n    this.dragEnd = () => {\n      isDragging = false;\n    };\n\n    this.drag = (e) => {\n      if (isDragging) {\n        e.preventDefault();\n        if (e.type === 'mousemove') {\n          currentX = e.clientX - initialX;\n          currentY = e.clientY - initialY;\n        } else {\n          currentX = e.touches[0].clientX - initialX;\n          currentY = e.touches[0].clientY - initialY;\n        }\n\n        xOffset = currentX;\n        yOffset = currentY;\n\n        toolbar.style.transform = `translate(${currentX}px, ${currentY}px)`;\n      }\n    };\n\n    const dragHandle = document.querySelector(\".bb-capture-toolbar-item[data-type='drag']\");\n\n    dragHandle.addEventListener('mousedown', this.dragStart);\n    dragHandle.addEventListener('touchstart', this.dragStart);\n    document.addEventListener('mousemove', this.drag);\n    document.addEventListener('touchmove', this.drag);\n    document.addEventListener('mouseup', this.dragEnd);\n    document.addEventListener('touchend', this.dragEnd);\n\n    // Hook up dismiss button\n    const dismissButton = document.querySelector('.bb-capture-dismiss');\n    dismissButton.onclick = function () {\n      self.dismiss();\n    };\n\n    // Hook up send button\n    const nextButton = document.querySelector('.bb-capture-button-next');\n    if (nextButton) {\n      nextButton.onclick = this.showNextStep.bind(this);\n    }\n\n    const colorpicker = document.querySelector('.bb-capture-toolbar-item-colorpicker');\n\n    // Capture SVG ref\n    const captureSVG = document.querySelector('.bb-capture-svg');\n\n    const chooseTool = function (type, toolbarItem) {\n      const toolbarTools = document.querySelectorAll('.bb-capture-toolbar-item-tool');\n      for (let j = 0; j < toolbarTools.length; j++) {\n        toolbarTools[j].classList.remove('bb-capture-toolbar-item--active');\n      }\n      toolbarItem.classList.add('bb-capture-toolbar-item--active');\n      self.screenDrawer.setTool(type);\n      self.dragCursor.innerHTML = '';\n      if (type === 'pointer') {\n        captureSVG.style.pointerEvents = 'none';\n      } else {\n        captureSVG.style.pointerEvents = 'auto';\n        try {\n          var svgClone = toolbarItem.querySelector('svg').cloneNode(true);\n          if (svgClone && self.dragCursor) {\n            self.dragCursor.appendChild(svgClone);\n          }\n        } catch (exp) {}\n      }\n    };\n\n    // Setup toolbar items\n    var toolbarItems = document.querySelectorAll('.bb-capture-toolbar-item');\n    for (var i = 0; i < toolbarItems.length; i++) {\n      const toolbarItem = toolbarItems[i];\n      toolbarItem.onclick = function () {\n        const type = toolbarItem.getAttribute('data-type');\n        if (colorpicker && type !== 'colorpicker') {\n          colorpicker.style.display = 'none';\n        }\n\n        // Mic & recording buttons\n        if (type === 'mic') {\n          self.screenRecorder.toggleAudio();\n        }\n        if (type === 'recording') {\n          if (self.screenRecorder.isRecording) {\n            self.screenRecorder.stopScreenRecording();\n          } else {\n            self.screenRecorder.startScreenRecording();\n            chooseTool('pointer', document.querySelector(\".bb-capture-toolbar-item[data-type='pointer']\"));\n          }\n        }\n\n        // Marker buttons\n        if (self.type === 'capture' && !self.screenRecorder.isRecording) {\n          // Inactivate buttons.\n          return;\n        }\n        if (type === 'pen' || type === 'blur' || type === 'rect' || type === 'pointer') {\n          chooseTool(type, toolbarItem);\n        }\n        if (type === 'colorpicker') {\n          if (colorpicker.style.display === 'flex') {\n            colorpicker.style.display = 'none';\n          } else {\n            colorpicker.style.display = 'flex';\n          }\n        }\n        if (type === 'undo') {\n          self.screenDrawer.removeLastAddedPathFromSvg();\n        }\n      };\n    }\n  }\n\n  captureScreenDrawerRerender() {\n    if (!this.screenDrawer) {\n      return;\n    }\n\n    const itemInactiveClass = 'bb-capture-editor-item-inactive';\n    const toolbarItems = document.querySelectorAll('.bb-capture-toolbar-item');\n    for (var i = 0; i < toolbarItems.length; i++) {\n      const toolbarItem = toolbarItems[i];\n      const type = toolbarItem.getAttribute('data-type');\n      switch (type) {\n        case 'undo':\n          if (this.screenDrawer.pathBuffer != null && this.screenDrawer.pathBuffer.length > 0) {\n            toolbarItem.classList.remove(itemInactiveClass);\n          } else {\n            toolbarItem.classList.add(itemInactiveClass);\n          }\n          break;\n        default:\n          break;\n      }\n    }\n  }\n\n  captureRenderer() {\n    if (!this.screenRecorder) {\n      return;\n    }\n\n    if (this.screenRecorder.file) {\n      Gleap.getInstance().setGlobalDataItem('screenRecordingData', this.screenRecorder.file);\n    }\n\n    const itemInactiveClass = 'bb-capture-editor-item-inactive';\n    const timerLabel = document.querySelector('.bb-capture-toolbar-item-timer');\n    const toolbarItems = document.querySelectorAll('.bb-capture-toolbar-item');\n    const screenRecordingTooltip = document.querySelector('.bb-tooltip-screen-recording');\n    const audioRecordingTooltip = document.querySelector('.bb-tooltip-audio-recording');\n    const captureEditor = document.querySelector('.bb-capture-editor');\n    const recordingClass = 'bb-capture-editor-recording';\n    const notRecordingClass = 'bb-capture-editor-notrecording';\n    if (this.screenRecorder.isRecording) {\n      captureEditor.classList.add(recordingClass);\n      captureEditor.classList.remove(notRecordingClass);\n    } else {\n      captureEditor.classList.add(notRecordingClass);\n      captureEditor.classList.remove(recordingClass);\n    }\n\n    // Update UI.\n    const dialog = document.querySelector('.bb-capture-toolbar');\n    const videoPreviewContainer = document.querySelector('.bb-capture-preview');\n    videoPreviewContainer.style.display = this.screenRecorder.file ? 'flex' : 'none';\n    dialog.style.display = !this.screenRecorder.file ? 'flex' : 'none';\n\n    for (var i = 0; i < toolbarItems.length; i++) {\n      const toolbarItem = toolbarItems[i];\n      const type = toolbarItem.getAttribute('data-type');\n      switch (type) {\n        case 'mic':\n          if (this.screenRecorder.audioAvailable && this.screenRecorder.available) {\n            toolbarItem.classList.remove(itemInactiveClass);\n            if (!this.screenRecorder.audioMuted) {\n              toolbarItem.classList.remove('bb-capture-toolbar-item--inactivecross');\n              audioRecordingTooltip.innerHTML = GleapTranslationManager.translateText('mute');\n            } else {\n              toolbarItem.classList.add('bb-capture-toolbar-item--inactivecross');\n              audioRecordingTooltip.innerHTML = GleapTranslationManager.translateText('unmute');\n            }\n          } else {\n            toolbarItem.classList.add(itemInactiveClass);\n            toolbarItem.classList.add('bb-capture-toolbar-item--inactivecross');\n            audioRecordingTooltip.innerHTML = GleapTranslationManager.translateText('browserNotSupported');\n          }\n          break;\n\n        case 'recording':\n          if (this.screenRecorder.available) {\n            toolbarItem.classList.remove(itemInactiveClass);\n            if (this.screenRecorder.isRecording) {\n              toolbarItem.setAttribute('data-active', 'true');\n              screenRecordingTooltip.innerHTML = GleapTranslationManager.translateText('stopRecording');\n              timerLabel.style.display = 'block';\n            } else {\n              toolbarItem.setAttribute('data-active', 'false');\n              screenRecordingTooltip.innerHTML = GleapTranslationManager.translateText('startRecording');\n              timerLabel.style.display = 'none';\n            }\n          } else {\n            // Recording is not available.\n            toolbarItem.classList.add(itemInactiveClass);\n            screenRecordingTooltip.innerHTML = GleapTranslationManager.translateText('browserNotSupported');\n          }\n          break;\n\n        default:\n          break;\n      }\n    }\n  }\n\n  setupScreenRecording() {\n    const self = this;\n\n    // Hook preview next button\n    const nextButtonPreview = document.querySelector('.bb-capture-preview-sendbutton');\n    nextButtonPreview.onclick = this.showNextStep.bind(this);\n\n    // Hook retry button\n    const retryButton = document.querySelector('.bb-capture-preview-retrybutton');\n    retryButton.onclick = function () {\n      self.screenRecorder.clearPreview();\n      if (self.screenDrawer) {\n        self.screenDrawer.clear();\n      }\n    };\n\n    // Setup screen recorder\n    this.screenRecorder = new GleapScreenRecorder(\n      this.captureRenderer.bind(this),\n      GleapTranslationManager.translateText('accessToScreenSharingDenied')\n    );\n  }\n}\n","import { GleapFrameManager, GleapFeedbackButtonManager, GleapConfigManager } from './Gleap';\n\nexport default class GleapTranslationManager {\n  overrideLanguage = '';\n  isRTLLayout = false;\n\n  // GleapTranslationManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapTranslationManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Returns the language to override the default language.\n   * @returns {string}\n   */\n  getOverrideLanguage() {\n    return this.overrideLanguage;\n  }\n\n  /**\n   * Sets the language to override the default language.\n   * @param {*} language\n   */\n  setOverrideLanguage(language) {\n    this.overrideLanguage = language;\n  }\n\n  updateRTLSupport() {\n    // Update RTL support.\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n\n    this.isRTLLayout = false;\n    if (flowConfig && flowConfig.localizationOptions && flowConfig.localizationOptions.rtl) {\n      this.isRTLLayout = true;\n    }\n\n    GleapFeedbackButtonManager.getInstance().updateFeedbackButtonState();\n    GleapFrameManager.getInstance().updateFrameStyle();\n  }\n\n  getActiveLanguage() {\n    var language = 'en';\n    if (typeof navigator !== 'undefined') {\n      language = navigator.language.toLowerCase();\n    }\n\n    // Get language from HTML lang attribute if available\n    if (typeof document !== 'undefined' && document.documentElement) {\n      const htmlLang = document.documentElement.lang;\n      if (htmlLang && htmlLang.trim() !== '') {\n        language = htmlLang.toLowerCase().trim();\n      }\n    }\n\n    if (this.overrideLanguage && this.overrideLanguage !== '') {\n      language = this.overrideLanguage.toLowerCase();\n    }\n\n    return language;\n  }\n\n  static translateText(key) {\n    if (!key) {\n      return '';\n    }\n\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n    const staticTranslation = flowConfig.staticTranslations;\n\n    if (staticTranslation && staticTranslation[key]) {\n      return staticTranslation[key];\n    }\n\n    return key;\n  }\n\n  static translateTextWithVars(key, vars) {\n    if (!key) {\n      return '';\n    }\n\n    var template = this.translateText(key);\n    if (!template) {\n      return '';\n    }\n\n    return template.replace(/{(\\w+)}/g, function (_, key) {\n      return vars[key];\n    });\n  }\n}\n","import Gleap from './Gleap';\n\nexport default class GleapShortcutListener {\n  shortCutListener = undefined;\n\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapShortcutListener();\n    }\n    return this.instance;\n  }\n\n  start() {\n    if (this.shortCutListener) {\n      return;\n    }\n\n    const charForEvent = function (event) {\n      var code;\n\n      if (event.key !== undefined) {\n        code = event.key;\n      } else if (event.keyIdentifier !== undefined) {\n        code = event.keyIdentifier;\n      } else if (event.keyCode !== undefined) {\n        code = event.keyCode;\n      }\n\n      return code;\n    };\n\n    this.shortCutListener = document.addEventListener('keyup', function (e) {\n      const char = charForEvent(e);\n      if (e.ctrlKey && (char === 'u' || char === 'U' || char === 85)) {\n        Gleap.startFeedbackFlowWithOptions('bugreporting', {\n          autostartDrawing: true,\n        });\n      }\n    });\n  }\n\n  stop() {\n    if (this.shortCutListener) {\n      document.removeEventListener('keyup', this.shortCutListener);\n      this.shortCutListener = undefined;\n    }\n  }\n}\n","export default class GleapPreFillManager {\n  formPreFill = {};\n\n  // GleapPreFillManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapPreFillManager();\n    }\n    return this.instance;\n  }\n}\n","import Gleap, {\n  GleapFeedbackButtonManager,\n  GleapConfigManager,\n  GleapSession,\n  GleapAudioManager,\n  GleapTranslationManager,\n  GleapEventManager,\n} from './Gleap';\nimport { loadFromGleapCache, saveToGleapCache } from './GleapHelper';\nimport { loadIcon } from './UI';\n\nexport default class GleapNotificationManager {\n  notificationContainer = null;\n  notifications = [];\n  unreadCount = 0;\n  unreadNotificationsKey = 'unread-notifications';\n  isTabActive = true;\n  showNotificationBadge = true;\n\n  // Keep track of the current index of news being shown\n  currentNewsIndex = 0;\n\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapNotificationManager();\n    }\n    return this.instance;\n  }\n\n  constructor() {}\n\n  updateTabBarNotificationCount() {\n    GleapEventManager.notifyEvent('unread-count-changed', this.unreadCount);\n  }\n\n  injectNotificationUI() {\n    if (this.notificationContainer) {\n      return;\n    }\n\n    var elem = document.createElement('div');\n    elem.className = 'gleap-notification-container gleap-font';\n    document.body.appendChild(elem);\n    this.notificationContainer = elem;\n\n    this.updateContainerStyle();\n    this.reloadNotificationsFromCache();\n  }\n\n  reloadNotificationsFromCache() {\n    try {\n      const notificationsFromCache = loadFromGleapCache(this.unreadNotificationsKey);\n      if (notificationsFromCache && notificationsFromCache.length > 0) {\n        let nots = notificationsFromCache.filter(\n          (notification) => new Date(notification.createdAt) > new Date(Date.now() - 1 * 60 * 60 * 1000)\n        );\n\n        if (nots.length > 2) {\n          this.notifications = nots.splice(0, nots.length - 2);\n        } else {\n          this.notifications = nots;\n        }\n        this.renderNotifications();\n      }\n    } catch (exp) {}\n  }\n\n  setNotificationCount(unreadCount) {\n    this.unreadCount = unreadCount;\n    this.updateTabBarNotificationCount();\n\n    // Update the badge counter.\n    GleapFeedbackButtonManager.getInstance().updateNotificationBadge(this.unreadCount);\n  }\n\n  showNotification(notification) {\n    if (!(this.notificationContainer && notification && notification.data)) {\n      return;\n    }\n\n    const notificationsForOutbound = this.notifications.find((e) => notification.outbound === e.outbound);\n    if (!notificationsForOutbound) {\n      this.notifications.push(notification);\n\n      // Play sound only if it's a new one\n      if (notification.sound) {\n        GleapAudioManager.ping();\n      }\n    }\n    if (this.notifications.length > 2) {\n      this.notifications.shift();\n    }\n\n    // Persist notifications.\n    saveToGleapCache(this.unreadNotificationsKey, this.notifications);\n\n    this.renderNotifications();\n  }\n\n  /**\n   * Renders notifications. For news-type notifications, only show\n   * one at a time if there are multiple, with a \"Next\" button to cycle.\n   * The \"Next\" button + pagination are placed within the news content area.\n   *\n   * - Sorts news notifications by createdAt (oldest first).\n   * - Shows \"Done\" on the last news item instead of \"Next\".\n   */\n  renderNotifications() {\n    if (!this.notificationContainer) {\n      return;\n    }\n\n    // Clear the existing notifications in the container (UI only).\n    this.clearAllNotifications(true);\n\n    // Append a close button (which clears everything).\n    const clearElem = document.createElement('div');\n    clearElem.onclick = () => {\n      this.clearAllNotifications();\n      // Reset the news index when everything is closed\n      this.currentNewsIndex = 0;\n    };\n    clearElem.className = 'gleap-notification-close';\n    clearElem.innerHTML = loadIcon('dismiss');\n    this.notificationContainer.appendChild(clearElem);\n\n    // Separate out news notifications vs. others, then sort news by date ascending\n    const newsNotifications = this.notifications\n      .filter((n) => n.data.news)\n      .sort((a, b) => new Date(a.createdAt) - new Date(b.createdAt));\n\n    const otherNotifications = this.notifications.filter((n) => !n.data.news);\n\n    // --- Render NEWS notifications (with pagination) ---\n    if (newsNotifications.length > 0) {\n      // We only show ONE news item at a time if there's more than one\n      const currentIndex = this.currentNewsIndex < newsNotifications.length ? this.currentNewsIndex : 0;\n      const currentNews = newsNotifications[currentIndex];\n\n      // Main wrapper for the news notification\n      const newsElem = document.createElement('div');\n      newsElem.className = 'gleap-notification-item-news';\n\n      // The container that holds image + content\n      const newsContainerElem = document.createElement('div');\n      newsContainerElem.className = 'gleap-notification-item-news-container';\n\n      // Create the image element (clickable)\n      if (\n        currentNews.data.coverImageUrl &&\n        currentNews.data.coverImageUrl !== '' &&\n        !currentNews.data.coverImageUrl.includes('NewsImagePlaceholder')\n      ) {\n        const newsImageElem = document.createElement('img');\n        newsImageElem.className = 'gleap-notification-item-news-image';\n        newsImageElem.src = currentNews.data.coverImageUrl;\n\n        // Only the image is clickable\n        newsImageElem.onclick = (e) => {\n          e.stopPropagation();\n          this.openNews(currentNews);\n        };\n        newsContainerElem.appendChild(newsImageElem);\n      }\n\n      // The content container\n      const newsContentElem = document.createElement('div');\n      newsContentElem.className = 'gleap-notification-item-news-content';\n\n      // Title (clickable)\n      const newsTitleElem = document.createElement('div');\n      newsTitleElem.className = 'gleap-notification-item-news-content-title';\n\n      let content = currentNews.data.text || '';\n      content = content.replaceAll('{{name}}', GleapSession.getInstance().getName());\n      newsTitleElem.innerText = content;\n\n      // Only the title is clickable\n      newsTitleElem.onclick = (e) => {\n        e.stopPropagation();\n        this.openNews(currentNews);\n      };\n\n      newsContentElem.appendChild(newsTitleElem);\n\n      // Description / Sender\n      const descHTML = this.renderDescription(currentNews);\n      if (descHTML) {\n        const descElem = document.createElement('div');\n        descElem.className = 'gleap-notification-item-news-preview';\n        descElem.innerHTML = descHTML;\n        newsContentElem.appendChild(descElem);\n      }\n\n      // If there's more than one news item, show pagination + next/done button\n      if (newsNotifications.length > 1) {\n        // Pagination container (still inside .gleap-notification-item-news-content)\n        const paginationElem = document.createElement('div');\n        paginationElem.className = 'gleap-news-pagination';\n\n        // Show current item / total\n        const pageIndicator = document.createElement('span');\n        pageIndicator.className = 'gleap-news-page-indicator';\n        pageIndicator.innerText = `${currentIndex + 1} / ${newsNotifications.length}`;\n        paginationElem.appendChild(pageIndicator);\n\n        // Next or Done button\n        const nextBtn = document.createElement('button');\n        nextBtn.className = 'gleap-news-next-button';\n\n        if (currentIndex < newsNotifications.length - 1) {\n          nextBtn.innerText = GleapTranslationManager.translateText(`next`);\n          nextBtn.onclick = (e) => {\n            e.stopPropagation(); // so we can click the button freely\n            this.currentNewsIndex++;\n            this.renderNotifications();\n          };\n        } else {\n          nextBtn.innerText = GleapTranslationManager.translateText(`done`);\n          nextBtn.onclick = (e) => {\n            e.stopPropagation();\n            this.clearAllNotifications();\n            this.currentNewsIndex = 0;\n          };\n        }\n        paginationElem.appendChild(nextBtn);\n        newsContentElem.appendChild(paginationElem);\n      }\n\n      // Append content to container\n      newsContainerElem.appendChild(newsContentElem);\n      // Append container to the main element\n      newsElem.appendChild(newsContainerElem);\n      // Finally append to the notification container\n      this.notificationContainer.appendChild(newsElem);\n    }\n\n    // --- Render OTHER notifications normally ---\n    for (let i = 0; i < otherNotifications.length; i++) {\n      const notification = otherNotifications[i];\n      let content = notification.data.text || '';\n      // Replace placeholders\n      content = content.replaceAll('{{name}}', GleapSession.getInstance().getName());\n\n      const elem = document.createElement('div');\n      elem.onclick = () => {\n        if (notification.data.conversation) {\n          Gleap.openConversation(notification.data.conversation.shareToken, true);\n        } else if (notification.data.checklist) {\n          Gleap.openChecklist(notification.data.checklist.id, true);\n        } else {\n          Gleap.open();\n        }\n      };\n\n      // Check if it's a checklist type\n      if (notification.data.checklist) {\n        let progress = Math.round((notification.data.currentStep / notification.data.totalSteps) * 100);\n        if (progress < 100) {\n          progress += 4;\n        }\n\n        elem.className = 'gleap-notification-item-checklist';\n        elem.innerHTML = `\n          <div class=\"gleap-notification-item-checklist-container\">\n            <div class=\"gleap-notification-item-checklist-content\">\n              <div class=\"gleap-notification-item-checklist-content-title\">\n                ${notification.data.text}\n              </div>\n              <div class=\"gleap-notification-item-checklist-content-progress\">\n                <div class=\"gleap-notification-item-checklist-content-progress-inner\" style=\"width: ${progress}%;\"></div>\n              </div>\n              <div class=\"gleap-notification-item-checklist-content-next\">\n                <svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\"\n                  fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n                  <path d=\"M4 12H20M20 12L14 6M20 12L14 18\"\n                    stroke=\"currentColor\" stroke-width=\"2\"\n                    stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n                </svg>\n                ${notification.data.nextStepTitle}\n              </div>\n            </div>\n          </div>`;\n      } else {\n        // Standard non-news notification\n        elem.className = 'gleap-notification-item';\n        elem.innerHTML = `\n          ${\n            notification.data.sender &&\n            notification.data.sender.profileImageUrl &&\n            `<img src=\"${notification.data.sender.profileImageUrl}\" />`\n          }\n          <div class=\"gleap-notification-item-container\">\n            ${\n              notification.data.sender\n                ? `<div class=\"gleap-notification-item-sender\">\n                     ${notification.data.sender.name}\n                   </div>`\n                : ''\n            }\n            <div class=\"gleap-notification-item-content\">${content}</div>\n          </div>`;\n      }\n      this.notificationContainer.appendChild(elem);\n    }\n\n    const hasNotifications = newsNotifications.length > 0 || otherNotifications.length > 0;\n    if (!hasNotifications) {\n      // Clear the notification container\n      this.clearAllNotifications(true);\n    }\n  }\n\n  /**\n   * Helper to open news from a given notification.\n   */\n  openNews(notification) {\n    if (notification.data.news) {\n      Gleap.openNewsArticle(notification.data.news.id, true);\n    } else {\n      Gleap.open();\n    }\n  }\n\n  /**\n   * Helper to render preview or sender info for news notifications.\n   */\n  renderDescription(notification) {\n    const { previewText, sender } = notification.data;\n    if (previewText && previewText.length > 0) {\n      return previewText;\n    } else if (sender) {\n      // Return HTML for the sender name + optional image\n      return `\n        <div class=\"gleap-notification-item-news-sender\">\n          ${sender.profileImageUrl ? `<img src=\"${sender.profileImageUrl}\" alt=\"${sender.name}\" />` : ''}\n          ${sender.name}\n        </div>\n      `;\n    }\n    return '';\n  }\n\n  /**\n   * Clears all notifications from the container.\n   *\n   * @param {boolean} uiOnly - Whether to only clear the UI or also the notifications.\n   */\n  clearAllNotifications(uiOnly = false) {\n    if (!this.notificationContainer) {\n      return;\n    }\n\n    if (!uiOnly) {\n      this.notifications = [];\n      // Reset currentNewsIndex whenever we clear them out\n      this.currentNewsIndex = 0;\n      saveToGleapCache(this.unreadNotificationsKey, this.notifications);\n    }\n\n    while (this.notificationContainer.firstChild) {\n      this.notificationContainer.removeChild(this.notificationContainer.firstChild);\n    }\n  }\n\n  updateContainerStyle() {\n    if (!this.notificationContainer) {\n      return;\n    }\n\n    const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n    const classLeft = 'gleap-notification-container--left';\n    const classNoButton = 'gleap-notification-container--no-button';\n    this.notificationContainer.classList.remove(classLeft);\n    this.notificationContainer.classList.remove(classNoButton);\n\n    if (\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_CLASSIC_LEFT ||\n      flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_BOTTOM_LEFT\n    ) {\n      this.notificationContainer.classList.add(classLeft);\n    }\n\n    if (GleapFeedbackButtonManager.getInstance().buttonHidden === null) {\n      if (flowConfig.feedbackButtonPosition === GleapFeedbackButtonManager.FEEDBACK_BUTTON_NONE) {\n        this.notificationContainer.classList.add(classNoButton);\n      }\n    } else {\n      if (GleapFeedbackButtonManager.getInstance().buttonHidden) {\n        this.notificationContainer.classList.add(classNoButton);\n      }\n    }\n\n    this.notificationContainer.setAttribute('dir', GleapTranslationManager.getInstance().isRTLLayout ? 'rtl' : 'ltr');\n  }\n}\n","import { GleapFrameManager, GleapConfigManager, GleapSession, GleapEventManager } from './Gleap';\nimport GleapAgentToolManager from './GleapAgentToolManager';\nimport { runFunctionWhenDomIsReady } from './GleapHelper';\n\nexport default class GleapAiChatbarManager {\n  chatbarUrl = 'https://outboundmedia.gleap.io/chatbar';\n  chatbarContainer = null;\n  chatbarFrame = null;\n  config = null;\n  agentId = 'kai';\n  agentContext = null;\n  isHidden = true;\n  manuallyHidden = false;\n  manuallyShown = false;\n  iframeReady = false;\n  pendingMessages = [];\n\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapAiChatbarManager();\n    }\n    return this.instance;\n  }\n\n  constructor() {\n    this._listenForMessages();\n    this._listenForOutsideClicks();\n  }\n\n  _listenForOutsideClicks() {\n    document.addEventListener('click', (event) => {\n      if (!this.chatbarContainer) return;\n      if (this.chatbarContainer.contains(event.target)) return;\n      if (this._suppressOutsideClick) return;\n      this._postMessage({ name: 'chatbar-outside-click' });\n    });\n  }\n\n  _listenForMessages() {\n    window.addEventListener('message', (event) => {\n      if (this.chatbarUrl && !this.chatbarUrl.includes(event.origin)) {\n        return;\n      }\n\n      try {\n        const data = JSON.parse(event.data);\n        if (data?.type !== 'CHATBAR') return;\n\n        if (data.name === 'chatbar-loaded') {\n          this.iframeReady = true;\n          this._sendChatbarData();\n          this._flushPendingMessages();\n        }\n        if (data.name === 'chatbar-resize' && data.data) {\n          this._resizeFrame(data.data);\n        }\n        if (data.name === 'chatbar-message-sent') {\n          GleapEventManager.notifyEvent('agent-message-sent', data.data);\n        }\n        if (data.name === 'chatbar-conversation-created') {\n          GleapEventManager.notifyEvent('agent-conversation-created', data.data);\n        }\n        if (data.name === 'chatbar-reply-received') {\n          GleapEventManager.notifyEvent('agent-reply-received', data.data);\n        }\n        if (data.name === 'chatbar-tool-executed' && data.data) {\n          GleapAgentToolManager.getInstance().triggerToolAction(data.data);\n        }\n        if (data.name === 'chatbar-error') {\n          GleapEventManager.notifyEvent('agent-error', data.data);\n        }\n        if (data.name === 'chatbar-panel-blur' && data.data) {\n          this._updateBlurBackdrop(data.data);\n        }\n      } catch (e) {}\n    });\n  }\n\n  _postMessage(message) {\n    try {\n      if (!this.iframeReady || !this.chatbarFrame?.contentWindow) {\n        this.pendingMessages.push(message);\n        return;\n      }\n      this.chatbarFrame.contentWindow.postMessage(JSON.stringify({ ...message, type: 'chatbar' }), '*');\n    } catch (e) {}\n  }\n\n  _flushPendingMessages() {\n    const queued = this.pendingMessages;\n    this.pendingMessages = [];\n    for (const msg of queued) {\n      this._postMessage(msg);\n    }\n  }\n\n  _sendChatbarData() {\n    if (!this.chatbarContainer) return;\n    let flowConfig = {};\n    let apiUrl = 'https://api.gleap.io';\n    let sdkKey = '';\n    let gleapId = '';\n    let gleapHash = '';\n\n    try {\n      flowConfig = GleapConfigManager.getInstance().getFlowConfig() || {};\n    } catch (e) {}\n\n    try {\n      const session = GleapSession.getInstance();\n      apiUrl = session.apiUrl || apiUrl;\n      sdkKey = session.sdkKey || '';\n      gleapId = session.session?.gleapId || '';\n      gleapHash = session.session?.gleapHash || '';\n    } catch (e) {}\n\n    const defaultAgentName = flowConfig?.aiBar?.defaultAgentName || 'Kai';\n\n    this._postMessage({\n      name: 'chatbar-data',\n      data: {\n        agentId: this.agentId,\n        defaultAgentName,\n        placeholder: this.config?.placeholder || 'Ask me anything...',\n        quickActions: this.config?.quickActions || [],\n        style: this.config?.style || 'glow',\n        primaryColor: flowConfig?.color || '#485BFF',\n        agentTools: GleapAgentToolManager.getInstance().getAgentTools(),\n        apiUrl,\n        sdkKey,\n        gleapId,\n        gleapHash,\n      },\n    });\n  }\n\n  _resizeFrame({ width, height }) {\n    if (!this.chatbarContainer) return;\n    this.chatbarContainer.style.width = Math.ceil(width) + 'px';\n    this.chatbarContainer.style.height = Math.ceil(height) + 'px';\n    if (!this.isHidden) {\n      this.chatbarContainer.style.display = 'block';\n    }\n  }\n\n  _updateBlurBackdrop({ visible, height, borderRadius }) {\n    if (!this.blurBackdrop) return;\n    if (visible) {\n      this.blurBackdrop.style.height = height + 'px';\n      this.blurBackdrop.style.borderRadius = borderRadius + 'px';\n      this.blurBackdrop.style.display = 'block';\n    } else {\n      this.blurBackdrop.style.display = 'none';\n    }\n  }\n\n  setConfig(config) {\n    this.config = config;\n\n    if (this.agentId === 'kai' || !this.agentId) {\n      if (!config.agentId || config.agentId === 'default') {\n        this.agentId = 'kai';\n      } else {\n        this.agentId = config.agentId;\n      }\n    }\n\n    if (config.enabled) {\n      this.show();\n    } else if (!this.manuallyShown) {\n      this.hide();\n    }\n\n    // Forward updated config to chatbar iframe (queued if not ready yet)\n    this._sendChatbarData();\n  }\n\n  setPlaceholder(placeholder) {\n    if (!this.config) this.config = {};\n    this.config.placeholder = placeholder;\n    this._sendChatbarData();\n  }\n\n  setQuickActions(quickActions) {\n    if (!this.config) this.config = {};\n    this.config.quickActions = quickActions;\n    this._sendChatbarData();\n  }\n\n  sendAgentToolsUpdate() {\n    this._postMessage({\n      name: 'chatbar-set-agent-tools',\n      data: { tools: GleapAgentToolManager.getInstance().getAgentTools() },\n    });\n  }\n\n  updateUIVisibility() {\n    const isOpened = GleapFrameManager.getInstance().isOpened();\n    if (isOpened) {\n      this.hide();\n    } else if (this.config?.enabled || this.manuallyShown) {\n      this.show();\n    } else {\n      this.hide();\n    }\n  }\n\n  show() {\n    if (this.manuallyHidden) {\n      return;\n    }\n    this.isHidden = false;\n    this._preloadIframe();\n    if (this.chatbarContainer) {\n      this.chatbarContainer.style.display = 'block';\n    }\n  }\n\n  hide() {\n    this.isHidden = true;\n    this._removeUI();\n  }\n\n  _removeUI() {\n    if (!this.chatbarContainer) return;\n    if (document.body && document.body.contains(this.chatbarContainer)) {\n      document.body.removeChild(this.chatbarContainer);\n    }\n    this.chatbarContainer = null;\n    this.chatbarFrame = null;\n    this.blurBackdrop = null;\n    this.iframeReady = false;\n    this.pendingMessages = [];\n  }\n\n  _resolveAgentId(agentId) {\n    if (!agentId || agentId === 'default') {\n      return 'kai';\n    }\n    return agentId;\n  }\n\n  _sendAgentCommand(agentId, options = {}, openPanel = false) {\n    const resolvedAgentId = this._resolveAgentId(agentId);\n    this.agentId = resolvedAgentId;\n    if (options.context) this.agentContext = options.context;\n    this.manuallyHidden = false;\n\n    const messageData = {\n      agentId: this.agentId,\n      context: this.agentContext,\n      primaryColor: options.primaryColor || undefined,\n      initialMessage: options.initialMessage || undefined,\n    };\n\n    const messageName = openPanel ? 'chatbar-show-agent' : 'chatbar-set-agent';\n\n    // Suppress outside-click for this tick so a button that calls\n    // startAgent() doesn't immediately close the conversation.\n    this._suppressOutsideClick = true;\n    setTimeout(() => { this._suppressOutsideClick = false; }, 0);\n\n    // Show the chatbar (preloads iframe if needed)\n    this.show();\n\n    // Post the agent command (queued automatically if iframe not ready yet)\n    this._postMessage({ name: messageName, data: messageData });\n  }\n\n  setAgent(agentId, options = {}) {\n    this._sendAgentCommand(agentId, options, false);\n  }\n\n  showWithAgent(agentId, options = {}) {\n    this._sendAgentCommand(agentId, options, true);\n  }\n\n  _preloadIframe() {\n    if (this.chatbarContainer) return;\n    runFunctionWhenDomIsReady(() => this._injectUI());\n  }\n\n  _injectUI() {\n    if (!document.body || this.chatbarContainer) return;\n\n    let flowConfig = {};\n    try {\n      flowConfig = GleapConfigManager.getInstance().getFlowConfig() || {};\n    } catch (e) {}\n\n    const container = document.createElement('div');\n    container.className = 'gleap-chatbar';\n    container.style.cssText = `\n      position: fixed;\n      bottom: 10px;\n      z-index: 2147483000;\n      border: 0;\n      width: 280px;\n      overflow: hidden;\n      height: 80px;\n      display: none;\n      transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);\n      left: 50%;\n      transform: translateX(-50%);\n    `;\n\n    const frame = document.createElement('iframe');\n    frame.src = this.chatbarUrl;\n    frame.className = 'gleap-chatbar-frame';\n    frame.title = 'Gleap AI Chatbar';\n    frame.setAttribute('role', 'dialog');\n    frame.setAttribute('frameborder', '0');\n    frame.setAttribute('allow', 'autoplay; encrypted-media; microphone *;');\n    frame.style.cssText = `\n      position: relative;\n      width: 100%;\n      height: 100%;\n      border: 0;\n      background: transparent;\n      z-index: 1;\n    `;\n\n    const blurBackdrop = document.createElement('div');\n    blurBackdrop.style.cssText = `\n      position: absolute;\n      bottom: 70px;\n      left: 20px;\n      right: 20px;\n      height: 0;\n      display: none;\n      backdrop-filter: blur(40px) saturate(180%);\n      -webkit-backdrop-filter: blur(40px) saturate(180%);\n      border-radius: 20px;\n      pointer-events: none;\n      z-index: 0;\n    `;\n\n    container.appendChild(blurBackdrop);\n    container.appendChild(frame);\n    document.body.appendChild(container);\n\n    this.chatbarContainer = container;\n    this.chatbarFrame = frame;\n    this.blurBackdrop = blurBackdrop;\n  }\n\n  destroy() {\n    this._removeUI();\n    this.config = null;\n    this.agentId = null;\n    this.agentContext = null;\n    this.isHidden = true;\n    this.iframeReady = false;\n    this.pendingMessages = [];\n    GleapAiChatbarManager.instance = null;\n  }\n}\n","import Gleap, { GleapFrameManager } from './Gleap';\n\nexport default class GleapBannerManager {\n  bannerUrl = 'https://outboundmedia.gleap.io';\n  bannerContainer = null;\n  bannerData = null;\n  disabled = false;\n\n  // GleapBannerManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapBannerManager();\n    }\n    return this.instance;\n  }\n\n  constructor() {\n    this.startCommunication();\n  }\n\n  setBannerUrl(url) {\n    this.bannerUrl = url;\n  }\n\n  startCommunication() {\n    // Add window message listener.\n    window.addEventListener('message', (event) => {\n      if (!this.bannerUrl?.includes(event.origin)) {\n        return;\n      }\n\n      try {\n        const data = JSON.parse(event.data);\n\n        if (data?.type !== 'BANNER') {\n          return;\n        }\n\n        if (data.name === 'banner-loaded' && this.bannerData) {\n          this.sendMessage({\n            name: 'banner-data',\n            data: this.bannerData,\n          });\n        }\n        if (data.name === 'banner-height') {\n          document.documentElement.style.setProperty('--gleap-margin-top', data.data.height + 'px');\n        }\n        if (data.name === 'banner-data-set') {\n          document.body.classList.add('gleap-b-shown');\n\n          if (this.bannerData?.format === 'floating') {\n            document.body.classList.add('gleap-b-f');\n          }\n        }\n        if (data.name === 'banner-close') {\n          this.removeBannerUI();\n        }\n        if (data.name === 'start-conversation') {\n          Gleap.startBot(data.data?.botId);\n        }\n        if (data.name === 'start-custom-action') {\n          Gleap.triggerCustomAction(data.data?.action);\n        }\n        if (data.name === 'start-product-tour') {\n          Gleap.startProductTour(data.data?.tourId, true);\n        }\n        if (data.name === 'open-url') {\n          const url = data.data;\n          const newTab = data.newTab ? true : false;\n          GleapFrameManager.getInstance().urlHandler(url, newTab);\n        }\n        if (data.name === 'show-form') {\n          Gleap.startFeedbackFlow(data.data?.formId);\n        }\n        if (data.name === 'show-survey') {\n          Gleap.showSurvey(data.data?.formId, data.data?.surveyFormat);\n        }\n        if (data.name === 'show-news-article') {\n          Gleap.openNewsArticle(data.data?.articleId);\n        }\n        if (data.name === 'show-help-article') {\n          Gleap.openHelpCenterArticle(data.data?.articleId);\n        }\n        if (data.name === 'show-checklist') {\n          Gleap.startChecklist(data.data?.checklistId, true, data.data?.sharedKey);\n        }\n      } catch (exp) {}\n    });\n  }\n\n  removeBannerUI() {\n    if (this.bannerContainer) {\n      document.body.removeChild(this.bannerContainer);\n      this.bannerContainer = null;\n    }\n\n    document.body.classList.remove('gleap-b-shown');\n    document.body.classList.remove('gleap-b-f');\n  }\n\n  disable() {\n    this.disabled = true;\n    this.removeBannerUI();\n  }\n\n  /**\n   * Injects the feedback button into the current DOM.\n   */\n  injectBannerUI(bannerData) {\n    if (!document.body) {\n      return false;\n    }\n\n    if (this.disabled) {\n      return false;\n    }\n\n    if (this.bannerContainer) {\n      this.removeBannerUI();\n    }\n\n    this.bannerData = bannerData;\n\n    var elem = document.createElement('div');\n    elem.className = 'gleap-b';\n    elem.innerHTML = `<iframe src=\"${this.bannerUrl}\" class=\"gleap-b-frame\" scrolling=\"no\" title=\"Gleap Banner\" role=\"dialog\" frameborder=\"0\"></iframe>`;\n    document.body.appendChild(elem);\n    this.bannerContainer = elem;\n  }\n\n  sendMessage(data) {\n    try {\n      const gleapBFrame = document.querySelector('.gleap-b-frame');\n      if (gleapBFrame && gleapBFrame.contentWindow) {\n        gleapBFrame.contentWindow.postMessage(\n          JSON.stringify({\n            ...data,\n            type: 'banner',\n          }),\n          '*'\n        );\n      }\n    } catch (e) {}\n  }\n\n  showBanner(bannerData) {\n    this.injectBannerUI(bannerData);\n  }\n}\n","import Gleap, { GleapConfigManager, GleapFrameManager } from './Gleap';\n\nexport default class GleapModalManager {\n  modalUrl = 'https://outboundmedia.gleap.io/modal';\n  modalContainer = null;\n  modalData = null;\n  modalBackdropClickListener = null;\n  disabled = false;\n  // singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapModalManager();\n    }\n    return this.instance;\n  }\n\n  constructor() {\n    this._listenForMessages();\n  }\n\n  setModalUrl(url) {\n    this.modalUrl = url;\n  }\n\n  disable() {\n    this.disabled = true;\n    this.hideModal();\n  }\n\n  _listenForMessages() {\n    window.addEventListener('message', (event) => {\n      if (!this.modalUrl?.includes(event.origin)) {\n        return;\n      }\n\n      try {\n        const data = JSON.parse(event.data);\n\n        if (data?.type !== 'MODAL') {\n          return;\n        }\n\n        if (data.name === 'modal-loaded' && this.modalData) {\n          const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n          const primaryColor = flowConfig.color ? flowConfig.color : '#485BFF';\n          const backgroundColor = flowConfig.backgroundColor ? flowConfig.backgroundColor : '#FFFFFF';\n\n          this._postMessage({\n            name: 'modal-data',\n            data: {\n              ...this.modalData,\n              primaryColor: primaryColor,\n              backgroundColor: backgroundColor,\n            },\n          });\n        }\n        if (data.name === 'modal-height') {\n          const height = data?.data?.height;\n          if (height) {\n            // Set the height of the modal iframe\n            const iframe = this.modalContainer.querySelector('.gleap-modal-frame');\n            if (iframe) {\n              iframe.style.height = `${height}px`;\n            }\n          }\n        }\n        if (data.name === 'modal-data-set') {\n          // TODO: Implement\n        }\n        if (data.name === 'modal-close') {\n          this.hideModal();\n        }\n        if (data.name === 'start-conversation') {\n          Gleap.startBot(data.data?.botId);\n        }\n        if (data.name === 'start-custom-action') {\n          Gleap.triggerCustomAction(data.data?.action);\n        }\n        if (data.name === 'start-product-tour') {\n          Gleap.startProductTour(data.data?.tourId, true);\n        }\n        if (data.name === 'open-url') {\n          const url = data.data;\n          const newTab = data.newTab ? true : false;\n          GleapFrameManager.getInstance().urlHandler(url, newTab);\n        }\n        if (data.name === 'show-form') {\n          Gleap.startFeedbackFlow(data.data?.formId);\n        }\n        if (data.name === 'show-survey') {\n          Gleap.showSurvey(data.data?.formId, data.data?.surveyFormat);\n        }\n        if (data.name === 'show-news-article') {\n          Gleap.openNewsArticle(data.data?.articleId);\n        }\n        if (data.name === 'show-help-article') {\n          Gleap.openHelpCenterArticle(data.data?.articleId);\n        }\n        if (data.name === 'show-checklist') {\n          Gleap.startChecklist(data.data?.checklistId, true, data.data?.sharedKey);\n        }\n      } catch (exp) {}\n    });\n  }\n\n  _injectModalUI(modalData) {\n    if (!document.body) return false;\n\n    if (this.disabled) {\n      return false;\n    }\n\n    if (this.modalContainer) {\n      this.hideModal();\n    }\n\n    this.modalData = modalData;\n\n    const wrapper = document.createElement('div');\n    wrapper.className = 'gleap-modal-wrapper';\n    wrapper.innerHTML = `\n      <div class=\"gleap-modal-backdrop\"></div>\n      <div class=\"gleap-modal\">\n        <iframe\n          src=\"${this.modalUrl}\"\n          class=\"gleap-modal-frame\"\n          scrolling=\"no\"\n          title=\"Gleap Modal\"\n          role=\"dialog\"\n          frameborder=\"0\"\n          allow=\"autoplay; encrypted-media; fullscreen; microphone *;\"\n        ></iframe>\n      </div>\n    `;\n    document.body.appendChild(wrapper);\n    this.modalContainer = wrapper;\n\n    // Add on backdrop click listener\n    this.modalBackdropClickListener = this.modalContainer\n      .querySelector('.gleap-modal-backdrop')\n      .addEventListener('click', () => {\n        if (this.modalData?.showCloseButton ?? true) {\n          this.hideModal();\n        }\n      });\n\n    // lock background scroll\n    document.body.classList.add('gleap-modal-open');\n  }\n\n  _postMessage(message) {\n    try {\n      const frame = this.modalContainer.querySelector('.gleap-modal-frame');\n      if (frame?.contentWindow) {\n        frame.contentWindow.postMessage(JSON.stringify({ ...message, type: 'modal' }), this.modalUrl);\n      }\n    } catch (err) {}\n  }\n\n  showModal(modalData) {\n    if (modalData && modalData.config) {\n      this._injectModalUI(modalData.config);\n    }\n  }\n\n  hideModal() {\n    if (!this.modalContainer) return;\n\n    if (this.modalBackdropClickListener) {\n      this.modalContainer\n        .querySelector('.gleap-modal-backdrop')\n        .removeEventListener('click', this.modalBackdropClickListener);\n    }\n\n    document.body.removeChild(this.modalContainer);\n    this.modalContainer = null;\n    document.body.classList.remove('gleap-modal-open');\n  }\n}\n","export default class GleapAudioManager {\n  static audio;\n  static settings = {\n    play: true,\n  };\n\n  static playSound(play) {\n    this.settings.play = play;\n  }\n\n  static ping() {\n    try {\n      if (!this.settings.play) {\n        return;\n      }\n\n      if (!this.audio) {\n        this.audio = new Audio('https://js.gleap.io/res/ping.mp3');\n      }\n\n      const playPromise = this.audio.play();\n      if (playPromise !== undefined) {\n        playPromise.then((_) => {}).catch((error) => {});\n      }\n    } catch (exp) {}\n  }\n}\n","export default class GleapTagManager {\n  tags = [];\n\n  // GleapTagManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapTagManager();\n    }\n    return this.instance;\n  }\n\n  /**\n   * Returns the tags\n   * @returns {*}\n   */\n  getTags() {\n    return this.tags;\n  }\n\n  /**\n   * Sets the tags sent with every ticket.\n   * @param {*} tags Array of strings\n   */\n  setTags(tags) {\n    this.tags = tags;\n  }\n}\n","/**\n * Returns the Tag of the element\n * @param  { Object } element\n * @return { String }\n */\nexport function getID(el) {\n  const id = el.getAttribute('id');\n\n  if (id !== null && id !== '') {\n    // if the ID starts with a number or contains \":\" selecting with a hash will cause a DOMException\n    return id.match(/(?:^\\d|:)/) ? `[id=\"${id}\"]` : '#' + id;\n  }\n  return null;\n}\n","/**\n * Get class names for an element\n *\n * @pararm { Element } el\n * @return { Array }\n */\nexport function getClasses(el) {\n  if (!el.hasAttribute('class')) {\n    return [];\n  }\n\n  try {\n    let classList = Array.prototype.slice.call(el.classList);\n\n    // return only the valid CSS selectors based on RegEx\n    return classList.filter((item) => (!/^[a-z_-][a-z\\d_-]*$/i.test(item) ? null : item));\n  } catch (e) {\n    let className = el.getAttribute('class');\n\n    // remove duplicate and leading/trailing whitespaces\n    className = className.trim().replace(/\\s+/g, ' ');\n\n    // split into separate classnames\n    return className.split(' ');\n  }\n}\n\n/**\n * Returns the Class selectors of the element\n * @param  { Object } element\n * @return { Array }\n */\nexport function getClassSelectors(el) {\n  const classList = getClasses(el).filter(Boolean);\n  return classList.map((cl) => `.${cl}`);\n}\n","/**\n * Recursively combinate items.\n * @param  { Array } result\n * @param  { Array } items\n * @param  { Array } data\n * @param  { Number } start\n * @param  { Number } end\n * @param  { Number } index\n * @param  { Number } k\n */\nfunction kCombinations(result, items, data, start, end, index, k) {\n  if (index === k) {\n    result.push(data.slice(0, index).join(''));\n    return;\n  }\n\n  for (let i = start; i <= end && end - i + 1 >= k - index; ++i) {\n    data[index] = items[i];\n    kCombinations(result, items, data, i + 1, end, index + 1, k);\n  }\n}\n\n/**\n * Returns all the possible selector combinations\n * @param  { Array } items\n * @param  { Number } k\n * @return { Array }\n */\nexport function getCombinations(items, k) {\n  const result = [],\n    n = items.length,\n    data = [];\n\n  for (var l = 1; l <= k; ++l) {\n    kCombinations(result, items, data, 0, n - 1, 0, l);\n  }\n\n  return result;\n}\n","/**\n * Determines if the passed el is a DOM element\n */\nexport function isElement(el) {\n  let isElem;\n\n  if (typeof HTMLElement === 'object') {\n    isElem = el instanceof HTMLElement;\n  } else {\n    isElem = !!el && typeof el === 'object' && el.nodeType === 1 && typeof el.nodeName === 'string';\n  }\n  return isElem;\n}\n","import { isElement } from './isElement';\n\n/**\n * Returns the selectors based on the position of the element relative to its siblings\n * @param  { Object } element\n * @return { Array }\n */\nexport function getNthChild(element) {\n  let counter = 0;\n  let k;\n  let sibling;\n  const { parentNode } = element;\n\n  if (Boolean(parentNode)) {\n    const { childNodes } = parentNode;\n    const len = childNodes.length;\n    for (k = 0; k < len; k++) {\n      sibling = childNodes[k];\n      if (isElement(sibling)) {\n        counter++;\n        if (sibling === element) {\n          return `:nth-child(${counter})`;\n        }\n      }\n    }\n  }\n  return null;\n}\n","/**\n * Returns the Tag of the element\n * @param  { Object } element\n * @return { String }\n */\nexport function getTag(el) {\n  return el.tagName.toLowerCase().replace(/:/g, '\\\\:');\n}\n","/**\n * Checks if the selector is unique\n * @param  { Object } element\n * @param  { String } selector\n * @return { Array }\n */\nexport function isUnique(el, selector) {\n  if (!Boolean(selector)) return false;\n  const elems = el.ownerDocument.querySelectorAll(selector);\n  return elems.length === 1 && elems[0] === el;\n}\n","/**\n * Expose `unique`\n */\n\nimport { getID } from './getID';\nimport { getClassSelectors } from './getClasses';\nimport { getCombinations } from './getCombinations';\nimport { getAttributes } from './getAttributes';\nimport { getNthChild } from './getNthChild';\nimport { getTag } from './getTag';\nimport { isUnique } from './isUnique';\nimport { getParents } from './getParents';\n\n/**\n * Returns all the selectors of the elmenet\n * @param  { Object } element\n * @return { Object }\n */\nfunction getAllSelectors(el, selectors, attributesToIgnore) {\n  const funcs = {\n    Tag: getTag,\n    NthChild: getNthChild,\n    Attributes: (elem) => getAttributes(elem, attributesToIgnore),\n    Class: getClassSelectors,\n    ID: getID,\n  };\n\n  return selectors.reduce((res, next) => {\n    res[next] = funcs[next](el);\n    return res;\n  }, {});\n}\n\n/**\n * Tests uniqueNess of the element inside its parent\n * @param  { Object } element\n * @param { String } Selectors\n * @return { Boolean }\n */\nfunction testUniqueness(element, selector) {\n  try {\n    const { parentNode } = element;\n    const elements = parentNode.querySelectorAll(selector);\n    return elements.length === 1 && elements[0] === element;\n  } catch (e) {\n    return false;\n  }\n}\n\n/**\n * Tests all selectors for uniqueness and returns the first unique selector.\n * @param  { Object } element\n * @param  { Array } selectors\n * @return { String }\n */\nfunction getFirstUnique(element, selectors) {\n  return selectors.find(testUniqueness.bind(null, element));\n}\n\n/**\n * Checks all the possible selectors of an element to find one unique and return it\n * @param  { Object } element\n * @param  { Array } items\n * @param  { String } tag\n * @return { String }\n */\nfunction getUniqueCombination(element, items, tag) {\n  let combinations = getCombinations(items, 3),\n    firstUnique = getFirstUnique(element, combinations);\n\n  if (Boolean(firstUnique)) {\n    return firstUnique;\n  }\n\n  if (Boolean(tag)) {\n    combinations = combinations.map((combination) => tag + combination);\n    firstUnique = getFirstUnique(element, combinations);\n\n    if (Boolean(firstUnique)) {\n      return firstUnique;\n    }\n  }\n\n  return null;\n}\n\n/**\n * Returns a uniqueSelector based on the passed options\n * @param  { DOM } element\n * @param  { Array } options\n * @return { String }\n */\nfunction getUniqueSelector(element, selectorTypes, attributesToIgnore, excludeRegex) {\n  let foundSelector;\n\n  const elementSelectors = getAllSelectors(element, selectorTypes, attributesToIgnore);\n\n  if (excludeRegex && excludeRegex instanceof RegExp) {\n    elementSelectors.ID = excludeRegex.test(elementSelectors.ID) ? null : elementSelectors.ID;\n    elementSelectors.Class = elementSelectors.Class.filter((className) => !excludeRegex.test(className));\n  }\n\n  for (let selectorType of selectorTypes) {\n    const { ID, Tag, Class: Classes, Attributes, NthChild } = elementSelectors;\n    switch (selectorType) {\n      case 'ID':\n        if (Boolean(ID) && testUniqueness(element, ID)) {\n          return ID;\n        }\n        break;\n\n      case 'Tag':\n        if (Boolean(Tag) && testUniqueness(element, Tag)) {\n          return Tag;\n        }\n        break;\n\n      case 'Class':\n        if (Boolean(Classes) && Classes.length) {\n          foundSelector = getUniqueCombination(element, Classes, Tag);\n          if (foundSelector) {\n            return foundSelector;\n          }\n        }\n        break;\n\n      case 'Attributes':\n        if (Boolean(Attributes) && Attributes.length) {\n          foundSelector = getUniqueCombination(element, Attributes, Tag);\n          if (foundSelector) {\n            return foundSelector;\n          }\n        }\n        break;\n\n      case 'NthChild':\n        if (Boolean(NthChild)) {\n          return NthChild;\n        }\n    }\n  }\n  return '*';\n}\n\n/**\n * Generate unique CSS selector for given DOM element\n *\n * @param {Element} el\n * @return {String}\n * @api private\n */\n\nexport default function unique(el, options = {}) {\n  const {\n    selectorTypes = ['ID', 'Class', 'Tag', 'NthChild'],\n    attributesToIgnore = ['id', 'class', 'length'],\n    excludeRegex = null,\n  } = options;\n  const allSelectors = [];\n  const parents = getParents(el);\n\n  for (let elem of parents) {\n    const selector = getUniqueSelector(elem, selectorTypes, attributesToIgnore, excludeRegex);\n    if (Boolean(selector)) {\n      allSelectors.push(selector);\n    }\n  }\n\n  const selectors = [];\n  for (let it of allSelectors) {\n    selectors.unshift(it);\n    const selector = selectors.join(' > ');\n    if (isUnique(el, selector)) {\n      return selector;\n    }\n  }\n\n  return null;\n}\n","/**\n * Returns the Attribute selectors of the element\n * @param  { DOM Element } element\n * @param  { Array } array of attributes to ignore\n * @return { Array }\n */\nexport function getAttributes(el, attributesToIgnore = ['id', 'class', 'length']) {\n  const { attributes } = el;\n  const attrs = [...attributes];\n\n  return attrs.reduce((sum, next) => {\n    if (!(attributesToIgnore.indexOf(next.nodeName) > -1)) {\n      sum.push(`[${next.nodeName}=\"${next.value}\"]`);\n    }\n    return sum;\n  }, []);\n}\n","import { isElement } from './isElement';\n\n/**\n * Returns all the element and all of its parents\n * @param { DOM Element }\n * @return { Array of DOM elements }\n */\nexport function getParents(el) {\n  const parents = [];\n  let currentElement = el;\n  while (isElement(currentElement)) {\n    parents.push(currentElement);\n    currentElement = currentElement.parentNode;\n  }\n\n  return parents;\n}\n","/**\n * Utility function to get the bounding rectangle of an element.\n * @param {HTMLElement} el - The target element.\n * @returns {Object} An object containing x, y, width, and height.\n */\nfunction getElementBounds(el) {\n  const rect = el.getBoundingClientRect();\n  return {\n    x: window.pageXOffset + rect.left,\n    y: window.pageYOffset + rect.top,\n    width: el.offsetWidth,\n    height: el.offsetHeight,\n  };\n}\n\n/**\n * Class representing an overlay element.\n */\nclass ElementOverlay {\n  /**\n   * Create an ElementOverlay.\n   * @param {Object} options - Configuration options.\n   * @param {string} [options.className] - CSS class name for the overlay.\n   * @param {Object} [options.style] - Style overrides for the overlay.\n   */\n  constructor(options) {\n    // Create and style the overlay element.\n    this.overlay = document.createElement('div');\n    this.overlay.className = options.className || '_ext-element-overlay';\n    this.overlay.style.background = (options.style && options.style.background) || 'rgba(250, 240, 202, 0.2)';\n    this.overlay.style.borderColor = (options.style && options.style.borderColor) || '#F95738';\n    this.overlay.style.borderStyle = (options.style && options.style.borderStyle) || 'solid';\n    this.overlay.style.borderRadius = (options.style && options.style.borderRadius) || '1px';\n    this.overlay.style.borderWidth = (options.style && options.style.borderWidth) || '1px';\n    this.overlay.style.boxSizing = (options.style && options.style.boxSizing) || 'border-box';\n    this.overlay.style.cursor = (options.style && options.style.cursor) || 'crosshair';\n    this.overlay.style.position = (options.style && options.style.position) || 'absolute';\n    this.overlay.style.zIndex = (options.style && options.style.zIndex) || '2147483647';\n    this.overlay.style.margin = (options.style && options.style.margin) || '0px';\n    this.overlay.style.padding = (options.style && options.style.padding) || '0px';\n\n    // Create a container that will host a Shadow DOM.\n    this.shadowContainer = document.createElement('div');\n    this.shadowContainer.className = '_ext-element-overlay-container';\n    this.shadowContainer.style.position = 'absolute';\n    this.shadowContainer.style.top = '0px';\n    this.shadowContainer.style.left = '0px';\n    this.shadowContainer.style.margin = '0px';\n    this.shadowContainer.style.padding = '0px';\n    this.shadowRoot = this.shadowContainer.attachShadow({ mode: 'open' });\n  }\n\n  /**\n   * Adds the overlay to the DOM.\n   * @param {Node} parent - The parent element.\n   * @param {boolean} useShadowDOM - Whether to use Shadow DOM.\n   */\n  addToDOM(parent, useShadowDOM) {\n    this.usingShadowDOM = useShadowDOM;\n    if (useShadowDOM) {\n      parent.insertBefore(this.shadowContainer, parent.firstChild);\n      this.shadowRoot.appendChild(this.overlay);\n    } else {\n      parent.appendChild(this.overlay);\n    }\n  }\n\n  /**\n   * Removes the overlay from the DOM.\n   */\n  removeFromDOM() {\n    this.setBounds({ x: 0, y: 0, width: 0, height: 0 });\n    if (this.overlay.remove) {\n      this.overlay.remove();\n    } else if (this.overlay.parentNode) {\n      this.overlay.parentNode.removeChild(this.overlay);\n    }\n    if (this.usingShadowDOM) {\n      if (this.shadowContainer.remove) {\n        this.shadowContainer.remove();\n      } else if (this.shadowContainer.parentNode) {\n        this.shadowContainer.parentNode.removeChild(this.shadowContainer);\n      }\n    }\n  }\n\n  /**\n   * Enables pointer events on the overlay.\n   */\n  captureCursor() {\n    this.overlay.style.pointerEvents = 'auto';\n  }\n\n  /**\n   * Disables pointer events on the overlay.\n   */\n  ignoreCursor() {\n    this.overlay.style.pointerEvents = 'none';\n  }\n\n  /**\n   * Sets the position and size of the overlay.\n   * @param {Object} bounds - The bounding box.\n   * @param {number} bounds.x - The x-coordinate.\n   * @param {number} bounds.y - The y-coordinate.\n   * @param {number} bounds.width - The width.\n   * @param {number} bounds.height - The height.\n   */\n  setBounds(bounds) {\n    const { x, y, width, height } = bounds;\n    this.overlay.style.left = x + 'px';\n    this.overlay.style.top = y + 'px';\n    this.overlay.style.width = width + 'px';\n    this.overlay.style.height = height + 'px';\n  }\n}\n\n/**\n * Class representing an element picker that uses the overlay.\n */\nclass ElementPicker {\n  /**\n   * Create an ElementPicker.\n   * @param {Object} [overlayOptions] - Options to pass to ElementOverlay.\n   */\n  constructor(overlayOptions) {\n    this.active = false;\n    this.overlay = new ElementOverlay(overlayOptions || {});\n    this.handleMouseMove = this.handleMouseMove.bind(this);\n    this.handleClick = this.handleClick.bind(this);\n    this.tick = this.tick.bind(this);\n  }\n\n  /**\n   * Starts the element picking process.\n   * @param {Object} options - Picker options.\n   * @param {Node} [options.parentElement] - Parent element to attach the overlay.\n   * @param {boolean} [options.useShadowDOM=true] - Whether to use Shadow DOM.\n   * @param {Function} [options.onClick] - Callback invoked on click.\n   * @param {Function} [options.onHover] - Callback invoked on hover.\n   * @param {Function} [options.elementFilter] - Function to filter elements.\n   * @returns {boolean} True if started successfully, false if already active.\n   */\n  start(options) {\n    if (this.active) {\n      return false;\n    }\n    this.active = true;\n    this.options = options;\n\n    document.addEventListener('mousemove', this.handleMouseMove, true);\n    document.addEventListener('click', this.handleClick, true);\n\n    const parentElement = options.parentElement || document.body;\n    const useShadowDOM = options.useShadowDOM !== undefined ? options.useShadowDOM : true;\n    this.overlay.addToDOM(parentElement, useShadowDOM);\n    this.tick();\n\n    return true;\n  }\n\n  /**\n   * Stops the element picking process.\n   */\n  stop() {\n    this.active = false;\n    this.options = undefined;\n\n    document.removeEventListener('mousemove', this.handleMouseMove, true);\n    document.removeEventListener('click', this.handleClick, true);\n\n    this.overlay.removeFromDOM();\n    this.target = undefined;\n    this.mouseX = undefined;\n    this.mouseY = undefined;\n\n    if (this.tickReq) {\n      window.cancelAnimationFrame(this.tickReq);\n    }\n  }\n\n  /**\n   * Handles mouse move events.\n   * @param {MouseEvent} event - The mousemove event.\n   */\n  handleMouseMove(event) {\n    this.mouseX = event.clientX;\n    this.mouseY = event.clientY;\n  }\n\n  /**\n   * Handles click events.\n   * @param {MouseEvent} event - The click event.\n   */\n  handleClick(event) {\n    const clickedEl = document.elementFromPoint(event.clientX, event.clientY);\n    if (this.options && this.options.elementFilter && clickedEl && !this.options.elementFilter(clickedEl)) {\n      return;\n    }\n\n    event.preventDefault();\n    event.stopPropagation();\n    event.stopImmediatePropagation();\n\n    if (this.target && this.options && this.options.onClick) {\n      this.options.onClick(this.target);\n    }\n  }\n\n  /**\n   * The tick function that continuously updates the target element.\n   */\n  tick() {\n    this.updateTarget();\n    this.tickReq = window.requestAnimationFrame(this.tick);\n  }\n\n  /**\n   * Updates the target element based on the current mouse position.\n   */\n  updateTarget() {\n    if (this.mouseX === undefined || this.mouseY === undefined) {\n      return;\n    }\n\n    // Temporarily ignore the overlay's pointer events to detect the underlying element.\n    this.overlay.ignoreCursor();\n    const elAtCursor = document.elementFromPoint(this.mouseX, this.mouseY);\n    const newTarget = elAtCursor;\n    this.overlay.captureCursor();\n\n    // If the target hasn't changed, do nothing.\n    if (!newTarget || newTarget === this.target) {\n      return;\n    }\n\n    // If an element filter is provided and the new target doesn't match, clear the target.\n    if (this.options && this.options.elementFilter) {\n      if (!this.options.elementFilter(newTarget)) {\n        this.target = undefined;\n        this.overlay.setBounds({ x: 0, y: 0, width: 0, height: 0 });\n        return;\n      }\n    }\n\n    this.target = newTarget;\n    const bounds = getElementBounds(newTarget);\n    this.overlay.setBounds(bounds);\n\n    if (this.options && this.options.onHover) {\n      this.options.onHover(newTarget);\n    }\n  }\n}\n\nexport default ElementPicker;\n","import unique from './unique-selector/src/unique-selector';\nimport ElementPicker from './ElementPicker';\n\nclass GleapAdminHelper {\n  picker = null;\n  onElementPicked = null;\n\n  stopPicker = () => {\n    if (this.picker) {\n      this.picker.stop();\n      this.picker = null;\n      return;\n    }\n  };\n\n  startPicker = () => {\n    this.stopPicker();\n    var self = this;\n\n    const style = {\n      borderColor: '#2142E7',\n      background: 'transparent',\n      borderWidth: '4px',\n      borderRadius: '5px',\n    };\n    this.picker = new ElementPicker({ style });\n    this.picker.start({\n      useShadowDOM: false,\n      onClick: (el) => {\n        try {\n          let selector;\n          const tourId = el.getAttribute('data-gleap-tour');\n          if (tourId) {\n            selector = `[data-gleap-tour=\"${tourId}\"]`;\n          } else {\n            selector = unique(el);\n          }\n\n          self.onElementPicked && self.onElementPicked(selector);\n        } catch (e) {\n          console.error('Error while getting unique selector', e);\n        }\n      },\n      elementFilter: (el) => {\n        if (el.classList.contains('gleap-admin-collapse-ui') || el.closest('.gleap-admin-collapse-ui')) {\n          return false;\n        }\n        return true;\n      },\n    });\n  };\n\n  setMode = (mode) => {\n    this.mode = mode;\n    if (mode === 'navigate') {\n      this.stopPicker();\n    }\n    if (mode === 'picker') {\n      this.startPicker();\n    }\n  };\n}\n\nexport default GleapAdminHelper;\n","import { loadIcon } from './UI';\nimport GleapAdminHelper from './GleapAdminHelper';\nimport Gleap, { GleapModalManager, GleapProductTours, GleapBannerManager } from './Gleap';\n\nexport default class GleapAdminManager {\n  libraryInstance = null;\n  lastUrl = undefined;\n  injectedFrame = false;\n  gleapFrameContainer = null;\n  gleapCollapseUI = null;\n  injectedCollapseUI = false;\n  gleapFrame = null;\n  configData = null;\n  adminHelper = null;\n  status = 'navigate';\n  initialized = false;\n\n  // GleapAdminManager singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapAdminManager();\n    }\n\n    return this.instance;\n  }\n\n  logCurrentPage() {\n    const currentUrl = window.location.href;\n    if (currentUrl && currentUrl !== this.lastUrl) {\n      this.lastUrl = currentUrl;\n\n      this.sendMessageToTourBuilder({\n        name: 'page-changed',\n        data: {\n          page: currentUrl,\n        },\n      });\n    }\n  }\n\n  startPageListener() {\n    const self = this;\n    setInterval(function () {\n      self.logCurrentPage();\n    }, 1000);\n  }\n\n  initAdminHelper() {\n    const self = this;\n\n    // Disable product tours.\n    this.initialized = true;\n    GleapProductTours.getInstance().disable();\n    GleapBannerManager.getInstance().disable();\n    GleapModalManager.getInstance().disable();\n    Gleap.close();\n    Gleap.showFeedbackButton(false);\n\n    self.adminHelper = new GleapAdminHelper();\n\n    try {\n      self.adminHelper.onElementPicked = (selector) => {\n        self.toggleCollapseUI(true);\n        self.sendMessageToTourBuilder({\n          name: 'element-picked',\n          data: {\n            selector,\n          },\n        });\n      };\n    } catch (e) {\n      console.log(e);\n    }\n\n    self.injectFrame();\n    self.injectCollapseUI();\n    self.setFrameHeight('loading');\n  }\n\n  setFrameHeight(state) {\n    if (this.gleapFrameContainer) {\n      var height = '';\n      if (state === 'picker' || state === 'navigate') {\n        height = '65px';\n      } else if (state === 'editor') {\n        height = '100vh';\n      } else {\n        height = '0px';\n      }\n      this.gleapFrameContainer.style.height = height;\n    }\n  }\n\n  start() {\n    if (typeof window === 'undefined') {\n      return;\n    }\n\n    if (window.gleapAdminDisabled) {\n      return;\n    }\n\n    var self = this;\n\n    // Add window message listener.\n    window.addEventListener('message', (event) => {\n      if (event.origin !== 'https://app.gleap.io') {\n        return;\n      }\n\n      try {\n        const data = JSON.parse(event.data);\n\n        if (data.type === 'admin') {\n          if (data.name === 'load') {\n            self.configData = data.data;\n            self.initAdminHelper();\n          }\n\n          if (data.name === 'smartlink-search-result') {\n            this.sendMessageToTourBuilder({\n              name: 'smartlink-search-result',\n              data: data.data,\n            });\n          }\n\n          if (data.name === 'translate-complete') {\n            this.sendMessageToTourBuilder({\n              name: 'translate-complete',\n              data: data.data,\n            });\n          }\n        }\n\n        if (data.type === 'tourbuilder') {\n          if (data.name === 'loaddata') {\n            this.sendMessageToTourBuilder({\n              name: 'data',\n              data: {\n                ...self.configData,\n                currentPage: window.location.href,\n              },\n            });\n          }\n\n          if (data.name === 'highlight-element') {\n            // Cleanup.\n            document.querySelectorAll('.gleap-admin-highlight').forEach((el) => {\n              el.classList.remove('gleap-admin-highlight');\n            });\n\n            // Find the element and highlight it.\n            if (data?.data?.selector) {\n              const element = document.querySelector(data?.data?.selector);\n              if (element) {\n                element.classList.add('gleap-admin-highlight');\n              }\n            }\n          }\n\n          if (data.name === 'smartlink-search') {\n            this.sendMessage({\n              name: 'smartlink-search',\n              data: data.data,\n            });\n          }\n\n          if (data.name === 'product-tour-started') {\n            this.sendMessage({\n              name: 'product-tour-started',\n              data: data.data,\n            });\n          }\n\n          if (data.name === 'translate') {\n            this.sendMessage({\n              name: 'translate',\n              data: data.data,\n            });\n          }\n\n          if (data.name === 'save') {\n            this.sendMessage({\n              name: 'save',\n              data: data.data,\n            });\n          }\n\n          if (data.name === 'update-steps') {\n            this.sendMessage({\n              name: 'update-steps',\n              data: data.data,\n            });\n          }\n\n          if (data.name === 'click') {\n            try {\n              document.querySelector(data.data.selector).click();\n            } catch (e) {\n              console.log(e);\n            }\n          }\n\n          if (data.name === 'status-changed') {\n            self.status = data.data;\n            this.setFrameHeight(self.status);\n            self.adminHelper.stopPicker();\n\n            if (self.status === 'picker') {\n              self.adminHelper.startPicker();\n            }\n          }\n        }\n      } catch (exp) {}\n    });\n\n    this.sendMessage({\n      name: 'init',\n    });\n\n    this.startPageListener();\n  }\n\n  sendMessage(data) {\n    try {\n      if (window && window.opener) {\n        window.opener.postMessage(\n          JSON.stringify({\n            ...data,\n            type: 'admin',\n          }),\n          '*'\n        );\n      }\n    } catch (e) {}\n  }\n\n  sendMessageToTourBuilder(data) {\n    try {\n      if (this.gleapFrame && this.gleapFrame.contentWindow) {\n        this.gleapFrame.contentWindow.postMessage(\n          JSON.stringify({\n            ...data,\n            type: 'tourbuilder',\n          }),\n          '*'\n        );\n      }\n    } catch (e) {}\n  }\n\n  toggleCollapseUI = (onlyIfActive = false) => {\n    const COLLAPSE_UI_ACTIVE_CLASS = 'gleap-admin-collapse-ui-active';\n    const FRAME_CONTAINER_ACTIVE_CLASS = 'gleap-admin-frame-container-active';\n\n    // Helper function to check if an element has an active class\n    const isActive = (element, activeClass) => element && element.classList.contains(activeClass);\n\n    // Check if onlyIfActive is true and if the UI elements are already inactive\n    if (\n      onlyIfActive &&\n      (!isActive(this.gleapCollapseUI, COLLAPSE_UI_ACTIVE_CLASS) ||\n        !isActive(this.gleapFrameContainer, FRAME_CONTAINER_ACTIVE_CLASS))\n    ) {\n      return; // Return early without toggling the UI\n    }\n\n    // Toggle the UI elements\n    if (this.gleapCollapseUI) {\n      this.gleapCollapseUI.classList.toggle(COLLAPSE_UI_ACTIVE_CLASS);\n    }\n    if (this.gleapFrameContainer) {\n      this.gleapFrameContainer.classList.toggle(FRAME_CONTAINER_ACTIVE_CLASS);\n    }\n  };\n\n  injectCollapseUI = () => {\n    if (this.injectedCollapseUI) {\n      return;\n    }\n    this.injectedCollapseUI = true;\n\n    // Inject widget HTML.\n    var elem = document.createElement('div');\n    elem.className = 'gleap-admin-collapse-ui';\n    elem.innerHTML = `<div class=\"gleap-admin-collapse-ui-icon\">\n    ${loadIcon('arrowdown')}\n    </div>`;\n    document.body.appendChild(elem);\n\n    this.gleapCollapseUI = elem;\n\n    elem.addEventListener('click', (e) => {\n      e.stopImmediatePropagation();\n      e.stopPropagation();\n      e.preventDefault();\n\n      this.toggleCollapseUI();\n    });\n  };\n\n  injectFrame = () => {\n    if (this.injectedFrame) {\n      return;\n    }\n    this.injectedFrame = true;\n\n    // Inject widget HTML.\n    var elem = document.createElement('div');\n    elem.className = 'gleap-admin-frame-container';\n    elem.innerHTML = `<iframe src=\"https://app.gleap.io/${\n      this?.configData?.type === 'tooltips' ? 'tooltipbuilder' : 'producttourbuilder'\n    }\" class=\"gleap-admin-frame\" scrolling=\"no\" title=\"Gleap Admin Window\" allow=\"autoplay; encrypted-media; fullscreen;\" frameborder=\"0\"></iframe>`;\n    document.body.appendChild(elem);\n\n    this.gleapFrameContainer = elem;\n    this.gleapFrame = document.querySelector('.gleap-admin-frame');\n  };\n}\n","const GleapTours = (function () {\n  'use strict';\n  let currentConfig = {};\n  function configure(config = {}) {\n    currentConfig = {\n      animate: true,\n      allowClose: true,\n      overlayOpacity: 0.7,\n      smoothScroll: false,\n      disableActiveInteraction: false,\n      showProgress: false,\n      stagePadding: 10,\n      stageRadius: 5,\n      popoverOffset: 10,\n      showButtons: ['next', 'previous', 'close'],\n      disableButtons: [],\n      overlayColor: '#000',\n      ...config,\n    };\n  }\n  function getConfig(key) {\n    return key ? currentConfig[key] : currentConfig;\n  }\n  function easeInOutQuad(elapsed, initialValue, amountOfChange, duration) {\n    if ((elapsed /= duration / 2) < 1) {\n      return (amountOfChange / 2) * elapsed * elapsed + initialValue;\n    }\n    return (-amountOfChange / 2) * (--elapsed * (elapsed - 2) - 1) + initialValue;\n  }\n  function getFocusableElements(parentEls) {\n    const focusableQuery =\n      'a[href]:not([disabled]), button:not([disabled]), textarea:not([disabled]), input[type=\"text\"]:not([disabled]), input[type=\"radio\"]:not([disabled]), input[type=\"checkbox\"]:not([disabled]), select:not([disabled])';\n    return parentEls\n      .flatMap((parentEl) => {\n        const isParentFocusable = parentEl.matches(focusableQuery);\n        const focusableEls = Array.from(parentEl.querySelectorAll(focusableQuery));\n        return [...(isParentFocusable ? [parentEl] : []), ...focusableEls];\n      })\n      .filter((el) => {\n        return getComputedStyle(el).pointerEvents !== 'none' && isElementVisible(el);\n      });\n  }\n  function bringInView(element) {\n    if (!element || isElementInView(element)) {\n      return;\n    }\n    const shouldSmoothScroll = getConfig('smoothScroll');\n    element.scrollIntoView({\n      // Removing the smooth scrolling for elements which exist inside the scrollable parent\n      // This was causing the highlight to not properly render\n      behavior: !shouldSmoothScroll || hasScrollableParent(element) ? 'auto' : 'smooth',\n      inline: 'center',\n      block: 'center',\n    });\n  }\n  function hasScrollableParent(e) {\n    if (!e || !e.parentElement) {\n      return;\n    }\n    const parent = e.parentElement;\n    return parent.scrollHeight > parent.clientHeight;\n  }\n  function isElementInView(element) {\n    const rect = element.getBoundingClientRect();\n    return (\n      rect.top >= 0 &&\n      rect.left >= 0 &&\n      rect.bottom <= (window.innerHeight || document.documentElement.clientHeight) &&\n      rect.right <= (window.innerWidth || document.documentElement.clientWidth)\n    );\n  }\n  function isElementVisible(el) {\n    return !!(el.offsetWidth || el.offsetHeight || el.getClientRects().length);\n  }\n  let currentState = {};\n  function setState(key, value) {\n    currentState[key] = value;\n  }\n  function getState(key) {\n    return key ? currentState[key] : currentState;\n  }\n  function resetState() {\n    currentState = {};\n  }\n  let registeredListeners = {};\n  function listen(hook, callback) {\n    registeredListeners[hook] = callback;\n  }\n  function emit(hook) {\n    var _a;\n    (_a = registeredListeners[hook]) == null ? void 0 : _a.call(registeredListeners);\n  }\n  function destroyEmitter() {\n    registeredListeners = {};\n  }\n  function transitionStage(elapsed, duration, from, to) {\n    let activeStagePosition = getState('__activeStagePosition');\n    const fromDefinition = activeStagePosition ? activeStagePosition : from.getBoundingClientRect();\n    const toDefinition = to.getBoundingClientRect();\n    const x = easeInOutQuad(elapsed, fromDefinition.x, toDefinition.x - fromDefinition.x, duration);\n    const y = easeInOutQuad(elapsed, fromDefinition.y, toDefinition.y - fromDefinition.y, duration);\n    const width = easeInOutQuad(elapsed, fromDefinition.width, toDefinition.width - fromDefinition.width, duration);\n    const height = easeInOutQuad(elapsed, fromDefinition.height, toDefinition.height - fromDefinition.height, duration);\n    activeStagePosition = {\n      x,\n      y,\n      width,\n      height,\n    };\n    renderOverlay(activeStagePosition);\n    setState('__activeStagePosition', activeStagePosition);\n  }\n  function trackActiveElement(element) {\n    if (!element) {\n      return;\n    }\n    const definition = element.getBoundingClientRect();\n    const activeStagePosition = {\n      x: definition.x,\n      y: definition.y,\n      width: definition.width,\n      height: definition.height,\n    };\n    setState('__activeStagePosition', activeStagePosition);\n    renderOverlay(activeStagePosition);\n  }\n  function refreshOverlay() {\n    const activeStagePosition = getState('__activeStagePosition');\n    const overlaySvg = getState('__overlaySvg');\n    if (!activeStagePosition) {\n      return;\n    }\n    if (!overlaySvg) {\n      console.warn('No stage svg found.');\n      return;\n    }\n    const windowX = window.innerWidth;\n    const windowY = window.innerHeight;\n    overlaySvg.setAttribute('viewBox', `0 0 ${windowX} ${windowY}`);\n  }\n  function mountOverlay(stagePosition) {\n    const overlaySvg = createOverlaySvg(stagePosition);\n    document.body.appendChild(overlaySvg);\n    onDriverClick(overlaySvg, (e) => {\n      const target = e.target;\n      if (target.tagName !== 'path') {\n        return;\n      }\n      emit('overlayClick');\n    });\n    setState('__overlaySvg', overlaySvg);\n  }\n  function renderOverlay(stagePosition) {\n    const overlaySvg = getState('__overlaySvg');\n    if (!overlaySvg) {\n      mountOverlay(stagePosition);\n      return;\n    }\n    const pathElement = overlaySvg.firstElementChild;\n    if ((pathElement == null ? void 0 : pathElement.tagName) !== 'path') {\n      throw new Error('no path element found in stage svg');\n    }\n    pathElement.setAttribute('d', generateStageSvgPathString(stagePosition));\n  }\n  function createOverlaySvg(stage) {\n    const windowX = window.innerWidth;\n    const windowY = window.innerHeight;\n    const svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg');\n    svg.classList.add('gleap-tour-overlay', 'gleap-tour-overlay-animated');\n    svg.setAttribute('viewBox', `0 0 ${windowX} ${windowY}`);\n    svg.setAttribute('xmlSpace', 'preserve');\n    svg.setAttribute('xmlnsXlink', 'http://www.w3.org/1999/xlink');\n    svg.setAttribute('version', '1.1');\n    svg.setAttribute('preserveAspectRatio', 'xMinYMin slice');\n    svg.style.fillRule = 'evenodd';\n    svg.style.clipRule = 'evenodd';\n    svg.style.strokeLinejoin = 'round';\n    svg.style.strokeMiterlimit = '2';\n    svg.style.zIndex = '10000';\n    svg.style.position = 'fixed';\n    svg.style.top = '0';\n    svg.style.left = '0';\n    svg.style.width = '100%';\n    svg.style.height = '100%';\n    const stagePath = document.createElementNS('http://www.w3.org/2000/svg', 'path');\n    stagePath.setAttribute('d', generateStageSvgPathString(stage));\n    stagePath.style.fill = getConfig('overlayColor') || 'rgb(0,0,0)';\n    stagePath.style.opacity = `${getConfig('overlayOpacity')}`;\n    stagePath.style.pointerEvents = 'auto';\n    stagePath.style.cursor = 'auto';\n    svg.appendChild(stagePath);\n    return svg;\n  }\n  function generateStageSvgPathString(stage) {\n    const windowX = window.innerWidth;\n    const windowY = window.innerHeight;\n    const stagePadding = getConfig('stagePadding') || 0;\n    const stageRadius = getConfig('stageRadius') || 0;\n    const stageWidth = stage.width + stagePadding * 2;\n    const stageHeight = stage.height + stagePadding * 2;\n    const limitedRadius = Math.min(stageRadius, stageWidth / 2, stageHeight / 2);\n    const normalizedRadius = Math.floor(Math.max(limitedRadius, 0));\n    const highlightBoxX = stage.x - stagePadding + normalizedRadius;\n    const highlightBoxY = stage.y - stagePadding;\n    const highlightBoxWidth = stageWidth - normalizedRadius * 2;\n    const highlightBoxHeight = stageHeight - normalizedRadius * 2;\n    return `M${windowX},0L0,0L0,${windowY}L${windowX},${windowY}L${windowX},0Z\n    M${highlightBoxX},${highlightBoxY} h${highlightBoxWidth} a${normalizedRadius},${normalizedRadius} 0 0 1 ${normalizedRadius},${normalizedRadius} v${highlightBoxHeight} a${normalizedRadius},${normalizedRadius} 0 0 1 -${normalizedRadius},${normalizedRadius} h-${highlightBoxWidth} a${normalizedRadius},${normalizedRadius} 0 0 1 -${normalizedRadius},-${normalizedRadius} v-${highlightBoxHeight} a${normalizedRadius},${normalizedRadius} 0 0 1 ${normalizedRadius},-${normalizedRadius} z`;\n  }\n  function destroyOverlay() {\n    const overlaySvg = getState('__overlaySvg');\n    if (overlaySvg) {\n      overlaySvg.remove();\n    }\n  }\n  function mountDummyElement() {\n    const existingDummy = document.getElementById('gleap-tour-dummy-element');\n    if (existingDummy) {\n      return existingDummy;\n    }\n    let element = document.createElement('div');\n    element.id = 'gleap-tour-dummy-element';\n    element.style.width = '0';\n    element.style.height = '0';\n    element.style.pointerEvents = 'none';\n    element.style.opacity = '0';\n    element.style.position = 'fixed';\n    element.style.top = '50%';\n    element.style.left = '50%';\n    document.body.appendChild(element);\n    return element;\n  }\n  function highlight(step, attemptTime = 5000) {\n    const { element } = step;\n    let elemObj = element;\n    if (typeof elemObj === 'string') {\n      try {\n        elemObj = document.querySelector(element);\n      } catch (error) {\n        // This will escape colons within IDs but not affect pseudo-classes or other valid uses of colons\n        let refactoredElement = element.replace(/(#[^#\\s]+)/g, function (match) {\n          return match.replace(/:/g, '\\\\:');\n        });\n        elemObj = document.querySelector(refactoredElement);\n      }\n    }\n    if (element && !elemObj && attemptTime >= 0) {\n      setTimeout(() => {\n        hidePopover();\n        highlight(step, attemptTime - 100);\n      }, 100);\n\n      return;\n    }\n\n    if (!elemObj) {\n      if (step.mode === 'INPUT' || step.mode === 'CLICK') {\n        return getConfig('onElementNotFound')(step);\n      }\n    }\n\n    if (!elemObj) {\n      elemObj = mountDummyElement();\n    }\n\n    transferHighlight(elemObj, step);\n  }\n  function refreshActiveHighlight() {\n    var activeHighlight = getState('__activeElement');\n    const activeStep = getState('__activeStep');\n    if (!activeHighlight || !activeStep) {\n      return;\n    }\n\n    // Re-query the element if the cached reference is no longer in the DOM.\n    if (!document.body.contains(activeHighlight) && activeStep.element && typeof activeStep.element === 'string') {\n      try {\n        var freshEl = document.querySelector(activeStep.element);\n        if (!freshEl) {\n          var escaped = activeStep.element.replace(/(#[^#\\s]+)/g, function (match) {\n            return match.replace(/:/g, '\\\\:');\n          });\n          freshEl = document.querySelector(escaped);\n        }\n        if (freshEl) {\n          activeHighlight = freshEl;\n          setState('__activeElement', freshEl);\n          setState('activeElement', freshEl);\n          freshEl.classList.add('gleap-tour-active-element');\n        }\n      } catch (e) {}\n    }\n\n    trackActiveElement(activeHighlight);\n    refreshOverlay();\n    repositionPopover(activeHighlight, activeStep);\n  }\n  function transferHighlight(toElement, toStep) {\n    const duration = 400;\n    const start = Date.now();\n    const fromStep = getState('__activeStep');\n    const fromElement = getState('__activeElement') || toElement;\n    const isFirstHighlight = !fromElement || fromElement === toElement;\n    const isToDummyElement = toElement.id === 'gleap-tour-dummy-element';\n    const isFromDummyElement = fromElement.id === 'gleap-tour-dummy-element';\n    const isAnimatedTour = getConfig('animate');\n    const highlightStartedHook = toStep.onHighlightStarted || getConfig('onHighlightStarted');\n    const highlightedHook = (toStep == null ? void 0 : toStep.onHighlighted) || getConfig('onHighlighted');\n    const deselectedHook = (fromStep == null ? void 0 : fromStep.onDeselected) || getConfig('onDeselected');\n    const config = getConfig();\n    const state = getState();\n    if (!isFirstHighlight && deselectedHook) {\n      deselectedHook(isFromDummyElement ? void 0 : fromElement, fromStep, {\n        config,\n        state,\n      });\n    }\n    if (highlightStartedHook) {\n      highlightStartedHook(isToDummyElement ? void 0 : toElement, toStep, {\n        config,\n        state,\n      });\n    }\n    const hasDelayedPopover = !isFirstHighlight && isAnimatedTour;\n    let isPopoverRendered = false;\n    hidePopover();\n    setState('previousStep', fromStep);\n    setState('previousElement', fromElement);\n    setState('activeStep', toStep);\n    setState('activeElement', toElement);\n    const animate = () => {\n      const transitionCallback = getState('__transitionCallback');\n      if (transitionCallback !== animate) {\n        return;\n      }\n      const elapsed = Date.now() - start;\n      const timeRemaining = duration - elapsed;\n      const isHalfwayThrough = timeRemaining <= duration / 2;\n      if (toStep.popover && isHalfwayThrough && !isPopoverRendered && hasDelayedPopover) {\n        renderPopover(toElement, toStep);\n        isPopoverRendered = true;\n      }\n      if (getConfig('animate') && elapsed < duration) {\n        transitionStage(elapsed, duration, fromElement, toElement);\n      } else {\n        trackActiveElement(toElement);\n        if (highlightedHook) {\n          highlightedHook(isToDummyElement ? void 0 : toElement, toStep, {\n            config: getConfig(),\n            state: getState(),\n          });\n        }\n        setState('__transitionCallback', void 0);\n        setState('__previousStep', fromStep);\n        setState('__previousElement', fromElement);\n        setState('__activeStep', toStep);\n        setState('__activeElement', toElement);\n      }\n      window.requestAnimationFrame(animate);\n    };\n    setState('__transitionCallback', animate);\n    window.requestAnimationFrame(animate);\n    bringInView(toElement);\n    if (!hasDelayedPopover && toStep.popover) {\n      renderPopover(toElement, toStep);\n    }\n    fromElement.classList.remove('gleap-tour-active-element', 'gleap-tour-no-interaction');\n    fromElement.removeAttribute('aria-haspopup');\n    fromElement.removeAttribute('aria-expanded');\n    fromElement.removeAttribute('aria-controls');\n    const disableActiveInteraction = toStep.disableActiveInteraction ?? getConfig('disableActiveInteraction') ?? false;\n    if (disableActiveInteraction) {\n      toElement.classList.add('gleap-tour-no-interaction');\n    }\n    toElement.classList.add('gleap-tour-active-element');\n    toElement.setAttribute('aria-haspopup', 'dialog');\n    toElement.setAttribute('aria-expanded', 'true');\n    toElement.setAttribute('aria-controls', 'gleap-tour-popover-content');\n  }\n  function destroyHighlight() {\n    var _a;\n    (_a = document.getElementById('gleap-tour-dummy-element')) == null ? void 0 : _a.remove();\n    document.querySelectorAll('.gleap-tour-active-element').forEach((element) => {\n      element.classList.remove('gleap-tour-active-element', 'gleap-tour-no-interaction');\n      element.removeAttribute('aria-haspopup');\n      element.removeAttribute('aria-expanded');\n      element.removeAttribute('aria-controls');\n    });\n  }\n  function requireRefresh() {\n    const resizeTimeout = getState('__resizeTimeout');\n    if (resizeTimeout) {\n      window.cancelAnimationFrame(resizeTimeout);\n    }\n    setState('__resizeTimeout', window.requestAnimationFrame(refreshActiveHighlight));\n  }\n  function trapFocus(e) {\n    var _a;\n    const isActivated = getState('isInitialized');\n    if (!isActivated) {\n      return;\n    }\n    const isTabKey = e.key === 'Tab' || e.keyCode === 9;\n    if (!isTabKey) {\n      return;\n    }\n    const activeElement = getState('__activeElement');\n    const popoverEl = (_a = getState('popover')) == null ? void 0 : _a.wrapper;\n    const focusableEls = getFocusableElements([\n      ...(popoverEl ? [popoverEl] : []),\n      ...(activeElement ? [activeElement] : []),\n    ]);\n    const firstFocusableEl = focusableEls[0];\n    const lastFocusableEl = focusableEls[focusableEls.length - 1];\n    e.preventDefault();\n    if (e.shiftKey) {\n      const previousFocusableEl = focusableEls[focusableEls.indexOf(document.activeElement) - 1] || lastFocusableEl;\n      previousFocusableEl == null ? void 0 : previousFocusableEl.focus();\n    } else {\n      const nextFocusableEl = focusableEls[focusableEls.indexOf(document.activeElement) + 1] || firstFocusableEl;\n      nextFocusableEl == null ? void 0 : nextFocusableEl.focus();\n    }\n  }\n  function onKeyup(e) {\n    var _a;\n    const allowKeyboardControl = (_a = getConfig('allowKeyboardControl')) != null ? _a : true;\n    if (!allowKeyboardControl) {\n      return;\n    }\n    if (e.key === 'Escape') {\n      emit('escapePress');\n    } else if (e.key === 'ArrowRight') {\n      emit('arrowRightPress');\n    } else if (e.key === 'ArrowLeft') {\n      emit('arrowLeftPress');\n    }\n  }\n  function onDriverClick(element, listener, shouldPreventDefault) {\n    const listenerWrapper = (e, listener2) => {\n      const target = e.target;\n      if (!element.contains(target)) {\n        return;\n      }\n      if (!shouldPreventDefault || shouldPreventDefault(target)) {\n        e.preventDefault();\n        e.stopPropagation();\n        e.stopImmediatePropagation();\n      }\n      listener2 == null ? void 0 : listener2(e);\n    };\n    const useCapture = true;\n    document.addEventListener('pointerdown', listenerWrapper, useCapture);\n    document.addEventListener('mousedown', listenerWrapper, useCapture);\n    document.addEventListener('pointerup', listenerWrapper, useCapture);\n    document.addEventListener('mouseup', listenerWrapper, useCapture);\n    document.addEventListener(\n      'click',\n      (e) => {\n        listenerWrapper(e, listener);\n      },\n      useCapture\n    );\n  }\n  function initEvents() {\n    window.addEventListener('keyup', onKeyup, false);\n    window.addEventListener('keydown', trapFocus, false);\n    window.addEventListener('resize', requireRefresh);\n    window.addEventListener('scroll', requireRefresh);\n\n    const interval = setInterval(function () {\n      if (!getState('isInitialized')) return;\n      requireRefresh();\n    }, 1000);\n    setState('__positionInterval', interval);\n  }\n  function destroyEvents() {\n    window.removeEventListener('keyup', onKeyup);\n    window.removeEventListener('resize', requireRefresh);\n    window.removeEventListener('scroll', requireRefresh);\n\n    const interval = getState('__positionInterval');\n    if (interval) clearInterval(interval);\n  }\n  function hidePopover() {\n    const popover = getState('popover');\n    if (!popover) {\n      return;\n    }\n    popover.wrapper.style.display = 'none';\n  }\n  function renderPopover(element, step) {\n    var _a, _b;\n    let popover = getState('popover');\n    if (popover) {\n      document.body.removeChild(popover.wrapper);\n    }\n    popover = createPopover();\n    document.body.appendChild(popover.wrapper);\n    const {\n      title,\n      description,\n      showButtons,\n      disableButtons,\n      showProgress,\n      nextBtnText = getConfig('nextBtnText') || 'Next',\n      prevBtnText = getConfig('prevBtnText') || 'Previous',\n      progressText = getConfig('progressText') || '{current} of {total}',\n    } = step.popover || {};\n    popover.nextButton.innerHTML = nextBtnText;\n    popover.previousButton.innerHTML = prevBtnText;\n    popover.progress.innerHTML = progressText;\n    if (title) {\n      popover.title.innerHTML = title;\n      popover.title.style.display = 'block';\n    } else {\n      popover.title.style.display = 'none';\n    }\n    if (description) {\n      popover.description.innerHTML = description;\n      popover.description.style.display = 'block';\n    } else {\n      popover.description.style.display = 'none';\n    }\n    const showButtonsConfig = showButtons || getConfig('showButtons');\n    const showProgressConfig = showProgress || getConfig('showProgress') || false;\n    const showFooter =\n      (showButtonsConfig == null ? void 0 : showButtonsConfig.includes('next')) ||\n      (showButtonsConfig == null ? void 0 : showButtonsConfig.includes('previous')) ||\n      showProgressConfig;\n    popover.closeButton.style.display = showButtonsConfig.includes('close') ? 'block' : 'none';\n    if (showFooter) {\n      popover.footer.style.display = 'flex';\n      popover.progress.style.display = showProgressConfig ? 'block' : 'none';\n      popover.nextButton.style.display = showButtonsConfig.includes('next') ? 'block' : 'none';\n      popover.previousButton.style.display = showButtonsConfig.includes('previous') ? 'block' : 'none';\n    } else {\n      popover.footer.style.display = 'none';\n    }\n    const disabledButtonsConfig = disableButtons || getConfig('disableButtons') || [];\n    if (disabledButtonsConfig == null ? void 0 : disabledButtonsConfig.includes('next')) {\n      popover.nextButton.disabled = true;\n      popover.nextButton.classList.add('gleap-tour-popover-btn-disabled');\n    }\n    if (disabledButtonsConfig == null ? void 0 : disabledButtonsConfig.includes('previous')) {\n      popover.previousButton.disabled = true;\n      popover.previousButton.classList.add('gleap-tour-popover-btn-disabled');\n    }\n    if (disabledButtonsConfig == null ? void 0 : disabledButtonsConfig.includes('close')) {\n      popover.closeButton.disabled = true;\n      popover.closeButton.classList.add('gleap-tour-popover-btn-disabled');\n    }\n    const popoverWrapper = popover.wrapper;\n    popoverWrapper.style.display = 'block';\n    popoverWrapper.style.left = '';\n    popoverWrapper.style.top = '';\n    popoverWrapper.style.bottom = '';\n    popoverWrapper.style.right = '';\n    popoverWrapper.id = 'gleap-tour-popover-content';\n    popoverWrapper.setAttribute('role', 'dialog');\n    popoverWrapper.setAttribute('aria-labelledby', 'gleap-tour-popover-title');\n    popoverWrapper.setAttribute('aria-describedby', 'gleap-tour-popover-description');\n    const popoverArrow = popover.arrow;\n    popoverArrow.className = 'gleap-tour-popover-arrow';\n    const customPopoverClass = ((_a = step.popover) == null ? void 0 : _a.popoverClass) || getConfig('popoverClass') || '';\n    popoverWrapper.className = `gleap-tour-popover ${customPopoverClass}`.trim();\n    onDriverClick(\n      popover.wrapper,\n      (e) => {\n        var _a2, _b2, _c;\n        const target = e.target;\n        const onNextClick = ((_a2 = step.popover) == null ? void 0 : _a2.onNextClick) || getConfig('onNextClick');\n        const onPrevClick = ((_b2 = step.popover) == null ? void 0 : _b2.onPrevClick) || getConfig('onPrevClick');\n        const onCloseClick = ((_c = step.popover) == null ? void 0 : _c.onCloseClick) || getConfig('onCloseClick');\n        if (target.classList.contains('gleap-tour-popover-next-btn')) {\n          if (onNextClick) {\n            return onNextClick(element, step, {\n              config: getConfig(),\n              state: getState(),\n            });\n          } else {\n            return emit('nextClick');\n          }\n        }\n        if (target.classList.contains('gleap-tour-popover-prev-btn')) {\n          if (onPrevClick) {\n            return onPrevClick(element, step, {\n              config: getConfig(),\n              state: getState(),\n            });\n          } else {\n            return emit('prevClick');\n          }\n        }\n        if (target.classList.contains('gleap-tour-popover-close-btn')) {\n          if (onCloseClick) {\n            return onCloseClick(element, step, {\n              config: getConfig(),\n              state: getState(),\n            });\n          } else {\n            return emit('closeClick');\n          }\n        }\n        return void 0;\n      },\n      (target) => {\n        return (\n          !(popover == null ? void 0 : popover.description.contains(target)) &&\n          !(popover == null ? void 0 : popover.title.contains(target)) &&\n          typeof target.className === 'string' &&\n          target.className.includes('gleap-tour-popover')\n        );\n      }\n    );\n    setState('popover', popover);\n    const onPopoverRender = ((_b = step.popover) == null ? void 0 : _b.onPopoverRender) || getConfig('onPopoverRender');\n    if (onPopoverRender) {\n      onPopoverRender(popover, {\n        config: getConfig(),\n        state: getState(),\n      });\n    }\n    repositionPopover(element, step);\n    bringInView(popoverWrapper);\n    const isToDummyElement = element.classList.contains('gleap-tour-dummy-element');\n    const focusableElement = getFocusableElements([popoverWrapper, ...(isToDummyElement ? [] : [element])]);\n    if (focusableElement.length > 0) {\n      focusableElement[0].focus();\n    }\n  }\n  function getPopoverDimensions() {\n    const popover = getState('popover');\n    if (!(popover == null ? void 0 : popover.wrapper)) {\n      return;\n    }\n    const boundingClientRect = popover.wrapper.getBoundingClientRect();\n    const stagePadding = getConfig('stagePadding') || 0;\n    const popoverOffset = getConfig('popoverOffset') || 0;\n    return {\n      width: boundingClientRect.width + stagePadding + popoverOffset,\n      height: boundingClientRect.height + stagePadding + popoverOffset,\n      realWidth: boundingClientRect.width,\n      realHeight: boundingClientRect.height,\n    };\n  }\n  function calculateTopForLeftRight(alignment, config) {\n    const { elementDimensions, popoverDimensions, popoverPadding, popoverArrowDimensions } = config;\n    if (alignment === 'start') {\n      return Math.max(\n        Math.min(\n          elementDimensions.top - popoverPadding,\n          window.innerHeight - popoverDimensions.realHeight - popoverArrowDimensions.width\n        ),\n        popoverArrowDimensions.width\n      );\n    }\n    if (alignment === 'end') {\n      return Math.max(\n        Math.min(\n          elementDimensions.top -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realHeight) +\n            elementDimensions.height +\n            popoverPadding,\n          window.innerHeight -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realHeight) -\n            popoverArrowDimensions.width\n        ),\n        popoverArrowDimensions.width\n      );\n    }\n    if (alignment === 'center') {\n      return Math.max(\n        Math.min(\n          elementDimensions.top +\n            elementDimensions.height / 2 -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realHeight) / 2,\n          window.innerHeight -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realHeight) -\n            popoverArrowDimensions.width\n        ),\n        popoverArrowDimensions.width\n      );\n    }\n    return 0;\n  }\n  function calculateLeftForTopBottom(alignment, config) {\n    const { elementDimensions, popoverDimensions, popoverPadding, popoverArrowDimensions } = config;\n    if (alignment === 'start') {\n      return Math.max(\n        Math.min(\n          elementDimensions.left - popoverPadding,\n          window.innerWidth - popoverDimensions.realWidth - popoverArrowDimensions.width\n        ),\n        popoverArrowDimensions.width\n      );\n    }\n    if (alignment === 'end') {\n      return Math.max(\n        Math.min(\n          elementDimensions.left -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) +\n            elementDimensions.width +\n            popoverPadding,\n          window.innerWidth -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) -\n            popoverArrowDimensions.width\n        ),\n        popoverArrowDimensions.width\n      );\n    }\n    if (alignment === 'center') {\n      return Math.max(\n        Math.min(\n          elementDimensions.left +\n            elementDimensions.width / 2 -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) / 2,\n          window.innerWidth -\n            (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) -\n            popoverArrowDimensions.width\n        ),\n        popoverArrowDimensions.width\n      );\n    }\n    return 0;\n  }\n  function repositionPopover(element, step) {\n    const popover = getState('popover');\n    if (!popover) {\n      return;\n    }\n    const { align = 'start', side = 'left' } = (step == null ? void 0 : step.popover) || {};\n    const requiredAlignment = align;\n    const requiredSide = element.id === 'gleap-tour-dummy-element' ? 'over' : side;\n    const popoverPadding = getConfig('stagePadding') || 0;\n    const popoverDimensions = getPopoverDimensions();\n    const popoverArrowDimensions = popover.arrow.getBoundingClientRect();\n    const elementDimensions = element.getBoundingClientRect();\n    const topValue = elementDimensions.top - popoverDimensions.height;\n    let isTopOptimal = topValue >= 0;\n    const bottomValue = window.innerHeight - (elementDimensions.bottom + popoverDimensions.height);\n    let isBottomOptimal = bottomValue >= 0;\n    const leftValue = elementDimensions.left - popoverDimensions.width;\n    let isLeftOptimal = leftValue >= 0;\n    const rightValue = window.innerWidth - (elementDimensions.right + popoverDimensions.width);\n    let isRightOptimal = rightValue >= 0;\n    const noneOptimal = !isTopOptimal && !isBottomOptimal && !isLeftOptimal && !isRightOptimal;\n    let popoverRenderedSide = requiredSide;\n    if (requiredSide === 'top' && isTopOptimal) {\n      isRightOptimal = isLeftOptimal = isBottomOptimal = false;\n    } else if (requiredSide === 'bottom' && isBottomOptimal) {\n      isRightOptimal = isLeftOptimal = isTopOptimal = false;\n    } else if (requiredSide === 'left' && isLeftOptimal) {\n      isRightOptimal = isTopOptimal = isBottomOptimal = false;\n    } else if (requiredSide === 'right' && isRightOptimal) {\n      isLeftOptimal = isTopOptimal = isBottomOptimal = false;\n    }\n    if (requiredSide === 'over') {\n      const leftToSet = window.innerWidth / 2 - popoverDimensions.realWidth / 2;\n      const topToSet = window.innerHeight / 2 - popoverDimensions.realHeight / 2;\n      popover.wrapper.style.left = `${leftToSet}px`;\n      popover.wrapper.style.right = `auto`;\n      popover.wrapper.style.top = `${topToSet}px`;\n      popover.wrapper.style.bottom = `auto`;\n    } else if (noneOptimal) {\n      const leftValue2 = window.innerWidth / 2 - (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) / 2;\n      const bottomValue2 = 10;\n      popover.wrapper.style.left = `${leftValue2}px`;\n      popover.wrapper.style.right = `auto`;\n      popover.wrapper.style.bottom = `${bottomValue2}px`;\n      popover.wrapper.style.top = `auto`;\n    } else if (isLeftOptimal) {\n      const leftToSet = Math.min(\n        leftValue,\n        window.innerWidth - (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) - popoverArrowDimensions.width\n      );\n      const topToSet = calculateTopForLeftRight(requiredAlignment, {\n        elementDimensions,\n        popoverDimensions,\n        popoverPadding,\n        popoverArrowDimensions,\n      });\n      popover.wrapper.style.left = `${leftToSet}px`;\n      popover.wrapper.style.top = `${topToSet}px`;\n      popover.wrapper.style.bottom = `auto`;\n      popover.wrapper.style.right = 'auto';\n      popoverRenderedSide = 'left';\n    } else if (isRightOptimal) {\n      const rightToSet = Math.min(\n        rightValue,\n        window.innerWidth - (popoverDimensions == null ? void 0 : popoverDimensions.realWidth) - popoverArrowDimensions.width\n      );\n      const topToSet = calculateTopForLeftRight(requiredAlignment, {\n        elementDimensions,\n        popoverDimensions,\n        popoverPadding,\n        popoverArrowDimensions,\n      });\n      popover.wrapper.style.right = `${rightToSet}px`;\n      popover.wrapper.style.top = `${topToSet}px`;\n      popover.wrapper.style.bottom = `auto`;\n      popover.wrapper.style.left = 'auto';\n      popoverRenderedSide = 'right';\n    } else if (isTopOptimal) {\n      const topToSet = Math.min(topValue, window.innerHeight - popoverDimensions.realHeight - popoverArrowDimensions.width);\n      let leftToSet = calculateLeftForTopBottom(requiredAlignment, {\n        elementDimensions,\n        popoverDimensions,\n        popoverPadding,\n        popoverArrowDimensions,\n      });\n      popover.wrapper.style.top = `${topToSet}px`;\n      popover.wrapper.style.left = `${leftToSet}px`;\n      popover.wrapper.style.bottom = `auto`;\n      popover.wrapper.style.right = 'auto';\n      popoverRenderedSide = 'top';\n    } else if (isBottomOptimal) {\n      const bottomToSet = Math.min(\n        bottomValue,\n        window.innerHeight -\n          (popoverDimensions == null ? void 0 : popoverDimensions.realHeight) -\n          popoverArrowDimensions.width\n      );\n      let leftToSet = calculateLeftForTopBottom(requiredAlignment, {\n        elementDimensions,\n        popoverDimensions,\n        popoverPadding,\n        popoverArrowDimensions,\n      });\n      popover.wrapper.style.left = `${leftToSet}px`;\n      popover.wrapper.style.bottom = `${bottomToSet}px`;\n      popover.wrapper.style.top = `auto`;\n      popover.wrapper.style.right = 'auto';\n      popoverRenderedSide = 'bottom';\n    }\n    if (!noneOptimal) {\n      renderPopoverArrow(requiredAlignment, popoverRenderedSide, element);\n    } else {\n      popover.arrow.classList.add('gleap-tour-popover-arrow-none');\n    }\n  }\n  function renderPopoverArrow(alignment, side, element) {\n    const popover = getState('popover');\n    if (!popover) {\n      return;\n    }\n    const elementDimensions = element.getBoundingClientRect();\n    const popoverDimensions = getPopoverDimensions();\n    const popoverArrow = popover.arrow;\n    const popoverWidth = popoverDimensions.width;\n    const windowWidth = window.innerWidth;\n    const elementWidth = elementDimensions.width;\n    const elementLeft = elementDimensions.left;\n    const popoverHeight = popoverDimensions.height;\n    const windowHeight = window.innerHeight;\n    const elementTop = elementDimensions.top;\n    const elementHeight = elementDimensions.height;\n    popoverArrow.className = 'gleap-tour-popover-arrow';\n    let arrowSide = side;\n    let arrowAlignment = alignment;\n    if (side === 'top') {\n      if (elementLeft + elementWidth <= 0) {\n        arrowSide = 'right';\n        arrowAlignment = 'end';\n      } else if (elementLeft + elementWidth - popoverWidth <= 0) {\n        arrowSide = 'top';\n        arrowAlignment = 'start';\n      }\n      if (elementLeft >= windowWidth) {\n        arrowSide = 'left';\n        arrowAlignment = 'end';\n      } else if (elementLeft + popoverWidth >= windowWidth) {\n        arrowSide = 'top';\n        arrowAlignment = 'end';\n      }\n    } else if (side === 'bottom') {\n      if (elementLeft + elementWidth <= 0) {\n        arrowSide = 'right';\n        arrowAlignment = 'start';\n      } else if (elementLeft + elementWidth - popoverWidth <= 0) {\n        arrowSide = 'bottom';\n        arrowAlignment = 'start';\n      }\n      if (elementLeft >= windowWidth) {\n        arrowSide = 'left';\n        arrowAlignment = 'start';\n      } else if (elementLeft + popoverWidth >= windowWidth) {\n        arrowSide = 'bottom';\n        arrowAlignment = 'end';\n      }\n    } else if (side === 'left') {\n      if (elementTop + elementHeight <= 0) {\n        arrowSide = 'bottom';\n        arrowAlignment = 'end';\n      } else if (elementTop + elementHeight - popoverHeight <= 0) {\n        arrowSide = 'left';\n        arrowAlignment = 'start';\n      }\n      if (elementTop >= windowHeight) {\n        arrowSide = 'top';\n        arrowAlignment = 'end';\n      } else if (elementTop + popoverHeight >= windowHeight) {\n        arrowSide = 'left';\n        arrowAlignment = 'end';\n      }\n    } else if (side === 'right') {\n      if (elementTop + elementHeight <= 0) {\n        arrowSide = 'bottom';\n        arrowAlignment = 'start';\n      } else if (elementTop + elementHeight - popoverHeight <= 0) {\n        arrowSide = 'right';\n        arrowAlignment = 'start';\n      }\n      if (elementTop >= windowHeight) {\n        arrowSide = 'top';\n        arrowAlignment = 'start';\n      } else if (elementTop + popoverHeight >= windowHeight) {\n        arrowSide = 'right';\n        arrowAlignment = 'end';\n      }\n    } else;\n    if (!arrowSide) {\n      popoverArrow.classList.add('gleap-tour-popover-arrow-none');\n    } else {\n      popoverArrow.classList.add(`gleap-tour-popover-arrow-side-${arrowSide}`);\n      popoverArrow.classList.add(`gleap-tour-popover-arrow-align-${arrowAlignment}`);\n    }\n  }\n  function createPopover() {\n    const wrapper = document.createElement('div');\n    wrapper.classList.add('gleap-tour-popover');\n    const arrow = document.createElement('div');\n    arrow.classList.add('gleap-tour-popover-arrow');\n    const title = document.createElement('div');\n    title.id = 'gleap-tour-popover-title';\n    title.classList.add('gleap-tour-popover-title');\n    title.style.display = 'none';\n    title.innerText = 'Popover Title';\n    const description = document.createElement('div');\n    description.id = 'gleap-tour-popover-description';\n    description.classList.add('gleap-tour-popover-description');\n    description.style.display = 'none';\n    description.innerText = 'Popover description is here';\n    const closeButton = document.createElement('button');\n    closeButton.type = 'button';\n    closeButton.classList.add('gleap-tour-popover-close-btn');\n    closeButton.setAttribute('aria-label', 'Close');\n    closeButton.innerHTML = '&times;';\n    const footer = document.createElement('div');\n    footer.classList.add('gleap-tour-popover-footer');\n    const progress = document.createElement('span');\n    progress.classList.add('gleap-tour-popover-progress-text');\n    progress.innerText = '';\n    const footerButtons = document.createElement('span');\n    footerButtons.classList.add('gleap-tour-popover-navigation-btns');\n    const previousButton = document.createElement('button');\n    previousButton.type = 'button';\n    previousButton.classList.add('gleap-tour-popover-prev-btn');\n    previousButton.innerHTML = '&larr; Previous';\n    const nextButton = document.createElement('button');\n    nextButton.type = 'button';\n    nextButton.classList.add('gleap-tour-popover-next-btn');\n    nextButton.innerHTML = 'Next &rarr;';\n    footerButtons.appendChild(previousButton);\n    footerButtons.appendChild(nextButton);\n    footer.appendChild(progress);\n    footer.appendChild(footerButtons);\n    wrapper.appendChild(closeButton);\n    wrapper.appendChild(arrow);\n    wrapper.appendChild(title);\n    wrapper.appendChild(description);\n    wrapper.appendChild(footer);\n    return {\n      wrapper,\n      arrow,\n      title,\n      description,\n      footer,\n      previousButton,\n      nextButton,\n      closeButton,\n      footerButtons,\n      progress,\n    };\n  }\n  function destroyPopover() {\n    var _a;\n    const popover = getState('popover');\n    if (!popover) {\n      return;\n    }\n    (_a = popover.wrapper.parentElement) == null ? void 0 : _a.removeChild(popover.wrapper);\n  }\n  function driver(options = {}) {\n    configure(options);\n    function handleClose() {\n      if (!getConfig('allowClose')) {\n        return;\n      }\n      destroy();\n    }\n    function moveNext() {\n      const activeIndex = getState('activeIndex');\n      const steps = getConfig('steps') || [];\n      if (typeof activeIndex === 'undefined') {\n        return;\n      }\n      const nextStepIndex = activeIndex + 1;\n      if (steps[nextStepIndex]) {\n        drive(nextStepIndex);\n      } else {\n        destroy();\n      }\n    }\n    function movePrevious() {\n      const activeIndex = getState('activeIndex');\n      const steps = getConfig('steps') || [];\n      if (typeof activeIndex === 'undefined') {\n        return;\n      }\n      const previousStepIndex = activeIndex - 1;\n      if (steps[previousStepIndex]) {\n        drive(previousStepIndex);\n      } else {\n        destroy();\n      }\n    }\n    function moveTo(index) {\n      const steps = getConfig('steps') || [];\n      if (steps[index]) {\n        drive(index);\n      } else {\n        destroy();\n      }\n    }\n    function handleArrowLeft() {\n      var _a;\n      const isTransitioning = getState('__transitionCallback');\n      if (isTransitioning) {\n        return;\n      }\n      const activeIndex = getState('activeIndex');\n      const activeStep = getState('__activeStep');\n      const activeElement = getState('__activeElement');\n\n      if (activeStep.mode === 'CLICK') {\n        return;\n      }\n      if (typeof activeIndex === 'undefined' || typeof activeStep === 'undefined') {\n        return;\n      }\n      const currentStepIndex = getState('activeIndex');\n      if (typeof currentStepIndex === 'undefined') {\n        return;\n      }\n      const onPrevClick = ((_a = activeStep.popover) == null ? void 0 : _a.onPrevClick) || getConfig('onPrevClick');\n      if (onPrevClick) {\n        return onPrevClick(activeElement, activeStep, {\n          config: getConfig(),\n          state: getState(),\n        });\n      }\n      movePrevious();\n    }\n    function handleArrowRight() {\n      var _a;\n      const isTransitioning = getState('__transitionCallback');\n      if (isTransitioning) {\n        return;\n      }\n      const activeIndex = getState('activeIndex');\n      const activeStep = getState('__activeStep');\n      const activeElement = getState('__activeElement');\n\n      if (activeStep.mode === 'CLICK') {\n        return;\n      }\n      if (typeof activeIndex === 'undefined' || typeof activeStep === 'undefined') {\n        return;\n      }\n      const onNextClick = ((_a = activeStep.popover) == null ? void 0 : _a.onNextClick) || getConfig('onNextClick');\n      if (onNextClick) {\n        return onNextClick(activeElement, activeStep, {\n          config: getConfig(),\n          state: getState(),\n        });\n      }\n      moveNext();\n    }\n    function init() {\n      if (getState('isInitialized')) {\n        return;\n      }\n      setState('isInitialized', true);\n      document.body.classList.add('gleap-tour-active', getConfig('animate') ? 'gleap-tour-fade' : 'gleap-tour-simple');\n      initEvents();\n      listen('overlayClick', handleClose);\n      listen('escapePress', handleClose);\n      listen('arrowLeftPress', handleArrowLeft);\n      listen('arrowRightPress', handleArrowRight);\n    }\n    function drive(stepIndex = 0) {\n      var _a, _b, _c, _d, _e, _f, _g, _h;\n      const steps = getConfig('steps');\n      if (!steps) {\n        console.error('No steps to drive through');\n        destroy();\n        return;\n      }\n      if (!steps[stepIndex]) {\n        destroy();\n        return;\n      }\n      setState('__activeOnDestroyed', document.activeElement);\n      setState('activeIndex', stepIndex);\n      const currentStep = steps[stepIndex];\n      const hasNextStep = steps[stepIndex + 1];\n      const hasPreviousStep = steps[stepIndex - 1];\n      const doneBtnText =\n        ((_a = currentStep.popover) == null ? void 0 : _a.doneBtnText) || getConfig('doneBtnText') || 'Done';\n      const allowsClosing = getConfig('allowClose');\n      const showProgress =\n        typeof ((_b = currentStep.popover) == null ? void 0 : _b.showProgress) !== 'undefined'\n          ? (_c = currentStep.popover) == null\n            ? void 0\n            : _c.showProgress\n          : getConfig('showProgress');\n      const progressText =\n        ((_d = currentStep.popover) == null ? void 0 : _d.progressText) ||\n        getConfig('progressText') ||\n        '{{current}} of {{total}}';\n      const progressTextReplaced = progressText\n        .replace('{{current}}', `${stepIndex + 1}`)\n        .replace('{{total}}', `${steps.length}`);\n      const configuredButtons = ((_e = currentStep.popover) == null ? void 0 : _e.showButtons) || getConfig('showButtons');\n      const calculatedButtons = ['next', 'previous', ...(allowsClosing ? ['close'] : [])].filter((b) => {\n        return !(configuredButtons == null ? void 0 : configuredButtons.length) || configuredButtons.includes(b);\n      });\n      const onNextClick = ((_f = currentStep.popover) == null ? void 0 : _f.onNextClick) || getConfig('onNextClick');\n      const onPrevClick = ((_g = currentStep.popover) == null ? void 0 : _g.onPrevClick) || getConfig('onPrevClick');\n      const onCloseClick = ((_h = currentStep.popover) == null ? void 0 : _h.onCloseClick) || getConfig('onCloseClick');\n      highlight({\n        ...currentStep,\n        popover: {\n          showButtons: calculatedButtons,\n          nextBtnText: !hasNextStep ? doneBtnText : void 0,\n          disableButtons: [...(!hasPreviousStep ? ['previous'] : [])],\n          showProgress,\n          progressText: progressTextReplaced,\n          onNextClick: onNextClick\n            ? onNextClick\n            : () => {\n                if (!hasNextStep) {\n                  destroy();\n                } else {\n                  drive(stepIndex + 1);\n                }\n              },\n          onPrevClick: onPrevClick\n            ? onPrevClick\n            : () => {\n                drive(stepIndex - 1);\n              },\n          onCloseClick: onCloseClick\n            ? onCloseClick\n            : () => {\n                destroy();\n              },\n          ...((currentStep == null ? void 0 : currentStep.popover) || {}),\n        },\n      });\n    }\n    function destroy(withOnDestroyStartedHook = true) {\n      const activeElement = getState('__activeElement');\n      const activeStep = getState('__activeStep');\n      const activeOnDestroyed = getState('__activeOnDestroyed');\n      const onDestroyStarted = getConfig('onDestroyStarted');\n      if (withOnDestroyStartedHook && onDestroyStarted) {\n        const isActiveDummyElement =\n          !activeElement || (activeElement == null ? void 0 : activeElement.id) === 'gleap-tour-dummy-element';\n        onDestroyStarted(isActiveDummyElement ? void 0 : activeElement, activeStep, {\n          config: getConfig(),\n          state: getState(),\n        });\n        return;\n      }\n      const onDeselected = (activeStep == null ? void 0 : activeStep.onDeselected) || getConfig('onDeselected');\n      const onDestroyed = getConfig('onDestroyed');\n      document.body.classList.remove('gleap-tour-active', 'gleap-tour-fade', 'gleap-tour-simple');\n      destroyEvents();\n      destroyPopover();\n      destroyHighlight();\n      destroyOverlay();\n      destroyEmitter();\n      resetState();\n      if (activeElement && activeStep) {\n        const isActiveDummyElement = activeElement.id === 'gleap-tour-dummy-element';\n        if (onDeselected) {\n          onDeselected(isActiveDummyElement ? void 0 : activeElement, activeStep, {\n            config: getConfig(),\n            state: getState(),\n          });\n        }\n        if (onDestroyed) {\n          onDestroyed(isActiveDummyElement ? void 0 : activeElement, activeStep, {\n            config: getConfig(),\n            state: getState(),\n          });\n        }\n      }\n      if (activeOnDestroyed) {\n        activeOnDestroyed.focus();\n      }\n    }\n    return {\n      isActive: () => getState('isInitialized') || false,\n      refresh: requireRefresh,\n      drive: (stepIndex = 0) => {\n        init();\n        drive(stepIndex);\n      },\n      setConfig: configure,\n      setSteps: (steps) => {\n        resetState();\n        configure({\n          ...getConfig(),\n          steps,\n        });\n      },\n      getConfig,\n      getState,\n      getActiveIndex: () => getState('activeIndex'),\n      isFirstStep: () => getState('activeIndex') === 0,\n      isLastStep: () => {\n        const steps = getConfig('steps') || [];\n        const activeIndex = getState('activeIndex');\n        return activeIndex !== void 0 && activeIndex === steps.length - 1;\n      },\n      getActiveStep: () => getState('activeStep'),\n      getActiveElement: () => getState('activeElement'),\n      getPreviousElement: () => getState('previousElement'),\n      getPreviousStep: () => getState('previousStep'),\n      moveNext,\n      movePrevious,\n      moveTo,\n      hasNextStep: () => {\n        const steps = getConfig('steps') || [];\n        const activeIndex = getState('activeIndex');\n        return activeIndex !== void 0 && steps[activeIndex + 1];\n      },\n      hasPreviousStep: () => {\n        const steps = getConfig('steps') || [];\n        const activeIndex = getState('activeIndex');\n        return activeIndex !== void 0 && steps[activeIndex - 1];\n      },\n      highlight: (step) => {\n        init();\n        highlight({\n          ...step,\n          popover: step.popover\n            ? {\n                showButtons: [],\n                showProgress: false,\n                progressText: '',\n                ...step.popover,\n              }\n            : void 0,\n        });\n      },\n      destroy: () => {\n        destroy(false);\n      },\n    };\n  }\n  return driver;\n})({});\n\nexport default GleapTours;\n","import { GleapConfigManager, GleapTranslationManager } from './Gleap';\nimport { calculateContrast, loadIcon } from './UI';\n\nconst localStorageKey = 'gleap-tour-data';\nconst pointerContainerId = 'copilot-pointer-container';\nconst styleId = 'copilot-tour-styles';\nconst copilotJoinedContainerId = 'copilot-joined-container';\n\nfunction estimateReadTime(text) {\n  if (typeof window === 'undefined') return;\n\n  const wordsPerSecond = 3.6; // Average reading speed\n  const wordCount = text.split(/\\s+/).filter((word) => word.length > 0).length;\n  const readTimeInSeconds = Math.ceil(wordCount / wordsPerSecond);\n  return readTimeInSeconds + 1;\n}\n\nfunction htmlToPlainText(html) {\n  if (typeof window === 'undefined') return;\n\n  const tempDiv = document.createElement('div');\n  tempDiv.innerHTML = html;\n  return tempDiv.textContent || '';\n}\n\nfunction scrollToElement(element) {\n  if (typeof window === 'undefined') return;\n\n  if (element) {\n    element.scrollIntoView({\n      behavior: 'smooth',\n      block: 'center',\n      inline: 'center',\n    });\n  }\n}\n\nfunction performClickAnimation(posX, posY) {\n  if (typeof window === 'undefined') return;\n\n  const wave = document.createElement('div');\n  wave.className = 'click-wave';\n  wave.style.left = `${posX - 17}px`;\n  wave.style.top = `${posY - 17}px`;\n  document.body.appendChild(wave);\n  setTimeout(() => {\n    wave.remove();\n  }, 800);\n}\n\nfunction waitForElement(selector, timeout = 5000) {\n  if (typeof window === 'undefined') return;\n\n  const pollInterval = 100;\n  const maxAttempts = timeout / pollInterval;\n  let attempts = 0;\n  return new Promise((resolve, reject) => {\n    const interval = setInterval(() => {\n      const element = document.querySelector(selector);\n      if (element) {\n        clearInterval(interval);\n        resolve(element);\n      } else if (attempts >= maxAttempts) {\n        clearInterval(interval);\n        reject(new Error(`Element not found for selector: ${selector}`));\n      }\n      attempts++;\n    }, pollInterval);\n  });\n}\n\nfunction smoothScrollToY(yPosition) {\n  if (typeof window === 'undefined') return;\n\n  const viewportHeight = window.innerHeight;\n  const targetScrollPosition = yPosition - viewportHeight / 2;\n  window.scrollTo({\n    top: targetScrollPosition,\n    behavior: 'smooth',\n  });\n}\n\nasync function canPlayAudio() {\n  if (typeof window === 'undefined') return;\n\n  const audio = new Audio('data:audio/wav;base64,UklGRigAAABXQVZFZm10IBAAAAABAAEARKwAABCxAgAEABAAZGF0YQAAAAA=');\n  try {\n    await audio.play();\n    return true;\n  } catch (err) {\n    return false;\n  }\n}\n\n// Helper: Check if an element is fully visible in the viewport.\nfunction isElementFullyVisible(el) {\n  if (typeof window === 'undefined') return;\n\n  const rect = el.getBoundingClientRect();\n  return rect.top >= 0 && rect.left >= 0 && rect.bottom <= window.innerHeight && rect.right <= window.innerWidth;\n}\n\n// Helper: Get scrollable ancestors of an element.\nfunction getScrollableAncestors(el) {\n  if (typeof window === 'undefined') return;\n\n  let ancestors = [];\n  let current = el.parentElement;\n  while (current) {\n    const style = window.getComputedStyle(current);\n    if ((style.overflowY === 'auto' || style.overflowY === 'scroll') && current.scrollHeight > current.clientHeight) {\n      ancestors.push(current);\n    }\n    current = current.parentElement;\n  }\n  return ancestors;\n}\n\nexport default class GleapCopilotTours {\n  productTourData = undefined;\n  productTourId = undefined;\n  currentActiveIndex = undefined;\n  lastArrowPositionX = undefined;\n  lastArrowPositionY = undefined;\n  onCompleteCallback = undefined;\n  audioMuted = false;\n  currentAudio = undefined;\n\n  // Cached pointer container.\n  _pointerContainer = null;\n  // For scroll handling.\n  _scrollListeners = [];\n  _currentAnchor = null;\n  _currentStep = null;\n  _scrollDebounceTimer = null;\n\n  // GleapReplayRecorder singleton.\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapCopilotTours();\n    }\n    return this.instance;\n  }\n\n  constructor() {\n    const self = this;\n\n    if (typeof window !== 'undefined') {\n      this._scrollListeners = [];\n      this._currentAnchor = null;\n      this._currentStep = null;\n      this._scrollDebounceTimer = null;\n\n      window.addEventListener('resize', () => {\n        if (self.productTourId && self.currentActiveIndex >= 0 && self.productTourData && self.productTourData.steps) {\n          const steps = self.productTourData.steps;\n          const currentStep = steps[self.currentActiveIndex];\n          if (currentStep && currentStep.selector && currentStep.selector !== '') {\n            self.updatePointerPosition(document.querySelector(currentStep.selector), currentStep);\n          }\n        }\n      });\n    }\n  }\n\n  disable() {\n    this.disabled = true;\n\n    this.cleanup();\n  }\n\n  startWithConfig(tourId, config, onCompleteCallback = undefined) {\n    if (typeof window === 'undefined') return;\n    if (this.productTourId) return;\n    if (this.disabled) return;\n\n    this.productTourId = tourId;\n    this.productTourData = config;\n    this.currentActiveIndex = 0;\n    this.onCompleteCallback = onCompleteCallback;\n    this.start();\n  }\n\n  storeUncompletedTour() {\n    if (typeof window === 'undefined') return;\n    if (this.productTourId && this.productTourData) {\n      try {\n        let data = JSON.parse(\n          JSON.stringify({\n            tourData: this.productTourData,\n            tourId: this.productTourId,\n          })\n        );\n        data.tourData.steps = data.tourData.steps.slice(this.currentActiveIndex || 0, data.tourData.steps.length);\n        localStorage.setItem(localStorageKey, JSON.stringify(data));\n      } catch (e) {\n        // Optionally log error in development mode.\n      }\n    } else {\n      localStorage.removeItem(localStorageKey);\n    }\n  }\n\n  // Attach scroll listeners with a debounce to update the pointer position after scrolling stops.\n  attachScrollListeners(anchor, currentStep) {\n    if (typeof window === 'undefined') return;\n    if (!anchor) return;\n    const scrollableAncestors = getScrollableAncestors(anchor);\n    // Also include window.\n    scrollableAncestors.push(window);\n    scrollableAncestors.forEach((el) => {\n      const handler = () => {\n        clearTimeout(this._scrollDebounceTimer);\n        this._scrollDebounceTimer = setTimeout(() => {\n          this.updatePointerPosition(anchor, currentStep);\n        }, 150);\n      };\n      el.addEventListener('scroll', handler, { passive: true });\n      this._scrollListeners.push({ el, handler });\n    });\n  }\n\n  // Remove scroll listeners and clear debounce timer.\n  removeScrollListeners() {\n    if (typeof window === 'undefined') return;\n    if (this._scrollListeners && this._scrollListeners.length > 0) {\n      this._scrollListeners.forEach(({ el, handler }) => {\n        el.removeEventListener('scroll', handler);\n      });\n      this._scrollListeners = [];\n    }\n    if (this._scrollDebounceTimer) {\n      clearTimeout(this._scrollDebounceTimer);\n      this._scrollDebounceTimer = null;\n    }\n  }\n\n  // Updated pointer position:\n  // 1. Scroll the element into view.\n  // 2. After the element is fully visible (or after a maximum delay), update the pointer position to point towards the element.\n  updatePointerPosition(anchor, currentStep) {\n    if (typeof window === 'undefined') return;\n    try {\n      const container = this._pointerContainer || document.getElementById(pointerContainerId);\n      if (!container) return;\n\n      if (!anchor) {\n        container.style.position = 'fixed';\n        container.style.left = '50%';\n        container.style.top = '50%';\n        container.style.transform = 'translate(-50%, -50%)';\n        smoothScrollToY(window.innerHeight / 2);\n        this.removeScrollListeners();\n        this._currentAnchor = null;\n        this._currentStep = null;\n        return;\n      }\n\n      // Step 1: Scroll the element into view.\n      scrollToElement(anchor);\n\n      // Step 2: Poll until the element is fully visible (or after maximum polls).\n      const pollInterval = 100;\n      const maxPolls = 20;\n      let pollCount = 0;\n      const updateFinalPosition = () => {\n        if (isElementFullyVisible(anchor) || pollCount >= maxPolls) {\n          // Compute final target coordinates.\n          const anchorRect = anchor.getBoundingClientRect();\n          const targetX = anchorRect.left + anchorRect.width / 2;\n          const targetY = anchorRect.top + anchorRect.height / 2 + 10; // 10px downward offset.\n          container.style.position = 'fixed';\n          container.style.left = `${targetX}px`;\n          container.style.top = `${targetY}px`;\n          container.style.transform = 'translate(-50%, -50%)';\n\n          // Adjust container if too far right.\n          let containerWidthSpace = 350;\n          if (containerWidthSpace > window.innerWidth - 40) {\n            containerWidthSpace = window.innerWidth - 40;\n          }\n          if (targetX + containerWidthSpace > window.innerWidth - 20) {\n            container.classList.add('copilot-pointer-container-right');\n          } else {\n            container.classList.remove('copilot-pointer-container-right');\n          }\n\n          // Reattach scroll listeners if the target or step has changed.\n          if (this._currentAnchor !== anchor || this._currentStep !== currentStep) {\n            this.removeScrollListeners();\n            this._currentAnchor = anchor;\n            this._currentStep = currentStep;\n            this.attachScrollListeners(anchor, currentStep);\n          }\n        } else {\n          pollCount++;\n          setTimeout(updateFinalPosition, pollInterval);\n        }\n      };\n      updateFinalPosition();\n    } catch (e) {\n      // Optionally log errors.\n    }\n  }\n\n  cleanup() {\n    if (typeof window === 'undefined') return;\n    document.body.classList.add('gl-copilot-fade-out');\n    if (this.currentAudio) {\n      this.currentAudio.pause();\n    }\n    setTimeout(() => {\n      if (this._pointerContainer) {\n        this._pointerContainer.remove();\n        this._pointerContainer = null;\n      } else {\n        const container = document.getElementById(pointerContainerId);\n        if (container) container.remove();\n      }\n      const copilotInfoContainer = document.getElementById(copilotJoinedContainerId);\n      if (copilotInfoContainer) copilotInfoContainer.remove();\n      const styleNode = document.getElementById(styleId);\n      if (styleNode) styleNode.remove();\n      document.body.classList.remove('gl-copilot-fade-out');\n    }, 800);\n\n    this.productTourId = undefined;\n    this.productTourData = undefined;\n\n    this.removeScrollListeners();\n  }\n\n  toggleAudio(muted = false) {\n    this.audioMuted = muted;\n    if (this.currentAudio) {\n      this.currentAudio.muted = this.audioMuted;\n    }\n    document.querySelector(`.${copilotJoinedContainerId}-mute`).innerHTML = loadIcon(this.audioMuted ? 'unmute' : 'mute');\n  }\n\n  setupCopilotTour() {\n    if (typeof window === 'undefined') return;\n\n    const primaryColor = GleapConfigManager.getInstance().flowConfig?.color ?? '#485BFF';\n    const contrastColor = calculateContrast(primaryColor);\n\n    let styleNode = document.getElementById(styleId);\n    if (!styleNode) {\n      styleNode = document.createElement('style');\n      styleNode.id = styleId;\n      styleNode.type = 'text/css';\n      styleNode.textContent = `\n        #${pointerContainerId} {\n          position: absolute;\n          top: 0;\n          left: 0;\n          display: flex;\n          align-items: flex-start;\n          pointer-events: none;\n          z-index: 2147483610;\n          transition: all 0.5s ease;\n        }\n        .${pointerContainerId}-clickmode {\n          cursor: pointer;\n          pointer-events: all !important;\n        }\n        .${pointerContainerId}-clickmode #copilot-info-bubble-content {\n          display: flex !important;\n        }\n        .${pointerContainerId}-clickmode svg {\n          display: none !important;\n        }\n        #${pointerContainerId} svg {\n          width: 20px;\n          height: auto;\n          fill: none;\n        }\n        #copilot-info-bubble {\n          position: relative;\n        }\n        #copilot-info-bubble-content-container {\n          position: absolute;\n          top: 0px;\n          left: 0px;\n          min-width: min(300px, 80vw);\n          display: flex;\n          flex-direction: column;\n          align-items: flex-start;\n        }\n        .${pointerContainerId}-right #copilot-info-bubble-content-container {\n          left: auto !important;\n          right: 0px !important;\n          align-items: flex-end;\n        }\n        .${pointerContainerId}-right .copilot-info-bubble-content {\n          margin-right: 5px;\n        }\n        .${pointerContainerId}-right svg {\n          transform: scaleX(-1);\n        }\n        #copilot-info-bubble-content svg {\n          width: 16px;\n          height: 16px;\n          display: inline-block !important;\n          margin-left: 5px;\n        }\n        #copilot-info-bubble-content {\n          margin-top: 18px;\n          margin-left: 5px;\n          padding: 10px 15px;\n          border-radius: 20px;\n          background-color: black;\n          color: white;\n          font-family: Arial, sans-serif;\n          font-size: 14px;\n          box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);\n          max-width: 100%;\n          white-space: normal;\n          overflow-wrap: break-word;\n          word-break: normal;\n          hyphens: none;\n        }\n        .${pointerContainerId}-right #copilot-info-bubble-content {\n          margin-top: 30px;\n          margin-left: 0px;\n          margin-right: 5px;\n        }\n        .click-wave {\n          position: absolute;\n          width: 34px;\n          height: 34px;\n          border-radius: 50%;\n          background-color: rgba(0, 0, 0, 0.5);\n          pointer-events: none;\n          z-index: 2147483611;\n          animation: click-wave-animation 0.8s ease forwards;\n        }\n        @keyframes click-wave-animation {\n          0% {\n            transform: scale(0.2);\n            opacity: 1;\n          }\n          100% {\n            transform: scale(2);\n            opacity: 0;\n          }\n        }\n        @keyframes slideInFromTop {\n          0% {\n            transform: translateY(-100%);\n            opacity: 0;\n          }\n          100% {\n            transform: translateY(0);\n            opacity: 1;\n          }\n        }\n        .${copilotJoinedContainerId} {\n          position: fixed;\n          top: 20px;\n          right: 20px;\n          z-index: 2147483610;\n          background: #fff;\n          padding: 6px;\n          border-radius: 10px;\n          box-shadow: 0 0 20px 0 #C294F2;\n          display: flex;\n          align-items: center;\n          gap: 8px;\n          border: 1px solid rgba(192, 146, 242, 0.5);\n          animation: slideInFromTop 0.5s ease-out forwards;\n        }\n        .${copilotJoinedContainerId} span {\n          font-size: 13px;\n          color: #000;\n          font-family: sans-serif;\n        }\n        .${copilotJoinedContainerId}-avatar {\n          width: 24px;\n          height: 24px;\n          flex-shrink: 0;\n          border-radius: 6px;\n        }\n        .${copilotJoinedContainerId}-mute {\n          display: flex;\n          align-items: center;\n          justify-content: center;\n        }\n        .${copilotJoinedContainerId}-mute svg {\n          width: 20px;\n          height: auto;\n          cursor: pointer;\n          animation: pulsate 2s infinite;\n        }\n        .${copilotJoinedContainerId}-mute svg:hover {\n          opacity: 0.8;\n        }\n        .${copilotJoinedContainerId}-dismiss {\n          display: flex;\n          align-items: center;\n          justify-content: center;\n          padding-right: 3px;\n        }\n        .${copilotJoinedContainerId}-dismiss svg {\n          width: 15px;\n          height: auto;\n          cursor: pointer;\n        }\n        .${copilotJoinedContainerId}-dismiss svg:hover {\n          opacity: 0.8;\n        }\n        @keyframes pulsate {\n          0% {\n            transform: scale(1);\n            opacity: 1;\n          }\n          50% {\n            transform: scale(1.1);\n            opacity: 0.8;\n          }\n          100% {\n            transform: scale(1);\n            opacity: 1;\n          }\n        }\n        @keyframes glCoFadeIn {\n          0% {\n            opacity: 0;\n          }\n          100% {\n            opacity: 1;\n          }\n        }\n        @keyframes glCoFadeOut {\n          0% {\n            opacity: 1;\n          }\n          100% {\n            opacity: 0;\n          }\n        }\n\n        .gleap-audio-unmute-modal-overlay {\n          position: fixed;\n          top: 0;\n          left: 0;\n          width: 100vw;\n          height: 100vh;\n          background-color: rgba(0, 0, 0, 0.5);\n          display: flex;\n          justify-content: center;\n          align-items: center;\n          z-index: 2147483620;\n        }\n\n        .gleap-audio-unmute-modal {\n          background-color: #fff;\n          padding: 20px;\n          border-radius: 8px;\n          box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);\n          text-align: center;\n          max-width: 90%;\n          width: 400px;\n        }\n\n        .gleap-audio-unmute-modal p {\n          margin-bottom: 20px;\n          font-size: 16px;\n          line-height: 22px;\n          font-weight: normal;\n        }\n\n        .gleap-audio-unmute-button {\n          background: ${primaryColor};\n          color: ${contrastColor};\n          outline: none;\n          border: none;\n          padding: 10px 14px;\n          border-radius: 12px;\n          font-size: 14px;\n          font-weight: bold;\n          cursor: pointer;\n        }\n\n        .gleap-audio-unmute-button:hover {\n          opacity: 0.8;\n        }\n\n        .gleap-tour-continue-button {\n          color: ${primaryColor};\n          text-decoration: none;\n          cursor: pointer;\n          font-size: 14px;\n          font-weight: bold;\n          border: none;\n          background: none;\n          padding: 0;\n          margin: 0;\n          margin-left: 20px;\n        }\n\n        .gleap-tour-continue-button:hover {\n          opacity: 0.8;\n        }\n\n        body.gl-copilot-fade-out::before,\n        body.gl-copilot-fade-out::after,\n        body.gl-copilot-fade-out #${copilotJoinedContainerId} {\n          animation: glCoFadeOut 0.8s ease-out forwards;\n        }\n        ${\n          (this.productTourData?.playVoice ?? true)\n            ? ''\n            : `\n          .${copilotJoinedContainerId}-mute {\n            display: none;\n          }\n        `\n        }\n        ${\n          this.productTourData.gradient\n            ? `body::before {\n          content: \"\";\n          position: fixed;\n          top: 0;\n          left: 0;\n          width: 100vw;\n          height: 100vh;\n          pointer-events: all;\n          z-index: 2147483609;\n          box-sizing: border-box;\n          border: 18px solid transparent;\n          filter: blur(25px);\n          border-image-slice: 1;\n          border-image-source: linear-gradient(45deg, #ED5587, #FBE6A9, #a6e3f8, #C294F2);\n          animation: glCoFadeIn 1.5s ease-out forwards;\n        }\n  \n        body::after {\n          content: \"\";\n          position: fixed;\n          top: 0;\n          left: 0;\n          width: 100vw;\n          height: 100vh;\n          pointer-events: all;\n          z-index: 2147483609;\n          opacity: 0.5;\n          box-sizing: border-box;\n          border: 3px solid transparent;\n          border-image-slice: 1;\n          border-image-source: linear-gradient(45deg, #ED5587, #FBE6A9, #a6e3f8, #C294F2);\n          animation: glCoFadeIn 1.5s ease-out forwards;\n        }`\n            : `body::after {\n          content: \"\";\n          position: fixed;\n          top: 0;\n          left: 0;\n          width: 100vw;\n          height: 100vh;\n          pointer-events: all;\n          z-index: 2147483609;\n          opacity: 0;\n        }`\n        }\n      `;\n      document.head.appendChild(styleNode);\n    }\n\n    const container = document.createElement('div');\n    container.id = pointerContainerId;\n    container.style.opacity = 0;\n    // Cache the pointer container.\n    this._pointerContainer = container;\n\n    const svgMouse = document.createElementNS('http://www.w3.org/2000/svg', 'svg');\n    svgMouse.setAttribute('viewBox', '0 0 380 476');\n    svgMouse.innerHTML =\n      '<path d=\"M352.595 268.315L352.581 268.302L352.566 268.29L78.6092 24.7278C71.6245 18.433 62.5487 15 53.2 15C32.1157 15 15 32.1157 15 53.2V424C15 444.34 31.4714 461 52 461C62.6797 461 72.8089 456.467 79.8863 448.38C79.8871 448.379 79.8879 448.378 79.8886 448.378L180.804 333.1H327.9C348.384 333.1 365 316.484 365 296C365 285.404 360.46 275.344 352.595 268.315Z\" fill=\"black\" stroke=\"white\" stroke-width=\"30\"/>';\n\n    const infoBubble = document.createElement('div');\n    infoBubble.id = 'copilot-info-bubble';\n    infoBubble.innerHTML = `<div id='copilot-info-bubble-content-container'><div id='copilot-info-bubble-content'></div></div>`;\n\n    const copilotInfoContainer = document.createElement('div');\n    copilotInfoContainer.id = copilotJoinedContainerId;\n    copilotInfoContainer.classList.add(copilotJoinedContainerId);\n    copilotInfoContainer.innerHTML = `\n      <img class=\"${copilotJoinedContainerId}-avatar\" src=\"${this.productTourData?.kaiAvatar}\" />\n      <span>${this.productTourData?.kaiSlug}</span>\n      <div class=\"${copilotJoinedContainerId}-mute\">\n        ${loadIcon(this.audioMuted ? 'unmute' : 'mute')}\n      </div>\n      ${\n        this.productTourData?.allowClose\n          ? `<div class=\"${copilotJoinedContainerId}-dismiss\">\n               ${loadIcon('dismiss')}\n             </div>`\n          : ''\n      }\n    `;\n    document.body.appendChild(copilotInfoContainer);\n\n    const self = this;\n\n    document.querySelector(`.${copilotJoinedContainerId}-mute`).addEventListener('click', () => {\n      this.toggleAudio(!this.audioMuted);\n    });\n\n    if (this.productTourData?.allowClose) {\n      document.querySelector(`.${copilotJoinedContainerId}-dismiss`).addEventListener('click', () => {\n        this.completeTour(false);\n      });\n    }\n\n    container.appendChild(svgMouse);\n    container.appendChild(infoBubble);\n    document.body.appendChild(container);\n  }\n\n  start() {\n    if (typeof window === 'undefined') return;\n    if (this.disabled) return;\n\n    const config = this.productTourData;\n    if (!config) return;\n    canPlayAudio().then((supported) => {\n      this.audioMuted = !supported;\n      this.setupCopilotTour();\n\n      if (this.audioMuted && config?.showUnmuteModal) {\n        this.showAudioUnmuteModal();\n      } else {\n        setTimeout(() => {\n          this.renderNextStep();\n        }, 1500);\n      }\n    });\n  }\n\n  showAudioUnmuteModal() {\n    // Create the overlay element\n    const modalOverlay = document.createElement('div');\n    modalOverlay.classList.add('gleap-audio-unmute-modal-overlay');\n\n    // Create the modal container element\n    const modal = document.createElement('div');\n    modal.classList.add('gleap-audio-unmute-modal');\n\n    // Create and add the modal message\n    const message = document.createElement('p');\n    message.textContent = this.productTourData?.unmuteModalTitle;\n    modal.appendChild(message);\n\n    // Create the \"Unmute Audio\" button\n    const unmuteButton = document.createElement('button');\n    unmuteButton.classList.add('gleap-audio-unmute-button');\n    unmuteButton.textContent = this.productTourData?.unmuteModalButton;\n    unmuteButton.addEventListener('click', () => {\n      this.toggleAudio(false);\n      if (modalOverlay.parentNode) {\n        modalOverlay.parentNode.removeChild(modalOverlay);\n      }\n      setTimeout(() => {\n        this.renderNextStep();\n      }, 1000);\n    });\n    modal.appendChild(unmuteButton);\n\n    // Create the \"Start Anyway\" button\n    const startAnywayButton = document.createElement('button');\n    startAnywayButton.classList.add('gleap-tour-continue-button');\n    startAnywayButton.textContent = this.productTourData?.unmuteModalContinue;\n    startAnywayButton.addEventListener('click', () => {\n      if (modalOverlay.parentNode) {\n        modalOverlay.parentNode.removeChild(modalOverlay);\n      }\n      setTimeout(() => {\n        this.renderNextStep();\n      }, 1000);\n    });\n    modal.appendChild(startAnywayButton);\n\n    // Build the modal and attach it to the DOM\n    modalOverlay.appendChild(modal);\n    document.body.appendChild(modalOverlay);\n  }\n\n  completeTour(success = true) {\n    if (typeof window === 'undefined') return;\n    this.cleanup();\n    if (this.onCompleteCallback) {\n      this.onCompleteCallback(success);\n    }\n  }\n\n  renderNextStep() {\n    if (typeof window === 'undefined') return;\n    if (this.disabled) return;\n\n    const self = this;\n    const config = this.productTourData;\n    const steps = config.steps;\n    if (this.currentActiveIndex >= steps.length) {\n      setTimeout(() => {\n        this.completeTour();\n      }, 500);\n      return;\n    }\n    const currentStep = steps[this.currentActiveIndex];\n    const handleStep = (element) => {\n      this._pointerContainer.style.display = 'flex';\n      if (currentStep.selector && currentStep.selector.length > 0 && !element) {\n        this.completeTour(false);\n        return;\n      }\n      const gotToNextStep = () => {\n        if (currentStep.mode === 'INPUT' && element) {\n          function proceedClickmode() {\n            document.querySelector(`#${pointerContainerId}`).classList.remove('copilot-pointer-container-clickmode');\n            element.classList.remove('gleap-input-highlight');\n            document.getElementById(pointerContainerId).style.display = 'none';\n            self.currentActiveIndex++;\n            self.storeUncompletedTour();\n            self.renderNextStep();\n          }\n          const inputModeType = currentStep.inputType ?? 'default';\n          if (inputModeType === 'default') {\n            function handleInputEvent(e) {\n              if (e?.target?.value?.length === 0) return;\n              const cursor = document.getElementById(`copilot-info-bubble-content`);\n              if (!cursor) return;\n              cursor.innerHTML = `${GleapTranslationManager.translateText(\n                'next'\n              )} <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 448 512\">\n  <path fill=\"currentColor\" d=\"M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z\"/>\n</svg>`;\n              cursor.addEventListener('click', proceedClickmode, {\n                once: true,\n              });\n              element.classList.add('gleap-input-highlight');\n              document.querySelector(`#${pointerContainerId}`).classList.add('copilot-pointer-container-clickmode');\n              element.removeEventListener('input', handleInputEvent);\n            }\n            element.addEventListener('input', handleInputEvent, {\n              once: false,\n            });\n            if (element.hasAttribute('contenteditable')) {\n              element.addEventListener('keyup', handleInputEvent, {\n                once: false,\n              });\n            }\n            element.addEventListener(\n              'blur',\n              () => {\n                element.focus();\n              },\n              { once: true }\n            );\n            element.focus();\n          } else {\n            const inputValue = currentStep.inputValue ?? '';\n            let index = 0;\n            function typeCharacter() {\n              if (index < inputValue.length) {\n                element.value += inputValue[index];\n                index++;\n                setTimeout(typeCharacter, 100);\n              } else {\n                setTimeout(() => {\n                  proceedClickmode();\n                }, 1200);\n              }\n            }\n            typeCharacter();\n          }\n          return;\n        }\n        self.currentActiveIndex++;\n        self.storeUncompletedTour();\n        if (currentStep.mode === 'CLICK' && element) {\n          const rect = element.getBoundingClientRect();\n          const scrollX = window.scrollX || 0;\n          const scrollY = window.scrollY || 0;\n          performClickAnimation(rect.left + rect.width / 2 + scrollX, rect.top + rect.height / 2 + scrollY);\n          element.click();\n        }\n        self.renderNextStep();\n      };\n\n      this.updatePointerPosition(element, currentStep);\n      const message = currentStep?.message ? htmlToPlainText(currentStep.message) : '🤔';\n      document.getElementById(`copilot-info-bubble-content`).textContent = message;\n      this._pointerContainer.style.opacity = 1;\n      const readTime = estimateReadTime(message);\n      const continueWithNoAudio = () => {\n        this.currentAudio = undefined;\n        setTimeout(() => {\n          gotToNextStep();\n        }, readTime * 1000);\n      };\n      if (currentStep.voice && currentStep.voice.length > 0) {\n        this.currentAudio = new Audio(currentStep.voice);\n        if (this.audioMuted) {\n          this.currentAudio.muted = true;\n        }\n        this.currentAudio.addEventListener('ended', () => {\n          setTimeout(() => {\n            gotToNextStep();\n          }, 1000);\n        });\n        this.currentAudio\n          .play()\n          .then(() => {})\n          .catch((error) => {\n            continueWithNoAudio();\n          });\n      } else {\n        continueWithNoAudio();\n      }\n    };\n\n    const elementPromise = currentStep.selector ? waitForElement(currentStep.selector) : Promise.resolve(null);\n    elementPromise.then(handleStep).catch(() => handleStep(null));\n  }\n}\n","import { loadIcon } from './UI';\nimport GleapTours from './GleapTours';\nimport Gleap, { GleapEventManager, GleapSession } from './Gleap';\nimport GleapCopilotTours from './GleapCopilotTours';\n\nconst localStorageKey = 'gleap-tour-data';\n\nexport default class GleapProductTours {\n  productTourData = undefined;\n  productTourId = undefined;\n  unmuted = false;\n  currentActiveIndex = undefined;\n  gleapTourObj = undefined;\n  disabled = false;\n\n  // GleapReplayRecorder singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new GleapProductTours();\n      return this.instance;\n    } else {\n      return this.instance;\n    }\n  }\n\n  disable() {\n    if (this.gleapTourObj) {\n      this.gleapTourObj.destroy();\n    }\n\n    // Disable copilot tours.\n    GleapCopilotTours.getInstance().disable();\n\n    this.gleapTourObj = undefined;\n    this.disabled = true;\n  }\n\n  constructor() {\n    const self = this;\n\n    if (typeof window !== 'undefined') {\n      const beforeUnloadListener = (event) => {\n        if (\n          !self?.disabled &&\n          self?.productTourId &&\n          self?.productTourData &&\n          self?.productTourData?.tourType !== 'cobrowse'\n        ) {\n          self.storeUncompletedTour();\n        }\n      };\n\n      if (typeof window !== 'undefined') {\n        window.addEventListener('beforeunload', beforeUnloadListener);\n      }\n    }\n  }\n\n  startWithConfig(tourId, config, delay = 0, manually = false) {\n    // Prevent multiple tours from being started.\n    if (this.productTourId || this.disabled) {\n      return;\n    }\n\n    this.productTourId = tourId;\n    this.productTourData = config;\n    this.currentActiveIndex = 0;\n\n    if (manually) {\n      this.start();\n    } else {\n      const self = this;\n\n      // Validate product tour.\n      GleapSession.getInstance()\n        .validateProductTour(tourId)\n        .then(() => {\n          if (delay > 0) {\n            return setTimeout(() => {\n              self.start();\n            }, delay);\n          } else {\n            return this.start();\n          }\n        })\n        .catch((error) => {\n          console.log('Product tour is not live. Cleaning up...');\n          console.error(error);\n\n          self.onComplete(false);\n        });\n    }\n  }\n\n  onComplete(success = true) {\n    const comData = {\n      tourId: this.productTourId,\n    };\n\n    if (success) {\n      GleapEventManager.notifyEvent('productTourCompleted', comData);\n      Gleap.trackEvent(`tour-${this.productTourId}-completed`, comData);\n    } else {\n      GleapEventManager.notifyEvent('productTourQuit', comData);\n      Gleap.trackEvent(`tour-${this.productTourId}-quit`, comData);\n    }\n\n    // Clear data.\n    if (this.gleapTourObj) {\n      this.gleapTourObj.destroy();\n    }\n\n    this.gleapTourObj = undefined;\n    this.productTourData = undefined;\n    this.productTourId = undefined;\n    this.currentActiveIndex = undefined;\n    this.clearUncompletedTour();\n  }\n\n  loadUncompletedTour() {\n    try {\n      const data = JSON.parse(localStorage.getItem(localStorageKey));\n      if (data?.tourData && data?.tourId) {\n        return data;\n      }\n    } catch (e) {}\n\n    return null;\n  }\n\n  storeUncompletedTour() {\n    if (this.productTourId && this.productTourData) {\n      try {\n        let data = JSON.parse(\n          JSON.stringify({\n            tourData: this.productTourData,\n            tourId: this.productTourId,\n          })\n        );\n\n        data.tourData.steps = data.tourData.steps.slice(this.currentActiveIndex || 0, data.tourData.steps.length);\n\n        localStorage.setItem(localStorageKey, JSON.stringify(data));\n      } catch (e) {}\n    } else {\n      this.clearUncompletedTour();\n    }\n  }\n\n  clearUncompletedTour() {\n    try {\n      localStorage.removeItem(localStorageKey);\n    } catch (e) {}\n  }\n\n  start() {\n    const config = this.productTourData;\n    if (!config) {\n      return;\n    }\n\n    if (config.tourType === 'cobrowse') {\n      return GleapCopilotTours.getInstance().startWithConfig(this.productTourId, config, (success) => {\n        this.onComplete(success);\n      });\n    }\n\n    this.unmuted = false;\n    const steps = config.steps;\n    const self = this;\n\n    var driverSteps = [];\n\n    for (let i = 0; i < steps.length; i++) {\n      const step = steps[i];\n\n      const isClickMode = step.mode === 'CLICK';\n      const isInputMode = step.mode === 'INPUT';\n      const isInteractionMode = step.mode === 'INTERACTION';\n\n      var message = '';\n      var hasSender = false;\n\n      if (step.type === 'video-pointer') {\n        message = `<div class=\"gleap-tour-video\">\n              <video class=\"gleap-tour-video-obj\" muted autoplay>\n                <source src=\"${step.videoUrl}\" type=\"video/mp4\">\n              </video>\n              <div class=\"gleap-tour-video-playpause\">${loadIcon('unmute')}</div>\n            </div>`;\n      } else {\n        var senderHTML = ``;\n\n        if (config.sender && config.sender.firstName) {\n          hasSender = true;\n          senderHTML = `<div class=\"gleap-tour-sender\">\n                <div class=\"gleap-tour-sender-image\" style=\"background-image: url('${config.sender.profileImageUrl}');\"></div>\n                <div class=\"gleap-tour-sender-name\">${config.sender.firstName}</div>\n              </div>`;\n        }\n\n        message = `${senderHTML}<div class=\"gleap-tour-message\">${step.message}</div>`;\n      }\n\n      const disableInteraction = !isClickMode && !isInputMode && !isInteractionMode;\n\n      var driverStep = {\n        disableActiveInteraction: disableInteraction,\n        mode: step.mode,\n        popover: {\n          description: message,\n          popoverClass: `gleap-tour-popover-${step.type} ${\n            !hasSender && 'gleap-tour-popover-no-sender'\n          } ${config.allowClose && 'gleap-tour-popover-can-close'}`,\n          ...(isClickMode\n            ? {\n                showButtons: [],\n              }\n            : {}),\n        },\n      };\n      if (step.selector && step.selector.length > 0) {\n        driverStep.element = step.selector;\n      }\n      driverSteps.push(driverStep);\n    }\n\n    var buttons = ['next', 'close'];\n\n    if (config.backButton) {\n      buttons.push('previous');\n    }\n\n    function onDocumentClick(evnt) {\n      try {\n        var gleapTourPopover = document.querySelector('.gleap-tour-popover');\n        if (gleapTourPopover && !gleapTourPopover.contains(evnt.target)) {\n          const stepIndex = self.gleapTourObj.getActiveIndex();\n          const step = steps[stepIndex];\n          const element = self.gleapTourObj.getActiveElement();\n\n          if (step?.mode === 'CLICK' && evnt?.target !== element) {\n            const isInsideElement = element.contains(evnt?.target);\n            if (!isInsideElement) {\n              // Ignore clicks outside of the actual element.\n              return;\n            }\n          }\n\n          // Store next step index.\n          self.currentActiveIndex = (self.currentActiveIndex || 0) + 1;\n          self.storeUncompletedTour();\n\n          if (\n            (element && element.tagName === 'INPUT') ||\n            step.mode === 'INPUT' ||\n            step.mode === 'INTERACTION' ||\n            evnt?.target?.id.includes('tooltip-svg')\n          ) {\n            // Prevent.\n          } else {\n            self.gleapTourObj.moveNext();\n          }\n        }\n      } catch (e) {}\n    }\n\n    this.gleapTourObj = GleapTours({\n      showProgress: true,\n      allowKeyboardControl: false,\n      steps: driverSteps,\n      showProgress: steps.length > 1,\n      allowClose: config.allowClose,\n      nextBtnText: config.nextText,\n      doneBtnText: config.doneText,\n      prevBtnText: config.prevText,\n      showButtons: buttons,\n      onHighlightStarted: (element, step, config) => {\n        this.currentActiveIndex = config?.state?.activeIndex;\n        this.storeUncompletedTour();\n      },\n      onElementNotFound: (step) => {\n        document.removeEventListener('click', onDocumentClick);\n\n        this.onComplete(false);\n      },\n      onDestroyStarted: () => {\n        if (!this.gleapTourObj.hasNextStep()) {\n          // Mark as completed.\n          this.onComplete(true);\n        } else {\n          // Mark as quit.\n          this.onComplete(false);\n        }\n\n        document.removeEventListener('click', onDocumentClick);\n      },\n      onPopoverRender: (popoverElement) => {\n        // Fix for images and videos.\n        if (popoverElement) {\n          const mediaElements = document.querySelectorAll(\n            '.gleap-tour-popover-description img, .gleap-tour-popover-description video'\n          );\n\n          const performRequentialRefresh = () => {\n            setTimeout(() => {\n              this.gleapTourObj.refresh();\n            }, 500);\n            setTimeout(() => {\n              this.gleapTourObj.refresh();\n            }, 750);\n          };\n\n          for (let i = 0; i < mediaElements.length; i++) {\n            const mediaElement = mediaElements[i];\n            if (mediaElement.tagName === 'IMG') {\n              mediaElement.addEventListener('load', () => {\n                performRequentialRefresh();\n              });\n              mediaElement.addEventListener('error', () => {\n                performRequentialRefresh();\n              });\n            } else if (mediaElement.tagName === 'VIDEO') {\n              mediaElement.addEventListener('canplaythrough', () => {\n                performRequentialRefresh();\n              });\n              mediaElement.addEventListener('error', () => {\n                performRequentialRefresh();\n              });\n            }\n          }\n        }\n\n        const playingClass = 'gleap-tour-video--playing';\n        const playPauseContainer = document.querySelector('.gleap-tour-video-playpause');\n\n        const videoElement = document.querySelector('.gleap-tour-video-obj');\n        if (videoElement) {\n          const videoContainer = videoElement.closest('.gleap-tour-video');\n\n          if (self.unmuted) {\n            if (videoElement) {\n              videoElement.pause();\n              videoElement.muted = false;\n              videoElement.play();\n              videoContainer.classList.add(playingClass);\n            }\n          }\n\n          videoElement.addEventListener('ended', function () {\n            playPauseContainer.innerHTML = loadIcon('replay');\n            playPauseContainer.classList.add('gleap-tour-video-svg--fullscreen');\n            videoContainer.classList.remove(playingClass);\n          });\n\n          videoElement.addEventListener('play', function () {\n            playPauseContainer.classList.remove('gleap-tour-video-svg--fullscreen');\n          });\n\n          if (playPauseContainer) {\n            playPauseContainer.addEventListener('click', () => clickVideo());\n          }\n\n          const clickVideo = () => {\n            if (videoElement.muted) {\n              self.unmuted = true;\n\n              videoElement.pause();\n              videoElement.currentTime = 0;\n              videoElement.muted = false;\n              videoElement.play();\n\n              playPauseContainer.innerHTML = loadIcon('mute');\n              videoContainer.classList.add(playingClass);\n            } else if (videoElement.paused) {\n              videoElement.muted = false;\n              videoElement.play();\n\n              playPauseContainer.innerHTML = loadIcon('mute');\n              videoContainer.classList.add(playingClass);\n            } else {\n              videoElement.pause();\n              playPauseContainer.innerHTML = loadIcon('unmute');\n              videoContainer.classList.remove(playingClass);\n            }\n          };\n        }\n      },\n    });\n    this.gleapTourObj.drive();\n\n    document.addEventListener('click', onDocumentClick, true);\n  }\n}\n","import AgentNetworkManager from './AgentNetworkManager';\n\n/**\n * Headless agent chat manager with streaming support.\n *\n * Framework-agnostic state manager for AI agent conversations.\n * Uses SSE streaming for real-time token-by-token responses.\n *\n * @example\n * const chat = Gleap.createAgentChat({\n *   agentId: 'abc123',\n *   onChange: ({ messages, isExecuting }) => { ... },\n * });\n * chat.sendMessage('Hello!');\n */\nclass GleapAgentChat {\n  constructor(options = {}) {\n    this._agentId = options.agentId || 'kai';\n    this._context = options.context || null;\n    this._onChange = options.onChange || null;\n    this._onError = options.onError || null;\n    this._onReplyReceived = options.onReplyReceived || null;\n    this._onConversationCreated = options.onConversationCreated || null;\n    this._onToken = options.onToken || null;\n\n    this._messages = [];\n    this._conversationId = options.conversationId || null;\n    this._isExecuting = false;\n    this._error = null;\n    this._destroyed = false;\n    this._abortController = null;\n\n    try {\n      this._networkManager = AgentNetworkManager.getInstance();\n    } catch (e) {\n      this._networkManager = null;\n    }\n  }\n\n  // --- Public API ---\n\n  /**\n   * Send a message to the agent (streaming).\n   * @param {string} content\n   * @returns {Promise<void>}\n   */\n  async sendMessage(content) {\n    const trimmed = (content || '').trim();\n    if (!trimmed || this._isExecuting || this._destroyed) return;\n\n    // Add user message optimistically\n    this._messages = [...this._messages, {\n      id: `user-${Date.now()}`,\n      role: 'user',\n      content: trimmed,\n      createdAt: new Date().toISOString(),\n    }];\n\n    // Add empty streaming assistant message\n    const streamingId = `stream-${Date.now()}`;\n    this._messages = [...this._messages, {\n      id: streamingId,\n      role: 'assistant',\n      content: '',\n      createdAt: new Date().toISOString(),\n      isStreaming: true,\n    }];\n\n    this._isExecuting = true;\n    this._error = null;\n    this._notify();\n\n    // For Kai mode, send full message history since there's no server-side conversation persistence\n    const isKai = this._agentId === 'kai';\n    const messages = isKai\n      ? this._messages\n          .filter((m) => !m.isStreaming && m.content)\n          .map((m) => ({ role: m.role, content: m.content }))\n      : [{ role: 'user', content: trimmed }];\n\n    const body = { messages };\n    if (this._conversationId) body.conversationId = this._conversationId;\n    if (this._context) body.additionalContext = this._context;\n\n    this._abortController = new AbortController();\n    const isNewConversation = !this._conversationId;\n    // Track by index — stable even when id changes\n    const streamingIdx = this._messages.length - 1;\n\n    await this._networkManager.streamAgent(this._agentId, body, {\n      onMeta: (data) => {\n        if (this._destroyed) return;\n        if (data.conversationId) {\n          this._conversationId = data.conversationId;\n          this._networkManager._invalidateMessagesCache(data.conversationId);\n          if (isNewConversation && this._onConversationCreated) {\n            this._onConversationCreated(data.conversationId);\n          }\n        }\n        if (data.runId && this._messages[streamingIdx]) {\n          this._messages[streamingIdx] = { ...this._messages[streamingIdx], id: data.runId };\n        }\n      },\n\n      onToken: (data) => {\n        if (this._destroyed) return;\n        const msg = this._messages[streamingIdx];\n        if (msg) {\n          msg.content += data.content || '';\n        }\n        this._notify();\n        if (this._onToken) this._onToken(data);\n      },\n\n      onDone: (data) => {\n        if (this._destroyed) return;\n        const msg = this._messages[streamingIdx];\n        if (msg) {\n          msg.isStreaming = false;\n          if (data.response && !msg.content) msg.content = data.response;\n        }\n        this._isExecuting = false;\n        this._abortController = null;\n        this._notify();\n        if (this._onReplyReceived) this._onReplyReceived(data);\n      },\n\n      onError: (data) => {\n        if (this._destroyed) return;\n        const msg = this._messages[streamingIdx];\n        if (msg && !msg.content) {\n          this._messages.splice(streamingIdx, 1);\n        } else if (msg) {\n          msg.isStreaming = false;\n        }\n        this._isExecuting = false;\n        this._error = data;\n        this._abortController = null;\n        this._notify();\n        if (this._onError) this._onError(data);\n      },\n\n      onToolStart: () => {},\n      onToolEnd: () => {},\n    }, this._abortController.signal);\n  }\n\n  /** Cancel the current streaming request. */\n  cancelStream() {\n    if (this._abortController) {\n      this._abortController.abort();\n      this._abortController = null;\n    }\n    // Finalize any streaming message\n    this._messages = this._messages.map((m) => m.isStreaming ? { ...m, isStreaming: false } : m);\n    // Remove empty streaming messages\n    this._messages = this._messages.filter((m) => m.content || m.role === 'user');\n    this._isExecuting = false;\n    this._notify();\n  }\n\n  clearMessages() {\n    this._messages = [];\n    this._conversationId = null;\n    this._isExecuting = false;\n    this._error = null;\n    this.cancelStream();\n    AgentNetworkManager.getInstance().clearCache();\n    this._notify();\n  }\n\n  setContext(context) { this._context = context; }\n\n  getState() {\n    return {\n      messages: this._messages,\n      isExecuting: this._isExecuting,\n      error: this._error,\n      conversationId: this._conversationId,\n    };\n  }\n\n  destroy() {\n    this.cancelStream();\n    this._destroyed = true;\n    this._onChange = null;\n    this._onError = null;\n    this._onReplyReceived = null;\n    this._onConversationCreated = null;\n    this._onToken = null;\n  }\n\n  // --- Private ---\n\n  _notify() {\n    if (this._onChange && !this._destroyed) {\n      this._onChange(this.getState());\n    }\n  }\n}\n\nexport default GleapAgentChat;\n","import { injectStyledCSS } from './UI';\nimport GleapNetworkIntercepter from './GleapNetworkIntercepter';\nimport { fixGleapHeight, gleapDataParser, runFunctionWhenDomIsReady } from './GleapHelper';\nimport GleapSession from './GleapSession';\nimport GleapStreamedEvent from './GleapStreamedEvent';\nimport GleapConfigManager from './GleapConfigManager';\nimport GleapFeedback from './GleapFeedback';\nimport GleapFrameManager from './GleapFrameManager';\nimport GleapMetaDataManager from './GleapMetaDataManager';\nimport GleapConsoleLogManager from './GleapConsoleLogManager';\nimport GleapClickListener from './GleapClickListener';\nimport GleapFeedbackButtonManager from './GleapFeedbackButtonManager';\nimport GleapCustomDataManager from './GleapCustomDataManager';\nimport GleapEventManager from './GleapEventManager';\nimport GleapCustomActionManager from './GleapCustomActionManager';\nimport GleapReplayRecorder from './GleapReplayRecorder';\nimport GleapMarkerManager from './GleapMarkerManager';\nimport GleapTranslationManager from './GleapTranslationManager';\nimport GleapShortcutListener from './GleapShortcutListener';\nimport GleapPreFillManager from './GleapPreFillManager';\nimport GleapNotificationManager from './GleapNotificationManager';\nimport GleapAiChatbarManager from './GleapAiChatbarManager';\nimport GleapAgentToolManager from './GleapAgentToolManager';\nimport GleapBannerManager from './GleapBannerManager';\nimport GleapModalManager from './GleapModalManager';\nimport GleapAudioManager from './GleapAudioManager';\nimport GleapTagManager from './GleapTagManager';\nimport GleapAdminManager from './GleapAdminManager';\nimport GleapProductTours from './GleapProductTours';\nimport { checkPageFilter, checkPageRules } from './GleapPageFilter';\nimport { registerGleapChecklist } from './GleapChecklist';\nimport ChecklistNetworkManager from './ChecklistNetworkManager';\nimport { registerGleapAgentComponents } from './GleapAgentConversation';\nimport AgentNetworkManager from './AgentNetworkManager';\nimport GleapAgentChat from './GleapAgentChat';\nimport { parseSSEStream, dispatchSSEEvent } from './GleapSSEParser';\n\nif (\n  typeof window !== 'undefined' &&\n  typeof HTMLCanvasElement !== 'undefined' &&\n  HTMLCanvasElement.prototype &&\n  HTMLCanvasElement.prototype.__originalGetContext === undefined\n) {\n  HTMLCanvasElement.prototype.__originalGetContext = HTMLCanvasElement.prototype.getContext;\n  HTMLCanvasElement.prototype.getContext = function (type, options) {\n    return this.__originalGetContext(type, {\n      ...options,\n      preserveDrawingBuffer: true,\n    });\n  };\n}\n\nif (typeof customElements !== 'undefined' && typeof HTMLElement !== 'undefined' && typeof window !== 'undefined') {\n  registerGleapChecklist();\n  registerGleapAgentComponents();\n}\n\nclass Gleap {\n  static invoked = true;\n  static silentCrashReportSent = false;\n  initialized = false;\n  offlineMode = false;\n  disablePageTracking = false;\n  disableInAppNotifications = false;\n  disableQueryParams = false;\n\n  // Global data\n  globalData = {\n    screenRecordingData: null,\n    webReplay: null,\n    snapshotPosition: {\n      x: 0,\n      y: 0,\n    },\n  };\n\n  // Gleap singleton\n  static instance;\n  static getInstance() {\n    if (!this.instance) {\n      this.instance = new Gleap();\n      return this.instance;\n    } else {\n      return this.instance;\n    }\n  }\n\n  /**\n   * Main constructor\n   */\n  constructor() {\n    if (typeof window !== 'undefined') {\n      // Make sure all instances are ready.\n      GleapMetaDataManager.getInstance();\n      GleapConsoleLogManager.getInstance().start();\n      GleapClickListener.getInstance().start();\n      GleapAdminManager.getInstance().start();\n    }\n  }\n\n  /**\n   * Sets the development environment\n   * @param {*} environment\n   */\n  static setEnvironment(environment) {\n    GleapMetaDataManager.getInstance().environment = environment;\n  }\n\n  /**\n   * Set tags to be submitted with each ticket.\n   * @param {*} tags\n   */\n  static setTags(tags) {\n    GleapTagManager.getInstance().setTags(tags);\n  }\n\n  /**\n   * Sets a custom URL handler.\n   * @param {*} urlHandler\n   */\n  static setUrlHandler(urlHandler) {\n    GleapFrameManager.getInstance().setUrlHandler(urlHandler);\n  }\n\n  /**\n   * Active the Gleap offline mode.\n   * @param {*} offlineMode\n   */\n  static setOfflineMode(offlineMode) {\n    const instance = this.getInstance();\n    instance.offlineMode = offlineMode;\n  }\n\n  /**\n   * Disable the in-app notifications.\n   * @param {*} disableInAppNotifications\n   */\n  static setDisableInAppNotifications(disableInAppNotifications) {\n    const instance = this.getInstance();\n    instance.disableInAppNotifications = disableInAppNotifications;\n  }\n\n  /**\n   * Disable the default page tracking.\n   * @param {*} disablePageTracking\n   */\n  static setDisablePageTracking(disablePageTracking) {\n    const instance = this.getInstance();\n    instance.disablePageTracking = disablePageTracking;\n  }\n\n  /**\n   * Revert console log overwrite.\n   */\n  static disableConsoleLogOverwrite() {\n    GleapConsoleLogManager.getInstance().stop();\n  }\n\n  /**\n   * Set frontend-side tools that AI agents (including Kai) can call.\n   * @param {Array} tools - Tool definitions with name, description, response, parameters.\n   */\n  static setAiTools(tools) {\n    GleapAgentToolManager.getInstance().setAgentTools(tools);\n    GleapAiChatbarManager.getInstance().sendAgentToolsUpdate();\n    GleapFrameManager.getInstance().sendConfigUpdate();\n  }\n\n  /**\n   * Attaches external network logs.\n   */\n  static attachNetworkLogs(networkLogs) {\n    GleapNetworkIntercepter.getInstance().externalRequests = gleapDataParser(networkLogs);\n  }\n\n  /**\n   * Add entry to logs.\n   * @param {*} message\n   * @param {*} logLevel\n   * @returns\n   */\n  static log(message, logLevel = 'INFO') {\n    GleapConsoleLogManager.getInstance().addLog(message, logLevel);\n  }\n\n  /**\n   * Initializes the SDK\n   * @param {*} sdkKey\n   */\n  static initialize(sdkKey) {\n    const instance = this.getInstance();\n    if (instance.initialized) {\n      console.warn('Gleap already initialized.');\n      return;\n    }\n\n    instance.initialized = true;\n\n    try {\n      fixGleapHeight();\n    } catch (error) {}\n\n    // Start session\n    const sessionInstance = GleapSession.getInstance();\n    sessionInstance.sdkKey = sdkKey;\n    sessionInstance.setOnSessionReady(() => {\n      // Run auto configuration.\n      setTimeout(() => {\n        GleapConfigManager.getInstance()\n          .start()\n          .then(() => {\n            GleapStreamedEvent.getInstance().start();\n\n            runFunctionWhenDomIsReady(() => {\n              // Inject the widget buttons\n              GleapFeedbackButtonManager.getInstance().injectFeedbackButton();\n\n              // Inject the notification container\n              GleapNotificationManager.getInstance().injectNotificationUI();\n\n              // Check for uncompleted tour.\n              Gleap.checkForUncompletedTour();\n\n              // Check for URL params.\n              Gleap.checkForUrlParams();\n\n              // Notify event.\n              GleapEventManager.notifyEvent('initialized');\n            });\n          })\n          .catch(function (err) {\n            console.warn('Failed to initialize Gleap.');\n          });\n      }, 0);\n    });\n    sessionInstance.startSession();\n  }\n\n  static openURL(url, newTab = false) {\n    GleapFrameManager.getInstance().urlHandler(url, newTab);\n  }\n\n  static disableQueryParams(disableQueryParams = true) {\n    this.getInstance().disableQueryParams = disableQueryParams;\n  }\n\n  static checkForUrlParams() {\n    if (this.getInstance().disableQueryParams) {\n      console.log('Query params are disabled.');\n      return;\n    }\n\n    if (typeof window === 'undefined' || !window.location.search) {\n      return;\n    }\n\n    try {\n      const urlParams = new URLSearchParams(window.location.search);\n\n      const widget = urlParams.get('gleap_widget');\n      if (widget && widget.length > 0) {\n        Gleap.open();\n      }\n\n      const conversationFlow = urlParams.get('gleap_conversation');\n      if (conversationFlow && conversationFlow.length > 0) {\n        if (conversationFlow === 'true') {\n          Gleap.startConversation(true);\n        } else {\n          Gleap.startBot(conversationFlow, true);\n        }\n      }\n\n      const feedbackFlow = urlParams.get('gleap_feedback');\n      if (feedbackFlow && feedbackFlow.length > 0) {\n        Gleap.startFeedbackFlow(feedbackFlow);\n      }\n      const surveyFlow = urlParams.get('gleap_survey');\n      const surveyFlowFormat = urlParams.get('gleap_survey_format');\n      if (surveyFlow && surveyFlow.length > 0) {\n        Gleap.showSurvey(surveyFlow, surveyFlowFormat === 'survey_full' ? 'survey_full' : 'survey');\n      }\n      const tourId = urlParams.get('gleap_tour');\n      if (tourId && tourId.length > 0) {\n        var tourDelay = parseInt(urlParams.get('gleap_tour_delay'));\n        if (isNaN(tourDelay)) {\n          tourDelay = 2;\n        }\n\n        setTimeout(() => {\n          Gleap.startProductTour(tourId);\n        }, tourDelay * 1000);\n      }\n    } catch (exp) {}\n  }\n\n  /**\n   * Destroy\n   * @returns\n   */\n  static destroy() {\n    GleapReplayRecorder.getInstance().stop();\n    GleapStreamedEvent.getInstance().stop();\n    GleapFrameManager.getInstance().destroy();\n    GleapFeedbackButtonManager.getInstance().destroy();\n    GleapNotificationManager.getInstance().clearAllNotifications(true);\n    GleapAiChatbarManager.getInstance().destroy();\n    GleapSession.getInstance().clearSession(0, false);\n    GleapBannerManager.getInstance().removeBannerUI();\n\n    // Reset the initialized flag and clear the instance\n    this.instance = null;\n  }\n\n  /**\n   * Close any open banner.\n   */\n  static closeBanner() {\n    GleapBannerManager.getInstance().removeBannerUI();\n  }\n\n  /**\n   * Close any open modal.\n   */\n  static closeModal() {\n    GleapModalManager.getInstance().hideModal();\n  }\n\n  /**\n   * Show the AI bar.\n   */\n  static showAiChatbar() {\n    const instance = GleapAiChatbarManager.getInstance();\n    instance.manuallyHidden = false;\n    instance.manuallyShown = true;\n    instance.show();\n  }\n\n  /**\n   * Hide the AI search.\n   */\n  static hideAiChatbar() {\n    const instance = GleapAiChatbarManager.getInstance();\n    instance.manuallyHidden = true;\n    instance.manuallyShown = false;\n    instance.hide();\n  }\n\n  /**\n   * Set the AI quick actions.\n   * @param {Array<string>} quickActions\n   */\n  static setAiChatbarQuickActions(quickActions) {\n    GleapAiChatbarManager.getInstance().setQuickActions(quickActions);\n  }\n\n  /**\n   * Set the AI chatbar placeholder.\n   * @param {string} placeholder\n   */\n  static setAiChatbarPlaceholder(placeholder) {\n    GleapAiChatbarManager.getInstance().setPlaceholder(placeholder);\n  }\n\n  /**\n   * Enable or disable Gleap session tracking through cookies.\n   * @param {*} useCookies\n   */\n  static setUseCookies(useCookies) {\n    GleapSession.getInstance().useCookies = useCookies;\n  }\n\n  static disableLocalStorage() {\n    GleapSession.getInstance().localStorageDisabled = true;\n  }\n\n  /**\n   * Indentifies the user session\n   * @param {string} userId\n   * @param {*} userData\n   */\n  static identify(userId, userData, userHash) {\n    return GleapSession.getInstance().identifySession(userId, gleapDataParser(userData), userHash);\n  }\n\n  /**\n   * Updates the contact data.\n   * @param {*} userData\n   */\n  static updateContact(userData) {\n    return GleapSession.getInstance().updateSession(gleapDataParser(userData));\n  }\n\n  /**\n   * Clears the current contact.\n   */\n  static clearIdentity() {\n    GleapSession.getInstance().clearSession();\n  }\n\n  /**\n   * Returns the current user session\n   */\n  static getIdentity() {\n    return GleapSession.getInstance().getSession();\n  }\n\n  /**\n   * Returns whether the user is identified or not.\n   */\n  static isUserIdentified() {\n    const session = GleapSession.getInstance().session;\n    if (session && session.userId && session.userId.length > 0) {\n      return true;\n    }\n    return false;\n  }\n\n  /**\n   * Widget opened status\n   * @returns {boolean} isOpened\n   */\n  static isOpened() {\n    return GleapFrameManager.getInstance().isOpened();\n  }\n\n  /**\n   * Hides any open Gleap dialogs.\n   */\n  static hide() {\n    GleapFrameManager.getInstance().hideWidget();\n  }\n\n  /**\n   * Sets the maximum network request count.\n   */\n  static setMaxNetworkRequests(maxRequests) {\n    GleapNetworkIntercepter.getInstance().setMaxRequests(maxRequests);\n  }\n\n  /**\n   * Sets the maximum network request count.\n   */\n  static startNetworkLogger() {\n    GleapNetworkIntercepter.getInstance().start();\n  }\n\n  /**\n   * Sets the network logger blacklist.\n   * @param {Array} networkLogBlacklist\n   */\n  static setNetworkLogsBlacklist(networkLogBlacklist) {\n    GleapNetworkIntercepter.getInstance().setBlacklist(networkLogBlacklist);\n  }\n\n  /**\n   * Sets the network logger props to ignore.\n   * @param {Array} filters\n   */\n  static setNetworkLogPropsToIgnore(filters) {\n    GleapNetworkIntercepter.getInstance().setFilters(filters);\n  }\n\n  /**\n   * Set custom replay options.\n   * @param {*} options\n   */\n  static setReplayOptions(options) {\n    GleapReplayRecorder.getInstance().setOptions(options);\n  }\n\n  /**\n   * Closes any open Gleap dialogs.\n   * @param {boolean} resetRoutes\n   */\n  static close(resetRoutes = false) {\n    GleapFrameManager.getInstance().hideWidget(resetRoutes);\n  }\n\n  /**\n   * Starts the Gleap flow.\n   */\n  static open() {\n    GleapFrameManager.getInstance().setAppMode('widget');\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Track a custom event\n   * @param {string} name\n   * @param {any} data\n   */\n  static trackEvent(name, data) {\n    GleapStreamedEvent.getInstance().logEvent(name, data);\n  }\n\n  /**\n   * Logs a custom event\n   * @param {string} name\n   * @param {any} data\n   * @deprecated Please use trackEvent instead.\n   */\n  static logEvent(name, data) {\n    GleapStreamedEvent.getInstance().logEvent(name, data);\n  }\n\n  /**\n   * Prefills a specific form field.\n   * @param {*} key\n   * @param {*} value\n   */\n  static preFillForm(data) {\n    const cleanedData = gleapDataParser(data);\n    GleapPreFillManager.getInstance().formPreFill = cleanedData;\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'prefill-form-data',\n        data: cleanedData,\n      },\n      true\n    );\n  }\n\n  /**\n   * Register events for Gleap.\n   * @param {*} eventName\n   * @param {*} callback\n   */\n  static on(eventName, callback) {\n    GleapEventManager.on(eventName, callback);\n  }\n\n  /**\n   * Enable or disable shortcuts\n   * @param {boolean} enabled\n   */\n  static enableShortcuts(enabled) {\n    if (enabled) {\n      GleapShortcutListener.getInstance().start();\n    } else {\n      GleapShortcutListener.getInstance().stop();\n    }\n  }\n\n  /**\n   * Show or hide the feedback button\n   * @param {*} show\n   * @returns\n   */\n  static showFeedbackButton(show) {\n    GleapFeedbackButtonManager.getInstance().toggleFeedbackButton(show);\n  }\n\n  /**\n   * Sets the app version code.\n   * @param {string} appVersionCode\n   */\n  static setAppVersionCode(appVersionCode) {\n    GleapMetaDataManager.setAppVersionCode(appVersionCode);\n  }\n\n  /**\n   * Sets the app version code.\n   * @param {string} appVersionCode\n   */\n  static setAppBuildNumber(appBuildNumber) {\n    GleapMetaDataManager.setAppBuildNumber(appBuildNumber);\n  }\n\n  /**\n   * Set a custom ws api url.\n   * @param {string} wsApiUrl\n   */\n  static setWSApiUrl(wsApiUrl) {\n    GleapSession.getInstance().wsApiUrl = wsApiUrl;\n  }\n\n  /**\n   * Set a custom api url.\n   * @param {string} apiUrl\n   */\n  static setApiUrl(apiUrl) {\n    GleapSession.getInstance().apiUrl = apiUrl;\n  }\n\n  /**\n   * Set a custom banner url.\n   * @param {string} bannerUrl\n   */\n  static setBannerUrl(bannerUrl) {\n    GleapBannerManager.getInstance().setBannerUrl(bannerUrl);\n  }\n\n  /**\n   * Set a custom modal url.\n   * @param {string} modalUrl\n   */\n  static setModalUrl(modalUrl) {\n    GleapModalManager.getInstance().setModalUrl(modalUrl);\n  }\n\n  /**\n   * Set a custom frame api url.\n   * @param {string} frameUrl\n   */\n  static setFrameUrl(frameUrl) {\n    GleapFrameManager.getInstance().frameUrl = frameUrl;\n  }\n\n  /**\n   * This method is used to set ticket attributes programmatically.\n   * @param {*} key The key of the attribute you want to add.\n   * @param {*} value The value to set.\n   */\n  static setTicketAttribute(key, value) {\n    GleapCustomDataManager.getInstance().setTicketAttribute(key, value);\n  }\n\n  /**\n   * This method is used to unset ticket attributes programmatically.\n   * @param {*} key The key of the attribute you want to unset.\n   */\n  static unsetTicketAttribute(key) {\n    GleapCustomDataManager.getInstance().unsetTicketAttribute(key);\n  }\n\n  /**\n   * This method is used to clear ticket attributes programmatically.\n   */\n  static clearTicketAttributes() {\n    GleapCustomDataManager.getInstance().clearTicketAttributes();\n  }\n\n  /**\n   * Set custom data that will be attached to the bug-report.\n   * @param {*} data\n   */\n  static attachCustomData(data) {\n    GleapCustomDataManager.getInstance().attachCustomData(data);\n  }\n\n  /**\n   * Add one key value pair to the custom data object\n   * @param {*} key The key of the custom data entry you want to add.\n   * @param {*} value The custom data you want to add.\n   */\n  static setCustomData(key, value) {\n    GleapCustomDataManager.getInstance().setCustomData(key, value);\n  }\n\n  /**\n   * Remove one key value pair of the custom data object\n   * @param {*} key The key of the custom data entry you want to remove.\n   */\n  static removeCustomData(key) {\n    GleapCustomDataManager.getInstance().removeCustomData(key);\n  }\n\n  /**\n   * Clear the custom data\n   */\n  static clearCustomData() {\n    GleapCustomDataManager.getInstance().clearCustomData();\n  }\n\n  /**\n   * Play or mute the sound.\n   * @param {*} play\n   */\n  static playSound(play) {\n    GleapAudioManager.playSound(play);\n  }\n\n  /**\n   * Show or hide the notification badge count.\n   * @param {boolean} showNotificationBadge show or hide the notification badge\n   *\n   */\n  static showTabNotificationBadge(showNotificationBadge) {\n    const notificationInstance = GleapNotificationManager.getInstance();\n    notificationInstance.showNotificationBadge = showNotificationBadge;\n    notificationInstance.updateTabBarNotificationCount();\n  }\n\n  /**\n   * Override the browser language.\n   * @param {string} language country code with two letters\n   */\n  static setLanguage(language) {\n    GleapTranslationManager.getInstance().setOverrideLanguage(language);\n\n    if (Gleap.getInstance().initialized) {\n      setTimeout(() => {\n        Gleap.getInstance().softReInitialize();\n\n        // Update language for contact.\n        Gleap.updateContact({\n          lang: language,\n        });\n      }, 1000);\n    }\n  }\n\n  /**\n   * Register a callback for agent tool executions.\n   * @param {function} callback - Called with { name, params, result, message, toolCallId } when any tool finishes.\n   */\n  static registerAgentToolAction(callback) {\n    GleapAgentToolManager.getInstance().registerAgentToolAction(callback);\n  }\n\n  /**\n   * Register custom action\n   * @param {*} action\n   */\n  static registerCustomAction(customAction) {\n    GleapCustomActionManager.registerCustomAction(customAction);\n  }\n\n  /**\n   * Triggers a custom action\n   * @param {*} actionName\n   */\n  static triggerCustomAction(name) {\n    GleapCustomActionManager.triggerCustomAction(name);\n  }\n\n  /**\n   * Sets a custom color scheme.\n   * @param {string} primaryColor\n   */\n  static setStyles(\n    primaryColor,\n    headerColor,\n    buttonColor,\n    backgroundColor = '#ffffff',\n    borderRadius = 20,\n    buttonX = 20,\n    buttonY = 20,\n    buttonStyle = GleapFeedbackButtonManager.FEEDBACK_BUTTON_BOTTOM_LEFT\n  ) {\n    runFunctionWhenDomIsReady(() => {\n      injectStyledCSS(primaryColor, headerColor, buttonColor, borderRadius, backgroundColor, buttonX, buttonY, buttonStyle);\n    });\n  }\n\n  /**\n   * Sends a silent feedback report\n   * @param {*} formData\n   * @param {*} priority\n   * @param {*} excludeData\n   */\n  static sendSilentCrashReport(\n    description = '',\n    priority = 'MEDIUM',\n    excludeData = {\n      screenshot: true,\n      replays: true,\n      attachments: true,\n    }\n  ) {\n    return Gleap.sendSilentCrashReportWithFormData(\n      {\n        description,\n      },\n      priority,\n      excludeData\n    );\n  }\n\n  /**\n   * Sends a silent feedback report\n   * @param {*} formData\n   * @param {*} priority\n   * @param {*} excludeData\n   */\n  static sendSilentCrashReportWithFormData(\n    formData,\n    priority = 'MEDIUM',\n    excludeData = {\n      screenshot: true,\n      replays: true,\n      attachments: true,\n    }\n  ) {\n    if (this.silentCrashReportSent) {\n      return;\n    }\n\n    this.silentCrashReportSent = true;\n    setTimeout(() => {\n      this.silentCrashReportSent = false;\n    }, 10000);\n\n    const excludeDataCleaned = excludeData ? gleapDataParser(excludeData) : {};\n    const sessionInstance = GleapSession.getInstance();\n    if (!sessionInstance.ready) {\n      return;\n    }\n\n    var newFormData = formData ? formData : {};\n    if (sessionInstance.session.email) {\n      newFormData.reportedBy = sessionInstance.session.email;\n    }\n\n    const feedback = new GleapFeedback('CRASH', priority, newFormData, true, excludeDataCleaned);\n    feedback\n      .sendFeedback()\n      .then(() => {})\n      .catch((error) => {});\n  }\n\n  /**\n   * Shows a survey manually.\n   * @param {*} actionType\n   * @param {*} format\n   */\n  static showSurvey(actionType, format = 'survey') {\n    Gleap.startFeedbackFlowWithOptions(\n      actionType,\n      {\n        hideBackButton: true,\n        format,\n      },\n      true\n    );\n  }\n\n  /**\n   * Starts a classic feedback form.\n   */\n  static startClassicForm(formId, showBackButton) {\n    Gleap.startFeedbackFlowWithOptions(formId, {\n      hideBackButton: !showBackButton,\n    });\n  }\n\n  /**\n   * Starts the bug reporting flow.\n   */\n  static startFeedbackFlow(feedbackFlow, showBackButton) {\n    Gleap.startFeedbackFlowWithOptions(feedbackFlow, {\n      hideBackButton: !showBackButton,\n    });\n  }\n\n  /**\n   * Starts the bug reporting flow.\n   */\n  static startFeedbackFlowWithOptions(feedbackFlow, options = {}, isSurvey = false) {\n    const { autostartDrawing, hideBackButton, format } = options;\n    const sessionInstance = GleapSession.getInstance();\n    if (!sessionInstance.ready) {\n      return;\n    }\n\n    // Initially set scroll position\n    Gleap.getInstance().setGlobalDataItem('snapshotPosition', {\n      x: window.scrollX,\n      y: window.scrollY,\n    });\n\n    var action = 'start-feedbackflow';\n    if (isSurvey) {\n      action = 'start-survey';\n    }\n\n    GleapFrameManager.getInstance().setAppMode(isSurvey ? format : 'widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: action,\n        data: {\n          flow: feedbackFlow,\n          hideBackButton: hideBackButton,\n          format,\n        },\n      },\n      true\n    );\n\n    if (autostartDrawing) {\n      GleapFrameManager.getInstance().showDrawingScreen('screenshot');\n    } else {\n      GleapFrameManager.getInstance().showWidget();\n    }\n  }\n\n  /**\n   * Opens the conversations overview.\n   */\n  static openConversations(showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-conversations',\n        data: {\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Opens a conversation\n   */\n  static openConversation(shareToken, showBackButton = true) {\n    if (!shareToken) {\n      return;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-conversation',\n        data: {\n          shareToken,\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Starts a new conversation\n   */\n  static startConversation(showBackButton = true) {\n    Gleap.startBot('', showBackButton);\n  }\n\n  /**\n   * Starts a new conversation and attaches the bot with the given id.\n   */\n  static startBot(botId, showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'start-bot',\n        data: {\n          botId: botId ? botId : '',\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Starts a new conversation and attaches the bot with the given id.\n   */\n  static askAI(question, showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'ask-ai',\n        data: {\n          question,\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Send a message to an agent programmatically.\n   * @param {string} agentId\n   * @param {string} message\n   * @param {{ conversationId?: string, additionalContext?: object }} [options={}]\n   * @returns {Promise<{ runId: string, status: string, response: string, conversationId?: string }>}\n   */\n  static sendAgentMessage(agentId, message, options = {}) {\n    if (!agentId || !message) {\n      return Promise.reject(new Error('agentId and message are required.'));\n    }\n\n    const body = {\n      messages: [{ role: 'user', content: message.trim() }],\n    };\n    if (options.conversationId) body.conversationId = options.conversationId;\n    if (options.additionalContext) body.additionalContext = options.additionalContext;\n\n    // Stream under the hood, collect and return full response\n    return new Promise((resolve, reject) => {\n      let fullResponse = '';\n      let conversationId = options.conversationId || null;\n      let runId = null;\n\n      AgentNetworkManager.getInstance().streamAgent(agentId, body, {\n        onMeta: (data) => {\n          if (data.conversationId) conversationId = data.conversationId;\n          if (data.runId) runId = data.runId;\n        },\n        onToken: (data) => {\n          fullResponse += data.content || '';\n          if (options.onToken) options.onToken(data);\n        },\n        onDone: (data) => {\n          resolve({\n            runId: runId || data?.runId,\n            status: data?.status || 'completed',\n            response: fullResponse || data?.response || '',\n            conversationId,\n          });\n        },\n        onError: (data) => { reject(data); },\n        onToolStart: () => {},\n        onToolEnd: () => {},\n      });\n    });\n  }\n\n  /**\n   * Clear agent conversation state from the cache.\n   */\n  static clearAgentConversation() {\n    AgentNetworkManager.getInstance().clearCache();\n  }\n\n  /**\n   * Create a headless agent chat instance.\n   * Framework-agnostic state manager for AI agent conversations.\n   * @param {object} options\n   * @returns {GleapAgentChat}\n   */\n  static createAgentChat(options) {\n    return new GleapAgentChat(options);\n  }\n\n  /**\n   * Opens a help center collection\n   */\n  static openHelpCenterCollection(collectionId, showBackButton = true) {\n    if (!collectionId) {\n      return;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-help-collection',\n        data: {\n          collectionId,\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Opens a help article\n   */\n  static openHelpCenterArticle(articleId, showBackButton = true) {\n    if (!articleId) {\n      return;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-help-article',\n        data: {\n          articleId,\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Opens the help center.\n   */\n  static openHelpCenter(showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-helpcenter',\n        data: {\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Search for news articles in the help center\n   */\n  static searchHelpCenter(term, showBackButton = true) {\n    if (!term) {\n      return;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-helpcenter-search',\n        data: {\n          term,\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Opens a news article\n   */\n  static openNewsArticle(id, showBackButton = true) {\n    if (!id) {\n      return;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-news-article',\n        data: {\n          id,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Open the checklists overview.\n   */\n  static openChecklists(showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-checklists',\n        data: {},\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Starts a new checklist and opens it.\n   */\n  static startChecklist(outboundId, showBackButton = true, sharedKey = undefined) {\n    if (!outboundId) {\n      return false;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'start-checklist',\n        data: {\n          outboundId: outboundId,\n          hideBackButton: !showBackButton,\n          ...(sharedKey ? { sharedKey: sharedKey } : {}),\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n\n    return true;\n  }\n\n  /**\n   * Open an existing checklist.\n   */\n  static openChecklist(checklistId, showBackButton = true) {\n    if (!checklistId) {\n      return;\n    }\n\n    GleapFrameManager.getInstance().setAppMode('widget');\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-checklist',\n        data: {\n          id: checklistId,\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Gets the full checklist data by validating the outbound ID and fetching the data.\n   * @param {string} outboundId - The outbound checklist ID to get data for.\n   * @param {string} [sharedKey] - Optional shared key for the checklist.\n   * @returns {Promise<object>} A promise that resolves with the full checklist data.\n   *\n   * Available events for checklist updates (use Gleap.on() to listen):\n   * - 'checklist-loaded': Fired when a checklist is initially loaded\n   * - 'checklist-update': Fired when checklist data is updated\n   * - 'checklist-step-completed': Fired when a step is marked as completed\n   * - 'checklist-completed': Fired when the entire checklist is completed\n   */\n  static getChecklistData(outboundId, sharedKey) {\n    if (!outboundId) {\n      return Promise.reject(new Error('outboundId is required'));\n    }\n\n    const networkManager = ChecklistNetworkManager.getInstance();\n\n    // First validate the checklist to get the internal ID\n    return networkManager.validateChecklist(outboundId, sharedKey).then((internalId) => {\n      // Then fetch the full checklist data\n      return networkManager.fetchChecklist(internalId);\n    });\n  }\n\n  /**\n   * Opens the news overview.\n   */\n  static openNews(showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-news',\n        data: {\n          hideBackButton: !showBackButton,\n        },\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  /**\n   * Opens the feature requests overview.\n   */\n  static openFeatureRequests(showBackButton = true) {\n    GleapFrameManager.getInstance().setAppMode('widget');\n\n    GleapFrameManager.getInstance().sendMessage(\n      {\n        name: 'open-feature-requests',\n        data: {},\n      },\n      true\n    );\n\n    GleapFrameManager.getInstance().showWidget();\n  }\n\n  isLiveMode() {\n    if (this.offlineMode === true) {\n      return false;\n    }\n\n    var hostname = window.location.hostname;\n    const isLocalHost =\n      ['localhost', '127.0.0.1', '0.0.0.0', '', '::1'].includes(hostname) ||\n      hostname.startsWith('192.168.') ||\n      hostname.startsWith('10.0.') ||\n      hostname.endsWith('.local') ||\n      !hostname.includes('.');\n    return !isLocalHost;\n  }\n\n  softReInitialize() {\n    GleapFrameManager.getInstance().destroy();\n    GleapConfigManager.getInstance()\n      .start()\n      .then(() => {\n        // Update the feedback button.\n        GleapFeedbackButtonManager.getInstance().refresh();\n\n        // Inject the notification container\n        GleapNotificationManager.getInstance().injectNotificationUI();\n      })\n      .catch(function (err) {\n        console.warn('Failed to initialize Gleap.');\n      });\n  }\n\n  /**\n   * Performs an action.\n   * @param {*} action\n   */\n  performActions(actions) {\n    for (let i = 0; i < actions.length; i++) {\n      const action = actions[i];\n      if (action && action.actionType) {\n        if ((action.pageRules?.length > 0 || action.pageFilter) && window && window.location) {\n          const passed = checkPageRules(window.location.href, action);\n\n          if (!passed) {\n            continue;\n          }\n        }\n\n        if (action.actionType === 'notification') {\n          if (action?.data?.checklist?.popupType === 'widget') {\n            Gleap.openChecklist(action.data.checklist.id, true);\n          } else {\n            if (!this.disableInAppNotifications) {\n              Gleap.showNotification(action);\n            }\n          }\n        } else if (action.actionType === 'banner') {\n          Gleap.showBanner(action);\n        } else if (action.actionType === 'modal') {\n          Gleap.showModal(action);\n        } else if (action.actionType === 'tour') {\n          Gleap.startProductTourWithConfig(action.outbound, action.data, false);\n        } else {\n          Gleap.showSurvey(action.actionType, action.format);\n        }\n      }\n    }\n  }\n\n  static startProductTour(tourId, checkStartUrl = false) {\n    const self = this;\n    GleapSession.getInstance()\n      .startProductTourConfig(tourId)\n      .then((config) => {\n        if (checkStartUrl && config?.startURL && !window?.location?.href?.includes(config?.baseURL)) {\n          window.location.href = `${config.startURL}?gleap_tour=${tourId}&gleap_tour_delay=1`;\n          return;\n        }\n\n        self.startProductTourWithConfig(tourId, config, true);\n      })\n      .catch((error) => {});\n  }\n\n  static checkForUncompletedTour() {\n    const tourData = GleapProductTours.getInstance().loadUncompletedTour();\n    if (tourData) {\n      GleapProductTours.getInstance().startWithConfig(tourData.tourId, tourData.tourData, 500);\n    }\n  }\n\n  static startProductTourWithConfig(tourId, config, manually = false) {\n    GleapProductTours.getInstance().startWithConfig(tourId, config, 0, manually);\n  }\n\n  static showBanner(data) {\n    try {\n      GleapBannerManager.getInstance().showBanner(data);\n    } catch (e) {}\n  }\n\n  static showModal(data) {\n    try {\n      GleapModalManager.getInstance().showModal(data);\n    } catch (e) {}\n  }\n\n  /**\n   * Start an agent conversation in the inline chatbar.\n   * @param {string} agentId - The agent ID to converse with.\n   * @param {object} [options] - Optional config: { context?, primaryColor?, initialMessage? }\n   *   Also accepts a plain context object for backward compatibility.\n   */\n  static startAgent(agentId, options) {\n    try {\n      GleapAiChatbarManager.getInstance().showWithAgent(agentId, options);\n    } catch (e) {}\n  }\n\n  /**\n   * Set the AI agent for the chatbar without opening the conversation panel.\n   * The chatbar input bar will be shown, but the panel stays closed until the user interacts.\n   * @param {string} agentId - The agent ID to use. Pass empty/null/'default' for Kai.\n   * @param {object} [options] - Optional config: { context?, primaryColor? }\n   */\n  static setAIAgent(agentId, options) {\n    try {\n      GleapAiChatbarManager.getInstance().setAgent(agentId, options);\n    } catch (e) {}\n  }\n\n  static showNotification(data) {\n    GleapNotificationManager.getInstance().showNotification(data);\n  }\n\n  /**\n   * Sets a global data value\n   * @param {*} key\n   * @param {*} value\n   */\n  setGlobalDataItem(key, value) {\n    this.globalData[key] = value;\n  }\n\n  /**\n   * Gets a global data value\n   * @param {*} key\n   * @returns\n   */\n  getGlobalDataItem(key) {\n    return this.globalData[key];\n  }\n\n  /**\n   * Takes the current replay and assigns it to the global data array.\n   */\n  takeCurrentReplay() {\n    const replayData = GleapReplayRecorder.getInstance().getReplayData();\n    this.setGlobalDataItem('webReplay', replayData);\n  }\n}\n\n// Check for unperformed Gleap actions.\nif (typeof window !== 'undefined') {\n  const GleapActions = window.GleapActions;\n  if (GleapActions && GleapActions.length > 0) {\n    for (var i = 0; i < GleapActions.length; i++) {\n      const GLAction = GleapActions[i];\n      if (GLAction && GLAction.e && Gleap[GLAction.e]) {\n        Gleap[GLAction.e].apply(Gleap, GLAction.a);\n      }\n    }\n  }\n}\n\nconst handleGleapLink = (href) => {\n  try {\n    const urlParts = href.split('/');\n    const type = urlParts[2];\n    if (type === 'article') {\n      const identifier = urlParts[3];\n      Gleap.openHelpCenterArticle(identifier, true);\n    }\n\n    if (type === 'collection') {\n      const identifier = urlParts[3];\n      Gleap.openHelpCenterCollection(identifier, true);\n    }\n\n    if (type === 'flow') {\n      const identifier = urlParts[3];\n      Gleap.startFeedbackFlow(identifier, true);\n    }\n\n    if (type === 'survey') {\n      const identifier = urlParts[3];\n      Gleap.showSurvey(identifier);\n    }\n\n    if (type === 'bot') {\n      const identifier = urlParts[3];\n      Gleap.startBot(identifier, true);\n    }\n\n    if (type === 'news') {\n      const identifier = urlParts[3];\n      Gleap.openNewsArticle(identifier, true);\n    }\n\n    if (type === 'checklist') {\n      const identifier = urlParts[3];\n      Gleap.startChecklist(identifier, true, urlParts[4]);\n    }\n\n    if (type === 'tour') {\n      const identifier = urlParts[3];\n      Gleap.startProductTour(identifier);\n    }\n  } catch (e) {\n    console.error('Failed to handle Gleap link: ', href);\n  }\n};\n\nexport {\n  GleapNetworkIntercepter,\n  GleapAudioManager,\n  GleapNotificationManager,\n  GleapAiChatbarManager,\n  GleapBannerManager,\n  GleapModalManager,\n  GleapPreFillManager,\n  GleapShortcutListener,\n  GleapMarkerManager,\n  GleapTranslationManager,\n  GleapReplayRecorder,\n  GleapFeedback,\n  GleapConsoleLogManager,\n  GleapCustomActionManager,\n  GleapEventManager,\n  GleapCustomDataManager,\n  GleapFeedbackButtonManager,\n  GleapClickListener,\n  GleapSession,\n  GleapStreamedEvent,\n  GleapConfigManager,\n  GleapFrameManager,\n  GleapMetaDataManager,\n  GleapTagManager,\n  GleapProductTours,\n  GleapAdminManager,\n  GleapAgentToolManager,\n  AgentNetworkManager,\n  GleapAgentChat,\n  parseSSEStream,\n  dispatchSSEEvent,\n  handleGleapLink,\n};\n\nexport default Gleap;\n","/**\n * Gleap Checklist Web Component\n *\n * Displays an interactive checklist fetched from the Gleap API.\n * Allows users to view steps, mark them as done, trigger actions,\n * and automatically updates based on external events. Includes localization support\n * via GleapTranslationManager.\n *\n * Waits for a Gleap session to be available before initializing and\n * reloads when the session changes (via 'session-updated' event).\n *\n * @element gleap-checklist\n *\n * @attr {string} checklistId - The outbound ID of the checklist to display. Required.\n * @attr {boolean} [info=true] - Whether to display the info section (title, description, sender).\n * @attr {boolean} [progressbar=true] - Whether to display the progress bar.\n * @attr {boolean} [dark=false] - Apply dark mode styling.\n * @attr {boolean} [floating=false] - When set to \"true\", shows a small bubble that expands on click.\n *\n * @cssprop --color-bg - Background color.\n * @cssprop --color-font-title - Title text color.\n * @cssprop --color-font-text - Body text color.\n * @cssprop --color-font-light - Lighter text color.\n * @cssprop --color-primary - Primary accent color.\n * @cssprop --color-primary-light - Light primary color shade.\n * @cssprop --color-primary-contrast - Text color for primary buttons.\n * @cssprop --color-border - Border color.\n * @cssprop --color-gray-light - Light gray background/border color.\n * @cssprop --color-gray-lighter - Even lighter gray background.\n * @cssprop --color-gray-dark - Darker gray text/icon color.\n * @cssprop --color-success - Success color (e.g., for completed items).\n * @cssprop --color-success-light - Contrast color for success elements.\n * @cssprop --radius-sm - Small border radius.\n * @cssprop --radius-lg - Large border radius.\n * @cssprop --radius-full - Full (pill) border radius.\n * @cssprop --shadow-sm - Small box shadow.\n * @cssprop --shadow-md - Medium box shadow.\n * @cssprop --animation-duration - Duration for animations (e.g., accordion).\n * @cssprop --animation-timing - Timing function for animations.\n */\nimport ChecklistNetworkManager from './ChecklistNetworkManager';\nimport Gleap, { GleapConfigManager, GleapSession, GleapTranslationManager, GleapEventManager } from './Gleap';\n\nexport const registerGleapChecklist = () => {\n  if (typeof customElements !== 'undefined' && typeof HTMLElement !== 'undefined' && typeof window !== 'undefined') {\n    class GleapChecklist extends HTMLElement {\n      /** @private {number} */\n      activeStep = -1;\n      /** @private {object|null} */\n      checklistData = null;\n      /** @private {boolean} */\n      _isInitialLoad = false;\n      /** @private {boolean} */\n      _initialActiveSet = false;\n      /** @private {boolean} Flag indicating if the component has loaded data at least once. */\n      _hasLoaded = false;\n      /** @private {boolean} Flag indicating if a Gleap session is currently considered active by the component. */\n      _isSessionReady = false;\n\n      /** @private {Function} */\n      _boundHandleChecklistUpdate = this.handleChecklistUpdate.bind(this);\n      /** @private {Function} */\n      _boundHandleSessionUpdate = this.handleSessionUpdate.bind(this);\n\n      constructor() {\n        super();\n        this.attachShadow({ mode: 'open' });\n        // Ensure NetworkManager instance is created only if Gleap is available\n        try {\n          if (typeof GleapSession !== 'undefined' && typeof ChecklistNetworkManager !== 'undefined') {\n            this._networkManager = ChecklistNetworkManager.getInstance();\n          } else {\n            this._networkManager = null;\n          }\n        } catch (e) {\n          this._networkManager = null;\n        }\n        // Bind click handlers for floating mode.\n        this._boundFloatingLauncherClick = this.handleFloatingLauncherClick.bind(this);\n        this._boundFloatingCloseClick = this.handleFloatingCloseClick.bind(this);\n        this._floatingHideTimeout = null;\n      }\n\n      // --- Observed Attributes ---\n      static get observedAttributes() {\n        return ['checklistId', 'info', 'progressbar', 'dark', 'floating', 'sharedKey'];\n      }\n\n      // --- Lifecycle Callbacks ---\n      connectedCallback() {\n        window.addEventListener('checkListUpdate', this._boundHandleChecklistUpdate);\n        window.addEventListener('session-updated', this._boundHandleSessionUpdate);\n        window.addEventListener('resize', (this._boundResizeHandler = this.handleResize.bind(this)));\n        this._checkSessionAndLoad();\n      }\n\n      disconnectedCallback() {\n        window.removeEventListener('checkListUpdate', this._boundHandleChecklistUpdate);\n        window.removeEventListener('session-updated', this._boundHandleSessionUpdate);\n        window.removeEventListener('resize', this._boundResizeHandler);\n        this.removeFloatingClickListeners();\n        if (this._floatingHideTimeout) {\n          clearTimeout(this._floatingHideTimeout);\n          this._floatingHideTimeout = null;\n        }\n        this.checklistData = null;\n        this.activeStep = -1;\n        this._hasLoaded = false;\n        this._isSessionReady = false;\n        this._initialActiveSet = false;\n        this.renderResponse();\n      }\n\n      handleResize() {\n        this.updateActiveTaskMaxHeight();\n      }\n\n      attributeChangedCallback(name, oldValue, newValue) {\n        if (oldValue !== newValue) {\n          if (name === 'checklistId' && this._isSessionReady) {\n            this.loadChecklist();\n          } else if (name !== 'checklistId' && this._hasLoaded) {\n            if (this.checklistData) {\n              this.renderChecklist(this.checklistData);\n            }\n          }\n        }\n      }\n\n      // --- Session Handling ---\n      _checkSessionAndLoad() {\n        const gleapSessionInstance = this._getGleapSessionInstance();\n        const hasChecklistId = this.getAttribute('checklistId');\n\n        if (gleapSessionInstance.ready && hasChecklistId) {\n          this._isSessionReady = true;\n          this._networkManager = ChecklistNetworkManager.getInstance();\n          this.loadChecklist();\n        } else {\n          this._isSessionReady = false;\n          this._hasLoaded = false;\n          this.checklistData = null;\n          this.activeStep = -1;\n          this._initialActiveSet = false;\n          this.renderResponse();\n        }\n      }\n\n      handleSessionUpdate() {\n        this._checkSessionAndLoad();\n      }\n\n      _getGleapSessionInstance() {\n        try {\n          return typeof GleapSession !== 'undefined' ? GleapSession.getInstance() : null;\n        } catch (e) {\n          return null;\n        }\n      }\n\n      // --- Getters for Configuration ---\n      get infoEnabled() {\n        const attr = this.getAttribute('info');\n        return attr === null || attr.toLowerCase() !== 'false';\n      }\n\n      get progressbarEnabled() {\n        const attr = this.getAttribute('progressbar');\n        return attr === null || attr.toLowerCase() !== 'false';\n      }\n\n      get floatingEnabled() {\n        return this.getAttribute('floating') === 'true';\n      }\n\n      // --- Translation Helpers ---\n      _translate(key, defaultValue = '') {\n        return GleapTranslationManager.translateText(key) || defaultValue;\n      }\n\n      _translateWithVars(key, vars, defaultValue = '') {\n        return GleapTranslationManager.translateTextWithVars(key, vars) || defaultValue;\n      }\n\n      // --- SVG Icons ---\n      getCheckIcon() {\n        return `<svg width=\"1em\" height=\"1em\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" style=\"display: block;\">\n                    <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M20.7071 5.29289C21.0976 5.68342 21.0976 6.31658 20.7071 6.70711L9.70711 17.7071C9.31658 18.0976 8.68342 18.0976 8.29289 17.7071L3.29289 12.7071C2.90237 12.3166 2.90237 11.6834 3.29289 11.2929C3.68342 10.9024 4.31658 10.9024 4.70711 11.2929L9 15.5858L19.2929 5.29289C19.6834 4.90237 20.3166 4.90237 20.7071 5.29289Z\" fill=\"currentColor\"/>\n                  </svg>`;\n      }\n\n      // --- Data Loading and Handling ---\n      loadChecklist() {\n        if (!this._isSessionReady || !this._networkManager) {\n          return;\n        }\n        const checklistId = this.getAttribute('checklistId');\n        if (checklistId) {\n          this.activeStep = -1;\n          this._initialActiveSet = false;\n          this.validateChecklist(checklistId);\n        } else {\n          this.renderResponse();\n          this.checklistData = null;\n          this._hasLoaded = false;\n        }\n      }\n\n      getQueryParams() {\n        const gleapSessionInstance = this._getGleapSessionInstance();\n        if (!gleapSessionInstance?.session) {\n          return '';\n        }\n        const session = gleapSessionInstance.session;\n        let lang = 'en';\n        try {\n          if (typeof GleapTranslationManager !== 'undefined') {\n            lang = GleapTranslationManager.getInstance().getActiveLanguage() || 'en';\n          }\n        } catch (e) {}\n        return `gleapId=${session.gleapId || ''}&gleapHash=${session.gleapHash || ''}&lang=${lang}`;\n      }\n\n      makeRequest(method, url, data, callback) {\n        const gleapSessionInstance = this._getGleapSessionInstance();\n        if (!gleapSessionInstance?.session) {\n          const mockXhr = {\n            readyState: 4,\n            status: 0,\n            responseText: 'Session unavailable',\n            _isMock: true,\n          };\n          callback(mockXhr);\n          return;\n        }\n        const xhr = new XMLHttpRequest();\n        xhr.open(method, url);\n        try {\n          gleapSessionInstance.injectSession(xhr);\n        } catch (e) {}\n        if (data) {\n          xhr.setRequestHeader('Content-Type', 'application/json;charset=UTF-8');\n        }\n        xhr.onreadystatechange = () => {\n          if (xhr.readyState === 4) {\n            callback(xhr);\n          }\n        };\n        xhr.onerror = () => {\n          callback(xhr);\n        };\n        xhr.send(data ? JSON.stringify(data) : null);\n      }\n\n      validateChecklist(outboundId) {\n        if (!this._isSessionReady || !this._networkManager) {\n          return;\n        }\n        this.checklistData = null;\n        this._hasLoaded = false;\n        this.renderResponse();\n        const sharedKey = this.getAttribute('sharedKey');\n\n        this._networkManager\n          .validateChecklist(outboundId, sharedKey)\n          .then((internalId) => {\n            if (!this.isConnected || !this._isSessionReady || !internalId) {\n              return;\n            }\n            this.fetchChecklist(internalId);\n          })\n          .catch((error) => {\n            this.renderResponse();\n            this.checklistData = null;\n            this._hasLoaded = false;\n          });\n      }\n\n      fetchChecklist(checklistId) {\n        if (!this._isSessionReady || !this._networkManager) {\n          return;\n        }\n        this._isInitialLoad = !this._hasLoaded;\n        this._networkManager\n          .fetchChecklist(checklistId)\n          .then((data) => {\n            if (!this.isConnected || !this._isSessionReady || !data) {\n              this._hasLoaded = false;\n              this.checklistData = null;\n              this._checkSessionAndLoad();\n              return;\n            }\n            this.checklistData = data;\n            this._hasLoaded = true;\n            if (data.status === 'done') {\n              this.renderResponse();\n              return;\n            }\n            if (this._isInitialLoad && !this._initialActiveSet) {\n              const steps = data.outbound?.config?.steps || [];\n              const completedSteps = data.completedSteps || [];\n              const firstIncompleteIndex = steps.findIndex((step) => !completedSteps.includes(step.id));\n              this.activeStep = firstIncompleteIndex >= 0 ? firstIncompleteIndex : -1;\n              if (this.activeStep !== -1) {\n                this._initialActiveSet = true;\n              }\n            }\n            this.renderChecklist(this.checklistData);\n\n            // Notify external listeners about the initial checklist load\n            GleapEventManager.notifyEvent('checklist-loaded', {\n              checklistId: this.checklistData.id,\n              outboundId: this.checklistData.outbound?.id,\n              completedSteps: this.checklistData.completedSteps,\n              status: this.checklistData.status,\n              data: this.checklistData,\n            });\n          })\n          .catch((error) => {\n            this.renderResponse();\n            this.checklistData = null;\n            this._hasLoaded = false;\n          });\n      }\n\n      updateChecklist(id, data) {\n        const gleapSessionInstance = this._getGleapSessionInstance();\n        if (!gleapSessionInstance?.session) {\n          return;\n        }\n        const apiUrl = gleapSessionInstance.apiUrl;\n        if (!apiUrl) {\n          return;\n        }\n        const session = gleapSessionInstance.session;\n        const gleapId = session?.gleapId ?? '';\n        const gleapHash = session?.gleapHash ?? '';\n        let lang = 'en';\n        try {\n          if (typeof GleapTranslationManager !== 'undefined') {\n            lang = GleapTranslationManager.getInstance().getActiveLanguage() || 'en';\n          }\n        } catch (e) {}\n        let url = `${apiUrl}/outbound/checklists/${id}`;\n        if (data.checkedStep) {\n          url += `/increment/${data.checkedStep}`;\n        }\n        url += `?gleapId=${gleapId}&gleapHash=${gleapHash}&lang=${lang}`;\n        this.makeRequest('PUT', url, data, (xhr) => {\n          if (xhr._isMock) return;\n          if (!(xhr.status === 200 || xhr.status === 204)) {\n            // Update failed\n          }\n        });\n      }\n\n      // --- External Update Handling ---\n      handleChecklistUpdate(event) {\n        if (!this._hasLoaded || !this.checklistData) {\n          return;\n        }\n        const updateData = event.detail;\n        if (!updateData || updateData.id !== this.checklistData.id) {\n          return;\n        }\n        const previousCompletedSteps = [...(this.checklistData.completedSteps || [])];\n        let dataChanged = false;\n        let activeStepCompleted = false;\n        const currentlyActiveStepIndex = this.activeStep;\n        if (\n          updateData.completedSteps &&\n          JSON.stringify(updateData.completedSteps) !== JSON.stringify(previousCompletedSteps)\n        ) {\n          this.checklistData.completedSteps = [...updateData.completedSteps];\n          dataChanged = true;\n          if (currentlyActiveStepIndex !== -1) {\n            const activeStepId = this.checklistData.outbound?.config?.steps?.[currentlyActiveStepIndex]?.id;\n            if (\n              activeStepId &&\n              this.checklistData.completedSteps.includes(activeStepId) &&\n              !previousCompletedSteps.includes(activeStepId)\n            ) {\n              activeStepCompleted = true;\n            }\n          }\n        }\n        if (updateData.status && updateData.status !== this.checklistData.status) {\n          this.checklistData.status = updateData.status;\n          dataChanged = true;\n        }\n        if (activeStepCompleted) {\n          const steps = this.checklistData.outbound?.config?.steps || [];\n          let nextActiveStep = -1;\n          for (let i = currentlyActiveStepIndex + 1; i < steps.length; i++) {\n            if (!this.checklistData.completedSteps.includes(steps[i].id)) {\n              nextActiveStep = i;\n              break;\n            }\n          }\n          if (this.activeStep !== nextActiveStep) {\n            this.setActiveStep(nextActiveStep);\n          }\n          dataChanged = true;\n        }\n        if (dataChanged) {\n          this.renderChecklist(this.checklistData);\n\n          // Notify external listeners about the checklist update\n          GleapEventManager.notifyEvent('checklist-update', {\n            checklistId: this.checklistData.id,\n            outboundId: this.checklistData.outbound?.id,\n            completedSteps: this.checklistData.completedSteps,\n            status: this.checklistData.status,\n            data: this.checklistData,\n          });\n        }\n      }\n\n      // --- Floating (Click-based) Listeners ---\n      handleFloatingLauncherClick(event) {\n        event.stopPropagation();\n\n        if (this.checklistData.status === 'done') {\n          return;\n        }\n\n        const tasks = this.shadowRoot.querySelector('.checklist-tasks');\n        if (tasks) {\n          tasks.style.display = tasks.style.display === 'block' ? 'none' : 'block';\n        }\n      }\n\n      handleFloatingCloseClick(event) {\n        event.stopPropagation();\n        const tasks = this.shadowRoot.querySelector('.checklist-tasks');\n        if (tasks) {\n          tasks.style.display = 'none';\n        }\n      }\n\n      addFloatingClickListeners() {\n        const launcher = this.shadowRoot.querySelector('.checklist-floating-launcher');\n        if (launcher) {\n          launcher.addEventListener('click', this._boundFloatingLauncherClick);\n        }\n        const header = this.shadowRoot.querySelector('.checklist-floating-header');\n        if (header) {\n          header.addEventListener('click', this._boundFloatingCloseClick);\n        }\n      }\n\n      removeFloatingClickListeners() {\n        const launcher = this.shadowRoot.querySelector('.checklist-floating-launcher');\n        if (launcher) {\n          launcher.removeEventListener('click', this._boundFloatingLauncherClick);\n        }\n        const header = this.shadowRoot.querySelector('.checklist-floating-header');\n        if (header) {\n          header.removeEventListener('click', this._boundFloatingCloseClick);\n        }\n      }\n\n      // --- Rendering Logic ---\n      renderResponse() {\n        this.shadowRoot.innerHTML = '';\n      }\n\n      /**\n       * Renders the floating launcher. When called with the default class (\"checklist-floating\")\n       * it shows a chevron icon; when called with \"checklist-floating-header\" it shows a close icon.\n       */\n      renderFloatingLauncher(outbound, className = 'checklist-floating', renderDoneState = false) {\n        const steps = outbound.config?.steps || [];\n        const completedSteps = this.checklistData?.completedSteps || [];\n        let progress = 0;\n        if (this.progressbarEnabled && steps.length > 0) {\n          const totalSteps = steps.length;\n          const doneSteps = completedSteps.length;\n          progress = totalSteps > 0 ? (doneSteps / totalSteps) * 100 : 0;\n        }\n\n        // Determine the next incomplete step\n        const nextIncompleteStep = steps.find((step) => !completedSteps.includes(step.id));\n        let titleText =\n          steps.length > 0\n            ? nextIncompleteStep\n              ? nextIncompleteStep.title ||\n                this._translateWithVars(\n                  'stepDefaultTitle',\n                  { index: steps.indexOf(nextIncompleteStep) + 1 },\n                  `Step ${steps.indexOf(nextIncompleteStep) + 1}`\n                )\n              : ''\n            : outbound.subject || '';\n\n        let subtitleText =\n          steps.length > 0 ? (nextIncompleteStep ? nextIncompleteStep.description || '' : '') : outbound.message || '';\n\n        if (renderDoneState) {\n          titleText = outbound.config?.successTitle || '';\n          subtitleText = outbound.config?.successMessage || '';\n          progress = 100;\n        }\n\n        const circumference = 2 * Math.PI * 7;\n        const computedOffset = circumference - (progress / 100) * circumference;\n\n        const isHeader = className === 'checklist-floating-header';\n        const icon = isHeader\n          ? `<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n               <line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\"></line>\n               <line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\"></line>\n             </svg>`\n          : `<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n               <polyline points=\"6 9 12 15 18 9\"></polyline>\n             </svg>`;\n\n        return `\n          <div part=\"${className}\" class=\"${\n            isHeader ? 'checklist-floating-header' : 'checklist-floating-launcher'\n          } ${renderDoneState ? 'checklist-floating-launcher--done' : ''}\">\n            <div class=\"floating-header\">\n              <div class=\"floating-circular-progress\">\n                <svg viewBox=\"0 0 20 20\">\n                  <circle class=\"track\" cx=\"10\" cy=\"10\" r=\"7\"></circle>\n                  <circle class=\"progress\" cx=\"10\" cy=\"10\" r=\"7\" stroke-dasharray=\"${circumference.toFixed(\n                    2\n                  )}\" stroke-dashoffset=\"${computedOffset.toFixed(2)}\"></circle>\n                </svg>\n              </div>\n              <div class=\"floating-title\">${titleText}</div>\n              ${renderDoneState ? '' : `<span class=\"floating-icon\">${icon}</span>`}\n            </div>\n            <div class=\"floating-subtitle\">${subtitleText}</div>\n          </div>\n        `;\n      }\n\n      renderInfoSection(outbound) {\n        if (!this.infoEnabled || !outbound) return '';\n        const subject = outbound.subject || this._translate('checklistDefaultTitle', 'Checklist');\n        const message = outbound.message || '';\n        let senderHtml = '';\n        if (outbound.sender?.profileImageUrl) {\n          senderHtml = `\n            <div part=\"sender\" class=\"checklists-sender\">\n              <img part=\"sender-image\" src=\"${outbound.sender.profileImageUrl}\" alt=\"${\n                outbound.sender.firstName || 'Sender'\n              }'s profile picture\" style=\"object-fit: cover;\" />\n              <span part=\"sender-name\">${outbound.sender.firstName || ''}</span>\n            </div>`;\n        }\n        return `\n          <div part=\"info\" class=\"checklists-info\">\n            ${subject ? `<div part=\"info-title\" class=\"checklists-title\">${subject}</div>` : ''}\n            ${message ? `<div part=\"info-description\" class=\"checklists-description\">${message}</div>` : ''}\n            ${senderHtml}\n          </div>`;\n      }\n\n      renderProgressSection(steps = [], completedSteps = []) {\n        if (!this.progressbarEnabled || !steps.length) return '';\n        const totalSteps = steps.length;\n        const doneSteps = completedSteps.length;\n        const progress = totalSteps > 0 ? (doneSteps / totalSteps) * 100 : 0;\n        let duration = 0;\n        steps.forEach((step) => {\n          if (!completedSteps.includes(step.id) && step.duration > 0) {\n            duration += step.duration;\n          }\n        });\n        const progressLabel = this._translateWithVars(\n          'taskProgress',\n          { a: doneSteps, b: totalSteps },\n          `${doneSteps} of ${totalSteps} done`\n        );\n        const durationLabel =\n          duration > 0 ? this._translateWithVars('aboutMinutes', { a: duration }, `About ${duration} min left`) : '';\n        return `\n          <div part=\"progress-labels\" class=\"checklist-progress-labels\">\n            <div part=\"progress-label-primary\" class=\"checklist-progress-label\">${progressLabel}</div>\n            ${\n              durationLabel\n                ? `<div part=\"progress-label-secondary\" class=\"checklist-progress-label\">${durationLabel}</div>`\n                : ''\n            }\n          </div>\n          <div part=\"progress-bar\" class=\"checklist-progress-bar\">\n            <div part=\"progress-bar-progress\" class=\"checklist-progress-bar-progress\" style=\"width: ${progress}%;\"></div>\n          </div>`;\n      }\n\n      renderTasks(steps = [], completedSteps = []) {\n        if (!steps || steps.length === 0) return `<p>${this._translate('noStepsDefined', 'No steps defined.')}</p>`;\n        return steps\n          .map((step, index) => {\n            const isTaskDone = completedSteps.includes(step.id);\n            const isActive = this.activeStep === index;\n            const badge = isTaskDone\n              ? `<span part=\"task-badge\" class=\"checklist-task-header--badge checklist-task-header--badge-done\">${this.getCheckIcon()}</span>`\n              : `<span part=\"task-badge\" class=\"checklist-task-header--badge\">${index + 1}</span>`;\n            const stepTitle =\n              step.title || this._translateWithVars('stepDefaultTitle', { index: index + 1 }, `Step ${index + 1}`);\n            const stepDescription = step.description || '';\n            const actionButtonText = step.actionTitle || this._translate('actionDefaultTitle', 'Action');\n            const actionHtml =\n              step.action && step.action !== 'none'\n                ? `<div part=\"task-action\" class=\"checklist-task-body-action\" data-action-index=\"${index}\">\n                      <button type=\"button\" class=\"action-button form-send-button\">${actionButtonText}</button>\n                   </div>`\n                : '';\n            const markDoneLabel = this._translate('markAsDone', 'Mark as done');\n            const markDoneHtml =\n              step.allowMarkDone && !isTaskDone\n                ? `<div part=\"task-mark-done\" class=\"checklist-task-body-markdone\" data-markdone-index=\"${index}\">\n                      ${this.getCheckIcon()}\n                      <div class=\"checklist-task-body-markdone-label\">${markDoneLabel}</div>\n                   </div>`\n                : '';\n            const taskClasses = [\n              'checklist-task',\n              isTaskDone ? 'checklist-task--done' : '',\n              isActive ? 'checklist-task--active' : '',\n            ]\n              .filter(Boolean)\n              .join(' ');\n            return `\n              <div part=\"task\" class=\"${taskClasses}\" data-task-index=\"${index}\">\n                <div part=\"task-header\" class=\"checklist-task-header\" role=\"button\" aria-expanded=\"${isActive}\" aria-controls=\"task-body-${index}\">\n                  ${badge}\n                  <div part=\"task-header-title\" class=\"checklist-task-header--title\">${stepTitle}</div>\n                  <span part=\"task-header-chevron\" class=\"checklist-task-header--chevron\">\n                    <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n                      <polyline points=\"6 9 12 15 18 9\"></polyline>\n                    </svg>\n                  </span>\n                </div>\n                <div part=\"task-body\" class=\"checklist-task-body\" id=\"task-body-${index}\">\n                  <div part=\"task-body-inner\" class=\"checklist-task-body-inner\">\n                    ${\n                      stepDescription\n                        ? `<div part=\"task-body-content\" class=\"checklist-task-body-content\">${stepDescription}</div>`\n                        : ''\n                    }\n                    ${actionHtml}\n                    ${markDoneHtml}\n                  </div>\n                </div>\n              </div>`;\n          })\n          .join('');\n      }\n\n      renderChecklist(data) {\n        if (!this._hasLoaded || !data || !data.outbound) {\n          this._checkSessionAndLoad();\n          return;\n        }\n        const { outbound } = data;\n        const steps = outbound.config?.steps || [];\n        const completedSteps = data.completedSteps || [];\n        const isDone = data.status === 'done' || (steps.length > 0 && completedSteps.length >= steps.length);\n        let content = '';\n        if (isDone) {\n          const successTitle = outbound.config?.successTitle || '';\n          const successMessage = outbound.config?.successMessage || '';\n          if (this.floatingEnabled) {\n            content = this.renderFloatingLauncher(outbound, 'checklist-floating-launcher', true);\n          } else {\n            content = `\n              <div part=\"content\" class=\"checklists-content checklists-content--done\">\n                <div part=\"success-icon\" class=\"checklists-success-icon\">\n                  <span part=\"success-icon-circle\" class=\"checklists-success-icon--circle\">${this.getCheckIcon()}</span>\n                </div>\n                <div part=\"success-title\" class=\"checklists-title\">${successTitle}</div>\n                <div part=\"success-description\" class=\"checklists-description\">${successMessage}</div>\n              </div>`;\n          }\n          if (this.activeStep !== -1) this.activeStep = -1;\n        } else {\n          content = `\n            <div part=\"content\" class=\"checklists-content\">\n              ${!this.floatingEnabled ? this.renderInfoSection(outbound) : ''}\n              ${!this.floatingEnabled ? this.renderProgressSection(steps, completedSteps) : ''}\n              ${this.floatingEnabled ? this.renderFloatingLauncher(outbound) : ''}\n              <div part=\"tasks\" class=\"checklist-tasks\">\n                ${this.floatingEnabled ? this.renderFloatingLauncher(outbound, 'checklist-floating-header') : ''}\n                ${this.renderTasks(steps, completedSteps)}\n              </div>\n            </div>`;\n        }\n\n        const flowConfig = GleapConfigManager.getInstance().getFlowConfig();\n        const primaryColor = flowConfig.color ? flowConfig.color : '#485BFF';\n\n        const styles = `\n          <style>\n            :host {\n              display: block;\n              --color-bg: #ffffff;\n              --color-font-title: #1f2937;\n              --color-font-text: #4b5563;\n              --color-font-light: #6b7280;\n              --color-primary: ${primaryColor};\n              --color-primary-light: ${primaryColor}22;\n              --color-primary-contrast: #ffffff;\n              --color-border: #e5e7eb;\n              --color-gray-light: #f3f4f6;\n              --color-gray-lighter: #f9fafb;\n              --color-gray-dark: #6b7280;\n              --color-success: #10b981;\n              --color-success-light: #ffffff;\n              --radius-sm: 4px;\n              --radius-lg: 12px;\n              --radius-full: 9999px;\n              --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);\n              --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.08);\n              --shadow-lg: rgba(0, 0, 0, 0.2) 0px 7px 29px 0px;\n              --animation-duration: 0.2s;\n              --animation-timing: ease-in-out;\n              font-family: system-ui, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";\n              box-sizing: border-box;\n            }\n            :host([dark]) {\n              --color-bg: #1f2937;\n              --color-font-title: #f9fafb;\n              --color-font-text: #d1d5db;\n              --color-font-light: #9ca3af;\n              --color-primary: ${primaryColor};\n              --color-primary-light: ${primaryColor}22;\n              --color-primary-contrast: #ffffff;\n              --color-border: #374151;\n              --color-gray-light: #374151;\n              --color-gray-lighter: #111827;\n              --color-gray-dark: #9ca3af;\n              --color-success: #34d399;\n              --color-success-light: #1f2937;\n            }\n            *, *:before, *:after { box-sizing: inherit; }\n            .checklists-content { color: var(--color-font-text); }\n            .checklists-content--done { text-align: center; }\n            .checklists-info { margin-bottom: 24px; text-align: center; }\n            .checklists-title { font-size: 1.25rem; font-weight: 600; margin-bottom: 8px; color: var(--color-font-title); }\n            .checklists-description { font-size: 0.9rem; margin-bottom: 16px; color: var(--color-font-text); line-height: 1.5; }\n            .checklists-sender { display: flex; align-items: center; justify-content: center; gap: 8px; }\n            .checklists-sender img { width: 28px; height: 28px; border-radius: var(--radius-full); object-fit: cover; }\n            .checklists-sender span { font-size: 0.875rem; color: var(--color-font-light); font-weight: 500; }\n            .checklists-success-icon { margin-bottom: 16px; line-height: 0; }\n            .checklists-success-icon--circle { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: var(--radius-full); background-color: var(--color-success); color: var(--color-success-light); font-size: 22px; }\n            .checklist-progress-labels { display: flex; justify-content: space-between; margin-bottom: 8px; }\n            .checklist-progress-label { font-size: 0.75rem; color: var(--color-font-light); font-weight: 500; }\n            .checklist-progress-bar { width: 100%; height: 6px; background-color: var(--color-gray-light); border-radius: var(--radius-full); overflow: hidden; margin-bottom: 20px; }\n            .checklist-progress-bar-progress { height: 100%; background-color: var(--color-primary); transition: width var(--animation-duration) var(--animation-timing); border-radius: var(--radius-full); }\n            .checklist-tasks { display: flex; flex-direction: column; gap: 12px; }\n            .checklist-task { border: 1px solid var(--color-border); border-radius: var(--radius-lg); background-color: var(--color-bg); box-shadow: var(--shadow-sm); overflow: hidden; transition: background-color var(--animation-duration) var(--animation-timing), border-color var(--animation-duration) var(--animation-timing); }\n            .checklist-task-header { display: flex; align-items: center; padding: 15px 20px; cursor: pointer; gap: 12px; position: relative; }\n            .checklist-task-header:hover { background: var(--color-gray-lighter); }\n            .checklist-task-header:hover .checklist-task-header--chevron {\n              color: var(--color-font-title);\n            }\n            .checklist-task-header--badge { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: var(--radius-full); background-color: var(--color-primary-light); color: var(--color-primary); font-size: 0.875rem; font-weight: 600; flex-shrink: 0; transition: background-color var(--animation-duration) var(--animation-timing), color var(--animation-duration) var(--animation-timing); line-height: 1; }\n            .checklist-task-header--badge svg { width: 16px; height: 16px; }\n            .checklist-task-header--title { flex-grow: 1; font-size: 0.9rem; font-weight: 500; color: var(--color-font-title); transition: font-weight var(--animation-duration) var(--animation-timing), color var(--animation-duration) var(--animation-timing), text-decoration var(--animation-duration) var(--animation-timing); }\n            .checklist-task-header--chevron { color: var(--color-font-light); transition: transform var(--animation-duration) var(--animation-timing); flex-shrink: 0; margin-left: auto; }\n            .checklist-task-header--chevron svg { display: block; width: 18px; height: 18px; }\n            .checklist-task-body {\n              overflow: hidden;\n              transition: max-height var(--animation-duration) var(--animation-timing), opacity var(--animation-duration) var(--animation-timing);\n              max-height: 0;\n              opacity: 0;\n            }\n            .checklist-task--active .checklist-task-body {\n              max-height: var(--task-body-active-height, 200px);\n              opacity: 1;\n            }\n            .checklist-task-body-inner { padding: 4px 16px 20px 60px; font-size: 0.875rem; color: var(--color-font-text); line-height: 1.5; }\n            .checklist-task-body-content { margin-bottom: 16px; }\n            .checklist-task-body-content p:first-child { margin-top: 0; }\n            .checklist-task-body-content p:last-child { margin-bottom: 0; }\n            .checklist-task-body-content iframe { width: 100%; height: 315px; object-fit: contain; border: none; }\n            .checklist-task-body-action { margin-top: 16px; }\n            .action-button { display: inline-flex; align-items: center; justify-content: center; background-color: var(--color-primary); color: var(--color-primary-contrast); padding: 10px 18px; font-size: 0.875rem; font-weight: 500; border-radius: var(--radius-lg); border: none; text-align: center; cursor: pointer; transition: background-color var(--animation-duration) var(--animation-timing), box-shadow var(--animation-duration) var(--animation-timing); box-shadow: var(--shadow-sm); }\n            .action-button:hover { background-color: color-mix(in srgb, var(--color-primary) 90%, black); box-shadow: var(--shadow-md); }\n            .action-button:focus { outline: 2px solid color-mix(in srgb, var(--color-primary) 50%, transparent); outline-offset: 2px; }\n            .checklist-task-body-markdone { margin-top: 20px; border-top: 1px solid var(--color-border); padding: 16px 0 0px 0; display: flex; align-items: center; cursor: pointer; color: var(--color-primary); transition: color var(--animation-duration) var(--animation-timing); }\n            .checklist-task-body-markdone:hover { color: color-mix(in srgb, var(--color-primary) 80%, black); }\n            .checklist-task-body-markdone svg { width: 18px; height: 18px; margin-right: 6px; flex-shrink: 0; font-size: 18px; }\n            .checklist-task-body-markdone-label { font-size: 0.875rem; font-weight: 500; line-height: 1; }\n            .checklist-task--active .checklist-task-header--title { font-weight: 600; }\n            .checklist-task--active .checklist-task-header--chevron { transform: rotate(180deg); }\n            .checklist-task--active .checklist-task-header:hover { background: linear-gradient(180deg, var(--color-gray-lighter), transparent); }\n            .checklist-task--done { background-color: var(--color-gray-lighter); border-color: var(--color-gray-light); box-shadow: none; }\n            .checklist-task--done .checklist-task-header--badge { background-color: var(--color-success); color: var(--color-success-light); }\n            .checklist-task--done .checklist-task-header--title { color: var(--color-font-light); }\n            .checklist-task--done .checklist-task-body-inner { color: var(--color-font-light); }\n            .checklist-task--done .checklist-task-header--title {\n              text-decoration: line-through;\n            }\n  \n            /* -------------------------\n               Floating style addition\n               Only applies if floating=\"true\"\n               ------------------------- */\n            :host([floating=\"true\"]) .checklists-content {\n              position: relative;\n            }\n            :host([floating=\"true\"]) .checklist-tasks {\n              position: absolute;\n              bottom: 0;\n              left: 0;\n              z-index: 1000;\n              max-height: 90vh;\n              display: none;\n              padding: 0px;\n              min-width: min(380px, 90vw);\n              background-color: var(--color-bg);\n              border-radius: var(--radius-lg);\n              box-shadow: var(--shadow-lg);\n              overflow: hidden;\n            }\n            :host([floating=\"true\"]) .checklist-task {\n              border-radius: 0px;\n              border: none;\n              box-shadow: none;\n              border-bottom: 1px solid var(--color-border);\n            }\n            :host([floating=\"true\"]) .checklist-task:last-child {\n              border-bottom: none;\n            }\n            :host([floating=\"true\"]) .checklist-task--done {\n              background-color: transparent;\n            }\n            :host([floating=\"true\"]) .checklist-task-header:hover {\n              background: linear-gradient(180deg, var(--color-gray-lighter), transparent);\n            }\n  \n            /* -------------------------\n               Floating Launcher Styles\n               ------------------------- */\n            .checklist-floating-launcher {\n              padding: 12px;\n              background-color: var(--color-bg);\n              border: 1px solid var(--color-border);\n              border-radius: var(--radius-lg);\n              box-shadow: var(--shadow-md);\n              transition: transform 0.3s ease;\n              cursor: pointer;\n            }\n            .checklist-floating-launcher--done {\n              cursor: default !important;\n            }\n            .checklist-floating-header {\n              padding: 20px;\n              padding-bottom: 16px;\n              border-bottom: 1px solid var(--color-border);\n              cursor: pointer;\n            }\n            .checklist-floating-header:hover .floating-icon,\n            .checklist-floating-launcher:hover .floating-icon {\n              color: var(--color-font-title);\n            }\n            .floating-header {\n              display: flex;\n              align-items: center;\n              justify-content: flex-start;\n            }\n            .floating-title {\n              font-size: 0.875rem;\n              font-weight: 600;\n              color: var(--color-font-title);\n              max-width: calc(100% - 32px);\n              display: -webkit-box;\n              -webkit-line-clamp: 1;\n              -webkit-box-orient: vertical;\n              overflow: hidden;\n            }\n            .floating-subtitle {\n              font-size: 0.875rem;\n              color: var(--color-font-text);\n              margin-top: 8px;\n              max-width: 100%;\n              display: -webkit-box;\n              -webkit-line-clamp: 1;\n              -webkit-box-orient: vertical;\n              overflow: hidden;\n            }\n            .floating-circular-progress {\n              width: 26px;\n              height: 26px;\n              margin-right: 6px;\n            }\n            .floating-circular-progress svg {\n              width: 100%;\n              height: 100%;\n              transform: rotate(-90deg);\n            }\n            .floating-circular-progress .track {\n              fill: none;\n              stroke: var(--color-gray-light);\n              stroke-width: 3;\n            }\n            .floating-circular-progress .progress {\n              fill: none;\n              stroke: var(--color-primary);\n              stroke-width: 3;\n              stroke-linecap: round;\n              transition: stroke-dashoffset var(--animation-duration) var(--animation-timing);\n            }\n            .checklist-floating-launcher--done .floating-circular-progress .progress {\n              stroke: var(--color-success);\n            }\n            .floating-icon {\n              margin-left: auto;\n              color: var(--color-font-light);\n            }\n          </style>\n        `;\n        this.shadowRoot.innerHTML = styles + content;\n        this.addTaskEventListeners();\n        if (this.floatingEnabled) {\n          this.addFloatingClickListeners();\n        }\n        if (this.activeStep !== -1) {\n          this.toggleTask(this.activeStep, true);\n        }\n      }\n\n      updateActiveTaskMaxHeight() {\n        if (this.activeStep !== -1) {\n          const taskBodyInner = this.shadowRoot.querySelector(\n            `.checklist-task[data-task-index=\"${this.activeStep}\"] .checklist-task-body-inner`\n          );\n          const container = this.shadowRoot.querySelector(\n            `.checklist-task[data-task-index=\"${this.activeStep}\"] .checklist-task-body`\n          );\n          if (taskBodyInner && container) {\n            const height = taskBodyInner.offsetHeight;\n            container.style.setProperty('--task-body-active-height', `${height}px`);\n          }\n        }\n      }\n\n      // --- Event Listener Setup ---\n      addTaskEventListeners() {\n        const tasks = this.shadowRoot.querySelectorAll('.checklist-task');\n        tasks.forEach((task) => {\n          const header = task.querySelector('.checklist-task-header');\n          const index = parseInt(task.getAttribute('data-task-index'), 10);\n          if (header) {\n            header.addEventListener('click', () => {\n              const newActiveStep = this.activeStep === index ? -1 : index;\n              this.setActiveStep(newActiveStep);\n            });\n          }\n          const markDoneBtn = task.querySelector('.checklist-task-body-markdone');\n          if (markDoneBtn) {\n            markDoneBtn.addEventListener('click', (e) => {\n              e.stopPropagation();\n              if (!this.checklistData?.outbound?.config?.steps) return;\n              const step = this.checklistData.outbound.config.steps[index];\n              if (!step) return;\n              const previouslyActiveStep = this.activeStep;\n              if (!this.checklistData.completedSteps) this.checklistData.completedSteps = [];\n              if (!this.checklistData.completedSteps.includes(step.id)) {\n                this.checklistData.completedSteps.push(step.id);\n                const allSteps = this.checklistData.outbound.config.steps;\n                let nextActiveStep = -1;\n                if (previouslyActiveStep === index) {\n                  for (let i = index + 1; i < allSteps.length; i++) {\n                    if (!this.checklistData.completedSteps.includes(allSteps[i].id)) {\n                      nextActiveStep = i;\n                      break;\n                    }\n                  }\n                  this.setActiveStep(nextActiveStep);\n                }\n                // Preserve the state of the floating modal.\n                setTimeout(() => {\n                  let isModalOpen = false;\n                  if (this.floatingEnabled) {\n                    const tasksModal = this.shadowRoot.querySelector('.checklist-tasks');\n                    isModalOpen = tasksModal && tasksModal.style.display === 'block';\n                  }\n                  this.renderChecklist(this.checklistData);\n                  if (this.floatingEnabled && isModalOpen) {\n                    const tasksModal = this.shadowRoot.querySelector('.checklist-tasks');\n                    if (tasksModal) tasksModal.style.display = 'block';\n                  }\n                }, 300);\n                const updateData = { checkedStep: step.id };\n                if (allSteps.length > 0 && this.checklistData.completedSteps.length >= allSteps.length) {\n                  this.checklistData.status = 'done';\n                  updateData.status = 'done';\n                }\n                this.updateChecklist(this.checklistData.id, updateData);\n              }\n            });\n          }\n          const actionBtn = task.querySelector('.checklist-task-body-action .action-button');\n          if (actionBtn) {\n            actionBtn.addEventListener('click', (e) => {\n              e.stopPropagation();\n              if (!this.checklistData?.outbound?.config?.steps || typeof Gleap === 'undefined') return;\n              const step = this.checklistData.outbound.config.steps[index];\n              if (!step || !step.action || step.action === 'none') return;\n              try {\n                if (step.action === 'BOT') Gleap.startBot(step.botId);\n                else if (step.action === 'CUSTOM_ACTION') Gleap.triggerCustomAction(step.actionBody);\n                else if (step.action === 'REDIRECT_URL') {\n                  e.preventDefault();\n                  e.stopPropagation();\n                  e.stopImmediatePropagation();\n                  Gleap.openURL(step.actionBody, !!step.actionOpenInNewTab);\n                } else if (step.action === 'FEEDBACK_FLOW') Gleap.startFeedbackFlow(step.formId);\n                else if (step.action === 'NEWS_ARTICLE') Gleap.openNewsArticle(step.articleId);\n                else if (step.action === 'HELP_ARTICLE') Gleap.openHelpCenterArticle(step.articleId);\n                else if (step.action === 'CHECKLIST') Gleap.startChecklist(step.outboundId, true, step?.sharedKey);\n                else if (step.action === 'PRODUCT_TOUR') Gleap.startProductTour(step.productTourId, true);\n              } catch (gleapError) {}\n            });\n          }\n        });\n      }\n\n      // --- Animation and State Management ---\n      setActiveStep(index) {\n        const previousActiveStep = this.activeStep;\n        this.activeStep = index;\n        const tasksToToggle = [];\n        if (previousActiveStep !== -1 && previousActiveStep !== this.activeStep) {\n          tasksToToggle.push({ index: previousActiveStep, open: false });\n        }\n        if (this.activeStep !== -1 && this.activeStep !== previousActiveStep) {\n          tasksToToggle.push({ index: this.activeStep, open: true });\n        }\n        tasksToToggle.forEach(({ index, open }) => {\n          this.toggleTask(index, open);\n        });\n      }\n\n      toggleTask(index, forceOpen = null) {\n        const taskElement = this.shadowRoot.querySelector(`.checklist-task[data-task-index=\"${index}\"]`);\n        if (!taskElement) return;\n        const header = taskElement.querySelector('.checklist-task-header');\n        if (!header) return;\n        const isOpen = taskElement.classList.contains('checklist-task--active');\n        const shouldOpen = forceOpen !== null ? forceOpen : !isOpen;\n        if (shouldOpen) {\n          if (!isOpen) {\n            taskElement.classList.add('checklist-task--active');\n            header.setAttribute('aria-expanded', 'true');\n          }\n          const taskBodyInner = taskElement.querySelector('.checklist-task-body-inner');\n          if (taskBodyInner) {\n            const height = taskBodyInner.offsetHeight;\n            const taskBody = taskElement.querySelector('.checklist-task-body');\n            if (taskBody) {\n              taskBody.style.setProperty('--task-body-active-height', `${height}px`);\n            }\n          }\n          // Recalculate height when iframes finish loading\n          const iframes = taskElement.querySelectorAll('iframe');\n          iframes.forEach((iframe) => {\n            if (!iframe._heightListenerAdded) {\n              iframe._heightListenerAdded = true;\n              iframe.addEventListener('load', () => {\n                if (this.activeStep === index) {\n                  this.updateActiveTaskMaxHeight();\n                }\n              });\n            }\n          });\n        } else if (!shouldOpen && isOpen) {\n          taskElement.classList.remove('checklist-task--active');\n          header.setAttribute('aria-expanded', 'false');\n        }\n      }\n    }\n\n    if (typeof customElements !== 'undefined' && !customElements.get('gleap-checklist')) {\n      customElements.define('gleap-checklist', GleapChecklist);\n    }\n  }\n};\n","import { GleapSession } from './Gleap';\n\nexport const registerGleapAgentComponents = () => {\n  if (typeof customElements === 'undefined' || typeof HTMLElement === 'undefined' || typeof window === 'undefined') return;\n\n  if (!customElements.get('gleap-agent-conversation')) {\n    class GleapAgentConversation extends HTMLElement {\n      _iframe = null;\n      _agentConvUrl = 'https://outboundmedia.gleap.io/agent-conversation';\n      _messageListener = null;\n      _config = {};\n\n      static get observedAttributes() {\n        return ['agentId', 'conversationId', 'dark', 'placeholder', 'agentColor', 'emptyText', 'context'];\n      }\n\n      connectedCallback() {\n        this._injectIframe();\n        this._listenForMessages();\n      }\n\n      disconnectedCallback() {\n        if (this._messageListener) {\n          window.removeEventListener('message', this._messageListener);\n        }\n        this._messageListener = null;\n      }\n\n      attributeChangedCallback(name, oldValue, newValue) {\n        if (oldValue !== newValue && this._iframe) {\n          this._sendConfig();\n        }\n      }\n\n      _injectIframe() {\n        if (this._iframe) return;\n        this.style.display = 'block';\n        this.style.width = '100%';\n        this.style.height = '100%';\n\n        const iframe = document.createElement('iframe');\n        iframe.src = this._agentConvUrl;\n        iframe.style.cssText = 'width: 100%; height: 100%; border: 0; background: transparent;';\n        iframe.setAttribute('frameborder', '0');\n        iframe.setAttribute('allow', 'autoplay; encrypted-media; microphone *;');\n        iframe.title = 'Gleap Agent Conversation';\n        this.appendChild(iframe);\n        this._iframe = iframe;\n      }\n\n      _listenForMessages() {\n        if (this._messageListener) return; // already listening — prevent duplicate on reconnect\n        this._messageListener = (event) => {\n          try {\n            const url = new URL(this._agentConvUrl);\n            if (event.origin !== url.origin) return;\n          } catch (e) {\n            return; // URL parse failed — reject message to be safe\n          }\n\n          let data;\n          try { data = JSON.parse(event.data); } catch (e) { return; }\n          if (data?.type !== 'AGENT_CONVERSATION') return;\n\n          if (data.name === 'agent-conv-loaded') {\n            this._sendConfig();\n          }\n          if (data.name === 'agent-conv-conversation-created') {\n            this.dispatchEvent(new CustomEvent('gleap-agent-conversation-created', { bubbles: true, composed: true, detail: data.data }));\n          }\n          if (data.name === 'agent-conv-message-sent') {\n            this.dispatchEvent(new CustomEvent('gleap-agent-message-sent', { bubbles: true, composed: true, detail: data.data }));\n          }\n          if (data.name === 'agent-conv-reply-received') {\n            this.dispatchEvent(new CustomEvent('gleap-agent-reply-received', { bubbles: true, composed: true, detail: data.data }));\n          }\n          if (data.name === 'agent-conv-error') {\n            this.dispatchEvent(new CustomEvent('gleap-agent-error', { bubbles: true, composed: true, detail: data.data }));\n          }\n        };\n        window.addEventListener('message', this._messageListener);\n      }\n\n      _sendConfig() {\n        if (!this._iframe?.contentWindow) return;\n\n        let apiUrl = 'https://api.gleap.io';\n        let sdkKey = '';\n        let gleapId = '';\n        let gleapHash = '';\n\n        try {\n          const session = GleapSession.getInstance();\n          apiUrl = session.apiUrl || apiUrl;\n          sdkKey = session.sdkKey || '';\n          gleapId = session.session?.gleapId || '';\n          gleapHash = session.session?.gleapHash || '';\n        } catch (e) {}\n\n        const config = {\n          agentId: this.getAttribute('agentId') || '',\n          conversationId: this.getAttribute('conversationId') || null,\n          dark: this.getAttribute('dark') === 'true' || this.getAttribute('dark') === '',\n          placeholder: this.getAttribute('placeholder') || 'Type a message...',\n          agentColor: this.getAttribute('agentColor') || null,\n          emptyText: this.getAttribute('emptyText') || 'How can I help you today?',\n          context: (() => { try { const c = this.getAttribute('context'); return c ? JSON.parse(c) : null; } catch { return null; } })(),\n          apiUrl,\n          sdkKey,\n          gleapId,\n          gleapHash,\n        };\n\n        this._config = config;\n\n        this._iframe.contentWindow.postMessage(\n          JSON.stringify({ type: 'agent-conversation', name: 'agent-conv-data', data: config }),\n          '*'\n        );\n      }\n\n      sendMessage(content) {\n        if (!this._iframe?.contentWindow || !content?.trim()) return;\n        this._iframe.contentWindow.postMessage(\n          JSON.stringify({ type: 'agent-conversation', name: 'agent-conv-send-message', data: { content } }),\n          '*'\n        );\n      }\n\n      clearConversation() {\n        if (!this._iframe?.contentWindow) return;\n        this._iframe.contentWindow.postMessage(\n          JSON.stringify({ type: 'agent-conversation', name: 'agent-conv-clear', data: {} }),\n          '*'\n        );\n      }\n    }\n\n    customElements.define('gleap-agent-conversation', GleapAgentConversation);\n  }\n};\n","import Gleap from './Gleap';\n\nexport default Gleap;\n"],"names":["__webpack_require__","exports","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","GleapFeedbackButtonManager","_classCallCheck","_defineProperty","value","this","instance","feedbackButton","remove","buttonHidden","lastButtonIcon","injectedFeedbackButton","show","getInstance","updateFeedbackButtonState","GleapNotificationManager","updateContainerStyle","frameManager","GleapFrameManager","isOpened","redDotClass","existingDot","querySelector","concat","dot","document","createElement","className","appendChild","hideWidget","updateRedDot","showingRedDot","setAppMode","showWidget","_this","elem","addEventListener","feedbackButtonPressed","body","count","notificationBadge","notificationHiddenClass","classList","innerText","add","updateFeedbackButtonText","injectFeedbackButton","flowConfig","GleapConfigManager","getFlowConfig","feedbackButtonPosition","FEEDBACK_BUTTON_CLASSIC","FEEDBACK_BUTTON_CLASSIC_BOTTOM","FEEDBACK_BUTTON_CLASSIC_LEFT","widgetButtonText","GleapAiChatbarManager","updateUIVisibility","buttonIcon","buttonLogo","loadIcon","setAttribute","GleapTranslationManager","isRTLLayout","innerHTML","hideButton","FEEDBACK_BUTTON_NONE","FEEDBACK_BUTTON_BOTTOM_LEFT","appMode","hideForGuests","GleapSession","isUser","calculateShadeColor","col","amt","replace","length","_col$match2","_slicedToArray","match","r","g","b","_ref","parseInt","Math","max","min","toString","rr","gg","bb","calculateContrast","hex","substr","name","color","GleapNetworkIntercepter","Date","now","loadAllResources","contentType","toLocaleLowerCase","supportedContentTypes","i","includes","requests","JSON","parse","stringify","values","externalRequests","filters","request","headers","j","payload","payloadObj","e","response","responseText","data","window","performance","resources","getEntriesByType","resource","indexOf","initiatorType","find","url","push","type","date","startTimestamp","startTime","duration","round","exp","blacklist","defaultBlacklist","filter","maxRequests","stopped","keys","keysToRemove","slice","bbRequestId","startDate","getTime","text","size","TextEncoder","encode","encodeURI","s","split","Blob","getTextContentSize","undefined","TextDecoder","_typeof","ArrayBuffer","isView","decode","payloadText","cleanupPayload","cleanupContentSize","initialized","self","interceptNetworkRequests","onFetch","params","fromEntries","entries","method","preparePayload","cleanRequests","onFetchLoad","req","status","statusText","calcRequestTime","isContentTypeSupported","then","err","onFetchFailed","onOpen","args","onSend","requestHeaders","onError","currentTarget","onLoad","target","responseType","callback","originalFetch","open","XMLHttpRequest","send","gleapSetRequestHeader","setRequestHeader","header","requestId","arguments","bind","apply","fetch","clone","blob","Promise","resolve","reject","fr","FileReader","onload","evt","result","onerror","readAsText","resizeImage","base64Str","maxWidth","maxHeight","isJPEG","img","Image","src","canvas","MAX_WIDTH","MAX_HEIGHT","width","height","getContext","drawImage","toDataURL","MOBILE_UA_REGEX","getDeviceType","isMobile","nav","navigator","userAgentData","mobile","test","userAgent","vendor","maxTouchPoints","matchMedia","coarsePointer","matches","gleapDataParser","String","truncateString","str","num","removeSubDomain","v","parts","is2ndLevelDomain","secondLevel","join","loadFromGleapCache","cachedData","localStorage","getItem","saveToGleapCache","k","setItem","removeItem","runFunctionWhenDomIsReady","readyState","RequestStatus","ChecklistNetworkManager","Map","validationCache","clear","fetchCache","validationRequests","fetchRequests","gleapSessionInstance","session","lang","getActiveLanguage","gleapId","gleapHash","apiUrl","xhr","injectSession","onreadystatechange","responseData","error","outboundId","sharedKey","cacheKey","_createCacheKey","cachedResult","internalId","has","_getApiUrl","Error","set","_getQueryParams","requestPromise","_makeRequest","id","_this2","_regeneratorRuntime","t","n","Symbol","a","iterator","c","asyncIterator","u","toStringTag","define","configurable","writable","wrap","Generator","create","Context","makeInvokeMethod","tryCatch","arg","h","l","f","y","GeneratorFunction","GeneratorFunctionPrototype","p","d","getPrototypeOf","defineIteratorMethods","forEach","_invoke","AsyncIterator","invoke","__await","callInvokeWithMethodAndArg","done","delegate","maybeInvokeDelegate","sent","_sent","dispatchException","abrupt","TypeError","resultName","next","nextLoc","pushTryEntry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","reset","isNaN","displayName","isGeneratorFunction","constructor","mark","setPrototypeOf","__proto__","awrap","async","reverse","pop","prev","charAt","stop","rval","handle","complete","finish","delegateYield","_createForOfIteratorHelper","allowArrayLike","it","Array","isArray","minLen","_arrayLikeToArray","from","_unsupportedIterableToArray","F","_e","normalCompletion","didErr","step","_e2","arr","len","arr2","asyncGeneratorStep","gen","_next","_throw","info","dispatchSSEEvent","event","callbacks","_callbacks$onMeta","_callbacks$onToken","_callbacks$onToolStar","_callbacks$onToolEnd","_callbacks$onDone","_callbacks$onError","_callbacks$onHandoff","onMeta","onToken","onToolStart","onToolEnd","onDone","onHandoff","parseSSEStream","fn","_callee","_callbacks$onError2","reader","decoder","buffer","currentEvent","currentData","_lines$pop","_yield$reader$read","lines","_iterator","_step","line","trimmed","parsed","_parsed","_callbacks$onError3","_context","message","getReader","read","stream","startsWith","trim","_unused","_unused2","t0","_x","_x2","ownKeys","getOwnPropertySymbols","getOwnPropertyDescriptor","_objectSpread","getOwnPropertyDescriptors","defineProperties","_defineProperties","props","descriptor","_toPropertyKey","toPrimitive","Number","_toPrimitive","AgentNetworkManager","Constructor","protoProps","staticProps","_streamAgent","messagesCache","messagesRequests","executeInFlight","_s$session","_s$session2","sdkKey","agentId","signal","_getHeaders","Accept","ok","conversationId","_invalidateMessagesCache","_x3","_x4","limit","skip","messages","cached","conversations","_step2","_iterator2","floor","createCoords","x","oppositeSideMap","left","right","bottom","top","oppositeAlignmentMap","start","end","clamp","param","placement","axis","getAxisLength","yAxisSides","Set","getAlignmentAxis","alignment","lrPlacement","rlPlacement","tbPlacement","btPlacement","getOppositeAxisPlacements","flipAlignment","direction","rtl","list","side","isStart","getSideList","map","getOppositePlacement","padding","expandPaddingObject","rect","computeCoordsFromPlacement","reference","floating","sideAxis","alignmentAxis","alignLength","isVertical","commonX","commonY","commonAlign","coords","detectOverflow","state","options","_await$platform$isEle","platform","rects","elements","strategy","boundary","rootBoundary","elementContext","altBoundary","paddingObject","element","clippingClientRect","getClippingRect","isElement","contextElement","getDocumentElement","offsetParent","getOffsetParent","offsetScale","getScale","elementClientRect","convertOffsetParentRelativeRectToViewportRelativeRect","originSides","hasWindow","getNodeName","node","isNode","nodeName","toLowerCase","getWindow","_node$ownerDocument","ownerDocument","defaultView","documentElement","Node","Element","isHTMLElement","HTMLElement","isShadowRoot","ShadowRoot","invalidOverflowDisplayValues","isOverflowElement","overflow","overflowX","overflowY","display","tableElements","isTableElement","topLayerSelectors","isTopLayer","some","selector","transformProperties","willChangeValues","containValues","isContainingBlock","elementOrCss","webkit","isWebKit","css","containerType","backdropFilter","willChange","contain","CSS","supports","lastTraversableNodeNames","isLastTraversableNode","getComputedStyle","getNodeScroll","scrollLeft","scrollTop","scrollX","scrollY","getParentNode","assignedSlot","parentNode","host","getNearestOverflowAncestor","getOverflowAncestors","traverseIframes","_node$ownerDocument2","scrollableAncestor","isBody","win","frameElement","getFrameElement","visualViewport","parent","getCssDimensions","parseFloat","hasOffset","offsetWidth","offsetHeight","shouldFallback","$","unwrapElement","domElement","getBoundingClientRect","isFinite","noOffsets","getVisualOffsets","offsetLeft","offsetTop","includeScale","isFixedStrategy","clientRect","scale","visualOffsets","isFixed","floatingOffsetParent","shouldAddVisualOffsets","offsetWin","currentWin","currentIFrame","iframeScale","iframeRect","clientLeft","paddingLeft","clientTop","paddingTop","getWindowScrollBarX","leftScroll","getHTMLOffset","scroll","htmlRect","SCROLLBAR_MAX","absoluteOrFixed","getClientRectFromClippingAncestor","clippingAncestor","html","clientWidth","clientHeight","visualViewportBased","windowScrollbarX","doc","bodyStyles","bodyMarginInline","compatMode","marginLeft","marginRight","clippingStableScrollbarWidth","abs","getViewportRect","scrollWidth","scrollHeight","getDocumentRect","getInnerBoundingClientRect","hasFixedPositionAncestor","stopNode","position","getRectRelativeToOffsetParent","isOffsetParentAnElement","offsets","setLeftRTLScrollbarOffset","offsetRect","htmlOffset","isStaticPositioned","getTrueOffsetParent","polyfill","rawOffsetParent","svgOffsetParent","currentNode","getContainingBlock","topLayer","elementClippingAncestors","cache","el","currentContainingBlockComputedStyle","elementIsFixed","computedStyle","currentNodeIsContaining","ancestor","getClippingElementAncestors","_c","clippingAncestors","firstClippingAncestor","clippingRect","reduce","accRect","getElementRects","getOffsetParentFn","getDimensionsFn","getDimensions","floatingDimensions","getClientRects","isRTL","rectsAreEqual","autoUpdate","update","ancestorScroll","ancestorResize","elementResize","ResizeObserver","layoutShift","IntersectionObserver","animationFrame","referenceEl","ancestors","passive","cleanupIo","onMove","timeoutId","io","root","cleanup","_io","clearTimeout","disconnect","refresh","threshold","elementRectForRootMargin","rootMargin","isFirstUpdate","handleObserve","ratio","intersectionRatio","setTimeout","observe","observeMove","frameId","reobserveFrame","resizeObserver","firstEntry","unobserve","cancelAnimationFrame","requestAnimationFrame","_resizeObserver","prevRefRect","frameLoop","nextRefRect","_resizeObserver2","removeEventListener","_middlewareData$offse","_middlewareData$arrow","middlewareData","diffCoords","mainAxisMulti","crossAxisMulti","rawValue","mainAxis","crossAxis","convertValueToCoords","offset","arrow","alignmentOffset","checkMainAxis","checkCrossAxis","limiter","detectOverflowOptions","mainAxisCoord","crossAxisCoord","maxSide","limitedCoords","enabled","_middlewareData$flip","initialPlacement","fallbackPlacements","specifiedFallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","initialSideAxis","isBasePlacement","oppositePlacement","getExpandedPlacements","hasFallbackAxisSideDirection","placements","overflows","overflowsData","flip","sides","mainAlignmentSide","every","_middlewareData$flip2","_overflowsData$filter","nextIndex","index","nextPlacement","resetPlacement","sort","_overflowsData$filter2","currentSideAxis","acc","arrowDimensions","isYAxis","minProp","maxProp","clientProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","largestPossiblePadding","minPadding","maxPadding","min$1","center","shouldAddOffset","centerOffset","mergedOptions","platformWithCache","config","middleware","validMiddleware","Boolean","statefulPlacement","resetCount","_platform$detectOverf","nextX","nextY","computePosition","checkPageFilter","currentUrl","pageFilter","pageFilterType","removeTrailingSlash","isMatchingUrl","regex","substring","regexPattern","RegExp","generateRegex","matched","endsWith","checkPageRules","action","rules","pageRules","GleapTooltipManager","WeakMap","tooltip","hasAttribute","nextId","tooltipElem","mode","hotspotContainer","canEmbed","firstChild","insertBefore","nextSibling","hotspot","icon","animated","repositionHotspot","elementToTooltipMap","floatingUIInstance","createTooltip","elementToFloatingUIMap","filteredTooltips","getFilteredTooltips","checkForTooltips","tooltips","location","href","page","pageType","querySelectorAll","linkTooltip","sessionInstance","http","console","updateFilteredTooltips","nodeType","ELEMENT_NODE","checkNodeTooltip","childNodes","childNode","processNodeInsertion","_this3","_this4","time","timeout","handleResizeThrottled","updateHotspotPositions","context","_toConsumableArray","observer","MutationObserver","mutations","lastUrl","mutation","addedNodes","removedNodes","floatingUI","childList","subtree","attributes","attributeFilter","_this5","tooltipText","tooltipData","hideTimeout","arrowEl","posX","shift","assign","style","arrowPos","transform","visibility","opacity","pointerEvents","hide","voidElements","tagName","resizeListener","anchor","removeAttribute","tooltipId","getAttribute","posY","offsetX","offsetY","elementRect","range","createRange","selectNodeContents","fixedWidth","anchorRect","tooltipSize","email","userId","phone","onSessionReady","ready","onSessionReadyListener","attemp","retry","GleapEventManager","notifyEvent","useCookies","cookie","eraseGleapCookie","sendMessage","clearAllNotifications","setNotificationCount","GleapBannerManager","removeBannerUI","GleapModalManager","hideModal","newTimeout","pow","startSession","_this$session","sessionChanged","localStorageDisabled","days","expires","setTime","toUTCString","setGleapCookie","encodeURIComponent","clearCache","GleapStreamedEvent","restart","tooltipManager","destroy","load","dispatchEvent","CustomEvent","notifySessionReady","sessionCookie","nameEQ","ca","getGleapCookie","sessionData","decodeURIComponent","validateSession","cachedSession","clearSession","deviceType","userData","checkIfSessionDataNeedsUpdate","userDataKeys","userDataKey","customData","setOnSessionReady","sdkVersion","SDK_VERSION","ws","userHash","checkIfSessionNeedsUpdate","dataToSend","tourId","tourData","_window","passedPageFilter","sendSessionUpdate","streamEvents","mainLoopTimeout","runEventStreamLoop","streamingEvents","errorCount","streamedEventArray","socket","OPEN","sessionDuration","GleapMetaDataManager","getSessionDuration","events","opened","handleOpenBound","handleOpen","handleErrorBound","handleError","handleMessageBound","handleMessage","handleCloseBound","handleClose","connectionTimeout","pingWS","clearInterval","close","cleanupWebSocket","connectedWebSocketGleapId","WebSocket","wsApiUrl","setInterval","processMessage","initWebSocket","GleapAdminManager","_ai$e","_message$data","ai","listOfActionsWhereIgnoreOpened","filteredActions","_action$actionType","actionType","Gleap","performActions","setConfig","placeholder","quickActions","agentName","_checklistData$comple","_checklistData$comple2","checklistData","completedSteps","completedStepsBefore","_loop","_checklistData$steps","steps","stepIndex","checklistId","stepId","detail","eventArray","cleanupMainLoop","trackInitialEvents","startPageListener","resetErrorCountLoop","logEvent","logCurrentPage","disablePageTracking","log","eventMaxLength","parseIntWithDefault","val","def","onConfigLoaded","onConfigLoadedListener","cachedConfig","applyConfig","loadConfigFromServer","clearGleapCache","setStyles","headerColor","buttonColor","backgroundColor","borderRadius","buttonX","buttonY","applyStylesFromConfig","sendConfigUpdate","enableWebReplays","GleapReplayRecorder","enableNetworkLogs","setLoadAllResources","sendNetworkResources","networkLogPropsToIgnore","setFilters","networkLogBlacklist","setBlacklist","updateRTLSupport","enableShortcuts","aiBar","notifyConfigLoaded","_asyncToGenerator","documentToHTML","doctype","publicId","systemId","outerHTML","loadCSSUrlResources","basePath","remote","asyncFn","matchedData","matchedUrl","replaceAll","resourcePath","URL","fetchCSSResource","resourceData","promises","_len","_key","promise","all","onloadend","readAsDataURL","fetchItemResource","isBlacklisted","warn","progressResource","replaceStyleNodes","styleSheet","cssTextContent","styleId","cloneTargetNode","ownerNode","replacementNode","head","styleNode","cssText","createTextNode","linkNode","rel","media","getTextContentFromStyleSheet","cssRules","cssRuleItem","depth","sanitizeCSSBraces","downloadAllCSSUrlResources","basePathURL","styleSheets","mediaText","baseTags","getElementsByTagName","origin","lastIndexOf","replacedStyle","styletext","stylesheet","results","prepareRemoteData","dom","imgItems","imgItemsPromises","item","downloadAllImages","handleAdoptedStyleSheets","shadowNodeId","adoptedStyleSheets","shadowStyleNode","firstElementChild","extractFinalCSSState","getAnimations","animations","finalCSSState","animation","_animation$effect","keyframes","effect","getKeyframes","finalKeyframe","property","deepClone","_callee3","cloneNode","fragment","clonedHead","_context3","_ref2","_callee2","shadowRoot","walkTree","webAnimations","boundingRect","resizedImage","_boundingRect","rootShadowNodeId","_context2","_ref3","nextn","nextp","innerShadowRoot","nextElementSibling","_x5","_x6","_x7","HTMLCanvasElement","toUpperCase","contains","checked","createDocumentFragment","prepareScreenshotData","_ref4","_callee4","styleTags","linkImportElems","referenceNode","scriptElems","existingBasePath","baseElems","baseUrl","newBaseUrl","baseNode","dialogElems","bbElems","_context4","innerWidth","innerHeight","_x8","_x9","GleapScreenRecorder","rerender","permissionErrorText","MAX_RECORD_TIME","mediaDevices","getDisplayMedia","available","RERENDER_DELAY","_uploadScreenRecording","_startAudioRecording","_startScreenRecording","MIME_TYPES","MediaRecorder","isTypeSupported","getTracks","track","_","tracks","validTracks","MediaStream","videoTracks","getVideoTracks","audioTracks","getAudioTracks","displayStream","composed","isRecording","video","ideal","screen","frameRate","IDEAL_FRAME_RATE","MAX_FRAME_RATE","displaySurface","audio","selfBrowserSurface","_displayStream","_displayVideoTrack","getFirstVideoTrack","audioMuted","startAudioRecording","audioAvailable","createMediaStream","handleRecord","alert","mediaRecorder","recordingTimer","stopStreamTracks","_micStream","voiceStream","micTrack","_composed","getUserMedia","echoCancellation","noiseSuppression","autoGainControl","getFirstAudioTrack","videoEl","SELECTORS","PREVIEW_VIDEO","file","recordedChunks","mimeType","getSupportedMimeType","recordTime","timerLabel","TIMER_LABEL","remainingTime","maxRecordTime","formatTime","stopScreenRecording","TIMER_UPDATE_INTERVAL","ondataavailable","videoTrack","onended","prepareRecording","onstop","CHUNK_INTERVAL","completeBlob","extension","File","previewVideoElement","createObjectURL","screenRecordingData","formData","FormData","append","fileUrl","GleapFeedback","priority","isSilent","excludeData","spamToken","gleapInstance","GleapCustomDataManager","getCustomData","metaData","getMetaData","consoleLog","GleapConsoleLogManager","getLogs","networkLogs","getRequests","customEventLog","getEventArray","ticketAttributes","getTicketAttributes","dataPromises","webReplay","getGlobalDataItem","isLiveSite","recordingUrlPromise","uploadScreenRecording","recordingUrl","screenRecordingUrl","screenshot","screenshotDataPromise","isLiveMode","screenshotData","snapshotPosition","feedbackData","outbound","tags","GleapTagManager","getTags","keysToExclude","keyToExclude","takeSnapshot","getData","feedback","setGlobalDataItem","takeCurrentReplay","eventListeners","eventListener","eventName","GleapAgentToolManager","tools","agentTools","agentToolCallbacks","cb","newTab","newWindow","focus","cmp_block_ignoredomains","injectedFrame","autoWhiteListCookieManager","frameUrl","gleapFrameContainer","gleapFrame","updateFrameStyle","showFrameContainer","closeElement","surveyStyle","extendedStyle","surveyFullStyle","classicStyle","classicStyleLeft","modernStyleLeft","noButtonStyleLeft","allStyles","styleToApply","startCommunication","appHeight","setProperty","handler","urlHandler","innerContainer","escListener","widgetOpened","markerManager","showLoader","_this$gleapFrameConta","loadingClass","disableBGFade","disableBGGradient","_this3$gleapFrameCont","updateUI","workThroughQueue","updateWidgetStatus","registerEscListener","isSurvey","updateNotificationBadge","runWidgetShouldOpenCallback","injectFrame","isWidgetOpen","resetRoutes","hideMarkerManager","reloadNotificationsFromCache","unregisterEscListener","queue","comReady","contentWindow","postMessage","getSession","aiTools","getAgentTools","overrideLanguage","getOverrideLanguage","GleapMarkerManager","success","workQueue","_this6","addMessageListener","GleapAudioManager","ping","showImage","ticketData","frameHeight","_data$data","startProductTour","GleapCustomActionManager","triggerCustomAction","shareToken","triggerToolAction","_checklistData$outbou","_checklistData$outbou2","_data$data2","_checklistData2$outbo","sendingFeedback","feedbackType","sendFeedback","reportedBy","trackEvent","showDrawingScreen","bannerUrl","listeners","appVersionCode","appBuildNumber","sessionStart","nameOffset","verOffset","ix","nAgt","browserName","appName","fullVersion","appVersion","majorVersion","OSName","browser","systemName","buildVersionNumber","releaseVersionNumber","devicePixelRatio","screenWidth","screenHeight","language","userLanguage","sdkType","environment","logArray","disabled","originalConsoleLog","logLevel","logMaxLength","addLog","origConsole","addLogWithArgs","GleapClickListener","protocol","preventDefault","handleGleapLink","elementId","elementClass","elemId","elemClass","elementTag","htmlPre","htmlPost","getDOMElementDescription","customAction","customActionCallbacks","_a","__defProp","__publicField","__defNormalProp","__defProp$1","__publicField$1","__defNormalProp$1","NodeType$3","NodeType2","testableAccessors$1","testableMethods$1","untaintedBasePrototype$1","isAngularZonePresent$1","globalThis","Zone","getUntaintedPrototype$1","defaultObj","defaultPrototype","accessorNames","isUntaintedAccessors","accessor","_a2","_b","methodNames","isUntaintedMethods","iframeEl","untaintedObject","removeChild","untaintedAccessorCache$1","getUntaintedAccessor$1","untaintedPrototype","untaintedAccessor","untaintedMethodCache$1","getUntaintedMethod$1","untaintedMethod","index$1","n2","parentElement","textContent","other","getRootNode","selectors","mutationObserver","patch","source","replacement","original","wrapped","__rrweb_original__","hostEl","isNativeShadowDom","shadowRoot2","stringifyStylesheet","s2","rules2","sheetHref","baseURI","stringifiedRules","rule2","stringifyRule","isCSSImportRule","importStringified","statement","layerName","supportsText","escapeImportStatement","absolutifyURLs","ruleStringified","isCSSStyleRule","selectorText","cssStringified","fixSafariColons","Mirror","getId","getMeta","getNode","idNodeMap","getIds","nodeMetaMap","removeNodeFromMap","delete","hasNode","node2","meta","oldNode","maskInputValue","maskInputOptions","maskInputFn","actualType","repeat","ORIGINAL_ATTRIBUTE_NAME","getInputType","extractFileExtension","path","baseURL","pathname","URL_IN_CSS_REF","URL_PROTOCOL_MATCH","URL_WWW_MATCH","DATA_URI","quote1","path1","quote2","path2","path3","filePath","maybeQuote","extractOrigin","stack","part","normalizeCssString","_testNoPxNorm","markCssSplits","childNodes2","splits","iterCount","cssTextNorm","normFactor","i2","textContentNorm","jLimit","startSubstring","cssNormSplits","splitNorm","prevTextContent","prevMinLength","normPart","splitCssText","_id","tagNameRegex","IGNORED_NODE","genId","canvasService","canvasCtx","SRCSET_NOT_SPACES","SRCSET_COMMAS_OR_SPACES","cachedDocument","absoluteToDoc","attributeValue","getHref","isSVGElement","ownerSVGElement","customHref","a2","transformAttribute","pos","collectCharacters","regEx","chars2","exec","output","descriptorsStr","inParens","c2","getAbsoluteSrcsetString","ignoreAttribute","_value","classMatchesRegex","checkAncestors","eIndex","needMaskingText","maskTextClass","maskTextSelector","closest","e2","serializeNode","mirror","mirror2","blockClass","blockSelector","needsMask","inlineStylesheet","maskTextFn","dataURLOptions","inlineImages","recordCanvas","keepIframeSrcFn","newlyAddedElement","cssCaptured","rootId","docId","getRootId","DOCUMENT_NODE","Document","DOCUMENT_TYPE_NODE","DocumentType","needBlock","_isBlockedElement","HTMLFormElement","processedTagName","getValidTagName$1","attr","_cssText","sheet","selected","rr_open_mode","__context","ctx","x2","getImageData","originalGetImageData","Uint32Array","pixel","is2DCanvasBlank","rr_dataURL","quality","canvasDataURL","blankCanvas","image","imageSrc","currentSrc","priorCrossOrigin","crossOrigin","recordInlineImage","naturalWidth","naturalHeight","mediaAttributes","rr_mediaState","paused","rr_mediaCurrentTime","currentTime","rr_mediaPlaybackRate","playbackRate","rr_mediaMuted","muted","rr_mediaLoop","loop","rr_mediaVolume","volume","rr_scrollLeft","rr_scrollTop","class","rr_width","rr_height","contentDocument","rr_src","isCustomElement","customElements","isSVG","isCustom","serializeElementNode","TEXT_NODE","parentTagName","textContent2","isStyle","isScript","Text","serializeTextNode","CDATA_SECTION_NODE","CDATA","COMMENT_NODE","Comment","lowerIfExists","maybeAttr","slimDOMDefaults","_slimDOMOptions","script","comment","headFavicon","headWhitespace","headMetaSocial","headMetaRobots","headMetaHttpEquiv","headMetaVerification","headMetaAuthorship","headMetaDescKeywords","headTitleMutations","serializeNodeWithId","skipChild","slimDOMOptions","onSerialize","onIframeLoad","iframeLoadTimeout","onStylesheetLoad","stylesheetLoadTimeout","preserveWhiteSpace","_serializedNode","sn","as","slimDOMExcluded","serializedNode","recordChild","shadowRootEl","isShadowHost","bypassOptions","childN","serializedChildNode","isShadow","listener","fired","timer","blankUrl","onceIframeLoaded","iframeDoc","serializedIframeNode","link","styleSheetLoadTimeout","styleSheetLoaded","onceStylesheetLoaded","serializedLinkNode","getDefaultExportFromCjs$1","__esModule","getAugmentedNamespace$1","f2","default","a22","Reflect","construct","picocolors_browser$1","x$1","create$1","isColorSupported","bold","dim","italic","underline","inverse","hidden","strikethrough","black","red","green","yellow","blue","magenta","cyan","white","gray","bgBlack","bgRed","bgGreen","bgYellow","bgBlue","bgMagenta","bgCyan","bgWhite","createColors","picocolors_browserExports$1","require$$2$1","freeze","pico$1","terminalHighlight$1$1","CssSyntaxError$3$1","CssSyntaxError","column","plugin22","super","reason","plugin","endLine","endColumn","setMessage","captureStackTrace","showSourceCode","aside","index2","number","gutter","spacing","code","cssSyntaxError$1","symbols$1","isClean","my","DEFAULT_RAW$1","after","beforeClose","beforeComment","beforeDecl","beforeOpen","beforeRule","colon","commentLeft","commentRight","emptyBody","indent","semicolon","Stringifier$2$1","builder","atrule","raws","afterName","nodes","block","between","beforeAfter","detect","raw","buf","last","child","before","decl","string","important","own","first","root2","rawCache","walk","rawBeforeClose","rawBeforeComment","walkComments","rawBeforeDecl","walkDecls","rawBeforeOpen","rawBeforeRule","rawColon","rawEmptyBody","rawIndent","rawSemicolon","rule","ownSemicolon","stringifier$1","Stringifier$1$1","stringify$4$1","stringify_1$1","isClean$2$1","my$2$1","CssSyntaxError$2$1","Stringifier2$1","stringify$3$1","cloneNode$1","cloned","Node$4$1","defaults","addToError","postcssNode","input","insertAfter","overrides","cleanRaws","keepBetween","cloneAfter","cloneBefore","opts","rangeBy","getProxyProcessor","toProxy","markDirty","positionBy","stringRepresentation","positionInside","word","endIndex","defaultType","replaceWith","bookmark","foundSelf","result2","toJSON","inputs","fixed","emitInputs","inputsNextIndex","inputId","input2","proxyCache","Proxy","stringifier2","proxyOf","node$1","Node$3$1","Declaration$4$1","variable","declaration$1","nonSecure$1","nanoid","random","customAlphabet","alphabet","defaultSize","SourceMapConsumer","SourceMapConsumer$2$1","SourceMapGenerator","SourceMapGenerator$2$1","existsSync","existsSync$1","readFileSync","readFileSync$1","dirname","dirname$1$1","join$1","PreviousMap$2$1","loadAnnotation","inline","startWith","annotation","loadMap","mapFile","consumer","consumerCache","decodeInline","lastMatch","Buffer","atob","encoding","getAnnotationURL","sourceMapString","isMap","mappings","_mappings","sections","comments","loadFile","fromSourceMap","prevPath","withContent","sourcesContent","previousMap$1","SourceMapConsumer$1$1","SourceMapGenerator$1$1","fileURLToPath","fileURLToPath$1","pathToFileURL","pathToFileURL$1$1","isAbsolute","isAbsolute$1","resolve$1$1","nanoid$2","terminalHighlight$2","CssSyntaxError$1$1","PreviousMap$1$1","fromOffsetCache$1","sourceMapAvailable$1$1","pathAvailable$1$1","Input$4$1","hasBOM","mapResolve","fromOffset","lastLine","lineToIndex","prevIndex","l2","mid","sourceRoot","to","fromUrl","originalPositionFor","sourceContentFor","json","input$1","registerInput","SourceMapConsumer$3","SourceMapGenerator$3","dirname$2","relative","relative$1","resolve$2","sep","sep$1","pathToFileURL$2","Input$3$1","sourceMapAvailable$2","pathAvailable$2","mapGenerator$1","stringify2","cssString","mapOpts","originalCSS","usesFileUrls","absolute","memoizedFileURLs","memoizedPaths","memoizedURLs","addAnnotation","content","isInline","toBase64","outputFile","eol","applyPrevMaps","previous","toUrl","applySourceMap","clearAnnotation","generate","generateMap","generateString","ignoreInvalidMapping","addMapping","generated","isSourcesContent","setSourcesContent","isAnnotation","noSource","mapping","sourcePath","charCodeAt","previousMaps","already","toFileUrl","setSourceContent","btoa","unescape","fileURL","Node$2$1","Comment$4$1","comment$1","parse$4$1","Rule$4$1","AtRule$4$1","Root$6$1","isClean$1$1","my$1$1","Declaration$3$1","Comment$3$1","Node$1$1","cleanSource$1","markDirtyUp$1","Container$7$1","Container","children","normalize","each","getIterator","indexes","condition","lastEach","exist","existIndex","splice","sample","rebuild","prepend","unshift","removeAll","replaceValues","pattern","fast","walkAtRules","walkRules","registerParse","dependant","registerRule","registerAtRule","registerRoot","container$1","LazyResult$4$1","Processor$3$1","Container$6$1","Document$3$1","toResult","registerLazyResult","registerProcessor","document$1$1","Warning$2$1","opt","warning$1","Warning$1$1","Result$3$1","processor2","processor","lastPlugin","postcssPlugin","warning2","warnings","result$1","SINGLE_QUOTE$1","DOUBLE_QUOTE$1","BACKSLASH$1","SLASH$1","NEWLINE$1","SPACE$1","FEED$1","TAB$1","CR$1","OPEN_SQUARE$1","CLOSE_SQUARE$1","OPEN_PARENTHESES$1","CLOSE_PARENTHESES$1","OPEN_CURLY$1","CLOSE_CURLY$1","SEMICOLON$1","ASTERISK$1","COLON$1","AT$1","RE_AT_END$1","RE_WORD_END$1","RE_BAD_BRACKET$1","RE_HEX_ESCAPE$1","Container$5$1","AtRule$3$1","atRule$1","LazyResult$3$1","Processor$2$1","Container$4$1","Root$5$1","ignore","root$1","list$2$1","comma","space","separators","array","current","func","inQuote","prevQuote","escape","letter","list_1$1","Container$3$1","list$1$1","Rule$3$1","sep2","rule$1","Declaration$2$1","tokenizer2$1","quote","escaped","escapePos","currentToken","valueOf","ignoreErrors","returned","unclosed","what","back","token","endOfFile","nextToken","ignoreUnclosed","controlChar","fromCharCode","lastIndex","Comment$2$1","AtRule$2$1","Root$4$1","Rule$2$1","SAFE_COMMENT_NEIGHBOR$1","empty","parser$1","spaces","createTokenizer","unnamedAtrule","init","brackets","tokenizer","getPosition","spacesAndCommentsFromEnd","spacesAndCommentsFromStart","checkMissedSemicolon","tokens","founded","doubleColon","customProperty","findLastWithPosition$1","unknownWord","firstSpaces","precheckMissedSemicolon","stringFrom","spacesFromEnd","emptyRule","unexpectedClose","endFile","unclosedBlock","freeSemicolon","bracket","unclosedBracket","clean","lastTokenType","Container$2$1","Parser2$1","Input$2$1","parse$3$1","parser2","parse_1$1","isClean$3","my$3","MapGenerator$1$1","stringify$2$1","Container$1$1","Document$2$1","Result$2$1","parse$2$1","Root$3$1","TYPE_TO_CLASS_NAME$1","PLUGIN_PROPS$1","AtRule","AtRuleExit","CommentExit","Declaration","DeclarationExit","DocumentExit","Once","OnceExit","prepare","Root","RootExit","Rule","RuleExit","NOT_VISITORS$1","CHILDREN$1","isPromise$1","getEvents$1","toStack$1","eventIndex","visitorIndex","visitors","cleanMarks$1","postcss$2$1","LazyResult$2$1","LazyResult","stringified","processed","syntax","parser","helpers","postcss","plugins","processing","runAsync","onRejected","catch","onFinally","getAsyncError","postcssVersion","prepareVisitors","version","hasListener","runOnRoot","visitTick","visitor","roots","subRoot","sync","stringifier","walkSync","visitSync","onFulfilled","visit2","registerPostcss","lazyResult$1","MapGenerator2$1","stringify$1$1","parse$1$1","Result$1$1","NoWorkResult$1$1","_processor","_css","_opts","_map","generatedCSS","generatedMap","_root","noWorkResult$1","NoWorkResult2$1","LazyResult$1$1","Document$1$1","Root$2$1","Processor$1$1","normalized","process","use","processor$1","Declaration$1$1","PreviousMap2$1","Comment$1$1","AtRule$1$1","Input$1$1","Root$1$1","Rule$1$1","fromJSON$1$1","ownInputs","inputHydrated","fromJSON_1$1","CssSyntaxError2$1","Declaration2$1","LazyResult2$1","Container2$1","Processor2$1","stringify$5","fromJSON$2","Document22","Warning2$1","Comment2$1","AtRule2$1","Result2$1","Input2$1","parse$5","list$3","Rule2$1","Root2$1","Node2$1","postcss$3","initializer","warningPrinted","creator","env","LANG","transformer","processOpts","pluginOpts","fromJSON","atRule","Processor","Warning","Result","Input","postcss_1$1","postcss$1$1","__defProp2","__publicField2","__defNormalProp2","getDefaultExportFromCjs","getAugmentedNamespace","picocolors_browser","picocolors_browserExports","require$$2","pico","terminalHighlight$1","CssSyntaxError$3","CssSyntaxError2","cssSyntaxError","symbols","DEFAULT_RAW","Stringifier$2","Stringifier$1","stringify$4","stringify_1","isClean$2","my$2","CssSyntaxError$2","Stringifier22","stringify$3","Node$4","Node$3","Declaration$4","declaration","nonSecure","SourceMapConsumer$2","SourceMapGenerator$2","dirname$1","PreviousMap$2","previousMap","SourceMapConsumer$1","SourceMapGenerator$1","pathToFileURL$1","resolve$1","terminalHighlight","CssSyntaxError$1","PreviousMap$1","fromOffsetCache","sourceMapAvailable$1","pathAvailable$1","Input$4","Input$3","sourceMapAvailable","pathAvailable","mapGenerator","Node$2","Comment$4","parse$4","Rule$4","AtRule$4","Root$6","isClean$1","my$1","Declaration$3","Comment$3","Node$1","cleanSource","markDirtyUp","Container$7","Container2","container","LazyResult$4","Processor$3","Container$6","Document$3","document$1","Warning$2","warning","Warning$1","Result$3","SINGLE_QUOTE","DOUBLE_QUOTE","BACKSLASH","SLASH","NEWLINE","SPACE","FEED","TAB","CR","OPEN_SQUARE","CLOSE_SQUARE","OPEN_PARENTHESES","CLOSE_PARENTHESES","OPEN_CURLY","CLOSE_CURLY","SEMICOLON","ASTERISK","COLON","AT","RE_AT_END","RE_WORD_END","RE_BAD_BRACKET","RE_HEX_ESCAPE","Container$5","AtRule$3","LazyResult$3","Processor$2","Container$4","Root$5","list$2","list_1","Container$3","list$1","Rule$3","Declaration$2","tokenizer22","Comment$2","AtRule$2","Root$4","Rule$2","SAFE_COMMENT_NEIGHBOR","findLastWithPosition","Container$2","Parser22","Input$2","parse$3","parse_1","MapGenerator$1","stringify$2","Container$1","Document$2","Result$2","parse$2","Root$3","TYPE_TO_CLASS_NAME","PLUGIN_PROPS","NOT_VISITORS","CHILDREN","isPromise","getEvents","toStack","cleanMarks","postcss$2","LazyResult$2","LazyResult2","lazyResult","MapGenerator22","stringify$1","parse$1","Result$1","NoWorkResult$1","noWorkResult","NoWorkResult22","LazyResult$1","Document$1","Root$2","Processor$1","Declaration$1","PreviousMap22","Comment$1","AtRule$1","Input$1","Root$1","Rule$1","fromJSON$1","fromJSON_1","CssSyntaxError22","Declaration22","LazyResult22","Container22","Processor22","Document222","Warning22","Comment22","AtRule22","Result22","Input22","Rule22","Root22","Node22","postcss_1","postcss$1","BaseRRNode","_args","childIterator","_newChild","_refChild","_node","testableAccessors","testableMethods","untaintedBasePrototype","isAngularZonePresent","getUntaintedPrototype","untaintedAccessorCache","getUntaintedAccessor","untaintedMethodCache","getUntaintedMethod","mutationObserverCtor","on","capture","DEPARTED_MIRROR_ACCESS_WARNING","_mirror","throttle","wait","leading","remaining","trailing","hookSetter","isRevoked","receiver","nowTimestamp","getWindowScroll","_d","scrollingElement","pageXOffset","pageYOffset","getWindowHeight","getWindowWidth","closestElementOfNode","isBlocked","isIgnored","isAncestorRemoved","legacy_isTouchEvent","changedTouches","isSerializedIframe","isSerializedStylesheet","hasShadowRoot","StyleSheetMirror","styleIDMap","newId","idStyleMap","getStyle","generateId","getShadowHost","shadowHost","DOCUMENT_FRAGMENT_NODE","shadowHostInDom","rootShadowHost","getRootShadowHost","inDom","EventType","EventType2","IncrementalSource","IncrementalSource2","MouseInteractions","MouseInteractions2","PointerTypes","PointerTypes2","CanvasContext","CanvasContext2","MediaInteractions","MediaInteractions2","NodeType","isNodeInLinkedList","DoubleLinkedList","addNode","__ln","previousSibling","tail","removeNode","moveKey","parentId","MutationBuffer","processMutation","emit","frozen","locked","adds","addedIds","addList","getNextId","ns","pushAdd","parentTag","addedSet","currentN","iframeManager","addIframe","stylesheetManager","trackLinkElement","shadowDomManager","addShadowRoot","iframe","childSn","attachIframe","observeAttachShadow","attachLinkElement","mapRemoves","movedSet","isParentRemoved","removesSubTreeCache","isAncestorInSet","droppedSet","candidate","tailNode","unhandledNode","texts","genTextAreaValueMutation","attribute","diffAsStr","styleDiff","unchangedAsStr","_unchangedStyles","removes","attributeMap","movedMap","mutationCb","textarea","cn","m","oldValue","attributeName","unattachedDoc","implementation","createHTMLDocument","old","pname","newValue","getPropertyValue","newPriority","getPropertyPriority","genAdds","nodeId","isSerialized","deepDelete","n22","processRemoves","processedNodeManager","inOtherBuffer","targetId","canvasManager","unfreeze","isFrozen","lock","unlock","addsSet","_mirror2","_isParentRemoved","_isAncestorInSet","errorHandler","callbackWrapper","rest","mutationBuffers","getEventTarget","composedPath","initMutationObserver","rootEl","mutationBuffer","processMutations","attributeOldValue","characterData","characterDataOldValue","initMouseInteractionObserver","mouseInteractionCb","sampling","mouseInteraction","disableMap","handlers","currentPointerType","eventKey","pointerType","thisEventKey","Mouse","Touch","Pen","MouseDown","MouseUp","Click","clientX","clientY","getHandler","PointerEvent","TouchStart","TouchEnd","initScrollObserver","scrollCb","scrollLeftTop","INPUT_TAGS","lastInputValueMap","getNestedCSSRulePositions","childRule","hasNestedCSSRule","parentRule","CSSGroupingRule","CSSMediaRule","CSSSupportsRule","CSSConditionRule","parentStyleSheet","recurse","getIdAndStyleId","styleMirror","initAdoptedStyleSheetObserver","host2","hostId","patchTarget","originalPropertyDescriptor","_a3","sheets","adoptStyleSheets","initObservers","o2","hooks","currentWindow","mousemoveCb","viewportResizeCb","inputCb","mediaInteractionCb","styleSheetRuleCb","styleDeclarationCb","canvasMutationCb","fontCb","selectionCb","customElementCb","mousemove","viewportResize","mediaInteaction","styleSheetRule","styleDeclaration","canvasMutation","font","selection","customElement","mergeHooks","recordDOM","mousemoveHandler","callbackThreshold","mousemoveCallback","timeBaseline","positions","wrappedCb","totalOffset","timeOffset","updatePosition","DragEvent","Drag","MouseEvent","MouseMove","TouchMove","initMoveObserver","mouseInteractionHandler","scrollHandler","viewportResizeHandler","lastH","lastW","initViewportResizeObserver","inputHandler","ignoreClass","ignoreSelector","userTriggeredOnInput","eventHandler","userTriggered","isTrusted","isChecked","cbWithDedup","text2","v2","lastInputValue","propertyDescriptor","HTMLInputElement","hookProperties","HTMLSelectElement","HTMLTextAreaElement","HTMLOptionElement","initInputObserver","mediaInteractionHandler","Play","Pause","Seeked","VolumeChange","RateChange","initMediaInteractionObserver","styleSheetObserver","adoptedStyleSheetObserver","styleDeclarationObserver","fontObserver","CSSStyleSheet","insertRule","thisArg","argumentsList","addRule","styleBlock","deleteRule","replaceSync","removeRule","supportedNestedCSSRuleTypes","canMonkeyPatchNestedCSSRule","unmodifiedFunctions","typeKey","initStyleSheetObserver","ignoreCSSAttributes","CSSStyleDeclaration","removeProperty","initStyleDeclarationObserver","collectFonts","fontMap","originalFontFace","FontFace","family","descriptors","fontFace","fontSource","Uint8Array","restoreHandler","fonts","initFontObserver","selectionObserver","collapsed","updateSelection","getSelection","isCollapsed","ranges","rangeCount","getRangeAt","startContainer","startOffset","endContainer","endOffset","initSelectionObserver","customElementObserver","initCustomElementObserver","pluginHandlers","plugin3","CrossOriginIframeMirror","generateIdFn","remoteId","idToRemoteMap","remoteToIdMap","idToRemoteIdMap","getIdToRemoteIdMap","remoteIdToIdMap","getRemoteIdToIdMap","getRemoteId","getRemoteIds","ids","iframeIdToRemoteIdMap","iframeRemoteIdToIdMap","IframeManager","wrappedEmit","recordCrossOriginIframes","crossOriginIframeStyleMirror","iframes","crossOriginIframeMap","addLoadListener","loadListener","isAttachIframe","crossOriginMessageEvent","transformedEvent","transformCrossOriginEvent","isCheckout","FullSnapshot","crossOriginIframeMirror","replaceIdOnNode","crossOriginIframeRootIdMap","patchRootIdOnNode","timestamp","IncrementalSnapshot","Mutation","Meta","Load","DomContentLoaded","Plugin","Custom","replaceIds","ViewportResize","MediaInteraction","MouseInteraction","Scroll","CanvasMutation","StyleSheetRule","StyleDeclaration","replaceStyleIds","Font","Selection","AdoptedStyleSheet","styles","iframeMirror","ShadowDomManager","WeakSet","patchAttachShadow","shadowDoms","restoreHandlers","iframeElement","manager","option","sRoot","chars","lookup","i$1","canvasVarMap","saveWebGLVar","isInstanceOfWebGLObject","list2","ctor","contextMap","variableListFor$1","serializeArg","Float32Array","Float64Array","Int32Array","Uint16Array","Int16Array","Int8Array","Uint8ClampedArray","rr_type","base64","arraybuffer","bytes","DataView","byteOffset","byteLength","HTMLImageElement","ImageData","serializeArgs","supportedWebGLConstructorNames","initCanvasContextObserver","setPreserveDrawingBufferToTrue","contextType","ctxName","getNormalizedContextName","contextAttributes","preserveDrawingBuffer","patchGLPrototype","getOwnPropertyNames","recordArgs","hookHandler","setter","encodedJs","WorkerWrapper","objURL","webkitURL","worker","Worker","revokeObjectURL","CanvasManager","latestId","invokeId","rafStamps","pendingCanvasMutations","initCanvasMutationObserver","initCanvasFPSObserver","resetObservers","fps","canvasContextReset","snapshotInProgressMap","onmessage","commands","timeBetweenSnapshots","rafId","lastSnapshotTime","takeCanvasSnapshots","matchedCanvas","getCanvas","getContextAttributes","COLOR_BUFFER_BIT","bitmap","createImageBitmap","startRAFTimestamping","startPendingCanvasMutationFlusher","canvas2DReset","props2D","CanvasRenderingContext2D","initCanvas2DMutationObserver","canvasWebGL1and2Reset","WebGLRenderingContext","WebGL","WebGL2RenderingContext","WebGL2","initCanvasWebGLMutationObserver","flushPendingCanvasMutations","setLatestRAFTimestamp","_values","flushPendingCanvasMutationFor","valuesWithType","type2","StylesheetManager","adoptedStyleSheetCb","linkEl","trackedLinkElements","trackStylesheetInLinkElement","adoptedStyleSheetData","styleIds","CSSRule","r2","_linkEl","ProcessedNodeManager","thisBuffer","buffers","nodeMap","active","takeFullSnapshot$1","recording","cleanFrame","debug","record","checkoutEveryNms","checkoutEveryNth","maskAllInputs","_maskInputOptions","packFn","mousemoveWait","recordAfter","errorHandler2","inEmittingFrame","passEmitsToParent","month","search","tel","week","select","password","lastFullSnapshotEvent","NodeList","DOMTokenList","polyfill$1","incrementalSnapshotCount","eventProcessor","exceedCount","exceedTime","wrappedMutationEmit","wrappedScrollEmit","wrappedCanvasMutationEmit","getMirror","nodeMirror","slimDOM","snapshot","initialOffset","CustomElement","t2","addCustomEvent","tag","freezePage","takeFullSnapshot","NotStarted","Running","Stopped","customOptions","stopFunction","ContextMenu","DblClick","Focus","Blur","rrwebEvent","stringifiedData","dataURIRegex","matchAll","ensureMaxMessageSize","bufferSize","ScreenDrawer","svgElement","minHeight","mouseDown","colorpicker","fadeOutToolbar","tool","mouseDownPen","mouseDownRect","mouseMove","mouseMovePen","mouseMoveRect","mouseUp","fadeInToolbar","mouseUpPen","mouseUpRect","appendToBuffer","getMousePosition","updateSvgPath","w","startPoint","setAttributeNS","createElementNS","strokeWidthRect","appendPathToSvg","strokeWidth","pt","strPath","touches","totalX","totalY","getAveragePoint","tmpPath","pathBuffer","fadeTarget","GleapScrollStopper","supportsPassive","wheelOpt","scrollDisabled","wheelEvent","preventDefaultForScrollKeys","keyCode","showWidgetUI","formKey","dirty","dialogUI","enableScroll","screenRecorder","unregisterListeners","cleanupMousePointer","screenDrawer","dialog","captureSVG","videoPreviewContainer","dismissUI","colorPicker","borderLayer","captureEditor","dragCursor","setMouseMove","mouseMoveEventHandler","touchMoveEventHandler","dragHandle","dragStart","drag","dragEnd","bugReportingEditor","translateText","pageLeaveListener","isEscape","isEnter","dismiss","showNextStep","returnValue","registerListeners","hideWidgetUI","createEditorUI","setupMousePointer","disableScroll","setupScreenRecording","captureScreenDrawerRerender","setupColorPicker","setupToolbar","selectedColor","colorItems","colorItem","hexColor","onclick","setColor","setPenColor","currentX","currentY","initialX","initialY","toolbar","isDragging","xOffset","yOffset","_getTransformValues","matrix","DOMMatrix","m41","m42","getTransformValues","nextButton","chooseTool","toolbarItem","toolbarTools","setTool","svgClone","toolbarItems","_loop2","toggleAudio","startScreenRecording","removeLastAddedPathFromSvg","itemInactiveClass","screenRecordingTooltip","audioRecordingTooltip","recordingClass","notRecordingClass","clearPreview","captureRenderer","penTips","fill","staticTranslation","staticTranslations","vars","template","localizationOptions","htmlLang","GleapShortcutListener","shortCutListener","char","keyIdentifier","ctrlKey","startFeedbackFlowWithOptions","autostartDrawing","GleapPreFillManager","unreadCount","notificationContainer","notificationsFromCache","unreadNotificationsKey","nots","notification","createdAt","notifications","renderNotifications","updateTabBarNotificationCount","sound","clearElem","currentNewsIndex","newsNotifications","news","otherNotifications","currentIndex","currentNews","newsElem","newsContainerElem","coverImageUrl","newsImageElem","stopPropagation","openNews","newsContentElem","newsTitleElem","getName","descHTML","renderDescription","descElem","paginationElem","pageIndicator","nextBtn","conversation","openConversation","checklist","openChecklist","progress","currentStep","totalSteps","nextStepTitle","sender","profileImageUrl","openNewsArticle","_notification$data","previewText","uiOnly","classLeft","classNoButton","_listenForMessages","_listenForOutsideClicks","chatbarContainer","_suppressOutsideClick","_postMessage","chatbarUrl","iframeReady","_sendChatbarData","_flushPendingMessages","_resizeFrame","_updateBlurBackdrop","_this$chatbarFrame","chatbarFrame","pendingMessages","queued","msg","_flowConfig","_this$config","_this$config2","_this$config3","_flowConfig2","_session$session","_session$session2","defaultAgentName","primaryColor","ceil","isHidden","visible","blurBackdrop","manuallyShown","_this$config4","manuallyHidden","_preloadIframe","_removeUI","openPanel","resolvedAgentId","_resolveAgentId","agentContext","messageData","initialMessage","messageName","_sendAgentCommand","_injectUI","frame","title","_this$bannerUrl","_this$bannerData","_data$data3","_data$data4","_data$data5","_data$data6","_data$data7","_data$data8","_data$data9","_data$data10","bannerData","format","startBot","botId","startFeedbackFlow","formId","showSurvey","surveyFormat","articleId","openHelpCenterArticle","startChecklist","bannerContainer","gleapBFrame","injectBannerUI","modalUrl","_this$modalUrl","_data$data11","modalData","modalContainer","wrapper","modalBackdropClickListener","_this2$modalData$show","_this2$modalData","showCloseButton","_injectModalUI","play","settings","Audio","playPromise","getID","getClassSelectors","getClasses","cl","kCombinations","items","getNthChild","sibling","counter","getTag","isUnique","elems","getAllSelectors","attributesToIgnore","funcs","Tag","NthChild","Attributes","sum","getAttributes","Class","ID","res","testUniqueness","getFirstUnique","getUniqueCombination","combinations","getCombinations","firstUnique","combination","getUniqueSelector","selectorTypes","excludeRegex","foundSelector","elementSelectors","selectorType","Classes","unique","_options$selectorType","_options$attributesTo","_options$excludeRegex","allSelectors","parents","currentElement","getParents","_i","_allSelectors","ElementOverlay","overlay","background","borderColor","borderStyle","borderWidth","boxSizing","cursor","zIndex","margin","shadowContainer","attachShadow","_createClass","useShadowDOM","usingShadowDOM","setBounds","bounds","ElementPicker","overlayOptions","handleMouseMove","handleClick","tick","addToDOM","removeFromDOM","mouseX","mouseY","tickReq","clickedEl","elementFromPoint","elementFilter","stopImmediatePropagation","onClick","updateTarget","ignoreCursor","newTarget","captureCursor","onHover","GleapAdminHelper","picker","stopPicker","onElementPicked","startPicker","COLLAPSE_UI_ACTIVE_CLASS","FRAME_CONTAINER_ACTIVE_CLASS","isActive","activeClass","gleapCollapseUI","toggle","injectedCollapseUI","toggleCollapseUI","_this$configData","configData","sendMessageToTourBuilder","GleapProductTours","disable","showFeedbackButton","adminHelper","injectCollapseUI","setFrameHeight","gleapAdminDisabled","initAdminHelper","currentPage","click","opener","GleapTours","currentConfig","configure","animate","allowClose","overlayOpacity","smoothScroll","disableActiveInteraction","showProgress","stagePadding","stageRadius","popoverOffset","showButtons","disableButtons","overlayColor","getConfig","easeInOutQuad","elapsed","initialValue","amountOfChange","getFocusableElements","parentEls","focusableQuery","flatMap","parentEl","isParentFocusable","focusableEls","isElementVisible","bringInView","isElementInView","shouldSmoothScroll","scrollIntoView","behavior","hasScrollableParent","currentState","setState","getState","resetState","registeredListeners","listen","hook","trackActiveElement","activeStagePosition","renderOverlay","mountOverlay","stagePosition","overlaySvg","stage","windowX","windowY","svg","fillRule","clipRule","strokeLinejoin","strokeMiterlimit","stagePath","generateStageSvgPathString","createOverlaySvg","onDriverClick","pathElement","stageWidth","stageHeight","limitedRadius","normalizedRadius","highlightBoxX","highlightBoxY","highlightBoxWidth","highlightBoxHeight","highlight","attemptTime","elemObj","refactoredElement","hidePopover","existingDummy","getElementById","mountDummyElement","toElement","toStep","_toStep$disableActive","fromStep","fromElement","isFirstHighlight","isToDummyElement","isFromDummyElement","isAnimatedTour","highlightStartedHook","onHighlightStarted","highlightedHook","onHighlighted","deselectedHook","onDeselected","hasDelayedPopover","isPopoverRendered","isHalfwayThrough","popover","renderPopover","fromDefinition","toDefinition","transitionStage","transferHighlight","refreshActiveHighlight","activeHighlight","activeStep","freshEl","refreshOverlay","repositionPopover","requireRefresh","resizeTimeout","trapFocus","activeElement","popoverEl","firstFocusableEl","lastFocusableEl","shiftKey","previousFocusableEl","nextFocusableEl","onKeyup","shouldPreventDefault","listenerWrapper","listener2","useCapture","description","closeButton","footer","footerButtons","previousButton","createPopover","_ref2$nextBtnText","nextBtnText","_ref2$prevBtnText","prevBtnText","_ref2$progressText","progressText","showButtonsConfig","showProgressConfig","showFooter","disabledButtonsConfig","popoverWrapper","customPopoverClass","popoverClass","_b2","onNextClick","onPrevClick","onCloseClick","onPopoverRender","focusableElement","getPopoverDimensions","boundingClientRect","realWidth","realHeight","calculateTopForLeftRight","elementDimensions","popoverDimensions","popoverPadding","popoverArrowDimensions","calculateLeftForTopBottom","_ref3$align","align","_ref3$side","requiredAlignment","requiredSide","topValue","isTopOptimal","bottomValue","isBottomOptimal","leftValue","isLeftOptimal","rightValue","isRightOptimal","noneOptimal","popoverRenderedSide","leftToSet","topToSet","leftValue2","rightToSet","bottomToSet","popoverArrow","popoverWidth","windowWidth","elementWidth","elementLeft","popoverHeight","windowHeight","elementTop","elementHeight","arrowSide","arrowAlignment","renderPopoverArrow","moveNext","activeIndex","nextStepIndex","drive","movePrevious","previousStepIndex","handleArrowLeft","handleArrowRight","_f","_g","_h","hasNextStep","hasPreviousStep","doneBtnText","allowsClosing","progressTextReplaced","configuredButtons","calculatedButtons","withOnDestroyStartedHook","activeOnDestroyed","onDestroyStarted","onDestroyed","interval","destroyEvents","destroyPopover","destroyHighlight","isActiveDummyElement","setSteps","getActiveIndex","isFirstStep","isLastStep","getActiveStep","getActiveElement","getPreviousElement","getPreviousStep","moveTo","localStorageKey","pointerContainerId","copilotJoinedContainerId","_canPlayAudio","GleapCopilotTours","_scrollListeners","_currentAnchor","_currentStep","_scrollDebounceTimer","productTourId","currentActiveIndex","productTourData","updatePointerPosition","onCompleteCallback","scrollableAncestors","getScrollableAncestors","_pointerContainer","yPosition","targetScrollPosition","scrollTo","smoothScrollToY","removeScrollListeners","pollCount","updateFinalPosition","isElementFullyVisible","targetX","targetY","containerWidthSpace","attachScrollListeners","currentAudio","pause","copilotInfoContainer","_GleapConfigManager$g","_GleapConfigManager$g2","_this$productTourData3","_this$productTourData4","_this$productTourData5","_this$productTourData6","_this$productTourData","_this$productTourData2","contrastColor","playVoice","gradient","svgMouse","infoBubble","kaiAvatar","kaiSlug","completeTour","canPlayAudio","supported","setupCopilotTour","showUnmuteModal","showAudioUnmuteModal","renderNextStep","_this$productTourData7","_this$productTourData8","_this$productTourData9","modalOverlay","modal","unmuteModalTitle","unmuteButton","unmuteModalButton","startAnywayButton","unmuteModalContinue","_this7","handleStep","gotToNextStep","_currentStep$inputTyp","proceedClickmode","storeUncompletedTour","inputType","handleInputEvent","_e$target","once","_currentStep$inputVal","inputValue","typeCharacter","wave","performClickAnimation","tempDiv","htmlToPlainText","readTime","wordCount","estimateReadTime","continueWithNoAudio","voice","elementPromise","maxAttempts","attempts","waitForElement","_self$productTourData","tourType","gleapTourObj","delay","manually","validateProductTour","onComplete","comData","clearUncompletedTour","startWithConfig","unmuted","driverSteps","isClickMode","isInputMode","isInteractionMode","hasSender","videoUrl","senderHTML","firstName","driverStep","buttons","backButton","allowKeyboardControl","nextText","doneText","prevText","_config$state","onDocumentClick","popoverElement","mediaElements","performRequentialRefresh","mediaElement","playingClass","playPauseContainer","videoElement","videoContainer","clickVideo","evnt","gleapTourPopover","_evnt$target","_arrayWithoutHoles","iter","_iterableToArray","_nonIterableSpread","GleapAgentChat","_agentId","_onChange","onChange","_onError","_onReplyReceived","onReplyReceived","_onConversationCreated","onConversationCreated","_onToken","_messages","_conversationId","_isExecuting","_error","_destroyed","_abortController","_networkManager","_sendMessage","streamingId","isKai","isNewConversation","streamingIdx","role","toISOString","isStreaming","_notify","additionalContext","AbortController","streamAgent","runId","abort","cancelStream","isExecuting","__originalGetContext","GleapChecklist","_HTMLElement","_assertThisInitialized","_callSuper","handleChecklistUpdate","handleSessionUpdate","_boundFloatingLauncherClick","handleFloatingLauncherClick","_boundFloatingCloseClick","handleFloatingCloseClick","_floatingHideTimeout","_inherits","_wrapNativeSuper","_boundHandleChecklistUpdate","_boundHandleSessionUpdate","_boundResizeHandler","handleResize","_checkSessionAndLoad","removeFloatingClickListeners","_hasLoaded","_isSessionReady","_initialActiveSet","renderResponse","updateActiveTaskMaxHeight","loadChecklist","renderChecklist","_getGleapSessionInstance","hasChecklistId","defaultValue","translateTextWithVars","validateChecklist","_isMock","isConnected","fetchChecklist","_isInitialLoad","_this3$checklistData$","_data$outbound","firstIncompleteIndex","findIndex","_session$gleapId","_session$gleapHash","checkedStep","makeRequest","updateData","_this$checklistData$o3","previousCompletedSteps","dataChanged","activeStepCompleted","currentlyActiveStepIndex","_this$checklistData$o","activeStepId","_this$checklistData$o2","nextActiveStep","setActiveStep","tasks","launcher","_outbound$config","_this$checklistData","renderDoneState","progressbarEnabled","doneSteps","_outbound$config2","_outbound$config3","nextIncompleteStep","titleText","_translateWithVars","subject","subtitleText","successTitle","successMessage","circumference","PI","computedOffset","isHeader","toFixed","_outbound$sender","infoEnabled","_translate","senderHtml","progressLabel","durationLabel","isTaskDone","badge","getCheckIcon","stepTitle","stepDescription","actionButtonText","actionTitle","actionHtml","markDoneLabel","markDoneHtml","allowMarkDone","taskClasses","_outbound$config4","_outbound$config5","_outbound$config6","floatingEnabled","renderFloatingLauncher","renderInfoSection","renderProgressSection","renderTasks","addTaskEventListeners","addFloatingClickListeners","toggleTask","taskBodyInner","task","newActiveStep","markDoneBtn","_this5$checklistData","previouslyActiveStep","allSteps","isModalOpen","tasksModal","updateChecklist","actionBtn","_this5$checklistData2","actionBody","openURL","actionOpenInNewTab","gleapError","previousActiveStep","tasksToToggle","forceOpen","taskElement","isOpen","shouldOpen","taskBody","_heightListenerAdded","registerGleapChecklist","GleapAgentConversation","_injectIframe","_messageListener","_iframe","_sendConfig","_agentConvUrl","_data","bubbles","_this$_iframe","dark","agentColor","emptyText","_config","_this$_iframe2","_this$_iframe3","registerGleapAgentComponents","offlineMode","hostname","injectNotificationUI","actions","_action$pageRules","_action$data","popupType","disableInAppNotifications","showNotification","showBanner","showModal","startProductTourWithConfig","globalData","replayData","getReplayData","setTags","setUrlHandler","setAgentTools","sendAgentToolsUpdate","updateContainerHeight","initialHeight","fixGleapHeight","checkForUncompletedTour","checkForUrlParams","disableQueryParams","urlParams","URLSearchParams","widget","conversationFlow","startConversation","feedbackFlow","surveyFlow","surveyFlowFormat","tourDelay","setQuickActions","setPlaceholder","identifySession","updateSession","setMaxRequests","setOptions","cleanedData","formPreFill","toggleFeedbackButton","setAppVersionCode","setAppBuildNumber","setBannerUrl","setModalUrl","setTicketAttribute","unsetTicketAttribute","clearTicketAttributes","attachCustomData","setCustomData","removeCustomData","clearCustomData","playSound","showNotificationBadge","notificationInstance","setOverrideLanguage","softReInitialize","updateContact","registerAgentToolAction","registerCustomAction","buttonStyle","contrastButtonColor","contrastBackgroundColor","contrastHeaderColor","isDarkMode","headerDarkColor","subTextColor","backgroundColorHover","hoverHoverColor","buttonBorderRadius","containerRadius","chatRadius","formItemBorderRadius","formItemSmallBorderRadius","bottomInfoOffset","colorStyleSheet","zIndexBase","injectStyledCSS","replays","attachments","sendSilentCrashReportWithFormData","silentCrashReportSent","excludeDataCleaned","newFormData","hideBackButton","showBackButton","flow","question","fullResponse","collectionId","term","networkManager","checkStartUrl","startProductTourConfig","startURL","loadUncompletedTour","showWithAgent","setAgent","GleapActions","GLAction","urlParts","identifier","openHelpCenterCollection"],"sourceRoot":""}