1"use strict";(self.webpackChunkingo_web=self.webpackChunkingo_web||[]).push([[1655],{96361:(e,i,r)=>{r.d(i,{A:()=>h});var t=r(65043),l=r(74117),n=r(96446),s=r(85865),o=r(82065),a=r(96745),d=r(33900),c=r(68732),u=r(70579);const p={root:{width:"100%",p:4,bgcolor:"grey.50",borderRadius:3},priceView:{height:48,display:"flex",justifyContent:"space-between",alignItems:"center",bgcolor:"grey.100",borderRadius:2,px:1.5},priceViewHover:{cursor:"pointer","&:hover":{bgcolor:"grey.200"}},showMoreIcon:e=>({transform:e?"rotate(180deg)":"rotate(0)"}),riskView:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center",gap:2},price:{width:"100%",display:"flex",alignItems:"center",gap:.5}};function m(e){let{planPrice:i,planName:r,price:m,risks:h,isLoading:v}=e;const{t:x}=(0,l.Bd)(),b=(0,d.A)(),[g,f]=(0,t.useState)(!1);return(0,u.jsxs)(n.A,{sx:p.root,children:[(0,u.jsx)(s.A,{mb:3,variant:"body2",fontWeight:"bold",children:x("titles.insurancePremium")}),(0,u.jsxs)(n.A,{sx:{...p.priceView,...null!==h&&void 0!==h&&h.length||i?p.priceViewHover:{}},onClick:()=>{f((e=>!e))},children:[(0,u.jsxs)(n.A,{sx:p.price,children:[(0,u.jsx)(o.h,{}),(0,u.jsx)(s.A,{variant:"h4",children:null===m||void 0===m?void 0:m.toLocaleString()})]}),v&&(0,u.jsx)(c.A,{}),(!(null===h||void 0===h||!h.length)||i)&&(0,u.jsx)(n.A,{sx:p.showMoreIcon(g),children:(0,u.jsx)(a.h,{})})]}),g&&(0,u.jsxs)(u.Fragment,{children:[i&&(0,u.jsxs)(n.A,{sx:p.riskView,children:[(0,u.jsx)(s.A,{variant:"body2",children:r||x("titles.insurancePremium")}),(0,u.jsx)(s.A,{variant:"body2",children:i.toLocaleString()})]}),null===h||void 0===h?void 0:h.map((e=>{var i;return(0,u.jsxs)(n.A,{sx:p.riskView,children:[(0,u.jsx)(s.A,{variant:"body2",children:e.name[b]}),(0,u.jsx)(s.A,{variant:"body2",children:null===(i=e.price)||void 0===i?void 0:i.toLocaleString()})]},e.id)}))]})]})}const h=(0,t.memo)(m)},71655:(e,i,r)=>{r.r(i),r.d(i,{default:()=>w});var t=r(65043),l=r(73216),n=r(74117),s=r(80078),o=r(99609),a=r(96361),d=r(60363),c=r(24858),u=r(11906),p=r(96446),m=r(52974),h=r(59945),v=r(27401),x=r(32890),b=r(22563),g=r(70579);const f={root:{display:"flex",flexDirection:"column",gap:4}};function j(e){var i,r,t,l;let{onSubmit:o,initialState:a}=e;const{t:d}=(0,n.Bd)(),{form:j}=(0,s.A)(),{register:A,formState:{errors:y},handleSubmit:w}=(0,c.mN)({reValidateMode:"onChange",defaultValues:a});return(0,g.jsx)("form",{onSubmit:w(o),children:(0,g.jsxs)(p.A,{sx:f.root,children:[(0,g.jsx)(m.A,{fullWidth:!0,label:d("labels.animalType"),defaultValue:null===a||void 0===a?void 0:a.type,error:!(null===y||void 0===y||!y.type),inputRef:A("type",x.Fy),helperText:d((null===(i=y.type)||void 0===i?void 0:i.message)||""),options:b.C}),(0,g.jsx)(h.A,{fullWidth:!0,label:d("labels.firstName"),error:!(null===y||void 0===y||!y.name),inputRef:A("name",x.Fy),helperText:d((null===(r=y.name)||void 0===r?void 0:r.message)||"")}),(0,g.jsx)(h.A,{fullWidth:!0,label:d("labels.passport"),error:!(null===y||void 0===y||!y.passportNumber),inputRef:A("passportNumber",x.Fy),helperText:d((null===(t=y.passportNumber)||void 0===t?void 0:t.message)||"")}),!j.risks.some((e=>{let{key:i}=e;return"PACKAGE _CHIP"===i}))&&(0,g.jsx)(h.A,{fullWidth:!0,label:d("labels.chipNumber"),error:!(null===y||void 0===y||!y.chipNumber),inputRef:A("chipNumber",x.Fy),helperText:d((null===(l=y.chipNumber)||void 0===l?void 0:l.message)||"")}),(0,g.jsx)(u.A,{fullWidth:!0,variant:"primary",size:"large",type:"submit",endIcon:(0,g.jsx)(v.h,{}),children:d("buttons.continue")})]})})}const A=(0,t.memo)(j);function y(){var e;const{t:i}=(0,n.Bd)(),{priceData:r,isPriceLoading:c}=(0,s.A)(),u=(0,l.Zp)(),p=(0,l.zy)(),m=(0,t.useCallback)((e=>{u("../".concat(d._h.PAYMENT),{state:{petDetails:e,...p.state}})}),[u,p]);return(0,g.jsx)(o.A,{padding:4,form:(0,g.jsx)(A,{initialState:null===(e=p.state)||void 0===e?void 0:e.petDetails,onSubmit:m}),details:(0,g.jsx)(a.A,{planPrice:null===r||void 0===r?void 0:r.insurancePrice,planName:i("petInsurance.title"),price:null===r||void 0===r?void 0:r.price,risks:null===r||void 0===r?void 0:r.risks,isLoading:c})})}const w=(0,t.memo)(y)}}]); 2//# sourceMappingURL=1655.1d2c0856.chunk.js.map
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.