{"version":3,"file":"Clock_1.CUvU6Ens.mjs","names":["useState"],"sources":["https:/framerusercontent.com/modules/BJCVnSq3TPS0VNOvb0Cw/qXekQHzzhBT4nxxepHOR/Clock_1.js"],"sourcesContent":["// Clock component with customizable styling and timezone support by country name\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{useState,useEffect,startTransition}from\"react\";import{addPropertyControls,ControlType}from\"framer\";/**\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight any-prefer-fixed\n */export default function Clock(props){const{font,textColor,backgroundColor,border,borderRadius,padding,style}=props;const[time,setTime]=useState(\"\");useEffect(()=>{if(typeof window===\"undefined\")return;const timezone=\"America/Vancouver\";const updateTime=()=>{const now=new Date;const options={timeZone:timezone,hour:\"2-digit\",minute:\"2-digit\",second:\"2-digit\",hour12:false};const formatter=new Intl.DateTimeFormat(\"en-US\",options);startTransition(()=>setTime(formatter.format(now)));};updateTime();const interval=setInterval(updateTime,1e3);return()=>clearInterval(interval);},[]);const isFixedWidth=style&&style.width===\"100%\";const isFixedHeight=style&&style.height===\"100%\";return /*#__PURE__*/_jsx(\"div\",{style:{...style,position:\"relative\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\",backgroundColor,borderRadius,...border,padding,...isFixedWidth?{}:{width:\"max-content\"},...isFixedHeight?{}:{height:\"max-content\"}},children:/*#__PURE__*/_jsx(\"span\",{style:{...font,color:textColor,whiteSpace:\"nowrap\"},children:time||\"00:00:00\"})});}addPropertyControls(Clock,{font:{type:ControlType.Font,title:\"Font\",defaultValue:{fontSize:\"40px\",variant:\"Bold\",letterSpacing:\"-0.04em\",lineHeight:\"1em\"},controls:\"extended\",defaultFontType:\"sans-serif\"},textColor:{type:ControlType.Color,title:\"Text Color\",defaultValue:\"#000000\"},backgroundColor:{type:ControlType.Color,title:\"Background\",defaultValue:\"#FFFFFF\"},border:{type:ControlType.Border,title:\"Border\",defaultValue:{borderWidth:1,borderStyle:\"solid\",borderColor:\"#EEEEEE\"}},borderRadius:{type:ControlType.BorderRadius,title:\"Radius\",defaultValue:\"8px\"},padding:{type:ControlType.Padding,title:\"Padding\",defaultValue:\"20px 40px\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"Clock\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"any-prefer-fixed\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"any-prefer-fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Clock_1.map"],"mappings":"iMAIG,SAAwB,EAAM,EAAM,CAAC,GAAK,CAAC,OAAK,YAAU,kBAAgB,SAAO,eAAa,UAAQ,SAAO,EAAW,CAAC,EAAK,GAASA,EAAS,GAAG,CAAC,MAAc,CAAC,GAAU,IAAS,OAAY,OAAO,IAAyC,MAAe,CAAC,IAAM,EAAI,IAAI,KAA2G,EAAU,IAAI,KAAK,eAAe,QAA1H,CAAC,SAAS,oBAAS,KAAK,UAAU,OAAO,UAAU,OAAO,UAAU,OAAO,GAAM,CAAyD,CAAC,MAAoB,EAAQ,EAAU,OAAO,EAAI,CAAC,CAAC,EAAG,GAAY,CAAC,IAAM,EAAS,YAAY,EAAW,IAAI,CAAC,UAAU,cAAc,EAAS,EAAG,EAAE,CAAC,CAAC,IAAM,EAAa,GAAO,EAAM,QAAQ,OAAa,EAAc,GAAO,EAAM,SAAS,OAAO,OAAoB,EAAK,MAAM,CAAC,MAAM,CAAC,GAAG,EAAM,SAAS,WAAW,QAAQ,OAAO,WAAW,SAAS,eAAe,SAAS,kBAAgB,eAAa,GAAG,EAAO,UAAQ,GAAG,EAAa,EAAE,CAAC,CAAC,MAAM,cAAc,CAAC,GAAG,EAAc,EAAE,CAAC,CAAC,OAAO,cAAc,CAAC,CAAC,SAAsB,EAAK,OAAO,CAAC,MAAM,CAAC,GAAG,EAAK,MAAM,EAAU,WAAW,SAAS,CAAC,SAAS,GAAM,WAAW,CAAC,CAAC,CAAC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