/**
 * Skipped minification because the original files appears to be already minified.
 * Original file: /npm/@iframe-resizer/child@5.4.6/index.umd.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
/*!
 *  @preserve
 *  
 *  @module      iframe-resizer/child 5.4.6 (umd) - 2025-04-24
 *
 *  @license     GPL-3.0 for non-commercial use only.
 *               For commercial use, you must purchase a license from
 *               https://iframe-resizer.com/pricing
 * 
 *  @description Keep same and cross domain iFrames sized to their content 
 *
 *  @author      David J. Bradshaw <info@iframe-resizer.com>
 * 
 *  @see         {@link https://iframe-resizer.com}
 * 
 *  @copyright  (c) 2013 - 2025, David J. Bradshaw. All rights reserved.
 */


!function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";const e="font-weight: normal;",t="font-weight: bold;",n="font-style: italic;",o=e+n,r="default",i=Object.freeze({assert:!0,error:!0,warn:!0}),a={expand:!0,defaultEvent:void 0,event:void 0,label:"AutoConsoleGroup",showTime:!0},s={profile:0,profileEnd:0,timeStamp:0,trace:0},l=Object.assign(console);const{fromEntries:c,keys:u}=Object,d=e=>[e,l[e]],f=e=>t=>[t,function(n){e[t]=n}],m=(e,t)=>c(u(e).map(t));const p=!(typeof window>"u"||"function"!=typeof window.matchMedia)&&window.matchMedia("(prefers-color-scheme: dark)").matches,h=p?"color: #A9C7FB;":"color: #135CD2;",g=p?"color: #E3E3E3;":"color: #1F1F1F;",y="5.4.6",b=10,v="data-iframe-size",z="data-iframe-overflowed",w="data-iframe-ignore",$="bottom",S="right",E="autoResizeEnabled",O=Symbol("sizeChanged"),j="manualResize",k="parentResize",M={[j]:1,[k]:1},T="setOffsetSize",C="resizeObserver",P="overflowObserver",A="mutationObserver",x="init",I=(e,t,n,o)=>e.addEventListener(t,n,o||!1),N=["<iy><yi>Puchspk Spjluzl Rlf</><iy><iy>","<iy><yi>Tpzzpun Spjluzl Rlf</><iy><iy>","Aopz spiyhyf pz hchpshisl dpao ivao Jvttlyjphs huk Vwlu-Zvbyjl spjluzlz.<iy><iy><i>Jvttlyjphs Spjluzl</><iy>Mvy jvttlyjphs bzl, <p>pmyhtl-ylzpgly</> ylxbpylz h svd jvza vul aptl spjluzl mll. Mvy tvyl pumvythapvu cpzpa <b>oaawz://pmyhtl-ylzpgly.jvt/wypjpun</>.<iy><iy><i>Vwlu Zvbyjl Spjluzl</><iy>Pm fvb hyl bzpun aopz spiyhyf pu h uvu-jvttlyjphs vwlu zvbyjl wyvqlja aolu fvb jhu bzl pa mvy myll bukly aol alytz vm aol NWS C3 Spjluzl. Av jvumpyt fvb hjjlwa aolzl alytz, wslhzl zla aol <i>spjluzl</> rlf pu <p>pmyhtl-ylzpgly</> vwapvuz av <i>NWSc3</>.<iy><iy>Mvy tvyl pumvythapvu wslhzl zll: <b>oaawz://pmyhtl-ylzpgly.jvt/nws</>","<i>NWSc3 Spjluzl Clyzpvu</><iy><iy>Aopz clyzpvu vm <p>pmyhtl-ylzpgly</> pz ilpun bzlk bukly aol alytz vm aol <i>NWS C3</> spjluzl. Aopz spjluzl hssvdz fvb av bzl <p>pmyhtl-ylzpgly</> pu Vwlu Zvbyjl wyvqljaz, iba pa ylxbpylz fvby wyvqlja av il wbispj, wyvcpkl haaypibapvu huk il spjluzlk bukly clyzpvu 3 vy shaly vm aol NUB Nlulyhs Wbispj Spjluzl.<iy><iy>Pm fvb hyl bzpun aopz spiyhyf pu h uvu-vwlu zvbyjl wyvqlja vy dlizpal, fvb dpss ullk av wbyjohzl h svd jvza vul aptl jvttlyjphs spjluzl.<iy><iy>Mvy tvyl pumvythapvu cpzpa <b>oaawz://pmyhtl-ylzpgly.jvt/wypjpun</>.","<iy><yi>Zvsv spjluzl kvlz uva zbwwvya jyvzz-kvthpu</><iy><iy>Av bzl <p>pmyhtl-ylzpgly</> dpao jyvzz kvthpu pmyhtlz fvb ullk lpaoly aol Wyvmlzzpvuhs vy Ibzpulzz spjluzlz. Mvy klahpsz vu bwnyhkl wypjpun wslhzl jvuahja pumv@pmyhtl-ylzpgly.jvt."];Object.fromEntries(["2cgs7fdf4xb","1c9ctcccr4z","1q2pc4eebgb","ueokt0969w","w2zxchhgqz","1umuxblj2e5"].map(((e,t)=>[e,Math.max(0,t-1)])));const R=e=>(e=>e.replace(/[A-Za-z]/g,(e=>String.fromCodePoint((e<="Z"?90:122)>=(e=e.codePointAt(0)+19)?e:e-26))))(N[e]),B=e=>{let t=!1;return function(){return t?void 0:(t=!0,Reflect.apply(e,this,arguments))}},q=e=>e,L=e=>Math.round(1e3*e)/1e3,F=e=>e.charAt(0).toUpperCase()+e.slice(1),W=e=>""!=`${e}`&&void 0!==e;const D=(e,t,n)=>{if(typeof e!==t)throw new TypeError(`${n} is not a ${F(t)}`)};let H=!0;const V=(U=function(n={}){const c={},u={},p=[],h={...a,expand:!n.collapsed||a.expanded,...n};let g="";function y(){p.length=0,g=""}function b(){delete h.event,y()}const v=()=>!!p.some((([e])=>e in i))||!!h.expand;function z(){if(0!==p.length){l[v()?"group":"groupCollapsed"](`%c${h.label}%c ${(e=>{const t=e.event||e.defaultEvent;return t?`${t}`:""})(h)} %c${h.showTime?g:""}`,e,t,o);for(const[e,...t]of p)l.assert(e in l,`Unknown console method: ${e}`),e in l&&l[e](...t);l.groupEnd(),b()}else b()}function w(){""===g&&(g=function(){const e=new Date,t=(t,n)=>e[t]().toString().padStart(n,"0");return`@ ${t("getHours",2)}:${t("getMinutes",2)}:${t("getSeconds",2)}.${t("getMilliseconds",3)}`}())}function $(e,...t){0===p.length&&(w(),queueMicrotask((()=>queueMicrotask(z)))),p.push([e,...t])}function S(e=r,...t){c[e]?$("log",`${e}: ${performance.now()-c[e]} ms`,...t):$("timeLog",e,...t)}return{...m(h,f(h)),...m(console,(e=>[e,(...t)=>$(e,...t)])),...m(s,d),assert:function(e,...t){e||$("assert",e,...t)},count:function(e=r){u[e]?u[e]+=1:u[e]=1,$("log",`${e}: ${u[e]}`)},countReset:function(e=r){delete u[e]},endAutoGroup:z,errorBoundary:e=>(...t)=>{let n;try{n=e(...t)}catch(e){if(!Error.prototype.isPrototypeOf(e))throw e;$("error",e)}return n},event:function(e){w(),h.event=e},purge:y,time:function(e=r){w(),c[e]=performance.now()},timeEnd:function(e=r){S(e),delete c[e]},timeLog:S,touch:w}},U?.__esModule?U.default:U);var U;const Z=V({label:"iframeResizer(child)"});var J;const _=(J="log",(...e)=>!H||Z[J](...e)),{assert:Q,debug:G,endAutoGroup:X,error:Y,errorBoundary:K,event:ee,label:te,purge:ne,warn:oe}=Z,re=e=>{return Z.warn((t=q,e=>window.chrome?t(e.replaceAll("<br>","\n").replaceAll("<rb>","[31;1m").replaceAll("</>","[m").replaceAll("<b>","[1m").replaceAll("<i>","[3m").replaceAll("<u>","[4m")):t(e.replaceAll("<br>","\n").replaceAll(/<[/a-z]+>/gi,"")))(e));var t},ie=re,ae=(e=>(t,n="renamed to")=>(o,r,i="",a="")=>e(a,`<rb>Deprecated ${t}(${o.replace("()","")})</>\n\nThe <b>${o}</> ${t.toLowerCase()} has been ${n} <b>${r}</>. ${i}Use of the old ${t.toLowerCase()} will be removed in a future version of <i>iframe-resizer</>.`))(((e,t)=>re(t))),se=ae("Method"),le=ae("Method","replaced with"),ce=ae("Option"),ue=e=>t=>void 0===t?void 0:e(t),de=ue((e=>"true"===e)),fe=ue(Number),me="--ifr-start",pe="--ifr-end",he=[],ge=new WeakSet,ye=e=>"object"==typeof e&&ge.add(e);let be={},ve=0;const ze=setInterval((()=>{if(he.length<10)return;if(be.hasTags&&be.len<25)return;he.sort();const e=Math.min(he.reduce(((e,t)=>e+t),0)/he.length,he[Math.floor(he.length/2)]),t=L(e);t>ve&&(ve=t,ee("performanceObserver")),e<=4||(clearInterval(ze),re(`<rb>Performance Warning</>\n\nCalculating the page size is taking an excessive amount of time (${L(e)}ms).\n\nTo improve performance add the <b>data-iframe-size</> attribute to the ${be.Side.toLowerCase()} most element on the page. For more details see: <u>https://iframe-resizer.com/perf</>.`))}),5e3);function we(e){e.getEntries().forEach((e=>{if(e.name===pe){const{duration:t}=performance.measure("--ifr-measure",me,pe);be=e.detail,he.push(t),he.length>100&&he.shift()}}))}function $e(){new PerformanceObserver(we).observe({entryTypes:["mark"]}),ye(document.documentElement),ye(document.body)}"undefined"!=typeof document&&"undefined"!=typeof PerformanceObserver&&("loading"===document.readyState?document.addEventListener("DOMContentLoaded",$e):$e());const Se=e=>(t,n)=>{if(n in t){if(typeof t[n]===e)return t[n];throw new TypeError(`${n} is not a ${e}.`)}},Ee=Se("function"),Oe=Se("number"),je=Se("string");"undefined"!=typeof window&&function(){const o={contentVisibilityAuto:!0,opacityProperty:!0,visibilityProperty:!0},r={height:()=>(oe("Custom height calculation function not defined"),zt.auto()),width:()=>(oe("Custom width calculation function not defined"),wt.auto())},i={bodyOffset:1,bodyScroll:1,offset:1,documentElementOffset:1,documentElementScroll:1,boundingClientRect:1,max:1,min:1,grow:1,lowestElement:1},a={},s="checkVisibility"in window,l="auto",c="[iFrameSizer]",u="scroll";let d,f,m,p,N,L=!0,V="",U=0,J="",G="",Y=!0,ae=!1,ue=!0,he=!1,ge=!1,ye=!1,be=1,ve=l,ze="",we=!0,$e={},Se=!0,ke=!1,Me="",Te=0,Ce=!1,Pe="",Ae=q,xe=[],Ie="child",Ne=null,Re=!1,Be="",qe=[],Le=window.parent,Fe="*",We=0,De=!1,He=1,Ve=u,Ue=window,Ze=()=>{oe("onMessage function not defined")},Je=()=>{},_e=null,Qe=null;function Ge(e){var t,n,o;!function(e){Pe=e[0]??Pe,U=fe(e[1])??U,ae=de(e[2])??ae,ke=de(e[3])??ke,L=de(e[6])??L,J=e[7]??J,ve=e[8]??ve,V=e[9]??V,G=e[10]??G,We=fe(e[11])??We,$e.enable=de(e[12])??!1,Ie=e[13]??Ie,Ve=e[14]??Ve,Ce=de(e[15])??Ce,d=fe(e[16])??d,f=fe(e[17])??f,Y=de(e[18])??Y,Me=e[19]??Me,p=e[20]??p,Te=fe(e[21])??Te,Se=de(e[23])??Se}(e),t={id:Pe,enabled:ke,expand:Se},Z.label(`${t.id}`),Z.expand(t.expand),H=t.enabled,function(){function e(e){N=Ee(e,"onBeforeResize")??N,Ze=Ee(e,"onMessage")??Ze,Je=Ee(e,"onReady")??Je,"number"==typeof e?.offset&&(ce("offset","offsetSize"),Y&&(d=Oe(e,"offset")??d),ae&&(f=Oe(e,"offset")??f)),"number"==typeof e?.offsetSize&&(Y&&(d=Oe(e,"offsetSize")??d),ae&&(f=Oe(e,"offsetSize")??f)),ze=je(e,"ignoreSelector")??ze,Be=je(e,"sizeSelector")??Be,Fe=je(e,"targetOrigin")??Fe,ve=e?.heightCalculationMethod||ve,Ve=e?.widthCalculationMethod||Ve}function t(e,t){return"function"==typeof e&&(re(`<rb>Deprecated Option(${t}CalculationMethod)</>\n\nThe use of <b>${t}CalculationMethod</> as a function is deprecated and will be removed in a future version of <i>iframe-resizer</>. Please use the new <b>onBeforeResize</> event handler instead.\n\nSee <u>https://iframe-resizer.com/api/child</> for more details.`),r[t]=e,e="custom"),e}if(1===Te)return;const n=window.iframeResizer||window.iFrameResizer;"object"==typeof n&&(e(n),ve=t(ve,"height"),Ve=t(Ve,"width"),_(`Set targetOrigin for parent: %c${Fe}`,h))}(),it(),function(){try{Re=1===Te||"iframeParentListener"in window.parent}catch(e){}}(),Te<0?ie(`${R(Te+2)}${R(2)}`):p?.codePointAt(0)>4||Te<2&&ie(R(3)),p&&""!==p&&"false"!==p?p!==y&&re(`<b>Version mismatch</>\n\nThe parent and child pages are running different versions of <i>iframe resizer</>.\n\nParent page: ${p} - Child page: ${y}.\n`):re("<rb>Legacy version detected on parent page</>\n\nDetected legacy version of parent page script. It is recommended to update the parent page to use <b>@iframe-resizer/parent</>.\n\nSee <u>https://iframe-resizer.com/setup/</> for more details.\n"),lt(),ct(),function(){let e=!1;const t=t=>document.querySelectorAll(`[${t}]`).forEach((n=>{e=!0,n.removeAttribute(t),n.toggleAttribute(v,!0)}));t("data-iframe-height"),t("data-iframe-width"),e&&re("<rb>Deprecated Attributes</>\n          \nThe <b>data-iframe-height</> and <b>data-iframe-width</> attributes have been deprecated and replaced with the single <b>data-iframe-size</> attribute. Use of the old attributes will be removed in a future version of <i>iframe-resizer</>.")}(),"BackCompat"===document.compatMode&&re("<rb>Quirks Mode Detected</>\n\nThis iframe is running in the browser's legacy <b>Quirks Mode</>, this may cause issues with the correct operation of <i>iframe-resizer</>. It is recommended that you switch to the modern <b>Standards Mode</>.\n\nFor more information see <u>https://iframe-resizer.com/quirks-mode</>.\n"),Ke(),1!==Te&&(Ue.parentIframe=Object.freeze({autoResize:e=>(D(e,"boolean","parentIframe.autoResize(enable) enable"),!1===ae&&!1===Y?(ee(E),re("Auto Resize can not be changed when <b>direction</> is set to 'none'."),!1):(!0===e&&!1===L?(L=!0,queueMicrotask((()=>jt(E,"Auto Resize enabled")))):!1===e&&!0===L&&(L=!1),Mt(0,0,"autoResize",JSON.stringify(L)),L)),close(){Mt(0,0,"close")},getId:()=>Pe,getOrigin:()=>(se("getOrigin()","getParentOrigin()"),m),getParentOrigin:()=>m,getPageInfo(e){if("function"==typeof e)return _e=e,Mt(0,0,"pageInfo"),void le("getPageInfo()","getParentProps()","See <u>https://iframe-resizer.com/upgrade</> for details. ");_e=null,Mt(0,0,"pageInfoStop")},getParentProps:e=>(D(e,"function","parentIframe.getParentProps(callback) callback"),Qe=e,Mt(0,0,"parentInfo"),()=>{Qe=null,Mt(0,0,"parentInfoStop")}),getParentProperties(e){se("getParentProperties()","getParentProps()"),this.getParentProps(e)},moveToAnchor(e){D(e,"string","parentIframe.moveToAnchor(anchor) anchor"),$e.findTarget(e)},reset(){!function(){const e=ve;ve=l,De||(De=!0,requestAnimationFrame((()=>{De=!1}))),kt("reset"),ve=e}()},setOffsetSize(e){D(e,"number","parentIframe.setOffsetSize(offset) offset"),d=e,f=e,jt(T,`parentIframe.setOffsetSize(${e})`)},scrollBy(e,t){D(e,"number","parentIframe.scrollBy(x, y) x"),D(t,"number","parentIframe.scrollBy(x, y) y"),Mt(t,e,"scrollBy")},scrollTo(e,t){D(e,"number","parentIframe.scrollTo(x, y) x"),D(t,"number","parentIframe.scrollTo(x, y) y"),Mt(t,e,"scrollTo")},scrollToOffset(e,t){D(e,"number","parentIframe.scrollToOffset(x, y) x"),D(t,"number","parentIframe.scrollToOffset(x, y) y"),Mt(t,e,"scrollToOffset")},sendMessage(e,t){t&&D(t,"string","parentIframe.sendMessage(msg, targetOrigin) targetOrigin"),Mt(0,0,"message",JSON.stringify(e),t)},setHeightCalculationMethod(e){ve=e,lt()},setWidthCalculationMethod(e){Ve=e,ct()},setTargetOrigin(e){D(e,"string","parentIframe.setTargetOrigin(targetOrigin) targetOrigin"),Fe=e},resize(e,t){e&&D(e,"number","parentIframe.resize(customHeight, customWidth) customHeight"),t&&D(t,"number","parentIframe.resize(customHeight, customWidth) customWidth"),jt(j,`parentIframe.resize(${e||""}${t?`,${t}`:""})`,e,t)},size(e,t){se("size()","resize()"),this.resize(e,t)}}),Ue.parentIFrame=Ue.parentIframe),function(){function e(e){Mt(0,0,e.type,`${e.screenY}:${e.screenX}`)}function t(t,n){I(window.document,t,e)}!0===Ce&&(t("mouseenter"),t("mouseleave"))}(),$e=function(){const e=()=>({x:document.documentElement.scrollLeft,y:document.documentElement.scrollTop});function t(t){const n=t.getBoundingClientRect(),o=e();return{x:parseInt(n.left,b)+parseInt(o.x,b),y:parseInt(n.top,b)+parseInt(o.y,b)}}function n(e){function n(e){const n=t(e);Mt(n.y,n.x,"scrollToOffset")}const o=e.split("#")[1]||e,r=decodeURIComponent(o),i=document.getElementById(r)||document.getElementsByName(r)[0];void 0===i?Mt(0,0,"inPageLink",`#${o}`):n(i)}function o(){const{hash:e,href:t}=window.location;""!==e&&"#"!==e&&n(t)}function r(){for(const e of document.querySelectorAll('a[href^="#"]'))"#"!==e.getAttribute("href")&&I(e,"click",(t=>{t.preventDefault(),n(e.getAttribute("href"))}))}function i(){I(window,"hashchange",o)}function a(){setTimeout(o,128)}function s(){r(),i(),a()}return $e.enable&&(1===Te?re("In page linking requires a Professional or Business license. Please see <u>https://iframe-resizer.com/pricing</> for more details."):s()),{findTarget:n}}(),void 0===J&&(J=`${U}px`),ot("margin",(n="margin",(o=J).includes("-")&&(oe(`Negative CSS value ignored for ${n}`),o=""),o)),ot("background",V),ot("padding",G),function(){const e=document.createElement("div");e.style.clear="both",e.style.display="block",e.style.height="0",document.body.append(e)}(),function(){const e=e=>e.style.setProperty("height","auto","important");e(document.documentElement),e(document.body)}(),function(e){at({method:e,eventType:"After Print",eventName:"afterprint"}),at({method:e,eventType:"Before Print",eventName:"beforeprint"}),at({method:e,eventType:"Ready State Change",eventName:"readystatechange"})}("add"),function(){const e=new Set,t=[];let n=!1,o=0;const r=t=>{_("Mutations observed:",t);for(const n of t){const{addedNodes:t,removedNodes:o}=n;for(const n of t)e.add(n);for(const t of o)e.delete(t)}},i=16,a=2,s=200;let l=1;function c(e){it(),et(e),e.forEach(ft),e.clear()}function u(){const d=performance.now(),f=d-o;if(f>i*l+++a&&f<s)return _("Backed off due to heavy workload on callStack"),setTimeout(u,i*l),void(o=d);l=1,t.forEach(r),t.length=0,e.size>0&&c(e),Ke(),Xe(),n=!1,jt(A,"Mutation Observed")}function d(e){t.push(e),n||(o=performance.now(),n=!0,requestAnimationFrame(u))}function f(){const e=new window.MutationObserver(d),t=document.querySelector("body"),n={attributes:!0,attributeFilter:[w,v],attributeOldValue:!1,characterData:!1,characterDataOldValue:!1,childList:!0,subtree:!0};return e.observe(t,n),e}f()}(),Ne=new ResizeObserver(ut),Ne.observe(document.body),dt.add(document.body),ft(document.body),Y!==ae&&(Ae=(e=>{const t=e.side||$,n=e.onChange||q,o={root:e.root,rootMargin:"0px",threshold:1},r=window?.requestAnimationFrame||q,i=(e=!1)=>n(e),a=(e,n)=>0===e||e>n[t],s=(e,t)=>e.toggleAttribute(z,t),l=new IntersectionObserver((function(e){for(const o of e){const{boundingClientRect:e,rootBounds:r,target:i}=o,l=e[t],c=a(l,r)&&!((n=i).hidden||null===n.offsetParent||"none"===n.style.display);s(i,c)}var n;r(i)}),o),c=new WeakSet;return function(e){for(const t of e){const e=t.nodeType===Node.ELEMENT_NODE,n=c.has(t);!n&&e?(l.observe(t),c.add(t)):Q(!n,"Node already observed",t)}}})({onChange:Ye,root:document.documentElement,side:Y?$:S})),et(ht(document)()),queueMicrotask(Je),jt(x,"Init message from host page",void 0,void 0,y),document.title&&""!==document.title&&Mt(0,0,"title",document.title)}function Xe(){xe=document.querySelectorAll(`[${z}]:not([${w}]):not([${w}] *)`),ge=xe.length>0}function Ye(e){Xe(),(ge||e)&&(ge?_("Overflowed Elements:",...xe):_("Overflow removed"),jt(P,"Overflow updated"))}function Ke(){qe=document.querySelectorAll(`[${v}]`),ye=qe.length>0}function et(e){ye||Ae(e)}let tt=0;function nt(){const n=document.querySelectorAll(`*[${w}]`);he=n.length>0,he&&n.length!==tt&&(function(n){const o=1===n.length?"":"s";oe(`%c[${w}]%c found on %c${n.length}%c element${o}`,t,e,t,e)}(n),tt=n.length)}function ot(e,t){void 0!==t&&""!==t&&"null"!==t&&(document.body.style.setProperty(e,t),_(`Set body ${e}: %c${t}`,h))}function rt(e,t,n){if(""!==n)for(const e of document.querySelectorAll(n))e.toggleAttribute(t,!0)}function it(){rt(0,v,Be),rt(0,w,ze)}function at(e){({add(t){function n(){jt(e.eventName,e.eventType)}a[t]=n,I(window,t,n,{passive:!0})},remove(e){const t=a[e];var n,o;delete a[e],n=e,o=t,window.removeEventListener(n,o,!1)}})[e.method](e.eventName)}function st(e,t,n,o){return t!==e&&(e in n||(oe(`${e} is not a valid option for ${o}CalculationMethod.`),e=t),e in i)&&re(`<rb>Deprecated ${o}CalculationMethod (${e})</>\n\nThis version of <i>iframe-resizer</> can auto detect the most suitable ${o} calculation method. It is recommended that you ${p?"remove this option.":"set this option to <b>'auto'</> when using an older version of <i>iframe-resizer</> on the parent page."}`),e}function lt(){ve=st(ve,l,zt,"height")}function ct(){Ve=st(Ve,u,wt,"width")}function ut(e){if(!Array.isArray(e)||0===e.length)return;const t=e[0].target;jt(C,`Element resized <${function(e){switch(!0){case!W(e):return"";case W(e.id):return`${e.nodeName}#${e.id}`;case W(e.name):return`${e.nodeName} (${e.name}`;case W(e.className):return`${e.nodeName}.${e.className}`;default:return e.nodeName}}(t)}>`)}const dt=new WeakSet;function ft(e){if(e.nodeType!==Node.ELEMENT_NODE)return;if(!dt.has(e)){const t=getComputedStyle(e)?.position;""!==t&&"static"!==t&&(Ne.observe(e),dt.add(e))}const t=ht(e)();for(const e of t){if(dt.has(e)||e?.nodeType!==Node.ELEMENT_NODE)continue;const t=getComputedStyle(e)?.position;""!==t&&"static"!==t&&(Ne.observe(e),dt.add(e))}}function mt(e){performance.mark(me);const t=F(e);let n=0,r=document.documentElement,i=ye?0:document.documentElement.getBoundingClientRect().bottom;const a=ye?qe:ge?xe:ht(document)();let l=a.length;for(const t of a)ye||!s||t.checkVisibility(o)?(n=t.getBoundingClientRect()[e]+parseFloat(getComputedStyle(t).getPropertyValue(`margin-${e}`)),n>i&&(i=n,r=t)):l-=1;return _(`${t} position calculated from:`,r),performance.mark(pe,{detail:{Side:t,len:l,hasTags:ye,logging:ke}}),i}const pt=e=>[e.bodyOffset(),e.bodyScroll(),e.documentElementOffset(),e.documentElementScroll(),e.boundingClientRect()],ht=e=>()=>{nt();const t=["* ","not(head)","not(meta)","not(base)","not(title)","not(script)","not(link)","not(style)","not(map)","not(area)","not(option)","not(optgroup)","not(template)","not(track)","not(wbr)","not(nobr)"];return he&&t.push(`not([${w}])`,`not([${w}] *)`),e.querySelectorAll(t.join(":"))},gt={height:0,width:0},yt={height:0,width:0},bt=[h,g,h];function vt(e){function t(){return yt[o]=r,gt[o]=s,r}const n=e===zt,o=n?"height":"width",r=e.boundingClientRect(),i=Math.ceil(r),a=Math.floor(r),s=(e=>e.documentElementScroll()+Math.max(0,e.getOffset()))(e),l=`HTML: %c${r}px %cPage: %c${s}px`;let c=0;switch(!0){case!e.enabled():return s;case ye:_("Found element with data-iframe-size attribute"),c=e.taggedElement();break;case!ge&&0===yt[o]&&0===gt[o]:_(`Initial page size values: ${l}`,...bt),c=t();break;case De&&r===yt[o]&&s===gt[o]:_(`Size unchanged: ${l}`,...bt),c=Math.max(r,s);break;case 0===r:_(`Page is hidden: ${l}`,...bt),c=s;break;case!ge&&r!==yt[o]&&s<=gt[o]:_(`New <html> size: ${l} `,...bt),_(`Previous <html> size: %c${yt[o]}px`,h),c=t();break;case!n:c=e.taggedElement();break;case!ge&&r<yt[o]:_(`<html> size decreased: ${l}`,...bt),c=t();break;case s===a||s===i:_(`<html> size equals page size: ${l}`,...bt),c=t();break;case r>s:_(`Page size < <html> size: ${l}`,...bt),c=t();break;case ge:_("Found element overflowing <html> "),c=e.taggedElement();break;default:_(`Using <html> size: ${l}`,...bt),c=t()}return _(`Content ${o}: %c${c}px`,h),c+=function(e){const t=e.getOffset();return 0!==t&&_(`Page offsetSize: %c${t}px`,h),t}(e),c}const zt={enabled:()=>Y,getOffset:()=>d,auto:()=>vt(zt),bodyOffset:()=>{const{body:e}=document,t=getComputedStyle(e);return e.offsetHeight+parseInt(t.marginTop,b)+parseInt(t.marginBottom,b)},bodyScroll:()=>document.body.scrollHeight,offset:()=>zt.bodyOffset(),custom:()=>r.height(),documentElementOffset:()=>document.documentElement.offsetHeight,documentElementScroll:()=>document.documentElement.scrollHeight,boundingClientRect:()=>Math.max(document.documentElement.getBoundingClientRect().bottom,document.body.getBoundingClientRect().bottom),max:()=>Math.max(...pt(zt)),min:()=>Math.min(...pt(zt)),grow:()=>zt.max(),lowestElement:()=>mt($),taggedElement:()=>mt($)},wt={enabled:()=>ae,getOffset:()=>f,auto:()=>vt(wt),bodyScroll:()=>document.body.scrollWidth,bodyOffset:()=>document.body.offsetWidth,custom:()=>r.width(),documentElementScroll:()=>document.documentElement.scrollWidth,documentElementOffset:()=>document.documentElement.offsetWidth,boundingClientRect:()=>Math.max(document.documentElement.getBoundingClientRect().right,document.body.getBoundingClientRect().right),max:()=>Math.max(...pt(wt)),min:()=>Math.min(...pt(wt)),rightMostElement:()=>mt(S),scroll:()=>Math.max(wt.bodyScroll(),wt.documentElementScroll()),taggedElement:()=>mt(S)},$t=(e,t)=>!(Math.abs(e-t)<=We);function St(e,t){const n=e[t]();return e.enabled()&&void 0!==N?function(e){const t=N(e);if(void 0===t)throw new TypeError("No value returned from onBeforeResize(), expected a numeric value");if(Number.isNaN(t))throw new TypeError(`Invalid value returned from onBeforeResize(): ${t}, expected Number`);return t}(n):n}let Et=!1;const Ot=B((()=>ie(R(4)))),jt=K(((e,t,n,o,r)=>{if(performance.now(),ee(e),!0!==Et)return L||e in M?void(document.hidden||(Et=!0,requestAnimationFrame((()=>{Et=!1})),function(e,t,n,o,r){const i=n??St(zt,ve),a=o??St(wt,Ve);switch(Y&&$t(be,i)||ae&&$t(He,a)?O:e){case x:case E:case O:be=i,He=a;case T:Mt(be,He,e,r);break;case C:case P:case A:ne();break;default:ne(),_("No change in content size detected")}}(e,0,n,o,r))):(_("Resizing disabled"),void X())}));function kt(e){be=zt[ve](),He=wt[Ve](),Mt(be,He,e)}const Mt=K((function(e,t,o,r,i){Te<-1||(ee(o),void 0!==i||(i=Fe),function(){const a=`${Pe}:${e}:${t}:${o}${void 0===r?"":`:${r}`}`;if(Re)try{window.parent.iframeParentListener(c+a)}catch(e){if(1!==Te)throw e;return void Ot()}else Le.postMessage(c+a,i);_(`Sending message to parent page via ${Re?"sameOrigin":"postMessage"}: %c%c${a}`,n,h)}(),X())})),Tt=K((function(e){ee("onMessage");const{freeze:t}=Object,{parse:n}=JSON,o=e=>Mt(0,0,`${e}Stop`),r={init:function(){if("loading"===document.readyState)return;const t=e.data.slice(13).split(":");Le=e.source,m=e.origin,Ge(t),ue=!1,setTimeout((()=>{we=!1}),128)},reset(){we||kt("resetPage")},resize(){jt(k,"Parent window requested size check")},moveToAnchor(){$e.findTarget(a())},inPageLink(){this.moveToAnchor()},pageInfo(){const e=a();_e?setTimeout((()=>_e(n(e)))):o("pageInfo")},parentInfo(){const e=(r=a(),t(n(r)));var r;Qe?setTimeout((()=>Qe(e))):o("parentInfo")},message(){const e=a();setTimeout((()=>Ze(n(e))))}},i=()=>e.data.split("]")[1].split(":")[0],a=()=>e.data.slice(e.data.indexOf(":")+1),s=()=>e.data.split(":")[2]in{true:1,false:1};function l(){const t=i();ee(t),t in r?r[t]():"iframeResize"in window||void 0!==window.jQuery&&""in window.jQuery.prototype||s()||oe(`Unexpected message (${e.data})`)}c===`${e.data}`.slice(0,13)&&function(){if(!1!==ue)return s()?(te(i()),ee(x),void r.init()):void 0;l()}()}));function Ct(){"loading"!==document.readyState&&window.parent.postMessage("[iFrameResizerChild]Ready","*")}"iframeChildListener"in window?oe("Already setup"):(window.iframeChildListener=e=>setTimeout((()=>Tt({data:e,sameOrigin:!0}))),I(window,"message",Tt),I(window,"readystatechange",Ct),Ct())}()}));
