1(self.webpackChunkaem_module_ui_frontend=self.webpackChunkaem_module_ui_frontend||[]).push([[3536],{3536:(t,e,i)=>{"use strict";i.r(e),i.d(e,{default:()=>l});var n=i(2749),s=i(9755),o=i.n(s),a=i(5789),c=i(3493),r=i.n(c),h=i(8353);class l extends n.Z{constructor(t){super(t),this.NAV_BTN_SELECTOR=".js-cmp-sections-outline__vertical-tab__item",this.ACCORDION_BTN_SELECTOR=".js-cmp-accordion__button",this.ACCORDION_BTN_CLASS="cmp-accordion__button",this.SECTION_CONTAINER_SELECTOR=".cmp-sections-outline__content__container",this.NAV_CONTAINER_SELECTOR=".js-cmp-sections-outline__vertical-tab",this.NAV_BTN_ACTIVE_CLASS="cmp-sections-outline__vertical-tab__item--active",this.NAV_ITEM_CLASS="cmp-sections-outline__vertical-tab__item",this.SCROLL_LINK_SELECTOR=".js-section-outline-scroll-link",this.TAB_NAVIGATION_SELECTOR=".cmp-tab-navigation__desktop-container",this.C_RIBBON_CONTAINER=".cmp-ribbon__container",this.HEADER_REDUCED_DIV_FOR_DESKTOP=".cmp-header-v2__content",this.HEADER_STICKY_DIV_MOBILE=".cmp-header-v2__site",this.HEADER_OUTER_DIV=".header-v2",this.$WINDOW=o()(window),this.offsetsTop=[],this.isAlternative=!1,this.topFirst=!1,this.activeIndex=0,this.prevActiveIndex=0,this.contentMarginTop=50,this.currentAccordionBtn=null,this.currentAccordionSection=null,this.lastScrollTop=0,this.isInitializing=!1,this.contentToNavIndexMap=[],this.defaultScrollLinkActiveIndex=-1,this.DEBUG_PARAM="sectionsOutlineDebug",this.btnClick=(t,e)=>{this.clickTimeout&&clearTimeout(this.clickTimeout),this.isClicking=!0,t.preventDefault();const i=e||t.currentTarget||t.target,n=(i.getAttribute("href")||"").split("#")[1],s=document.getElementById(n);if(!s)return void(this.isClicking=!1);const o=i.getAttribute("data-sectionindex"),a=null!==o?parseInt(o,10):NaN,c=this.$navButtons.index(i);if(this.prevActiveIndex=this.activeIndex,c>=0)this.activeIndex=c;else if(!Number.isNaN(a)){const t=this.getNavButtonIndexBySectionIndex(a);t>=0&&(this.activeIndex=t)}if(this.activeIndex<0){const t=this.isScrollLinkNavIndex(this.defaultScrollLinkActiveIndex)?this.defaultScrollLinkActiveIndex:this.getFirstScrollLinkNavIndex();t>=0&&(this.activeIndex=t)}const r=document.querySelector(".cmp-tab-navigation__desktop-container"),l=document.querySelector(".cmp-header-v2__content"),d=document.querySelector(".cmp-header-v2__site");let u=0;r&&r.getBoundingClientRect().height>0?u=r.getBoundingClientRect().bottom:l&&l.getBoundingClientRect().height>0?u=l.getBoundingClientRect().bottom:d&&(u=d.getBoundingClientRect().bottom);const v=s.getBoundingClientRect().top-u;if(v>=-10&&v<=120)return this.updateNavHighlight(this.activeIndex),void(this.clickTimeout=setTimeout((()=>{this.isClicking=!1}),500));h.f.scrollToTarget(s,!0),this.updateNavHighlight(this.activeIndex),this.clickTimeout=setTimeout((()=>{this.isClicking=!1}),2500)},this.clickTimeout=null,this.windowScroll=()=>{!1===this.isClicking&&(this.isInitializing||(this.resetFixedElementsHeight(),this.changeActiveNavBasedOnScrollPosition(),this.updateNavHighlight(this.activeIndex),this.throttledAdjustNavContainerTop(),this.lastScrollTop=window.scrollY))},this.$navButtons=o()(this.NAV_BTN_SELECTOR,this.$cmp),this.$accordionBtns=o()(this.ACCORDION_BTN_SELECTOR,this.$cmp),this.$tabNavigation=o()(this.TAB_NAVIGATION_SELECTOR),this.$contentContainer=o()(this.SECTION_CONTAINER_SELECTOR,this.$cmp),this.$verticalNavContainer=o()(this.NAV_CONTAINER_SELECTOR,this.$cmp),this.isAlternative=void 0!==this.$verticalNavContainer.data("isAlternative"),this.topFirst=void 0!==this.$verticalNavContainer.data("topFirst"),this.$ribbonContainer=o()(this.C_RIBBON_CONTAINER),this.ribbonHeight=this.$ribbonContainer.outerHeight()||0,this.$headerTopDivDesktop=o()(this.HEADER_STICKY_DIV_MOBILE),this.$headerBottomDivDesktop=o()(this.HEADER_REDUCED_DIV_FOR_DESKTOP),this.$headerStickyDivMobile=o()(this.HEADER_STICKY_DIV_MOBILE),this.$headerOuterDiv=o()(this.HEADER_OUTER_DIV),this.headerHeight=this.$headerOuterDiv.outerHeight()||0,this.isDesktop=["lg","xl"].includes((0,a.Z)()),this.isClicking=!1,this.buildContentToNavIndexMap(),this.throttledAdjustNavContainerTop=r()(this.adjustNavContainerTop.bind(this),100);const e=document.querySelector(this.SECTION_CONTAINER_SELECTOR);if(e){const t=o()(e).find('.cmp-accordion__button[data-index="0"]');t.length>0&&([this.currentAccordionBtn]=t,this.currentAccordionSection=e)}let i=!1;const n=this.$verticalNavContainer.data("defaultActiveNav");if(n){const t=parseInt(n,10)-1;t>=0&&t<this.$navButtons.length&&this.isScrollLinkNavIndex(t)&&(this.isInitializing=!0,this.activeIndex=t,i=!0)}if(!this.isScrollLinkNavIndex(this.activeIndex)){const t=this.getFirstScrollLinkNavIndex();t>=0&&(this.activeIndex=t)}this.defaultScrollLinkActiveIndex=this.activeIndex,this.updateNavHighlight(this.activeIndex),this.bindComponentEvents(),i?setTimeout((()=>{const t=this.$navButtons.eq(this.activeIndex);if(t.length>0){const e=(t.attr("href")||"").split("#")[1],i=document.getElementById(e);if(i){const t=this.$tabNavigation.outerHeight()||0;this.resetFixedElementsHeight();const e=i.getBoundingClientRect().top+window.pageYOffset-this.headerHeight-t-50;window.scrollTo({top:e,behavior:"smooth"}),setTimeout((()=>{this.isInitializing=!1}),1200)}}}),100):this.isInitializing=!1,window.addEventListener("resize",(()=>{this.resetFixedElementsHeight(),this.adjustNavContainerTop()}),{passive:!0})}bindComponentEvents(){this.bindNavItemClick(),this.bindScrollEvents(),this.adjustNavContainerTop()}getNavButtonIndexBySectionIndex(t){let e=-1;return this.$navButtons.each(((i,n)=>{if(-1!==e)return;const s=n.getAttribute("data-sectionindex"),o=null!==s?parseInt(s,10):NaN;Number.isNaN(o)||o!==t||(e=i)})),e}buildContentToNavIndexMap(){this.contentToNavIndexMap=[],this.$contentContainer.each(((t,e)=>{const i=e.getAttribute("data-sectionindex"),n=null!==i?parseInt(i,10):t;if(Number.isNaN(n))return void this.contentToNavIndexMap.push(t);const s=this.getNavButtonIndexBySectionIndex(n);this.contentToNavIndexMap.push(s>=0?s:t)})),this.debugLog("contentToNavIndexMap",this.contentToNavIndexMap)}isDebugEnabled(){try{return new URLSearchParams(window.location.search).has(this.DEBUG_PARAM)}catch(t){return!1}}debugLog(t,...e){this.isDebugEnabled()}isScrollLinkNavIndex(t){if(t<0||t>=this.$navButtons.length)return!1;const e=this.$navButtons.eq(t),i=e.hasClass("js-section-outline-scroll-link"),n=e.hasClass("js-section-outline-page-link"),s=(e.attr("href")||"").trim(),o=s.startsWith("#"),a=i&&!n&&o;return this.debugLog("isScrollLinkNavIndex",{index:t,isScrollLink:i,isPageLinkClass:n,isHashLink:o,isEligible:a,href:s,dataPageLink:this.$navButtons.eq(t).attr("data-pagelink")||""}),a}getFirstScrollLinkNavIndex(){let t=-1;return this.$navButtons.each(((e,i)=>{-1===t&&this.isScrollLinkNavIndex(e)&&(t=e)})),t}bindNavItemClick(){o()(this.SCROLL_LINK_SELECTOR,this.$cmp).on("click",(t=>{t.preventDefault(),this.btnClick(t.originalEvent,t.currentTarget)}))}adjustNavContainerTop(){const t=this.$tabNavigation.outerHeight()||0,e=(this.$headerOuterDiv.outerHeight()||0)+t+20;this.isDesktop?this.$verticalNavContainer.css("top",e):this.$verticalNavContainer.css("top","")}resetFixedElementsHeight(){var t;this.isDesktop=["lg","xl"].includes((0,a.Z)()),this.headerHeight=(null===(t=this.$headerBottomDivDesktop)||void 0===t?void 0:t.outerHeight())||0,this.isDesktop||(this.headerHeight=this.$headerStickyDivMobile.outerHeight()||0)}bindScrollEvents(){window.removeEventListener("scroll",this.windowScroll),window.addEventListener("scroll",this.windowScroll)}changeActiveNavBasedOnScrollPosition(){const{scrollY:t}=window,e=t<this.lastScrollTop;let{contentMarginTop:i}=this,n=!1;i=e?0:this.contentMarginTop;let s=!0;if(this.$contentContainer.each(((e,o)=>{var a;const c=o.getBoundingClientRect().top||0,r=c+(o.getBoundingClientRect().height||0),h=window.pageYOffset+c-this.headerHeight-i,l=window.pageYOffset+r-this.headerHeight-i;if(t<=l&&h<=t&&!0===s){const i=null!==(a=this.contentToNavIndexMap[e])&&void 0!==a?a:e;this.debugLog("scroll match candidate",{contentIndex:e,mappedNavIndex:i,scrollY:t,calculatedTop:h,calculatedBottom:l}),this.isScrollLinkNavIndex(i)&&(this.activeIndex=i),n=!0,s=!1}})),!n&&this.$contentContainer.length>0){const e=this.$contentContainer.get(0);if(e){const n=window.pageYOffset+e.getBoundingClientRect().top-this.headerHeight-i;if(t<n){const t=this.isScrollLinkNavIndex(this.defaultScrollLinkActiveIndex)?this.defaultScrollLinkActiveIndex:this.getFirstScrollLinkNavIndex();t>=0&&(this.activeIndex=t)}}}}updateNavHighlight(t){if(this.$navButtons.removeClass(this.NAV_BTN_ACTIVE_CLASS),!this.isScrollLinkNavIndex(t))return void this.debugLog("skip highlight for non-eligible index",{index:t});const e=this.$navButtons.eq(t);this.debugLog("highlight index",{index:t,text:e.text().trim()}),e.addClass(this.NAV_BTN_ACTIVE_CLASS)}}},8353:(t,e,i)=>{"use strict";i.d(e,{f:()=>s});
1class n{constructor(){this.lastOffset=0,this.suppressHashChange=!1,this.tabNavNaturalTopCache=0,this.ribbon=document.querySelector(".cmp-ribbon__container"),this.header=document.querySelector(".header-v2"),this.headerTopDiv=document.querySelector(".cmp-header-v2__site"),this.headerBottomDiv=document.querySelector(".cmp-header-v2__content"),this.tabNav=document.querySelector(".cmp-tab-navigation__container"),this.init()}calculateOffset(){return this.calculateOffsetForScrollPosition(window.scrollY)}calculateOffsetForScrollPosition(t,e){var i,n,s,o;let a=0;const c=(null===(i=this.ribbon)||void 0===i?void 0:i.offsetHeight)||0,r=(null===(n=this.headerTopDiv)||void 0===n?void 0:n.offsetHeight)||0,h=(null===(s=this.headerBottomDiv)||void 0===s?void 0:s.offsetHeight)||0,l=(null===(o=this.header)||void 0===o?void 0:o.offsetHeight)||0,d=window.scrollY,u=window.innerWidth<1200;let v;if(v=void 0!==e?"up"===e:t<d,this.ribbon&&t<=c&&(a+=c),this.header)if(u)a+=r;else if(v)a+=l;else{a+=t>=c+r?h:l}if(this.tabNav){const e=this.tabNav.classList.contains("cmp-tab-navigation__container--fixed"),i=this.tabNav.querySelector(".cmp-tab-navigation__desktop-container"),n=(null==i?void 0:i.offsetHeight)||this.tabNav.offsetHeight||0,s=this.tabNav.getBoundingClientRect().top+d;e||(this.tabNavNaturalTopCache=s);const o=e&&this.tabNavNaturalTopCache>0?this.tabNavNaturalTopCache:s;let c;c=u?r:v?l:h;const g=o-c,p=t-a>=g;if(t-a-n>=g){a+=n;!e&&!v&&!u&&(a+=n)}else p&&(a+=n)}return a+=10,a}updateOffset(){const t=this.calculateOffset();t!==this.lastOffset&&(document.documentElement.style.setProperty("--scroll-offset",`${t}px`),this.lastOffset=t)}refresh(){this.ribbon=document.querySelector(".cmp-ribbon__container"),this.header=document.querySelector(".header-v2"),this.headerTopDiv=document.querySelector(".cmp-header-v2__site"),this.headerBottomDiv=document.querySelector(".cmp-header-v2__content"),this.tabNav=document.querySelector(".cmp-tab-navigation__container"),this.updateOffset()}scrollToTarget(t,e=!0,i=!1){const s="string"==typeof t?document.querySelector(t):t;if(!s)return;const o=s.getBoundingClientRect().top+window.pageYOffset,a=o<window.scrollY?"up":"down",c=this.calculateOffsetForScrollPosition(o,a),r=this.avoidTabNavDangerBand(Math.max(0,o-c));window.scrollTo({top:r,behavior:e?"smooth":"instant"}),n.verifyLargeShiftOnce(s,c,r),i&&"string"==typeof t&&t.startsWith("#")&&(this.suppressHashChange=!0,window.history.replaceState(null,"",window.location.pathname+window.location.search+t))}static verifyLargeShiftOnce(t,e,i){let n=-1,s=0,o=0;const a=window.setInterval((()=>{o+=1,window.scrollY===n?s+=1:(s=0,n=window.scrollY),(s>=6||o>=60)&&(window.clearInterval(a),window.setTimeout((()=>{const n=t.getBoundingClientRect().top-e;if(n>40){const t=window.scrollY+n;window.scrollTo({top:t,behavior:"instant"})}else n<-40&&(window.location.hash&&window.history.replaceState(null,"",window.location.pathname+window.location.search),window.scrollTo({top:i,behavior:"instant"}))}),250))}),50)}avoidTabNavDangerBand(t){var e;if(!this.tabNav||this.tabNavNaturalTopCache<=0)return t;const i=(null===(e=this.headerBottomDiv)||void 0===e?void 0:e.offsetHeight)||0;if(i<=0)return t;const n=this.tabNavNaturalTopCache-i;if(t>n-i&&t<n){return n+5}return t}static waitForScrollSettle(t){let e=-1,i=0,n=0;const s=window.setInterval((()=>{n+=1,window.scrollY===e?i+=1:(i=0,e=window.scrollY),(i>=6||n>=60)&&(window.clearInterval(s),window.setTimeout(t,200))}),50)}getLiveStickyStackBottom(){let t=0;if(this.header){const e=this.header.getBoundingClientRect();(e.top<=0&&e.bottom>
10||e.top>=0&&e.top<10)&&(t=Math.max(t,e.bottom))}if(this.tabNav&&this.tabNav.classList.contains("cmp-tab-navigation__container--fixed")){const e=this.tabNav.querySelector(".cmp-tab-navigation__desktop-container");e&&(t=Math.max(t,e.getBoundingClientRect().bottom))}return t}init(){let t;"loading"===document.readyState?document.addEventListener("DOMContentLoaded",(()=>{this.updateOffset(),this.handleHashOnLoad()})):(this.updateOffset(),this.handleHashOnLoad()),"complete"!==document.readyState&&window.addEventListener("load",(()=>{if(this.tabNavNaturalTopCache=0,this.updateOffset(),window.location.hash){const{hash:t}=window.location;setTimeout((()=>{this.scrollToTarget(t,!1)}),50)}})),this.interceptAnchorClicks(),window.addEventListener("hashchange",(()=>{this.suppressHashChange?this.suppressHashChange=!1:window.location.hash&&this.scrollToTarget(window.location.hash,!0)})),window.addEventListener("resize",(()=>{clearTimeout(t),t=window.setTimeout((()=>{this.updateOffset(),window.location.hash&&this.scrollToTarget(window.location.hash,!1)}),150)})),this.observeClassChanges()}interceptAnchorClicks(){document.addEventListener("click",(t=>{const e=t.target.closest('a[href*="#"]');if(!e)return;const i=e.getAttribute("href");if(!i)return;if(-1===i.indexOf("#"))return;let n;try{n=new URL(i,window.location.href)}catch(t){return}const{hash:s}=n;if(!s||"#"===s)return;if(!(n.origin===window.location.origin&&n.pathname===window.location.pathname))return;if(e.closest(".cmp-tab-navigation__container"))return;if(e.closest(".cmp-sections-outline__vertical-tab"))return;if(e.closest(".cmp-tab-navigation__container"))return;if(e.closest(".cmp-sections-outline__vertical-tab"))return;if(e.closest(".cmp-glossary"))return;const o=s.substring(1);let a=null;try{a=document.querySelector(s)}catch(t){a=document.getElementById(o)}a&&(t.preventDefault(),this.scrollToTarget(a,!0,!0))}),{capture:!0})}observeClassChanges(){const t=new MutationObserver((t=>{t.forEach((t=>{if("attributes"===t.type&&"class"===t.attributeName){t.target}})),this.updateOffset()})),e={attributes:!0,attributeFilter:["class"]};this.ribbon&&t.observe(this.ribbon,e),this.header&&t.observe(this.header,e),this.tabNav&&t.observe(this.tabNav,e)}handleHashOnLoad(){const{hash:t}=window.location;t&&(window.history.replaceState(null,"",window.location.pathname+window.location.search),setTimeout((()=>{this.scrollToTarget(t,!1,!0)}),100))}}window.cudaScrollOffsetCalculator||(window.cudaScrollOffsetCalculator=new n);const s=window.cudaScrollOffsetCalculator}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.