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AKC,SAAS,CAAC,CAC/D,EACA,CACI,GAAG6I,CAAS,CACZ1J,GAAAA,CACJ,EACH,EAAI,GACT,CACJ,GAsBgB,sBAAbqI,GACHpI,GAEA+G,EAAUjH,OAAO,CAACuK,OAAO,CAACrK,EAAKyJ,EAAUa,SAAS,CAAG,CACjDzC,GAAI,SACJyC,UAAWb,EAAUa,SAAS,EAC9B,CACAzC,GAAI,QACR,EAGZ,CACA,OAAO,IACX,CACA/J,OAAOuD,cAAc,CAACmI,EAAQ,eAAgB,CAC1CzL,MAAO,EACX,GACA,IAAM4I,EAAW6C,EAEZ,oBAAOrL,EAAQ2B,OAAO,EAAoB,iBAAO3B,EAAQ2B,OAAO,EAAiB3B,OAAAA,EAAQ2B,OAAO,GAAe,KAAsC,IAA/B3B,EAAQ2B,OAAO,CAACL,UAAU,GACnJ3B,OAAOuD,cAAc,CAAClD,EAAQ2B,OAAO,CAAE,aAAc,CAAE/B,MAAO,EAAK,GACnED,OAAO4H,MAAM,CAACvH,EAAQ2B,OAAO,CAAE3B,GAC/BwH,EAAOxH,OAAO,CAAGA,EAAQ2B,OAAO,wCEpVlC6F,EAAAxH,OAAA,EAAkB,OAAS,6EAAgF","sources":["webpack://_N_E/?fa49","webpack://_N_E/./node_modules/@next/third-parties/dist/ThirdPartyScriptEmbed.js","webpack://_N_E/./node_modules/@next/third-parties/dist/google/ga.js","webpack://_N_E/./node_modules/@next/third-parties/dist/google/gtm.js","webpack://_N_E/./node_modules/next/dist/api/script.js","webpack://_N_E/./node_modules/next/dist/client/head-manager.js","webpack://_N_E/./node_modules/next/dist/client/request-idle-callback.js","webpack://_N_E/./node_modules/next/dist/client/script.js","webpack://_N_E/./app/globals.css","webpack://_N_E/./node_modules/next/font/google/target.css","webpack://_N_E/"],"sourcesContent":["import(/* webpackMode: \"eager\" */ \"/codebuild/output/src4243223962/src/EbWebsiteProd/app/globals.css\");\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src4243223962/src/EbWebsiteProd/node_modules/@next/third-parties/dist/google/ga.js\");\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src4243223962/src/EbWebsiteProd/node_modules/@next/third-parties/dist/google/gtm.js\");\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src4243223962/src/EbWebsiteProd/node_modules/@next/third-parties/dist/ThirdPartyScriptEmbed.js\");\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src4243223962/src/EbWebsiteProd/node_modules/next/dist/client/script.js\");\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src4243223962/src/EbWebsiteProd/node_modules/next/font/google/target.css?{\\\"path\\\":\\\"app/layout.js\\\",\\\"import\\\":\\\"Inter\\\",\\\"arguments\\\":[{\\\"subsets\\\":[\\\"latin\\\"]}],\\\"variableName\\\":\\\"inter\\\"}\")","\"use strict\";\n'use client';\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst jsx_runtime_1 = require(\"react/jsx-runtime\");\nconst react_1 = require(\"react\");\nfunction ThirdPartyScriptEmbed({ html, height = null, width = null, children, dataNtpc = '', }) {\n (0, react_1.useEffect)(() => {\n if (dataNtpc) {\n // performance.mark is being used as a feature use signal. While it is traditionally used for performance\n // benchmarking it is low overhead and thus considered safe to use in production and it is a widely available\n // existing API.\n performance.mark('mark_feature_usage', {\n detail: {\n feature: `next-third-parties-${dataNtpc}`,\n },\n });\n }\n }, [dataNtpc]);\n return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [children, html ? ((0, jsx_runtime_1.jsx)(\"div\", { style: {\n height: height != null ? `${height}px` : 'auto',\n width: width != null ? `${width}px` : 'auto',\n }, \"data-ntpc\": dataNtpc, dangerouslySetInnerHTML: { __html: html } })) : null] }));\n}\nexports.default = ThirdPartyScriptEmbed;\n","\"use strict\";\n'use client';\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.sendGAEvent = exports.GoogleAnalytics = void 0;\nconst jsx_runtime_1 = require(\"react/jsx-runtime\");\n// TODO: Evaluate import 'client only'\nconst react_1 = require(\"react\");\nconst script_1 = __importDefault(require(\"next/script\"));\nlet currDataLayerName = undefined;\nfunction GoogleAnalytics(props) {\n const { gaId, dataLayerName = 'dataLayer' } = props;\n if (currDataLayerName === undefined) {\n currDataLayerName = dataLayerName;\n }\n (0, react_1.useEffect)(() => {\n // performance.mark is being used as a feature use signal. While it is traditionally used for performance\n // benchmarking it is low overhead and thus considered safe to use in production and it is a widely available\n // existing API.\n // The performance measurement will be handled by Chrome Aurora\n performance.mark('mark_feature_usage', {\n detail: {\n feature: 'next-third-parties-ga',\n },\n });\n }, []);\n return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(script_1.default, { id: \"_next-ga-init\", dangerouslySetInnerHTML: {\n __html: `\n window['${dataLayerName}'] = window['${dataLayerName}'] || [];\n function gtag(){window['${dataLayerName}'].push(arguments);}\n gtag('js', new Date());\n\n gtag('config', '${gaId}');`,\n } }), (0, jsx_runtime_1.jsx)(script_1.default, { id: \"_next-ga\", src: `https://www.googletagmanager.com/gtag/js?id=${gaId}` })] }));\n}\nexports.GoogleAnalytics = GoogleAnalytics;\nconst sendGAEvent = (...args) => {\n if (currDataLayerName === undefined) {\n console.warn(`@next/third-parties: GA has not been initialized`);\n return;\n }\n if (window[currDataLayerName]) {\n window[currDataLayerName].push(...args);\n }\n else {\n console.warn(`@next/third-parties: GA dataLayer ${currDataLayerName} does not exist`);\n }\n};\nexports.sendGAEvent = sendGAEvent;\n","\"use strict\";\n'use client';\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.sendGTMEvent = exports.GoogleTagManager = void 0;\nconst jsx_runtime_1 = require(\"react/jsx-runtime\");\n// TODO: Evaluate import 'client only'\nconst react_1 = require(\"react\");\nconst script_1 = __importDefault(require(\"next/script\"));\nlet currDataLayerName = undefined;\nfunction GoogleTagManager(props) {\n const { gtmId, dataLayerName = 'dataLayer', auth, preview, dataLayer } = props;\n if (currDataLayerName === undefined) {\n currDataLayerName = dataLayerName;\n }\n const gtmLayer = dataLayerName !== 'dataLayer' ? `$l=${dataLayerName}` : '';\n const gtmAuth = auth ? `>m_auth=${auth}` : '';\n const gtmPreview = preview ? `>m_preview=${preview}>m_cookies_win=x` : '';\n (0, react_1.useEffect)(() => {\n // performance.mark is being used as a feature use signal. While it is traditionally used for performance\n // benchmarking it is low overhead and thus considered safe to use in production and it is a widely available\n // existing API.\n // The performance measurement will be handled by Chrome Aurora\n performance.mark('mark_feature_usage', {\n detail: {\n feature: 'next-third-parties-gtm',\n },\n });\n }, []);\n return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(script_1.default, { id: \"_next-gtm-init\", dangerouslySetInnerHTML: {\n __html: `\n (function(w,l){\n w[l]=w[l]||[];\n w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});\n ${dataLayer ? `w[l].push(${JSON.stringify(dataLayer)})` : ''}\n })(window,'${dataLayerName}');`,\n } }), (0, jsx_runtime_1.jsx)(script_1.default, { id: \"_next-gtm\", \"data-ntpc\": \"GTM\", src: `https://www.googletagmanager.com/gtm.js?id=${gtmId}${gtmLayer}${gtmAuth}${gtmPreview}` })] }));\n}\nexports.GoogleTagManager = GoogleTagManager;\nconst sendGTMEvent = (data) => {\n if (currDataLayerName === undefined) {\n console.warn(`@next/third-parties: GTM has not been initialized`);\n return;\n }\n if (window[currDataLayerName]) {\n window[currDataLayerName].push(data);\n }\n else {\n console.warn(`@next/third-parties: GTM dataLayer ${currDataLayerName} does not exist`);\n }\n};\nexports.sendGTMEvent = sendGTMEvent;\n","export { default } from \"../client/script\";\nexport * from \"../client/script\";\n\n//# sourceMappingURL=script.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n0 && (module.exports = {\n DOMAttributeNames: null,\n isEqualNode: null,\n default: null\n});\nfunction _export(target, all) {\n for(var name in all)Object.defineProperty(target, name, {\n enumerable: true,\n get: all[name]\n });\n}\n_export(exports, {\n DOMAttributeNames: function() {\n return DOMAttributeNames;\n },\n isEqualNode: function() {\n return isEqualNode;\n },\n default: function() {\n return initHeadManager;\n }\n});\nconst DOMAttributeNames = {\n acceptCharset: \"accept-charset\",\n className: \"class\",\n htmlFor: \"for\",\n httpEquiv: \"http-equiv\",\n noModule: \"noModule\"\n};\nfunction reactElementToDOM(param) {\n let { type, props } = param;\n const el = document.createElement(type);\n for(const p in props){\n if (!props.hasOwnProperty(p)) continue;\n if (p === \"children\" || p === \"dangerouslySetInnerHTML\") continue;\n // we don't render undefined props to the DOM\n if (props[p] === undefined) continue;\n const attr = DOMAttributeNames[p] || p.toLowerCase();\n if (type === \"script\" && (attr === \"async\" || attr === \"defer\" || attr === \"noModule\")) {\n el[attr] = !!props[p];\n } else {\n el.setAttribute(attr, props[p]);\n }\n }\n const { children, dangerouslySetInnerHTML } = props;\n if (dangerouslySetInnerHTML) {\n el.innerHTML = dangerouslySetInnerHTML.__html || \"\";\n } else if (children) {\n el.textContent = typeof children === \"string\" ? children : Array.isArray(children) ? children.join(\"\") : \"\";\n }\n return el;\n}\nfunction isEqualNode(oldTag, newTag) {\n if (oldTag instanceof HTMLElement && newTag instanceof HTMLElement) {\n const nonce = newTag.getAttribute(\"nonce\");\n // Only strip the nonce if `oldTag` has had it stripped. An element's nonce attribute will not\n // be stripped if there is no content security policy response header that includes a nonce.\n if (nonce && !oldTag.getAttribute(\"nonce\")) {\n const cloneTag = newTag.cloneNode(true);\n cloneTag.setAttribute(\"nonce\", \"\");\n cloneTag.nonce = nonce;\n return nonce === oldTag.nonce && oldTag.isEqualNode(cloneTag);\n }\n }\n return oldTag.isEqualNode(newTag);\n}\nlet updateElements;\nif (process.env.__NEXT_STRICT_NEXT_HEAD) {\n updateElements = (type, components)=>{\n const headEl = document.querySelector(\"head\");\n if (!headEl) return;\n const headMetaTags = headEl.querySelectorAll('meta[name=\"next-head\"]') || [];\n const oldTags = [];\n if (type === \"meta\") {\n const metaCharset = headEl.querySelector(\"meta[charset]\");\n if (metaCharset) {\n oldTags.push(metaCharset);\n }\n }\n for(let i = 0; i < headMetaTags.length; i++){\n var _headTag_tagName;\n const metaTag = headMetaTags[i];\n const headTag = metaTag.nextSibling;\n if ((headTag == null ? void 0 : (_headTag_tagName = headTag.tagName) == null ? void 0 : _headTag_tagName.toLowerCase()) === type) {\n oldTags.push(headTag);\n }\n }\n const newTags = components.map(reactElementToDOM).filter((newTag)=>{\n for(let k = 0, len = oldTags.length; k < len; k++){\n const oldTag = oldTags[k];\n if (isEqualNode(oldTag, newTag)) {\n oldTags.splice(k, 1);\n return false;\n }\n }\n return true;\n });\n oldTags.forEach((t)=>{\n var _t_parentNode;\n const metaTag = t.previousSibling;\n if (metaTag && metaTag.getAttribute(\"name\") === \"next-head\") {\n var _t_parentNode1;\n (_t_parentNode1 = t.parentNode) == null ? void 0 : _t_parentNode1.removeChild(metaTag);\n }\n (_t_parentNode = t.parentNode) == null ? void 0 : _t_parentNode.removeChild(t);\n });\n newTags.forEach((t)=>{\n var _t_tagName;\n const meta = document.createElement(\"meta\");\n meta.name = \"next-head\";\n meta.content = \"1\";\n // meta[charset] must be first element so special case\n if (!(((_t_tagName = t.tagName) == null ? void 0 : _t_tagName.toLowerCase()) === \"meta\" && t.getAttribute(\"charset\"))) {\n headEl.appendChild(meta);\n }\n headEl.appendChild(t);\n });\n };\n} else {\n updateElements = (type, components)=>{\n const headEl = document.getElementsByTagName(\"head\")[0];\n const headCountEl = headEl.querySelector(\"meta[name=next-head-count]\");\n if (process.env.NODE_ENV !== \"production\") {\n if (!headCountEl) {\n console.error(\"Warning: next-head-count is missing. https://nextjs.org/docs/messages/next-head-count-missing\");\n return;\n }\n }\n const headCount = Number(headCountEl.content);\n const oldTags = [];\n for(let i = 0, j = headCountEl.previousElementSibling; i < headCount; i++, j = (j == null ? void 0 : j.previousElementSibling) || null){\n var _j_tagName;\n if ((j == null ? void 0 : (_j_tagName = j.tagName) == null ? void 0 : _j_tagName.toLowerCase()) === type) {\n oldTags.push(j);\n }\n }\n const newTags = components.map(reactElementToDOM).filter((newTag)=>{\n for(let k = 0, len = oldTags.length; k < len; k++){\n const oldTag = oldTags[k];\n if (isEqualNode(oldTag, newTag)) {\n oldTags.splice(k, 1);\n return false;\n }\n }\n return true;\n });\n oldTags.forEach((t)=>{\n var _t_parentNode;\n return (_t_parentNode = t.parentNode) == null ? void 0 : _t_parentNode.removeChild(t);\n });\n newTags.forEach((t)=>headEl.insertBefore(t, headCountEl));\n headCountEl.content = (headCount - oldTags.length + newTags.length).toString();\n };\n}\nfunction initHeadManager() {\n return {\n mountedInstances: new Set(),\n updateHead: (head)=>{\n const tags = {};\n head.forEach((h)=>{\n if (// If the font tag is loaded only on client navigation\n // it won't be inlined. In this case revert to the original behavior\n h.type === \"link\" && h.props[\"data-optimized-fonts\"]) {\n if (document.querySelector('style[data-href=\"' + h.props[\"data-href\"] + '\"]')) {\n return;\n } else {\n h.props.href = h.props[\"data-href\"];\n h.props[\"data-href\"] = undefined;\n }\n }\n const components = tags[h.type] || [];\n components.push(h);\n tags[h.type] = components;\n });\n const titleComponent = tags.title ? tags.title[0] : null;\n let title = \"\";\n if (titleComponent) {\n const { children } = titleComponent.props;\n title = typeof children === \"string\" ? children : Array.isArray(children) ? children.join(\"\") : \"\";\n }\n if (title !== document.title) document.title = title;\n [\n \"meta\",\n \"base\",\n \"link\",\n \"style\",\n \"script\"\n ].forEach((type)=>{\n updateElements(type, tags[type] || []);\n });\n }\n };\n}\n\nif ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {\n Object.defineProperty(exports.default, '__esModule', { value: true });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n}\n\n//# sourceMappingURL=head-manager.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n0 && (module.exports = {\n requestIdleCallback: null,\n cancelIdleCallback: null\n});\nfunction _export(target, all) {\n for(var name in all)Object.defineProperty(target, name, {\n enumerable: true,\n get: all[name]\n });\n}\n_export(exports, {\n requestIdleCallback: function() {\n return requestIdleCallback;\n },\n cancelIdleCallback: function() {\n return cancelIdleCallback;\n }\n});\nconst requestIdleCallback = typeof self !== \"undefined\" && self.requestIdleCallback && self.requestIdleCallback.bind(window) || function(cb) {\n let start = Date.now();\n return self.setTimeout(function() {\n cb({\n didTimeout: false,\n timeRemaining: function() {\n return Math.max(0, 50 - (Date.now() - start));\n }\n });\n }, 1);\n};\nconst cancelIdleCallback = typeof self !== \"undefined\" && self.cancelIdleCallback && self.cancelIdleCallback.bind(window) || function(id) {\n return clearTimeout(id);\n};\n\nif ((typeof exports.default === 'function' || (typeof exports.default === 'object' && exports.default !== null)) && typeof exports.default.__esModule === 'undefined') {\n Object.defineProperty(exports.default, '__esModule', { value: true });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n}\n\n//# sourceMappingURL=request-idle-callback.js.map","\"use client\";\n\n\"use strict\";\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n0 && (module.exports = {\n handleClientScriptLoad: null,\n initScriptLoader: null,\n default: null\n});\nfunction _export(target, all) {\n for(var name in all)Object.defineProperty(target, name, {\n enumerable: true,\n get: all[name]\n });\n}\n_export(exports, {\n handleClientScriptLoad: function() {\n return handleClientScriptLoad;\n },\n initScriptLoader: function() {\n return initScriptLoader;\n },\n default: function() {\n return _default;\n }\n});\nconst _interop_require_default = require(\"@swc/helpers/_/_interop_require_default\");\nconst _interop_require_wildcard = require(\"@swc/helpers/_/_interop_require_wildcard\");\nconst _jsxruntime = require(\"react/jsx-runtime\");\nconst _reactdom = /*#__PURE__*/ _interop_require_default._(require(\"react-dom\"));\nconst _react = /*#__PURE__*/ _interop_require_wildcard._(require(\"react\"));\nconst _headmanagercontextsharedruntime = require(\"../shared/lib/head-manager-context.shared-runtime\");\nconst _headmanager = require(\"./head-manager\");\nconst _requestidlecallback = require(\"./request-idle-callback\");\nconst ScriptCache = new Map();\nconst LoadCache = new Set();\nconst ignoreProps = [\n \"onLoad\",\n \"onReady\",\n \"dangerouslySetInnerHTML\",\n \"children\",\n \"onError\",\n \"strategy\",\n \"stylesheets\"\n];\nconst insertStylesheets = (stylesheets)=>{\n // Case 1: Styles for afterInteractive/lazyOnload with appDir injected via handleClientScriptLoad\n //\n // Using ReactDOM.preinit to feature detect appDir and inject styles\n // Stylesheets might have already been loaded if initialized with Script component\n // Re-inject styles here to handle scripts loaded via handleClientScriptLoad\n // ReactDOM.preinit handles dedup and ensures the styles are loaded only once\n if (_reactdom.default.preinit) {\n stylesheets.forEach((stylesheet)=>{\n _reactdom.default.preinit(stylesheet, {\n as: \"style\"\n });\n });\n return;\n }\n // Case 2: Styles for afterInteractive/lazyOnload with pages injected via handleClientScriptLoad\n //\n // We use this function to load styles when appdir is not detected\n // TODO: Use React float APIs to load styles once available for pages dir\n if (typeof window !== \"undefined\") {\n let head = document.head;\n stylesheets.forEach((stylesheet)=>{\n let link = document.createElement(\"link\");\n link.type = \"text/css\";\n link.rel = \"stylesheet\";\n link.href = stylesheet;\n head.appendChild(link);\n });\n }\n};\nconst loadScript = (props)=>{\n const { src, id, onLoad = ()=>{}, onReady = null, dangerouslySetInnerHTML, children = \"\", strategy = \"afterInteractive\", onError, stylesheets } = props;\n const cacheKey = id || src;\n // Script has already loaded\n if (cacheKey && LoadCache.has(cacheKey)) {\n return;\n }\n // Contents of this script are already loading/loaded\n if (ScriptCache.has(src)) {\n LoadCache.add(cacheKey);\n // It is possible that multiple `next/script` components all have same \"src\", but has different \"onLoad\"\n // This is to make sure the same remote script will only load once, but \"onLoad\" are executed in order\n ScriptCache.get(src).then(onLoad, onError);\n return;\n }\n /** Execute after the script first loaded */ const afterLoad = ()=>{\n // Run onReady for the first time after load event\n if (onReady) {\n onReady();\n }\n // add cacheKey to LoadCache when load successfully\n LoadCache.add(cacheKey);\n };\n const el = document.createElement(\"script\");\n const loadPromise = new Promise((resolve, reject)=>{\n el.addEventListener(\"load\", function(e) {\n resolve();\n if (onLoad) {\n onLoad.call(this, e);\n }\n afterLoad();\n });\n el.addEventListener(\"error\", function(e) {\n reject(e);\n });\n }).catch(function(e) {\n if (onError) {\n onError(e);\n }\n });\n if (dangerouslySetInnerHTML) {\n // Casting since lib.dom.d.ts doesn't have TrustedHTML yet.\n el.innerHTML = dangerouslySetInnerHTML.__html || \"\";\n afterLoad();\n } else if (children) {\n el.textContent = typeof children === \"string\" ? children : Array.isArray(children) ? children.join(\"\") : \"\";\n afterLoad();\n } else if (src) {\n el.src = src;\n // do not add cacheKey into LoadCache for remote script here\n // cacheKey will be added to LoadCache when it is actually loaded (see loadPromise above)\n ScriptCache.set(src, loadPromise);\n }\n for (const [k, value] of Object.entries(props)){\n if (value === undefined || ignoreProps.includes(k)) {\n continue;\n }\n const attr = _headmanager.DOMAttributeNames[k] || k.toLowerCase();\n el.setAttribute(attr, value);\n }\n if (strategy === \"worker\") {\n el.setAttribute(\"type\", \"text/partytown\");\n }\n el.setAttribute(\"data-nscript\", strategy);\n // Load styles associated with this script\n if (stylesheets) {\n insertStylesheets(stylesheets);\n }\n document.body.appendChild(el);\n};\nfunction handleClientScriptLoad(props) {\n const { strategy = \"afterInteractive\" } = props;\n if (strategy === \"lazyOnload\") {\n window.addEventListener(\"load\", ()=>{\n (0, _requestidlecallback.requestIdleCallback)(()=>loadScript(props));\n });\n } else {\n loadScript(props);\n }\n}\nfunction loadLazyScript(props) {\n if (document.readyState === \"complete\") {\n (0, _requestidlecallback.requestIdleCallback)(()=>loadScript(props));\n } else {\n window.addEventListener(\"load\", ()=>{\n (0, _requestidlecallback.requestIdleCallback)(()=>loadScript(props));\n });\n }\n}\nfunction addBeforeInteractiveToCache() {\n const scripts = [\n ...document.querySelectorAll('[data-nscript=\"beforeInteractive\"]'),\n ...document.querySelectorAll('[data-nscript=\"beforePageRender\"]')\n ];\n scripts.forEach((script)=>{\n const cacheKey = script.id || script.getAttribute(\"src\");\n LoadCache.add(cacheKey);\n });\n}\nfunction initScriptLoader(scriptLoaderItems) {\n scriptLoaderItems.forEach(handleClientScriptLoad);\n addBeforeInteractiveToCache();\n}\nfunction Script(props) {\n const { id, src = \"\", onLoad = ()=>{}, onReady = null, strategy = \"afterInteractive\", onError, stylesheets, ...restProps } = props;\n // Context is available only during SSR\n const { updateScripts, scripts, getIsSsr, appDir, nonce } = (0, _react.useContext)(_headmanagercontextsharedruntime.HeadManagerContext);\n /**\n * - First mount:\n * 1. The useEffect for onReady executes\n * 2. hasOnReadyEffectCalled.current is false, but the script hasn't loaded yet (not in LoadCache)\n * onReady is skipped, set hasOnReadyEffectCalled.current to true\n * 3. The useEffect for loadScript executes\n * 4. hasLoadScriptEffectCalled.current is false, loadScript executes\n * Once the script is loaded, the onLoad and onReady will be called by then\n * [If strict mode is enabled / is wrapped in component]\n * 5. The useEffect for onReady executes again\n * 6. hasOnReadyEffectCalled.current is true, so entire effect is skipped\n * 7. The useEffect for loadScript executes again\n * 8. hasLoadScriptEffectCalled.current is true, so entire effect is skipped\n *\n * - Second mount:\n * 1. The useEffect for onReady executes\n * 2. hasOnReadyEffectCalled.current is false, but the script has already loaded (found in LoadCache)\n * onReady is called, set hasOnReadyEffectCalled.current to true\n * 3. The useEffect for loadScript executes\n * 4. The script is already loaded, loadScript bails out\n * [If strict mode is enabled / is wrapped in component]\n * 5. The useEffect for onReady executes again\n * 6. hasOnReadyEffectCalled.current is true, so entire effect is skipped\n * 7. The useEffect for loadScript executes again\n * 8. hasLoadScriptEffectCalled.current is true, so entire effect is skipped\n */ const hasOnReadyEffectCalled = (0, _react.useRef)(false);\n (0, _react.useEffect)(()=>{\n const cacheKey = id || src;\n if (!hasOnReadyEffectCalled.current) {\n // Run onReady if script has loaded before but component is re-mounted\n if (onReady && cacheKey && LoadCache.has(cacheKey)) {\n onReady();\n }\n hasOnReadyEffectCalled.current = true;\n }\n }, [\n onReady,\n id,\n src\n ]);\n const hasLoadScriptEffectCalled = (0, _react.useRef)(false);\n (0, _react.useEffect)(()=>{\n if (!hasLoadScriptEffectCalled.current) {\n if (strategy === \"afterInteractive\") {\n loadScript(props);\n } else if (strategy === \"lazyOnload\") {\n loadLazyScript(props);\n }\n hasLoadScriptEffectCalled.current = true;\n }\n }, [\n props,\n strategy\n ]);\n if (strategy === \"beforeInteractive\" || strategy === \"worker\") {\n if (updateScripts) {\n scripts[strategy] = (scripts[strategy] || []).concat([\n {\n id,\n src,\n onLoad,\n onReady,\n onError,\n ...restProps\n }\n ]);\n updateScripts(scripts);\n } else if (getIsSsr && getIsSsr()) {\n // Script has already loaded during SSR\n LoadCache.add(id || src);\n } else if (getIsSsr && !getIsSsr()) {\n loadScript(props);\n }\n }\n // For the app directory, we need React Float to preload these scripts.\n if (appDir) {\n // Injecting stylesheets here handles beforeInteractive and worker scripts correctly\n // For other strategies injecting here ensures correct stylesheet order\n // ReactDOM.preinit handles loading the styles in the correct order,\n // also ensures the stylesheet is loaded only once and in a consistent manner\n //\n // Case 1: Styles for beforeInteractive/worker with appDir - handled here\n // Case 2: Styles for beforeInteractive/worker with pages dir - Not handled yet\n // Case 3: Styles for afterInteractive/lazyOnload with appDir - handled here\n // Case 4: Styles for afterInteractive/lazyOnload with pages dir - handled in insertStylesheets function\n if (stylesheets) {\n stylesheets.forEach((styleSrc)=>{\n _reactdom.default.preinit(styleSrc, {\n as: \"style\"\n });\n });\n }\n // Before interactive scripts need to be loaded by Next.js' runtime instead\n // of native