import{G as x,z as A,R as C,r as I,H as a,I as _,Q as s,O as d,J as i,au as m,N as v,K as P,M as B,ao as N,aw as y,ax as U,u as V}from"./common.modules-8cbc64b2.js";import{G as $,b as z,A as G,bo as R,_ as E}from"./page-activity-ActivityDetail-11971e62.js";import"./page-turntable-assets-d6267459.js";import"./native/index-15fb3a5d.js";import"./en-5d34117c.js";const F={class:"avatar-container"},L={class:"avatar-container-content"},j=["src"],p=!0,D=x({__name:"index",setup(H){const{t:f}=A(),c=$(),n=c.getUserInfo,l=C(),r=I(n.userPhoto);async function g(e){if(r.value=(e+1).toString(),e<0)return V({message:f("tipSelectPls")}),!1;await G(R({userPhoto:(e+1).toString()}))&&(n.userPhoto=(e+1).toString(),c.setUserInfo({...n}),l.go(-1))}return(e,t)=>{const h=a("NavBar"),w=a("van-checkbox"),k=a("van-grid-item"),S=a("van-grid");return v(),_("div",F,[s(h,{title:e.$t("changeAvatar"),"left-arrow":"",onClickLeft:t[0]||(t[0]=b=>d(l).go(-1))},null,8,["title"]),i("div",L,[s(S,{border:!1,"column-num":3,gutter:10},{default:m(()=>[(v(),_(P,null,B(20,(b,o)=>s(k,{onClick:u=>g(o)},{default:m(()=>[i("img",{class:N(r.value===(o+1).toString()?"active":""),src:d(z)("main/Avatar",`${o+1}`)},null,10,j),y(i("div",null,[s(w,{modelValue:p,"onUpdate:modelValue":t[1]||(t[1]=u=>p=u),"icon-size":"20px"})],512),[[U,r.value===(o+1).toString()]])]),_:2},1032,["onClick"])),64))]),_:1})])])}}});const T=E(D,[["__scopeId","data-v-0cd6dac4"],["__file","/usr/local/jenkins-prod/workspace/ar055-india-bdg/src/views/main/Avatar/index.vue"]]);export{T as default};
