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AAC,IAAA,EACA,oBAAAA,KAAA,mBAGqEF,OAAAC,OAAA,SAAAD,OAAAC,OAAA,CAAAD,OAAAC,OAAA,CAAAE,UAAA","sources":["webpack://_N_E/./node_modules/core-js/modules/es.string.link.js","webpack://_N_E/./adapters/helpers/Scroll.js","webpack://_N_E/./components/CollectionTabs/CollectionTabsDropdownBlock.js","webpack://_N_E/./components/CollectionTabs/helpers.js","webpack://_N_E/./node_modules/next/dist/compiled/@babel/runtime/helpers/readOnlyError.js","webpack://_N_E/"],"sourcesContent":["'use strict';\nvar $ = require('../internals/export');\nvar createHTML = require('../internals/create-html');\nvar forcedStringHTMLMethod = require('../internals/string-html-forced');\n\n// `String.prototype.link` method\n// https://tc39.github.io/ecma262/#sec-string.prototype.link\n$({ target: 'String', proto: true, forced: forcedStringHTMLMethod('link') }, {\n link: function link(url) {\n return createHTML(this, 'a', 'href', url);\n }\n});\n","let smoothScrollId = null;\nlet smoothScrollStartY = 0;\nlet smoothScrollDeltaY = 0;\nlet smoothScrollStartTime = 0;\nlet smoothScrollDuration = 400;\n\nexport function scrollIntoView(element, options = {}) {\n smoothScrollStartY = window.scrollY || window.pageYOffset || 0;\n smoothScrollDeltaY = element.getBoundingClientRect().top;\n\n const headerElement = document.querySelector('.zone-header');\n const productSubNavElement = document.querySelector('.ob-product-sub-nav');\n\n if (headerElement) {\n smoothScrollDeltaY -= headerElement.getBoundingClientRect().bottom;\n\n if (productSubNavElement) {\n smoothScrollDeltaY -= productSubNavElement.getBoundingClientRect().bottom;\n }\n }\n\n if (options.behavior === 'smooth' && typeof requestAnimationFrame !== 'undefined') {\n smoothScrollStartTime = Date.now();\n\n if (smoothScrollId == null) {\n smoothScrollStep();\n }\n } else {\n if (smoothScrollId != null) {\n cancelAnimationFrame(smoothScrollId);\n smoothScrollId = null;\n }\n\n window.scrollTo(window.scrollX, null);\n }\n}\n\nfunction smoothScrollStep() {\n const elapsed = Date.now() - smoothScrollStartTime;\n const t = elapsed / smoothScrollDuration;\n\n if (t < 1) {\n smoothScrollId = requestAnimationFrame(smoothScrollStep);\n window.scrollTo(window.scrollX, easeInOutQuad(t) * smoothScrollDeltaY + smoothScrollStartY);\n }\n else {\n smoothScrollId = null;\n window.scrollTo(window.scrollX, smoothScrollDeltaY + smoothScrollStartY);\n }\n}\n\nfunction easeInOutQuad(t) {\n return (t < 0.5) ? (2 * t * t) : ((4 - 2 * t) * t - 1);\n}\n","import React, { useEffect, useRef, Suspense } from 'react';\nimport dynamic from 'next/dynamic';\nimport PropTypes from 'prop-types';\nimport {getSelectedIndex, mapLinks} from './helpers';\nimport Block from '../../adapters/helpers/Block';\nimport { scrollIntoView } from '../../adapters/helpers/Scroll';\nimport Loader from '../../adapters/helpers/Loader';\nconst ButtonTabsNavigation = dynamic(() => import('../ButtonTabsNavigation/ButtonTabsNavigation'));\nconst Eyebrow = dynamic(() => import('../Eyebrow/Eyebrow'));\nexport default function CollectionTabsDropdown(props) {\n const {extraAttributes, document} = props;\n\n const block = new Block(props);\n \n const title = document?.fields?.title;\n const subtitle = document?.fields?.surtitle;\n const extraClassNames = document?.fields?.classNames;\n const links = document?.fields?.links;\n const anchorId = block.getAnchorId();\n const currentURL = extraAttributes?.slug;\n const tabsRef = useRef();\n\n const classNames = ['ob-collection-tabs-dropdown'];\n if (extraClassNames) {\n classNames.push(extraClassNames);\n }\n\n const tabs = mapLinks(links);\n const selectedIndex = getSelectedIndex(links, currentURL.replace(/\\/$/, ''));\n\n if (typeof(selectedIndex) == 'undefined'){\n tabs && tabs.forEach((tab,index) => {\n if(tab?.link == currentURL.replace(/\\/$/, '')){\n selectedIndex = index;\n }\n });\n }\n\n useEffect(() => {\n if (window?.location?.hash === `#${anchorId}` && tabsRef?.current) {\n let timeout = null;\n window.setTimeout(() => {\n timeout = scrollIntoView(tabsRef.current, {behavior: 'smooth'});\n }, 250);\n\n return () => {\n clearTimeout(timeout);\n }\n }\n }, []);\n\n return (\n }>\n
\n {title}\n {subtitle && {subtitle} }\n
\n \n
\n
\n
\n )\n}\n\nCollectionTabsDropdown.propTypes = {\n extraAttributes: PropTypes.any,\n document: PropTypes.any,\n}","import {removeAnchorFromLink} from '../../adapters/helpers/Anchor';\n\nexport function getSelectedIndex(links, currentURL) {\n let selectedIndex = undefined;\n\n for(let i = 0 ; i < links.length; i++) {\n const link = links[i];\n const tabURL = link?.fields?.url;\n if(tabURL && removeAnchorFromLink(tabURL) === currentURL) {\n selectedIndex = i;\n }\n }\n\n return selectedIndex;\n}\n\nexport function mapLinks(links) {\n return links?.map(link => ({\n text: link?.fields?.title,\n link: link?.fields?.url,\n iconType:link?.fields?.iconType,\n assetLink: link?.fields?.asset?.fields?.file?.url,\n image:link?.fields?.image,\n mobileImage: link?.fields?.mobileImage,\n LinkAriaLabel: link?.fields?.linkAriaLabel\n })) || [];\n}","function _readOnlyError(name) {\n throw new TypeError(\"\\\"\" + name + \"\\\" is read-only\");\n}\n\nmodule.exports = _readOnlyError;\nmodule.exports[\"default\"] = module.exports, module.exports.__esModule = true;","(self[\"webpackChunk_N_E\"] = self[\"webpackChunk_N_E\"] || []).push([[9210],{\n\n/***/ 29254:\n/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(82109);\nvar createHTML = __webpack_require__(14230);\nvar forcedStringHTMLMethod = __webpack_require__(43429);\n\n// `String.prototype.link` method\n// https://tc39.github.io/ecma262/#sec-string.prototype.link\n$({ target: 'String', proto: true, forced: forcedStringHTMLMethod('link') }, {\n link: function link(url) {\n return createHTML(this, 'a', 'href', url);\n }\n});\n\n\n/***/ }),\n\n/***/ 55891:\n/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"z\": function() { return /* binding */ scrollIntoView; }\n/* harmony export */ });\nvar smoothScrollId = null;\nvar smoothScrollStartY = 0;\nvar smoothScrollDeltaY = 0;\nvar smoothScrollStartTime = 0;\nvar smoothScrollDuration = 400;\nfunction scrollIntoView(element) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n smoothScrollStartY = window.scrollY || window.pageYOffset || 0;\n smoothScrollDeltaY = element.getBoundingClientRect().top;\n var headerElement = document.querySelector('.zone-header');\n var productSubNavElement = document.querySelector('.ob-product-sub-nav');\n\n if (headerElement) {\n smoothScrollDeltaY -= headerElement.getBoundingClientRect().bottom;\n\n if (productSubNavElement) {\n smoothScrollDeltaY -= productSubNavElement.getBoundingClientRect().bottom;\n }\n }\n\n if (options.behavior === 'smooth' && typeof requestAnimationFrame !== 'undefined') {\n smoothScrollStartTime = Date.now();\n\n if (smoothScrollId == null) {\n smoothScrollStep();\n }\n } else {\n if (smoothScrollId != null) {\n cancelAnimationFrame(smoothScrollId);\n smoothScrollId = null;\n }\n\n window.scrollTo(window.scrollX, null);\n }\n}\n\nfunction smoothScrollStep() {\n var elapsed = Date.now() - smoothScrollStartTime;\n var t = elapsed / smoothScrollDuration;\n\n if (t < 1) {\n smoothScrollId = requestAnimationFrame(smoothScrollStep);\n window.scrollTo(window.scrollX, easeInOutQuad(t) * smoothScrollDeltaY + smoothScrollStartY);\n } else {\n smoothScrollId = null;\n window.scrollTo(window.scrollX, smoothScrollDeltaY + smoothScrollStartY);\n }\n}\n\nfunction easeInOutQuad(t) {\n return t < 0.5 ? 2 * t * t : (4 - 2 * t) * t - 1;\n}\n\n/***/ }),\n\n/***/ 9210:\n/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": function() { return /* binding */ CollectionTabsDropdown; }\n/* harmony export */ });\n/* harmony import */ var _home_runner_work_mw_mt_oralb_com_cs_cz_mw_mt_oralb_com_cs_cz_node_modules_next_dist_compiled_babel_runtime_helpers_readOnlyError_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(13579);\n/* harmony import */ var _home_runner_work_mw_mt_oralb_com_cs_cz_mw_mt_oralb_com_cs_cz_node_modules_next_dist_compiled_babel_runtime_helpers_readOnlyError_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_home_runner_work_mw_mt_oralb_com_cs_cz_mw_mt_oralb_com_cs_cz_node_modules_next_dist_compiled_babel_runtime_helpers_readOnlyError_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(41539);\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(88674);\n/* harmony import */ var core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_promise_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(74916);\n/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(15306);\n/* harmony import */ var core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(89554);\n/* harmony import */ var core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_for_each_js__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(54747);\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_6__);\n/* harmony import */ var core_js_modules_es_string_link_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(29254);\n/* harmony import */ var core_js_modules_es_string_link_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_link_js__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(69600);\n/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_8__);\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(67294);\n/* harmony import */ var next_dynamic__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(5152);\n/* harmony import */ var next_dynamic__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(next_dynamic__WEBPACK_IMPORTED_MODULE_10__);\n/* harmony import */ var _helpers__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(10139);\n/* harmony import */ var _adapters_helpers_Block__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(40483);\n/* harmony import */ var _adapters_helpers_Scroll__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(55891);\n/* harmony import */ var _adapters_helpers_Loader__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(47322);\n/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(85893);\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nvar ButtonTabsNavigation = next_dynamic__WEBPACK_IMPORTED_MODULE_10___default()(function () {\n return Promise.all(/* import() */[__webpack_require__.e(1664), __webpack_require__.e(8665), __webpack_require__.e(9986)]).then(__webpack_require__.bind(__webpack_require__, 30831));\n}, {\n loadableGenerated: {\n webpack: function webpack() {\n return [/*require.resolve*/(30831)];\n }\n }\n});\nvar Eyebrow = next_dynamic__WEBPACK_IMPORTED_MODULE_10___default()(function () {\n return Promise.all(/* import() */[__webpack_require__.e(4885), __webpack_require__.e(8765), __webpack_require__.e(9238), __webpack_require__.e(8996), __webpack_require__.e(7890)]).then(__webpack_require__.bind(__webpack_require__, 405));\n}, {\n loadableGenerated: {\n webpack: function webpack() {\n return [/*require.resolve*/(405)];\n }\n }\n});\nfunction CollectionTabsDropdown(props) {\n var _document$fields, _document$fields2, _document$fields3, _document$fields4;\n\n var extraAttributes = props.extraAttributes,\n document = props.document;\n var block = new _adapters_helpers_Block__WEBPACK_IMPORTED_MODULE_12__/* [\"default\"] */ .Z(props);\n var title = document == null ? void 0 : (_document$fields = document.fields) == null ? void 0 : _document$fields.title;\n var subtitle = document == null ? void 0 : (_document$fields2 = document.fields) == null ? void 0 : _document$fields2.surtitle;\n var extraClassNames = document == null ? void 0 : (_document$fields3 = document.fields) == null ? void 0 : _document$fields3.classNames;\n var links = document == null ? void 0 : (_document$fields4 = document.fields) == null ? void 0 : _document$fields4.links;\n var anchorId = block.getAnchorId();\n var currentURL = extraAttributes == null ? void 0 : extraAttributes.slug;\n var tabsRef = (0,react__WEBPACK_IMPORTED_MODULE_9__.useRef)();\n var classNames = ['ob-collection-tabs-dropdown'];\n\n if (extraClassNames) {\n classNames.push(extraClassNames);\n }\n\n var tabs = (0,_helpers__WEBPACK_IMPORTED_MODULE_11__/* .mapLinks */ .r)(links);\n var selectedIndex = (0,_helpers__WEBPACK_IMPORTED_MODULE_11__/* .getSelectedIndex */ .w)(links, currentURL.replace(/\\/$/, ''));\n\n if (typeof selectedIndex == 'undefined') {\n tabs && tabs.forEach(function (tab, index) {\n if ((tab == null ? void 0 : tab.link) == currentURL.replace(/\\/$/, '')) {\n index, _home_runner_work_mw_mt_oralb_com_cs_cz_mw_mt_oralb_com_cs_cz_node_modules_next_dist_compiled_babel_runtime_helpers_readOnlyError_js__WEBPACK_IMPORTED_MODULE_0___default()(\"selectedIndex\");\n }\n });\n }\n\n (0,react__WEBPACK_IMPORTED_MODULE_9__.useEffect)(function () {\n var _window, _window$location;\n\n if (((_window = window) == null ? void 0 : (_window$location = _window.location) == null ? void 0 : _window$location.hash) === \"#\".concat(anchorId) && (tabsRef == null ? void 0 : tabsRef.current)) {\n var timeout = null;\n window.setTimeout(function () {\n timeout = (0,_adapters_helpers_Scroll__WEBPACK_IMPORTED_MODULE_15__/* .scrollIntoView */ .z)(tabsRef.current, {\n behavior: 'smooth'\n });\n }, 250);\n return function () {\n clearTimeout(timeout);\n };\n }\n }, []);\n return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx)(react__WEBPACK_IMPORTED_MODULE_9__.Suspense, {\n fallback: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx)(_adapters_helpers_Loader__WEBPACK_IMPORTED_MODULE_13__[\"default\"], {}),\n children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsxs)(\"div\", {\n className: classNames.join(' '),\n id: anchorId,\n ref: tabsRef,\n children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx)(Eyebrow, {\n className: \"ob-collection-tabs-dropdown__eyebrow\",\n children: title\n }), subtitle && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx)(Eyebrow, {\n className: \"ob-collection-tabs-dropdown__eyebrow-subtitle\",\n children: subtitle\n }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx)(\"div\", {\n className: \"ob-collection-tabs-dropdown__tabs-wrapper\",\n children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx)(ButtonTabsNavigation, {\n tabs: tabs,\n selectedIndex: selectedIndex\n })\n })]\n })\n });\n}\n\n/***/ }),\n\n/***/ 10139:\n/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"r\": function() { return /* binding */ mapLinks; },\n/* harmony export */ \"w\": function() { return /* binding */ getSelectedIndex; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(21249);\n/* harmony import */ var core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _adapters_helpers_Anchor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(97020);\n\n\nfunction getSelectedIndex(links, currentURL) {\n var selectedIndex = undefined;\n\n for (var i = 0; i < links.length; i++) {\n var _link$fields;\n\n var link = links[i];\n var tabURL = link == null ? void 0 : (_link$fields = link.fields) == null ? void 0 : _link$fields.url;\n\n if (tabURL && (0,_adapters_helpers_Anchor__WEBPACK_IMPORTED_MODULE_1__/* .removeAnchorFromLink */ .gb)(tabURL) === currentURL) {\n selectedIndex = i;\n }\n }\n\n return selectedIndex;\n}\nfunction mapLinks(links) {\n return (links == null ? void 0 : links.map(function (link) {\n var _link$fields2, _link$fields3, _link$fields4, _link$fields5, _link$fields5$asset, _link$fields5$asset$f, _link$fields5$asset$f2, _link$fields6, _link$fields7, _link$fields8;\n\n return {\n text: link == null ? void 0 : (_link$fields2 = link.fields) == null ? void 0 : _link$fields2.title,\n link: link == null ? void 0 : (_link$fields3 = link.fields) == null ? void 0 : _link$fields3.url,\n iconType: link == null ? void 0 : (_link$fields4 = link.fields) == null ? void 0 : _link$fields4.iconType,\n assetLink: link == null ? void 0 : (_link$fields5 = link.fields) == null ? void 0 : (_link$fields5$asset = _link$fields5.asset) == null ? void 0 : (_link$fields5$asset$f = _link$fields5$asset.fields) == null ? void 0 : (_link$fields5$asset$f2 = _link$fields5$asset$f.file) == null ? void 0 : _link$fields5$asset$f2.url,\n image: link == null ? void 0 : (_link$fields6 = link.fields) == null ? void 0 : _link$fields6.image,\n mobileImage: link == null ? void 0 : (_link$fields7 = link.fields) == null ? void 0 : _link$fields7.mobileImage,\n LinkAriaLabel: link == null ? void 0 : (_link$fields8 = link.fields) == null ? void 0 : _link$fields8.linkAriaLabel\n };\n })) || [];\n}\n\n/***/ }),\n\n/***/ 13579:\n/***/ (function(module) {\n\nfunction _readOnlyError(name) {\n throw new TypeError(\"\\\"\" + name + \"\\\" is read-only\");\n}\n\nmodule.exports = _readOnlyError;\nmodule.exports[\"default\"] = module.exports, module.exports.__esModule = true;\n\n/***/ })\n\n}]);"],"names":["self","push","__unused_webpack_module","__unused_webpack_exports","__webpack_require__","$","createHTML","target","proto","forced","forcedStringHTMLMethod","link","url","__webpack_exports__","d","scrollIntoView","smoothScrollId","smoothScrollStartY","smoothScrollDeltaY","smoothScrollStartTime","element","options","arguments","length","undefined","window","scrollY","pageYOffset","getBoundingClientRect","top","headerElement","document","querySelector","productSubNavElement","bottom","behavior","requestAnimationFrame","Date","now","smoothScrollStep","t","elapsed","scrollTo","scrollX","easeInOutQuad","cancelAnimationFrame","r","CollectionTabsDropdown","_home_runner_work_mw_mt_oralb_com_cs_cz_mw_mt_oralb_com_cs_cz_node_modules_next_dist_compiled_babel_runtime_helpers_readOnlyError_js__WEBPACK_IMPORTED_MODULE_0__","_home_runner_work_mw_mt_oralb_com_cs_cz_mw_mt_oralb_com_cs_cz_node_modules_next_dist_compiled_babel_runtime_helpers_readOnlyError_js__WEBPACK_IMPORTED_MODULE_0___default","n","react__WEBPACK_IMPORTED_MODULE_9__","next_dynamic__WEBPACK_IMPORTED_MODULE_10__","next_dynamic__WEBPACK_IMPORTED_MODULE_10___default","_helpers__WEBPACK_IMPORTED_MODULE_11__","_adapters_helpers_Block__WEBPACK_IMPORTED_MODULE_12__","_adapters_helpers_Scroll__WEBPACK_IMPORTED_MODULE_15__","_adapters_helpers_Loader__WEBPACK_IMPORTED_MODULE_13__","react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__","ButtonTabsNavigation","Promise","all","e","then","bind","loadableGenerated","webpack","Eyebrow","props","_document$fields","_document$fields2","_document$fields3","_document$fields4","extraAttributes","block","Z","title","fields","subtitle","surtitle","extraClassNames","classNames","links","anchorId","getAnchorId","currentURL","slug","tabsRef","useRef","tabs","selectedIndex","w","replace","forEach","tab","index","useEffect","_window","_window$location","location","hash","concat","current","timeout","setTimeout","z","clearTimeout","jsx","Suspense","fallback","children","jsxs","className","join","id","ref","mapLinks","getSelectedIndex","_adapters_helpers_Anchor__WEBPACK_IMPORTED_MODULE_1__","i","_link$fields","tabURL","gb","map","_link$fields2","_link$fields3","_link$fields4","_link$fields5","_link$fields5$asset","_link$fields5$asset$f","_link$fields5$asset$f2","_link$fields6","_link$fields7","_link$fields8","text","iconType","assetLink","asset","file","image","mobileImage","LinkAriaLabel","linkAriaLabel","module","exports","name","__esModule"],"sourceRoot":""}