{"version":3,"file":"shared-lib.Cwmrgst5.mjs","names":["useStore","useState","useState","useRef","metadata","siteMetadata","metadataVersion","__FramerMetadata__","metadata","siteMetadata"],"sources":["https:/framerusercontent.com/modules/vj7bFUjvEQFgEzNBkdoG/vf3CKm378wlVcBk7IhSU/createStore.js","https:/framer.com/m/framer/store.js@^1.0.0","https:/framerusercontent.com/modules/cjsQ9dGtGRAqMOBTVbvN/99vfufuMRwn7HaJDm7Yp/AudioPlayer.js","https:/framerusercontent.com/modules/fARsITBZ3jdpip2RtDUM/JLxU2t2Y4MoC61piOP9S/siteMetadata.js","https:/framerusercontent.com/modules/trq2qB9m9JQVoCkxYHae/MGgitQNuDhTFXpSTT9r2/augiA20Il.js","https:/framerusercontent.com/modules/9NpigZX5eYFay2DJCuFV/PJGuYfqE1eoVq9VHNRro/m6VErLiG0.js"],"sourcesContent":["import{useState,useEffect}from\"react\";import{Data,useObserveData}from\"framer\";export function createStore(state1){// Use Data so that a Preview reload resets the state\nconst dataStore=Data({state:Object.freeze({...state1})});// Create a set function that updates the state\nconst setDataStore=newState=>{// If the state is an object, make sure we copy it\nif(typeof newState===\"function\"){newState=newState(dataStore.state);}dataStore.state=Object.freeze({...dataStore.state,...newState});};// Store the initial state, copy the object if it's an object\nlet storeState=typeof state1===\"object\"?Object.freeze({...state1}):state1;// Keep a list of all the listeners, in the form of React hook setters\nconst storeSetters=new Set();// Create a set function that updates all the listeners / setters\nconst setStoreState=newState=>{// If the state is an object, make sure we copy it\nif(typeof newState===\"function\"){newState=newState(storeState);}storeState=typeof newState===\"object\"?Object.freeze({...storeState,...newState}):newState;// Update all the listeners / setters with the new value\nstoreSetters.forEach(setter=>setter(storeState));};// Create the actual hook based on everything above\nfunction useStore(){// Create the hook we are going to use as a listener\nconst[state,setState]=useState(storeState);// If we unmount the component using this hook, we need to remove the listener\n// @ts-ignore\nuseEffect(()=>{// But right now, we need to add the listener\nstoreSetters.add(setState);return()=>storeSetters.delete(setState);},[]);// If Data context exists, use Data, otherwise use vanilla React state\nif(useObserveData()===true){useObserveData();return[dataStore.state,setDataStore];}else{// Return the state and a function to update the central store\nreturn[state,setStoreState];}}return useStore;}\nexport const __FramerMetadata__ = {\"exports\":{\"createStore\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./createStore.map","/*\n * createStore (framer/store@1.0.1)\n *\n * Learn More: https://www.framer.com/asset-urls\n */\n\nexport * from \"https://framerusercontent.com/modules/vj7bFUjvEQFgEzNBkdoG/vf3CKm378wlVcBk7IhSU/createStore.js\"\n","import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useState,useEffect,useRef}from\"react\";import{addPropertyControls,ControlType}from\"framer\";import{createStore}from\"https://framer.com/m/framer/store.js@^1.0.0\";// Memori store sekarang hidup di dalam file ini\nexport const useStore=createStore({shouldPlay:false});export default function AudioPlayer(props){const{audioUrl,bgColor,iconColor}=props;const[store,setStore]=useStore();const[isPlaying,setIsPlaying]=useState(false);const audioRef=useRef(null);useEffect(()=>{if(!audioRef.current){audioRef.current=new Audio(audioUrl);audioRef.current.loop=true;}if(store.shouldPlay){audioRef.current.play().then(()=>setIsPlaying(true)).catch(err=>console.log(\"Menunggu interaksi user...\"));}return()=>{if(audioRef.current)audioRef.current.pause();};},[store.shouldPlay,audioUrl]);const togglePlay=()=>{if(isPlaying){audioRef.current.pause();setStore({shouldPlay:false});}else{audioRef.current.play();setStore({shouldPlay:true});}setIsPlaying(!isPlaying);};return /*#__PURE__*/_jsxs(\"div\",{onClick:togglePlay,style:{width:48,height:48,borderRadius:\"50%\",backgroundColor:bgColor,display:\"flex\",justifyContent:\"center\",alignItems:\"center\",cursor:\"pointer\",boxShadow:\"0 4px 12px rgba(0,0,0,0.15)\",animation:isPlaying?\"spin 4s linear infinite\":\"none\"},children:[/*#__PURE__*/_jsx(\"style\",{children:`@keyframes spin { 100% { transform: rotate(360deg); } }`}),isPlaying?/*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:iconColor,children:[/*#__PURE__*/_jsx(\"rect\",{x:\"6\",y:\"4\",width:\"4\",height:\"16\",rx:\"1\"}),/*#__PURE__*/_jsx(\"rect\",{x:\"14\",y:\"4\",width:\"4\",height:\"16\",rx:\"1\"})]}):/*#__PURE__*/_jsx(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:iconColor,children:/*#__PURE__*/_jsx(\"path\",{d:\"M5 3.868v16.264c0 .894 1.077 1.341 1.707.707l11.455-11.455a1 1 0 0 0 0-1.414L6.707 3.161C6.077 2.531 5 2.978 5 3.868z\"})})]});}addPropertyControls(AudioPlayer,{audioUrl:{type:ControlType.String,title:\"URL Lagu (MP3)\"},bgColor:{type:ControlType.Color,title:\"Warna Lingkaran\",defaultValue:\"#FFF\"},iconColor:{type:ControlType.Color,title:\"Warna Ikon\",defaultValue:\"#181818\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"AudioPlayer\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"useStore\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./AudioPlayer.map","// Generated by Framer (8bbc62e)\nexport default function metadata(params,activeLocale){return{description:\"Undangan Digital Acara Pernikahan Rifqi & Nans. 27-28 Juni 2026.\",favicon:\"https://framerusercontent.com/assets/2pu8Vik2NB36s1fLTBl1VHQmU.png\",robots:\"max-image-preview:large\",socialImage:\"https://framerusercontent.com/assets/HvooTcT9hG1bBAZKcslE8ISvX8.png\",title:\"Wedding Invitation Rifqi & Nans\"};}export const metadataVersion=1;\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"metadataVersion\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}","// Generated by Framer (f3f9b36)\nimport siteMetadata from\"#framer/local/siteMetadata/siteMetadata/siteMetadata.js\";export default function metadata(params,activeLocale){return{breakpoints:[{hash:\"72rtr7\",mediaQuery:\"(min-width: 1280px)\"},{hash:\"ecmggo\",mediaQuery:\"(max-width: 1279.98px)\"}],description:siteMetadata(params,activeLocale).description,elements:{},robots:\"max-image-preview:large\",serializationId:\"framer-KNfSw\",socialImage:\"https://framerusercontent.com/assets/HvooTcT9hG1bBAZKcslE8ISvX8.png\",title:siteMetadata(params,activeLocale).title||\"Home\",viewport:\"width=device-width\"};}export const metadataVersion=1;\nexport const __FramerMetadata__ = {\"exports\":{\"metadataVersion\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"default\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}","// Generated by Framer (f3f9b36)\nimport siteMetadata from\"#framer/local/siteMetadata/siteMetadata/siteMetadata.js\";export default function metadata(params,activeLocale){return{breakpoints:[{hash:\"1hru7fr\",mediaQuery:\"(min-width: 1280px)\"},{hash:\"1dkuc03\",mediaQuery:\"(min-width: 810px) and (max-width: 1279.98px)\"},{hash:\"cvz9kj\",mediaQuery:\"(max-width: 809.98px)\"}],description:siteMetadata(params,activeLocale).description,elements:{},robots:\"max-image-preview:large\",serializationId:\"framer-po6dL\",socialImage:\"https://framerusercontent.com/assets/HvooTcT9hG1bBAZKcslE8ISvX8.png\",title:siteMetadata(params,activeLocale).title||\"Invitation\",viewport:\"width=device-width\"};}export const metadataVersion=1;\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"metadataVersion\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],"mappings":"6MAA8E,SAAgB,EAAY,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