try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="d8d59ba8-a5f2-4c0f-9b22-79d23044064e",e._sentryDebugIdIdentifier="sentry-dbid-d8d59ba8-a5f2-4c0f-9b22-79d23044064e")}catch(e){}(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3880],{9484:(e,t,a)=>{"use strict";a.d(t,{C1:()=>w,bL:()=>b});var s=a(12115),n=a(3468),r=a(97602),o=a(95155),l="Progress",[i,c]=(0,n.A)(l),[d,u]=i(l),f=s.forwardRef((e,t)=>{var a,s,n,l;let{__scopeProgress:i,value:c=null,max:u,getValueLabel:f=g,...m}=e;(u||0===u)&&!x(u)&&console.error((a="".concat(u),s="Progress","Invalid prop `max` of value `".concat(a,"` supplied to `").concat(s,"`. Only numbers greater than 0 are valid max values. Defaulting to `").concat(100,"`.")));let p=x(u)?u:100;null===c||y(c,p)||console.error((n="".concat(c),l="Progress","Invalid prop `value` of value `".concat(n,"` supplied to `").concat(l,"`. The `value` prop must be:\n  - a positive number\n  - less than the value passed to `max` (or ").concat(100," if no `max` prop is set)\n  - `null` or `undefined` if the progress is indeterminate.\n\nDefaulting to `null`.")));let b=y(c,p)?c:null,w=v(b)?f(b,p):void 0;return(0,o.jsx)(d,{scope:i,value:b,max:p,children:(0,o.jsx)(r.sG.div,{"aria-valuemax":p,"aria-valuemin":0,"aria-valuenow":v(b)?b:void 0,"aria-valuetext":w,role:"progressbar","data-state":h(b,p),"data-value":null!=b?b:void 0,"data-max":p,...m,ref:t})})});f.displayName=l;var m="ProgressIndicator",p=s.forwardRef((e,t)=>{var a;let{__scopeProgress:s,...n}=e,l=u(m,s);return(0,o.jsx)(r.sG.div,{"data-state":h(l.value,l.max),"data-value":null!==(a=l.value)&&void 0!==a?a:void 0,"data-max":l.max,...n,ref:t})});function g(e,t){return"".concat(Math.round(e/t*100),"%")}function h(e,t){return null==e?"indeterminate":e===t?"complete":"loading"}function v(e){return"number"==typeof e}function x(e){return v(e)&&!isNaN(e)&&e>0}function y(e,t){return v(e)&&!isNaN(e)&&e<=t&&e>=0}p.displayName=m;var b=f,w=p},20097:function(e,t,a){var s,n;void 0!==(n="function"==typeof(s=function(){"use strict";function t(e,t,a){var s=new XMLHttpRequest;s.open("GET",e),s.responseType="blob",s.onload=function(){l(s.response,t,a)},s.onerror=function(){console.error("could not download file")},s.send()}function s(e){var t=new XMLHttpRequest;t.open("HEAD",e,!1);try{t.send()}catch(e){}return 200<=t.status&&299>=t.status}function n(e){try{e.dispatchEvent(new MouseEvent("click"))}catch(a){var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}var r="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof a.g&&a.g.global===a.g?a.g:void 0,o=r.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),l=r.saveAs||("object"!=typeof window||window!==r?function(){}:"download"in HTMLAnchorElement.prototype&&!o?function(e,a,o){var l=r.URL||r.webkitURL,i=document.createElement("a");i.download=a=a||e.name||"download",i.rel="noopener","string"==typeof e?(i.href=e,i.origin===location.origin?n(i):s(i.href)?t(e,a,o):n(i,i.target="_blank")):(i.href=l.createObjectURL(e),setTimeout(function(){l.revokeObjectURL(i.href)},4e4),setTimeout(function(){n(i)},0))}:"msSaveOrOpenBlob"in navigator?function(e,a,r){if(a=a||e.name||"download","string"!=typeof e){var o;navigator.msSaveOrOpenBlob((void 0===(o=r)?o={autoBom:!1}:"object"!=typeof o&&(console.warn("Deprecated: Expected third argument to be a object"),o={autoBom:!o}),o.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\uFEFF",e],{type:e.type}):e),a)}else if(s(e))t(e,a,r);else{var l=document.createElement("a");l.href=e,l.target="_blank",setTimeout(function(){n(l)})}}:function(e,a,s,n){if((n=n||open("","_blank"))&&(n.document.title=n.document.body.innerText="downloading..."),"string"==typeof e)return t(e,a,s);var l="application/octet-stream"===e.type,i=/constructor/i.test(r.HTMLElement)||r.safari,c=/CriOS\/[\d]+/.test(navigator.userAgent);if((c||l&&i||o)&&"undefined"!=typeof FileReader){var d=new FileReader;d.onloadend=function(){var e=d.result;e=c?e:e.replace(/^data:[^;]*;/,"data:attachment/file;"),n?n.location.href=e:location=e,n=null},d.readAsDataURL(e)}else{var u=r.URL||r.webkitURL,f=u.createObjectURL(e);n?n.location=f:location.href=f,n=null,setTimeout(function(){u.revokeObjectURL(f)},4e4)}});r.saveAs=l.saveAs=l,e.exports=l})?s.apply(t,[]):s)&&(e.exports=n)},20764:(e,t,a)=>{"use strict";a.d(t,{$:()=>i});var s=a(95155);a(12115);var n=a(32467),r=a(83101),o=a(64269);let l=(0,r.F)("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-[color,box-shadow] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",destructive:"bg-destructive text-white shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40",outline:"border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9"}},defaultVariants:{variant:"default",size:"default"}});function i(e){let{className:t,variant:a,size:r,asChild:i=!1,...c}=e,d=i?n.DX:"button";return(0,s.jsx)(d,{"data-slot":"button",className:(0,o.cn)(l({variant:a,size:r,className:t})),...c,"data-sentry-element":"Comp","data-sentry-component":"Button","data-sentry-source-file":"button.tsx"})}},25532:(e,t,a)=>{"use strict";a.d(t,{bq:()=>u,eb:()=>m,gC:()=>f,l6:()=>c,yv:()=>d});var s=a(95155);a(12115);var n=a(15686),r=a(24033),o=a(5917),l=a(12108),i=a(64269);function c(e){let{...t}=e;return(0,s.jsx)(n.bL,{"data-slot":"select",...t,"data-sentry-element":"unknown","data-sentry-component":"Select","data-sentry-source-file":"select.tsx"})}function d(e){let{...t}=e;return(0,s.jsx)(n.WT,{"data-slot":"select-value",...t,"data-sentry-element":"unknown","data-sentry-component":"SelectValue","data-sentry-source-file":"select.tsx"})}function u(e){let{className:t,children:a,...o}=e;return(0,s.jsxs)(n.l9,{"data-slot":"select-trigger",className:(0,i.cn)("border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive flex h-9 w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",t),...o,"data-sentry-element":"unknown","data-sentry-component":"SelectTrigger","data-sentry-source-file":"select.tsx",children:[a,(0,s.jsx)(n.In,{asChild:!0,"data-sentry-element":"unknown","data-sentry-source-file":"select.tsx",children:(0,s.jsx)(r.A,{className:"size-4 opacity-50","data-sentry-element":"ChevronDownIcon","data-sentry-source-file":"select.tsx"})})]})}function f(e){let{className:t,children:a,position:r="popper",...o}=e;return(0,s.jsx)(n.ZL,{"data-sentry-element":"unknown","data-sentry-component":"SelectContent","data-sentry-source-file":"select.tsx",children:(0,s.jsxs)(n.UC,{"data-slot":"select-content",className:(0,i.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border shadow-md","popper"===r&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",t),position:r,...o,"data-sentry-element":"unknown","data-sentry-source-file":"select.tsx",children:[(0,s.jsx)(p,{"data-sentry-element":"SelectScrollUpButton","data-sentry-source-file":"select.tsx"}),(0,s.jsx)(n.LM,{className:(0,i.cn)("p-1","popper"===r&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),"data-sentry-element":"unknown","data-sentry-source-file":"select.tsx",children:a}),(0,s.jsx)(g,{"data-sentry-element":"SelectScrollDownButton","data-sentry-source-file":"select.tsx"})]})})}function m(e){let{className:t,children:a,...r}=e;return(0,s.jsxs)(n.q7,{"data-slot":"select-item",className:(0,i.cn)("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",t),...r,"data-sentry-element":"unknown","data-sentry-component":"SelectItem","data-sentry-source-file":"select.tsx",children:[(0,s.jsx)("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:(0,s.jsx)(n.VF,{"data-sentry-element":"unknown","data-sentry-source-file":"select.tsx",children:(0,s.jsx)(o.A,{className:"size-4","data-sentry-element":"CheckIcon","data-sentry-source-file":"select.tsx"})})}),(0,s.jsx)(n.p4,{"data-sentry-element":"unknown","data-sentry-source-file":"select.tsx",children:a})]})}function p(e){let{className:t,...a}=e;return(0,s.jsx)(n.PP,{"data-slot":"select-scroll-up-button",className:(0,i.cn)("flex cursor-default items-center justify-center py-1",t),...a,"data-sentry-element":"unknown","data-sentry-component":"SelectScrollUpButton","data-sentry-source-file":"select.tsx",children:(0,s.jsx)(l.A,{className:"size-4","data-sentry-element":"ChevronUpIcon","data-sentry-source-file":"select.tsx"})})}function g(e){let{className:t,...a}=e;return(0,s.jsx)(n.wn,{"data-slot":"select-scroll-down-button",className:(0,i.cn)("flex cursor-default items-center justify-center py-1",t),...a,"data-sentry-element":"unknown","data-sentry-component":"SelectScrollDownButton","data-sentry-source-file":"select.tsx",children:(0,s.jsx)(r.A,{className:"size-4","data-sentry-element":"ChevronDownIcon","data-sentry-source-file":"select.tsx"})})}},26737:(e,t,a)=>{"use strict";a.d(t,{k:()=>o});var s=a(95155);a(12115);var n=a(9484),r=a(64269);function o(e){let{className:t,value:a,...o}=e;return(0,s.jsx)(n.bL,{"data-slot":"progress",className:(0,r.cn)("bg-primary/20 relative h-2 w-full overflow-hidden rounded-full",t),...o,"data-sentry-element":"unknown","data-sentry-component":"Progress","data-sentry-source-file":"progress.tsx",children:(0,s.jsx)(n.C1,{"data-slot":"progress-indicator",className:"bg-primary h-full w-full flex-1 transition-all",style:{transform:"translateX(-".concat(100-(a||0),"%)")},"data-sentry-element":"unknown","data-sentry-source-file":"progress.tsx"})})}},39867:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(71847).A)("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]])},42526:(e,t,a)=>{"use strict";a.d(t,{J:()=>o});var s=a(95155);a(12115);var n=a(10489),r=a(64269);function o(e){let{className:t,...a}=e;return(0,s.jsx)(n.b,{"data-slot":"label",className:(0,r.cn)("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",t),...a,"data-sentry-element":"unknown","data-sentry-component":"Label","data-sentry-source-file":"label.tsx"})}},60495:(e,t,a)=>{"use strict";async function s(e,t){try{var a;let s=await (a=e,new Promise((e,t)=>{let s=new Image;s.onload=()=>e(s),s.onerror=t,s.src=URL.createObjectURL(a)})),n=document.createElement("canvas"),r=n.getContext("2d"),o=t.width||s.width,l=t.height||s.height;if(t.maintainAspectRatio&&(t.width||t.height)){let e=s.width/s.height;if(t.width&&!t.height)l=Math.round(t.width/e);else if(!t.width&&t.height)o=Math.round(t.height*e);else if(t.width&&t.height){let e=Math.min(t.width/s.width,t.height/s.height);o=Math.round(s.width*e),l=Math.round(s.height*e)}}n.width=o,n.height=l,r.drawImage(s,0,0,o,l),t.effect&&function(e,t,a){let s=e.getImageData(0,0,e.canvas.width,e.canvas.height),n=s.data;switch(t){case"grayscale":for(let e=0;e<n.length;e+=4){let t=(n[e]+n[e+1]+n[e+2])/3;n[e]=n[e+1]=n[e+2]=t}break;case"brightness":let r=1+a;for(let e=0;e<n.length;e+=4)n[e]*=r,n[e+1]*=r,n[e+2]*=r;break;case"contrast":let o=255*a,l=(255+o)/(255.01-o);for(let e=0;e<n.length;e+=4)n[e]=l*(n[e]-128)+128,n[e+1]=l*(n[e+1]-128)+128,n[e+2]=l*(n[e+2]-128)+128;break;case"sepia":for(let e=0;e<n.length;e+=4){let t=n[e],a=n[e+1],s=n[e+2];n[e]=Math.min(255,.393*t+.769*a+.189*s),n[e+1]=Math.min(255,.349*t+.686*a+.168*s),n[e+2]=Math.min(255,.272*t+.534*a+.131*s)}break;case"invert":for(let e=0;e<n.length;e+=4)n[e]=255-n[e],n[e+1]=255-n[e+1],n[e+2]=255-n[e+2];break;case"blur":let i=e.canvas.width,c=e.canvas.height,d=Math.floor(10*a),u=document.createElement("canvas");u.width=i,u.height=c,u.getContext("2d").putImageData(s,0,0),e.filter="blur(".concat(d,"px)"),e.drawImage(u,0,0);return;case"saturation":for(let e=0;e<n.length;e+=4){let t=n[e],s=n[e+1],r=n[e+2],o=.2989*t+.587*s+.114*r;n[e]=o+a*(t-o),n[e+1]=o+a*(s-o),n[e+2]=o+a*(r-o)}}e.putImageData(s,0,0)}(r,t.effect,t.effectIntensity||1);let i=await new Promise(e=>{n.toBlob(t=>e(t),"image/".concat(t.format||"png"),t.quality?t.quality/100:.9)});return{success:!0,message:"Image processed successfully",processedBlob:i,originalSize:e.size,processedSize:i.size}}catch(e){return console.error("Image processing failed:",e),{success:!1,message:e instanceof Error?e.message:"Image processing failed"}}}async function n(e,t){return s(e,t)}async function r(e,t){return n(e,t)}async function o(e,t){let a=new FormData;a.append("file",e),a.append("options",JSON.stringify(t));try{let t=await fetch("/api/image/remove-background",{method:"POST",body:a});if(!t.ok)throw Error("Background removal failed");let s=await t.blob();return{success:!0,message:"Background removed successfully",processedBlob:s,originalSize:e.size,processedSize:s.size}}catch(e){return{success:!1,message:e instanceof Error?e.message:"Background removal failed"}}}function l(e){if(0===e)return"0 Bytes";let t=Math.floor(Math.log(e)/Math.log(1024));return parseFloat((e/Math.pow(1024,t)).toFixed(2))+" "+["Bytes","KB","MB","GB"][t]}a.d(t,{JF:()=>n,hS:()=>o,v7:()=>l,yh:()=>r}),a(7496)},64269:(e,t,a)=>{"use strict";a.d(t,{cn:()=>r});var s=a(2821),n=a(75889);function r(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return(0,n.QP)((0,s.$)(t))}},66094:(e,t,a)=>{"use strict";a.d(t,{BT:()=>i,Wu:()=>c,ZB:()=>l,Zp:()=>r,aR:()=>o});var s=a(95155);a(12115);var n=a(64269);function r(e){let{className:t,...a}=e;return(0,s.jsx)("div",{"data-slot":"card",className:(0,n.cn)("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",t),...a,"data-sentry-component":"Card","data-sentry-source-file":"card.tsx"})}function o(e){let{className:t,...a}=e;return(0,s.jsx)("div",{"data-slot":"card-header",className:(0,n.cn)("flex flex-col gap-1.5 px-6",t),...a,"data-sentry-component":"CardHeader","data-sentry-source-file":"card.tsx"})}function l(e){let{className:t,...a}=e;return(0,s.jsx)("div",{"data-slot":"card-title",className:(0,n.cn)("leading-none font-semibold",t),...a,"data-sentry-component":"CardTitle","data-sentry-source-file":"card.tsx"})}function i(e){let{className:t,...a}=e;return(0,s.jsx)("div",{"data-slot":"card-description",className:(0,n.cn)("text-muted-foreground text-sm",t),...a,"data-sentry-component":"CardDescription","data-sentry-source-file":"card.tsx"})}function c(e){let{className:t,...a}=e;return(0,s.jsx)("div",{"data-slot":"card-content",className:(0,n.cn)("px-6",t),...a,"data-sentry-component":"CardContent","data-sentry-source-file":"card.tsx"})}},74742:(e,t,a)=>{"use strict";a.d(t,{ImageEffects:()=>x});var s=a(95155),n=a(12115),r=a(11636),o=a(66094),l=a(20764),i=a(26737),c=a(42196),d=a(92001),u=a(39867),f=a(42526),m=a(96407),p=a(25532),g=a(60495),h=a(20097);let v=[{value:"grayscale",label:"Grayscale"},{value:"blur",label:"Blur"},{value:"sepia",label:"Sepia"},{value:"invert",label:"Invert"},{value:"brightness",label:"Brightness"},{value:"contrast",label:"Contrast"},{value:"saturation",label:"Saturation"}];function x(){let[e,t]=(0,n.useState)(null),[a,x]=(0,n.useState)(""),[y,b]=(0,n.useState)(""),[w,j]=(0,n.useState)(!1),[N,k]=(0,n.useState)(0),[E,S]=(0,n.useState)("grayscale"),[I,C]=(0,n.useState)(50),{getRootProps:B,getInputProps:z,isDragActive:A}=(0,r.VB)({accept:{"image/*":[".png",".jpg",".jpeg",".webp"]},maxFiles:1,onDrop:async e=>{if(e.length>0){let a=e[0];t(a),x(URL.createObjectURL(a)),b("")}}});(0,n.useEffect)(()=>{if(!e)return;let t=setTimeout(async()=>{try{let t=await (0,g.JF)(e,{effect:E,effectIntensity:I/100});if(t.success&&t.processedBlob){let e=URL.createObjectURL(t.processedBlob);b(e)}}catch(e){console.error("Preview generation failed:",e)}},300);return()=>clearTimeout(t)},[e,E,I]);let L=async()=>{if(e){j(!0),k(0);try{let t=await (0,g.JF)(e,{effect:E,effectIntensity:I/100});if(!t.success||!t.processedBlob)throw Error(t.message||"Effect application failed");let a=e.name.match(/\.[^/.]+$/),s=e.name.replace(/\.[^/.]+$/,"-".concat(E).concat(a&&a.length>0?a[0]:""));(0,h.saveAs)(t.processedBlob,s),alert("Effect applied successfully!")}catch(e){console.error("Effect application failed:",e),alert(e instanceof Error?e.message:"Failed to apply effect")}finally{j(!1),k(0)}}};return(0,s.jsxs)("div",{className:"grid md:grid-cols-2 gap-6","data-sentry-component":"ImageEffects","data-sentry-source-file":"ImageEffects.tsx",children:[(0,s.jsx)(o.Zp,{className:"p-6","data-sentry-element":"Card","data-sentry-source-file":"ImageEffects.tsx",children:(0,s.jsxs)("div",{...B(),className:"border-2 border-dashed rounded-lg p-12 text-center cursor-pointer transition-colors\n            ".concat(A?"border-primary bg-primary/5":"border-gray-300 dark:border-gray-600"),children:[(0,s.jsx)("input",{...z()}),(0,s.jsxs)("div",{className:"flex flex-col items-center gap-2",children:[(0,s.jsx)(c.A,{className:"w-12 h-12 text-muted-foreground","data-sentry-element":"ImageIcon","data-sentry-source-file":"ImageEffects.tsx"}),(0,s.jsx)("p",{children:"Drag & drop an image here, or click to select"}),(0,s.jsx)("p",{className:"text-sm text-muted-foreground",children:"Supports PNG, JPG, WEBP"})]})]})}),(0,s.jsx)(o.Zp,{className:"p-6 space-y-6","data-sentry-element":"Card","data-sentry-source-file":"ImageEffects.tsx",children:e?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{className:"flex items-center justify-between",children:[(0,s.jsxs)("div",{className:"flex items-center space-x-3",children:[(0,s.jsx)(d.A,{className:"h-8 w-8 text-primary"}),(0,s.jsxs)("div",{children:[(0,s.jsx)("h3",{className:"font-medium",children:e.name}),(0,s.jsx)("p",{className:"text-sm text-muted-foreground",children:(0,g.v7)(e.size)})]})]}),(0,s.jsx)(l.$,{variant:"outline",onClick:()=>{t(null),x(""),b("")},children:"Change File"})]}),(0,s.jsxs)("div",{className:"space-y-4",children:[(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsx)(f.J,{children:"Effect"}),(0,s.jsxs)(p.l6,{value:E,onValueChange:e=>S(e),children:[(0,s.jsx)(p.bq,{children:(0,s.jsx)(p.yv,{placeholder:"Select effect"})}),(0,s.jsx)(p.gC,{children:v.map(e=>(0,s.jsx)(p.eb,{value:e.value,children:e.label},e.value))})]})]}),(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsxs)(f.J,{children:["Intensity (",I,"%)"]}),(0,s.jsx)(m.A,{value:[I],onValueChange:e=>C(e[0]),min:0,max:100,step:1})]})]}),w?(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsx)(i.k,{value:N}),(0,s.jsxs)("p",{className:"text-sm text-center text-muted-foreground",children:["Processing... ",Math.round(N),"%"]})]}):(0,s.jsxs)(l.$,{className:"w-full",onClick:L,disabled:!e,children:[(0,s.jsx)(u.A,{className:"w-4 h-4 mr-2"}),"Apply Effect & Download"]})]}):(0,s.jsx)("div",{className:"flex flex-col items-center justify-center h-full text-muted-foreground",children:(0,s.jsx)("p",{children:"Select an image to start applying effects"})})}),a&&(0,s.jsx)(o.Zp,{className:"p-6 md:col-span-2",children:(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsx)(f.J,{children:"Preview"}),(0,s.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsx)(f.J,{children:"Original"}),(0,s.jsx)("div",{className:"rounded-lg overflow-hidden border bg-background",children:(0,s.jsx)("img",{src:a,alt:"Original",className:"max-w-full h-auto mx-auto",style:{maxHeight:"400px"}})})]}),(0,s.jsxs)("div",{className:"space-y-2",children:[(0,s.jsx)(f.J,{children:"With Effect"}),(0,s.jsx)("div",{className:"rounded-lg overflow-hidden border bg-background",children:(0,s.jsx)("img",{src:y||a,alt:"Preview with effect",className:"max-w-full h-auto mx-auto",style:{maxHeight:"400px"}})})]})]})]})})]})}},92912:(e,t,a)=>{Promise.resolve().then(a.bind(a,74742))},96407:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var s=a(95155),n=a(12115),r=a(83026),o=a(64269);let l=n.forwardRef((e,t)=>{let{className:a,...n}=e;return(0,s.jsxs)(r.bL,{ref:t,className:(0,o.cn)("relative flex w-full touch-none select-none items-center",a),...n,children:[(0,s.jsx)(r.CC,{className:"relative h-2 w-full grow overflow-hidden rounded-full bg-secondary",children:(0,s.jsx)(r.Q6,{className:"absolute h-full bg-primary"})}),(0,s.jsx)(r.zi,{className:"block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"})]})});l.displayName=r.bL.displayName}},e=>{var t=t=>e(e.s=t);e.O(0,[4909,1636,7851,9900,6127,4850,8441,4879,7358],()=>t(92912)),_N_E=e.O()}]);