@hhgtech/hhg-components 1.29.335-beta-1 → 1.29.335
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/{LastPeriod-46e96dd6.js → LastPeriod-ba21f506.js} +1 -1
- package/build/{MobileBottomNavigationIcon-9ecd2e22.js → MobileBottomNavigationIcon-d2aed6f6.js} +3 -3
- package/build/{Spinner-7d3b9e67.js → Spinner-c0f6a1e9.js} +1 -1
- package/build/{WhatsApp-2676f310.js → WhatsApp-8f383a74.js} +1 -1
- package/build/adapters.js +19 -19
- package/build/atoms.js +46 -49
- package/build/babyGrowth.js +83 -83
- package/build/cache.js +2 -2
- package/build/care.js +17 -17
- package/build/careBookingSearchBar.js +14 -14
- package/build/careBookingSearchBarV2.js +15 -15
- package/build/components/adapters/button/index.d.ts +1 -3
- package/build/components/atoms/index.d.ts +0 -1
- package/build/components.js +131 -134
- package/build/{constants-458d96dd.js → constants-6953a0d4.js} +1 -1
- package/build/constants.js +3 -3
- package/build/constantsDomainLocales.js +1 -1
- package/build/constantsRiskScreener.js +2 -2
- package/build/constantsSite.js +2 -2
- package/build/{core-29eb007d.js → core-83da01a5.js} +1 -1
- package/build/{dataTransform-b3ce52d2.js → dataTransform-1cd76236.js} +1 -1
- package/build/ecom.js +4 -4
- package/build/{editor-36954549.js → editor-ba869a7d.js} +11 -11
- package/build/embeddedHeathToolCards_babyGrowth.js +23 -23
- package/build/embeddedHeathToolCards_babyPoop.js +19 -19
- package/build/embeddedHeathToolCards_babyVaccine.js +22 -22
- package/build/embeddedHeathToolCards_bmi_bmi.js +25 -25
- package/build/embeddedHeathToolCards_bmrBmr.js +25 -25
- package/build/embeddedHeathToolCards_dueDate_dueDate.js +22 -22
- package/build/embeddedHeathToolCards_ovulation_ovulation.js +22 -22
- package/build/embeddedHeathToolCards_pwg_pwg.js +26 -26
- package/build/embeddedHeathToolCards_targetHeartRate.js +27 -27
- package/build/esm/{LastPeriod-141f040c.js → LastPeriod-ee84b089.js} +1 -1
- package/build/esm/{MobileBottomNavigationIcon-9d4bb215.js → MobileBottomNavigationIcon-b67e6ed0.js} +3 -3
- package/build/esm/{Spinner-59a5bfaf.js → Spinner-0f69be3b.js} +1 -1
- package/build/esm/{WhatsApp-26485356.js → WhatsApp-18fce68c.js} +1 -1
- package/build/esm/adapters.js +19 -19
- package/build/esm/atoms.js +46 -48
- package/build/esm/babyGrowth.js +83 -83
- package/build/esm/cache.js +2 -2
- package/build/esm/care.js +17 -17
- package/build/esm/careBookingSearchBar.js +14 -14
- package/build/esm/careBookingSearchBarV2.js +15 -15
- package/build/esm/components/adapters/button/index.d.ts +1 -3
- package/build/esm/components/atoms/index.d.ts +0 -1
- package/build/esm/components.js +90 -92
- package/build/esm/{constants-70dd8224.js → constants-8d65289f.js} +1 -1
- package/build/esm/constants.js +3 -3
- package/build/esm/constantsDomainLocales.js +1 -1
- package/build/esm/constantsRiskScreener.js +2 -2
- package/build/esm/constantsSite.js +2 -2
- package/build/esm/{core-b123de98.js → core-f0937be9.js} +1 -1
- package/build/esm/{dataTransform-e88e0ee7.js → dataTransform-73e35955.js} +1 -1
- package/build/esm/ecom.js +4 -4
- package/build/esm/{editor-16d60bbc.js → editor-2c7334e2.js} +11 -11
- package/build/esm/embeddedHeathToolCards_babyGrowth.js +23 -23
- package/build/esm/embeddedHeathToolCards_babyPoop.js +19 -19
- package/build/esm/embeddedHeathToolCards_babyVaccine.js +22 -22
- package/build/esm/embeddedHeathToolCards_bmi_bmi.js +25 -25
- package/build/esm/embeddedHeathToolCards_bmrBmr.js +25 -25
- package/build/esm/embeddedHeathToolCards_dueDate_dueDate.js +22 -22
- package/build/esm/embeddedHeathToolCards_ovulation_ovulation.js +22 -22
- package/build/esm/embeddedHeathToolCards_pwg_pwg.js +26 -26
- package/build/esm/embeddedHeathToolCards_targetHeartRate.js +27 -27
- package/build/esm/footer.js +21 -21
- package/build/esm/gAssets.js +2 -2
- package/build/esm/healthToolsCardWrapper.js +18 -18
- package/build/esm/healthToolsForm.js +33 -33
- package/build/esm/hooks/usePlacesAutocomplete.d.ts +0 -2
- package/build/esm/hooks.js +13 -13
- package/build/esm/i18n.js +2 -2
- package/build/esm/i18nV2.js +2 -2
- package/build/esm/icons/index.d.ts +3 -5
- package/build/esm/{index-14400976.js → index-049d753a.js} +17 -17
- package/build/esm/{index-0eb6554f.js → index-0f1ee266.js} +7 -7
- package/build/esm/{index-7894bd17.js → index-111b7c08.js} +30 -30
- package/build/esm/{index-43e0be3f.js → index-125298cb.js} +3 -3
- package/build/esm/{index-d68cb591.js → index-1281be34.js} +24 -24
- package/build/esm/{index-6eda197c.js → index-17241889.js} +15 -15
- package/build/esm/{index-7414a9c7.js → index-172694d6.js} +13 -13
- package/build/esm/{index-cc9bf4ac.js → index-17a1b3f9.js} +16 -16
- package/build/esm/{index-231d81e5.js → index-1d2ba1db.js} +13 -13
- package/build/esm/{index-f2e0892c.js → index-213d2266.js} +1 -1
- package/build/esm/{index-2cdeaac9.js → index-2623cd75.js} +16 -16
- package/build/esm/{index-a976b896.js → index-272d977d.js} +2 -2
- package/build/esm/{index-98593eae.js → index-300712d7.js} +6 -6
- package/build/esm/{index-5b81f72d.js → index-3f4fc48d.js} +1 -1
- package/build/esm/{index-d1f5b625.js → index-3f7921e6.js} +2 -2
- package/build/esm/{index-e4065b61.js → index-4295cda1.js} +18 -18
- package/build/esm/{index-f0bb9ac3.js → index-4361942b.js} +1 -3
- package/build/esm/{index-23444f0c.js → index-4aad6743.js} +17 -17
- package/build/esm/{index-047a6277.js → index-4dd95bae.js} +5 -5
- package/build/esm/{index-9b1fd51e.js → index-4e0c5b66.js} +2 -2
- package/build/esm/{index-7d3edfbf.js → index-51443985.js} +1 -1
- package/build/esm/{index-23a3f63b.js → index-666d1195.js} +10 -10
- package/build/esm/{index-2143d7ea.js → index-6f5ce9e6.js} +16 -16
- package/build/esm/{index-5aa22a6e.js → index-731ec22a.js} +32 -32
- package/build/esm/{index-c95625bb.js → index-7d1292b2.js} +7 -7
- package/build/esm/{index-e2d5abc2.js → index-7d7cd80e.js} +3 -3
- package/build/esm/{index-fcd58ffe.js → index-819eec4d.js} +2 -2
- package/build/esm/{index-e8e0b300.js → index-8279d3d1.js} +13 -13
- package/build/esm/{index-f45875f8.js → index-86f46388.js} +2 -2
- package/build/esm/{index-4bccc123.js → index-88fb7021.js} +15 -15
- package/build/esm/{index-ff9ca6f3.js → index-89ab1f4d.js} +2 -2
- package/build/esm/{index-a1079018.js → index-89cc4741.js} +2 -2
- package/build/esm/{index-6e7a5f37.js → index-89facfc8.js} +2 -2
- package/build/esm/{index-14d5aabc.js → index-8cbc49a3.js} +3 -3
- package/build/esm/{index-f8148161.js → index-8d201d73.js} +1 -1
- package/build/esm/{index-2c53b2e0.js → index-906ceed9.js} +1 -1
- package/build/esm/{index-259410e7.js → index-927ce549.js} +2 -2
- package/build/esm/{index-f0d7dd50.js → index-9d05cfd1.js} +3 -3
- package/build/esm/{index-96100685.js → index-a3a89865.js} +3 -3
- package/build/esm/{index-4362f220.js → index-a8c09ebf.js} +1 -1
- package/build/esm/{index-35352bc4.js → index-a97e63b7.js} +2 -2
- package/build/esm/{index-ea66843b.js → index-a982ec16.js} +2 -2
- package/build/esm/{index-86053fce.js → index-aa51be62.js} +31 -31
- package/build/esm/{index-fec5188f.js → index-af6832bb.js} +6 -6
- package/build/esm/{index-99f4a579.js → index-b1881c11.js} +4 -4
- package/build/esm/{index-80112067.js → index-b7671a59.js} +20 -20
- package/build/esm/{index-891ece79.js → index-c1245374.js} +3 -3
- package/build/esm/{index-3f925719.js → index-c461e5a4.js} +1 -1
- package/build/esm/{index-7fb3b538.js → index-ca53f881.js} +3 -3
- package/build/esm/{index-8b8571bc.js → index-d7daa35d.js} +16 -16
- package/build/esm/{index-3b854861.js → index-d811e755.js} +18 -18
- package/build/esm/{index-15938e1a.js → index-e400c387.js} +6 -6
- package/build/esm/{index-97964a08.js → index-e7ba79e1.js} +14 -14
- package/build/esm/{index-616b5b25.js → index-e80c6cb4.js} +18 -18
- package/build/esm/{index-7d103034.js → index-ec851f36.js} +24 -24
- package/build/esm/{index-6e75c651.js → index-ed9ee946.js} +6 -6
- package/build/esm/{index-f71c0218.js → index-f2452c57.js} +2 -2
- package/build/esm/{index-ec51425b.js → index-f3859b54.js} +1 -1
- package/build/esm/{index-567d6542.js → index-f967107c.js} +21 -21
- package/build/esm/{index-f56128bf.js → index-fb220371.js} +5 -5
- package/build/esm/{index-5fe1a3fd.js → index-fc84dde4.js} +13 -13
- package/build/esm/index.css +1 -1
- package/build/esm/index.js +117 -146
- package/build/esm/interfaces/types/Subot.d.ts +0 -1
- package/build/esm/{labelSorting-c5ee7f2b.js → labelSorting-d70be32f.js} +4 -4
- package/build/esm/lead/components/context.d.ts +0 -2
- package/build/esm/lead/components/index.d.ts +2 -4
- package/build/esm/lead/index.d.ts +1 -1
- package/build/esm/lead/layouts/lightbox/index.d.ts +2 -4
- package/build/esm/lead/newLeadPopup.d.ts +2 -4
- package/build/esm/lead.css +1 -1
- package/build/esm/lead.js +351 -772
- package/build/esm/{logoIcon-5a154eb9.js → logoIcon-af3e5a17.js} +2 -2
- package/build/esm/mantine.js +25 -25
- package/build/esm/misc.js +16 -16
- package/build/esm/miscGetDynamicHealthTool.js +4 -4
- package/build/esm/miscGetSocialList.js +8 -8
- package/build/esm/miscScreenSizeContext.js +1 -1
- package/build/esm/mobileBottomNavigation.js +5 -5
- package/build/esm/mobileBottomNavigationIcon.js +5 -5
- package/build/esm/molecules.js +69 -69
- package/build/esm/moleculesArticleCard.js +6 -6
- package/build/esm/moleculesArticleCardV2.js +16 -16
- package/build/esm/navigation.js +40 -40
- package/build/esm/navigationLogoutPopup.js +9 -9
- package/build/esm/navigationProfileButton.js +23 -23
- package/build/esm/onboardingV2.js +29 -29
- package/build/esm/organisms.js +44 -44
- package/build/esm/{post-ee36ab85.js → post-3a1a66b8.js} +2 -2
- package/build/esm/profileNavigation.js +19 -19
- package/build/esm/progressBar.js +1 -1
- package/build/esm/pwg.js +22 -22
- package/build/esm/ssoV2.js +26 -26
- package/build/esm/{store-e3296a0f.js → store-19b28367.js} +4 -4
- package/build/esm/subot.js +39 -123
- package/build/esm/surveyOrPremiumBanner.js +31 -31
- package/build/esm/surveyQuestionCard.js +10 -10
- package/build/esm/{surveyThankyouCard-caeb59ce.js → surveyThankyouCard-ebc6b1be.js} +5 -5
- package/build/esm/together.js +53 -53
- package/build/esm/togetherApiUtils.js +4 -4
- package/build/esm/togetherAtoms.js +30 -30
- package/build/esm/togetherComponentGlobalContext.js +4 -4
- package/build/esm/togetherMolecules.js +48 -48
- package/build/esm/togetherMoleculesCardAuthor.js +27 -27
- package/build/esm/togetherMoleculesPostImagePreview.js +11 -11
- package/build/esm/togetherMoleculesProfileDetail.js +37 -37
- package/build/esm/togetherOrganisms.js +47 -47
- package/build/esm/togetherRichTextEditor.js +17 -17
- package/build/esm/togetherShareBox.js +10 -10
- package/build/esm/{treePopoverMenu-d40c9694.js → treePopoverMenu-4bceadef.js} +19 -19
- package/build/esm/{types-c66801fe.js → types-aa1c411e.js} +2 -2
- package/build/esm/types.js +2 -2
- package/build/esm/{useCategory-94066620.js → useCategory-acc2c1e8.js} +5 -5
- package/build/esm/{useHealthToolCache-fa338d83.js → useHealthToolCache-c2684203.js} +1 -1
- package/build/esm/{useMantineLocale-152fcbe4.js → useMantineLocale-6de622f7.js} +6 -6
- package/build/esm/{usePlacesAutocomplete-d301e4f0.js → usePlacesAutocomplete-1606467b.js} +1 -2
- package/build/esm/{useScreenSize-e1918ff7.js → useScreenSize-828d9bce.js} +2 -2
- package/build/esm/useTogetherAuthRequiredAction.js +9 -9
- package/build/esm/{utils-45fbf72d.js → utils-503eac0d.js} +2 -2
- package/build/esm/{utils-aab0fc52.js → utils-e3692227.js} +2 -2
- package/build/esm/{utils-f4b796ca.js → utils-f7442d3f.js} +3 -3
- package/build/esm/vaccination.js +21 -21
- package/build/footer.js +21 -21
- package/build/gAssets.js +2 -2
- package/build/healthToolsCardWrapper.js +18 -18
- package/build/healthToolsForm.js +33 -33
- package/build/hooks/usePlacesAutocomplete.d.ts +0 -2
- package/build/hooks.js +13 -13
- package/build/i18n.js +1 -1
- package/build/i18nV2.js +1 -1
- package/build/icons/index.d.ts +3 -5
- package/build/{index-aa242b44.js → index-013f2ca1.js} +16 -16
- package/build/{index-c3daf737.js → index-022c6360.js} +1 -1
- package/build/{index-94f6d394.js → index-02a064cf.js} +14 -14
- package/build/{index-34b76f52.js → index-0372231c.js} +16 -16
- package/build/{index-cf6e110f.js → index-06277ff9.js} +6 -6
- package/build/{index-a49a6847.js → index-06986d0f.js} +13 -13
- package/build/{index-f93511e8.js → index-087fe95e.js} +17 -17
- package/build/{index-ce1d5fb9.js → index-0996c8af.js} +2 -2
- package/build/{index-bd9bcd47.js → index-099c0ae2.js} +3 -3
- package/build/{index-80b33602.js → index-0aaa493e.js} +30 -30
- package/build/{index-81d9f786.js → index-0b35135a.js} +6 -6
- package/build/{index-06f21d69.js → index-10565ae1.js} +1 -1
- package/build/{index-f48c64cf.js → index-212ff8bf.js} +6 -6
- package/build/{index-21e7419a.js → index-21df7f49.js} +17 -17
- package/build/{index-685e00fa.js → index-2676d693.js} +21 -21
- package/build/{index-c54eb923.js → index-2f13a23d.js} +2 -2
- package/build/{index-62907ebf.js → index-302b87c5.js} +5 -5
- package/build/{index-9d96310d.js → index-308067f0.js} +1 -1
- package/build/{index-dd47ed56.js → index-3c5fcd67.js} +3 -3
- package/build/{index-8b3a4dcb.js → index-41532440.js} +1 -3
- package/build/{index-380604fc.js → index-4481d3d7.js} +2 -2
- package/build/{index-bd79efdb.js → index-464aaa65.js} +31 -31
- package/build/{index-0865f8b3.js → index-479c9ed1.js} +2 -2
- package/build/{index-440615b6.js → index-48da8df2.js} +15 -15
- package/build/{index-3b3e5d0a.js → index-4cf53090.js} +1 -1
- package/build/{index-44d2b01c.js → index-60182dd9.js} +13 -13
- package/build/{index-a357695a.js → index-62a78cec.js} +24 -24
- package/build/{index-57086cdc.js → index-676f3c4f.js} +3 -3
- package/build/{index-bcafb201.js → index-6a356df5.js} +3 -3
- package/build/{index-45e49461.js → index-70aef25b.js} +5 -5
- package/build/{index-31377875.js → index-76a4c58d.js} +18 -18
- package/build/{index-a7bd3e53.js → index-7a73c148.js} +2 -2
- package/build/{index-7250c3f2.js → index-8028db52.js} +2 -2
- package/build/{index-3f65a73d.js → index-9dfbb72e.js} +3 -3
- package/build/{index-ca0a418f.js → index-9f2cd267.js} +7 -7
- package/build/{index-31857d74.js → index-9fb2ae0a.js} +1 -1
- package/build/{index-73b791ff.js → index-a0bda1e0.js} +3 -3
- package/build/{index-f93c8ffe.js → index-a57421a5.js} +16 -16
- package/build/{index-6a047ad3.js → index-a5e2cc3f.js} +2 -2
- package/build/{index-bfc6b53f.js → index-a6bce961.js} +2 -2
- package/build/{index-2b2513b5.js → index-af3aa7aa.js} +6 -6
- package/build/{index-20ce6f81.js → index-b4bf4074.js} +1 -1
- package/build/{index-2ff0bdae.js → index-bc79ffd9.js} +2 -2
- package/build/{index-31cf80ca.js → index-c190b54f.js} +3 -3
- package/build/{index-5a92da15.js → index-c6aa41c1.js} +18 -18
- package/build/{index-a71f79a3.js → index-c6bef368.js} +24 -24
- package/build/{index-9e321f90.js → index-c8f6c1a9.js} +13 -13
- package/build/{index-02b4de22.js → index-cc8bf5c9.js} +20 -20
- package/build/{index-c84f1a88.js → index-d03e8b2d.js} +13 -13
- package/build/{index-7e9de344.js → index-dc7c2c4d.js} +32 -32
- package/build/{index-29a5b335.js → index-dd014ba3.js} +7 -7
- package/build/{index-fe3154a0.js → index-e0095c5b.js} +2 -2
- package/build/{index-1e31f755.js → index-e084b2c5.js} +2 -2
- package/build/{index-13b2d3bf.js → index-e58154c7.js} +2 -2
- package/build/{index-d5c7a02e.js → index-e8870a3c.js} +1 -1
- package/build/{index-1dbc7435.js → index-ea37733b.js} +10 -10
- package/build/{index-4b4fb8b3.js → index-ed758ff7.js} +15 -15
- package/build/{index-c462decb.js → index-ee982cce.js} +18 -18
- package/build/{index-55f792d3.js → index-f2ec6279.js} +16 -16
- package/build/{index-a9fa3f81.js → index-f9dc1022.js} +4 -4
- package/build/{index-91558337.js → index-ff744f5d.js} +1 -1
- package/build/index.css +1 -1
- package/build/index.js +179 -211
- package/build/interfaces/types/Subot.d.ts +0 -1
- package/build/{labelSorting-b3f94544.js → labelSorting-ced18dfa.js} +4 -4
- package/build/lead/components/context.d.ts +0 -2
- package/build/lead/components/index.d.ts +2 -4
- package/build/lead/index.d.ts +1 -1
- package/build/lead/layouts/lightbox/index.d.ts +2 -4
- package/build/lead/newLeadPopup.d.ts +2 -4
- package/build/lead.css +1 -1
- package/build/lead.js +350 -772
- package/build/{logoIcon-1558651c.js → logoIcon-7bb432ca.js} +2 -2
- package/build/mantine.js +22 -22
- package/build/misc.js +16 -16
- package/build/miscGetDynamicHealthTool.js +4 -4
- package/build/miscGetSocialList.js +8 -8
- package/build/miscScreenSizeContext.js +1 -1
- package/build/mobileBottomNavigation.js +5 -5
- package/build/mobileBottomNavigationIcon.js +5 -5
- package/build/molecules.js +69 -69
- package/build/moleculesArticleCard.js +6 -6
- package/build/moleculesArticleCardV2.js +16 -16
- package/build/navigation.js +40 -40
- package/build/navigationLogoutPopup.js +9 -9
- package/build/navigationProfileButton.js +23 -23
- package/build/onboardingV2.js +28 -28
- package/build/organisms.js +44 -44
- package/build/{post-d2e7ce8d.js → post-b27e59c0.js} +2 -2
- package/build/profileNavigation.js +19 -19
- package/build/progressBar.js +1 -1
- package/build/pwg.js +22 -22
- package/build/ssoV2.js +25 -25
- package/build/{store-05a60cf0.js → store-6298e376.js} +4 -4
- package/build/subot.js +41 -126
- package/build/surveyOrPremiumBanner.js +31 -31
- package/build/surveyQuestionCard.js +10 -10
- package/build/{surveyThankyouCard-79837fe8.js → surveyThankyouCard-bad691e9.js} +5 -5
- package/build/together.js +53 -53
- package/build/togetherApiUtils.js +4 -4
- package/build/togetherAtoms.js +30 -30
- package/build/togetherComponentGlobalContext.js +4 -4
- package/build/togetherMolecules.js +48 -48
- package/build/togetherMoleculesCardAuthor.js +27 -27
- package/build/togetherMoleculesPostImagePreview.js +11 -11
- package/build/togetherMoleculesProfileDetail.js +37 -37
- package/build/togetherOrganisms.js +47 -47
- package/build/togetherRichTextEditor.js +17 -17
- package/build/togetherShareBox.js +10 -10
- package/build/{treePopoverMenu-c5233a82.js → treePopoverMenu-044c32a4.js} +19 -19
- package/build/{types-11b52584.js → types-dce83d8b.js} +2 -2
- package/build/types.js +2 -2
- package/build/{useCategory-d46c8900.js → useCategory-ecc66204.js} +5 -5
- package/build/{useHealthToolCache-75feb4d4.js → useHealthToolCache-c45bbd67.js} +1 -1
- package/build/{useMantineLocale-135701f5.js → useMantineLocale-d11812c5.js} +6 -6
- package/build/{usePlacesAutocomplete-d0e1d9e4.js → usePlacesAutocomplete-2bc75236.js} +1 -2
- package/build/{useScreenSize-4591c969.js → useScreenSize-83ac08f1.js} +2 -2
- package/build/useTogetherAuthRequiredAction.js +9 -9
- package/build/{utils-eddc9ee2.js → utils-0cbba059.js} +3 -3
- package/build/{utils-0be8267b.js → utils-36234b1a.js} +2 -2
- package/build/{utils-eab0eaa0.js → utils-92cd1e7a.js} +2 -2
- package/build/vaccination.js +21 -21
- package/package.json +1 -1
- package/build/components/atoms/drawerComponent/index.d.ts +0 -8
- package/build/components/atoms/drawerComponent/index.styled.d.ts +0 -7
- package/build/components/atoms/googleLocation/index.d.ts +0 -7
- package/build/esm/components/atoms/drawerComponent/index.d.ts +0 -8
- package/build/esm/components/atoms/drawerComponent/index.styled.d.ts +0 -7
- package/build/esm/components/atoms/googleLocation/index.d.ts +0 -7
- package/build/esm/icons/ChatbotBg.d.ts +0 -4
- package/build/esm/icons/Search.d.ts +0 -4
- package/build/esm/index-2df875c9.js +0 -106
- package/build/esm/lead/layouts/ emptyIcon.d.ts +0 -6
- package/build/esm/lead/layouts/lightbox/fields/textField/index.d.ts +0 -13
- package/build/esm/lead/layouts/lightbox/fields/textField/index.styled.d.ts +0 -11
- package/build/esm/subot/components/dob/index.d.ts +0 -4
- package/build/esm/subot/components/dob/utils.d.ts +0 -10
- package/build/icons/ChatbotBg.d.ts +0 -4
- package/build/icons/Search.d.ts +0 -4
- package/build/index-b5b04cde.js +0 -113
- package/build/lead/layouts/ emptyIcon.d.ts +0 -6
- package/build/lead/layouts/lightbox/fields/textField/index.d.ts +0 -13
- package/build/lead/layouts/lightbox/fields/textField/index.styled.d.ts +0 -11
- package/build/subot/components/dob/index.d.ts +0 -4
- package/build/subot/components/dob/utils.d.ts +0 -10
- /package/build/{BMI_BOYS.percentile.monthly-52c93b82.js → BMI_BOYS.percentile.monthly-fae500f2.js} +0 -0
- /package/build/{BMI_BOYS.percentile.weekly-ea488fef.js → BMI_BOYS.percentile.weekly-aa294985.js} +0 -0
- /package/build/{BMI_BOYS.percentile.yearly-023101aa.js → BMI_BOYS.percentile.yearly-9e6fd6dd.js} +0 -0
- /package/build/{BMI_BOYS.zscore.monthly-a3dd3503.js → BMI_BOYS.zscore.monthly-9ea48c8c.js} +0 -0
- /package/build/{BMI_BOYS.zscore.weekly-4fbe45bc.js → BMI_BOYS.zscore.weekly-2773fa61.js} +0 -0
- /package/build/{BMI_BOYS.zscore.yearly-7b769276.js → BMI_BOYS.zscore.yearly-b03827e7.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.monthly-5131145f.js → BMI_GIRLS.percentile.monthly-1fa58953.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.weekly-fd4eff22.js → BMI_GIRLS.percentile.weekly-db5dbfd4.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.yearly-cc7e1d92.js → BMI_GIRLS.percentile.yearly-e4ef6fce.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.monthly-9830f357.js → BMI_GIRLS.zscore.monthly-f1fe0427.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.weekly-0ca1a177.js → BMI_GIRLS.zscore.weekly-efce6fb2.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.yearly-617d6a5f.js → BMI_GIRLS.zscore.yearly-bc41ceb0.js} +0 -0
- /package/build/{ChevronDown-217240d0.js → ChevronDown-471c8091.js} +0 -0
- /package/build/{Close-edb48b46.js → Close-8bde9c2f.js} +0 -0
- /package/build/{Google-0f0834a8.js → Google-ac0354ae.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.monthly-954c1abe.js → HEAD CIRCUM_BOYS.percentile.monthly-cd991624.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.weekly-e4f36505.js → HEAD CIRCUM_BOYS.percentile.weekly-4a0c6bdd.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.yearly-37679bf9.js → HEAD CIRCUM_BOYS.percentile.yearly-e3d2bbc5.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.monthly-6cccd8bc.js → HEAD CIRCUM_BOYS.zscore.monthly-4e342021.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.weekly-b96bd2b2.js → HEAD CIRCUM_BOYS.zscore.weekly-9a54efae.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.yearly-b1050fa7.js → HEAD CIRCUM_BOYS.zscore.yearly-c14bee9a.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.monthly-b88ab7f2.js → HEAD CIRCUM_GIRLS.percentile.monthly-618e95ff.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.weekly-b20bb0af.js → HEAD CIRCUM_GIRLS.percentile.weekly-a7c4912f.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.yearly-291b478b.js → HEAD CIRCUM_GIRLS.percentile.yearly-6053a9c8.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.monthly-82c93f84.js → HEAD CIRCUM_GIRLS.zscore.monthly-04b6e597.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.weekly-dd6a552b.js → HEAD CIRCUM_GIRLS.zscore.weekly-37e66837.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.yearly-1269e2c4.js → HEAD CIRCUM_GIRLS.zscore.yearly-2b53756c.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.monthly-37451103.js → HEIGHT_BOYS.percentile.monthly-f3ff755f.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.weekly-057e301c.js → HEIGHT_BOYS.percentile.weekly-65d1525c.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.yearly-921c7600.js → HEIGHT_BOYS.percentile.yearly-46882afc.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.monthly-e2d2fc0a.js → HEIGHT_BOYS.zscore.monthly-d440d178.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.weekly-a6f655cd.js → HEIGHT_BOYS.zscore.weekly-aac82089.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.yearly-91954b46.js → HEIGHT_BOYS.zscore.yearly-3556ce35.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.monthly-d40f2442.js → HEIGHT_GIRLS.percentile.monthly-f0337f1a.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.weekly-48a48c7f.js → HEIGHT_GIRLS.percentile.weekly-c4cde187.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.yearly-a39f517e.js → HEIGHT_GIRLS.percentile.yearly-7c79eae1.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.monthly-eaad21f1.js → HEIGHT_GIRLS.zscore.monthly-6ad5d453.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.weekly-b4f7ad33.js → HEIGHT_GIRLS.zscore.weekly-93ee746c.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.yearly-22aab32e.js → HEIGHT_GIRLS.zscore.yearly-7ddba194.js} +0 -0
- /package/build/{Locale-8aac3225.js → Locale-a81611df.js} +0 -0
- /package/build/{Visible-4045c980.js → Visible-68270fc7.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.monthly-8d78f6ac.js → WEIGHT_BOYS.percentile.monthly-a006d6ff.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.weekly-553745cd.js → WEIGHT_BOYS.percentile.weekly-aac8cda0.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.yearly-7a7a987b.js → WEIGHT_BOYS.percentile.yearly-f2f9e9cb.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.monthly-16551ea1.js → WEIGHT_BOYS.zscore.monthly-4191e485.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.weekly-51a6e021.js → WEIGHT_BOYS.zscore.weekly-7f6f5748.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.yearly-4f31ee0d.js → WEIGHT_BOYS.zscore.yearly-e09a0ab2.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.monthly-2cf7d585.js → WEIGHT_GIRLS.percentile.monthly-25d6847f.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.weekly-62f277bd.js → WEIGHT_GIRLS.percentile.weekly-46dfa66e.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.yearly-d0d8bfcf.js → WEIGHT_GIRLS.percentile.yearly-3fb26336.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.monthly-d9514529.js → WEIGHT_GIRLS.zscore.monthly-786b74ad.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.weekly-451c310d.js → WEIGHT_GIRLS.zscore.weekly-d733f4de.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.yearly-a36edf50.js → WEIGHT_GIRLS.zscore.yearly-de583439.js} +0 -0
- /package/build/{animation-a7a6abb4.js → animation-f1553def.js} +0 -0
- /package/build/{constants-a6434266.js → constants-84f38be5.js} +0 -0
- /package/build/{constants-a29847e9.js → constants-90166342.js} +0 -0
- /package/build/{constants-11c15798.js → constants-cce2f8f6.js} +0 -0
- /package/build/{dataTransform-adb2a8ec.js → dataTransform-56a33f97.js} +0 -0
- /package/build/{doctor-3059722a.js → doctor-58bbeecf.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.monthly-895095e8.js → BMI_BOYS.percentile.monthly-be455c2d.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.weekly-a88b6ba5.js → BMI_BOYS.percentile.weekly-9f32de31.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.yearly-e2a95cfe.js → BMI_BOYS.percentile.yearly-0c2407b1.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.monthly-22c250ef.js → BMI_BOYS.zscore.monthly-de4f9a75.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.weekly-498cb7d6.js → BMI_BOYS.zscore.weekly-998396ea.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.yearly-c3df88f3.js → BMI_BOYS.zscore.yearly-b17c74c7.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.monthly-5adc3dac.js → BMI_GIRLS.percentile.monthly-32120032.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.weekly-817f7204.js → BMI_GIRLS.percentile.weekly-56175adb.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.yearly-5e017a16.js → BMI_GIRLS.percentile.yearly-a1694c1f.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.monthly-3f00b16a.js → BMI_GIRLS.zscore.monthly-ae560ee7.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.weekly-b1e7cb12.js → BMI_GIRLS.zscore.weekly-3a584bd7.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.yearly-5ce36c77.js → BMI_GIRLS.zscore.yearly-e8c0813e.js} +0 -0
- /package/build/esm/{ChevronDown-45267371.js → ChevronDown-3b278da4.js} +0 -0
- /package/build/esm/{Close-dc1e0f37.js → Close-edd9e39c.js} +0 -0
- /package/build/esm/{Google-d7e555bd.js → Google-9062c4ef.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.monthly-1d8ade72.js → HEAD CIRCUM_BOYS.percentile.monthly-9f74b8db.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.weekly-09d2c7e2.js → HEAD CIRCUM_BOYS.percentile.weekly-bbf5d9bd.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.yearly-383a8582.js → HEAD CIRCUM_BOYS.percentile.yearly-3bb65eb3.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.monthly-fdeeed17.js → HEAD CIRCUM_BOYS.zscore.monthly-02470123.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.weekly-e4450537.js → HEAD CIRCUM_BOYS.zscore.weekly-ef655b55.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.yearly-2e2010d1.js → HEAD CIRCUM_BOYS.zscore.yearly-d7612c74.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.monthly-a2d90da8.js → HEAD CIRCUM_GIRLS.percentile.monthly-d3fa4f82.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.weekly-d71211ba.js → HEAD CIRCUM_GIRLS.percentile.weekly-4722c8b8.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.yearly-d128deae.js → HEAD CIRCUM_GIRLS.percentile.yearly-b1beb914.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.monthly-843c78de.js → HEAD CIRCUM_GIRLS.zscore.monthly-533cdaf4.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.weekly-e7d7aec4.js → HEAD CIRCUM_GIRLS.zscore.weekly-f6445517.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.yearly-20fbffcc.js → HEAD CIRCUM_GIRLS.zscore.yearly-cb87284f.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.monthly-b16d801d.js → HEIGHT_BOYS.percentile.monthly-3dc695a6.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.weekly-6338aa21.js → HEIGHT_BOYS.percentile.weekly-84cc031e.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.yearly-292c7999.js → HEIGHT_BOYS.percentile.yearly-0ad15042.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.monthly-441f3bff.js → HEIGHT_BOYS.zscore.monthly-c601565b.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.weekly-c4b3e5b6.js → HEIGHT_BOYS.zscore.weekly-27d3a326.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.yearly-228a8df3.js → HEIGHT_BOYS.zscore.yearly-ef7bc92e.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.monthly-27ea3fcd.js → HEIGHT_GIRLS.percentile.monthly-9154540f.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.weekly-cfeaf087.js → HEIGHT_GIRLS.percentile.weekly-9d54d800.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.yearly-c49f7492.js → HEIGHT_GIRLS.percentile.yearly-211964e6.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.monthly-2634f9f3.js → HEIGHT_GIRLS.zscore.monthly-dd943f5f.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.weekly-f383b17d.js → HEIGHT_GIRLS.zscore.weekly-23630973.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.yearly-0923f3ae.js → HEIGHT_GIRLS.zscore.yearly-b095f267.js} +0 -0
- /package/build/esm/{Locale-7f7d0b5d.js → Locale-9a8d7014.js} +0 -0
- /package/build/esm/{Visible-a58db64e.js → Visible-60317e10.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.monthly-0b32e2a6.js → WEIGHT_BOYS.percentile.monthly-2bde8464.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.weekly-1ece4dac.js → WEIGHT_BOYS.percentile.weekly-220d5cc3.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.yearly-0093dc36.js → WEIGHT_BOYS.percentile.yearly-391d087c.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.monthly-0932ff0a.js → WEIGHT_BOYS.zscore.monthly-de496448.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.weekly-31082401.js → WEIGHT_BOYS.zscore.weekly-0adb09ed.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.yearly-e06ca15e.js → WEIGHT_BOYS.zscore.yearly-d20b78d8.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.monthly-2692d638.js → WEIGHT_GIRLS.percentile.monthly-def0dfc9.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.weekly-6c043f6d.js → WEIGHT_GIRLS.percentile.weekly-b9b14f32.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.yearly-df4dac6d.js → WEIGHT_GIRLS.percentile.yearly-1ea01f1b.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.monthly-ce881c09.js → WEIGHT_GIRLS.zscore.monthly-29892d73.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.weekly-2daf0045.js → WEIGHT_GIRLS.zscore.weekly-4e72a42f.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.yearly-aec39ebb.js → WEIGHT_GIRLS.zscore.yearly-22b3e590.js} +0 -0
- /package/build/esm/{animation-e114c5d1.js → animation-a169fce5.js} +0 -0
- /package/build/esm/{constants-846c62e1.js → constants-10597147.js} +0 -0
- /package/build/esm/{constants-3a65efb3.js → constants-1b936c16.js} +0 -0
- /package/build/esm/{constants-f1af4c3e.js → constants-7efac097.js} +0 -0
- /package/build/esm/{dataTransform-712aeba0.js → dataTransform-93cd11dd.js} +0 -0
- /package/build/esm/{doctor-1b0a9f09.js → doctor-453fdde1.js} +0 -0
- /package/build/esm/{index-b5cd32f5.js → index-09345edf.js} +0 -0
- /package/build/esm/{index-02a03409.js → index-513a4e56.js} +0 -0
- /package/build/esm/{index-24836b56.js → index-6df8fc35.js} +0 -0
- /package/build/esm/{index-472147f2.js → index-8103381b.js} +0 -0
- /package/build/esm/{index-aeaf1d7b.js → index-83c5ea9d.js} +0 -0
- /package/build/esm/{index-21bf11f9.js → index-871b0215.js} +0 -0
- /package/build/esm/{index-a3a593c2.js → index-94f00abc.js} +0 -0
- /package/build/esm/{index-22bf596e.js → index-98592aa9.js} +0 -0
- /package/build/esm/{index-1912ad4d.js → index-c4690639.js} +0 -0
- /package/build/esm/{index.styles-1dd772f8.js → index.styles-4975f159.js} +0 -0
- /package/build/esm/{localizeNumberFormat-19c8d2d8.js → localizeNumberFormat-327ef79b.js} +0 -0
- /package/build/esm/{normalizeLink-5a1b40fe.js → normalizeLink-c00261c5.js} +0 -0
- /package/build/esm/{other-ef01d1f4.js → other-280b32ab.js} +0 -0
- /package/build/esm/{paths-dcc3fa7f.js → paths-af7b0346.js} +0 -0
- /package/build/esm/{translationsContext-e2fbaa27.js → translationsContext-970699a3.js} +0 -0
- /package/build/esm/{tslib.es6-a2bd2269.js → tslib.es6-eca8a1d1.js} +0 -0
- /package/build/esm/{types-bb912a76.js → types-48fa3d8e.js} +0 -0
- /package/build/esm/{useIsInit-9ea7f5e4.js → useIsInit-6fd7ad4e.js} +0 -0
- /package/build/esm/{useOutsideClick-d3a2dc81.js → useOutsideClick-f6b8f1cd.js} +0 -0
- /package/build/esm/{useScrollbarSize-ab5d6df5.js → useScrollbarSize-76a18900.js} +0 -0
- /package/build/esm/{useUniqueId-41acf5a0.js → useUniqueId-76e83ac6.js} +0 -0
- /package/build/esm/{utils-438babc4.js → utils-ed4859f3.js} +0 -0
- /package/build/{index-3b61fab1.js → index-13c15517.js} +0 -0
- /package/build/{index-5033ea1c.js → index-3d42916c.js} +0 -0
- /package/build/{index-44829a33.js → index-47f9f1e5.js} +0 -0
- /package/build/{index-fcc09133.js → index-6c3a42d0.js} +0 -0
- /package/build/{index-b389afd5.js → index-827eafad.js} +0 -0
- /package/build/{index-67581cfd.js → index-94556c4f.js} +0 -0
- /package/build/{index-ad98e521.js → index-972d76d1.js} +0 -0
- /package/build/{index-f1f599d0.js → index-abf7a2cb.js} +0 -0
- /package/build/{index-475449f0.js → index-b744ef38.js} +0 -0
- /package/build/{index.styles-0acf6022.js → index.styles-a1b042a0.js} +0 -0
- /package/build/{localizeNumberFormat-3dae922a.js → localizeNumberFormat-7fb12e39.js} +0 -0
- /package/build/{normalizeLink-21f822e6.js → normalizeLink-d1060c3d.js} +0 -0
- /package/build/{other-8180bdc6.js → other-693a6ae5.js} +0 -0
- /package/build/{paths-443f946c.js → paths-1004acf7.js} +0 -0
- /package/build/{translationsContext-4f7a2e2e.js → translationsContext-200cf744.js} +0 -0
- /package/build/{tslib.es6-f7427702.js → tslib.es6-748c9937.js} +0 -0
- /package/build/{types-6f4267d7.js → types-d8e6306c.js} +0 -0
- /package/build/{useIsInit-a939127f.js → useIsInit-b45e611a.js} +0 -0
- /package/build/{useOutsideClick-44b0ae0e.js → useOutsideClick-c46a0027.js} +0 -0
- /package/build/{useScrollbarSize-851126cb.js → useScrollbarSize-bfe4ab4a.js} +0 -0
- /package/build/{useUniqueId-6bc1a0bb.js → useUniqueId-5db58a2f.js} +0 -0
- /package/build/{utils-3baac105.js → utils-f132a093.js} +0 -0
package/build/esm/lead.js
CHANGED
|
@@ -1,44 +1,42 @@
|
|
|
1
|
-
import { _ as __rest, a as __awaiter } from './tslib.es6-
|
|
2
|
-
import React__default, { createContext, useEffect, useMemo, useRef, useState, useContext
|
|
3
|
-
import { createStyles, Box,
|
|
1
|
+
import { _ as __rest, a as __awaiter } from './tslib.es6-eca8a1d1.js';
|
|
2
|
+
import React__default, { createContext, useEffect, useMemo, useRef, useState, useContext } from 'react';
|
|
3
|
+
import { createStyles, Box, Portal, Transition, Overlay } from '@mantine/core';
|
|
4
4
|
import dayjs from 'dayjs';
|
|
5
5
|
import debounce from 'lodash/debounce';
|
|
6
6
|
import { createFormContext } from '@mantine/form';
|
|
7
|
-
import { u as useTranslations } from './index-
|
|
8
|
-
import { T as Text } from './index-
|
|
9
|
-
import { S as Select, d as Checkbox, I as Input, R as Radio, P as Phone, N as NumberInput } from './index-
|
|
10
|
-
import { D as DatePicker } from './index-
|
|
11
|
-
import { M as MAPPED_LOCALE } from './utils-
|
|
7
|
+
import { u as useTranslations } from './index-8d201d73.js';
|
|
8
|
+
import { T as Text } from './index-272d977d.js';
|
|
9
|
+
import { S as Select, d as Checkbox, I as Input, R as Radio, P as Phone, N as NumberInput } from './index-e7ba79e1.js';
|
|
10
|
+
import { D as DatePicker } from './index-e400c387.js';
|
|
11
|
+
import { M as MAPPED_LOCALE } from './utils-e3692227.js';
|
|
12
12
|
import '@mantine/dates';
|
|
13
|
-
import { Z as ZINDEX_SSO } from './index-
|
|
14
|
-
import './index-
|
|
15
|
-
import { C as CommonGAssets } from './index-
|
|
16
|
-
import './useMantineLocale-
|
|
17
|
-
import { B as Button$1 } from './index-
|
|
18
|
-
import './index.styles-
|
|
19
|
-
import { T as TranslationsContext } from './translationsContext-
|
|
20
|
-
import
|
|
21
|
-
import { b as getWrapperDomWithSelector, a as getPopupWrapperDom } from './utils-
|
|
22
|
-
import './other-
|
|
23
|
-
import './index-
|
|
24
|
-
import { u as usePlacesAutocomplete, G as GOOGLE_API_KEY } from './usePlacesAutocomplete-
|
|
25
|
-
import { B as Button } from './index-
|
|
26
|
-
import { H as Heading$1 } from './index-
|
|
13
|
+
import { Z as ZINDEX_SSO } from './index-86f46388.js';
|
|
14
|
+
import './index-4361942b.js';
|
|
15
|
+
import { C as CommonGAssets } from './index-09345edf.js';
|
|
16
|
+
import './useMantineLocale-6de622f7.js';
|
|
17
|
+
import { B as Button$1 } from './index-a8c09ebf.js';
|
|
18
|
+
import './index.styles-4975f159.js';
|
|
19
|
+
import { T as TranslationsContext } from './translationsContext-970699a3.js';
|
|
20
|
+
import '@mantine/hooks';
|
|
21
|
+
import { b as getWrapperDomWithSelector, a as getPopupWrapperDom } from './utils-ed4859f3.js';
|
|
22
|
+
import './other-280b32ab.js';
|
|
23
|
+
import './index-7d7cd80e.js';
|
|
24
|
+
import { u as usePlacesAutocomplete, G as GOOGLE_API_KEY } from './usePlacesAutocomplete-1606467b.js';
|
|
25
|
+
import { B as Button } from './index-a97e63b7.js';
|
|
26
|
+
import { H as Heading$1 } from './index-819eec4d.js';
|
|
27
27
|
import { v1 } from 'uuid';
|
|
28
|
-
import { i as isVideo } from './index-
|
|
29
|
-
import { D as DrawerComponent } from './index-2df875c9.js';
|
|
30
|
-
import { u as useScreenSize } from './useScreenSize-e1918ff7.js';
|
|
31
|
-
import { createPortal } from 'react-dom';
|
|
32
|
-
import { css } from '@emotion/react';
|
|
33
|
-
import styled from '@emotion/styled';
|
|
28
|
+
import { i as isVideo } from './index-513a4e56.js';
|
|
34
29
|
import { theme } from './miscTheme.js';
|
|
30
|
+
import { createPortal } from 'react-dom';
|
|
35
31
|
import { getCookie, setCookie } from './miscCookieHelper.js';
|
|
36
|
-
import { C as Close } from './Close-
|
|
32
|
+
import { C as Close } from './Close-edd9e39c.js';
|
|
37
33
|
import '@hhgtech/icons/other';
|
|
34
|
+
import './useScreenSize-828d9bce.js';
|
|
35
|
+
import '@emotion/styled';
|
|
38
36
|
import '@mantine/carousel';
|
|
39
|
-
import './Locale-
|
|
37
|
+
import './Locale-9a8d7014.js';
|
|
40
38
|
import 'classnames';
|
|
41
|
-
import './useUniqueId-
|
|
39
|
+
import './useUniqueId-76e83ac6.js';
|
|
42
40
|
import './constantsSite.js';
|
|
43
41
|
import '@hhgtech/icons/core';
|
|
44
42
|
import 'date-fns/locale';
|
|
@@ -46,7 +44,6 @@ import './constantsDomainLocales.js';
|
|
|
46
44
|
import './constantsRiskScreener.js';
|
|
47
45
|
import './constantsIsProduction.js';
|
|
48
46
|
import '@mantine/notifications';
|
|
49
|
-
import 'vaul';
|
|
50
47
|
|
|
51
48
|
const LeadGenComponentContext = createContext({});
|
|
52
49
|
|
|
@@ -520,7 +517,7 @@ const useLeadFormConfig$1 = ({ listBlockAdded = [], validatingPhoneRef, validati
|
|
|
520
517
|
return { form, validateObj };
|
|
521
518
|
};
|
|
522
519
|
|
|
523
|
-
const Component = ({ campaign, onClose: onCloseProp, onOtherSubmit, onSubmit, showThankyou, setShowThankyou, locale, children,
|
|
520
|
+
const Component = ({ campaign, onClose: onCloseProp, onOtherSubmit, onSubmit, showThankyou, setShowThankyou, locale, children, }) => {
|
|
524
521
|
var _a, _b;
|
|
525
522
|
const extraFields = campaign.extra_fields;
|
|
526
523
|
const campaignId = campaign.id;
|
|
@@ -573,8 +570,6 @@ const Component = ({ campaign, onClose: onCloseProp, onOtherSubmit, onSubmit, sh
|
|
|
573
570
|
onSubmit,
|
|
574
571
|
showThankyou,
|
|
575
572
|
setShowThankyou,
|
|
576
|
-
showEmpty,
|
|
577
|
-
setShowEmpty,
|
|
578
573
|
} }, children)) : null;
|
|
579
574
|
};
|
|
580
575
|
|
|
@@ -591,7 +586,7 @@ var useStyles$2 = createStyles(() => {
|
|
|
591
586
|
});
|
|
592
587
|
|
|
593
588
|
const libraries$1 = ['places'];
|
|
594
|
-
const LocationBlock = ({ name, placeholder, locale, required = true, }) => {
|
|
589
|
+
const LocationBlock$1 = ({ name, placeholder, locale, required = true, }) => {
|
|
595
590
|
var _a;
|
|
596
591
|
const form = useLeadFormContext$1();
|
|
597
592
|
const [searchValue, setSearchValue] = useState('');
|
|
@@ -691,7 +686,7 @@ const Fields = ({ listBlockAdded, popupId, locale, onClose, onOtherSubmit, style
|
|
|
691
686
|
id: id, defaultCountry: (locale ? MAPPED_LOCALE[locale] || 'VN' : 'VN'), "data-control": "tel" })));
|
|
692
687
|
}
|
|
693
688
|
case 'LocationBlock': {
|
|
694
|
-
return (React__default.createElement(LocationBlock, { key: index, name: value, placeholder: placeholder, locale: locale, required: required }));
|
|
689
|
+
return (React__default.createElement(LocationBlock$1, { key: index, name: value, placeholder: placeholder, locale: locale, required: required }));
|
|
695
690
|
}
|
|
696
691
|
case 'DateBlock':
|
|
697
692
|
return (React__default.createElement(React__default.Fragment, null,
|
|
@@ -1041,10 +1036,7 @@ var enPH = {
|
|
|
1041
1036
|
"lead.otp.verify": "Verify",
|
|
1042
1037
|
"lead.otp.resend": "Resend OTP{timer}",
|
|
1043
1038
|
"lead.otp.phoneLabel": "Phone OTP",
|
|
1044
|
-
"lead.otp.phonePlaceholder": "Enter OTP"
|
|
1045
|
-
"lead.empty.title": "Oops, seem your information is empty, do you want to submit the information again?",
|
|
1046
|
-
"lead.empty.cancel": "Cancel",
|
|
1047
|
-
"lead.empty.submitAgain": "Submit again"
|
|
1039
|
+
"lead.otp.phonePlaceholder": "Enter OTP"
|
|
1048
1040
|
};
|
|
1049
1041
|
|
|
1050
1042
|
var hiIN = {
|
|
@@ -1060,10 +1052,7 @@ var hiIN = {
|
|
|
1060
1052
|
"lead.otp.title": "Enter OTP",
|
|
1061
1053
|
"lead.otp.desc": "We have sent an OTP to your mobile number {phone}",
|
|
1062
1054
|
"lead.otp.verify": "Verify",
|
|
1063
|
-
"lead.otp.resend": "Resend OTP{timer}"
|
|
1064
|
-
"lead.empty.title": "ऊप्स! लगता है आपकी जानकारी खाली है। क्या आप जानकारी फिर से सबमिट करना चाहते हैं?",
|
|
1065
|
-
"lead.empty.cancel": "रद्द करें",
|
|
1066
|
-
"lead.empty.submitAgain": "फिर से सबमिट करें"
|
|
1055
|
+
"lead.otp.resend": "Resend OTP{timer}"
|
|
1067
1056
|
};
|
|
1068
1057
|
|
|
1069
1058
|
var idID = {
|
|
@@ -1081,10 +1070,7 @@ var idID = {
|
|
|
1081
1070
|
"lead.otp.verify": "Verifikasi",
|
|
1082
1071
|
"lead.otp.resend": "Kirim Ulang OTP {timer}",
|
|
1083
1072
|
"lead.otp.phoneLabel": "OTP Telepon",
|
|
1084
|
-
"lead.otp.phonePlaceholder": "Masukkan OTP"
|
|
1085
|
-
"lead.empty.title": "Oops, sepertinya informasi Anda kosong. Apakah Anda ingin mengirimkan informasi lagi?",
|
|
1086
|
-
"lead.empty.cancel": "Batal",
|
|
1087
|
-
"lead.empty.submitAgain": "Kirim lagi"
|
|
1073
|
+
"lead.otp.phonePlaceholder": "Masukkan OTP"
|
|
1088
1074
|
};
|
|
1089
1075
|
|
|
1090
1076
|
var kmKH = {
|
|
@@ -1102,10 +1088,7 @@ var kmKH = {
|
|
|
1102
1088
|
"lead.otp.verify": "ផ្ទៀងផ្ទាត់",
|
|
1103
1089
|
"lead.otp.resend": "ផ្ញើ OTP ម្តងទៀត {timer}",
|
|
1104
1090
|
"lead.otp.phoneLabel": "OTP ទូរស័ព្ទ",
|
|
1105
|
-
"lead.otp.phonePlaceholder": "បញ្ចូល OTP"
|
|
1106
|
-
"lead.empty.title": "អូុបស! ហាក់ដូចជាព័ត៌មានរបស់អ្នកទទេ។ តើអ្នកចង់ដាក់ស្នើព័ត៌មានម្តងទៀតទេ?",
|
|
1107
|
-
"lead.empty.cancel": "លុបចោល",
|
|
1108
|
-
"lead.empty.submitAgain": "ដាក់ស្នើម្ដងទៀត"
|
|
1091
|
+
"lead.otp.phonePlaceholder": "បញ្ចូល OTP"
|
|
1109
1092
|
};
|
|
1110
1093
|
|
|
1111
1094
|
var msMY = {
|
|
@@ -1123,10 +1106,7 @@ var msMY = {
|
|
|
1123
1106
|
"lead.otp.verify": "Sahkan",
|
|
1124
1107
|
"lead.otp.resend": "Hantar semula OTP {timer}",
|
|
1125
1108
|
"lead.otp.phoneLabel": "OTP Telefon",
|
|
1126
|
-
"lead.otp.phonePlaceholder": "Masukkan OTP"
|
|
1127
|
-
"lead.empty.title": "Oops, nampaknya maklumat anda kosong. Adakah anda ingin menghantar maklumat semula?",
|
|
1128
|
-
"lead.empty.cancel": "Batal",
|
|
1129
|
-
"lead.empty.submitAgain": "Hantar semula"
|
|
1109
|
+
"lead.otp.phonePlaceholder": "Masukkan OTP"
|
|
1130
1110
|
};
|
|
1131
1111
|
|
|
1132
1112
|
var myMM = {
|
|
@@ -1144,10 +1124,7 @@ var myMM = {
|
|
|
1144
1124
|
"lead.otp.verify": "အတည်ပြုပါ",
|
|
1145
1125
|
"lead.otp.resend": "OTP ကိုထပ်မံပို့ရန် {timer}",
|
|
1146
1126
|
"lead.otp.phoneLabel": "ဖုန်း OTP",
|
|
1147
|
-
"lead.otp.phonePlaceholder": "OTP ကိုထည့်ပါ"
|
|
1148
|
-
"lead.empty.title": "အုပ်စ်! သင့်အချက်အလက်သည် ဗလာဖြစ်နေသလိုဖြစ်သည်။ ထပ်မံတင်သွင်းလိုပါသလား?",
|
|
1149
|
-
"lead.empty.cancel": "မလုပ်ဆောင်ပါ",
|
|
1150
|
-
"lead.empty.submitAgain": "ထပ်မံတင်သွင်းပါ"
|
|
1127
|
+
"lead.otp.phonePlaceholder": "OTP ကိုထည့်ပါ"
|
|
1151
1128
|
};
|
|
1152
1129
|
|
|
1153
1130
|
var thTH = {
|
|
@@ -1165,10 +1142,7 @@ var thTH = {
|
|
|
1165
1142
|
"lead.otp.verify": "ยืนยัน",
|
|
1166
1143
|
"lead.otp.resend": "ส่ง OTP อีกครั้ง {timer}",
|
|
1167
1144
|
"lead.otp.phoneLabel": "OTP โทรศัพท์",
|
|
1168
|
-
"lead.otp.phonePlaceholder": "ป้อน OTP"
|
|
1169
|
-
"lead.empty.title": "อุ๊ปส์! ดูเหมือนว่าข้อมูลของคุณว่างเปล่า คุณต้องการส่งข้อมูลอีกครั้งหรือไม่?",
|
|
1170
|
-
"lead.empty.cancel": "ยกเลิก",
|
|
1171
|
-
"lead.empty.submitAgain": "ส่งอีกครั้ง"
|
|
1145
|
+
"lead.otp.phonePlaceholder": "ป้อน OTP"
|
|
1172
1146
|
};
|
|
1173
1147
|
|
|
1174
1148
|
var viVN = {
|
|
@@ -1197,10 +1171,7 @@ var viVN = {
|
|
|
1197
1171
|
"lead.otp.verify": "Xác minh",
|
|
1198
1172
|
"lead.otp.resend": "Gửi lại OTP {timer}",
|
|
1199
1173
|
"lead.otp.phoneLabel": "Nhập OTP",
|
|
1200
|
-
"lead.otp.phonePlaceholder": "Nhập OTP"
|
|
1201
|
-
"lead.empty.title": "Oops, có vẻ như thông tin của bạn đang trống. Bạn có muốn gửi lại thông tin không?",
|
|
1202
|
-
"lead.empty.cancel": "Hủy",
|
|
1203
|
-
"lead.empty.submitAgain": "Gửi lại"
|
|
1174
|
+
"lead.otp.phonePlaceholder": "Nhập OTP"
|
|
1204
1175
|
};
|
|
1205
1176
|
|
|
1206
1177
|
var zhTW = {
|
|
@@ -1218,10 +1189,7 @@ var zhTW = {
|
|
|
1218
1189
|
"lead.otp.verify": "驗證",
|
|
1219
1190
|
"lead.otp.resend": "重新發送 OTP {timer}",
|
|
1220
1191
|
"lead.otp.phoneLabel": "電話 OTP",
|
|
1221
|
-
"lead.otp.phonePlaceholder": "輸入 OTP"
|
|
1222
|
-
"lead.empty.title": "哎呀,您的資訊似乎是空的,您想要重新提交資訊嗎?",
|
|
1223
|
-
"lead.empty.cancel": "取消",
|
|
1224
|
-
"lead.empty.submitAgain": "重新提交"
|
|
1192
|
+
"lead.otp.phonePlaceholder": "輸入 OTP"
|
|
1225
1193
|
};
|
|
1226
1194
|
|
|
1227
1195
|
const translationsMap = {
|
|
@@ -1281,8 +1249,9 @@ const useImageSize = (src) => {
|
|
|
1281
1249
|
};
|
|
1282
1250
|
|
|
1283
1251
|
const CloseButton = ({ onClose, containerClassName, svgClassName, }) => (React__default.createElement("button", { onClick: onClose, className: `le-newbuilder-close-button js-modal__close ${containerClassName || ''}` },
|
|
1284
|
-
React__default.createElement("svg", { width: "
|
|
1285
|
-
React__default.createElement("
|
|
1252
|
+
React__default.createElement("svg", { width: "32", height: "32", viewBox: "0 0 32 32", fill: "none", className: svgClassName },
|
|
1253
|
+
React__default.createElement("circle", { cx: "16", cy: "16", r: "16", fill: "white" }),
|
|
1254
|
+
React__default.createElement("path", { d: "m16 17.05-5.075 5.075a.74.74 0 0 1-.512.212.7.7 0 0 1-.538-.212.72.72 0 0 1-.225-.525q0-.3.225-.525L14.95 16l-5.075-5.075a.74.74 0 0 1-.212-.513.7.7 0 0 1 .212-.537.72.72 0 0 1 .525-.225q.3 0 .525.225L16 14.95l5.075-5.075a.74.74 0 0 1 .513-.213.7.7 0 0 1 .537.213.72.72 0 0 1 .225.525.72.72 0 0 1-.225.525L17.05 16l5.075 5.075a.74.74 0 0 1 .212.512.7.7 0 0 1-.212.538.72.72 0 0 1-.525.225.72.72 0 0 1-.525-.225z", fill: "#595959" }))));
|
|
1286
1255
|
|
|
1287
1256
|
// url: imageBlocks.imageMobile.data.url
|
|
1288
1257
|
// newTab: imageBlocks.imageMobile.data.newtab
|
|
@@ -1359,192 +1328,6 @@ const FloatingLayout = ({ popupId, url, title, urlText, titleAlign, subtitle, su
|
|
|
1359
1328
|
React__default.createElement(CloseButton, { onClose: onClose, containerClassName: "close-button-top-right" }))))));
|
|
1360
1329
|
};
|
|
1361
1330
|
|
|
1362
|
-
const ThankyouPopup = ({ title, titleAlign, subtitle, subtitleAlign, link, linkNewTab, linkText, image, }) => {
|
|
1363
|
-
const { width: imageWidth, height: imageHeight, loaded: imageLoaded, } = useImageSize(image);
|
|
1364
|
-
if (!imageLoaded)
|
|
1365
|
-
return null;
|
|
1366
|
-
return (React__default.createElement("div", { className: "lead-modal__thank-you" },
|
|
1367
|
-
React__default.createElement("div", { style: { width: '100%' } },
|
|
1368
|
-
React__default.createElement("img", { src: image, style: {
|
|
1369
|
-
maxHeight: 162,
|
|
1370
|
-
objectFit: 'cover',
|
|
1371
|
-
aspectRatio: `${imageWidth}/${imageHeight}`,
|
|
1372
|
-
}, loading: "lazy" }),
|
|
1373
|
-
title && (React__default.createElement("h1", { className: `le-thankyou-title le-text-align-${titleAlign}` }, title)),
|
|
1374
|
-
subtitle && (React__default.createElement("p", { className: `le-thankyou-subtitle le-text-align-${subtitleAlign}` }, subtitle.split('\n').map((text, idx, list) => {
|
|
1375
|
-
const isShowBr = idx < list.length - 1;
|
|
1376
|
-
return (React__default.createElement(React__default.Fragment, null,
|
|
1377
|
-
text,
|
|
1378
|
-
isShowBr && React__default.createElement("br", null)));
|
|
1379
|
-
}))),
|
|
1380
|
-
linkText && (React__default.createElement("div", null,
|
|
1381
|
-
React__default.createElement("a", { href: link, target: linkNewTab ? '_blank' : 'parrent', rel: "noreferrer" },
|
|
1382
|
-
React__default.createElement("button", { className: `lead-modal__btn ${LEAD_CLASS}` }, linkText)))))));
|
|
1383
|
-
};
|
|
1384
|
-
|
|
1385
|
-
const InlineLayout = ({ content, inlinePosition, }) => {
|
|
1386
|
-
const target = useMemo(() => {
|
|
1387
|
-
if (!inlinePosition)
|
|
1388
|
-
return null;
|
|
1389
|
-
const parents = document.querySelectorAll(`[data-url="${location.pathname}"] .body-content`);
|
|
1390
|
-
const allChildren = Array.from(parents).reduce((r, p) => {
|
|
1391
|
-
return [...r, ...Array.from(p.children)];
|
|
1392
|
-
}, []);
|
|
1393
|
-
if (allChildren === null || allChildren === void 0 ? void 0 : allChildren.length) {
|
|
1394
|
-
// find the third p tag in the body content, some other tags might mix in between
|
|
1395
|
-
const allPTags = allChildren.filter((c) => c.nodeName === 'P');
|
|
1396
|
-
const allH2Tags = allChildren.filter((c) => c.nodeName === 'H2');
|
|
1397
|
-
let target = null;
|
|
1398
|
-
switch (inlinePosition) {
|
|
1399
|
-
case '1th':
|
|
1400
|
-
target = allPTags[0];
|
|
1401
|
-
break;
|
|
1402
|
-
case '2th':
|
|
1403
|
-
target = allPTags[1];
|
|
1404
|
-
break;
|
|
1405
|
-
case '3th':
|
|
1406
|
-
target = allPTags[2];
|
|
1407
|
-
break;
|
|
1408
|
-
case '4th':
|
|
1409
|
-
target = allPTags[3];
|
|
1410
|
-
break;
|
|
1411
|
-
case '5th':
|
|
1412
|
-
target = allPTags[4];
|
|
1413
|
-
break;
|
|
1414
|
-
case '6th':
|
|
1415
|
-
target = allPTags[5];
|
|
1416
|
-
break;
|
|
1417
|
-
case '7th':
|
|
1418
|
-
target = allPTags[6];
|
|
1419
|
-
break;
|
|
1420
|
-
case '8th':
|
|
1421
|
-
target = allPTags[7];
|
|
1422
|
-
break;
|
|
1423
|
-
case '9th':
|
|
1424
|
-
target = allPTags[8];
|
|
1425
|
-
break;
|
|
1426
|
-
case '10th':
|
|
1427
|
-
target = allPTags[9];
|
|
1428
|
-
break;
|
|
1429
|
-
case '11th':
|
|
1430
|
-
target = allPTags[10];
|
|
1431
|
-
break;
|
|
1432
|
-
case '12th':
|
|
1433
|
-
target = allPTags[11];
|
|
1434
|
-
break;
|
|
1435
|
-
case 'lastP':
|
|
1436
|
-
target = allPTags[allPTags.length - 1];
|
|
1437
|
-
break;
|
|
1438
|
-
case '1thH2':
|
|
1439
|
-
target = allH2Tags[0];
|
|
1440
|
-
break;
|
|
1441
|
-
case '2thH2':
|
|
1442
|
-
target = allH2Tags[1];
|
|
1443
|
-
break;
|
|
1444
|
-
case '3thH2':
|
|
1445
|
-
target = allH2Tags[2];
|
|
1446
|
-
break;
|
|
1447
|
-
case '4thH2':
|
|
1448
|
-
target = allH2Tags[3];
|
|
1449
|
-
break;
|
|
1450
|
-
case '5thH2':
|
|
1451
|
-
target = allH2Tags[4];
|
|
1452
|
-
break;
|
|
1453
|
-
case '6thH2':
|
|
1454
|
-
target = allH2Tags[5];
|
|
1455
|
-
break;
|
|
1456
|
-
case '7thH2':
|
|
1457
|
-
target = allH2Tags[6];
|
|
1458
|
-
break;
|
|
1459
|
-
case '8thH2':
|
|
1460
|
-
target = allH2Tags[7];
|
|
1461
|
-
break;
|
|
1462
|
-
case '9thH2':
|
|
1463
|
-
target = allH2Tags[8];
|
|
1464
|
-
break;
|
|
1465
|
-
case '10thH2':
|
|
1466
|
-
target = allH2Tags[9];
|
|
1467
|
-
break;
|
|
1468
|
-
case 'lastH2':
|
|
1469
|
-
target = allH2Tags[allH2Tags.length - 1];
|
|
1470
|
-
break;
|
|
1471
|
-
}
|
|
1472
|
-
if (target) {
|
|
1473
|
-
if (!target.parentElement.querySelector('.inline-lead-wrapper')) {
|
|
1474
|
-
const wrapper = document.createElement('div');
|
|
1475
|
-
wrapper.classList.add('inline-lead-wrapper');
|
|
1476
|
-
if (target.nextElementSibling) {
|
|
1477
|
-
target.parentElement.insertBefore(wrapper, target.nextElementSibling);
|
|
1478
|
-
}
|
|
1479
|
-
else {
|
|
1480
|
-
target.parentElement.appendChild(wrapper);
|
|
1481
|
-
}
|
|
1482
|
-
return wrapper;
|
|
1483
|
-
}
|
|
1484
|
-
else {
|
|
1485
|
-
return target.parentElement.querySelector('.inline-lead-wrapper');
|
|
1486
|
-
}
|
|
1487
|
-
}
|
|
1488
|
-
}
|
|
1489
|
-
}, [inlinePosition]);
|
|
1490
|
-
if (!inlinePosition || !target)
|
|
1491
|
-
return null;
|
|
1492
|
-
return createPortal(content, target);
|
|
1493
|
-
};
|
|
1494
|
-
|
|
1495
|
-
const SideBarLayout = ({ content }) => {
|
|
1496
|
-
const targets = useMemo(() => {
|
|
1497
|
-
const targetDoms = Array.from(document.querySelectorAll('.hc2-sidebar-with-ads,.page-main-col .right-col.f-right,.hhg-lead-sidebar'));
|
|
1498
|
-
targetDoms.forEach((dom) => {
|
|
1499
|
-
if (dom.querySelector('.sidebar-lead-modal-wrapper'))
|
|
1500
|
-
return;
|
|
1501
|
-
const wrapper = document.createElement('div');
|
|
1502
|
-
wrapper.classList.add('sidebar-lead-modal-wrapper');
|
|
1503
|
-
dom.prepend(wrapper);
|
|
1504
|
-
});
|
|
1505
|
-
return targetDoms.map((d) => d.querySelector('.sidebar-lead-modal-wrapper'));
|
|
1506
|
-
}, []);
|
|
1507
|
-
return (React__default.createElement(React__default.Fragment, null, targets.map((target) => createPortal(content, getWrapperDomWithSelector(target, 'sidebar-lead-modal-wrapper')))));
|
|
1508
|
-
};
|
|
1509
|
-
|
|
1510
|
-
const libraries = ['places'];
|
|
1511
|
-
const GoogleLocation = (props) => {
|
|
1512
|
-
var _a;
|
|
1513
|
-
const { inputWrapperOrder = ['label', 'input', 'description', 'error'], defaultValue, value: valueProps, onChange: onChangeProps, locale } = props, restProps = __rest(props, ["inputWrapperOrder", "defaultValue", "value", "onChange", "locale"]);
|
|
1514
|
-
const [LoadScript, setLoadScript] = useState(null);
|
|
1515
|
-
const [value, setValue] = useState(defaultValue || valueProps);
|
|
1516
|
-
const { predictions } = usePlacesAutocomplete(value, '', locale === 'tl-PH' ? 'en' : (_a = locale === null || locale === void 0 ? void 0 : locale.split('-')) === null || _a === void 0 ? void 0 : _a[0]);
|
|
1517
|
-
const onChangeAutocomplete = useCallback((s) => {
|
|
1518
|
-
setValue(s);
|
|
1519
|
-
onChangeProps === null || onChangeProps === void 0 ? void 0 : onChangeProps(s);
|
|
1520
|
-
}, []);
|
|
1521
|
-
const onClickItem = useCallback((item) => {
|
|
1522
|
-
/** For sure get value */
|
|
1523
|
-
setValue(item.value);
|
|
1524
|
-
const predCur = predictions === null || predictions === void 0 ? void 0 : predictions.find(({ description }) => description === item.value);
|
|
1525
|
-
onChangeProps === null || onChangeProps === void 0 ? void 0 : onChangeProps(item.value, predCur === null || predCur === void 0 ? void 0 : predCur.rawData);
|
|
1526
|
-
}, [onChangeProps, predictions]);
|
|
1527
|
-
useEffect(() => {
|
|
1528
|
-
setValue(valueProps);
|
|
1529
|
-
}, [valueProps]);
|
|
1530
|
-
useEffect(() => {
|
|
1531
|
-
var _a, _b, _c;
|
|
1532
|
-
// only load extra google script when not yet loaded
|
|
1533
|
-
if (!((_c = (_b = (_a = window === null || window === void 0 ? void 0 : window.google) === null || _a === void 0 ? void 0 : _a.maps) === null || _b === void 0 ? void 0 : _b.places) === null || _c === void 0 ? void 0 : _c.AutocompleteService) && !LoadScript) {
|
|
1534
|
-
import('@react-google-maps/api').then((m) => {
|
|
1535
|
-
setLoadScript(() => m.LoadScript);
|
|
1536
|
-
});
|
|
1537
|
-
}
|
|
1538
|
-
}, []);
|
|
1539
|
-
return (React__default.createElement(Autocomplete, Object.assign({ defaultValue: defaultValue, value: value, onChange: onChangeAutocomplete, data: predictions.map((pred) => {
|
|
1540
|
-
return { value: pred.description, label: pred.description };
|
|
1541
|
-
}), filter: () => true, onItemSubmit: onClickItem, inputWrapperOrder: inputWrapperOrder, inputContainer: (children) => {
|
|
1542
|
-
return (React__default.createElement(React__default.Fragment, null,
|
|
1543
|
-
LoadScript && (React__default.createElement(LoadScript, { googleMapsApiKey: GOOGLE_API_KEY, libraries: libraries, loadingElement: React__default.createElement(React__default.Fragment, null), style: { width: '100%' } })),
|
|
1544
|
-
children));
|
|
1545
|
-
} }, restProps)));
|
|
1546
|
-
};
|
|
1547
|
-
|
|
1548
1331
|
// You can give context variables any name
|
|
1549
1332
|
const [LeadFormProvider, useLeadFormContext, useLeadForm] = createFormContext();
|
|
1550
1333
|
const useLeadFormConfig = ({ listBlockAdded = [], validatingPhoneRef, validatingEmailRef, campaignId, campaign_subot_id = [], }) => {
|
|
@@ -1574,9 +1357,9 @@ const useLeadFormConfig = ({ listBlockAdded = [], validatingPhoneRef, validating
|
|
|
1574
1357
|
const isBLockRequired = (_a = block === null || block === void 0 ? void 0 : block.data) === null || _a === void 0 ? void 0 : _a.required;
|
|
1575
1358
|
if (!formRef.current.isTouched(name))
|
|
1576
1359
|
return;
|
|
1577
|
-
if (
|
|
1578
|
-
typeof value === 'undefined' ||
|
|
1360
|
+
if (typeof value === 'undefined' ||
|
|
1579
1361
|
value === '' ||
|
|
1362
|
+
(typeof value === 'string' && value.replace(' ', '') === '') ||
|
|
1580
1363
|
(Array.isArray(value) && value.length === 0)) {
|
|
1581
1364
|
return isBLockRequired
|
|
1582
1365
|
? t('validator.required')
|
|
@@ -1710,377 +1493,108 @@ const useLeadFormConfig = ({ listBlockAdded = [], validatingPhoneRef, validating
|
|
|
1710
1493
|
return { form, validateObj };
|
|
1711
1494
|
};
|
|
1712
1495
|
|
|
1713
|
-
const
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
const cssInputShrink = css `
|
|
1734
|
-
height: auto !important;
|
|
1735
|
-
cursor: text;
|
|
1736
|
-
opacity: 1;
|
|
1737
|
-
transition: 0.1s ease-in-out all;
|
|
1738
|
-
`;
|
|
1739
|
-
const cssLabelNotShrink = css `
|
|
1740
|
-
position: absolute;
|
|
1741
|
-
top: calc(var(--container-height) / 2);
|
|
1742
|
-
left: var(--space-x, 16px);
|
|
1743
|
-
color: ${theme.colors.gray400};
|
|
1744
|
-
font-size: var(--label-not-shrink, 16px);
|
|
1745
|
-
font-weight: 400;
|
|
1746
|
-
line-height: calc(var(--container-height, 56px) * 18 / 56);
|
|
1747
|
-
margin: 0;
|
|
1748
|
-
z-index: 1;
|
|
1749
|
-
cursor: pointer;
|
|
1750
|
-
transform: translateY(-50%);
|
|
1751
|
-
transition: 0.125s ease-in all;
|
|
1752
|
-
`;
|
|
1753
|
-
const cssLabelShrink = css `
|
|
1754
|
-
color: ${theme.colors.gray600};
|
|
1755
|
-
font-weight: 600;
|
|
1756
|
-
font-size: var(--label-shrink, 12px);
|
|
1757
|
-
top: calc(var(--container-height) * 7 / 56);
|
|
1758
|
-
transform: none;
|
|
1759
|
-
transition: 0.125s ease-out all;
|
|
1760
|
-
`;
|
|
1761
|
-
const cssWrapperInputNotShrink = css `
|
|
1762
|
-
min-height: var(--container-height, 56px);
|
|
1763
|
-
display: flex;
|
|
1764
|
-
align-items: flex-end;
|
|
1765
|
-
border: 1px solid ${theme.colors.gray200};
|
|
1766
|
-
border-radius: 8px;
|
|
1767
|
-
background-color: #fff;
|
|
1768
|
-
padding-inline: var(--space-x, 16px);
|
|
1769
|
-
padding-block: var(--space-y-not-shrink, 16px);
|
|
1770
|
-
cursor: pointer;
|
|
1771
|
-
pointer-events: none;
|
|
1772
|
-
|
|
1773
|
-
&:has(input[data-invalid]) {
|
|
1774
|
-
border-color: ${theme.colors.red400};
|
|
1775
|
-
}
|
|
1776
|
-
|
|
1777
|
-
&:has(.mantine-Input-rightSection) {
|
|
1778
|
-
padding-right: var(--container-height, 56px);
|
|
1779
|
-
}
|
|
1780
|
-
|
|
1781
|
-
.mantine-Input-icon {
|
|
1782
|
-
display: none;
|
|
1783
|
-
}
|
|
1784
|
-
|
|
1785
|
-
.mantine-NumberInput-control {
|
|
1786
|
-
border-color: ${theme.colors.gray200};
|
|
1787
|
-
}
|
|
1788
|
-
`;
|
|
1789
|
-
const cssWrapperInputShrink = css `
|
|
1790
|
-
height: auto;
|
|
1791
|
-
min-height: var(--container-height, 56px);
|
|
1792
|
-
padding-block: var(--space-y-shrink, 7px);
|
|
1793
|
-
cursor: text;
|
|
1794
|
-
pointer-events: auto;
|
|
1795
|
-
`;
|
|
1796
|
-
const StyledTextFieldContainer = styled.div `
|
|
1797
|
-
--space-x: 16px;
|
|
1798
|
-
--space-y-not-shrink: 16px;
|
|
1799
|
-
--space-y-shrink: 7px;
|
|
1800
|
-
--container-height: 56px;
|
|
1801
|
-
--label-not-shrink: 16px;
|
|
1802
|
-
--label-shrink: 12px;
|
|
1803
|
-
--input: 16px;
|
|
1804
|
-
|
|
1805
|
-
position: relative;
|
|
1806
|
-
min-width: 100px;
|
|
1807
|
-
max-width: 100%;
|
|
1808
|
-
display: inline-block;
|
|
1809
|
-
|
|
1810
|
-
.textField_wrapper {
|
|
1811
|
-
display: inline-block;
|
|
1812
|
-
width: 100%;
|
|
1813
|
-
cursor: pointer;
|
|
1814
|
-
}
|
|
1815
|
-
|
|
1816
|
-
.mantine-InputWrapper-label {
|
|
1817
|
-
${cssLabelNotShrink}
|
|
1818
|
-
}
|
|
1819
|
-
|
|
1820
|
-
.mantine-Input-wrapper {
|
|
1821
|
-
${cssWrapperInputNotShrink}
|
|
1822
|
-
|
|
1823
|
-
+ .mantine-Popover-dropdown[data-position="bottom-start"] {
|
|
1824
|
-
left: 0 !important;
|
|
1825
|
-
}
|
|
1826
|
-
}
|
|
1827
|
-
|
|
1828
|
-
.mantine-Input-input {
|
|
1829
|
-
${cssInputNotShrink}
|
|
1830
|
-
}
|
|
1831
|
-
|
|
1832
|
-
&.textField_shrink,
|
|
1833
|
-
&:focus-within {
|
|
1834
|
-
.mantine-InputWrapper-label {
|
|
1835
|
-
${cssLabelShrink}
|
|
1836
|
-
}
|
|
1837
|
-
|
|
1838
|
-
.mantine-Input-wrapper {
|
|
1839
|
-
${cssWrapperInputShrink}
|
|
1840
|
-
&.mantine-Select-wrapper {
|
|
1841
|
-
.mantine-Select-rightSection {
|
|
1842
|
-
pointer-events: auto !important;
|
|
1843
|
-
}
|
|
1844
|
-
}
|
|
1845
|
-
}
|
|
1846
|
-
|
|
1847
|
-
.mantine-Input-input {
|
|
1848
|
-
${cssInputShrink}
|
|
1849
|
-
}
|
|
1850
|
-
|
|
1851
|
-
&:has(.PhoneInput) {
|
|
1852
|
-
.mantine-InputWrapper-label {
|
|
1853
|
-
left: var(--space-x, 16px);
|
|
1854
|
-
}
|
|
1855
|
-
.PhoneInput {
|
|
1856
|
-
.PhoneInputInput {
|
|
1857
|
-
opacity: 1;
|
|
1858
|
-
}
|
|
1859
|
-
}
|
|
1860
|
-
}
|
|
1861
|
-
}
|
|
1862
|
-
|
|
1863
|
-
.PhoneInput {
|
|
1864
|
-
--phone-select: 75px;
|
|
1865
|
-
--phone-input-space-x: 8px;
|
|
1866
|
-
width: 100%;
|
|
1867
|
-
opacity: 1;
|
|
1868
|
-
border: none;
|
|
1869
|
-
.PhoneInputCountry {
|
|
1870
|
-
background-color: transparent;
|
|
1871
|
-
border: none;
|
|
1872
|
-
padding: 0;
|
|
1873
|
-
width: var(--phone-select, 75px);
|
|
1874
|
-
}
|
|
1875
|
-
.PhoneInputInput {
|
|
1876
|
-
flex: 1;
|
|
1877
|
-
min-width: 0;
|
|
1878
|
-
line-height: 1.5;
|
|
1879
|
-
outline: none !important;
|
|
1880
|
-
border: none;
|
|
1881
|
-
box-shadow: none;
|
|
1882
|
-
padding: 0 var(--phone-input-space-x, 8px);
|
|
1883
|
-
opacity: 0;
|
|
1884
|
-
color: ${theme.colors.gray800} !important;
|
|
1885
|
-
:focus {
|
|
1886
|
-
color: ${theme.colors.gray800} !important;
|
|
1887
|
-
}
|
|
1888
|
-
}
|
|
1889
|
-
}
|
|
1890
|
-
|
|
1891
|
-
&:has(.PhoneInput) {
|
|
1892
|
-
.mantine-InputWrapper-label {
|
|
1893
|
-
left: calc(
|
|
1894
|
-
var(--space-x, 16px) + var(--phone-select, 75px) +
|
|
1895
|
-
var(--phone-input-space-x, 8px)
|
|
1896
|
-
);
|
|
1897
|
-
}
|
|
1898
|
-
}
|
|
1899
|
-
`;
|
|
1900
|
-
const StyledChoiceFieldContainer = styled.div `
|
|
1901
|
-
&.leadgen-form_checkbox,
|
|
1902
|
-
&.leadgen-form_radio {
|
|
1903
|
-
width: 100%;
|
|
1904
|
-
}
|
|
1905
|
-
|
|
1906
|
-
&.leadgen-form_dropdown {
|
|
1907
|
-
width: calc(50% - 12px);
|
|
1908
|
-
}
|
|
1909
|
-
|
|
1910
|
-
.mantine-InputWrapper-root {
|
|
1911
|
-
display: block;
|
|
1912
|
-
}
|
|
1913
|
-
|
|
1914
|
-
.mantine-InputWrapper-label {
|
|
1915
|
-
margin-bottom: 0.5rem;
|
|
1916
|
-
color: ${theme.colors.gray800};
|
|
1917
|
-
font-size: 16px;
|
|
1918
|
-
font-weight: 400;
|
|
1919
|
-
line-height: 1.5;
|
|
1920
|
-
}
|
|
1921
|
-
|
|
1922
|
-
.mantine-Radio-root,
|
|
1923
|
-
.mantine-Checkbox-root {
|
|
1924
|
-
gap: 8px;
|
|
1925
|
-
min-width: calc(50% - 4px);
|
|
1926
|
-
|
|
1927
|
-
input[type='radio'],
|
|
1928
|
-
input[type='checkbox'] {
|
|
1929
|
-
border-color: ${theme.colors.gray600};
|
|
1930
|
-
width: 18px;
|
|
1931
|
-
height: 18px;
|
|
1932
|
-
}
|
|
1933
|
-
input[type='checkbox'] {
|
|
1934
|
-
border-radius: 4px;
|
|
1935
|
-
}
|
|
1936
|
-
|
|
1937
|
-
&[data-checked='true'] {
|
|
1938
|
-
input[type='radio'],
|
|
1939
|
-
input[type='checkbox'] {
|
|
1940
|
-
border-color: ${theme.colors.primary600};
|
|
1941
|
-
}
|
|
1942
|
-
|
|
1943
|
-
input[type='radio'] {
|
|
1944
|
-
background-color: white;
|
|
1945
|
-
}
|
|
1946
|
-
}
|
|
1947
|
-
}
|
|
1948
|
-
|
|
1949
|
-
.mantine-Radio-inner,
|
|
1950
|
-
.mantine-Checkbox-inner {
|
|
1951
|
-
width: 24px;
|
|
1952
|
-
height: 24px;
|
|
1953
|
-
display: flex;
|
|
1954
|
-
align-items: center;
|
|
1955
|
-
justify-content: center;
|
|
1956
|
-
}
|
|
1957
|
-
|
|
1958
|
-
.mantine-Radio-body,
|
|
1959
|
-
.mantine-Checkbox-body {
|
|
1960
|
-
display: flex;
|
|
1961
|
-
align-items: center;
|
|
1962
|
-
}
|
|
1963
|
-
|
|
1964
|
-
.mantine-Radio-label,
|
|
1965
|
-
.mantine-Checkbox-label {
|
|
1966
|
-
padding-left: 8px;
|
|
1967
|
-
color: ${theme.colors.gray800};
|
|
1968
|
-
font-size: 14px;
|
|
1969
|
-
line-height: 1.4;
|
|
1970
|
-
letter-spacing: -0.2px;
|
|
1971
|
-
}
|
|
1972
|
-
|
|
1973
|
-
.leadgen-choiceContainer {
|
|
1974
|
-
display: flex;
|
|
1975
|
-
flex-wrap: wrap;
|
|
1976
|
-
align-items: flex-start;
|
|
1977
|
-
gap: 8px;
|
|
1978
|
-
}
|
|
1979
|
-
`;
|
|
1980
|
-
|
|
1981
|
-
const TextField = (props) => {
|
|
1982
|
-
const { shrink: shrinkProps, onChangeShrink, className, children } = props, restProps = __rest(props, ["shrink", "onChangeShrink", "className", "children"]);
|
|
1983
|
-
const containerRef = useClickOutside(() => {
|
|
1984
|
-
if (shrinkProps) {
|
|
1985
|
-
return;
|
|
1986
|
-
}
|
|
1987
|
-
setShrink(false);
|
|
1988
|
-
onChangeShrink === null || onChangeShrink === void 0 ? void 0 : onChangeShrink(false);
|
|
1989
|
-
});
|
|
1990
|
-
const [shrink, setShrink] = useState(shrinkProps);
|
|
1991
|
-
const onClick = useCallback((e) => {
|
|
1992
|
-
setShrink(true);
|
|
1993
|
-
onChangeShrink === null || onChangeShrink === void 0 ? void 0 : onChangeShrink(true);
|
|
1994
|
-
if (shrink) {
|
|
1995
|
-
return;
|
|
1496
|
+
const libraries = ['places'];
|
|
1497
|
+
const LocationBlock = ({ name, placeholder, locale, required = true, }) => {
|
|
1498
|
+
var _a;
|
|
1499
|
+
const form = useLeadFormContext();
|
|
1500
|
+
const [searchValue, setSearchValue] = useState('');
|
|
1501
|
+
const [address, setAddress] = useState('');
|
|
1502
|
+
const { predictions } = usePlacesAutocomplete(searchValue, '', locale === 'tl-PH' ? 'en' : (_a = locale === null || locale === void 0 ? void 0 : locale.split('-')) === null || _a === void 0 ? void 0 : _a[0]);
|
|
1503
|
+
const [LoadScript, setLoadScript] = useState(null);
|
|
1504
|
+
const [ready, setReady] = useState(false);
|
|
1505
|
+
const randRef = useRef(Math.random().toString(36).substring(7));
|
|
1506
|
+
const options = useMemo(() => {
|
|
1507
|
+
const _opts = predictions.map((p) => {
|
|
1508
|
+
return {
|
|
1509
|
+
value: p.description,
|
|
1510
|
+
label: p.description,
|
|
1511
|
+
};
|
|
1512
|
+
});
|
|
1513
|
+
const isExist = _opts.find((o) => o.value === address);
|
|
1514
|
+
if (!address || isExist) {
|
|
1515
|
+
return _opts;
|
|
1996
1516
|
}
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
1517
|
+
return [{ value: address, label: address }].concat(_opts);
|
|
1518
|
+
}, [predictions, address]);
|
|
1519
|
+
useEffect(() => {
|
|
1520
|
+
var _a, _b, _c;
|
|
1521
|
+
// only load extra google script when not yet loaded
|
|
1522
|
+
if (!((_c = (_b = (_a = window === null || window === void 0 ? void 0 : window.google) === null || _a === void 0 ? void 0 : _a.maps) === null || _b === void 0 ? void 0 : _b.places) === null || _c === void 0 ? void 0 : _c.AutocompleteService)) {
|
|
1523
|
+
import('@react-google-maps/api').then((m) => {
|
|
1524
|
+
setLoadScript(() => m.LoadScript);
|
|
1525
|
+
setTimeout(() => {
|
|
1526
|
+
setReady(true);
|
|
1527
|
+
}, 200);
|
|
2005
1528
|
});
|
|
2006
1529
|
}
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
}, [
|
|
2011
|
-
|
|
2012
|
-
React__default.createElement("div", {
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
1530
|
+
else {
|
|
1531
|
+
setReady(true);
|
|
1532
|
+
}
|
|
1533
|
+
}, []);
|
|
1534
|
+
if (!ready)
|
|
1535
|
+
return (React__default.createElement("div", { style: {
|
|
1536
|
+
height: 73,
|
|
1537
|
+
} }));
|
|
1538
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
1539
|
+
LoadScript && (React__default.createElement(LoadScript, { googleMapsApiKey: GOOGLE_API_KEY, libraries: libraries, loadingElement: React__default.createElement(React__default.Fragment, null) })),
|
|
1540
|
+
React__default.createElement("div", { style: { display: 'none' }, "data-extra": true, "data-name": name, "data-control": 'text' }),
|
|
1541
|
+
React__default.createElement(Select, Object.assign({ className: "lead-modal__form-control", label: placeholder, placeholder: placeholder, withAsterisk: required, name: name, data: options, searchValue: searchValue, onSearchChange: (query) => {
|
|
1542
|
+
setSearchValue(query);
|
|
1543
|
+
}, filter: () => true, clearable: true, searchable: true, onChange: (val) => setAddress(val || ''), icon: React__default.createElement("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none" },
|
|
1544
|
+
React__default.createElement("path", { d: "M10 9.792q.605 0 1.032-.427.426-.428.426-1.032 0-.603-.426-1.031A1.4 1.4 0 0 0 10 6.875q-.604 0-1.032.427a1.4 1.4 0 0 0-.426 1.031q0 .604.426 1.032.428.426 1.032.427m0 8.083q-.145 0-.292-.042a.7.7 0 0 1-.27-.145Q6.478 15 5.01 12.708 3.54 10.418 3.54 8.5q0-3.021 1.949-4.823T10 1.875t4.51 1.802q1.95 1.802 1.949 4.823 0 1.917-1.468 4.208-1.47 2.292-4.427 4.98a.7.7 0 0 1-.271.145 1 1 0 0 1-.292.042", fill: "#8C8C8C" })), autoComplete: 'no-auto-complete-' + randRef.current, rightSection: React__default.createElement(React__default.Fragment, null) }, form.getInputProps(name)))));
|
|
2017
1545
|
};
|
|
2018
1546
|
|
|
1547
|
+
const SubtitleBlock = ({ children, align, }) => (React__default.createElement("p", { className: `lead-modal__description ${'le-text-align-' + (align || '')} ${LEAD_CLASS}` }, children));
|
|
1548
|
+
|
|
2019
1549
|
const TitleBlock = ({ children, align, }) => (React__default.createElement("h2", { className: `lead-modal__title ${'le-text-align-' + (align || '')} ${LEAD_CLASS}` }, children));
|
|
2020
1550
|
|
|
2021
1551
|
const LightboxFields = ({ listBlockAdded, popupId, locale, onClose, onOtherSubmit, }) => {
|
|
2022
1552
|
const form = useLeadFormContext();
|
|
2023
|
-
const formValues = form.values;
|
|
2024
1553
|
return (React__default.createElement(React__default.Fragment, null, listBlockAdded.map((b, index) => {
|
|
2025
1554
|
var _a;
|
|
2026
1555
|
const { name = '', data = {} } = b || {};
|
|
2027
1556
|
const { placeholder, value, align, listQuestion, isSendMailChimp = false, newtab, url, } = data;
|
|
2028
1557
|
const required = (_a = data.required) !== null && _a !== void 0 ? _a : true;
|
|
2029
|
-
const formValue = (formValues === null || formValues === void 0 ? void 0 : formValues[value]) || null;
|
|
2030
1558
|
switch (name) {
|
|
2031
1559
|
case 'TitleBlock':
|
|
2032
1560
|
return (React__default.createElement(TitleBlock, { key: index, align: align }, value));
|
|
2033
1561
|
case 'SubtitleBlock':
|
|
2034
1562
|
return (React__default.createElement(SubtitleBlock, { key: index, align: align }, value));
|
|
2035
1563
|
case 'TextBlock':
|
|
2036
|
-
return (React__default.createElement(
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
// onChangeRaw={(e) => inputOnChange('text', e)}
|
|
2040
|
-
label: placeholder, "data-control": "text", name: value, inputWrapperOrder: ['label', 'input', 'description', 'error'] }, form.getInputProps(value)))));
|
|
1564
|
+
return (React__default.createElement(Input, Object.assign({ key: index, withAsterisk: required, spellCheck: false, type: "text", placeholder: placeholder, className: "lead-modal__form-control",
|
|
1565
|
+
// onChangeRaw={(e) => inputOnChange('text', e)}
|
|
1566
|
+
label: placeholder, "data-control": "text", name: value }, form.getInputProps(value))));
|
|
2041
1567
|
case 'NumberBlock':
|
|
2042
|
-
return (React__default.createElement(
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
// onChange={(e) => inputOnChange('number', e)}
|
|
2046
|
-
label: placeholder, "data-control": "number", name: value, inputWrapperOrder: ['label', 'input', 'description', 'error'] }, form.getInputProps(value)))));
|
|
1568
|
+
return (React__default.createElement(NumberInput, Object.assign({ key: index, withAsterisk: required, spellCheck: false, type: "number", placeholder: placeholder, className: "lead-modal__form-control",
|
|
1569
|
+
// onChange={(e) => inputOnChange('number', e)}
|
|
1570
|
+
label: placeholder, "data-control": "number", name: value }, form.getInputProps(value))));
|
|
2047
1571
|
case 'EmailBlock':
|
|
2048
|
-
return (React__default.createElement(
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
placeholder: placeholder,
|
|
2052
|
-
// className="lead-modal__form-control leadgen-form_field"
|
|
2053
|
-
label: placeholder, "data-control": "email", name: value, inputWrapperOrder: ['label', 'input', 'description', 'error'] }, form.getInputProps(value)))));
|
|
1572
|
+
return (React__default.createElement(Input, Object.assign({ key: index, withAsterisk: required, spellCheck: false,
|
|
1573
|
+
// type="email"
|
|
1574
|
+
placeholder: placeholder, className: "lead-modal__form-control", label: placeholder, "data-control": "email", name: value }, form.getInputProps(value))));
|
|
2054
1575
|
case 'PhoneOtpBlock':
|
|
2055
1576
|
case 'WhatsappOtpBlock':
|
|
2056
1577
|
case 'ZaloOtpBlock':
|
|
2057
1578
|
case 'PhoneBlock': {
|
|
2058
1579
|
const id = popupId + '-' + value + '-' + index;
|
|
2059
|
-
return (React__default.createElement(
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
},
|
|
2070
|
-
// onBlur={(e) => inputOnBlur('tel', e)}
|
|
2071
|
-
id: id, defaultCountry: (locale ? MAPPED_LOCALE[locale] || 'VN' : 'VN'), "data-control": "tel" })))));
|
|
1580
|
+
return (React__default.createElement(Input.Wrapper, Object.assign({ size: "md", withAsterisk: required, key: index, label: placeholder,
|
|
1581
|
+
// error={errorField.phone}
|
|
1582
|
+
className: "lead-modal__form-control", labelProps: {
|
|
1583
|
+
htmlFor: id,
|
|
1584
|
+
} }, form.getInputProps(value)),
|
|
1585
|
+
React__default.createElement(Phone, { name: value, spellCheck: false, type: "tel", placeholder: placeholder, onChange: (v) => {
|
|
1586
|
+
form.setFieldValue(value, v);
|
|
1587
|
+
},
|
|
1588
|
+
// onBlur={(e) => inputOnBlur('tel', e)}
|
|
1589
|
+
id: id, defaultCountry: (locale ? MAPPED_LOCALE[locale] || 'VN' : 'VN'), "data-control": "tel" })));
|
|
2072
1590
|
}
|
|
2073
1591
|
case 'LocationBlock': {
|
|
2074
|
-
return (React__default.createElement(
|
|
2075
|
-
React__default.createElement(GoogleLocation, Object.assign({ withAsterisk: required, key: index, name: value, placeholder: placeholder, label: placeholder, "data-control": "text", locale: locale, inputWrapperOrder: ['label', 'input', 'description', 'error'] }, form.getInputProps(value)))));
|
|
1592
|
+
return (React__default.createElement(LocationBlock, { key: index, name: value, placeholder: placeholder, locale: locale, required: required }));
|
|
2076
1593
|
}
|
|
2077
1594
|
case 'DateBlock':
|
|
2078
|
-
return (React__default.createElement(
|
|
2079
|
-
React__default.createElement(DatePicker, Object.assign({
|
|
2080
|
-
|
|
2081
|
-
children,
|
|
2082
|
-
React__default.createElement("input", { type: "hidden", "data-control": "date", name: value, value: formValue })));
|
|
2083
|
-
} }, form.getInputProps(value)))));
|
|
1595
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
1596
|
+
React__default.createElement(DatePicker, Object.assign({ withAsterisk: required, key: index, type: "default", name: value, placeholder: placeholder, className: "lead-modal__form-control", label: placeholder, "data-control": "date" }, form.getInputProps(value))),
|
|
1597
|
+
React__default.createElement("input", { type: "hidden", name: value, "data-control": "date" })));
|
|
2084
1598
|
case 'LinkButtonBlock':
|
|
2085
1599
|
return (React__default.createElement("div", { key: index },
|
|
2086
1600
|
React__default.createElement("a", { target: newtab ? 'blank' : 'parrent', href: url, style: { textDecoration: 'none' } },
|
|
@@ -2089,40 +1603,29 @@ const LightboxFields = ({ listBlockAdded, popupId, locale, onClose, onOtherSubmi
|
|
|
2089
1603
|
onOtherSubmit === null || onOtherSubmit === void 0 ? void 0 : onOtherSubmit();
|
|
2090
1604
|
} }, value))));
|
|
2091
1605
|
case 'CheckboxBlock':
|
|
2092
|
-
return (React__default.createElement(
|
|
1606
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
2093
1607
|
isSendMailChimp && (React__default.createElement("div", { style: {
|
|
2094
1608
|
display: 'none',
|
|
2095
1609
|
}, "data-name": value + '-mailchimp' })),
|
|
2096
|
-
React__default.createElement(Checkbox.Group, Object.assign({ withAsterisk: required,
|
|
2097
|
-
// className="lead-modal__form-control leadgen-form_field"
|
|
2098
|
-
key: index, label: placeholder, size: "md", sx: {
|
|
1610
|
+
React__default.createElement(Checkbox.Group, Object.assign({ withAsterisk: required, className: "lead-modal__form-control", key: index, label: placeholder, size: "md", sx: {
|
|
2099
1611
|
display: 'flex',
|
|
2100
1612
|
flexDirection: 'column',
|
|
2101
|
-
flexWrap: 'wrap',
|
|
2102
1613
|
gap: 8,
|
|
2103
|
-
}, inputWrapperOrder: ['label', 'input', 'description', 'error'], inputContainer: (children) => {
|
|
2104
|
-
return (React__default.createElement("div", { className: "leadgen-choiceContainer" }, children));
|
|
2105
1614
|
} }, form.getInputProps(value)), listQuestion.map((l, _index) => (React__default.createElement(Checkbox, { name: value, key: _index, value: l.value, label: l.placeholder, "data-control": "checkbox" }))))));
|
|
2106
1615
|
case 'RadioBlock':
|
|
2107
|
-
return (React__default.createElement(
|
|
2108
|
-
isSendMailChimp && (React__default.createElement(Input
|
|
2109
|
-
React__default.createElement(Radio.Group, Object.assign({ withAsterisk: required,
|
|
2110
|
-
// className="lead-modal__form-control leadgen-form_field"
|
|
2111
|
-
key: index, label: placeholder, size: "md", inputWrapperOrder: ['label', 'input', 'description', 'error'], inputContainer: (children) => {
|
|
2112
|
-
return (React__default.createElement("div", { className: "leadgen-choiceContainer" }, children));
|
|
2113
|
-
} }, form.getInputProps(value)), listQuestion.map((l, _index) => (React__default.createElement(Radio, { name: value, key: _index, value: l.value, label: l.placeholder, "data-control": "radio" }))))));
|
|
1616
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
1617
|
+
isSendMailChimp && (React__default.createElement(Input, { type: "hidden", name: value + '-mailchimp', value: isSendMailChimp })),
|
|
1618
|
+
React__default.createElement(Radio.Group, Object.assign({ withAsterisk: required, className: "lead-modal__form-control", key: index, label: placeholder, size: "md" }, form.getInputProps(value)), listQuestion.map((l, _index) => (React__default.createElement(Radio, { name: value, key: _index, value: l.value, label: l.placeholder, "data-control": "radio" }))))));
|
|
2114
1619
|
case 'DropdownBlock':
|
|
2115
|
-
return (React__default.createElement(
|
|
1620
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
2116
1621
|
React__default.createElement("div", { style: { display: 'none' }, "data-extra": true, "data-name": value, "data-control": 'dropdown' }),
|
|
2117
|
-
React__default.createElement(Select, Object.assign({ key: index,
|
|
2118
|
-
// className="lead-modal__form-control leadgen-form_field"
|
|
2119
|
-
label: placeholder, placeholder: placeholder, withAsterisk: required, name: value, data: listQuestion.map((l) => ({
|
|
1622
|
+
React__default.createElement(Select, Object.assign({ key: index, className: "lead-modal__form-control", label: placeholder, withAsterisk: required, name: value, data: listQuestion.map((l) => ({
|
|
2120
1623
|
value: l.value,
|
|
2121
1624
|
label: l.placeholder,
|
|
2122
1625
|
})) }, form.getInputProps(value)))));
|
|
2123
1626
|
case 'TncBlock':
|
|
2124
1627
|
const tncInputProps = form.getInputProps('TNC-' + b.id);
|
|
2125
|
-
return (React__default.createElement(
|
|
1628
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
2126
1629
|
React__default.createElement(Checkbox, Object.assign({ name: 'TNC-' + b.id, key: b.id, label: React__default.createElement("p", { className: "lead-modal__tnc-link", dangerouslySetInnerHTML: { __html: data.valueHTML } }), className: "tnc-block", "data-control": "checkbox" }, tncInputProps, { error: tncInputProps.error ? tncInputProps.error : undefined }))));
|
|
2127
1630
|
}
|
|
2128
1631
|
return null;
|
|
@@ -2254,27 +1757,169 @@ const OtpBlock = ({ otpData, onSuccess, autoSendWhenOpen, }) => {
|
|
|
2254
1757
|
})))));
|
|
2255
1758
|
};
|
|
2256
1759
|
|
|
2257
|
-
const
|
|
2258
|
-
const {
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
React__default.createElement("
|
|
1760
|
+
const ThankyouPopup = ({ title, titleAlign, subtitle, subtitleAlign, link, linkNewTab, linkText, image, }) => {
|
|
1761
|
+
const { width: imageWidth, height: imageHeight, loaded: imageLoaded, } = useImageSize(image);
|
|
1762
|
+
if (!imageLoaded)
|
|
1763
|
+
return null;
|
|
1764
|
+
return (React__default.createElement("div", { className: "lead-modal__thank-you" },
|
|
1765
|
+
React__default.createElement("div", { style: { width: '100%' } },
|
|
1766
|
+
React__default.createElement("img", { src: image, style: {
|
|
1767
|
+
maxHeight: 162,
|
|
1768
|
+
objectFit: 'cover',
|
|
1769
|
+
aspectRatio: `${imageWidth}/${imageHeight}`,
|
|
1770
|
+
}, loading: "lazy" }),
|
|
1771
|
+
title && (React__default.createElement("h1", { className: `le-thankyou-title le-text-align-${titleAlign}` }, title)),
|
|
1772
|
+
subtitle && (React__default.createElement("p", { className: `le-thankyou-subtitle le-text-align-${subtitleAlign}` }, subtitle.split('\n').map((text, idx, list) => {
|
|
1773
|
+
const isShowBr = idx < list.length - 1;
|
|
1774
|
+
return (React__default.createElement(React__default.Fragment, null,
|
|
1775
|
+
text,
|
|
1776
|
+
isShowBr && React__default.createElement("br", null)));
|
|
1777
|
+
}))),
|
|
1778
|
+
linkText && (React__default.createElement("div", null,
|
|
1779
|
+
React__default.createElement("a", { href: link, target: linkNewTab ? '_blank' : 'parrent', rel: "noreferrer" },
|
|
1780
|
+
React__default.createElement("button", { className: `lead-modal__btn ${LEAD_CLASS}` }, linkText)))))));
|
|
1781
|
+
};
|
|
1782
|
+
|
|
1783
|
+
const InlineLayout = ({ content, inlinePosition, }) => {
|
|
1784
|
+
const target = useMemo(() => {
|
|
1785
|
+
if (!inlinePosition)
|
|
1786
|
+
return null;
|
|
1787
|
+
const parents = document.querySelectorAll(`[data-url="${location.pathname}"] .body-content`);
|
|
1788
|
+
const allChildren = Array.from(parents).reduce((r, p) => {
|
|
1789
|
+
return [...r, ...Array.from(p.children)];
|
|
1790
|
+
}, []);
|
|
1791
|
+
if (allChildren === null || allChildren === void 0 ? void 0 : allChildren.length) {
|
|
1792
|
+
// find the third p tag in the body content, some other tags might mix in between
|
|
1793
|
+
const allPTags = allChildren.filter((c) => c.nodeName === 'P');
|
|
1794
|
+
const allH2Tags = allChildren.filter((c) => c.nodeName === 'H2');
|
|
1795
|
+
let target = null;
|
|
1796
|
+
switch (inlinePosition) {
|
|
1797
|
+
case '1th':
|
|
1798
|
+
target = allPTags[0];
|
|
1799
|
+
break;
|
|
1800
|
+
case '2th':
|
|
1801
|
+
target = allPTags[1];
|
|
1802
|
+
break;
|
|
1803
|
+
case '3th':
|
|
1804
|
+
target = allPTags[2];
|
|
1805
|
+
break;
|
|
1806
|
+
case '4th':
|
|
1807
|
+
target = allPTags[3];
|
|
1808
|
+
break;
|
|
1809
|
+
case '5th':
|
|
1810
|
+
target = allPTags[4];
|
|
1811
|
+
break;
|
|
1812
|
+
case '6th':
|
|
1813
|
+
target = allPTags[5];
|
|
1814
|
+
break;
|
|
1815
|
+
case '7th':
|
|
1816
|
+
target = allPTags[6];
|
|
1817
|
+
break;
|
|
1818
|
+
case '8th':
|
|
1819
|
+
target = allPTags[7];
|
|
1820
|
+
break;
|
|
1821
|
+
case '9th':
|
|
1822
|
+
target = allPTags[8];
|
|
1823
|
+
break;
|
|
1824
|
+
case '10th':
|
|
1825
|
+
target = allPTags[9];
|
|
1826
|
+
break;
|
|
1827
|
+
case '11th':
|
|
1828
|
+
target = allPTags[10];
|
|
1829
|
+
break;
|
|
1830
|
+
case '12th':
|
|
1831
|
+
target = allPTags[11];
|
|
1832
|
+
break;
|
|
1833
|
+
case 'lastP':
|
|
1834
|
+
target = allPTags[allPTags.length - 1];
|
|
1835
|
+
break;
|
|
1836
|
+
case '1thH2':
|
|
1837
|
+
target = allH2Tags[0];
|
|
1838
|
+
break;
|
|
1839
|
+
case '2thH2':
|
|
1840
|
+
target = allH2Tags[1];
|
|
1841
|
+
break;
|
|
1842
|
+
case '3thH2':
|
|
1843
|
+
target = allH2Tags[2];
|
|
1844
|
+
break;
|
|
1845
|
+
case '4thH2':
|
|
1846
|
+
target = allH2Tags[3];
|
|
1847
|
+
break;
|
|
1848
|
+
case '5thH2':
|
|
1849
|
+
target = allH2Tags[4];
|
|
1850
|
+
break;
|
|
1851
|
+
case '6thH2':
|
|
1852
|
+
target = allH2Tags[5];
|
|
1853
|
+
break;
|
|
1854
|
+
case '7thH2':
|
|
1855
|
+
target = allH2Tags[6];
|
|
1856
|
+
break;
|
|
1857
|
+
case '8thH2':
|
|
1858
|
+
target = allH2Tags[7];
|
|
1859
|
+
break;
|
|
1860
|
+
case '9thH2':
|
|
1861
|
+
target = allH2Tags[8];
|
|
1862
|
+
break;
|
|
1863
|
+
case '10thH2':
|
|
1864
|
+
target = allH2Tags[9];
|
|
1865
|
+
break;
|
|
1866
|
+
case 'lastH2':
|
|
1867
|
+
target = allH2Tags[allH2Tags.length - 1];
|
|
1868
|
+
break;
|
|
1869
|
+
}
|
|
1870
|
+
if (target) {
|
|
1871
|
+
if (!target.parentElement.querySelector('.inline-lead-wrapper')) {
|
|
1872
|
+
const wrapper = document.createElement('div');
|
|
1873
|
+
wrapper.classList.add('inline-lead-wrapper');
|
|
1874
|
+
if (target.nextElementSibling) {
|
|
1875
|
+
target.parentElement.insertBefore(wrapper, target.nextElementSibling);
|
|
1876
|
+
}
|
|
1877
|
+
else {
|
|
1878
|
+
target.parentElement.appendChild(wrapper);
|
|
1879
|
+
}
|
|
1880
|
+
return wrapper;
|
|
1881
|
+
}
|
|
1882
|
+
else {
|
|
1883
|
+
return target.parentElement.querySelector('.inline-lead-wrapper');
|
|
1884
|
+
}
|
|
1885
|
+
}
|
|
1886
|
+
}
|
|
1887
|
+
}, [inlinePosition]);
|
|
1888
|
+
if (!inlinePosition || !target)
|
|
1889
|
+
return null;
|
|
1890
|
+
return createPortal(content, target);
|
|
1891
|
+
};
|
|
1892
|
+
|
|
1893
|
+
const SideBarLayout = ({ content }) => {
|
|
1894
|
+
const targets = useMemo(() => {
|
|
1895
|
+
const targetDoms = Array.from(document.querySelectorAll('.hc2-sidebar-with-ads,.page-main-col .right-col.f-right,.hhg-lead-sidebar'));
|
|
1896
|
+
targetDoms.forEach((dom) => {
|
|
1897
|
+
if (dom.querySelector('.sidebar-lead-modal-wrapper'))
|
|
1898
|
+
return;
|
|
1899
|
+
const wrapper = document.createElement('div');
|
|
1900
|
+
wrapper.classList.add('sidebar-lead-modal-wrapper');
|
|
1901
|
+
dom.prepend(wrapper);
|
|
1902
|
+
});
|
|
1903
|
+
return targetDoms.map((d) => d.querySelector('.sidebar-lead-modal-wrapper'));
|
|
1904
|
+
}, []);
|
|
1905
|
+
return (React__default.createElement(React__default.Fragment, null, targets.map((target) => createPortal(content, getWrapperDomWithSelector(target, 'sidebar-lead-modal-wrapper')))));
|
|
2263
1906
|
};
|
|
2264
1907
|
|
|
2265
1908
|
// url: imageBlocks.imageMobile.data.url
|
|
2266
1909
|
// newTab: imageBlocks.imageMobile.data.newtab
|
|
2267
1910
|
// image: campaignShow.image
|
|
2268
1911
|
// imageDestkop: campaignShow.image_desktop
|
|
2269
|
-
const
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
const
|
|
2273
|
-
const
|
|
2274
|
-
const
|
|
1912
|
+
const LightboxLayout = ({ popupId, extraFields, onClose: onCloseProp, onOtherSubmit, imageMobile, imageDesktop, imageOverlayMobile, imageOverlayDesktop, imageBackground, currentLayout, title, onSubmit, showThankyou, campaignId, campaign_subot_id, locale, }) => {
|
|
1913
|
+
var _a, _b, _c;
|
|
1914
|
+
const listBlockAdded = JSON.parse(extraFields.listBlockAdded);
|
|
1915
|
+
const actionBlocks = JSON.parse(extraFields.actionBlocks);
|
|
1916
|
+
const textBlocks = JSON.parse(extraFields.textBlocks);
|
|
1917
|
+
const popUpSubmitText = actionBlocks.submitBlock.data.value;
|
|
1918
|
+
const currentPath = location.pathname;
|
|
1919
|
+
const isInPage = currentLayout.includes('Inline') || currentLayout === 'Sidebar';
|
|
1920
|
+
const isSlider = currentLayout === 'Slider';
|
|
2275
1921
|
const [showOtpPhone, setShowOtpPhone] = useState(null);
|
|
2276
1922
|
const [isSubmitLoading, setIsSubmitLoading] = useState(false);
|
|
2277
|
-
const [snap, setSnap] = useState(0.8);
|
|
2278
1923
|
const formRef = useRef();
|
|
2279
1924
|
const onClose = () => {
|
|
2280
1925
|
if (showOtpPhone) {
|
|
@@ -2284,17 +1929,6 @@ const LightboxLayout = ({ popupId, extraFields, onClose: onCloseProp, onOtherSub
|
|
|
2284
1929
|
onCloseProp === null || onCloseProp === void 0 ? void 0 : onCloseProp();
|
|
2285
1930
|
}
|
|
2286
1931
|
};
|
|
2287
|
-
const listBlockAdded = JSON.parse(extraFields.listBlockAdded);
|
|
2288
|
-
const actionBlocks = JSON.parse(extraFields.actionBlocks);
|
|
2289
|
-
const textBlocks = JSON.parse(extraFields.textBlocks);
|
|
2290
|
-
const popUpSubmitText = actionBlocks.submitBlock.data.value;
|
|
2291
|
-
const currentPath = location.pathname;
|
|
2292
|
-
const isInPage = currentLayout.includes('Inline') || currentLayout === 'Sidebar';
|
|
2293
|
-
const isSlider = currentLayout === 'Slider';
|
|
2294
|
-
const isDrawer = currentLayout.includes('LightBoxB') && isMobile;
|
|
2295
|
-
const isLightBox = useMemo(() => !!currentLayout.includes('LightBox'), [currentLayout]);
|
|
2296
|
-
const isSmallLightBoxB = currentLayout === 'LightBoxB' &&
|
|
2297
|
-
listBlockAdded.length <= LEADGEN_LIMIT_LIGHTBOXB;
|
|
2298
1932
|
if (window.innerWidth < 769 &&
|
|
2299
1933
|
['Fullscreen', 'Slider'].includes(currentLayout)) {
|
|
2300
1934
|
console.log('😎 Not show fullscreen, slider on mobile ');
|
|
@@ -2385,134 +2019,83 @@ const LightboxLayout = ({ popupId, extraFields, onClose: onCloseProp, onOtherSub
|
|
|
2385
2019
|
})(e);
|
|
2386
2020
|
}, 100);
|
|
2387
2021
|
};
|
|
2388
|
-
const onOpenChange = (_open) => {
|
|
2389
|
-
setOpen(_open);
|
|
2390
|
-
if (!_open) {
|
|
2391
|
-
setTimeout(() => {
|
|
2392
|
-
onClose();
|
|
2393
|
-
}, 250);
|
|
2394
|
-
}
|
|
2395
|
-
};
|
|
2396
2022
|
const { width: imageBackgroundWidth, height: imageBackgroundHeight, loaded: imageBackgroundLoaded, } = useImageSize(imageBackground);
|
|
2397
2023
|
const { width: imageMobileWidth, height: imageMobileHeight, loaded: imageMobileLoaded, } = useImageSize(imageMobile);
|
|
2398
2024
|
const { width: imageDesktopWidth, height: imageDesktopHeight, loaded: imageDesktopLoaded, } = useImageSize(imageDesktop);
|
|
2399
2025
|
const renderAfterImageSizes = imageMobileLoaded &&
|
|
2400
2026
|
imageDesktopLoaded &&
|
|
2401
2027
|
(currentLayout == 'Fullscreen' ? imageBackgroundLoaded : true);
|
|
2402
|
-
const
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
}, src: imageDesktop, alt: "" }))) : null,
|
|
2426
|
-
imageMobile ? (isVideo(imageMobile) ? (React__default.createElement("video", { className: "le-only-mobile lead-modal__image lead-modal-image-cover", muted: true, autoPlay: true, loop: true },
|
|
2427
|
-
React__default.createElement("source", { src: imageMobile, type: "video/mp4" }))) : (React__default.createElement("img", { draggable: "false", className: "le-only-mobile lead-modal__image lead-modal-image-cover", src: imageMobile, alt: "", style: {
|
|
2428
|
-
aspectRatio: `${imageMobileWidth}/${imageMobileHeight}`,
|
|
2429
|
-
} }))) : null))))));
|
|
2430
|
-
const PopupEmpty = showEmpty && (React__default.createElement("div", { className: "leadgen-empty" },
|
|
2431
|
-
React__default.createElement("div", { className: "leadgen-empty_body" },
|
|
2432
|
-
React__default.createElement("div", { className: "leadgen-empty_wrapper" },
|
|
2433
|
-
React__default.createElement(EmptyIcon, { className: "leadgen-empty_image" }),
|
|
2434
|
-
React__default.createElement("h5", { className: "leadgen-empty_title" }, t('lead.empty.title')))),
|
|
2435
|
-
React__default.createElement("div", { className: "leadgen-empty_footer" },
|
|
2436
|
-
React__default.createElement(Button$2, { onClick: onClose, size: "lg", variant: "default", fullWidth: false, className: "leadgen-btn leadgen-btn_empty_cancel" }, t('lead.empty.cancel')),
|
|
2437
|
-
React__default.createElement(Button$2, { onClick: () => setShowEmpty(false), size: "lg", variant: "filled", fullWidth: false, className: "leadgen-btn leadgen-btn_empty_again" }, t('lead.empty.submitAgain')))));
|
|
2438
|
-
const PopupFormTitle = (React__default.createElement("h2", { title: title, className: clsx(LEAD_CLASS, `lead-modal__title`, `le-text-align-${(_f = textBlocks.titleBlock.data) === null || _f === void 0 ? void 0 : _f.align}`, { 'leadgen-title': isLightBox }) }, title));
|
|
2439
|
-
const PopupFormDescription = (React__default.createElement("p", { title: textBlocks.subtitleBlock.data.value, className: clsx(LEAD_CLASS, `lead-modal__description`, `le-text-align-${(_g = textBlocks.subtitleBlock.data) === null || _g === void 0 ? void 0 : _g.align}`, { 'leadgen-description': isLightBox }) }, textBlocks.subtitleBlock.data.value));
|
|
2440
|
-
const PopupForm = (React__default.createElement(LeadFormProvider, { form: form },
|
|
2441
|
-
React__default.createElement("form", { ref: formRef, className: clsx(`lead-modal__form ${popupId}`, {
|
|
2442
|
-
'leadgen-form': isLightBox,
|
|
2443
|
-
}), onSubmit: middlewareOnSubmit },
|
|
2444
|
-
React__default.createElement("div", { className: clsx('lead-modal__form-header', {
|
|
2445
|
-
'leadgen-form_header': isLightBox,
|
|
2446
|
-
}) },
|
|
2447
|
-
PopupFormTitle,
|
|
2448
|
-
PopupFormDescription),
|
|
2449
|
-
React__default.createElement("div", { className: clsx('lead-modal__form-control-wrapper', {
|
|
2450
|
-
'leadgen-form_body': isLightBox,
|
|
2451
|
-
}) },
|
|
2452
|
-
React__default.createElement("div", { className: "leadgen-form_inner" },
|
|
2453
|
-
React__default.createElement(LightboxFields, { listBlockAdded: listBlockAdded, popupId: popupId, locale: locale, onClose: onClose, onOtherSubmit: onOtherSubmit }))),
|
|
2454
|
-
React__default.createElement("div", { className: "leadgen-form_footer" }, currentLayout.includes('LightBoxA') ? ButtonLink : ButtonSubmit))));
|
|
2455
|
-
const PopupThankYou = showThankyou && (React__default.createElement(ThankyouPopup, { title: showThankyou.title, titleAlign: showThankyou.titleAlign, subtitle: showThankyou.subtitle, subtitleAlign: showThankyou.subtitleAlign, link: showThankyou.link, linkNewTab: showThankyou.linkNewTab, linkText: showThankyou.linkText, image: showThankyou.image }));
|
|
2456
|
-
const popupContentClassName = clsx('lead-modal__content', `le-newbuilder-${currentLayout}`, 'leadPopupContent', { 'leadgen-content': isLightBox });
|
|
2457
|
-
const PopupContent = (React__default.createElement("div", { className: popupContentClassName },
|
|
2458
|
-
PopupHeader,
|
|
2459
|
-
React__default.createElement("div", { className: "leadgen-inner" },
|
|
2460
|
-
PopupThankYou,
|
|
2461
|
-
!showThankyou && (React__default.createElement(React__default.Fragment, null,
|
|
2462
|
-
showOtpPhone && (React__default.createElement(OtpBlock, { otpData: showOtpPhone, autoSendWhenOpen: false, onSuccess: () => {
|
|
2463
|
-
setShowOtpPhone(null);
|
|
2464
|
-
onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(formRef.current, form.values);
|
|
2465
|
-
} })),
|
|
2466
|
-
showEmpty && PopupEmpty,
|
|
2467
|
-
React__default.createElement("div", { "data-hidden": !!showOtpPhone || !!showEmpty, className: clsx('lead-modal__body le-newbuilder-overlay', {
|
|
2468
|
-
'leadgen-body': isLightBox,
|
|
2469
|
-
}) }, PopupForm))))));
|
|
2470
|
-
const PopupWrapper = (React__default.createElement("div", { className: clsx(`lead-modal__wrapper le-newbuilder-wrap-${currentLayout}`, {
|
|
2471
|
-
'leadgen-wrapper': isLightBox,
|
|
2472
|
-
'leadgen-wrapper_small': isSmallLightBoxB,
|
|
2473
|
-
}) },
|
|
2474
|
-
!currentLayout.includes('Inline') && (React__default.createElement(CloseButton, { onClose: () => onOpenChange(false), containerClassName: clsx('close-button-top-right', {
|
|
2475
|
-
'leadgen-close_btn': isLightBox,
|
|
2476
|
-
}) })),
|
|
2477
|
-
PopupContent));
|
|
2478
|
-
const styleOverlay = useMemo(() => {
|
|
2479
|
-
let styleContent = `.le-newbuilder-overlay {background-repeat: no-repeat;background-size: cover;background-position:center;}`;
|
|
2480
|
-
if (isMobile && imageOverlayMobile) {
|
|
2481
|
-
styleContent += `.le-newbuilder-overlay {background-image: url(${imageOverlayMobile});}`;
|
|
2482
|
-
}
|
|
2483
|
-
if (!isMobile && imageOverlayDesktop) {
|
|
2484
|
-
styleContent += `@media screen and (min-width:768px) {.le-newbuilder-overlay {background-image: url(${imageOverlayDesktop});}}`;
|
|
2485
|
-
}
|
|
2486
|
-
return styleContent;
|
|
2487
|
-
}, [isMobile, imageOverlayDesktop, imageOverlayMobile]);
|
|
2488
|
-
const popupContainerClassName = clsx('lead-modal lead-modal-wrapper modal--animate-scale', {
|
|
2489
|
-
'le-buider-inline': !!isInPage,
|
|
2490
|
-
'le-buider-slider': !!isSlider,
|
|
2491
|
-
leadgen: isLightBox,
|
|
2492
|
-
[`leadgen-${currentLayout}`]: isLightBox,
|
|
2493
|
-
});
|
|
2494
|
-
const PopupContainer = isDrawer ? (React__default.createElement(DrawerComponent, { open: open, snapPoints: [0.8, 1], activeSnapPoint: snap, setActiveSnapPoint: setSnap, onOpenChange: onOpenChange, overlayClassName: popupContainerClassName, className: "leadgen-drawer" },
|
|
2495
|
-
React__default.createElement("style", { dangerouslySetInnerHTML: { __html: styleOverlay } }),
|
|
2496
|
-
PopupWrapper,
|
|
2497
|
-
React__default.createElement("div", { className: "", style: { position: 'absolute', inset: 0, zIndex: snap === 1 ? -1 : 1 }, onClick: () => setSnap(1) }))) : (React__default.createElement(React__default.Fragment, null,
|
|
2498
|
-
React__default.createElement("style", { dangerouslySetInnerHTML: { __html: styleOverlay } }),
|
|
2499
|
-
React__default.createElement("div", { id: popupId, "data-popup-url": currentPath, "data-popup-type": "lightbox-inline", className: popupContainerClassName },
|
|
2028
|
+
const PopupContent = (React__default.createElement(React__default.Fragment, null,
|
|
2029
|
+
React__default.createElement("style", { dangerouslySetInnerHTML: {
|
|
2030
|
+
__html: `
|
|
2031
|
+
.le-newbuilder-overlay {
|
|
2032
|
+
background-repeat: no-repeat;
|
|
2033
|
+
background-size: cover;
|
|
2034
|
+
}
|
|
2035
|
+
${imageOverlayMobile
|
|
2036
|
+
? `
|
|
2037
|
+
.le-newbuilder-overlay {
|
|
2038
|
+
background: url(${imageOverlayMobile}) ;
|
|
2039
|
+
}`
|
|
2040
|
+
: ``}
|
|
2041
|
+
${imageOverlayDesktop
|
|
2042
|
+
? `
|
|
2043
|
+
@media screen and (min-width:768px) {
|
|
2044
|
+
.le-newbuilder-overlay {
|
|
2045
|
+
background: url(${imageOverlayDesktop}) ;
|
|
2046
|
+
}
|
|
2047
|
+
}`
|
|
2048
|
+
: ``}`,
|
|
2049
|
+
} }),
|
|
2050
|
+
React__default.createElement("div", { id: popupId, "data-popup-url": currentPath, "data-popup-type": "lightbox-inline", className: `lead-modal lead-modal-wrapper modal--animate-scale ${isInPage ? 'le-buider-inline' : ''} ${isSlider ? 'le-buider-slider' : ''}` },
|
|
2500
2051
|
currentLayout == 'Fullscreen' ? (React__default.createElement("img", { className: "le-only-desktop le-fullscreen-img", draggable: false, src: imageBackground || '', style: {
|
|
2501
2052
|
aspectRatio: `${imageBackgroundWidth}/${imageBackgroundHeight}`,
|
|
2502
2053
|
} })) : null,
|
|
2503
|
-
|
|
2054
|
+
React__default.createElement("div", { className: `lead-modal__wrapper le-newbuilder-wrap-${currentLayout}` },
|
|
2055
|
+
React__default.createElement("div", { className: `lead-modal__content le-newbuilder-${currentLayout}` }, showThankyou ? (React__default.createElement(ThankyouPopup, { title: showThankyou.title, titleAlign: showThankyou.titleAlign, subtitle: showThankyou.subtitle, subtitleAlign: showThankyou.subtitleAlign, link: showThankyou.link, linkNewTab: showThankyou.linkNewTab, linkText: showThankyou.linkText, image: showThankyou.image })) : (React__default.createElement(React__default.Fragment, null,
|
|
2056
|
+
React__default.createElement("header", { className: "lead-modal__header" }, showOtpPhone ? (React__default.createElement("img", { src: CommonGAssets.getAssetPath('lead-otp-thumb.png'), draggable: "false", alt: "", style: {
|
|
2057
|
+
width: '100%',
|
|
2058
|
+
minHeight: '150px',
|
|
2059
|
+
backgroundColor: '#f2f2f2',
|
|
2060
|
+
}, loading: "lazy" })) : (React__default.createElement(React__default.Fragment, null, ['LightBoxA', 'InlineA', 'Sidebar', 'Slider'].includes(currentLayout) ? (imageMobile ? (isVideo(imageMobile) ? (React__default.createElement("video", { className: "lead-modal__image lead-modal-image-cover", muted: true, autoPlay: true, loop: true },
|
|
2061
|
+
React__default.createElement("source", { src: imageMobile, type: "video/mp4" }))) : (React__default.createElement("img", { draggable: "false", className: "lead-modal__image lead-modal-image-cover", src: imageMobile, style: {
|
|
2062
|
+
aspectRatio: `${imageMobileWidth}/${imageMobileHeight}`,
|
|
2063
|
+
}, alt: "" }))) : null) : (React__default.createElement(React__default.Fragment, null,
|
|
2064
|
+
imageDesktop ? (isVideo(imageDesktop) ? (React__default.createElement("video", { className: "le-only-desktop lead-modal__image lead-modal-image-cover", muted: true, autoPlay: true, loop: true },
|
|
2065
|
+
React__default.createElement("source", { src: imageDesktop, type: "video/mp4" }))) : (React__default.createElement("img", { draggable: "false", className: "le-only-desktop lead-modal__image lead-modal-image-cover", style: {
|
|
2066
|
+
objectFit: 'cover',
|
|
2067
|
+
aspectRatio: `${imageDesktopWidth}/${imageDesktopHeight}`,
|
|
2068
|
+
}, src: imageDesktop, alt: "" }))) : null,
|
|
2069
|
+
imageMobile ? (isVideo(imageMobile) ? (React__default.createElement("video", { className: "le-only-mobile lead-modal__image lead-modal-image-cover", muted: true, autoPlay: true, loop: true },
|
|
2070
|
+
React__default.createElement("source", { src: imageMobile, type: "video/mp4" }))) : (React__default.createElement("img", { draggable: "false", className: "le-only-mobile lead-modal__image lead-modal-image-cover", src: imageMobile, alt: "", style: {
|
|
2071
|
+
aspectRatio: `${imageMobileWidth}/${imageMobileHeight}`,
|
|
2072
|
+
} }))) : null))))),
|
|
2073
|
+
showOtpPhone && (React__default.createElement(OtpBlock, { otpData: showOtpPhone, autoSendWhenOpen: false, onSuccess: () => {
|
|
2074
|
+
setShowOtpPhone(null);
|
|
2075
|
+
onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(formRef.current, form.values);
|
|
2076
|
+
} })),
|
|
2077
|
+
React__default.createElement("div", { "data-hidden": !!showOtpPhone, className: "lead-modal__body le-newbuilder-overlay" },
|
|
2078
|
+
React__default.createElement(LeadFormProvider, { form: form },
|
|
2079
|
+
React__default.createElement("form", { ref: formRef, className: `lead-modal__form ${popupId}`, onSubmit: middlewareOnSubmit },
|
|
2080
|
+
React__default.createElement("div", { style: { marginBottom: 20 } },
|
|
2081
|
+
React__default.createElement("h2", { className: `lead-modal__title ${'le-text-align-' + ((_a = textBlocks.titleBlock.data) === null || _a === void 0 ? void 0 : _a.align)} ${LEAD_CLASS}` }, title),
|
|
2082
|
+
React__default.createElement("p", { className: `lead-modal__description ${'le-text-align-' + ((_b = textBlocks.titleBlock.data) === null || _b === void 0 ? void 0 : _b.align)} ${LEAD_CLASS}` }, textBlocks.subtitleBlock.data.value)),
|
|
2083
|
+
React__default.createElement("div", { className: "lead-modal__form-control-wrapper" },
|
|
2084
|
+
React__default.createElement(LightboxFields, { listBlockAdded: listBlockAdded, popupId: popupId, locale: locale, onClose: onClose, onOtherSubmit: onOtherSubmit })),
|
|
2085
|
+
((_c = actionBlocks === null || actionBlocks === void 0 ? void 0 : actionBlocks.submitBlock) === null || _c === void 0 ? void 0 : _c.isHide) ? null : (React__default.createElement(Button, { size: "md", id: "lead-submit", type: "submit", className: `lead-modal__btn ${LEAD_CLASS}`, isLoading: isSubmitLoading }, popUpSubmitText)))))))),
|
|
2086
|
+
!currentLayout.includes('Inline') && (React__default.createElement(CloseButton, { onClose: onClose, containerClassName: "close-button-top-right" }))))));
|
|
2504
2087
|
if (!renderAfterImageSizes)
|
|
2505
2088
|
return null;
|
|
2506
2089
|
if (currentLayout.includes('LightBox') ||
|
|
2507
2090
|
currentLayout == 'Fullscreen' ||
|
|
2508
2091
|
currentLayout == 'Slider') {
|
|
2509
|
-
return
|
|
2092
|
+
return PopupContent;
|
|
2510
2093
|
}
|
|
2511
2094
|
else if (currentLayout == 'Sidebar') {
|
|
2512
|
-
return React__default.createElement(SideBarLayout, { content:
|
|
2095
|
+
return React__default.createElement(SideBarLayout, { content: PopupContent });
|
|
2513
2096
|
}
|
|
2514
2097
|
else if (currentLayout.includes('Inline')) {
|
|
2515
|
-
return (React__default.createElement(InlineLayout, { content:
|
|
2098
|
+
return (React__default.createElement(InlineLayout, { content: PopupContent, inlinePosition: extraFields.popupInlinePosition }));
|
|
2516
2099
|
}
|
|
2517
2100
|
return null;
|
|
2518
2101
|
};
|
|
@@ -2957,7 +2540,7 @@ function getCategoryLevel(t = 'Xin chao {{category_2}} extra') {
|
|
|
2957
2540
|
return null;
|
|
2958
2541
|
}
|
|
2959
2542
|
}
|
|
2960
|
-
const NewLeadPopup = ({ campaign, action, onSubmit, onClose, showThankyou, locale,
|
|
2543
|
+
const NewLeadPopup = ({ campaign, action, onSubmit, onClose, showThankyou, locale, }) => {
|
|
2961
2544
|
var _a, _b;
|
|
2962
2545
|
const { apiUrl, siteDomain } = useContext(LeadGenContext);
|
|
2963
2546
|
useEffect(() => {
|
|
@@ -3076,7 +2659,7 @@ const NewLeadPopup = ({ campaign, action, onSubmit, onClose, showThankyou, local
|
|
|
3076
2659
|
currentLayout == 'Fullscreen' ||
|
|
3077
2660
|
currentLayout == 'Sidebar' ||
|
|
3078
2661
|
currentLayout == 'Slider') {
|
|
3079
|
-
return (React__default.createElement(LightboxLayout, { popupId: popupIdRef.current, extraFields: extra_fields, onClose: onClose, onOtherSubmit: onOtherSubmit, imageMobile: image, imageDesktop: image_desktop, imageBackground: image_background, currentLayout: currentLayout, title: titleText, onSubmit: (form, values) => onSubmit(form, values, categoryLevel, categoryData), key: currentLayout, imageOverlayDesktop: image_overlay_desktop, imageOverlayMobile: image_overlay_mobile, showThankyou: showThankyou, campaignId: campaign.id, campaign_subot_id: campaign.bot_id || [], locale: locale
|
|
2662
|
+
return (React__default.createElement(LightboxLayout, { popupId: popupIdRef.current, extraFields: extra_fields, onClose: onClose, onOtherSubmit: onOtherSubmit, imageMobile: image, imageDesktop: image_desktop, imageBackground: image_background, currentLayout: currentLayout, title: titleText, onSubmit: (form, values) => onSubmit(form, values, categoryLevel, categoryData), key: currentLayout, imageOverlayDesktop: image_overlay_desktop, imageOverlayMobile: image_overlay_mobile, showThankyou: showThankyou, campaignId: campaign.id, campaign_subot_id: campaign.bot_id || [], locale: locale }));
|
|
3080
2663
|
}
|
|
3081
2664
|
else if (currentLayout.includes('Skin')) {
|
|
3082
2665
|
return (React__default.createElement(SkinLayout, { popupId: popupIdRef.current, link: actionBlocks.linkButtonBlock.data.url, linkNewTab: !!actionBlocks.linkButtonBlock.data.newtab, linkText: actionBlocks.linkButtonBlock.data.value, onClose: onClose, onOtherSubmit: onOtherSubmit, imageMobile: image, imageDesktop: image_desktop, currentLayout: currentLayout }));
|
|
@@ -3101,7 +2684,6 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3101
2684
|
const [showCampaign, setShowCampaign] = useState(forceCampaign);
|
|
3102
2685
|
const [action, setAction] = useState('');
|
|
3103
2686
|
const [showThankyou, setShowThankyou] = useState(null);
|
|
3104
|
-
const [showEmpty, setShowEmpty] = useState(false);
|
|
3105
2687
|
useEffect(() => {
|
|
3106
2688
|
if (forceCampaign) {
|
|
3107
2689
|
setShowCampaign(forceCampaign);
|
|
@@ -3117,11 +2699,6 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3117
2699
|
setShowCampaign(campaign);
|
|
3118
2700
|
setAction(action);
|
|
3119
2701
|
};
|
|
3120
|
-
const onCloseBase = () => {
|
|
3121
|
-
document.body.classList.remove('noscroll');
|
|
3122
|
-
setShowCampaign(null);
|
|
3123
|
-
setShowThankyou(null);
|
|
3124
|
-
};
|
|
3125
2702
|
const onClose = () => {
|
|
3126
2703
|
var _a, _b;
|
|
3127
2704
|
if (!showCampaign)
|
|
@@ -3139,6 +2716,7 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3139
2716
|
}
|
|
3140
2717
|
}
|
|
3141
2718
|
}
|
|
2719
|
+
document.body.classList.remove('noscroll');
|
|
3142
2720
|
fetch(`${apiUrl}api/campaign/${showCampaign.code}/popup_exit`, {
|
|
3143
2721
|
method: 'POST',
|
|
3144
2722
|
headers: {
|
|
@@ -3152,7 +2730,8 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3152
2730
|
duration: Math.ceil((Date.now() - leadStartTimeRef.current) / 1000),
|
|
3153
2731
|
}),
|
|
3154
2732
|
});
|
|
3155
|
-
|
|
2733
|
+
setShowCampaign(null);
|
|
2734
|
+
setShowThankyou(null);
|
|
3156
2735
|
}; //
|
|
3157
2736
|
useEffect(() => {
|
|
3158
2737
|
if (forceCampaign === null || forceCampaign === void 0 ? void 0 : forceCampaign.code)
|
|
@@ -3194,10 +2773,8 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3194
2773
|
}, []);
|
|
3195
2774
|
const onSubmit = (currentForm, formDataObj, categoryLevel, categoryData) => __awaiter(void 0, void 0, void 0, function* () {
|
|
3196
2775
|
var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
3197
|
-
if (!formDataObj
|
|
3198
|
-
setShowEmpty(true);
|
|
2776
|
+
if (!formDataObj)
|
|
3199
2777
|
return;
|
|
3200
|
-
}
|
|
3201
2778
|
LeadLog('submitHandler', categoryLevel, categoryData);
|
|
3202
2779
|
const formData = Object.keys(formDataObj)
|
|
3203
2780
|
.filter((key) => !!formDataObj[key])
|
|
@@ -3205,7 +2782,6 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3205
2782
|
name: key,
|
|
3206
2783
|
value: String(formDataObj[key]),
|
|
3207
2784
|
}));
|
|
3208
|
-
console.log('** RYAN index.tsx 218 formData : ', formData);
|
|
3209
2785
|
const numberFormatType = 2; // i18n.phonenumbers.PhoneNumberFormat.NATIONAL
|
|
3210
2786
|
// Get ga_client_id from cookies
|
|
3211
2787
|
const gaCookie = getCookie('_ga') || null;
|
|
@@ -3353,15 +2929,18 @@ const _LeadGen = ({ apiUrl: apiUrlProp, siteDomain, siteId, locale, apiSubotUrl,
|
|
|
3353
2929
|
}
|
|
3354
2930
|
}, [showCampaign]);
|
|
3355
2931
|
return (React__default.createElement(LeadGenContext.Provider, { value: { apiUrl, siteDomain, siteId, locale } },
|
|
3356
|
-
React__default.createElement(TranslationsContext.Provider, { value: {
|
|
2932
|
+
React__default.createElement(TranslationsContext.Provider, { value: {
|
|
2933
|
+
locale,
|
|
2934
|
+
values: getTranslations(locale),
|
|
2935
|
+
} }, children ? (React__default.createElement(Component, { campaign: showCampaign, onSubmit: onSubmit, onClose: onClose, showThankyou: showThankyou, setShowThankyou: setShowThankyou, locale: locale }, children)) : (React__default.createElement(Portal, { target: getPopupWrapperDom() },
|
|
3357
2936
|
React__default.createElement(Box, { sx: { position: 'fixed', zIndex: ZINDEX_SSO - 9e6 } },
|
|
3358
2937
|
React__default.createElement(Transition, { mounted: Boolean(((_a = showCampaign === null || showCampaign === void 0 ? void 0 : showCampaign.extra_fields) === null || _a === void 0 ? void 0 : _a.popupVersion) === '2.1'), transition: "fade", duration: 600, timingFunction: "ease" }, (styles) => {
|
|
3359
2938
|
var _a;
|
|
3360
2939
|
return (React__default.createElement(Box, { style: styles }, ((_a = showCampaign === null || showCampaign === void 0 ? void 0 : showCampaign.extra_fields) === null || _a === void 0 ? void 0 : _a.popupVersion) === '2.1' && (React__default.createElement(React__default.Fragment, null,
|
|
3361
2940
|
!!showCampaign.extra_fields.currentLayout &&
|
|
3362
2941
|
!showCampaign.extra_fields.currentLayout.includes('Inline') &&
|
|
3363
|
-
!showCampaign.extra_fields.currentLayout.includes('Sidebar') && (React__default.createElement(Overlay, { color: "#000", opacity: 0.
|
|
3364
|
-
React__default.createElement(NewLeadPopup, { campaign: showCampaign, action: action, onSubmit: onSubmit, onClose: onClose, showThankyou: showThankyou, locale: locale
|
|
2942
|
+
!showCampaign.extra_fields.currentLayout.includes('Sidebar') && (React__default.createElement(Overlay, { color: "#000", opacity: 0.5, center: true, zIndex: 400, pos: 'fixed', onClick: () => onClose() })),
|
|
2943
|
+
React__default.createElement(NewLeadPopup, { campaign: showCampaign, action: action, onSubmit: onSubmit, onClose: onClose, showThankyou: showThankyou, locale: locale })))));
|
|
3365
2944
|
})))))));
|
|
3366
2945
|
};
|
|
3367
2946
|
const LeadGen = _LeadGen;
|