@hhgtech/hhg-components 1.22.13 → 1.22.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/components/mantine/index.d.ts +3 -1
- package/build/components/mantine/indicator/index.d.ts +4 -0
- package/build/esm/lead.js +1 -1
- package/build/esm/mantine.js +1 -1
- package/build/lead/campaign.d.ts +11 -1
- package/build/lead/layouts/lightbox.d.ts +13 -1
- package/build/lead/newLeadPopup.d.ts +11 -1
- package/build/lead/oldLeadPopup.d.ts +11 -1
- package/build/lead/style.d.ts +2 -0
- package/build/lead/thankyou.d.ts +1 -2
- package/build/lead.js +1 -1
- package/build/mantine.js +1 -1
- package/package.json +1 -1
- package/build/lead/index.styled.d.ts +0 -1
|
@@ -2,6 +2,8 @@ export type { SelectProps } from './select';
|
|
|
2
2
|
export { Select } from './select';
|
|
3
3
|
export type { DatePickerProps, DateRangePickerProps } from './datepicker';
|
|
4
4
|
export { DatePicker } from './datepicker';
|
|
5
|
+
export { Indicator } from './indicator';
|
|
6
|
+
export type { IndicatorProps } from './indicator';
|
|
5
7
|
export { TextArea } from './textArea';
|
|
6
8
|
export type { TextAreaProps } from './textArea';
|
|
7
9
|
export { Modal } from './modal';
|
|
@@ -15,7 +17,7 @@ export type { AccordionProps } from './accordion';
|
|
|
15
17
|
export { Avatar } from './avatar';
|
|
16
18
|
export type { AvatarProps } from './avatar';
|
|
17
19
|
export { Input } from './input';
|
|
18
|
-
export type { InputProps, FileInputProps, NumberInputProps, PasswordInputProps } from './input';
|
|
20
|
+
export type { InputProps, FileInputProps, NumberInputProps, PasswordInputProps, } from './input';
|
|
19
21
|
export { LoadingOverlay } from './loadingOverlay';
|
|
20
22
|
export type { LoadingOverlayProps } from './loadingOverlay';
|
|
21
23
|
export { Carousel } from './carousel';
|
package/build/esm/lead.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as n,e,b as t,_ as a,a as o}from"./tslib.es6-2fa94e2c.js";import l,{createContext as i,useMemo as r,useContext as d,useState as c,useEffect as s,useRef as m}from"react";import p from"lodash/debounce";import{createPortal as u}from"react-dom";import{T as h}from"./translationsContext-e7808c8f.js";import{g,s as b}from"./cookieHelper-8c12973e.js";import{b as f,a as x}from"./utils-40d4438f.js";import{v1 as k}from"uuid";import{u as _}from"./useTranslations-b3eb31ef.js";import"dayjs";import"./screenSizeContext-ff96a3d1.js";import"./lazyLoad-59e8ff6d.js";import v from"styled-components";import"./index-2cf746a8.js";import"./isProduction-6fc0946c.js";import"./Locale-69030fff.js";import"./gAssets.js";import"string-format";import"lodash/throttle";import"vanilla-lazyload";var w=function(n){var e=n.onClose,t=n.containerClassName,a=n.svgClassName;return l.createElement("button",{onClick:e,className:"le-newbuilder-close-button js-modal__close ".concat(t||"")},l.createElement("svg",{className:"le-newbuilder-close-svg ".concat(a||""),xmlns:"http://www.w3.org/2000/svg",width:"53",height:"53",viewBox:"0 0 53 53"},l.createElement("defs",null,l.createElement("filter",{width:"53",height:"53",filterUnits:"userSpaceOnUse"},l.createElement("feGaussianBlur",{result:"blur",stdDeviation:"3"}),l.createElement("feFlood",{floodOpacity:".4"}),l.createElement("feComposite",{in2:"blur",operator:"in"}),l.createElement("feComposite",{in:"SourceGraphic"})),l.createElement("style",{dangerouslySetInnerHTML:{__html:".cls-2{fill:none;stroke:#fff;stroke-linecap:round;stroke-width:2px}"}})),l.createElement("g",{filter:"url(#Ellipse_482)"},l.createElement("circle",{cx:"17.5",cy:"17.5",r:"17.5",transform:"translate(-483.1 -671.163)translate(483.1 671.16)translate(9 9)",fill:"#005cfd"})),l.createElement("path",{d:"M19 19L34 34",className:"cls-2"}),l.createElement("path",{d:"M34 19L19 34",className:"cls-2"})))},y=function(n){var e=n.popupId,t=n.url,a=n.newTab,o=n.imageDestkop,i=n.imageMobile,r=n.onClose,d=n.onOtherSubmit;return l.createElement("div",{id:e,className:"lead-modal-wrapper","data-popup-url":location.pathname,"data-popup-type":"center_tab"},l.createElement("div",{className:"le-center-tab-popup"},l.createElement("div",{style:{position:"relative"}},l.createElement("a",{className:"js-popup-other-submit",href:t,target:a?"blank":"_parent",onClick:d},l.createElement("img",{className:"le-only-mobile",src:i}),l.createElement("img",{className:"le-only-desktop",src:o})),l.createElement(w,{onClose:r,containerClassName:"le-abs-outer-mobile-top-right-2",svgClassName:"le-mobile-btn"}))))},E=function(n){var e=n.popupId,t=n.url,a=n.title,o=n.urlText,i=n.titleAlign,r=n.subtitle,d=n.subtitleAlign,c=n.newTab,s=n.imageDesktop,m=n.imageMobile,p=n.onClose,u=n.onOtherSubmit;return l.createElement("div",{id:e,className:"lead-modal-wrapper lead-floating-wrapper","data-popup-url":location.pathname,"data-popup-type":"floating"},l.createElement("aside",{className:"le-only-desktop"},l.createElement("div",{className:"le-floating-desktop"},l.createElement("div",{className:"le-floating-desktop-wrap",style:{position:"relative",background:"#fff"}},s?l.createElement("div",null,l.createElement("img",{style:{maxWidth:120,borderTopLeftRadius:5,borderBottomLeftRadius:5},src:s})):null,l.createElement("div",{style:{padding:20}},l.createElement("div",{className:"le-floating-desktop-title le-text-align-".concat(i)},a),l.createElement("div",{className:"le-floating-desktop-desc le-text-align-".concat(d)},r)),l.createElement("a",{target:c?"blank":"_parent",style:{marginLeft:35,textDecoration:"none"},href:t},l.createElement("button",{className:"le-joinbow-floating-btn js-popup-other-submit",onClick:u},o)),l.createElement(w,{onClose:p,containerClassName:"le-abs-outer-top-right"})))),l.createElement("aside",{className:"le-only-mobile"},l.createElement("div",{className:"le-floating-mobile"},l.createElement("div",{className:"le-floating-mobile-wrap",style:{position:"relative",background:"#fff"}},l.createElement("aside",{style:{display:"flex",justifyContent:"space-between"}},l.createElement("div",null,l.createElement("div",{className:"le-floating-mobile-title le-text-align-".concat(i)},a),l.createElement("div",{className:"le-floating-mobile-desc le-text-align-".concat(d)},r)),m?l.createElement("div",null,l.createElement("img",{style:{marginLeft:15,marginTop:4,maxWidth:100},src:m})):null),l.createElement("div",{style:{textAlign:"center",marginTop:10}},l.createElement("a",{target:c?"blank":"_parent",href:t,style:{textDecoration:"none"}},l.createElement("button",{className:"le-joinbow-floating-btn js-popup-other-submit",onClick:u},o))),l.createElement(w,{onClose:p,containerClassName:"le-abs-outer-top-right",svgClassName:"le-mobile-btn"})))))},N=1,C=2,B="https://dev.leadgen.hellobacsi.com/",S=1,T=2,z="";B.includes("localhost")&&(B="https://dev.leadgen.hellobacsi.com/"),location.hostname.includes("marrybaby.vn")&&(z="pink");var j="https://"+location.hostname+location.pathname+location.search;j=j.toLowerCase(),sessionStorage.getItem("insider_object")&&(window.insider_object=JSON.parse(sessionStorage.getItem("insider_object")));var L={"vi-VN":{popupLang:"vi",countryCode:"vn",countryCodeNumber:84},"id-ID":{popupLang:"id",countryCode:"id",countryCodeNumber:62},"th-TH":{popupLang:"th",countryCode:"th",countryCodeNumber:66},"ms-MY":{popupLang:"ms",countryCode:"my",countryCodeNumber:60},"zh-TW":{popupLang:"zh",countryCode:"tw",countryCodeNumber:886},"km-KH":{popupLang:"km",countryCode:"kh",countryCodeNumber:855},"my-MM":{popupLang:"my",countryCode:"mm",countryCodeNumber:95},"hi-IN":{popupLang:"hi",countryCode:"in",countryCodeNumber:91}},O=L[document.documentElement.lang]||L["vi-VN"];var P=i({}),I=function(n){var e=n.content,t=n.inlinePosition,a=r((function(){var n;if(!t)return null;var e=document.querySelector('[data-url="'.concat(location.pathname,'"] .body-content'));if(null===(n=null==e?void 0:e.childNodes)||void 0===n?void 0:n.length){var a=e.querySelectorAll("p"),o=e.querySelectorAll("h2"),l=null;switch(t){case"1th":l=a[0];break;case"2th":l=a[1];break;case"3th":l=a[2];break;case"4th":l=a[3];break;case"5th":l=a[4];break;case"6th":l=a[5];break;case"7th":l=a[6];break;case"8th":l=a[7];break;case"9th":l=a[8];break;case"10th":l=a[9];break;case"11th":l=a[10];break;case"12th":l=a[11];break;case"lastP":l=a[a.length-1];break;case"1thH2":l=o[0];break;case"2thH2":l=o[1];break;case"3thH2":l=o[2];break;case"4thH2":l=o[3];break;case"5thH2":l=o[4];break;case"6thH2":l=o[5];break;case"7thH2":l=o[6];break;case"8thH2":l=o[7];break;case"9thH2":l=o[8];break;case"10thH2":l=o[9];break;case"lastH2":l=o[o.length-1]}if(l){var i=document.createElement("div");return i.classList.add("inline-lead-wrapper"),l.nextElementSibling?e.insertBefore(i,l.nextElementSibling):e.appendChild(i),i}}}),[t]);return t&&a?u(e,a):null},A=function(n){var e=n.content,t=r((function(){var n=[];return document.querySelectorAll(".hc2-sidebar-with-ads,.page-main-col .right-col.f-right,.hhg-lead-sidebar").forEach((function(e){return n.push(e)})),n}),[]);return l.createElement(l.Fragment,null,t.map((function(n){return u(e,f(n,"sidebar-lead-modal-wrapper"))})))},D=function(t){var a,o,i,m=t.popupId,p=t.extraFields,u=t.onClose,h=t.onOtherSubmit,g=t.imageMobile,b=t.imageDesktop,f=t.imageBackground,x=t.currentLayout,k=t.title,v=t.onSubmit,w=_().t,y=JSON.parse(p.listBlockAdded),E=JSON.parse(p.actionBlocks),N=JSON.parse(p.textBlocks),C=d(P).apiUrl,B=E.submitBlock.data.url,S=E.submitBlock.data.text,T=E.submitBlock.data.text2,j=E.submitBlock.data.value,L=location.pathname,D=x.includes("Inline")||"Sidebar"===x,M="Slider"===x,H=c(!0),q=H[0],V=H[1];if(window.innerWidth<769&&["Fullscreen","Slider"].includes(x))return console.log("😎 Not show fullscreen, slider on mobile "),null;s((function(){(x.includes("LightBox")||"Fullscreen"==x)&&document.body.classList.add("noscroll")}),[]);var F=function(t,a){return n(void 0,void 0,void 0,(function(){return e(this,(function(n){switch(n.label){case 0:return a.target.validity.valueMissing?(a.target.setCustomValidity(w("validator.required")),[3,5]):[3,1];case 1:return a.target.validity.valid||a.target.validity.customError?[3,2]:("tel"===t?a.target.setCustomValidity(w("validator.phone")):"date"===t?a.target.setCustomValidity(w("validator.date")):"email"===t&&a.target.setCustomValidity(w("validator.email")),[3,5]);case 2:return"tel"!==t?[3,4]:[4,require("intl-tel-input")];case 3:return n.sent().isValidNumber(String(a.target.value),O.countryCode)?a.target.setCustomValidity(""):a.target.setCustomValidity(w("validator.phone")),[3,5];case 4:a.target.setCustomValidity(""),n.label=5;case 5:return[2]}}))}))},R=r((function(){var n={TextBlock:0,NumberBlock:0,EmailBlock:0,PhoneBlock:0,DateBlock:0,CheckboxBlock:0,RadioBlock:0};return y.map((function(e,t){var a,o;if("TitleBlock"==e.name)return l.createElement("h2",{key:t,className:"lead-modal__title ".concat("le-text-align-"+((null===(a=e.data)||void 0===a?void 0:a.align)||"")," ").concat(z)},e.data.value);if("SubtitleBlock"==e.name)return l.createElement("p",{key:t,className:"lead-modal__description ".concat("le-text-align-"+((null===(o=e.data)||void 0===o?void 0:o.align)||"")," ").concat(z)},e.data.value);if("TextBlock"==e.name)return n.TextBlock+=1,l.createElement("div",{key:t},l.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,"data-key":e.data.value,name:"text"+(n.TextBlock>1?n.TextBlock:""),spellCheck:!1,type:"text",placeholder:e.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(n){return F("text",n)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/text.svg")})));if("NumberBlock"==e.name){var i=l.createElement("div",{key:t},l.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,"data-key":e.data.value,name:"number"+(n.NumberBlock?n.NumberBlock:""),spellCheck:!1,type:"number",min:"0",placeholder:e.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(n){return F("number",n)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/number.svg")})));return n.NumberBlock+=1,i}if("EmailBlock"==e.name){i=l.createElement("div",{key:t},l.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,"data-key":e.data.value,name:"email"+(n.EmailBlock?n.EmailBlock:""),spellCheck:!1,type:"email",placeholder:e.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(n){return F("email",n)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/email.svg")})));return n.EmailBlock+=1,i}if("PhoneBlock"==e.name){i=l.createElement("div",{key:t},l.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,"data-key":e.data.value,name:"tel"+(n.PhoneBlock?n.PhoneBlock:""),spellCheck:!1,type:"tel",placeholder:e.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(n){return F("tel",n)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/tel.svg")})));return n.PhoneBlock+=1,i}if("DateBlock"==e.name){i=l.createElement("div",null,l.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,type:"date","data-key":e.data.value,name:"date"+(n.DateBlock?n.DateBlock:""),placeholder:e.data.placeholder,onClick:function(n){n.currentTarget.classList.remove("placeholderclass")},onBlur:function(n){n.currentTarget.value||n.currentTarget.classList.add("placeholderclass")},className:"dateclass placeholderclass lead-modal__form-control width-100%",onChange:function(n){return F("date",n)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/date.svg")})));return n.DateBlock+=1,i}if("LinkButtonBlock"==e.name)return l.createElement("div",{key:t},l.createElement("a",{target:e.data.newtab?"blank":"parrent",href:e.data.url,style:{textDecoration:"none"}},l.createElement("button",{type:"button",className:"lead-modal__btn js-modal__close js-popup-other-submit ".concat(z),onClick:function(){null==u||u(),null==h||h()}},e.data.value)));if("CheckboxBlock"==e.name){var r=e.data,d=r.listQuestion,c=r.isSendMailChimp,s=void 0!==c&&c;i=l.createElement("div",{key:t,style:{margin:"5px 0"}},l.createElement("div",{className:"le-checkbox-title"},e.data.placeholder),l.createElement("div",{className:"mailchimp-".concat(e.data.value),"data-mailchimp":s}),d.map((function(t,a){return l.createElement("label",{key:a,className:"lead-checkbox-container"},l.createElement("input",{"data-key":e.data.value,name:"checkbox"+(n.CheckboxBlock?n.CheckboxBlock:"")+"[]",value:t.value,type:"checkbox",onChange:function(n){return F("checkbox",n)}}),l.createElement("span",{className:"lead-checkbox-checkmark"}),"$",t.placeholder)})));return n.CheckboxBlock+=1,i}if("RadioBlock"==e.name){d=e.data.listQuestion,i=l.createElement("div",{key:t,style:{margin:"5px 0"}},l.createElement("div",{className:"le-checkbox-title"},e.data.placeholder),d.map((function(t,a){return l.createElement("label",{className:"lead-radio-container",key:a},l.createElement("input",{"data-key":e.data.value,name:"radio"+(n.RadioBlock?n.RadioBlock:""),value:t.value,type:"radio",onChange:function(n){return F("radio",n)}}),l.createElement("span",{className:"lead-radio-checkmark"}),t.placeholder)})));return n.RadioBlock+=1,i}if("DropdownBlock"==e.name){d=e.data.listQuestion,i=l.createElement("div",{key:t,style:{margin:"5px 0"}},l.createElement("div",{className:"le-checkbox-title"},e.data.placeholder),l.createElement("div",{className:"le-newbuilder-select-wrapper"},l.createElement("select",{className:"le-newbuilder-select","data-key":e.data.value,name:"dropdown"+(n.DropdownBlock?n.DropdownBlock:"")},d.forEach((function(n,e){return l.createElement("option",{key:e,value:n.value},n.placeholder)})))));return n.DropdownBlock+=1,i}}))}),[]),W=l.createElement(l.Fragment,null,l.createElement("style",{dangerouslySetInnerHTML:{__html:".le-newbuilder-overlay {\n background: url(".concat(g,") ;\n background-repeat: no-repeat;\n background-size: cover;\n }\n @media screen and (min-width:768px) {\n .le-newbuilder-overlay {\n background: url(").concat(b,") ;\n background-repeat: no-repeat;\n background-size: cover;\n }\n }")}}),l.createElement("div",{id:m,"data-popup-url":L,"data-popup-type":"lightbox-inline",className:"lead-modal lead-modal-wrapper modal--animate-scale ".concat(D?"le-buider-inline":""," ").concat(M?"le-buider-slider":"")},"Fullscreen"==x?l.createElement("img",{className:"le-only-desktop le-fullscreen-img",draggable:!1,src:f||""}):null,l.createElement("div",{className:"lead-modal__wrapper le-newbuilder-wrap-".concat(x)},l.createElement("div",{className:"lead-modal__content le-newbuilder-".concat(x)},l.createElement("header",{className:"lead-modal__header"},["LightBoxA","InlineA","Sidebar","Slider"].includes(x)?g?l.createElement("img",{draggable:"false",className:"lead-modal__image lead-modal-image-cover",src:g,alt:""}):null:l.createElement(l.Fragment,null,b?l.createElement("img",{draggable:"false",className:"le-only-desktop lead-modal__image lead-modal-image-cover",style:{height:"100%",objectFit:"cover"},src:b,alt:""}):null,g?l.createElement("img",{draggable:"false",className:"le-only-mobile lead-modal__image lead-modal-image-cover",src:g,alt:""}):null)),l.createElement("div",{className:"lead-modal__body le-newbuilder-overlay"},l.createElement("form",{className:"lead-modal__form ".concat(m),onSubmit:v},l.createElement("div",{style:{marginBottom:20}},l.createElement("h2",{className:"lead-modal__title ".concat("le-text-align-"+(null===(a=N.titleBlock.data)||void 0===a?void 0:a.align)," ").concat(z)},k),l.createElement("p",{className:"lead-modal__description ".concat("le-text-align-"+(null===(o=N.titleBlock.data)||void 0===o?void 0:o.align)," ").concat(z)},N.subtitleBlock.data.value)),l.createElement("div",null,R),(null===(i=null==E?void 0:E.submitBlock)||void 0===i?void 0:i.isHide)?null:l.createElement(l.Fragment,null,l.createElement("div",{className:"lead-modal__checkbox-wrapper ".concat(z)},l.createElement("div",{className:"lead-modal__checkbox"},l.createElement("input",{id:"lead-term-checkbox",className:"lead-modal__checkbox__input ".concat(z),type:"checkbox","aria-label":"Checkbox label",checked:q,onChange:function(n){return V(n.currentTarget.checked)}}),l.createElement("div",{className:"lead-modal__checkbox__control","aria-hidden":"true"})),l.createElement("label",{htmlFor:"checkbox",className:"lead-modal__checkbox__label"},S," ",l.createElement("span",{style:{fontWeight:"bold"}},l.createElement("a",{target:"blank",href:B||"https://hellobacsi.com/chinh-sach",rel:"noopener noreferrer",style:{textDecoration:"none"}},T)))),l.createElement("button",{id:"lead-submit",type:"submit",className:"lead-modal__btn ".concat(z),disabled:!q}," ",j))))),l.createElement("button",{className:"lead-modal__close-btn ".concat("Fullscreen"==x?"lead-fullscreen-desktop-close-btn":""," js-modal__close ").concat(z),onClick:u},l.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},l.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},l.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),l.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"})))))));return x.includes("LightBox")||"Fullscreen"==x||"Slider"==x?W:"Sidebar"==x?l.createElement(A,{content:W}):x.includes("Inline")?l.createElement(I,{content:W,inlinePosition:p.popupInlinePosition}):null},M=function(n){var e=n.popupId,t=n.link,a=n.linkText,o=n.linkNewTab,i=n.onClose,r=n.imageMobile,d=n.imageDesktop,c=n.currentLayout,s=n.onOtherSubmit,m=location.pathname;return l.createElement("div",{id:e,className:"lead-modal-wrapper","data-popup-url":m,"data-popup-type":"skin_ab"},"SkinA"==c?l.createElement("aside",{className:"le-only-desktop"},l.createElement("div",{className:"le-skin-a-desktop"},l.createElement("div",{style:{position:"relative"}},l.createElement("img",{src:d}),l.createElement("a",{style:{position:"absolute",top:"75%",left:"50%",transform:"translate(-50%, -50%)",textAlign:"center",width:"calc(100% - 15px)"},href:t,target:o?"blank":"_parent"},l.createElement("button",{onClick:s,className:"le-joinbow-btn js-popup-other-submit"},a)),l.createElement("button",{className:"lead-modal__close-btn js-modal__close ".concat(z)},l.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},l.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},l.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),l.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"}))))))):"SkinB"==c?l.createElement("aside",{className:"le-only-desktop"},l.createElement("div",{className:""},l.createElement("div",{style:{position:"relative",zIndex:1e4}},l.createElement("img",{src:d,style:{width:"100%"}}),l.createElement("a",{style:{position:"absolute",top:"75%",left:"50%",transform:"translate(-50%, -50%)",textAlign:"center",width:"100%"},href:t,target:o?"blank":"_parent"},l.createElement("button",{onClick:s,className:"le-joinbow-btn-mobile js-popup-other-submit"},a)),l.createElement(w,{containerClassName:"le-abs-top-right",onClose:i})))):null,l.createElement("aside",{className:"le-only-mobile"},l.createElement("div",{className:"le-skin-mobile"},l.createElement("div",{style:{position:"relative"}},l.createElement("img",{src:r,style:{width:"100%"}}),l.createElement("a",{style:{position:"absolute",top:"82%",left:"50%",transform:"translate(-50%, -50%)",textAlign:"center",maxWidth:"calc(100% - 15px)"},href:t,target:o?"blank":"_parent"},l.createElement("button",{onClick:s,className:"le-joinbow-btn-mobile js-popup-other-submit"},a)),l.createElement(w,{containerClassName:"le-abs-top-right",svgClassName:"le-mobile-btn",onClose:i})))))},H=function(n){var e=n.popupId,t=n.url,a=n.newTab,o=n.image,i=n.onClose,r=n.onOtherSubmit;return l.createElement("div",{id:e,className:"lead-modal-wrapper","data-popup-url":location.pathname,"data-popup-type":"tab"},l.createElement("div",{className:"le-tab-popup"},l.createElement("div",{style:{position:"relative"}},l.createElement("a",{href:t,target:a?"blank":"_parent",onClick:r},l.createElement("img",{className:"js-popup-other-submit",src:o})),l.createElement(w,{onClose:i,containerClassName:"le-abs-outer-mobile-top-right-2",svgClassName:"le-mobile-btn"}))))};var q,V=function(n){var e,t,a=n.campaign,o=n.action,i=n.onSubmit,r=n.onClose;_().t;var c=d(P),p=c.apiUrl,u=c.siteDomain;s((function(){var n=g("_ga")||null;fetch("".concat(p,"api/campaign/").concat(v,"/impression"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:o,url:location.href.toLowerCase(),title_article:document.title,cookie_id:g("hhg-id"),ga_client_id:n})})}),[]);var h=a.extra_fields,f=a.image,x=a.image_desktop,v=a.code,w=a.image_background,N=h.currentLayout,C=h.imageBlocks?JSON.parse(h.imageBlocks):{},B=JSON.parse(h.actionBlocks),S=JSON.parse(h.textBlocks),T=(null===(t=null===(e=null==S?void 0:S.titleBlock)||void 0===e?void 0:e.data)||void 0===t?void 0:t.value)||"",z={1:{},2:{},3:{}},j=m("lead-modal-"+k()),L=function(n){if(void 0===n&&(n="Xin chao {{category_2}} extra"),n.includes("{{category_")){var e="{{category_".length,t=n.search("{{category_");return+n.charAt(e+t)}return null}(T);if(L){console.log("⚡️ Has categoryLevel",L);var O=Array.from(document.getElementsByTagName("META")),I=O.find((function(n){return n.name==="content_category_".concat(L)})),A=O.find((function(n){return n.name==="content_category_en_".concat(L)}));if(!I||!A)return console.log("⚡️ No META TAG for categoryLevel, not show popup",L),null;z[L]={value:I.content,value_en:A.content},T=T.replace("{{category_".concat(L,"}}"),I.content),console.log("⚡️ Set categoryData ",L)}else console.log("⚡️ No categoryLevel",L);var q=function(){var n,e,t,o;if(console.log("👌 Other submit click"),document.body.classList.remove("noscroll"),N.includes("Skin")){var l=document.querySelector("#masthead");l&&(l.style.top="0px !important;")}var i=Number(null!==(e=null===(n=a.rules.find((function(n){return"days_to_show_again"==n.rule})))||void 0===n?void 0:n.value)&&void 0!==e?e:7),d=Number(null!==(o=null===(t=a.rules.find((function(n){return"show_again_after_submit"==n.rule})))||void 0===t?void 0:t.value)&&void 0!==o?o:0);0===d&&(console.log("⛔ Popup never show again!"),b("lead_submited_".concat(v),"target_".concat(h.popupVersion),{domain:"."+u,path:"/"})),1==d&&(console.log("⌛ Popup will show again after ".concat(i," days!")),b("lead_submited_".concat(v),"target_".concat(h.popupVersion),{domain:"."+u,days:i,path:"/"}));var c=g("_ga")||null,s={url:location.href.toLowerCase(),title_article:document.title,meta:[],cookie_id:g("hhg-id"),ga_client_id:c};L&&(s.category=z[L].value_en),fetch("".concat(p,"api/campaign/").concat(v,"/lead"),{method:"POST",body:JSON.stringify(s),headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest"}}).then((function(n){return n.json()})).then((function(n){"error"===n.status&&console.log(n)})).catch((function(n){console.error("Error:",n)})),null==r||r()};return"CenterTab"===N?l.createElement(y,{popupId:j.current,url:C.imageMobile.data.url,newTab:C.imageMobile.data.newtab,imageMobile:f,imageDestkop:x,onClose:r,onOtherSubmit:q}):"Tab"===N?l.createElement(H,{popupId:j.current,url:C.imageMobile.data.url,newTab:C.imageMobile.data.newtab,image:f,onClose:r,onOtherSubmit:q}):"Floating"===N?l.createElement(E,{popupId:j.current,title:T,titleAlign:S.titleBlock.data.align,subtitle:S.subtitleBlock.data.value,subtitleAlign:S.subtitleBlock.data.align,url:B.linkButtonBlock.data.url,urlText:B.linkButtonBlock.data.value,newTab:B.linkButtonBlock.data.newtab,imageMobile:f,imageDesktop:x,onClose:r,onOtherSubmit:q}):N.includes("LightBox")||N.includes("Inline")||"Fullscreen"==N||"Sidebar"==N||"Slider"==N?l.createElement(D,{popupId:j.current,extraFields:h,onClose:r,onOtherSubmit:q,imageMobile:f,imageDesktop:x,imageBackground:w,currentLayout:N,title:T,onSubmit:function(n){return i(n,L,z,j.current)},key:N}):N.includes("Skin")?l.createElement(M,{popupId:j.current,link:B.linkButtonBlock.data.url,linkNewTab:!!B.linkButtonBlock.data.newtab,linkText:B.linkButtonBlock.data.value,onClose:r,onOtherSubmit:q,imageMobile:f,imageDesktop:x,currentLayout:N}):null},F=function(t){var a=t.campaign,o=t.action,i=t.onSubmit,r=t.onClose,m=_().t,p=c(!0),u=p[0],h=p[1];s((function(){document.body.classList.add("noscroll");var n=g("_ga")||null;fetch("".concat(C,"api/campaign/").concat(x,"/impression"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:o||"",url:location.href.toLowerCase(),title_article:document.title,cookie_id:g("hhg-id"),ga_client_id:n})})}),[]);var b=a.extra_fields,f=a.image,x=a.code,k=b.title,v=b.desc,w=b.submit,y=b.popUpTermURL,E=b.popUpTermAgreeText,N=b.popUpTermText,C=d(P).apiUrl,B=b.fields?JSON.parse(b.fields):[],S={tel:0,text:0,date:0,email:0},T=function(t,a){return n(void 0,void 0,void 0,(function(){return e(this,(function(n){switch(n.label){case 0:return a.target.validity.valueMissing?(a.target.setCustomValidity(m("validator.required")),[3,5]):[3,1];case 1:return a.target.validity.valid||a.target.validity.customError?[3,2]:("tel"===t?a.target.setCustomValidity(m("validator.phone")):"date"===t?a.target.setCustomValidity(m("validator.date")):"email"===t&&a.target.setCustomValidity(m("validator.email")),[3,5]);case 2:return"tel"!==t?[3,4]:[4,require("intl-tel-input")];case 3:return n.sent().isValidNumber(String(a.target.value),O.countryCode)?a.target.setCustomValidity(""):a.target.setCustomValidity(m("validator.phone")),[3,5];case 4:a.target.setCustomValidity(""),n.label=5;case 5:return[2]}}))}))},j=B.map((function(n,e){var t=l.createElement(l.Fragment,null);return t="date"==n.control?l.createElement("div",{key:e,className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,type:"date","data-key":n.listEdit[0].value,name:S.date?n.control+S.date:n.control,placeholder:n.listEdit[1].value||"...",onClick:function(n){return n.currentTarget.classList.remove("placeholderclass")},onBlur:function(n){return!n.currentTarget.value&&n.currentTarget.classList.add("placeholderclass")},className:"dateclass placeholderclass lead-modal__form-control width-100%",onChange:function(e){return T(n.control,e)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/").concat(n.name,".svg")})):l.createElement("div",{key:e,className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},l.createElement("input",{required:!0,"data-key":n.listEdit[0].value,name:S[n.control]?n.control+S[n.control]:n.control,spellCheck:!1,type:n.control,placeholder:n.listEdit[1].value||"...",className:"lead-modal__form-control width-100%",onChange:function(e){return T(n.control,e)}}),l.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(C,"admin/img/builder/").concat(n.name,".svg")})),"date"==n.control&&(S.date+=1),"text"==n.control&&(S.text+=1),"tel"==n.control&&(S.tel+=1),"email"==n.control&&(S.email+=1),t}));return l.createElement("div",{id:"lead-modal",className:"lead-modal modal--animate-scale"},l.createElement("div",{className:"lead-modal__wrapper animate__animated "},l.createElement("div",{className:"lead-modal__content"},l.createElement("header",{className:"lead-modal__header"},!!f&&l.createElement("img",{className:"lead-modal__image lead-modal-image-cover",src:f,alt:""})),l.createElement("div",{className:"lead-modal__body"},l.createElement("h2",{className:"lead-modal__title ".concat(z)},k),l.createElement("p",{className:"lead-modal__description ".concat(z)},v),l.createElement("form",{className:"lead-modal__form",onSubmit:function(n){n.preventDefault(),i(n)}},j,l.createElement("div",{className:"lead-modal__checkbox-wrapper ".concat(z)},l.createElement("div",{className:"lead-modal__checkbox"},l.createElement("input",{id:"lead-term-checkbox",className:"lead-modal__checkbox__input ".concat(z),type:"checkbox","aria-label":"Checkbox label",checked:u,onChange:function(n){return h(n.currentTarget.checked)}}),l.createElement("div",{className:"lead-modal__checkbox__control","aria-hidden":"true"})),l.createElement("label",{htmlFor:"checkbox",className:"lead-modal__checkbox__label"},E," ",l.createElement("span",{style:{fontWeight:"bold"}},l.createElement("a",{target:"blank",href:y||"https://hellobacsi.com/chinh-sach",style:{textDecoration:"none"},rel:"noopener noreferrer"},N)))),l.createElement("button",{id:"lead-submit",type:"submit",className:"lead-modal__btn ".concat(z),disabled:!u},w)))),l.createElement("button",{className:"lead-modal__close-btn js-modal__close ".concat(z),onClick:r},l.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},l.createElement("title",null,"Close modal window"),l.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},l.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),l.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"}))))))},R=function(n){var e=n.campaign,t=n.action,a=n.onSubmit,o=n.onClose;return e.extra_fields?"2.1"==e.extra_fields.popupVersion?l.createElement(V,{campaign:e,action:t,onSubmit:a,onClose:o}):l.createElement(F,{campaign:e,action:t,onSubmit:a,onClose:o}):null},W={"validator.required":"This field is required.","validator.remote":"Please fix this field.","validator.email":"Please enter a valid email address.","validator.phone":"Please input correct phone number.","validator.url":"Please enter a valid URL.","validator.date":"Please enter a valid date.","validator.dateISO":"Please enter a valid date (ISO).","validator.number":"Please enter a valid number.","validator.digits":"Please enter only digits.","validator.creditcard":"Please enter a valid credit card number.","validator.equalTo":"Please enter the same value again.","validator.accept":"Please enter a value with a valid extension.","validator.maxlength":"jQuery.validator.format('Please enter no more than {0} characters.","validator.minlength":"jQuery.validator.format('Please enter at least {0} characters.","validator.rangelength":"jQuery.validator.format('Please enter a value between {0} and {1} characters long.","validator.range":"jQuery.validator.format('Please enter a value between {0} and {1}.","validator.max":"jQuery.validator.format('Please enter a value less than or equal to {0}.","validator.min":"jQuery.validator.format('Please enter a value greater than or equal to {0}."},U={"en-PH":W,"vi-VN":{"validator.required":"Vui lòng điền mục này","validator.email":"Vui lòng điền email có thật.","validator.number":"Vui lòng điền số có thật","validator.digits":"Vui lòng chỉ điền số","validator.maxlength":"Vui lòng điền dưới {0} số","validator.minlength":"Vui lòng điền hơn {0} số","validator.remote":"Hãy sửa cho đúng.","validator.url":"Hãy nhập URL.","validator.date":"Hãy nhập ngày.","validator.dateISO":"Hãy nhập ngày (ISO).","validator.creditcard":"Hãy nhập số thẻ tín dụng.","validator.equalTo":"Hãy nhập thêm lần nữa.","validator.extension":"Phần mở rộng không đúng.","validator.rangelength":"Hãy nhập từ {0} đến {1} kí tự.","validator.range":"Hãy nhập từ {0} đến {1}.","validator.max":"Hãy nhập từ {0} trở xuống.","validator.min":"Hãy nhập từ {0} trở lên.","validator.phone":"Nhập đúng định dạng số điện thoại"},"hi-IN":{"validator.required":"इस क्षेत्र की आवश्यकता है।","validator.email":"कृपया एक मान्य ईमेल पता दर्ज करें","validator.number":"कृपया एक वैध संख्या दर्ज करें","validator.digits":"कृपया केवल अंक दर्ज करें","validator.maxlength":"कृपया {0} अक्षर से अधिक दर्ज न करें","validator.minlength":"कृपया कम से कम {0} अक्षर दर्ज करें","validator.phone":"कृपया एक वैध संख्या दर्ज करें"},"id-ID":{"validator.required":"Kolom ini wajib diisi","validator.email":"Tolong daftarkan email yang valid","validator.number":"Tolong daftarkan nomor telepon yang valid","validator.digits":"Tolong masukkan angka saja","validator.maxlength":"Jangan memasukkan lebih dari {0} karakter","validator.minlength":"Tolong ketik sedikitnya {0} karakter","validator.phone":"Tolong daftarkan nomor telepon yang valid"},"ms-MY":{"validator.required":"Bahagian ini wajib diisi.","validator.email":"Sila masukkan alamat emel yang sah.","validator.number":"Sila masukkan no telefon yang sah.","validator.digits":"Sila masukkan nombor digit sahaja.","validator.maxlength":"Sila masukkan tidak lebih dari {0} aksara","validator.minlength":"Sila masukkan sekurang-kurangnya {0} aksara","validator.phone":"Sila masukkan no telefon yang sah."},"my-MM":{"validator.required":"ဒီနေရာမှာ ဖြည့်ဖို့ လိုအပ်ပါတယ်","validator.email":"မှန်ကန်သော အီးမေးလ်လိပ်စာထည့်သွင်းပါ","validator.number":"မှန်ကန်သော ဖုန်းနံပါတ်ထည့်သွင်းပါ","validator.digits":"နံပါတ်များသာဖြည့်ပါ","validator.maxlength":"ကျေးဇူးပြု၍ {0} ထပ်မပိုသော ဂဏန်းများသာဖြည့်ပါ","validator.minlength":"ကျေးဇူးပြု၍ အနည်းဆုံး {0} ဂဏန်းဖြည့်ပါ","validator.phone":"မှန်ကန်သော ဖုန်းနံပါတ်ထည့်သွင်းပါ"},"km-KH":{"validator.required":"ព័ត៌មានចាំបាច់ដែលត្រូវបំពេញ","validator.email":"សូមវាយអាសយដ្ឋានអ៊ីម៉ែលឲ្យបានត្រឹមត្រូវ","validator.number":"សូមវាយបញ្ចូលលេខឲ្យបានត្រឹមត្រូវ","validator.digits":"វាយបញ្ចូលបានតែលេខប៉ុណ្ណោះ","validator.maxlength":"សូមវាយបញ្ចូលកុំឲ្យលើស {0} តួអក្សរ","validator.minlength":"សូមវាយបញ្ចូលតិចបំផុត {0} តួអក្ស","validator.phone":"សូមវាយបញ្ចូលលេខឲ្យបានត្រឹមត្រូវ"},"zh-TW":{"validator.required":"此為必填欄位","validator.email":"請填入有效的 email 地址","validator.number":"請填入有效的電話號碼","validator.digits":"此欄位僅能輸入數字","validator.maxlength":"請輸入少於 {0} 位數","validator.minlength":"請輸入至少 {0} 位數","validator.phone":"請填入有效的電話號碼"},"th-TH":{"validator.required":"ต้องระบุข้อมูลในช่องนี้","validator.email":"กรุณาใส่อีเมล์ที่ถูกต้อง","validator.number":"กรุณาใส่ตัวเลขที่ถูกต้อง","validator.digits":"กรุณาส่เฉพาะตัวเลข","validator.maxlength":"กรุณาใส่ตัวเลขมากกว่า {0} หลัก","validator.minlength":"กรุณาใส่ตัวเลขอย่างน้อย {0} หลัก","validator.phone":"กรุณาใส่ตัวเลขที่ถูกต้อง"},"tl-PH":W},J=function(n){var e=U[n];return e||U["en-PH"]},Q=v.div(q||(q=t(["\n /* lead-modal : start */\n .lead-modal {\n font-family: 'Open sans', sans-serif !important;\n position: fixed;\n z-index: 99999;\n width: 100%;\n height: 100%;\n left: 0;\n top: 0;\n opacity: 1;\n visibility: visible;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: transparent;\n padding: 10px;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n white-space: normal !important;\n }\n\n .lead-modal__wrapper {\n position: relative;\n width: 100%;\n max-width: 450px;\n background-color: #fff;\n border-radius: 6px;\n box-shadow: 0 14px 28px rgba(0, 0, 0, 0.25), 0 10px 10px rgba(0, 0, 0, 0.22);\n }\n\n .lead-modal__content {\n width: inherit;\n overflow: auto;\n /* min-height: 400px; */\n max-height: calc(100vh - 125px);\n -webkit-overflow-scrolling: touch;\n }\n\n .lead-modal__header {\n padding: 0px 0px;\n }\n\n .lead-modal__image {\n display: block;\n margin: 0 auto;\n border: none !important;\n box-shadow: none !important;\n }\n .lead-modal-image-logo {\n margin-top: 15px;\n margin-bottom: 15px;\n }\n\n .lead-modal-image-cover {\n width: 100% !important;\n padding: 0 0px;\n border-top-left-radius: 4px;\n border: none !important;\n box-shadow: none !important;\n margin: 0 !important;\n }\n\n .lead-modal__image + .lead-modal__image {\n /* margin-top: 10px; */\n /* border-radius: 4px; */\n }\n\n .lead-modal__body {\n font-family: 'Open sans', sans-serif !important;\n padding: 15px 15px 25px 15px;\n }\n\n .lead-modal__title {\n font-family: 'Open sans', sans-serif !important;\n font-size: 20px !important;\n font-weight: bold !important;\n font-stretch: normal !important;\n font-style: normal !important;\n line-height: 1.3 !important;\n letter-spacing: -0.4px !important;\n color: #2a4975 !important;\n box-shadow: none !important;\n padding-bottom: 0 !important;\n }\n\n .lead-modal__title.pink {\n color: #2661ad !important;\n }\n\n .lead-modal__description {\n font-family: 'Open sans', sans-serif !important;\n font-size: 13px !important;\n font-weight: normal !important;\n font-stretch: normal !important;\n font-style: normal !important;\n line-height: 1.62 !important;\n letter-spacing: 0.14px !important;\n color: #2c87f3 !important;\n margin-top: 10px !important;\n }\n\n .lead-modal__description.pink {\n color: #3e3f58 !important;\n }\n\n .lead-modal__form-control-wrapper {\n margin-top: 10px;\n margin-left: 0px !important;\n position: relative;\n }\n\n .lead-modal__form-control {\n box-shadow: none !important;\n height: 40px !important;\n width: 100%;\n padding-left: calc(15px + 1.5em + 15px) !important;\n background-color: #fff !important;\n padding-top: 10px !important;\n padding-bottom: 10px !important;\n padding-right: 15px !important;\n border: solid 1px #dddddd !important;\n color: #2a4975 !important;\n line-height: 1.7em !important;\n border-radius: 0 !important;\n font-family: 'Open Sans', sans-serif !important;\n background-image: linear-gradient(transparent, transparent) !important;\n margin-left: 0px !important;\n font-size: 14px !important;\n line-height: 14px !important;\n }\n\n .lead-modal__form-control {\n &:focus {\n border-color: var(--color-primary);\n box-shadow: 0px 0px 0px 3px rgba(44, 135, 243, 0.1);\n outline: none;\n }\n\n &::-webkit-input-placeholder {\n /* Chrome, Firefox, Opera, Safari 10.1+ */\n color: #b5b5b5;\n }\n\n &::-moz-placeholder {\n color: #b5b5b5;\n }\n\n &:-ms-input-placeholder {\n color: #b5b5b5;\n }\n\n &::-ms-input-placeholder {\n color: #b5b5b5;\n }\n\n &::placeholder {\n color: #b5b5b5;\n }\n }\n\n img.lead-modal__form-control-icon {\n display: inline-block !important;\n color: #b5b5b5 !important;\n fill: #b5b5b5 !important;\n line-height: 1 !important;\n flex-shrink: 0 !important;\n max-width: initial !important;\n display: block !important;\n position: absolute !important;\n pointer-events: none !important;\n left: 15px !important;\n top: 10px !important;\n height: 20px !important;\n width: 20px !important;\n border: none !important;\n margin: 0 !important;\n }\n\n .lead-modal__checkbox-wrapper {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n align-items: center;\n margin-top: 15px;\n a {\n color: #2c87f3 !important;\n text-decoration: none !important;\n }\n\n a:visited {\n color: #2c87f3 !important;\n }\n &.pink a,\n &.pink a:visited {\n color: #e55c8a !important;\n }\n }\n\n .lead-modal__checkbox {\n position: relative;\n z-index: 1;\n display: inline-block;\n font-size: 20px;\n }\n\n .lead-modal__checkbox__input {\n position: relative;\n margin: 0 !important;\n padding: 0;\n opacity: 0;\n height: 1em !important;\n width: 1em !important;\n display: block;\n z-index: 1;\n font-size: 1em !important;\n }\n\n .lead-modal__checkbox__control {\n position: absolute;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n z-index: -1;\n pointer-events: none;\n transition: transform 0.2s;\n color: #dddddd;\n &::before,\n &::after {\n content: '';\n position: absolute;\n }\n\n &::before {\n width: 120%;\n height: 120%;\n background-color: currentColor;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%) scale(0);\n opacity: 0;\n border-radius: 50%;\n will-change: transform;\n transition: transform 0.2s;\n }\n\n &::after {\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: #fff;\n border-radius: 6px;\n -webkit-box-shadow: inset 0 0 0 1px #dddddd;\n box-shadow: inset 0 0 0 1px #dddddd;\n }\n\n &:focus::after {\n box-shadow: inset 0 0 0 1px #2c87f3;\n }\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control::after,\n .lead-modal__checkbox__input:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-color: currentColor;\n background-repeat: no-repeat;\n background-position: center;\n background-size: 18px;\n box-shadow: none;\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control {\n color: #2c87f3;\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control::after {\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpolyline points='2.5 8 6.5 12 13.5 3' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5'/%3E%3C/svg%3E\");\n }\n\n .lead-modal__checkbox__input:indeterminate ~ .lead-modal__checkbox__control {\n color: var(--custom-checkbox-color-disabled);\n }\n\n .lead-modal__checkbox__input:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cline x1='2' y1='8' x2='14' y2='8' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'/%3E%3C/svg%3E\");\n }\n\n .lead-modal__checkbox__input:active ~ .lead-modal__checkbox__control {\n transform: scale(0.9);\n }\n\n .lead-modal__checkbox__input:checked:active ~ .lead-modal__checkbox__control,\n .lead-modal__checkbox__input:indeterminate:active\n ~ .lead-modal__checkbox__control {\n transform: scale(1);\n }\n\n .lead-modal__checkbox__input:focus ~ .lead-modal__checkbox__control::before {\n opacity: 0.2;\n transform: translate(-50%, -50%) scale(1);\n }\n\n .lead-modal__checkbox__input.pink ~ .lead-modal__checkbox__control::after {\n border-radius: 50% !important;\n }\n\n .lead-modal__checkbox__input.pink:checked ~ .lead-modal__checkbox__control {\n color: #2661ad;\n }\n\n .lead-modal__checkbox__input.pink:checked\n ~ .lead-modal__checkbox__control::after,\n .lead-modal__checkbox__input.pink:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-size: 12px;\n }\n\n .lead-modal__checkbox__label {\n /* font-family: OpenSans; */\n font-size: 13px;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: 0.14px;\n color: #969696;\n margin-left: 10px;\n margin-bottom: 0 !important;\n }\n\n .lead-modal__btn {\n display: block;\n width: 100%;\n border: none;\n color: #fff;\n padding: 12px 10px;\n font-weight: 700;\n text-align: center;\n margin-top: 15px;\n border-radius: 4px;\n background-color: #2699fb;\n transition: all 0.2s ease-in-out;\n text-shadow: none !important;\n box-shadow: none !important;\n font-family: 'Open sans', sans-serif !important;\n font-size: 14px;\n cursor: pointer !important;\n &:hover,\n &:active {\n background-color: #337eff;\n }\n\n &.pink {\n background-color: #e55c8a;\n }\n\n &.pink:hover {\n background-color: #b4466a;\n }\n }\n\n .lead-modal__close-btn {\n position: absolute;\n padding-top: 5px;\n top: -15px;\n right: -10px;\n width: 35px;\n height: 35px;\n box-shadow: -2px 4px 4px 0 rgba(191, 191, 191, 0.44) !important;\n text-shadow: none !important;\n background-color: #005cfd;\n border-radius: 50%;\n line-height: inherit;\n appearance: none;\n border: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.2s ease-in-out;\n outline: none;\n z-index: 1;\n padding: 5px 13px !important;\n cursor: pointer !important;\n &:hover,\n &:active {\n background-color: #337eff;\n }\n\n &.pink {\n background-color: #fff;\n }\n\n &.pink .lead-modal__close-icon {\n color: #000;\n }\n\n &.pink:hover .lead-modal__close-icon {\n color: #e55c8a;\n transition: 0.3s all ease;\n }\n }\n\n .lead-modal__close-icon {\n display: inline-block;\n color: #fff;\n fill: #fff;\n height: 1em;\n width: 1em;\n line-height: 1;\n flex-shrink: 0;\n max-width: initial;\n transition: 0.3s all ease;\n }\n\n .lead-modal__thank-you {\n padding: 0 15px;\n display: flex;\n align-items: center;\n justify-content: center;\n height: inherit;\n text-align: center;\n min-height: 400px;\n h1 {\n margin-top: 10px;\n font-size: 32px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: -0.23px;\n color: #1b3250;\n }\n\n p {\n margin-top: 5px;\n font-size: 16px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: -0.11px;\n color: #1b3250;\n }\n img {\n max-width: 100% !important;\n border: none !important;\n width: auto !important;\n margin: 0 auto !important;\n }\n\n &.hidden {\n display: none;\n }\n }\n\n /* lead-modal : end */\n\n .modal__container {\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n z-index: 1000000000000;\n pointer-events: none;\n overflow-y: scroll;\n }\n\n .modal__content {\n position: relative;\n width: 80vw;\n margin: auto 0;\n }\n\n /* Make clicks pass-through */\n #nprogress {\n pointer-events: none;\n }\n\n #nprogress .bar {\n background: #223bdd;\n\n position: fixed;\n z-index: 1031;\n top: 0;\n left: 0;\n\n width: 100%;\n height: 2px;\n }\n\n /* Fancy blur effect */\n #nprogress .peg {\n display: block;\n position: absolute;\n right: 0px;\n width: 100px;\n height: 100%;\n box-shadow: 0 0 10px #29d, 0 0 5px #29d;\n opacity: 1;\n transform: rotate(3deg) translate(0px, -4px);\n }\n\n /* Remove these to get rid of the spinner */\n #nprogress .spinner {\n display: block;\n position: fixed;\n z-index: 1031;\n top: 15px;\n right: 15px;\n }\n\n #nprogress .spinner-icon {\n width: 18px;\n height: 18px;\n box-sizing: border-box;\n\n border: solid 2px transparent;\n border-top-color: #29d;\n border-left-color: #29d;\n border-radius: 50%;\n\n -webkit-animation: nprogress-spinner 400ms linear infinite;\n animation: nprogress-spinner 400ms linear infinite;\n }\n\n .nprogress-custom-parent {\n overflow: hidden;\n position: relative;\n }\n\n .nprogress-custom-parent #nprogress .spinner,\n .nprogress-custom-parent #nprogress .bar {\n position: absolute;\n }\n\n @-webkit-keyframes nprogress-spinner {\n 0% {\n -webkit-transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n }\n }\n @keyframes nprogress-spinner {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n\n .lead-modal__btn:disabled {\n background: #d5d5d5 !important;\n }\n\n .dateclass {\n width: 100%;\n }\n\n .dateclass.placeholderclass::before {\n width: 100%;\n content: attr(placeholder);\n color: #b8b8b8;\n }\n\n .dateclass.placeholderclass:hover::before {\n width: 0%;\n content: '';\n }\n\n /* Change Autocomplete styles in Chrome*/\n .lead-modal input:-webkit-autofill,\n .lead-modal input:-webkit-autofill:hover,\n .lead-modal input:-webkit-autofill:focus,\n .lead-modal textarea:-webkit-autofill,\n .lead-modal textarea:-webkit-autofill:hover,\n .lead-modal textarea:-webkit-autofill:focus,\n .lead-modal select:-webkit-autofill,\n .lead-modal select:-webkit-autofill:hover,\n .lead-modal select:-webkit-autofill:focus {\n -webkit-box-shadow: 0 0 0 1000px white inset !important;\n -webkit-text-fill-color: #2a4975;\n }\n\n .lead-modal label.error {\n font-size: 13px;\n color: #fa140f;\n margin-bottom: 0;\n margin-left: 0px !important;\n line-height: 1.65 !important;\n width: 100%;\n display: block;\n }\n\n /* === Lead gen wrapper === */\n .le-text-align-center {\n text-align: center !important;\n }\n .le-text-align-left {\n text-align: left !important;\n }\n .le-text-align-right {\n text-align: right !important;\n }\n\n .le-only-desktop {\n display: none !important;\n }\n .le-only-mobile {\n display: block !important;\n }\n\n .le-only-desktop a {\n text-decoration: none !important;\n }\n\n .le-only-mobile a {\n text-decoration: none !important;\n }\n\n @media screen and (min-width: 992px) {\n .le-newbuilder-LightBoxB,\n .le-newbuilder-InlineB {\n display: flex !important;\n }\n\n .le-newbuilder-LightBoxB .lead-modal__header,\n .le-newbuilder-InlineB .lead-modal__header {\n max-width: 50%;\n }\n }\n\n @media screen and (min-width: 768px) {\n .le-only-desktop {\n display: block !important;\n }\n\n .le-only-mobile {\n display: none !important;\n }\n\n .le-newbuilder-LightBoxB .lead-modal__body,\n .le-newbuilder-InlineB .lead-modal__body {\n flex: 1;\n }\n\n .le-newbuilder-wrap-LightBoxB {\n max-width: 720px !important;\n }\n .le-newbuilder-wrap-InlineB {\n max-width: 100% !important;\n }\n .le-newbuilder-LightBoxB .le-only-desktop.lead-modal-image-cover {\n max-width: 400px !important;\n }\n }\n\n .lead-modal__title {\n margin: 7px 0 !important;\n }\n\n .lead-modal__description {\n margin: 0;\n }\n\n .lead-modal-image-cover,\n .lead-modal__wrapper {\n border-radius: 0px !important;\n }\n\n .lead-modal__form {\n margin: 0;\n display: block !important;\n }\n\n .lead-modal__image + .lead-modal__image {\n margin-top: 0px;\n }\n\n .lead-modal__thank-you {\n width: 100%;\n }\n\n /* Skins */\n .le-skin-a-desktop {\n position: fixed;\n z-index: 99999;\n top: 0;\n left: 0;\n height: 100%;\n display: flex;\n align-items: center;\n }\n\n .le-skin-b-desktop {\n }\n\n .le-join-now {\n }\n\n .le-joinbow-btn {\n background: #2c87f3;\n color: #ffffff;\n font-size: 16px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 30px;\n border: none !important;\n border: 1px solid transparent !important;\n cursor: pointer !important;\n }\n .le-joinbow-btn:hover {\n border: 1px solid white !important;\n }\n\n .le-joinbow-btn-mobile {\n background: #2c87f3;\n color: #ffffff;\n font-size: 14px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 30px;\n border: none !important;\n }\n\n .le-newbuilder-close-svg {\n border-radius: 50%;\n width: 35px;\n height: 35px;\n background: #005cfd;\n cursor: pointer !important;\n }\n .le-mobile-btn {\n width: 24px;\n height: 24px;\n }\n\n .le-newbuilder-close-button {\n padding: 0;\n background: transparent;\n box-shadow: none;\n border: none;\n width: auto !important;\n cursor: pointer !important;\n }\n .le-abs-top-right {\n position: absolute;\n right: 10px;\n top: 10px;\n }\n\n .le-abs-outer-top-right {\n position: absolute;\n right: 0px;\n top: -45px;\n }\n\n /* Skin floating */\n .le-floating-desktop {\n position: fixed;\n bottom: 40px;\n left: 25px;\n z-index: 9999;\n }\n\n .le-floating-desktop-wrap {\n background: #fff;\n backdrop-filter: blur(30px);\n box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);\n padding: 0px;\n padding-right: 30px;\n border-radius: 5px;\n display: flex;\n align-items: center;\n }\n\n .le-floating-desktop-title {\n font-size: 20px;\n font-weight: bold;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.5;\n letter-spacing: normal;\n color: #2a4975;\n max-width: 530px;\n }\n .le-floating-desktop-desc {\n font-size: 13px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.65;\n letter-spacing: normal;\n color: #2699fb;\n max-width: 530px;\n }\n\n .le-joinbow-floating-btn {\n background: #2c87f3;\n color: #ffffff;\n font-size: 14px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 40px;\n border: none !important;\n border: 1px solid transparent !important;\n font-weight: 500;\n cursor: pointer !important;\n }\n\n /* // Floating mobile */\n .le-floating-mobile {\n position: fixed;\n bottom: 0px;\n left: 0px;\n width: 100%;\n z-index: 9999;\n }\n .le-abs-outer-mobile-top-right {\n position: absolute;\n right: 2px;\n top: -30px;\n }\n\n .le-floating-mobile-wrap {\n background: #fff;\n box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);\n padding: 10px 15px;\n }\n .le-floating-mobile-title {\n font-size: 18px;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.5;\n letter-spacing: normal;\n color: #2a4975;\n font-weight: 600;\n }\n .le-floating-mobile-desc {\n font-size: 12px;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.65;\n letter-spacing: normal;\n color: #2699fb;\n }\n\n /* // Tab popup */\n .le-tab-popup {\n position: fixed;\n bottom: 15px;\n left: 15px;\n max-width: 150px;\n }\n .le-abs-outer-mobile-top-right-2 {\n position: absolute;\n right: -12px;\n top: -15px;\n }\n\n .le-center-tab-popup {\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n z-index: 99999999 !important;\n width: calc(100% - 40px);\n max-width: 400px;\n }\n\n .le-center-tab-popup img {\n max-width: 100% !important;\n }\n\n /* // Popup */\n .le-checkbox-title {\n font-size: 15px;\n font-weight: bold;\n font-stretch: normal;\n font-style: normal;\n color: #2a4975;\n margin: 13px 0 !important;\n /* line-height: 1.65 !important; */\n }\n\n /* Checkbox */\n .lead-checkbox-container {\n position: relative;\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 14px;\n line-height: 1.65;\n margin: 10px 0;\n }\n\n .lead-checkbox-checkmark {\n display: inline-block;\n height: 24px;\n border: solid 1px #d0d0d0;\n vertical-align: middle;\n margin-right: 8px;\n position: relative;\n border-radius: 4px;\n flex: 0 0 24px;\n }\n\n .lead-checkbox-container input {\n position: absolute;\n opacity: 0;\n top: 0;\n left: 0;\n }\n\n .lead-checkbox-checkmark::after {\n position: absolute;\n content: '';\n }\n\n .lead-checkbox-container input:checked ~ .lead-checkbox-checkmark {\n background: #337eff;\n border: solid 1px #337eff;\n }\n\n .lead-checkbox-container input:checked ~ .lead-checkbox-checkmark::after {\n left: 8px;\n top: 3px;\n width: 7px;\n height: 12px;\n border: solid white;\n border-width: 0 2px 2px 0;\n transform: rotate(45deg);\n }\n /* End checkbox */\n\n .le-fullscreen-img {\n position: absolute;\n left: 0;\n top: 0;\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n @media screen and (min-width: 768px) {\n .lead-fullscreen-desktop-close-btn {\n position: fixed;\n top: 27px;\n right: 23px;\n }\n }\n\n /* // Inline */\n .lead-modal.le-buider-inline {\n position: static;\n display: block;\n padding: 20px 0;\n height: initial !important;\n padding-top: 10px;\n }\n\n .lead-modal.le-buider-inline .lead-modal__wrapper {\n box-shadow: none;\n border: 1px solid #ddd;\n }\n .lead-modal.le-buider-inline .lead-modal__content {\n max-height: initial !important;\n }\n .lead-modal.le-buider-inline .lead-modal__content .lead-modal__header img {\n /* height: auto !important; */\n object-fit: fill;\n }\n\n .le-thankyou-title {\n font-size: 24px !important;\n margin-bottom: 8px !important;\n color: #2a4975 !important;\n }\n\n .le-thankyou-subtitle {\n font-size: 14px !important;\n color: #2699fb !important;\n margin: 0 !important;\n }\n\n /* Radio */\n .lead-radio-container {\n position: relative;\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 14px;\n line-height: 1.65;\n margin: 10px 0;\n }\n\n .lead-radio-checkmark {\n display: inline-block;\n height: 24px;\n border: solid 1px #d0d0d0;\n vertical-align: middle;\n margin-right: 8px;\n position: relative;\n border-radius: 50%;\n flex: 0 0 24px;\n }\n\n .lead-radio-container input {\n position: absolute;\n opacity: 0;\n top: 0;\n left: 0;\n }\n\n .lead-radio-checkmark::after {\n position: absolute;\n content: '';\n }\n\n .lead-radio-container input:checked ~ .lead-radio-checkmark {\n background: #337eff;\n border: solid 1px #337eff;\n }\n\n .lead-radio-container input:checked ~ .lead-radio-checkmark::after {\n left: 50%;\n top: 50%;\n width: 8px;\n height: 8px;\n background: #fff;\n border-radius: 50%;\n transform: translate(-50%, -50%);\n }\n /* End Radio */\n\n /* Dropdown */\n .le-newbuilder-select {\n width: 100%;\n padding: 12px;\n border-radius: 4px;\n border: solid 1px #d0d0d0;\n outline: none;\n appearance: none;\n font-size: 15px;\n padding-right: 35px;\n }\n .le-newbuilder-select-wrapper {\n position: relative;\n }\n .le-newbuilder-select-wrapper::after {\n content: '';\n position: absolute;\n right: 15px;\n top: 18px;\n transform: rotate(45deg);\n width: 10px;\n height: 10px;\n border: 2px solid #616060;\n border-left: transparent;\n border-top: transparent;\n }\n /* End Dropdown */\n\n .le-buider-slider {\n width: 420px;\n height: auto;\n bottom: 15px;\n top: unset;\n left: -200px;\n animation: le-builder-slide 0.5s forwards;\n }\n\n @keyframes le-builder-slide {\n 100% {\n left: 15px;\n }\n }\n\n @media screen and (max-width: 768px) {\n .le-buider-slider,\n .le-buider-fullscreen {\n display: none !important;\n }\n }\n\n .le-skin-mobile {\n margin-top: 64px;\n }\n"],["\n /* lead-modal : start */\n .lead-modal {\n font-family: 'Open sans', sans-serif !important;\n position: fixed;\n z-index: 99999;\n width: 100%;\n height: 100%;\n left: 0;\n top: 0;\n opacity: 1;\n visibility: visible;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: transparent;\n padding: 10px;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n white-space: normal !important;\n }\n\n .lead-modal__wrapper {\n position: relative;\n width: 100%;\n max-width: 450px;\n background-color: #fff;\n border-radius: 6px;\n box-shadow: 0 14px 28px rgba(0, 0, 0, 0.25), 0 10px 10px rgba(0, 0, 0, 0.22);\n }\n\n .lead-modal__content {\n width: inherit;\n overflow: auto;\n /* min-height: 400px; */\n max-height: calc(100vh - 125px);\n -webkit-overflow-scrolling: touch;\n }\n\n .lead-modal__header {\n padding: 0px 0px;\n }\n\n .lead-modal__image {\n display: block;\n margin: 0 auto;\n border: none !important;\n box-shadow: none !important;\n }\n .lead-modal-image-logo {\n margin-top: 15px;\n margin-bottom: 15px;\n }\n\n .lead-modal-image-cover {\n width: 100% !important;\n padding: 0 0px;\n border-top-left-radius: 4px;\n border: none !important;\n box-shadow: none !important;\n margin: 0 !important;\n }\n\n .lead-modal__image + .lead-modal__image {\n /* margin-top: 10px; */\n /* border-radius: 4px; */\n }\n\n .lead-modal__body {\n font-family: 'Open sans', sans-serif !important;\n padding: 15px 15px 25px 15px;\n }\n\n .lead-modal__title {\n font-family: 'Open sans', sans-serif !important;\n font-size: 20px !important;\n font-weight: bold !important;\n font-stretch: normal !important;\n font-style: normal !important;\n line-height: 1.3 !important;\n letter-spacing: -0.4px !important;\n color: #2a4975 !important;\n box-shadow: none !important;\n padding-bottom: 0 !important;\n }\n\n .lead-modal__title.pink {\n color: #2661ad !important;\n }\n\n .lead-modal__description {\n font-family: 'Open sans', sans-serif !important;\n font-size: 13px !important;\n font-weight: normal !important;\n font-stretch: normal !important;\n font-style: normal !important;\n line-height: 1.62 !important;\n letter-spacing: 0.14px !important;\n color: #2c87f3 !important;\n margin-top: 10px !important;\n }\n\n .lead-modal__description.pink {\n color: #3e3f58 !important;\n }\n\n .lead-modal__form-control-wrapper {\n margin-top: 10px;\n margin-left: 0px !important;\n position: relative;\n }\n\n .lead-modal__form-control {\n box-shadow: none !important;\n height: 40px !important;\n width: 100%;\n padding-left: calc(15px + 1.5em + 15px) !important;\n background-color: #fff !important;\n padding-top: 10px !important;\n padding-bottom: 10px !important;\n padding-right: 15px !important;\n border: solid 1px #dddddd !important;\n color: #2a4975 !important;\n line-height: 1.7em !important;\n border-radius: 0 !important;\n font-family: 'Open Sans', sans-serif !important;\n background-image: linear-gradient(transparent, transparent) !important;\n margin-left: 0px !important;\n font-size: 14px !important;\n line-height: 14px !important;\n }\n\n .lead-modal__form-control {\n &:focus {\n border-color: var(--color-primary);\n box-shadow: 0px 0px 0px 3px rgba(44, 135, 243, 0.1);\n outline: none;\n }\n\n &::-webkit-input-placeholder {\n /* Chrome, Firefox, Opera, Safari 10.1+ */\n color: #b5b5b5;\n }\n\n &::-moz-placeholder {\n color: #b5b5b5;\n }\n\n &:-ms-input-placeholder {\n color: #b5b5b5;\n }\n\n &::-ms-input-placeholder {\n color: #b5b5b5;\n }\n\n &::placeholder {\n color: #b5b5b5;\n }\n }\n\n img.lead-modal__form-control-icon {\n display: inline-block !important;\n color: #b5b5b5 !important;\n fill: #b5b5b5 !important;\n line-height: 1 !important;\n flex-shrink: 0 !important;\n max-width: initial !important;\n display: block !important;\n position: absolute !important;\n pointer-events: none !important;\n left: 15px !important;\n top: 10px !important;\n height: 20px !important;\n width: 20px !important;\n border: none !important;\n margin: 0 !important;\n }\n\n .lead-modal__checkbox-wrapper {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n align-items: center;\n margin-top: 15px;\n a {\n color: #2c87f3 !important;\n text-decoration: none !important;\n }\n\n a:visited {\n color: #2c87f3 !important;\n }\n &.pink a,\n &.pink a:visited {\n color: #e55c8a !important;\n }\n }\n\n .lead-modal__checkbox {\n position: relative;\n z-index: 1;\n display: inline-block;\n font-size: 20px;\n }\n\n .lead-modal__checkbox__input {\n position: relative;\n margin: 0 !important;\n padding: 0;\n opacity: 0;\n height: 1em !important;\n width: 1em !important;\n display: block;\n z-index: 1;\n font-size: 1em !important;\n }\n\n .lead-modal__checkbox__control {\n position: absolute;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n z-index: -1;\n pointer-events: none;\n transition: transform 0.2s;\n color: #dddddd;\n &::before,\n &::after {\n content: '';\n position: absolute;\n }\n\n &::before {\n width: 120%;\n height: 120%;\n background-color: currentColor;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%) scale(0);\n opacity: 0;\n border-radius: 50%;\n will-change: transform;\n transition: transform 0.2s;\n }\n\n &::after {\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: #fff;\n border-radius: 6px;\n -webkit-box-shadow: inset 0 0 0 1px #dddddd;\n box-shadow: inset 0 0 0 1px #dddddd;\n }\n\n &:focus::after {\n box-shadow: inset 0 0 0 1px #2c87f3;\n }\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control::after,\n .lead-modal__checkbox__input:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-color: currentColor;\n background-repeat: no-repeat;\n background-position: center;\n background-size: 18px;\n box-shadow: none;\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control {\n color: #2c87f3;\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control::after {\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpolyline points='2.5 8 6.5 12 13.5 3' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5'/%3E%3C/svg%3E\");\n }\n\n .lead-modal__checkbox__input:indeterminate ~ .lead-modal__checkbox__control {\n color: var(--custom-checkbox-color-disabled);\n }\n\n .lead-modal__checkbox__input:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cline x1='2' y1='8' x2='14' y2='8' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'/%3E%3C/svg%3E\");\n }\n\n .lead-modal__checkbox__input:active ~ .lead-modal__checkbox__control {\n transform: scale(0.9);\n }\n\n .lead-modal__checkbox__input:checked:active ~ .lead-modal__checkbox__control,\n .lead-modal__checkbox__input:indeterminate:active\n ~ .lead-modal__checkbox__control {\n transform: scale(1);\n }\n\n .lead-modal__checkbox__input:focus ~ .lead-modal__checkbox__control::before {\n opacity: 0.2;\n transform: translate(-50%, -50%) scale(1);\n }\n\n .lead-modal__checkbox__input.pink ~ .lead-modal__checkbox__control::after {\n border-radius: 50% !important;\n }\n\n .lead-modal__checkbox__input.pink:checked ~ .lead-modal__checkbox__control {\n color: #2661ad;\n }\n\n .lead-modal__checkbox__input.pink:checked\n ~ .lead-modal__checkbox__control::after,\n .lead-modal__checkbox__input.pink:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-size: 12px;\n }\n\n .lead-modal__checkbox__label {\n /* font-family: OpenSans; */\n font-size: 13px;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: 0.14px;\n color: #969696;\n margin-left: 10px;\n margin-bottom: 0 !important;\n }\n\n .lead-modal__btn {\n display: block;\n width: 100%;\n border: none;\n color: #fff;\n padding: 12px 10px;\n font-weight: 700;\n text-align: center;\n margin-top: 15px;\n border-radius: 4px;\n background-color: #2699fb;\n transition: all 0.2s ease-in-out;\n text-shadow: none !important;\n box-shadow: none !important;\n font-family: 'Open sans', sans-serif !important;\n font-size: 14px;\n cursor: pointer !important;\n &:hover,\n &:active {\n background-color: #337eff;\n }\n\n &.pink {\n background-color: #e55c8a;\n }\n\n &.pink:hover {\n background-color: #b4466a;\n }\n }\n\n .lead-modal__close-btn {\n position: absolute;\n padding-top: 5px;\n top: -15px;\n right: -10px;\n width: 35px;\n height: 35px;\n box-shadow: -2px 4px 4px 0 rgba(191, 191, 191, 0.44) !important;\n text-shadow: none !important;\n background-color: #005cfd;\n border-radius: 50%;\n line-height: inherit;\n appearance: none;\n border: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.2s ease-in-out;\n outline: none;\n z-index: 1;\n padding: 5px 13px !important;\n cursor: pointer !important;\n &:hover,\n &:active {\n background-color: #337eff;\n }\n\n &.pink {\n background-color: #fff;\n }\n\n &.pink .lead-modal__close-icon {\n color: #000;\n }\n\n &.pink:hover .lead-modal__close-icon {\n color: #e55c8a;\n transition: 0.3s all ease;\n }\n }\n\n .lead-modal__close-icon {\n display: inline-block;\n color: #fff;\n fill: #fff;\n height: 1em;\n width: 1em;\n line-height: 1;\n flex-shrink: 0;\n max-width: initial;\n transition: 0.3s all ease;\n }\n\n .lead-modal__thank-you {\n padding: 0 15px;\n display: flex;\n align-items: center;\n justify-content: center;\n height: inherit;\n text-align: center;\n min-height: 400px;\n h1 {\n margin-top: 10px;\n font-size: 32px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: -0.23px;\n color: #1b3250;\n }\n\n p {\n margin-top: 5px;\n font-size: 16px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: -0.11px;\n color: #1b3250;\n }\n img {\n max-width: 100% !important;\n border: none !important;\n width: auto !important;\n margin: 0 auto !important;\n }\n\n &.hidden {\n display: none;\n }\n }\n\n /* lead-modal : end */\n\n .modal__container {\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n z-index: 1000000000000;\n pointer-events: none;\n overflow-y: scroll;\n }\n\n .modal__content {\n position: relative;\n width: 80vw;\n margin: auto 0;\n }\n\n /* Make clicks pass-through */\n #nprogress {\n pointer-events: none;\n }\n\n #nprogress .bar {\n background: #223bdd;\n\n position: fixed;\n z-index: 1031;\n top: 0;\n left: 0;\n\n width: 100%;\n height: 2px;\n }\n\n /* Fancy blur effect */\n #nprogress .peg {\n display: block;\n position: absolute;\n right: 0px;\n width: 100px;\n height: 100%;\n box-shadow: 0 0 10px #29d, 0 0 5px #29d;\n opacity: 1;\n transform: rotate(3deg) translate(0px, -4px);\n }\n\n /* Remove these to get rid of the spinner */\n #nprogress .spinner {\n display: block;\n position: fixed;\n z-index: 1031;\n top: 15px;\n right: 15px;\n }\n\n #nprogress .spinner-icon {\n width: 18px;\n height: 18px;\n box-sizing: border-box;\n\n border: solid 2px transparent;\n border-top-color: #29d;\n border-left-color: #29d;\n border-radius: 50%;\n\n -webkit-animation: nprogress-spinner 400ms linear infinite;\n animation: nprogress-spinner 400ms linear infinite;\n }\n\n .nprogress-custom-parent {\n overflow: hidden;\n position: relative;\n }\n\n .nprogress-custom-parent #nprogress .spinner,\n .nprogress-custom-parent #nprogress .bar {\n position: absolute;\n }\n\n @-webkit-keyframes nprogress-spinner {\n 0% {\n -webkit-transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n }\n }\n @keyframes nprogress-spinner {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n\n .lead-modal__btn:disabled {\n background: #d5d5d5 !important;\n }\n\n .dateclass {\n width: 100%;\n }\n\n .dateclass.placeholderclass::before {\n width: 100%;\n content: attr(placeholder);\n color: #b8b8b8;\n }\n\n .dateclass.placeholderclass:hover::before {\n width: 0%;\n content: '';\n }\n\n /* Change Autocomplete styles in Chrome*/\n .lead-modal input:-webkit-autofill,\n .lead-modal input:-webkit-autofill:hover,\n .lead-modal input:-webkit-autofill:focus,\n .lead-modal textarea:-webkit-autofill,\n .lead-modal textarea:-webkit-autofill:hover,\n .lead-modal textarea:-webkit-autofill:focus,\n .lead-modal select:-webkit-autofill,\n .lead-modal select:-webkit-autofill:hover,\n .lead-modal select:-webkit-autofill:focus {\n -webkit-box-shadow: 0 0 0 1000px white inset !important;\n -webkit-text-fill-color: #2a4975;\n }\n\n .lead-modal label.error {\n font-size: 13px;\n color: #fa140f;\n margin-bottom: 0;\n margin-left: 0px !important;\n line-height: 1.65 !important;\n width: 100%;\n display: block;\n }\n\n /* === Lead gen wrapper === */\n .le-text-align-center {\n text-align: center !important;\n }\n .le-text-align-left {\n text-align: left !important;\n }\n .le-text-align-right {\n text-align: right !important;\n }\n\n .le-only-desktop {\n display: none !important;\n }\n .le-only-mobile {\n display: block !important;\n }\n\n .le-only-desktop a {\n text-decoration: none !important;\n }\n\n .le-only-mobile a {\n text-decoration: none !important;\n }\n\n @media screen and (min-width: 992px) {\n .le-newbuilder-LightBoxB,\n .le-newbuilder-InlineB {\n display: flex !important;\n }\n\n .le-newbuilder-LightBoxB .lead-modal__header,\n .le-newbuilder-InlineB .lead-modal__header {\n max-width: 50%;\n }\n }\n\n @media screen and (min-width: 768px) {\n .le-only-desktop {\n display: block !important;\n }\n\n .le-only-mobile {\n display: none !important;\n }\n\n .le-newbuilder-LightBoxB .lead-modal__body,\n .le-newbuilder-InlineB .lead-modal__body {\n flex: 1;\n }\n\n .le-newbuilder-wrap-LightBoxB {\n max-width: 720px !important;\n }\n .le-newbuilder-wrap-InlineB {\n max-width: 100% !important;\n }\n .le-newbuilder-LightBoxB .le-only-desktop.lead-modal-image-cover {\n max-width: 400px !important;\n }\n }\n\n .lead-modal__title {\n margin: 7px 0 !important;\n }\n\n .lead-modal__description {\n margin: 0;\n }\n\n .lead-modal-image-cover,\n .lead-modal__wrapper {\n border-radius: 0px !important;\n }\n\n .lead-modal__form {\n margin: 0;\n display: block !important;\n }\n\n .lead-modal__image + .lead-modal__image {\n margin-top: 0px;\n }\n\n .lead-modal__thank-you {\n width: 100%;\n }\n\n /* Skins */\n .le-skin-a-desktop {\n position: fixed;\n z-index: 99999;\n top: 0;\n left: 0;\n height: 100%;\n display: flex;\n align-items: center;\n }\n\n .le-skin-b-desktop {\n }\n\n .le-join-now {\n }\n\n .le-joinbow-btn {\n background: #2c87f3;\n color: #ffffff;\n font-size: 16px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 30px;\n border: none !important;\n border: 1px solid transparent !important;\n cursor: pointer !important;\n }\n .le-joinbow-btn:hover {\n border: 1px solid white !important;\n }\n\n .le-joinbow-btn-mobile {\n background: #2c87f3;\n color: #ffffff;\n font-size: 14px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 30px;\n border: none !important;\n }\n\n .le-newbuilder-close-svg {\n border-radius: 50%;\n width: 35px;\n height: 35px;\n background: #005cfd;\n cursor: pointer !important;\n }\n .le-mobile-btn {\n width: 24px;\n height: 24px;\n }\n\n .le-newbuilder-close-button {\n padding: 0;\n background: transparent;\n box-shadow: none;\n border: none;\n width: auto !important;\n cursor: pointer !important;\n }\n .le-abs-top-right {\n position: absolute;\n right: 10px;\n top: 10px;\n }\n\n .le-abs-outer-top-right {\n position: absolute;\n right: 0px;\n top: -45px;\n }\n\n /* Skin floating */\n .le-floating-desktop {\n position: fixed;\n bottom: 40px;\n left: 25px;\n z-index: 9999;\n }\n\n .le-floating-desktop-wrap {\n background: #fff;\n backdrop-filter: blur(30px);\n box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);\n padding: 0px;\n padding-right: 30px;\n border-radius: 5px;\n display: flex;\n align-items: center;\n }\n\n .le-floating-desktop-title {\n font-size: 20px;\n font-weight: bold;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.5;\n letter-spacing: normal;\n color: #2a4975;\n max-width: 530px;\n }\n .le-floating-desktop-desc {\n font-size: 13px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.65;\n letter-spacing: normal;\n color: #2699fb;\n max-width: 530px;\n }\n\n .le-joinbow-floating-btn {\n background: #2c87f3;\n color: #ffffff;\n font-size: 14px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 40px;\n border: none !important;\n border: 1px solid transparent !important;\n font-weight: 500;\n cursor: pointer !important;\n }\n\n /* // Floating mobile */\n .le-floating-mobile {\n position: fixed;\n bottom: 0px;\n left: 0px;\n width: 100%;\n z-index: 9999;\n }\n .le-abs-outer-mobile-top-right {\n position: absolute;\n right: 2px;\n top: -30px;\n }\n\n .le-floating-mobile-wrap {\n background: #fff;\n box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);\n padding: 10px 15px;\n }\n .le-floating-mobile-title {\n font-size: 18px;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.5;\n letter-spacing: normal;\n color: #2a4975;\n font-weight: 600;\n }\n .le-floating-mobile-desc {\n font-size: 12px;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.65;\n letter-spacing: normal;\n color: #2699fb;\n }\n\n /* // Tab popup */\n .le-tab-popup {\n position: fixed;\n bottom: 15px;\n left: 15px;\n max-width: 150px;\n }\n .le-abs-outer-mobile-top-right-2 {\n position: absolute;\n right: -12px;\n top: -15px;\n }\n\n .le-center-tab-popup {\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n z-index: 99999999 !important;\n width: calc(100% - 40px);\n max-width: 400px;\n }\n\n .le-center-tab-popup img {\n max-width: 100% !important;\n }\n\n /* // Popup */\n .le-checkbox-title {\n font-size: 15px;\n font-weight: bold;\n font-stretch: normal;\n font-style: normal;\n color: #2a4975;\n margin: 13px 0 !important;\n /* line-height: 1.65 !important; */\n }\n\n /* Checkbox */\n .lead-checkbox-container {\n position: relative;\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 14px;\n line-height: 1.65;\n margin: 10px 0;\n }\n\n .lead-checkbox-checkmark {\n display: inline-block;\n height: 24px;\n border: solid 1px #d0d0d0;\n vertical-align: middle;\n margin-right: 8px;\n position: relative;\n border-radius: 4px;\n flex: 0 0 24px;\n }\n\n .lead-checkbox-container input {\n position: absolute;\n opacity: 0;\n top: 0;\n left: 0;\n }\n\n .lead-checkbox-checkmark::after {\n position: absolute;\n content: '';\n }\n\n .lead-checkbox-container input:checked ~ .lead-checkbox-checkmark {\n background: #337eff;\n border: solid 1px #337eff;\n }\n\n .lead-checkbox-container input:checked ~ .lead-checkbox-checkmark::after {\n left: 8px;\n top: 3px;\n width: 7px;\n height: 12px;\n border: solid white;\n border-width: 0 2px 2px 0;\n transform: rotate(45deg);\n }\n /* End checkbox */\n\n .le-fullscreen-img {\n position: absolute;\n left: 0;\n top: 0;\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n @media screen and (min-width: 768px) {\n .lead-fullscreen-desktop-close-btn {\n position: fixed;\n top: 27px;\n right: 23px;\n }\n }\n\n /* // Inline */\n .lead-modal.le-buider-inline {\n position: static;\n display: block;\n padding: 20px 0;\n height: initial !important;\n padding-top: 10px;\n }\n\n .lead-modal.le-buider-inline .lead-modal__wrapper {\n box-shadow: none;\n border: 1px solid #ddd;\n }\n .lead-modal.le-buider-inline .lead-modal__content {\n max-height: initial !important;\n }\n .lead-modal.le-buider-inline .lead-modal__content .lead-modal__header img {\n /* height: auto !important; */\n object-fit: fill;\n }\n\n .le-thankyou-title {\n font-size: 24px !important;\n margin-bottom: 8px !important;\n color: #2a4975 !important;\n }\n\n .le-thankyou-subtitle {\n font-size: 14px !important;\n color: #2699fb !important;\n margin: 0 !important;\n }\n\n /* Radio */\n .lead-radio-container {\n position: relative;\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 14px;\n line-height: 1.65;\n margin: 10px 0;\n }\n\n .lead-radio-checkmark {\n display: inline-block;\n height: 24px;\n border: solid 1px #d0d0d0;\n vertical-align: middle;\n margin-right: 8px;\n position: relative;\n border-radius: 50%;\n flex: 0 0 24px;\n }\n\n .lead-radio-container input {\n position: absolute;\n opacity: 0;\n top: 0;\n left: 0;\n }\n\n .lead-radio-checkmark::after {\n position: absolute;\n content: '';\n }\n\n .lead-radio-container input:checked ~ .lead-radio-checkmark {\n background: #337eff;\n border: solid 1px #337eff;\n }\n\n .lead-radio-container input:checked ~ .lead-radio-checkmark::after {\n left: 50%;\n top: 50%;\n width: 8px;\n height: 8px;\n background: #fff;\n border-radius: 50%;\n transform: translate(-50%, -50%);\n }\n /* End Radio */\n\n /* Dropdown */\n .le-newbuilder-select {\n width: 100%;\n padding: 12px;\n border-radius: 4px;\n border: solid 1px #d0d0d0;\n outline: none;\n appearance: none;\n font-size: 15px;\n padding-right: 35px;\n }\n .le-newbuilder-select-wrapper {\n position: relative;\n }\n .le-newbuilder-select-wrapper::after {\n content: '';\n position: absolute;\n right: 15px;\n top: 18px;\n transform: rotate(45deg);\n width: 10px;\n height: 10px;\n border: 2px solid #616060;\n border-left: transparent;\n border-top: transparent;\n }\n /* End Dropdown */\n\n .le-buider-slider {\n width: 420px;\n height: auto;\n bottom: 15px;\n top: unset;\n left: -200px;\n animation: le-builder-slide 0.5s forwards;\n }\n\n @keyframes le-builder-slide {\n 100% {\n left: 15px;\n }\n }\n\n @media screen and (max-width: 768px) {\n .le-buider-slider,\n .le-buider-fullscreen {\n display: none !important;\n }\n }\n\n .le-skin-mobile {\n margin-top: 64px;\n }\n"]))),G=function(n){var e=n.title,t=n.titleAlign,a=n.subtitle,o=n.subtitleAlign,i=n.link,r=n.linkNewTab,d=n.linkText,c=n.image,s=n.onClose;return l.createElement("div",{id:"lead-modal",className:"lead-modal modal--animate-scale"},l.createElement("div",{className:"lead-modal__wrapper animate__animated "},l.createElement("div",{className:"lead-modal__content"},l.createElement("div",{className:"lead-modal__thank-you"},l.createElement("div",{style:{width:"100%"}},l.createElement("img",{src:c,style:{maxHeight:162,objectFit:"cover"}}),e&&l.createElement("h1",{className:"le-thankyou-title le-text-align-".concat(t)}," ",e," "),a&&l.createElement("p",{className:"le-thankyou-subtitle le-text-align-".concat(o)}," ",a," "),d&&l.createElement("div",null,l.createElement("a",{href:i,target:r?"_blank":"parrent",rel:"noreferrer"},l.createElement("button",{className:"lead-modal__btn ".concat(z)},i)))))),l.createElement("button",{className:"lead-modal__close-btn js-modal__close ".concat(z),onClick:s},l.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},l.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},l.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),l.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"}))))))};function K(n){var e=n.leadApi,t=n.leadSiteId,l=n.leadDomain,i=n.onShowPopup,r=("https://"+location.hostname+location.pathname+location.search).toLowerCase();fetch(e+"api/campaign/"+t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:r,ga_client_id:g("_ga")||null})}).then((function(n){return n.json()})).then((function(n){var e,t,d;if(console.log("List campagin: ",n),j="https://"+location.hostname+location.pathname+location.search,1==n._status){var c=n._data.campaigns;g("hhg-id")||(b("hhg-id",k(),{domain:"."+l,path:"/"}),console.log("😍 Set HHG ID cookie"));var s=[];s=/Android|webOS|iPhone|iPad|iPod|BlackBerry|BB|PlayBook|IEMobile|Windows Phone|Kindle|Silk|Opera Mini/i.test(navigator.userAgent)?c.filter((function(n){return n.device_types.some((function(n){return n.id==S}))})):c.filter((function(n){return n.device_types.some((function(n){return n.id==T}))})),console.log("👓 campaignsDevice",s);var m=s.map((function(n,e){return n.targets.filter((function(n){return n.type==N})).map((function(n){return a(a({},n),{campaignIndex:e})}))})).flat(1);m=m.filter((function(n){var e=new URL(String(n.target).toLowerCase());return"exact_match"==n.option?Boolean(r===e.href):"start_with"==n.option?!!r.includes(String(n.target))&&!n.sub_target.filter((function(n){return"excluding"==n.option})).map((function(n){return n.value})).includes(r):void 0}));var p=Array.from(document.getElementsByTagName("META")).filter((function(n){return"article:tag"==n.getAttribute("property")})).map((function(n){return n.content})),u=[];p&&p.length&&(u=s.map((function(n,e){return n.targets.filter((function(n){return n.type==C})).map((function(n){return a(a({},n),{campaignIndex:e})}))})).flat(1).filter((function(n){return p.includes(n.target)})));var h=o(o([],m,!0),u,!0),f=document.cookie.split("; ").map((function(n){return n.split("=")[0]})),x=f.filter((function(n){return n.includes("lead_submited")}));console.log("--listCampaignCodeSubmited",x);var _=f.filter((function(n){return n.includes("lead_closed")}));console.log("--listCampaignCodeClosed",_);var v,w=o(o([],x,!0),_,!0);if(v=h.filter((function(n){return!w.some((function(e){return e.includes(s[n.campaignIndex].code)}))})).sort((function(n,e){return n.score-e.score})),console.log("--listCampaignValid : ",v),v&&v.length){var y=s[v[0].campaignIndex];console.log("CAMPAIGN_SHOW",y);var E=y.rules,B=Number(null===(e=E.find((function(n){return"time"==n.rule})))||void 0===e?void 0:e.value);console.log("timeoutRule",B);var z=Number(null===(t=E.find((function(n){return"scroll"==n.rule})))||void 0===t?void 0:t.value);console.log("scrollRule",z);var L=Number(null===(d=E.find((function(n){return"exclude_sponsored"==n.rule})))||void 0===d?void 0:d.value);console.log("excludeSponsored",L);var O=Boolean(document.querySelector(".hhg-disclaimer-text"));if(console.log("💎 LEAD current page isSponsored",O),O&&L)return;var P="TIME";if(Number.isInteger(B)&&(P="TIME",console.log("✨ SHOW AWESOME POPUP AFTER: ",B," seconds"),setTimeout((function(){null==i||i(y,P)}),1e3*B)),Number.isInteger(z)){P="SCROLL",console.log("✨ SHOW AWESOME AFTER: SCROLL",z," %");var I=document.querySelector('[data-url="'.concat(location.pathname,'"]'))||document.querySelector("body"),A=I.getBoundingClientRect().top,D=I.offsetHeight;console.log("👓 Element check scroll: ",I);var M=function(){var n=window.pageYOffset||document.documentElement.scrollTop,e=0;n>=A&&(e=Math.round((n-A)/(D-innerHeight)*100)),console.log("---Scroll",e,z),e>=z&&(window.removeEventListener("scroll",M),null==i||i(y,P))};window.addEventListener("scroll",M)}}else console.log("🚧 No lead campaigns on current URL, tags")}})).catch((function(n){console.error("Lead error: ",n)}))}var Y=function(t){var a=t.apiUrl,o=t.siteDomain,i=t.siteId,d=t.locale,f=m(),k=m(Date.now()),_=r((function(){var n=a;return n.includes("localhost")&&(n="https://dev.leadgen.hellobacsi.com/"),{apiUrl:n}}),[a,o,i]).apiUrl,v=c(null),w=v[0],y=v[1],E=c(""),N=E[0],C=E[1],B=c(null),S=B[0],T=B[1],z=function(n,e){y(n),C(e)},j=function(){var n,e;if(w){console.log("👋👋👋 CLOSE POPUP ".concat(w.code," 👋👋👋"));var t=Number(null===(n=w.rules.find((function(n){return"show_again_after_exit "==n.rule})))||void 0===n?void 0:n.value),a=Number(null===(e=w.rules.find((function(n){return"days_to_show_again"==n.rule})))||void 0===e?void 0:e.value);0==t&&b("lead_closed_".concat(w.code),"target_".concat(w.extra_fields.popupVersion),a?{domain:"."+o,days:a,path:"/"}:{domain:"."+o,path:"/"}),document.body.classList.remove("noscroll"),fetch("".concat(_,"api/campaign/").concat(w.code,"/popup_exit"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:"CLICK",url:location.href.toLowerCase(),title_article:document.title,cookie_id:g("hhg-id"),duration:Math.ceil((Date.now()-k.current)/1e3)})}),y(null)}};s((function(){if(window.next){var n=p((function(n){console.log("--🌻 routeChangeComplete",n,Date.now());var e=location.pathname;j(),document.querySelectorAll('[data-popup-url="'.concat(e,'"]')).length||K({leadApi:_,leadDomain:o,leadSiteId:i,onShowPopup:z}),f.current&&window.removeEventListener("scroll",f.current)}),500);window.next.router.events.on("routeChangeComplete",n)}K({leadApi:_,leadDomain:o,leadSiteId:i,onShowPopup:z})}),[]);return s((function(){w&&(k.current=Date.now())}),[w]),l.createElement(P.Provider,{value:{apiUrl:_,siteDomain:o,siteId:i,locale:d}},l.createElement(h.Provider,{value:{locale:d,values:J(d)}},u(l.createElement(Q,null,w&&!S&&l.createElement(R,{campaign:w,onClose:j,onSubmit:function(t,a,l,i){return n(void 0,void 0,void 0,(function(){var n,r,d,c,s,m,p,u,h,f,x,k,v,y,E,N,C,B,S,z,L,P,I,A,D,M,H,q,V,F,R,W,U,J,Q;return e(this,(function(e){switch(e.label){case 0:return t.preventDefault(),console.log("submitHandler",a,l),n=new FormData(t.currentTarget),r={},n.forEach((function(n,e){r[e]=r[e]||[],r[e].push(n)})),d=Object.keys(r).map((function(n){return{name:n,value:r[n]}})),c=2,s=g("_ga")||null,[4,require("intl-tel-input")];case 1:return m=e.sent(),p={url:location.href.toLowerCase(),title_article:document.title,meta:d.map((function(n){var e,t,a;return{key:null===(e=document.querySelector(".lead-modal__form.".concat(i,' [name="').concat(n.name,'"]')))||void 0===e?void 0:e.getAttribute("data-key"),value:(null==O?void 0:O.countryCodeNumber)&&["tel","tel1","tel2","tel3"].includes(n.name)?m.formatNumber(String(n.value),null==O?void 0:O.countryCodeNumber,c).replace(/\s+/g,""):n.value,control:n.name.replace("1","").replace("2","").replace("3",""),is_sent_mailchimp:(null===(a=document.querySelector(".lead-modal__form.".concat(i," .mailchimp-").concat(null===(t=document.querySelector(".lead-modal__form.".concat(i,' [name="').concat(n.name,'"]')))||void 0===t?void 0:t.getAttribute("data-key"))))||void 0===a?void 0:a.getAttribute("data-mailchimp"))||"false"}})),cookie_id:g("hhg-id"),ga_client_id:s},a&&l[a].value_en&&(p.category=l[a].value_en),u=Number((null===(M=null===(D=w.rules)||void 0===D?void 0:D.find((function(n){return"days_to_show_again"===n.rule})))||void 0===M?void 0:M.value)||7),0==(h=Number((null===(q=null===(H=w.rules)||void 0===H?void 0:H.find((function(n){return"show_again_after_submit"===n.rule})))||void 0===q?void 0:q.value)||0))&&(console.log("⛔ Popup never show again!"),b("lead_submited_".concat(w.code),"target_".concat(w.extra_fields.targetType),{domain:"."+o,path:"/"})),1==h&&(console.log("⌛ Popup will show again after ".concat(u," days!")),b("lead_submited_".concat(w.code),"target_".concat(w.extra_fields.targetType),{domain:"."+o,days:u,path:"/"})),fetch("".concat(_,"api/campaign/").concat(w.code,"/lead"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(p)}),"notshow"==w.extra_fields.popupShowThankYou?(j(),document.body.classList.remove("noscroll"),[2]):(f=!0,x=w.thank_you_image||"".concat(_,"admin/img/thanksyou.png"),k=w.extra_fields.popupThankyouTitle||"Thank you.",v=w.extra_fields.popupThankyouDesc||"We appreciate your time!",y="",E="",B="","2.1"==w.extra_fields.popupVersion&&(S=w.extra_fields,z=JSON.parse(S.listBlockThankyou),L=z.find((function(n){return"TitleBlock"==n.name})),P=z.find((function(n){return"SubtitleBlock"==n.name})),I=z.find((function(n){return"LinkButtonBlock"==n.name})),k=(null===(V=null==L?void 0:L.data)||void 0===V?void 0:V.value)||"",y=(null===(F=null==L?void 0:L.data)||void 0===F?void 0:F.align)||"",v=(null===(R=null==P?void 0:P.data)||void 0===R?void 0:R.value)||"",E=(null===(W=null==P?void 0:P.data)||void 0===W?void 0:W.align)||"",N=(null===(U=null==I?void 0:I.data)||void 0===U?void 0:U.value)||"",C=(null===(J=null==I?void 0:I.data)||void 0===J?void 0:J.newtab)||!1,B=(null===(Q=null==I?void 0:I.data)||void 0===Q?void 0:Q.url)||"",A=w.extra_fields.currentLayout,["SkinA","SkinB","Floating","Tab","CenterTab"].includes(A)&&(f=!1)),T(f?{title:k,titleAlign:y,subtitle:v,subtitleAlign:E,link:B,linkNewTab:C,linkText:N,image:x}:null),sessionStorage.getItem("insider_object")?window.insider_object=JSON.parse(sessionStorage.getItem("insider_object")):window.insider_object={user:{email:"",phone_number:"",gdpr_optin:!0,sms_optin:!0,email_optin:!0}},d.map((function(n){var e=n.name,t=n.value;"tel"==e?window.insider_object.user.phone_number=t:"email"==e&&(window.insider_object.user.email=t)})),sessionStorage.setItem("insider_object",JSON.stringify(window.insider_object)),[2])}}))}))},action:N}),S&&l.createElement(G,{title:S.title,titleAlign:S.titleAlign,subtitle:S.subtitle,subtitleAlign:S.subtitleAlign,link:S.link,linkNewTab:S.linkNewTab,linkText:S.linkText,image:S.image,onClose:j})),x())))};export{Y as LeadGen};
|
|
1
|
+
import{a as e,d as n,e as t,_ as a}from"./tslib.es6-2fa94e2c.js";import o,{createContext as l,useMemo as i,useContext as r,useState as c,useEffect as d,useRef as s}from"react";import m from"lodash/debounce";import{createPortal as p}from"react-dom";import{T as u}from"./translationsContext-e7808c8f.js";import{g as h,s as g}from"./cookieHelper-8c12973e.js";import{b,a as f}from"./utils-40d4438f.js";import{v1 as v}from"uuid";import{u as k}from"./useTranslations-b3eb31ef.js";import"dayjs";import"./screenSizeContext-ff96a3d1.js";import"./lazyLoad-59e8ff6d.js";import"styled-components";import"./index-2cf746a8.js";import"./isProduction-6fc0946c.js";import"./Locale-69030fff.js";import"./gAssets.js";import"string-format";import"lodash/throttle";import"vanilla-lazyload";var x=function(e){var n=e.onClose,t=e.containerClassName,a=e.svgClassName;return o.createElement("button",{onClick:n,className:"le-newbuilder-close-button js-modal__close ".concat(t||"")},o.createElement("svg",{className:"le-newbuilder-close-svg ".concat(a||""),xmlns:"http://www.w3.org/2000/svg",width:"53",height:"53",viewBox:"0 0 53 53"},o.createElement("defs",null,o.createElement("filter",{width:"53",height:"53",filterUnits:"userSpaceOnUse"},o.createElement("feGaussianBlur",{result:"blur",stdDeviation:"3"}),o.createElement("feFlood",{floodOpacity:".4"}),o.createElement("feComposite",{in2:"blur",operator:"in"}),o.createElement("feComposite",{in:"SourceGraphic"})),o.createElement("style",{dangerouslySetInnerHTML:{__html:".cls-2{fill:none;stroke:#fff;stroke-linecap:round;stroke-width:2px}"}})),o.createElement("g",{filter:"url(#Ellipse_482)"},o.createElement("circle",{cx:"17.5",cy:"17.5",r:"17.5",transform:"translate(-483.1 -671.163)translate(483.1 671.16)translate(9 9)",fill:"#005cfd"})),o.createElement("path",{d:"M19 19L34 34",className:"cls-2"}),o.createElement("path",{d:"M34 19L19 34",className:"cls-2"})))},_=function(e){var n=e.popupId,t=e.url,a=e.newTab,l=e.imageDestkop,i=e.imageMobile,r=e.onClose,c=e.onOtherSubmit;return o.createElement("div",{id:n,className:"lead-modal-wrapper","data-popup-url":location.pathname,"data-popup-type":"center_tab"},o.createElement("div",{className:"le-center-tab-popup"},o.createElement("div",{style:{position:"relative"}},o.createElement("a",{className:"js-popup-other-submit",href:t,target:a?"blank":"_parent",onClick:c},o.createElement("img",{className:"le-only-mobile",src:i}),o.createElement("img",{className:"le-only-desktop",src:l})),o.createElement(x,{onClose:r,containerClassName:"le-abs-outer-mobile-top-right-2",svgClassName:"le-mobile-btn"}))))},y=function(e){var n=e.popupId,t=e.url,a=e.title,l=e.urlText,i=e.titleAlign,r=e.subtitle,c=e.subtitleAlign,d=e.newTab,s=e.imageDesktop,m=e.imageMobile,p=e.onClose,u=e.onOtherSubmit;return o.createElement("div",{id:n,className:"lead-modal-wrapper lead-floating-wrapper","data-popup-url":location.pathname,"data-popup-type":"floating"},o.createElement("aside",{className:"le-only-desktop"},o.createElement("div",{className:"le-floating-desktop"},o.createElement("div",{className:"le-floating-desktop-wrap",style:{position:"relative",background:"#fff"}},s?o.createElement("div",null,o.createElement("img",{style:{maxWidth:120,borderTopLeftRadius:5,borderBottomLeftRadius:5},src:s})):null,o.createElement("div",{style:{padding:20}},o.createElement("div",{className:"le-floating-desktop-title le-text-align-".concat(i)},a),o.createElement("div",{className:"le-floating-desktop-desc le-text-align-".concat(c)},r)),o.createElement("a",{target:d?"blank":"_parent",style:{marginLeft:35,textDecoration:"none"},href:t},o.createElement("button",{className:"le-joinbow-floating-btn js-popup-other-submit",onClick:u},l)),o.createElement(x,{onClose:p,containerClassName:"le-abs-outer-top-right"})))),o.createElement("aside",{className:"le-only-mobile"},o.createElement("div",{className:"le-floating-mobile"},o.createElement("div",{className:"le-floating-mobile-wrap",style:{position:"relative",background:"#fff"}},o.createElement("aside",{style:{display:"flex",justifyContent:"space-between"}},o.createElement("div",null,o.createElement("div",{className:"le-floating-mobile-title le-text-align-".concat(i)},a),o.createElement("div",{className:"le-floating-mobile-desc le-text-align-".concat(c)},r)),m?o.createElement("div",null,o.createElement("img",{style:{marginLeft:15,marginTop:4,maxWidth:100},src:m})):null),o.createElement("div",{style:{textAlign:"center",marginTop:10}},o.createElement("a",{target:d?"blank":"_parent",href:t,style:{textDecoration:"none"}},o.createElement("button",{className:"le-joinbow-floating-btn js-popup-other-submit",onClick:u},l))),o.createElement(x,{onClose:p,containerClassName:"le-abs-outer-top-right",svgClassName:"le-mobile-btn"})))))},w=1,E=2,N="https://dev.leadgen.hellobacsi.com/",C=1,S=2,B="";N.includes("localhost")&&(N="https://dev.leadgen.hellobacsi.com/"),location.hostname.includes("marrybaby.vn")&&(B="pink");var T="https://"+location.hostname+location.pathname+location.search;T=T.toLowerCase(),sessionStorage.getItem("insider_object")&&(window.insider_object=JSON.parse(sessionStorage.getItem("insider_object")));var j={"vi-VN":{popupLang:"vi",countryCode:"vn",countryCodeNumber:84},"id-ID":{popupLang:"id",countryCode:"id",countryCodeNumber:62},"th-TH":{popupLang:"th",countryCode:"th",countryCodeNumber:66},"ms-MY":{popupLang:"ms",countryCode:"my",countryCodeNumber:60},"zh-TW":{popupLang:"zh",countryCode:"tw",countryCodeNumber:886},"km-KH":{popupLang:"km",countryCode:"kh",countryCodeNumber:855},"my-MM":{popupLang:"my",countryCode:"mm",countryCodeNumber:95},"hi-IN":{popupLang:"hi",countryCode:"in",countryCodeNumber:91}},L=j[document.documentElement.lang]||j["vi-VN"];var O=l({}),P=function(e){var n=e.title,t=e.titleAlign,a=e.subtitle,l=e.subtitleAlign,i=e.link,r=e.linkNewTab,c=e.linkText,d=e.image;return o.createElement("div",{className:"lead-modal__thank-you"},o.createElement("div",{style:{width:"100%"}},o.createElement("img",{src:d,style:{maxHeight:162,objectFit:"cover"}}),n&&o.createElement("h1",{className:"le-thankyou-title le-text-align-".concat(t)},n),a&&o.createElement("p",{className:"le-thankyou-subtitle le-text-align-".concat(l)},a),c&&o.createElement("div",null,o.createElement("a",{href:i,target:r?"_blank":"parrent",rel:"noreferrer"},o.createElement("button",{className:"lead-modal__btn ".concat(B)},c)))))},I=function(n){var t=n.content,a=n.inlinePosition,o=i((function(){if(!a)return null;var n=document.querySelectorAll('[data-url="'.concat(location.pathname,'"] .body-content')),t=Array.from(n).reduce((function(n,t){return e(e([],n,!0),Array.from(t.children),!0)}),[]);if(null==t?void 0:t.length){var o=t.filter((function(e){return"P"===e.nodeName})),l=t.filter((function(e){return"H2"===e.nodeName})),i=null;switch(a){case"1th":i=o[0];break;case"2th":i=o[1];break;case"3th":i=o[2];break;case"4th":i=o[3];break;case"5th":i=o[4];break;case"6th":i=o[5];break;case"7th":i=o[6];break;case"8th":i=o[7];break;case"9th":i=o[8];break;case"10th":i=o[9];break;case"11th":i=o[10];break;case"12th":i=o[11];break;case"lastP":i=o[o.length-1];break;case"1thH2":i=l[0];break;case"2thH2":i=l[1];break;case"3thH2":i=l[2];break;case"4thH2":i=l[3];break;case"5thH2":i=l[4];break;case"6thH2":i=l[5];break;case"7thH2":i=l[6];break;case"8thH2":i=l[7];break;case"9thH2":i=l[8];break;case"10thH2":i=l[9];break;case"lastH2":i=l[l.length-1]}if(i){var r=document.createElement("div");return r.classList.add("inline-lead-wrapper"),i.nextElementSibling?i.parentElement.insertBefore(r,i.nextElementSibling):i.parentElement.appendChild(r),r}}}),[a]);return a&&o?p(t,o):null},A=function(e){var n=e.content,t=i((function(){var e=[];return document.querySelectorAll(".hc2-sidebar-with-ads,.page-main-col .right-col.f-right,.hhg-lead-sidebar").forEach((function(n){return e.push(n)})),e}),[]);return o.createElement(o.Fragment,null,t.map((function(e){return p(n,b(e,"sidebar-lead-modal-wrapper"))})))},z=function(e){var a,l,s,m=e.popupId,p=e.extraFields,u=e.onClose,h=e.onOtherSubmit,g=e.imageMobile,b=e.imageDesktop,f=e.imageOverlayMobile,v=e.imageOverlayDesktop,x=e.imageBackground,_=e.currentLayout,y=e.title,w=e.onSubmit,E=e.showThankyou,N=k().t,C=JSON.parse(p.listBlockAdded),S=JSON.parse(p.actionBlocks),T=JSON.parse(p.textBlocks),j=r(O).apiUrl,z=S.submitBlock.data.url,D=S.submitBlock.data.text,H=S.submitBlock.data.text2,M=S.submitBlock.data.value,q=location.pathname,V=_.includes("Inline")||"Sidebar"===_,F="Slider"===_,R=c(!0),U=R[0],W=R[1];if(window.innerWidth<769&&["Fullscreen","Slider"].includes(_))return console.log("😎 Not show fullscreen, slider on mobile "),null;d((function(){(_.includes("LightBox")||"Fullscreen"==_)&&document.body.classList.add("noscroll")}),[]);var J=function(e,a){return n(void 0,void 0,void 0,(function(){return t(this,(function(n){switch(n.label){case 0:return a.target.validity.valueMissing?(a.target.setCustomValidity(N("validator.required")),[3,6]):[3,1];case 1:return a.target.validity.valid||a.target.validity.customError?[3,2]:("tel"===e?a.target.setCustomValidity(N("validator.phone")):"date"===e?a.target.setCustomValidity(N("validator.date")):"email"===e&&a.target.setCustomValidity(N("validator.email")),[3,6]);case 2:return"tel"!==e?[3,5]:window.intlTelInputUtils?[3,4]:[4,require("intl-tel-input/build/js/utils")];case 3:n.sent(),n.label=4;case 4:return window.intlTelInputUtils.isValidNumber(String(a.target.value),L.countryCode)?a.target.setCustomValidity(""):a.target.setCustomValidity(N("validator.phone")),[3,6];case 5:a.target.setCustomValidity(""),n.label=6;case 6:return[2]}}))}))},Q=i((function(){var e={TextBlock:0,NumberBlock:0,EmailBlock:0,PhoneBlock:0,DateBlock:0,CheckboxBlock:0,RadioBlock:0};return C.map((function(n,t){var a,l;if("TitleBlock"==n.name)return o.createElement("h2",{key:t,className:"lead-modal__title ".concat("le-text-align-"+((null===(a=n.data)||void 0===a?void 0:a.align)||"")," ").concat(B)},n.data.value);if("SubtitleBlock"==n.name)return o.createElement("p",{key:t,className:"lead-modal__description ".concat("le-text-align-"+((null===(l=n.data)||void 0===l?void 0:l.align)||"")," ").concat(B)},n.data.value);if("TextBlock"==n.name)return e.TextBlock+=1,o.createElement("div",{key:t},o.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,"data-key":n.data.value,name:"text"+(e.TextBlock>1?e.TextBlock:""),spellCheck:!1,type:"text",placeholder:n.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(e){return J("text",e)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(j,"admin/img/builder/text.svg")})));if("NumberBlock"==n.name){var i=o.createElement("div",{key:t},o.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,"data-key":n.data.value,name:"number"+(e.NumberBlock?e.NumberBlock:""),spellCheck:!1,type:"number",min:"0",placeholder:n.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(e){return J("number",e)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(j,"admin/img/builder/number.svg")})));return e.NumberBlock+=1,i}if("EmailBlock"==n.name){i=o.createElement("div",{key:t},o.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,"data-key":n.data.value,name:"email"+(e.EmailBlock?e.EmailBlock:""),spellCheck:!1,type:"email",placeholder:n.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(e){return J("email",e)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(j,"admin/img/builder/email.svg")})));return e.EmailBlock+=1,i}if("PhoneBlock"==n.name){i=o.createElement("div",{key:t},o.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,"data-key":n.data.value,name:"tel"+(e.PhoneBlock?e.PhoneBlock:""),spellCheck:!1,type:"tel",placeholder:n.data.placeholder,className:"lead-modal__form-control width-100%",onChange:function(e){return J("tel",e)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(j,"admin/img/builder/tel.svg")})));return e.PhoneBlock+=1,i}if("DateBlock"==n.name){i=o.createElement("div",null,o.createElement("div",{className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,type:"date","data-key":n.data.value,name:"date"+(e.DateBlock?e.DateBlock:""),placeholder:n.data.placeholder,onClick:function(e){e.currentTarget.classList.remove("placeholderclass")},onBlur:function(e){e.currentTarget.value||e.currentTarget.classList.add("placeholderclass")},className:"dateclass placeholderclass lead-modal__form-control width-100%",onChange:function(e){return J("date",e)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(j,"admin/img/builder/date.svg")})));return e.DateBlock+=1,i}if("LinkButtonBlock"==n.name)return o.createElement("div",{key:t},o.createElement("a",{target:n.data.newtab?"blank":"parrent",href:n.data.url,style:{textDecoration:"none"}},o.createElement("button",{type:"button",className:"lead-modal__btn js-modal__close js-popup-other-submit ".concat(B),onClick:function(){null==u||u(),null==h||h()}},n.data.value)));if("CheckboxBlock"==n.name){var r=n.data,c=r.listQuestion,d=r.isSendMailChimp,s=void 0!==d&&d;i=o.createElement("div",{key:t,style:{margin:"5px 0"}},o.createElement("div",{className:"le-checkbox-title"},n.data.placeholder),o.createElement("div",{className:"mailchimp-".concat(n.data.value),"data-mailchimp":s}),c.map((function(t,a){return o.createElement("label",{key:a,className:"lead-checkbox-container"},o.createElement("input",{"data-key":n.data.value,name:"checkbox"+(e.CheckboxBlock?e.CheckboxBlock:"")+"[]",value:t.value,type:"checkbox",onChange:function(e){return J("checkbox",e)}}),o.createElement("span",{className:"lead-checkbox-checkmark"}),t.placeholder)})));return e.CheckboxBlock+=1,i}if("RadioBlock"==n.name){c=n.data.listQuestion,i=o.createElement("div",{key:t,style:{margin:"5px 0"}},o.createElement("div",{className:"le-checkbox-title"},n.data.placeholder),c.map((function(t,a){return o.createElement("label",{className:"lead-radio-container",key:a},o.createElement("input",{"data-key":n.data.value,name:"radio"+(e.RadioBlock?e.RadioBlock:""),value:t.value,type:"radio",onChange:function(e){return J("radio",e)}}),o.createElement("span",{className:"lead-radio-checkmark"}),t.placeholder)})));return e.RadioBlock+=1,i}if("DropdownBlock"==n.name){c=n.data.listQuestion,i=o.createElement("div",{key:t,style:{margin:"5px 0"}},o.createElement("div",{className:"le-checkbox-title"},n.data.placeholder),o.createElement("div",{className:"le-newbuilder-select-wrapper"},o.createElement("select",{className:"le-newbuilder-select","data-key":n.data.value,name:"dropdown"+(e.DropdownBlock?e.DropdownBlock:"")},c.map((function(e,n){return o.createElement("option",{key:n,value:e.value},e.placeholder)})))));return e.DropdownBlock+=1,i}}))}),[]),G=o.createElement(o.Fragment,null,o.createElement("style",{dangerouslySetInnerHTML:{__html:".le-newbuilder-overlay {\n background: url(".concat(f,") ;\n background-repeat: no-repeat;\n background-size: cover;\n }\n @media screen and (min-width:768px) {\n .le-newbuilder-overlay {\n background: url(").concat(v,") ;\n background-repeat: no-repeat;\n background-size: cover;\n }\n }")}}),o.createElement("div",{id:m,"data-popup-url":q,"data-popup-type":"lightbox-inline",className:"lead-modal lead-modal-wrapper modal--animate-scale ".concat(V?"le-buider-inline":""," ").concat(F?"le-buider-slider":"")},"Fullscreen"==_?o.createElement("img",{className:"le-only-desktop le-fullscreen-img",draggable:!1,src:x||""}):null,o.createElement("div",{className:"lead-modal__wrapper le-newbuilder-wrap-".concat(_)},o.createElement("div",{className:"lead-modal__content le-newbuilder-".concat(_)},E?o.createElement(P,{title:E.title,titleAlign:E.titleAlign,subtitle:E.subtitle,subtitleAlign:E.subtitleAlign,link:E.link,linkNewTab:E.linkNewTab,linkText:E.linkText,image:E.image}):o.createElement(o.Fragment,null,o.createElement("header",{className:"lead-modal__header"},["LightBoxA","InlineA","Sidebar","Slider"].includes(_)?g?o.createElement("img",{draggable:"false",className:"lead-modal__image lead-modal-image-cover",src:g,alt:""}):null:o.createElement(o.Fragment,null,b?o.createElement("img",{draggable:"false",className:"le-only-desktop lead-modal__image lead-modal-image-cover",style:{height:"100%",objectFit:"cover"},src:b,alt:""}):null,g?o.createElement("img",{draggable:"false",className:"le-only-mobile lead-modal__image lead-modal-image-cover",src:g,alt:""}):null)),o.createElement("div",{className:"lead-modal__body le-newbuilder-overlay"},o.createElement("form",{className:"lead-modal__form ".concat(m),onSubmit:w},o.createElement("div",{style:{marginBottom:20}},o.createElement("h2",{className:"lead-modal__title ".concat("le-text-align-"+(null===(a=T.titleBlock.data)||void 0===a?void 0:a.align)," ").concat(B)},y),o.createElement("p",{className:"lead-modal__description ".concat("le-text-align-"+(null===(l=T.titleBlock.data)||void 0===l?void 0:l.align)," ").concat(B)},T.subtitleBlock.data.value)),o.createElement("div",null,Q),(null===(s=null==S?void 0:S.submitBlock)||void 0===s?void 0:s.isHide)?null:o.createElement(o.Fragment,null,o.createElement("div",{className:"lead-modal__checkbox-wrapper ".concat(B)},o.createElement("div",{className:"lead-modal__checkbox"},o.createElement("input",{id:"lead-term-checkbox",className:"lead-modal__checkbox__input ".concat(B),type:"checkbox","aria-label":"Checkbox label",checked:U,onChange:function(e){return W(e.currentTarget.checked)}}),o.createElement("div",{className:"lead-modal__checkbox__control","aria-hidden":"true"})),o.createElement("label",{htmlFor:"checkbox",className:"lead-modal__checkbox__label"},D," ",o.createElement("span",{style:{fontWeight:"bold"}},o.createElement("a",{target:"blank",href:z||"https://hellobacsi.com/chinh-sach",rel:"noopener noreferrer",style:{textDecoration:"none"}},H)))),o.createElement("button",{id:"lead-submit",type:"submit",className:"lead-modal__btn ".concat(B),disabled:!U},M)))))),!_.includes("Inline")&&o.createElement("button",{className:"lead-modal__close-btn ".concat("Fullscreen"==_?"lead-fullscreen-desktop-close-btn":""," js-modal__close ").concat(B),onClick:u},o.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},o.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},o.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),o.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"})))))));return _.includes("LightBox")||"Fullscreen"==_||"Slider"==_?G:"Sidebar"==_?o.createElement(A,{content:G}):_.includes("Inline")?o.createElement(I,{content:G,inlinePosition:p.popupInlinePosition}):null},D=function(e){var n=e.popupId,t=e.link,a=e.linkText,l=e.linkNewTab,i=e.onClose,r=e.imageMobile,c=e.imageDesktop,d=e.currentLayout,s=e.onOtherSubmit,m=location.pathname;return o.createElement("div",{id:n,className:"lead-modal-wrapper","data-popup-url":m,"data-popup-type":"skin_ab"},"SkinA"==d?o.createElement("aside",{className:"le-only-desktop"},o.createElement("div",{className:"le-skin-a-desktop"},o.createElement("div",{style:{position:"relative"}},o.createElement("img",{src:c}),o.createElement("a",{style:{position:"absolute",top:"75%",left:"50%",transform:"translate(-50%, -50%)",textAlign:"center",width:"calc(100% - 15px)"},href:t,target:l?"blank":"_parent"},o.createElement("button",{onClick:s,className:"le-joinbow-btn js-popup-other-submit"},a)),o.createElement("button",{className:"lead-modal__close-btn js-modal__close ".concat(B)},o.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},o.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},o.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),o.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"}))))))):"SkinB"==d?o.createElement("aside",{className:"le-only-desktop"},o.createElement("div",{className:""},o.createElement("div",{style:{position:"relative",zIndex:1e4}},o.createElement("img",{src:c,style:{width:"100%"}}),o.createElement("a",{style:{position:"absolute",top:"75%",left:"50%",transform:"translate(-50%, -50%)",textAlign:"center",width:"100%"},href:t,target:l?"blank":"_parent"},o.createElement("button",{onClick:s,className:"le-joinbow-btn-mobile js-popup-other-submit"},a)),o.createElement(x,{containerClassName:"le-abs-top-right",onClose:i})))):null,o.createElement("aside",{className:"le-only-mobile"},o.createElement("div",{className:"le-skin-mobile"},o.createElement("div",{style:{position:"relative"}},o.createElement("img",{src:r,style:{width:"100%"}}),o.createElement("a",{style:{position:"absolute",top:"82%",left:"50%",transform:"translate(-50%, -50%)",textAlign:"center",maxWidth:"calc(100% - 15px)"},href:t,target:l?"blank":"_parent"},o.createElement("button",{onClick:s,className:"le-joinbow-btn-mobile js-popup-other-submit"},a)),o.createElement(x,{containerClassName:"le-abs-top-right",svgClassName:"le-mobile-btn",onClose:i})))))},H=function(e){var n=e.popupId,t=e.url,a=e.newTab,l=e.image,i=e.onClose,r=e.onOtherSubmit;return o.createElement("div",{id:n,className:"lead-modal-wrapper","data-popup-url":location.pathname,"data-popup-type":"tab"},o.createElement("div",{className:"le-tab-popup"},o.createElement("div",{style:{position:"relative"}},o.createElement("a",{href:t,target:a?"blank":"_parent",onClick:r},o.createElement("img",{className:"js-popup-other-submit",src:l})),o.createElement(x,{onClose:i,containerClassName:"le-abs-outer-mobile-top-right-2",svgClassName:"le-mobile-btn"}))))};var M=function(e){var n,t,a=e.campaign,l=e.action,i=e.onSubmit,c=e.onClose,m=e.showThankyou;k().t;var p=r(O),u=p.apiUrl,b=p.siteDomain;d((function(){var e=h("_ga")||null;fetch("".concat(u,"api/campaign/").concat(E,"/impression"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:l,url:location.href.toLowerCase(),title_article:document.title,cookie_id:h("hhg-id"),ga_client_id:e})})}),[]);var f=a.extra_fields,x=a.image,w=a.image_desktop,E=a.code,N=a.image_background,C=a.image_overlay_mobile,S=a.image_overlay_desktop,B=f.currentLayout,T=f.imageBlocks?JSON.parse(f.imageBlocks):{},j=JSON.parse(f.actionBlocks),L=JSON.parse(f.textBlocks),P=(null===(t=null===(n=null==L?void 0:L.titleBlock)||void 0===n?void 0:n.data)||void 0===t?void 0:t.value)||"",I={1:{},2:{},3:{}},A=s("lead-modal-"+v()),M=function(e){if(void 0===e&&(e="Xin chao {{category_2}} extra"),e.includes("{{category_")){var n="{{category_".length,t=e.search("{{category_");return+e.charAt(n+t)}return null}(P);if(M){console.log("⚡️ Has categoryLevel",M);var q=Array.from(document.getElementsByTagName("META")),V=q.find((function(e){return e.name==="content_category_".concat(M)})),F=q.find((function(e){return e.name==="content_category_en_".concat(M)}));if(!V||!F)return console.log("⚡️ No META TAG for categoryLevel, not show popup",M),null;I[M]={value:V.content,value_en:F.content},P=P.replace("{{category_".concat(M,"}}"),V.content),console.log("⚡️ Set categoryData ",M)}else console.log("⚡️ No categoryLevel",M);var R=function(){var e,n,t,o;if(console.log("👌 Other submit click"),document.body.classList.remove("noscroll"),B.includes("Skin")){var l=document.querySelector("#masthead");l&&(l.style.top="0px !important;")}var i=Number(null!==(n=null===(e=a.rules.find((function(e){return"days_to_show_again"==e.rule})))||void 0===e?void 0:e.value)&&void 0!==n?n:7),r=Number(null!==(o=null===(t=a.rules.find((function(e){return"show_again_after_submit"==e.rule})))||void 0===t?void 0:t.value)&&void 0!==o?o:0);0===r&&(console.log("⛔ Popup never show again!"),g("lead_submited_".concat(E),"target_".concat(f.popupVersion),{domain:"."+b,path:"/"})),1==r&&(console.log("⌛ Popup will show again after ".concat(i," days!")),g("lead_submited_".concat(E),"target_".concat(f.popupVersion),{domain:"."+b,days:i,path:"/"}));var d=h("_ga")||null,s={url:location.href.toLowerCase(),title_article:document.title,meta:[],cookie_id:h("hhg-id"),ga_client_id:d};M&&(s.category=I[M].value_en),fetch("".concat(u,"api/campaign/").concat(E,"/lead"),{method:"POST",body:JSON.stringify(s),headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest"}}).then((function(e){return e.json()})).then((function(e){"error"===e.status&&console.log(e)})).catch((function(e){console.error("Error:",e)})),null==c||c()};return"CenterTab"===B?o.createElement(_,{popupId:A.current,url:T.imageMobile.data.url,newTab:T.imageMobile.data.newtab,imageMobile:x,imageDestkop:w,onClose:c,onOtherSubmit:R}):"Tab"===B?o.createElement(H,{popupId:A.current,url:T.imageMobile.data.url,newTab:T.imageMobile.data.newtab,image:x,onClose:c,onOtherSubmit:R}):"Floating"===B?o.createElement(y,{popupId:A.current,title:P,titleAlign:L.titleBlock.data.align,subtitle:L.subtitleBlock.data.value,subtitleAlign:L.subtitleBlock.data.align,url:j.linkButtonBlock.data.url,urlText:j.linkButtonBlock.data.value,newTab:j.linkButtonBlock.data.newtab,imageMobile:x,imageDesktop:w,onClose:c,onOtherSubmit:R}):B.includes("LightBox")||B.includes("Inline")||"Fullscreen"==B||"Sidebar"==B||"Slider"==B?o.createElement(z,{popupId:A.current,extraFields:f,onClose:c,onOtherSubmit:R,imageMobile:x,imageDesktop:w,imageBackground:N,currentLayout:B,title:P,onSubmit:function(e){return i(e,M,I,A.current)},key:B,imageOverlayDesktop:S,imageOverlayMobile:C,showThankyou:m}):B.includes("Skin")?o.createElement(D,{popupId:A.current,link:j.linkButtonBlock.data.url,linkNewTab:!!j.linkButtonBlock.data.newtab,linkText:j.linkButtonBlock.data.value,onClose:c,onOtherSubmit:R,imageMobile:x,imageDesktop:w,currentLayout:B}):null},q=function(e){var a=e.campaign,l=e.action,i=e.onSubmit,s=e.onClose,m=e.showThankyou,p=k().t,u=c(!0),g=u[0],b=u[1];d((function(){document.body.classList.add("noscroll");var e=h("_ga")||null;fetch("".concat(S,"api/campaign/").concat(x,"/impression"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:l||"",url:location.href.toLowerCase(),title_article:document.title,cookie_id:h("hhg-id"),ga_client_id:e})})}),[]);var f=a.extra_fields,v=a.image,x=a.code,_=f.title,y=f.desc,w=f.submit,E=f.popUpTermURL,N=f.popUpTermAgreeText,C=f.popUpTermText,S=r(O).apiUrl,T=f.fields?JSON.parse(f.fields):[],j={tel:0,text:0,date:0,email:0},I=function(e,a){return n(void 0,void 0,void 0,(function(){return t(this,(function(n){switch(n.label){case 0:return a.target.validity.valueMissing?(a.target.setCustomValidity(p("validator.required")),[3,5]):[3,1];case 1:return a.target.validity.valid||a.target.validity.customError?[3,2]:("tel"===e?a.target.setCustomValidity(p("validator.phone")):"date"===e?a.target.setCustomValidity(p("validator.date")):"email"===e&&a.target.setCustomValidity(p("validator.email")),[3,5]);case 2:return"tel"!==e?[3,4]:[4,require("intl-tel-input")];case 3:return n.sent().isValidNumber(String(a.target.value),L.countryCode)?a.target.setCustomValidity(""):a.target.setCustomValidity(p("validator.phone")),[3,5];case 4:a.target.setCustomValidity(""),n.label=5;case 5:return[2]}}))}))},A=T.map((function(e,n){var t=o.createElement(o.Fragment,null);return t="date"==e.control?o.createElement("div",{key:n,className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,type:"date","data-key":e.listEdit[0].value,name:j.date?e.control+j.date:e.control,placeholder:e.listEdit[1].value||"...",onClick:function(e){return e.currentTarget.classList.remove("placeholderclass")},onBlur:function(e){return!e.currentTarget.value&&e.currentTarget.classList.add("placeholderclass")},className:"dateclass placeholderclass lead-modal__form-control width-100%",onChange:function(n){return I(e.control,n)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(S,"admin/img/builder/").concat(e.name,".svg")})):o.createElement("div",{key:n,className:"lead-modal__form-control-wrapper form-control-wrapper--icon-left"},o.createElement("input",{required:!0,"data-key":e.listEdit[0].value,name:j[e.control]?e.control+j[e.control]:e.control,spellCheck:!1,type:e.control,placeholder:e.listEdit[1].value||"...",className:"lead-modal__form-control width-100%",onChange:function(n){return I(e.control,n)}}),o.createElement("img",{className:"lead-modal__form-control-icon",src:"".concat(S,"admin/img/builder/").concat(e.name,".svg")})),"date"==e.control&&(j.date+=1),"text"==e.control&&(j.text+=1),"tel"==e.control&&(j.tel+=1),"email"==e.control&&(j.email+=1),t}));return o.createElement("div",{id:"lead-modal",className:"lead-modal modal--animate-scale"},o.createElement("div",{className:"lead-modal__wrapper animate__animated "},o.createElement("div",{className:"lead-modal__content"},m?o.createElement(P,{title:m.title,titleAlign:m.titleAlign,subtitle:m.subtitle,subtitleAlign:m.subtitleAlign,link:m.link,linkNewTab:m.linkNewTab,linkText:m.linkText,image:m.image}):o.createElement(o.Fragment,null,o.createElement("header",{className:"lead-modal__header"},!!v&&o.createElement("img",{className:"lead-modal__image lead-modal-image-cover",src:v,alt:""})),o.createElement("div",{className:"lead-modal__body"},o.createElement("h2",{className:"lead-modal__title ".concat(B)},_),o.createElement("p",{className:"lead-modal__description ".concat(B)},y),o.createElement("form",{className:"lead-modal__form",onSubmit:function(e){e.preventDefault(),i(e)}},A,o.createElement("div",{className:"lead-modal__checkbox-wrapper ".concat(B)},o.createElement("div",{className:"lead-modal__checkbox"},o.createElement("input",{id:"lead-term-checkbox",className:"lead-modal__checkbox__input ".concat(B),type:"checkbox","aria-label":"Checkbox label",checked:g,onChange:function(e){return b(e.currentTarget.checked)}}),o.createElement("div",{className:"lead-modal__checkbox__control","aria-hidden":"true"})),o.createElement("label",{htmlFor:"checkbox",className:"lead-modal__checkbox__label"},N," ",o.createElement("span",{style:{fontWeight:"bold"}},o.createElement("a",{target:"blank",href:E||"https://hellobacsi.com/chinh-sach",style:{textDecoration:"none"},rel:"noopener noreferrer"},C)))),o.createElement("button",{id:"lead-submit",type:"submit",className:"lead-modal__btn ".concat(B),disabled:!g},w))))),o.createElement("button",{className:"lead-modal__close-btn js-modal__close ".concat(B),onClick:s},o.createElement("svg",{className:"lead-modal__close-icon",viewBox:"0 0 24 24"},o.createElement("title",null,"Close modal window"),o.createElement("g",{fill:"none",stroke:"currentColor",strokeMiterlimit:"10",strokeWidth:"2"},o.createElement("line",{x1:"3",y1:"3",x2:"21",y2:"21"}),o.createElement("line",{x1:"21",y1:"3",x2:"3",y2:"21"}))))))},V=function(e){var n=e.campaign,t=e.action,a=e.onSubmit,l=e.onClose,i=e.showThankyou;return n.extra_fields?"2.1"==n.extra_fields.popupVersion?o.createElement(M,{campaign:n,action:t,onSubmit:a,onClose:l,showThankyou:i}):o.createElement(q,{campaign:n,action:t,onSubmit:a,onClose:l,showThankyou:i}):null},F={"validator.required":"This field is required.","validator.remote":"Please fix this field.","validator.email":"Please enter a valid email address.","validator.phone":"Please input correct phone number.","validator.url":"Please enter a valid URL.","validator.date":"Please enter a valid date.","validator.dateISO":"Please enter a valid date (ISO).","validator.number":"Please enter a valid number.","validator.digits":"Please enter only digits.","validator.creditcard":"Please enter a valid credit card number.","validator.equalTo":"Please enter the same value again.","validator.accept":"Please enter a value with a valid extension.","validator.maxlength":"jQuery.validator.format('Please enter no more than {0} characters.","validator.minlength":"jQuery.validator.format('Please enter at least {0} characters.","validator.rangelength":"jQuery.validator.format('Please enter a value between {0} and {1} characters long.","validator.range":"jQuery.validator.format('Please enter a value between {0} and {1}.","validator.max":"jQuery.validator.format('Please enter a value less than or equal to {0}.","validator.min":"jQuery.validator.format('Please enter a value greater than or equal to {0}."},R={"en-PH":F,"vi-VN":{"validator.required":"Vui lòng điền mục này","validator.email":"Vui lòng điền email có thật.","validator.number":"Vui lòng điền số có thật","validator.digits":"Vui lòng chỉ điền số","validator.maxlength":"Vui lòng điền dưới {0} số","validator.minlength":"Vui lòng điền hơn {0} số","validator.remote":"Hãy sửa cho đúng.","validator.url":"Hãy nhập URL.","validator.date":"Hãy nhập ngày.","validator.dateISO":"Hãy nhập ngày (ISO).","validator.creditcard":"Hãy nhập số thẻ tín dụng.","validator.equalTo":"Hãy nhập thêm lần nữa.","validator.extension":"Phần mở rộng không đúng.","validator.rangelength":"Hãy nhập từ {0} đến {1} kí tự.","validator.range":"Hãy nhập từ {0} đến {1}.","validator.max":"Hãy nhập từ {0} trở xuống.","validator.min":"Hãy nhập từ {0} trở lên.","validator.phone":"Nhập đúng định dạng số điện thoại"},"hi-IN":{"validator.required":"इस क्षेत्र की आवश्यकता है।","validator.email":"कृपया एक मान्य ईमेल पता दर्ज करें","validator.number":"कृपया एक वैध संख्या दर्ज करें","validator.digits":"कृपया केवल अंक दर्ज करें","validator.maxlength":"कृपया {0} अक्षर से अधिक दर्ज न करें","validator.minlength":"कृपया कम से कम {0} अक्षर दर्ज करें","validator.phone":"कृपया एक वैध संख्या दर्ज करें"},"id-ID":{"validator.required":"Kolom ini wajib diisi","validator.email":"Tolong daftarkan email yang valid","validator.number":"Tolong daftarkan nomor telepon yang valid","validator.digits":"Tolong masukkan angka saja","validator.maxlength":"Jangan memasukkan lebih dari {0} karakter","validator.minlength":"Tolong ketik sedikitnya {0} karakter","validator.phone":"Tolong daftarkan nomor telepon yang valid"},"ms-MY":{"validator.required":"Bahagian ini wajib diisi.","validator.email":"Sila masukkan alamat emel yang sah.","validator.number":"Sila masukkan no telefon yang sah.","validator.digits":"Sila masukkan nombor digit sahaja.","validator.maxlength":"Sila masukkan tidak lebih dari {0} aksara","validator.minlength":"Sila masukkan sekurang-kurangnya {0} aksara","validator.phone":"Sila masukkan no telefon yang sah."},"my-MM":{"validator.required":"ဒီနေရာမှာ ဖြည့်ဖို့ လိုအပ်ပါတယ်","validator.email":"မှန်ကန်သော အီးမေးလ်လိပ်စာထည့်သွင်းပါ","validator.number":"မှန်ကန်သော ဖုန်းနံပါတ်ထည့်သွင်းပါ","validator.digits":"နံပါတ်များသာဖြည့်ပါ","validator.maxlength":"ကျေးဇူးပြု၍ {0} ထပ်မပိုသော ဂဏန်းများသာဖြည့်ပါ","validator.minlength":"ကျေးဇူးပြု၍ အနည်းဆုံး {0} ဂဏန်းဖြည့်ပါ","validator.phone":"မှန်ကန်သော ဖုန်းနံပါတ်ထည့်သွင်းပါ"},"km-KH":{"validator.required":"ព័ត៌មានចាំបាច់ដែលត្រូវបំពេញ","validator.email":"សូមវាយអាសយដ្ឋានអ៊ីម៉ែលឲ្យបានត្រឹមត្រូវ","validator.number":"សូមវាយបញ្ចូលលេខឲ្យបានត្រឹមត្រូវ","validator.digits":"វាយបញ្ចូលបានតែលេខប៉ុណ្ណោះ","validator.maxlength":"សូមវាយបញ្ចូលកុំឲ្យលើស {0} តួអក្សរ","validator.minlength":"សូមវាយបញ្ចូលតិចបំផុត {0} តួអក្ស","validator.phone":"សូមវាយបញ្ចូលលេខឲ្យបានត្រឹមត្រូវ"},"zh-TW":{"validator.required":"此為必填欄位","validator.email":"請填入有效的 email 地址","validator.number":"請填入有效的電話號碼","validator.digits":"此欄位僅能輸入數字","validator.maxlength":"請輸入少於 {0} 位數","validator.minlength":"請輸入至少 {0} 位數","validator.phone":"請填入有效的電話號碼"},"th-TH":{"validator.required":"ต้องระบุข้อมูลในช่องนี้","validator.email":"กรุณาใส่อีเมล์ที่ถูกต้อง","validator.number":"กรุณาใส่ตัวเลขที่ถูกต้อง","validator.digits":"กรุณาส่เฉพาะตัวเลข","validator.maxlength":"กรุณาใส่ตัวเลขมากกว่า {0} หลัก","validator.minlength":"กรุณาใส่ตัวเลขอย่างน้อย {0} หลัก","validator.phone":"กรุณาใส่ตัวเลขที่ถูกต้อง"},"tl-PH":F},U=function(e){var n=R[e];return n||R["en-PH"]},W=function(){return o.createElement("style",{dangerouslySetInnerHTML:{__html:"\n /* lead-modal : start */\n .lead-modal {\n font-family: 'Open sans', sans-serif !important;\n position: fixed;\n z-index: 99999;\n width: 100%;\n height: 100%;\n left: 0;\n top: 0;\n opacity: 1;\n visibility: visible;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: transparent;\n padding: 10px;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n white-space: normal !important;\n }\n\n .lead-modal__wrapper {\n position: relative;\n width: 100%;\n max-width: 450px;\n background-color: #fff;\n border-radius: 6px;\n box-shadow: 0 14px 28px rgba(0, 0, 0, 0.25), 0 10px 10px rgba(0, 0, 0, 0.22);\n }\n\n .lead-modal__content {\n width: inherit;\n overflow: auto;\n /* min-height: 400px; */\n max-height: calc(100vh - 125px);\n -webkit-overflow-scrolling: touch;\n }\n\n .lead-modal__header {\n padding: 0px 0px;\n }\n\n .lead-modal__image {\n display: block;\n margin: 0 auto;\n border: none !important;\n box-shadow: none !important;\n }\n .lead-modal-image-logo {\n margin-top: 15px;\n margin-bottom: 15px;\n }\n\n .lead-modal-image-cover {\n width: 100% !important;\n padding: 0 0px;\n border-top-left-radius: 4px;\n border: none !important;\n box-shadow: none !important;\n /* margin: 0 !important; */\n }\n\n .lead-modal__image + .lead-modal__image {\n /* margin-top: 10px; */\n /* border-radius: 4px; */\n }\n\n .lead-modal__body {\n font-family: 'Open sans', sans-serif !important;\n padding: 15px 15px 25px 15px;\n }\n\n .lead-modal__title {\n font-family: 'Open sans', sans-serif !important;\n font-size: 20px !important;\n font-weight: bold !important;\n font-stretch: normal !important;\n font-style: normal !important;\n line-height: 1.3 !important;\n letter-spacing: -0.4px !important;\n color: #2a4975 !important;\n box-shadow: none !important;\n padding-bottom: 0 !important;\n }\n\n .lead-modal__title.pink {\n color: #2661ad !important;\n }\n\n .lead-modal__description {\n font-family: 'Open sans', sans-serif !important;\n font-size: 13px !important;\n font-weight: normal !important;\n font-stretch: normal !important;\n font-style: normal !important;\n line-height: 1.62 !important;\n letter-spacing: 0.14px !important;\n color: #2c87f3 !important;\n margin-top: 10px !important;\n }\n\n .lead-modal__description.pink {\n color: #3e3f58 !important;\n }\n\n .lead-modal__form-control-wrapper {\n margin-top: 10px;\n margin-left: 0px !important;\n position: relative;\n }\n\n .lead-modal__form-control {\n box-shadow: none !important;\n height: 40px !important;\n width: 100%;\n padding-left: calc(15px + 1.5em + 15px) !important;\n background-color: #fff !important;\n padding-top: 10px !important;\n padding-bottom: 10px !important;\n padding-right: 15px !important;\n border: solid 1px #dddddd !important;\n color: #2a4975 !important;\n line-height: 1.7em !important;\n border-radius: 0 !important;\n font-family: 'Open Sans', sans-serif !important;\n background-image: linear-gradient(transparent, transparent) !important;\n margin-left: 0px !important;\n font-size: 14px !important;\n line-height: 14px !important;\n }\n\n .lead-modal__form-control {\n &:focus {\n border-color: var(--color-primary);\n box-shadow: 0px 0px 0px 3px rgba(44, 135, 243, 0.1);\n outline: none;\n }\n\n &::-webkit-input-placeholder {\n /* Chrome, Firefox, Opera, Safari 10.1+ */\n color: #b5b5b5;\n }\n\n &::-moz-placeholder {\n color: #b5b5b5;\n }\n\n &:-ms-input-placeholder {\n color: #b5b5b5;\n }\n\n &::-ms-input-placeholder {\n color: #b5b5b5;\n }\n\n &::placeholder {\n color: #b5b5b5;\n }\n }\n\n img.lead-modal__form-control-icon {\n display: inline-block !important;\n color: #b5b5b5 !important;\n fill: #b5b5b5 !important;\n line-height: 1 !important;\n flex-shrink: 0 !important;\n max-width: initial !important;\n display: block !important;\n position: absolute !important;\n pointer-events: none !important;\n left: 15px !important;\n top: 10px !important;\n height: 20px !important;\n width: 20px !important;\n border: none !important;\n margin: 0 !important;\n }\n\n .lead-modal__checkbox-wrapper {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n align-items: center;\n margin-top: 15px;\n a {\n color: #2c87f3 !important;\n text-decoration: none !important;\n }\n\n a:visited {\n color: #2c87f3 !important;\n }\n &.pink a,\n &.pink a:visited {\n color: #e55c8a !important;\n }\n }\n\n .lead-modal__checkbox {\n position: relative;\n z-index: 1;\n display: inline-block;\n font-size: 20px;\n }\n\n .lead-modal__checkbox__input {\n position: relative;\n margin: 0 !important;\n padding: 0;\n opacity: 0;\n height: 1em !important;\n width: 1em !important;\n display: block;\n z-index: 1;\n font-size: 1em !important;\n }\n\n .lead-modal__checkbox__control {\n position: absolute;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n z-index: -1;\n pointer-events: none;\n transition: transform 0.2s;\n color: #dddddd;\n &::before,\n &::after {\n content: '';\n position: absolute;\n }\n\n &::before {\n width: 120%;\n height: 120%;\n background-color: currentColor;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%) scale(0);\n opacity: 0;\n border-radius: 50%;\n will-change: transform;\n transition: transform 0.2s;\n }\n\n &::after {\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: #fff;\n border-radius: 6px;\n -webkit-box-shadow: inset 0 0 0 1px #dddddd;\n box-shadow: inset 0 0 0 1px #dddddd;\n }\n\n &:focus::after {\n box-shadow: inset 0 0 0 1px #2c87f3;\n }\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control::after,\n .lead-modal__checkbox__input:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-color: currentColor;\n background-repeat: no-repeat;\n background-position: center;\n background-size: 18px;\n box-shadow: none;\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control {\n color: #2c87f3;\n }\n\n .lead-modal__checkbox__input:checked ~ .lead-modal__checkbox__control::after {\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpolyline points='2.5 8 6.5 12 13.5 3' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5'/%3E%3C/svg%3E\");\n }\n\n .lead-modal__checkbox__input:indeterminate ~ .lead-modal__checkbox__control {\n color: var(--custom-checkbox-color-disabled);\n }\n\n .lead-modal__checkbox__input:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cline x1='2' y1='8' x2='14' y2='8' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'/%3E%3C/svg%3E\");\n }\n\n .lead-modal__checkbox__input:active ~ .lead-modal__checkbox__control {\n transform: scale(0.9);\n }\n\n .lead-modal__checkbox__input:checked:active ~ .lead-modal__checkbox__control,\n .lead-modal__checkbox__input:indeterminate:active\n ~ .lead-modal__checkbox__control {\n transform: scale(1);\n }\n\n .lead-modal__checkbox__input:focus ~ .lead-modal__checkbox__control::before {\n opacity: 0.2;\n transform: translate(-50%, -50%) scale(1);\n }\n\n .lead-modal__checkbox__input.pink ~ .lead-modal__checkbox__control::after {\n border-radius: 50% !important;\n }\n\n .lead-modal__checkbox__input.pink:checked ~ .lead-modal__checkbox__control {\n color: #2661ad;\n }\n\n .lead-modal__checkbox__input.pink:checked\n ~ .lead-modal__checkbox__control::after,\n .lead-modal__checkbox__input.pink:indeterminate\n ~ .lead-modal__checkbox__control::after {\n background-size: 12px;\n }\n\n .lead-modal__checkbox__label {\n /* font-family: OpenSans; */\n font-size: 13px;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: 0.14px;\n color: #969696;\n margin-left: 10px;\n margin-bottom: 0 !important;\n }\n\n .lead-modal__btn {\n display: block;\n width: 100%;\n border: none;\n color: #fff;\n padding: 12px 10px;\n font-weight: 700;\n text-align: center;\n margin-top: 15px;\n border-radius: 4px;\n background-color: #2699fb;\n transition: all 0.2s ease-in-out;\n text-shadow: none !important;\n box-shadow: none !important;\n font-family: 'Open sans', sans-serif !important;\n font-size: 14px;\n cursor: pointer !important;\n &:hover,\n &:active {\n background-color: #337eff;\n }\n\n &.pink {\n background-color: #e55c8a;\n }\n\n &.pink:hover {\n background-color: #b4466a;\n }\n }\n\n .lead-modal__close-btn {\n position: absolute;\n padding-top: 5px;\n top: -15px;\n right: -10px;\n width: 35px;\n height: 35px;\n box-shadow: -2px 4px 4px 0 rgba(191, 191, 191, 0.44) !important;\n text-shadow: none !important;\n background-color: #005cfd;\n border-radius: 50%;\n line-height: inherit;\n appearance: none;\n border: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.2s ease-in-out;\n outline: none;\n z-index: 1;\n padding: 5px 13px !important;\n cursor: pointer !important;\n &:hover,\n &:active {\n background-color: #337eff;\n }\n\n &.pink {\n background-color: #fff;\n }\n\n &.pink .lead-modal__close-icon {\n color: #000;\n }\n\n &.pink:hover .lead-modal__close-icon {\n color: #e55c8a;\n transition: 0.3s all ease;\n }\n }\n\n .lead-modal__close-icon {\n display: inline-block;\n color: #fff;\n fill: #fff;\n height: 1em;\n width: 1em;\n line-height: 1;\n flex-shrink: 0;\n max-width: initial;\n transition: 0.3s all ease;\n }\n\n .lead-modal__thank-you {\n padding: 0 15px;\n display: flex;\n align-items: center;\n justify-content: center;\n height: inherit;\n text-align: center;\n min-height: 400px;\n h1 {\n margin-top: 10px;\n font-size: 32px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: -0.23px;\n color: #1b3250;\n }\n\n p {\n margin-top: 5px;\n font-size: 16px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: normal;\n letter-spacing: -0.11px;\n color: #1b3250;\n }\n img {\n max-width: 100% !important;\n border: none !important;\n width: auto !important;\n margin: 0 auto !important;\n }\n\n &.hidden {\n display: none;\n }\n }\n\n /* lead-modal : end */\n\n .modal__container {\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n z-index: 1000000000000;\n pointer-events: none;\n overflow-y: scroll;\n }\n\n .modal__content {\n position: relative;\n width: 80vw;\n margin: auto 0;\n }\n\n /* Make clicks pass-through */\n #nprogress {\n pointer-events: none;\n }\n\n #nprogress .bar {\n background: #223bdd;\n\n position: fixed;\n z-index: 1031;\n top: 0;\n left: 0;\n\n width: 100%;\n height: 2px;\n }\n\n /* Fancy blur effect */\n #nprogress .peg {\n display: block;\n position: absolute;\n right: 0px;\n width: 100px;\n height: 100%;\n box-shadow: 0 0 10px #29d, 0 0 5px #29d;\n opacity: 1;\n transform: rotate(3deg) translate(0px, -4px);\n }\n\n /* Remove these to get rid of the spinner */\n #nprogress .spinner {\n display: block;\n position: fixed;\n z-index: 1031;\n top: 15px;\n right: 15px;\n }\n\n #nprogress .spinner-icon {\n width: 18px;\n height: 18px;\n box-sizing: border-box;\n\n border: solid 2px transparent;\n border-top-color: #29d;\n border-left-color: #29d;\n border-radius: 50%;\n\n -webkit-animation: nprogress-spinner 400ms linear infinite;\n animation: nprogress-spinner 400ms linear infinite;\n }\n\n .nprogress-custom-parent {\n overflow: hidden;\n position: relative;\n }\n\n .nprogress-custom-parent #nprogress .spinner,\n .nprogress-custom-parent #nprogress .bar {\n position: absolute;\n }\n\n @-webkit-keyframes nprogress-spinner {\n 0% {\n -webkit-transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n }\n }\n @keyframes nprogress-spinner {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n\n .lead-modal__btn:disabled {\n background: #d5d5d5 !important;\n }\n\n .dateclass {\n width: 100%;\n }\n\n .dateclass.placeholderclass::before {\n width: 100%;\n content: attr(placeholder);\n color: #b8b8b8;\n }\n\n .dateclass.placeholderclass:hover::before {\n width: 0%;\n content: '';\n }\n\n /* Change Autocomplete styles in Chrome*/\n .lead-modal input:-webkit-autofill,\n .lead-modal input:-webkit-autofill:hover,\n .lead-modal input:-webkit-autofill:focus,\n .lead-modal textarea:-webkit-autofill,\n .lead-modal textarea:-webkit-autofill:hover,\n .lead-modal textarea:-webkit-autofill:focus,\n .lead-modal select:-webkit-autofill,\n .lead-modal select:-webkit-autofill:hover,\n .lead-modal select:-webkit-autofill:focus {\n -webkit-box-shadow: 0 0 0 1000px white inset !important;\n -webkit-text-fill-color: #2a4975;\n }\n\n .lead-modal label.error {\n font-size: 13px;\n color: #fa140f;\n margin-bottom: 0;\n margin-left: 0px !important;\n line-height: 1.65 !important;\n width: 100%;\n display: block;\n }\n\n /* === Lead gen wrapper === */\n .le-text-align-center {\n text-align: center !important;\n }\n .le-text-align-left {\n text-align: left !important;\n }\n .le-text-align-right {\n text-align: right !important;\n }\n\n .le-only-desktop {\n display: none !important;\n }\n .le-only-mobile {\n display: block !important;\n }\n\n .le-only-desktop a {\n text-decoration: none !important;\n }\n\n .le-only-mobile a {\n text-decoration: none !important;\n }\n\n @media screen and (min-width: 992px) {\n .le-newbuilder-LightBoxB,\n .le-newbuilder-InlineB {\n display: flex !important;\n }\n\n .le-newbuilder-LightBoxB .lead-modal__header,\n .le-newbuilder-InlineB .lead-modal__header {\n max-width: 50%;\n }\n }\n\n @media screen and (min-width: 768px) {\n .le-only-desktop {\n display: block !important;\n }\n\n .le-only-mobile {\n display: none !important;\n }\n\n .le-newbuilder-LightBoxB .lead-modal__body,\n .le-newbuilder-InlineB .lead-modal__body {\n flex: 1;\n }\n\n .le-newbuilder-wrap-LightBoxB {\n max-width: 720px !important;\n }\n .le-newbuilder-wrap-InlineB {\n max-width: 100% !important;\n }\n .le-newbuilder-LightBoxB .le-only-desktop.lead-modal-image-cover {\n max-width: 400px !important;\n }\n }\n\n .lead-modal__title {\n margin: 7px 0 !important;\n }\n\n .lead-modal__description {\n margin: 0;\n }\n\n .lead-modal-image-cover,\n .lead-modal__wrapper {\n border-radius: 0px !important;\n }\n\n .lead-modal__form {\n margin: 0;\n display: block !important;\n }\n\n .lead-modal__image + .lead-modal__image {\n margin-top: 0px;\n }\n\n .lead-modal__thank-you {\n width: 100%;\n }\n\n /* Skins */\n .le-skin-a-desktop {\n position: fixed;\n z-index: 99999;\n top: 0;\n left: 0;\n height: 100%;\n display: flex;\n align-items: center;\n }\n\n .le-skin-b-desktop {\n }\n\n .le-join-now {\n }\n\n .le-joinbow-btn {\n background: #2c87f3;\n color: #ffffff;\n font-size: 16px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 30px;\n border: none !important;\n border: 1px solid transparent !important;\n cursor: pointer !important;\n }\n .le-joinbow-btn:hover {\n border: 1px solid white !important;\n }\n\n .le-joinbow-btn-mobile {\n background: #2c87f3;\n color: #ffffff;\n font-size: 14px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 30px;\n border: none !important;\n }\n\n .le-newbuilder-close-svg {\n border-radius: 50%;\n width: 35px;\n height: 35px;\n background: #005cfd;\n cursor: pointer !important;\n }\n .le-mobile-btn {\n width: 24px;\n height: 24px;\n }\n\n .le-newbuilder-close-button {\n padding: 0;\n background: transparent;\n box-shadow: none;\n border: none;\n width: auto !important;\n cursor: pointer !important;\n }\n .le-abs-top-right {\n position: absolute;\n right: 10px;\n top: 10px;\n }\n\n .le-abs-outer-top-right {\n position: absolute;\n right: 0px;\n top: -45px;\n }\n\n /* Skin floating */\n .le-floating-desktop {\n position: fixed;\n bottom: 40px;\n left: 25px;\n z-index: 9999;\n }\n\n .le-floating-desktop-wrap {\n background: #fff;\n backdrop-filter: blur(30px);\n box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);\n padding: 0px;\n padding-right: 30px;\n border-radius: 5px;\n display: flex;\n align-items: center;\n }\n\n .le-floating-desktop-title {\n font-size: 20px;\n font-weight: bold;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.5;\n letter-spacing: normal;\n color: #2a4975;\n max-width: 530px;\n }\n .le-floating-desktop-desc {\n font-size: 13px;\n font-weight: normal;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.65;\n letter-spacing: normal;\n color: #2699fb;\n max-width: 530px;\n }\n\n .le-joinbow-floating-btn {\n background: #2c87f3;\n color: #ffffff;\n font-size: 14px;\n text-align: center;\n outline: none !important;\n box-shadow: none !important;\n padding: 12px 40px;\n border: none !important;\n border: 1px solid transparent !important;\n font-weight: 500;\n cursor: pointer !important;\n }\n\n /* // Floating mobile */\n .le-floating-mobile {\n position: fixed;\n bottom: 0px;\n left: 0px;\n width: 100%;\n z-index: 9999;\n }\n .le-abs-outer-mobile-top-right {\n position: absolute;\n right: 2px;\n top: -30px;\n }\n\n .le-floating-mobile-wrap {\n background: #fff;\n box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);\n padding: 10px 15px;\n }\n .le-floating-mobile-title {\n font-size: 18px;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.5;\n letter-spacing: normal;\n color: #2a4975;\n font-weight: 600;\n }\n .le-floating-mobile-desc {\n font-size: 12px;\n font-stretch: normal;\n font-style: normal;\n line-height: 1.65;\n letter-spacing: normal;\n color: #2699fb;\n }\n\n /* // Tab popup */\n .le-tab-popup {\n position: fixed;\n bottom: 15px;\n left: 15px;\n max-width: 150px;\n }\n .le-abs-outer-mobile-top-right-2 {\n position: absolute;\n right: -12px;\n top: -15px;\n }\n\n .le-center-tab-popup {\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n z-index: 99999999 !important;\n width: calc(100% - 40px);\n max-width: 400px;\n }\n\n .le-center-tab-popup img {\n max-width: 100% !important;\n }\n\n /* // Popup */\n .le-checkbox-title {\n font-size: 15px;\n font-weight: bold;\n font-stretch: normal;\n font-style: normal;\n color: #2a4975;\n margin: 13px 0 !important;\n /* line-height: 1.65 !important; */\n }\n\n /* Checkbox */\n .lead-checkbox-container {\n position: relative;\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 14px;\n line-height: 1.65;\n margin: 10px 0;\n }\n\n .lead-checkbox-checkmark {\n display: inline-block;\n height: 24px;\n border: solid 1px #d0d0d0;\n vertical-align: middle;\n margin-right: 8px;\n position: relative;\n border-radius: 4px;\n flex: 0 0 24px;\n }\n\n .lead-checkbox-container input {\n position: absolute;\n opacity: 0;\n top: 0;\n left: 0;\n }\n\n .lead-checkbox-checkmark::after {\n position: absolute;\n content: '';\n }\n\n .lead-checkbox-container input:checked ~ .lead-checkbox-checkmark {\n background: #337eff;\n border: solid 1px #337eff;\n }\n\n .lead-checkbox-container input:checked ~ .lead-checkbox-checkmark::after {\n left: 8px;\n top: 3px;\n width: 7px;\n height: 12px;\n border: solid white;\n border-width: 0 2px 2px 0;\n transform: rotate(45deg);\n }\n /* End checkbox */\n\n .le-fullscreen-img {\n position: absolute;\n left: 0;\n top: 0;\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n @media screen and (min-width: 768px) {\n .lead-fullscreen-desktop-close-btn {\n position: fixed;\n top: 27px;\n right: 23px;\n }\n }\n\n /* // Inline */\n .lead-modal.le-buider-inline {\n position: static;\n display: block;\n padding: 20px 0;\n height: initial !important;\n padding-top: 10px;\n }\n\n .lead-modal.le-buider-inline .lead-modal__wrapper {\n box-shadow: none;\n border: 1px solid #ddd;\n }\n .lead-modal.le-buider-inline .lead-modal__content {\n max-height: initial !important;\n }\n .lead-modal.le-buider-inline .lead-modal__content .lead-modal__header img {\n /* height: auto !important; */\n object-fit: fill;\n }\n\n .le-thankyou-title {\n font-size: 24px !important;\n margin-bottom: 8px !important;\n color: #2a4975 !important;\n }\n\n .le-thankyou-subtitle {\n font-size: 14px !important;\n color: #2699fb !important;\n margin: 0 !important;\n }\n\n /* Radio */\n .lead-radio-container {\n position: relative;\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 14px;\n line-height: 1.65;\n margin: 10px 0;\n }\n\n .lead-radio-checkmark {\n display: inline-block;\n height: 24px;\n border: solid 1px #d0d0d0;\n vertical-align: middle;\n margin-right: 8px;\n position: relative;\n border-radius: 50%;\n flex: 0 0 24px;\n }\n\n .lead-radio-container input {\n position: absolute;\n opacity: 0;\n top: 0;\n left: 0;\n }\n\n .lead-radio-checkmark::after {\n position: absolute;\n content: '';\n }\n\n .lead-radio-container input:checked ~ .lead-radio-checkmark {\n background: #337eff;\n border: solid 1px #337eff;\n }\n\n .lead-radio-container input:checked ~ .lead-radio-checkmark::after {\n left: 50%;\n top: 50%;\n width: 8px;\n height: 8px;\n background: #fff;\n border-radius: 50%;\n transform: translate(-50%, -50%);\n }\n /* End Radio */\n\n /* Dropdown */\n .le-newbuilder-select {\n width: 100%;\n padding: 12px;\n border-radius: 4px;\n border: solid 1px #d0d0d0;\n outline: none;\n appearance: none;\n font-size: 15px;\n padding-right: 35px;\n }\n .le-newbuilder-select-wrapper {\n position: relative;\n }\n .le-newbuilder-select-wrapper::after {\n content: '';\n position: absolute;\n right: 15px;\n top: 18px;\n transform: rotate(45deg);\n width: 10px;\n height: 10px;\n border: 2px solid #616060;\n border-left: transparent;\n border-top: transparent;\n }\n /* End Dropdown */\n\n .le-buider-slider {\n width: 420px;\n height: auto;\n bottom: 15px;\n top: unset;\n left: -200px;\n animation: le-builder-slide 0.5s forwards;\n }\n\n @keyframes le-builder-slide {\n 100% {\n left: 15px;\n }\n }\n\n @media screen and (max-width: 768px) {\n .le-buider-slider,\n .le-buider-fullscreen {\n display: none !important;\n }\n }\n\n .le-skin-mobile {\n margin-top: 64px;\n }\n"}})};function J(n){var t=n.leadApi,o=n.leadSiteId,l=n.leadDomain,i=n.onShowPopup,r=("https://"+location.hostname+location.pathname+location.search).toLowerCase();fetch(t+"api/campaign/"+o,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:r,ga_client_id:h("_ga")||null})}).then((function(e){return e.json()})).then((function(n){var t,o,c;if(console.log("List campagin: ",n),T="https://"+location.hostname+location.pathname+location.search,1==n._status){var d=n._data.campaigns;h("hhg-id")||(g("hhg-id",v(),{domain:"."+l,path:"/"}),console.log("😍 Set HHG ID cookie"));var s=[];s=/Android|webOS|iPhone|iPad|iPod|BlackBerry|BB|PlayBook|IEMobile|Windows Phone|Kindle|Silk|Opera Mini/i.test(navigator.userAgent)?d.filter((function(e){return e.device_types.some((function(e){return e.id==C}))})):d.filter((function(e){return e.device_types.some((function(e){return e.id==S}))})),console.log("👓 campaignsDevice",s);var m=s.map((function(e,n){return e.targets.filter((function(e){return e.type==w})).map((function(e){return a(a({},e),{campaignIndex:n})}))})).flat(1);m=m.filter((function(e){var n=new URL(String(e.target).toLowerCase());return"exact_match"==e.option?Boolean(location.pathname===n.pathname):"start_with"==e.option?!!location.pathname.includes(n.pathname)&&!e.sub_target.filter((function(e){return"excluding"==e.option})).map((function(e){return e.value})).includes(r):void 0}));var p=Array.from(document.getElementsByTagName("META")).filter((function(e){return"article:tag"==e.getAttribute("property")})).map((function(e){return e.content})),u=[];p&&p.length&&(u=s.map((function(e,n){return e.targets.filter((function(e){return e.type==E})).map((function(e){return a(a({},e),{campaignIndex:n})}))})).flat(1).filter((function(e){return p.includes(e.target)})));var b=e(e([],m,!0),u,!0),f=document.cookie.split("; ").map((function(e){return e.split("=")[0]})),k=f.filter((function(e){return e.includes("lead_submited")}));console.log("--listCampaignCodeSubmited",k);var x=f.filter((function(e){return e.includes("lead_closed")}));console.log("--listCampaignCodeClosed",x);var _,y=e(e([],k,!0),x,!0);if(_=b.filter((function(e){return!y.some((function(n){return n.includes(s[e.campaignIndex].code)}))})).sort((function(e,n){return e.score-n.score})),console.log("--listCampaignValid : ",_),_&&_.length){var N=s[_[0].campaignIndex];console.log("CAMPAIGN_SHOW",N);var B=N.rules,j=Number(null===(t=B.find((function(e){return"time"==e.rule})))||void 0===t?void 0:t.value);console.log("timeoutRule",j);var L=Number(null===(o=B.find((function(e){return"scroll"==e.rule})))||void 0===o?void 0:o.value);console.log("scrollRule",L);var O=Number(null===(c=B.find((function(e){return"exclude_sponsored"==e.rule})))||void 0===c?void 0:c.value);console.log("excludeSponsored",O);var P=Boolean(document.querySelector(".hhg-disclaimer-text"));if(console.log("💎 LEAD current page isSponsored",P),P&&O)return;var I="TIME";if(Number.isInteger(j)&&(I="TIME",console.log("✨ SHOW AWESOME POPUP AFTER: ",j," seconds"),setTimeout((function(){null==i||i(N,I)}),1e3*j)),Number.isInteger(L)){I="SCROLL",console.log("✨ SHOW AWESOME AFTER: SCROLL",L," %");var A=document.querySelector('[data-url="'.concat(location.pathname,'"]'))||document.querySelector("body"),z=A.getBoundingClientRect().top,D=A.offsetHeight;console.log("👓 Element check scroll: ",A);var H=function(){var e=window.pageYOffset||document.documentElement.scrollTop,n=0;e>=z&&(n=Math.round((e-z)/(D-innerHeight)*100)),console.log("---Scroll",n,L),n>=L&&(window.removeEventListener("scroll",H),null==i||i(N,I))};window.addEventListener("scroll",H)}}else console.log("🚧 No lead campaigns on current URL, tags")}})).catch((function(e){console.error("Lead error: ",e)}))}var Q=function(e){var a=e.apiUrl,l=e.siteDomain,r=e.siteId,b=e.locale,v=s(),k=s(Date.now()),x=i((function(){var e=a;return e.includes("localhost")&&(e="https://dev.leadgen.hellobacsi.com/"),{apiUrl:e}}),[a,l,r]).apiUrl,_=c(null),y=_[0],w=_[1],E=c(""),N=E[0],C=E[1],S=c(null),B=S[0],T=S[1],j=function(e,n){w(e),C(n)},P=function(){var e,n;if(y){console.log("👋👋👋 CLOSE POPUP ".concat(y.code," 👋👋👋"));var t=Number(null===(e=y.rules.find((function(e){return"show_again_after_exit "==e.rule})))||void 0===e?void 0:e.value),a=Number(null===(n=y.rules.find((function(e){return"days_to_show_again"==e.rule})))||void 0===n?void 0:n.value);0==t&&g("lead_closed_".concat(y.code),"target_".concat(y.extra_fields.popupVersion),a?{domain:"."+l,days:a,path:"/"}:{domain:"."+l,path:"/"}),document.body.classList.remove("noscroll"),fetch("".concat(x,"api/campaign/").concat(y.code,"/popup_exit"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:"CLICK",url:location.href.toLowerCase(),title_article:document.title,cookie_id:h("hhg-id"),duration:Math.ceil((Date.now()-k.current)/1e3)})}),w(null),T(null)}};d((function(){if(window.next){var e=m((function(e){console.log("--🌻 routeChangeComplete",e,Date.now());var n=location.pathname;P(),document.querySelectorAll('[data-popup-url="'.concat(n,'"]')).length||J({leadApi:x,leadDomain:l,leadSiteId:r,onShowPopup:j}),v.current&&window.removeEventListener("scroll",v.current)}),500);window.next.router.events.on("routeChangeComplete",e)}J({leadApi:x,leadDomain:l,leadSiteId:r,onShowPopup:j})}),[]);return d((function(){y&&(k.current=Date.now())}),[y]),o.createElement(O.Provider,{value:{apiUrl:x,siteDomain:l,siteId:r,locale:b}},o.createElement(u.Provider,{value:{locale:b,values:U(b)}},o.createElement(W,null),p(o.createElement(o.Fragment,null,y&&o.createElement(V,{campaign:y,onClose:P,onSubmit:function(e,a,o,i){return n(void 0,void 0,void 0,(function(){var n,r,c,d,s,m,p,u,b,f,v,k,_,w,E,N,C,S,B,j,O,I,A,z,D,H,M,q,V,F,R,U,W,J;return t(this,(function(t){switch(t.label){case 0:return e.preventDefault(),console.log("submitHandler",a,o),n=new FormData(e.currentTarget),r={},n.forEach((function(e,n){r[n]=r[n]||[],r[n].push(e)})),c=Object.keys(r).map((function(e){return{name:e,value:String(r[e])}})),d=2,s=h("_ga")||null,window.intlTelInputUtils?[3,2]:[4,require("intl-tel-input/build/js/utils")];case 1:t.sent(),t.label=2;case 2:return m={url:location.href.toLowerCase(),title_article:document.title,meta:c.map((function(e){var n,t,a;return{key:null===(n=document.querySelector(".lead-modal__form.".concat(i,' [name="').concat(e.name,'"]')))||void 0===n?void 0:n.getAttribute("data-key"),value:(null==L?void 0:L.countryCodeNumber)&&["tel","tel1","tel2","tel3"].includes(e.name)?window.intlTelInputUtils.formatNumber(String(e.value),null==L?void 0:L.countryCodeNumber,d).replace(/\s+/g,""):e.value,control:e.name.replace("1","").replace("2","").replace("3",""),is_sent_mailchimp:(null===(a=document.querySelector(".lead-modal__form.".concat(i," .mailchimp-").concat(null===(t=document.querySelector(".lead-modal__form.".concat(i,' [name="').concat(e.name,'"]')))||void 0===t?void 0:t.getAttribute("data-key"))))||void 0===a?void 0:a.getAttribute("data-mailchimp"))||"false"}})),cookie_id:h("hhg-id"),ga_client_id:s},a&&o[a].value_en&&(m.category=o[a].value_en),p=Number((null===(D=null===(z=y.rules)||void 0===z?void 0:z.find((function(e){return"days_to_show_again"===e.rule})))||void 0===D?void 0:D.value)||7),0==(u=Number((null===(M=null===(H=y.rules)||void 0===H?void 0:H.find((function(e){return"show_again_after_submit"===e.rule})))||void 0===M?void 0:M.value)||0))&&(console.log("⛔ Popup never show again!"),g("lead_submited_".concat(y.code),"target_".concat(y.extra_fields.targetType),{domain:"."+l,path:"/"})),1==u&&(console.log("⌛ Popup will show again after ".concat(p," days!")),g("lead_submited_".concat(y.code),"target_".concat(y.extra_fields.targetType),{domain:"."+l,days:p,path:"/"})),fetch("".concat(x,"api/campaign/").concat(y.code,"/lead"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(m)}),"notshow"==y.extra_fields.popupShowThankYou?(P(),document.body.classList.remove("noscroll"),[2]):(b=!0,f=y.thank_you_image||"".concat(x,"admin/img/thanksyou.png"),v=y.extra_fields.popupThankyouTitle||"Thank you.",k=y.extra_fields.popupThankyouDesc||"We appreciate your time!",_="",w="",C="","2.1"==y.extra_fields.popupVersion&&(S=y.extra_fields,B=JSON.parse(S.listBlockThankyou),j=B.find((function(e){return"TitleBlock"==e.name})),O=B.find((function(e){return"SubtitleBlock"==e.name})),I=B.find((function(e){return"LinkButtonBlock"==e.name})),v=(null===(q=null==j?void 0:j.data)||void 0===q?void 0:q.value)||"",_=(null===(V=null==j?void 0:j.data)||void 0===V?void 0:V.align)||"",k=(null===(F=null==O?void 0:O.data)||void 0===F?void 0:F.value)||"",w=(null===(R=null==O?void 0:O.data)||void 0===R?void 0:R.align)||"",E=(null===(U=null==I?void 0:I.data)||void 0===U?void 0:U.value)||"",N=(null===(W=null==I?void 0:I.data)||void 0===W?void 0:W.newtab)||!1,C=(null===(J=null==I?void 0:I.data)||void 0===J?void 0:J.url)||"",A=y.extra_fields.currentLayout,["SkinA","SkinB","Floating","Tab","CenterTab"].includes(A)&&(b=!1)),T(b?{title:v,titleAlign:_,subtitle:k,subtitleAlign:w,link:C,linkNewTab:N,linkText:E,image:f}:null),sessionStorage.getItem("insider_object")?window.insider_object=JSON.parse(sessionStorage.getItem("insider_object")):window.insider_object={user:{email:"",phone_number:"",gdpr_optin:!0,sms_optin:!0,email_optin:!0}},c.map((function(e){var n=e.name,t=e.value;"tel"==n?window.insider_object.user.phone_number=t:"email"==n&&(window.insider_object.user.email=t)})),sessionStorage.setItem("insider_object",JSON.stringify(window.insider_object)),[2])}}))}))},action:N,showThankyou:B})),f())))};export{Q as LeadGen};
|
package/build/esm/mantine.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as n,_ as t,b as r}from"./tslib.es6-2fa94e2c.js";import o,{useMemo as i,useState as a,useEffect as l}from"react";import{Autocomplete as c,Image as s,Select as d,Textarea as m,Modal as p,Badge as u,Spoiler as h,Accordion as g,Indicator as f,Avatar as v,LoadingOverlay as b,Checkbox as x,Slider as w,Radio as k,Switch as y,MantineProvider as E}from"@mantine/core";import{CommonGAssets as S}from"./gAssets.js";import{DatePicker as j,DateRangePicker as A}from"@mantine/dates";import P,{css as M}from"styled-components";import"dayjs";import"./screenSizeContext-ff96a3d1.js";import"./lazyLoad-59e8ff6d.js";import{t as z}from"./theme-13d11d67.js";import"./index-2cf746a8.js";import"./utils-40d4438f.js";import"./isProduction-6fc0946c.js";import{L as B}from"./Locale-69030fff.js";import{T as H}from"./index-a0e2043c.js";import{u as L}from"./useTranslations-b3eb31ef.js";import{D as R,a as D}from"./index-d87f080b.js";export{I as Input,e as emotionCache}from"./index-d87f080b.js";import{Carousel as T}from"@mantine/carousel";export{C as CentralCarousel}from"./index-d20231b7.js";import{useDebouncedValue as W}from"@mantine/hooks";import{B as F}from"./index-bfb83ce8.js";import{g as G}from"./defaultClassWrapper-27a74473.js";import"lodash/throttle";import"vanilla-lazyload";import"./translationsContext-e7808c8f.js";import"string-format";var O,N,U,V,q=function(e){var r=e.keepSearch,i=void 0!==r&&r,a=n(e,["keepSearch"]);return i?o.createElement(c,t({rightSection:o.createElement(s,{src:S.getAssetPath("chevron-down.svg"),fit:"none"}),size:"md",maxDropdownHeight:300},a)):o.createElement(d,t({rightSection:o.createElement(s,{src:S.getAssetPath("chevron-down.svg"),fit:"none"}),size:"md",maxDropdownHeight:300},a))},_=P(j)(N||(N=r(["\n position: relative;\n ","\n"],["\n position: relative;\n ","\n"])),(function(n){return n.fullWidth&&M(O||(O=r(["\n .mantine-DatePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "],["\n .mantine-DatePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "])))})),J=P(A)(V||(V=r(["\n position: relative;\n ","\n"],["\n position: relative;\n ","\n"])),(function(n){return n.fullWidth&&M(U||(U=r(["\n .mantine-DateRangePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "],["\n .mantine-DateRangePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "])))})),K=function(n){return o.createElement(_,t({size:"md",clearable:!1,fullWidth:!0,rightSection:o.createElement(s,{src:S.getAssetPath("OutlineCalendar.svg"),width:16,height:16})},n))};K.Range=function(n){return o.createElement(J,t({size:"md",clearable:!1,fullWidth:!0,rightSection:o.createElement(s,{src:S.getAssetPath("OutlineCalendar.svg"),width:16,height:16})},n))};var Q,X,Y,Z=P(m)(Q||(Q=r(["\n .mantine-Textarea-input {\n padding: 12px 16px;\n background: #ffffff;\n border: 1px solid ",";\n border-radius: 4px;\n }\n"],["\n .mantine-Textarea-input {\n padding: 12px 16px;\n background: #ffffff;\n border: 1px solid ",";\n border-radius: 4px;\n }\n"])),z.colors.gray200),$=function(n){return o.createElement(Z,t({minRows:2,maxRows:4},n))},nn=P(p)(X||(X=r(["\n .mantine-Modal-inner {\n border-radius: 6px;\n }\n .mantine-Modal-modal {\n padding: 0;\n }\n .mantine-Modal-header {\n border-bottom: 1px solid ",";\n margin-right: 0;\n margin-bottom: 0;\n padding: 16px;\n }\n .mantine-Modal-title {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-right: 0;\n }\n .mantine-Modal-close {\n cursor: pointer;\n width: 24px;\n height: 24px;\n }\n .mantine-Modal-body {\n padding: 40px;\n }\n"],["\n .mantine-Modal-inner {\n border-radius: 6px;\n }\n .mantine-Modal-modal {\n padding: 0;\n }\n .mantine-Modal-header {\n border-bottom: 1px solid ",";\n margin-right: 0;\n margin-bottom: 0;\n padding: 16px;\n }\n .mantine-Modal-title {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-right: 0;\n }\n .mantine-Modal-close {\n cursor: pointer;\n width: 24px;\n height: 24px;\n }\n .mantine-Modal-body {\n padding: 40px;\n }\n"])),z.colors.neutral100),en=function(e){var r=e.title,i=n(e,["title"]);return o.createElement(o.Fragment,null,o.createElement(nn,t({centered:!0},i,{withCloseButton:!1,title:o.createElement(o.Fragment,null,r,o.createElement("img",{className:"mantine-Modal-close",src:S.getAssetPath("CloseModal.svg"),onClick:function(){var n;return null===(n=i.onClose)||void 0===n?void 0:n.call(i)}}))})))},tn=function(e){var r=e.color,i=void 0===r?z.colors.primaryBase:r,a=n(e,["color"]);return o.createElement(u,t({variant:"filled",color:i,styles:{root:{borderRadius:"2px",background:i,textTransform:"unset"}}},a))},rn=function(e){var r=e.children,a=e.line,l=e.lineHeight,c=e.trackingAttributes,s=e.maxHeight,d=n(e,["children","line","lineHeight","trackingAttributes","maxHeight"]),m=L().t,p=i((function(){return s||(a&&l?a*l:(console.error("[HHG-Comp]:[Spoiler] Please provide maxHeight, or line with lineHeight"),0))}),[]);r||console.error("[HHG-Comp]:[Spoiler] Please provide children");var u=i((function(){return c?{"data-event-category":c.dataEventCategory,"data-event-action":c.dataEventAction,"data-event-label":c.dataEventLabel}:{}}),[c]);return o.createElement(h,t({showLabel:o.createElement(H,t({size:"p3",color:z.colors.primaryBase},u),m("articlePage.readMore")),hideLabel:o.createElement(H,t({size:"p3",color:z.colors.primaryBase},u),m("articlePage.showLess"))},d,{maxHeight:p}),r)},on=P(g)(Y||(Y=r(["\n .mantine-Accordion-control {\n &:hover {\n background-color: transparent;\n }\n }\n .mantine-Accordion-item {\n .mantine-Accordion-chevron {\n > div {\n background-repeat: no-repeat;\n width: 16px;\n height: 16px;\n background-position: center;\n background-image: url(",");\n }\n }\n &[data-active='true'] {\n .mantine-Accordion-chevron {\n > div {\n background-image: url(",");\n }\n }\n }\n }\n .mantine-Accordion-panel {\n border-radius: 6px;\n }\n .mantine-Accordion-content {\n white-space: pre-wrap;\n }\n"],["\n .mantine-Accordion-control {\n &:hover {\n background-color: transparent;\n }\n }\n .mantine-Accordion-item {\n .mantine-Accordion-chevron {\n > div {\n background-repeat: no-repeat;\n width: 16px;\n height: 16px;\n background-position: center;\n background-image: url(",");\n }\n }\n &[data-active='true'] {\n .mantine-Accordion-chevron {\n > div {\n background-image: url(",");\n }\n }\n }\n }\n .mantine-Accordion-panel {\n border-radius: 6px;\n }\n .mantine-Accordion-content {\n white-space: pre-wrap;\n }\n"])),(function(n){return n.closeChevron||S.getAssetPath("plus-icon.svg")}),(function(n){return n.openChevron||S.getAssetPath("minus-icon.svg")})),an=function(e){var r=e.children,i=n(e,["children"]);return o.createElement(on,t({chevron:o.createElement("div",null),disableChevronRotation:!0,transitionDuration:300},i),r)};an.Control=g.Control,an.Item=g.Item,an.Panel=g.Panel;var ln=S.getAssetPath("avatar.jpg"),cn=function(e){var r=e.withIndicator,i=void 0!==r&&r,a=e.indicatorConfig,l=void 0===a?null:a,c=e.size,s=void 0===c?56:c,d=e.children,m=n(e,["withIndicator","indicatorConfig","size","children"]),p=function(){return o.createElement(v,t({size:s,radius:"xl"},m),d||o.createElement("img",{src:ln,width:s}))};return i?o.createElement(f,t({inline:!0,position:"bottom-end",offset:9},l,{styles:{indicator:{backgroundColor:o.isValidElement(l.label)&&"transparent"}}}),p()):p()},sn=function(n){return o.createElement(b,t({loaderProps:{color:z.colors.primaryBase}},n))},dn=function(e){var r=e.slidesToShow,i=void 0===r?1:r,a=e.children,l=n(e,["slidesToShow","children"]);return o.createElement(T,t({slideSize:String(Math.floor(1/i*100))+"%",containScroll:"trimSnaps"},l),a)};dn.Slide=T.Slide;var mn=function(n){return o.createElement(x,t({},n))};mn.Group=x.Group;var pn,un,hn,gn="hhgcomp-mantine-slider-slider",fn=G(P(w)(pn||(pn=r(["\n .mantine-Slider-track {\n background-color: ",";\n }\n\n .mantine-Slider-label {\n background-color: transparent;\n color: #000;\n font-size: 14px;\n font-weight: bold;\n }\n"],["\n .mantine-Slider-track {\n background-color: ",";\n }\n\n .mantine-Slider-label {\n background-color: transparent;\n color: #000;\n font-size: 14px;\n font-weight: bold;\n }\n"])),(function(n){return n.color||n.theme.colors.primaryBase})),gn),vn=P.div(un||(un=r(["\n display: flex;\n align-items: center;\n ."," {\n flex-grow: 1;\n }\n"],["\n display: flex;\n align-items: center;\n ."," {\n flex-grow: 1;\n }\n"])),gn),bn=function(e){var r=e.color,i=void 0===r?z.colors.primaryBase:r,c=e.withControl,s=e.onChange,d=e.value,m=e.min,p=e.max,u=e.isStatic,h=n(e,["color","withControl","onChange","value","min","max","isStatic"]),g=a(d||m||0),f=g[0],v=g[1],b=W(f,R)[0];return l((function(){null==s||s(b)}),[b]),o.createElement(vn,null,c&&o.createElement(F,{type:"button",size:"sm",color:"ghost",onClick:function(){v((function(n){return m&&n===m?n:n-1}))}},o.createElement("svg",{width:"10",height:"10",fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 12 3"},o.createElement("path",{d:"M1 1.004h8",stroke:i,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}))),o.createElement(fn,t({thumbSize:21,labelAlwaysOn:!0,radius:"xl",color:i,value:f,onChange:u?function(){return null}:v,min:m,max:p},h)),c&&o.createElement(F,{type:"button",size:"sm",color:"ghost",onClick:function(){v((function(n){return p&&n===p?n:n+1}))}},o.createElement("svg",{width:"16",height:"20",fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},o.createElement("path",{d:"M8 4v8M4 8h8",stroke:i,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}))))},xn=P(k)(hn||(hn=r(["\n .mantine-Radio-icon {\n color: ",";\n }\n"],["\n .mantine-Radio-icon {\n color: ",";\n }\n"])),(function(n){return n.color||z.colors.primaryBase})),wn=function(n){return o.createElement(xn,t({size:"sm"},n))};wn.Group=k.Group;var kn,yn,Cn=P(y)(kn||(kn=r(["\n .mantine-Switch-track {\n }\n"],["\n .mantine-Switch-track {\n }\n"]))),En=((yn={})[B.Vietnam]="vi",yn[B.Cambodia]="km",yn[B.India]="hi",yn[B.Indonesia]="id",yn[B.Malaysia]="ms",yn[B.Thailand]="th",yn[B.Taiwan]="zh-tw",yn[B.PhilippinesTagalog]="tl-ph",yn[B.PhilippinesEnglish]="en",yn[B.Myanmar]="my",yn),Sn=function(n){l((function(){En[n]&&require("dayjs/locale/".concat(En[n],".js"))}),[n])},jn={"&:hover":{borderColor:"".concat(z.colors.blue200),boxShadow:"0 0 2px 2px ".concat(z.colors.blue200)}},An=function(n){return{datesLocale:En[n],dateFormat:D[n].dateFormat,fontFamily:n===B.Cambodia?"Battambang,":"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI',\n Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif",components:{InputWrapper:{styles:{label:{marginBottom:"0.5rem"}}},NumberInput:{defaultProps:{decimalSeparator:D[n].separator}},Input:{styles:{input:{borderRadius:"6px",transition:"all ".concat("100ms"," ease-in-out"),"&:hover, &:focus":{borderColor:"".concat(z.colors.blue200),boxShadow:"0 0 2px 2px ".concat(z.colors.blue200)}},rightSection:{pointerEvents:"none",cursor:"default"},invalid:{color:"#000"}}},Checkbox:{styles:{input:jn}},Radio:{styles:{radio:t(t({backgroundColor:"#ffffff"},jn),{"&:checked":{backgroundColor:"#ffffff"}})}}}}},Pn=function(e){var r=e.children,i=e.locale,a=n(e,["children","locale"]);return Sn(i),o.createElement(E,t({theme:An(i)},a),r)};export{an as Accordion,cn as Avatar,tn as Badge,dn as Carousel,mn as Checkbox,K as DatePicker,sn as LoadingOverlay,En as MAPPED_LOCALE,Pn as MantineProvider,en as Modal,wn as Radio,q as Select,bn as Slider,rn as Spoiler,Cn as Switch,$ as TextArea,An as getMantineThemeOverride,Sn as useMantineLocale};
|
|
1
|
+
import{c as n,_ as t,b as r}from"./tslib.es6-2fa94e2c.js";import o,{useMemo as i,useState as a,useEffect as l}from"react";import{Autocomplete as c,Image as s,Select as d,Indicator as m,Textarea as u,Modal as p,Badge as h,Spoiler as f,Accordion as g,Avatar as v,LoadingOverlay as b,Checkbox as x,Slider as w,Radio as k,Switch as y,MantineProvider as E}from"@mantine/core";import{CommonGAssets as S}from"./gAssets.js";import{DatePicker as j,DateRangePicker as A}from"@mantine/dates";import P,{css as M}from"styled-components";import"dayjs";import"./screenSizeContext-ff96a3d1.js";import"./lazyLoad-59e8ff6d.js";import{t as z}from"./theme-13d11d67.js";import"./index-2cf746a8.js";import"./utils-40d4438f.js";import"./isProduction-6fc0946c.js";import{L as B}from"./Locale-69030fff.js";import{T as H}from"./index-a0e2043c.js";import{u as L}from"./useTranslations-b3eb31ef.js";import{D as R,a as D}from"./index-d87f080b.js";export{I as Input,e as emotionCache}from"./index-d87f080b.js";import{Carousel as T}from"@mantine/carousel";export{C as CentralCarousel}from"./index-d20231b7.js";import{useDebouncedValue as W}from"@mantine/hooks";import{B as F}from"./index-bfb83ce8.js";import{g as G}from"./defaultClassWrapper-27a74473.js";import"lodash/throttle";import"vanilla-lazyload";import"./translationsContext-e7808c8f.js";import"string-format";var O,N,U,V,q=function(e){var r=e.keepSearch,i=void 0!==r&&r,a=n(e,["keepSearch"]);return i?o.createElement(c,t({rightSection:o.createElement(s,{src:S.getAssetPath("chevron-down.svg"),fit:"none"}),size:"md",maxDropdownHeight:300},a)):o.createElement(d,t({rightSection:o.createElement(s,{src:S.getAssetPath("chevron-down.svg"),fit:"none"}),size:"md",maxDropdownHeight:300},a))},_=P(j)(N||(N=r(["\n position: relative;\n ","\n"],["\n position: relative;\n ","\n"])),(function(n){return n.fullWidth&&M(O||(O=r(["\n .mantine-DatePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "],["\n .mantine-DatePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "])))})),J=P(A)(V||(V=r(["\n position: relative;\n ","\n"],["\n position: relative;\n ","\n"])),(function(n){return n.fullWidth&&M(U||(U=r(["\n .mantine-DateRangePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "],["\n .mantine-DateRangePicker-dropdown {\n min-width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "])))})),K=function(n){return o.createElement(_,t({size:"md",clearable:!1,fullWidth:!0,rightSection:o.createElement(s,{src:S.getAssetPath("OutlineCalendar.svg"),width:16,height:16})},n))};K.Range=function(n){return o.createElement(J,t({size:"md",clearable:!1,fullWidth:!0,rightSection:o.createElement(s,{src:S.getAssetPath("OutlineCalendar.svg"),width:16,height:16})},n))};var Q,X,Y,Z=function(n){return o.createElement(m,t({inline:!0,position:"top-end",offset:4,styles:{indicator:{backgroundColor:z.colors.red700}}},n))},$=P(u)(Q||(Q=r(["\n .mantine-Textarea-input {\n padding: 12px 16px;\n background: #ffffff;\n border: 1px solid ",";\n border-radius: 4px;\n }\n"],["\n .mantine-Textarea-input {\n padding: 12px 16px;\n background: #ffffff;\n border: 1px solid ",";\n border-radius: 4px;\n }\n"])),z.colors.gray200),nn=function(n){return o.createElement($,t({minRows:2,maxRows:4},n))},en=P(p)(X||(X=r(["\n .mantine-Modal-inner {\n border-radius: 6px;\n }\n .mantine-Modal-modal {\n padding: 0;\n }\n .mantine-Modal-header {\n border-bottom: 1px solid ",";\n margin-right: 0;\n margin-bottom: 0;\n padding: 16px;\n }\n .mantine-Modal-title {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-right: 0;\n }\n .mantine-Modal-close {\n cursor: pointer;\n width: 24px;\n height: 24px;\n }\n .mantine-Modal-body {\n padding: 40px;\n }\n"],["\n .mantine-Modal-inner {\n border-radius: 6px;\n }\n .mantine-Modal-modal {\n padding: 0;\n }\n .mantine-Modal-header {\n border-bottom: 1px solid ",";\n margin-right: 0;\n margin-bottom: 0;\n padding: 16px;\n }\n .mantine-Modal-title {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-right: 0;\n }\n .mantine-Modal-close {\n cursor: pointer;\n width: 24px;\n height: 24px;\n }\n .mantine-Modal-body {\n padding: 40px;\n }\n"])),z.colors.neutral100),tn=function(e){var r=e.title,i=n(e,["title"]);return o.createElement(o.Fragment,null,o.createElement(en,t({centered:!0},i,{withCloseButton:!1,title:o.createElement(o.Fragment,null,r,o.createElement("img",{className:"mantine-Modal-close",src:S.getAssetPath("CloseModal.svg"),onClick:function(){var n;return null===(n=i.onClose)||void 0===n?void 0:n.call(i)}}))})))},rn=function(e){var r=e.color,i=void 0===r?z.colors.primaryBase:r,a=n(e,["color"]);return o.createElement(h,t({variant:"filled",color:i,styles:{root:{borderRadius:"2px",background:i,textTransform:"unset"}}},a))},on=function(e){var r=e.children,a=e.line,l=e.lineHeight,c=e.trackingAttributes,s=e.maxHeight,d=n(e,["children","line","lineHeight","trackingAttributes","maxHeight"]),m=L().t,u=i((function(){return s||(a&&l?a*l:(console.error("[HHG-Comp]:[Spoiler] Please provide maxHeight, or line with lineHeight"),0))}),[]);r||console.error("[HHG-Comp]:[Spoiler] Please provide children");var p=i((function(){return c?{"data-event-category":c.dataEventCategory,"data-event-action":c.dataEventAction,"data-event-label":c.dataEventLabel}:{}}),[c]);return o.createElement(f,t({showLabel:o.createElement(H,t({size:"p3",color:z.colors.primaryBase},p),m("articlePage.readMore")),hideLabel:o.createElement(H,t({size:"p3",color:z.colors.primaryBase},p),m("articlePage.showLess"))},d,{maxHeight:u}),r)},an=P(g)(Y||(Y=r(["\n .mantine-Accordion-control {\n &:hover {\n background-color: transparent;\n }\n }\n .mantine-Accordion-item {\n .mantine-Accordion-chevron {\n > div {\n background-repeat: no-repeat;\n width: 16px;\n height: 16px;\n background-position: center;\n background-image: url(",");\n }\n }\n &[data-active='true'] {\n .mantine-Accordion-chevron {\n > div {\n background-image: url(",");\n }\n }\n }\n }\n .mantine-Accordion-panel {\n border-radius: 6px;\n }\n .mantine-Accordion-content {\n white-space: pre-wrap;\n }\n"],["\n .mantine-Accordion-control {\n &:hover {\n background-color: transparent;\n }\n }\n .mantine-Accordion-item {\n .mantine-Accordion-chevron {\n > div {\n background-repeat: no-repeat;\n width: 16px;\n height: 16px;\n background-position: center;\n background-image: url(",");\n }\n }\n &[data-active='true'] {\n .mantine-Accordion-chevron {\n > div {\n background-image: url(",");\n }\n }\n }\n }\n .mantine-Accordion-panel {\n border-radius: 6px;\n }\n .mantine-Accordion-content {\n white-space: pre-wrap;\n }\n"])),(function(n){return n.closeChevron||S.getAssetPath("plus-icon.svg")}),(function(n){return n.openChevron||S.getAssetPath("minus-icon.svg")})),ln=function(e){var r=e.children,i=n(e,["children"]);return o.createElement(an,t({chevron:o.createElement("div",null),disableChevronRotation:!0,transitionDuration:300},i),r)};ln.Control=g.Control,ln.Item=g.Item,ln.Panel=g.Panel;var cn=S.getAssetPath("avatar.jpg"),sn=function(e){var r=e.withIndicator,i=void 0!==r&&r,a=e.indicatorConfig,l=void 0===a?null:a,c=e.size,s=void 0===c?56:c,d=e.children,u=n(e,["withIndicator","indicatorConfig","size","children"]),p=function(){return o.createElement(v,t({size:s,radius:"xl"},u),d||o.createElement("img",{src:cn,width:s}))};return i?o.createElement(m,t({inline:!0,position:"bottom-end",offset:9},l,{styles:{indicator:{backgroundColor:o.isValidElement(l.label)&&"transparent"}}}),p()):p()},dn=function(n){return o.createElement(b,t({loaderProps:{color:z.colors.primaryBase}},n))},mn=function(e){var r=e.slidesToShow,i=void 0===r?1:r,a=e.children,l=n(e,["slidesToShow","children"]);return o.createElement(T,t({slideSize:String(Math.floor(1/i*100))+"%",containScroll:"trimSnaps"},l),a)};mn.Slide=T.Slide;var un=function(n){return o.createElement(x,t({},n))};un.Group=x.Group;var pn,hn,fn,gn="hhgcomp-mantine-slider-slider",vn=G(P(w)(pn||(pn=r(["\n .mantine-Slider-track {\n background-color: ",";\n }\n\n .mantine-Slider-label {\n background-color: transparent;\n color: #000;\n font-size: 14px;\n font-weight: bold;\n }\n"],["\n .mantine-Slider-track {\n background-color: ",";\n }\n\n .mantine-Slider-label {\n background-color: transparent;\n color: #000;\n font-size: 14px;\n font-weight: bold;\n }\n"])),(function(n){return n.color||n.theme.colors.primaryBase})),gn),bn=P.div(hn||(hn=r(["\n display: flex;\n align-items: center;\n ."," {\n flex-grow: 1;\n }\n"],["\n display: flex;\n align-items: center;\n ."," {\n flex-grow: 1;\n }\n"])),gn),xn=function(e){var r=e.color,i=void 0===r?z.colors.primaryBase:r,c=e.withControl,s=e.onChange,d=e.value,m=e.min,u=e.max,p=e.isStatic,h=n(e,["color","withControl","onChange","value","min","max","isStatic"]),f=a(d||m||0),g=f[0],v=f[1],b=W(g,R)[0];return l((function(){null==s||s(b)}),[b]),o.createElement(bn,null,c&&o.createElement(F,{type:"button",size:"sm",color:"ghost",onClick:function(){v((function(n){return m&&n===m?n:n-1}))}},o.createElement("svg",{width:"10",height:"10",fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 12 3"},o.createElement("path",{d:"M1 1.004h8",stroke:i,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}))),o.createElement(vn,t({thumbSize:21,labelAlwaysOn:!0,radius:"xl",color:i,value:g,onChange:p?function(){return null}:v,min:m,max:u},h)),c&&o.createElement(F,{type:"button",size:"sm",color:"ghost",onClick:function(){v((function(n){return u&&n===u?n:n+1}))}},o.createElement("svg",{width:"16",height:"20",fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},o.createElement("path",{d:"M8 4v8M4 8h8",stroke:i,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}))))},wn=P(k)(fn||(fn=r(["\n .mantine-Radio-icon {\n color: ",";\n }\n"],["\n .mantine-Radio-icon {\n color: ",";\n }\n"])),(function(n){return n.color||z.colors.primaryBase})),kn=function(n){return o.createElement(wn,t({size:"sm"},n))};kn.Group=k.Group;var yn,Cn,En=P(y)(yn||(yn=r(["\n .mantine-Switch-track {\n }\n"],["\n .mantine-Switch-track {\n }\n"]))),Sn=((Cn={})[B.Vietnam]="vi",Cn[B.Cambodia]="km",Cn[B.India]="hi",Cn[B.Indonesia]="id",Cn[B.Malaysia]="ms",Cn[B.Thailand]="th",Cn[B.Taiwan]="zh-tw",Cn[B.PhilippinesTagalog]="tl-ph",Cn[B.PhilippinesEnglish]="en",Cn[B.Myanmar]="my",Cn),jn=function(n){l((function(){Sn[n]&&require("dayjs/locale/".concat(Sn[n],".js"))}),[n])},An={"&:hover":{borderColor:"".concat(z.colors.blue200),boxShadow:"0 0 2px 2px ".concat(z.colors.blue200)}},Pn=function(n){return{datesLocale:Sn[n],dateFormat:D[n].dateFormat,fontFamily:n===B.Cambodia?"Battambang,":"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI',\n Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif",components:{InputWrapper:{styles:{label:{marginBottom:"0.5rem"}}},NumberInput:{defaultProps:{decimalSeparator:D[n].separator}},Input:{styles:{input:{borderRadius:"6px",transition:"all ".concat("100ms"," ease-in-out"),"&:hover, &:focus":{borderColor:"".concat(z.colors.blue200),boxShadow:"0 0 2px 2px ".concat(z.colors.blue200)}},rightSection:{pointerEvents:"none",cursor:"default"},invalid:{color:"#000"}}},Checkbox:{styles:{input:An}},Radio:{styles:{radio:t(t({backgroundColor:"#ffffff"},An),{"&:checked":{backgroundColor:"#ffffff"}})}}}}},Mn=function(e){var r=e.children,i=e.locale,a=n(e,["children","locale"]);return jn(i),o.createElement(E,t({theme:Pn(i)},a),r)};export{ln as Accordion,sn as Avatar,rn as Badge,mn as Carousel,un as Checkbox,K as DatePicker,Z as Indicator,dn as LoadingOverlay,Sn as MAPPED_LOCALE,Mn as MantineProvider,tn as Modal,kn as Radio,q as Select,xn as Slider,on as Spoiler,En as Switch,nn as TextArea,Pn as getMantineThemeOverride,jn as useMantineLocale};
|
package/build/lead/campaign.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FormEvent } from 'react';
|
|
2
|
-
export declare const LeadCampaign: ({ campaign, action, onSubmit, onClose, }: {
|
|
2
|
+
export declare const LeadCampaign: ({ campaign, action, onSubmit, onClose, showThankyou, }: {
|
|
3
3
|
campaign: any;
|
|
4
4
|
action?: string;
|
|
5
5
|
onSubmit?: (e: FormEvent<HTMLFormElement>, categoryLevel?: number, categoryData?: {
|
|
@@ -9,4 +9,14 @@ export declare const LeadCampaign: ({ campaign, action, onSubmit, onClose, }: {
|
|
|
9
9
|
};
|
|
10
10
|
}, popupId?: string) => void;
|
|
11
11
|
onClose?: () => void;
|
|
12
|
+
showThankyou?: {
|
|
13
|
+
title: string;
|
|
14
|
+
titleAlign?: string;
|
|
15
|
+
subtitle: string;
|
|
16
|
+
subtitleAlign?: string;
|
|
17
|
+
link: string;
|
|
18
|
+
linkNewTab?: boolean;
|
|
19
|
+
linkText: string;
|
|
20
|
+
image?: string;
|
|
21
|
+
};
|
|
12
22
|
}) => JSX.Element;
|
|
@@ -1,13 +1,25 @@
|
|
|
1
1
|
import { FormEvent } from 'react';
|
|
2
|
-
export declare const LightboxLayout: ({ popupId, extraFields, onClose, onOtherSubmit, imageMobile, imageDesktop, imageBackground, currentLayout, title, onSubmit, }: {
|
|
2
|
+
export declare const LightboxLayout: ({ popupId, extraFields, onClose, onOtherSubmit, imageMobile, imageDesktop, imageOverlayMobile, imageOverlayDesktop, imageBackground, currentLayout, title, onSubmit, showThankyou, }: {
|
|
3
3
|
popupId: string;
|
|
4
4
|
currentLayout: string;
|
|
5
5
|
extraFields: any;
|
|
6
6
|
title?: string;
|
|
7
7
|
imageMobile?: string;
|
|
8
8
|
imageDesktop?: string;
|
|
9
|
+
imageOverlayMobile?: string;
|
|
10
|
+
imageOverlayDesktop?: string;
|
|
9
11
|
imageBackground?: string;
|
|
10
12
|
onClose?: () => void;
|
|
11
13
|
onOtherSubmit?: () => void;
|
|
12
14
|
onSubmit?: (e: FormEvent<HTMLFormElement>) => void;
|
|
15
|
+
showThankyou?: {
|
|
16
|
+
title: string;
|
|
17
|
+
titleAlign?: string;
|
|
18
|
+
subtitle: string;
|
|
19
|
+
subtitleAlign?: string;
|
|
20
|
+
link: string;
|
|
21
|
+
linkNewTab?: boolean;
|
|
22
|
+
linkText: string;
|
|
23
|
+
image?: string;
|
|
24
|
+
};
|
|
13
25
|
}) => JSX.Element;
|