PageSourceSearch

https://www.ttbbank.com/_next/static/chunks/pages/branch-survey/[level]-build-1789371932-3c1390f20d07a5e4.js

js ttbbank.com collected 2026-09-24 09:11:23 UTC 49,035 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[66526],{10638:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/branch-survey/[level]",function(){return n(93191)}])},32780:function(e,t,n){"use strict";var r=n(85893);n(67294),t.Z=e=>{let{height:t="16",width:n="16",color:i="#002D63"}=e;return(0,r.jsxs)("svg",{width:n,height:t,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,r.jsx)("mask",{id:"mask0_641_2139",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"16",height:"16",children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 2C8.78793 2 9.56815 2.15519 10.2961 2.45672C11.0241 2.75825 11.6855 3.20021 12.2426 3.75736C12.7998 4.31451 13.2417 4.97595 13.5433 5.7039C13.8448 6.43185 14 7.21207 14 8C14 8.78793 13.8448 9.56815 13.5433 10.2961C13.2417 11.0241 12.7998 11.6855 12.2426 12.2426C11.6855 12.7998 11.0241 13.2417 10.2961 13.5433C9.56815 13.8448 8.78793 14 8 14C6.4087 14 4.88258 13.3679 3.75736 12.2426C2.63214 11.1174 2 9.5913 2 8C2 6.4087 2.63214 4.88258 3.75736 3.75736C4.88258 2.63214 6.4087 2 8 2ZM8.007 10.167L7.91 10.175C7.78638 10.1973 7.67567 10.2653 7.5999 10.3655C7.52413 10.4657 7.48885 10.5907 7.50108 10.7157C7.5133 10.8407 7.57214 10.9566 7.66588 11.0402C7.75962 11.1238 7.8814 11.1691 8.007 11.167L8.097 11.159C8.21995 11.1367 8.3301 11.0693 8.40578 10.9698C8.48146 10.8704 8.51717 10.7463 8.50588 10.6218C8.49459 10.4974 8.43712 10.3817 8.34478 10.2975C8.25245 10.2133 8.13195 10.1668 8.007 10.167ZM8 4.833C7.86739 4.833 7.74021 4.88568 7.64645 4.97945C7.55268 5.07321 7.5 5.20039 7.5 5.333V8L7.508 8.09C7.53026 8.21295 7.59775 8.3231 7.69717 8.39878C7.79659 8.47446 7.92074 8.51017 8.04518 8.49888C8.16961 8.48759 8.28531 8.43012 8.36949 8.33778C8.45367 8.24545 8.50023 8.12495 8.5 8V5.333L8.492 5.243C8.47093 5.12789 8.41016 5.02381 8.32026 4.94889C8.23036 4.87397 8.11703 4.83296 8 4.833Z",fill:i})}),(0,r.jsx)("g",{mask:"url(#mask0_641_2139)",children:(0,r.jsx)("rect",{width:"16",height:"16",fill:i})})]})}},4116:function(e,t,n){"use strict";var r=n(85893);t.Z=e=>{let{style:t,width:n,height:i,color:l="#002D63"}=e;return(0,r.jsxs)("svg",{viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:t||{},width:n,height:i,children:[(0,r.jsx)("rect",{x:"1",y:"1",width:"14",height:"14",rx:"7",fill:"white"}),(0,r.jsx)("rect",{x:"1",y:"1",width:"14",height:"14",rx:"7",stroke:l,strokeWidth:"2"})]})}},57378:function(e,t,n){"use strict";var r=n(85893);t.Z=e=>{let{style:t,width:n,height:i,color:l="#F68B1F"}=e;return(0,r.jsxs)("svg",{viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:t||{},width:n,height:i,children:[(0,r.jsx)("rect",{x:"2.5",y:"2.5",width:"11",height:"11",rx:"5.5",fill:"white"}),(0,r.jsx)("circle",{cx:"8",cy:"8",r:"3",fill:"white"}),(0,r.jsx)("rect",{x:"2.5",y:"2.5",width:"11",height:"11",rx:"5.5",stroke:l,strokeWidth:"5"})]})}},92107:function(e,t,n){"use strict";n.d(t,{Z:function(){return f}});var r=n(85893),i=n(79028),l=n(59795),o=n(93967),a=n.n(o),s=n(4466),d=n(20050),c=n(16232),p=n.n(c),h=n(84593),u=e=>{let{title:t,children:n,onClose:i,open:o,closeable:c=!0,bgColor:u="#FFFFFF",isCenterTitle:m=!1}=e,{handleScroll:g,isTop:x}=(0,h.Z)();return(0,r.jsxs)(l.ZP,{anchor:"bottom",classes:{modal:p()["mui-modal__root"],paper:p()["bottom-sheet__paper"]},PaperProps:{elevation:0},onClose:(e,t)=>{(c||!c&&"backdropClick"!==t&&"escapeKeyDown"!==t)&&i()},open:o,children:[(0,r.jsxs)("div",{className:a()(p()["bottom-sheet__header"],{[p()["bottom-sheet__header--scrolled"]]:!x,[p()["bottom-sheet__header--centered"]]:m}),children:[(0,r.jsx)(d.X6,{tag:"h2",as:"p",className:m?p()["modal__title--centered"]:"",children:t}),c&&(0,r.jsx)("button",{onClick:i,children:(0,r.jsx)(s.X1,{})})]}),(0,r.jsx)("div",{onScroll:g,className:a()(p()["bottom-sheet__body"]),style:{backgroundColor:u},children:n})]})},m=n(21207),g=n(82629),x=e=>{let{title:t,onClose:n,open:i,children:l,closeable:o=!0,bgColor:c="#FFFFFF",isCenterTitle:u=!1}=e,{handleScroll:x,isTop:f}=(0,h.Z)();return(0,r.jsxs)(m.Z,{open:i,TransitionComponent:g.Z,classes:{root:p()["mui-modal__root"],paper:p().modal__paper},keepMounted:!0,onClose:(e,t)=>{(o||!o&&"backdropClick"!==t&&"escapeKeyDown"!==t)&&n()},PaperProps:{elevation:0},children:[(0,r.jsxs)("div",{className:a()(p().modal__header,{[p()["modal__header--scrolled"]]:!f,[p()["modal__header--centered"]]:u}),children:[(0,r.jsx)(d.X6,{tag:"h2",as:"p",breakpoint:"mobile",className:u?p()["modal__title--centered"]:"",children:t}),o&&(0,r.jsx)("button",{onClick:n,children:(0,r.jsx)(s.X1,{})})]}),i&&(0,r.jsx)("div",{onScroll:x,className:a()(p().modal__body),style:{backgroundColor:c},children:l})]})},f=e=>{let{title:t,children:n,open:l,onClose:o,closeable:a=!0,bgColor:s="#FFFFFF",isCenterTitle:d=!1}=e;return(0,i.Z)(640)?(0,r.jsx)(u,{title:t,onClose:o,open:l,closeable:a,bgColor:s,isCenterTitle:d,children:n}):(0,r.jsx)(x,{title:t,onClose:o,open:l,closeable:a,bgColor:s,isCenterTitle:d,children:n})}},26569:function(e,t,n){"use strict";n.d(t,{Z:function(){return r.Z}});var r=n(92107)},84593:function(e,t,n){"use strict";var r=n(67294);t.Z=()=>{let[e,t]=(0,r.useState)(!0);return{handleScroll:e=>{e.currentTarget.scrollTop>0?t(!1):t(!0)},isTop:e}}},20050:function(e,t,n){"use strict";n.d(t,{X6:function(){return p},nv:function(){return s},QE:function(){return m}});var r=n(85893),i=n(93967),l=n.n(i),o=n(20995),a=n.n(o),s=e=>{let{children:t,className:n="",color:i="navy",size:o="medium",as:s="p"}=e;return(0,r.jsx)(s,{className:l()(a().paragraph,a()["paragraph--".concat(o)],a()["paragraph--".concat(i)],n),children:t})},d=n(54629),c=n.n(d),p=e=>{let{tag:t,children:n,color:i="navy",breakpoint:o="auto",as:a,className:s}=e;return(0,r.jsx)(null!=a?a:t,{className:l()(c().heading,c()["heading--".concat(t,"--").concat(o)],c()["heading--".concat(i)],s),children:n})},h=n(9196),u=n.n(h),m=e=>{let{children:t,className:n="",color:i="navy"}=e;return(0,r.jsx)("p",{className:l()(u().subtitle,u()["subtitle--".concat(i)],n),children:t})}},70744:function(e,t,n){"use strict";n.d(t,{d:function(){return r}});let r=(0,n(67294).createContext)({methods:{},isLoading:!1,isError:!1,setIsError:()=>({}),getData:()=>({}),handleSelected:()=>({}),handleSubmit:()=>({}),handleBack:()=>({})})},33719:function(e,t,n){"use strict";n.d(t,{AD:function(){return b},DQ:function(){return f},RC:function(){return x},mv:function(){return m}});var r=n(85893),i=n(11163),l=n(67294),o=n(27484),a=n.n(o),s=n(96486),d=n.n(s),c=n(87536),p=n(88773),h=n(8060),u=n(70744);let m="_ttbbs-seq",g="_ttbbs-data",x="_ttbbs-uid",f="_ttbbs-mb",b=e=>{let{levels:t=[],children:n}=e,o=t.length>0?t[0]:"level1",s=(0,i.useRouter)(),{level:b=o,branch_code:_=""}=s.query,v=(0,c.cI)(),{getValues:y,setValue:w,clearErrors:C,trigger:j,reset:k}=v,[Z,I]=(0,l.useState)(!1),[M,L]=(0,l.useState)(!1),P=()=>{let[e]=(0,p.Z)().split("-"),t=new Date(Date.now()).getTime().toString().slice(-5);return"".concat("ttbbs","-").concat(e,"-").concat(t)},S=()=>{let e=localStorage.getItem(x);d().isEmpty(e)&&localStorage.setItem(x,P())},D=()=>{var e;let t=V()>=0,n=null!==(e=sessionStorage.getItem(m))&&void 0!==e?e:"";if(d().isEmpty(n)&&t){let e={url:window.location.href.replace(/\/(level1|level2|level3|level4|level5)/,""),application_version:localStorage.getItem(x)||"",created_time:a()().format("YYYY/MM/DD HH:mm:ss")};_&&(e.branch_code=_),I(!0),fetch("/api/branch-survey/transaction",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}).then(e=>e.json()).then(e=>{let{sequence_id:t}=e;sessionStorage.setItem(m,t)}).catch(()=>{L(!0),I(!1)})}},N=()=>
1{if(d().isEmpty(y())){var e;null===(e=q().items)||void 0===e||e.map(e=>{w(e.label,e.answer,{shouldValidate:!0,shouldDirty:!0,shouldTouch:!0})})}},F=()=>{let e=q();d().isEmpty(e.id)&&b.startsWith("level")&&s.replace({pathname:"/th/branch-survey/level1",query:d().omit(s.query,"level")})},E=e=>h.Z.encrypt(x,e),V=()=>t.findIndex(e=>e===b),q=()=>{var e;return JSON.parse(null!==(e=sessionStorage.getItem(g))&&void 0!==e?e:"{}")},B=e=>sessionStorage.setItem(g,JSON.stringify(e)),z=()=>{sessionStorage.removeItem(g),sessionStorage.removeItem(m)},R=async e=>{I(!0),fetch("/api/branch-survey/transaction",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}).then(e=>e.json()).then(n=>{let{success:r=!1}=n;if(r){let n=V();if(n<t.length){let r=q();if(n===t.length-1){let t=e.find(e=>"Feedback"===e.labelKey);if(t){if("Yes"===t.answer){let e=r.items.find(e=>"Mobile"===e.labelKey),t={};if(null==e?void 0:e.answer){let t=E(e.answer.replaceAll("-",""));sessionStorage.setItem(f,t)}d().isEmpty(r.branchCode)||(t.branch_code=r.branchCode),z(),s.push({pathname:"/th/contact/cxm/level1",query:t});return}z(),s.push("/th/branch-survey/success");return}z(),s.push("/th")}else{let e=t[n+1];r.currentLevel=e,B(r),C(),s.push({pathname:"/th/branch-survey/".concat(e),query:d().omit(s.query,"level")})}}}else L(!0),I(!1)}).catch(()=>{L(!0),I(!1)})},T=()=>{var e;let t=window.location.pathname.split("/").slice(-1)[0]||o,n=q(),r=(null==n?void 0:null===(e=n.items)||void 0===e?void 0:e.filter(e=>e.level===t))||[],i=r.map(e=>e.label),l={};null==r||r.map(e=>{l[e.label]=e.answer}),k({...l}),r.map(e=>{w(e.label,e.answer)}),j(i)};return(0,l.useEffect)(()=>{S(),D(),N(),F();let e=()=>{I(!1),T()};return s.events.on("routeChangeComplete",e),()=>{s.events.off("routeChangeComplete",e)}},[]),(0,r.jsx)(u.d.Provider,{value:{methods:v,isLoading:Z,getData:q,isError:M,setIsError:L,handleSelected:e=>{let t=q();if(d().isEmpty(t.createdAt)&&(t.createdAt=a()().format("DD/MM/YYYY")),d().isEmpty(t.id)&&(t.id=sessionStorage.getItem(m)||""),d().isEmpty(t.branchCode)&&_&&(t.branchCode=_),t.items){let n=t.items.filter(t=>{let{labelKey:n}=t;return n!==e.labelKey});t.items=[...n,e]}else t.items=[e];B(t)},handleSubmit:R,handleBack:()=>{let e=V();if(e<=t.length){let n=t[e-1],r=q();r.currentLevel=n,B(r),C(),s.push({pathname:"/th/branch-survey/".concat(n),query:d().omit(s.query,"level")})}}},children:n})}},79028:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});var r=n(67294);function i(e){let[t,n]=(0,r.useState)(!1);(0,r.useLayoutEffect)(()=>(window&&(i(),window.addEventListener("resize",i,!1)),()=>{window.removeEventListener("resize",i)}),[]);let i=()=>{window&&(window.innerWidth<=e?n(!0):n(!1))};return t}},28535:function(e,t,n){"use strict";var r=n(11752),i=n.n(r),l=n(48212);let{publicRuntimeConfig:o}=i()();t.Z=()=>{let{env:e}=(0,l.bp)(),t=o.mediaUrl[e];return{getURL:n=>"production"===e?[t,"1",n].join("/"):[t,"34",n].join("/")}}},93191:function(e,t,n){"use strict";n.r(t),n.d(t,{__N_SSP:function(){return eO},default:function(){return eU}});var r=n(85893),i=n(9008),l=n.n(i),o=n(89755),a=n.n(o),s=n(11163),d=n(67294),c=n(56799),p=n(85444),h=e=>{let{height:t="36",width:n="36",color:i="#002D63"}=e;return(0,r.jsx)("svg",{width:n,height:t,viewBox:"0 0 36 36",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M18 3.5C26.0081 3.5 32.5 9.99187 32.5 18C32.5 26.0081 26.0081 32.5 18 32.5C9.99187 32.5 3.5 26.0081 3.5 18C3.5 9.99187 9.99187 3.5 18 3.5ZM18 5.5C11.0964 5.5 5.5 11.0964 5.5 18C5.5 24.9036 11.0964 30.5 18 30.5C24.9036 30.5 30.5 24.9036 30.5 18C30.5 11.0964 24.9036 5.5 18 5.5ZM23.2071 14.2929C23.5676 14.6534 23.5953 15.2206 23.2903 15.6129L23.2071 15.7071L17.2071 21.7071C16.8466 22.0676 16.2794 22.0953 15.8871 21.7903L15.7929 21.7071L12.7929 18.7071C12.4024 18.3166 12.4024 17.6834 12.7929 17.2929C13.1534 16.9324 13.7206 16.9047 14.1129 17.2097L14.2071 17.2929L16.5 19.585L21.7929 14.2929C22.1834 13.9024 22.8166 13.9024 23.2071 14.2929Z",fill:i})})},u=n(90438),m=n(55695),g=n(96486),x=n.n(g),f=n(79028),b=n(29187),_=n(61945),v=n(85700);
1let y=p.ZP.form.withConfig({componentId:"sc-2ffa282d-0"})(["display:flex;flex-direction:column;gap:24px;height:100%;@media screen and (","){gap:unset;justify-content:space-between;min-height:calc(100dvh - 160px);}"],e=>{let{theme:t}=e;return t.breakpoints.mobile}),w=(0,p.ZP)(b.Z).withConfig({componentId:"sc-2ffa282d-1"})(["display:flex;flex-direction:column;label{margin-bottom:16px;}"]),C=(0,p.ZP)(_.Z).withConfig({componentId:"sc-2ffa282d-2"})(["font-size:16px !important;line-height:24px !important;font-weight:700 !important;font-family:"," !important;letter-spacing:"," !important;color:"," !important;margin:0;"],e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{color:t,theme:n}=e;return t||n.colors.textDefault}),j=p.ZP.div.withConfig({componentId:"sc-2ffa282d-3"})(["color:",";letter-spacing:"," !important;font-family:",";font-size:14px;line-height:20px;margin-top:2px;"],e=>{let{theme:t}=e;return t.colors.textDesc},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.font}),k=(0,p.ZP)(v.Z).withConfig({componentId:"sc-2ffa282d-4"})(["background-color:",";border:1px solid "," !important;border-radius:12px;font-size:16px;font-family:",';line-height:24px;padding:8px 12px !important;min-height:60px;max-height:60px;&:has([class*="Mui-focused"]){border-color:'," !important;}&:has(.MuiInput-multiline){height:84px;max-height:84px;}&:has(.Mui-error){border-color:"," !important;}.MuiFormLabel-root{color:"," !important;font-size:16px !important;font-family:"," !important;letter-spacing:"," !important;line-height:24px !important;left:12px;transition:all 0.2s ease-in-out;&.Mui-focused,&.MuiInputLabel-shrink{top:8px !important;font-size:12px !important;line-height:16px !important;margin-bottom:0;transform:unset;}&.MuiInputLabel-shrink{color:"," !important;}}.MuiInputLabel-formControl{top:18px !important;transform:unset;.Mui-focused{color:"," !important;}}.MuiInputBase-input{font-family:"," !important;font-size:16px;line-height:24px;letter-spacing:"," !important;color:"," !important;padding:4px 0 0 0 !important;&:focus{caret-color:#0050f0 !important;}}.MuiInputBase-root{padding:0 !important;margin:0 !important;.Mui-focused{margin-top:24px !important;}.MuiInputBase-input{margin-top:16px !important;}}"],e=>{let{theme:t}=e;return t.colors.white},e=>{let{theme:t}=e;return t.colors.placeholder},e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.colors.primary},e=>{let{theme:t}=e;return t.colors.error},e=>{let{theme:t}=e;return t.colors.placeholder},e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.colors.label},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.colors.textDefault});var Z=n(87536),I=n(32780),M=n(94761),L=e=>{let{message:t}=e;return t?(0,r.jsxs)(P,{children:[(0,r.jsx)(I.Z,{color:"#DA2110"})," ",t]}):null};let P=(0,p.ZP)(M.Z).withConfig({componentId:"sc-98e809de-0"})(["color:#da2110 !important;display:flex;align-items:center;font-size:14px !important;font-family:"," !important;letter-spacing:"," !important;line-height:20px !important;margin-top:2px !important;gap:4px;"],e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.letterSpacing}),S=/^[a-zA-Zก-๛()\-\/\s0-9]+$/;var D=(0,d.memo)(e=>{let{methods:t,label:n,name:i,data:l,isLoading:o,callback:a}=e,{config:s={}}=l||{},d=(null==s?void 0:s.maxLength)||524288,{control:c,setValue:p,setError:h,trigger:u,clearErrors:m,formState:{errors:g}}=t,x="".concat(i,"-label"),f=e=>{var t;""===e||new RegExp(null!==(t=s.validate)&&void 0!==t?t:S).test(e)?(m(),p(i,e),a(e)):h(i,{type:"validate",message:"โปรดตรวจสอบ".concat(n)})},b=e=>{f(e.target.value),u(i)},_=e=>{f(e.target.value),u(i)};return(0,r.jsx)(Z.Qr,{control:c,name:i,defaultValue:"",rules:{required:{value:!!(null==s?void 0:s.required),message:(null==s?void 0:s.errorMessage)||"โปรดระบุ".concat(null==s?void 0:s.label)},validate:e=>(f(e),!0)},render:e=>{var t,l;let{field:a,fieldState:{error:c}}=e;return(0,r.jsxs)(w,{error:!!c,disabled:o,hidden:(null==s?void 0:s.hidden)||!1,children:[(0,r.jsx)(C,{id:x,children:n}),(0,r.jsx)(k,{...a,label:null==s?void 0:s.label,fullWidth:!0,autoComplete:"off",type:(null==s?void 0:s.type)||"text",inputMode:(null==s?void 0:s.inputMode)||"text",InputProps:{disableUnderline:!0,multiline:null==s?void 0:s.multiline,maxRows:(null==s?void 0:s.multiline)?null==s?void 0:s.maxRows:void 0,minRows:(null==s?void 0:s.multiline)?null==s?void 0:s.minRows:void 0},inputProps:{maxLength:d},onChange:b,onBlur:_,error:!!g[i],disabled:o}),g[i]?(0,r.jsx)(L,{message:(null===(t=g[i])||void 0===t?void 0:t.message)||""}):(null==s?void 0:s.showCounter)?(0,r.jsxs)(j,{children:["พิมพ์ได้อีก ",(d-((null===(l=a.value)||void 0===l?void 0:l.length)||0)).toLocaleStr
1ing()," อักษร"]}):(0,r.jsx)(r.Fragment,{})]})}})}),N=n(81772),F=n(90021),E=n(36741),V=n(93967),q=n.n(V),B=n(4116),z=n(57378),R=n(28535),T=(0,d.memo)(e=>{let{methods:t,label:n,name:i,data:l,isLoading:o,callback:s}=e,{config:c}=l,{type:p="radio"}=c||{},{getURL:h}=(0,R.Z)(),{control:u,formState:{errors:m},getValues:g,setValue:x}=t,f=(e,t)=>{let n=e.target.value;x(i,n),s(n)},b=e=>{let{src:t="",alt:n="",...i}=e;return(0,r.jsx)(a(),{src:t,alt:n,...i})},_=e=>{let{checked:t=!1,index:n=0,label:i=""}=e,l=b({src:h("branch_survey/smiley/smiley-".concat(n,".svg")),alt:i,width:40,height:40});return(0,r.jsx)(N.Z,{checkedIcon:l,icon:l,disabled:o,checked:t})},v=(e,t)=>{let n=e.value===g(i);switch(p){case"score":return(0,r.jsx)(O,{control:(0,r.jsx)(N.Z,{className:"d-none"}),label:e.label,value:e.value,disabled:o,className:q()({"score-checked":n}),onChange:f});case"smiley":return(0,r.jsx)(U,{control:_({checked:n,index:t+1,label:e.label}),label:"",value:e.value,className:q()({"smiley-checked":n}),onChange:f});default:return(0,r.jsx)(Y,{control:(0,r.jsx)(N.Z,{checkedIcon:(0,r.jsx)(z.Z,{width:16,height:16}),icon:(0,r.jsx)(B.Z,{width:16,height:16}),disabled:o,checked:n}),label:e.label,value:e.value,className:q()({"radio-checked":n}),onChange:f})}},y="radio"===p?d.Fragment:W;return(0,r.jsx)(Z.Qr,{control:u,name:i,defaultValue:"",rules:{required:{value:!!(null==c?void 0:c.required),message:(null==c?void 0:c.errorMessage)||"โปรดระบุ".concat(null==c?void 0:c.label)}},render:e=>{var t,a;let{field:s}=e;return(0,r.jsxs)(w,{error:!!m[i],disabled:o,hidden:(null==c?void 0:c.hidden)||!1,children:[(0,r.jsx)(C,{id:i,children:n}),(0,r.jsx)(A,{...s,name:i,"aria-label":i,row:(null==c?void 0:c.row)||!1,className:q()({"is-score":"score"===p,"is-smiley":"smiley"===p}),children:null==l?void 0:null===(t=l.options)||void 0===t?void 0:t.map((e,t)=>(0,r.jsxs)(y,{children:[v(e,t),(null==c?void 0:c.minText)&&(null==c?void 0:c.maxText)&&(0,r.jsxs)(K,{children:[0===t&&(null==c?void 0:c.minText),4===t&&(null==c?void 0:c.maxText)]})]},"".concat(i,"-").concat(e.value)))}),m[i]&&(0,r.jsx)(L,{message:(null===(a=m[i])||void 0===a?void 0:a.message)||""})]})}})});let A=(0,p.ZP)(F.Z).withConfig({componentId:"sc-812b2174-0"})(["gap:16px;&.MuiFormGroup-row{justify-content:center;}.radio-checked{border-width:2px;border-color:",";border-style:solid;}&.is-score{gap:24px !important;justify-content:space-evenly;@media screen and (","){justify-content:center;}}&.is-smiley{justify-content:space-between;align-items:baseline;&:has(.smiley-checked){label:not(.smiley-checked){opacity:0.3;}}}"],e=>{let{theme:t}=e;return t.colors.secondary},e=>{let{theme:t}=e;return t.breakpoints.mobile}),Y=(0,p.ZP)(E.Z).withConfig({componentId:"sc-812b2174-1"})(["height:56px;gap:8px;background-color:",";border-radius:12px;padding:16px;border-width:1px;border-color:",";border-style:solid;box-shadow:0px 4px 0px 0px rgba(76,87,101,0.06),0px 2px 0px 0px rgba(0,0,0,0.04);color:",";margin:0 !important;user-select:none;.MuiFormControlLabel-label{color:",";font-family:",";font-weight:700;font-size:16px;line-height:24px;}"],e=>{let{theme:t}=e;return t.colors.white},e=>{let{theme:t}=e;return t.colors.placeholder},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.font}),O=(0,p.ZP)(E.Z).withConfig({componentId:"sc-812b2174-2"})(["margin:0 !important;.MuiFormControlLabel-label{width:40px;height:40px;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:16px;line-height:24px;letter-spacing:",";border-radius:24px;background-color:",";border:1px solid ",";color:",";&:hover{color:",";background-color:",";border-color:",";}}&.score-checked{.MuiFormControlLabel-label{background-color:",";border:1px solid ",";color:",";}}"],e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.colors.white},e=>{let{theme:t}=e;return t.colors.textDisabled},e=>{let{theme:t}=e;return t.colors.textDesc},e=>{let{theme:t}=e;return t.colors.white},e=>{let{theme:t}=e;return t.colors.btnHover},e=>{let{theme:t}=e;
1return t.colors.btnHover},e=>{let{theme:t}=e;return t.colors.btnActive},e=>{let{theme:t}=e;return t.colors.btnActive},e=>{let{theme:t}=e;return t.colors.white}),U=(0,p.ZP)(E.Z).withConfig({componentId:"sc-812b2174-3"})(["margin:0 !important;opacity:1;.MuiFormControlLabel-label{display:none;}.MuiButtonBase-root{padding:0;}"]),W=p.ZP.div.withConfig({componentId:"sc-812b2174-4"})(["display:flex;flex-direction:column;align-items:center;gap:16px;"]),K=p.ZP.div.withConfig({componentId:"sc-812b2174-5"})(["display:flex;align-items:center;font-family:",";font-weight:400;font-size:12px;line-height:16px;color:",";letter-spacing:",";"],e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.colors.textDesc},e=>{let{theme:t}=e;return t.letterSpacing});var H=n(19861),Q=n(39938),X=n(97893),J=n(92375),G=n(59795),$=n(54398),ee=n(4466),et=n(84593),en=e=>{let{height:t="24",width:n="24",color:i="#002D63"}=e;return(0,r.jsx)("svg",{width:n,height:t,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M19.2932 6.29267C19.4731 6.11332 19.7146 6.0092 19.9685 6.00144C20.2225 5.99369 20.4699 6.08289 20.6604 6.25092C20.851 6.41895 20.9705 6.65322 20.9946 6.90615C21.0187 7.15907 20.9456 7.41168 20.7902 7.61267L20.7072 7.70667L10.7072 17.7067C10.535 17.8788 10.3059 17.9823 10.0628 17.9976C9.81981 18.0128 9.57956 17.9389 9.38716 17.7897L9.29316 17.7067L4.29316 12.7067C4.11381 12.5267 4.00969 12.2852 4.00193 12.0313C3.99418 11.7773 4.08337 11.53 4.25141 11.3394C4.41944 11.1488 4.65371 11.0294 4.90663 11.0053C5.15956 10.9812 5.41217 11.0543 5.61316 11.2097L5.70716 11.2927L10.0002 15.5847L19.2932 6.29267Z",fill:i})})},er=e=>{let{height:t="24",width:n="24",color:i="#002D63"}=e;return(0,r.jsx)("svg",{width:n,height:t,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M5.29303 8.29311C5.46522 8.12093 5.69432 8.0175 5.93735 8.00222C6.18038 7.98694 6.42063 8.06085 6.61303 8.2101L6.70703 8.29311L12 13.5851L17.293 8.29311C17.4652 8.12093 17.6943 8.0175 17.9373 8.00222C18.1804 7.98694 18.4206 8.06085 18.613 8.2101L18.707 8.29311C18.8792 8.4653 18.9826 8.6944 18.9979 8.93742C19.0132 9.18045 18.9393 9.4207 18.79 9.6131L18.707 9.7071L12.707 15.7071C12.5348 15.8793 12.3057 15.9827 12.0627 15.998C11.8197 16.0133 11.5794 15.9394 11.387 15.7901L11.293 15.7071L5.29303 9.7071C5.10556 9.51958 5.00024 9.26527 5.00024 9.0001C5.00024 8.73494 5.10556 8.48063 5.29303 8.29311Z",fill:i})})},ei=(0,d.memo)(e=>{var t;let{methods:n,label:i,name:l,data:o,isLoading:a,callback:s}=e,{config:c,options:p}=o,h=(0,f.Z)(640),{isTop:u,handleScroll:m}=(0,et.Z)(),{control:g,formState:{errors:x},setValue:b,getValues:_}=n,[v,y]=(0,d.useState)(!1),j="".concat(l,"-label"),k=(null==c?void 0:null===(t=c.label)||void 0===t?void 0:t.split("|"))||[],I="",M="";(null==k?void 0:k.length)===1?(I=k[0],M=k[0]):(I=k[0],M=k[1]);let P=e=>null==p?void 0:p.map(t=>(0,r.jsxs)(es,{value:t.value,onClick:()=>{b(l,t.value),y(!1),s(t.value)},children:[(0,r.jsx)(eu,{as:"div",$isBottomSheet:e,children:t.label}),e&&h&&t.value===_(l)&&(0,r.jsx)(en,{})]},t.value)),S=()=>{document.activeElement.blur()};return(0,r.jsxs)(w,{children:[(0,r.jsx)(C,{children:i}),(0,r.jsx)(Z.Qr,{name:l,control:g,rules:{required:{value:!!(null==c?void 0:c.required),message:(null==c?void 0:c.errorMessage)||"โปรดระบุ".concat(null==c?void 0:c.label)}},defaultValue:"",render:e=>{var t;let{field:n}=e;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(el,{error:!!x[l],disabled:a,hidden:(null==c?void 0:c.hidden)||!1,children:[(0,r.jsx)(eo,{id:j,children:I}),(0,r.jsx)(ea,{...n,labelId:j,fullWidth:!0,disableUnderline:!0,label:I,required:null==c?void 0:c.required,open:v,onOpen:()=>y(!0),onClose:()=>y(!1),MenuProps:{getContentAnchorEl:null,anchorOrigin:{vertical:"bottom",horizontal:"left"},PopoverClasses:{root:q()({"d-none":h})},TransitionProps:{onExited:S}},input:(0,r.jsx)(H.Z,{}),inputProps:{"aria-label":I},IconComponent:er,error:!!x[l],disabled:a,children:P()}),x[l]&&(0,r.jsx)(L,{message:(null===(t=x[l])||void 0===t?void 0:t.message)||""})]}),h&&!a&&(0,r.jsx)(ed,{open:v,anchor:"bottom",onClose:()=>y(!1),children:(0,r.jsxs)(ec,{children:[(0,r.jsxs)(ep,{isScroll:!u,children:[M||I,(0,r.jsx)("button",{onClick:()=>y(!1),children:(0,r.jsx)(ee.X1,{})})]}),(0,r.jsx)(eh,{onScroll:m,children:P(!0)})]})})]})}})]})});let el=(0,p.ZP)(b.Z).withConfig({componentId:"sc-47df2b39-0"}
1)(["height:60px;max-height:60px;overflow:hidden;.MuiPaper-root{margin-top:60px;}.MuiInputBase-root.Mui-focused{border:1px solid ",";}&:has(.MuiInputLabel-shrink){.MuiSelect-select{padding-left:12px !important;padding-top:16px;}}"],e=>{let{theme:t}=e;return t.colors.primary}),eo=(0,p.ZP)(Q.Z).withConfig({componentId:"sc-47df2b39-1"})(["font-size:16px !important;font-family:"," !important;line-height:24px !important;letter-spacing:"," !important;color:"," !important;margin-bottom:0;left:12px !important;transition:all .2s ease-in-out;&.Mui-focused,&.MuiInputLabel-shrink{top:8px !important;font-size:12px !important;line-height:16px !important;margin-bottom:0;transform:unset;}&.MuiInputLabel-shrink{color:"," !important;}&.Mui-focused{color:"," !important;&.MuiInputLabel-shrink{color:"," !important;}}&.MuiInputLabel-shrink{color:"," !important;}&.MuiInputLabel-formControl{top:18px;transform:unset !important;.Mui-focused{color:"," !important;}}"],e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.colors.placeholder},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.colors.label},e=>{let{theme:t}=e;return t.colors.textDefault}),ea=(0,p.ZP)(X.Z).withConfig({componentId:"sc-47df2b39-2"})(["height:60px;margin-top:0 !important;border:1px solid ",";border-radius:12px !important;font-family:"," !important;letter-spacing:"," !important;cursor:pointer !important;overflow:hidden;.MuiSelect-select{display:flex;align-items:center;height:24px;padding:4px 0 0 0 !important;margin-top:16px;&:focus{background-color:transparent;}}.MuiSelect-icon{color:"," !important;margin:0 8px !important;}input{display:none;}svg{margin:8px;right:0;position:absolute;pointer-events:none;}"],e=>{let{theme:t}=e;return t.colors.placeholder},e=>{let{theme:t}=e;return t.font},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.colors.textDefault}),es=(0,p.ZP)(J.Z).withConfig({componentId:"sc-47df2b39-3"})(["color:"," !important;font-size:16px !important;line-height:24px !important;font-weight:700 !important;letter-spacing:"," !important;padding:16px !important;border-bottom:1px solid "," !important;&:hover{background-color:"," !important;}@media screen and (","){&:first-of-type{border-top:1px solid "," !important;}}"],e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.letterSpacing},e=>{let{theme:t}=e;return t.colors.btnDisabledOutline},e=>{let{theme:t}=e;return t.colors.btnDisabled},e=>{let{theme:t}=e;return t.breakpoints.mobile},e=>{let{theme:t}=e;return t.colors.btnDisabledOutline}),ed=(0,p.ZP)(G.ZP).withConfig({componentId:"sc-47df2b39-4"})([".MuiPaper-root{padding-top:16px;border-top-right-radius:24px;border-top-left-radius:24px;}"]),ec=p.ZP.div.withConfig({componentId:"sc-47df2b39-5"})([""]),ep=p.ZP.div.withConfig({componentId:"sc-47df2b39-6"})(["display:flex;align-items:center;justify-content:center;color:",";font-size:16px;line-height:24px;font-weight:700;letter-spacing:0.4px;padding:0 16px;position:relative;height:40px;"," button{display:flex;align-items:center;justify-content:center;height:100%;position:absolute;top:0;right:16px;border:0;background-color:transparent;}"],e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{isScroll:t}=e;return t&&"box-shadow: 0px 2px 0px rgba(0, 0, 0, 0.04), 0px 4px 0px rgba(76, 87, 101, 0.06);"}),eh=p.ZP.div.withConfig({componentId:"sc-47df2b39-7"})(["max-height:calc(100vh - 50px);overflow-x:hidden;overflow-y:auto;@supports(height:100dvh){max-height:calc(100dvh - 50px) !important;}li:first-of-type{margin-top:8px;}div:first-of-type{padding-bottom:16px;}"]),eu=(0,p.ZP)($.ay).withConfig({componentId:"sc-47df2b39-8"})(["width:100%;font-weight:",";padding-bottom:0 !important;"],e=>{let{$isBottomSheet:t}=e;return t?700:400}),em=/^(06|08|09)[0-9]{8}$/,eg=/(\d{0,3})(\d{0,3})(\d{0,4})/;var ex=(0,d.memo)(e=>{let{methods:t,label:n,name:i,data:l,isLoading:o,callback:a}=e,{config:s={}}=l||{},{control:d,setValue:c,setError:p,clearErrors:h,trigger:u,formState:{errors:m}}=t,g="".concat(i,"-label"),f=e=>x().isEmpty(e)?e:e=(e=e.replace(/[^\d]/g,"").replace(/[-]/g,"")).replace(eg,(e,t,n,r)=>{let i=[];return t&&i.push(t),n&&i.push(n),r&&i.push(r),i.join("-")}),b=e=>{let t=(null==e?void 0:e.replace(/[^\d]/g,"").replaceAll(/[-]/g,""))||"";0===t.length?(h(i),c(i,e),a(e)):t.length<10?p(i,{type:"validate",message:"โปรดใส่เบอร์มือถือ 10 หลัก"}):em.test(t)?(h(i),c(i,e),a(e)):p(i,{type:"validate",message:"โปรดตรวจสอบเบอร์มือถือ"})},_=e=>{let t=e.target.value;c(i,t=f(t)),a(t)},v=e=>{b(e.target.value),c(i,e.target.value),a(e.target.value),u(i)};return(0,r.jsx)(Z.Qr,{control:d,name:i,defaultValue:"",rules:{required:{value:!!(null==s?void 0:s.required),message:(null==s?void 0:s.errorMessage)||"โปรดใส่เบอร์มือถือ"},validate:e=>(b(e),!0)},render:e=>{var t;let{field:l,fieldState:{error:a}}=e;return(0,r.jsxs)(w,{error:!!a,disabled:o,hidden:(null==s?void 0:s.hidden)||!1,children:[(0,r.jsx)(C,{id:g,children:n}),(0,r.jsx)(k,{...l,label:null==s?void 0:s.label,fullWidth:!0,autoComplete:"off",type:"tel",inputMode:"tel",InputProps:{disableUnderline:!0},inputProps:{maxLength:12},onChange:_,onBlur:v,error:!!m[i],disabled:o}),m[i]&&(0,r.jsx)(L,{message:(null===(t=m[i])||void 0===t?void 0:t.message)||""})]})}})});let ef=[">","<","==","!=",">=","<=","unknown"];class eb{constructor(e){this.DEFAULT_VALUE="''",this._operator="unknown",this.fieldName="",this.fieldValue=this.DEFAULT_VALUE,this.isOperator=e=>ef.includes(e),this.getOperator=e=>{let[t]=new RegExp(ef.join("|")).exec(e)||["unknown"];return t}
1,this.calcWithOperator=(e,t,n)=>({">":e>t,"<":e<t,"==":e==t,"!=":e!=t,">=":e>=t,"<=":e<=t,unknown:e})[n],this.extractCondition=()=>{if(this._config.condition){let[e,t]=this._config.condition.split("->"),n=this.getOperator(t);if(this._operator=n,"unknown"!==n){let[e,r]=t.split(n);this.fieldName=e,this.fieldValue=r||this.DEFAULT_VALUE}}},this.validateHidden=e=>("unknown"!==this._operator&&(this._config.hidden=this.calcWithOperator(e||this.DEFAULT_VALUE,this.fieldValue,this._operator)),this._config),this._config=e,this.extractCondition()}}p.ZP.div.withConfig({componentId:"sc-90749f1f-0"})(["display:flex;flex-direction:column;gap:46px;height:100%;@media screen and (","){gap:unset;justify-content:space-between;}"],e=>{let{theme:t}=e;return t.breakpoints.mobile});let e_=p.ZP.div.withConfig({componentId:"sc-90749f1f-1"})(["display:flex;flex-direction:column;gap:24px;padding:0 24px;@media screen and (","){padding:0 16px;}"],e=>{let{theme:t}=e;return t.breakpoints.mobile}),ev=p.ZP.div.withConfig({componentId:"sc-90749f1f-2"})(["display:flex;align-items:center;justify-content:flex-end;padding:8px 24px;@media screen and (","){padding:24px 16px;height:96px;}"],e=>{let{theme:t}=e;return t.breakpoints.mobile});p.ZP.div.withConfig({componentId:"sc-90749f1f-3"})(["display:flex;flex-direction:column;gap:16px;"]),(0,p.ZP)(X.Z).withConfig({componentId:"sc-90749f1f-4"})(["background-color:white !important;border:1px solid #b0bccb;border-radius:12px !important;"]);let ey=(0,p.ZP)($.KM).withConfig({componentId:"sc-90749f1f-5"})(["font-weight:700;@media screen and (","){width:100%;}"],e=>{let{theme:t}=e;return t.breakpoints.mobile});var ew=e=>{let{methods:t,fields:n,isLoading:i=!1,onSubmit:l,onSelected:o}=e,a=(0,f.Z)(640),s={radio:T,input:D,tel:ex,select:ei},{control:c,formState:p,handleSubmit:h,getValues:g,watch:b}=t;return(0,r.jsxs)(y,{onSubmit:h(l),noValidate:!0,children:[(0,r.jsx)(e_,{children:n.map(e=>{var n;let i=null!==(n=s[e.type])&&void 0!==n?n:d.Fragment;if(e.data.config){let t=new eb(e.data.config);b(t.fieldName),e.data.config=t.validateHidden(g(t.fieldName))}return(0,r.jsx)(i,{methods:t,label:e.label,name:e.name,data:e.data,callback:t=>o(e,t)},e.name)})}),(0,r.jsx)(ev,{children:(0,r.jsxs)(ey,{inline:!0,size:a?"large":"medium",disabled:!p.isValid||!x().isEmpty(p.errors)||i,children:[i&&(0,r.jsx)(m.Z,{disableShrink:!0,size:16,color:"inherit"}),"ถัดไป"]})}),(0,r.jsx)(u.DevTool,{control:c})]})},eC=n(20050),ej=n(70744),ek=n(33719),eZ=n(27484),eI=n.n(eZ),eM=n(50067),eL=e=>{let{level:t,questions:n,name:i}=e,{methods:l,handleSelected:o,handleSubmit:a,isLoading:s}=(0,d.useContext)(ej.d),c=n.map(e=>({name:e.label,label:e.description_th,labelKey:e.label_key,data_field:e.data_field,type:e.component,type_of_question:e.type_of_question,data:e.data_config,order:e.order})).sort((e,t)=>e.order-t.order),p=(e,n)=>{var r,i;return{seqId:null!==(r=sessionStorage.getItem(ek.mv))&&void 0!==r?r:"",uid:null!==(i=localStorage.getItem(ek.RC))&&void 0!==i?i:"",label:e.name,labelKey:e.labelKey,field:e.data_field,question:e.label,answer:n,type:e.type_of_question,level:t,submitAt:eI()().format("YYYY/MM/DD HH:mm:ss")}};return(0,r.jsx)(eM.Z,{children:(0,r.jsxs)(Z.RV,{...l,children:["level1"===t&&i&&(0,r.jsxs)(eC.QE,{className:"px-lg-4 px-3",children:["สำหรับ",i]}),(0,r.jsx)(ew,{methods:l,fields:c,isLoading:s,onSelected:(e,t)=>{o(p(e,t))},onSubmit:e=>{a(c.map(t=>p(t,e[t.name])))}})]})})},eP=e=>{let{height:t="24",width:n="24",color:i="#002D63"}=e;return(0,r.jsx)("svg",{width:n,height:t,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14.293 5.29267C14.4729 5.11332 14.7144 5.0092 14.9684 5.00144C15.2223 4.99369 15.4697 5.08289 15.6603 5.25092C15.8508 5.41895 15.9703 5.65322 15.9944 5.90615C16.0185 6.15907 15.9454 6.41168 15.79 6.61267L15.707 6.70667L10.415 11.9997L15.707 17.2927C15.8792 17.4649 15.9826 17.694 15.9979 17.937C16.0132 18.18 15.9392 18.4203 15.79 18.6127L15.707 18.7067C15.5348 18.8788 15.3057 18.9823 15.0627 18.9976C14.8196 19.0128 14.5794 18.9389 14.387 18.7897L14.293 18.7067L8.29298 12.7067C8.12081 12.5345 8.01738 12.3054 8.00209 12.0624C7.98681 11.8193 8.06073 
111.5791 8.20998 11.3867L8.29298 11.2927L14.293 5.29267Z",fill:i})})},eS=n(26569),eD=e=>{let{width:t="48",height:n="48",color:i="#002D63"}=e;return(0,r.jsxs)("svg",{width:t,height:n,viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,r.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M2.66602 8.0013C2.66602 5.05579 5.05383 2.66797 7.99935 2.66797H22.666C25.6115 2.66797 27.9993 5.05578 27.9993 8.0013V12.0013C27.9993 12.7377 27.4024 13.3346 26.666 13.3346C25.9296 13.3346 25.3327 12.7377 25.3327 12.0013V8.0013C25.3327 6.52854 24.1388 5.33464 22.666 5.33464H7.99935C6.52659 5.33464 5.33268 6.52854 5.33268 8.0013V40.0013C5.33268 41.4741 6.52659 42.668 7.99935 42.668H22.666C24.1388 42.668 25.3327 41.4741 25.3327 40.0013V22.0013C25.3327 21.2649 25.9296 20.668 26.666 20.668C27.4024 20.668 27.9993 21.2649 27.9993 22.0013V40.0013C27.9993 42.9468 25.6115 45.3346 22.666 45.3346H7.99935C5.05383 45.3346 2.66602 42.9468 2.66602 40.0013V8.0013Z",fill:i}),(0,r.jsx)("ellipse",{cx:"1.33333",cy:"1.33333",rx:"1.33333",ry:"1.33333",transform:"matrix(-4.37114e-08 -1 -1 4.37113e-08 21.332 18.668)",fill:i}),(0,r.jsx)("ellipse",{cx:"1.33333",cy:"1.33333",rx:"1.33333",ry:"1.33333",transform:"matrix(-4.37114e-08 -1 -1 4.37113e-08 25.332 18.668)",fill:i}),(0,r.jsx)("ellipse",{cx:"1.33333",cy:"1.33333",rx:"1.33333",ry:"1.33333",transform:"matrix(-4.37114e-08 -1 -1 4.37113e-08 29.332 18.668)",fill:i}),(0,r.jsx)("path",{d:"M14.4591 33.6426C14.4591 33.1018 14.5587 32.606 14.758 32.1553C14.9725 31.6896 15.2254 31.2914 15.5166 30.9609C15.8078 30.6154 16.1986 30.2022 16.689 29.7215C17.2714 29.1806 17.7082 28.7149 17.9993 28.3243C18.2905 27.9187 18.4361 27.4755 18.4361 26.9947C18.4361 26.4389 18.2522 25.9882 17.8844 25.6426C17.5319 25.2971 16.9649 25.1243 16.1833 25.1243C15.371 25.1243 14.7503 25.3346 14.3212 25.7553C14.1147 25.9504 13.9491 26.1838 13.8242 26.4555C13.5749 26.9978 13.1091 27.468 12.5122 27.468V27.468C11.5093 27.468 10.685 26.5974 11.1017 25.6851C11.1888 25.4943 11.2888 25.3074 11.4016 25.1243C11.8614 24.3882 12.4974 23.7947 13.3097 23.344C14.1373 22.8933 15.0875 22.668 16.1603 22.668C17.984 22.668 19.302 23.0886 20.1143 23.9299C20.9266 24.7713 21.3327 25.7929 21.3327 26.9947C21.3327 27.6858 21.1488 28.2943 20.781 28.8201C20.4285 29.3309 19.8921 29.9393 19.1718 30.6454C18.5434 31.2464 18.0683 31.7647 17.7465 32.2004C17.44 32.636 17.2867 33.1168 17.2867 33.6426V33.9208C17.2867 34.7017 16.6537 35.3346 15.8729 35.3346V35.3346C15.0921 35.3346 14.4591 34.7017 14.4591 33.9208V33.6426Z",fill:i}),(0,r.jsx)("ellipse",{cx:"15.9993",cy:"38.6654",rx:"1.33333",ry:"1.33333",fill:i}),(0,r.jsx)("ellipse",{cx:"6.66667",cy:"6.66667",rx:"6.66667",ry:"6.66667",transform:"matrix(-1 0 0 1 45.334 10.668)",fill:i}),(0,r.jsx)("rect",{width:"8.22695",height:"1.70213",rx:"0.851064",transform:"matrix(-0.707107 0.707107 0.707107 0.707107 40.9102 13.7891)",fill:"white"}),(0,r.jsx)("rect",{width:"8.22695",height:"1.70213",rx:"0.851064",transform:"matrix(0.707107 0.707107 0.707107 -0.707107 35.1914 15.0938)",fill:"white"})]})},eN=e=>{let{children:t,canBack:n,isLevel:i=!0}=e,{isError:l,setIsError:o,handleBack:a}=(0,d.useContext)(ej.d);return(0,r.jsxs)(eF,{id:"qr-branch-survey__layout",children:[(0,r.jsx)(eE,{children:(0,r.jsxs)(eV,{children:[i&&(0,r.jsxs)(eq,{$isCanBack:n,children:[n&&(0,r.jsx)(eT,{onClick:a,children:(0,r.jsx)(eP,{})}),(0,r.jsx)(ez,{children:"แบบสอบถาม"}),n&&(0,r.jsx)(eR,{"aria-hidden":"true"})]}),(0,r.jsx)(eB,{children:t})]})}),(0,r.jsx)(eS.Z,{title:"",onClose:()=>o(!1),open:l,children:(0,r.jsxs)(eA,{children:[(0,r.jsxs)(eY,{children:[(0,r.jsx)(eD,{}),(0,r.jsx)($.xl,{children:"ไม่สามารถทำรายการได้ขณะนี้"}),(0,r.jsx)($.Yl,{color:"#7D8999",children:"โปรดลองใหม่อีกครั้งภายหลัง"})]}),(0,r.jsx)($.KM,{className:"font-weight-bold",onClick:()=>o(!1),children:"ตกลง"})]})})]})};let eF=p.ZP.section.withConfig({componentId:"sc-c6402593-0"})(["display:flex;flex-direction:column;align-items:center;gap:16px;margin:0;overflow:hidden;padding-top:48px;padding-left:200px;padding-right:200px;padding-bottom:80px;background-color:#f5f6f7;transition:all 0.3s ease;overflow-x:hidden;overflow-y:auto;@media screen and (","){padding-top:60px;}@media screen and (","){background-color:#ffffff;padding-top:0;padding-left:0;padding-right:0;padding-bottom:0;}"],e=>{let{theme:t}=e;return t.breakpoints.tablet},e=>{let{theme:t}=e;return t.breakpoints.mobile}),eE=p.ZP.div.withConfig({componentId:"sc-c6402593-1"})(["width:680px;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;gap:46px;border-radius:16px;border:1px solid #dfe6ec;background-color:#fff;box-shadow:0px 4px 0px 0px rgba(76,87,101,0.06),0px 2px 0px 0px rgba(0,0,0,0.04);transition:all 0.3s ease;@media screen and (","){width:572px;}@media screen and (","){border-radius:0;border:none;width:100%;padding:0;}"],e=>{let{theme:t}=e;return t.breakpoints.tablet},e=>{let{theme:t}=e;return t.breakpoints.mobile}),eV=p.ZP.div.withConfig({componentId:"sc-c6402593-2"})(["display:flex;flex-direction:column;gap:24px;flex:1;width:100%;padding:24px 0 32px 0;@media screen and (","){gap:8px;padding:0;min-height:calc(100vh - 60px) !important;padding:0;@supports (min-height:100dvh){min-height:calc(100dvh - 60px) !important;}}"],e=>{let{theme:t}=e;return t.breakpoints.mobile}),eq=p.ZP.div.withConfig({componentId:"sc-c6402593-3"})(["display:flex;gap:8px;align-items:center;padding:",";@media screen and (","){margin:0;}"],e=>{let{$isCanBack:t}=e;return t?"0 8px 0 8px":"0 24px"},e=>{let{theme:t}=e;return t.breakpoints.mobile}),eB=p.ZP.div.withConfig({componentId:"sc-c6402593-4"})(["display:flex;flex-direction:column;gap:16px;max-height:100%;height:100%;"]),ez=(0,p.ZP)($.V1).withConfig({componentId:"sc-c6402593-5"})(["padding:0;text-align:center;flex:1;"]),eR=p.ZP.div.withConfig({componentId:"sc-c6402593-6"})(["width:40px;height:40px;"]),eT=(0,p.ZP)($.gh).withConfig({componentId:"sc-c6402593-7"})(["width:40px;height:40px;padding:8px;color:",";&:hover{color:",";}&:focus,&:active{background-color:transparent;border:1px solid ",";}"],e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;return t.colors.textDefault},e=>{let{theme:t}=e;
1return t.colors.btnDisabled}),eA=p.ZP.div.withConfig({componentId:"sc-c6402593-8"})(["display:flex;flex-direction:column;align-items:center;gap:24px;padding-bottom:24px;button{height:40px;max-width:160px;}"]),eY=p.ZP.div.withConfig({componentId:"sc-c6402593-9"})(["padding:0 16px;display:flex;flex-direction:column;align-items:center;gap:16px;"]);var eO=!0,eU=e=>{var t;let{questions:n,branch:i,levels:o}=e,d=(0,f.Z)(640),u=(0,s.useRouter)(),m=null===(t=u.query)||void 0===t?void 0:t.level,g=()=>{u.replace("/th")};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(l(),{children:(0,r.jsx)("meta",{name:"robots",content:"noindex,nofollow"})}),(0,r.jsxs)(p.f6,{theme:c.D,children:[(0,r.jsx)(eW,{}),(0,r.jsx)(ek.AD,{levels:o,children:(0,r.jsx)(eN,{canBack:m.startsWith("level")&&"level1"!==m,isLevel:m.startsWith("level"),children:(()=>{switch(m){case"success":return(0,r.jsxs)(eK,{children:[(0,r.jsxs)(eH,{children:[(0,r.jsx)(h,{width:56,height:56,color:"#1EB950"}),(0,r.jsx)($.xl,{children:"ตอบแบบสอบถามสำเร็จ"}),(0,r.jsxs)($.Yl,{color:"#7D8999",className:"text-center",children:["ทีทีบี ขอขอบคุณสำหรับความคิดเห็นเพื่อให้ ",(0,r.jsx)("br",{}),"เราสามารถพัฒนาผลิตภัณฑ์และบริการให้ดียิ่งขึ้น"]})]}),(0,r.jsx)(eQ,{children:(0,r.jsx)($.KM,{inline:!0,size:d?"large":"medium",className:"font-weight-bold",onClick:g,children:"ปิด"})})]});case"timeout":return(0,r.jsxs)(eK,{children:[(0,r.jsxs)(eH,{children:[(0,r.jsx)(a(),{src:"/assets/qr-branch-survey/timeout.png",alt:"timeout",width:240,height:240}),(0,r.jsx)($.xl,{children:"ขณะนี้อยู่นอกเวลาให้บริการ"}),(0,r.jsxs)($.Yl,{color:"#7D8999",className:"text-center",children:["โปรดกลับมาทำรายการอีกครั้งในเวลา",(0,r.jsx)("br",{}),"08:30-20:00 น. ทีทีบี ขออภัยในความไม่สะดวกครับ"]})]}),(0,r.jsx)(eQ,{children:(0,r.jsx)($.KM,{inline:!0,size:d?"large":"medium",className:"font-weight-bold",onClick:g,children:"ตกลง"})})]});default:return(0,r.jsx)(eL,{level:m,questions:n,name:(null==i?void 0:i.name)||""})}})()})})]})]})};let eW=(0,p.vJ)(["main{display:flex;flex-direction:column;overflow-x:hidden;overflow-y:auto;@media screen and (","){max-height:100%;}}header{position:relative !important;}.MuiPopover{&-root{margin-top:8px;}&-paper{border-radius:16px !important;border:1px solid ",';}}#qr-branch-survey__layout{height:100vh;@supports(height:100dvh){height:100dvh !important;}}&:has(header){#qr-branch-survey__layout{height:calc(100vh - 60px);@supports(height:100dvh){height:calc(100dvh - 60px) !important;}}}[class^="styles_modal__body"]{width:calc(100dvw - 64px);}.MuiBackdrop-root{background-color:rgba(0,45,99,0.50) !important;}.MuiMenu-list{max-height:368px;&.MuiList-padding{padding:0 !important;}}'],e=>{let{theme:t}=e;return t.breakpoints.mobile},e=>{let{theme:t}=e;return t.colors.placeholder}),eK=p.ZP.div.withConfig({componentId:"sc-dff05aca-0"})(["display:flex;flex-direction:column;@media screen and (","){height:100vh;@supports (height:100dvh){height:100dvh !important;}}"],e=>{let{theme:t}=e;return t.breakpoints.mobile}),eH=p.ZP.div.withConfig({componentId:"sc-dff05aca-1"})(["flex:1;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:16px;padding:24px 16px 48px 16px;@media screen and (","){padding:24px 16px;}"],e=>{let{theme:t}=e;return t.breakpoints.mobile}),eQ=p.ZP.div.withConfig({componentId:"sc-dff05aca-2"})(["width:100%;padding:0 24px;display:flex;align-items:center;justify-content:flex-end;@media screen and (","){padding:24px 16px;}button{width:auto;@media screen and (","){width:100%;}}"],e=>{let{theme:t}=e;return t.breakpoints.mobile},e=>{let{theme:t}=e;return t.breakpoints.mobile})},8060:function(e,t,n){"use strict";let r=n(64956);t.Z=r},16232:function(e){e.exports={"mui-modal__root":"styles_mui-modal__root__KjIkp","bottom-sheet__header":"styles_bottom-sheet__header__qpuo8","bottom-sheet__header--scrolled":"styles_bottom-sheet__header--scrolled__VxHy2","bottom-sheet__header--centered":"styles_bottom-sheet__header--centered__NVMx7","bottom-sheet__body":"styles_bottom-sheet__body__lkfN6","bottom-sheet__paper":"styles_bottom-sheet__paper__Zd9Zi",modal__header:"styles_modal__header__SAhRZ","modal__header--scrolled":"styles_modal__header--scrolled__l8BDN","modal__header--centered":"styles_modal__header--centered__oCulx","modal__title--centered":"styles_modal__title--centered__opits",modal__paper:"styles_modal__paper__Le5N3",modal__body:"styles_modal__body__c4TxM"}},54629:function(e){e.exports={heading:"styles_heading__PwzPA","heading--h1--auto":"styles_heading--h1--auto__0kg4F","heading--h1--desktop":"styles_heading--h1--desktop___Fn_p","heading--h1--mobile":"styles_heading--h1--mobile__bQ2h3","heading--h2--auto":"styles_heading--h2--auto__mSrTW","heading--h2--desktop":"styles_heading--h2--desktop__hoJzW","heading--h2--mobile":"styles_heading--h2--mobile__zKnQJ","heading--h3--auto":"styles_heading--h3--auto__dlg9B","heading--h3--desktop":"styles_heading--h3--desktop__nuykg","heading--h3--mobile":"styles_heading--h3--mobile__vKjWN","heading--h4--auto":"styles_heading--h4--auto__T9_tp","heading--h4--desktop":"styles_heading--h4--desktop__mBwWH","heading--h4--mobile":"styles_heading--h4--mobile__jdJjk","heading--h5--auto":"styles_heading--h5--auto__L6WAf","heading--h5--desktop":"styles_heading--h5--desktop__GjbaF","heading--h5--mobile":"styles_heading--h5--mobile__zPzUV","heading--h6--auto":"styles_heading--h6--auto__gz7md","heading--h6--desktop":"styles_heading--h6--desktop__K_q85","heading--h6--mobile":"styles_heading--h6--mobile__YLSeq","heading--white":"styles_heading--white__bjb1A","heading--navy":"styles_heading--navy__vYr0R","heading--blue":"styles_heading--blue__zk_pX","heading--orange":"styles_heading--orange__1F9Ew","heading--error":"styles_heading--error__u9nCW","heading--grey-100":"styles_heading--grey-100__4_VV0","heading--grey-70":"styles_heading--grey-70__ggNCn","heading--grey-50":"styles_heading--grey-50__qQJ_m"}},20995:function(e){e.exports={paragraph:"styles_paragraph__OBWzw","paragraph--medium":"styles_paragraph--medium__IRBto","paragraph--small":"styles_paragraph--small__aBuD6","paragraph--white":"styles_paragraph--white__eEMoB","paragraph--navy":"styles_paragraph--navy__GIk2w","paragraph--blue":"styles_paragraph--blue__6u5wc","paragraph--orange":"styles_paragraph--orange__lpCxw","paragraph--error":"styles_paragraph--error__PTXjJ","paragraph--grey-100":"styles_paragraph--grey-100__kRQ59","paragraph--grey-70":"styles_paragraph--grey-70__qUkbc","paragraph--grey-50":"styles_paragraph--grey-50__wVNVG"}}
1,9196:function(e){e.exports={subtitle:"styles_subtitle___VXlh","subtitle--white":"styles_subtitle--white__akBY4","subtitle--navy":"styles_subtitle--navy__s82jb","subtitle--blue":"styles_subtitle--blue__tvms9","subtitle--orange":"styles_subtitle--orange__IH_Nm","subtitle--error":"styles_subtitle--error__RItDr","subtitle--grey-100":"styles_subtitle--grey-100__BmA7p","subtitle--grey-70":"styles_subtitle--grey-70__ne2_s","subtitle--grey-50":"styles_subtitle--grey-50__TInGG"}}},function(e){e.O(0,[33714,40744,39569,31933,89111,56817,55934,4466,92888,49774,40179],function(){return e(e.s=10638)}),_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.