1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[98270,52048,9003],{52048:function(e,t,n){n.r(t),n.d(t,{Mixpanel:function(){return i}});var r=n(34904);r.Z.init("e30dd2a930e01bac74364ce34c2d6beb");let i={identify:e=>{r.Z.identify(e)},alias:e=>{r.Z.alias(e)},track:(e,t)=>{r.Z.track(e,t)},action:e=>{r.Z.track(e)},people:{set:e=>{r.Z.people.set(e)}},reset:()=>{r.Z.reset()}}},17949:function(e,t,n){var r=n(57437);t.Z=e=>{let{label:t,isActive:n,onClick:i,className:l=""}=e;return(0,r.jsx)("button",{onClick:i,className:"px-[12px] py-[6px] border border-[rgba(80,80,80,1)] cursor-pointer\n ".concat(n?"bg-[rgba(45,45,45,1)] text-white transition-all duration-200":"bg-[rgba(29,29,29,1)] text-[rgba(143,143,143,1)] hover:bg-[rgba(55,55,55,1)] hover:text-[rgba(200,200,200,1)] transition-all duration-200","\n ").concat(l),children:t})}},12381:function(e,t,n){n.d(t,{d:function(){return v},z:function(){return h}});var r=n(57437),i=n(2265),l=n(37053),a=n(90535),o=n(38452);let u="flex items-center justify-center whitespace-nowrap rounded-md focus-visible:outline-none",c={primary:"bg-primary text-primary-foreground hover:bg-[#e8e8e8] active:bg-[#c7c7c7] border border-primary transition-all duration-200",dark:"bg-dark-green text-white hover:bg-black transition-all duration-200",outline:"border-gradient-2 text-gradient-2 bg-transparent rounded-full hover:bg-white/[0.04] transition-all duration-200",secondary:"bg-gradient-2 hover:bg-gradient-3 text-white transition-all duration-200",link:"text-primary underline-offset-4 hover:underline transition-all duration-200",ghost:"hover:bg-white/[0.06] active:scale-[0.98] transition-all duration-200",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90 transition-all duration-200",bare:""},d={default:"",sm:"h-9",lg:"h-14",icon:"h-12 w-12"},s={default:"",sm:"px-3",lg:"px-8 py-2",icon:""},v=(0,a.j)(u,{variants:{variant:c,size:d,space:s},defaultVariants:{variant:"primary",size:"default",space:"default"}}),h=i.forwardRef((e,t)=>{let{className:n,innerClassName:i="",variant:a,size:h="default",children:f,asChild:g=!1,...p}=e,m=g?l.g7:"button";return(0,r.jsx)(r.Fragment,{children:"secondary"===a?(0,r.jsx)(m,{className:(0,o.cn)(u,a&&(null==c?void 0:c[a])?null==c?void 0:c[a]:"",h&&(null==d?void 0:d[h])?null==d?void 0:d[h]:"","group",n),ref:t,...p,children:(0,r.jsx)("span",{className:(0,o.cn)(h&&(null==s?void 0:s[h])?null==s?void 0:s[h]:"","bg-dark-green group-hover:bg-black group-active:bg-dark-green rounded-md inline-flex items-center justify-center font-display transition-all duration-500",i),children:f})}):(0,r.jsx)(m,{className:(0,o.cn)(v({variant:a,size:h,className:n})),ref:t,...p,children:f})})});h.displayName="Button"},32731:function(e,t,n){n.d(t,{X:function(){return l}});var r=n(2265),i=n(9979);let l=()=>(0,r.useContext)(i.J)},9979:function(e,t,n){n.d(t,{J:function(){return h},D:function(){return m}});var r=n(57437),i=n(2265),l=n(28105),a=n(93306),o=n(37853),u=n(28853);let c=async()=>{try{var e,t,n,r,i,l;let a=await (0,o.W)({method:"get",url:"/billing/stat"}),c="data"in a?a.data:a;if(!c)return null;let d={name:(null==c?void 0:null===(e=c.plan)||void 0===e?void 0:e.name)?(0,u.m0)(c.plan.name):null==c?void 0:null===(t=c.plan)||void 0===t?void 0:t.name,type:null==c?void 0:null===(n=c.plan)||void 0===n?void 0:n.type,billing_cycle:null==c?void 0:null===(r=c.plan)||void 0===r?void 0:r.billing_cycle,plan_cost:null==c?void 0:null===(i=c.plan)||void 0===i?void 0:i.plan_cost,id:null==c?void 0:null===(l=c.plan)||void 0===l?void 0:l.id};return{usage:null==c?void 0:c.usage,plan:d,is_enterprise:null==c?void 0:c.is_enterprise,hide_wallet_balance:null==c?void 0:c.hide_wallet_balance,cancel_at_period_end:null==c?void 0:c.cancel_at_period_end,cancel_at:null==c?void 0:c.cancel_at}}catch(e){return console.error("Failed to fetch subscription:",e),null}},d=async()=>{try{return await (0,o.W)({method:"get",url:"/billing/credits"})}catch(e){return console.error("Failed to fetch credit balance:",e),null}},s=async()=>{let[e,t]=await Promise.all([c(),d()]);return{subscription:e,creditBalanceData:t}},v=()=>{let{authStatus:e}=(0,a.Z)(e=>[e.authStatus]),t="authenticated"===e,{data:n,isLoading:r,isValidating:o,mutate:u}=(0,l.ZP)(t?"subscription-data":null,s,{revalidateOnFocus:!1}),c=(0,i.useCallback)(()=>t?u():Promise.resolve(void 0),[t,u]);return{data:null!=n?n:null,isLoading:!!t&&(r||o),refresh:c,mutate:u}},h=i.createContext({data:null,isLoading:!1,refresh:()=>Promise.resolve(void 0),resolution:{status:"idle"},resolveCheckout:()=>{}}),f=[1e3,2e3,3e3,5e3];function g(e,t){var n;return!!e&&e.name===t.displayName&&("Enterprise Plan"===t.displayName||(null!==(n=e.billing_cycle)&&void 0!==n?n:"").toLowerCase()===t.billingCycle)}function p(){localStorage.setItem("show-upgrade-modal","true"),localStorage.removeItem("pendingPaymentProductId"),localStorage.removeItem("selectedProductId"),window.dispatchEvent(new Event("show-upgrade-modal"))}let m=e=>{let{children:t}=e,{data:n,isLoading:l,refresh:a,mutate:o}=v(),[u,c]=(0,i.useState)({status:"idle"}),d=(0,i.useRef)(n);(0,i.useEffect)(()=>{d.current=n},[n]);let s=(0,i.useRef)(null),m=(0,i.useRef)(null);(0,i.useEffect)(()=>()=>{var e;(null===(e=s.current)||void 0===e?void 0:e.timer)&&clearTimeout(s.current.timer),s.current&&(s.current.cancelled=!0)},[]);let b=(0,i.useCallback)((e,t)=>{var n,r,i;if(!e||m.current===e)return;m.current=e;let l=function(e){let t;let n=e.toLowerCase();if("free"===n)t="Free Plan";else if(n.includes("enterprise"))t="Enterprise Plan";else{if(!(n.includes("pro")||n.includes("base")))return null;t="Pro Plan"}return{displayName:t,billingCycle:n.includes("annual")||n.includes("year")?"annual"
1:"monthly"}}(e);if(!l){c({status:"failed",expectedProductId:e,reason:"unrecognised"});return}if((null===(n=s.current)||void 0===n?void 0:n.timer)&&clearTimeout(s.current.timer),s.current&&(s.current.cancelled=!0),g(null===(i=d.current)||void 0===i?void 0:null===(r=i.subscription)||void 0===r?void 0:r.plan,l)){c({status:"settled",expectedProductId:e}),p();return}let a=Date.now(),u={expectedProductId:e,timer:null,cancelled:!1};s.current=u;let v=0;c({status:"pending",expectedProductId:e,startedAt:a});let h=()=>{u.cancelled||(u.cancelled=!0,s.current===u&&(s.current=null),c({status:"settled",expectedProductId:e}),p())},b=()=>{u.cancelled||(u.cancelled=!0,s.current===u&&(s.current=null),c({status:"failed",expectedProductId:e,reason:"timeout"}))},_=async()=>{var e;let t;if(u.cancelled)return;try{t=await o()}catch(e){t=void 0}if(u.cancelled)return;if(g(null==t?void 0:null===(e=t.subscription)||void 0===e?void 0:e.plan,l)){h();return}if(Date.now()-a>=6e4){b();return}let n=f[Math.min(v,f.length-1)];v+=1,u.timer=setTimeout(_,n)};u.timer=setTimeout(_,f[0])},[o]);return(0,r.jsx)(h.Provider,{value:{data:n,isLoading:l,refresh:a,resolution:u,resolveCheckout:b},children:t})}},89819:function(e,t,n){var r,i;n.d(t,{Q:function(){return r}}),(i=r||(r={})).BASE="base",i.FREE="free",i.PRO="pro",i.ENTERPRISE="enterprise"},37853:function(e,t,n){n.d(t,{W:function(){return u}});var r=n(83464),i=n(10924);let l=r.Z.create({baseURL:"https://api.aiornot.com/aion"});l.interceptors.request.use(async e=>(e.headers={...e.headers},e),e=>(console.error("response in interceptor line number 27",JSON.stringify(e)),Promise.reject(e)));let a=async(e,t)=>{var n;let r={headers:{Authorization:"",...e}},{accessToken:l}=null!==(n=(await (0,i.y)()).tokens)&&void 0!==n?n:{};l&&(null==l?void 0:l.toString())&&(r.headers.Authorization="Bearer ".concat(null==l?void 0:l.toString()));{let e=sessionStorage.getItem("impersonatedUserId");e&&(r.headers["X-Impersonate-User-Id"]=e)}return{...r,...t}},o=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l,{method:n,url:r,data:i,config:o,headers:u}=e,c=await a(u,o);switch(n){case"get":return t.get(r,c);case"post":return t.post(r,i,c);case"put":return t.put(r,i,c);case"patch":return t.patch(r,i,c);case"delete":return t.delete(r,c);default:throw Error("Unsupported method: ".concat(n))}},u=async e=>{let t=await o(e);if(!t)throw Error("Request failed with no response.");return t.data}},28853:function(e,t,n){n.d(t,{JK:function(){return u},Z0:function(){return a},_D:function(){return o},m0:function(){return l},mo:function(){return r}});let r="/billing/usage/current-period",i=new Set(["Hitachi ProjectF","Hitachi Internal Intelligence","VerifyLabs Enterprise","AIorNot Internal Service"]);function l(e){return e?e.startsWith("AIorNot Free")?"Free Plan":e.startsWith("AIorNot Pro")||"Dimensa Prepaid Image Pack"===e?"Pro Plan":i.has(e)?"Enterprise Plan":e:e}function a(e){let t=e/1e6;return 0===t?"$0.00":t<.01?"$".concat(t.toFixed(6).replace(/0+$/,"")):new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:2,maximumFractionDigits:4}).format(t)}function o(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=new Map(t.map(e=>[e.model_key,e]));return e.map(e=>{var t,r,i;let l=n.get(e.model_code);return{...e,total_calls:null!==(t=null==l?void 0:l.total_calls)&&void 0!==t?t:0,total_units:null!==(r=null==l?void 0:l.total_units)&&void 0!==r?r:0,total_cost_microusd:null!==(i=null==l?void 0:l.total_cost_microusd)&&void 0!==i?i:0,included_units:function(e){var t;let n=e.find(e=>e.threshold_units>0&&e.unit_price_microusd>0);return null!==(t=null==n?void 0:n.threshold_units)&&void 0!==t?t:null}(e.tiers)}})}function u(e){if(e.is_enterprise||e.hide_wallet_balance)return{showWallet:!1,showTopOff:!1,showAutoRecharge:!1};let t=!1!==e.top_offs_enabled,n=t&&!1!==e.auto_recharge_available;return{showWallet:!0,showTopOff:t,showAutoRecharge:n}}},38452:function(e,t,n){n.d(t,{Tq:function(){return s},_1:function(){return c},az:function(){return o},cn:function(){return l}});var r=n(61994),i=n(53335);function l(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,i.m6)((0,r.W)(t))}let a=e=>{if(!e)return"";let t=e.toString();return t.charAt(0).toUpperCase()+t.slice(1).toLowerCase()},o=function(e){var t,n;let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"Something went wrong!";return a((null==e?void 0:null===(n=e.response)||void 0===n?void 0:null===(t=n.data)||void 0===t?void 0:t.message)||r)},u=(e,t)=>
10===e?0:t/e*100,c=(e,t)=>Number((100-u(e,t)).toFixed(2)),d={image:["image","images","image_check","image_checks"],audio:["audio","audios","audio_check","audio_checks"],video:["video","videos","video_check","video_checks"],text:["text","texts","text_check","text_checks"]},s=(e,t)=>{var n;if(!(null==e?void 0:e.length))return;let r=t.toLowerCase(),i=null!==(n=d[r])&&void 0!==n?n:[r];return e.find(e=>i.includes(e.name))}},97519:function(e,t,n){n.r(t),t.default={src:"/_next/static/media/deepfake-image.88fe1546.svg",height:20,width:20,blurWidth:0,blurHeight:0}},27315:function(e,t,n){n.r(t),t.default={src:"/_next/static/media/image-icon.be2ec800.svg",height:20,width:20,blurWidth:0,blurHeight:0}},19139:function(e,t,n){n.r(t),t.default={src:"/_next/static/media/video-icon.7b843a2e.svg",height:20,width:20,blurWidth:0,blurHeight:0}},70928:function(e,t,n){n.r(t),t.default={src:"/_next/static/media/white-music-icon.a93796bd.svg",height:20,width:20,blurWidth:0,blurHeight:0}},18768:function(e,t,n){n.r(t),t.default={src:"/_next/static/media/white-voice-icon.30e09313.svg",height:20,width:20,blurWidth:0,blurHeight:0}}}]);
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.