PageSourceSearch

https://www.instamotion.com/_next/static/chunks/4459.fa14ae9cdc0e40a2.js

js instamotion.com collected 2026-10-04 06:06:44 UTC 4,423 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4459],{4459:(e,t,a)=>{a.r(t),a.d(t,{AddDamageModal:()=>A});var o=a(43231);let d=(0,a(97687).w)({d:"M0,12a1.5,1.5,0,0,0,1.5,1.5h8.75a.25.25,0,0,1,.25.25V22.5a1.5,1.5,0,0,0,3,0V13.75a.25.25,0,0,1,.25-.25H22.5a1.5,1.5,0,0,0,0-3H13.75a.25.25,0,0,1-.25-.25V1.5a1.5,1.5,0,0,0-3,0v8.75a.25.25,0,0,1-.25.25H1.5A1.5,1.5,0,0,0,0,12Z",displayName:"AddIcon"});var r=a(22620),i=a(26734),l=a(98821),n=a(63806),c=a(53812),h=a(81883),u=a(3574),s=a(33651),g=a(80139),m=a(670),p=a(24582),f=a(21462),_=a(50289),S=a(16499),Y=a(19782);let I=({photo:e,setPhoto:t,onNewPhotoUploaded:a,placeholderTitle:d,className:r,name:i,upload:l})=>{let n=(0,f.useMemo)(()=>e.loadedIdFromStorageBucket?(0,_.uN)(e.loadedIdFromStorageBucket,{width:400,height:400}):void 0,[e]),c=e.fileBase64||e.loadedIdFromStorageBucket&&n||"";return(0,o.Y)(Y.B,{hasImage:!!c,className:r,children:(0,o.FD)(S.z,{name:i,photo:e,setPhoto:t,onNewPhotoUploaded:a,upload:l,isDamage:!0,children:[c&&(0,o.Y)("img",{src:c,alt:e.photoStorage?.id}),!c&&(0,o.FD)(m.Or,{children:[(0,o.Y)(m.GX,{children:d??(0,o.Y)(u.x6,{id:"feature.photoguide.add_photo"})}),(0,o.Y)(p.U,{width:5,height:5,color:"blue.400"})]})]})})};var B=a(35630),k=a(21465),b=a(2641),v=a(88014),w=a(64280),y=a(55309),F=a(67198),x=a(81168),z=a(9432),D=a(31064);let N=(0,c.A)(r.az,{target:"e4exrdd0"})("	",Y.B,",",m.Or,"{height:24.5rem;}"),H={fontSize:D.w.fontSize.desktop.text2,lineHeight:"2.4rem",letterSpacing:"0.5px",fontWeight:"700",color:"gray.800"},A=({photo:e,setPhoto:t,upload:a,onRemove:c,onPhotoCommitted:m})=>{let[p,_]=(0,f.useState)(e),S=(0,f.useCallback)(e=>{_(e),t(e)},[t]),Y=(0,k.H)(),D=(0,w.v)(),{mutateAsync:A}=(0,g.z7)(s.Qy),[M,V]=(0,f.useState)(!1),[C,P]=(0,f.useState)(!1),E=(0,z.mN)({defaultValues:(e=>(0,f.useMemo)(()=>({desc:e.description,photo:{fileBase64:"",file:null,photoStorage:null,loadedIdFromStorageBucket:null}}),[e.description]))(p),reValidateMode:"onBlur"}),R=()=>{C&&m()},L=()=>{R(),Y()},O=E.handleSubmit((({setPhoto:e,setIsLoading:t,photo:a,auctionId:o,onCloseModal:d})=>{let r=(0,w.v)(),{mutateAsync:i}=(0,g.z7)(s.je),l=(0,F.d)();return async n=>{if(n.desc&&a.photoStorage){t(!0);try{await i({auctionId:o,photoId:a.photoStorage.storage_service_id,type:"damage-other",description:n.desc}),e(e=>({...e,description:n.desc}))}catch(e){l(e),n.desc?.length>255?r.error({title:h.Ru._("feature.car_swap.auction_error.max_length_damage_description")}):r.error({title:h.Ru._("unknown_error")})}finally{t(!1),d()}}else d()}})({setPhoto:S,setIsLoading:V,photo:p,auctionId:a.auctionId,onCloseModal:L})),T=p?.fileBase64||p?.loadedIdFromStorageBucket,U=(0,F.d)(),W=async()=>{try{V(!0),(p.photoStorage||p.loadedIdFromStorageBucket)&&await A({auctionId:a.auctionId,photoId:p?.loadedIdFromStorageBucket||p?.photoStorage?.storage_service_id||""}),S(()=>({fileBase64:"",file:null,photoStorage:null,description:"",loadedIdFromStorageBucket:null})),c(),L()}catch(e){U(e),D.error({title:h.Ru._("unknown_error")})}finally{V(!1)}};return(0,o.Y)(b.a,{onClose:R,dataTestId:"general.modal.car-swap-modal",children:(0,o.FD)(v.$,{padding:{base:8,MD:12},children:[(0,o.Y)(i.E,{fontSize:{base:"2rem",lg:"2.4rem"},lineHeight:"3.2rem",fontWeight:"700",paddingBottom:"3.2rem",children:(0,o.Y)(u.x6,{id:"feature.photoguide.damage_title"})}),(0,o.Y)(z.Op,{...E,children:(0,o.FD)("form",{onSubmit:O,children:[(0,o.Y)(N,{paddingBottom:"2.4rem",children:(0,o.Y)(I,{photo:p,setPhoto:S,onNewPhotoUploaded:()=>P(!0),upload:a,name:"damage-other",placeholderTitle:(0,o.Y)(u.x6,{id:"feature.photoguide.add_damage"})})}),(0,o.Y)(r.az,{paddingBottom:"3.2rem",children:(0,o.Y)(y.V,{maxLength:255,label:(0,o.Y)(i.E,{...H,children:(0,o.Y)(u.x6,{id:"feature.photoguide.damage_desc_label"})}),name:"desc",placeholder:h.Ru._("feature.photoguide.damage_desc_input")})}),(0,o.FD)(l.o,{children:[T&&(0,o.Y)(n.K,{"aria-label":"next-button",variant:"tertiary",colorScheme:"danger",icon:(0,o.Y)(x.z,{color:"red.600"}),onClick:W}),(0,o.Y)(B.ye,{type:"submit",isLoading:M,marginLeft:T?"3.2rem":void 0,size:"lg",width:"full",disabled:!T,leftIcon:T?void 0:(0,o.Y)(d,{}),children:(0,o.Y)(u.x6,{id:"feature.photoguide.save_damage"})})]})]})})]})})}},81168:(e,t,a)=>{a.d(t,{z:()=>i});var o=a(43231),d=a(6071);let r={src:"/_next/static/media/Trash16.1af0f829.svg",height:16,width:16,blurWidth:0,blurHeight:0},i=function(e){return(0,o.Y)(d.I,{...e,"data-icon-id":"trash16",svg:r})}}}]);

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.