1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2488],{22488:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(57437),a=n(2265),o=n(75648),i=n(2353),l=n(40636),c=n(37785);function s(e){var t;let{projectExport:n}=e,s=(0,l.Z)(null==n?void 0:n.url),[u,d]=(0,a.useState)((0,c.Z)(n.projectId));return(0,a.useEffect)(()=>{(async()=>{d(await (0,i.bW)(n))})()},[]),(0,r.jsx)(o.default,{label:(null===(t=n.project)||void 0===t?void 0:t.name)||"",shareUrl:u,title:"Share this Video!",userId:n.userId,videoUrl:s})}},75648:function(e,t,n){n.d(t,{default:function(){return v}});var r=n(57437),a=n(36760),o=n.n(a),i=n(2265),l=n(88692),c=n(11309),s=n(2115),u=n(47028),d=n(6904),C=/(\.\w+)$/,p=n(95804),h=n(46362);function m(e){let{className:t,onCopy:n,value:a}=e,[l,c]=(0,i.useState)(!1),s=(0,i.useRef)(null);return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("input",{ref:s,readOnly:!0,"aria-label":"Link to share",className:"sr-only",type:"text",value:a}),(0,r.jsxs)(p.Z,{"aria-label":"Copy link to clipboard",className:o()("relative",t),onClick:function(){var e,t;if(null===(e=s.current)||void 0===e?void 0:e.value){s.current.select();let e=document.execCommand("copy");null===(t=document.getSelection())||void 0===t||t.removeAllRanges(),e&&(n&&n(),c(!0),setTimeout(()=>c(!1),500))}},children:[(0,r.jsx)("span",{style:{visibility:l?"hidden":"visible"},children:"Copy Link"}),l&&(0,r.jsx)(h.Z,{className:"absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2"})]})]})}var f=n(88891);function b(e){let{className:t,label:n,text:a,userId:i,videoUrl:l}=e,c=new URLSearchParams({label:n,text:a,url:encodeURIComponent(l)});return(0,r.jsx)("a",{"aria-label":"Share on YouTube",className:o()("btn",t),href:"/api/auth/youtube?".concat(c),rel:"noopener noreferrer",target:"_blank",onClick:()=>{(0,d.B)("share_video",{platform:"youtube",userId:i,url:l})},children:(0,r.jsx)(f.Z,{className:"size-5"})})}function v(e){let{className:t,label:n,shareUrl:a,title:h="Share Your Masterpiece!",userId:f,videoUrl:v}=e,[x,w]=(0,i.useState)(!1),{nativeShareAvailable:j}=(0,l.L)(),k=(0,i.useRef)(),g="Check out this video I made on worbler.ai!";async function y(){if(k.current)return k.current;w(!0);try{let e=await fetch(v).then(e=>e.blob());k.current=new File([e],"worbler.mp4",{type:e.type})}catch(e){}w(!1)}return(0,r.jsxs)("div",{className:o()("flex w-full flex-col gap-4 roun
1ded-lg bg-background-layer-2 p-8 text-center",t),children:[(0,r.jsx)("h3",{children:h}),(0,r.jsxs)("div",{className:"flex flex-row items-center justify-center gap-2",children:[j?(0,r.jsx)(p.Z,{"aria-label":"Share Worble",className:"btn-primary btn-medium xs:btn-large w-1/2",submitting:x,onClick:async()=>{(0,d.B)("share_video",{platform:"native",userId:f,url:v});try{await y(),await navigator.share({files:k.current?[k.current]:void 0,title:"Worbler AI",text:g,url:a})}catch(e){console.error(e)}},children:"Download"}):(0,r.jsx)(p.Z,{"aria-label":"Download Worble",className:"btn-primary btn-medium xs:btn-large w-1/2",submitting:x,onClick:async()=>{(0,d.B)("download_video",{userId:f,url:v}),await y();let e=document.createElement("a");e.rel="noopener noreferrer",e.target="_blank";let t=k.current;t?(e.download=t.name,e.href=URL.createObjectURL(t)):(e.download="worbler.zip",e.href=v.replace(C,".zip")),e.click()},children:"Download"}),(0,r.jsx)(m,{className:"btn-tertiary btn-medium xs:btn-large w-1/2",value:a})]}),(0,r.jsxs)("div",{className:"flex flex-row flex-wrap items-center justify-center gap-2",children:[(0,r.jsx)("a",{"aria-label":"Share Worble on Twitter",className:"btn btn-transparent btn-icon-medium",href:"https://twitter.com/intent/tweet?".concat(new URLSearchParams({text:g,url:encodeURIComponent(a)})),rel:"noopener noreferrer",target:"_blank",onClick:()=>{(0,d.B)("share_video",{platform:"twitter",userId:f,url:v})},children:(0,r.jsx)(u.Z,{className:"size-5"})}),(0,r.jsx)("a",{"aria-label":"Share Worble on Facebook",className:"btn btn-transparent btn-icon-medium",href:"https://www.facebook.com/sharer/sharer.php?".concat(new URLSearchParams({u:encodeURIComponent(a)})),rel:"noopener noreferrer",target:"_blank",onClick:()=>{(0,d.B)("share_video",{platform:"facebook",userId:f,url:v})},children:(0,r.jsx)(c.Z,{className:"size-5"})}),(0,r.jsx)(b,{className:"btn-transparent btn-icon-medium",label:n,text:g,userId:f,videoUrl:v}),(0,r.jsx)("a",{"aria-label":"Share Worble on TikTok",className:"btn btn-transparent btn-icon-medium",href:"/api/auth/tiktok?".concat(new URLSearchParams({text:g,url:encodeURIComponent(v),label:n})),rel:"noopener noreferrer",target:"_blank",onClick:()=>{(0,d.B)("share_video",{platform:"tiktok",userId:f,url:v})},children:(0,r.jsx)(s.Z,{className:"size-5"})})]})]})}},88692:function(e,t,n){n.d(t,{L:function(){return l},NativeShareProvider:function(){return c}});var r=n(57437),a=n(2265);let o=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i,i=(0,a.createContext)({nativeShareAvailable:!1}),l=()=>(0,a.useContext)(i);function c(e){let{children:t}=e,[n,l]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{var e;let t=void 0!==(null===(e=navigator)||void 0===e?void 0:e.share),n="ontouchstart"in document.documentElement&&o.test(navigator.userAgent);l(t&&n)},[]),(0,r.jsx)(i.Provider,{value:{nativeShareAvailable:n},children:t})}},2115:function(e,t,n){n.d(t,{Z:function(){return i}});var r=n(57437),a=n(36760),o=n.n(a);function i(e){let{className:t}=e;return(0,r.jsxs)("svg",{className:o()("icon",t),height:"32",viewBox:"0 0 32 32",width:"32",children:[(0,r.jsx)("path",{d:"M22.902 11.5513C24.9598 13.0275 27.4807 13.8961 30.2034 13.8961V8.63811C29.6881 8.63822 29.1742 8.58429 28.67 8.47711V12.6159C25.9476 12.6159 23.427 11.7473 21.3686 10.2712V21.0011C21.3686 26.3688 17.0328 30.7198 11.6845 30.7198C9.68892 30.7198 7.83412 30.1144 6.29333 29.076C8.05188 30.8805 10.5043 31.9999 13.2175 31.9999C18.5661 31.9999 22.9022 27.6489 22.9022 22.281V11.5513H22.902ZM24.7935 6.24662C23.7419 5.09359 23.0514 3.60353 22.902 1.95619V1.27991H21.4489C21.8147 3.37367 23.0622 5.16245 24.7935 6.24662ZM9.67612 24.957C9.08855 24.1839 8.77103 23.2381 8.77245 22.2656C8.77245 19.8106 10.7557 17.8201 13.2024 17.8201C13.6584 17.82 14.1116 17.8901 14.5462 18.0285V12.653C14.0384 12.5831 13.5258 12.5535 13.0135 12.5644V16.7484C12.5786 16.61 12.1252 16.5397 11.6691 16.5401C9.22232 16.5401 7.23922 18.5305 7.23922 20.9857C7.23922 22.7218 8.2305 24.2248 9.67612 24.957Z",fill:"#FF004F"}),(0,r.jsx)("path",{d:"M21.3686 10.2711C23.427 11.7472 25.9475 12.6158 28.67 12.6158V8.477C27.1503 8.15214 25.805 7.35516 24.7935 6.24662C23.0621 5.16234 21.8147 3.37356 21.4489 1.27991H17.6321V22.2808C17.6235 24.729 15.6437 26.7114 13.2022 26.7114C11.7634 26.7114 10.4853 26.0232 9.67577 24.957C8.23025 24.2248 7.23897 22.7217 7.23897 20.9859C7.23897 18.5308 9.22207 16.5403 11.6688 16.5403C12.1376 16.5403 12.5894 16.6135 13.0133 16.7485V12.5645C7.75895 12.6734 3.5332 16.982 3.5332 22.2809C3.5332 24.9261 4.58551 27.324 6.29342 29.0761C7.8342 30.1144 9.689 30.72 11.6846 30.72C17.0329 30.72 21.3687 26.3687 21.3687 21.0011V10.2711H21.3686Z",fill:"black"}
1),(0,r.jsx)("path",{d:"M28.6701 8.47707V7.35798C27.2997 7.36007 25.9562 6.97492 24.7935 6.24658C25.8228 7.37742 27.1781 8.15716 28.6701 8.47707ZM21.4489 1.27998C21.414 1.07988 21.3872 0.878468 21.3686 0.676285V0H16.0987V21.0011C16.0903 23.449 14.1106 25.4314 11.6688 25.4314C10.952 25.4314 10.2752 25.2606 9.6758 24.9572C10.4853 26.0233 11.7635 26.7114 13.2022 26.7114C15.6435 26.7114 17.6236 24.7292 17.6321 22.281V1.27998H21.4489ZM13.0135 12.5645V11.3732C12.5732 11.3128 12.1292 11.2825 11.6847 11.2827C6.33589 11.2826 2 15.6339 2 21.0011C2 24.366 3.70408 27.3316 6.29356 29.076C4.58565 27.324 3.53334 24.9259 3.53334 22.2808C3.53334 16.982 7.75898 12.6735 13.0135 12.5645Z",fill:"#00F2EA"})]})}},47028:function(e,t,n){n.d(t,{Z:function(){return i}});var r=n(57437),a=n(36760),o=n.n(a);function i(e){let{className:t}=e;return(0,r.jsx)("svg",{className:o()("icon",t),height:"32",viewBox:"0 0 32 32",width:"32",children:(0,r.jsx)("path",{d:"M10.0634 29.0009C22.1389 29.0009 28.7437 18.9965 28.7437 10.3206C28.7437 10.0365 28.7437 9.75357 28.7245 9.47197C30.0094 8.54258 31.1185 7.39182 32 6.07357C30.8019 6.60477 29.5307 6.95298 28.2291 7.10653C29.5998 6.28612 30.6255 4.99558 31.1155 3.47517C29.8268 4.23998 28.4168 4.77894 26.9466 5.06877C25.9567 4.01621 24.6475 3.31923 23.2216 3.08568C21.7957 2.85214 20.3326 3.09506 19.0586 3.77684C17.7847 4.45863 16.771 5.54127 16.1743 6.85724C15.5777 8.1732 15.4314 9.64912 15.7581 11.0566C13.1479 10.9257 10.5943 10.2473 8.26327 9.06558C5.9322 7.88384 3.87569 6.22512 2.2272 4.19709C1.38764 5.64242 1.1305 7.3534 1.50813 8.98165C1.88577 10.6099 2.86979 12.033 4.25984 12.9613C3.21498 12.9306 2.19286 12.6488 1.28 12.1395V12.2227C1.28041 13.7385 1.80513 15.2075 2.76516 16.3805C3.72519 17.5535 5.06141 18.3584 6.5472 18.6585C5.58064 18.9222 4.5665 18.9607 3.58272 18.7712C4.00242 20.0756 4.81924 21.2163 5.91899 22.0338C7.01873 22.8512 8.34644 23.3046 9.71648 23.3305C8.35525 24.4005 6.79642 25.1916 5.12917 25.6585C3.46191 26.1255 1.71895 26.2591 0 26.0518C3.00244 27.9785 6.4959 29.0005 10.0634 28.9958",fill:"#1DA1F2"})})}},46362:function(e,t,n){n.d(t,{Z:function(){return i}});var r=n(57437),a=n(36760),o=n.n(a);function i(e){let{className:t}=e;return(0,r.jsx)("svg",{className:o()("icon -ml-px -mt-px",t),height:"16",viewBox:"0 0 16 16",width:"16",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("path",{d:"M14.3896 3.19481C14.251 3.19894 14.1195 3.25685 14.0229 3.35627L5.86668 11.5125L2.51043 8.15627C2.46128 8.10508 2.40242 8.06422 2.33729 8.03607C2.27215 8.00792 2.20205 7.99304 2.1311 7.99232C2.06014 7.9916 1.98976 8.00504 1.92406 8.03186C1.85837 8.05868 1.79869 8.09834 1.74851 8.14852C1.69834 8.19869 1.65868 8.25838 1.63185 8.32407C1.60503 8.38976 1.59159 8.46015 1.59231 8.53111C1.59303 8.60206 1.60791 8.67216 1.63606 8.73729C1.66421 8.80243 1.70508 8.86129 1.75626 8.91044L5.4896 12.6438C5.58962 12.7438 5.72525 12.7999 5.86668 12.7999C6.0081 12.7999 6.14374 12.7438 6.24376 12.6438L14.7771 4.11044C14.8542 4.03552 14.9068 3.93908 14.9281 3.83373C14.9494 3.72839 14.9384 3.61906 14.8965 3.52008C14.8546 3.4211 14.7838 3.33709 14.6934 3.27905C14.6029 3.221 14.497 3.19164 14.3896 3.19481Z"})})}},2353:function(e,t,n){n.d(t,{XU:function(){return a},bW:function(){return o}});var r=n(4374);function a(e){let{expand:t=[],limit:n,startKey:a,updated:o,userId:i}=e,l=new URLSearchParams;return l.append("id",i),o instanceof Date&&l.append("updated","".concat(+o)),n&&!isNaN(n)&&l.append("limit","".concat(n)),a&&l.append("startKey",a),t.forEach(e=>l.append("expand",e)),(0,r.Z)("/api/project-export/recent?".concat(l))}function o(e){var t,n,a,o;let i=new URLSearchParams({projectId:e.projectId});(null===(t=e.project)||void 0===t?void 0:t.name)&&i.append("name",e.project.name);let l=null===(o=e.project)||void 0===o?void 0:null===(a=o.tokens.find(e=>"video"===e.type))||void 0===a?void 0:null===(n=a.options.find(e=>"video"===e.type))||void 0===n?void 0:n.image;return l&&i.append("image",l),(0,r.Z)("/api/project-export/deep-link?".concat(i.toString()),{method:"POST",headers:{"Content-Type":"application/json"}}).then(e=>e.json()).then(e=>e.url)}},37785:function(e,t,n){n.d(t,{Z:function(){return a}});var r=n(70916);function a(e){return(0,r.Z)("/project/".concat(e,"/view"))}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.