PageSourceSearch

https://smartmortgages.com.au/_next/static/chunks/pages/questionnaire/[flowId]/[userId]-72b61ac18bf60fce.js

js smartmortgages.com.au collected 2026-10-04 01:44:56 UTC 10,408 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7378],{9019:function(e,d,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/questionnaire/[flowId]/[userId]",function(){return s(9899)}])},9899:function(e,d,s){"use strict";s.r(d),s.d(d,{__N_SSP:function(){return j}});var i=s(5893),a=s(5379),o=s.n(a),t=s(9008),n=s.n(t),c=s(1163),f=s(7294),r=s(7527),l=s(8114),x=s(3974),m=s(9958),g=s(9473),b=s(793),j=!0;d.default=e=>{var d;let s=(0,r.N)(l.Z),a=(0,r.N)(x.Z),[t,j]=(0,f.useState)(0),[h,u]=(0,f.useState)({}),[p,v]=(0,f.useState)([]),[w,N]=(0,f.useState)(null),[k,z]=(0,f.useState)(!1),[y,M]=(0,f.useState)({}),[C,_]=(0,f.useState)(!1),[S,I]=(0,f.useState)(null),q=(0,c.useRouter)(),{userId:E,flowId:Q}=q.query,{data:L,lang:O}=e,T=(0,g.I0)(),updateRespond=(e,d)=>{u({...h,[e]:d})};(0,f.useEffect)(()=>{if(navigator){var e,d,s;let i;(null===(e=navigator)||void 0===e?void 0:e.language)==="en"&&(i="en"),(null===(d=navigator)||void 0===d?void 0:d.language)==="zh"&&(i="cn"),i&&i!==O&&q.push("/".concat(null===(s=navigator)||void 0===s?void 0:s.language,"/questionnaire/").concat(Q,"/").concat(E))}},[]),(0,f.useEffect)(()=>{""!==L[t].toQID&&L.map(e=>e.id).indexOf(L[t].toQID)>0?N(L[t].toQID):N(null)},[L,t]);let handleSubmitClick=async()=>{if((void 0===y.email||""===y.email)&&(void 0===y.phone||""===y.phone)){I(a.formatMessage({id:"phone-or-email-error-message"}));return}T((0,b.K4)({message:"uploading your information.."}));let e={flowId:Q,managerId:E,...y,data:{...h}};try{let d=await (0,m.q$)(e);console.log(d)}catch(e){I(a.formatMessage({id:"submition-error-message"})),T((0,b.Mz)());return}T((0,b.Mz)()),_(!0)};return(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e container",children:[(0,i.jsxs)(n(),{children:[(0,i.jsx)("title",{className:"jsx-ddd36df10ff4c71e",children:"Questionnaire | ".concat(s.formatMessage({id:"company-name"}))}),(0,i.jsx)("link",{rel:"icon",href:"/favicon.ico",className:"jsx-ddd36df10ff4c71e"})]}),(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e session",children:(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e flex",children:[(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e image-container",children:(0,i.jsx)("img",{src:"https://firebasestorage.googleapis.com/v0/b/smart-mortgage-core.appspot.com/o/webImages%2Flet's%20talk.png?alt=media&token=678a2b51-07c1-409a-b731-f079b7324ce5",className:"jsx-ddd36df10ff4c71e"})}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e content",children:[(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e logo-container",children:[(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e logo",children:(0,i.jsx)("img",{src:"/Icon.svg",alt:"smart mortgage corp logo icon",className:"jsx-ddd36df10ff4c71e"})}),(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e logo-text",children:(0,i.jsx)("img",{src:"/Text.svg",alt:"smart mortgage corp logo text",className:"jsx-ddd36df10ff4c71e"})})]}),!C&&(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e session",children:(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e questionnaire-container",children:(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e ",children:[(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e  desciption wrap-text",children:a.formatMessage({id:"questionnaire-description"})}),!k&&(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e column",children:[(0,i.jsxs)("h2",{className:"jsx-ddd36df10ff4c71e",children:["Q",p.length+1,":"," ",null===(d=L[t])||void 0===d?void 0:d.question[O]]}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e answer",children:["options"===L[t].answer.answerType&&(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e optionAnswersContainer column",children:L[t].answer.data.map((e,d)=>{let s=L[t].dataLabel;return(0,i.jsxs)("div",{onClick:()=>{updateRespond(s,e.value),N(e.toQID)},className:"jsx-ddd36df10ff4c71e "+"option-answer row pointer ".concat(h[s]===e.value?"selected-option":""),children:[(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e "+"option-answer-selector ".concat(h[s]===e.value?"selected-selector":"")}),e.display[O]]},d)})}),"input"===L[t].answer.answerType&&(0,i.jsx)("input",{placeholder:a.formatMessage({id:"input-placeholder"}
1),value:h[L[t].dataLabel]?h[L[t].dataLabel]:"",onChange:e=>{updateRespond(L[t].dataLabel,e.target.value)},className:"jsx-ddd36df10ff4c71e"})]}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e row",children:[0!==t&&(0,i.jsx)("div",{onClick:()=>{let e=p[p.length-1],d=L.map(e=>e.id).indexOf(e),s=[...p];s.pop();let i={...h};delete i[L[d].dataLabel],j(d),v([...s]),u({...i})},className:"jsx-ddd36df10ff4c71e action-button bg-grey",children:a.formatMessage({id:"back"})}),w&&(0,i.jsx)("div",{onClick:()=>{var e;let d=null===(e=L[t])||void 0===e?void 0:e.id;if(null!==w){let e=L.map(e=>e.id).indexOf(w);j(e),v([...p,d])}},className:"jsx-ddd36df10ff4c71e action-button",children:a.formatMessage({id:"next"})}),!w&&0!==t&&(0,i.jsx)("div",{onClick:()=>{z(!0)},className:"jsx-ddd36df10ff4c71e action-button",children:a.formatMessage({id:"next"})})]})]}),k&&(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e column",children:[(0,i.jsx)("h3",{className:"jsx-ddd36df10ff4c71e  wrap-text",children:a.formatMessage({id:"contact-description"})}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e column",children:[(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e ",children:[(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e label",children:a.formatMessage({id:"name"})}),(0,i.jsx)("input",{value:(null==y?void 0:y.name)?y.name:"",onChange:e=>{M({...y,name:e.target.value})},className:"jsx-ddd36df10ff4c71e"})]}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e ",children:[(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e label",children:[" ",a.formatMessage({id:"email"})]}),(0,i.jsx)("input",{value:(null==y?void 0:y.email)?y.email:"",onChange:e=>{M({...y,email:e.target.value})},className:"jsx-ddd36df10ff4c71e"})]}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e ",children:[" ",(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e label",children:[" ",a.formatMessage({id:"phone"})]}),(0,i.jsx)("input",{value:(null==y?void 0:y.phone)?y.phone:"",onChange:e=>{M({...y,phone:e.target.value})},className:"jsx-ddd36df10ff4c71e"})]})]}),S&&(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e error",children:S}),(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e row",children:[(0,i.jsx)("div",{onClick:()=>z(!1),className:"jsx-ddd36df10ff4c71e action-button bg-grey",children:a.formatMessage({id:"back"})}),(0,i.jsx)("div",{onClick:handleSubmitClick,className:"jsx-ddd36df10ff4c71e action-button",children:a.formatMessage({id:"submit"})})]})]})]})})}),C&&(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e session",children:(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e questionnaire-container",children:(0,i.jsxs)("div",{className:"jsx-ddd36df10ff4c71e column",children:[(0,i.jsx)("h2",{className:"jsx-ddd36df10ff4c71e",children:a.formatMessage({id:"succeed-title"})}),(0,i.jsx)("div",{className:"jsx-ddd36df10ff4c71e",children:a.formatMessage({id:"succeed-message"})}),(0,i.jsxs)("div",{onClick:()=>{q.push("/")},className:"jsx-ddd36df10ff4c71e action-button pointer",children:[" ",a.formatMessage({id:"confirm"})]})]})})})]})]})}),(0,i.jsx)(o(),{id:"ddd36df10ff4c71e",children:".container.jsx-ddd36df10ff4c71e{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;margin:4em 0;width:100%;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-moz-box-orient:horizontal;-moz-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.questionnaire-container.jsx-ddd36df10ff4c71e{padding:4em 0;width:100%}.option-answer.jsx-ddd36df10ff4c71e{padding:1em 2em;border:1px solid var(--light-grey);-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.selected-option.jsx-ddd36df10ff4c71e{background:var(--secondary)}.option-answer-selector.jsx-ddd36df10ff4c71e{height:1em;width:1em;border:1px solid var(--dark)}.selected-selector.jsx-ddd36df10ff4c71e{background:var(--dark)}input.jsx-ddd36df10ff4c71e{width:100%;padding:.8em 1em;border:1px solid var(--light-grey);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.flex.jsx-ddd36df10ff4c71e{-webkit-box-pack:stretch;
1-webkit-justify-content:stretch;-moz-box-pack:stretch;-ms-flex-pack:stretch;justify-content:stretch}.image-container.jsx-ddd36df10ff4c71e{max-width:30%;height:80%;max-height:60vh;-webkit-align-self:stretch;-ms-flex-item-align:stretch;align-self:stretch;-o-object-fit:none;object-fit:none}.image-container.jsx-ddd36df10ff4c71e img.jsx-ddd36df10ff4c71e{width:auto;height:auto;height:80%;max-height:60vh;-webkit-transform:translatex(-25%);-moz-transform:translatex(-25%);-ms-transform:translatex(-25%);-o-transform:translatex(-25%);transform:translatex(-25%)}.logo-container.jsx-ddd36df10ff4c71e{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;gap:1em;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-moz-box-orient:horizontal;-moz-box-direction:normal;-ms-flex-direction:row;flex-direction:row;padding:1em;-webkit-box-align:center;-webkit-align-items:center;-moz-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.logo-text.jsx-ddd36df10ff4c71e{height:2em}.logo.jsx-ddd36df10ff4c71e{width:3em;background:var(--secondary);padding:.8em 1em}.logo.jsx-ddd36df10ff4c71e img.jsx-ddd36df10ff4c71e{width:100%;height:100%;-o-object-fit:cover;object-fit:cover}.flex.jsx-ddd36df10ff4c71e{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.error.jsx-ddd36df10ff4c71e{color:red}@media(max-width:600px){.container.jsx-ddd36df10ff4c71e{max-width:100%;width:100%}.image-container.jsx-ddd36df10ff4c71e{max-width:100vw;max-height:200px}.session.jsx-ddd36df10ff4c71e{padding:0}.content.jsx-ddd36df10ff4c71e{padding:0 var(--horizontal-padding)}}"})]})}},9008:function(e,d,s){e.exports=s(9201)}},function(e){e.O(0,[9774,2888,179],function(){return e(e.s=9019)}
1),_N_E=e.O()}]);

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.