PageSourceSearch

https://watchmyfilm.com/_next/static/chunks/2572.9b19f224dbd038c6.js

js watchmyfilm.com collected 2026-10-07 11:19:54 UTC 86,576 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2572],{53666:function(e,s){s.DF={prefix:"fas",iconName:"circle-notch",icon:[512,512,[],"f1ce","M222.7 32.1c5 16.9-4.6 34.8-21.5 39.8C121.8 95.6 64 169.1 64 256c0 106 86 192 192 192s192-86 192-192c0-86.9-57.8-160.4-137.1-184.1c-16.9-5-26.6-22.9-21.5-39.8s22.9-26.6 39.8-21.5C434.9 42.1 512 140 512 256c0 141.4-114.6 256-256 256S0 397.4 0 256C0 140 77.1 42.1 182.9 10.6c16.9-5 34.8 4.6 39.8 21.5z"]},s.IJ=s.DF},41124:function(e,s){s.E=function(e,s){return e.split(",").map(function(e){var s=(e=e.trim()).match(t),n=s[1],l=s[2],r=s[3]||"",c={};return c.inverse=!!n&&"not"===n.toLowerCase(),c.type=l?l.toLowerCase():"all",r=r.match(/\([^\)]+\)/g)||[],c.expressions=r.map(function(e){var s=e.match(a),t=s[1].toLowerCase().match(i);return{modifier:t[1],feature:t[2],value:s[2]}}),c}).some(function(e){var t=e.inverse,a="all"===e.type||s.type===e.type;if(a&&t||!(a||t))return!1;var i=e.expressions.every(function(e){var t=e.feature,a=e.modifier,i=e.value,n=s[t];if(!n)return!1;switch(t){case"orientation":case"scan":return n.toLowerCase()===i.toLowerCase();case"width":case"height":case"device-width":case"device-height":i=d(i),n=d(n);break;case"resolution":i=c(i),n=c(n);break;case"aspect-ratio":case"device-aspect-ratio":case"device-pixel-ratio":i=r(i),n=r(n);break;case"grid":case"color":case"color-index":case"monochrome":i=parseInt(i,10)||1,n=parseInt(n,10)||0}switch(a){case"min":return n>=i;case"max":return n<=i;default:return n===i}});return i&&!t||!i&&t})};var t=/(?:(only|not)?\s*([^\s\(\)]+)(?:\s*and)?\s*)?(.+)?/i,a=/\(\s*([^\s\:\)]+)\s*(?:\:\s*([^\s\)]+))?\s*\)/,i=/^(?:(min|max)-)?(.+)/,n=/(em|rem|px|cm|mm|in|pt|pc)?$/,l=/(dpi|dpcm|dppx)?$/;function r(e){var s,t=Number(e);return t||(t=(s=e.match(/^(\d+)\s*\/\s*(\d+)$/))[1]/s[2]),t}function c(e){var s=parseFloat(e);switch(String(e).match(l)[1]){case"dpcm":return s/2.54;case"dppx":return 96*s;default:return s}}function d(e){var s=parseFloat(e);switch(String(e).match(n)[1]){case"em":case"rem":return 16*s;case"cm":return 96*s/2.54;case"mm":return 96*s/2.54/10;case"in":return 96*s;case"pt":return 72*s;case"pc":return 72*s/12;default:return s}}},88079:function(e,s,t){var a=t(41124).E,i="undefined"!=typeof window?window.matchMedia:null;function n(e,s,t){var n,l=this;function r(e){l.matches=e.matches,l.media=e.media}i&&!t&&(n=i.call(window,e)),n?(this.matches=n.matches,this.media=n.media,n.addListener(r)):(this.matches=a(e,s),this.media=e),this.addListener=function(e){n&&n.addListener(e)},this.removeListener=function(e){n&&n.removeListener(e)},this.dispose=function(){n&&n.removeListener(r)}}e.exports=function(e,s,t){return new n(e,s,t)}},722:function(e,s,t){t.d(s,{ac:function(){return O}});var a=t(2265),i=t(88079),n=t.n(i),l=/[A-Z]/g,r=/^ms-/,c={};function d(e){return"-"+e.toLowerCase()}var o=function(e){if(c.hasOwnProperty(e))return c[e];var s=e.replace(l,d);return c[e]=r.test(s)?"-"+s:s},m=t(40718),x=t.n(m);let p=x().oneOfType([x().string,x().number]),u={all:x().bool,grid:x().bool,aural:x().bool,braille:x().bool,handheld:x().bool,print:x().bool,projection:x().bool,screen:x().bool,tty:x().bool,tv:x().bool,embossed:x().bool},{type:h,...b}={orientation:x().oneOf(["portrait","landscape"]),scan:x().oneOf(["progressive","interlace"]),aspectRatio:x().string,deviceAspectRatio:x().string,height:p,deviceHeight:p,width:p,deviceWidth:p,color:x().bool,colorIndex:x().bool,monochrome:x().bool,resolution:p,type:Object.keys(u)},g={minAspectRatio:x().string,maxAspectRatio:x().string,minDeviceAspectRatio:x().string,maxDeviceAspectRatio:x().string,minHeight:p,maxHeight:p,minDeviceHeight:p,maxDeviceHeight:p,minWidth:p,maxWidth:p,minDeviceWidth:p,maxDeviceWidth:p,minColor:x().number,maxColor:x().number,minColorIndex:x().number,maxColorIndex:x().number,minMonochrome:x().number,maxMonochrome:x().number,minResolution:p,maxResolution:p,...b};var j={...u,...g};let f=e=>`not ${e}`,v=(e,s)=>{let t=o(e);return("number"==typeof s&&(s=`${s}px`),!0===s)?t:!1===s?f(t):`(${t}: ${s})`},_=e=>e.join(" and "),N=e=>{let s=[];return Object.keys(j).forEach(t=>{let a=e[t];null!=a&&s.push(v(t,a))}),_(s)},y=(0,a.createContext)(void 0),w=e=>e.query||N(e),S=e=>{if(e)return Object.keys(e).reduce((s,t)=>(s[o(t)]=e[t],s),{})},k=()=>{let e=(0,a.useRef)(!1);return(0,a.useEffect)(()=>{e.current=!0},[]),e.current},C=e=>{let s=(0,a.useContext)(y),t=()=>S(e)||S(s),[i,n]=(0,a.useState)(t);return(0,a.useEffect)(()=>{let e=t();!function(e,s){if(e===s)return!0;
1if(!e||!s)return!1;let t=Object.keys(e),a=Object.keys(s),i=t.length;if(a.length!==i)return!1;for(let a=0;a<i;a++){let i=t[a];if(e[i]!==s[i]||!Object.prototype.hasOwnProperty.call(s,i))return!1}return!0}(i,e)&&n(e)},[e,s]),i},F=e=>{let s=()=>w(e),[t,i]=(0,a.useState)(s);return(0,a.useEffect)(()=>{let e=s();t!==e&&i(e)},[e]),t},E=(e,s)=>{let t=()=>n()(e,s||{},!!s),[i,l]=(0,a.useState)(t),r=k();return(0,a.useEffect)(()=>{if(r){let e=t();return l(e),()=>{e&&e.dispose()}}},[e,s]),i},P=e=>{let[s,t]=(0,a.useState)(e.matches);return(0,a.useEffect)(()=>{let s=e=>{t(e.matches)};return e.addListener(s),t(e.matches),()=>{e.removeListener(s)}},[e]),s},O=(e,s,t)=>{let i=C(s),n=F(e);if(!n)throw Error("Invalid or missing MediaQuery!");let l=E(n,i),r=P(l),c=k();return(0,a.useEffect)(()=>{c&&t&&t(r)},[r]),(0,a.useEffect)(()=>()=>{l&&l.dispose()},[]),r}},3389:function(e,s,t){t.d(s,{Z:function(){return m}});var a=t(57437),i=t(23563),n=t(2265),l=t(51268),r=t(35217),c=t(65725);t(2121);var d=t(5943),o=t.n(d);function m(e){let[s,t]=(0,n.useState)(Object),[d,m]=(0,n.use
1State)(e.defaultValue),[x,p]=(0,n.useState)(!1),[u,h]=(0,n.useState)(String),b=e.onChange,g=!!e.border&&e.border,j=e.accept?e.accept:{},f=!!e.disabled&&e.disabled,v=!!e.isDark&&e.isDark,_=e.maxSize?e.maxSize:2,[N,y]=(0,n.useState)(String),{getRootProps:w,getInputProps:S}=(0,c.uI)({accept:j,noDrag:!0,onDrop:e=>{var s;let t,a,n=e[0];n.size<=1048576*_?((s=new FormData).append("file",n),(t=window.location.host).indexOf(":")>-1&&(t=t.trim().substring(0,t.trim().indexOf(":"))),a=i.Z.api_url+"upload","prod"==i.Z.app_env&&(a="https://"+t+"/"+a),o().ajax({url:a,dataType:"text",cache:!1,contentType:!1,processData:!1,data:s,type:"post",success:function(e){let s=o().parseJSON(e);m(s.name),b({name:s.name,path:s.path,url:s.url})}})):y("File size exceeds the allowed limit of "+_+"MB")}});return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex",children:[(0,a.jsxs)("div",{...w({className:"btn !rounded-l-lg !rounded-r-none flex-none content-center"+(f?" disabled":"")}),children:[(0,a.jsx)("input",{disabled:f,...S()}),(0,a.jsx)("p",{children:"Browse"})]}),(0,a.jsx)("div",{className:"".concat(v?"bg-zinc-900":"bg-white"," h-[46px] rounded-r-lg flex-1 px-[10px] relative ").concat(g?"border-gray-300 border":""," ").concat(f?"!bg-gray-100":""),children:(0,a.jsxs)("p",{className:"leading-[46px]",children:[d||(0,a.jsx)("i",{className:"text-gray-300",children:"No File Choosen"}),d&&!f&&(0,a.jsx)("div",{className:"absolute h-[46px] content-center w-[46px] right-0 text-center top-0",onClick:function(e){m(""),b({})},children:(0,a.jsx)(l.G,{icon:r.NBC})})]})})]}),N&&(0,a.jsx)("p",{className:"text-xs text-red-500 mt-[5px]",children:N})]})}},92572:function(e,s,t){t.r(s),t.d(s,{default:function(){return q}});var a=t(57437),i=t(27648),n=t(2265),l=t(11614),r=t(85221),c=t(40586),d=t(51268),o=t(35217),m=t(99376),x=t(85994),p=t.n(x);t(21005),t(62420);var u=t(10574),h=t(45908);function b(e){let s=e.submission,t=e.setSubmission,[i,l]=(0,n.use
1State)(null),[r,x]=(0,n.useState)(s.social_media&&s.social_media.length?s.social_media:[]),[b,g]=(0,n.useState)(s.filmmaker_bio&&s.filmmaker_bio.length?s.filmmaker_bio:[]),j=e.setActiveStep,[f,v]=(0,n.useState)(Object),_=(0,m.useRouter)(),N="ms_"==s.prefix,[y,w]=(0,n.useState)(!1),S=s.current_step>=2.5&&s.curation_decision,k=s.current_step>7,[C,F]=(0,n.useState)({name:s.name,email:s.email,tentative_release_date:s.tentative_release_date}),E={tagline:220,medium_synopsis:500,fm_bio:250},[P,O]=(0,n.useState)({tagline:E.tagline-(s.tagline?s.tagline.length:0),medium_synopsis:E.medium_synopsis-(s.medium_synopsis?s.medium_synopsis.length:0)}),I=[{value:"website",label:"Website"},{value:"facebook",label:"Facebook"},{value:"twitter",label:"Twitter"},{value:"instagram",label:"Instagram"},{value:"wikipedia",label:"Wikipedia"}];async function T(e,s,t){let a=[...r],i="";i="type"==s?e||"":e.target.value,a[t][s]=i,x(a)}async function D(e,s,t){let a=[...b],i="";i="profile_pic"==s?e.name?e.name:"":e.target.value,a[t][s]=i,g(a)}async function A(e,s){let t=[...r];t[s].deleted=!0,x(t)}async function V(e,s){let t=[...b];t[s].deleted=!0,g(t)}async function R(e,s){F({...C,[s]:e})}async function Z(e,s){let t=e.target.value,a=E[s]-t.length;F({...C,[s]:t}),O({...P,[s]:a})}async function M(){C.social_media=r.filter(e=>!e.deleted),C.filmmaker_bio=b.filter(e=>!e.deleted),C.step=1,C.is_paid=1,C.prefix=s.prefix,C.bundle_id=s.bundle_id,w(!0),v({}),c.Z.post({url:"submissions/save"+(s.id?"/"+s.id:""),data:C}).then(e=>{s.id?(t(e.submission),j(1.5)):_.push("/submit/edit/"+e.submission.unique_id)}).catch(e=>{w(!1),422==e.status_code?(e.message.main="Please fix above errors",v(e.message)):v({main:"Something went wrong! Please try again"})})}return(0,n.useEffect)(()=>{console.log("aaaa"),s.id&&(s.movie_country=s.country,F(s)),s.social_media&&s.social_media.length&&x(s.social_media),s.filmmaker_bio&&s.filmmaker_bio.length&&g(s.filmmaker_bio)},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Basic Info"}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4 mb-[30px]",children:[(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Movie Name ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:s.title,name:"title",placeholder:"Enter movie name",disabled:S,onChange:e=>R(e.target.value,"title")}),f.title&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.title[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Production Year ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:s.production_year,name:"production_year",placeholder:"Enter production year",disabled:S,onChange:e=>R(e.target.value,"production_year")}),f.production_year&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.production_year[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Production Country ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)(h.Z,{isMulti:!0,table:"country_text",defaultOptions:!0,placeholder:"Enter production country",defaultValue:s.country,isDisabled:S,onChange:e=>R(e,"movie_country")}),f.country&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.country[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Language ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)(h.Z,{isMulti:!0,table:"language",defaultOptions:!0,placeholder:"Enter language",defaultValue:s.language,isDisabled:S,onChange:e=>R(e,"language")}),f.language&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.language[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Genre ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)(h.Z,{isMulti:!0,table:"genre",defaultOptions:!0,placeholder:"Enter genre",defaultValue:s.genre,isDisabled:S,onChange:e=>R(e,"genre")}),f.genre&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.genre[0]})]})]}),(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Tagline / Synopsis"}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4 mb-[30px]",children:[(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5
1px]",children:["Tagline (One liner - max 220 characters) ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("textarea",{className:"txt",placeholder:"Enter tagline",name:"tagline",defaultValue:s.tagline,onChange:e=>Z(e,"tagline")}),(0,a.jsxs)("small",{className:P.tagline<0?"text-red-500":"",children:["Remaining : ",P.tagline]}),f.tagline&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.tagline[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Short synopsis (max 500 characters) ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("textarea",{className:"txt",placeholder:"Enter short synopsis",name:"medium_synopsis",defaultValue:s.medium_synopsis,onChange:e=>Z(e,"medium_synopsis")}),(0,a.jsxs)("small",{className:P.medium_synopsis<0?"text-red-500":"",children:["Remaining : ",P.medium_synopsis]}),f.medium_synopsis&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.medium_synopsis[0]})]})]}),N&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Release Info"}),(0,a.jsx)("div",{className:"grid grid-cols-3 gap-4 mb-[30px]",children:(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"mb-[5px]",children:"Tentative Release Date"}),(0,a.jsx)(p(),{selected:C.tentative_release_date,onChange:e=>R(e,"tentative_release_date"),placeholderText:"Enter tentative release date",className:"txt",dateFormat:"MMM dd, yyyy",wrapperClassName:"w-full",name:"release_date",minDate:new Date,disabled:S}),(0,a.jsx)("p",{className:"mt-[5px]",children:"If undecided then leave blank"})]})})]}),(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Contact Info"}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-4 mb-[30px]",children:[(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Your Name ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt",defaultValue:s.name,name:"name",placeholder:"Enter your name",disabled:S,onChange:e=>R(e.target.value,"name")}),f.name&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.name[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Your Email ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt disabled",value:s.email,name:"email",readOnly:!0,placeholder:"Enter your email",disabled:S}),f.email&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.email[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Your Role ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt",name:"role",defaultValue:s.role,placeholder:"Enter your role",disabled:S,onChange:e=>R(e.target.value,"role")}),f.role&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.role[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Your Contact No. ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsxs)("div",{className:"relative w-full",children:[(0,a.jsx)("div",{className:"absolute inset-y-0 left-0 flex items-center pl-[2px] after:content-[''] after:absolute after:right-0 after:top-[10px] after:bottom-[10px] after:w-[1px] after:bg-gray-200",children:(0,a.jsx)(h.Z,{table:"calling_code",defaultOptions:!0,placeholder:"Code",controllClass:"!border-none !border-transparent w-[170px] !shadow-none !h-[40px] !min-h-[40px]",defaultValue:s.phone_code,isDisabled:S,onChange:e=>R(e,"phone_code")})}),(0,a.jsx)("input",{type:"number",className:"txt block !pl-[180px] [appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none",name:"phone",placeholder:"Enter your contact no",defaultValue:s.phone,disabled:S,onChange:e=>R(e.target.value,"phone")})]}),f.phone?(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.phone[0]}):f.phone_code?(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.phone_code[0]}):""]})]}),(0,a.jsx)("p",{className:"mb-[10px]",children:"Social Media"}),(0,a.jsx)("div",{id:"social_media_container",children:r.map((e,s)=>!e.deleted&&(0,a.jsxs)("div",{className:"social_media flex gap-4 mb-[10px]",children:[(0,a.jsx)(h.Z,{type:"select",options:I,placeholder:"Select",className:"flex-1",onChange:e=>T(e,"type",s),defaultValue:e.type,isDisabled:S}),(0,a.jsx)("input",{type:"text",className:"txt flex-1",placeholder:"Enter link",onChange:e=>T(e,"link",s),defaultValue:e.link,disabled:S}),!S&&(0,a.jsx)("button",{type:"button",className:"btn-gray flex-none",onClick:e=>A(e,s),children:(0,a.jsx)(d.G,{icon:o.$aW})})]},s))}),!S&&(0,a.jsxs)("p",{className:"text-blue-500 cursor-pointer hover:underline",onClick:()=>x(e=>[...e,{}]),children:[(0,a.jsx)(d.G,{icon:o.r8p,className:"mr-[10px]"}),"Add Social Media Details"]}
1)]}),(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Filmmaker'Bio"}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[(0,a.jsx)("div",{children:b.map((e,t)=>!e.deleted&&(0,a.jsx)("div",{className:"mb-[10px]",children:(0,a.jsxs)("div",{className:"flex gap-4",children:[(0,a.jsxs)("div",{className:"flex-none",children:[(0,a.jsx)("div",{className:"w-[240px] h-[240px]",children:(0,a.jsx)(u.Z,{onChange:e=>D(e,"profile_pic",t),defaultValue:e.profile_pic?s.filmmaker_bio_url+"/"+e.profile_pic:"",disabled:k,text:"Upload Profile Pic",isRequired:!0})}),f["filmmaker_bio."+t+".profile_pic"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f["filmmaker_bio."+t+".profile_pic"]})]}),(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsxs)("div",{className:"flex gap-4 mb-[20px] items-start",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsxs)("p",{children:["Name ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter Name",onChange:e=>D(e,"name",t),defaultValue:e.name,disabled:k}),f["filmmaker_bio."+t+".name"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f["filmmaker_bio."+t+".name"]})]}),(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsxs)("p",{children:["Role ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter Role",onChange:e=>D(e,"role",t),defaultValue:e.role,disabled:k}),f["filmmaker_bio."+t+".role"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f["filmmaker_bio."+t+".role"]})]}),(0,a.jsxs)("div",{className:"flex-none",children:[(0,a.jsx)("p",{children:"\xa0"}),(0,a.jsx)("button",{type:"button",className:"btn-gray h-[46px]",onClick:e=>V(e,t),disabled:k,children:(0,a.jsx)(d.G,{icon:o.$aW})})]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{children:["Bio ",(0,a.jsx)("small",{children:"(max 250 characters)"})," ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("textarea",{className:"txt",placeholder:"Enter Bio",onChange:e=>D(e,"bio",t),defaultValue:e.bio,disabled:k}),(0,a.jsxs)("p",{className:"text-sm ".concat(E.fm_bio<(e.bio?e.bio.length:0)?"text-red-500":""),children:["Remaining: ",E.fm_bio-(e.bio?e.bio.length:0)]}),f["filmmaker_bio."+t+".bio"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f["filmmaker_bio."+t+".bio"]})]})]})]})},t))}),!k&&(0,a.jsxs)("p",{className:"text-blue-500 cursor-pointer hover:underline",onClick:()=>g(e=>[...e,{}]),children:[(0,a.jsx)(d.G,{icon:o.r8p,className:"mr-[10px]"}),"Add Bio"]})]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:!k&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{className:"btn",disabled:y,onClick:M,children:y?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),f.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:f.main})]})})]})}function g(e){let s=e.activeStep,t=e.currentStep,i=e.setActiveStep,n=e.curationDecision;e.feeWaived;let l=!1!==e.showFestivalStep,r=!1!==e.showTerritoriesStep,c="string"!=typeof e.submissionPrefix||"ms_"===e.submissionPrefix;async function m(e){t>=e&&i(e)}return(0,a.jsxs)("ol",{className:"flex items-start w-full mx-[auto]",children:[(0,a.jsxs)("li",{className:"submit_steps ".concat(1==s?"active":""," ").concat(t>1?"success":""),onClick:()=>m(1),children:[(0,a.jsx)("span",{className:"step_no",children:"1"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Basic Info"})]}),(0,a.jsxs)("li",{className:"submit_steps ".concat(1.5==s?"active":""," ").concat(t>1.5?"success":""),onClick:()=>m(1.5),children:[(0,a.jsx)("span",{className:"step_no",children:(0,a.jsx)(d.G,{icon:o.IyC})}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Movie"})]}),l&&(0,a.jsxs)("li",{className:"submit_steps ".concat(2==s?"active":""," ").concat(t>2?"success":""),onClick:()=>m(2),children:[(0,a.jsx)("span",{className:"step_no",children:"2"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Festivals"})]}),(0,a.jsxs)("li",{className:"submit_steps ".concat(2.5==s?"active":""," ").concat(t>2.5?"success":""," ").concat(-1==["release","recommend"].indexOf(n)?"last":""),onClick:()=>m(2.5),children:[["reject"].indexOf(n)>-1&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"step_no",children:"\uD83D\uDE1E"}),(0,a.jsx)("p",{className:"hidden lg:block",children:c?"Not Approved":"Not Selected"})]}),["release","recommend"].indexOf(n)>-1&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"step_no",children:"\uD83D\uDC4D"}),(0,a.jsxs)("p",{className:"hidden lg:block",children:["✔\xa0",c?"Approved":"Selected"]})]}),-1==["release","recommend","reject"].indexOf(n)&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"step_no",children:(0,a.jsx)(d.G,{icon:o.byT})}),(0,a.jsx)("p",{className:"hidden lg:block",children:["pending","review"].indexOf(n)>-1?"Curation Pending":"Submit for curation"})]})]}),["release","recommend"].indexOf(n)>-1&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("li",{className:"submit_steps ".concat(3==s?"active":""," ").concat(t>3?"success":""),onClick:()=>m(3),children:[(0,a.jsx)("span",{className:"step_no",children:"3"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Credits"})]}),(0,a.jsxs)("li",{className:"submit_steps ".concat(4==s?"active":""," ").concat(t>4?"success":""),onClick:()=>m(4),children:[(0,a.jsx)("span",{className:"step_no",children:"4"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Posters"})]}),(0,a.jsxs)("li",{className:"submit_steps ".concat(5==s?"active":""," ").concat(t>5?"success":""),onClick:()=>m(5),children:[(0,a.jsx)("span",{className:"step_no",children:"5"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Trailer & Bonu
1s Content"})]}),r&&(0,a.jsxs)("li",{className:"submit_steps ".concat(6==s?"active":""," ").concat(t>6?"success":""),onClick:()=>m(6),children:[(0,a.jsx)("span",{className:"step_no",children:"6"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Territories"})]}),(0,a.jsxs)("li",{className:"submit_steps last ".concat(7==s?"active":""," ").concat(t>7?"success":""),onClick:()=>m(7),children:[(0,a.jsx)("span",{className:"step_no",children:"7"}),(0,a.jsx)("p",{className:"hidden lg:block",children:"Legal"})]})]})]})}var j=t(83263),f=t(61406),v=t(3389),_=t(23563);function N(e){let s=e.submission,t=e.setSubmission,i=!1!==e.showTerritoriesStep,[l,r]=(0,n.useState)([]),x=e.setActiveStep,[p,u]=(0,n.useState)(Object);(0,m.useRouter)();let[h,b]=(0,n.useState)(!1),[g,j]=(0,n.useState)(s.trailer_thumbnail),[N,y]=(0,n.useState)(s.trailer_link),[w,S]=(0,n.useState)(s.trailer_subtitle_file?0:1),[k,C]=(0,n.useState)(String);async function F(e,s,t){let a=[...l],i="";i="thumbnail"==s?e.name?e.name:"":e.target.value,a[t][s]=i,r(a)}async function E(e,s){let t=[...l];t[s].deleted=!0,r(t)}async function P(e){let a={};a.step=5,a.prefix=s.prefix,a.trailer_thumbnail=g,a.trailer_link=N,0==w&&(a.trailer_subtitle_file=k),a.bonus_content=l.filter(e=>!e.deleted),b(!0),u({}),c.Z.post({url:"submissions/save"+(s.id?"/"+s.id:""),data:a}).then(e=>{t(e.submission),x(i?6:7)}).catch(e=>{b(!1),422==e.status_code?(e.message.main="Please fix above errors",u(e.message)):u({main:"Something went wrong! Please try again"})})}return(0,n.useEffect)(()=>{s.bonus_content&&s.bonus_content.length&&r(s.bonus_content)},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsxs)("p",{className:"text-blue-500 text-2xl mb-[20px]",children:["Link to trailer (Google Drive/Dropbox/Vimeo/etc.)"," ",(0,a.jsx)("span",{className:"text-sm text-gray-500",children:"(container: mp4, resolution: 1080p, sound: Stereo)"})]}),(0,a.jsx)("div",{className:"mb-[30px]",children:(0,a.jsxs)("div",{className:"mb-[10px] flex gap-4",children:[(0,a.jsx)("div",{className:"flex-none w-[256px] h-[168px]",children:(0,a.jsx)(f.Z,{text:"Add Trailer Thumbnail",onChange:e=>j(e.name),defaultValue:s.trailer_thumbnail?s.trailer_thumbnail_url+"/"+s.trailer_thumbnail:"",disabled:s.current_step>7})}),(0,a.jsxs)("div",{className:"flex-1 content-between",children:[(0,a.jsx)("div",{className:"flex gap-4 items-end mb-[30px]",children:(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)("p",{className:"mb-[10px]",children:"Trailer Url"}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter Trailer Url",onChange:e=>y(e.target.value),defaultValue:s.trailer_link,disabled:s.current_step>7})]})}),(0,a.jsxs)("div",{className:"flex gap-4 items-end mb-[30px]",children:[(0,a.jsx)("p",{className:"mr-[50px]",children:"English subtitles?"}),(0,a.jsxs)("p",{children:[(0,a.jsx)("input",{type:"radio",name:"trailer_subtitle_hardcoded",value:"1",id:"hardcoded_true",defaultChecked:1==w,onChange:e=>S(e.target.value),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:s.current_step>7}),(0,a.jsx)("label",{htmlFor:"hardcoded_true",children:"Hardcoded in video file"})]}),(0,a.jsxs)("p",{children:[(0,a.jsx)("input",{type:"radio",name:"trailer_subtitle_hardcoded",value:"0",id:"hardcoded_false",defaultChecked:0==w,onChange:e=>S(e.target.value),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:s.current_step>7}),(0,a.jsx)("label",{htmlFor:"hardcoded_false",children:"Not hardcoded"})]})]})]})]})}),0==w&&(0,a.jsxs)("div",{className:"mb-[30px]",children:[(0,a.jsxs)("p",{children:["Trailer: English Subtitles ",(0,a.jsx)("i",{children:"(ONLY if not hardcoded in the trailer)"})]}),(0,a.jsx)("p",{className:"text-sm",children:"Subtitles should be in .vtt or .srt format"}),(0,a.jsx)("p",{className:"text-sm mb-[20px]",children:"If you have subtitles in other languages please contact [email protected]"}),(0,a.jsx)("div",{className:"w-[500px]",children:(0,a.jsx)(v.Z,{onChange:e=>C(e.name),defaultValue:s.trailer_subtitle_file?s.trailer_subtitle_file:"",border:!0,accept:{"text/vtt":[".vtt"],"text/srt":[".srt"]},disabled:s.current_step>7})})]}),(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Link to download Bonus Content (if any)"}),(0,a.jsxs)("ul",{className:"list-disc mb-[20px] ml-[30px]",children:[(0,a.jsx)("li",{children:"Please create separate links for separate bonus content. (Example: put 'Behind the Scenes' in one google drive link, and 'Poster Art' in another)"}),(0,a.jsxs)("li",{children:["Please provide appropriate thumbnails for each bonus content"," ",(0,a.jsx)("a",{href:_.Z.s3_file_url+"bonusContentPoster/example-bonus-content-thumbnails.jpg",target:"_blank",className:"text-blue-500 font-bold",children:"(See example)"})]})]}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[l.map((e,t)=>(0,a.jsx)(a.Fragment,{children:!e.deleted&&(0,a.jsxs)("div",{className:"mb-[10px] flex gap-4",children:[(0,a.jsx)("div",{className:"flex-none w-[200px] h-[200px]",children:(0,a.jsx)(f.Z,{text:"Upload Thumbnail",onChange:e=>F(e,"thumbnail",t),defaultValue:e.thumbnail?s.bonus_content_url+"/"+e.thumbnail:"",disabled:s.current_step>7})}),(0,a.jsx)("div",{className:"flex-1 content-between",children:(0,a.jsxs)("div",{className:"flex gap-4 items-end mb-[30px]",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)("p",{className:"mb-[10px]",children:"Bonus Content Title"}),(0,a.jsx)("input",{type:"text",className:"txt mb-[20px]",placeholder:"Enter Bonus Content Title",onCh
1ange:e=>F(e,"title",t),defaultValue:e.title,disabled:s.current_step>7}),(0,a.jsx)("p",{className:"mb-[10px]",children:"Bonus Content Link"}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter Bonus Content Link",onChange:e=>F(e,"link",t),defaultValue:e.link,disabled:s.current_step>7})]}),(0,a.jsx)("div",{className:"flex-none",children:(0,a.jsx)("button",{type:"button",className:"btn-gray h-[46px]",onClick:e=>E(e,t),disabled:s.current_step>7,children:(0,a.jsx)(d.G,{icon:o.$aW})})})]})})]},t)})),s.current_step<=7&&(0,a.jsxs)("span",{className:"text-blue-500 hover:underline cursor-pointer",onClick:()=>r(e=>[...e,{}]),children:[(0,a.jsx)(d.G,{icon:o.r8p,className:"mr-[10px]"})," Add Bonus Content"]})]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:s.current_step<=7&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>x(4),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:h,onClick:P,children:h?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," ","Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),p.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:p.main})]})})]})}var y=t(5943),w=t.n(y),S=t(12200);let k={DropdownIndicator:null},C=e=>({label:e,value:e});function F(e){let s=e.submission,t=e.setSubmission,i=e.setActiveStep,[l,r]=(0,n.useState)(Object),[m,x]=(0,n.useState)(!1),[p,u]=(0,n.use
1State)(s.credit&&s.credit.length?"manual":"imdb"),[h,b]=(0,n.useState)([]),[g,j]=(0,n.useState)(""),[f,v]=(0,n.useState)([]);async function _(e){u(e.target.value)}async function N(e,s,t){let a=[...h],i="";i="name"==s?e:"input_value"==s?e:e.target.value,a[t][s]=i,b(a)}async function y(e){let s=[...h];s[e].deleted=!0,b(s)}(0,n.useEffect)(()=>{s.credit&&s.credit.length?b(s.credit):b([{designation:"Producer",input_value:"",name:[],disabled:!0},{designation:"Director",input_value:"",name:[],disabled:!0,required:!0},{designation:"Writer",input_value:"",name:[],disabled:!0},{designation:"Key Cast",input_value:"",name:[],disabled:!0},{designation:"Production Company",input_value:"",name:[],disabled:!0}])},[]);let F=(e,s)=>{if(h[s].input_value)switch(e.key){case"Enter":case"Tab":case",":let t=[...h][s].name;t.push(C(h[s].input_value)),N(t,"name",s),N("","input_value",s),e.preventDefault()}},E=(e,s)=>{if(h[s].input_value){let t=[...h][s].name;t.push(C(h[s].input_value)),N(t,"name",s),N("","input_value",s),e.preventDefault()}};async function P(e){let a={};a.prefix=s.prefix,a.step=3,a.cast_type=p,"imdb"==p?a.cast_file_url=w()("#cast_file_url").val():"manual"==p&&(a.credit=h.filter(e=>!e.deleted)),x(!0),r({}),c.Z.post({url:"submissions/save/"+s.id,data:a}).then(e=>{t(e.submission),i(4)}).catch(e=>{x(!1),422==e.status_code?(e.message.main="Please fix above errors",r(e.message)):r({main:"Something went wrong! Please try again"})})}return(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[20px]",children:"Credits"}),(0,a.jsxs)("p",{className:"mb-[20px]",children:[(0,a.jsxs)("span",{className:"mr-[20px]",children:[(0,a.jsx)("input",{type:"radio",name:"cast_type",value:"imdb",id:"from_imdb",defaultChecked:"imdb"==p,onChange:_,className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:s.current_step>7}),(0,a.jsx)("label",{htmlFor:"from_imdb",children:"Upload from IMDB"})]}),(0,a.jsxs)("span",{children:[(0,a.jsx)("input",{type:"radio",name:"cast_type",value:"manual",id:"from_manual",defaultChecked:"manual"==p,onChange:_,className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:s.current_step>7}),(0,a.jsx)("label",{htmlFor:"from_manual",children:"Add manually"})]})]}),(0,a.jsxs)("div",{className:"mb-[30px]",children:["imdb"==p&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{children:["Movie's IMDB url ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt",id:"cast_file_url",placeholder:"Enter movie's IMDB url (eg. https://www.imdb.com/title/...)",defaultValue:s.cast_file_url,disabled:s.current_step>7}),l.cast_file_url&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:l.cast_file_url})]}),"manual"==p&&(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-sm text-yellow-700 mb-[20px]",children:"After entering a name, press comma (,) before the next name. Leave blank if there are no names."}),h.map((e,t)=>!e.deleted&&(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-8 mb-[15px]",children:[(0,a.jsx)("div",{children:e.disabled?(0,a.jsxs)("div",{className:"txt !bg-gray-100",children:[e.designation," ",e.required&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}):(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Designation",onChange:e=>N(e,"designation",t),defaultValue:e.designation+(e.required?"*":""),disabled:s.current_step>7})}),(0,a.jsxs)("div",{children:[(0,a.jsx)(S.Z,{onBlur:e=>E(e,t),classNames:{control:e=>"!min-h-[46px] !rounded-lg"},components:k,inputValue:h[t].input_value,isClearable:!0,isMulti:!0,menuIsOpen:!1,onChange:e=>N(e,"name",t),onInputChange:e=>N(e,"input_value",t),onKeyDown:e=>F(e,t),placeholder:"Enter names...",value:h[t].name,isDisabled:s.current_step>7}),l["credit."+t+".name"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:l["credit."+t+".name"]})]}),!e.disabled&&(0,a.jsx)("div",{children:(0,a.jsx)("button",{className:"btn-gray",onClick:()=>y(t),children:(0,a.jsx)(d.G,{icon:o.$aW})})})]}
1,t)),s.current_step<=7&&(0,a.jsxs)("span",{className:"text-blue-500 hover:underline cursor-pointer",onClick:()=>b(e=>[...e,{designation:"",input_value:"",name:[],disabled:!1}]),children:[(0,a.jsx)(d.G,{icon:o.r8p,className:"mr-[10px]"})," Add credit"]})]})]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:s.current_step<=7&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>i(1.5),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:m,onClick:P,children:m?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),l.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:l.main})]})})]})}var E=t(78772),P=t(30054),O=t(95979);function I(e){let s=new Date(e);return s.setHours(0,0,0,0),s}function T(e){if(e instanceof Date&&!Number.isNaN(e.getTime()))return I(e);if("string"!=typeof e)return null;let s=e.match(/^(\d{4})-(\d{2})-(\d{2})/),t=s?new Date(Number(s[1]),Number(s[2])-1,Number(s[3])):new Date(e);return Number.isNaN(t.getTime())?null:I(t)}function D(e){let s=e.getFullYear(),t=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(s,"-").concat(t,"-").concat(a)}function A(e){let s=e.submission,t=e.setSubmission,l=e.setActiveStep,r=!1!==e.showFestivalStep,x="ms_"==s.prefix,[u,h]=(0,n.useState)(Object),[b,g]=(0,n.useState)(!1),j=(0,n.useContext)(E.p).currentDomain,f=P.domain[j],v=function(){let e=I(new Date);return e.setDate(e.getDate()+3),e}(),_=T(s.release_date),N=T(s.tentative_release_date),y=_||(N&&N>=v?N:null),[w,S]=(0,n.useState)(y),[k,C]=(0,n.useState)({prefix:s.prefix,domain:f.display_name,step:2.5,release_date:y?D(y):null}),F=s.fees?s.fees[s.length]||s.fees.default:{},A=!!s.bundle_id&&1==s.open_submissions&&0===s.entries_open&&!s.curation_decision,V=(0,m.useSearchParams)(),R=(0,m.usePathname)(),Z=(0,m.useRouter)(),M=r?2:1.5,B=s.bundle_full_name||s.bundle_name||s.subdomain||"this program";async function G(){g(!0),h({}),c.Z.post({url:"submissions/submitForCuration/"+s.id,data:k}).then(e=>{let a={};Object.assign(a,s,{curation_decision:e.curation_decision}),t(a)}).catch(e=>{g(!1),422==e.status_code?(e.message.main="Please fix above errors",h(e.message)):h({main:"Something went wrong! Please try again"})})}async function L(e){if(x&&(!w||w<v)){h({release_date:["Please select an available release date."]});return}g(!0),h({}),c.Z.post({url:"submissions/save/"+s.id,data:k}).then(e=>{t(e.submission),l(3)}).catch(e=>{g(!1),422==e.status_code?(e.message.main="Please fix above errors",h(e.message)):h({main:"Something went wrong! Please try again"})})}async function U(){if(!F||!F.amount||!F.currency||!F.payment_gateway){h({main:"Submissions are closed for this program."});return}g(!0);let e={},t=parseFloat(F.amount);if("INR"==F.currency&&!s.bundle_id){let e=Math.ceil(.18*t);t+=e}e.payment_info={amount:t,payment_gateway:F.payment_gateway,zero_decimal:F.zero_decimal,submissions_id:s.id,submissions_title:s.title,use_route:!!s.bundle_id,description:"Submission #"+s.id+": "+s.title,currency:F.currency},(0,O.JE)(e,{make_order_attempt_url:"submissions/makeFeeOrderAttempt",make_razorpay_order_url:"submissions/makeFeeRzpOrder",make_stripe_session_url:"submissions/makeFeeStripeSession",make_order_url:"submissions/makeFeePayment"}).then(e=>{G()}).catch(e=>{var s;g(!1),(null==e?void 0:e.error_description)?h({main:e.error_description}):(null==e?void 0:null===(s=e.errors)||void 0===s?void 0:s.errorMessage)?h({main:e.errors.errorMessage}):h({main:"Something went wrong! Please try again."})})}async function z(){(0,O.Sh)(V,{make_order_attempt_url:"submissions/makeFeeOrderAttempt",make_razorpay_order_url:"submissions/makeFeeRzpOrder",make_stripe_session_url:"submissions/makeFeeStripeSession",make_order_url:"submissions/makeFeePayment"}).then(e=>{"success"==e.result&&G();let s=new URLSearchParams(V);s.delete("stripe_result"),s.delete("stripe_session_id"),s.delete("stripe_type");let t="".concat(R,"?").concat(s.toString());Z.replace(t)}).catch(e=>{console.log(e)})}return(0,n.useEffect)(()=>{V.has("stripe_result")&&z()},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:["payment_duration_mismatch"==s.curation_decision&&(0,a.jsxs)("div",{className:"max-w-[600px] m-auto py-[100px]",children:[(0,a.jsx)("p",{className:"text-2xl text-center mb-[20px]",children:"Additional payment required"}),(0,a.jsx)("p",{className:"text-xl text-center mb-[20px]",children:"The duration of your film differs from the duration category selected during payment. We've emailed you with details of the outstanding amount. Your submission will enter curation once the remaining payment has been received."}),(0,a.jsxs)("p",{className:"text-xl text-center",children:["Please ",(0,a.jsx)(i.default,{href:"/contact_us",className:"text-blue-500 underline",children:"contact support"})," if you have any questions."]})]}),"payment_duration_mismatch"!=s.curation_decision&&-1==["release","recommend","reject"].indexOf(s.curation_decision)&&(0,a.jsxs)(a.Fragment,{children:[["pending","review"].indexOf(s.curation_decision)>-1&&(0,a.jsx)("div",{className:"max-w-[500px] m-auto py-[100px]",children:(0,a.jsx)("p",{className:"text-xl text-center",children:"The curation team is reviewing your submission and will revert back with their decision soon."})}),-1==["pending","review"].indexOf(s.curation_decision)&&(0,a.jsx)("div",{className:"max-w-[600px] m-auto py-[50px]",children:x?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"text-xl mb-[10px]",children:"The Curation team will review your submission and notify you of their decision within 15 days via email"}),(0,a.jsxs)("ul",{className:"list-disc ml-[30px] mb-[20px]",children:[(0,a.jsx)("li",{children:"If approved we will send you a release confirmation with further steps."}),(0,a.jsx)("li",{children:"If rejected the submission fee will be refunded back to you."})]}),(0,a.jsx)("p",{className:"text-xs",children:"WatchMyFilm is designed as a self-distribution service, so we do not promote individual films. However, we've created a basic roadmap for film promotion that serves as a starting point, which we will share once your movie is approved."})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("p",{className:"text-xl mb-[10px]",children:["The curation team will review your submission for ",(0,a.jsx)("span",{className:"italic",children:B}
1)," and notify you of the decision by email."]}),(0,a.jsxs)("ul",{className:"list-disc ml-[30px] mb-[20px]",children:[(0,a.jsx)("li",{children:"If selected, we will share the next steps for your submission."}),(0,a.jsx)("li",{children:"If not selected, no further action is required."})]}),(0,a.jsx)("p",{className:"text-xs",children:"This submission does not automatically include a release on MovieSaints or WatchMyFilm."})]})})]}),["reject"].indexOf(s.curation_decision)>-1&&(0,a.jsxs)("div",{className:"max-w-[500px] m-auto py-[100px]",children:[(0,a.jsxs)("p",{className:"text-xl text-center mb-[10px]",children:["Thank you for submitting your film to ",f.display_name,"."]}),(0,a.jsx)("p",{className:"text-xl text-center mb-[10px]",children:"Unfortunately, your submission was not selected."}),x&&(0,a.jsx)("p",{className:"text-xl text-center",children:"We carefully review a large number of submissions and can only select a limited number."})]}),["release","recommend"].indexOf(s.curation_decision)>-1&&(0,a.jsxs)("div",{className:"max-w-[500px] m-auto py-[100px]",children:[(0,a.jsx)("p",{className:"text-2xl text-center",children:"Congratulations!!"}),x?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"text-xl text-center",children:"Your film has been approved for release!"}),(0,a.jsxs)("div",{className:"mt-[30px] text-left",children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Release Date ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)(p(),{selected:w,onChange:e=>{S(e),C({...k,release_date:e?D(e):null}),h({})},placeholderText:"Select release date",className:"txt",dateFormat:"MMM dd, yyyy",wrapperClassName:"w-full",name:"release_date",minDate:v}),u.release_date&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:u.release_date[0]})]})]}):(0,a.jsxs)("p",{className:"text-xl text-center",children:["Your film has been selected for ",(0,a.jsx)("span",{className:"italic",children:B}),"!"]}),(0,a.jsxs)("ul",{children:[(0,a.jsx)("li",{className:"pt-[10px]",children:x?"Please fill out the rest of the information to prepare your film for release.":"Please fill out the rest of the information to complete your submission."}),x&&(0,a.jsxs)("li",{className:"pt-[10px]",children:["You can find the"," ",(0,a.jsxs)("a",{href:f.logo_public_gdrive,target:"_blank",className:"text-blue-500 hover:underline",children:[f.display_name," Logo here"]}),".",(0,a.jsx)("ul",{className:"list-[circle] mt-[10px] pl-[30px]",children:(0,a.jsxs)("small",{children:[(0,a.jsx)("li",{children:"Feel free to add the logo to the trailer/posters/images or any other promotional materials."}),(0,a.jsx)("li",{children:"Note: Please use 'Watch Now' or 'Available Now' only (Please DO NOT USE streaming or playing)"})]})})]})]})]}),!s.curation_decision&&(0,a.jsxs)("div",{className:"border-t px-[25px] py-[50px] text-center",children:[A?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"mb-[10px]",children:"Submissions are closed for this program."}),(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>l(M),children:"BACK TO PREVIOUS"})]}):(0,a.jsxs)(a.Fragment,{children:[1==s.fee_waived?(0,a.jsxs)("p",{className:"mb-[10px]",children:["Your submission fee of ",(0,a.jsxs)("b",{children:[F.currency," ",F.amount]})," has been waived."]}):(0,a.jsxs)("p",{className:"mb-[10px]",children:["Your submission fee is ",(0,a.jsxs)("b",{children:[F.currency," ",F.amount]}),"INR"!=F.currency||s.bundle_id?(0,a.jsx)(a.Fragment,{}):(0,a.jsxs)("span",{className:"text-xs text-gray-500",children:["\xa0(+",F.currency," ",Math.ceil(.18*parseFloat(F.amount))," GST)"]})]}),(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>l(M),children:"BACK TO PREVIOUS"}),1==s.fee_waived?(0,a.jsx)("button",{type:"submit",className:"btn",disabled:b,onClick:G,children:b?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"SUBMIT FOR CURATION"})}):(0,a.jsx)("button",{type:"submit",className:"btn",disabled:b,onClick:U,children:b?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"PAY & SUBMIT FOR CURATION"})})]}),u.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:u.main})]}),["release","recommend"].indexOf(s.curation_decision)>
1-1&&s.current_step<=7&&(0,a.jsxs)("div",{className:"border-t px-[25px] py-[50px] text-center",children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>l(M),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:b,onClick:L,children:b?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"NEXT"})}),u.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:u.main})]})]})}function V(e){let s=e.submission,t=e.setSubmission,[i,l]=(0,n.useState)([]),r=e.setActiveStep,[x,p]=(0,n.useState)(Object);(0,m.useRouter)();let[u,h]=(0,n.useState)(!1),[b,g]=(0,n.useState)({step:2,prefix:s.prefix});async function j(e,s,t){let a=[...i],n="";n="thumbnail"==s?e.name?e.name:"":e.target.value,a[t][s]=n,l(a)}async function v(e,s){let t=[...i];t[s].deleted=!0,l(t)}async function _(e){b.festival=i.filter(e=>!e.deleted),h(!0),p({}),c.Z.post({url:"submissions/save"+(s.id?"/"+s.id:""),data:b}).then(e=>{t(e.submission),r(2.5)}).catch(e=>{h(!1),422==e.status_code?(e.message.main="Please fix above errors",p(e.message)):p({main:"Something went wrong! Please try again"})})}return(0,n.useEffect)(()=>{s.festival&&s.festival.length&&l(s.festival)},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Film Festival Laurels"}),(0,a.jsx)("p",{className:"font-bold mb-[20px]",children:"Note: We strongly advice you to fill this section carefully as Film Festivals will increase the chance of your film being approved for release."}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[i.map((e,t)=>!e.deleted&&(0,a.jsxs)("div",{className:"mb-[10px] flex gap-4",children:[(0,a.jsx)("div",{className:"flex-none w-[150px] h-[150px]",children:(0,a.jsx)(f.Z,{text:"Upload Festival Laurel Image",smallText:"(Optional)",onChange:e=>j(e,"thumbnail",t),defaultValue:e.thumbnail?s.festival_url+"/"+e.thumbnail:"",disabled:s.current_step>=2.5&&s.curation_decision})}),(0,a.jsxs)("div",{className:"flex-1 content-between",children:[(0,a.jsxs)("div",{className:"flex gap-4 mb-[30px]",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)("p",{className:"mb-[10px]",children:"Festival Name"}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter Festival Name",onChange:e=>j(e,"laurel",t),defaultValue:e.laurel,disabled:s.current_step>=2.5&&s.curation_decision}),x["festival."+t+".laurel"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:x["festival."+t+".laurel"]})]}),(0,a.jsx)("div",{className:"flex-none pt-[32px]",children:(0,a.jsx)("button",{type:"button",className:"btn-gray h-[46px]",onClick:e=>v(e,t),disabled:s.current_step>=2.5&&s.curation_decision,children:(0,a.jsx)(d.G,{icon:o.$aW})})})]}),(0,a.jsx)("p",{className:"text-gray-500",children:(0,a.jsx)("small",{children:"Image should be black on transparent/white background"})})]})]},t)),!(s.current_step>=2.5&&s.curation_decision)&&(0,a.jsxs)("span",{className:"text-blue-500 hover:underline cursor-pointer",onClick:()=>l(e=>[...e,{}]),children:[(0,a.jsx)(d.G,{icon:o.r8p,className:"mr-[10px]"})," Add festival"]})]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:s.current_step<=7&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>r(1.5),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:u,onClick:_,children:u?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),x.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:x.main})]})})]})}function R(e){var s,t;let i=e.submission,l=e.setSubmission,r=!1!==e.showTerritoriesStep,x="ms_"==i.prefix,[p,u]=(0,n.use
1State)(i.agreement_particular?i.agreement_particular:{type:"Production company"}),[h,b]=(0,n.useState)(Object),g=e.setActiveStep,[j,f]=(0,n.useState)(Object);(0,m.useRouter)();let[v,_]=(0,n.useState)(!1),N=(0,n.useContext)(E.p).currentDomain,y=P.domain[N],w=(s=F(i.bundle_from_date),t=F(i.bundle_to_date),s&&t?" from ".concat(s," to ").concat(t):s?" starting ".concat(s):t?" until ".concat(t):"");async function S(e,s){"type"==s?(u({type:e.target.value}),f({})):u({...p,[s]:e.target.value})}async function k(e,s){b({...h,[s]:e.target.checked})}async function C(e){let s={};s.step=7,s.prefix=i.prefix,s.agreement_particular=p,s.domain=y.display_name,h.accept1&&h.accept2&&h.accept3&&h.accept4?(_(!0),f({}),c.Z.post({url:"submissions/save"+(i.id?"/"+i.id:""),data:s}).then(e=>{l(e.submission),g(8)}).catch(e=>{_(!1),422==e.status_code?(e.message.main="Please fix above errors",f(e.message)):f({main:"Something went wrong! Please try again"})})):f({main:"Please accept all above"})}function F(e){if(!e)return"";let s=String(e).split(" ")[0].split("-");if(3!==s.length)return"";let t=parseInt(s[0],10),a=parseInt(s[1],10),i=parseInt(s[2],10);return t&&a&&i?new Date(Date.UTC(t,a-1,i)).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric",timeZone:"UTC"}):""}return(0,n.useEffect)(()=>{i.current_step>7&&b({accept1:1,accept2:1,accept3:1,accept4:1})},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[x&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[20px]",children:"Rights Holder Details"}),(0,a.jsx)("div",{className:"mb-[30px]",children:(0,a.jsxs)("div",{className:"flex gap-4 items-end mb-[30px]",children:[(0,a.jsxs)("p",{children:[(0,a.jsx)("input",{type:"radio",name:"type",value:"Production company",id:"production_company",defaultChecked:"Production company"==p.type,onChange:e=>S(e,"type"),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:i.current_step>7}),(0,a.jsx)("label",{htmlFor:"production_company",children:"Production Company"})]}),(0,a.jsxs)("p",{children:[(0,a.jsx)("input",{type:"radio",name:"type",value:"Individual",id:"individual",defaultChecked:"Individual"==p.type,onChange:e=>S(e,"type"),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:i.current_step>7}),(0,a.jsx)("label",{htmlFor:"individual",children:"Individual"})]})]})})]}),x&&"Production company"==p.type&&(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-8 mb-[30px]",children:[(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Name of the company ","ms_"==i.prefix&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:p.company,name:"company",placeholder:"Enter name of the company",onChange:e=>S(e,"company"),disabled:i.current_step>7}),j["agreement_particular.company"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j["agreement_particular.company"][0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Address ","ms_"==i.prefix&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:p.address,name:"address",placeholder:"Enter address",onChange:e=>S(e,"address"),disabled:i.current_step>7}),j["agreement_particular.address"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j["agreement_particular.address"][0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Authorized Signatory ","ms_"==i.prefix&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:p.auth_signatory,name:"auth_signatory",placeholder:"Enter name of authorized signatory",onChange:e=>S(e,"auth_signatory"),disabled:i.current_step>7}),j["agreement_particular.auth_signatory"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j["agreement_particular.auth_signatory"][0]})]})]}),x&&"Individual"==p.type&&(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-8 mb-[30px]",children:[(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5
1px]",children:["Your full name ","ms_"==i.prefix&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:p.name,name:"name",placeholder:"Enter your name",onChange:e=>S(e,"name"),disabled:i.current_step>7}),j["agreement_particular.name"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j["agreement_particular.name"][0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Your address ","ms_"==i.prefix&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:p.address,name:"address",placeholder:"Enter address",onChange:e=>S(e,"address"),disabled:i.current_step>7}),j["agreement_particular.address"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j["agreement_particular.address"][0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Your age ","ms_"==i.prefix&&(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{className:"txt",defaultValue:p.age,name:"age",placeholder:"Enter age",onChange:e=>S(e,"age"),disabled:i.current_step>7}),j["agreement_particular.age"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j["agreement_particular.age"][0]})]})]}),(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[20px]",children:"Legal"}),(0,a.jsx)("p",{className:"text-sm",children:"Please read and accept the following before submitting"}),(0,a.jsxs)("div",{className:"mb-[30px] w-[80%]",children:[(0,a.jsxs)("div",{className:"flex gap-4 items-center",children:[(0,a.jsx)("div",{className:"flex-1 p-[20px]"}),(0,a.jsx)("div",{className:"flex-none w-[150px] text-center",children:(0,a.jsx)("b",{children:"Yes, I agree"})})]}),(0,a.jsxs)("div",{className:"flex gap-4 items-center mb-[20px]",children:[(0,a.jsx)("div",{className:"flex-1 p-[20px] bg-gray-200 rounded",children:(0,a.jsx)("p",{children:"You assure that you own all copyright associated with the film and associated materials submitted via this form."})}),(0,a.jsx)("div",{className:"flex-none w-[150px] text-center",children:(0,a.jsx)("input",{type:"checkbox",value:"1",defaultChecked:i.current_step>7,onChange:e=>k(e,"accept1"),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:i.current_step>7})})]}),(0,a.jsxs)("div",{className:"flex gap-4 items-center mb-[20px]",children:[(0,a.jsx)("div",{className:"flex-1 p-[20px] bg-gray-200 rounded",children:(0,a.jsxs)("p",{children:["You are giving ",y.display_name," the right to host/exhibit the content submitted via this form on ",i.subdomain,w,"."]})}),(0,a.jsx)("div",{className:"flex-none w-[150px] text-center",children:(0,a.jsx)("input",{type:"checkbox",value:"1",defaultChecked:i.current_step>7,onChange:e=>k(e,"accept2"),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:i.current_step>7})})]}),(0,a.jsxs)("div",{className:"flex gap-4 items-center mb-[20px]",children:[(0,a.jsx)("div",{className:"flex-1 p-[20px] bg-gray-200 rounded",children:(0,a.jsxs)("p",{children:["The views expressed in the submitted content are yours and yours only. ",y.display_name," can not be held liable for them."]})}),(0,a.jsx)("div",{className:"flex-none w-[150px] text-center",children:(0,a.jsx)("input",{type:"checkbox",value:"1",defaultChecked:i.current_step>7,onChange:e=>k(e,"accept3"),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:i.current_step>7})})]}),(0,a.jsxs)("div",{className:"flex gap-4 items-center mb-[20px]",children:[(0,a.jsx)("div",{className:"flex-1 p-[20px] bg-gray-200 rounded",children:(0,a.jsxs)("p",{children:[y.display_name," reserves the right to stop exhibiting any of the content at any time in the future. The grounds for such action will be communicated to you via email."]})}),(0,a.jsx)("div",{className:"flex-none w-[150px] text-center",children:(0,a.jsx)("input",{type:"checkbox",value:"1",defaultChecked:i.current_step>7,onChange:e=>k(e,"accept4"),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:i.current_step>7})})]})]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:i.current_step<=7&&
1(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>g(r?6:5),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:v,onClick:C,children:v?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"}),"Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),j.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:j.main})]})})]})}var Z=t(53666);function M(e){let{email:s}=e;return(0,a.jsx)("span",{className:"inline-flex items-center rounded-full border border-slate-200 bg-slate-100 px-3 py-1 text-xs font-medium text-slate-700 break-all",children:s})}function B(e){let s=e.submission,t=e.setSubmission,i=e.setActiveStep,l=!1!==e.showFestivalStep,r="ms_"==s.prefix,[m,x]=(0,n.useState)({email:s.subscription_email?s.subscription_email:s.email}),[p,u]=(0,n.useState)("secured_screener"),[b,g]=(0,n.useState)(Object),[j,f]=(0,n.useState)(!1),[_,N]=(0,n.useState)(!1),[y,S]=(0,n.useState)(""),[k,C]=(0,n.useState)(),[F,E]=(0,n.useState)([{}
1]),[P,O]=(0,n.useState)(!1),[I,T]=(0,n.useState)(!1),D=s.current_step>=2.5&&s.curation_decision,A=s.current_step>7,[V,R]=(0,n.useState)({movie_subtitle_hardcoded:1}),B=Array.from(new Set([s.contact_email,"[email protected]"].filter(Boolean))),G=Array.from({length:6},(e,s)=>({value:s,label:s.toString().padStart(2,"0")})),L=Array.from({length:60},(e,s)=>({value:s,label:s.toString().padStart(2,"0")})),U=Array.from({length:60},(e,s)=>({value:s,label:s.toString().padStart(2,"0")}));function z(e){c.Z.post({url:"securedScreener/getSubscriptionByEmail",data:{subscription_email:e}}).then(e=>{x(e.subscription),f(!1)})}async function W(e,t,a){let i=[...F],n="";if("iso"==t){n=e?e.value:"";let t=s.iso_language?s.iso_language:{};t[e.value]=e,R({...V,iso_language:t})}else n="file"==t?e.name?e.name:"":e.target.value;i[a][t]=n,E(i)}async function Y(e,s){"ss_video_id"==s?R({...V,[s]:e.value,ss_video_title:e.label}):R({...V,[s]:e})}async function J(e,s){let t=[...F];t[s].deleted=!0,E(t)}async function $(e){let s=e.target.value;s.indexOf("google.com")>-1?O(!0):O(!1),R({...V,movie_link:s})}async function q(e){C(e.target.value),R({...V,movie_subtitle_hardcoded:e.target.value})}async function K(e,s){let t={...V};t[s]=e,("ctr_hh"==s||"ctr_mm"==s)&&("ctr_hh"==s&&void 0==V.ctr_mm&&(t.ctr_mm=0),void 0==V.ctr_ss&&(t.ctr_ss=0)),R(t)}async function H(e){let a=!1,n="";if("download_link"==p?(V.movie_subtitle=F,delete V.ss_video_id,void 0!==k?void 0!=V.ctr_hh&&0!=V.ctr_hh||void 0!=V.ctr_mm&&0!=V.ctr_mm||void 0!=V.ctr_ss&&0!=V.ctr_ss?P&&V.access_given?a=!0:P?n="google_drive":a=!0:n="credits_roll_timestamp":n="subtitle_type"):(delete V.movie_link,delete V.movie_subtitle,delete V.movie_pwd,a=!0),g({}),a)T(!0),V.step=1.5,V.prefix=s.prefix,V.submit_type=p,c.Z.post({url:"submissions/save/"+s.id,data:V}).then(e=>{t(e.submission),i(l?2:e.submission.open_submissions?2.5:3)}).catch(e=>{T(!1),422==e.status_code?(e.message.main="Please fix above errors",g(e.message)):g({main:"Something went wrong! Please try again"})});else{let e={};switch(n){case"google_drive":e={main:"Please fix above errors",drive_access:"Please give access for google drive link."};break;case"credits_roll_timestamp":e={ctr:"Credits can not start at the beginning of the movie",main:"Please fix above errors"};break;case"subtitle_type":e={subtitle_type:"Please select type of video file",main:"Please fix above errors"};break;default:e={main:"Something went wrong! Please try again"}}g(e)}}return(0,n.useEffect)(()=>{console.log(s),s.id&&R(s),m.email&&!m.id&&z(m.email),s.movie_link&&!s.ss_video_id&&(u("download_link"),C(s.movie_subtitle_hardcoded),s.movie_subtitle&&E(s.movie_subtitle),s.movie_link.indexOf("google.com")>-1&&(O(!0),s.access_given=!0))},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsxs)("div",{className:"mb-[50px]",children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Movie Duration"}),(0,a.jsxs)("div",{className:"w-[30%]",children:[(0,a.jsxs)("p",{className:"mb-[5px]",children:["Movie Duration ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("p",{className:"text-xs",children:"Submission fee will be calculated based on duration at the end."}),r&&(0,a.jsx)("p",{className:"text-xs mb-[10px]",children:"(Refunded if movie is not approved for release)."}),(0,a.jsx)(h.Z,{type:"select",options:[{value:"< 10 mins",label:"< 10 mins"},{value:"10 - 20 mins",label:"10 - 20 mins"},{value:"20 - 40 mins",label:"20 - 40 mins"},{value:"40 - 60 mins",label:"40 - 60 mins"},{value:"> 60 mins",label:"> 60 mins"}],placeholder:"Select Duration",controllClass:"max-w-[]",onChange:e=>Y(e,"length"),defaultValue:s.length,isDisabled:D}),b.length&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.length[0]})]})]}),(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:"Submit Movie"}),(0,a.jsx)("p",{className:"mb-[20px]",children:(0,a.jsx)("small",{children:"(container: mp4, resolution: 1080p, sound: stereo)"})}),(0,a.jsx)("p",{className:"font-bold mb-[20px]",children:"Movies without english subtitles will not be considered"}),(0,a.jsxs)("div",{children:[(0,a.jsx)("button",{type:"button",className:"font-bold px-[25px] py-[15px] rounded-t-lg mr-[25px] ".concat("secured_screener"==p?"bg-blue-100":"bg-gray-200"),onClick:()=>{u("secured_screener")},disabled:D,children:"Via Secured Screener"}),(0,a.jsx)("button",{type:"button",className:"font-bold px-[25px] py-[15px] rounded-t-lg mr-[25px] ".concat("download_link"==p?"bg-blue-100":"bg-gray-200"),onClick:()=>{u("download_link")},disabled:D,children:"Via Downloadable Link"})]}),(0,a.jsxs)("div",{className:"mb-[30px]",children:["secured_screener"==p&&(0,a.jsxs)("div",{className:"bg-blue-100 rounded-b-lg p-[25px]",children:[(0,a.jsxs)("div",{className:"grid grid-cols-2 gap-8 mb-[30px]",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"mb-[10px]",children:"Your SecuredScreener Email"}),!j&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"font-bold mb-[10px]",children:m.email}),!D&&(0,a.jsx)("span",{onClick:()=>void f(!0),className:"text-blue-500 hover:underline cursor-pointer",children:"Change"})]}),j&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("input",{type:"text",className:"txt mb-[10px]",id:"subscription_email",placeholder:"Enter SecuredScreener Account Email",defaultValue:m.email}),y&&(0,a.jsx)("p",{className:"text-red-500",children:y}),(0,a.jsxs)("button",{type:"button",className:"btn",onClick:()=>void z(w()("#subscription_email").val()),children:[!_&&(0,a.jsx)("span",{children:"DONE"}),_&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:Z.IJ,spin:!0,className:"mr-[10px]"})," ",(0,a.jsx)("span",{children:"Processing"})]})]})]})]}),(0,a.jsx)("div",{children:m.id&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"text-lg mb-[10px]",children:"Subscription Details"}),(0,a.jsxs)("p",{children:["Plan : ",(0,a.jsx)("span",{className:"font-semibold",children:"TRIAL"==m.currency?"FREE TRIAL":m.name})]}
1),(0,a.jsxs)("p",{children:["Videos : ",(0,a.jsx)("span",{className:"font-semibold",children:"Unlimited"})]})]})})]}),!m.id&&!j&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[10px]",children:["No subscription found with this email, please join free trial to upload ",(0,a.jsx)("i",{children:(0,a.jsx)("u",{children:"unlimited"})})," videos."]}),(0,a.jsx)("a",{href:"https://www.securedscreener.com/join",target:"_blank",children:(0,a.jsx)("button",{className:"btn",children:(0,a.jsx)("b",{children:"JOIN FREE TRIAL"})})})]}),m.id&&!j&&(0,a.jsxs)("div",{children:[(0,a.jsxs)("p",{className:"mb-[10px]",children:["Choose video from SecuredScreener ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)(h.Z,{table:"ss_video",loadParams:{with_date:1,uploaded:1,ss_email:m.email},defaultOptions:!0,placeholder:"Choose video from SecuredScreener",defaultValue:s.ss_video_id?{value:s.ss_video_id,label:s.ss_video_title}:"",isDisabled:D,returnType:"object",onChange:e=>Y(e,"ss_video_id")}),b.ss_video_id&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.ss_video_id[0]}),(0,a.jsx)("p",{className:"mt-[20px]",children:(0,a.jsxs)("b",{children:["If you are submitting a ",(0,a.jsx)("i",{children:"new video"})," - ",(0,a.jsx)("a",{href:"https://www.securedscreener.com/video/create",target:"_blank",className:"text-blue-500 hover:underline",children:"upload it to SecuredScreener"})]})})]})]}),"download_link"==p&&(0,a.jsxs)("div",{className:"bg-blue-100 rounded-b-lg p-[25px]",children:[(0,a.jsxs)("div",{className:"text-red-500 p-[25px] border-2 border-red-500 bg-red-100 font-bold mb-[20px]",children:[(0,a.jsx)("p",{children:"90% of films are pirated from unsecured links and passwords."}),(0,a.jsxs)("p",{children:["We highly recommend that you use the free tier of our ",(0,a.jsx)("a",{href:"https://www.securedscreener.com/join",target:"_blank",className:"text-blue-500 hover:underline",children:"SecuredScreener"})," service"]})]}),(0,a.jsxs)("div",{className:"mt-[30px] mb-[30px]",children:[(0,a.jsxs)("div",{className:"mb-[10px]",children:[(0,a.jsx)("input",{type:"radio",name:"movie_subtitle_hardcoded",value:"0",id:"subtitle_not_hardcoded",defaultChecked:0==k,onChange:q,className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:D}),(0,a.jsxs)("label",{htmlFor:"subtitle_not_hardcoded",children:[(0,a.jsx)("b",{children:"(Recommended)"})," Video file without subtitles + separate subtitle files"]})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("input",{type:"radio",name:"movie_subtitle_hardcoded",value:"1",id:"subtitle_hardcoded",defaultChecked:1==k,onChange:q,className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:D}),(0,a.jsx)("label",{htmlFor:"subtitle_hardcoded",children:"Video file with English subtitles burned in"})]}),b.subtitle_type&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.subtitle_type})]}),(0,a.jsxs)("div",{className:"grid grid-cols-3 gap-4",children:[(0,a.jsxs)("div",{className:"col-span-2",children:[(0,a.jsxs)("p",{className:"mb-[10px]",children:["Movie Url ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter movie link",defaultValue:s.movie_link,name:"movie_link",onChange:$,disabled:D}),b.movie_link&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.movie_link[0]})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"mb-[10px]",children:"Password (if any)"}),(0,a.jsx)("input",{type:"text",className:"txt",placeholder:"Enter password",defaultValue:s.movie_pwd,name:"movie_pwd",disabled:D,onChange:e=>Y(e.target.value,"movie_pwd")})]})]}),B.length>0&&(0,a.jsxs)("p",{className:"text-sm text-slate-600",children:["For Google Drive links please give access to"," ",B.map((e,s)=>(0,a.jsxs)("span",{children:[(0,a.jsx)(M,{email:e}),s<B.length-1&&(0,a.jsx)("span",{className:"mx-2",children:"and"})]},e))]}),P&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("p",{className:"mt-[10px]",children:[(0,a.jsx)("input",{type:"checkbox",id:"access_given",name:"access_given",defaultChecked:s.access_given,className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",onChange:e=>Y(e.target.checked,"access_given"),disabled:D}),(0,a.jsxs)("label",{htmlFor:"access_given",children:["I have given access to"," ",B.map((e,s)=>(0,a.jsxs)("span",{children:[(0,a.jsx)(M,{email:e}),s<B.length-1&&(0,a.jsx)("span",{className:"mx-2",children:"and"})]},e))]})]}),b.drive_access&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.drive_access})]}),0==k&&(0,a.jsxs)("div",{className:"mt-[30px]",children:[(0,a.jsx)("p",{children:"Subtitles"}),(0,a.jsx)("div",{children:F.map((e,t)=>!e.deleted&&(0,a.jsxs)("div",{className:"social_media flex gap-4 mb-[10px]",children:[(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)(h.Z,{table:"language_subtitle",defaultOptions:!0,placeholder:"Select Language",defaultValue:e.iso&&s.iso_language?s.iso_language[e.iso]:"",isDisabled:D,returnType:"object",onChange:e=>W(e,"iso",t)}),b["movie_subtitle."+t+".iso"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b["movie_subtitle."+t+".iso"][0]})]}),(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)(v.Z,{onChange:e=>W(e,"file",t),defaultValue:e.file,accept:{"text/vtt":[".vtt"],"text/srt":[".srt"]},disabled:D}),b["movie_subtitle."+t+".file"]&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b["movie_subtitle."+t+".file"][0]})]}),F.length>1&&(0,a.jsx)("button",{type:"button",className:"btn-gray flex-none",onClick:e=>J(e,t),disabled:D,children:(0,a.jsx)(d.G,{icon:o.$aW})})]},t))}),!D&&(0,a.jsxs)("span",{className:"text-blue-500 hover:underline cursor-pointer",onClick:()=>E(e=>[...e,{}]),children:[(0,a.jsx)(d.G,{icon:o.r8p,className:"mr-[10px]"}
1)," Add subtitle"]})]}),(0,a.jsxs)("div",{className:"mt-[30px]",children:[(0,a.jsxs)("p",{className:"mb-[10px]",children:["Credits Roll Timestamp ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("p",{className:"mb-[20px] text-sm italic",children:"Please provide the timestamp at which the credits begin to roll in the film. This will help us ensure the correct timing for the end of the movie."}),(0,a.jsxs)("div",{className:"lg:flex lg:gap-16 items-center mb-[10px]",children:[(0,a.jsxs)("div",{className:"lg:flex lg:gap-4 lg:items-center",children:[(0,a.jsx)(h.Z,{type:"select",options:G,placeholder:"hh",controllClass:"min-w-[130px] max-w-[] mb-[10px] lg:mb-0",onChange:e=>K(e,"ctr_hh"),value:void 0!=V.ctr_hh?{value:V.ctr_hh,label:V.ctr_hh.toString().padStart(2,"0")}:""}),(0,a.jsx)("span",{className:"hidden lg:block",children:":"}),(0,a.jsx)(h.Z,{type:"select",options:L,placeholder:"mm",controllClass:"min-w-[130px] max-w-[] mb-[10px] lg:mb-0",onChange:e=>K(e,"ctr_mm"),value:void 0!=V.ctr_mm?{value:V.ctr_mm,label:V.ctr_mm.toString().padStart(2,"0")}:""}),(0,a.jsx)("span",{className:"hidden lg:block",children:":"}),(0,a.jsx)(h.Z,{type:"select",options:U,placeholder:"ss",controllClass:"min-w-[130px] max-w-[] mb-[10px] lg:mb-0",onChange:e=>K(e,"ctr_ss"),value:void 0!=V.ctr_ss?{value:V.ctr_ss,label:V.ctr_ss.toString().padStart(2,"0")}:""})]}),(0,a.jsx)("div",{children:(void 0!=V.ctr_hh||void 0!=V.ctr_mm||void 0!=V.ctr_ss)&&(0,a.jsxs)("span",{className:"space-x-2 lg:space-x-4",children:[void 0!=V.ctr_hh&&(0,a.jsxs)("span",{children:[(0,a.jsx)("b",{children:V.ctr_hh.toString().padStart(2,"0")})," hours"]}),void 0!=V.ctr_mm&&(0,a.jsxs)("span",{children:[(0,a.jsx)("b",{children:V.ctr_mm.toString().padStart(2,"0")})," minutes"]}),void 0!=V.ctr_ss&&(0,a.jsxs)("span",{children:[(0,a.jsx)("b",{children:V.ctr_ss.toString().padStart(2,"0")})," seconds"]})]})})]}),b.ctr?(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.ctr}):""]})]}),!1]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:!A&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>i(1),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{className:"btn",disabled:I,onClick:H,children:I?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:Z.IJ,spin:!0,className:"mr-[10px]"})," Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),b.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:b.main})]})})]})}var G=t(69491);function L(e){let s=e.submission,t=e.setSubmission,i=e.setActiveStep,[l,r]=(0,n.useState)(Object);(0,m.useRouter)();let[x,p]=(0,n.useState)(!1),[h,b]=(0,n.useState)([]),[g,j]=(0,n.useState)([]);async function f(e){let s=e.url?e.url:G.Z.getLocalStorage("uploads/"+e.name);b(t=>[...t,{name:e.name,url:s}])}async function v(e){let s=e.url?e.url:G.Z.getLocalStorage("uploads/"+e.name);j(t=>[...t,{name:e.name,url:s}])}async function N(e,s){if("horizontal"==s){let s=[...h];s.splice(e,1),b(s)}else if("vertical"==s){let s=[...g];s.splice(e,1),j(s)}}async function y(e){let a={};a.step=4,a.prefix=s.prefix,a.poster=h.map(e=>e.name),a.vposter=g.map(e=>e.name),p(!0),r({}),c.Z.post({url:"submissions/save"+(s.id?"/"+s.id:""),data:a}).then(e=>{t(e.submission),i(5)}).catch(e=>{p(!1),422==e.status_code?(e.message.main="Please fix above errors",r(e.message)):r({main:"Something went wrong! Please try again"})})}return(0,n.useEffect)(()=>{},[]),(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsxs)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:["Horizontal Poster or Images from the movie ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})," ",(0,a.jsx)("span",{className:"text-sm text-gray-500",children:"(aspect ratio: 16:9, max file size: 5MB)"})]}),(0,a.jsxs)("p",{className:"mb-[20px] text-gray-500",children:["This will be used as the main background for your movie page, so please keep the following in mind"," ",(0,a.jsx)("a",{href:_.Z.s3_file_url+"landscape_poster/example-background+image.jpg",className:"text-blue-500",target:"_blank",children:(0,a.jsx)("b",{children:"(see example)"})})]}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[s.file.horizontal_poster.length>0&&(0,a.jsx)(a.Fragment,{children:s.file.horizontal_poster.map((e,s)=>(0,a.jsx)("div",{className:"w-[256px] h-[144px] m-[5px] inline-block align-top relative group",children:(0,a.jsx)("img",{src:_.Z.s3_url+e,alt:"Uploaded horizontal poster",className:"h-full w-full rounded-lg"})},s))}),h.map((e,s)=>(0,a.jsxs)("div",{className:"w-[256px] h-[144px] m-[5px] inline-block align-top relative group",children:[(0,a.jsx)("img",{src:e.url,alt:"New horizontal poster preview",className:"h-full w-full rounded-lg"}),(0,a.jsx)("div",{className:"absolute hidden group-hover:block w-[30px] h-[30px] top-[10px] right-[10px] bg-red-600 rounded-full text-white cursor-pointer leading-[30px] text-center",onClick:()=>N(s,"horizontal"),children:(0,a.jsx)(d.G,{icon:o.NBC})})]},s)),(0,a.jsx)("div",{className:"w-[256px] h-[144px] m-[5px] inline-block align-top",children:(0,a.jsx)(u.Z,{type:"horizontal",multiple:!0,preview:!1,onChange:e=>f(e),disabled:s.current_step>7})})]}),(0,a.jsxs)("p",{className:"text-blue-500 text-2xl mb-[10px]",children:["Vertical Posters ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})," ",(0,a.jsx)("span",{className:"text-sm text-gray-500",children:"(aspect ratio: 27:40, max file size: 1MB)"})]}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[s.file.vertical_poster.length>0&&(0,a.jsx)(a.Fragment,{children:s.file.vertical_poster.map((e,s)=>(0,a.jsx)("div",{className:"w-[148px] h-[220px] m-[5px] inline-block align-top relative group",children:(0,a.jsx)("img",{src:_.Z.s3_url+e,alt:"Uploaded vertical poster",className:"h-full w-full rounded-lg"})},s))}),g.map((e,s)=>(0,a.jsxs)("div",{className:"w-[148px] h-[220px] m-[5px] inline-block align-top relative group",children:[(0,a.jsx)("img",{src:e.url,alt:"New vertical poster preview",className:"h-full w-full rounded-lg"}),(0,a.jsx)("div",{className:"absolute hidden group-hover:block w-[30px] h-[30px] top-[10px] right-[10px] bg-red-600 rounded-full text-white cursor-pointer leading-[30px] text-center",onClick:()=>N(s,"vertical"),children:(0,a.jsx)(d.G,{icon:o.NBC})})]},s)),(0,a.jsx)("div",{className:"w-[148px] h-[220px] m-[5px] inline-block align-top",children:(0,a.jsx)(u.Z,{type:"vertical",multiple:!0,preview:!1,onChange:e=>v(e),disabled:s.current_step>7})})]}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:s.current_step<=7&&
1(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>i(3),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:x,onClick:y,children:x?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," ","Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),l.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:l.main})]})})]})}var U=t(17810);function z(e){let s=e.submission,t=e.setSubmission,[i,l]=(0,n.useState)(s.worldwide_rights?s.worldwide_rights:1),[r,x]=(0,n.useState)(s.countries_rights_array?s.countries_rights_array:[]),p=e.setActiveStep,[u,h]=(0,n.useState)(Object);(0,m.useRouter)();let[b,g]=(0,n.useState)(!1);async function j(e){x(e)}async function f(e){let a={};a.step=6,a.prefix=s.prefix,a.right=i,a.countries=r,g(!0),h({}),c.Z.post({url:"submissions/save"+(s.id?"/"+s.id:""),data:a}).then(e=>{t(e.submission),p(7)}).catch(e=>{g(!1),422==e.status_code?(e.message.main="Please fix above errors",h(e.message)):h({main:"Something went wrong! Please try again"})})}return(0,a.jsxs)("div",{className:"py-[25px] px-[25px]",children:[(0,a.jsx)("p",{className:"text-blue-500 text-2xl mb-[20px]",children:"Territories"}),(0,a.jsxs)("div",{className:"mb-[30px]",children:[(0,a.jsx)("p",{className:"mb-[20px]",children:"Do you want to make the movie available globally or in certain countries only?"}),(0,a.jsxs)("div",{className:"flex gap-4 items-end mb-[30px]",children:[(0,a.jsxs)("p",{children:[(0,a.jsx)("input",{type:"radio",name:"right",value:"1",id:"worldwide_right",defaultChecked:1==i,onChange:e=>l(e.target.value),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:s.current_step>7}),(0,a.jsx)("label",{htmlFor:"worldwide_right",children:"Show world wide"})]}),(0,a.jsxs)("p",{children:[(0,a.jsx)("input",{type:"radio",name:"right",value:"0",id:"country_right",defaultChecked:0==i,onChange:e=>l(e.target.value),className:"w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 align-[-3px] mr-[10px]",disabled:s.current_step>7}),(0,a.jsx)("label",{htmlFor:"country_right",children:"Show in selected countries only"})]})]})]}),0==i&&(0,a.jsx)("div",{children:(0,a.jsx)(U.Z,{isMulti:!0,loadOptions:e=>(function(e){let s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return c.Z.post({url:"dropdown/"+e,data:{str:s}}).then(e=>e)})("country_text",e),defaultOptions:!0,placeholder:"Enter production country",classNames:{control:e=>"!min-h-[46px] !rounded-lg"},name:"movie_country",defaultValue:r,onChange:j,isDisabled:s.current_step>7})}),(0,a.jsx)("div",{className:"border-t px-[25px] py-[50px] text-center",children:s.current_step<=7&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",className:"btn-simple-theme mr-[10px]",onClick:()=>p(4),children:"BACK TO PREVIOUS"}),(0,a.jsx)("button",{type:"submit",className:"btn",disabled:b,onClick:f,children:b?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"mr-[10px]"})," ","Processing"]}):(0,a.jsx)(a.Fragment,{children:"SAVE & NEXT"})}),u.main&&(0,a.jsx)("p",{className:"text-red-500 text-sm mt-[10px]",children:u.main})]})})]})}var W=t(48667),Y=t(722),J=t(94664),$=t(16415);function q(e){let{unique_id:s}=e,[t,m]=(0,n.useState)(""),[x,p]=(0,n.useState)(1),[u,h]=(0,n.useState)(Object),f="ms_"==u.prefix,[v,_]=(0,n.useState)(!0),[y,w]=(0,n.useState)(!1),S=(0,Y.ac)({query:"(max-width: 768px)"}),[k,C]=(0,n.useState)(""),[E,P]=(0,n.useState)(!1),[O,I]=(0,n.useState)(!1),T=(0,n.useRef)(new Set),D=u.bundle_full_name||u.bundle_name||j.subdomain.get("full_name")||u.subdomain||"",Z=f?"WatchMyFilm.com":D;return((0,n.useEffect)(()=>{if(S)_(!1);else{let e=(0,l.getCookie)("token");e?(m(e),s?c.Z.post({url:"submissions/getByUniqueId/"+s}).then(e=>{h(e);let s="ms_"==e.prefix,t=parseFloat(e.current_step);s||2!==t||(t=e.open_submissions?2.5:3),s||6!==t||(t=7),e.bundle_id&&1==e.open_submissions&&0===e.entries_open&&!e.curation_decision&&(I(!0),C("Submissions are closed for this program.")),p(t),_(!1)}):c.Z.post({url:"getUser"}).then(e=>{let s=e.first_name+(e.last_name?" ".concat(e.last_name):""),t=j.subdomain.get("submit_prefix")||"ms_",a=j.subdomain.get("bundle_id")||null;h({name:s,email:e.email,prefix:t,bundle_id:a}),"ms_"!=t&&a?c.Z.post({url:"submissions/getEntriesStatus",data:{bundle_id:a}}).then(e=>{1==e.open_submissions&&0===e.entries_open&&(P(!0),C(e.message||"Submissions are closed for this program.")),_(!1)}).catch(()=>{_(!1)}):_(!1)})):(w(!0),_(!1))}},[]),(0,n.useEffect)(()=>
1{if(v||y||!(null==u?void 0:u.prefix))return;let e="ms_"!==u.prefix,t=e?"festival_submission":"movie_submission",a="".concat(t,":started");T.current.has(a)||(T.current.add(a),J.Z.trackEvent({eventName:e?"festival_submission_started":"movie_submission_started",eventGroup:e?"festival_submission_funnel":"movie_submission_funnel",intent:e?"festival_submission":"movie_submission",data:{submission_id:u.id||null,is_new:!s}}));let i="".concat(t,":step:").concat(x);T.current.has(i)||(T.current.add(i),J.Z.trackEvent({eventName:e?"festival_submission_step_viewed":"movie_submission_step_viewed",eventGroup:e?"festival_submission_funnel":"movie_submission_funnel",intent:e?"festival_submission":"movie_submission",data:{submission_id:u.id||null,step:x}}))},[x,v,y,u,s]),v)?(0,a.jsx)("div",{children:(0,a.jsx)("div",{className:"w-[100px] m-auto text-center",children:(0,a.jsx)(d.G,{icon:o.IJ7,spin:!0,className:"text-blue-500 text-5xl"})})}):S?(0,a.jsx)("div",{className:"grow content-center bg-white text-center",children:(0,a.jsx)("p",{className:"font-bold text-2xl",children:"Please use a larger screen (such as a tablet or desktop) to submit."})}):y?(0,a.jsx)("div",{children:(0,a.jsxs)("div",{className:"m-auto text-center",children:[(0,a.jsx)("p",{className:"mb-[20px] text-xl font-bold",children:"Please sign in to access"}),(0,a.jsx)(r.Z,{btn_class:"btn"})]})}):E||O?(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"pt-[30px] pb-[30px] px-[25px]",children:(0,a.jsxs)("div",{children:[(0,a.jsxs)(i.default,{href:"/submit",className:"group text-slate-700 hover:text-black mb-[10px]",children:[(0,a.jsx)(d.G,{icon:o.acZ,className:"mr-[5px] group-hover:mr-[10px] transition-all ease-in-out duration-300"})," Back to dashboard"]}),!!Z&&(0,a.jsxs)("p",{className:"text-center text-base font-medium mb-[14px]",children:["Submission for: ",Z]})]})}),(0,a.jsx)("div",{className:"px-[25px] py-[50px]",children:(0,a.jsxs)("div",{className:"max-w-[700px] m-auto p-[25px] rounded-lg border border-red-300 bg-red-50 text-center",children:[(0,a.jsx)("p",{className:"text-xl font-semibold mb-[10px]",children:"Submission Deadline Passed"}),(0,a.jsx)("p",{children:k||"Submissions are closed for this program."})]})})]})}):"more_info_needed"==u.curation_decision?(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"pt-[30px] pb-[30px] px-[25px]",children:(0,a.jsxs)(i.default,{href:"/submit",className:"group text-slate-700 hover:text-black mb-[10px]",children:[(0,a.jsx)(d.G,{icon:o.acZ,className:"mr-[5px] group-hover:mr-[10px] transition-all ease-in-out duration-300"})," Back to dashboard"]})}),(0,a.jsx)("div",{className:"px-[25px] py-[50px]",children:(0,a.jsx)($.Z,{contactEmail:"[email protected]"})})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(W.default,{src:"https://checkout.razorpay.com/v1/checkout.js"}),(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"pt-[30px] pb-[30px] px-[25px]",children:(0,a.jsxs)("div",{children:[(0,a.jsxs)(i.default,{href:"/submit",className:"group text-slate-700 hover:text-black mb-[10px]",children:[(0,a.jsx)(d.G,{icon:o.acZ,className:"mr-[5px] group-hover:mr-[10px] transition-all ease-in-out duration-300"})," Back to dashboard"]}),!!Z&&(0,a.jsxs)("p",{className:"text-center text-base font-medium mb-[14px]",children:["Submission for: ",Z]}),(0,a.jsxs)("p",{className:"text-2xl lg:text-3xl font-light mb-[10px] mt-[30px]",children:["SUBMIT MOVIE: ",(0,a.jsx)("i",{children:u.title})]}),(0,a.jsx)("p",{className:"mb-[10px]",children:"Email us at [email protected] if you have any questions."})]})}),(0,a.jsx)("div",{children:(0,a.jsx)("div",{className:"lg:py-[25px] border-b px-[15px] lg:px-[0px]",children:(0,a.jsx)(g,{activeStep:x,setActiveStep:p,currentStep:u.current_step,curationDecision:u.curation_decision,feeWaived:u.fee_waived,showFestivalStep:f,showTerritoriesStep:f,submissionPrefix:u.prefix})})}),1==x&&(0,a.jsx)(b,{submission:u,setSubmission:h,setActiveStep:p}),1.5==x&&(0,a.jsx)(B,{submission:u,setSubmission:h,setActiveStep:p,showFestivalStep:f}),f&&2==x&&(0,a.jsx)(V,{submission:u,setSubmission:h,setActiveStep:p}),2.5==x&&(0,a.jsx)(A,{submission:u,setSubmission:h,setActiveStep:p,showFestivalStep:f}),3==x&&(0,a.jsx)(F,{submission:u,setSubmission:h,setActiveStep:p}),4==x&&(0,a.jsx)(L,{submission:u,setSubmission:h,setActiveStep:p}),5==x&&(0,a.jsx)(N,{submission:u,setSubmission:h,setActiveStep:p,showTerritoriesStep:f}),f&&6==x&&(0,a.jsx)(z,{submission:u,setSubmission:h,setActiveStep:p}),7==x&&(0,a.jsx)(R,{submission:u,setSubmission:h,setActiveStep:p,showTerritoriesStep:f}),8==x&&(0,a.jsxs)("div",{className:"text-center pt-[30px]",children:[(0,a.jsx)("h1",{className:"text-2xl mb-[20px]",children:"You have successfully submitted your movie."}),(0,a.jsx)("h2",{className:"text-xl",children:"If you want to change anything, please email us at [email protected]"})]})]})]})}}}]);

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.