(self.webpackChunklite=self.webpackChunklite||[]).push([[5064],{28859:(e,t,r)=>{"use strict";r.d(t,{u6:()=>c,Am:()=>u,TA:()=>l});var a=r(63038),n=r.n(a),i=r(67294),o={updateWatchedBounds:function(){},watchedBounds:new Map},c=i.createContext(o),u=function(e){var t=new Map,r=i.useState(t),a=n()(r,2),o=a[0],u=a[1],l={offset:{left:0,right:0,top:0,bottom:0}},p={watchedBounds:o,updateWatchedBounds:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l;u((function(a){var n=new Map(a);return n.set(e,{ref:t,opts:r}),n}))}};return i.createElement(c.Provider,{value:p},e.children)},l=function(e){var t=e.children,r=e.className,a=e.name,n=e.type,o=e.offset,u=i.useContext(c).updateWatchedBounds,l=i.useRef(null);return i.useEffect((function(){u&&u(a,l,{type:n,offset:o})}),[]),i.createElement("div",{className:r,ref:l},t)}},50391:(e,t,r)=>{"use strict";r.d(t,{Jj:()=>qe,_V:()=>Ce,ZP:()=>ke});var a=r(28655),n=r.n(a),i=r(34575),o=r.n(i),c=r(93913),u=r.n(c),l=r(2205),p=r.n(l),h=r(78585),s=r.n(h),g=r(29754),f=r.n(g),d=r(71439),m=r(67294),v=r(28859),E=r(59713),x=r.n(E),y=r(63038),S=r.n(y),T=r(12291),b=r(79914),R=r(93340),w=r(25309),P=r(319),_=r.n(P),I=r(67995),O=r(24438),W=r(28309),N=r(80637),k=function(e){return function(t){return x()({marginTop:"10px",textAlign:e,maxWidth:"".concat((0,O.G)(t,8,!0),"px"),marginLeft:"left"===e?"0":"auto",marginRight:"auto"},N.lg(t),{marginLeft:"auto",textAlign:"center"})}},q=function(e){return function(){var t=e&&100*e;return{width:"".concat(t,"%"),position:"relative",left:"calc(".concat(100-t/2,"% - 8px)"),transform:"translateX(-50%)"}}};const C=m.forwardRef((function(e,t){var r=e.children,a=e.richTextStyle,n=e.textAlign,i=void 0===n?"center":n,o=e.extendLeftRatio,c=(0,W.Iq)(),u=(0,I.n)({name:"detail",scale:"CARD"===a||"SHORTFORM_CARD"===a?"S":"M",color:"LIGHTER"});return m.createElement("figcaption",{className:c([k(i),u].concat(_()(o?[q(o)]:[]))),ref:t},r)}));function L(e){var t=e.children,r=e.figCaption,a=e.className,n=e.figureRef;return m.createElement("figure",{className:a,ref:n},t,r)}var B=r(67154),M=r.n(B),A=r(72955),H=r(41331),F=r(53006),U=function(e){return{backgroundColor:e.baseColor.background.normal}},j=function(){return{width:"1px",minWidth:"100%","*width":"100%"}};const D=(0,T.$j)((function(e){return{isAmp:e.config.isAmp}}))((function(e){var t,r=e.src,a=e.title,n=e.height,i=e.width,o=e.allowFullScreen,c=e.frameBorder,u=e.thumbnailUrl,l=e.rules,p=e.placeholderRef,h=e.iframeRef,s=e.isAmp,g=(0,W.Iq)(),f={src:r,allowFullScreen:o,frameBorder:c,height:n,width:i},d=m.useState(!1),v=S()(d,2),E=v[0],x=v[1],y=m.useState(!1),T=S()(y,2),b=T[0],R=T[1];if(b||A.V6.on("load",(function(){return R(!0)})),null!=h&&null!==(t=h.current)&&void 0!==t&&t.parentElement&&h.current.parentElement.offsetWidth0&&(s(n.current.offsetWidth),n.current.contentWindow===r&&u(e.details.height)),"iframe.resize"===e.context&&e.src===t&&e.height>0&&(n.current&&s(n.current.offsetWidth),u(e.height))})).destructor;return function(){e()}}}),[t,r]),[c,h,n]}({src:E,initialHeight:f||0,initialWidth:d||0}),T=S()(y,3),P=T[0],_=T[1],I=T[2],O=m.useRef(null);if(m.useEffect((function(){if(c&&p&&p.id&&_&&P){var e="";l.current&&(e=l.current.offsetTop.toString()),c("".concat(p.id,"-").concat(e),l,{type:"image"})}}),[]),!E)return null;var k=a.text?m.createElement(C,{richTextStyle:i},m.createElement(b.T2,{paragraph:a,paragraphStyle:n,richTextStyle:i})):null,q=[(0,z.qB)(o)];q.push((function(){return{clear:"both"}})),"OUTSET_LEFT"===(a.layout||void 0)&&"STREAM"!==i&&q.push((function(e){var t;return t={background:e.backgroundColor,borderWidth:e.borderWidthThick+"px",borderStyle:e.borderStyle,borderColor:e.backgroundColor,float:"left",marginLeft:"-150px",marginRight:"30px",width:"75%",padding:"0",paddingBottom:"10px"},x()(t,N.md(e),{float:"none",marginLeft:"0",marginRight:"0",width:"100%"}),x()(t,"marginBottom","16px"),t}));var B=r?(0,G.XC)(a):null;return m.createElement(L,{className:u(q),figCaption:k,figureRef:l},B?m.createElement(m.Fragment,null,m.createElement("amp-embedly-card",{"data-url":B.url,layout:"responsive",width:_,height:P,"data-card-controls":"0"})):m.createElement(w.G,{height:P,width:_,backgroundColor:"NONE",ref:O},m.createElement(D,{placeholderRef:O,iframeRef:I,src:E,title:v||"",height:P,width:_,allowFullScreen:!0,frameBorder:"0",rules:F.m})))},Z=m.memo(V);const Y=(0,T.$j)((function(e){return{isAmp:e.config.isAmp,host:e.navigation.host}}))(Z);var J=(0,d.Ps)(Q(),G.Zp,b.Zr);const $=Y;var K=r(59854),ee=r.n(K),te=r(7647),re=r(69677),ae=r(16660),ne=r(65922),ie=r(7530),oe=r(90038),ce=function(e){return{backgroundColor:e.brandColor.sage.light}},ue=function(e,t){var r=(0,oe.W6)({freezeGifs:!1,miroId:e,strategy:oe._S.Resample,width:t.breakpoints.sm}),a=(0,oe.W6)({freezeGifs:!1,miroId:e,strategy:oe._S.Resample,width:t.breakpoints.md}),n=(0,oe.W6)({freezeGifs:!1,miroId:e,strategy:oe._S.Resample,width:t.breakpoints.lg}),i=(0,oe.W6)({freezeGifs:!1,miroId:e,strategy:oe._S.Resample,width:t.breakpoints.xl});return{xl:"url('".concat(i,"')"),lg:"url('".concat(i,"')"),md:"url('".concat(n,"')"),sm:"url('".concat(a,"')"),xs:"url('".concat(r,"')")}};function le(e){var t=e.metadata,r=(0,W.Iq)();return m.createElement(ie.Yi,null,(function(e){return m.createElement("div",{className:r(ce)},m.createElement(ne.Z,{backgroundImage:ue(t.id,e),miroId:t.id,height:"60vh",width:"100%",minHeight:{xl:500,lg:400,md:400,sm:300,xs:300},imgHeight:500,imgWidth:2e3,focusPercent:null===t.focusPercentX||void 0===t.focusPercentX||null===t.focusPercentY||void 0===t.focusPercentY?void 0:[t.focusPercentX,t.focusPercentY]}))}))}var pe=r(8558),he=r(62031),se=r(8667);function ge(){var e=n()(["\n fragment ImageParagraph_privateNote on Note {\n ...PostAnnotationsMarker_privateNote\n }\n ","\n"]);return ge=function(){return e},e}function fe(){var e=n()(["\n fragment ImageParagraph_highlight on Quote {\n id\n ...Markups_highlight\n }\n ","\n"]);return fe=function(){return e},e}function de(){var e=n()(["\n fragment ImageParagraph_paragraph on Paragraph {\n href\n layout\n metadata {\n id\n originalHeight\n originalWidth\n focusPercentX\n focusPercentY\n alt\n }\n ...Markups_paragraph\n ...PostAnnotationsMarker_paragraph\n }\n ","\n ","\n"]);return de=function(){return e},e}var me=function(e){var t=e.highlights,r=e.isSequenceCover,a=void 0!==r&&r,n=e.marginTopOverride,i=e.paragraph,o=e.paragraphStyle,c=e.privateNotes,u=e.richTextStyle,l=e.sequenceAspectRatio,p=e.spaceTop,h=e.updateWatchedBounds,s=(0,W.Iq)(),g=m.useRef(null),f=(0,re.CF)(i,o),d=m.useContext(te.U);return m.useEffect((function(){if(h){var e=i.name,t=i.metadata&&i.metadata.id;if(e&&t){var r="";g.current&&(r=g.current.offsetTop.toString()),h("".concat(e,"-").concat(t,"-").concat(r),g,{type:"image"})}}}),[]),m.useMemo((function(){var e=i.metadata,r=i.layout;if(!e)return null;var h,v=e.id,E=e.originalHeight,y=e.originalWidth,S=e.alt,T=(0,oe.JI)(v),R="CARD"===u||"SHORTFORM_CARD"===u,w=(0,se.jg)({layout:r,originalWidth:y||0,originalHeight:E||0,sequenceAspectRatio:l,richTextStyle:u}),P=w.width,_=w.height,I=w.strategy,O=w.otherWidths;if("OUTSET_ROW_CONTINUE"===r&&y&&E&&l){var W=y/E;h=ee()(l/W,2)}var k,q=i.text?m.createElement(C,{ref:f,richTextStyle:u,textAlign:a?"left":"center",extendLeftRatio:h},c&&m.createElement(ae.A7,{paragraph:i,privateNotes:c}),m.createElement(b.T2,{highlights:t,paragraph:i,paragraphStyle:o,richTextStyle:u})):null;if(a)k=m.createElement(le,{metadata:{id:v,focusPercentX:e.focusPercentX,focusPercentY:e.focusPercentY}});else{var B=d?[{maxWidth:"100%",height:"auto"}]:_?[F.m]:[{maxWidth:"100%"}],A={isAmp:!1,alt:S||"Image for post",miroId:v,height:_,width:P,rules:B,maxWidth:_?void 0:"100%",strategy:I,freezeGifs:"STREAM"===u||"RESAMPLE"!==I,focusPercentX:e.focusPercentX,focusPercentY:e.focusPercentY,expectedWidth:P,otherWidths:O};if((0,G.jH)(u)){var H=function(){var e={};return P>0&&(e.maxWidth="".concat(P,"px")),R&&("INSET_CENTER"===r||"OUTSET_LEFT"===r)&&y&&(e.marginLeft="auto",e.marginRight="auto"),m.createElement("div",{className:s(e)},m.createElement(pe.Fh,A))};if(!P||!_)return m.createElement("div",{className:s((0,z.qB)(p))},m.createElement(H,null));k=m.createElement(H,null)}else if("OUTSET_LEFT"===r||"INSET_LEFT"===r||"INSET_CENTER"===r&&y||"OUTSET_CENTER"===r&&y){var U=y&&(T?y/2:y);k=m.createElement(he.X1,{isLinked:!!i.href,width:A.width,height:A.height,originalHeight:e.originalHeight,originalWidth:e.originalWidth,paragraphRef:g},m.createElement("div",{className:s((function(e){return{marginLeft:"auto",marginRight:"auto",maxWidth:"OUTSET_CENTER"===r&&U&&U{"use strict";r.d(t,{ZQ:()=>P,PL:()=>_,NR:()=>I,lD:()=>O,l:()=>N});var a=r(63038),n=r.n(a),i=r(28655),o=r.n(i),c=r(59713),u=r.n(c),l=r(67154),p=r.n(l),h=r(71439),s=r(67294),g=r(28859),f=r(10515),d=r(50391),m=r(19692),v=r(98701),E=r(28309),x=r(80637),y=r(65441);function S(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,a)}return r}function T(e){for(var t=1;t{"use strict";function a(e){e&&e.iframe&&e.height&&e.iframe.getAttribute&&"number"==typeof e.height&&o({context:"iframe.resize",height:e.height,src:e.iframe.getAttribute("src")||""})}function n(e){if(e.data&&"string"==typeof e.data){var t;try{t=JSON.parse(e.data)}catch(e){return}o(t,e.source)}}r.d(t,{x:()=>c});var i=[];function o(e,t){i.forEach((function(r){return r(e,t)}))}function c(e){return window._resizeIframe||(window._resizeIframe=a,window.addEventListener("message",n)),i.push(e),{destructor:function(){0===(i=i.filter((function(t){return e!==t}))).length&&"undefined"!=typeof window&&(window._resizeIframe=null,window.removeEventListener("message",n))}}}},65922:(e,t,r)=>{"use strict";r.d(t,{Z:()=>s});var a=r(63038),n=r.n(a),i=r(67294),o=r(98701),c=r(28309),u=r(90038),l=function(e){var t=n()(e,1)[0];return"number"==typeof t?"".concat(t,"px"):t},p=function(e){var t=n()(e,1)[0];return"".concat(t[0],"% ").concat(t[1],"%")},h=function(e){return n()(e,1)[0]};function s(e){var t=e.backgroundImage,r=e.boxShadowRules,a=e.miroId,n=e.height,s=e.width,g=e.minHeight,f=e.minWidth,d=e.imgHeight,m=e.imgWidth,v=e.focusPercent,E=e.strategy,x=void 0===E?u._S.Resample:E,y=e.darken,S=e.freezeGifs,T=(0,c.Iq)(),b=t;if(!b){var R=(0,u.W6)({miroId:a,height:d,width:m,strategy:x,darken:y,freezeGifs:S});b="url(".concat(R,")")}var w=(0,o.mu)(l,n),P=(0,o.mu)(l,s),_=g&&(0,o.mu)(l,g),I=f&&(0,o.mu)(l,f),O=(0,o.mu)(p,v),W={backgroundImage:(0,o.mu)(h,b),display:"block",backgroundOrigin:"border-box",backgroundSize:"cover",height:w,width:P,minHeight:_,minWidth:I,backgroundPosition:O,maxWidth:"100%"};return i.createElement("div",{className:T([W,r])})}s.defaultProps={focusPercent:[50,50]}},41331:(e,t,r)=>{"use strict";r.d(t,{v:()=>c});var a=r(63038),n=r.n(a),i=r(67294),o=r(72955),c=function(e){var t=e.rootMargin,r=e.children,a=e.target,c=i.useState(!1),u=n()(c,2),l=u[0],p=u[1],h=i.useCallback((function(e){!l&&e.isIntersecting&&p(!0)}),[l]);return(0,o.S1)({onIntersect:h,target:a,disconnect:function(){return l},rootMargin:t},[l]),"function"==typeof r?i.createElement(i.Fragment,null,r(l)):l?i.createElement(i.Fragment,null,r):null}}}]); //# sourceMappingURL=https://stats.medium.build/lite/sourcemaps/5064.ee9cac75.chunk.js.map