PageSourceSearch

https://rice-market.jp/_nuxt/reset-password.7039417a.js

js rice-market.jp collected 2026-09-25 11:47:03 UTC 5,281 bytes, 1 lines download raw bytes

1import{_ as I}from"./nuxt-link.4e1885ef.js";import{_ as M}from"./PasswordField.vue.abf04c90.js";import{d as U,b as A,cp as D,a3 as F,f as B,u as N,g as O,V as R,cq as V,co as K,_ as L}from"./entry.c3e0a1c4.js";import{u as Y}from"./useQuery.2026556e.js";import{a as j}from"./asyncData.3e5a20f0.js";import{u as q,a as z}from"./useFields.117627c5.js";import{a as H}from"./auth.4fb65c3c.js";import"./array.18d8c8c4.js";import{m as Q,a as k,y as X,M as p,N as _,P as i,_ as o,D as r,Y as n,K as Z,ae as G,u as e,Z as f,X as J,a8 as W,a9 as ee,aa as se}from"./swiper-vue.5f831b22.js";import{V as te}from"./VForm.b9eede0a.js";import"./VTextField.1b6c3c79.js";import"./VCounter.5f2238a3.js";import"./index.d9525883.js";import"./common.4b0d27ea.js";const P={password:"",password_confirm:""},oe=d=>{const{$uaaServices:l}=U(),w=A(),{t:g}=w,h=D();j("verify_key",async()=>{try{const{data:a}=await l.unauthorizedUsers.verifyKey(String(d||""));if(!a.valid)throw new Error("invalid-key")}catch{await h({name:"forgot-password",query:{expired:"true"}},{replace:!0})}});const{handleSubmit:S,values:b,meta:x,errors:E,setErrors:$}=q({initialValues:P,validationSchema:Q(H().resetPassword())});z(Object.keys(P));const c=k(!1),u=k(!1),s=k(""),m=k(null),y=S(async({password:a})=>{u.value=!0;const t={password:a,key:d};try{await l.unauthorizedUsers.resetPassword(t),c.value=!0}catch(T){v(T)}finally{u.value=!1}}),v=a=>{if(a.data.status===F.BAD_REQUEST){const t=B(a.data,w);t&&Object.hasOwn(t,"errorMsg")?(s.value=t.errorMsg,m.value=t.errorCode):$(t||{})}else s.value=g("errors.undefined")};return{errorMsg:s,errorCode:m,errors:E,isPending:u,isSuccess:c,meta:x,values:b,submit:y}},ae=""+new URL("tick-success.d04c118d.png",import.meta.url).href,re=""+new URL("tick-error.9c4ba153.png",import.meta.url).href,C=d=>(ee("data-v-d80c176a"),d=d(),se(),d),ie={class:"text-center text-xl text-gray-600 font-weight-semibold","data-test-id":"title"},ne={key:"success",class:"text-center mt-4 notification-wrapper"},de=C(()=>i("img",{with:"188",height:"189",src:ae,alt:"reset-password-success"},null,-1)),le={class:"text-primary mb-5 whitespace-pre-wrap","data-test-id":"success-msg"},ce={key:"error",class:"text-center mt-4 notification-wrapper"},me=C(()=>i("img",{with:"188",height:"189",src:re,alt:"reset-password-error"},null,-1)),pe={key:1,class:"text-error mb-5 whitespace-pre-wrap","data-test-id":"error-msg"},ue={key:"form"},_e={class:"text-sm text-center my-9","data-test-id":"description"},fe={class:"pl-3 mb-2 text-gray-500 text-sm"},we={"data-test-id":"password-description"},ge=X({__name:"reset-password",setup(d){const l=N(),w=Y("key",""),{mobile:g}=O(),{errorMsg:h,errorCode:S,errors:b,isPending:x,meta:E,submit:$,values:c,isSuccess:u}=oe(w.value);return(s,m)=>{const y=I,v=G("i18n-t"),a=M;return p(),_("div",null,[i("h1",ie,o(s.$t("reset_password.title")),1),r(Z,{name:"fade",mode:"out-in"},{default:n(()=>[e(u)?(p(),_("div",ne,[de,i("p",le,o(s.$t("reset_password.reset_success")),1),r(R,{block:"",type:"button",color:"primary","data-test-id":"btn-login",to:e(l)({name:"login"})},{default:n(()=>[f(o(s.$t("common.back_login")),1)]),_:1},8,["to"])])):e(h)?(p(),_("div",ce,[me,e(S)===e(V)?(p(),J(v,{key:0,keypath:`api_errors.${e(V)}`,tag:"p",class:"text-error mb-5 whitespace-pre-wrap","data-test-id":"forgot-password-text",scope:"global"},{here_link:n(()=>[r(y,{to:e(l)({name:"forgot-password"}),class:"font-weight-semibold"},{default:n(()=>[f(o(s.$t("common.here")),1)]),_:1},8,["to"])]),_:1},8,["keypath"])):(p(),_("p",pe,o(e(h)),1)),r(R,{block:"",type:"button",color:"primary",variant:"outlined","data-test-id":"btn-login",to:e(l)({name:"login"})},{default:n(()=>[f(o(s.$t("common.back_login")),1)]),_:1},8,["to"])])):(p(),_("div",ue,[i("p",_e,o(s.$t("reset_password.description")),1),r(te,{onSubmit:W(e($),["prevent"])},{default:n(()=>[i("div",null,[r(a,{modelValue:e(c).password,"onUpdate:modelValue":m[0]||(m[0]=t=>e(c).password=t),modelModifiers:{trim:!0},class:"mb-2",maxlength:"255",name:"new-password","hide-details":"auto","data-test-id":"new-password",focused:!e(g),autofocus:!e(g),label:s.$t("form.label.password"),"error-messages":e(b).password},null,8,["modelValue","focused","autofocus","label","error-messages"]),i("div",fe,[i("ul",we,[i("li",null,o(s.$t("signup.password_info_1")),1),i("li",null,o(s.$t("signup.password_info_2",{symbols:e(K)})),1)])])]),r(a,{modelValue:e(c).password_confirm,"onUpdate:modelValue":m[1]||(m[1]=t=>e(c).password_confirm=t),modelModifiers:{trim:!0},class:"mb-2",maxlength:"255",name:"password-confirmation","data-test-id":"password-confirmation",label:s.$t("form.label.confirm_password"),"error-messages":e(b).password_confirm},null,8,["modelValue","label","error-messages"]),r(R,{block:"",type:"submit",color:"primary","data-test-id":"btn-submit",disabled:!e(E).valid,loading:e(x)},{default:n(()=>[f(o(s.$t("reset_password.submit")),1)]),_:1},8,["disabled","loading"])]),_:1},8,["onSubmit"]),r(v,{keypath:"reset_password.login_link",tag:"p",class:"text-center mt-16","data-test-id":"login-link",scope:"global"},{link:n(()=>
1[r(y,{to:e(l)({name:"login"}),class:"font-weight-semibold"},{default:n(()=>[f(o(s.$t("reset_password.login_text")),1)]),_:1},8,["to"])]),_:1})]))]),_:1})])}}});const Ie=L(ge,[["__scopeId","data-v-d80c176a"]]);export{Ie 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.