{"version":3,"file":"Voxel_Model_Viewer.B6gh2IBf.mjs","names":["_Fragment"],"sources":["https:/framerusercontent.com/modules/aLM1yTVfZKLLg24ue3lw/2Wo0She567bYQrvDGqUO/Voxel_Model_Viewer.js"],"sourcesContent":["// Get Started: https://www.framer.com/developers\nimport{jsx as _jsx,Fragment as _Fragment}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{motion}from\"framer-motion\";import{cloneElement}from\"react\";// Viewer\n/**\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n */export function Voxel_Model_Viewer(props){return /*#__PURE__*/_jsx(_Fragment,{children:props.filepath&&/*#__PURE__*/_jsx(\"model-viewer\",{style:{width:\"100%\",height:\"100%\"},src:props.filepath,autoplay:true,\"shadow-intensity\":\"0.7\",\"interaction-prompt\":\"none\",\"camera-controls\":true,\"disable-pan\":true,\"disable-zoom\":true,\"camera-orbit\":`${props.initialAngle.toString()}deg 90deg ${props.modelDistance.toString()}%`})});}addPropertyControls(Voxel_Model_Viewer,{filepath:{type:ControlType.String,title:\"Model File\"},modelDistance:{type:ControlType.Number,title:\"Model Distance\",max:105,min:1,step:1,defaultValue:105,unit:\"%\"},initialAngle:{type:ControlType.Number,title:\"Initial Angle\",max:360,min:1,step:1,defaultValue:170,unit:\"deg\"}});// Equipment Wrapper\n/**\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n */export function Voxel_Equipment_Wrapper(props){const masks=[props.mask1.src,props.mask2.src,props.mask3.src];const rng=Math.seedrandom?new Math.seedrandom(props.name):null;const randMask=rng?Math.round(rng()*2):Math.round(Math.random()*2);const cardElement=props.card[0];let cardChild=null;if(cardElement&&typeof cardElement===\"object\"&&\"type\"in cardElement){cardChild=/*#__PURE__*/cloneElement(cardElement,{style:{width:\"100%\",height:\"100%\",...cardElement.props?.style||{}}});}return /*#__PURE__*/_jsx(motion.div,{style:{width:\"100%\",height:\"100%\",maskImage:`url(${masks[randMask]})`,WebkitMaskSize:\"100% 100%\",maskSize:\"100% 100%\"},children:cardChild});}addPropertyControls(Voxel_Equipment_Wrapper,{card:{type:ControlType.Slot,maxCount:1,title:\"Card Component\"},name:{type:ControlType.String,title:\"Name\"},mask1:{type:ControlType.ResponsiveImage,title:\"Mask 1\"},mask2:{type:ControlType.ResponsiveImage,title:\"Mask 2\"},mask3:{type:ControlType.ResponsiveImage,title:\"Mask 3\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"Voxel_Model_Viewer\":{\"type\":\"reactComponent\",\"name\":\"Voxel_Model_Viewer\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"fixed\",\"framerSupportedLayoutWidth\":\"fixed\"}},\"Voxel_Equipment_Wrapper\":{\"type\":\"reactComponent\",\"name\":\"Voxel_Equipment_Wrapper\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"fixed\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Voxel_Model_Viewer.map"],"mappings":"wVAKG,SAAgB,EAAmB,EAAM,CAAC,OAAoB,EAAKA,EAAU,CAAC,SAAS,EAAM,UAAuB,EAAK,eAAe,CAAC,MAAM,CAAC,MAAM,OAAO,OAAO,OAAO,CAAC,IAAI,EAAM,SAAS,SAAS,GAAK,mBAAmB,MAAM,qBAAqB,OAAO,kBAAkB,GAAK,cAAc,GAAK,eAAe,GAAK,eAAe,GAAG,EAAM,aAAa,WAAW,YAAY,EAAM,cAAc,WAAW,GAAG,EAAE,CAAG,CAIna,SAAgB,EAAwB,EAAM,CAAC,IAAM,EAAM,CAAC,EAAM,MAAM,IAAI,EAAM,MAAM,IAAI,EAAM,MAAM,IAAI,CAAO,EAAI,KAAK,WAAW,IAAI,KAAK,WAAW,EAAM,MAAM,KAAW,EAAS,EAAI,KAAK,MAAM,IAAM,GAAG,KAAK,MAAM,KAAK,SAAS,GA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