PageSourceSearch

https://ubistake.io/js/980.f3305b8a.js

js ubistake.io collected 2026-10-09 00:21:01 UTC 15,443 bytes, 1 lines download raw bytes

1"use strict";(globalThis["webpackChunkubi"]=globalThis["webpackChunkubi"]||[]).push([[980],{8980:(e,l,a)=>{a.r(l),a.d(l,{default:()=>qe});var o=a(3673);const t={class:"q-gutter-y-md q-pt-md"},i=(0,o._)("div",{class:"text-h5"},"Photo",-1),n={class:"row q-mb-md"},r=["src"],s={class:"q-ml-md q-my-auto text-gray"},d=(0,o._)("span",null,"Upload new avatar",-1),u=(0,o._)("span",null,"Delete",-1),m={class:"row q-col-gutter-lg"},c={class:"col-md-4 col-12"},p={class:"col-md-4 col-12"},g={class:"row"},h=(0,o._)("div",{class:"text-h5 q-mb-md q-mt-lg"},"Email",-1);function f(e,l,a,f,C,v){const w=(0,o.up)("q-icon"),q=(0,o.up)("q-avatar"),b=(0,o.up)("q-input"),D=(0,o.up)("q-btn"),y=(0,o.up)("q-form"),k=(0,o.up)("ChangeEmail"),E=(0,o.up)("UploadAvatarDialog"),_=(0,o.up)("q-dialog"),x=(0,o.up)("DeleteAvatarDialog");return(0,o.wg)(),(0,o.iD)("div",null,[(0,o._)("div",t,[i,(0,o._)("div",n,[(0,o.Wm)(q,{color:"grey",size:"100px",class:"avatar q-mb-sm"},{default:(0,o.w5)((()=>[e.userAvatar?((0,o.wg)(),(0,o.iD)("img",{key:0,src:e.userAvatar,alt:""},null,8,r)):((0,o.wg)(),(0,o.j4)(w,{key:1,name:"person",color:"white"}))])),_:1}),(0,o._)("div",s,[(0,o._)("div",{onClick:l[0]||(l[0]=()=>e.uploadAvatarDialog=!0),class:"row q-mb-sm q-gutter-x-sm cursor-pointer"},[(0,o.Wm)(w,{name:"add",class:"q-my-auto"}),d]),(0,o._)("div",{onClick:l[1]||(l[1]=()=>e.deleteAvatarDialog=!0),class:"row q-gutter-x-sm cursor-pointer"},[(0,o.Wm)(w,{name:"delete",class:"q-my-auto"}),u])])]),(0,o.Wm)(b,{type:"file","aria-hidden":"",style:{display:"none"},accept:"image/png, image/jpeg"}),(0,o.Wm)(y,{class:"q-gutter-y-md",onSubmit:e.changeNames},{default:(0,o.w5)((()=>[(0,o._)("div",m,[(0,o._)("div",c,[(0,o.Wm)(b,{modelValue:e.profile.fullName,"onUpdate:modelValue":l[2]||(l[2]=l=>e.profile.fullName=l),"lazy-rules":"",rules:[e=>e&&e.length>0||"Required field"],label:"Full name",borderless:"",class:"grayInput grayInputColor q-px-md inputWithRules inputSettings",type:"text","hide-bottom-space":"",autocomplete:"username"},null,8,["modelValue","rules"])]),(0,o._)("div",p,[(0,o.Wm)(b,{modelValue:e.profile.name,"onUpdate:modelValue":l[3]||(l[3]=l=>e.profile.name=l),"lazy-rules":"",rules:[e=>e&&e.length>0||"Required field"],label:"Profile name",borderless:"",class:"grayInput grayInputColor q-px-md inputWithRules inputSettings",type:"text","hide-bottom-space":"",autocomplete:"username"},null,8,["modelValue","rules"])])]),(0,o._)("div",g,[(0,o.Wm)(D,{type:"submit",loading:e.changeNamesLoading,label:"Save",color:"primary",class:"roundBtn paddingBtn"},null,8,["loading"])])])),_:1},8,["onSubmit"]),h,(0,o.Wm)(k)]),(0,o.Wm)(_,{modelValue:e.uploadAvatarDialog,"onUpdate:modelValue":l[4]||(l[4]=l=>e.uploadAvatarDialog=l)},{default:(0,o.w5)((()=>[(0,o.Wm)(E,{onCloseDialog:e.closeUploadAvatarDialog,profileId:e.profile.id},null,8,["onCloseDialog","profileId"])])),_:1},8,["modelValue"]),(0,o.Wm)(_,{modelValue:e.deleteAvatarDialog,"onUpdate:modelValue":l[5]||(l[5]=l=>e.deleteAvatarDialog=l)},{default:(0,o.w5)((()=>[(0,o.Wm)(x,{onCloseDialog:e.closeDeleteAvatarDialog,profileId:e.profile.id},null,8,["onCloseDialog","profileId"])])),_:1},8,["modelValue"])])}var C=a(1959),v=a(993),w=a(2323);const q={key:0},b=(0,o._)("p",{class:"text-center q-my-lg"},[(0,o.Uk)(" Please upload a real photo of yourself so that users can get to know You. We accept files in "),(0,o._)("b",null,"JPG"),(0,o.Uk)(" or "),(0,o._)("b",null,"PNG"),(0,o.Uk)(". Maximum photo size "),(0,o._)("b",null,"500 KB"),(0,o.Uk)(". ")],-1),D={class:"row"},y={class:"row q-mt-md justify-center"},k={key:2,class:"text-red text-center q-mt-md"};function E(e,l,a,t,i,n){const r=(0,o.up)("q-icon"),s=(0,o.up)("q-card-section"),d=(0,o.up)("q-btn"),u=(0,o.up)("cropper"),m=(0,o.up)("q-card");return(0,o.wg)(),(0,o.j4)(m,{class:"dialogCard q-pa-md"},{default:(0,o.w5)((()=>[(0,o.Wm)(r,{name:"close",class:"rightTopAngle cursor-pointer",size:"md",onClick:l[0]||(l[0]=l=>e.$emit("closeDialog"))}),(0,o.Wm)(s,{class:"text-h3 text-center"},{default:(0,o.w5)((()=>[(0,o.Uk)("Upload new photo")])),_:1}),e.base64data?((0,o.wg)(),(0,o.iD)(o.HY,{key:1},[(0,o.Wm)(u,{class:"cropper",src:e.base64data,"stencil-component":e.$options.components.CircleStencil,"stencil-props":{class:"customStencil",aspectRatio:1},backgroundClass:"backgroundClass",onChange:e.cropChange},null,8,["src","stencil-component","onChange"]),(0,o._)("div",y,[(0,o.Wm)(d,{onClick:l[2]||(l[2]=l=>e.$emit("closeDialog")),label:"Cancel",color:"primary",class:"roundBtn paddingBtn q-mr-md"}),(0,o.Wm)(d,{onClick:e.changeAvatar,loading:e.loading,label:"Save and continue",color:"primary",class:"roundBtn paddingBtn"},null,8,["onClick","loading"])])],64)):((0,o.wg)(),(0,o.iD)("div",q,[b,(0,o._)("input",{ref:"fileUploader",type:"file","aria-hidden":"",style:{display:"none"},accept:"image/png, image/jpeg",onChange:l[1]||(l[1]=(...l)=>e.selected&&e.selected(...l))},null,544),(0,o._)("div",D,[(0,o.Wm)(d,{onClick:e.selectFile,label:"Select File",color:"primary",class:"roundBtn paddingBtn q-mx-auto"},null,8,["onClick"])])])),e.error?((0,o.wg)(),(0,o.iD)("p",k,(0,w.zw)(e.error),1)):(0,o.kq)("",!0)])),_:1})}var _=a(6041),x=a(6868),W=a.n(x);const U=(0,o.aZ)({name:"UploadAvatarDialog",props:["profileId"],components:{Cropper:_.fl,CircleStencil:_.xq},setup(){const e=(0,C.iH)(null),l=(0,C.iH)(""),a=(0,C.iH)(null),o=(0,C.iH)(null),t=(0,C.iH)(!1);return{fileUploader:e,base64data:l,croppedImage:a,error:o,loading:t}},methods:{selectFile(){this.fileUploader.click()},selected(e){if(this.fileUploader.files[0].size>5e5)W()(this.$q,"negative","File size is too big"),this.fileUploader.value=null;else{const e=new FileReader;e.onloadend=()=>{this.base64data=e.result}
1,e.readAsDataURL(this.fileUploader.files[0])}},cropChange({canvas:e}){this.croppedImage=e.toDataURL()},changeAvatar(){this.loading=!0,v.T.uploadAvatar(this.croppedImage).then((e=>{e&&v.T.changeAvatar(this.profileId,e).then((e=>{v.T.getFullInfo(this.profileId).then((e=>{this.loading=!1,this.$emit("closeDialog")}))}))})).catch((e=>{this.error=e,this.loading=!1}))}}});var I=a(4260),V=a(151),A=a(4554),Z=a(5589),H=a(2165),N=a(7518),O=a.n(N);const B=(0,I.Z)(U,[["render",E]]),Q=B;O()(U,"components",{QCard:V.Z,QIcon:A.Z,QCardSection:Z.Z,QBtn:H.Z});const S=(0,o._)("p",{class:"text-center text-h5 q-my-lg"}," Are you sure you want to delete your photo? ",-1),F={class:"row justify-center"},T={key:0,class:"text-red text-center q-mt-md"};function $(e,l,a,t,i,n){const r=(0,o.up)("q-icon"),s=(0,o.up)("q-card-section"),d=(0,o.up)("q-btn"),u=(0,o.up)("q-card");return(0,o.wg)(),(0,o.j4)(u,{class:"dialogCard q-pa-md"},{default:(0,o.w5)((()=>[(0,o.Wm)(r,{name:"close",class:"rightTopAngle cursor-pointer",size:"md",onClick:l[0]||(l[0]=l=>e.$emit("closeDialog"))}),(0,o.Wm)(s,{class:"text-h3 text-center"},{default:(0,o.w5)((()=>[(0,o.Uk)("Delete photo")])),_:1}),(0,o._)("div",null,[S,(0,o._)("div",F,[(0,o.Wm)(d,{onClick:e.deletePhoto,loading:e.loading,label:"Delete",color:"primary",class:"roundBtn paddingBtn q-mr-md"},null,8,["onClick","loading"]),(0,o.Wm)(d,{onClick:l[1]||(l[1]=l=>e.$emit("closeDialog")),label:"Cancel","text-color":"primary",outline:"",class:"roundBtn paddingBtn"})])]),e.error?((0,o.wg)(),(0,o.iD)("p",T,(0,w.zw)(e.error),1)):(0,o.kq)("",!0)])),_:1})}const z=(0,o.aZ)({name:"DeleteAvatarDialog",props:["profileId"],setup(){const e=(0,C.iH)(null),l=(0,C.iH)(!1);return{error:e,loading:l}},methods:{deletePhoto(){this.loading=!0,v.T.changeAvatar(this.profileId,null).then((e=>{v.T.getFullInfo(this.profileId).then((e=>{this.loading=!1,this.$emit("closeDialog")}))})).catch((e=>{this.error=e}))}}}),R=(0,I.Z)(z,[["render",$]]),L=R;O()(z,"components",{QCard:V.Z,QIcon:A.Z,QCardSection:Z.Z,QBtn:H.Z});const P={class:"row q-col-gutter-lg"},j={class:"col-md-auto col-12"},Y={class:"col-md-4 col-12"},G=(0,o._)("br",null,null,-1),J=(0,o._)("br",null,null,-1),K={class:"row"};function M(e,l,a,t,i,n){const r=(0,o.up)("q-input"),s=(0,o.up)("q-tooltip"),d=(0,o.up)("q-btn"),u=(0,o.up)("ConfirmEmailCodesDialog"),m=(0,o.up)("q-dialog"),c=(0,o.up)("q-form");return(0,o.wg)(),(0,o.j4)(c,{class:"q-gutter-y-md",onSubmit:e.changeEmail},{default:(0,o.w5)((()=>[(0,o._)("div",P,[(0,o._)("div",j,[(0,o.Wm)(r,{modelValue:e.email,"onUpdate:modelValue":l[0]||(l[0]=l=>e.email=l),label:"Current email",readonly:"",borderless:"",class:"grayInput grayInputColor q-px-md inputWithRules inputSettings","hide-bottom-space":""},null,8,["modelValue"])]),(0,o._)("div",Y,[(0,o.Wm)(r,{ref:"newEmailRef",modelValue:e.newEmail,"onUpdate:modelValue":l[1]||(l[1]=l=>e.newEmail=l),"lazy-rules":"",rules:[(e,l)=>l.email(e)||"Please enter a valid email address"],label:"New email",borderless:"",class:"grayInput grayInputColor q-px-md inputWithRules inputSettings",type:"email","hide-bottom-space":""},{default:(0,o.w5)((()=>[(0,o.Wm)(s,{anchor:"top left",self:"bottom left",offset:[0,8]},{default:(0,o.w5)((()=>[(0,o.Uk)(" A confirmation codes will be sent to"),G,(0,o.Uk)("your new address and your"),J,(0,o.Uk)("old address. ")])),_:1})])),_:1},8,["modelValue","rules"])])]),(0,o._)("div",K,[(0,o.Wm)(d,{type:"submit",loading:e.changeEmailLoading,label:"Change",color:"primary",class:"roundBtn paddingBtn"},null,8,["loading"])]),(0,o.Wm)(m,{modelValue:e.confirmCodesDialog,"onUpdate:modelValue":l[2]||(l[2]=l=>e.confirmCodesDialog=l)},{default:(0,o.w5)((()=>[(0,o.Wm)(u,{onCloseDialog:e.closeConfirmCodesDialog},null,8,["onCloseDialog"])])),_:1},8,["modelValue"])])),_:1},8,["onSubmit"])}const X=(0,o._)("p",{class:"text-center q-mb-lg"},[(0,o.Uk)(" To confirm the change of email we sent the"),(0,o._)("br"),(0,o.Uk)(" codes to the current and new email addresses."),(0,o._)("br"),(0,o.Uk)(" Enter the codes from the emails. ")],-1),ee=(0,o._)("p",{class:"text-center text-h5"},"2. Code from the new email:",-1),le={key:0,class:"text-red text-center"},ae=(0,o._)("p",{class:"text-center text-h5"},"1. Code from the old email:",-1),oe={key:0,class:"text-red text-center"},te={class:"column q-mt-lg"};function ie(e,l,a,t,i,n){const r=(0,o.up)("q-icon"),s=(0,o.up)("q-card-section"),d=(0,o.up)("VOtpInput"),u=(0,o.up)("q-btn"),m=(0,o.up)("q-form"),c=(0,o.up)("q-card");return(0,o.wg)(),(0,o.j4)(c,{class:"dialogCard q-pa-md"},{default:(0,o.w5)((()=>[(0,o.Wm)(r,{name:"close",class:"rightTopAngle cursor-pointer",size:"md",onClick:l[0]||(l[0]=l=>e.$emit("closeDialog"))}),(0,o.Wm)(s,{class:"text-h3 text-center"},{default:(0,o.w5)((()=>[(0,o.Uk)("Change Email")])),_:1}),(0,o._)("div",null,[X,(0,o.Wm)(m,{onSubmit:e.submit},{default:(0,o.w5)((()=>[e.confirmedCodeFromOldEmail?((0,o.wg)(),(0,o.iD)(o.HY,{key:0}
1,[ee,(0,o.Wm)(d,{class:"otp-input-wrapper",ref:"newEmailCodeInput","input-classes":"otp-input q-mx-auto",conditionalClass:["one","two","three","four"],separator:"","num-inputs":5,value:e.newEmailCodeValue,"onUpdate:value":l[1]||(l[1]=l=>e.newEmailCodeValue=l),onOnChange:e.validateNew,"should-auto-focus":!0,placeholder:["1","2","3","4","5"]},null,8,["value","onOnChange"]),e.errorNew?((0,o.wg)(),(0,o.iD)("p",le,(0,w.zw)(e.errorNew),1)):(0,o.kq)("",!0)],64)):((0,o.wg)(),(0,o.iD)(o.HY,{key:1},[ae,(0,o.Wm)(d,{class:"otp-input-wrapper",ref:"oldEmailCodeInput","input-classes":"otp-input q-mx-auto",conditionalClass:["one","two","three","four"],separator:"","num-inputs":5,value:e.oldEmailCodeValue,"onUpdate:value":l[2]||(l[2]=l=>e.oldEmailCodeValue=l),"should-auto-focus":!0,onOnChange:e.validateOld,placeholder:["1","2","3","4","5"]},null,8,["value","onOnChange"]),e.errorOld?((0,o.wg)(),(0,o.iD)("p",oe,(0,w.zw)(e.errorOld),1)):(0,o.kq)("",!0)],64)),(0,o._)("div",te,[(0,o.Wm)(u,{type:"submit",loading:e.loading,label:e.confirmedCodeFromOldEmail?"Ok":"Next",color:"primary",class:"roundBtn paddingBtn q-mx-auto q-mb-sm"},null,8,["loading","label"]),(0,o.Wm)(u,{onClick:e.resendCodes,label:"I have not received a mail","text-color":"primary",borderless:"",class:"roundBtn paddingBtn q-mx-auto"},null,8,["onClick"])])])),_:1},8,["onSubmit"])])])),_:1})}var ne=a(5261);const re=(0,o.aZ)({name:"ConfirmEmailCodesDialog",components:{VOtpInput:ne.Z},setup(){const e=(0,C.iH)(!1),l=(0,C.iH)(null),a=(0,C.iH)(""),o=(0,C.iH)(null),t=(0,C.iH)(""),i=(0,C.iH)(null),n=(0,C.iH)(null),r=(0,C.iH)(!1);return{newEmailCodeInput:l,newEmailCodeValue:a,oldEmailCodeInput:o,oldEmailCodeValue:t,confirmedCodeFromOldEmail:e,errorNew:i,errorOld:n,loading:r}},methods:{validateNew(e){this.errorNew=null},validateOld(e){this.errorOld=null},submit(){if(this.loading=!0,this.oldEmailCodeValue.length<5)return this.errorOld="Required field",void(this.loading=!1);if(this.confirmedCodeFromOldEmail){if(this.newEmailCodeValue.length<5)return this.errorNew="Required field",void(this.loading=!1);v.T.confirmEmailChange({confirmationCode:this.oldEmailCodeValue,confirmationCodeNew:this.newEmailCodeValue}).then((e=>{this.loading=!1,this.$store.dispatch("LOGOUT")})).catch((e=>{W()(this.$q,"negative","Error",e.response.data),this.confirmedCodeFromOldEmail=!1,this.newEmailCodeValue="",this.oldEmailCodeValue="",this.loading=!1}))}else this.confirmedCodeFromOldEmail=!0,this.loading=!1},resendCodes(){this.confirmedCodeFromOldEmail=!1,this.newEmailCodeValue="",this.oldEmailCodeValue="",this.errorNew=null,this.errorOld=null,v.T.resendConfirmationCode().then((e=>{this.$q.notify({color:"blue",message:"The codes have been resent",position:"top-right"})})).catch((e=>W()(this.$q,"negative","Error",e)))}}});var se=a(8689);const de=(0,I.Z)(re,[["render",ie]]),ue=de;O()(re,"components",{QCard:V.Z,QIcon:A.Z,QCardSection:Z.Z,QForm:se.Z,QBtn:H.Z});const me=(0,o.aZ)({name:"SettingsPersonal",components:{ConfirmEmailCodesDialog:ue},setup(){const e=(0,C.iH)(""),l=(0,C.iH)(""),a=(0,C.iH)(!1),o=(0,C.iH)(!1);return{newEmailRef:e,newEmail:l,changeEmailLoading:a,confirmCodesDialog:o}},computed:{email(){return this.$store.getters.profile?.email||JSON.parse(sessionStorage.getItem("profile"))?.email}},methods:{changeEmail(){this.changeEmailLoading=!0,v.T.changeEmail(this.newEmail).then((e=>{this.changeEmailLoading=!1,this.confirmCodesDialog=!0})).catch((e=>{this.changeEmailLoading=!1,W()(this.$q,"negative","Error",e)}))},closeConfirmCodesDialog(){this.confirmCodesDialog=!1}}});var ce=a(4689),pe=a(5363),ge=a(6778);const he=(0,I.Z)(me,[["render",M]]),fe=he;O()(me,"components",{QForm:se.Z,QInput:ce.Z,QTooltip:pe.Z,QBtn:H.Z,QDialog:ge.Z});const Ce=(0,o.aZ)({name:"SettingsPersonal",components:{ChangeEmail:fe,UploadAvatarDialog:Q,DeleteAvatarDialog:L},setup(){const e=(0,C.iH)(""),l=(0,C.iH)(""),a=(0,C.iH)(!1),o=(0,C.iH)(!1),t=(0,C.iH)(!1),i=(0,C.iH)(!1);return{fullName:e,profileName:l,changeNamesLoading:a,isTwoFADialogOpened:o,uploadAvatarDialog:t,deleteAvatarDialog:i}},computed:{userAvatar(){let e="https://api.ubikiri.com";return this.profile?.avatarUrl?`${e}/Files?fileName=${this.profile?.avatarUrl}`:void 0},profile(){return this.$store.getters.profile}},methods:{closeUploadAvatarDialog(){this.uploadAvatarDialog=!1},closeDeleteAvatarDialog(){this.deleteAvatarDialog=!1},changeNames(){this.changeNamesLoading=!0,v.T.putPersonal({id:this.profile.id,fullName:this.profile.fullName,name:this.profile.name,documents:[]}).then((e=>{this.updateProfileData(),this.changeNamesLoading=!1,W()(this.$q,"positive","Success")})).catch((e=>{this.changeNamesLoading=!1,W()(this.$q,"negative","Error",e.response.data)}))},updateProfileData(){v.T.getFullInfo(this.profile.id)}},created(){}});var ve=a(5096);const we=(0,I.Z)(Ce,[["render",f]]),qe=we;O()(Ce,"components",{QAvatar:ve.Z,QIcon:A.Z,QInput:ce.Z,QForm:se.Z,QBtn:H.Z,QDialog:ge.Z})}}]);

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.