{"version":3,"file":"Buton.Bfvb0Xpk.mjs","names":[],"sources":["https:/framerusercontent.com/modules/Kno709JtzxtpO1uo1QG6/o9K0EXk97Vuji0mOi8nu/Buton.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/**\n * @framerIntrinsicWidth 200\n * @framerIntrinsicHeight 50\n */export default function CustomDownloadButton(props){const{file,fileName,label,tint,color,fontFamily,fontSize,fontWeight,radius,padding,shadowColor,shadowBlur,shadowX,shadowY}=props;const handleDownload=async()=>{if(!file)return;try{const response=await fetch(file);const blob=await response.blob();const blobUrl=window.URL.createObjectURL(blob);const link=document.createElement(\"a\");link.href=blobUrl;link.download=fileName||\"indirilen-dosya\";document.body.appendChild(link);link.click();document.body.removeChild(link);window.URL.revokeObjectURL(blobUrl);}catch(error){console.error(\"İndirme hatası:\",error);window.open(file,\"_blank\");}};const style={width:\"100%\",height:\"100%\",backgroundColor:tint,color:color,borderRadius:radius,border:\"none\",cursor:\"pointer\",fontFamily:fontFamily,fontWeight:fontWeight,fontSize:fontSize,display:\"flex\",alignItems:\"center\",justifyContent:\"center\",padding:padding,boxShadow:`${shadowX}px ${shadowY}px ${shadowBlur}px ${shadowColor}`,transition:\"all 0.2s ease\"};return /*#__PURE__*/_jsx(\"button\",{onClick:handleDownload,style:style,children:label});}addPropertyControls(CustomDownloadButton,{file:{type:ControlType.File,title:\"Dosya\",allowedFileTypes:[\"pdf\",\"zip\",\"png\",\"jpg\"]},fileName:{type:ControlType.String,title:\"Dosya Adı\",defaultValue:\"dosyam.pdf\",placeholder:\"ornek.pdf\",description:\"Uzantıyı (.pdf) yazmayı unutma!\"},label:{type:ControlType.String,title:\"Buton Yazısı\",defaultValue:\"İndir\"},// --- Yeni Font ve Kalınlık Ayarları ---\nfontFamily:{type:ControlType.String,title:\"Yazı Tipi (Font)\",defaultValue:\"Inter, sans-serif\",placeholder:\"\\xd6rn: Inter, Roboto...\",description:\"Framer projenizde y\\xfckl\\xfc olan fontun adını yazın.\"},fontWeight:{type:ControlType.Enum,title:\"Font Kalınlığı\",defaultValue:700,options:[100,200,300,400,500,600,700,800,900],optionTitles:[\"100 - İnce (Thin)\",\"200 - Ekstra Hafif\",\"300 - Hafif (Light)\",\"400 - Normal (Regular)\",\"500 - Orta (Medium)\",\"600 - Yarı Kalın (Semi Bold)\",\"700 - Kalın (Bold)\",\"800 - Ekstra Kalın\",\"900 - Siyah (Black)\"]},fontSize:{type:ControlType.Number,title:\"Yazı Boyutu\",defaultValue:16,min:8,max:100,unit:\"px\"},tint:{type:ControlType.Color,title:\"Arkaplan\",defaultValue:\"#0099ff\"},color:{type:ControlType.Color,title:\"Yazı Rengi\",defaultValue:\"#ffffff\"},radius:{type:ControlType.Number,title:\"K\\xf6şe (Radius)\",defaultValue:12,min:0,max:50},shadowColor:{type:ControlType.Color,title:\"G\\xf6lge Rengi\",defaultValue:\"rgba(0, 0, 0, 0.2)\"},shadowBlur:{type:ControlType.Number,title:\"G\\xf6lge Bulanıklığı\",defaultValue:15,min:0},shadowY:{type:ControlType.Number,title:\"G\\xf6lge Y (Aşağı)\",defaultValue:5},shadowX:{type:ControlType.Number,title:\"G\\xf6lge X (Yan)\",defaultValue:0}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"CustomDownloadButton\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerIntrinsicWidth\":\"200\",\"framerIntrinsicHeight\":\"50\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Buton.map"],"mappings":"0KAGG,SAAwB,EAAqB,EAAM,CAAC,GAAK,CAAC,OAAK,WAAS,QAAM,OAAK,QAAM,aAAW,WAAS,aAAW,SAAO,UAAQ,cAAY,aAAW,UAAQ,WAAS,EAAuzB,OAAoB,EAAK,SAAS,CAAC,QAA/zB,SAAS,CAAK,KAAY,GAAG,CAAkC,IAAM,EAAK,MAA7B,MAAM,MAAM,EAA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