"use strict";(self.webpackChunk_genially_view_client=self.webpackChunk_genially_view_client||[]).push([[8916],{79809:(e,t,n)=>{n.d(t,{q:()=>Fe});var i=n(45992),r=n(37577),o=n(79883),a=n(87878),s=n(17588);const l="Start chronometer",c="Pause chronometer",d="Reset chronometer",g=e=>{const t=new Image;return t.src=e,t},h=(e,t)=>{try{if(Array.from(document.fonts).some((t=>t.family===e)))return;new FontFace(e,`url(${t})`).load().then((e=>{document.fonts.add(e)}))}catch(n){console.warn("Error preloading font",n)}},u="Unbounded";h(u,"https://fonts.gstatic.com/s/unbounded/v12/Yq6W-LOTXCb04q32xlpwu8ZfvRIkSQ.woff2");const p=r.Ay.div({fontSize:"calc(var(--parent-height) * 1px)",position:"relative",height:"100%",width:"100%",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"space-between",padding:"0 5%"}),f=r.Ay.div((e=>{let{theme:{color:t,font:n}}=e;return{fontSize:"0.49em",color:t.background.accent.active(),fontFamily:`'${u}', "Source Sans Pro", _fb_`,fontWeight:n.weight.bold,letterSpacing:"normal",lineHeight:1.15,textAlign:"center"}})),m=r.Ay.div({display:"flex",flexDirection:"row",gap:"5%",height:"0.35em"}),b=r.Ay.button({height:"100%",width:"100%","& > img":{height:"100%"}}),x=(0,s.forwardRef)(((e,t)=>{let{timeInMMSS:n,size:r,onPlay:o,onPause:a,onReset:s,isPaused:g}=e;return(0,i.jsxs)(p,{ref:t,style:{"--parent-height":r.height},children:[(0,i.jsx)(f,{children:n}),(0,i.jsxs)(m,{children:[g?(0,i.jsx)(b,{onClick:o,"aria-label":l,children:(0,i.jsx)("img",{src:"https://img.genially.com/59e059d30b9c21060cb4c2ec/a3938a9b-677c-4910-98bd-c27893621dc5.png",alt:"",role:"presentation"})}):(0,i.jsx)(b,{onClick:a,"aria-label":c,children:(0,i.jsx)("img",{src:"https://img.genially.com/59e059d30b9c21060cb4c2ec/1ce58e08-80a9-43cd-a75c-eddc2ec5758c.png",alt:"",role:"presentation"})}),(0,i.jsx)(b,{onClick:s,"aria-label":d,children:(0,i.jsx)("img",{src:"https://img.genially.com/59e059d30b9c21060cb4c2ec/e9859854-6f64-4d6e-a892-4053d2e9020f.png",alt:"",role:"presentation"})})]})]})}));var y=n(13847);const j="https://images.genially.com/widgets/countdown/sportwatch.avif";g(j);const v="https://images.genially.com/resources/play-crono.png";g(v);const w="https://img.genially.com/5f4d04bc24f8aa6ccbd06c83/53991127-e2c7-4bb0-a23f-77da6ea0bb4a.png";g(w);const A="https://img.genially.com/5f4d04bc24f8aa6ccbd06c83/29a21dd2-ee3c-4485-ab31-41e5aa135313.png";g(A);const k="Offside";h(k,"https://fonts.gstatic.com/s/offside/v24/HI_KiYMWKa9QrAykc5boR72elpU.woff2");const C=r.Ay.div({position:"relative",height:"100%",aspectRatio:"1/1",isolation:"isolate"}),S=r.Ay.div({width:"100%",height:"100%",position:"absolute",top:"0",left:"0",backgroundImage:`url(${j})`,backgroundSize:"contain",backgroundPosition:"center",backgroundRepeat:"no-repeat"}),P=r.Ay.div((e=>{let{$width:t,$height:n,$top:i,$right:r}=e;return{position:"absolute",backgroundColor:"rgb(13, 37, 53)",width:t,height:n,top:i,right:r,display:"flex",alignItems:"center",justifyContent:"center"}})),R=r.Ay.button(Object.assign(Object.assign({},y.iF.mixins.increaseSpecificity({background:"transparent"})),{position:"relative",height:"70%",aspectRatio:"1/1",zIndex:3,"& > img":{height:"100%",width:"100%",objectFit:"contain"}})),I=r.Ay.div((e=>{let{theme:t,$distance:n,$startFromBottom:i=!1,$running:o=!1}=e;return r.AH`
    content: '';
    opacity: ${o?1:0};
    position: absolute;
    width: 10%;
    height: 10%;
    background-color: ${t.color.content.info.default()};
    border-radius: 50%;
    top: 0%;
    left: 50%;
    transform-origin: 0 ${n};
    animation-name: ${o?(e=>{const t=e?180:0;return(0,r.i7)({"0%":{transform:`rotate(${0+t}deg) translateX(-50%)`},"100%":{transform:`rotate(${360+t}deg) translateX(-50%)`}})})(i):""};
    animation-duration: 4s;
    animation-iteration-count: infinite;
    animation-timing-function: linear;
    z-index: 0;
  `})),$=r.Ay.div({fontSize:"calc(var(--parent-height) / 3.7 * 1px)",position:"absolute",top:"48%",left:"50%",transform:"translate(-50%, -48%)",fontFamily:`'${k}', "Source Sans Pro", _fb_`,color:"rgb(191, 212, 232)"}),F=e=>{let{onClick:t}=e;return(0,i.jsx)(R,{onClick:t,"aria-label":d,children:(0,i.jsx)("img",{src:A,alt:""})})},z=e=>{let{onClick:t}=e;return(0,i.jsx)(R,{onClick:t,"aria-label":l,children:(0,i.jsx)("img",{src:v,alt:""})})},M=e=>{let{onClick:t}=e;return(0,i.jsx)(R,{onClick:t,"aria-label":c,children:(0,i.jsx)("img",{src:w,alt:""})})},O=(0,s.forwardRef)(((e,t)=>{let{timeInMMSS:n,size:r,isPaused:o,onPlay:a,onPause:s,onReset:l}=e;return(0,i.jsxs)(C,{ref:t,children:[(0,i.jsxs)(P,{$width:"21%",$height:"21%",$top:"11%",$right:"22%",children:[(0,i.jsx)(F,{onClick:l}),(0,i.jsx)(I,{$distance:"480%",$running:!o})]}),(0,i.jsxs)(P,{$width:"28%",$height:"28%",$top:"64.5%",$right:"36.5%",children:[o?(0,i.jsx)(z,{onClick:a}):(0,i.jsx)(M,{onClick:s}),(0,i.jsx)(I,{$distance:"500%",$running:!o,$startFromBottom:!0})]}),(0,i.jsx)(S,{}),(0,i.jsx)($,{style:{"--parent-height":r.height},children:n})]})}));var T=n(55404),_=n(66294),E=n(22848);const H=e=>{let{className:t,color:n,height:i,size:r,style:o,width:a,...l}=e;return s.createElement(E.A,{className:t,color:n,height:i,size:r,style:o,viewBox:"0 0 16 16",width:a,...l},s.createElement("g",null,s.createElement("path",{d:"M9.785,3.342H4.08L5.321,2.077A1.217,1.217,0,0,0,3.63,0.356L0.35,3.698a1.215,1.215,0,0,0,0,1.72L3.63,8.76a1.217,1.217,0,0,0,1.72-1.721L4.08,5.774H9.785a3.897,3.897,0,0,1,0,7.794H4.978a1.218,1.218,0,0,0,0,2.435H9.785a6.332,6.332,0,0,0,0-12.661Z"})))};var D=n(35086);const N="Fugaz One";h(N,"https://fonts.gstatic.com/s/fugazone/v21/rax_HiWKp9EAITukFsl8AxhfsUjQ8Q.woff2");const W="rgb(30, 97, 109)",B=r.Ay.div((e=>{let{theme:t}=e;return{fontSize:"0.58em",fontFamily:`'${N}', "Source Sans Pro", _fb_`,fontWeight:t.font.weight.bold,lineHeight:.8,color:W}})),X=r.Ay.button(Object.assign(Object.assign({},y.iF.mixins.increaseSpecificity({color:W})),{fontSize:"0.25em",lineHeight:0})),q=(0,r.Ay)(X)({"& > svg":{transform:"skewX(-10deg)"},"&  g":{strokeWidth:"2px",stroke:"currentcolor"}}),K=r.Ay.button(Object.assign(Object.assign({},y.iF.mixins.increaseSpecificity({color:"white",background:W,borderRadius:"50%"})),{fontSize:"0.10em",height:"80%",aspectRatio:"1 / 1",lineHeight:0})),L=r.Ay.div({width:"95%",lineHeight:0}),U=r.Ay.div({fontSize:"calc(var(--parent-height) * 1px)",width:"100%",height:"100%",padding:"0.05em",display:"grid",gridTemplateRows:"70% 30%",gridTemplateColumns:"10% 80% 10%",gridTemplateAreas:'\n    "blank-toggle time blank-reset"\n    "toggle progressbar reset"',justifyItems:"center",alignItems:"center",[X]:{gridArea:"toggle"},[q]:{gridArea:"toggle"},[B]:{gridArea:"time"},[L]:{gridArea:"progressbar"},[K]:{gridArea:"reset"}}),Y=(0,s.forwardRef)(((e,t)=>{let{timeInMMSS:n,size:r,isPaused:o,onPause:a,onPlay:s,onReset:g}=e;return(0,i.jsxs)(U,{ref:t,style:{"--parent-height":r.height},children:[(0,i.jsx)(B,{children:n}),o?(0,i.jsx)(X,{onClick:s,"aria-label":l,children:(0,i.jsx)(T.A,{})}):(0,i.jsx)(q,{onClick:a,"aria-label":c,children:(0,i.jsx)(_.A,{})}),(0,i.jsx)(L,{children:(0,i.jsx)(D.z,{running:!o})}),(0,i.jsx)(K,{onClick:g,"aria-label":d,children:(0,i.jsx)(H,{})})]})})),Q=g("https://img.genially.com/59e059d30b9c21060cb4c2ec/320263af-a2ab-45c1-8f09-f6d429e90e60.png"),V="Gugi";h(V,"https://fonts.gstatic.com/s/gugi/v21/A2BVn5dXywshZAmK9RMckqI.woff2");const G=r.Ay.div({height:"70%",width:"70%",display:"flex",alignItems:"center",justifyContent:"center",aspectRatio:"1 / 1",borderRadius:"50%",backgroundImage:`url(${Q.src})`,backgroundSize:"contain",backgroundPosition:"center",backgroundRepeat:"no-repeat"}),J=r.Ay.div((e=>{let{$isPaused:t}=e;return{"@property --angle-spinner":{syntax:'"<angle>"',initialValue:"0deg",inherits:"false"},"@property --rotation-spinner":{syntax:'"<angle>"',initialValue:"0deg",inherits:"false"},"@property --color1-spinner":{syntax:'"<color>"',initialValue:"transparent",inherits:"false"},"@property --color2-spinner":{syntax:'"<color>"',initialValue:"transparent",inherits:"false"},"@property --color3-spinner":{syntax:'"<color>"',initialValue:"rgb(49,49,49)",inherits:"false"},height:"90%",aspectRatio:"1 / 1",borderRadius:"50%",background:"conic-gradient(\n      from 0deg,\n      var(--color1-spinner) 0deg,\n      var(--color2-spinner) var(--angle-spinner),\n      var(--color3-spinner) var(--angle-spinner)\n    )",transform:"translate(-50%, -50%) rotate(var(--rotation-spinner))",animation:t?"none":"spinner-angle 5s ease-in-out infinite,\n    rotate-spinner 5s linear infinite,\n    color-spinner 5s linear infinite",animationsTimingFunction:"ease-in-out","@keyframes spinner-angle":{"0%":{"--angle-spinner":"0deg"},"40%":{"--angle-spinner":"360deg"},"40.001%":{"--angle-spinner":"0deg"},"80%":{"--angle-spinner":"360deg"},"100%":{"--angle-spinner":"360deg"}},"@keyframes rotate-spinner":{"0%":{"--rotation-spinner":"0deg"},"40%":{"--rotation-spinner":"360deg"},"80%":{"--rotation-spinner":"720deg"},"100%":{"--rotation-spinner":"720deg"}},"@keyframes color-spinner":{"0%":{"--color1-spinner":"transparent","--color2-spinner":"transparent","--color3-spinner":"rgb(49,49,49)"},"40%":{"--color1-spinner":"transparent","--color2-spinner":"transparent","--color3-spinner":"rgb(49,49,49)"},"40.001%":{"--color1-spinner":"rgb(49,49,49)","--color2-spinner":"rgb(49,49,49)","--color3-spinner":"transparent"},"80%":{"--color1-spinner":"rgb(49,49,49)","--color2-spinner":"rgb(49,49,49)","--color3-spinner":"transparent"},"100%":{"--color1-spinner":"rgb(49,49,49)","--color2-spinner":"rgb(49,49,49)","--color3-spinner":"transparent"}}}})),Z=r.Ay.div(Object.assign(Object.assign({boxShadow:"0 0 0.1em rgba(0,0,0,0.1)",height:"100%",width:"36.7%",display:"flex",alignItems:"center",justifyContent:"center"},y.iF.mixins.increaseSpecificity({border:"0.04938em solid rgba(206, 212, 210)",padding:"1.8%"})),{aspectRatio:"1 / 1",borderRadius:"50%",backgroundColor:"rgb(244, 245, 245)",[J]:{position:"absolute",top:"50%",left:"50%"},[G]:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})),ee=r.Ay.div({height:"100%",width:"100%",background:"linear-gradient(\n      120deg,\n      rgba(255, 255, 255, 0) 0%,\n      rgba(255, 255, 255, 0) 30%,\n      rgba(255, 255, 255, 0.3) 30.1%,\n      rgba(255, 255, 255, 0.3) 35%,\n      rgba(255, 255, 255, 0) 35.1%,\n      rgba(255, 255, 255, 0) 35.6%,\n      rgba(255, 255, 255, 0.3) 35.7%,\n      rgba(255, 255, 255, 0.3) 37.7%,\n      rgba(255, 255, 255, 0) 37.8%,\n      rgba(255, 255, 255, 0) 60%\n    )",backgroundSize:"300%",backgroundPositionX:"100%",animation:"shimmer 4.8s linear infinite","@keyframes shimmer":{"0%":{backgroundPositionX:"100%"},"75%":{backgroundPositionX:"100%"},"100%":{backgroundPositionX:"0%"}}}),te=r.Ay.div((e=>{let{theme:{font:t}}=e;return{fontSize:"0.451em",color:"rgb(49, 49, 49)",fontFamily:`'${V}', "Source Sans Pro", _fb_`,fontWeight:t.weight.bold,letterSpacing:"normal",lineHeight:1.15,textAlign:"right"}})),ne=r.Ay.div(Object.assign(Object.assign({borderRadius:"0.20704em",position:"relative",display:"flex",alignItems:"center",justifyContent:"flex-end",height:"72%",width:"100%"},y.iF.mixins.increaseSpecificity({paddingRight:"12.3%",paddingTop:"0.9%",marginLeft:"10%"})),{backgroundColor:"rgba(206, 212, 210)",[ee]:{position:"absolute",top:0,left:0},[te]:{position:"absolute",left:"32.5%"}})),ie=r.Ay.div({display:"flex",alignItems:"center",justifyContent:"center",flexDirection:"column",gap:"4%",height:"100%"}),re=r.Ay.button(Object.assign(Object.assign({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",width:"calc(var(--parent-height) / 3.3 * 1px)",aspectRatio:"1 / 1",cursor:"pointer"},y.iF.mixins.increaseSpecificity({background:"rgb(255, 64, 75)",border:"none",borderRadius:"50%",padding:"0",color:"rgb(255, 255, 255)",boxShadow:"rgba(0, 0, 0, 0.5) -0.2em 0.2em 0.1em"})),{"& svg":{zIndex:1,width:"45%",height:"45%"}})),oe=r.Ay.div({position:"relative",height:"100%",width:"100%",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"calc(var(--parent-height) * 1px)",[Z]:{position:"absolute",top:"0%",left:"0%"},[ie]:{position:"absolute",right:"2%",top:"50%",transform:"translateY(-50%)"}}),ae=(0,s.forwardRef)(((e,t)=>{let{timeInMMSS:n,size:r,onPlay:o,onPause:a,onReset:s,isPaused:g}=e;const h={"--parent-height":r.height};return(0,i.jsxs)(oe,{ref:t,style:h,children:[(0,i.jsxs)(ne,{children:[(0,i.jsx)(te,{children:n}),(0,i.jsx)(ee,{})]}),(0,i.jsxs)(ie,{children:[g?(0,i.jsx)(re,{onClick:o,"aria-label":l,children:(0,i.jsx)(T.A,{})}):(0,i.jsx)(re,{onClick:a,"aria-label":c,children:(0,i.jsx)(_.A,{})}),(0,i.jsx)(re,{onClick:s,disabled:!s,"aria-label":d,children:(0,i.jsx)(H,{})})]}),(0,i.jsxs)(Z,{children:[(0,i.jsx)(J,{$isPaused:g}),(0,i.jsx)(G,{})]})]})})),se="https://img.genially.com/60ef11e790ed4a0ff835b724/0ecdb3d6-1773-46ee-927b-362b2b911e74.gif",le="https://static.genially.com/widgets/chronometer/sand/stopped_sand.gif";g(se),g(le);const ce="Comfortaa";h(ce,"https://fonts.gstatic.com/s/comfortaa/v47/1PtCg8LJRfWJmhDAuUsSQamb1W0lwk4S4WjMXL830efAesmwYSFoxBEP_I28dnyM.woff2");const de=r.Ay.img((e=>{let{$hide:t=!1}=e;return{height:"160%",opacity:t?0:1}})),ge=r.Ay.div((e=>{let{theme:t}=e;return{fontSize:"calc(var(--parent-height) / 1.96 * 1px)",letterSpacing:"normal",color:"white",fontFamily:`'${ce}', "Source Sans Pro", _fb_`,fontWeight:t.font.weight.bold}})),he=r.Ay.div({display:"flex",alignItems:"center",justifyContent:"center",flexDirection:"column",gap:"4%",height:"100%"}),ue=r.Ay.button(Object.assign(Object.assign({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",width:"calc(var(--parent-height) / 3.5 * 1px)",aspectRatio:"1 / 1",cursor:"pointer"},y.iF.mixins.increaseSpecificity({background:"rgb(198, 62, 38)",border:"none",borderRadius:"50%",padding:"0",color:"rgb(255, 255, 255)"})),{"&:before":{content:'""',position:"absolute",width:"90%",aspectRatio:"1 / 1",borderRadius:"50%",top:"50%",left:"50%",background:"rgb(255, 69, 30)",transform:"translate(-50%, -50%) scale(1)",transition:"transform 0.3s ease-in-out"},"&:hover:before":{transform:"translate(-50%, -50%) scale(1.25)"},"& svg":{zIndex:1,width:"45%",height:"45%"}})),pe=r.Ay.div({position:"absolute",top:"50%",left:"50%",display:"flex",flexDirection:"row",alignItems:"center",width:"93%",height:"65%",borderRadius:"100vmax",background:"rgb(21, 53, 80)",transform:"translate(-50%, -50%)",[de]:{position:"absolute",left:"-8.7%",top:"50%",transform:"translateY(-50%)"},[ge]:{position:"absolute",left:"33.6%",top:"52%",transform:"translateY(-50%)"},[he]:{position:"absolute",right:"9%",top:"50%",transform:"translateY(-50%)"}}),fe=(0,s.forwardRef)(((e,t)=>{let{timeInMMSS:n,size:r,onPlay:o,onPause:a,onReset:s,isPaused:g}=e;return(0,i.jsxs)(pe,{ref:t,style:{"--parent-height":r.height},children:[(0,i.jsx)(de,{src:se,alt:"Sand hourglass",$hide:g}),(0,i.jsx)(de,{src:le,alt:"Sand hourglass",$hide:!g}),(0,i.jsx)(ge,{children:n}),(0,i.jsxs)(he,{children:[(0,i.jsx)(ue,{onClick:s,disabled:!s,"aria-label":d,children:(0,i.jsx)(H,{})}),g?(0,i.jsx)(ue,{onClick:o,"aria-label":l,children:(0,i.jsx)(T.A,{})}):(0,i.jsx)(ue,{onClick:a,"aria-label":c,children:(0,i.jsx)(_.A,{})})]})]})})),me="DM Mono";h(me,"https://fonts.gstatic.com/s/dmmono/v16/aFTU7PB1QTsUX8KYthqQBK6PYK0.woff2");const be=g("https://img.genial.ly/5d08988468a4ee0fc40f66c5/c8aae60b-c70c-4166-8460-8820ef8367a8.png"),xe=r.Ay.div({width:"8.21%",aspectRatio:"1/1",backgroundImage:`url(${be.src})`,backgroundSize:"contain",backgroundPosition:"center",backgroundRepeat:"no-repeat"}),ye=r.Ay.span((e=>{let{theme:t}=e;return{fontSize:"calc(var(--parent-height) / 1.99 * 1px)",color:"rgb(255, 255, 255)",fontFamily:`'${me}', "Source Sans Pro", _fb_`,fontWeight:t.font.weight.normal,letterSpacing:"normal",lineHeight:1,textAlign:"center"}})),je=r.Ay.div({display:"flex",justifyContent:"space-between",alignItems:"center"}),ve=r.Ay.div((e=>{let{theme:{color:t}}=e;return{position:"relative",display:"flex",alignItems:"center",justifyContent:"center",width:"100%",height:"100%",backgroundColor:t.background.reversed.active(.8),borderRadius:"calc(var(--parent-height) / 12.5 * 1px)",boxShadow:"rgba(0, 0, 0, 0.25) 3px 4px 18px",[ye]:{position:"absolute",top:"12%",left:"17%"},[xe]:{position:"absolute",top:"8%",left:"5%"},[je]:{position:"absolute",bottom:"14%",left:"18%",right:"10%"}}})),we=r.Ay.button(Object.assign(Object.assign({display:"flex",alignItems:"center",justifyContent:"center",width:"11.40%",background:"transparent",border:"none",padding:"0",cursor:"pointer",aspectRatio:"1/1"},y.iF.mixins.increaseSpecificity({color:"rgb(255, 255, 255)",fill:"rgb(255, 255, 255)"})),{"& svg":{width:"100%",height:"100%"}})),Ae=(0,s.forwardRef)(((e,t)=>{let{timeInMMSS:n,size:r,onPlay:o,onPause:a,onReset:s,isPaused:g}=e;return(0,i.jsxs)(ve,{ref:t,style:{"--parent-height":r.height},children:[(0,i.jsx)(xe,{}),(0,i.jsx)(ye,{children:n}),(0,i.jsxs)(je,{children:[(0,i.jsx)(we,{onClick:s,disabled:!s,"aria-label":d,children:(0,i.jsx)(H,{})}),g?(0,i.jsx)(we,{onClick:o,"aria-label":l,children:(0,i.jsx)(T.A,{})}):(0,i.jsx)(we,{onClick:a,"aria-label":c,children:(0,i.jsx)(_.A,{})})]})]})})),ke=e=>{let{variant:t,timeInMillis:n,onPlay:r,onPause:l,onReset:c,isPaused:d}=e;const g=(0,o.AF)(n),h=(e=>{switch(e){case a.oR.SAND:return fe;case a.oR.CRONO:return O;case a.oR.STANDARD:return Ae;case a.oR.AKIHABARA:return x;case a.oR.PROGRESS_BAR:return Y;case a.oR.RETRO:return ae;default:return()=>(0,i.jsx)("h1",{children:"\u23f1\ufe0f WIP-ing chronometers"})}})(t),{ref:u,size:p}=(e=>{const[t,n]=(0,s.useState)({width:0,height:0}),i=(0,s.useRef)(null);return(0,s.useEffect)((()=>{if(!i.current)return;const e=new ResizeObserver((e=>{const{width:t,height:i}=e[0].contentRect;n({width:t,height:i})}));return e.observe(i.current),()=>e.disconnect()}),[i,e]),{ref:i,size:t}})(t);return(0,i.jsx)(h,{ref:u,timeInMMSS:g,size:p,onPlay:r,onPause:l,onReset:c,isPaused:d})},Ce=e=>{let{variant:t}=e;return(0,i.jsx)(ke,{variant:t,timeInMillis:0,isPaused:!0})};var Se=n(57567),Pe=n(86991);const Re="https://s3.eu-west-1.amazonaws.com/genially-audio-dev/64676ad5ec3dd256383244f9/520b02c3-751c-456c-816b-817a3d8050da.mpga",Ie="https://s3.eu-west-1.amazonaws.com/genially-audio-dev/64676ad5ec3dd256383244f9/038b75ee-5922-4a44-902c-4a751318bf11.mpga",$e=e=>{let{variant:t,timeAPI:n,audioAPI:r,animationAPI:o}=e;const{elapsedTime:a,isPaused:l,startChronometer:c,pauseChronometer:d,resetChronometer:g}=(()=>{const e=(0,s.useRef)(),[t,n]=(0,s.useState)(!1),[i,r]=(0,s.useState)(0),o=(0,s.useCallback)((()=>{e.current&&(clearInterval(e.current),e.current=void 0)}),[e]);(0,s.useEffect)((()=>()=>o()),[o]);const a=(0,s.useCallback)((()=>{n(!0),o()}),[o]),l=(0,s.useCallback)((()=>{if(e.current)return;n(!1);const t=Date.now(),o=i;e.current=setInterval((()=>{const e=1e3*Math.floor((Date.now()-t)/1e3),n=Math.min(o+e,Pe.l);r(n),n>=Pe.l&&a()}),1e3)}),[i,a]),c=(0,s.useCallback)((()=>{r(0),n(!0),o()}),[o]);return{elapsedTime:i,isPaused:t,startChronometer:l,pauseChronometer:a,resetChronometer:c}})(),h=(0,s.useRef)(!1),u=(0,s.useCallback)((()=>{r.playAudio({source:Re})}),[r]),p=(0,s.useCallback)((()=>{r.playAudio({source:Ie})}),[r]);(0,s.useEffect)((()=>{r.preloadAudio(Re),r.preloadAudio(Ie)}),[r]),(0,s.useEffect)((()=>{h.current||(c(),h.current=!0)}),[c]);return(0,i.jsx)(ke,{variant:t,timeInMillis:a,onPlay:()=>{c(),u()},onPause:()=>{d();const e=o.playAnimation({type:Se.K.Heartbeat,parameters:{delayMs:0,durationMs:2e3}});n.setTimeout((()=>{e.stop()}),2e3),u()},onReset:()=>{g(),p()},isPaused:l})},Fe=e=>{let{theme:t,variant:n,disabled:o,timeAPI:a,audioAPI:s,animationAPI:l}=e;return(0,i.jsx)(r.NP,{theme:t,children:o?(0,i.jsx)(Ce,{variant:n}):(0,i.jsx)($e,{variant:n,timeAPI:a,audioAPI:s,animationAPI:l})})}},38916:(e,t,n)=>{n.r(t),n.d(t,{geniallyChronometerEditorScript:()=>c});var i=n(45992),r=n(13847),o=n(57277),a=n(79809),s=n(87878),l=n(86991);const c=e=>{let{script:t,editor:n}=e;const c=t.item;c&&("preserveAspectRatio"in c&&(c.preserveAspectRatio=!0),t.on("configChange",(e=>{let{config:i,prevConfig:r}=e;var o;const{variant:a}=i,d=t.item;d&&((e=>{e.thumbnail&&(e.thumbnail=void 0)})(d),r&&a!==r.variant&&(null===(o=n.trackWidgetPresetChange)||void 0===o||o.call(n,`${l.L.scriptId};${a}`)),((e,t)=>{const n=e.height*s.NJ[t];e.setSize(n,e.height)})(c,a),d.showOverflow||(d.showOverflow=!0))})),(0,o.x)({getTargetNodeItem:()=>t.item,renderApp:()=>{const{variant:e}=t.getConfig();return(0,i.jsx)(a.q,{theme:r.iF.themes.newPrimary,variant:e,disabled:!0})},renderThumbnailApp:()=>{const{variant:e}=t.getConfig();return(0,i.jsx)(a.q,{theme:r.iF.themes.newPrimary,variant:e,disabled:!0})},nodePrefix:"chronometer"})({script:t,editor:n}))}},35086:(e,t,n)=>{n.d(t,{z:()=>o});var i=n(45992);const r=n(37577).Ay.rect`
  @keyframes fill {
    0% {
      x: 0%;
      width: 0%;
    }
    50% {
      x: 13%;
      width: 100%;
    }
    100% {
      x: 110%;
      width: 100%;
    }
  }

  ${e=>e.$running&&"\n    animation: fill 2.2s ease-in-out infinite;\n  "}
`,o=e=>{let{running:t=!1}=e;return(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"7 0 82 20",preserveAspectRatio:"none",children:(0,i.jsxs)("g",{transform:"skewX(-10)",children:[(0,i.jsxs)("defs",{children:[(0,i.jsxs)("linearGradient",{id:"barGradient",x1:"13",y1:"0",x2:"87",y2:"0",gradientUnits:"userSpaceOnUse",children:[(0,i.jsx)("stop",{offset:"0%",stopColor:"#0A4E4E"}),(0,i.jsx)("stop",{offset:"100%",stopColor:"#A8D5D5"})]}),(0,i.jsx)("clipPath",{id:"barClip",children:(0,i.jsx)("rect",{x:"13",y:"4.5",width:"74",height:"11",rx:"2",ry:"2"})})]}),(0,i.jsx)("rect",{x:"11",y:"2.5",width:"78",height:"15",rx:"3",ry:"3",fill:"none",stroke:"#808080",strokeWidth:"2"}),(0,i.jsx)("rect",{x:"13",y:"4.5",width:"74",height:"11",rx:"2",ry:"2",fill:"#eeeeee"}),(0,i.jsx)("g",{clipPath:"url(#barClip)",children:(0,i.jsx)(r,{x:"13",y:"4.5",width:"0",height:"11",fill:"url(#barGradient)",$running:t})})]})})}},57277:(e,t,n)=>{n.d(t,{x:()=>r});var i=n(70377);function r(e){let{getTargetNodeItem:t,renderApp:n,renderThumbnailApp:r,nodePrefix:o}=e;return e=>{let{script:a,editor:s}=e,l=null,c=[];function d(e){l&&(i.unmountComponentAtNode(l),l=null),e&&"innerHtml"in e&&(e.innerHtml='<div class="card-iframe"><div style="width: 100%; height: 100%; background: #FF0000; color: #FFFFFF;">Deleted</div><script><\/script></div>')}function g(){l&&i.render(n(),l)}function h(){const e=t(a.getConfig());if(!e)return;const n=`${o}-${e.id}`;"innerHtml"in e&&(e.innerHtml=`<div class="card-iframe"><div id="${n}" class="genially-widget-app" style="width: 100%; height: 100%;"></div></div>`),requestAnimationFrame((()=>{l="idOfFreeNode"in e?document.getElementById(e.idOfFreeNode)||null:document.getElementById(n)||null,g()}))}function u(){r&&c.length&&c.forEach((e=>{i.render(r(),e)}))}function p(){const e=t(a.getConfig());e&&"idOfThumbnailFreeNode"in e&&requestAnimationFrame((()=>{const t=document.getElementsByClassName(e.idOfThumbnailFreeNode);c=Array.from(t),u()}))}a.on("configChange",(e=>{let{config:n,prevConfig:i}=e;const r=t(n),o=i?t(i):void 0;o&&o!==r&&d(o),r&&(r!==o?(h(),p()):(g(),u()))})),a.on("dispose",(()=>{d(t(a.getConfig()))})),s.on("itemMount",(e=>{let{item:t}=e;t===a.item&&h()})),s.on("slideChange",(()=>{g()})),s.on("itemUnmount",(e=>{let{item:t}=e;t===a.item&&d()})),s.on("itemThumbnailMount",(e=>{let{item:t}=e;t===a.item&&p()}))}}},79883:(e,t,n)=>{n.d(t,{EJ:()=>s,AF:()=>a,di:()=>l});const i=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;return e.toString().padStart(t,"0")};function r(e){const t=Math.floor(e/1e3);return{seconds:t%60,minutes:Math.floor(t/60)}}function o(e){const t=function(e){const t=r(e);return{seconds:t.seconds,minutes:t.minutes%60,hours:Math.floor(t.minutes/60)}}(e);return{seconds:t.seconds,minutes:t.minutes,hours:t.hours%24,days:Math.floor(t.hours/24)}}function a(e){const t=r(e);return`${i(t.minutes)}:${i(t.seconds)}`}function s(e){const t=o(e);return`${i(t.days,2)}:${i(t.hours)}:${i(t.minutes)}:${i(t.seconds)}`}function l(){const e=new Date,t=e.getTime();return t-(t+6e4*e.getTimezoneOffset())}}}]);
//# sourceMappingURL=https://s3-static-genially.genially.com/view/static/js/8916.bf304a44.chunk.js.map