dsql-admin/dsql-app/.local_dist/server/chunks/7640.js

1 line
29 KiB
JavaScript
Raw Normal View History

2024-12-09 09:39:09 +00:00
"use strict";exports.id=7640,exports.ids=[7640],exports.modules={30671:(e,a)=>{Object.defineProperty(a,"M",{enumerable:!0,get:function(){return function e(a,t){return t in a?a[t]:"then"in a&&"function"==typeof a.then?a.then(a=>e(a,t)):"function"==typeof a&&"default"===t?a:void 0}}})},99486:(e,a,t)=>{t.d(a,{A:()=>o});var l=t(8732);t(82015);var i=t(55158),s=t(83158),n=t(82544);let r=(0,n.A)("Files",[["path",{d:"M20 7h-3a2 2 0 0 1-2-2V2",key:"x099mo"}],["path",{d:"M9 18a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h7l4 4v10a2 2 0 0 1-2 2Z",key:"18t6ie"}],["path",{d:"M3 7.6v12.8A1.6 1.6 0 0 0 4.6 22h9.8",key:"1nja0z"}]]),d=(0,n.A)("FileVideo2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4",key:"1pf5j1"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["rect",{width:"8",height:"6",x:"2",y:"12",rx:"1",key:"1a6c1e"}],["path",{d:"m10 15.5 4 2.5v-6l-4 2.5",key:"t7cp39"}]]);function o({user:e}){return(0,l.jsx)(i.Ay,{title:"choose-media-type-popoup",noContainer:!0,wrapperClasses:"items-center",wrapperStyle:{alignItems:"center"},children:(0,l.jsxs)("div",{className:"paper items-center max-w-2xl m-auto z-50 p-4 xl:p-10",children:[(0,l.jsxs)("h4",{className:"m-0 text-center text-lg leading-tight",children:["What kind of Media do you",(0,l.jsx)("br",{}),"want to upload?"]}),(0,l.jsx)("span",{children:"Please Select the media type to upload."}),(0,l.jsxs)("div",{className:"w-full grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch",children:[(0,l.jsxs)("div",{className:"card cursor-pointer",onClick:a=>{if(e?.verification_status?.toString().match(/1/)){let e=document.getElementById("upload_image_input");e?.click()}else alert("Please Verify to Add Media");setTimeout(()=>{(0,i.fs)()},500)},children:[(0,l.jsx)(s.A,{size:50,className:"text-primary"}),(0,l.jsxs)("div",{className:"content",children:[(0,l.jsx)("span",{className:"title",children:"Images"}),(0,l.jsx)("span",{className:"text-sm",children:"General image formats like JPEG, PNG, SVG, WEBP, etc."})]})]}),(0,l.jsxs)("div",{className:"card cursor-pointer",onClick:a=>{e?.verification_status?.toString().match(/1/)?document.getElementById("upload_file_input")?.click():alert("Please Verify to Add Media"),(0,i.fs)()},children:[(0,l.jsx)(r,{size:50,className:"text-secondary"}),(0,l.jsxs)("div",{className:"content",children:[(0,l.jsx)("span",{className:"title",children:"Files"}),(0,l.jsx)("span",{className:"text-sm",children:"Other documents type. Like PDF, XLSX, CSV, etc."})]})]})]}),(0,l.jsx)("div",{className:"w-full grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch",children:(0,l.jsxs)("div",{className:"card cursor-pointer",onClick:a=>{e?.verification_status?.toString().match(/1/)?document.getElementById("upload_video_input")?.click():alert("Please Verify to Add Media"),(0,i.fs)()},children:[(0,l.jsx)(d,{size:55,className:"text-slate-600"}),(0,l.jsxs)("div",{className:"content",children:[(0,l.jsx)("span",{className:"title",children:"Videos"}),(0,l.jsxs)("span",{className:"text-sm",children:["Video Files. ",(0,l.jsx)("b",{children:"MP4"})," for now. These files can be streamed. Max 200mb"]})]})]})})]})})}},82747:(e,a,t)=>{t.d(a,{A:()=>N});var l=t(8732),i=t(82015),s=t.n(i),n=t(63715),r=t(32415),d=t(82544);let o=(0,d.A)("Folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);var c=t(58150);function m({folderName:e,folder:a,user:t}){let i=`${a?a+"/":""}${e}`,[d,m]=s().useState(!1);return(0,l.jsxs)("a",{href:`/admin/${t?.id}/media/${i}`,className:"card col items-center justify-center",onClick:e=>{if(e.target.closest("button"))return e.preventDefault()},children:[d&&(0,l.jsx)(r.A,{}),(0,l.jsx)(o,{opacity:.5}),(0,l.jsx)("span",{className:"absolute top-4 left-4 text-xs bg-slate-200 dark:bg-slate-700 px-2 py-0.5 rounded-full",children:"Folder"}),(0,l.jsx)("span",{className:"",children:e}),(0,l.jsx)("button",{className:"plain-text absolute top-2 right-2",onClick:e=>{window.confirm("Delete this Folder and all its contents?")&&(m(!0),window.confirm("NOTE: this folder and all its contents will b