"use strict";(self.webpackChunkUmbracoVuePrototype=self.webpackChunkUmbracoVuePrototype||[]).push([[7338],{8330:(t,i,n)=>{n.d(i,{Z:()=>r});var e=n(7537),o=n.n(e),s=n(3645),a=n.n(s)()(o());a.push([t.id,".icon-container[data-v-557105e4]{display:flex}.icon-container .icon-angle-down[data-v-557105e4]:hover{color:var(--icon-colour-hover);cursor:pointer}","",{version:3,sources:["webpack://./Scripts/src/vue-components/_autoScroll/downArrow/style.scss"],names:[],mappings:"AAAA,iCACE,YAAA,CACA,wDACE,8BAAA,CACA,cAAA",sourcesContent:[".icon-container {\r\n display: flex;\r\n .icon-angle-down:hover {\r\n color: var(--icon-colour-hover);\r\n cursor: pointer;\r\n }\r\n}"],sourceRoot:""}]);const r=a},6848:(t,i,n)=>{function e(t){switch(t){case"left":return"flex-start";case"right":return"flex-end";case"justify":return"space-between";default:return"center"}}function o(t){switch(t){case"top":return"flex-start";case"bottom":return"flex-end";default:return"center"}}n.d(i,{K:()=>o,q:()=>e})},7338:(t,i,n)=>{n.r(i),n.d(i,{default:()=>z});var e=n(6252),o=n(3577);var s=n(655),a=n(4437);class r{constructor(t){this.justify=(0,a.G)().textAlign(t.justify,"center"),this.iconSize=(0,a.G)().size(t.iconSize,"60px"),this.iconColour=(0,a.G)().colour(t.iconColour,"var(--h1-colour)"),this.iconColourHover=(0,a.G)().colour(t.iconColourHover,"var(--h1-colour)"),this.scrollTagName=(0,a.G)().string(t.scrollTagName,"scroll-tag")}}var l=n(8159),h=n(6848);const m=(0,e.aZ)({mixins:[l.Z],data:()=>({downArrowStyle:{}}),computed:{},mounted(){this.typedModel=new r(this.componentModel),this.downArrowStyle["justify-content"]=(0,h.q)(this.typedModel.justify),this.downArrowStyle["font-size"]=this.typedModel.iconSize,this.downArrowStyle.color=this.typedModel.iconColour,this.downArrowStyle["--icon-colour-hover"]=this.typedModel.iconColourHover},methods:{arrowClicked(){return(0,s.mG)(this,void 0,void 0,(function*(){document.getElementsByTagName("autoscroll-stop-"+this.typedModel.scrollTagName)[0].scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})}))}}});var c=n(3379),d=n.n(c),y=n(7795),u=n.n(y),p=n(569),A=n.n(p),g=n(3565),v=n.n(g),b=n(9216),w=n.n(b),f=n(4589),C=n.n(f),S=n(8330),x={};x.styleTagTransform=C(),x.setAttributes=v(),x.insert=A().bind(null,"head"),x.domAPI=u(),x.insertStyleElement=w();d()(S.Z,x);S.Z&&S.Z.locals&&S.Z.locals;const z=(0,n(3744).Z)(m,[["render",function(t,i,n,s,a,r){return(0,e.wg)(),(0,e.iD)("div",{class:"component-margins icon-container",style:(0,o.j5)([t.downArrowStyle,t.entryAnimationStyle])},[(0,e._)("div",{class:"icon-angle-down",onClick:i[0]||(i[0]=i=>t.arrowClicked())})],4)}],["__scopeId","data-v-557105e4"]])},8159:(t,i,n)=>{n.d(i,{Z:()=>l});var e=n(655),o=n(6252),s=n(4437);class a{constructor(t){this.animationEnable=(0,s.G)().boolean(t.animationEnable,!1),this.animationAlwaysRunOnLoad=(0,s.G)().boolean(t.animationAlwaysRunOnLoad,!1),this.animationDelay=(0,s.G)().number(t.animationDelay,.2),this.animationDuration=(0,s.G)().number(t.animationDuration,.3),this.animationDirection=(0,s.G)().string(t.animationDirection,"bottom")}}var r=n(4572);const l=(0,o.aZ)({data:()=>({backgroundUrl:"",componentModel:{},componentWidth:0,isDesktopSize:!0,themeId:"",elementContainer:{},entryAnimations:{},entryAnimationStyle:{},loadState:{},observer:{},observerFirstRun:!0}),watch:{loadState(t,i){1==t&&this.entryAnimations.animationEnable&&this.setupEntryAnimation()}},beforeUnmount:function(){window.removeEventListener("resize",this.handleResize)},mounted(){const t=this.$el.parentElement.getAttribute("umbracomodel");this.componentModel="null"!==t&&null!=t?JSON.parse(t):{},this.componentModel.entryAnimations||(this.componentModel.entryAnimations={}),this.initiateEntryAnimations(),this.elementContainer=this.$el.closest(".component-margins");const i=window.innerWidth;this.initiateMargins(i),this.initiatePadding(i),this.initiateHeight(),this.initiateResizeListener(),(0,r.y)().addLoadedModule(),this.loadState=(0,r.y)().getLoadState()},onUnmounted(){if(this.entryAnimations.animationEnable)try{this.observer.unobserve(this.elementContainer)}catch(t){}},methods:{delay(t){return(0,e.mG)(this,void 0,void 0,(function*(){return new Promise((i=>setTimeout(i,t)))}))},handleResize(t){this.componentWidth=this.$el.clientWidth,this.resizeWindow()},resizeWindow(){const t=window.innerWidth;t>991!==this.isDesktopSize&&(this.initiateMargins(t),this.initiatePadding(t),this.calculateSize(t))},initiateResizeListener(){window.addEventListener("resize",this.handleResize),this.$el&&(this.componentWidth=this.$el.clientWidth);const t=window.innerWidth;this.calculateSize(t)},calculateSize(t){this.isDesktopSize=t>991},initiateMargins(t){t>991?this.setMargins(this.componentModel.moduleMargin):this.setMargins(this.componentModel.moduleMarginMobile)},initiatePadding(t){t>991?this.setPadding(this.componentModel.modulePadding):this.setPadding(this.componentModel.modulePaddingMobile)},setMargins(t){null!==this.elementContainer&&t&&(this.elementContainer.style.marginTop=t.top?(0,s.G)().size(t.top,"0px"):"0px",this.elementContainer.style.marginBottom=t.bottom?(0,s.G)().size(t.bottom,"0px"):"0px",this.elementContainer.style.marginLeft=t.left?(0,s.G)().size(t.left,"0px"):"0px",this.elementContainer.style.marginRight=t.right?(0,s.G)().size(t.right,"0px"):"0px")},setPadding(t){null!==this.elementContainer&&t&&(this.elementContainer.style.paddingTop=t.top?(0,s.G)().size(t.top,"0px"):"0px",this.elementContainer.style.paddingBottom=t.bottom?(0,s.G)().size(t.bottom,"0px"):"0px",this.elementContainer.style.paddingLeft=t.left?(0,s.G)().size(t.left,"0px"):"0px",this.elementContainer.style.paddingRight=t.right?(0,s.G)().size(t.right,"0px"):"0px")},initiateHeight(){if(null!==this.elementContainer){let t;t=this.componentModel.moduleHeight?(0,s.G)().size(this.componentModel.moduleHeight,"auto"):"auto",this.elementContainer.style.height=t,(t.includes("vh")||t.includes("vmax"))&&(this.elementContainer.style.maxHeight="2300px"),this.elementContainer.style.overflow="hidden"}},initiateEntryAnimations(){if(this.entryAnimations=new a(this.componentModel.entryAnimations),this.entryAnimations.animationEnable)switch(this.entryAnimationStyle.opacity="0!important",this.entryAnimations.animationDirection){case"bottom":this.entryAnimationStyle.bottom="-20vh";break;case"top":this.entryAnimationStyle.top="-20vh";break;case"left":this.entryAnimationStyle.left="-20vw";break;case"right":this.entryAnimationStyle.right="-20vw"}},setupEntryAnimation(){this.setupEntryAnimationObserver(.3)},setupEntryAnimationObserver(t){return(0,e.mG)(this,void 0,void 0,(function*(){this.entryAnimations.animationAlwaysRunOnLoad&&(this.observerFirstRun=!1),this.observer=new IntersectionObserver((t=>{t[0].isIntersecting&&this.runEntryAnimations(),this.observerFirstRun=!1}),{threshold:[t]}),this.observer.observe(this.elementContainer)}))},runEntryAnimations(){return(0,e.mG)(this,void 0,void 0,(function*(){switch(this.observerFirstRun?this.entryAnimationStyle.transition="none!important":this.entryAnimationStyle.transition="opacity "+this.entryAnimations.animationDuration+"s ease-in-out "+this.entryAnimations.animationDelay+"s,bottom "+this.entryAnimations.animationDuration+"s ease-in-out "+this.entryAnimations.animationDelay+"s,top "+this.entryAnimations.animationDuration+"s ease-in-out "+this.entryAnimations.animationDelay+"s,left "+this.entryAnimations.animationDuration+"s ease-in-out "+this.entryAnimations.animationDelay+"s,right "+this.entryAnimations.animationDuration+"s ease-in-out "+this.entryAnimations.animationDelay+"s",this.entryAnimationStyle.opacity="1",this.entryAnimations.animationDirection){case"bottom":this.entryAnimationStyle.bottom="0px";break;case"top":this.entryAnimationStyle.top="-0px";break;case"left":this.entryAnimationStyle.left="-0px";break;case"right":this.entryAnimationStyle.right="-0px"}this.observer.unobserve(this.elementContainer);try{let t=this.entryAnimations.animationDuration+this.entryAnimations.animationDelay;yield this.delay(1e3*t),this.entryAnimationStyle={}}catch(t){this.entryAnimationStyle={},console.log("Core mixin addition failed.")}}))}}})}}]); //# sourceMappingURL=source-maps-1.2/7338.fe43623f7cf0ad6a7f28.map