PageSourceSearch

https://intranet.arrossaires.com/build/assets/UpdateProfileInformationForm-87fe7cf2.js

js arrossaires.com collected 2026-10-01 12:25:16 UTC 4,093 bytes, 1 lines download raw bytes

1import{T as j,d as f,o as d,c as w,w as l,g as n,e as V,a as r,b as t,l as p,P as v,S as B,i as g,f as _,u as s,j as E,n as D,N as F}from"./app-d352f483.js";import{_ as z}from"./ActionMessage-b6354b48.js";import{_ as T}from"./FormSection-7614e1ca.js";import{a as h,_ as S}from"./TextInput-5c7128df.js";import{_ as b}from"./InputLabel-81307e37.js";import{_ as A}from"./PrimaryButton-eab26e9e.js";import{_ as $}from"./SecondaryButton-b9c47e88.js";/* empty css            */import"./SectionTitle-6a1ff836.js";import"./_plugin-vue_export-helper-c27b6911.js";const L={key:0,class:"col-span-6 sm:col-span-4"},R={class:"mt-2"},q=["src","alt"],M={class:"mt-2"},O={class:"col-span-6 sm:col-span-4"},G={class:"col-span-6 sm:col-span-4"},H={key:0},J={class:"text-sm mt-2"},K={class:"mt-2 font-medium text-sm text-green-600"},le={__name:"UpdateProfileInformationForm",props:{user:Object},setup(u){const k=u,o=j({_method:"PUT",name:k.user.name,email:k.user.email,photo:null}),y=f(null),m=f(null),i=f(null),x=()=>{i.value&&(o.photo=i.value.files[0]),o.post(route("user-profile-information.update"),{errorBag:"updateProfileInformation",preserveScroll:!0,onSuccess:()=>P()})},C=()=>{y.value=!0},N=()=>{i.value.click()},I=()=>{const a=i.value.files[0];if(!a)return;const e=new FileReader;e.onload=c=>{m.value=c.target.result},e.readAsDataURL(a)},U=()=>{F.delete(route("current-user-photo.destroy"),{preserveScroll:!0,onSuccess:()=>{m.value=null,P()}})},P=()=>{var a;(a=i.value)!=null&&a.value&&(i.value.value=null)};return(a,e)=>(d(),w(T,{onSubmitted:x},{title:l(()=>e[2]||(e[2]=[n(" Informació del perfil ")])),description:l(()=>e[3]||(e[3]=[n(" Actualitza la informació del teu perfil i la teva foto. ")])),form:l(()=>[a.$page.props.jetstream.managesProfilePhotos?(d(),V("div",L,[r("input",{ref_key:"photoInput",ref:i,type:"file",class:"hidden",onChange:I},null,544),t(b,{for:"photo",value:"Photo"}),p(r("div",R,[r("img",{src:u.user.profile_photo_url,alt:u.user.name,class:"rounded-full h-20 w-20 object-cover"},null,8,q)],512),[[v,!m.value]]),p(r("div",M,[r("span",{class:"block rounded-full w-20 h-20 bg-cover bg-no-repeat bg-center",style:B("background-image: url('"+m.value+"');")},null,4)],512),[[v,m.value]]),t($,{class:"mt-2 mr-2",type:"button",onClick:g(N,["prevent"])},{default:l(()=>e[4]||(e[4]=[n(" Selecciona una nova foto ")])),_:1}),u.user.profile_photo_path?(d(),w($,{key:0,type:"button",class:"mt-2",onClick:g(U,["prevent"])},{default:l(()=>e[5]||(e[5]=[n(" Esborra la foto ")])),_:1})):_("",!0),t(h,{message:s(o).errors.photo,class:"mt-2"},null,8,["message"])])):_("",!0),r("div",O,[t(b,{for:"name",value:"Nom"}),t(S,{id:"name",modelValue:s(o).name,"onUpdate:modelValue":e[0]||(e[0]=c=>s(o).name=c),type:"text",class:"mt-1 block w-full",autocomplete:"name"},null,8,["modelValue"]),t(h,{message:s(o).errors.name,class:"mt-2"},null,8,["message"])]),r("div",G,[t(b,{for:"email",value:"Correu electrònic"}),t(S,{id:"email",modelValue:s(o).email,"onUpdate:modelValue":e[1]||(e[1]=c=>s(o).email=c),type:"email",class:"mt-1 block w-full",autocomplete:"username"},null,8,["modelValue"]),t(h,{message:s(o).errors.email,class:"mt-2"},null,8,["message"]),a.$page.props.jetstream.hasEmailVerification&&u.user.email_verified_at===null?(d(),V("div",H,[r("p",J,[e[7]||(e[7]=n(" El teu correu electrònic no ha estat verificat. ")),t(s(E),{href:a.route("verification.send"),method:"post",as:"button",class:"underline text-sm text-gray-600 hover:text-gray-900 rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500",onClick:g(C,["prevent"])},{default:l(()=>e[6]||(e[6]=[n(" Fes click aquí per rebre un altre correu de verificació ")])),_:1},8,["href"])]),p(r("div",K," Un nou link de verificació ha estat enviat al correu electrònic. ",512),[[v,y.value]])])):_("",!0)])]),actions:l(()=>[t(z,{on:s(o).recentlySuccessful,class:"mr-3"},{default:l(()=>e[8]||(e[8]=[n(" Desat. ")])),_:1},8,["on"]),t(A,{class:D({"opacity-25":s(o).processing}),disabled:s(o).processing},{default:l(()=>e[9]||(e[9]=[n(" Desar ")])),_:1},8,["class","disabled"])]),_:1}))}};export{le 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.