PageSourceSearch

https://pricelink.io/_next/static/chunks/app/(marketing)/(auth)/login/page-b834436cc3d3ea6c.js

js pricelink.io collected 2026-10-01 15:42:24 UTC 11,215 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3205],{29010:function(e,r,t){Promise.resolve().then(t.bind(t,21181))},21181:function(e,r,t){"use strict";t.d(r,{UserLoginForm:function(){return j}});var n=t(27573),o=t(7653),s=t(64387),i=t(14699),a=t(81695),l=t(66592),d=t(14959),c=t(88146),u=t(18113),m=t(4356),f=t(93351),x=t(58489),g=t(60127),p=t(95239),h=t(49877);function v(){let e=(0,a.useRouter)(),r=(0,f.cI)({resolver:(0,u.F)(m.d),defaultValues:{email:"",password:""}});async function t(t){r.trigger();let{email:n,password:o}=t;try{let r=await (0,s.signIn)("credentials",{email:n,password:o,redirect:!1});if(null==r?void 0:r.ok){e.push("/dashboard");return}throw Error("Invalid email or password")}catch(e){r.setError("root",{type:"manual",message:"Invalid email or password"})}}return(0,n.jsx)(x.Form,{...r,children:(0,n.jsxs)("form",{onSubmit:r.handleSubmit(t),className:"grid gap-4",children:[(0,n.jsx)("div",{className:"grid gap-2",children:(0,n.jsx)(x.FormField,{control:r.control,name:"email",render:e=>{let{field:r}=e;return(0,n.jsxs)(x.FormItem,{children:[(0,n.jsx)(x.FormLabel,{children:"Email"}),(0,n.jsx)(x.FormControl,{children:(0,n.jsx)(g.I,{placeholder:"[email protected]",...r})}),(0,n.jsx)(x.FormMessage,{})]})}})}),(0,n.jsx)("div",{className:"grid gap-2",children:(0,n.jsx)(x.FormField,{control:r.control,name:"password",render:e=>{let{field:r}=e;return(0,n.jsxs)(x.FormItem,{children:[(0,n.jsx)(x.FormLabel,{children:(0,n.jsxs)("div",{className:"flex items-center",children:["Password",(0,n.jsx)(c.default,{href:"/forgot-password",className:"ml-auto inline-block text-sm underline text-primary-visible",children:"Forgot your password?"})]})}),(0,n.jsx)(x.FormControl,{children:(0,n.jsx)(g.I,{...r,type:"password"})}),(0,n.jsx)(x.FormMessage,{})]})}})}),(0,n.jsx)(x.FormRootError,{}),(0,n.jsx)(p.z,{type:"submit",className:"w-full",disabled:r.formState.isSubmitting,children:r.formState.isSubmitting?(0,n.jsx)(h.P.spinner,{className:"animate-spin w-5 h-5"}):(0,n.jsx)(n.Fragment,{children:"Login"})})]})})}function b(){let e=(0,a.useSearchParams)().get("error");return(0,n.jsx)(n.Fragment,{children:e&&(0,n.jsx)("div",{className:"text-destructive text-sm mt-2",children:"Email is already linked to local account"})})}function j(e){let{className:r,...t}=e,[a,u]=o.useState(!1);return(0,n.jsxs)(l.Zb,{className:"mx-auto min-w-fit w-[45vw] max-w-lg",children:[(0,n.jsxs)(l.Ol,{children:[(0,n.jsx)(l.ll,{className:"text-2xl",children:"Login"}),(0,n.jsx)(l.SZ,{children:"Login to your account"})]}),(0,n.jsxs)(l.aY,{children:[(0,n.jsxs)("div",{className:"grid gap-4",children:[(0,n.jsx)(v,{}),(0,n.jsxs)(d.z,{onClick:()=>{u(!0),(0,s.signIn)("google",{redirect:!1})},disabled:a,variant:"outline",className:"w-full",children:[a?(0,n.jsx)(i.P.spinner,{className:"mr-2 h-4 w-4 animate-spin"}):(0,n.jsx)(i.P.google,{className:"mr-2 h-4 w-4"})," Login with Google"]}),(0,n.jsx)(o.Suspense,{children:(0,n.jsx)(b,{})})]}),(0,n.jsxs)("div",{className:"mt-4 text-center text-sm",children:["Don't have an account?"," ",(0,n.jsx)(c.default,{href:"/signup",className:"underline",children:"Sign up"})]})]})]})}},4356:function(e,r,t){"use strict";t.d(r,{d:function(){return o},e:function(){return s}});var n=t(41270);let o=n.Ry({email:n.Z_().email("Invalid email address").toLowerCase(),password:n.Z_().min(6,"Password too short").max(100,"Password too long")}),s=n.Ry({email:n.Z_().email("Invalid email address")})},14959:function(e,r,t){"use strict";t.d(r,{d:function(){return l},z:function(){return d}});var n=t(27573),o=t(7653),s=t(8828),i=t(49289),a=t(75298);let l=(0,i.j)("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium 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",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline",orange:"border border-input  hover:bg-accent hover:text-accent-foreground"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),d=o.forwardRef((e,r)=>{let{className:t,variant:o,size:i,asChild:d=!1,...c}=e,u=d?s.g7:"button";return(0,n.jsx)(u,{className:(0,a.cn)(l({variant:o,size:i,className:t})),ref:r,...c})});d.displayName="Button"},66592:function(e,r,t){"use strict";t.d(r,{Ol:function(){return a},SZ:function(){return d},Zb:function(){return i},aY:function(){return c},ll:function(){return l}});var n=t(27573),o=t(7653),s=t(75298);let i=o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)("div",{ref:r,className:(0,s.cn)("rounded-lg border bg-card text-card-foreground shadow-sm",t),...o})});
1i.displayName="Card";let a=o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)("div",{ref:r,className:(0,s.cn)("flex flex-col space-y-1.5 p-6",t),...o})});a.displayName="CardHeader";let l=o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)("h3",{ref:r,className:(0,s.cn)("text-2xl font-semibold leading-none tracking-tight",t),...o})});l.displayName="CardTitle";let d=o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)("p",{ref:r,className:(0,s.cn)("text-sm text-muted-foreground",t),...o})});d.displayName="CardDescription";let c=o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)("div",{ref:r,className:(0,s.cn)("p-6 pt-0",t),...o})});c.displayName="CardContent",o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)("div",{ref:r,className:(0,s.cn)("flex items-center p-6 pt-0",t),...o})}).displayName="CardFooter"},95239:function(e,r,t){"use strict";t.d(r,{d:function(){return l},z:function(){return d}});var n=t(27573),o=t(7653),s=t(8828),i=t(49289),a=t(29986);let l=(0,i.j)("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm 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",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),d=o.forwardRef((e,r)=>{let{className:t,variant:o,size:i,asChild:d=!1,...c}=e,u=d?s.g7:"button";return(0,n.jsx)(u,{className:(0,a.cn)(l({variant:o,size:i,className:t})),ref:r,...c})});d.displayName="Button"},58489:function(e,r,t){"use strict";t.r(r),t.d(r,{Form:function(){return d},FormControl:function(){return p},FormDescription:function(){return h},FormField:function(){return u},FormItem:function(){return x},FormLabel:function(){return g},FormMessage:function(){return v},FormRootError:function(){return b},useFormField:function(){return m}});var n=t(27573),o=t(7653),s=t(8828),i=t(93351),a=t(29986),l=t(59435);let d=i.RV,c=o.createContext({}),u=e=>{let{...r}=e;return(0,n.jsx)(c.Provider,{value:{name:r.name},children:(0,n.jsx)(i.Qr,{...r})})},m=()=>{let e=o.useContext(c),r=o.useContext(f),{getFieldState:t,formState:n}=(0,i.Gc)(),s=t(e.name,n);if(!e)throw Error("useFormField should be used within <FormField>");let{id:a}=r;return{id:a,name:e.name,formItemId:"".concat(a,"-form-item"),formDescriptionId:"".concat(a,"-form-item-description"),formMessageId:"".concat(a,"-form-item-message"),...s}},f=o.createContext({}),x=o.forwardRef((e,r)=>{let{className:t,...s}=e,i=o.useId();return(0,n.jsx)(f.Provider,{value:{id:i},children:(0,n.jsx)("div",{ref:r,className:(0,a.cn)("space-y-2",t),...s})})});x.displayName="FormItem";let g=o.forwardRef((e,r)=>{let{className:t,...o}=e,{error:s,formItemId:i}=m();return(0,n.jsx)(l._,{ref:r,className:(0,a.cn)(s&&"text-destructive",t),htmlFor:i,...o})});g.displayName="FormLabel";let p=o.forwardRef((e,r)=>{let{...t}=e,{error:o,formItemId:i,formDescriptionId:a,formMessageId:l}=m();return(0,n.jsx)(s.g7,{ref:r,id:i,"aria-describedby":o?"".concat(a," ").concat(l):"".concat(a),"aria-invalid":!!o,...t})});p.displayName="FormControl";let h=o.forwardRef((e,r)=>{let{className:t,...o}=e,{formDescriptionId:s}=m();return(0,n.jsx)("p",{ref:r,id:s,className:(0,a.cn)("text-[0.8rem] text-muted-foreground",t),...o})});h.displayName="FormDescription";let v=o.forwardRef((e,r)=>{let{className:t,children:o,...s}=e,{error:i,formMessageId:l}=m(),d=i?String(null==i?void 0:i.message):o;return d?(0,n.jsx)("p",{ref:r,id:l,className:(0,a.cn)("text-[0.8rem] font-medium text-destructive",t),...s,children:d}):null});v.displayName="FormMessage";let b=o.forwardRef((e,r)=>{let{className:t,...o}=e,{errors:s}=(0,i.cl)(),l=s.root;return l?(0,n.jsx)("p",{ref:r,className:(0,a.cn)("text-sm font-medium text-destructive",t),...o,children:l.message}):null});b.displayName="FormRootError"},60127:function(e,r,t){"use strict";t.d(r,{I:function(){return i}});var n=t(27573),o=t(7653),s=t(29986);let i=o.forwardRef((e,r)=>{let{className:t,type:o,...i}=e;return(0,n.jsx)("input",{type:o,className:(0,s.cn)("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",t),ref:r,...i})});i.displayName="Input"},59435:function(e,r,t){"use strict";t.d(r,{_:function(){return d}});var n=t(27573),o=t(7653),s=t(1001),i=t(49289),a=t(29986);let l=(0,i.j)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),d=o.forwardRef((e,r)=>{let{className:t,...o}=e;return(0,n.jsx)(s.Root,{ref:r,className:(0,a.cn)(l(),t),...o})});d.displayName=s.Root.displayName},29986:function(e,r,t){"use strict";t.d(r,{kC:function(){return a},cn:function(){return s},p6:function(){return i}});var n=t(10607),o=t(25579);let s=function(){for(var e=arguments.length,r=Array(e),t=0;t<e;t++)r[t]=arguments[t];return(0,o.m6)((0,n.W)(r))};function i(e,r){return new Date(e).toLocaleDateString("en-US",{month:"long",day:"numeric",year:"numeric",...r?{hour:"2-digit",minute:"2-digit"}:{}})}function a(e,r){return e&&"string"==typeof e?r?e.toLowerCase().split(" ").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "):e.charAt(0).toUpperCase()+e.toLowerCase().slice(1):e}t(44230),t(68571)}},function(e){e.O(0,[1697,9804,461,7754,9606,6340,6519,1270,4387,8712,9877,5298,1293,1528,1744],function(){return e(e.s=29010)}),_N_E=e.O()}]);

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.