{
  "version": 3,
  "sources": ["/cdn/shop/t/1044/assets/dtf-ai-modal.js?auto=format%2Ccompress"],
  "sourcesContent": ["/* =========================================================\n   DTF AI Modal \u2014 shell driver\n   ---------------------------------------------------------\n   On pages where the legacy pink \"Create a design with Ninja AI\"\n   box is rendered (via the aiImageGenerator content-for), clicks\n   on that box open this modal instead of the legacy\n   <dialog id=\"generative-ai-dialog\">.\n\n   The chat UI inside the modal is the same .ai-chat panel used on\n   /pages/ai-image-creator and the dtfut Tab 3 \u2014 it is driven by\n   ai-chat-sandbox.js via instanceKey=\"dtfut\", which routes\n   \"Use this design\" clicks through the local cart/manage upload\n   pipeline. This file owns ONLY the modal shell \u2014 open/close,\n   focus restore, scroll-lock body class, and the post-select\n   dismiss when a tile is used.\n   ========================================================= */\n\n(function () {\n  'use strict';\n\n  if (window.__dtfAiModalInit) return;\n  window.__dtfAiModalInit = true;\n\n  /* Relocate the modal element to <body> so it escapes any ancestor\n     stacking context. The snippet is rendered deep inside bySizeNew.liquid\n     (sections often have transforms / filters / will-change) which traps\n     position:fixed children \u2014 visually that means the site header (which\n     has its own z-index) can render *over* the modal. Moving #dtf-ai-modal\n     to be a direct child of <body> gives our z-index: 100000 a clean\n     stacking context. Done once, idempotent. */\n  function relocateModalToBody() {\n    var el = document.getElementById('dtf-ai-modal');\n    if (!el) return;\n    if (el.parentNode === document.body) return;\n    document.body.appendChild(el);\n  }\n  if (document.readyState === 'loading') {\n    document.addEventListener('DOMContentLoaded', relocateModalToBody);\n  } else {\n    relocateModalToBody();\n  }\n\n  /* Same fetch interception used in dtf-upload-tabs.js so the AI\n     submit shows up to 3 cached canned results immediately and\n     skips the slower postBatchGenerativeAiUpload when canned came\n     back. Set once per page; safe to dedupe by checking the flag. */\n  if (!window.__dtfutFetchPatched && typeof window.fetch === 'function') {\n    window.__dtfutFetchPatched = true;\n    var origFetch = window.fetch;\n    window.fetch = function (url, options) {\n      try {\n        var urlStr = typeof url === 'string' ? url : (url && url.url) || '';\n\n        if (urlStr.indexOf('getGenerativeAiUploads.php') !== -1) {\n          return origFetch.apply(this, arguments).then(function (resp) {\n            return resp.clone().json().then(function (data) {\n              var capped = Array.isArray(data) ? data.slice(0, 3) : [];\n              if (capped.length > 0) {\n                window.__dtfutSkipNewAIGeneration = true;\n              }\n              return new Response(JSON.stringify(capped), {\n                status: resp.status,\n                headers: { 'Content-Type': 'application/json' }\n              });\n            }).catch(function () { return resp; });\n          });\n        }\n\n        if (window.__dtfutSkipNewAIGeneration && urlStr.indexOf('postBatchGenerativeAiUpload.php') !== -1) {\n          window.__dtfutSkipNewAIGeneration = false;\n          return Promise.resolve(new Response('[]', {\n            status: 200,\n            headers: { 'Content-Type': 'application/json' }\n          }));\n        }\n      } catch (e) { /* fall through */ }\n      return origFetch.apply(this, arguments);\n    };\n  }\n\n  /* ---------------- Modal open/close ---------------- */\n  var modal = null;\n  var lastFocused = null;\n\n  function openModal() {\n    if (!modal) modal = document.getElementById('dtf-ai-modal');\n    if (!modal) return;\n    lastFocused = document.activeElement;\n    modal.hidden = false;\n    /* Force a reflow so the transition runs from opacity:0. */\n    void modal.offsetHeight;\n    modal.classList.add('is-open');\n    document.body.classList.add('dtf-ai-modal-open');\n    var input = modal.querySelector('[data-ai-prompt]');\n    if (input) {\n      try { input.focus(); } catch (_) {}\n    }\n  }\n\n  function closeModal() {\n    if (!modal) return;\n    modal.classList.remove('is-open');\n    document.body.classList.remove('dtf-ai-modal-open');\n    setTimeout(function () {\n      if (!modal.classList.contains('is-open')) modal.hidden = true;\n    }, 220);\n    if (lastFocused && typeof lastFocused.focus === 'function') {\n      try { lastFocused.focus(); } catch (_) {}\n    }\n  }\n\n  /* Capture-phase listener so it runs before generative-ai-image-modal.js's\n     delegated jQuery handler on .generative-ai-area, which would otherwise\n     call .showModal() on the legacy <dialog>. We stopImmediatePropagation()\n     to short-circuit both other capture handlers and the bubble-phase\n     jQuery delegation. */\n  document.addEventListener('click', function (e) {\n    var area = e.target && e.target.closest && e.target.closest('.generative-ai-area');\n    if (!area) return;\n    /* If the click is inside our modal, ignore \u2014 our modal contains the\n       hidden .generative-ai-area from aiImageGenerator and we don't want\n       a self-trigger. (CSS hides it; this is belt-and-braces.) */\n    if (e.target.closest && e.target.closest('.dtf-ai-modal')) return;\n    e.stopImmediatePropagation();\n    e.preventDefault();\n    openModal();\n  }, true);\n\n  document.addEventListener('click', function (e) {\n    if (!modal || modal.hidden) return;\n    if (e.target.closest('[data-dtf-ai-modal-close]')) {\n      closeModal();\n    }\n  });\n\n  document.addEventListener('keydown', function (e) {\n    if (e.key === 'Escape' && modal && !modal.hidden) closeModal();\n  });\n\n  /* When a tile is clicked inside the modal, ai-chat-sandbox.js handles the\n     async upload via the cart pipeline. We just need to dismiss the modal\n     so the user lands on the upload-state UI behind it. The upload runs in\n     parallel \u2014 closing the modal does not cancel it. */\n  document.addEventListener('click', function (e) {\n    if (!modal || modal.hidden) return;\n    var tile = e.target && e.target.closest && e.target.closest('.ai-pop-tile');\n    if (!tile) return;\n    if (!modal.contains(tile)) return;\n    /* Skeleton/loading tiles aren't real picks. */\n    if (tile.classList.contains('is-skeleton')) return;\n    closeModal();\n  });\n\n  /* Same dismissal when the selection-bar \"Use Design\" / \"Use Designs\" CTA\n     fires (multi/single-select via Recently Generated). The CTA's own\n     handler in ai-chat-sandbox.js calls `stopPropagation()` to block the\n     document-level outside-click closer for `#ai-panel` \u2014 that also\n     prevents this listener from seeing the click in the bubble phase.\n     Capture phase runs BEFORE the target's stopPropagation takes effect,\n     so the modal closes synchronously and the CTA's own handler still\n     does the upload. */\n  document.addEventListener('click', function (e) {\n    if (!modal || modal.hidden) return;\n    var cta = e.target && e.target.closest && e.target.closest('.ai-chat-history-selection-bar__cta, [data-ai-selection-cta]');\n    if (!cta) return;\n    if (!modal.contains(cta)) return;\n    closeModal();\n  }, true);\n\n  /* ---------------- Reload-and-restore for multi-AI selection ----------------\n     When the user has an active upload (round-1 design) and picks 2+ AI images,\n     the desired UX is: add the round-1 design to cart, RELOAD the product page,\n     and re-open the multi-upload modal pre-populated with the 2+ AI images.\n     We achieve this by intercepting `md-picker:use-designs` in the capture\n     phase (before the bridge handler in product-page-popups-multiupload.liquid),\n     stashing the items in sessionStorage, calling singleFileAddToCart, and\n     reloading. On the next page load we read the stash and re-dispatch the\n     event \u2014 without an active upload this time \u2014 so the bridge handler routes\n     the URLs into multiFilesManageByURL.\n     ----------------------------------------------------------------------- */\n  var STASH_KEY = 'dtf:ai-multi-reload:v1';\n  var LOADING_FLAG = 'dtf:ai-multi-reload:loading';\n  var OVERLAY_ID = '__dtf-ai-multi-reload-overlay';\n\n  /* Full-screen white loading overlay shown from the moment the user clicks\n     \"Use Designs\" through the page reload until the multi-upload modal is\n     ready. The overlay is rendered by injecting a fixed-position div with a\n     very high z-index. We also suppress the legacy `.toast` and\n     `.loadingScreen__` (singleFileAddToCart's own UI) via CSS \u2014 they have\n     very high z-index values and would otherwise paint above the overlay. */\n  function showLoadingOverlay() {\n    if (!document.getElementById('__dtf-ai-hide-legacy-loaders')) {\n      var hideStyle = document.createElement('style');\n      hideStyle.id = '__dtf-ai-hide-legacy-loaders';\n      hideStyle.textContent = '.toast, .loadingScreen__ { display: none !important; }';\n      (document.head || document.documentElement).appendChild(hideStyle);\n    }\n    if (document.getElementById(OVERLAY_ID)) return;\n    var ov = document.createElement('div');\n    ov.id = OVERLAY_ID;\n    ov.style.cssText = 'position:fixed;inset:0;background:#ffffff;z-index:2147483647;display:flex;align-items:center;justify-content:center;font:600 16px/1.4 system-ui,-apple-system,\"Segoe UI\",sans-serif;color:#0f172a;';\n    ov.innerHTML =\n      '<div style=\"text-align:center;\">' +\n        '<div class=\"__dtf-ai-spinner\" style=\"width:48px;height:48px;border:4px solid #e2e8f0;border-top-color:#46aae3;border-radius:50%;animation:__dtfSpin 0.8s linear infinite;margin:0 auto 16px;\"></div>' +\n        '<div>Loading designs\u2026</div>' +\n      '</div>';\n    /* Inject keyframes once. */\n    if (!document.getElementById('__dtf-ai-spinner-style')) {\n      var s = document.createElement('style');\n      s.id = '__dtf-ai-spinner-style';\n      s.textContent = '@keyframes __dtfSpin { to { transform: rotate(360deg); } }';\n      (document.head || document.documentElement).appendChild(s);\n    }\n    (document.body || document.documentElement).appendChild(ov);\n  }\n\n  function hideLoadingOverlay() {\n    var ov = document.getElementById(OVERLAY_ID);\n    if (ov && ov.parentNode) ov.parentNode.removeChild(ov);\n    var hideStyle = document.getElementById('__dtf-ai-hide-legacy-loaders');\n    if (hideStyle && hideStyle.parentNode) hideStyle.parentNode.removeChild(hideStyle);\n    try { sessionStorage.removeItem(LOADING_FLAG); } catch (_) {}\n  }\n\n  /* If a previous page set the loading flag (i.e. we're returning from a\n     reload triggered by stashAndReload), render the overlay synchronously\n     so the user never sees the bare product page. */\n  try {\n    if (sessionStorage.getItem(LOADING_FLAG) === '1') {\n      if (document.body) {\n        showLoadingOverlay();\n      } else {\n        document.addEventListener('DOMContentLoaded', showLoadingOverlay);\n      }\n    }\n  } catch (_) {}\n\n  function hasActiveUpload() {\n    /* If the multi-upload-wrapper is already active, the user is in multi-mode\n       \u2014 new selections should merge into the existing wrapper, not trigger a\n       reload. Bail out early. */\n    if (document.querySelector('multi-upload-wrapper.active')) return false;\n\n    /* Single-upload mode: detect via uploadType (lives in different scopes\n       depending on which JS bundle the product loads \u2014 bySize.js /\n       bySize_popular.js / pdp_transferBySize-multiupload.js \u2014 `let` at script\n       top level is in the global lexical environment but NOT on window, so\n       we probe both). Fall back to the master-upload hidden class which is\n       set whenever a round-1 design is currently active. */\n    try {\n      if (typeof uploadType !== 'undefined' && uploadType === 'single') return true;\n    } catch (_) {}\n    if (typeof window.uploadType !== 'undefined' && window.uploadType === 'single') return true;\n    var jq = window.jQuery || window.$;\n    if (jq && jq('upload-controls master-upload').hasClass('hidden')) return true;\n    return false;\n  }\n\n  function stashAndReload(items) {\n    try {\n      sessionStorage.setItem(STASH_KEY, JSON.stringify({\n        items: items,\n        ts: Date.now()\n      }));\n      sessionStorage.setItem(LOADING_FLAG, '1');\n    } catch (_) {}\n\n    /* Show the overlay BEFORE kicking off addToCart so the user sees one\n       continuous loading screen rather than the live cart UI flashing\n       through \"Product Added to cart\" + scroll animation. */\n    showLoadingOverlay();\n\n    var addToCartPromise = (typeof window.singleFileAddToCart === 'function')\n      ? Promise.resolve(window.singleFileAddToCart())\n      : Promise.resolve();\n\n    addToCartPromise\n      .catch(function (err) { console.error('singleFileAddToCart failed', err); })\n      .then(function () {\n        /* Small defer so the cart fetch settles before navigation. */\n        setTimeout(function () { window.location.reload(); }, 100);\n      });\n  }\n\n  /* Capture-phase intercept \u2014 runs BEFORE the document-bound bridge handler in\n     product-page-popups-multiupload.liquid (which is bubble-phase by default). */\n  document.addEventListener('md-picker:use-designs', function (e) {\n    var items = (e.detail && e.detail.items) || [];\n    if (items.length < 2) return;          /* single \u2192 existing flow loads new design in place */\n\n    if (!hasActiveUpload()) {\n      /* No active single-upload, but possibly in multi-upload mode. Let the\n         bridge handler in product-page-popups-multiupload.liquid run, then\n         auto-scroll the multi-upload-wrapper to the first new block. Mirrors\n         the focus behaviour `.use_designes_bulk` already does for the\n         previous-uploads picker. */\n      if (document.querySelector('multi-upload-wrapper.active')) {\n        var jq = window.jQuery || window.$;\n        var beforeBlocks = jq ? jq('multi-upload uploaded-files-block').length : 0;\n        setTimeout(function () {\n          if (typeof window.setFocusOfMultiUpload === 'function') {\n            window.setFocusOfMultiUpload(beforeBlocks);\n          }\n        }, 700);\n      }\n      return;\n    }\n\n    e.stopImmediatePropagation();\n    if (typeof e.preventDefault === 'function') e.preventDefault();\n\n    stashAndReload(items);\n  }, true);\n\n  /* On page load, if a stash exists from a prior reload, drive the multi-upload\n     pipeline directly (createFileObjectFromUrl \u2192 multiFilesManageByURL) so the\n     `isAIImage` flag is preserved on each file detail. The bridge handler in\n     product-page-popups-multiupload.liquid also handles this event, but it\n     doesn't set isAIImage; calling the helpers directly avoids that gap.\n     We wait (poll) for the upload helpers to load. */\n  function getHelper(name) {\n    if (typeof window[name] === 'function') return window[name];\n    /* Helpers declared as `async function foo` at script top level are also\n       window-attached; helpers stored in `let`/`const` would not be. Try the\n       bare global as a last resort, suppressing the ReferenceError if absent. */\n    try { /* eslint-disable-next-line no-eval */ return (0, eval)(name); } catch (_) { return null; }\n  }\n\n  function rehydrateFromStash() {\n    var raw;\n    try { raw = sessionStorage.getItem(STASH_KEY); } catch (_) { hideLoadingOverlay(); return; }\n    if (!raw) { hideLoadingOverlay(); return; }\n    try { sessionStorage.removeItem(STASH_KEY); } catch (_) {}\n\n    var data;\n    try { data = JSON.parse(raw); } catch (_) { hideLoadingOverlay(); return; }\n    if (!data || !data.items || data.items.length < 2) { hideLoadingOverlay(); return; }\n\n    var attempts = 0;\n    function tryProcess() {\n      attempts++;\n      var createFn = getHelper('createFileObjectFromUrl');\n      var multiFn = getHelper('multiFilesManageByURL');\n      if ((!createFn || !multiFn) && attempts < 60) {\n        setTimeout(tryProcess, 200);\n        return;\n      }\n\n      if (createFn && multiFn) {\n        var files = data.items.map(function (it) {\n          var url = it.file || it.url;\n          if (!url) return null;\n          var detail = createFn(url);\n          detail.fileURL = url;\n          detail.isAIImage = true;\n          return detail;\n        }).filter(Boolean);\n        if (files.length) {\n          multiFn(files);\n          waitForMultiUploadAndHideOverlay();\n        } else {\n          hideLoadingOverlay();\n        }\n        return;\n      }\n\n      /* Fallback: dispatch the event so the bridge handler can process it. */\n      document.dispatchEvent(new CustomEvent('md-picker:use-designs', {\n        bubbles: true,\n        detail: { items: data.items }\n      }));\n      waitForMultiUploadAndHideOverlay();\n    }\n\n    /* Poll briefly for the multi-upload-wrapper to land in the DOM, then hide\n       the loading overlay. Capped at ~6s in case something goes wrong; we\n       still want to give the user back control of the page. */\n    function waitForMultiUploadAndHideOverlay() {\n      var jq = window.jQuery || window.$;\n      var waitAttempts = 0;\n      function check() {\n        waitAttempts++;\n        var ready = jq\n          ? (jq('multi-upload-wrapper').length > 0)\n          : !!document.querySelector('multi-upload-wrapper');\n        if (ready || waitAttempts >= 60) {\n          hideLoadingOverlay();\n          return;\n        }\n        setTimeout(check, 100);\n      }\n      check();\n    }\n\n    if (document.readyState === 'loading') {\n      document.addEventListener('DOMContentLoaded', tryProcess);\n    } else {\n      tryProcess();\n    }\n  }\n\n  rehydrateFromStash();\n})();\n"],
  "mappings": "CAiBC,UAAY,CACX,aAEA,GAAI,OAAO,iBAAkB,OAC7B,OAAO,iBAAmB,GAS1B,SAAS,qBAAsB,CAC7B,IAAI,GAAK,SAAS,eAAe,cAAc,EAC1C,IACD,GAAG,aAAe,SAAS,MAC/B,SAAS,KAAK,YAAY,EAAE,CAC9B,CAWA,GAVI,SAAS,aAAe,UAC1B,SAAS,iBAAiB,mBAAoB,mBAAmB,EAEjE,oBAAoB,EAOlB,CAAC,OAAO,qBAAuB,OAAO,OAAO,OAAU,WAAY,CACrE,OAAO,oBAAsB,GAC7B,IAAI,UAAY,OAAO,MACvB,OAAO,MAAQ,SAAU,IAAK,QAAS,CACrC,GAAI,CACF,IAAI,OAAS,OAAO,KAAQ,SAAW,IAAO,KAAO,IAAI,KAAQ,GAEjE,GAAI,OAAO,QAAQ,4BAA4B,IAAM,GACnD,OAAO,UAAU,MAAM,KAAM,SAAS,EAAE,KAAK,SAAU,KAAM,CAC3D,OAAO,KAAK,MAAM,EAAE,KAAK,EAAE,KAAK,SAAU,KAAM,CAC9C,IAAI,OAAS,MAAM,QAAQ,IAAI,EAAI,KAAK,MAAM,EAAG,CAAC,EAAI,CAAC,EACvD,OAAI,OAAO,OAAS,IAClB,OAAO,2BAA6B,IAE/B,IAAI,SAAS,KAAK,UAAU,MAAM,EAAG,CAC1C,OAAQ,KAAK,OACb,QAAS,CAAE,eAAgB,kBAAmB,CAChD,CAAC,CACH,CAAC,EAAE,MAAM,UAAY,CAAE,OAAO,IAAM,CAAC,CACvC,CAAC,EAGH,GAAI,OAAO,4BAA8B,OAAO,QAAQ,iCAAiC,IAAM,GAC7F,cAAO,2BAA6B,GAC7B,QAAQ,QAAQ,IAAI,SAAS,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