PageSourceSearch

https://www.societeamission.com/_nuxt/CAR5aley.js

js societeamission.com collected 2026-10-05 18:21:18 UTC 4,913 bytes, 1 lines download raw bytes

1import{d as B,n as T,$ as D,u as P,ae as $,af as F,ag as M,o as r,c as a,a as o,f as d,w as u,e as E,_ as I,y as t,C as n,k as v,M as O,B as L,z as H,N as U,F as Z,A as G,t as J,m as g,a9 as K,l as h,ah as Q}from"./C4yZnucn.js";import{d as R}from"./DB-vnM2T.js";const W={class:"absolute bg-linear-to-r/hsl from-primary to-primary-hover inset-0 sm:inset-y-0 left-0 flex"},X={class:"bg-background text-text max-w-sm"},Y={class:"relative py-12 px-6"},ee={class:"font-black text-primary text-2xl mb-2 transition-all duration-500 ease-in-out relative"},se={key:0},te={key:0},re=["disabled"],ae={key:0,class:"i-mdi-loading animate-spin"},oe={key:0,class:"mt-4"},ie={key:0,class:"mt-4"},de=B({__name:"reinitialiser-mot-de-passe",setup(ne){const{$api:S}=T(),{changePassword:q}=Q(S),{addToast:z}=D();P({title:"Réinitialiser le mot de passe",meta:[{name:"description",content:"Réinitialisez facilement votre mot de passe pour retrouver l’accès à votre compte Société à Mission et poursuivre vos recherches."},{property:"og:title",content:"Réinitialiser le mot de passe - Société à Mission"},{property:"og:description",content:"Réinitialisez facilement votre mot de passe pour retrouver l’accès à votre compte Société à Mission et poursuivre vos recherches."},{name:"twitter:title",content:"Réinitialiser le mot de passe - Société à Mission"},{name:"twitter:description",content:"Réinitialisez facilement votre mot de passe pour retrouver l’accès à votre compte Société à Mission et poursuivre vos recherches."}]}),R("Default",{page:"Réinitialiser son mot de passe"}),R("Square",{page:"Réinitialiser son mot de passe"},{key:"square",width:1200,height:1200});const x=$({password:F().min(8,{message:"Le mot de passe doit comporter au moins 8 caractères."}).refine(e=>/[A-Z]/.test(e),{message:"Le mot de passe doit contenir au moins une majuscule."}).refine(e=>/[a-z]/.test(e),{message:"Le mot de passe doit contenir au moins une minuscule."}).refine(e=>/[0-9]/.test(e),{message:"Le mot de passe doit contenir au moins un chiffre."}).refine(e=>/[!@#$%^&*()_+\-=[\]{};':"\\|,.<>/?]/.test(e),{message:"Le mot de passe doit contenir au moins un caractère spécial."})}),w=g(!1),l=K({password:void 0}),N=h(()=>{const e=x.safeParse(l);return e.success?{fieldErrors:{},formErrors:[]}:e.error.flatten()}),y=h(()=>{const e=[],s=N.value;return s.formErrors?.length>0&&e.push(...s.formErrors),Object.entries(s.fieldErrors||{}).forEach(([_,i])=>{w.value&&Array.isArray(i)&&i.forEach(p=>{let f=p;if(p.includes("Invalid input: expected string, received undefined"))switch(_){case"email":f="L'email est requis";break;case"password":f="Le mot de passe est requis";break;default:f="Ce champ est requis"}e.push(f)})}),e}),V=h(()=>!x.safeParse(l).success),b=h(()=>y.value.length>0),C=M().query.token,j=M().query.email,k=g(!0),c=g(!1),m=g(!1);async function A(e){if(e.preventDefault(),!V.value){m.value=!0;try{k.value&&(await q(j,C,l.password),m.value=!1,c.value=!0)}catch(s){m.value=!1,z({title:"Error",description:s.message,type:"error"})}}}return(e,s)=>{const _=I;return r(),a("div",W,[o("div",X,[d(_,{to:"/",class:"flex text-sm items-center pt-2 pl-2"},{default:u(()=>[...s[2]||(s[2]=[o("div",{class:"i-mdi-arrow-left-thin text-xl"},null,-1),E(" retour ",-1)])]),_:1}),o("div",Y,[o("h1",ee,[d(v,{name:"slide-fade"},{default:u(()=>[t(c)?n("",!0):(r(),a("div",se," Modifiez votre mot de passe "))]),_:1}),d(v,{name:"slide-fade"},{default:u(()=>[t(c)?(r(),a("div",te," Mot de passe modifié ! ")):n("",!0)]),_:1})]),d(v,{name:"slide-fade"},{default:u(()=>[t(c)?n("",!0):(r(),a("form",{key:0,onSubmit:O(A,["prevent"]),class:"grid grid-cols-1 gap-4 mt-8 mb-4"},[o("div",{class:L(["grid grid-cols-1 gap-2 transition-all duration-300 ease-in-out",t(k)?"max-h-24 opacity-100":"max-h-0 opacity-0"])},[s[3]||(s[3]=o("label",{for:"password","data-required":"true"},"Nouveau mot de passe",-1)),H(o("input",{type:"password",name:"password",id:"password",onBlur:s[0]||(s[0]=i=>w.value=!0),autocomplete:"new-password",placeholder:"8 caractères, symbole, majuscule, chiffre","onUpdate:modelValue":s[1]||(s[1]=i=>t(l).password=i)},null,544),[[U,t(l).password]])],2),o("button",{type:"submit",class:L(["px-2 py-2 rounded font-medium text-center bg-linear-to-r/hsl from-primary to-primary-hover hover:bg-primary-hover text-background flex items-center gap-2 justify-center transition-all duration-300 ease-in-out",t(b)?"cursor-not-allowed opacity-50":""]),disabled:t(b)},[t(m)?(r(),a("div",ae)):n("",!0),s[4]||(s[4]=E(" Modifier ",-1))],10,re)],32))]),_:1}),t(y).length>0?(r(),a("div",oe,[(r(!0),a(Z,null,G(t(y),(i,p)=>(r(),a("p",{key:p,class:"text-error text-sm mb-1"},J(i),1))),128))])):n("",!0),d(v,{name:"slide-fade"},{default:u(()=>[t(c)?(r(),a("p",ie," Votre mot de passe a été modifié avec succès. Vous pouvez l'utiliser dès maintenant pour vous connecter. ")):n("",!0)]),_:1})])])])}}});
1export{de as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.