{"version":3,"file":"Youtube.CD-QYuqB.mjs","names":[],"sources":["https:/framerusercontent.com/modules/2EKZwuzbK5qqRmtKLqTS/zSVriQ3GDqzq2byRdEZy/Youtube.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/**\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any\n * @framerDefaultWidth 300\n * @framerDefaultHeight 150\n */export default function Youtube(props){const getYouTubeID=input=>{// Regex die verschillende YouTube URL formaten matcht\nconst regex=/(?:youtube\\.com\\/(?:[^\\/]+\\/.+\\/|(?:v|e(?:mbed)?)\\/|.*[?&]v=)|youtu\\.be\\/)([^\"&?\\/\\s]{11})/i;const match=input.match(regex);// Als er een match is, geef de ID terug (groep 1), anders de originele input\nreturn match?match[1]:input;};const videoId=getYouTubeID(props.videoId);return /*#__PURE__*/_jsx(\"div\",{style:{width:props.width,height:props.height,background:\"red\"},children:/*#__PURE__*/_jsxs(\"article\",{role:\"presentation\",style:{width:\"100%\",height:\"100%\",position:\"relative\",borderRadius:\"0px\",transform:\"unset\",cursor:\"pointer\",overflow:\"hidden\"},children:[/*#__PURE__*/_jsx(\"link\",{rel:\"preconnect\",href:\"https://www.youtube.com\"}),/*#__PURE__*/_jsx(\"link\",{rel:\"preconnect\",href:\"https://www.google.com\"}),/*#__PURE__*/_jsx(\"link\",{rel:\"preconnect\",href:\"https://i.ytimg.com\"}),/*#__PURE__*/_jsx(\"img\",{decoding:\"async\",src:\"https://i.ytimg.com/vi_webp/\"+videoId+\"/sddefault.webp\",alt:\"Thumbnail\",style:{position:\"absolute\",top:\"0px\",left:\"0px\",height:\"100%\",width:\"100%\",objectFit:\"cover\"}}),/*#__PURE__*/_jsx(\"iframe\",{title:\"Youtube Video\",allow:\"presentation; fullscreen; accelerometer; encrypted-media; gyroscope; picture-in-picture\",referrerPolicy:\"strict-origin-when-cross-origin\",src:\"https://www.youtube.com/embed/\"+videoId+\"?v=\"+videoId+\"&iv_load_policy=3&rel=0&modestbranding=1&playsinline=1\",frameBorder:\"0\",style:{position:\"absolute\",top:\"0px\",left:\"0px\",height:\"100%\",width:\"100%\"}})]})});}// Defining the defaults\naddPropertyControls(Youtube,{width:{type:ControlType.Number,defaultValue:300,min:0},height:{type:ControlType.Number,defaultValue:150,min:0},videoId:{type:ControlType.String,defaultValue:\"aFBIWGcbuDs\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"Youtube\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"any\",\"framerDefaultHeight\":\"150\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"any\",\"framerDefaultWidth\":\"300\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Youtube.map"],"mappings":"mKAKG,SAAwB,EAAQ,EAAM,CAEX,IAAM,GAFyB,GAAO,CACsC,IAAM,EAAM,EAAM,MAAhH,8FAA4H,CACxI,OAAO,EAAM,EAAM,GAAG,IAAmC,EAAM,QAAQ,CAAC,OAAoB,EAAK,MAAM,CAAC,MAAM,CAAC,MAAM,EAAM,MAAM,OAAO,EAAM,OAAO,WAAW,MAAM,CAAC,SAAsB,EAAM,UAAU,CAAC,KAAK,eAAe,MAAM,CAAC,MAAM,OAAO,OAAO,OAAO,SAAS,WAAW,aAAa,MAAM,UAAU,QAAQ,OAAO,UAAU,SAAS,SAAS,CAAC,SAAS,CAAc,EAAK,OAAO,CAAC,IAAI,aAAa,KAAK,0BAA0B,CAAC,CAAc,EAAK,OAAO,CAAC,IAAI,aAAa,KAAK,yBAAyB,CAAC,CAAc,EAAK,OAAO,CAAC,IAAI,aAAa,KAAK,sBAAsB,CAAC,CAAc,EAAK,MAAM,CAAC,SAAS,QAAQ,IAAI,+BAA+B,EAAQ,kBAAkB,IAAI,YAAY,MAAM,CAAC,SAAS,WAAW,IAAI,MAAM,KAAK,MAAM,OAAO,OAAO,MAAM,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