@hhgtech/hhg-components 1.27.86 → 1.27.88
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/babyGrowth.js +2 -2
- package/build/cache.js +1 -1
- package/build/care/components/organisms/bookingSearchBarV2/reducer.d.ts +2 -2
- package/build/care.js +1 -1
- package/build/components.js +1 -1
- package/build/constants.js +1 -1
- package/build/{core-cd5cd796.js → core-944714e2.js} +1 -1
- package/build/{dataTransform-78ae8b8c.js → dataTransform-5bb8c118.js} +1 -1
- package/build/ecom.js +1 -1
- package/build/esm/babyGrowth.js +4 -4
- package/build/esm/cache.js +1 -1
- package/build/esm/care/components/organisms/bookingSearchBarV2/reducer.d.ts +2 -2
- package/build/esm/care.js +1 -1
- package/build/esm/components.js +1 -1
- package/build/esm/constants.js +1 -1
- package/build/esm/{core-1cee131e.js → core-b554a99b.js} +1 -1
- package/build/esm/{dataTransform-32d90a04.js → dataTransform-fba1eda1.js} +1 -1
- package/build/esm/ecom.js +1 -1
- package/build/esm/{fixedBottomAdBlock-de8db8c6.js → fixedBottomAdBlock-7507cfcb.js} +1 -1
- package/build/esm/footer.js +1 -1
- package/build/esm/gAssets.js +1 -1
- package/build/esm/getDynamicHealthTool-3cea54e3.js +1 -0
- package/build/esm/{getSocialList-4f55ecb2.js → getSocialList-019e247c.js} +1 -1
- package/build/esm/hooks.js +1 -1
- package/build/esm/i18n.js +1 -1
- package/build/esm/i18nV2.js +1 -1
- package/build/esm/{index-3f4e21b8.js → index-082bd9e3.js} +1 -1
- package/build/esm/{index-085ff41e.js → index-0dbf58bf.js} +1 -1
- package/build/esm/{index-151bce44.js → index-20cd227f.js} +1 -1
- package/build/esm/{index-0f66c501.js → index-27056737.js} +1 -1
- package/build/esm/{index-1d2a3d09.js → index-41160d03.js} +4 -4
- package/build/esm/{index-b65fbd53.js → index-528651a7.js} +2 -2
- package/build/esm/{index-87684d32.js → index-5b37296e.js} +1 -1
- package/build/esm/index-5b8b1794.js +1 -0
- package/build/esm/{index-ec40c49c.js → index-65dde3b2.js} +1 -1
- package/build/esm/{index-6f2bc89e.js → index-6ba3f8e0.js} +1 -1
- package/build/esm/index-6fb981e8.js +1 -0
- package/build/esm/{index-913181ee.js → index-7b1ab1a1.js} +1 -1
- package/build/esm/{index-c2a904b4.js → index-7b350e05.js} +1 -1
- package/build/esm/index-83ccc22e.js +1 -0
- package/build/esm/index-89216476.js +1 -0
- package/build/esm/{index-e95be9d3.js → index-8afb32a6.js} +1 -1
- package/build/esm/{index-b5b4e118.js → index-aa5b7907.js} +1 -1
- package/build/esm/{index-5c16846e.js → index-bb26a324.js} +1 -1
- package/build/esm/{index-02afedd5.js → index-c09f22b0.js} +1 -1
- package/build/esm/{index-79ace58e.js → index-d8829440.js} +2 -2
- package/build/esm/{index-53a7f605.js → index-f385f184.js} +1 -1
- package/build/esm/index.js +1 -1
- package/build/esm/{index.styled-82d6ac21.js → index.styled-1764a5b4.js} +9 -9
- package/build/esm/{index.styled-eac62c7a.js → index.styled-9ed09b52.js} +1 -1
- package/build/esm/{index.styled-676fe08e.js → index.styled-e957e6a0.js} +6 -6
- package/build/esm/lead.js +1 -1
- package/build/esm/mantine.js +1 -1
- package/build/esm/misc.js +1 -1
- package/build/esm/navigation.js +1 -1
- package/build/esm/onboarding.js +1 -1
- package/build/esm/onboardingV2.js +1 -1
- package/build/esm/{paths-45db61cf.js → paths-619878cb.js} +1 -1
- package/build/esm/pwg.js +5 -5
- package/build/esm/{routing-a6c08233.js → routing-20bec742.js} +1 -1
- package/build/esm/together.js +1 -1
- package/build/esm/{types-4976008c.js → types-4f5827f7.js} +1 -1
- package/build/esm/{types-932fb88d.js → types-af14a453.js} +4 -4
- package/build/esm/types.js +1 -1
- package/build/esm/useHealthToolCache-6f24e29d.js +1 -0
- package/build/esm/{useRafState-4b03a615.js → useRafState-fb8e37ee.js} +1 -1
- package/build/esm/useTranslations-3490d8cf.js +1 -0
- package/build/esm/{utils-e1256807.js → utils-cd46d4b9.js} +1 -1
- package/build/esm/{utils-bb45ded5.js → utils-faeda2b1.js} +1 -1
- package/build/esm/vaccination.js +5 -5
- package/build/{fixedBottomAdBlock-f9c6084c.js → fixedBottomAdBlock-1f6f739e.js} +1 -1
- package/build/footer.js +1 -1
- package/build/gAssets.js +1 -1
- package/build/{getDynamicHealthTool-dea80808.js → getDynamicHealthTool-f0248328.js} +1 -1
- package/build/{getSocialList-f5942142.js → getSocialList-544cf52b.js} +1 -1
- package/build/hooks.js +1 -1
- package/build/i18n.js +1 -1
- package/build/i18nV2.js +1 -1
- package/build/{index-41aa0a61.js → index-01dde56e.js} +1 -1
- package/build/index-07edb6b3.js +1 -0
- package/build/{index-8dde1b92.js → index-0fc2c531.js} +3 -3
- package/build/{index-988a4639.js → index-18aa30c6.js} +1 -1
- package/build/{index-1e70de4f.js → index-1cb4a497.js} +1 -1
- package/build/{index-86204bff.js → index-558c345e.js} +1 -1
- package/build/{index-6c4d17f6.js → index-615e9900.js} +1 -1
- package/build/{index-936e1a1e.js → index-71ee9d03.js} +1 -1
- package/build/index-75214568.js +1 -0
- package/build/{index-8161ec2c.js → index-75c370c5.js} +1 -1
- package/build/{index-8190552a.js → index-8698308c.js} +1 -1
- package/build/index-87362c30.js +53 -0
- package/build/{index-86c8b855.js → index-a764fbd3.js} +1 -1
- package/build/{index-c5b79d1f.js → index-afc10ce4.js} +1 -1
- package/build/{index-46e9245b.js → index-cdb83b1f.js} +1 -1
- package/build/{index-d8a74fa9.js → index-d643704e.js} +1 -1
- package/build/{index-b7942975.js → index-d759a97b.js} +1 -1
- package/build/{index-b731e2e0.js → index-dd23acd3.js} +1 -1
- package/build/{index-64515772.js → index-e464dc9d.js} +1 -1
- package/build/{index-6cd7e2f0.js → index-f6821534.js} +1 -1
- package/build/{index-0a295fe9.js → index-fd7366ca.js} +1 -1
- package/build/index.js +1 -1
- package/build/{index.styled-361ec162.js → index.styled-66e6ff85.js} +1 -1
- package/build/{index.styled-d1db6e01.js → index.styled-85f37ce0.js} +3 -3
- package/build/index.styled-97ae1c6a.js +50 -0
- package/build/lead.js +1 -1
- package/build/mantine.js +1 -1
- package/build/misc.js +1 -1
- package/build/navigation.js +1 -1
- package/build/onboarding.js +1 -1
- package/build/onboardingV2.js +1 -1
- package/build/{paths-dbdce160.js → paths-7e5b5714.js} +1 -1
- package/build/pwg.js +4 -4
- package/build/{routing-3d33b4c9.js → routing-f8d9a098.js} +1 -1
- package/build/together.js +1 -1
- package/build/{types-128c2ca2.js → types-08fd54d3.js} +1 -1
- package/build/{types-28fd2f77.js → types-2b151885.js} +4 -4
- package/build/types.js +1 -1
- package/build/useHealthToolCache-14e77a9f.js +1 -0
- package/build/{useRafState-56089ce1.js → useRafState-f9fe24e3.js} +1 -1
- package/build/{useTranslations-e3170e13.js → useTranslations-54a6826c.js} +1 -1
- package/build/utils-cec07ed4.js +1 -0
- package/build/{utils-ccbc9e8e.js → utils-d9d36010.js} +1 -1
- package/build/vaccination.js +1 -1
- package/package.json +1 -1
- package/build/esm/getDynamicHealthTool-0430fe34.js +0 -1
- package/build/esm/index-1b0727f9.js +0 -1
- package/build/esm/index-640358c7.js +0 -1
- package/build/esm/index-ba2b88bc.js +0 -1
- package/build/esm/index-daa0bde1.js +0 -1
- package/build/esm/useHealthToolCache-eaf1794a.js +0 -1
- package/build/esm/useTranslations-13e3deda.js +0 -1
- package/build/index-943332ff.js +0 -1
- package/build/index-b6bf0d44.js +0 -53
- package/build/index-e2a080f4.js +0 -1
- package/build/index.styled-51fd278c.js +0 -50
- package/build/useHealthToolCache-b3abbc82.js +0 -1
- package/build/utils-2a0a92fd.js +0 -1
- /package/build/{BMI_BOYS.percentile.monthly-48e7ebde.js → BMI_BOYS.percentile.monthly-3757785a.js} +0 -0
- /package/build/{BMI_BOYS.percentile.weekly-1a92165d.js → BMI_BOYS.percentile.weekly-3d4d8ac0.js} +0 -0
- /package/build/{BMI_BOYS.percentile.yearly-c7f08171.js → BMI_BOYS.percentile.yearly-4f3b7049.js} +0 -0
- /package/build/{BMI_BOYS.zscore.monthly-61d4e522.js → BMI_BOYS.zscore.monthly-dc0eb418.js} +0 -0
- /package/build/{BMI_BOYS.zscore.weekly-e692d009.js → BMI_BOYS.zscore.weekly-9e6111a2.js} +0 -0
- /package/build/{BMI_BOYS.zscore.yearly-f93f6914.js → BMI_BOYS.zscore.yearly-de190cb7.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.monthly-5f1e24cf.js → BMI_GIRLS.percentile.monthly-986b1cbb.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.weekly-d26655e5.js → BMI_GIRLS.percentile.weekly-a9b824c2.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.yearly-ac381ece.js → BMI_GIRLS.percentile.yearly-ff9bcd49.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.monthly-2763e1bf.js → BMI_GIRLS.zscore.monthly-cdc060c8.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.weekly-a2997d23.js → BMI_GIRLS.zscore.weekly-f16a22ce.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.yearly-bb7df557.js → BMI_GIRLS.zscore.yearly-ab40c2f8.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.monthly-915b9916.js → HEAD CIRCUM_BOYS.percentile.monthly-dfe0f398.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.weekly-16c0811c.js → HEAD CIRCUM_BOYS.percentile.weekly-08a9af16.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.yearly-1439ebac.js → HEAD CIRCUM_BOYS.percentile.yearly-e04bdd84.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.monthly-f42746dc.js → HEAD CIRCUM_BOYS.zscore.monthly-4010de82.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.weekly-9f399d62.js → HEAD CIRCUM_BOYS.zscore.weekly-8757dcf8.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.yearly-02bc7d14.js → HEAD CIRCUM_BOYS.zscore.yearly-5f404da6.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.monthly-8f856deb.js → HEAD CIRCUM_GIRLS.percentile.monthly-970127fb.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.weekly-cce57536.js → HEAD CIRCUM_GIRLS.percentile.weekly-d2327a1c.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.yearly-56026250.js → HEAD CIRCUM_GIRLS.percentile.yearly-8fa5c514.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.monthly-1c9a7a7d.js → HEAD CIRCUM_GIRLS.zscore.monthly-1382c285.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.weekly-05b3491a.js → HEAD CIRCUM_GIRLS.zscore.weekly-3718241f.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.yearly-176f8c3c.js → HEAD CIRCUM_GIRLS.zscore.yearly-eb6a6dc9.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.monthly-a41c4df1.js → HEIGHT_BOYS.percentile.monthly-e34b7838.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.weekly-74426765.js → HEIGHT_BOYS.percentile.weekly-57c3d2f5.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.yearly-91d90cc2.js → HEIGHT_BOYS.percentile.yearly-29285ae7.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.monthly-0e0f237d.js → HEIGHT_BOYS.zscore.monthly-3f852238.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.weekly-5c974b1c.js → HEIGHT_BOYS.zscore.weekly-a5c442c5.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.yearly-0cf8ceab.js → HEIGHT_BOYS.zscore.yearly-684c9473.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.monthly-8cd90e4c.js → HEIGHT_GIRLS.percentile.monthly-5a94996d.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.weekly-9fdd8a81.js → HEIGHT_GIRLS.percentile.weekly-2a2db340.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.yearly-39de3511.js → HEIGHT_GIRLS.percentile.yearly-646f8281.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.monthly-a081635b.js → HEIGHT_GIRLS.zscore.monthly-80930ad8.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.weekly-61dbc366.js → HEIGHT_GIRLS.zscore.weekly-442bd327.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.yearly-f28202a3.js → HEIGHT_GIRLS.zscore.yearly-8badb34c.js} +0 -0
- /package/build/{Onboarding-f30006ae.js → Onboarding-41cd0c5b.js} +0 -0
- /package/build/{Visible-4d92a0a4.js → Visible-c67d0cfc.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.monthly-633bb23d.js → WEIGHT_BOYS.percentile.monthly-114b11b6.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.weekly-0b8788cd.js → WEIGHT_BOYS.percentile.weekly-96698ada.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.yearly-2df702b1.js → WEIGHT_BOYS.percentile.yearly-6fe03046.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.monthly-f42e3dde.js → WEIGHT_BOYS.zscore.monthly-33303d30.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.weekly-221ea265.js → WEIGHT_BOYS.zscore.weekly-3515e4a6.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.yearly-cb3ad51b.js → WEIGHT_BOYS.zscore.yearly-6f411d8b.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.monthly-c41e1e0a.js → WEIGHT_GIRLS.percentile.monthly-3fff1888.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.weekly-a015759f.js → WEIGHT_GIRLS.percentile.weekly-e8d4fffc.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.yearly-b5a0c9a8.js → WEIGHT_GIRLS.percentile.yearly-b1b285b5.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.monthly-edb25ee7.js → WEIGHT_GIRLS.zscore.monthly-f2ec23ff.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.weekly-d9e76b87.js → WEIGHT_GIRLS.zscore.weekly-58ed18b1.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.yearly-271bcd04.js → WEIGHT_GIRLS.zscore.yearly-d159dbc3.js} +0 -0
- /package/build/{constants-25148617.js → constants-d9417c87.js} +0 -0
- /package/build/{cookieHelper-c96c0c97.js → cookieHelper-c5f87e77.js} +0 -0
- /package/build/{dataTransform-e1f0b295.js → dataTransform-15bad192.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.monthly-ea0dbe17.js → BMI_BOYS.percentile.monthly-751eee00.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.weekly-175df741.js → BMI_BOYS.percentile.weekly-f7b3f5b0.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.yearly-ea91649c.js → BMI_BOYS.percentile.yearly-5870f938.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.monthly-40d70b2f.js → BMI_BOYS.zscore.monthly-88b0aa5f.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.weekly-b6a309e5.js → BMI_BOYS.zscore.weekly-ed8dcc59.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.yearly-557e8993.js → BMI_BOYS.zscore.yearly-91486d6a.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.monthly-6bb8568f.js → BMI_GIRLS.percentile.monthly-e1ef85c8.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.weekly-faea8270.js → BMI_GIRLS.percentile.weekly-2d64db50.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.yearly-9d762601.js → BMI_GIRLS.percentile.yearly-0423ba78.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.monthly-e34aebbf.js → BMI_GIRLS.zscore.monthly-82369504.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.weekly-3869a198.js → BMI_GIRLS.zscore.weekly-80810988.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.yearly-d4e86a21.js → BMI_GIRLS.zscore.yearly-8b1060df.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.monthly-3805c552.js → HEAD CIRCUM_BOYS.percentile.monthly-369c483a.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.weekly-01e4f3ae.js → HEAD CIRCUM_BOYS.percentile.weekly-fb464fe8.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.yearly-0ae7cc0e.js → HEAD CIRCUM_BOYS.percentile.yearly-8764863f.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.monthly-fe9f9d06.js → HEAD CIRCUM_BOYS.zscore.monthly-753c9e89.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.weekly-f244a3a8.js → HEAD CIRCUM_BOYS.zscore.weekly-015f1162.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.yearly-19f7b4a9.js → HEAD CIRCUM_BOYS.zscore.yearly-0ab19877.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.monthly-70297084.js → HEAD CIRCUM_GIRLS.percentile.monthly-9835ce32.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.weekly-afc85506.js → HEAD CIRCUM_GIRLS.percentile.weekly-cd7300e2.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.yearly-1194ece5.js → HEAD CIRCUM_GIRLS.percentile.yearly-88eb4ca2.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.monthly-700479c2.js → HEAD CIRCUM_GIRLS.zscore.monthly-0b757c43.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.weekly-c500203d.js → HEAD CIRCUM_GIRLS.zscore.weekly-94534538.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.yearly-b44df460.js → HEAD CIRCUM_GIRLS.zscore.yearly-baee7830.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.monthly-9a95ba5d.js → HEIGHT_BOYS.percentile.monthly-42ac27b7.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.weekly-474501d0.js → HEIGHT_BOYS.percentile.weekly-6dbe6a1e.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.yearly-6361be2f.js → HEIGHT_BOYS.percentile.yearly-14501806.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.monthly-c7ead7a8.js → HEIGHT_BOYS.zscore.monthly-7a555ca1.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.weekly-b0b9f59e.js → HEIGHT_BOYS.zscore.weekly-f84cc8e7.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.yearly-b501d982.js → HEIGHT_BOYS.zscore.yearly-04784903.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.monthly-8e52e01e.js → HEIGHT_GIRLS.percentile.monthly-9e3d5155.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.weekly-4af7257f.js → HEIGHT_GIRLS.percentile.weekly-14523546.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.yearly-c7d3a837.js → HEIGHT_GIRLS.percentile.yearly-eb458aa7.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.monthly-910ebd15.js → HEIGHT_GIRLS.zscore.monthly-0ec62860.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.weekly-c991727f.js → HEIGHT_GIRLS.zscore.weekly-c9fff163.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.yearly-efc24ef3.js → HEIGHT_GIRLS.zscore.yearly-12c026a1.js} +0 -0
- /package/build/esm/{Onboarding-7aae6591.js → Onboarding-4fea1737.js} +0 -0
- /package/build/esm/{Visible-f4a38eb0.js → Visible-3b2f0a06.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.monthly-2ab65943.js → WEIGHT_BOYS.percentile.monthly-3a90a99c.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.weekly-57cf6a64.js → WEIGHT_BOYS.percentile.weekly-a001b979.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.yearly-cc075161.js → WEIGHT_BOYS.percentile.yearly-7ab0f563.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.monthly-65e43653.js → WEIGHT_BOYS.zscore.monthly-822d7e82.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.weekly-4d5430dd.js → WEIGHT_BOYS.zscore.weekly-bbe2a5db.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.yearly-9c2aac1a.js → WEIGHT_BOYS.zscore.yearly-6ee98440.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.monthly-8afde931.js → WEIGHT_GIRLS.percentile.monthly-ff720106.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.weekly-2da762f3.js → WEIGHT_GIRLS.percentile.weekly-ba5dda04.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.yearly-842a4558.js → WEIGHT_GIRLS.percentile.yearly-ee513f53.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.monthly-06ed818f.js → WEIGHT_GIRLS.zscore.monthly-3b4b3075.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.weekly-b2d76f17.js → WEIGHT_GIRLS.zscore.weekly-f16f908f.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.yearly-ca23739f.js → WEIGHT_GIRLS.zscore.yearly-abdad86f.js} +0 -0
- /package/build/esm/{constants-fd43ae8a.js → constants-40246210.js} +0 -0
- /package/build/esm/{cookieHelper-0126174d.js → cookieHelper-164f0b8c.js} +0 -0
- /package/build/esm/{dataTransform-ae3407db.js → dataTransform-977c15f0.js} +0 -0
- /package/build/esm/{index-bcbeba21.js → index-05fb4031.js} +0 -0
- /package/build/esm/{isProduction-5b883868.js → isProduction-49838df1.js} +0 -0
- /package/build/esm/{localizeNumberFormat-149d5e39.js → localizeNumberFormat-f3849e8e.js} +0 -0
- /package/build/esm/{normalizeLink-6f9d1a59.js → normalizeLink-75e2aba3.js} +0 -0
- /package/build/esm/{number-1a1ab7d5.js → number-37f42c6a.js} +0 -0
- /package/build/esm/{screenSizeContext-239dadf0.js → screenSizeContext-047093be.js} +0 -0
- /package/build/esm/{theme-84310d70.js → theme-c7dd40d5.js} +0 -0
- /package/build/esm/{translationsContext-548d8e49.js → translationsContext-cb9cc714.js} +0 -0
- /package/build/esm/{tslib.es6-62fd61aa.js → tslib.es6-38c1b6ee.js} +0 -0
- /package/build/esm/{types-cdaedeeb.js → types-5a1cbee0.js} +0 -0
- /package/build/esm/{useIsInit-960e198e.js → useIsInit-457576f7.js} +0 -0
- /package/build/esm/{useOutsideClick-b0405035.js → useOutsideClick-2318875b.js} +0 -0
- /package/build/esm/{useScrollbarSize-83d1cba9.js → useScrollbarSize-e5dfdbb4.js} +0 -0
- /package/build/esm/{useUniqueId-5c654228.js → useUniqueId-698c1d63.js} +0 -0
- /package/build/{index-b8c748ef.js → index-adc33906.js} +0 -0
- /package/build/{isProduction-233fe264.js → isProduction-ad420ef8.js} +0 -0
- /package/build/{localizeNumberFormat-ee913abc.js → localizeNumberFormat-2182ad1b.js} +0 -0
- /package/build/{normalizeLink-4c23bec6.js → normalizeLink-8f929fb5.js} +0 -0
- /package/build/{number-dd4f17d4.js → number-24c0d0e1.js} +0 -0
- /package/build/{screenSizeContext-53b92594.js → screenSizeContext-77599820.js} +0 -0
- /package/build/{theme-a8fac2fb.js → theme-60584197.js} +0 -0
- /package/build/{translationsContext-735ad870.js → translationsContext-cce05878.js} +0 -0
- /package/build/{tslib.es6-acb602d8.js → tslib.es6-4eb751d0.js} +0 -0
- /package/build/{types-6c7d80f9.js → types-cfcc1e36.js} +0 -0
- /package/build/{useIsInit-48c8a3f9.js → useIsInit-e6e0ea2f.js} +0 -0
- /package/build/{useOutsideClick-bfaa0861.js → useOutsideClick-9508c4f0.js} +0 -0
- /package/build/{useScrollbarSize-950a1979.js → useScrollbarSize-d63980bc.js} +0 -0
- /package/build/{useUniqueId-6dbab5ea.js → useUniqueId-2b12f9b4.js} +0 -0
package/build/pwg.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("./index-18aa30c6.js"),a=require("./index-01dde56e.js"),l=require("./index-71ee9d03.js"),r=require("./useTranslations-54a6826c.js"),n=require("./theme-60584197.js"),o=require("recharts"),i=require("./index-e464dc9d.js"),s=require("./useOutsideClick-9508c4f0.js"),c=require("styled-components"),d=require("./tslib.es6-4eb751d0.js");function u(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}require("./Onboarding-41cd0c5b.js"),require("./index.styled-97ae1c6a.js"),require("./gAssets.js"),require("./index-d643704e.js"),require("date-fns/locale"),require("./isProduction-ad420ef8.js"),require("./translationsContext-cce05878.js"),require("string-format"),require("@mantine/carousel"),require("@mantine/core"),require("@mantine/hooks");var m=u(e),p=u(c);const f=e=>{const{x:t,y:a,payload:l,activeWeek:r}=e;return r===l.value?m.default.createElement("g",{transform:`translate(${t},${a})`},m.default.createElement("circle",{r:12,fill:"marryBaby"===e.siteType?n.theme.mbColors.pink:n.theme.colors.primaryBase}),m.default.createElement("text",{textAnchor:"middle",alignmentBaseline:"central",fill:n.theme.colors.white,fontFamily:"Inter",fontWeight:"600",fontSize:"12px"},l.value)):m.default.createElement("g",{transform:`translate(${t},${a})`},m.default.createElement("text",{textAnchor:"middle",alignmentBaseline:"central",fill:n.theme.colors.gray600,fontFamily:"Inter",fontWeight:"400",fontSize:"12px"},l.value))},g=p.default.div`
|
|
2
2
|
/* position: absolute; */
|
|
3
3
|
display: flex;
|
|
4
4
|
flex-direction: column;
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
border-radius: 2px;
|
|
33
33
|
background: #ffffff;
|
|
34
34
|
}
|
|
35
|
-
`,h=
|
|
35
|
+
`,h=p.default.div`
|
|
36
36
|
position: relative;
|
|
37
37
|
width: 100%;
|
|
38
38
|
.custom-chart-label {
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
display: flex;
|
|
46
46
|
justify-content: space-between;
|
|
47
47
|
}
|
|
48
|
-
`,y=
|
|
48
|
+
`,y=p.default.div`
|
|
49
49
|
display: flex;
|
|
50
50
|
gap: 40px;
|
|
51
51
|
justify-content: center;
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
align-items: center;
|
|
56
56
|
gap: 4px;
|
|
57
57
|
}
|
|
58
|
-
`,x=[{name:"overweight",backgroundColor:n.theme.colors.yellow50,color:n.theme.colors.yellow900},{name:"underweight",backgroundColor:n.theme.colors.yellow50,color:n.theme.colors.yellow900},{name:"healthy",backgroundColor:n.theme.colors.green50,color:n.theme.colors.green900}],b=t=>{var l,r,o,i,s;const{payload:c,active:d}=t,u=null===(l=null==c?void 0:c[0])||void 0===l?void 0:l.payload;if(!u||!u.toolTipLabel||!d)return null;const{backgroundColor:
|
|
58
|
+
`,x=[{name:"overweight",backgroundColor:n.theme.colors.yellow50,color:n.theme.colors.yellow900},{name:"underweight",backgroundColor:n.theme.colors.yellow50,color:n.theme.colors.yellow900},{name:"healthy",backgroundColor:n.theme.colors.green50,color:n.theme.colors.green900}],b=t=>{var l,r,o,i,s;const{payload:c,active:d}=t,u=null===(l=null==c?void 0:c[0])||void 0===l?void 0:l.payload;if(!u||!u.toolTipLabel||!d)return null;const{backgroundColor:p,color:f}=e.useMemo((()=>x.find((e=>e.name===u.status))),[null==u?void 0:u.status]);return m.default.createElement(g,null,m.default.createElement("div",null,null===(r=u.toolTipLabel)||void 0===r?void 0:r[0]," ",null===(o=u.toolTipLabel)||void 0===o?void 0:o[1]),m.default.createElement("div",null,(null===(i=u.toolTipLabel)||void 0===i?void 0:i[2])&&m.default.createElement(a.Text,{as:"span",size:"s3",color:n.theme.colors.gray800,type:"semiBold"},null===(s=u.toolTipLabel)||void 0===s?void 0:s[2]),m.default.createElement("div",{className:"risk",style:{backgroundColor:p}},m.default.createElement(a.Text,{size:"n1",color:f},u.translatedStatus))))},E=({weightByWeek:e,weightBefore:t,toolTipLabel:a,status:l,activeWeek:r,t:n})=>{const o=n(`bmi.result.${l}`);return e.map((e=>Object.assign({name:e.week,min:t+e.min,difference:e.max-e.min,max:t+e.max},e.week===r?{toolTipLabel:a,translatedStatus:o,status:l}:{})))},k=({weightBefore:l,weightByWeek:c,activeWeek:d,currentWeight:u,toolTipLabel:p=[],status:g,withLine:y=!1,siteType:x})=>{const{t:k}=r.useTranslations(),v="marryBaby"===x,w=e.useMemo((()=>E({weightByWeek:c,weightBefore:l,toolTipLabel:p,status:g,activeWeek:d,t:k})),[c,l,p,g,d]),[T,C]=e.useState(!1),j=e.useRef(null);return s.useOutsideClick(j,(()=>C(!1))),m.default.createElement(h,null,v?m.default.createElement(t.MarryBabyText,{type:"bodytext-3",color:n.theme.mbColors.dark}," ",k("babyGrowth.weight")," ",k("pregnancyWeightGain.weightInput.desc")):m.default.createElement(a.Text,{size:"n1",color:n.theme.colors.gray500},k("babyGrowth.weight")," ",k("pregnancyWeightGain.weightInput.desc")),Array.isArray(w)&&w.length>0&&m.default.createElement(h,null,m.default.createElement(o.ResponsiveContainer,{height:388,className:"chart"},m.default.createElement(o.AreaChart,{data:w,margin:{top:16,right:0,left:0}},m.default.createElement(o.CartesianGrid,{stroke:n.theme.colors.neutral100}),m.default.createElement(o.Tooltip,{trigger:"click",content:e=>m.default.createElement(b,Object.assign({active:!y&&T&&void 0!==d&&void 0!==u},e))}),m.default.createElement(o.XAxis,{type:"number",scale:"linear",ticks:Array.from({length:40},((e,t)=>t+1)),dataKey:"name",tickLine:!1,tickMargin:12,tick:e=>m.default.createElement(f,Object.assign({},e,{activeWeek:d,siteType:x})),domain:["dataMin","dataMax"],interval:"preserveStartEnd",tickCount:1,allowDecimals:!1}),m.default.createElement(o.YAxis,{domain:[e=>Math.max(e,l-10||e),e=>Math.max(e,l+20||e)],type:"number",scale:"auto",interval:"preserveStartEnd",tickLine:!1,tickMargin:7,width:45,tickCount:10,allowDecimals:!0,tickFormatter:e=>String(Math.round(100*(e+Number.EPSILON))/100),tick:{fontFamily:"Inter",fontWeight:400,fontSize:12,color:n.theme.colors.gray600}}),m.default.createElement(o.Area,{connectNulls:!0,type:"monotone",dataKey:"min",stackId:"1",stroke:"transparent",fill:"transparent"}),m.default.createElement(o.Area,{connectNulls:!0,type:"monotone",dataKey:"difference",stackId:"1",stroke:"transparent",fill:v?n.theme.mbColors.tonePink:n.theme.colors.primary100}),void 0!==d&&void 0!==u&&m.default.createElement(o.ReferenceDot,{onClick:()=>C(!0),x:0===d?1:d,y:u,r:4,shape:m.default.createElement(i.CustomReferenceDot,{ref:j,r:4}),fill:v?n.theme.mbColors.pink:n.theme.colors.primaryBase,stroke:v?n.theme.mbColors.pink:n.theme.colors.primaryBase}))),m.default.createElement("div",{className:"custom-chart-label"},m.default.createElement("i",null),v?m.default.createElement(t.MarryBabyText,{type:"bodytext-3",color:n.theme.mbColors.dark},k("pregnancy.week")):m.default.createElement(a.Text,{size:"n1",color:n.theme.colors.gray500},k("pregnancy.week")))))},v=e=>{var{color:t}=e,a=d.__rest(e,["color"]);return m.default.createElement("svg",Object.assign({width:"8",height:"8",viewBox:"0 0 8 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},a),m.default.createElement("circle",{cx:"4",cy:"4",r:"4",fill:t||n.theme.colors.primaryBase}))},w=({idealWeight:e,siteType:l})=>{const{t:o}=r.useTranslations(),i="marryBaby"===l;return m.default.createElement(y,null,m.default.createElement("div",null,i?m.default.createElement(m.default.Fragment,null,m.default.createElement(v,{color:n.theme.mbColors.lightPink}),m.default.createElement(t.MarryBabyText,{type:"bodytext-3",color:n.theme.mbColors.dark},o("pregnancyTool.weightSuggested")," ",m.default.createElement(a.Text,{size:"n1",color:n.theme.colors.gray800,type:"bold",as:"span"},e))):m.default.createElement(m.default.Fragment,null,m.default.createElement(v,{color:n.theme.colors.primary100}),m.default.createElement(a.Text,{size:"n1",color:n.theme.colors.gray600},m.default.createElement(a.Text,{size:"n1",as:"span"},o("pregnancyTool.weightSuggested")," "),m.default.createElement(a.Text,{size:"n1",color:n.theme.colors.gray800,type:"bold",as:"span"},e)))),m.default.createElement("div",null,i?m.default.createElement(m.default.Fragment,null,m.default.createElement(v,{color:n.theme.mbColors.pink}),m.default.createElement(t.MarryBabyText,{type:"bodytext-3",color:n.theme.mbColors.dark},o("pwg.placeholder.weight"))):m.default.createElement(m.default.Fragment,null,m.default.createElement(v,null),m.default.createElement(a.Text,{size:"n1",color:n.theme.colors.gray600},o("pwg.placeholder.weight")))))},T=p.default.div`
|
|
59
59
|
display: flex;
|
|
60
60
|
flex-direction: column;
|
|
61
61
|
align-items: center;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("./index-
|
|
1
|
+
"use strict";var e=require("./index-d643704e.js"),o=require("./isProduction-ad420ef8.js");exports.getCareApiDomain=()=>process.env.UNIFY_INTERNAL_CARE_API||process.env.UNIFY_CARE_API||`https://${o.isProduction?"health-care.":"service-health-care."}hellohealthgroup.com`,exports.getCurrentBaseUrl=(t,s)=>{if("undefined"!=typeof window)return window.location.origin;const r="development"===process.env.NEXT_PUBLIC_DEPLOY_ENV,i=!r&&!o.isProduction;return r?"http://localhost:3000":`https://${i?s?"fe.":"discover.":s?"www.":""}${e.domainLocales[s?"vi-VN_MB":t]}`},exports.getCurrentSsoUrl=(t,s)=>process.env.UNIFY_SSO_API||`https://${o.isProduction?"id.":"staging-id."}${e.domainLocales[s?"vi-VN_MB":t]}`,exports.getDiscoverApiDomain=t=>process.env.UNIFY_DISCOVER_API||`https://${o.isProduction?"wp.":"staging."}${e.domainLocales[t]}`,exports.getTogetherApiDomain=()=>process.env.UNIFY_INTERNAL_TOGETHER_API||process.env.UNIFY_TOGETHER_API||`https://${o.isProduction?"together.":"staging-together."}hellohealthgroup.com`;
|
package/build/together.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./types-
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./types-08fd54d3.js"),r=require("./index.styled-66e6ff85.js"),t=require("./dataTransform-5bb8c118.js"),o=require("./utils-d9d36010.js");require("./tslib.es6-4eb751d0.js"),require("react"),require("@mantine/core"),require("./index-a764fbd3.js"),require("styled-components"),require("./screenSizeContext-77599820.js"),require("lodash/throttle"),require("./index-75c370c5.js"),require("./gAssets.js"),require("./index-d643704e.js"),require("date-fns/locale"),require("./Onboarding-41cd0c5b.js"),require("./isProduction-ad420ef8.js"),require("./index-e464dc9d.js"),require("@mantine/carousel"),require("@mantine/hooks"),require("./index-01dde56e.js"),require("./index-615e9900.js"),require("./index-cdb83b1f.js"),require("./index-f6821534.js"),require("./theme-60584197.js"),require("dayjs"),require("./useUniqueId-2b12f9b4.js"),require("@mantine/dates"),require("./translationsContext-cce05878.js"),require("string-format"),require("@hookform/resolvers/yup"),require("react-hook-form"),require("./index-0fc2c531.js"),require("./useTranslations-54a6826c.js"),require("./index-18aa30c6.js"),require("date-fns"),require("./index-fd7366ca.js"),require("lodash/debounce"),require("./types-cfcc1e36.js"),require("react-day-picker/DayPickerInput"),require("innertext"),require("./index-afc10ce4.js"),require("./paths-7e5b5714.js"),require("./constants-d9417c87.js"),require("react-contenteditable"),require("./cookieHelper-c5f87e77.js"),require("react-dom"),require("./number-24c0d0e1.js"),require("date-fns/locale/en-US"),require("date-fns/locale/id"),require("date-fns/locale/vi"),require("date-fns/locale/zh-TW"),require("./index.styled-97ae1c6a.js"),require("uuid"),require("./utils-cec07ed4.js"),require("dayjs/plugin/relativeTime"),require("./index-1cb4a497.js"),require("./routing-f8d9a098.js"),require("react-keyed-flatten-children"),require("slugify"),exports.CardAuthor=e.CardAuthor,exports.CardLink=e.CardLink,exports.CardPost=e.CardPost,exports.CardPostPopoverMore=e.CardPostPopoverMore,exports.CardReactions=e.CardReactions,exports.CardReply=e.CardReply,exports.CardReplyPopover=e.CardReplyPopover,exports.CreateNewPostContent=e.CreateNewPostContent,exports.CreatePostDescription=e.CreatePostDescription,exports.CreatePostTitle=e.CreatePostTitle,exports.ImagePreviewPopup=e.ImagePreviewPopup,exports.InputCommentBar=e.InputCommentBar,exports.LabelPin=e.LabelPin,exports.LabelSortPin=e.LabelSortPin,exports.LabelSorting=e.LabelSorting,exports.Loading=e.Loading,exports.PopoverMenu=e.PopoverMenu,exports.PopupDanger=e.PopupDanger,exports.PopupDoctor=e.PopupDoctor,exports.PopupExpert=e.PopupExpert,exports.PopupFrame=e.PopupFrame,exports.PopupHospital=e.PopupHospital,exports.PostContent=e.PostContent,exports.PostImagePreview=e.PostImagePreview,exports.PostSingleImageViewPopup=e.PostSingleImageViewPopup,exports.ProfileDetail=e.ProfileDetail,exports.ProfileDetailModal=e.ProfileDetailModal,exports.ShareBox=e.ShareBox,exports.SharePopup=e.SharePopup,exports.SkipQuestionOfExpertBtn=e.SkipQuestionOfExpertBtn,exports.SocialLinkPreview=e.SocialLinkPreview,exports.SourceList=e.SourceList,exports.SubmitReportForm=e.SubmitReportForm,Object.defineProperty(exports,"TabNameInProfileDetail",{enumerable:!0,get:function(){return e.TabName}}),exports.TagTopic=e.TagTopic,exports.TogetherAuthConfigContext=e.TogetherAuthConfigContext,exports.TogetherAuthConfigContextProvider=e.TogetherAuthConfigContextProvider,exports.TogetherTypes=e.types,exports.TopicSelectList=e.TopicSelectList,exports.VerifiedTag=e.VerifiedTag,exports.useTogetherAuthRequiredAction=e.useTogetherAuthRequiredAction,exports.UserAvatar=r.UserAvatar,exports.TogetherDataTransforms=t.dataTransform,exports.DefaultComponentGlobalContextData=o.DefaultComponentGlobalContextData,Object.defineProperty(exports,"GlobalData",{enumerable:!0,get:function(){return o.GlobalData}}),exports.TogetherComponentGlobalContext=o.TogetherComponentGlobalContext,exports.TogetherComponentGlobalContextProvider=o.TogetherComponentGlobalContextProvider,exports.TogetherConstants=o.constants;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-
|
|
1
|
+
"use strict";var e=require("./tslib.es6-4eb751d0.js"),t=require("react"),a=require("@mantine/core"),l=require("./index-a764fbd3.js"),o=require("./useTranslations-54a6826c.js"),n=require("innertext"),i=require("./theme-60584197.js"),r=require("./index-f6821534.js"),s=require("./utils-d9d36010.js");require("@mantine/dates");var d=require("./index-d643704e.js");require("./Onboarding-41cd0c5b.js");var c=require("./gAssets.js"),u=require("dayjs"),m=require("./screenSizeContext-77599820.js"),p=require("styled-components");require("./isProduction-ad420ef8.js");var g=require("./index-e464dc9d.js");require("@mantine/hooks");var h=require("./index-afc10ce4.js"),f=require("./dataTransform-5bb8c118.js"),v=require("./index-01dde56e.js"),b=require("./index-cdb83b1f.js"),x=require("lodash/debounce"),y=require("react-contenteditable"),w=require("./index-615e9900.js"),C=require("./cookieHelper-c5f87e77.js"),E=require("react-dom"),k=require("./number-24c0d0e1.js"),A=require("date-fns");require("react-day-picker/DayPickerInput");var N=require("./index.styled-66e6ff85.js");require("./index-0fc2c531.js"),require("lodash/throttle"),require("./types-cfcc1e36.js"),require("react-hook-form"),require("date-fns/locale/en-US"),require("date-fns/locale/id"),require("date-fns/locale/vi"),require("date-fns/locale/zh-TW"),require("./index.styled-97ae1c6a.js"),require("uuid"),require("./utils-cec07ed4.js"),require("string-format");var T=require("dayjs/plugin/relativeTime"),S=require("./index-1cb4a497.js"),P=require("./useUniqueId-2b12f9b4.js");require("./translationsContext-cce05878.js");var I=require("./routing-f8d9a098.js");function M(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function z(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(a){if("default"!==a){var l=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,l.get?l:{enumerable:!0,get:function(){return e[a]}})}})),t.default=e,Object.freeze(t)}var L=z(t),B=M(t),R=M(n),j=M(u),O=M(p),F=M(x),D=M(y),V=z(E),U=M(T);const _=e=>L.createElement("svg",Object.assign({width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},e),L.createElement("path",{d:"M3.99403 3.32695C3.86141 3.32698 3.73181 3.36657 3.62181 3.44065C3.5118 3.51472 3.42638 3.61992 3.37648 3.7428C3.32658 3.86567 3.31445 4.00064 3.34165 4.13044C3.36885 4.26024 3.43415 4.37898 3.52919 4.47148L7.05784 8.00013L3.52919 11.5288C3.46521 11.5902 3.41413 11.6638 3.37894 11.7452C3.34375 11.8266 3.32516 11.9142 3.32425 12.0029C3.32335 12.0916 3.34015 12.1796 3.37368 12.2617C3.40721 12.3438 3.45678 12.4185 3.5195 12.4812C3.58222 12.5439 3.65682 12.5935 3.73894 12.627C3.82106 12.6605 3.90904 12.6773 3.99774 12.6764C4.08643 12.6755 4.17405 12.6569 4.25547 12.6217C4.33689 12.5865 4.41047 12.5355 4.4719 12.4715L8.00054 8.94283L11.5292 12.4715C11.5906 12.5355 11.6642 12.5865 11.7456 12.6217C11.827 12.6569 11.9147 12.6755 12.0034 12.6764C12.092 12.6773 12.18 12.6605 12.2621 12.627C12.3443 12.5935 12.4189 12.5439 12.4816 12.4812C12.5443 12.4185 12.5939 12.3439 12.6274 12.2617C12.6609 12.1796 12.6777 12.0916 12.6768 12.0029C12.6759 11.9142 12.6573 11.8266 12.6222 11.7452C12.587 11.6638 12.5359 11.5902 12.4719 11.5288L8.94325 8.00013L12.4719 4.47148C12.5682 4.37784 12.634 4.25728 12.6607 4.1256C12.6873 3.99392 12.6735 3.85726 12.6212 3.73354C12.5688 3.60982 12.4803 3.5048 12.3672 3.43224C12.2542 3.35969 12.1218 3.32299 11.9875 3.32695C11.8143 3.33211 11.6499 3.4045 11.5292 3.52877L8.00054 7.05742L4.4719 3.52877C4.40977 3.46491 4.33548 3.41415 4.2534 3.37948C4.17132 3.34482 4.08313 3.32696 3.99403 3.32695Z"})),H=t.createContext({}),W=({children:e,defaultParams:t})=>B.default.createElement(H.Provider,{value:{defaultParams:t}},e),q=e=>{const{data:{userInfo:a,env:{togetherBasePath:l}}}=t.useContext(s.TogetherComponentGlobalContext),{defaultParams:o}=t.useContext(H)||{},n=null==a?void 0:a.id,i=a&&"number"==typeof a.communities_interacted&&0===a.communities_interacted;return{authActionWrapper:(t,a)=>{const r=Object.assign(Object.assign(Object.assign({},o),e),a);if(!n||i){n||C.deleteCookie(s.BEARER_TOKEN_COOKIE),(null==r?void 0:r._joinCommunityIds)&&(localStorage.setItem("to_join_community_ids",JSON.stringify(Array.from(new Set((JSON.parse(localStorage.getItem("to_join_community_ids")||"[]")||[]).concat(r._joinCommunityIds).filter(Boolean))))),null==r||delete r._joinCommunityIds),(null==r?void 0:r._joinTopicIds)&&(localStorage.setItem("to_join_topic_ids",JSON.stringify(Array.from(new Set((JSON.parse(localStorage.getItem("to_join_topic_ids")||"[]")||[]).concat(r._joinTopicIds).filter(Boolean))))),null==r||delete r._joinTopicIds);const e=(null==r?void 0:r._location)||window.location.href;return null==r||delete r._location,window.location.href=s.getUrlToSignUp(e,r,l),null}return t&&t()},params:Object.assign(Object.assign({},o),e)}},G=O.default.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
align-items: center;
|
|
4
4
|
justify-content: center;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-
|
|
1
|
+
"use strict";var e=require("./tslib.es6-4eb751d0.js"),t=require("react"),a=require("./useTranslations-54a6826c.js"),i=require("lodash/debounce"),o=require("./constants-d9417c87.js"),l=require("./index-cdb83b1f.js"),n=require("styled-components"),s=require("./index-01dde56e.js"),r=require("./theme-60584197.js"),c=require("./screenSizeContext-77599820.js"),d=require("react-loading-skeleton"),u=require("lodash/shuffle"),p=require("./useOutsideClick-9508c4f0.js"),h=require("./paths-7e5b5714.js"),g=require("@mantine/core"),f=require("./index-d643704e.js"),m=require("./cookieHelper-c5f87e77.js"),C=require("./index-f6821534.js"),b=require("string-format");function y(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function v(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(a){if("default"!==a){var i=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,i.get?i:{enumerable:!0,get:function(){return e[a]}})}})),t.default=e,Object.freeze(t)}var x=v(t),E=y(t),S=y(i),w=y(n),L=y(d),O=y(u),k=y(b);const I=e=>x.createElement("svg",Object.assign({width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},e),x.createElement("path",{d:"M7.99969 9.38055L5.45236 6.83322C5.17636 6.55722 4.72836 6.55722 4.45236 6.83322C4.17636 7.10922 4.17636 7.55722 4.45236 7.83322L7.52836 10.9092C7.78903 11.1699 8.21103 11.1699 8.47103 10.9092L11.547 7.83322C11.823 7.55722 11.823 7.10922 11.547 6.83322C11.271 6.55722 10.823 6.55722 10.547 6.83322L7.99969 9.38055Z"}));function T(){const[e,a]=t.useState((()=>{if("undefined"==typeof window)return"unset";if(m.getCookie(f.USER_GEOLOCATION_COORDINATES_COOKIE))return"granted";const e=!location.protocol.includes("https")&&"localhost"!==location.hostname;return!navigator.geolocation||e?"denied":"unset"})),[i,o]=t.useState((()=>{if("undefined"==typeof window)return null;const e=m.getCookie(f.USER_GEOLOCATION_COORDINATES_COOKIE);if(e)try{return JSON.parse(e)}catch(e){console.log(e)}return null})),l=t.useCallback((function(){navigator.geolocation&&navigator.geolocation.getCurrentPosition((e=>{const t={lat:""+Math.round(1e7*e.coords.latitude)/1e7,lng:""+Math.round(1e7*e.coords.longitude)/1e7};m.setCookie(f.USER_GEOLOCATION_COORDINATES_COOKIE,JSON.stringify(t),{minutes:15}),o(t),a("granted")}),(()=>{m.deleteCookie(f.USER_GEOLOCATION_COORDINATES_COOKIE),a("denied")}))}),[]);return t.useMemo((()=>({geoLocationPermission:e,geoLocationCoordinates:i,requestGeoLocation:l})),[e,i])}const j=w.default.div``,M=w.default.div`
|
|
2
2
|
--searchbar-z-index: 305;
|
|
3
3
|
&[data-is-modal='true'] {
|
|
4
4
|
position: fixed;
|
|
@@ -705,7 +705,7 @@
|
|
|
705
705
|
text-align: center;
|
|
706
706
|
}
|
|
707
707
|
}
|
|
708
|
-
`,jt=({state:e,isMobile:i,specialties:l,isLoading:n,dispatch:c})=>{const{t:d,locale:u}=a.useTranslations(),{selectedLocation:p}=e,h=t.useMemo((()=>o.LOCALIZED_SLUGS[u]),[u]);return E.default.createElement(E.default.Fragment,null,!i&&E.default.createElement(It,{color:"#E4E8EC"}),E.default.createElement(Ot,null,l.length>0&&!n&&E.default.createElement(E.default.Fragment,null,l.map(((e,t)=>t>=
|
|
708
|
+
`,jt=({state:e,isMobile:i,specialties:l,isLoading:n,dispatch:c})=>{const{t:d,locale:u}=a.useTranslations(),{selectedLocation:p}=e,h=t.useMemo((()=>o.LOCALIZED_SLUGS[u]),[u]);return E.default.createElement(E.default.Fragment,null,!i&&E.default.createElement(It,{color:"#E4E8EC"}),E.default.createElement(Ot,null,l.length>0&&!n&&E.default.createElement(E.default.Fragment,null,l.map(((e,t)=>t>=9?E.default.createElement(E.default.Fragment,null):E.default.createElement(kt,{key:e.id,onClick:()=>(e=>{const t=`/${p.slug}/${h.DOCTOR}/${e}`;c({type:at.NavigateTo,payload:t})})(e.slug)},E.default.createElement("div",{className:"image-item"},E.default.createElement("img",{src:e.thumbnail,alt:e.name})),E.default.createElement("div",{className:"infor"},E.default.createElement("div",{className:"title"},e.name)))))),0===l.length&&!n&&E.default.createElement(s.Text,{size:"sm",color:r.theme.colors.gray400},d("booking.searchBar.noResults")),n&&Array(6).fill(void 0).map(((e,t)=>E.default.createElement(kt,{key:"loading"+t},E.default.createElement("div",{className:"image-item"},E.default.createElement(g.Skeleton,{height:40,animate:!0})),E.default.createElement("div",{className:"infor"},E.default.createElement("div",{className:"title"},E.default.createElement(g.Skeleton,{height:20,radius:"sm",animate:!0}))))))),l.length>9&&E.default.createElement(Tt,null,E.default.createElement("div",{className:"show-more",onClick:()=>{const e=`/${h.SPECIALTIES}`;c({type:at.NavigateTo,payload:e})}},d("home.seeAll"))))},Mt=w.default.div`
|
|
709
709
|
display: flex;
|
|
710
710
|
gap: 5px;
|
|
711
711
|
margin-top: 16px;
|
|
@@ -752,8 +752,8 @@
|
|
|
752
752
|
border: 1px solid ${r.theme.colors.white};
|
|
753
753
|
margin-bottom: 5px;
|
|
754
754
|
margin-right: 7px;
|
|
755
|
-
`,Nt=({state:e,type:i,typeInformation:o,dispatch:l})=>{const{t:n}=a.useTranslations(),{selectedLocation:s}=e,r=t.useMemo((()=>o[i].slug),[o,i]);return E.default.createElement(Mt,null,E.default.createElement(At,null,n("booking.searchBar.popularKey")),e.popularKeys.map((e=>E.default.createElement(Rt,{key:e.id,onClick:()=>{var t;(t=e).url&&
|
|
755
|
+
`,Nt=({state:e,type:i,typeInformation:o,dispatch:l})=>{const{t:n}=a.useTranslations(),{selectedLocation:s}=e,r=t.useMemo((()=>o[i].slug),[o,i]);return E.default.createElement(Mt,null,E.default.createElement(At,null,n("booking.searchBar.popularKey")),e.popularKeys.map((e=>E.default.createElement(Rt,{key:e.id,onClick:()=>{var t;(t=e).url&&(window.location.href=t.url)}},e.keyword))),E.default.createElement(Rt,{className:"view-all",onClick:()=>{const e=`/${s.slug}/${r}`;e&&l({type:at.NavigateTo,payload:e})}},n("booking.searchBar.viewAll")))},Pt=w.default.div`
|
|
756
756
|
background: rgba(255, 255, 255, 0.64);
|
|
757
757
|
backdrop-filter: blur(12px);
|
|
758
758
|
border-bottom: 1px solid ${r.theme.colors.neutral100};
|
|
759
|
-
`,Ft=({currentTab:e,isMobile:i,setCurrentTab:o})=>{const{t:l}=a.useTranslations(),n=t.useMemo((()=>({root:{overflowY:i?"hidden":"initial",overflowX:i?"auto":"initial"},tabsList:{background:"rgba(255, 255, 255, 0)",borderBottom:"none",flexWrap:"nowrap",".mantine-Tabs-tab":{"&:last-child":{"&:after":{display:"none"}}}},tab:{padding:i?"12px 16px 12px 16px":"15px 40px 15px 40px",borderTop:"2px solid transparent",borderBottom:"none",margin:0,borderRadius:0,position:"relative",width:"auto",'&[data-active="true"]':{borderColor:"#2d87f3",backgroundColor:"#ffffff","&:after":{display:"none"},"&:before":{content:'""',width:"100%",height:"1px",position:"absolute",backgroundColor:"#ffffff",bottom:"-1px"}},"&:hover":{borderColor:"#2d87f3",backgroundColor:"#ffffff","&:before":{content:'""',width:"100%",height:"1px",position:"absolute",backgroundColor:"#ffffff",bottom:"-1px"}},"&:after":{content:'""',width:"1px",height:"24px",backgroundColor:"#E4E8EC",position:"absolute",right:"-1px"}},tabLabel:{color:"#595959",fontSize:i?"14px":"16px",fontWeight:600,lineHeight:i?"22px":"24px"}})),[i]);return E.default.createElement(Pt,{className:"booking-search-tab"},E.default.createElement(C.Container,null,E.default.createElement(g.Tabs,{value:e,onTabChange:e=>{o(e)},styles:n},E.default.createElement(g.Tabs.List,null,E.default.createElement(g.Tabs.Tab,{value:"hospital"},l("booking.searchPopup.hospitals")),E.default.createElement(g.Tabs.Tab,{value:"doctor"},l("booking.searchPopup.doctors")),E.default.createElement(g.Tabs.Tab,{value:"service"},l("booking.searchPopup.services")),E.default.createElement(g.Tabs.Tab,{value:"specialty"},l("booking.searchPopup.specialties"))))))};var _t;!function(e){e.doctor="doctor",e.service="hospital_service",e.hospital="hospital_branch"}(_t||(_t={}));var $t;!function(e){e[e.SPECIALTY=1]="SPECIALTY",e[e.DOCTOR=2]="DOCTOR",e[e.CLINIC=3]="CLINIC",e[e.SERVICE=4]="SERVICE"}($t||($t={}));var Dt=Object.freeze({__proto__:null,get RedirectType(){return $t}});exports.BookingSearchBar=({isMobile:i,careApiDomain:l,geoLocationPermission:n,geoLocationCoordinates:s,initialSelectedCity:r,initialSearchValue:c="",careFrontDomain:d="/care",isDebug:u=!1,askForGeolocationPermission:p=!1,gaTrackingSearchBar:g,gaTrackingLocationSearch:f,autoCompleteDisabled:m=!1,inputSearchPlaceholder:C="",isOptionAllLocation:b=!1,hideResults:y=[],isNavResultItem:v=!0,routerPush:x,onGeoLocationPermissionChange:w,onSearch:L,onChangeLocation:O})=>{const{t:k,locale:I}=a.useTranslations(),N=t.useRef(null),F=t.useRef(null),[_,$]=t.useState(void 0),[D,B]=t.useState(!1),{geoLocationPermission:V,geoLocationCoordinates:H,requestGeoLocation:K}=T(),[z,G]=t.useReducer(Ce,ge,(e=>Object.assign(Object.assign({},e),{isDebug:u,isMobile:i,geoLocationPermission:n||V||"unset",geoLocationCoordinates:s||H||null,searchKeywords:c,initialSelectedCity:r||null,selectedLocation:r||e.selectedLocation||null,searchLocationKeywords:(null==r?void 0:r.name)||e.searchLocationKeywords,autoCompleteDisabled:m,inputSearchPlaceholder:C,locale:I}))),{navigateTo:U,focused:Q,isLoadingCities:q,cities:Y,searchKeywords:W,geoLocationPermission:J,selectedLocation:X,initialSelectedCity:ee,defaultCity:te,searchResults:ae,isLoadingSearchResults:ie,isMobileModalOpened:oe,inputSearchPlaceholder:le}=z,{fetchCitiesByLocation:se,fetchCitiesByKeyword:re,fetchSearchResults:ce}=function({dispatch:e,careApiDomain:a,locale:i="vi-VN"}){const l=t.useCallback((function(t,o={}){const l=`${a}${t}`;return e({type:fe.FetchCitiesStart}),fetch(Ye(l,o,i),{method:"GET"}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:(console.log("error loading cities",e),Promise.reject(e)))).finally((()=>e({type:fe.FetchCitiesFinish})))}),[i]);return{fetchCitiesByLocation:t.useCallback((function({coordinates:t}){let a={};const o={};t&&(a={lat:t.lat,lng:t.lng}),"ms-MY"===i&&(o.noPaging=1);const n=[l(h.PATHS.GET_CITY_BY_IP,Object.assign(Object.assign({},a),o))];return"zh-TW"===i&&n.push(l(h.PATHS.GET_CITIES_LIST,{noPaging:1})),Promise.all(n).then((([t,a])=>{const i=Object.assign({},t);if(a){const e=i.cities.map((e=>e.id));i.cities=i.cities.concat(a.cities.filter((t=>!e.includes(t.id))))}e({type:fe.FetchCitiesByGeoIpComplete,payload:i})})).catch((e=>console.error("error loading cities by location",e)))}),[i,a,e]),fetchCitiesByKeyword:t.useCallback((function(t){return l(h.PATHS.GET_CITIES_LIST,{keyword:t}).then((t=>{e({type:fe.FetchCitiesByKeywordComplete,payload:t.cities})})).catch((e=>console.error("error loading cities by keyword",e)))}),[i,a,e]),fetchSearchResults:t.useCallback((function(t,l){const n=`${a}${h.PATHS.GET_SEARCH_V2}`;e({type:fe.FetchSearchResultsStart});const{defaultCity:s,selectedLocation:r,geoLocationCoordinates:c}=l;let d="";if(!r||!s)return void e({type:fe.FetchSearchResultsFinish});r.id===o.ID_OPTION_CURRENT_LOCATION?c||(d=s.id):d=r.id===o.ID_OPTION_ALL_LOCATION?"":r.id;const u=(null==c?void 0:c.lat)||"",p=(null==c?void 0:c.lng)||"";return fetch(Ye(n,{domain:a,searchType:"global",keyword:t.trim().length>he[i]?t.trim():"",city:d===o.ID_OPTION_CURRENT_LOCATION?"":d,lat:u,lng:p},i),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>e({type:fe.FetchSearchResultsComplete,payload:t}))).catch((e=>{console.log("error loading search results",{url:n,error:e})})).finally((()=>e({type:fe.FetchSearchResultsFinish})))}),[i,a,e])}}({dispatch:G,locale:I,careApiDomain:l}),de=t.useMemo((()=>{var e;return{id:o.ID_OPTION_CURRENT_LOCATION,name:k("booking.searchBar.currentLocation"),slug:null===(e=o.LOCALIZED_SLUGS[I])||void 0===e?void 0:e.CURRENT}}),[k,I]),ue=t.useMemo((()=>S.default(re,400)),[re]),me=t.useMemo((()=>S.default(ce,400)),[ce]);t.useEffect((()=>{""!==c&&c!==z.searchKeywords&&G({type:fe.UpdateInitialSearchValue,payload:c})}),[c]),t.useEffect((()=>{p&&(null==X?void 0:X.id)===o.ID_OPTION_CURRENT_LOCATION&&"unset"===J&&K()}),[p,X,J]),t.useEffect((()=>{n||J===V||("granted"===V&&H?G({type:fe.GrantGeoLocationPermission,payload:H}):"denied"===V&&G({type:fe.DenyGeoLocationPermission}))}),[J,V,H,n]),t.useEffect((()=>{U&&(x?x(U):window.location.href=`${d}${U}`)}),[U]);const be=t.useCallback((function(){G({type:fe.SelectCurrentLocation,payload:de})}),[k,G]);t.useEffect((()=>{var e;"denied"===J||ee||G({type:fe.SelectLocation,payload:{name:k("booking.searchBar.allLocations"),id:o.ID_OPTION_ALL_LOCATION,slug:null===(e=o.LOCALIZED_SLUGS[I])||void 0===e?void 0:e.ALL}}),w&&w(J,z.geoLocationCoordinates),i&&"granted"===J&&X&&G({type:fe.FocusInputSearch}),se({coordinates:z.geoLocationCoordinates})}),[J]),t.useEffect((()=>{X&&te&&ce(z.searchKeywords,z)}),[X,te]),t.useEffect((()=>{C!==le&&G({type:fe.SetInputSearchPlaceholder,payload:C})}),[C,le]),t.useEffect((()=>{oe?document.body.classList.add("care-popup-open"):document.body.classList.remove("care-popup-open")}),[oe]);const ye=t.useCallback((function(e){"ms-MY"===I&&B(!0),G({type:fe.SelectLocation,payload:e}),"ms-MY"!==I&&Ee(),O&&O(e)}),[k,G]);function ve(){"ms-MY"===I&&B(!0),i&&"granted"!==z.geoLocationPermission?K():(be(),"ms-MY"!==I&&Ee())}function xe(){var e;N.current&&(null===(e=N.current.querySelector('input[name="search-location"]'))||void 0===e||e.focus())}function Ee(){var e;N.current&&(null===(e=N.current.querySelector('input[name="search-results"]'))||void 0===e||e.focus())}function Se(){G({type:fe.CloseMobileModal})}function we(){return"location"!==Q?null:E.default.createElement(Z,{isLoading:q,cities:Y,onLocationClick:ye,onCurrentLocationClick:ve,isLocationLoading:q,geoLocationPermission:J,selectedLocation:X,isOptionAllLocation:b})}function Le(){return"search"!==Q?null:z.autoCompleteDisabled?i?E.default.createElement(Oe,{onClick:()=>{L({cityId:z.selectedLocation.id,keyword:W}),Se()}}):null:E.default.createElement(qe,{data:ae,state:z,dispatch:G,isMobile:!1,keyword:W,isLoading:ie,hideResults:y,isNavResultItem:v})}function Ie(){return E.default.createElement(ke,{isMobile:i,state:z,dispatch:G,debouncedFetchCitiesByKeyword:ue,debouncedFetchSearchResults:me,focusLocationInput:xe,focusSearchInput:Ee,renderLocationResults:we,renderSearchResults:Le,trackingAttributes:g,locationTrackingAttributes:f,onSearch:L,initalSearchValue:c})}return t.useEffect((()=>{if(window.visualViewport){const e=e=>{const t=e.target;$(null==t?void 0:t.height)};return window.visualViewport.addEventListener("resize",e,{passive:!0}),()=>{window.visualViewport.removeEventListener("resize",e)}}}),[$]),t.useEffect((()=>{if(X&&D&&"ms-MY"===I){const e=`/${X.slug}/hospital`;G({type:fe.NavigateTo,payload:e}),B(!1)}}),[D,I,X]),i?E.default.createElement(E.default.Fragment,null,E.default.createElement(P,null),E.default.createElement(A,{ref:F}),E.default.createElement(M,{id:"booking-search-bar",ref:N,"data-is-modal":i&&oe,style:{"--mobile-care-searchbar-height":oe&&_?`${_}px`:"100%"}},oe?E.default.createElement(E.default.Fragment,null,E.default.createElement(R,null,E.default.createElement(pe,{headingText:k("booking.searchBar.searchButton"),onLeftClick:Se}),Ie()),we(),Le()):E.default.createElement(ne,{onClick:function(){var t;return e.__awaiter(this,void 0,void 0,(function*(){F.current&&F.current.focus(),G({type:fe.OpenMobileModal}),yield Promise.resolve(),N.current&&(null===(t=N.current.querySelector('input[name="search-location"]'))||void 0===t||t.focus())}))},focused:Q,value:W,trackingAttributes:g,inputSearchPlaceholder:C}))):E.default.createElement(j,{id:"booking-search-bar",ref:N},Ie())},exports.BookingSearchBarV2=({isMobile:e,careApiDomain:i,geoLocationPermission:l,geoLocationCoordinates:n,initialSelectedCity:s,initialSearchValue:r="",initTypeSearch:c="hospital",initSpecialty:d,careFrontDomain:u="/care",isDebug:f=!1,gaTrackingSearchBar:m,gaTrackingLocationSearch:C,autoCompleteDisabled:b=!1,inputSearchPlaceholder:y="",routerPush:v,onGeoLocationPermissionChange:x,onChangeLocation:w})=>{const{locale:L,t:O}=a.useTranslations(),k=t.useRef(null),I=t.useRef(null),[j,M]=t.useState(c),{geoLocationPermission:R,geoLocationCoordinates:A}=T(),[N,P]=t.useReducer(ot,tt,(t=>Object.assign(Object.assign({},t),{isDebug:f,isMobile:e,geoLocationPermission:l||R||"unset",geoLocationCoordinates:n||A||null,searchKeywords:r,initialSelectedCity:s||null,selectedLocation:s||t.selectedLocation||null,searchLocationKeywords:(null==s?void 0:s.name)||t.searchLocationKeywords,autoCompleteDisabled:b,inputSearchPlaceholder:y,locale:L}))),{navigateTo:F,focusedSpecialty:_,searchKeywords:$,geoLocationPermission:D,selectedLocation:B,selectedSpecialty:V,initialSelectedCity:H,searchResults:K,isLoadingSearchResults:z}=N,{fetchCitiesByLocation:G,fetchCitiesByKeyword:Z,fetchSearchResults:U,fetchAllSpecialties:Q,fetchPopularKeys:q}=function({dispatch:e,careApiDomain:a,locale:i="vi-VN"}){const l=t.useCallback((function(t,o={}){const l=`${a}${t}`;return e({type:at.FetchCitiesStart}),fetch(Ye(l,o,i),{method:"GET"}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:(console.log("error loading cities",e),Promise.reject(e)))).finally((()=>e({type:at.FetchCitiesFinish})))}),[i]);return{fetchCitiesByLocation:t.useCallback((function({coordinates:t}){let a={};const o={};t&&(a={lat:t.lat,lng:t.lng}),"ms-MY"===i&&(o.noPaging=1);const n=[l(h.PATHS.GET_CITY_BY_IP,Object.assign(Object.assign({},a),o))];return"zh-TW"===i&&n.push(l(h.PATHS.GET_CITIES_LIST,{noPaging:1})),Promise.all(n).then((([t,a])=>{const i=Object.assign({},t);if(a){const e=i.cities.map((e=>e.id));i.cities=i.cities.concat(a.cities.filter((t=>!e.includes(t.id))))}e({type:at.FetchCitiesByGeoIpComplete,payload:i})})).catch((e=>console.error("error loading cities by location",e)))}),[i,a,e]),fetchCitiesByKeyword:t.useCallback((function(t){return l(h.PATHS.GET_CITIES_LIST,{keyword:t}).then((t=>{e({type:at.FetchCitiesByKeywordComplete,payload:t.cities})})).catch((e=>console.error("error loading cities by keyword",e)))}),[i,a,e]),fetchSearchResults:t.useCallback((function(t,l,n,s){const r="specialty"===n?`${a}${h.PATHS.GET_SEARCH_SPECIALTY}`:`${a}${h.PATHS.GET_SEARCH_V2}`;e({type:at.FetchSearchResultsStart});const{selectedLocation:c,geoLocationCoordinates:d,selectedSpecialty:u}=l;let p="";if(!c)return void e({type:at.FetchSearchResultsFinish});p=c.id===o.ID_OPTION_ALL_LOCATION?"":c.id;const g=(null==d?void 0:d.lat)||"",f=(null==d?void 0:d.lng)||"",m=(null==u?void 0:u.id)>0?null==u?void 0:u.id:"";return fetch(Ye(r,{domain:a,searchType:n||"global",keyword:t.trim().length>et[i]?t.trim():"",city:p===o.ID_OPTION_CURRENT_LOCATION?"":p,lat:g,lng:f,specialty_id:m},i),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>{e({type:at.FetchSearchResultsComplete,payload:{key:n,searches:t.searches||t.specialties||[]}}),s&&e({type:at.UpdateInitialSearchResults,payload:{key:n,searches:t.searches||t.specialties||[]}})})).catch((e=>{console.log("error loading search results",{url:r,error:e})})).finally((()=>e({type:at.FetchSearchResultsFinish})))}),[i,a,e]),fetchAllSpecialties:t.useCallback((function(){const t=`${a}${h.PATHS.GET_SEARCH_SPECIALTY}`;return fetch(Ye(t,{domain:a,searchType:""},i),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>{e({type:at.FetchAllSpecialties,payload:t.specialties||[]})})).catch((e=>{console.log("error loading search results",{url:t,error:e})}))}),[i,a,e]),fetchPopularKeys:t.useCallback((function(t){const o=`${a}${h.PATHS.GET_SEARCH_POPULAR_KEY}`;return fetch(Ye(o,{domain:a,searchType:_t[t],sort_by:"display_order",sort_order:"asc"},i)).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>{e({type:at.FetchPopularKeys,payload:t.popular_searches||[]})})).catch((e=>{console.log("error loading search results",{url:o,error:e})}))}),[i,a,e])}}({dispatch:P,locale:L,careApiDomain:i}),Y=t.useMemo((()=>o.LOCALIZED_SLUGS[L]),[L]),W=t.useMemo((()=>({doctor:{name:O("booking.searchPopup.doctors"),icon:E.default.createElement(ft,null),slug:Y.DOCTOR},service:{name:O("booking.searchPopup.services"),icon:E.default.createElement(mt,null),slug:Y.SERVICE},hospital:{name:O("booking.searchPopup.hospitals"),icon:E.default.createElement(Ct,null),slug:Y.HOSPITAL},specialty:{name:O("booking.searchPopup.specialties"),icon:E.default.createElement(bt,null),slug:Y.SPECIALTIES}})),[j]),J=t.useMemo((()=>S.default(Z,400)),[Z]),X=t.useMemo((()=>S.default(U,400)),[U]),ee=t.useCallback((function(e){P({type:at.SelectLocation,payload:e}),te(),w&&w(e)}),[O,P]);function te(){var e;k.current&&(null===(e=k.current.querySelector('input[name="search-results"]'))||void 0===e||e.focus())}return p.useOutsideClick(I,(()=>{P({type:at.ClickOutsideInputSearchSpecialty})})),t.useEffect((()=>{var t;"denied"===D||H||P({type:at.SelectLocation,payload:{name:O("booking.searchBar.allLocations"),id:o.ID_OPTION_ALL_LOCATION,slug:null===(t=o.LOCALIZED_SLUGS[L])||void 0===t?void 0:t.ALL}}),x&&x(D,N.geoLocationCoordinates),e&&"granted"===D&&B&&P({type:at.FocusInputSearch}),G({coordinates:N.geoLocationCoordinates})}),[D]),t.useEffect((()=>{const e=d||{name:O("booking.searchBar.allSpecialties"),id:-1,thumbnail:"",total_doctor:0,slug:Y.SPECIALTIES};N.selectedSpecialty||P({type:at.SelectSpecialty,payload:e})}),[d,N.selectedSpecialty]),t.useEffect((()=>{Q()}),[]),t.useEffect((()=>{q(j)}),[j]),t.useEffect((()=>{F&&(v?v(F):window.location.href=`${u}${F}`)}),[F]),t.useEffect((()=>{U(N.searchKeywords,N,j,!0)}),[B,V,j]),E.default.createElement(We,{ref:k},E.default.createElement(Ft,{currentTab:j,setCurrentTab:M,isMobile:e}),E.default.createElement(Je,{className:"booking-search-container"},E.default.createElement(Xe,null,E.default.createElement("div",{ref:I},E.default.createElement(g.Flex,{gap:"12px",justify:"space-between",align:"center",direction:e?"column":"row",className:"flex-search-input"},"specialty"!==j&&E.default.createElement(Lt,{state:N,isMobile:e,dispatch:P,debouncedFetchCitiesByKeyword:J,selectedLocation:B,onLocationClick:ee,trackingAttributes:C}),E.default.createElement(vt,{type:j,isMobile:e,state:N,dispatch:P,debouncedFetchSearchResults:X,initalSearchValue:r,focusSearchInput:te,typeInformation:W,trackingAttributes:m,isLoading:z}),E.default.createElement(g.Button,{size:e?"md":"lg",fullWidth:e,onClick:function(){let e="";const{slug:t}=W[j];let a="";("doctor"===j||"hospital"===j)&&N.selectedSpecialty.id>0&&(a=`&specialtyId=${N.selectedSpecialty.id}`),e="specialty"===j?`/${t}?q=${$}${a}`:`/${B.slug}/${t}?q=${$}${a}`,e&&P({type:at.NavigateTo,payload:e})},styles:{root:{height:e?"40px":"48px"}}},O("booking.searchBar.searchButton"))),"specialty"!==j&&N.popularKeys.length>0&&E.default.createElement(Nt,{type:j,state:N,typeInformation:W,dispatch:P}),"specialty"===j&&"search"===_&&E.default.createElement(jt,{state:N,isMobile:e,dispatch:P,specialties:(null==K?void 0:K.specialty)||[],isLoading:z})))))},exports.ChevronDown=I,exports.types=Dt;
|
|
759
|
+
`,Ft=({currentTab:e,isMobile:i,setCurrentTab:o})=>{const{t:l}=a.useTranslations(),n=t.useMemo((()=>({root:{overflowY:i?"hidden":"initial",overflowX:i?"auto":"initial"},tabsList:{background:"rgba(255, 255, 255, 0)",borderBottom:"none",flexWrap:"nowrap",".mantine-Tabs-tab":{"&:last-child":{"&:after":{display:"none"}}}},tab:{padding:i?"12px 16px 12px 16px":"15px 40px 15px 40px",borderTop:"2px solid transparent",borderBottom:"none",margin:0,borderRadius:0,position:"relative",width:"auto",'&[data-active="true"]':{borderColor:"#2d87f3",backgroundColor:"#ffffff","&:after":{display:"none"},"&:before":{content:'""',width:"100%",height:"1px",position:"absolute",backgroundColor:"#ffffff",bottom:"-1px"}},"&:hover":{borderColor:"#2d87f3",backgroundColor:"#ffffff","&:before":{content:'""',width:"100%",height:"1px",position:"absolute",backgroundColor:"#ffffff",bottom:"-1px"}},"&:after":{content:'""',width:"1px",height:"24px",backgroundColor:"#E4E8EC",position:"absolute",right:"-1px"}},tabLabel:{color:"#595959",fontSize:i?"14px":"16px",fontWeight:600,lineHeight:i?"22px":"24px"}})),[i]);return E.default.createElement(Pt,{className:"booking-search-tab"},E.default.createElement(C.Container,null,E.default.createElement(g.Tabs,{value:e,onTabChange:e=>{o(e)},styles:n},E.default.createElement(g.Tabs.List,null,E.default.createElement(g.Tabs.Tab,{value:"hospital"},l("booking.searchPopup.hospitals")),E.default.createElement(g.Tabs.Tab,{value:"doctor"},l("booking.searchPopup.doctors")),E.default.createElement(g.Tabs.Tab,{value:"service"},l("booking.searchPopup.services")),E.default.createElement(g.Tabs.Tab,{value:"specialty"},l("booking.searchPopup.specialties"))))))};var _t;!function(e){e.doctor="doctor",e.service="hospital_service",e.hospital="hospital_branch"}(_t||(_t={}));var $t;!function(e){e[e.SPECIALTY=1]="SPECIALTY",e[e.DOCTOR=2]="DOCTOR",e[e.CLINIC=3]="CLINIC",e[e.SERVICE=4]="SERVICE"}($t||($t={}));var Dt=Object.freeze({__proto__:null,get RedirectType(){return $t}});exports.BookingSearchBar=({isMobile:i,careApiDomain:l,geoLocationPermission:n,geoLocationCoordinates:s,initialSelectedCity:r,initialSearchValue:c="",careFrontDomain:d="/care",isDebug:u=!1,askForGeolocationPermission:p=!1,gaTrackingSearchBar:g,gaTrackingLocationSearch:f,autoCompleteDisabled:m=!1,inputSearchPlaceholder:C="",isOptionAllLocation:b=!1,hideResults:y=[],isNavResultItem:v=!0,routerPush:x,onGeoLocationPermissionChange:w,onSearch:L,onChangeLocation:O})=>{const{t:k,locale:I}=a.useTranslations(),N=t.useRef(null),F=t.useRef(null),[_,$]=t.useState(void 0),[D,B]=t.useState(!1),{geoLocationPermission:V,geoLocationCoordinates:H,requestGeoLocation:K}=T(),[z,G]=t.useReducer(Ce,ge,(e=>Object.assign(Object.assign({},e),{isDebug:u,isMobile:i,geoLocationPermission:n||V||"unset",geoLocationCoordinates:s||H||null,searchKeywords:c,initialSelectedCity:r||null,selectedLocation:r||e.selectedLocation||null,searchLocationKeywords:(null==r?void 0:r.name)||e.searchLocationKeywords,autoCompleteDisabled:m,inputSearchPlaceholder:C,locale:I}))),{navigateTo:U,focused:Q,isLoadingCities:q,cities:Y,searchKeywords:W,geoLocationPermission:J,selectedLocation:X,initialSelectedCity:ee,defaultCity:te,searchResults:ae,isLoadingSearchResults:ie,isMobileModalOpened:oe,inputSearchPlaceholder:le}=z,{fetchCitiesByLocation:se,fetchCitiesByKeyword:re,fetchSearchResults:ce}=function({dispatch:e,careApiDomain:a,locale:i="vi-VN"}){const l=t.useCallback((function(t,o={}){const l=`${a}${t}`;return e({type:fe.FetchCitiesStart}),fetch(Ye(l,o,i),{method:"GET"}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:(console.log("error loading cities",e),Promise.reject(e)))).finally((()=>e({type:fe.FetchCitiesFinish})))}),[i]);return{fetchCitiesByLocation:t.useCallback((function({coordinates:t}){let a={};const o={};t&&(a={lat:t.lat,lng:t.lng}),"ms-MY"===i&&(o.noPaging=1);const n=[l(h.PATHS.GET_CITY_BY_IP,Object.assign(Object.assign({},a),o))];return"zh-TW"===i&&n.push(l(h.PATHS.GET_CITIES_LIST,{noPaging:1})),Promise.all(n).then((([t,a])=>{const i=Object.assign({},t);if(a){const e=i.cities.map((e=>e.id));i.cities=i.cities.concat(a.cities.filter((t=>!e.includes(t.id))))}e({type:fe.FetchCitiesByGeoIpComplete,payload:i})})).catch((e=>console.error("error loading cities by location",e)))}),[i,a,e]),fetchCitiesByKeyword:t.useCallback((function(t){return l(h.PATHS.GET_CITIES_LIST,{keyword:t}).then((t=>{e({type:fe.FetchCitiesByKeywordComplete,payload:t.cities})})).catch((e=>console.error("error loading cities by keyword",e)))}),[i,a,e]),fetchSearchResults:t.useCallback((function(t,l){const n=`${a}${h.PATHS.GET_SEARCH_V2}`;e({type:fe.FetchSearchResultsStart});const{defaultCity:s,selectedLocation:r,geoLocationCoordinates:c}=l;let d="";if(!r||!s)return void e({type:fe.FetchSearchResultsFinish});r.id===o.ID_OPTION_CURRENT_LOCATION?c||(d=s.id):d=r.id===o.ID_OPTION_ALL_LOCATION?"":r.id;const u=(null==c?void 0:c.lat)||"",p=(null==c?void 0:c.lng)||"";return fetch(Ye(n,{domain:a,searchType:"global",keyword:t.trim().length>he[i]?t.trim():"",city:d===o.ID_OPTION_CURRENT_LOCATION?"":d,lat:u,lng:p},i),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>e({type:fe.FetchSearchResultsComplete,payload:t}))).catch((e=>{console.log("error loading search results",{url:n,error:e})})).finally((()=>e({type:fe.FetchSearchResultsFinish})))}),[i,a,e])}}({dispatch:G,locale:I,careApiDomain:l}),de=t.useMemo((()=>{var e;return{id:o.ID_OPTION_CURRENT_LOCATION,name:k("booking.searchBar.currentLocation"),slug:null===(e=o.LOCALIZED_SLUGS[I])||void 0===e?void 0:e.CURRENT}}),[k,I]),ue=t.useMemo((()=>S.default(re,400)),[re]),me=t.useMemo((()=>S.default(ce,400)),[ce]);t.useEffect((()=>{""!==c&&c!==z.searchKeywords&&G({type:fe.UpdateInitialSearchValue,payload:c})}),[c]),t.useEffect((()=>{p&&(null==X?void 0:X.id)===o.ID_OPTION_CURRENT_LOCATION&&"unset"===J&&K()}),[p,X,J]),t.useEffect((()=>{n||J===V||("granted"===V&&H?G({type:fe.GrantGeoLocationPermission,payload:H}):"denied"===V&&G({type:fe.DenyGeoLocationPermission}))}),[J,V,H,n]),t.useEffect((()=>{U&&(x?x(U):window.location.href=`${d}${U}`)}),[U]);const be=t.useCallback((function(){G({type:fe.SelectCurrentLocation,payload:de})}),[k,G]);t.useEffect((()=>{var e;"denied"===J||ee||G({type:fe.SelectLocation,payload:{name:k("booking.searchBar.allLocations"),id:o.ID_OPTION_ALL_LOCATION,slug:null===(e=o.LOCALIZED_SLUGS[I])||void 0===e?void 0:e.ALL}}),w&&w(J,z.geoLocationCoordinates),i&&"granted"===J&&X&&G({type:fe.FocusInputSearch}),se({coordinates:z.geoLocationCoordinates})}),[J]),t.useEffect((()=>{X&&te&&ce(z.searchKeywords,z)}),[X,te]),t.useEffect((()=>{C!==le&&G({type:fe.SetInputSearchPlaceholder,payload:C})}),[C,le]),t.useEffect((()=>{oe?document.body.classList.add("care-popup-open"):document.body.classList.remove("care-popup-open")}),[oe]);const ye=t.useCallback((function(e){"ms-MY"===I&&B(!0),G({type:fe.SelectLocation,payload:e}),"ms-MY"!==I&&Ee(),O&&O(e)}),[k,G]);function ve(){"ms-MY"===I&&B(!0),i&&"granted"!==z.geoLocationPermission?K():(be(),"ms-MY"!==I&&Ee())}function xe(){var e;N.current&&(null===(e=N.current.querySelector('input[name="search-location"]'))||void 0===e||e.focus())}function Ee(){var e;N.current&&(null===(e=N.current.querySelector('input[name="search-results"]'))||void 0===e||e.focus())}function Se(){G({type:fe.CloseMobileModal})}function we(){return"location"!==Q?null:E.default.createElement(Z,{isLoading:q,cities:Y,onLocationClick:ye,onCurrentLocationClick:ve,isLocationLoading:q,geoLocationPermission:J,selectedLocation:X,isOptionAllLocation:b})}function Le(){return"search"!==Q?null:z.autoCompleteDisabled?i?E.default.createElement(Oe,{onClick:()=>{L({cityId:z.selectedLocation.id,keyword:W}),Se()}}):null:E.default.createElement(qe,{data:ae,state:z,dispatch:G,isMobile:!1,keyword:W,isLoading:ie,hideResults:y,isNavResultItem:v})}function Ie(){return E.default.createElement(ke,{isMobile:i,state:z,dispatch:G,debouncedFetchCitiesByKeyword:ue,debouncedFetchSearchResults:me,focusLocationInput:xe,focusSearchInput:Ee,renderLocationResults:we,renderSearchResults:Le,trackingAttributes:g,locationTrackingAttributes:f,onSearch:L,initalSearchValue:c})}return t.useEffect((()=>{if(window.visualViewport){const e=e=>{const t=e.target;$(null==t?void 0:t.height)};return window.visualViewport.addEventListener("resize",e,{passive:!0}),()=>{window.visualViewport.removeEventListener("resize",e)}}}),[$]),t.useEffect((()=>{if(X&&D&&"ms-MY"===I){const e=`/${X.slug}/hospital`;G({type:fe.NavigateTo,payload:e}),B(!1)}}),[D,I,X]),i?E.default.createElement(E.default.Fragment,null,E.default.createElement(P,null),E.default.createElement(A,{ref:F}),E.default.createElement(M,{id:"booking-search-bar",ref:N,"data-is-modal":i&&oe,style:{"--mobile-care-searchbar-height":oe&&_?`${_}px`:"100%"}},oe?E.default.createElement(E.default.Fragment,null,E.default.createElement(R,null,E.default.createElement(pe,{headingText:k("booking.searchBar.searchButton"),onLeftClick:Se}),Ie()),we(),Le()):E.default.createElement(ne,{onClick:function(){var t;return e.__awaiter(this,void 0,void 0,(function*(){F.current&&F.current.focus(),G({type:fe.OpenMobileModal}),yield Promise.resolve(),N.current&&(null===(t=N.current.querySelector('input[name="search-location"]'))||void 0===t||t.focus())}))},focused:Q,value:W,trackingAttributes:g,inputSearchPlaceholder:C}))):E.default.createElement(j,{id:"booking-search-bar",ref:N},Ie())},exports.BookingSearchBarV2=({isMobile:e,careApiDomain:i,geoLocationPermission:l,geoLocationCoordinates:n,initialSelectedCity:s,initialSearchValue:r="",initTypeSearch:c="hospital",initSpecialty:d,careFrontDomain:u="/care",isDebug:f=!1,gaTrackingSearchBar:m,gaTrackingLocationSearch:C,autoCompleteDisabled:b=!1,inputSearchPlaceholder:y="",routerPush:v,onGeoLocationPermissionChange:x,onChangeLocation:w})=>{const{locale:L,t:O}=a.useTranslations(),k=t.useRef(null),I=t.useRef(null),[j,M]=t.useState(c),{geoLocationPermission:R,geoLocationCoordinates:A}=T(),[N,P]=t.useReducer(ot,tt,(t=>Object.assign(Object.assign({},t),{isDebug:f,isMobile:e,geoLocationPermission:l||R||"unset",geoLocationCoordinates:n||A||null,searchKeywords:r,initialSelectedCity:s||null,selectedLocation:s||t.selectedLocation||null,searchLocationKeywords:(null==s?void 0:s.name)||t.searchLocationKeywords,autoCompleteDisabled:b,inputSearchPlaceholder:y,locale:L}))),{navigateTo:F,focusedSpecialty:_,searchKeywords:$,geoLocationPermission:D,selectedLocation:B,selectedSpecialty:V,initialSelectedCity:H,searchResults:K,isLoadingSearchResults:z}=N,{fetchCitiesByLocation:G,fetchCitiesByKeyword:Z,fetchSearchResults:U,fetchAllSpecialties:Q,fetchPopularKeys:q}=function({dispatch:e,careApiDomain:a,locale:i="vi-VN"}){const l=t.useCallback((function(t,o={}){const l=`${a}${t}`;return e({type:at.FetchCitiesStart}),fetch(Ye(l,o,i),{method:"GET"}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:(console.log("error loading cities",e),Promise.reject(e)))).finally((()=>e({type:at.FetchCitiesFinish})))}),[i]);return{fetchCitiesByLocation:t.useCallback((function({coordinates:t}){let a={};const o={};t&&(a={lat:t.lat,lng:t.lng}),"ms-MY"===i&&(o.noPaging=1);const n=[l(h.PATHS.GET_CITY_BY_IP,Object.assign(Object.assign({},a),o))];return"zh-TW"===i&&n.push(l(h.PATHS.GET_CITIES_LIST,{noPaging:1})),Promise.all(n).then((([t,a])=>{const i=Object.assign({},t);if(a){const e=i.cities.map((e=>e.id));i.cities=i.cities.concat(a.cities.filter((t=>!e.includes(t.id))))}e({type:at.FetchCitiesByGeoIpComplete,payload:i})})).catch((e=>console.error("error loading cities by location",e)))}),[i,a,e]),fetchCitiesByKeyword:t.useCallback((function(t){return l(h.PATHS.GET_CITIES_LIST,{keyword:t}).then((t=>{e({type:at.FetchCitiesByKeywordComplete,payload:t.cities})})).catch((e=>console.error("error loading cities by keyword",e)))}),[i,a,e]),fetchSearchResults:t.useCallback((function(t,l,n,s){const r="specialty"===n?`${a}${h.PATHS.GET_SEARCH_SPECIALTY}`:`${a}${h.PATHS.GET_SEARCH_V2}`;e({type:at.FetchSearchResultsStart});const{selectedLocation:c,geoLocationCoordinates:d,selectedSpecialty:u}=l;let p="";if(!c)return void e({type:at.FetchSearchResultsFinish});p=c.id===o.ID_OPTION_ALL_LOCATION?"":c.id;const g=(null==d?void 0:d.lat)||"",f=(null==d?void 0:d.lng)||"",m=(null==u?void 0:u.id)>0?null==u?void 0:u.id:"",C=t.trim().length>et[i]?t.trim():"";return fetch(Ye(r,{domain:a,searchType:n||"global",keyword:C,city:p===o.ID_OPTION_CURRENT_LOCATION?"":p,lat:g,lng:f,specialty_id:m},i),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>{let a=[];"specialty"!==n&&(a=t.searches),"specialty"===n&&(a=C?t.specialties:t.default),e({type:at.FetchSearchResultsComplete,payload:{key:n,searches:a||[]}}),s&&e({type:at.UpdateInitialSearchResults,payload:{key:n,searches:a||[]}})})).catch((e=>{console.log("error loading search results",{url:r,error:e})})).finally((()=>e({type:at.FetchSearchResultsFinish})))}),[i,a,e]),fetchAllSpecialties:t.useCallback((function(){const t=`${a}${h.PATHS.GET_SEARCH_SPECIALTY}`;return fetch(Ye(t,{domain:a,searchType:""},i),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>{e({type:at.FetchAllSpecialties,payload:t.specialties||[]})})).catch((e=>{console.log("error loading search results",{url:t,error:e})}))}),[i,a,e]),fetchPopularKeys:t.useCallback((function(t){const o=`${a}${h.PATHS.GET_SEARCH_POPULAR_KEY}`;return fetch(Ye(o,{domain:a,searchType:_t[t],sort_by:"display_order",sort_order:"asc"},i)).then((e=>e.json())).then((e=>1===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e))).then((t=>{e({type:at.FetchPopularKeys,payload:t.popular_searches||[]})})).catch((e=>{console.log("error loading search results",{url:o,error:e})}))}),[i,a,e])}}({dispatch:P,locale:L,careApiDomain:i}),Y=t.useMemo((()=>o.LOCALIZED_SLUGS[L]),[L]),W=t.useMemo((()=>({doctor:{name:O("booking.searchPopup.doctors"),icon:E.default.createElement(ft,null),slug:Y.DOCTOR},service:{name:O("booking.searchPopup.services"),icon:E.default.createElement(mt,null),slug:Y.SERVICE},hospital:{name:O("booking.searchPopup.hospitals"),icon:E.default.createElement(Ct,null),slug:Y.HOSPITAL},specialty:{name:O("booking.searchPopup.specialties"),icon:E.default.createElement(bt,null),slug:Y.SPECIALTIES}})),[j]),J=t.useMemo((()=>S.default(Z,400)),[Z]),X=t.useMemo((()=>S.default(U,400)),[U]),ee=t.useCallback((function(e){P({type:at.SelectLocation,payload:e}),te(),w&&w(e)}),[O,P]);function te(){var e;k.current&&(null===(e=k.current.querySelector('input[name="search-results"]'))||void 0===e||e.focus())}return p.useOutsideClick(I,(()=>{P({type:at.ClickOutsideInputSearchSpecialty})})),t.useEffect((()=>{var t;"denied"===D||H||P({type:at.SelectLocation,payload:{name:O("booking.searchBar.allLocations"),id:o.ID_OPTION_ALL_LOCATION,slug:null===(t=o.LOCALIZED_SLUGS[L])||void 0===t?void 0:t.ALL}}),x&&x(D,N.geoLocationCoordinates),e&&"granted"===D&&B&&P({type:at.FocusInputSearch}),G({coordinates:N.geoLocationCoordinates})}),[D]),t.useEffect((()=>{const e=d||{name:O("booking.searchBar.allSpecialties"),id:-1,thumbnail:"",total_doctor:0,slug:Y.SPECIALTIES};N.selectedSpecialty||P({type:at.SelectSpecialty,payload:e})}),[d,N.selectedSpecialty]),t.useEffect((()=>{Q()}),[]),t.useEffect((()=>{q(j)}),[j]),t.useEffect((()=>{F&&(v?v(F):window.location.href=`${u}${F}`)}),[F]),t.useEffect((()=>{U(N.searchKeywords,N,j,!0)}),[B,V,j]),E.default.createElement(We,{ref:k},E.default.createElement(Ft,{currentTab:j,setCurrentTab:M,isMobile:e}),E.default.createElement(Je,{className:"booking-search-container"},E.default.createElement(Xe,null,E.default.createElement("div",{ref:I},E.default.createElement(g.Flex,{gap:"12px",justify:"space-between",align:"center",direction:e?"column":"row",className:"flex-search-input"},"specialty"!==j&&E.default.createElement(Lt,{state:N,isMobile:e,dispatch:P,debouncedFetchCitiesByKeyword:J,selectedLocation:B,onLocationClick:ee,trackingAttributes:C}),E.default.createElement(vt,{type:j,isMobile:e,state:N,dispatch:P,debouncedFetchSearchResults:X,initalSearchValue:r,focusSearchInput:te,typeInformation:W,trackingAttributes:m,isLoading:z}),E.default.createElement(g.Button,{size:e?"md":"lg",fullWidth:e,onClick:function(){let e="";const{slug:t}=W[j];let a="";("doctor"===j||"hospital"===j)&&N.selectedSpecialty.id>0&&(a=`&specialtyId=${N.selectedSpecialty.id}`),e="specialty"===j?`/${t}?q=${$}${a}`:`/${B.slug}/${t}?q=${$}${a}`,e&&P({type:at.NavigateTo,payload:e})},styles:{root:{height:e?"40px":"48px"}}},O("booking.searchBar.searchButton"))),"specialty"!==j&&N.popularKeys.length>0&&E.default.createElement(Nt,{type:j,state:N,typeInformation:W,dispatch:P}),"specialty"===j&&"search"===_&&E.default.createElement(jt,{state:N,isMobile:e,dispatch:P,specialties:(null==K?void 0:K.specialty)||[],isLoading:z})))))},exports.ChevronDown=I,exports.types=Dt;
|
package/build/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./Onboarding-
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./Onboarding-41cd0c5b.js");Object.defineProperty(exports,"BabyGrowthChartDuration",{enumerable:!0,get:function(){return e.BabyGrowthChartDuration}}),Object.defineProperty(exports,"BabyGrowthChartType",{enumerable:!0,get:function(){return e.BabyGrowthChartType}}),Object.defineProperty(exports,"BabyGrowthResultTab",{enumerable:!0,get:function(){return e.BabyGrowthResultTab}}),Object.defineProperty(exports,"Gender",{enumerable:!0,get:function(){return e.Gender}}),Object.defineProperty(exports,"LOCALE",{enumerable:!0,get:function(){return e.LOCALE}}),Object.defineProperty(exports,"OnboardingStep",{enumerable:!0,get:function(){return e.OnboardingStep}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var e=require("./tslib.es6-4eb751d0.js"),t=require("react"),o=require("./getDynamicHealthTool-f0248328.js");exports.useHealthToolsCache=a=>{const[i,l]=t.useState([]);t.useEffect((()=>{e.__awaiter(void 0,void 0,void 0,(function*(){const e=yield o.getDynamicHealthToolWithCache(a);l(e)}))}),[o.getDynamicHealthToolWithCache,a]);const r=t.useCallback((e=>{var t;return(null===(t=i.find((t=>t.template===e)))||void 0===t?void 0:t.link)||""}),[i]);return{allTools:i,getHealthToolLink:r}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-
|
|
1
|
+
"use strict";var e=require("./tslib.es6-4eb751d0.js"),t=require("react"),r=require("./cookieHelper-c5f87e77.js"),n=require("./useUniqueId-2b12f9b4.js");function i(e){const t=(new TextEncoder).encode(e.trim().toLowerCase());return crypto.subtle.digest("SHA-256",t).then((e=>Array.from(new Uint8Array(e)).map((e=>e.toString(16).padStart(2,"0"))).join("")))}exports.useFbDataLayer=n=>{const o=t.useRef("");t.useEffect((()=>(e.__awaiter(void 0,void 0,void 0,(function*(){var e,t,a,u,l;if(!o.current){let e=yield fetch("https://api.ipify.org").then((e=>e.text()));e||(e=yield fetch("https://icanhazip.com").then((e=>e.text()))),o.current=e}if(null===(t=null===(e=window.localStorage)||void 0===e?void 0:e.setItem)||void 0===t||t.call(e,"fbClientIp",JSON.stringify({client_ip_address:(null===(a=o.current)||void 0===a?void 0:a.replace("\n",""))||"",client_user_agent:navigator.userAgent||""})),null==n?void 0:n.id){const[e,t,o,a,c,s]=yield Promise.all([n.email?i(n.email):null,n.phone?i(n.phone):null,n.birthday?i(n.birthday.split("-").join("")):null,n.gender?"m":"f",n.city_name?i(n.city_name).then((e=>e.replace(/\s/g,""))):null,n.name?i(n.name):null]);r.getCookie("_fbc"),r.getCookie("_fbp");const d={user_id:n.id};s&&(d.fn=s),e&&(d.em=e),t&&(d.ph=t),o&&(d.db=o),c&&(d.ct=c),null===(l=null===(u=window.localStorage)||void 0===u?void 0:u.setItem)||void 0===l||l.call(u,"fbDataLayer_userInfo",JSON.stringify(d))}})),()=>{})),[n])},exports.usePrevious=e=>{const r=t.useRef(),i=t.useRef(e);return n.useInitialMount()||i.current===e||(r.current=i.current,i.current=e),r.current},exports.useRafState=e=>{const[r,n]=t.useState(e),i=t.useRef(0),o=t.useCallback((e=>{cancelAnimationFrame(i.current),i.current=requestAnimationFrame((()=>{n(e)}))}),[]);return t.useEffect((()=>()=>cancelAnimationFrame(i.current))),[r,o]};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("react"),t=require("./translationsContext-
|
|
1
|
+
"use strict";var e=require("react"),t=require("./translationsContext-cce05878.js");function a(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=a(require("string-format"));exports.useTranslations=function(){const{values:a,locale:o}=e.useContext(t.TranslationsContext)||{locale:"en-PH"};return e.useMemo((()=>({t:(e,t)=>a?a[e]?t?n.default(a[e]||e,t):a[e]||e:(console.warn(`[useTranslations] Missing translation for key ${e} and locale ${o}`),t?n.default(e,t):e):(console.error("[useTranslations] t method called before translation values are loaded"),e),locale:o})),[a,o])};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var i=require("./Onboarding-41cd0c5b.js");const a={[i.LOCALE.Vietnam]:"VN",[i.LOCALE.Cambodia]:"KH",[i.LOCALE.Indonesia]:"ID",[i.LOCALE.Malaysia]:"MY",[i.LOCALE.PhilippinesEnglish]:"PH",[i.LOCALE.PhilippinesTagalog]:"PH",[i.LOCALE.Taiwan]:"TW",[i.LOCALE.Thailand]:"TH",[i.LOCALE.Myanmar]:"MM"};exports.MAPPED_LOCALE=a,exports.hiddenEmailChar=(i="")=>{const a=i.indexOf("@"),n=i.substring(0,a),L=n.length>3?3:n.length;return i.replace(i.substring(L,a),i.slice(L,a).replace(/./g,"x"))};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-
|
|
1
|
+
"use strict";var e=require("./tslib.es6-4eb751d0.js"),t=require("react"),a=require("@mantine/core"),r=require("styled-components"),l=require("./index-e464dc9d.js"),o=require("./theme-60584197.js"),i=require("./screenSizeContext-77599820.js"),n=require("./gAssets.js"),s=require("./index-f6821534.js"),d=require("./Onboarding-41cd0c5b.js"),c=require("./index-01dde56e.js");require("./translationsContext-cce05878.js");var u=require("string-format"),p=require("dayjs"),h=require("./index-d643704e.js"),m=require("./isProduction-ad420ef8.js"),g=require("react-keyed-flatten-children"),f=require("@mantine/hooks");require("@mantine/dates");var b=require("@mantine/carousel"),E=require("./useUniqueId-2b12f9b4.js");require("lodash/debounce");var x=require("./cookieHelper-c5f87e77.js"),v=require("slugify");function w(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function y(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(a){if("default"!==a){var r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:!0,get:function(){return e[a]}})}})),t.default=e,Object.freeze(t)}var C=w(t),L=y(t),_=w(r),O=w(u),A=w(p),T=w(g),S=w(v);const k=_.default.div`
|
|
2
2
|
background-color: var(--background-color, transparent);
|
|
3
3
|
color: white;
|
|
4
4
|
cursor: pointer;
|
package/build/vaccination.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./tslib.es6-
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./tslib.es6-4eb751d0.js"),t=require("react"),a=require("@mantine/core"),l=require("./utils-d9d36010.js");require("@mantine/dates"),require("./index-d643704e.js");var n=require("./Onboarding-41cd0c5b.js");require("./gAssets.js");var r=require("dayjs"),i=require("./screenSizeContext-77599820.js"),o=require("styled-components"),c=require("./theme-60584197.js");require("./isProduction-ad420ef8.js");var s=require("./useTranslations-54a6826c.js");require("./index-e464dc9d.js");var d=require("@mantine/hooks");require("lodash/debounce");var u=require("./index-adc33906.js");require("./translationsContext-cce05878.js"),require("string-format");var m=require("./index-f6821534.js"),f=require("./index-1cb4a497.js"),C=require("@mantine/form"),p=require("dayjs/plugin/customParseFormat"),g=require("./index-07edb6b3.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}require("./index-01dde56e.js"),require("react-keyed-flatten-children"),require("@mantine/carousel"),require("./useUniqueId-2b12f9b4.js"),require("./cookieHelper-c5f87e77.js"),require("slugify"),require("date-fns/locale"),require("lodash/throttle");var b=h(t),E=h(r),x=h(o),v=h(p);const y=x.default.div`
|
|
2
2
|
position: relative;
|
|
3
3
|
padding: 16px;
|
|
4
4
|
min-height: 110px;
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as t}from"./tslib.es6-62fd61aa.js";import{g as o}from"./core-1cee131e.js";import{n as i}from"./normalizeLink-6f9d1a59.js";import{c as l}from"./routing-a6c08233.js";const n=(t,o)=>{var i,l;if(!t)return{};const n="tl-PH"===o?"/fil":"";return{id:t.id,isSubot:t.is_subot,template:t.template,icon:t.icon,link:(null===(i=t.link)||void 0===i?void 0:i.startsWith("http"))?t.link:`${n}/health-tools`+(null===(l=t.link)||void 0===l?void 0:l.replace(`${n}/`,"/")),subtitle:t.subtitle,title:t.title}},e=o=>t(void 0,void 0,void 0,(function*(){var t,e;try{const a="tl-PH"===o?"lang=fil":"";let s=[];try{const r=yield fetch(i(`${l(o)}/wp-json/api/healthtools?ismenu=0${a?"&"+a:""}`)).then((t=>t.json()));s=(null===(e=null===(t=null==r?void 0:r.data)||void 0===t?void 0:t.map)||void 0===e?void 0:e.call(t,(t=>n(t,o))))||[]}catch(t){}return s}catch(t){console.error(t)}})),a=i=>t(void 0,void 0,void 0,(function*(){return(yield o("all-health-tools",(()=>e(i||"en-PH")),(t=>!!(null==t?void 0:t.length)),6e4))||[]}));export{a,n as f,e as g};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as e}from"./tslib.es6-62fd61aa.js";import t from"react";import{S as a,a as s}from"./index-1d2a3d09.js";const r=s=>{var{type:r,color:o,style:l}=s,c=e(s,["type","color","style"]);return t.createElement(a,Object.assign({type:r,"data-type":{h1:"headline-1",h2:"headline-2",h3:"headline-3",h4:"headline-4"}[r],style:Object.assign(Object.assign({},o&&{"--text-color":o}),l)},c))},o=a=>{var{type:r,color:o,style:l}=a,c=e(a,["type","color","style"]);return t.createElement(s,Object.assign({"data-type":r,style:Object.assign(Object.assign({},l),o&&{"--text-color":o})},c))};export{o as M,r as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as a}from"./tslib.es6-62fd61aa.js";import e from"react";var t="wIj6fkD";const s=s=>{var{size:r="base",type:o="regular",className:c,style:n,children:d,color:i,dataEventCategory:l,dataEventAction:p,dataEventLabel:v,as:m="p",wordWrap:y,isUppercase:b}=s,g=a(s,["size","type","className","style","children","color","dataEventCategory","dataEventAction","dataEventLabel","as","wordWrap","isUppercase"]);const E=m;return e.createElement(E,Object.assign({"data-size":r,"data-type":o,style:Object.assign(Object.assign({},n),i?{"--custom-color":i}:void 0),className:`${t} ${c||""}`,"data-event-category":l,"data-event-action":p,"data-event-label":v,"data-word-wrap":y,"data-is-uppercase":b},g),d)};export{s as T};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import o,{useState as a,useEffect as e,useMemo as t,useCallback as i}from"react";import{M as d,N as l,E as s,O as n,Q as r}from"./utils-e1256807.js";import{_ as c,a as u}from"./tslib.es6-62fd61aa.js";import{u as v}from"./useTranslations-13e3deda.js";import{P as m}from"./paths-45db61cf.js";import{L as p}from"./constants-fd43ae8a.js";import"@mantine/core";import"@mantine/dates";import{d as g}from"./index-0f66c501.js";import"./Onboarding-7aae6591.js";import"./gAssets.js";import"dayjs";import"./screenSizeContext-239dadf0.js";import"styled-components";import"./theme-84310d70.js";import"./isProduction-5b883868.js";import"./index-1d2a3d09.js";import"@mantine/hooks";import"lodash/debounce";const y=({type:a="solid",className:e,style:t})=>o.createElement(d,{style:t,className:e,"data-diver-type":a,dividerType:a}),b={admin:"cardAuthor.admin",moderator:"cardAuthor.moderator",ambassador:"cardAuthor.ambassador",expert:"cardAuthor.expert",sponsor:"cardAuthor.sponsor",guide:"cardAuthor.guide",influencer:"cardAuthor.influencer"},E=a=>{var{siteType:e,role:t,title:i,styles:d,className:s}=a,n=c(a,["siteType","role","title","styles","className"]);const{t:r}=v(),u=t?(o=>["admin","moderator","ambassador","expert","sponsor","guide","influencer"].find((a=>a===o)))(t):"",{classes:m,cx:p}=l(void 0,{name:"AuthorBadge",styles:d});return u&&b[u]?o.createElement("div",Object.assign({className:p(m.root,s),"data-label-type":u,"data-is-marrybaby":"marryBaby"===e},n),i||r(b[u])):null};var f="Dudns9-";const h=({value:t,choices:i,onChange:d})=>{const[l,n]=a(t);return e((()=>{n(t)}),[t]),o.createElement("div",{className:f},i.map(((a,e)=>o.createElement(s,{dataEventCategory:a.dataEventCategory,dataEventAction:a.dataEventAction,dataEventLabel:a.dataEventLabel,size:"sm",variant:a.value===l?"primary":"tertiary",key:e,onClick:()=>{n(a.value),null==d||d(a.value)}},a.label||""))))},A=e=>{var{label:d,bookingId:l,bookingType:y="doctor",locale:b="vi-VN"}=e,E=c(e,["label","bookingId","bookingType","locale"]);const{t:f}=v(),[h,A]=a(!1),T=t((()=>"undefined"!=typeof window?window.location.href:""),[]),j=i((()=>u(void 0,void 0,void 0,(function*(){var o,a,e,t,i,d,s,c,u,v,E,f,h,T,j;const _="doctor"===y?m.GET_DOCTOR_DETAIL:"hospital"===y?m.GET_HOSPITAL_DETAIL:"service"===y?m.GET_SERVICE_DETAIL:"";try{A(!0);const m=yield n(r(_,{id:l,site:g[b]}),"get");if(1===(null==m?void 0:m._status)){const l="doctor"===y?{id:null===(a=null===(o=null==m?void 0:m._data)||void 0===o?void 0:o.doctor)||void 0===a?void 0:a.id,slug:null===(t=null===(e=null==m?void 0:m._data)||void 0===e?void 0:e.doctor)||void 0===t?void 0:t.slug,localSlug:null===(i=p[b])||void 0===i?void 0:i.DOCTOR}:"hospital"===y?{id:null===(s=null===(d=null==m?void 0:m._data)||void 0===d?void 0:d.branch)||void 0===s?void 0:s.id,slug:null===(u=null===(c=null==m?void 0:m._data)||void 0===c?void 0:c.branch)||void 0===u?void 0:u.slug,localSlug:null===(v=p[b])||void 0===v?void 0:v.HOSPITAL}:{id:null===(f=null===(E=null==m?void 0:m._data)||void 0===E?void 0:E.service)||void 0===f?void 0:f.id,slug:null===(T=null===(h=null==m?void 0:m._data)||void 0===h?void 0:h.service)||void 0===T?void 0:T.slug,localSlug:null===(j=p[b])||void 0===j?void 0:j.SERVICE};window.location.href=`/care/${l.localSlug}/${l.slug}-${l.id}/`}else A(!1)}catch(o){console.log(o),A(!1)}}))),[]);return l&&y?o.createElement(s,Object.assign({dataEventCategory:"Care",dataEventAction:"Comment - Quick Booking",dataEventLabel:T,onClick:j,loading:h},E),d||f("careBooking.bookAnAppointment")):null};export{E as A,h as B,y as D,A as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as o}from"./tslib.es6-62fd61aa.js";import t from"react";import{Indicator as s}from"@mantine/core";import"dayjs";import"./screenSizeContext-239dadf0.js";import"styled-components";import{t as e}from"./theme-84310d70.js";import"./index-0f66c501.js";import"./isProduction-5b883868.js";import"./Onboarding-7aae6591.js";import"./gAssets.js";const r=r=>{var{styles:i,color:n=e.colors.red700}=r,a=o(r,["styles","color"]);return t.createElement(s,Object.assign({inline:!0,position:"top-end",offset:4,styles:Object.assign({processing:{animationDirection:"alternate"}},i),color:n},a))};export{r as I};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as o}from"./tslib.es6-62fd61aa.js";import{useState as t,useEffect as i,useCallback as a}from"react";import{a as e}from"./getDynamicHealthTool-0430fe34.js";const l=l=>{const[n,r]=t([]);i((()=>{o(void 0,void 0,void 0,(function*(){const o=yield e(l);r(o)}))}),[e,l]);const s=a((o=>{var t;return(null===(t=n.find((t=>t.template===o)))||void 0===t?void 0:t.link)||""}),[n]);return{allTools:n,getHealthToolLink:s}};export{l as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{useContext as o,useMemo as a}from"react";import{T as e}from"./translationsContext-548d8e49.js";import r from"string-format";function t(){const{values:t,locale:n}=o(e)||{locale:"en-PH"};return a((()=>({t:(o,a)=>t?t[o]?a?r(t[o]||o,a):t[o]||o:(console.warn(`[useTranslations] Missing translation for key ${o} and locale ${n}`),a?r(o,a):o):(console.error("[useTranslations] t method called before translation values are loaded"),o),locale:n})),[t,n])}export{t as u};
|
package/build/index-943332ff.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-acb602d8.js"),t=require("react"),r=require("@mantine/core"),a=require("@mantine/dates"),s=require("./index-d8a74fa9.js"),i=require("./Onboarding-f30006ae.js"),n=require("./gAssets.js"),l=require("./utils-ccbc9e8e.js");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var u=o(t);exports.DatePicker=t=>{var o,{value:c,fullWidth:d=!0}=t,v=e.__rest(t,["value","fullWidth"]);return u.default.createElement(a.DatePickerInput,Object.assign({locale:l.MAPPED_LOCALE[process.env.UNIFY_LOCALE||i.LOCALE.Vietnam],valueFormat:null===(o=s.ISO_FORMAT[process.env.UNIFY_LOCALE||i.LOCALE.Vietnam])||void 0===o?void 0:o.dateFormat,size:"md",clearable:!1,popoverProps:d?{styles:{dropdown:{minWidth:"100%",display:"flex",justifyContent:"center",alignItems:"center"}}}:{},styles:{root:{position:"relative"},rightSection:{pointerEvents:"none",cursor:"default"}},rightSection:u.default.createElement(r.Image,{src:n.CommonGAssets.getAssetPath(v.isMB?"MB-calendar.svg":"OutlineCalendar.svg"),width:16,height:16}),value:c},v,{className:`input-control ${(null==v?void 0:v.className)||""}`}))};
|
package/build/index-b6bf0d44.js
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-acb602d8.js"),r=require("react"),t=require("@mantine/core"),i=require("./utils-ccbc9e8e.js");require("@mantine/dates");var n=require("./index-d8a74fa9.js");require("./Onboarding-f30006ae.js"),require("./gAssets.js"),require("dayjs");var o=require("./screenSizeContext-53b92594.js"),a=require("styled-components"),s=require("./theme-a8fac2fb.js");require("./isProduction-233fe264.js"),require("./translationsContext-735ad870.js"),require("string-format"),require("./index-64515772.js"),require("@mantine/hooks");var c=require("@mantine/form");function d(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var m=d(r),l=d(a);const u=r.createContext({}),[p,g,f]=c.createFormContext(),x=l.default.div`
|
|
2
|
-
margin-top: 70px;
|
|
3
|
-
display: flex;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
align-items: center;
|
|
6
|
-
justify-content: center;
|
|
7
|
-
&.similac {
|
|
8
|
-
margin-top: 16px;
|
|
9
|
-
}
|
|
10
|
-
`,h=l.default(t.Container)`
|
|
11
|
-
&.hhg-comp-onboarding-container.hhg-comp-onboarding-container {
|
|
12
|
-
display: flex;
|
|
13
|
-
flex-direction: column;
|
|
14
|
-
align-items: center;
|
|
15
|
-
height: 100%;
|
|
16
|
-
width: 100%;
|
|
17
|
-
max-width: 520px;
|
|
18
|
-
}
|
|
19
|
-
.header {
|
|
20
|
-
margin-bottom: 32px;
|
|
21
|
-
text-align: center;
|
|
22
|
-
${o.MediaQueries.mbDown} {
|
|
23
|
-
margin-bottom: 16px;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.input-control {
|
|
28
|
-
width: 100%;
|
|
29
|
-
}
|
|
30
|
-
.radio-group,
|
|
31
|
-
.input-control {
|
|
32
|
-
margin-bottom: 16px;
|
|
33
|
-
}
|
|
34
|
-
.form {
|
|
35
|
-
width: 100%;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/* .form-error {
|
|
39
|
-
margin-top: 32px;
|
|
40
|
-
font-size: 14px;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
.field-error {
|
|
44
|
-
margin-top: 10px;
|
|
45
|
-
font-size: 14px;
|
|
46
|
-
} */
|
|
47
|
-
|
|
48
|
-
.form-button {
|
|
49
|
-
width: 100%;
|
|
50
|
-
}
|
|
51
|
-
`,b=l.default.img`
|
|
52
|
-
margin-bottom: 38px;
|
|
53
|
-
`;exports.FormProvider=p,exports.Onboarding=o=>{var a,{heading:c,description:d,children:l,className:p,imgSrc:g,hiddenLogo:f=!1}=o,q=e.__rest(o,["heading","description","children","className","imgSrc","hiddenLogo"]);const{isMarryBaby:j,siteType:v}=r.useContext(u);return m.default.createElement(h,Object.assign({},q,{className:`hhg-comp-onboarding-container ${p}`,size:"sm"}),!f&&m.default.createElement(i.LogoIcon,{type:j?v:(null===(a=n.LOCALE_SPECS[process.env.UNIFY_LOCALE])||void 0===a?void 0:a.LOGO_TYPE)||"hellobacsi"}),m.default.createElement(x,{className:f?"similac":""},g&&m.default.createElement(b,{src:g,loading:"lazy"}),(c||d)&&m.default.createElement("div",{className:"header"},c&&m.default.createElement(t.Title,{order:3},c),d&&m.default.createElement(i.Text,{size:"p3",mt:8,color:s.theme.colors.gray600},d)),l))},exports.OnboardingContext=u,exports.useForm=f,exports.useFormContext=g;
|
package/build/index-e2a080f4.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-acb602d8.js"),r=require("react"),t=require("@mantine/core");require("dayjs"),require("./screenSizeContext-53b92594.js"),require("styled-components");var s=require("./theme-a8fac2fb.js");function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}require("./index-d8a74fa9.js"),require("./isProduction-233fe264.js"),require("./Onboarding-f30006ae.js"),require("./gAssets.js");var n=i(r);exports.Indicator=r=>{var{styles:i,color:o=s.theme.colors.red700}=r,a=e.__rest(r,["styles","color"]);return n.default.createElement(t.Indicator,Object.assign({inline:!0,position:"top-end",offset:4,styles:Object.assign({processing:{animationDirection:"alternate"}},i),color:o},a))};
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-acb602d8.js"),t=require("react"),a=require("./Onboarding-f30006ae.js"),n=require("./gAssets.js"),r=require("./theme-a8fac2fb.js"),o=require("styled-components"),i=require("./index-64515772.js"),l=require("./index-41aa0a61.js");function s(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var c=s(t),d=s(o);const u=d.default.div`
|
|
2
|
-
display: inline-flex;
|
|
3
|
-
overflow: hidden;
|
|
4
|
-
width: ${e=>e.size}px;
|
|
5
|
-
height: ${e=>e.size}px;
|
|
6
|
-
box-sizing: border-box;
|
|
7
|
-
align-items: center;
|
|
8
|
-
justify-content: center;
|
|
9
|
-
|
|
10
|
-
border: 1px solid #e4e8ec;
|
|
11
|
-
background-color: ${e=>e.backgroundColor||r.theme.colors.white};
|
|
12
|
-
border-radius: ${e=>e.borderRadius||"50%"};
|
|
13
|
-
& > * {
|
|
14
|
-
width: ${e=>e.iconSize}px;
|
|
15
|
-
height: ${e=>e.iconSize}px;
|
|
16
|
-
}
|
|
17
|
-
`,p=d.default.div`
|
|
18
|
-
display: inline-block;
|
|
19
|
-
height: 108px;
|
|
20
|
-
background-color: ${e=>e.theme.colors.white};
|
|
21
|
-
border-radius: 60px;
|
|
22
|
-
cursor: pointer;
|
|
23
|
-
&.selected-week-pill {
|
|
24
|
-
background-color: ${e=>e.theme.colors.pink100};
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
& > div:first-child {
|
|
28
|
-
margin: 4px 4px 0;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
& > p {
|
|
32
|
-
margin-top: 8px;
|
|
33
|
-
text-align: center;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
& > * {
|
|
37
|
-
pointer-events: none;
|
|
38
|
-
}
|
|
39
|
-
`,g=[a.LOCALE.Myanmar,a.LOCALE.Taiwan],x=d.default((a=>{var{icon:o,name:s,className:d,locale:x="en-PH",dataEventCategory:m,dataEventAction:b,dataEventLabel:f,onSelect:h}=a,v=e.__rest(a,["icon","name","className","locale","dataEventCategory","dataEventAction","dataEventLabel","onSelect"]);const y=t.useMemo((()=>null==d?void 0:d.includes("selected-week-pill")),[d]);return c.default.createElement(p,Object.assign({onClick:h,className:d?"week-pill".concat(" non-pointer-event-child ",d):"week-pill non-pointer-event-child","data-event-category":m,"data-event-action":b,"data-event-label":f},v),c.default.createElement(u,{size:64,iconSize:40,backgroundColor:r.theme.colors.white},c.default.createElement(i.ImageWrap,{src:o||n.CommonGAssets.getAssetPath("week_default.png"),alt:`week ${s}`})),y?c.default.createElement(l.Text,Object.assign({type:"semiBold",size:"n1",color:r.theme.colors.gray800},g.includes(x)&&{style:{fontSize:"10px"}}),s):c.default.createElement(l.Text,Object.assign({size:"n1",color:r.theme.colors.gray600},g.includes(x)&&{style:{fontSize:"10px"}}),s))}))`
|
|
40
|
-
box-shadow: 0px 0px 24px rgba(0, 0, 0, 0.08);
|
|
41
|
-
`,m=d.default(i.CentralCarousel.Slide)`
|
|
42
|
-
cursor: pointer;
|
|
43
|
-
> div * {
|
|
44
|
-
pointer-events: none;
|
|
45
|
-
}
|
|
46
|
-
`,b=d.default(i.CentralCarousel)`
|
|
47
|
-
.centerred-pill-wrapper {
|
|
48
|
-
padding: 16px 0;
|
|
49
|
-
}
|
|
50
|
-
`;exports.StyledCarousel=b,exports.StyledPill=x,exports.StyledSlide=m;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";var e=require("./tslib.es6-acb602d8.js"),t=require("react"),a=require("./getDynamicHealthTool-dea80808.js");exports.useHealthToolsCache=o=>{const[i,l]=t.useState([]);t.useEffect((()=>{e.__awaiter(void 0,void 0,void 0,(function*(){const e=yield a.getDynamicHealthToolWithCache(o);l(e)}))}),[a.getDynamicHealthToolWithCache,o]);const r=t.useCallback((e=>{var t;return(null===(t=i.find((t=>t.template===e)))||void 0===t?void 0:t.link)||""}),[i]);return{allTools:i,getHealthToolLink:r}};
|
package/build/utils-2a0a92fd.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";var a=require("./Onboarding-f30006ae.js");const i={[a.LOCALE.Vietnam]:"VN",[a.LOCALE.Cambodia]:"KH",[a.LOCALE.Indonesia]:"ID",[a.LOCALE.Malaysia]:"MY",[a.LOCALE.PhilippinesEnglish]:"PH",[a.LOCALE.PhilippinesTagalog]:"PH",[a.LOCALE.Taiwan]:"TW",[a.LOCALE.Thailand]:"TH",[a.LOCALE.Myanmar]:"MM"};exports.MAPPED_LOCALE=i,exports.hiddenEmailChar=(a="")=>{const i=a.indexOf("@"),e=a.substring(0,i),n=e.length>3?3:e.length;return a.replace(a.substring(n,i),a.slice(n,i).replace(/./g,"x"))};
|
/package/build/{BMI_BOYS.percentile.monthly-48e7ebde.js → BMI_BOYS.percentile.monthly-3757785a.js}
RENAMED
|
File without changes
|
/package/build/{BMI_BOYS.percentile.weekly-1a92165d.js → BMI_BOYS.percentile.weekly-3d4d8ac0.js}
RENAMED
|
File without changes
|
/package/build/{BMI_BOYS.percentile.yearly-c7f08171.js → BMI_BOYS.percentile.yearly-4f3b7049.js}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/build/{BMI_GIRLS.percentile.monthly-5f1e24cf.js → BMI_GIRLS.percentile.monthly-986b1cbb.js}
RENAMED
|
File without changes
|
/package/build/{BMI_GIRLS.percentile.weekly-d26655e5.js → BMI_GIRLS.percentile.weekly-a9b824c2.js}
RENAMED
|
File without changes
|
/package/build/{BMI_GIRLS.percentile.yearly-ac381ece.js → BMI_GIRLS.percentile.yearly-ff9bcd49.js}
RENAMED
|
File without changes
|
/package/build/{BMI_GIRLS.zscore.monthly-2763e1bf.js → BMI_GIRLS.zscore.monthly-cdc060c8.js}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|