PageSourceSearch

https://cdn.azfans.com/react/v110/chunks/UploadPage.js

js azfans.com collected 2026-10-02 12:42:21 UTC 25,038 bytes, 1 lines download raw bytes

1import{j as t,r as o,o as gt,a as Te,g as yt,b as ie,d as le,s as xt,p as Ae,c as De}from"../app.js";import{s as bt}from"./authActions.js";import{r as vt,g as wt,s as jt}from"./firebaseStorage.js";import{i as Ct,c as kt,g as Nt,f as Me,u as It}from"./helpers.js";import{S as f}from"./sentry.js";import{C as St,a as Ut,T as Et,F as Tt,A as de,c as je}from"./AddEntityModal.js";import{T as At,E as ce}from"./EntityAutocomplete.js";function Dt(n,s){try{if(!s||isNaN(s))return[];const c=[];for(let h=0;h<n.length;h++){const x=n[h];if(x.yob&&!isNaN(x.yob)){const j=s-x.yob;j>0&&j<18&&c.push({...x,index:h,ageAtTime:j})}}if(c.length>0)try{f.addBreadcrumb({category:"age-verification",message:"Found underage celebrities",level:"warning",data:{count:c.length,contentYor:s,celebNames:c.map(h=>h.name).join(", ")}})}catch{}return c}catch(c){try{f.captureException(c,{tags:{area:"age-verification",op:"getCelebsUnderAge"},extra:{contentYor:s,celebCount:n?.length}})}catch{}return console.error("Error in getCelebsUnderAge:",c),[]}}function Re(n,s){try{if(!n||!s||isNaN(n)||isNaN(s))return!1;const c=s-n,h=c>0&&c<18;if(h)try{f.addBreadcrumb({category:"age-verification",message:"Age check triggered",level:"warning",data:{celebYob:n,contentYor:s,age:c}})}catch{}return h}catch(c){try{f.captureException(c,{tags:{area:"age-verification",op:"shouldTriggerAgeCheck"},extra:{celebYob:n,contentYor:s}})}catch{}return console.error("Error in shouldTriggerAgeCheck:",c),!1}}const te=({id:n,value:s,checked:c,name:h,onChange:x,label:j})=>t.jsxs("label",{htmlFor:n,className:`inline-flex items-center gap-2 px-3 py-1.5 rounded border cursor-pointer transition-colors text-[15px] font-semibold ${c?"border-primary bg-primary/10 text-primary":"border-[#333] text-[#888] hover:border-[#555] hover:text-white"}`,children:[t.jsx("input",{className:"hidden",id:n,type:"radio",value:s,checked:c,name:h,onChange:x}),j]});function Mt({value:n,onChange:s,varValues:c,isAzFans:h=!1}){if(h){const U=localStorage.getItem("sexuality");let k={straight:1,gay:2,trans:3};U==="Gay"?k={gay:1,straight:2,trans:3}:U==="Trans"&&(k={trans:1,gay:2,straight:3});const E=$=>{const u=$.target.value;u==="straight"?s("f"):u==="gay"?s("m"):u==="trans"&&s("t")};return t.jsxs("div",{children:[t.jsxs("label",{className:"text-[15px] mb-2",children:["What is the sexuality of the model? ",t.jsx("span",{className:"text-red-500",children:"*"})]}),t.jsxs("div",{className:"flex flex-wrap gap-2 mt-2",children:[t.jsx("div",{style:{order:k.straight},children:t.jsx(te,{id:"radioStraight",value:"straight",checked:n==="f",name:"user[sexuality]",onChange:E,label:"Straight"})}),t.jsx("div",{style:{order:k.gay},children:t.jsx(te,{id:"radioGay",value:"gay",checked:n==="m",name:"user[sexuality]",onChange:E,label:"Gay"})}),t.jsx("div",{style:{order:k.trans},children:t.jsx(te,{id:"radioTrans",value:"trans",checked:n==="t",name:"user[sexuality]",onChange:E,label:"Trans"})})]})]})}const x=n==="m",j=n==="f",I=c?.gender==="m"||c?.main==="azmen",O=U=>{const k=U.target.value==="male"?"m":"f";s(k)};return t.jsxs("div",{children:[t.jsxs("label",{className:"text-[15px] mb-2",children:["What is the gender of the celebrity? ",t.jsx("span",{className:"text-red-500",children:"*"})]}),t.jsxs("div",{className:"flex flex-wrap gap-2 mt-2",children:[t.jsx("div",{style:{order:I?2:1},children:t.jsx(te,{id:"radioFemale",value:"female",checked:j,name:"user[gender]",onChange:O,label:"Female"})}),t.jsx("div",{style:{order:I?1:2},children:t.jsx(te,{id:"radioMale",value:"male",checked:x,name:"user[gender]",onChange:O,label:"Male"})})]})]})}const Rt=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round",children:[t.jsx("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),t.jsx("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]});function Bt({celebrities:n,setCelebrities:s,onCelebritySelect:c,onRemoveCelebrity:h,onAddClick:x,onAddMore:j,unknownCelebrity:I,onUnknownChange:O,unknownCelebrityDisabled:U,unknownLockedHint:k,gender:E,contentType:$,isAzFans:u=!1}){const K=n.length,y=!u&&K<5&&n[K-1]?.firebaseId,[N,P]=o.useState(null),Y=i=>{i.preventDefault(),y&&j&&(P(K),j())},me=()=>n.filter(i=>i.firebaseId).map(i=>i.firebaseId),L=!u&&$!=="story",p=(i,S)=>{const R=[...n];R[i]={...R[i],appearance:S},s(R)},ae=i=>{O(i),s(i?[{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!0}]:[{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!1}])},v=u?1:5,M=[];for(let i=0;i<v;i++)M.push(n[i]||null);const V=u?"Who is the model?":"Select one or more celebrity";return t.jsxs("div",{children:[t.jsxs("div",{className:"flex items-center justify-between",children:[t.jsxs("label",{className:"text-[15px]",children:[V," ",t.jsx("span",{className:"text-red-500",children:"*"})]}),!u&&t.jsxs("label",{className:"unknown-toggle inline-flex items-center gap-1.5 text-[13px] text-[#888] cursor-pointer !mb-0 !font-normal",children:[t.jsx("input",{type:"checkbox",id:"unknownceleb",className:"accent-primary",checked:I,onChange:i=>ae(i.target.checked),disabled:U}),"Unknown Celeb",k&&t.jsx(At,{content:k,children:t.jsxs("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"cursor-help ml-1",children:[t.jsx("circle",{cx:"12",cy:"12",r:"10"}),t.jsx("line",{x1:"12",y1:"16",x2:"12",y2:"12"}),t.jsx("line",{x1:"12",y1:"8",x2:"12.01",y2:"8"})]})})]})]}),t.jsx("div",{className:"space-y-3",children:M.map((i,S)=>{const R=S===0,g=i&&i.firebaseId,B=S<K,F=g||!R&&B;return B?t.jsx("div",{className:"space-y-2",children:t.jsxs("div",{className:"flex gap-2 items-start",children:[g&&i?.thumb&&t.jsx("img",{src:i.thumb,alt:i.name,className:"w-10 h-10 shrink-0 rounded object-cover border border-[#333] bg-[#111]"}),t.jsx("div",{className:`flex-1 ${!u&&g&&L?"min-w-0":""}`,children:t.jsx(ce,{entityType:"celebrity",index:S,value:i?.name||"",onChange:()=>{},onSelect:W=>c(W,S),onAddClick:()=>x(S),disabled:i?.disabled||I,gender:E,existingSelections:me(),entityId:i?.firebaseId||"",entityYear:i?.yob||"",check18:i?.check18||"",isAzFans:u,autoFocus:N===S})}),!u&&g&&L&&t.jsxs("div",{className:"flex-1 min-w-0 relative",children:[t.jsx("div",{className:"flex absolute left-3 top-1/2 -translate-y-1/2 text-[#555] pointer-events-none",children:t.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:t.jsx("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"})})}),t.jsx("input",{name:"user[celebname-appearance]",type:"text",placeholder:"Role name (optional)",className:"form-input-dark !pl-[35px] pr-3",value:i?.appearance||"",onChange:W=>p(S,W.target.value)})]}),F&&t.jsx("button",{type:"button",className:"shrink-0 w-10 h-10 flex items-center justify-center rounded border border-[#333] text-[#888] hover:text-red-400 hover:border-red-500/50 transition-colors bg-transparent cursor-pointer",onClick:()=>h(S),children:t.jsx(Rt,{})})]})},i?.id||`slot-${S}`):null})}),!u&&y&&!I&&t.jsx("button",{type:"button",className:"btn-ghost text-sm mt-3",onClick:Y,children:"+ Add Additional Celebrity"})]})}function Lt({isOpen:n,onClose:s,onRemoveCelebrity:c,onContinueAnyway:h,celebrityName:x,contentTitle:j,contentType:I}){o.useEffect(()=>{if(n){try{f.addBreadcrumb({category:"age-verification",message:"Age verification modal opened",level:"info",data:{celebrityName:x,contentType:I}})}catch{}return document.body.style.overflow="hidden",()=>{document.body.style.overflow="unset"}}},[n,x,I]);const O=()=>{try{f.addBreadcrumb({category:"age-verification",message:"User removed underage celebrity",level:"info",data:{celebrityName:x,contentType:I,action:"remove"}})}catch{}c()},U=()=>{try{f.addBreadcrumb({category:"age-verification",message:"User continued with underage celebrity",level:"warning",data:{celebrityName:x,contentType:I,action:"continue"}})}catch{}h()};if(!n)return null;let k=j;return I==="story"&&!j?k="story":j&&(k=`"${j}"`),t.jsx("div",{className:"modal-overlay",children:t.jsxs("div",{className:"modal-box max-w-[480px]",children:[t.jsxs("div",{className:"modal-box-header",children:[t.jsx("h3",{children:"Age Verification"}),t.jsx("button",{type:"button",className:"bg-transparent border-none text-white opacity-80 curs
1or-pointer text-2xl leading-none p-0 hover:opacity-100",onClick:s,children:"×"})]}),t.jsx("div",{className:"modal-box-body",children:t.jsxs("p",{className:"text-sm leading-relaxed",children:["It appears that the celebrity, ",t.jsx("strong",{children:x}),", was under 18, thus a minor, at the time of the ",t.jsx("strong",{children:k})," shoot."]})}),t.jsxs("div",{className:"modal-box-footer",children:[t.jsx("button",{type:"button",className:"btn-ghost text-[13px]",onClick:O,children:"Remove Celebrity"}),t.jsx("button",{type:"button",className:"btn-primary-tw text-[13px]",onClick:U,children:"Continue Anyway"})]})]})})}const Be=200,Le=150,_e=50,Ce="You need at least 10 published uploads before you can select an unknown celeb, movie, or series.";function _t({varValues:n,isAzFans:s=!1}){const[c,h]=o.useState(null),[x,j]=o.useState(!1),[I,O]=o.useState(!1),[U,k]=o.useState(!0),[E,$]=o.useState(""),[u,K]=o.useState(()=>{if(s){const e=localStorage.getItem("sexuality");return e==="Gay"?"m":e==="Trans"?"t":"f"}return n?.gender==="m"?"m":"f"}),[y,N]=o.useState([{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!1}]),[P,Y]=o.useState(!1),[me,L]=o.useState(!1),[p,ae]=o.useState("movie"),[v,M]=o.useState({name:"",id:"",yor:"",thumb:""}
1),[V,i]=o.useState(!1),[S,R]=o.useState(!1),[g,B]=o.useState({name:"",id:"",yor:"",thumb:""}),[F,W]=o.useState(!1),[Oe,ne]=o.useState(!1),[z,ke]=o.useState(!1),[w,J]=o.useState({name:"",id:"",yor:"",thumb:""}),[se,Ne]=o.useState([]),[ue,$e]=o.useState([]),[re,Q]=o.useState([]),[X,We]=o.useState(""),[_,oe]=o.useState({isOpen:!1,celebrityName:"",celebrityIndex:null,contentTitle:"",contentType:"movie"}),[Pe,fe]=o.useState(!1),[Ie,he]=o.useState(null),[Ve,pe]=o.useState(!1),[Fe,ge]=o.useState(!1),[Ge,ye]=o.useState(!1),[xe,Se]=o.useState(!1),[Ue,Z]=o.useState(""),[qe,be]=o.useState(!0),He=o.useRef(null),G=o.useRef(null);o.useRef(null),o.useEffect(()=>{const e=gt(Te,async a=>{if(!a){f.setUser(null),window.location.href="/signin.html?next="+encodeURI(window.location.href);return}try{const l=await a.getIdTokenResult(!0);if(f.setUser({id:a.uid||void 0,email:a.email||void 0}),f.setContext("firebaseClaims",l?.claims||{}),l.claims.isBanned)return localStorage.removeItem("azn_id"),f.addBreadcrumb({category:"auth",message:"User is banned, signing out",level:"info"}),bt(Te);if(Ct(a.uid)){j(!0),be(!1);return}h(a),k(a.emailVerified);const d=await kt(a.uid);O(d);try{const r=await yt(ie(le,`userStats/${a.uid}/publishedUploadCount`));ke((r.val()||0)>=10)}catch(r){ke(!1);try{f.captureException(r,{tags:{area:"upload",op:"published-count"},extra:{uid:a.uid}})}catch{}}be(!1)}catch(l){f.captureException(l,{tags:{area:"auth",op:"getIdTokenResult"}}),be(!1)}});return()=>e()},[]);const ve=e=>!!e.verifiedName&&e.verifiedName===e.name,Ke=async e=>{if(e.preventDefault(),E!=="Sending..."){$("Sending...");try{await xt(c),$("Verification email sent! Please check your inbox.")}catch(a){a.code==="auth/too-many-requests"?$("A verification email was already sent. Please check your inbox or try again in a few minutes."):$("Failed to send verification email. Please try again later."),f.captureException(a,{tags:{area:"auth",op:"sendEmailVerification"}})}}},Ee=()=>p==="movie"?v.yor?parseInt(v.yor,10):null:p==="series"?g.yor?parseInt(g.yor,10):null:p==="story"&&w.yor?parseInt(w.yor,10):null,Ye=()=>p==="movie"?v.name||"movie":p==="series"?g.name||"series":p==="story"?w.name||"story":"",we=(e,a,l)=>{const d=l||Ye();f.addBreadcrumb({category:"age-verification",message:"Age check modal triggered",level:"warning",data:{celebrityName:e.n
1ame,index:a,contentType:p}}),oe({isOpen:!0,celebrityName:e.name,celebrityIndex:a,contentTitle:d,contentType:p})},q=(e,a)=>{if(!e||P)return;const l=Dt(y,e);l.length>0&&we(l[0],l[0].index,a)},ze=()=>{const{celebrityIndex:e}=_;if(y.length===1)N([{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!1}]);else{const a=y.filter((l,d)=>d!==e);N(a)}oe({..._,isOpen:!1}),Z("")},Je=()=>{const{celebrityIndex:e}=_,a=[...y];a[e]={...a[e],check18:"true"},N(a),oe({..._,isOpen:!1})},Qe=e=>{if(Y(e),e)N([{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!0}]),R(!0),ne(!0),i(!1),W(!1);else{const a=[...y];a.length>0&&(a[0].disabled=!1),N(a),R(!1),ne(!1)}},Xe=e=>{if(i(e),e){M({name:"",id:"",yor:"",thumb:""}),L(!0),Y(!1);const a=[...y];a.length>0&&a[0].disabled&&(a[0].disabled=!1),N(a)}else L(!1)},Ze=e=>{if(W(e),e){B({name:"",id:"",yor:"",thumb:""}),L(!0),Y(!1);const a=[...y];a.length>0&&a[0].disabled&&(a[0].disabled=!1),N(a)}else L(!1)},et=(e,a)=>{const l=[...y];if(l[a]={...e,check18:""},N(l),!s){const d=Ee();d&&Re(e.yob,d)&&setTimeout(()=>we(e,a),100)}},tt=e=>{const a=Ie!==null?Ie:y.length-1,l=[...y];if(l[a]={...e,check18:""},N(l),!s){const d=Ee();d&&e.yob&&Re(e.yob,d)&&setTimeout(()=>we(e,a),100)}fe(!1),he(null)},at=()=>{if(y.length<5){const e=[...y];e.length>0&&(e[e.length-1].disabled=!0),e.push({id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!1}),N(e)}},nt=e=>{if(y.length===1)N([{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!1}]);else{const a=[...y];for(let l=e;l<a.length-1;l++)a[l]={...a[l+1]};a.pop(),a.length>0&&!a[a.length-1].firebaseId&&(a[a.length-1].disabled=!1),N(a)}},st=e=>{M({...e,verifiedName:e.id&&e.id!=="freetext"?e.name:""}),e.yor&&q(parseInt(e.yor,10),e.name)},rt=e=>{B({...e,verifiedName:e.id&&e.id!=="freetext"?e.name:""}),e.yor&&q(parseInt(e.yor,10),e.name)},ot=e=>{J({...e,verifiedName:e.id&&e.id!=="freetext"?e.name:""}),e.yor&&q(parseInt(e.yor,10),e.name)},it=e=>{M(e),e.yor&&q(parseInt(e.yor,10),e.name),pe(!1)},lt=e=>{B(e),e.yor&&q(parseInt(e.yor,10),e.name),ge(!1)},dt=e=>{J(e),e.yor&&q(parseInt(e.yor,10),e.name),ye(!1)},ct=e=>{ae(e),e!=="movie"&&M({name:"",id:"",yor:"",thumb:""}),e!=="series"&&B({name:"",id:"",yor:"",thumb:""}),e!=="story"&&J({name:"",id:"",yor:"",thumb:""}),i(!1),W(!1),R(!1),ne(!1),L(!1),setTimeout(()=>{let a=null;e==="movie"&&v.yor?a=parseInt(v.yor,10):e==="series"&&g.yor?a=parseInt(g.yor,10):e==="story"&&w.yor&&(a=parseInt(w.yor,10)),a&&q(a)},0)},mt=e=>{K(e),N([{id:Date.now(),name:"",appearance:"",firebaseId:"",yob:"",check18:"",disabled:!1}]),Ne([]),s||(Y(!1),L(!1),M({name:"",id:"",yor:"",thumb:""}),B({name:"",id:"",yor:"",thumb:""}),J({name:"",id:"",yor:"",thumb:""}),i(!1),R(!1),W(!1),ne(!1),ae("movie"))},ut=async e=>{e.preventDefault(),Se(!0),Z("");try{f.addBreadcrumb({category:"upload",message:"Submit started",level:"info"});const a=new Set,l=[];if(re.forEach(m=>{a.has(m.file.name)?l.push(m.id):a.add(m.file.name)}),l.length>0){f.addBreadcrumb({category:"upload",level:"info",message:"Submit-time dedupe",data:{removedCount:l.length}});const m=re.filter(C=>!l.includes(C.id));Q(m)}const d=re.filter(m=>!l.includes(m.id));if(d.length===0)throw new Error("Please add some files to upload.");if(d.length>Be)throw new Error(`Maximum files allowed is ${Be}, currently it's ${d.length}.`);let r=0,T=0;if(d.forEach(m=>{const C=m.file.type;C==="image/jpeg"||C==="image/png"?r++:(C==="video/mp4"||C==="video/avi"||C==="video/3gpp"||C==="video/3gpp2"||C==="video/3gp2"||C==="video/mpeg"||C==="video/ogg"||C==="video/quicktime"||C==="video/webm")&&T++}),r>Le)throw new Error(`Maximum images allowed is ${Le}, currently it's ${r}.`);if(T>_e)throw new Error(`Maximum videos allowed is ${_e}, currently it's ${T}.`);if(y.filter(m=>m.firebaseId).length===0&&!P)throw new Error("No celeb has been selected or uploaded.");if(P&&(V||F))throw new Error("Cannot have unknown celebs and unknown movie/series at the same time.");if(!s){if(p==="movie"){if(!V&&!v.id)throw new Error("No movie has been selected, uploaded, or marked as unknown.");if(!V&&v.name&&!ve(v)){const m=await je(v.name);if(m)throw new Error(`Your movie title contains an illegal word, which is '${m}'.`)}}else if(p==="series"){if(!F&&!g.id)throw new Error("No series has been selected, uploaded, or marked as unknown.");if(!F&&g.name&&!ve(g)){const m=await je(g.name);if(m)throw new Error(`Your series title contains an illegal word, which is '${m}'.`)}}else if(p==="story"){if(!w.id)throw new Error("No story has been selected or added.");if(w.yor&&!/^\d{4}
1$/.test(String(w.yor)))throw new Error("Story year is invalid. Please re-select the story.");if(w.name&&!ve(w)){const m=await je(w.name);if(m)throw new Error(`Your story title contains an illegal word, which is '${m}'.`)}}}if(I&&se.length===0)throw new Error("Please include at least one category.");await ft(d)}catch(a){f.captureException(a,{tags:{area:"upload",op:"handleFormSubmit"}}),Z(a.message),Se(!1),setTimeout(()=>{G.current&&(G.current.scrollIntoView({behavior:"smooth",block:"center"}),G.current.focus())},100)}},ft=async e=>{const a=ie(le,"Uploads"),d=Ae(a).key;f.addBreadcrumb({category:"upload",message:"Starting Firebase upload",level:"info",data:{uploadId:d,numFiles:e.length}}),Q(A=>A.map(D=>({...D,isUploading:!0})));const r=e.map(A=>ht(A,d,D=>{Q(ee=>ee.map(H=>H.id===A.id?{...H,progress:D}:H))}).then(D=>(Q(ee=>ee.map(H=>H.id===A.id?{...H,isDone:!0,progress:100}:H)),D)).catch(D=>{throw f.captureException(D,{tags:{area:"storage",op:"uploadFile"},extra:{uploadId:d,fileName:A.file.name}}),D})),T=await Promise.all(r),b=await Nt(),m=pt(d,T,b),C=ie(le,`uploads/${d}`);f.addBreadcrumb({category:"upload",level:"info",message:"All files uploaded successfully, finalizing",data:{uploadId:d,count:e.length}});try{await De(C,m),window.location.href="/profile.html#content-uploaded"}catch(A){throw f.captureException(A,{tags:{area:"realtime-db",op:"createUploadEntry"},extra:{uploadId:d}}),new Error("Failed to create upload entry in database.")}},ht=async(e,a,l)=>{const r=`Uploads/${`${Date.now()}-${e.file.name}`}`,T=vt(jt,r),b={contentType:e.file.type};f.addBreadcrumb({category:"storage",level:"info",message:"Starting uploadBytesResumable",data:{id:e.id,uploadId:a,fileURL:r,fileName:e.file.name,fileType:e.file.type,fileSize:Me(e.file.size)}}),await It(T,e.file,b,D=>{const ee=Math.floor(D.bytesTransferred/D.totalBytes*100);l&&l(ee)});const m=await wt(T),C=ie(le,"files"),A=Ae(C);return await De(A,{uploadedBy:c.uid,downloadURL:m,createdOn:Date.now(),uploadId:a,fileType:e.file.type,fileSize:Me(e.file.size),fileURL:r}),{fileId:A.key}},pt=(e,a,l)=>{const d=y.filter(b=>b.firebaseId);if(s){const b={files:a,status:"awaiting_moderation",createdOn:Date.now(),createdBy:c.uid,website:"azfans",sexuality:u,tags:ue.join(","),categories:se.join("|"),ip:l,celebName:d.map(m=>m.name).join("|"),celebIds:d.map(m=>m.firebaseId).join("|")};return X&&(b.comments=X),b}const r={files:a,status:"awaiting_moderation",createdOn:Date.now(),createdBy:c.uid,gender:u==="m"?"male":"female",tags:ue.join(","),categories:se.join("|"),ip:l},T=n?.genderLong==="feet";return r.website=n?.main==="azfans"?"azfans":u==="m"?T?"feetmen":"azmen":T?"feet":"az",X&&(r.comments=X),P?(r.celebName="az-undetermined",r.celebIds="-1",r.check_18="-1"):(r.celebName=d.map(b=>b.name).join("|"),r.celebIds=d.map(b=>b.firebaseId).join("|"),r.check_18=d.map(b=>b.check18||"-1").join("|")),p==="movie"?(r.type="movie",r.appearance=d.map(b=>b.appearance||"-1").join("|"),V?(r.movieName="az-undetermined",r.movieId="-1"):(r.movieName=v.name,r.movieId=v.id)):p==="series"?(r.type="series",r.appearance=d.map(b=>b.appearance||"-1").join("|"),F?(r.seriesName="az-undetermined",r.seriesId="-1"):(r.seriesName=g.name,r.seriesId=g.id)):p==="story"&&(r.type="story",r.storyName=w.name,r.storyId=w.id),r};return qe?t.jsx("div",{className:"max-w-[900px] mx-auto px-4",children:t.jsx("div",{className:"flex justify-center py-15",children:t.jsx("div",{className:"spinner"})})}):x?t.jsx("div",{className:"max-w-[900px] mx-auto px-4 py-8",children:t.jsx("div",{className:"alert-bar !bg-red-500/10 !border-red-500/30 !text-red-400",children:t.jsx("div",{className:"flex-1",children:"Your account has been restricted from uploading content. If you believe this is an error, please contact support."})})}):t.jsxs("div",{className:"max-w-[900px] mx-auto px-4",children:[t.jsx("h1",{className:"text-[22px] font-semibold mb-1",children:"Upload"}),!U&&t.jsxs("div",{className:"mb-5",children:[t.jsxs("p",{className:"text-[15px] mb-2",children:["Please verify your email (",c?.email,") to upload content."," ",t.jsx("a",{href:"#",onClick:Ke,children:"Click here"})," ","to resend verification email. You can also go to"," ",t.jsx("a",{href:"/profile.html#settings",children:"Settings"})," to change your email."]}),E&&t.jsx("p",{className:"text-xs text-primary mt-2",children:E})]}),t.jsxs("div",{className:U?"":"opacity-40 pointer-events-none",children:[Ue&&t.jsxs("div",{ref:G,className:"alert-bar mb-5 !bg-red-500/10 !border-red-500/30 !text-red-400",tabIndex:"0",children:[t.jsx("div",{className:"flex-1",children:Ue}),t.jsx("button",{type:"button",onClick:()=>Z(""),className:"alert-bar-close !text-red-400","aria-label":"Dismiss",children:"×"})]}),t.jsx("form",{id:"upload",name:"upload",onKeyDown:e=>e.key==="Enter"&&e.preventDefault(),onSubmit:ut,children:t.jsxs("fieldset",{disabled:xe,className:"border-none p-0 m-0 space-y-2",children:[t.jsx("div",{children:t.jsx(Mt,{value:u,onChange:mt,varValues:n,isAzFans:s})}),t.jsx("div",{children:t.jsx(Bt,{celebrities:y,setCelebrities:N,onCelebritySelect:et,onRemoveCelebrity:nt,onAddClick:e=>{he(e),fe(!0)},onAddMore:at,unknownCelebrity:P,onUnknownChange:Qe,unknownCelebrityDisabled:me||!z,unknownLockedHint:z?null:Ce,gender:u,contentType:p,isAzFans:s})}),!s&&t.jsxs("div",{className:"space-y-2",children:[t.jsx(St,{value:p,onChange:ct}),p==="story"&&t.jsx("p",{className:"text-[#666] text-sm leading-relaxed !mt-1",children:"A story covers real-world appearances, events, and candid moments. Think red carpet arrivals, award show outfits, paparazzi shots, vacation sightings, or any public appearance."}
1),t.jsx(ce,{entityType:"movie",value:v.name,entityId:v.id,entityYear:v.yor,entityThumb:v.thumb,onChange:e=>M({...v,name:e}),onSelect:st,onAddClick:()=>pe(!0),onClear:()=>M({name:"",id:"",yor:"",thumb:""}),gender:u,unknown:V,onUnknownChange:Xe,unknownDisabled:S||!z,unknownLockedHint:z?null:Ce,visible:p==="movie"}),t.jsx(ce,{entityType:"story",value:w.name,entityId:w.id,entityYear:w.yor,entityThumb:w.thumb,onChange:e=>J({...w,name:e}),onSelect:ot,onAddClick:()=>ye(!0),onClear:()=>J({name:"",id:"",yor:"",thumb:""}),gender:u,visible:p==="story"}),t.jsx(ce,{entityType:"series",value:g.name,entityId:g.id,entityYear:g.yor,entityThumb:g.thumb,onChange:e=>B({...g,name:e}),onSelect:rt,onAddClick:()=>ge(!0),onClear:()=>B({name:"",id:"",yor:"",thumb:""}),gender:u,unknown:F,onUnknownChange:Ze,unknownDisabled:Oe||!z,unknownLockedHint:z?null:Ce,visible:p==="series"})]}),t.jsx("div",{children:t.jsx(Ut,{gender:u,categories:se,onChange:Ne,isAzFans:s})}),t.jsx("div",{children:t.jsx(Et,{tags:ue,onChange:$e})}),t.jsx("div",{children:t.jsx(Tt,{ref:He,files:re,onChange:Q,onError:e=>{Z(e),setTimeout(()=>{G.current&&(G.current.scrollIntoView({behavior:"smooth",block:"center"}),G.current.focus())},100)}})}),t.jsxs("div",{children:[t.jsx("label",{htmlFor:"comments",className:"text-[15px] mb-2",children:"Moderator Notes"}),t.jsxs("div",{className:"relative",children:[t.jsx("div",{className:"flex absolute left-3 top-1/2 -translate-y-1/2 text-[#555] pointer-events-none",children:t.jsx("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:t.jsx("path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"})})}),t.jsx("input",{type:"text",id:"comments",className:"form-input-dark !pl-[35px] pr-3",placeholder:"Add a comment (optional)",value:X,onChange:e=>We(e.target.value)})]})]}),t.jsx("button",{id:"submitBtn",type:"submit",className:"btn-primary-tw w-full py-3.5 text-base",disabled:xe||!U,children:xe?"Uploading...":"Upload"})]})})]}),!s&&t.jsx(Lt,{isOpen:_.isOpen,onClose:()=>oe({..._,isOpen:!1}),onRemoveCelebrity:ze,onContinueAnyway:Je,celebrityName:_.celebrityName,contentTitle:_.contentTitle,contentType:_.contentType}),t.jsx(de,{entityType:"celebrity",isOpen:Pe,onClose:()=>{fe(!1),he(null)},onAdd:tt,gender:u,varValues:n,isAzFans:s}),!s&&t.jsxs(t.Fragment,{children:[t.jsx(de,{entityType:"movie",isOpen:Ve,onClose:()=>pe(!1),onAdd:it,gender:u,varValues:n}),t.jsx(de,{entityType:"series",isOpen:Fe,onClose:()=>ge(!1),onAdd:lt,gender:u,varValues:n}),t.jsx(de,{entityType:"story",isOpen:Ge,onClose:()=>ye(!1),onAdd:dt,gender:u})]})]})}const qt=()=>{const n=document.querySelector('meta[name="website"]')?.content==="azfans";return t.jsx(_t,{varValues,isAzFans:n})};export{qt as default};

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.