@hhgtech/hhg-components 1.27.153 → 1.27.154
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.js +1 -1
- package/build/components.js +1 -1
- package/build/{constants-4f957bf1.js → constants-4bb1d33d.js} +1 -1
- package/build/{constants-724f3693.js → constants-e0fe0939.js} +1 -1
- package/build/constants.js +1 -1
- package/build/{core-b48b0440.js → core-d5ace86d.js} +1 -1
- package/build/ecom.js +1 -1
- package/build/esm/babyGrowth.js +9 -9
- package/build/esm/cache.js +1 -1
- package/build/esm/care.js +1 -1
- package/build/esm/components.js +1 -1
- package/build/esm/{constants-6a448cae.js → constants-bb592d87.js} +2 -2
- package/build/esm/{constants-d8636a01.js → constants-ede77eee.js} +1 -1
- package/build/esm/constants.js +1 -1
- package/build/esm/{core-4536cc25.js → core-14561d71.js} +1 -1
- package/build/esm/ecom.js +1 -1
- package/build/esm/footer.js +1 -1
- package/build/esm/gAssets.js +1 -1
- package/build/esm/{getDynamicHealthTool-1e27f7e3.js → getDynamicHealthTool-11436c03.js} +1 -1
- package/build/esm/{getSocialList-316e9141.js → getSocialList-07d25384.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-9fff7cf8.js → index-055c04c2.js} +1 -1
- package/build/esm/{index-dbbbb305.js → index-0cefeefb.js} +1 -1
- package/build/esm/index-1b1d8134.js +1 -0
- package/build/esm/{index-226c09bf.js → index-23a3b10b.js} +6 -6
- package/build/esm/{index-18df2d15.js → index-2edd91fd.js} +1 -1
- package/build/esm/{index-911ef162.js → index-433c4190.js} +1 -1
- package/build/esm/{index-a7edfb36.js → index-48ddad2b.js} +1 -1
- package/build/esm/{index-864a8b89.js → index-66ec59ce.js} +1 -1
- package/build/esm/{index-62ecf56a.js → index-75dfeb72.js} +1 -1
- package/build/esm/{index-6ad80e10.js → index-8576436d.js} +3 -3
- package/build/esm/{index-77ce1f0e.js → index-8f1912f1.js} +1 -1
- package/build/esm/{index-a0fc1ef4.js → index-9d32e317.js} +1 -1
- package/build/esm/{index-6da33d7f.js → index-a3f195da.js} +1 -1
- package/build/esm/{index-3764269a.js → index-bf09c5ae.js} +1 -1
- package/build/esm/{index-9af57ae9.js → index-c096f533.js} +1 -1
- package/build/esm/index-e9467986.js +1 -0
- package/build/esm/{index-f7429df6.js → index-efc1382a.js} +1 -1
- package/build/esm/{index-3107d233.js → index-f7d54b3e.js} +1 -1
- package/build/esm/{index-9e896146.js → index-fc471630.js} +1 -1
- package/build/esm/index.js +1 -1
- package/build/esm/{index.styled-18ea8428.js → index.styled-5f810be8.js} +1 -1
- package/build/esm/{index.styled-d6b0ebe7.js → index.styled-be95abd0.js} +1 -1
- package/build/esm/{index.styles-1b3ed9ef.js → index.styles-d8ab3053.js} +1 -1
- 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/onboardingV2.js +9 -9
- package/build/esm/pwg.js +2 -2
- package/build/esm/{routing-d8af5355.js → routing-998bc5c2.js} +1 -1
- package/build/esm/together.js +1 -1
- package/build/esm/{types-088474a6.js → types-7ad9947b.js} +1 -1
- package/build/esm/{types-06fb2c02.js → types-9e82bb64.js} +12 -12
- package/build/esm/types.js +1 -1
- package/build/esm/{useCategory-559c57b8.js → useCategory-e6bf1fff.js} +1 -1
- package/build/esm/useHealthToolCache-3e969843.js +1 -0
- package/build/esm/{useRafState-9fefcffa.js → useRafState-48a85c6f.js} +1 -1
- package/build/esm/{useTranslations-d7353bde.js → useTranslations-3a1f0a5e.js} +1 -1
- package/build/esm/{utils-623afa37.js → utils-de689222.js} +1 -1
- package/build/esm/{utils-e5cd1f3c.js → utils-ece766af.js} +1 -1
- package/build/esm/vaccination.js +1 -1
- package/build/footer.js +1 -1
- package/build/gAssets.js +1 -1
- package/build/{getDynamicHealthTool-5ba21d35.js → getDynamicHealthTool-2f8cdabb.js} +1 -1
- package/build/{getSocialList-90439a89.js → getSocialList-86cc5ebb.js} +1 -1
- package/build/hooks.js +1 -1
- package/build/i18n.js +1 -1
- package/build/i18nV2.js +1 -1
- package/build/{index-00c19b9f.js → index-07fb0fd8.js} +1 -1
- package/build/{index-2acc260d.js → index-0e97a8dc.js} +1 -1
- package/build/{index-2fe91496.js → index-364d4b5d.js} +1 -1
- package/build/{index-7bf93545.js → index-387326cf.js} +1 -1
- package/build/{index-a420166f.js → index-3e1d16c8.js} +1 -1
- package/build/index-3e9f9f38.js +1 -0
- package/build/{index-a95ca065.js → index-4059efb5.js} +1 -1
- package/build/{index-a5672035.js → index-4fa6567e.js} +1 -1
- package/build/{index-862175c1.js → index-6aea4edf.js} +1 -1
- package/build/{index-afdb815d.js → index-6e8f7158.js} +1 -1
- package/build/index-720f5789.js +1 -0
- package/build/{index-04a7d01c.js → index-83bb3b84.js} +1 -1
- package/build/{index-8e06dad9.js → index-9014ef1c.js} +1 -1
- package/build/{index-549ce0b0.js → index-a8def907.js} +1 -1
- package/build/{index-4ab271c4.js → index-b0496219.js} +1 -1
- package/build/{index-342ab33d.js → index-e44abb40.js} +1 -1
- package/build/{index-cb087664.js → index-efd2b19f.js} +1 -1
- package/build/{index-1d13b981.js → index-f855a850.js} +1 -1
- package/build/{index-0fc65688.js → index-fe972faf.js} +1 -1
- package/build/index.js +1 -1
- package/build/{index.styled-95d22b84.js → index.styled-026f22e1.js} +1 -1
- package/build/{index.styled-b8c1dc38.js → index.styled-62810db3.js} +1 -1
- package/build/{index.styles-9eafeaf6.js → index.styles-c31fed61.js} +1 -1
- 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/onboardingV2.js +5 -5
- package/build/pwg.js +1 -1
- package/build/{routing-006878c5.js → routing-b7e2b123.js} +1 -1
- package/build/together.js +1 -1
- package/build/{types-51ff6c0e.js → types-31c44090.js} +1 -1
- package/build/{types-5226e3ab.js → types-7e28c0e0.js} +1 -1
- package/build/types.js +1 -1
- package/build/{useCategory-e67b1843.js → useCategory-0145c866.js} +1 -1
- package/build/{useHealthToolCache-908eeae7.js → useHealthToolCache-adbea861.js} +1 -1
- package/build/{useRafState-450a8acf.js → useRafState-b4e0eb0b.js} +1 -1
- package/build/{useTranslations-7a6724a1.js → useTranslations-744c368a.js} +1 -1
- package/build/{utils-69d80ac6.js → utils-38055ed7.js} +1 -1
- package/build/{utils-5815c013.js → utils-ab0e1bde.js} +1 -1
- package/build/vaccination.js +1 -1
- package/package.json +1 -1
- package/build/esm/index-8bf77698.js +0 -1
- package/build/esm/index-9363a28e.js +0 -1
- package/build/esm/useHealthToolCache-0e0d41d0.js +0 -1
- package/build/index-43790e8a.js +0 -1
- package/build/index-c7b48042.js +0 -1
- /package/build/{BMI_BOYS.percentile.monthly-9ff20de9.js → BMI_BOYS.percentile.monthly-b15326e2.js} +0 -0
- /package/build/{BMI_BOYS.percentile.weekly-5f5a1c9f.js → BMI_BOYS.percentile.weekly-6ae77f86.js} +0 -0
- /package/build/{BMI_BOYS.percentile.yearly-26b83da5.js → BMI_BOYS.percentile.yearly-141205c6.js} +0 -0
- /package/build/{BMI_BOYS.zscore.monthly-9246d24e.js → BMI_BOYS.zscore.monthly-a5789eb2.js} +0 -0
- /package/build/{BMI_BOYS.zscore.weekly-973fc724.js → BMI_BOYS.zscore.weekly-f7ba1f0b.js} +0 -0
- /package/build/{BMI_BOYS.zscore.yearly-394008f9.js → BMI_BOYS.zscore.yearly-80553a0c.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.monthly-3914b8a4.js → BMI_GIRLS.percentile.monthly-f1508b0e.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.weekly-5ccf466b.js → BMI_GIRLS.percentile.weekly-e319d370.js} +0 -0
- /package/build/{BMI_GIRLS.percentile.yearly-15af99f6.js → BMI_GIRLS.percentile.yearly-58486c6c.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.monthly-f10cdc42.js → BMI_GIRLS.zscore.monthly-41ce4832.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.weekly-e77192bd.js → BMI_GIRLS.zscore.weekly-33776140.js} +0 -0
- /package/build/{BMI_GIRLS.zscore.yearly-7a401ed0.js → BMI_GIRLS.zscore.yearly-a84db944.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.monthly-88d2e4f5.js → HEAD CIRCUM_BOYS.percentile.monthly-375da0e0.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.weekly-174bff8b.js → HEAD CIRCUM_BOYS.percentile.weekly-0d9d57a6.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.percentile.yearly-1eb30865.js → HEAD CIRCUM_BOYS.percentile.yearly-8208df04.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.monthly-0d1354ec.js → HEAD CIRCUM_BOYS.zscore.monthly-097a6716.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.weekly-f6f42707.js → HEAD CIRCUM_BOYS.zscore.weekly-17647566.js} +0 -0
- /package/build/{HEAD CIRCUM_BOYS.zscore.yearly-91b637b7.js → HEAD CIRCUM_BOYS.zscore.yearly-db00f10b.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.monthly-7c4d7eb8.js → HEAD CIRCUM_GIRLS.percentile.monthly-cc68584f.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.weekly-1dc54c88.js → HEAD CIRCUM_GIRLS.percentile.weekly-75e999bf.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.percentile.yearly-0b608fb6.js → HEAD CIRCUM_GIRLS.percentile.yearly-d7543e3a.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.monthly-0421f807.js → HEAD CIRCUM_GIRLS.zscore.monthly-dc5c6082.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.weekly-4e40f8c4.js → HEAD CIRCUM_GIRLS.zscore.weekly-710cf924.js} +0 -0
- /package/build/{HEAD CIRCUM_GIRLS.zscore.yearly-4259f20e.js → HEAD CIRCUM_GIRLS.zscore.yearly-d5b2131b.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.monthly-e38d52a6.js → HEIGHT_BOYS.percentile.monthly-4337f046.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.weekly-277fa162.js → HEIGHT_BOYS.percentile.weekly-5dde3ca8.js} +0 -0
- /package/build/{HEIGHT_BOYS.percentile.yearly-71ad6997.js → HEIGHT_BOYS.percentile.yearly-e1012340.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.monthly-050e73a1.js → HEIGHT_BOYS.zscore.monthly-b78666c0.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.weekly-3b29e206.js → HEIGHT_BOYS.zscore.weekly-eaf01a98.js} +0 -0
- /package/build/{HEIGHT_BOYS.zscore.yearly-3fc3aa6d.js → HEIGHT_BOYS.zscore.yearly-ae0c7428.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.monthly-914e4ad5.js → HEIGHT_GIRLS.percentile.monthly-1b9fd0ad.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.weekly-50629625.js → HEIGHT_GIRLS.percentile.weekly-0d98606b.js} +0 -0
- /package/build/{HEIGHT_GIRLS.percentile.yearly-99c14cdc.js → HEIGHT_GIRLS.percentile.yearly-e3428998.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.monthly-8de672e8.js → HEIGHT_GIRLS.zscore.monthly-3ce4a8de.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.weekly-618a81c7.js → HEIGHT_GIRLS.zscore.weekly-8119e23f.js} +0 -0
- /package/build/{HEIGHT_GIRLS.zscore.yearly-d8a51a7b.js → HEIGHT_GIRLS.zscore.yearly-30e2e86e.js} +0 -0
- /package/build/{Onboarding-c82acdbe.js → Onboarding-b39b12a4.js} +0 -0
- /package/build/{Visible-18acebd4.js → Visible-07ee6516.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.monthly-82db3e1d.js → WEIGHT_BOYS.percentile.monthly-ef6e233b.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.weekly-0302efed.js → WEIGHT_BOYS.percentile.weekly-bc1f2e25.js} +0 -0
- /package/build/{WEIGHT_BOYS.percentile.yearly-d449b1a4.js → WEIGHT_BOYS.percentile.yearly-e953f8f6.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.monthly-2fa0e7fb.js → WEIGHT_BOYS.zscore.monthly-27640aea.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.weekly-84e818de.js → WEIGHT_BOYS.zscore.weekly-2dd51eb6.js} +0 -0
- /package/build/{WEIGHT_BOYS.zscore.yearly-75199782.js → WEIGHT_BOYS.zscore.yearly-b6159ca9.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.monthly-fd957a7b.js → WEIGHT_GIRLS.percentile.monthly-e2a14e0a.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.weekly-d4f103af.js → WEIGHT_GIRLS.percentile.weekly-0359eda4.js} +0 -0
- /package/build/{WEIGHT_GIRLS.percentile.yearly-51b573f5.js → WEIGHT_GIRLS.percentile.yearly-8eb1cea8.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.monthly-7c4e2425.js → WEIGHT_GIRLS.zscore.monthly-e80294cb.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.weekly-8c40e771.js → WEIGHT_GIRLS.zscore.weekly-7881629a.js} +0 -0
- /package/build/{WEIGHT_GIRLS.zscore.yearly-0af0013b.js → WEIGHT_GIRLS.zscore.yearly-37524d7b.js} +0 -0
- /package/build/{cookieHelper-4f4ff569.js → cookieHelper-5deb4ffc.js} +0 -0
- /package/build/{dataTransform-ef0aad5b.js → dataTransform-e675124f.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.monthly-9c5ed66f.js → BMI_BOYS.percentile.monthly-5aa4e7cc.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.weekly-10dd36f3.js → BMI_BOYS.percentile.weekly-698c6a47.js} +0 -0
- /package/build/esm/{BMI_BOYS.percentile.yearly-9897eb63.js → BMI_BOYS.percentile.yearly-1d6883f5.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.monthly-8921a683.js → BMI_BOYS.zscore.monthly-2304da2b.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.weekly-f9fb60a3.js → BMI_BOYS.zscore.weekly-1352ce0f.js} +0 -0
- /package/build/esm/{BMI_BOYS.zscore.yearly-ab846210.js → BMI_BOYS.zscore.yearly-26b35d00.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.monthly-812f4c9f.js → BMI_GIRLS.percentile.monthly-d3d01649.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.weekly-4b16d449.js → BMI_GIRLS.percentile.weekly-7bdb701f.js} +0 -0
- /package/build/esm/{BMI_GIRLS.percentile.yearly-da5cd007.js → BMI_GIRLS.percentile.yearly-fec46ae1.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.monthly-eeeb9658.js → BMI_GIRLS.zscore.monthly-ca2443f7.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.weekly-537a20ee.js → BMI_GIRLS.zscore.weekly-fde68b3e.js} +0 -0
- /package/build/esm/{BMI_GIRLS.zscore.yearly-2bf205fe.js → BMI_GIRLS.zscore.yearly-2b04d084.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.monthly-43390f66.js → HEAD CIRCUM_BOYS.percentile.monthly-dc86eced.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.weekly-79137ad6.js → HEAD CIRCUM_BOYS.percentile.weekly-7ee4d8a9.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.percentile.yearly-a9192412.js → HEAD CIRCUM_BOYS.percentile.yearly-fdf97de8.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.monthly-04d2c1a4.js → HEAD CIRCUM_BOYS.zscore.monthly-e83170cc.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.weekly-b28f7c9c.js → HEAD CIRCUM_BOYS.zscore.weekly-d1f9a3a0.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_BOYS.zscore.yearly-deee6cdb.js → HEAD CIRCUM_BOYS.zscore.yearly-f970ea18.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.monthly-0c0bb2ff.js → HEAD CIRCUM_GIRLS.percentile.monthly-5857617c.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.weekly-9122e8ef.js → HEAD CIRCUM_GIRLS.percentile.weekly-d0b4f05e.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.percentile.yearly-ff79254c.js → HEAD CIRCUM_GIRLS.percentile.yearly-0c7cacbd.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.monthly-583f8314.js → HEAD CIRCUM_GIRLS.zscore.monthly-ce59536d.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.weekly-3f694b54.js → HEAD CIRCUM_GIRLS.zscore.weekly-47159897.js} +0 -0
- /package/build/esm/{HEAD CIRCUM_GIRLS.zscore.yearly-1a70f197.js → HEAD CIRCUM_GIRLS.zscore.yearly-c0f47c8f.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.monthly-628ae682.js → HEIGHT_BOYS.percentile.monthly-34e36c62.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.weekly-1f6bfe49.js → HEIGHT_BOYS.percentile.weekly-c417c1cb.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.percentile.yearly-cd7be544.js → HEIGHT_BOYS.percentile.yearly-44d4092e.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.monthly-f186fed2.js → HEIGHT_BOYS.zscore.monthly-a343ecb2.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.weekly-2968e92d.js → HEIGHT_BOYS.zscore.weekly-69a79410.js} +0 -0
- /package/build/esm/{HEIGHT_BOYS.zscore.yearly-79e1afb0.js → HEIGHT_BOYS.zscore.yearly-d1edcf76.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.monthly-b45c2ff3.js → HEIGHT_GIRLS.percentile.monthly-06dae2d6.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.weekly-8995272f.js → HEIGHT_GIRLS.percentile.weekly-51f92824.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.percentile.yearly-a6090949.js → HEIGHT_GIRLS.percentile.yearly-8a524632.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.monthly-d57cbd7c.js → HEIGHT_GIRLS.zscore.monthly-0807da1f.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.weekly-c537e604.js → HEIGHT_GIRLS.zscore.weekly-658a94a7.js} +0 -0
- /package/build/esm/{HEIGHT_GIRLS.zscore.yearly-284471d8.js → HEIGHT_GIRLS.zscore.yearly-e14b0398.js} +0 -0
- /package/build/esm/{Onboarding-2b508269.js → Onboarding-8c3938e0.js} +0 -0
- /package/build/esm/{Visible-df0ec23c.js → Visible-9036d9ee.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.monthly-17795422.js → WEIGHT_BOYS.percentile.monthly-9eb984a3.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.weekly-74f40bb4.js → WEIGHT_BOYS.percentile.weekly-487c7199.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.percentile.yearly-6c2605fa.js → WEIGHT_BOYS.percentile.yearly-638911ee.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.monthly-e439ba17.js → WEIGHT_BOYS.zscore.monthly-b725b7b2.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.weekly-166698e7.js → WEIGHT_BOYS.zscore.weekly-e8521cf9.js} +0 -0
- /package/build/esm/{WEIGHT_BOYS.zscore.yearly-6a481594.js → WEIGHT_BOYS.zscore.yearly-4df79a53.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.monthly-570831bf.js → WEIGHT_GIRLS.percentile.monthly-de4b4e65.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.weekly-673216bc.js → WEIGHT_GIRLS.percentile.weekly-7b29e0e7.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.percentile.yearly-ad6855c7.js → WEIGHT_GIRLS.percentile.yearly-dbaac151.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.monthly-dffedf98.js → WEIGHT_GIRLS.zscore.monthly-cea7e78a.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.weekly-bf195ff3.js → WEIGHT_GIRLS.zscore.weekly-b49d5a13.js} +0 -0
- /package/build/esm/{WEIGHT_GIRLS.zscore.yearly-1dafc1fe.js → WEIGHT_GIRLS.zscore.yearly-daac090b.js} +0 -0
- /package/build/esm/{cookieHelper-fd8c7baa.js → cookieHelper-d48ad6f0.js} +0 -0
- /package/build/esm/{dataTransform-08bf17cc.js → dataTransform-fdbb9245.js} +0 -0
- /package/build/esm/{index-cc1afaef.js → index-5a0dc9ca.js} +0 -0
- /package/build/esm/{index-7e4df5cc.js → index-8b412d39.js} +0 -0
- /package/build/esm/{index-f37be36c.js → index-9f3d92ea.js} +0 -0
- /package/build/esm/{index-213c0fdc.js → index-fa94e465.js} +0 -0
- /package/build/esm/{isProduction-d4dd3302.js → isProduction-52c76560.js} +0 -0
- /package/build/esm/{localizeNumberFormat-9505e563.js → localizeNumberFormat-29ddaab1.js} +0 -0
- /package/build/esm/{normalizeLink-c30efb38.js → normalizeLink-59af508a.js} +0 -0
- /package/build/esm/{number-ae79e735.js → number-860c5b25.js} +0 -0
- /package/build/esm/{paths-bb6215b2.js → paths-9a39b106.js} +0 -0
- /package/build/esm/{screenSizeContext-01c0829e.js → screenSizeContext-be2375b1.js} +0 -0
- /package/build/esm/{theme-78a0ec17.js → theme-17fe8568.js} +0 -0
- /package/build/esm/{translationsContext-e7d1541a.js → translationsContext-8efd3a3b.js} +0 -0
- /package/build/esm/{tslib.es6-e075fd14.js → tslib.es6-4213f703.js} +0 -0
- /package/build/esm/{types-f429485e.js → types-028758a2.js} +0 -0
- /package/build/esm/{useIsInit-ac45f1a8.js → useIsInit-aacf8bc0.js} +0 -0
- /package/build/esm/{useOutsideClick-dc84e0ad.js → useOutsideClick-3515d44f.js} +0 -0
- /package/build/esm/{useScrollbarSize-e7f8192b.js → useScrollbarSize-6e27c5de.js} +0 -0
- /package/build/{index-0dc7faf9.js → index-28d898bb.js} +0 -0
- /package/build/{index-732abd33.js → index-5852b347.js} +0 -0
- /package/build/{index-ee5cc88f.js → index-6bdb89ed.js} +0 -0
- /package/build/{index-f749258d.js → index-da18d6d1.js} +0 -0
- /package/build/{isProduction-ce29d48a.js → isProduction-1fabb04f.js} +0 -0
- /package/build/{localizeNumberFormat-80fd8fbd.js → localizeNumberFormat-b15c4e54.js} +0 -0
- /package/build/{normalizeLink-2545f1d1.js → normalizeLink-76b1be18.js} +0 -0
- /package/build/{number-59af10e6.js → number-43ece9de.js} +0 -0
- /package/build/{paths-45ca38b7.js → paths-c7772697.js} +0 -0
- /package/build/{screenSizeContext-9f259904.js → screenSizeContext-e71500a7.js} +0 -0
- /package/build/{theme-c1ade062.js → theme-17265af7.js} +0 -0
- /package/build/{translationsContext-80bc6f5d.js → translationsContext-9894f417.js} +0 -0
- /package/build/{tslib.es6-839a4eec.js → tslib.es6-3704b5a0.js} +0 -0
- /package/build/{types-f16adb08.js → types-0fb08e25.js} +0 -0
- /package/build/{useIsInit-20840333.js → useIsInit-098d8a9b.js} +0 -0
- /package/build/{useOutsideClick-10c84bbc.js → useOutsideClick-72552b1e.js} +0 -0
- /package/build/{useScrollbarSize-8c9e58c9.js → useScrollbarSize-f123883e.js} +0 -0
package/build/esm/ecom.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as o}from"./theme-78a0ec17.js";export{c as Constants}from"./constants-d8636a01.js";export{t as Types}from"./types-f429485e.js";import"./index-18df2d15.js";import"date-fns/locale";import"./Onboarding-2b508269.js";import"./isProduction-d4dd3302.js";var e=Object.freeze({__proto__:null}),i=Object.freeze({__proto__:null});function l(t){return null!=t}const a={formatAutoCompleteAddress:t=>t&&t.place_id?{placeId:t.place_id,description:t.description||""}:null,formatPrice:(t,o)=>{const e="string"==typeof t?parseInt(t):t;return new Intl.NumberFormat(o||"vi-VN").format(e)},formatHotSearchKeyword:t=>({text:(null==t?void 0:t.name)||""}),formatHelpfulUrl:t=>({name:(null==t?void 0:t.name)||"",featuredImage:(null==t?void 0:t.featured_image)||"",url:(null==t?void 0:t.url)||""}),formatCategory:function(t,e,i){var l,r,n;const d=i?i+"/"+t.slug:t.slug,u=(null===(r=null===(l=null==t?void 0:t.children)||void 0===l?void 0:l.map)||void 0===r?void 0:r.call(l,(o=>a.formatCategory(o,t.id,d))))||[];return{id:null==t?void 0:t.id,name:(null==t?void 0:t.name)||"",logo:(null==t?void 0:t.logo)||"",slug:(null==t?void 0:t.slug)||"",fullSlug:d||"",children:u,backgroundColor:t.color||o.colors.teal50,parentId:e||0,products:(null===(n=t.products)||void 0===n?void 0:n.map(a.formatProduct))||[]}},formatFooterInfo:t=>{var o,e,i,l,a,r,n,d,u,s,m,c,v,p,_,g,f,b,h;const y=(null===(i=null===(e=null===(o=null==t?void 0:t.branch)||void 0===o?void 0:o.branch)||void 0===e?void 0:e.map)||void 0===i?void 0:i.call(e,(t=>({flag:t.flag||"",name:t.name||"",url:t.url||""}))))||[],x=(null===(r=null===(a=null===(l=null==t?void 0:t.general)||void 0===l?void 0:l.verified)||void 0===a?void 0:a.map)||void 0===r?void 0:r.call(a,(t=>({image:t.image||"",url:t.url||""}))))||[],P=(null===(d=null===(n=null==t?void 0:t.menu)||void 0===n?void 0:n.map)||void 0===d?void 0:d.call(n,(t=>{var o,e;return{menu_title:t.menu_title,items:null===(e=null===(o=t.items)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,(t=>({title:t.title,url:t.url})))}})))||[],C=(null===(m=null===(s=null===(u=null==t?void 0:t.social)||void 0===u?void 0:u.socials)||void 0===s?void 0:s.map)||void 0===m?void 0:m.call(s,(t=>({icon:t.icon||"",name:t.name||"",url:t.url||""}))))||[];return{branch:{title:(null===(c=null==t?void 0:t.branch)||void 0===c?void 0:c.title)||"",branch:y},general:{logo:null!==(p=null===(v=null==t?void 0:t.general)||void 0===v?void 0:v.logo)&&void 0!==p?p:"",content:null!==(g=null===(_=null==t?void 0:t.general)||void 0===_?void 0:_.content)&&void 0!==g?g:"",copyright:null!==(b=null===(f=null==t?void 0:t.general)||void 0===f?void 0:f.copyright)&&void 0!==b?b:"",verified:x},menu:P,social:{title:(null===(h=null==t?void 0:t.social)||void 0===h?void 0:h.title)||"",socials:C}}},formatNavigation:function(t){var o,e,i,l,r,n;return{hotSearchKeywords:(null===(e=null===(o=null==t?void 0:t.hot_search_keywords)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatHotSearchKeyword))||[],helpfulUrls:(null===(l=null===(i=null==t?void 0:t.helpful_urls)||void 0===i?void 0:i.map)||void 0===l?void 0:l.call(i,a.formatHelpfulUrl))||[],categories:(null===(n=null===(r=null==t?void 0:t.categories)||void 0===r?void 0:r.map)||void 0===n?void 0:n.call(r,(t=>a.formatCategory(t))))||[],footer:a.formatFooterInfo(null==t?void 0:t.footer),storeId:(null==t?void 0:t.store_id)||0,customerId:(null==t?void 0:t.customer_id)||0,cartItemsQty:"number"==typeof(null==t?void 0:t.cart_items_qty)?t.cart_items_qty:null}},formatPriceInfo:t=>t?{final:t.final||0,regular:t.regular||0,discountPercent:t.discount_percent||0}:null,formatProduct:function(t){var o,e,i,r;if(!t)return null;const n={final:0,regular:0,discountPercent:0};return{id:t.id||0,price:t.price&&a.formatPriceInfo(t.price)||n,thumbnail:t.thumbnail||"",name:t.name||"",averageRating:Number((t.average_rating||0).toFixed(2)),reviewsCount:t.reviews_count||0,tag:t.tag||null,sku:t.sku||"",slug:t.slug||"",images:t.images||[],tags:t.tags||[],unit:t.unit||"",brand:t.brand?{name:t.brand.name||"",image:t.brand.image||"",slug:t.brand.slug||"",productsCount:t.brand.products_count||0}:null,description:t.description||"",productPromotions:(null===(e=null===(o=t.product_promotions)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatProductPromotion).filter(l))||[],categories:(null===(r=null===(i=t.categories)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,(t=>a.formatCategory(t))).filter(l))||[],isInStock:(null==t?void 0:t.is_in_stock)||!1}},formatBanner:t=>t?{name:t.name||"",url:t.url||"",featuredImage:t.featured_image||"",alt:t.image_alt}:null,formatBlogPost:t=>{var o,e;return t?{title:t.title||"",image:t.image||"",link:t.link||"",postData:t.post_data?{reviewed:t.post_data.reviewed?{author:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.author||void 0),editor:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.editor||void 0),expert:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.expert||void 0),factCheck:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.fact_check||void 0),isAuthor:Boolean(t.post_data.reviewed.is_author)}:null,categories:t.post_data.categories?null===(e=(o=t.post_data.categories).map)||void 0===e?void 0:e.call(o,(t=>({termId:t.term_id||0,name:t.name||"",permalink:t.permalink||"",textColor:t.text_color||""}))):[],postDate:t.post_data.post_date||"",postModified:t.post_data.post_modified||"",modifiedTime:t.post_data.modified_time||""}:null}:null},formatBlogPostDataReviewedUser:t=>t?{id:t.ID||0,userId:t.user_id||0,formerRole:t.former_role||"",role:t.role||"",slug:t.slug||"",displayName:t.display_name||"",description:t.description||"",profileUrl:t.profile_url||"",avatar:t.avatar||"",avatarThumbnail:t.avatar_thumbnail||"",turnOffProfile:Boolean(t.turn_off_profile)}:null,formatBrand:function(t){var o,e,i,r;return t?{id:t.id||0,image:t.image||"",position:t.position||"",isPopular:t.is_popular||!1,summary:t.summary||"",name:t.name||"",slug:t.slug||"",description:t.description||null,banners:(null===(e=null===(o=t.banners)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatBanner).filter(l))||[],bestsellerProducts:(null===(r=null===(i=t.bestseller_products)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l))||[]}:null},formatHomePage:t=>{var o,e,i,r,n,d,u,s,m,c,v,p,_,g,f,b,h,y,x,P;return t?{brands:t.brands?null===(e=(o=t.brands).map)||void 0===e?void 0:e.call(o,a.formatBrand).filter(l):[],hotDeals:t.hot_deals?null===(r=(i=t.hot_deals).map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l):[],newProducts:t.new_products?null===(d=(n=t.new_products).map)||void 0===d?void 0:d.call(n,a.formatProduct).filter(l):[],slideBanners:t.slide_banners?null===(s=(u=t.slide_banners).map)||void 0===s?void 0:s.call(u,a.formatBanner).filter(l):[],subBanners:t.sub_banners?null===(c=(m=t.sub_banners).map)||void 0===c?void 0:c.call(m,a.formatBanner).filter(l):[],footerBanners:t.footer_banners?null===(p=(v=t.footer_banners).map)||void 0===p?void 0:p.call(v,a.formatBanner).filter(l):[],blogPosts:t.blog_posts?null===(g=(_=t.blog_posts).map)||void 0===g?void 0:g.call(_,a.formatBlogPost).filter(l):[],popularCategories:t.popular_categories?null===(b=(f=t.popular_categories).map)||void 0===b?void 0:b.call(f,(t=>a.formatCategory(t))).filter(l):[],suggestProducts:t.suggest_products?null===(y=(h=t.suggest_products).map)||void 0===y?void 0:y.call(h,(t=>a.formatCategory(t))).filter(l):[],promotions:t.promotions?null===(P=(x=t.promotions).map)||void 0===P?void 0:P.call(x,(t=>a.formatPromotion(t))).filter(l):[]}:null},formatCategoryPage:function(t){var o,e,i,r;return t?{id:t.id||0,name:t.name||"",slug:t.slug||"",description:t.description||null,banners:(null===(e=null===(o=t.banners)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatBanner).filter(l))||[],bestsellerProducts:(null===(r=null===(i=t.bestseller_products)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l))||[]}:null},formatBrandPage:function(t){return t?a.formatBrand(t):null},formatPagination:t=>t?{current:t.current||0,first:t.first||0,itemsPerPage:t.items_per_page||0,last:t.last||0,next:t.next||0,prev:t.prev||0,totalItems:t.total_items||0}:null,formatProductDetailPage:function(t){var o,e,i,r,n,d,u,s;return t?Object.assign(Object.assign({},a.formatProduct(t)),{relatedProducts:(null===(e=null===(o=t.related_products)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatProduct).filter(l))||[],bestsellerProducts:(null===(r=null===(i=t.bestseller_products)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l))||[],viewedProducts:(null===(d=null===(n=t.viewed_products)||void 0===n?void 0:n.map)||void 0===d?void 0:d.call(n,a.formatProduct).filter(l))||[],promotions:(null===(s=null===(u=t.promotions)||void 0===u?void 0:u.map)||void 0===s?void 0:s.call(u,a.formatPromotion).filter(l))||[]}):null},formatProductReview:t=>{var o,e;return t?{reviewId:t.review_id||"",createdAt:t.created_at||"",title:t.title||"",detail:t.detail||"",nickname:t.nick_name||"",avatar:t.avatar||"",ratingVotes:(null===(e=null===(o=t.rating_votes)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,(t=>({ratingCode:t.rating_code||"",value:Number(t.value)||0,percent:Number(t.percent)||0}))))||[],images:t.images||[]}:null},formatProductPromotion:t=>t?{id:t.id||0,name:t.name||"",thumbnail:t.thumbnail||"",expirationDate:t.expiration_date||""}:null,formatPromotion:t=>t?{id:t.id||0,name:t.name||"",slug:t.slug||"",thumbnail:t.thumbnail||"",expiredDate:t.expired_date||"",banners:t.banners||[],points:0,description:t.description||"",metaTitle:t.meta_title||"",metaKeywords:t.meta_keywords||"",metaDescription:t.meta_description||""}:null,formatCustomAttributes:(t,o)=>{var e;return(null==t?void 0:t.length)&&(null===(e=null==t?void 0:t.find((t=>t.attribute_code===o)))||void 0===e?void 0:e.value)||""},formatAddress:t=>{var o,e,i,l;return t?{id:t.id||0,fullName:t.firstname||"",telephone:t.telephone||"",province:{value:null===(o=t.region)||void 0===o?void 0:o.region_id,label:null===(e=t.region)||void 0===e?void 0:e.region}||null,district:{value:a.formatCustomAttributes(t.custom_attributes,"district_id"),label:a.formatCustomAttributes(t.custom_attributes,"district")},commune:{value:a.formatCustomAttributes(t.custom_attributes,"ward_id"),label:a.formatCustomAttributes(t.custom_attributes,"ward")},street:(null===(i=null==t?void 0:t.street)||void 0===i?void 0:i.length)?null==t?void 0:t.street[0]:"",isDefault:t.default_billing&&t.default_shipping||!1,fullAddress:(null===(l=null==t?void 0:t.extension_attributes)||void 0===l?void 0:l.full_address)||""}:null},formatProvince:t=>(null==t?void 0:t.available_regions)?t.available_regions.map((t=>({value:t.id||"",label:t.name||""}))):[],formatDistrict:t=>(null==t?void 0:t.districts)?t.districts.map((t=>({value:t.id||"",label:t.name||""}))):[],formatCommune:t=>(null==t?void 0:t.communes)?t.communes.map((t=>({value:t.id||"",label:t.name||""}))):[],formatOrder:t=>{var o,e;return t?{orderNumber:(null==t?void 0:t.order_number)||"",shippingData:(null==t?void 0:t.shipping_data)?{shippingMethod:t.shipping_data.shipping_method||"",shippingDescription:t.shipping_data.shipping_description||"",shippingAddress:t.shipping_data.shipping_address?{fullName:t.shipping_data.shipping_address.firstname||"",fullAddress:t.shipping_data.shipping_address.full_address||"",telephone:t.shipping_data.shipping_address.telephone||""}:null,storeAddress:null}:null,orderedDate:(null==t?void 0:t.ordered_date)||"",status:(null==t?void 0:t.status)||null,totals:(null==t?void 0:t.totals)?{subtotal:t.totals.subtotal||0,shippingAmount:t.totals.shipping_amount||0,discountAmount:t.totals.discount_amount||0,grandTotal:t.totals.grand_total||0}:null,products:(null===(e=null===(o=null==t?void 0:t.products)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,(t=>({sku:t.sku||"",name:t.name||"",price:t.price||0,rowTotal:t.row_total||0,image:t.image||"",qty:t.qty||0}))))||[],paymentMethod:(null==t?void 0:t.payment_method)||""}:null},formatStatistic:t=>{var o,e,i,l,a;return t?{pending:Number(null===(o=null==t?void 0:t.find((t=>"pending"===t.status)))||void 0===o?void 0:o.amount)||0,processing:Number(null===(e=null==t?void 0:t.find((t=>"processing"===t.status)))||void 0===e?void 0:e.amount)||0,delivering:Number(null===(i=null==t?void 0:t.find((t=>"delivering"===t.status)))||void 0===i?void 0:i.amount)||0,complete:Number(null===(l=null==t?void 0:t.find((t=>"complete"===t.status)))||void 0===l?void 0:l.amount)||0,canceled:Number(null===(a=null==t?void 0:t.find((t=>"canceled"===t.status)))||void 0===a?void 0:a.amount)||0}:{}},formatCartItem:t=>{var o,e,i,l,r,n,d,u;return t?{itemId:t.item_id||0,sku:t.sku||"",qty:t.qty||0,name:t.name||"",price:t.price||0,basePrice:(null===(o=t.extension_attributes)||void 0===o?void 0:o.base_price)||0,productType:t.product_type||"",quoteId:t.quote_id||"",thumbnail:(null===(e=t.extension_attributes)||void 0===e?void 0:e.thumbnail)||"",rowTotal:(null===(i=t.extension_attributes)||void 0===i?void 0:i.row_total)||0,promotions:(null===(n=null===(r=null===(l=t.extension_attributes)||void 0===l?void 0:l.promotions)||void 0===r?void 0:r.map)||void 0===n?void 0:n.call(r,a.formatProductPromotion))||[],isInStock:(null===(d=t.extension_attributes)||void 0===d?void 0:d.is_in_stock)||!1,urlProduct:(null===(u=t.extension_attributes)||void 0===u?void 0:u.url_key)||""}:null},formatCartAddress:t=>{var o;return t?{customerAddressId:(null==t?void 0:t.customer_address_id)||0,id:t.id||0,region:t.region||"",regionId:t.region_id||0,regionCode:t.region_code||"",countryId:t.country_id||"",street:t.street||[],postcode:t.postcode||"",city:t.city||"",firstname:t.firstname||"",lastname:t.lastname||"",customerId:t.customer_id||0,email:t.email||"",telephone:t.telephone||"",sameAsBilling:t.same_as_billing||0,saveInAddressBook:t.save_in_address_book||0,fullAddress:(null===(o=t.extension_attributes)||void 0===o?void 0:o.full_address)||""}:null},formatEstimatedShipping:t=>t?{carrierCode:t.carrier_code||"",methodCode:t.method_code||"",carrierTitle:t.carrier_title||"",methodTitle:t.method_title||"",amount:t.amount||0,baseAmount:t.base_amount||0,available:t.available||!1,errorMessage:t.error_message||"",priceExclTax:t.price_excl_tax||0,priceInclTax:t.price_incl_tax||0}:null,formatCartLoggedInCustomer:t=>{var o,e,i;return t?{email:t.email||"",firstname:t.firstname||"",lastname:t.lastname||"",id:t.id||0,groupId:t.group_id||0,createdAt:t.created_at||"",updatedAt:t.updated_at||"",createdIn:t.created_in||"",storeId:t.store_id||0,websiteId:t.website_id||0,addresses:(null===(e=null===(o=t.addresses)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatCartAddress))||[],disableAutoGroupChange:t.disable_auto_group_change||0,isSubscribed:(null===(i=t.extension_attributes)||void 0===i?void 0:i.is_subscribed)||!1}:null},formatCart:t=>{var o,e,i,l,r,n,d,u,s,m,c,v,p,_;return t?{id:t.id||0,createdAt:t.created_at||"",updatedAt:t.updated_at||"",isActive:t.is_active||!1,isVirtual:t.is_virtual||!1,items:(null===(i=null===(e=null===(o=t.items)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatCartItem))||void 0===i?void 0:i.sort(((t,o)=>Number(null==o?void 0:o.isInStock)-Number(null==t?void 0:t.isInStock))))||[],itemsCount:t.items_count||0,itemsQty:t.items_qty||0,customer:t.customer?a.formatCartLoggedInCustomer(t.customer):null,billingAddress:t.billing_address?a.formatCartAddress(t.billing_address):null,origOrderId:t.orig_order_id||0,currency:{globalCurrencyCode:(null===(l=t.currency)||void 0===l?void 0:l.global_currency_code)||"",baseCurrencyCode:(null===(r=t.currency)||void 0===r?void 0:r.base_currency_code)||"",storeCurrencyCode:(null===(n=t.currency)||void 0===n?void 0:n.store_currency_code)||"",quoteCurrencyCode:(null===(d=t.currency)||void 0===d?void 0:d.quote_currency_code)||"",storeToBaseRate:(null===(u=t.currency)||void 0===u?void 0:u.store_to_base_rate)||0,storeToQuoteRate:(null===(s=t.currency)||void 0===s?void 0:s.store_to_quote_rate)||0,baseToGlobalRate:(null===(m=t.currency)||void 0===m?void 0:m.base_to_global_rate)||0,baseToQuoteRate:(null===(c=t.currency)||void 0===c?void 0:c.base_to_quote_rate)||0},customerIsGuest:t.customer_is_guest||!1,customerNoteNotify:t.customer_note_notify||!1,customerTaxClassId:t.customer_tax_class_id||0,storeId:t.store_id||0,shippingAssignments:null===(_=null===(p=null===(v=t.extension_attributes)||void 0===v?void 0:v.shipping_assignments)||void 0===p?void 0:p.map)||void 0===_?void 0:_.call(p,(t=>{var o,e,i;return{shipping:{address:t.shipping.address?a.formatCartAddress(t.shipping.address):null,method:(null===(o=t.shipping)||void 0===o?void 0:o.method)||""},items:(null===(i=(e=t.items).map)||void 0===i?void 0:i.call(e,a.formatCartItem))||[]}}))}:null},formatCartTotal:t=>{var o,e,i;return t?{grandTotal:t.grand_total||0,baseGrandTotal:t.base_grand_total||0,subtotal:t.subtotal||0,baseSubtotal:t.base_subtotal||0,discountAmount:t.discount_amount||0,baseDiscountAmount:t.base_discount_amount||0,subtotalWithDiscount:t.subtotal_with_discount||0,baseSubtotalWithDiscount:t.base_subtotal_with_discount||0,shippingAmount:t.shipping_amount||0,baseShippingAmount:t.base_shipping_amount||0,shippingDiscountAmount:t.shipping_discount_amount||0,baseShippingDiscountAmount:t.base_shipping_discount_amount||0,taxAmount:t.tax_amount||0,baseTaxAmount:t.base_tax_amount||0,weeeTaxAppliedAmount:t.weee_tax_applied_amount||0,shippingTaxAmount:t.shipping_tax_amount||0,baseShippingTaxAmount:t.base_shipping_tax_amount||0,subtotalInclTax:t.subtotal_incl_tax||0,shippingInclTax:t.shipping_incl_tax||0,baseShippingInclTax:t.base_shipping_incl_tax||0,baseCurrencyCode:t.base_currency_code||"",quoteCurrencyCode:t.quote_currency_code||"",itemsQty:t.items_qty||0,coupon:{couponCode:t.coupon_code||"",couponDescription:(null===(o=null==t?void 0:t.extension_attributes)||void 0===o?void 0:o.coupon_description_text)||""},items:(null===(i=null===(e=t.items)||void 0===e?void 0:e.map)||void 0===i?void 0:i.call(e,(t=>({itemId:t.item_id||0,price:t.price||0,basePrice:t.base_price||0,qty:t.qty||0,rowTotal:t.row_total||0,baseRowTotal:t.base_row_total||0,rowTotalWithDiscount:t.row_total_with_discount||0,taxAmount:t.tax_amount||0,baseTaxAmount:t.base_tax_amount||0,taxPercent:t.tax_percent||0,discountAmount:t.discount_amount||0,baseDiscountAmount:t.base_discount_amount||0,discountPercent:t.discount_percent||0,priceInclTax:t.price_incl_tax||0,basePriceInclTax:t.base_price_incl_tax||0,rowTotalInclTax:t.row_total_incl_tax||0,baseRowTotalInclTax:t.base_row_total_incl_tax||0,options:t.options||"",weeeTaxAppliedAmount:t.weee_tax_applied_amount||0,weeeTaxApplied:t.weee_tax_applied||0,name:t.name||""}))))||[],totalSegments:t.total_segments||[]}:null},formatPaymentMethod:t=>t?null==t?void 0:t.map((t=>({code:(null==t?void 0:t.payment_code)||"",title:(null==t?void 0:t.payment_title)||"",thumbnail:(null==t?void 0:t.payment_thumbnail)||""}))):null,formatPaymentInformation:t=>{var o;return t?{paymentMethods:a.formatPaymentMethod(null===(o=null==t?void 0:t.extension_attributes)||void 0===o?void 0:o.payment_detail_info)||[],totals:a.formatCartTotal(t.totals)}:null},formatOrderConfirmation:t=>t?{isSuccess:t.is_success||!1,orderInfo:a.formatOrder(t.order_info)}:null,formatCoupons:t=>{var o;return(null===(o=null==t?void 0:t.items)||void 0===o?void 0:o.length)?t.items.map((t=>({code:(null==t?void 0:t.code)||"",name:(null==t?void 0:t.name)||"",thumbnail:(null==t?void 0:t.thumbnail)||"",description:(null==t?void 0:t.expired_date)||""}))):null},formatShippings:t=>t?t.map((t=>{var o;return{carrierCode:t.carrier_code||"",methodCode:t.method_code||"",title:t.carrier_title||"",description:t.method_title||"",price:(null==t?void 0:t.base_amount)||0,thumbnail:(null===(o=null==t?void 0:t.extension_attributes)||void 0===o?void 0:o.thumbnail)||""}})):[]};var r=Object.freeze({__proto__:null,dataFormatter:a});export{e as ApiTypes,r as DataFormatter,i as DataTypes};
|
|
1
|
+
import{t as o}from"./theme-17fe8568.js";export{c as Constants}from"./constants-ede77eee.js";export{t as Types}from"./types-028758a2.js";import"./index-2edd91fd.js";import"date-fns/locale";import"./Onboarding-8c3938e0.js";import"./isProduction-52c76560.js";var e=Object.freeze({__proto__:null}),i=Object.freeze({__proto__:null});function l(t){return null!=t}const a={formatAutoCompleteAddress:t=>t&&t.place_id?{placeId:t.place_id,description:t.description||""}:null,formatPrice:(t,o)=>{const e="string"==typeof t?parseInt(t):t;return new Intl.NumberFormat(o||"vi-VN").format(e)},formatHotSearchKeyword:t=>({text:(null==t?void 0:t.name)||""}),formatHelpfulUrl:t=>({name:(null==t?void 0:t.name)||"",featuredImage:(null==t?void 0:t.featured_image)||"",url:(null==t?void 0:t.url)||""}),formatCategory:function(t,e,i){var l,r,n;const d=i?i+"/"+t.slug:t.slug,u=(null===(r=null===(l=null==t?void 0:t.children)||void 0===l?void 0:l.map)||void 0===r?void 0:r.call(l,(o=>a.formatCategory(o,t.id,d))))||[];return{id:null==t?void 0:t.id,name:(null==t?void 0:t.name)||"",logo:(null==t?void 0:t.logo)||"",slug:(null==t?void 0:t.slug)||"",fullSlug:d||"",children:u,backgroundColor:t.color||o.colors.teal50,parentId:e||0,products:(null===(n=t.products)||void 0===n?void 0:n.map(a.formatProduct))||[]}},formatFooterInfo:t=>{var o,e,i,l,a,r,n,d,u,s,m,c,v,p,_,g,f,b,h;const y=(null===(i=null===(e=null===(o=null==t?void 0:t.branch)||void 0===o?void 0:o.branch)||void 0===e?void 0:e.map)||void 0===i?void 0:i.call(e,(t=>({flag:t.flag||"",name:t.name||"",url:t.url||""}))))||[],x=(null===(r=null===(a=null===(l=null==t?void 0:t.general)||void 0===l?void 0:l.verified)||void 0===a?void 0:a.map)||void 0===r?void 0:r.call(a,(t=>({image:t.image||"",url:t.url||""}))))||[],P=(null===(d=null===(n=null==t?void 0:t.menu)||void 0===n?void 0:n.map)||void 0===d?void 0:d.call(n,(t=>{var o,e;return{menu_title:t.menu_title,items:null===(e=null===(o=t.items)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,(t=>({title:t.title,url:t.url})))}})))||[],C=(null===(m=null===(s=null===(u=null==t?void 0:t.social)||void 0===u?void 0:u.socials)||void 0===s?void 0:s.map)||void 0===m?void 0:m.call(s,(t=>({icon:t.icon||"",name:t.name||"",url:t.url||""}))))||[];return{branch:{title:(null===(c=null==t?void 0:t.branch)||void 0===c?void 0:c.title)||"",branch:y},general:{logo:null!==(p=null===(v=null==t?void 0:t.general)||void 0===v?void 0:v.logo)&&void 0!==p?p:"",content:null!==(g=null===(_=null==t?void 0:t.general)||void 0===_?void 0:_.content)&&void 0!==g?g:"",copyright:null!==(b=null===(f=null==t?void 0:t.general)||void 0===f?void 0:f.copyright)&&void 0!==b?b:"",verified:x},menu:P,social:{title:(null===(h=null==t?void 0:t.social)||void 0===h?void 0:h.title)||"",socials:C}}},formatNavigation:function(t){var o,e,i,l,r,n;return{hotSearchKeywords:(null===(e=null===(o=null==t?void 0:t.hot_search_keywords)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatHotSearchKeyword))||[],helpfulUrls:(null===(l=null===(i=null==t?void 0:t.helpful_urls)||void 0===i?void 0:i.map)||void 0===l?void 0:l.call(i,a.formatHelpfulUrl))||[],categories:(null===(n=null===(r=null==t?void 0:t.categories)||void 0===r?void 0:r.map)||void 0===n?void 0:n.call(r,(t=>a.formatCategory(t))))||[],footer:a.formatFooterInfo(null==t?void 0:t.footer),storeId:(null==t?void 0:t.store_id)||0,customerId:(null==t?void 0:t.customer_id)||0,cartItemsQty:"number"==typeof(null==t?void 0:t.cart_items_qty)?t.cart_items_qty:null}},formatPriceInfo:t=>t?{final:t.final||0,regular:t.regular||0,discountPercent:t.discount_percent||0}:null,formatProduct:function(t){var o,e,i,r;if(!t)return null;const n={final:0,regular:0,discountPercent:0};return{id:t.id||0,price:t.price&&a.formatPriceInfo(t.price)||n,thumbnail:t.thumbnail||"",name:t.name||"",averageRating:Number((t.average_rating||0).toFixed(2)),reviewsCount:t.reviews_count||0,tag:t.tag||null,sku:t.sku||"",slug:t.slug||"",images:t.images||[],tags:t.tags||[],unit:t.unit||"",brand:t.brand?{name:t.brand.name||"",image:t.brand.image||"",slug:t.brand.slug||"",productsCount:t.brand.products_count||0}:null,description:t.description||"",productPromotions:(null===(e=null===(o=t.product_promotions)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatProductPromotion).filter(l))||[],categories:(null===(r=null===(i=t.categories)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,(t=>a.formatCategory(t))).filter(l))||[],isInStock:(null==t?void 0:t.is_in_stock)||!1}},formatBanner:t=>t?{name:t.name||"",url:t.url||"",featuredImage:t.featured_image||"",alt:t.image_alt}:null,formatBlogPost:t=>{var o,e;return t?{title:t.title||"",image:t.image||"",link:t.link||"",postData:t.post_data?{reviewed:t.post_data.reviewed?{author:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.author||void 0),editor:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.editor||void 0),expert:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.expert||void 0),factCheck:a.formatBlogPostDataReviewedUser(t.post_data.reviewed.fact_check||void 0),isAuthor:Boolean(t.post_data.reviewed.is_author)}:null,categories:t.post_data.categories?null===(e=(o=t.post_data.categories).map)||void 0===e?void 0:e.call(o,(t=>({termId:t.term_id||0,name:t.name||"",permalink:t.permalink||"",textColor:t.text_color||""}))):[],postDate:t.post_data.post_date||"",postModified:t.post_data.post_modified||"",modifiedTime:t.post_data.modified_time||""}:null}:null},formatBlogPostDataReviewedUser:t=>t?{id:t.ID||0,userId:t.user_id||0,formerRole:t.former_role||"",role:t.role||"",slug:t.slug||"",displayName:t.display_name||"",description:t.description||"",profileUrl:t.profile_url||"",avatar:t.avatar||"",avatarThumbnail:t.avatar_thumbnail||"",turnOffProfile:Boolean(t.turn_off_profile)}:null,formatBrand:function(t){var o,e,i,r;return t?{id:t.id||0,image:t.image||"",position:t.position||"",isPopular:t.is_popular||!1,summary:t.summary||"",name:t.name||"",slug:t.slug||"",description:t.description||null,banners:(null===(e=null===(o=t.banners)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatBanner).filter(l))||[],bestsellerProducts:(null===(r=null===(i=t.bestseller_products)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l))||[]}:null},formatHomePage:t=>{var o,e,i,r,n,d,u,s,m,c,v,p,_,g,f,b,h,y,x,P;return t?{brands:t.brands?null===(e=(o=t.brands).map)||void 0===e?void 0:e.call(o,a.formatBrand).filter(l):[],hotDeals:t.hot_deals?null===(r=(i=t.hot_deals).map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l):[],newProducts:t.new_products?null===(d=(n=t.new_products).map)||void 0===d?void 0:d.call(n,a.formatProduct).filter(l):[],slideBanners:t.slide_banners?null===(s=(u=t.slide_banners).map)||void 0===s?void 0:s.call(u,a.formatBanner).filter(l):[],subBanners:t.sub_banners?null===(c=(m=t.sub_banners).map)||void 0===c?void 0:c.call(m,a.formatBanner).filter(l):[],footerBanners:t.footer_banners?null===(p=(v=t.footer_banners).map)||void 0===p?void 0:p.call(v,a.formatBanner).filter(l):[],blogPosts:t.blog_posts?null===(g=(_=t.blog_posts).map)||void 0===g?void 0:g.call(_,a.formatBlogPost).filter(l):[],popularCategories:t.popular_categories?null===(b=(f=t.popular_categories).map)||void 0===b?void 0:b.call(f,(t=>a.formatCategory(t))).filter(l):[],suggestProducts:t.suggest_products?null===(y=(h=t.suggest_products).map)||void 0===y?void 0:y.call(h,(t=>a.formatCategory(t))).filter(l):[],promotions:t.promotions?null===(P=(x=t.promotions).map)||void 0===P?void 0:P.call(x,(t=>a.formatPromotion(t))).filter(l):[]}:null},formatCategoryPage:function(t){var o,e,i,r;return t?{id:t.id||0,name:t.name||"",slug:t.slug||"",description:t.description||null,banners:(null===(e=null===(o=t.banners)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatBanner).filter(l))||[],bestsellerProducts:(null===(r=null===(i=t.bestseller_products)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l))||[]}:null},formatBrandPage:function(t){return t?a.formatBrand(t):null},formatPagination:t=>t?{current:t.current||0,first:t.first||0,itemsPerPage:t.items_per_page||0,last:t.last||0,next:t.next||0,prev:t.prev||0,totalItems:t.total_items||0}:null,formatProductDetailPage:function(t){var o,e,i,r,n,d,u,s;return t?Object.assign(Object.assign({},a.formatProduct(t)),{relatedProducts:(null===(e=null===(o=t.related_products)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatProduct).filter(l))||[],bestsellerProducts:(null===(r=null===(i=t.bestseller_products)||void 0===i?void 0:i.map)||void 0===r?void 0:r.call(i,a.formatProduct).filter(l))||[],viewedProducts:(null===(d=null===(n=t.viewed_products)||void 0===n?void 0:n.map)||void 0===d?void 0:d.call(n,a.formatProduct).filter(l))||[],promotions:(null===(s=null===(u=t.promotions)||void 0===u?void 0:u.map)||void 0===s?void 0:s.call(u,a.formatPromotion).filter(l))||[]}):null},formatProductReview:t=>{var o,e;return t?{reviewId:t.review_id||"",createdAt:t.created_at||"",title:t.title||"",detail:t.detail||"",nickname:t.nick_name||"",avatar:t.avatar||"",ratingVotes:(null===(e=null===(o=t.rating_votes)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,(t=>({ratingCode:t.rating_code||"",value:Number(t.value)||0,percent:Number(t.percent)||0}))))||[],images:t.images||[]}:null},formatProductPromotion:t=>t?{id:t.id||0,name:t.name||"",thumbnail:t.thumbnail||"",expirationDate:t.expiration_date||""}:null,formatPromotion:t=>t?{id:t.id||0,name:t.name||"",slug:t.slug||"",thumbnail:t.thumbnail||"",expiredDate:t.expired_date||"",banners:t.banners||[],points:0,description:t.description||"",metaTitle:t.meta_title||"",metaKeywords:t.meta_keywords||"",metaDescription:t.meta_description||""}:null,formatCustomAttributes:(t,o)=>{var e;return(null==t?void 0:t.length)&&(null===(e=null==t?void 0:t.find((t=>t.attribute_code===o)))||void 0===e?void 0:e.value)||""},formatAddress:t=>{var o,e,i,l;return t?{id:t.id||0,fullName:t.firstname||"",telephone:t.telephone||"",province:{value:null===(o=t.region)||void 0===o?void 0:o.region_id,label:null===(e=t.region)||void 0===e?void 0:e.region}||null,district:{value:a.formatCustomAttributes(t.custom_attributes,"district_id"),label:a.formatCustomAttributes(t.custom_attributes,"district")},commune:{value:a.formatCustomAttributes(t.custom_attributes,"ward_id"),label:a.formatCustomAttributes(t.custom_attributes,"ward")},street:(null===(i=null==t?void 0:t.street)||void 0===i?void 0:i.length)?null==t?void 0:t.street[0]:"",isDefault:t.default_billing&&t.default_shipping||!1,fullAddress:(null===(l=null==t?void 0:t.extension_attributes)||void 0===l?void 0:l.full_address)||""}:null},formatProvince:t=>(null==t?void 0:t.available_regions)?t.available_regions.map((t=>({value:t.id||"",label:t.name||""}))):[],formatDistrict:t=>(null==t?void 0:t.districts)?t.districts.map((t=>({value:t.id||"",label:t.name||""}))):[],formatCommune:t=>(null==t?void 0:t.communes)?t.communes.map((t=>({value:t.id||"",label:t.name||""}))):[],formatOrder:t=>{var o,e;return t?{orderNumber:(null==t?void 0:t.order_number)||"",shippingData:(null==t?void 0:t.shipping_data)?{shippingMethod:t.shipping_data.shipping_method||"",shippingDescription:t.shipping_data.shipping_description||"",shippingAddress:t.shipping_data.shipping_address?{fullName:t.shipping_data.shipping_address.firstname||"",fullAddress:t.shipping_data.shipping_address.full_address||"",telephone:t.shipping_data.shipping_address.telephone||""}:null,storeAddress:null}:null,orderedDate:(null==t?void 0:t.ordered_date)||"",status:(null==t?void 0:t.status)||null,totals:(null==t?void 0:t.totals)?{subtotal:t.totals.subtotal||0,shippingAmount:t.totals.shipping_amount||0,discountAmount:t.totals.discount_amount||0,grandTotal:t.totals.grand_total||0}:null,products:(null===(e=null===(o=null==t?void 0:t.products)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,(t=>({sku:t.sku||"",name:t.name||"",price:t.price||0,rowTotal:t.row_total||0,image:t.image||"",qty:t.qty||0}))))||[],paymentMethod:(null==t?void 0:t.payment_method)||""}:null},formatStatistic:t=>{var o,e,i,l,a;return t?{pending:Number(null===(o=null==t?void 0:t.find((t=>"pending"===t.status)))||void 0===o?void 0:o.amount)||0,processing:Number(null===(e=null==t?void 0:t.find((t=>"processing"===t.status)))||void 0===e?void 0:e.amount)||0,delivering:Number(null===(i=null==t?void 0:t.find((t=>"delivering"===t.status)))||void 0===i?void 0:i.amount)||0,complete:Number(null===(l=null==t?void 0:t.find((t=>"complete"===t.status)))||void 0===l?void 0:l.amount)||0,canceled:Number(null===(a=null==t?void 0:t.find((t=>"canceled"===t.status)))||void 0===a?void 0:a.amount)||0}:{}},formatCartItem:t=>{var o,e,i,l,r,n,d,u;return t?{itemId:t.item_id||0,sku:t.sku||"",qty:t.qty||0,name:t.name||"",price:t.price||0,basePrice:(null===(o=t.extension_attributes)||void 0===o?void 0:o.base_price)||0,productType:t.product_type||"",quoteId:t.quote_id||"",thumbnail:(null===(e=t.extension_attributes)||void 0===e?void 0:e.thumbnail)||"",rowTotal:(null===(i=t.extension_attributes)||void 0===i?void 0:i.row_total)||0,promotions:(null===(n=null===(r=null===(l=t.extension_attributes)||void 0===l?void 0:l.promotions)||void 0===r?void 0:r.map)||void 0===n?void 0:n.call(r,a.formatProductPromotion))||[],isInStock:(null===(d=t.extension_attributes)||void 0===d?void 0:d.is_in_stock)||!1,urlProduct:(null===(u=t.extension_attributes)||void 0===u?void 0:u.url_key)||""}:null},formatCartAddress:t=>{var o;return t?{customerAddressId:(null==t?void 0:t.customer_address_id)||0,id:t.id||0,region:t.region||"",regionId:t.region_id||0,regionCode:t.region_code||"",countryId:t.country_id||"",street:t.street||[],postcode:t.postcode||"",city:t.city||"",firstname:t.firstname||"",lastname:t.lastname||"",customerId:t.customer_id||0,email:t.email||"",telephone:t.telephone||"",sameAsBilling:t.same_as_billing||0,saveInAddressBook:t.save_in_address_book||0,fullAddress:(null===(o=t.extension_attributes)||void 0===o?void 0:o.full_address)||""}:null},formatEstimatedShipping:t=>t?{carrierCode:t.carrier_code||"",methodCode:t.method_code||"",carrierTitle:t.carrier_title||"",methodTitle:t.method_title||"",amount:t.amount||0,baseAmount:t.base_amount||0,available:t.available||!1,errorMessage:t.error_message||"",priceExclTax:t.price_excl_tax||0,priceInclTax:t.price_incl_tax||0}:null,formatCartLoggedInCustomer:t=>{var o,e,i;return t?{email:t.email||"",firstname:t.firstname||"",lastname:t.lastname||"",id:t.id||0,groupId:t.group_id||0,createdAt:t.created_at||"",updatedAt:t.updated_at||"",createdIn:t.created_in||"",storeId:t.store_id||0,websiteId:t.website_id||0,addresses:(null===(e=null===(o=t.addresses)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatCartAddress))||[],disableAutoGroupChange:t.disable_auto_group_change||0,isSubscribed:(null===(i=t.extension_attributes)||void 0===i?void 0:i.is_subscribed)||!1}:null},formatCart:t=>{var o,e,i,l,r,n,d,u,s,m,c,v,p,_;return t?{id:t.id||0,createdAt:t.created_at||"",updatedAt:t.updated_at||"",isActive:t.is_active||!1,isVirtual:t.is_virtual||!1,items:(null===(i=null===(e=null===(o=t.items)||void 0===o?void 0:o.map)||void 0===e?void 0:e.call(o,a.formatCartItem))||void 0===i?void 0:i.sort(((t,o)=>Number(null==o?void 0:o.isInStock)-Number(null==t?void 0:t.isInStock))))||[],itemsCount:t.items_count||0,itemsQty:t.items_qty||0,customer:t.customer?a.formatCartLoggedInCustomer(t.customer):null,billingAddress:t.billing_address?a.formatCartAddress(t.billing_address):null,origOrderId:t.orig_order_id||0,currency:{globalCurrencyCode:(null===(l=t.currency)||void 0===l?void 0:l.global_currency_code)||"",baseCurrencyCode:(null===(r=t.currency)||void 0===r?void 0:r.base_currency_code)||"",storeCurrencyCode:(null===(n=t.currency)||void 0===n?void 0:n.store_currency_code)||"",quoteCurrencyCode:(null===(d=t.currency)||void 0===d?void 0:d.quote_currency_code)||"",storeToBaseRate:(null===(u=t.currency)||void 0===u?void 0:u.store_to_base_rate)||0,storeToQuoteRate:(null===(s=t.currency)||void 0===s?void 0:s.store_to_quote_rate)||0,baseToGlobalRate:(null===(m=t.currency)||void 0===m?void 0:m.base_to_global_rate)||0,baseToQuoteRate:(null===(c=t.currency)||void 0===c?void 0:c.base_to_quote_rate)||0},customerIsGuest:t.customer_is_guest||!1,customerNoteNotify:t.customer_note_notify||!1,customerTaxClassId:t.customer_tax_class_id||0,storeId:t.store_id||0,shippingAssignments:null===(_=null===(p=null===(v=t.extension_attributes)||void 0===v?void 0:v.shipping_assignments)||void 0===p?void 0:p.map)||void 0===_?void 0:_.call(p,(t=>{var o,e,i;return{shipping:{address:t.shipping.address?a.formatCartAddress(t.shipping.address):null,method:(null===(o=t.shipping)||void 0===o?void 0:o.method)||""},items:(null===(i=(e=t.items).map)||void 0===i?void 0:i.call(e,a.formatCartItem))||[]}}))}:null},formatCartTotal:t=>{var o,e,i;return t?{grandTotal:t.grand_total||0,baseGrandTotal:t.base_grand_total||0,subtotal:t.subtotal||0,baseSubtotal:t.base_subtotal||0,discountAmount:t.discount_amount||0,baseDiscountAmount:t.base_discount_amount||0,subtotalWithDiscount:t.subtotal_with_discount||0,baseSubtotalWithDiscount:t.base_subtotal_with_discount||0,shippingAmount:t.shipping_amount||0,baseShippingAmount:t.base_shipping_amount||0,shippingDiscountAmount:t.shipping_discount_amount||0,baseShippingDiscountAmount:t.base_shipping_discount_amount||0,taxAmount:t.tax_amount||0,baseTaxAmount:t.base_tax_amount||0,weeeTaxAppliedAmount:t.weee_tax_applied_amount||0,shippingTaxAmount:t.shipping_tax_amount||0,baseShippingTaxAmount:t.base_shipping_tax_amount||0,subtotalInclTax:t.subtotal_incl_tax||0,shippingInclTax:t.shipping_incl_tax||0,baseShippingInclTax:t.base_shipping_incl_tax||0,baseCurrencyCode:t.base_currency_code||"",quoteCurrencyCode:t.quote_currency_code||"",itemsQty:t.items_qty||0,coupon:{couponCode:t.coupon_code||"",couponDescription:(null===(o=null==t?void 0:t.extension_attributes)||void 0===o?void 0:o.coupon_description_text)||""},items:(null===(i=null===(e=t.items)||void 0===e?void 0:e.map)||void 0===i?void 0:i.call(e,(t=>({itemId:t.item_id||0,price:t.price||0,basePrice:t.base_price||0,qty:t.qty||0,rowTotal:t.row_total||0,baseRowTotal:t.base_row_total||0,rowTotalWithDiscount:t.row_total_with_discount||0,taxAmount:t.tax_amount||0,baseTaxAmount:t.base_tax_amount||0,taxPercent:t.tax_percent||0,discountAmount:t.discount_amount||0,baseDiscountAmount:t.base_discount_amount||0,discountPercent:t.discount_percent||0,priceInclTax:t.price_incl_tax||0,basePriceInclTax:t.base_price_incl_tax||0,rowTotalInclTax:t.row_total_incl_tax||0,baseRowTotalInclTax:t.base_row_total_incl_tax||0,options:t.options||"",weeeTaxAppliedAmount:t.weee_tax_applied_amount||0,weeeTaxApplied:t.weee_tax_applied||0,name:t.name||""}))))||[],totalSegments:t.total_segments||[]}:null},formatPaymentMethod:t=>t?null==t?void 0:t.map((t=>({code:(null==t?void 0:t.payment_code)||"",title:(null==t?void 0:t.payment_title)||"",thumbnail:(null==t?void 0:t.payment_thumbnail)||""}))):null,formatPaymentInformation:t=>{var o;return t?{paymentMethods:a.formatPaymentMethod(null===(o=null==t?void 0:t.extension_attributes)||void 0===o?void 0:o.payment_detail_info)||[],totals:a.formatCartTotal(t.totals)}:null},formatOrderConfirmation:t=>t?{isSuccess:t.is_success||!1,orderInfo:a.formatOrder(t.order_info)}:null,formatCoupons:t=>{var o;return(null===(o=null==t?void 0:t.items)||void 0===o?void 0:o.length)?t.items.map((t=>({code:(null==t?void 0:t.code)||"",name:(null==t?void 0:t.name)||"",thumbnail:(null==t?void 0:t.thumbnail)||"",description:(null==t?void 0:t.expired_date)||""}))):null},formatShippings:t=>t?t.map((t=>{var o;return{carrierCode:t.carrier_code||"",methodCode:t.method_code||"",title:t.carrier_title||"",description:t.method_title||"",price:(null==t?void 0:t.base_amount)||0,thumbnail:(null===(o=null==t?void 0:t.extension_attributes)||void 0===o?void 0:o.thumbnail)||""}})):[]};var r=Object.freeze({__proto__:null,dataFormatter:a});export{e as ApiTypes,r as DataFormatter,i as DataTypes};
|
package/build/esm/footer.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"react";import{B as t}from"./index-62ecf56a.js";import{C as a}from"./index-213c0fdc.js";import l from"dayjs";import{d as n}from"./index-18df2d15.js";import{t as o}from"./theme-78a0ec17.js";import"./index-3107d233.js";import{Flex as i,Stack as r,Box as m}from"@mantine/core";import"@mantine/dates";import"./Onboarding-2b508269.js";import"./gAssets.js";import{T as c}from"./index-9e896146.js";import"./screenSizeContext-01c0829e.js";import"styled-components";import"./isProduction-d4dd3302.js";import{u as s}from"./useTranslations-d7353bde.js";import"@mantine/hooks";import{L as d}from"./index-dbbbb305.js";import{M as v}from"./index-3764269a.js";import"./translationsContext-e7d1541a.js";import"string-format";import"./tslib.es6-e075fd14.js";import"date-fns/locale";import"@mantine/carousel";import"lodash/throttle";import"./utils-623afa37.js";import"./index.styled-d6b0ebe7.js";var u="Lj0qoTD",E="OO-qFWT";const g=({url:t,isMobile:a,dataEventCategory:l,dataEventAction:n,dataEventLabel:o})=>e.createElement("div",{className:E,"data-is-mobile":a},e.createElement("img",{loading:"lazy",className:"country-flag",src:t,alt:"Country Flag","data-event-category":l,"data-event-action":n,"data-content-label":o})),p=({className:i,type:r="main",footerInfo:m,isMobile:d,locale:v})=>{var E,p,y,f,b,N,h,k,F,z,$,x,T,j,M,C,L,_,S,w,H,I,A,B,G,D,q,O;const{t:U}=s(),J=null==m?void 0:m.menu,K=(null===(p=null===(E=null==m?void 0:m.general)||void 0===E?void 0:E.verified)||void 0===p?void 0:p.filter(Boolean))||[];return e.createElement("footer",{className:`${u} ${i||""}`,style:"mini"===r?{backgroundColor:o.colors.neutral50}:{}},e.createElement(a,null,e.createElement("div",{className:"inner","data-type":r},"main"===r?e.createElement(e.Fragment,null,e.createElement("a",{href:"/"},e.createElement("img",{loading:"lazy",className:"footer-logo",src:null===(y=null==m?void 0:m.general)||void 0===y?void 0:y.logo,alt:"Logo","data-is-sehat":"id-ID"===v})),e.createElement("div",{className:"columns"},e.createElement("div",{className:"newsletter"},e.createElement(c,{size:"p1",weight:"bold"},null===(f=null==m?void 0:m.general)||void 0===f?void 0:f.content),e.createElement(t,{className:"signupButton",color:"primary",size:"lg"},U("footer.signUp")),e.createElement("div",{className:"social"},e.createElement(c,{size:"sm"},null===(b=null==m?void 0:m.social)||void 0===b?void 0:b.title),e.createElement("div",{className:"icons"},null===(h=null===(N=null==m?void 0:m.social)||void 0===N?void 0:N.socials)||void 0===h?void 0:h.map(((t,a)=>e.createElement("a",{key:a,"data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,href:t.url},e.createElement("img",{loading:"lazy","data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,src:t.icon,alt:"Logo Social",className:"social-icon"}))))),e.createElement("hr",{className:"hrMobile"}))),e.createElement("div",null,J&&e.createElement(e.Fragment,null,e.createElement("div",{className:"biglinks"},null===(F=null===(k=J[0])||void 0===k?void 0:k.items)||void 0===F?void 0:F.map(((t,a)=>e.createElement("a",{"data-event-category":"Footer","data-event-action":t.title,"data-event-label":`https://${n[v]}${t.url}`,className:"bigLink",key:a,href:t.url},t.title)))),e.createElement("hr",{className:"hrMobile"}),e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(z=J[1])||void 0===z?void 0:z.menu_title),null===(x=null===($=J[1])||void 0===$?void 0:$.items)||void 0===x?void 0:x.map(((t,a)=>e.createElement("a",{"data-event-category":"Footer","data-event-action":t.title,"data-event-label":`https://${n[v]}${t.url}`,className:"link",href:t.url,key:a},e.createElement(c,{size:"sm",dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:`https://${n[v]}${t.url}`},t.title))))),e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(T=J[2])||void 0===T?void 0:T.menu_title),null===(M=null===(j=J[2])||void 0===j?void 0:j.items)||void 0===M?void 0:M.map(((t,a)=>t.url&&e.createElement("a",{"data-event-category":"Footer","data-event-action":t.title,"data-event-label":t.url,className:"link",href:t.url,key:a},e.createElement(c,{size:"sm",dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:t.url},t.title)))))),e.createElement("hr",{className:"hrMobile"}),e.createElement("div",{className:"otherSites"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(C=null==m?void 0:m.branch)||void 0===C?void 0:C.title),e.createElement("div",{className:"flags"},null===(_=null===(L=null==m?void 0:m.branch)||void 0===L?void 0:L.branch)||void 0===_?void 0:_.map(((t,a)=>e.createElement("a",{className:"link",href:t.url,key:a,"data-event-category":"Footer","data-event-action":t.name,"data-event-label":t.url},e.createElement(g,{url:t.flag,isMobile:d,dataEventCategory:"Footer",dataEventAction:t.name,dataEventLabel:t.url})))))))),e.createElement("hr",null),e.createElement("div",{className:"copyright"},e.createElement("div",{className:"copyright-image-wrapper"},K.length?K.map(((t,a)=>e.createElement("a",{href:t.url,key:a,className:"copyright-image"},e.createElement("img",{loading:"lazy",src:t.image,alt:"DMCA Icon"})))):null),e.createElement(c,{size:"xs",className:"copyright-content",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null===(S=null==m?void 0:m.general)||void 0===S?void 0:S.copyright.replace(/{currentYear}/gi,l().get("year").toString())}})))):e.createElement(e.Fragment,null,(null==m?void 0:m.menu)&&e.createElement("div",{className:"columns"},e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(w=null==m?void 0:m.menu[1])||void 0===w?void 0:w.menu_title),null===(I=null===(H=null==m?void 0:m.menu[1])||void 0===H?void 0:H.items)||void 0===I?void 0:I.map((t=>e.createElement("a",{className:"link",href:t.url,key:t.title,"data-list-type":"Footer","data-content-type":"Navigate","data-content-topic":"Information","data-content-title":t.title,"data-content-id":`https://${n[v]}${t.url}`,"data-event-category":"Footer","data-event-action":t.title,"data-event-label":`https://${n[v]}${t.url}`},e.createElement(c,{dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:`https://${n[v]}${t.url}`,size:"sm",style:{color:o.colors.gray800}},t.title))))),e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(A=null==m?void 0:m.menu[2])||void 0===A?void 0:A.menu_title),null===(G=null===(B=null==m?void 0:m.menu[2])||void 0===B?void 0:B.items)||void 0===G?void 0:G.map(((t,a)=>e.createElement("a",{className:"link",href:t.url,key:a,"data-list-type":"Footer","data-content-type":"Navigate","data-content-topic":"Hello Health","data-content-title":t.title,"data-content-id":t.url,"data-event-category":"Footer","data-event-action":t.title,"data-event-label":t.url},e.createElement(c,{size:"sm",color:o.colors.gray800,dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:t.url},t.title))))),"mini"!==r&&e.createElement("hr",{className:"hrMobile"}),e.createElement("div",{className:"newsletter"},e.createElement("div",{className:"social"},e.createElement(c,{size:"sm"},null===(D=null==m?void 0:m.social)||void 0===D?void 0:D.title),e.createElement("div",{className:"icons"},null===(O=null===(q=null==m?void 0:m.social)||void 0===q?void 0:q.socials)||void 0===O?void 0:O.map(((t,a)=>e.createElement("a",{key:a,"data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,href:t.url},e.createElement("img",{"data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,src:t.icon,alt:"Logo Social",loading:"lazy",className:"social-icon"}))))))))))))};var y="B6-KmWK",f="GS-7mbG",b="qc5bEb3",N="CQGVeuT",h="_8eUT8Jr",k="_6JMoel-",F="pFG7UH3";const z=({logoType:t="marryBaby",footerMenu:n,background:s})=>{var u;if(!n)return null;const{general:E,menu:g,socials:p}=n;return e.createElement("footer",{className:y,style:{backgroundColor:s||"none"}},e.createElement(a,null,e.createElement("div",{className:f},null==g?void 0:g.map((({menu_title:t,items:a},l)=>e.createElement("div",{className:b,key:`mbf${l}`},e.createElement(v,{className:"title",type:"subtitle-1",color:o.mbColors.pink},t),null==a?void 0:a.map((({title:t,url:a},l)=>e.createElement("a",{"data-event-category":"Footer","data-event-action":"Click","data-event-label":`${a}`,className:"link",href:a,key:`footer-links-${l}`},e.createElement("div",{className:N,key:`mbitem${l}`},e.createElement(v,{type:"bodytext-2",color:o.mbColors.gray},t)))))))))),e.createElement(a,null,e.createElement("div",{className:k},e.createElement(i,{gap:"24px",sx:e=>({[e.fn.largerThan("sm")]:{".info-item":{flexGrow:1,width:"50%"}},[e.fn.smallerThan("sm")]:{flexDirection:"column"}})},e.createElement(r,{spacing:"24px",className:"info-item"},e.createElement(d,{className:"logo",type:t}),e.createElement(c,{size:"p4",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null==E?void 0:E.content}})),e.createElement("div",{className:F},null==p?void 0:p.map((({icon:t,name:a,url:l},n)=>e.createElement("a",{key:`social${n}`,target:"_blank",rel:"noreferrer","data-event-category":"Footer","data-event-action":`Follow us - ${a}`,"data-content-label":a,href:l},e.createElement("img",{className:"social-logo",loading:"lazy",src:t,alt:a})))))),e.createElement(m,{className:"info-item",sx:{paddingTop:"7px"}},e.createElement(c,{size:"p4",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null==E?void 0:E.information}})))))),e.createElement("div",{className:h},e.createElement(a,null,e.createElement("div",{className:"content"},e.createElement(c,{size:"p5",color:"#fff",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null==E?void 0:E.copyright.replace(/{currentYear}/gi,l().get("year").toString())}})),e.createElement("div",{className:"verify"},null===(u=null==E?void 0:E.verified)||void 0===u?void 0:u.map((({image:t,url:a},l)=>e.createElement("img",{loading:"lazy",key:`imgMbFt${l}`,src:t,alt:a}))))))))},$=({type:t,isMobile:a=!0,locale:l,footerInfo:n,siteType:o,background:i})=>"helloSites"===o?e.createElement(p,{isMobile:a,type:t,locale:l,footerInfo:n||{}}):e.createElement(z,{footerMenu:n,background:i});export{$ as Footer};
|
|
1
|
+
import e from"react";import{B as t}from"./index-75dfeb72.js";import{C as a}from"./index-fa94e465.js";import l from"dayjs";import{d as n}from"./index-2edd91fd.js";import{t as o}from"./theme-17fe8568.js";import"./index-f7d54b3e.js";import{Flex as i,Stack as r,Box as m}from"@mantine/core";import"@mantine/dates";import"./Onboarding-8c3938e0.js";import"./gAssets.js";import{T as c}from"./index-fc471630.js";import"./screenSizeContext-be2375b1.js";import"styled-components";import"./isProduction-52c76560.js";import{u as s}from"./useTranslations-3a1f0a5e.js";import"@mantine/hooks";import{L as d}from"./index-0cefeefb.js";import{M as v}from"./index-bf09c5ae.js";import"./translationsContext-8efd3a3b.js";import"string-format";import"./tslib.es6-4213f703.js";import"date-fns/locale";import"@mantine/carousel";import"lodash/throttle";import"./utils-de689222.js";import"./index.styled-be95abd0.js";var u="Lj0qoTD",E="OO-qFWT";const g=({url:t,isMobile:a,dataEventCategory:l,dataEventAction:n,dataEventLabel:o})=>e.createElement("div",{className:E,"data-is-mobile":a},e.createElement("img",{loading:"lazy",className:"country-flag",src:t,alt:"Country Flag","data-event-category":l,"data-event-action":n,"data-content-label":o})),p=({className:i,type:r="main",footerInfo:m,isMobile:d,locale:v})=>{var E,p,y,f,b,N,h,k,F,z,$,x,T,j,M,C,L,_,S,w,H,I,A,B,G,D,q,O;const{t:U}=s(),J=null==m?void 0:m.menu,K=(null===(p=null===(E=null==m?void 0:m.general)||void 0===E?void 0:E.verified)||void 0===p?void 0:p.filter(Boolean))||[];return e.createElement("footer",{className:`${u} ${i||""}`,style:"mini"===r?{backgroundColor:o.colors.neutral50}:{}},e.createElement(a,null,e.createElement("div",{className:"inner","data-type":r},"main"===r?e.createElement(e.Fragment,null,e.createElement("a",{href:"/"},e.createElement("img",{loading:"lazy",className:"footer-logo",src:null===(y=null==m?void 0:m.general)||void 0===y?void 0:y.logo,alt:"Logo","data-is-sehat":"id-ID"===v})),e.createElement("div",{className:"columns"},e.createElement("div",{className:"newsletter"},e.createElement(c,{size:"p1",weight:"bold"},null===(f=null==m?void 0:m.general)||void 0===f?void 0:f.content),e.createElement(t,{className:"signupButton",color:"primary",size:"lg"},U("footer.signUp")),e.createElement("div",{className:"social"},e.createElement(c,{size:"sm"},null===(b=null==m?void 0:m.social)||void 0===b?void 0:b.title),e.createElement("div",{className:"icons"},null===(h=null===(N=null==m?void 0:m.social)||void 0===N?void 0:N.socials)||void 0===h?void 0:h.map(((t,a)=>e.createElement("a",{key:a,"data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,href:t.url},e.createElement("img",{loading:"lazy","data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,src:t.icon,alt:"Logo Social",className:"social-icon"}))))),e.createElement("hr",{className:"hrMobile"}))),e.createElement("div",null,J&&e.createElement(e.Fragment,null,e.createElement("div",{className:"biglinks"},null===(F=null===(k=J[0])||void 0===k?void 0:k.items)||void 0===F?void 0:F.map(((t,a)=>e.createElement("a",{"data-event-category":"Footer","data-event-action":t.title,"data-event-label":`https://${n[v]}${t.url}`,className:"bigLink",key:a,href:t.url},t.title)))),e.createElement("hr",{className:"hrMobile"}),e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(z=J[1])||void 0===z?void 0:z.menu_title),null===(x=null===($=J[1])||void 0===$?void 0:$.items)||void 0===x?void 0:x.map(((t,a)=>e.createElement("a",{"data-event-category":"Footer","data-event-action":t.title,"data-event-label":`https://${n[v]}${t.url}`,className:"link",href:t.url,key:a},e.createElement(c,{size:"sm",dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:`https://${n[v]}${t.url}`},t.title))))),e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(T=J[2])||void 0===T?void 0:T.menu_title),null===(M=null===(j=J[2])||void 0===j?void 0:j.items)||void 0===M?void 0:M.map(((t,a)=>t.url&&e.createElement("a",{"data-event-category":"Footer","data-event-action":t.title,"data-event-label":t.url,className:"link",href:t.url,key:a},e.createElement(c,{size:"sm",dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:t.url},t.title)))))),e.createElement("hr",{className:"hrMobile"}),e.createElement("div",{className:"otherSites"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(C=null==m?void 0:m.branch)||void 0===C?void 0:C.title),e.createElement("div",{className:"flags"},null===(_=null===(L=null==m?void 0:m.branch)||void 0===L?void 0:L.branch)||void 0===_?void 0:_.map(((t,a)=>e.createElement("a",{className:"link",href:t.url,key:a,"data-event-category":"Footer","data-event-action":t.name,"data-event-label":t.url},e.createElement(g,{url:t.flag,isMobile:d,dataEventCategory:"Footer",dataEventAction:t.name,dataEventLabel:t.url})))))))),e.createElement("hr",null),e.createElement("div",{className:"copyright"},e.createElement("div",{className:"copyright-image-wrapper"},K.length?K.map(((t,a)=>e.createElement("a",{href:t.url,key:a,className:"copyright-image"},e.createElement("img",{loading:"lazy",src:t.image,alt:"DMCA Icon"})))):null),e.createElement(c,{size:"xs",className:"copyright-content",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null===(S=null==m?void 0:m.general)||void 0===S?void 0:S.copyright.replace(/{currentYear}/gi,l().get("year").toString())}})))):e.createElement(e.Fragment,null,(null==m?void 0:m.menu)&&e.createElement("div",{className:"columns"},e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(w=null==m?void 0:m.menu[1])||void 0===w?void 0:w.menu_title),null===(I=null===(H=null==m?void 0:m.menu[1])||void 0===H?void 0:H.items)||void 0===I?void 0:I.map((t=>e.createElement("a",{className:"link",href:t.url,key:t.title,"data-list-type":"Footer","data-content-type":"Navigate","data-content-topic":"Information","data-content-title":t.title,"data-content-id":`https://${n[v]}${t.url}`,"data-event-category":"Footer","data-event-action":t.title,"data-event-label":`https://${n[v]}${t.url}`},e.createElement(c,{dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:`https://${n[v]}${t.url}`,size:"sm",style:{color:o.colors.gray800}},t.title))))),e.createElement("div",{className:"mHalf"},e.createElement(c,{size:"sm",className:"linkTitle"},null===(A=null==m?void 0:m.menu[2])||void 0===A?void 0:A.menu_title),null===(G=null===(B=null==m?void 0:m.menu[2])||void 0===B?void 0:B.items)||void 0===G?void 0:G.map(((t,a)=>e.createElement("a",{className:"link",href:t.url,key:a,"data-list-type":"Footer","data-content-type":"Navigate","data-content-topic":"Hello Health","data-content-title":t.title,"data-content-id":t.url,"data-event-category":"Footer","data-event-action":t.title,"data-event-label":t.url},e.createElement(c,{size:"sm",color:o.colors.gray800,dataEventCategory:"Footer",dataEventAction:t.title,dataEventLabel:t.url},t.title))))),"mini"!==r&&e.createElement("hr",{className:"hrMobile"}),e.createElement("div",{className:"newsletter"},e.createElement("div",{className:"social"},e.createElement(c,{size:"sm"},null===(D=null==m?void 0:m.social)||void 0===D?void 0:D.title),e.createElement("div",{className:"icons"},null===(O=null===(q=null==m?void 0:m.social)||void 0===q?void 0:q.socials)||void 0===O?void 0:O.map(((t,a)=>e.createElement("a",{key:a,"data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,href:t.url},e.createElement("img",{"data-event-category":"Footer","data-event-action":`Follow us - ${t.name}`,"data-content-label":t.url,src:t.icon,alt:"Logo Social",loading:"lazy",className:"social-icon"}))))))))))))};var y="B6-KmWK",f="GS-7mbG",b="qc5bEb3",N="CQGVeuT",h="_8eUT8Jr",k="_6JMoel-",F="pFG7UH3";const z=({logoType:t="marryBaby",footerMenu:n,background:s})=>{var u;if(!n)return null;const{general:E,menu:g,socials:p}=n;return e.createElement("footer",{className:y,style:{backgroundColor:s||"none"}},e.createElement(a,null,e.createElement("div",{className:f},null==g?void 0:g.map((({menu_title:t,items:a},l)=>e.createElement("div",{className:b,key:`mbf${l}`},e.createElement(v,{className:"title",type:"subtitle-1",color:o.mbColors.pink},t),null==a?void 0:a.map((({title:t,url:a},l)=>e.createElement("a",{"data-event-category":"Footer","data-event-action":"Click","data-event-label":`${a}`,className:"link",href:a,key:`footer-links-${l}`},e.createElement("div",{className:N,key:`mbitem${l}`},e.createElement(v,{type:"bodytext-2",color:o.mbColors.gray},t)))))))))),e.createElement(a,null,e.createElement("div",{className:k},e.createElement(i,{gap:"24px",sx:e=>({[e.fn.largerThan("sm")]:{".info-item":{flexGrow:1,width:"50%"}},[e.fn.smallerThan("sm")]:{flexDirection:"column"}})},e.createElement(r,{spacing:"24px",className:"info-item"},e.createElement(d,{className:"logo",type:t}),e.createElement(c,{size:"p4",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null==E?void 0:E.content}})),e.createElement("div",{className:F},null==p?void 0:p.map((({icon:t,name:a,url:l},n)=>e.createElement("a",{key:`social${n}`,target:"_blank",rel:"noreferrer","data-event-category":"Footer","data-event-action":`Follow us - ${a}`,"data-content-label":a,href:l},e.createElement("img",{className:"social-logo",loading:"lazy",src:t,alt:a})))))),e.createElement(m,{className:"info-item",sx:{paddingTop:"7px"}},e.createElement(c,{size:"p4",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null==E?void 0:E.information}})))))),e.createElement("div",{className:h},e.createElement(a,null,e.createElement("div",{className:"content"},e.createElement(c,{size:"p5",color:"#fff",as:"div"},e.createElement("div",{dangerouslySetInnerHTML:{__html:null==E?void 0:E.copyright.replace(/{currentYear}/gi,l().get("year").toString())}})),e.createElement("div",{className:"verify"},null===(u=null==E?void 0:E.verified)||void 0===u?void 0:u.map((({image:t,url:a},l)=>e.createElement("img",{loading:"lazy",key:`imgMbFt${l}`,src:t,alt:a}))))))))},$=({type:t,isMobile:a=!0,locale:l,footerInfo:n,siteType:o,background:i})=>"helloSites"===o?e.createElement(p,{isMobile:a,type:t,locale:l,footerInfo:n||{}}):e.createElement(z,{footerMenu:n,background:i});export{$ as Footer};
|
package/build/esm/gAssets.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as s}from"./index-
|
|
1
|
+
import{d as s}from"./index-2edd91fd.js";import{i as e}from"./isProduction-52c76560.js";import"date-fns/locale";import"./Onboarding-8c3938e0.js";const t="hellosehat.com";class o{constructor(){this.baseDomain="",this.subPath="",this.getAssetPath=(s,t,o)=>{const i="https://hhg-common."+[t||this.getBaseDomain(),o||this.subPath,s].join("/");return e||process.env.JEST_WORKER_ID?i:i+"?v="+Math.floor((new Date).getTime()/1e3/60/3)}}getBaseDomain(){if(this.baseDomain)return this.baseDomain;if("undefined"!=typeof window){const{host:e}=window.location,o=e.split("."),i=s[Object.keys(s).find((t=>e.includes(s[t])))];return o.includes("localhost")||o.includes("hellohealthgroup")||o.every((s=>{return e=s,!isNaN(parseFloat(e))&&isFinite(e);var e}))||!i?t:i}return t}}const i=new o;i.subPath="common",process.env.NEXT_PUBLIC_DEPLOY_LOCALE&&(i.baseDomain=s[process.env.NEXT_PUBLIC_DEPLOY_LOCALE]);export{i as CommonGAssets,o as GAssets};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as t}from"./tslib.es6-
|
|
1
|
+
import{a as t}from"./tslib.es6-4213f703.js";import{g as o}from"./core-14561d71.js";import{n as i}from"./normalizeLink-59af508a.js";import{c as l}from"./routing-998bc5c2.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 s="tl-PH"===o?"lang=fil":"";let a=[];try{const r=yield fetch(i(`${l(o)}/wp-json/api/healthtools?ismenu=0${s?"&"+s:""}`)).then((t=>t.json()));a=(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 a}catch(t){console.error(t)}})),s=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{s as a,n as f,e as g};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"react";import{L as t}from"./Onboarding-
|
|
1
|
+
import e from"react";import{L as t}from"./Onboarding-8c3938e0.js";import{CommonGAssets as C}from"./gAssets.js";const l=l=>[{icon:e.createElement("svg",{width:"33",height:"32",viewBox:"0 0 33 32",fill:"none"},e.createElement("path",{d:"M27.5 0H5.5C2.73858 0 0.5 2.23858 0.5 5V27C0.5 29.7614 2.73858 32 5.5 32H27.5C30.2614 32 32.5 29.7614 32.5 27V5C32.5 2.23858 30.2614 0 27.5 0Z",fill:"#1778F2"}),e.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M20.814 32V19.499H24.069L24.5 15.19H20.814L20.82 13.034C20.82 11.911 20.92 11.309 22.443 11.309H24.477V7H21.222C17.312 7 15.937 9.09 15.937 12.604V15.191H13.5V19.499H15.937V32H20.814Z",fill:"white"})),name:"Facebook",href:`https://www.facebook.com/sharer/sharer.php?u=${l}`},{icon:e.createElement("img",{src:C.getAssetPath("zalo-mini.png"),alt:"Zalo",style:{width:32,height:32},loading:"lazy"}),name:"Zalo",href:`https://sp.zalo.me/share?href=${l}`,allowedLocales:[t.Vietnam]},{icon:e.createElement("svg",{width:"33",height:"32",viewBox:"0 0 33 32",fill:"none"},e.createElement("rect",{x:"0.5",width:"32",height:"32",rx:"4",fill:"#1FA1F3"}),e.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M16.2304 13.2349L16.2708 13.8692L15.5964 13.7916C13.1417 13.4938 10.9972 12.484 9.17631 10.788L8.2861 9.94646L8.05683 10.5679C7.57124 11.9532 7.88149 13.4161 8.89305 14.4001C9.43257 14.9438 9.31116 15.0215 8.38052 14.6978C8.05683 14.5943 7.77357 14.5166 7.74658 14.5554C7.65216 14.646 7.97591 15.8241 8.23218 16.2902C8.58286 16.9376 9.29766 17.5719 10.08 17.9474L10.7409 18.2452L9.9586 18.2581C9.20324 18.2581 9.17631 18.271 9.25723 18.5429C9.52699 19.3844 10.5925 20.2777 11.7794 20.6661L12.6157 20.938L11.8873 21.3523C10.8083 21.9478 9.54049 22.2844 8.2726 22.3103C7.66566 22.3232 7.16663 22.375 7.16663 22.4139C7.16663 22.5433 8.81213 23.2684 9.76976 23.5531C12.6427 24.3947 16.055 24.0322 18.6177 22.5951C20.4385 21.5724 22.2593 19.5398 23.1091 17.5719C23.5677 16.5232 24.0263 14.6072 24.0263 13.688C24.0263 13.0925 24.0667 13.0148 24.822 12.3027C25.2671 11.8885 25.6853 11.4353 25.7662 11.3059C25.901 11.0598 25.8875 11.0598 25.1997 11.28C24.0532 11.6683 23.8913 11.6166 24.4579 11.034C24.876 10.6197 25.375 9.86879 25.375 9.64873C25.375 9.60987 25.1727 9.67458 24.9434 9.79112C24.7006 9.92061 24.1611 10.1148 23.7565 10.2313L23.0281 10.4514L22.3673 10.0241C22.0031 9.79112 21.4905 9.53219 21.2208 9.45452C20.5329 9.27327 19.4809 9.29918 18.8605 9.50628C17.1745 10.0889 16.1089 11.5907 16.2304 13.2349Z",fill:"white"})),name:"Twitter",href:`https://twitter.com/intent/tweet?url=${l}`},{icon:e.createElement("svg",{width:"33",height:"32",viewBox:"0 0 33 32",fill:"none"},e.createElement("g",{clipPath:"url(#clip0_687_88944)"},e.createElement("path",{d:"M29.5309 0H3.46909C1.82931 0 0.5 1.32931 0.5 2.96909V29.0309C0.5 30.6707 1.82931 32 3.46909 32H29.5309C31.1707 32 32.5 30.6707 32.5 29.0309V2.96909C32.5 1.32931 31.1707 0 29.5309 0Z",fill:"url(#paint0_linear_687_88944)"}),e.createElement("path",{d:"M23.5545 8.94548C21.8898 7.2642 19.6792 6.23313 17.3212 6.03825C14.9633 5.84336 12.6134 6.49749 10.6953 7.88265C8.77715 9.2678 7.41716 11.2928 6.86059 13.5924C6.30403 15.8919 6.58753 18.3147 7.65997 20.4237L6.60724 25.5346C6.59632 25.5854 6.59601 25.638 6.60633 25.689C6.61665 25.74 6.63739 25.7883 6.66724 25.8309C6.71097 25.8956 6.77338 25.9454 6.84616 25.9737C6.91893 26.0019 6.99859 26.0073 7.07451 25.9891L12.0836 24.8018C14.1866 25.8471 16.5923 26.1124 18.8725 25.5505C21.1528 24.9885 23.1597 23.6358 24.5362 21.7331C25.9128 19.8303 26.5696 17.5009 26.3898 15.1593C26.21 12.8177 25.2053 10.6158 23.5545 8.94548ZM21.9927 21.4109C20.8409 22.5595 19.3578 23.3176 17.7523 23.5786C16.1468 23.8395 14.4998 23.5901 13.0436 22.8655L12.3454 22.52L9.27451 23.2473L9.2836 23.2091L9.91997 20.1182L9.57815 19.4437C8.83408 17.9823 8.57159 16.323 8.82831 14.7034C9.08502 13.0837 9.84775 11.5869 11.0072 10.4273C12.4642 8.97083 14.4399 8.15263 16.5 8.15263C18.56 8.15263 20.5358 8.97083 21.9927 10.4273C22.0051 10.4415 22.0185 10.4549 22.0327 10.4673C23.4716 11.9275 24.2748 13.8974 24.2673 15.9474C24.2598 17.9974 23.4422 19.9613 21.9927 21.4109Z",fill:"white"}),e.createElement("path",{d:"M21.7199 19.1436C21.3436 19.7364 20.749 20.4618 20.0017 20.6418C18.6926 20.9582 16.6836 20.6527 14.1836 18.3218L14.1526 18.2946C11.9545 16.2564 11.3836 14.56 11.5217 13.2146C11.5981 12.4509 12.2345 11.76 12.7708 11.3091C12.8556 11.2367 12.9562 11.1852 13.0645 11.1586C13.1727 11.1321 13.2857 11.1312 13.3944 11.1561C13.503 11.181 13.6044 11.231 13.6903 11.3021C13.7761 11.3732 13.8442 11.4634 13.889 11.5655L14.6981 13.3836C14.7507 13.5015 14.7702 13.6315 14.7545 13.7596C14.7388 13.8878 14.6885 14.0092 14.609 14.1109L14.1999 14.6418C14.1121 14.7515 14.0592 14.8848 14.0478 15.0248C14.0365 15.1648 14.0673 15.305 14.1363 15.4273C14.3654 15.8291 14.9145 16.42 15.5236 16.9673C16.2072 17.5855 16.9654 18.1509 17.4454 18.3436C17.5738 18.3961 17.715 18.4089 17.8508 18.3804C17.9866 18.3519 18.1107 18.2834 18.2072 18.1836L18.6817 17.7055C18.7733 17.6152 18.8872 17.5508 19.0117 17.5188C19.1363 17.4869 19.2671 17.4886 19.3908 17.5236L21.3126 18.0691C21.4187 18.1016 21.5158 18.158 21.5967 18.2338C21.6776 18.3096 21.7401 18.4029 21.7794 18.5066C21.8187 18.6103 21.8338 18.7216 21.8235 18.832C21.8132 18.9424 21.7777 19.049 21.7199 19.1436Z",fill:"white"})),e.createElement("defs",null,e.createElement("linearGradient",{id:"paint0_linear_687_88944",x1:"16.5",y1:"0.130909",x2:"16.5",y2:"30.4509",gradientUnits:"userSpaceOnUse"},e.createElement("stop",{stopColor:"#36F46C"}),e.createElement("stop",{offset:"1",stopColor:"#03D749"})),e.createElement("clipPath",{id:"clip0_687_88944"},e.createElement("rect",{width:"32",height:"32",fill:"white",transform:"translate(0.5)"})))),name:"WhatsApp",href:`https://wa.me/?text=${l}`},{icon:e.createElement("svg",{width:"33",height:"32",viewBox:"0 0 33 32",fill:"none"},e.createElement("rect",{x:"0.5",width:"32",height:"32",rx:"4",fill:"#0077B5"}),e.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11.3571 9.07077C11.3349 7.97643 10.6126 7.14288 9.43969 7.14288C8.26679 7.14288 7.5 7.97643 7.5 9.07077C7.5 10.1425 8.24415 11 9.39516 11H9.4171C10.6126 11 11.3571 10.1425 11.3571 9.07077ZM11.3571 12.286H7.5V23.8574H11.3571V12.286ZM20.651 12.286C23.4224 12.286 25.5 13.9022 25.5 17.3748L25.4999 23.8571H21.2885V17.8086C21.2885 16.2894 20.6791 15.2526 19.1545 15.2526C17.991 15.2526 17.2979 15.9515 16.9935 16.6265C16.8822 16.8685 16.8548 17.2056 16.8548 17.5435V23.8574H12.6429C12.6429 23.8574 12.6984 13.6127 12.6429 12.5518H16.8548V14.1531C17.4138 13.3834 18.415 12.286 20.651 12.286Z",fill:"white"})),name:"LinkedIn",href:`https://www.linkedin.com/sharing/share-offsite/?url=${l}`},{icon:e.createElement("svg",{width:"32px",height:"32px",viewBox:"0 0 32 32",version:"1.1"},e.createElement("g",{id:"surface1"},e.createElement("path",{fill:"#00cf2e",d:"M 26.398438 32 L 5.601562 32 C 2.507812 32 0 29.492188 0 26.398438 L 0 5.601562 C 0 2.507812 2.507812 0 5.601562 0 L 26.398438 0 C 29.492188 0 32 2.507812 32 5.601562 L 32 26.398438 C 32 29.492188 29.492188 32 26.398438 32 Z M 26.398438 32 "}),e.createElement("path",{fill:"#fff",d:"M 28.199219 14.199219 C 28.199219 9.800781 23 5 16.199219 5 C 9.574219 5 4.199219 8.898438 4.199219 14.199219 C 4.199219 19.089844 8.390625 23.128906 14.285156 23.726562 C 14.648438 23.753906 14.980469 23.949219 15.179688 24.253906 C 15.320312 24.476562 15.398438 24.734375 15.398438 25 C 15.386719 25.542969 15.324219 26.082031 15.21875 26.613281 C 15.1875 26.761719 15.238281 26.914062 15.355469 27.011719 C 15.472656 27.109375 15.632812 27.128906 15.769531 27.070312 C 18.59375 25.820312 28.199219 20.679688 28.199219 14.199219 Z M 28.199219 14.199219 "}),e.createElement("path",{fill:"#00cf2e",d:"M 11.800781 16.398438 L 10 16.398438 L 10 12.199219 C 10 11.867188 9.730469 11.601562 9.398438 11.601562 C 9.070312 11.601562 8.800781 11.867188 8.800781 12.199219 L 8.800781 17 C 8.800781 17.332031 9.070312 17.601562 9.398438 17.601562 L 11.800781 17.601562 C 12.132812 17.601562 12.398438 17.332031 12.398438 17 C 12.398438 16.667969 12.132812 16.398438 11.800781 16.398438 Z M 11.800781 16.398438 "}),e.createElement("path",{fill:"#00cf2e",d:"M 13.398438 11.601562 C 13.070312 11.601562 12.800781 11.867188 12.800781 12.199219 L 12.800781 17 C 12.800781 17.332031 13.070312 17.601562 13.398438 17.601562 C 13.730469 17.601562 14 17.332031 14 17 L 14 12.199219 C 14 11.867188 13.730469 11.601562 13.398438 11.601562 Z M 13.398438 11.601562 "}),e.createElement("path",{fill:"#00cf2e",d:"M 19 11.601562 C 18.667969 11.601562 18.398438 11.867188 18.398438 12.199219 L 18.398438 15.199219 L 15.898438 11.839844 C 15.746094 11.632812 15.476562 11.550781 15.230469 11.628906 C 14.984375 11.710938 14.820312 11.941406 14.820312 12.199219 L 14.820312 17 C 14.871094 17.285156 15.121094 17.492188 15.410156 17.492188 C 15.699219 17.492188 15.949219 17.285156 16 17 L 16 14 L 18.5 17.359375 C 18.617188 17.515625 18.804688 17.605469 19 17.601562 C 19.066406 17.601562 19.128906 17.589844 19.191406 17.570312 C 19.433594 17.488281 19.601562 17.257812 19.601562 17 L 19.601562 12.199219 C 19.601562 11.867188 19.332031 11.601562 19 11.601562 Z M 19 11.601562 "}),e.createElement("path",{fill:"#00cf2e",d:"M 23.398438 15.199219 C 23.730469 15.199219 24 14.929688 24 14.601562 C 24 14.269531 23.730469 14 23.398438 14 L 21.601562 14 L 21.601562 12.800781 L 23.398438 12.800781 C 23.730469 12.800781 24 12.53125 24 12.199219 C 24 11.867188 23.730469 11.601562 23.398438 11.601562 L 21 11.601562 C 20.667969 11.601562 20.398438 11.867188 20.398438 12.199219 L 20.398438 17 C 20.398438 17.332031 20.667969 17.601562 21 17.601562 L 23.398438 17.601562 C 23.730469 17.601562 24 17.332031 24 17 C 24 16.667969 23.730469 16.398438 23.398438 16.398438 L 21.601562 16.398438 L 21.601562 15.199219 Z M 23.398438 15.199219 "}))),name:"Line",href:`http://line.me/R/msg/text/?${l}`,allowedLocales:[t.Taiwan]}];export{l as g};
|
package/build/esm/hooks.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as useInitialMount,u as useTranslations,b as useUniqueId}from"./useTranslations-
|
|
1
|
+
export{a as useInitialMount,u as useTranslations,b as useUniqueId}from"./useTranslations-3a1f0a5e.js";export{M as MEASURE_ELEMENT_CLASS,u as useScrollbarSize}from"./useScrollbarSize-6e27c5de.js";export{u as useFbDataLayer,a as usePrevious,b as useRafState}from"./useRafState-48a85c6f.js";export{u as useHealthToolsCache}from"./useHealthToolCache-3e969843.js";export{u as useIsInit}from"./useIsInit-aacf8bc0.js";export{i as initSharedOutSideClickListener,a as useOutsideClick,u as useSharedOutsideClick}from"./useOutsideClick-3515d44f.js";export{M as MAPPED_CATEGORY_SLUGS,P as PREGNANCY_SLUG,u as useCategory}from"./useCategory-e6bf1fff.js";import"react";import"./translationsContext-8efd3a3b.js";import"string-format";import"lodash/debounce";import"./tslib.es6-4213f703.js";import"./cookieHelper-d48ad6f0.js";import"./getDynamicHealthTool-11436c03.js";import"./core-14561d71.js";import"./isProduction-52c76560.js";import"./normalizeLink-59af508a.js";import"./routing-998bc5c2.js";import"./index-2edd91fd.js";import"date-fns/locale";import"./Onboarding-8c3938e0.js";
|
package/build/esm/i18n.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{T as s}from"./translationsContext-
|
|
1
|
+
import{T as s}from"./translationsContext-8efd3a3b.js";export{T as TranslationsContext}from"./translationsContext-8efd3a3b.js";import o,{useState as e,useEffect as r,useMemo as t}from"react";import i from"./i18n-values/en-PH.js";import n from"./i18n-values/hi-IN.js";import a from"./i18n-values/id-ID.js";import l from"./i18n-values/km-KH.js";import m from"./i18n-values/ms-MY.js";import v from"./i18n-values/my-MM.js";import j from"./i18n-values/th-TH.js";import u from"./i18n-values/tl-PH.js";import f from"./i18n-values/vi-VN.js";import p from"./i18n-values/vi-VN_MB.js";import c from"./i18n-values/zh-TW.js";const d={"en-PH":i,"vi-VN":f,"hi-IN":n,"id-ID":a,"ms-MY":m,"my-MM":v,"km-KH":l,"zh-TW":c,"th-TH":j,"tl-PH":u,"vi-VN_MB":p},h=({locale:i="en-PH",overrides:n,overrideCurrentLocale:a,children:l,shouldLoadTranslation:m=!0,loader:v=null,onTranslationsLoaded:j})=>{const u=n&&n[i]||a,[f,p]=e((()=>Object.assign(Object.assign({},u),m?d[i]:{})));r((()=>{p(Object.assign(Object.assign({},u),m?d[i]:{}))}),[m,i]);const c=t((()=>f?{locale:i,values:f}:null),[i,f]);return r((()=>{j&&Object.keys(f).length&&j(f)}),[f]),o.createElement(s.Provider,{value:c},c?l:v)};export{h as TranslationsProvider,d as translationsMap};
|
package/build/esm/i18nV2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{T as e}from"./translationsContext-
|
|
1
|
+
import{T as e}from"./translationsContext-8efd3a3b.js";export{T as TranslationsContext}from"./translationsContext-8efd3a3b.js";import t,{useMemo as o}from"react";const a=({locale:a="en-PH",values:r,children:n})=>{const l=o((()=>r?{locale:a,values:r}:null),[a,r]);return t.createElement(e.Provider,{value:l},n)};export{a as TranslationsProvider};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import e,{useState as t,useRef as a,useMemo as n,useEffect as i,Fragment as r,memo as o,useCallback as l,useImperativeHandle as s,forwardRef as c,createContext as d,useContext as m}from"react";import{T as p,I as h}from"./index-9e896146.js";import{f as u,g,h as b,i as f,j as v,k as y,l as x,m as w,n as E,o as k,p as C,q as S,r as N,s as B,t as T,u as D,v as I,w as z,x as _,H as A,T as L,y as P,Z as $,P as M,z as O,A as j,B as F,C as H,E as R,d as U,F as V,I as W,J as G}from"./index.styles-1b3ed9ef.js";import{i as q,M as Z}from"./screenSizeContext-01c0829e.js";import{T as Y}from"./index-8bf77698.js";import{b as X,u as K}from"./useTranslations-d7353bde.js";import"lodash/debounce";import{i as J}from"./isProduction-d4dd3302.js";import{d as Q,L as ee,F as te,Q as ae,R as ne,a as ie,G as re}from"./index-18df2d15.js";import"./useCategory-559c57b8.js";import{CommonGAssets as oe}from"./gAssets.js";import{t as le}from"./theme-78a0ec17.js";import{_ as se,a as ce}from"./tslib.es6-e075fd14.js";import{Box as de,Radio as me,Flex as pe,rem as he,Card as ue,Group as ge,createStyles as be,getStylesRef as fe,useMantineTheme as ve,Container as ye,Stack as xe,UnstyledButton as we,AspectRatio as Ee,ScrollArea as ke,Chip as Ce,Badge as Se,MultiSelect as Ne,Stepper as Be}from"@mantine/core";import Te from"innertext";import{u as De,A as Ie,a as ze,b as _e,c as Ae,d as Le,B as Pe,e as $e,I as Me,f as Oe,g as je,t as Fe}from"./index-3107d233.js";import"@mantine/dates";import{G as He,L as Re}from"./Onboarding-2b508269.js";import Ue from"dayjs";import Ve,{keyframes as We,css as Ge}from"styled-components";import"./translationsContext-e7d1541a.js";import"string-format";import{useViewportSize as qe}from"@mantine/hooks";import{i as Ze}from"./index-a0fc1ef4.js";import Ye from"lodash/throttle";import{L as Xe}from"./index-dbbbb305.js";import{B as Ke}from"./index-62ecf56a.js";import{I as Je}from"./index-911ef162.js";import{format as Qe,addDays as et,isBefore as tt,startOfMonth as at,addMonths as nt,subMonths as it,getDaysInMonth as rt,isToday as ot,isSameDay as lt,isWithinInterval as st,isAfter as ct,isPast as dt}from"date-fns";import"./utils-623afa37.js";import"./index.styled-d6b0ebe7.js";import"./index-cc1afaef.js";import{L as mt}from"./constants-6a448cae.js";import{D as pt}from"./types-f429485e.js";import{S as ht}from"./index-a7edfb36.js";import{M as ut}from"./index-3764269a.js";import{b as gt}from"./index.styled-18ea8428.js";import{C as bt}from"./index-213c0fdc.js";import{useForm as ft,Controller as vt}from"react-hook-form";import{u as yt}from"./useHealthToolCache-0e0d41d0.js";import{yupResolver as xt}from"@hookform/resolvers/yup";import{B as wt,D as Et}from"./index-226c09bf.js";import{f as kt}from"./index-f7429df6.js";import Ct from"react-day-picker/DayPickerInput";import{a as St}from"./useOutsideClick-dc84e0ad.js";import Nt from"date-fns/locale/en-US";import Bt from"date-fns/locale/id";import Tt from"date-fns/locale/vi";import Dt from"date-fns/locale/zh-TW";import{g as It}from"./getSocialList-316e9141.js";import{v4 as zt}from"uuid";import{g as _t,a as At}from"./routing-d8af5355.js";import{useForm as Lt,isNotEmpty as Pt}from"@mantine/form";import{M as $t}from"./index-864a8b89.js";import Mt from"js-cookie";import Ot from"lodash/flatten";import"react-contenteditable";import"react-dom";import jt from"lodash/uniqBy";var Ft="CHw-fZZ",Ht="_03U6VRS",Rt="EO828Vv";const Ut=({style:t,onClose:a,text:n,type:i,contentIcon:r,closeIcon:o,className:l,description:s})=>e.createElement("div",{className:`${Ft} ${l||""}`,style:t,"data-alert-type":i},e.createElement("div",{className:Ht},e.createElement("div",{className:"icon-title"},r,e.createElement(p,{weight:"bold",size:"label1"},n)),e.createElement(p,{weight:"regular",size:"p3"},s)),e.createElement("div",{className:Rt,onClick:a},o)),Vt=({amount:t,type:a,size:n="medium",color:i="primary",icon:r,className:o})=>e.createElement(u,{"data-notification-type":a,"data-notification-size":n,"data-notification-color":i,"data-has-icon":!!r||void 0,notificationType:a,notificationSize:n,notificationColor:i,hasIcon:!!r,className:o},e.createElement("div",null,t&&e.createElement("span",null,t)," ",r&&e.createElement("div",null,r))),Wt=({style:t,children:a,className:n,size:i="lg",type:r="bold",upperCase:o,as:l="h4",color:s})=>e.createElement(g,{style:Object.assign({color:s},t),className:n,"data-size":i,"data-type":r,"data-uppercase":o,as:l},a),Gt=()=>e.createElement("style",null,".file-dropdown-path{fill:none;stroke:#595959;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px}"),qt=()=>e.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 12.17 14.83"},e.createElement("defs",null,e.createElement("clipPath",{id:"prefix__clip-path",transform:"translate(-1.92 -1.54)"},e.createElement("path",{fill:"none",d:"M0 .96h16v16H0z"}))),e.createElement("title",null,"File"),e.createElement("g",{clipPath:"url(#prefix__clip-path)"},e.createElement("path",{className:"file-dropdown-path",d:"M8.67 2.29H4a1.33 1.33 0 00-1.33 1.33v10.67A1.33 1.33 0 004 15.62h8a1.33 1.33 0 001.33-1.33V7z",transform:"translate(-1.92 -1.54)"}),e.createElement("path",{className:"file-dropdown-path",d:"M8.67 2.29V7h4.66",transform:"translate(-1.92 -1.54)"}))),Zt=()=>e.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 13.5 13.5"},e.createElement("title",null,"download"),e.createElement("path",{className:"file-dropdown-path",d:"M14 11v2.66A1.33 1.33 0 0112.67 15H3.33A1.33 1.33 0 012 13.62V11M4.67 7.62L8 11l3.33-3.34M8 11V3",transform:"translate(-1.25 -2.21)"})),Yt=()=>e.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 13.5 13.5"},e.createElement("title",null,"upload"),e.createElement("path",{className:"file-dropdown-path",d:"M14 11v2.66A1.33 1.33 0 0112.67 15H3.33A1.33 1.33 0 012 13.62V11M11.33 6.29L8 3 4.67 6.29M8 3v8",transform:"translate(-1.25 -2.21)"})),Xt=({className:n,value:i,options:r,onUploadSelected:o,id:l,placeholderIcon:s,placeholder:c,style:d})=>{const[m,p]=t(!1),h=()=>p(!m),u=a(r.map((t=>"upload"===t.type&&e.createElement("input",{id:"uploader-dropdown-input-"+l+"-"+t.value,key:"uploader-dropdown-input-"+l+"-"+t.value,accept:t.fileAcceptedType,multiple:t.multiple,type:"file",style:{display:"none"},onChange:e=>{console.log("change"),o(e.target.files)}}))));return e.createElement(b,{className:n,"data-dropdown-open":!!m,id:l,"data-has-icons":!0,style:d,onBlur:()=>p(!1),tabIndex:0},e.createElement(Gt,null),e.createElement(f,{onClick:h},s||e.createElement(qt,null)," ",e.createElement("span",null,i&&i.value?i.label:c)),m&&e.createElement(v,{onClick:h,"data-has-icons":!0},r.map((t=>e.createElement(y,{key:`${l}-${t.value}`,"data-selected":i&&i.value===t.value||void 0,onClick:()=>{return"upload"===t.type?(a="#uploader-dropdown-input-"+l+"-"+t.value,void(null===(n=document.querySelector(a))||void 0===n||n.click())):void((e=t.url)&&window.open(e,"_blank"));var e,a,n}},e.createElement(x,null,t.icon||"download"===t.type?e.createElement(Zt,null):e.createElement(Yt,null)),t.label)))),e.createElement(e.Fragment,null,u.current))},Kt=({className:t,columns:a,columnsDesktop:n,gridTemplateColumns:i,gridTemplateColumnsDesktop:r,gap:o,children:l,justifyChildren:s,style:c,alignItems:d})=>e.createElement(w,{className:t,style:c,theme:{columns:a,columnsDesktop:n,gap:o,justifyChildren:s,gridTemplateColumns:i,gridTemplateColumnsDesktop:r,alignItems:d}},l),Jt=({pagesAmount:a,activePage:n,handlePageChange:o,handleClick:l,href:s,queryPageName:c="page"})=>{const d=[...Array(a)].map(((e,t)=>t+1)),[m,p]=t(n<=4?d.slice(0,5):n>=d.length-3?d.slice(d.length-5,d.length):d.slice(n-2,n+1));return i((()=>{n<=4?p(d.slice(0,5)):n>=d.length-3?p(d.slice(d.length-5,d.length)):p(d.slice(n-2,n+1))}),[n]),e.createElement(r,null,n>4&&e.createElement(r,null,e.createElement(C,{onClick:()=>o(1)},s?e.createElement("a",{href:s,onClick:l},1):1),e.createElement(C,null,"...")),m.map((t=>e.createElement(C,{key:`pagination+${t}`,"data-page-active":t===n||void 0,onClick:()=>o(t)},s?e.createElement("a",{href:q(s,t,c),onClick:l},t):t))),n<d.length-3&&e.createElement(r,null,e.createElement(C,null,"..."),e.createElement(C,{onClick:()=>o(d.length)},s?e.createElement("a",{href:q(s,d.length,c),onClick:l},d.length):d.length)))},Qt=({className:a,pagesAmount:r,currentPage:o,onChange:l,onClick:s,style:c,href:d,queryPageName:m="page"})=>{const p=[...Array(r)].map(((e,t)=>t+1)),[h,u]=t(o),g=n((()=>d&&d.endsWith("&page=")?d.replace("&page=",""):d),[d]),b=r-1,f=e=>{e<=r&&e>0&&(u(e),l(e))},v=e=>{s&&s(e)};return i((()=>{u(o)}),[o]),e.createElement(E,{className:a,style:c},e.createElement(k,{className:"prev-page",onClick:()=>f(h-1),"data-last-page":1===h||void 0},g?e.createElement("a",{href:q(g,h,m),onClick:v},e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M5.5 9L1.5 5L5.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))):e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M5.5 9L1.5 5L5.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))),p.length>8?e.createElement(Jt,{pagesAmount:r,activePage:h,handlePageChange:f,handleClick:v,href:g,queryPageName:m}):p.map((t=>e.createElement(C,{key:`pagination+${t}`,"data-page-active":t===h||void 0,onClick:()=>f(t)},g?e.createElement("a",{href:q(g,t,m),onClick:v},t):t))),e.createElement(k,{className:"next-page",onClick:()=>f(h+1),"data-last-page":h===b+1||void 0},g?e.createElement("a",{href:q(g,h,m),onClick:v},e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M1.5 9L5.5 5L1.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))):e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M1.5 9L5.5 5L1.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))))},ea=({type:t,size:a="small",label:n,name:i,checked:r,value:o,className:l,isDisabled:s=!1,onChange:c,dataEventCategory:d,dataEventAction:m,dataEventLabel:p})=>{const h=!!m&&!!d&&!!p?{"data-event-category":d,"data-event-action":m,"data-event-label":p}:{};return e.createElement(S,{"data-disabled":s,className:l,"data-type":t,"data-size":a},e.createElement("label",Object.assign({style:{display:"flex",alignItems:"center"},"data-checked":r},h),e.createElement("input",Object.assign({type:"radio",checked:r,name:i,value:o,onChange:()=>c(o)},h)),n))},ta=({type:t,children:a,style:n,isInline:i,isSquared:r=!1,className:o,isLight:l,hasMorePadding:s,isLink:c,isSelected:d,textProps:m={size:"sm"}})=>{const p=m.color?{"--text-props-color":m.color}:{};return e.createElement(N,{"data-is-squared":r||void 0,"data-tag-type":t,"data-is-light":l||void 0,"data-has-more-padding":s||void 0,"data-is-inline":i||void 0,style:Object.assign(Object.assign({},n),p),className:o,"data-is-selected":d||void 0,"data-is-link":c||void 0,tagType:t,isInline:i,tagHasMorePadding:s,tagIsLight:l,tagIsSquared:r,tagIsALink:c},e.createElement(Y,Object.assign({},m),a))},aa=({className:t,id:a,onChange:n,checked:i,style:r,label:o})=>e.createElement(B,{className:t,style:r},e.createElement("input",{type:"checkbox",id:a,onChange:n,checked:i}),e.createElement("label",{htmlFor:a},e.createElement(T,null),o&&e.createElement(D,null,o))),na=({label:t,name:a,checked:n,className:i,isDisabled:r,onChange:o,value:l,isRectangle:s,inputDataTestId:c,siteType:d})=>e.createElement(I,{className:i,"data-disabled":r||void 0,"data-is-rectangle":s||void 0,"data-label-text":t,"data-theme":d},e.createElement("input",{type:"checkbox",checked:n,name:a,onChange:()=>o(l,!n),disabled:r,value:l,id:`${a}-${l}`,"data-label-text":t,"data-testid":c}),!s&&e.createElement("label",{htmlFor:`${a}-${l}`},t)),ia=t=>e.createElement("svg",Object.assign({},t,{viewBox:"0 0 32 32",fill:"none"}),e.createElement("path",{d:"M16.0002 23.0266L22.8935 27.1866C23.4002 27.4933 24.0268 27.04 23.8935 26.4666L22.0668 18.6266L28.1468 13.36C28.5868 12.9733 28.3602 12.24 27.7602 12.1866L19.7468 11.5066L16.6135 4.11996C16.3868 3.57329 15.6135 3.57329 15.3868 4.11996L12.2535 11.5066L4.24016 12.1866C3.65349 12.24 3.41349 12.9733 3.86682 13.36L9.94682 18.6266L8.12016 26.4666C7.98682 27.04 8.61349 27.4933 9.12016 27.1866L16.0002 23.0266Z",fill:"#D2D6DC"})),ra=t=>e.createElement("svg",Object.assign({},t,{width:"32",height:"32",viewBox:"0 0 32 32",fill:"none"}),e.createElement("path",{d:"M16.0002 23.0266L22.8935 27.1866C23.4002 27.4933 24.0268 27.04 23.8935 26.4666L22.0668 18.6266L28.1468 13.36C28.5868 12.9733 28.3602 12.24 27.7602 12.1866L19.7468 11.5066L16.6135 4.11996C16.3868 3.57329 15.6135 3.57329 15.3868 4.11996L12.2535 11.5066L4.24016 12.1866C3.65349 12.24 3.41349 12.9733 3.86682 13.36L9.94682 18.6266L8.12016 26.4666C7.98682 27.04 8.61349 27.4933 9.12016 27.1866L16.0002 23.0266Z",fill:"#FFC326"})),oa=t=>{const a=X();return e.createElement("svg",Object.assign({},t,{viewBox:"0 0 24 24",fill:"none"}),e.createElement("path",{d:"M12.0001 17.2697L17.1701 20.3897C17.5501 20.6197 18.0201 20.2797 17.9201 19.8497L16.5501 13.9697L21.1101 10.0197C21.4401 9.72973 21.2701 9.17973 20.8201 9.13973L14.8101 8.62973L12.4601 3.08973C12.2901 2.67973 11.7101 2.67973 11.5401 3.08973L9.19006 8.62973L3.18006 9.13973C2.74006 9.17973 2.56006 9.72973 2.90006 10.0197L7.46006 13.9697L6.09006 19.8497C5.99006 20.2797 6.46006 20.6197 6.84006 20.3897L12.0001 17.2697Z",fill:"#E4E8EC"}),e.createElement("mask",{id:a,maskUnits:"userSpaceOnUse",x:"2",y:"0",width:"10",height:"24"},e.createElement("rect",{x:"2",width:"10",height:"24",fill:"#C4C4C4"})),e.createElement("g",{mask:`url(#${a})`},e.createElement("path",{d:"M11.9998 17.2697L17.1698 20.3897C17.5498 20.6197 18.0198 20.2797 17.9198 19.8497L16.5498 13.9697L21.1098 10.0197C21.4398 9.72973 21.2698 9.17973 20.8198 9.13973L14.8098 8.62973L12.4598 3.08973C12.2898 2.67973 11.7098 2.67973 11.5398 3.08973L9.18981 8.62973L3.17981 9.13973C2.73981 9.17973 2.55981 9.72973 2.89981 10.0197L7.45981 13.9697L6.08981 19.8497C5.98981 20.2797 6.45981 20.6197 6.83981 20.3897L11.9998 17.2697Z",fill:"#FFC326"})))},la=({gap:a=2,size:n=24,star:i,totalStars:r=5,onSelect:o,hideEmptyStars:l,style:s,className:c})=>{const d=Math.floor(i),m=i-d>=.5?1:0,[p,h]=t(null),u=p||d,g=p?0:m;return e.createElement(z,{"data-selectable":!!o,style:Object.assign({"--gap":a,"--star-size":n},s),className:c},Array.from({length:l?d+m:r}).map(((t,a)=>{const n=()=>!!o&&h(a+1),i=()=>!!o&&h(null);return a+1<=u?e.createElement(ra,{key:a,onClick:()=>null==o?void 0:o(a+1),onMouseOver:n,onMouseLeave:i}):a+1===u+g?e.createElement(oa,{key:a,onClick:()=>null==o?void 0:o(a+1),onMouseOver:n,onMouseLeave:i}):e.createElement(ia,{key:a,onClick:()=>null==o?void 0:o(a+1),onMouseOver:n,onMouseLeave:i})})))},sa=r=>{var{label:o,availableValue:l,styles:s,isBaby:c,genderValue:d={male:"male",female:"female"}}=r,m=se(r,["label","availableValue","styles","isBaby","genderValue"]);const{t:h}=K(),{classes:u,cx:g}=_(void 0,{name:"GenderOptionControl",styles:s}),[b,f]=t(),v=a(null),y=n((()=>[{value:d.male,label:h(c?"gender.boy":"gender.male"),icon:oe.getAssetPath(c?"health-tools/boy-icon.svg":"health-tools/male-icon.svg")},{value:d.female,label:h(c?"gender.girl":"gender.female"),icon:oe.getAssetPath(c?"health-tools/girl-icon.svg":"health-tools/female-icon.svg")}]),[]);return i((()=>{f(l)}),[l]),e.createElement(de,{ref:v,className:u.root},e.createElement(me.Group,Object.assign({className:"radio-group",label:e.createElement(p,{as:"label",size:"s4",weight:"semiBold"},o||h(c?"tools.selectBabyGender":"tools.selectGender")),size:"lg"},m,{classNames:{error:u.groupErr}}),e.createElement(pe,{className:g(u.wrapper)},y.map((t=>e.createElement(me,Object.assign({className:"gender-item",classNames:{root:u.itemRoot,labelWrapper:u.itemLabelWrapper,label:u.itemLabel,inner:u.itemInner},key:t.value,value:t.value},b&&t.value!==b&&{disabled:!0},{label:e.createElement(pe,{gap:he(8),align:"center",justify:"center",sx:{zIndex:0}},e.createElement("img",{src:t.icon,className:"gender-image",alt:"female",loading:"lazy"}),e.createElement(p,{size:"p3"},t.label))})))))))};var ca="tliWyii";const da=({className:t,theme:a,hideText:n})=>{const{t:i}=K();return e.createElement("div",{className:`${ca} ${t}`},e.createElement(h.Spinner,{isMarryBaby:"marryBaby"===a}),!n&&i("loading"))};var ma="PiqKaXk",pa="HgbW6-m",ha="_6lkfLYy",ua="j7c-onH";const ga=({avatarImg:t,authorName:a,authorLink:n,uploadTime:i,size:r})=>e.createElement("div",{className:ua},e.createElement("div",{className:"author"},e.createElement("div",{className:"avatar","data-size":r},t),e.createElement("div",{className:"poster","data-is-disabled-url":!n},e.createElement(p,{size:"lg"===r?"p3":"p4"},e.createElement("a",{href:n},e.createElement("span",{className:"name"},a),"•"," "),e.createElement("span",null,i))))),ba=({isMobile:t,avatarImg:a,name:n,link:i,size:r="lg",specialty:o})=>e.createElement("div",{className:ua},e.createElement("div",{className:"author"},e.createElement("div",{className:"expert-avatar","data-size":r},a),e.createElement("div",{className:"expert","data-is-disabled-url":!i},t?e.createElement("a",{href:i},"lg"===r?e.createElement(e.Fragment,null,e.createElement(A,{tag:"h6",className:"expert__name",color:le.colors.gray600},n),e.createElement(p,{color:le.colors.gray500,size:"p3",className:"specialty"},o)):e.createElement(e.Fragment,null,e.createElement(A,{tag:"h6",className:"expert__name",color:le.colors.gray600},n))):e.createElement("a",{href:i},"lg"===r?e.createElement(e.Fragment,null,e.createElement(A,{tag:"h6",className:"expert__name",color:le.colors.gray600},n),e.createElement(p,{color:le.colors.gray500,size:"p3",className:"specialty"},o)):e.createElement(e.Fragment,null,e.createElement("h6",{color:le.colors.gray600,className:`${ma} expert__name`},n),e.createElement(p,{color:le.colors.gray500,size:"p4",className:"specialty"},o)))))),fa=o((()=>e.createElement("div",{className:"shoppable"},e.createElement("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},e.createElement("rect",{width:"24",height:"24",rx:"12",fill:"#1B3250"}),e.createElement("path",{d:"M16.6667 8.00033H15.3333C15.3333 6.16033 13.84 4.66699 12 4.66699C10.16 4.66699 8.66667 6.16033 8.66667 8.00033H7.33333C6.6 8.00033 6 8.60033 6 9.33366V17.3337C6 18.067 6.6 18.667 7.33333 18.667H16.6667C17.4 18.667 18 18.067 18 17.3337V9.33366C18 8.60033 17.4 8.00033 16.6667 8.00033ZM12 6.00033C13.1067 6.00033 14 6.89366 14 8.00033H10C10 6.89366 10.8933 6.00033 12 6.00033ZM12 12.667C10.4467 12.667 9.14 11.607 8.77333 10.167C8.66 9.74699 8.98667 9.33366 9.42 9.33366C9.73333 9.33366 9.98667 9.56033 10.0733 9.86699C10.3067 10.7137 11.08 11.3337 12 11.3337C12.92 11.3337 13.6933 10.7137 13.9267 9.86699C14.0133 9.56033 14.2667 9.33366 14.58 9.33366C15.0133 9.33366 15.3333 9.74699 15.2267 10.167C14.86 11.607 13.5533 12.667 12 12.667Z",fill:"white"}))))),va=o((({dataEventCategoryForBookmark:t,dataEventActionForBookmark:a,dataEventLabelForBookmark:n})=>e.createElement("svg",{"data-event-category":t,"data-event-action":a,"data-event-label":n,width:"14",height:"16",viewBox:"0 0 14 16",fill:"none"},e.createElement("path",{d:"M13 15L7 11.1111L1 15V2.55556C1 2.143 1.18061 1.74733 1.5021 1.45561C1.82359 1.16389 2.25963 1 2.71429 1H11.2857C11.7404 1 12.1764 1.16389 12.4979 1.45561C12.8194 1.74733 13 2.143 13 2.55556V15Z",fill:"#2ED69E",stroke:"#2ED69E",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})))),ya=o((({dataEventCategoryForBookmark:t,dataEventActionForBookmark:a,dataEventLabelForBookmark:n})=>e.createElement("svg",{"data-event-category":t,"data-event-action":a,"data-event-label":n,width:"18",height:"18",viewBox:"0 0 18 18",fill:"none"},e.createElement("path",{d:"M12.75 2.25H5.25C4.425 2.25 3.75 2.925 3.75 3.75V15.75L9 13.5L14.25 15.75V3.75C14.25 2.925 13.575 2.25 12.75 2.25Z",fill:"#D2D6DC"})))),xa=({articleLink:t,authorLink:a,authorName:n,avatarImg:i,banner:r,categoryLink:o,categoryName:l,className:s,dataEventActionForBanner:c,dataEventActionForBookmark:d,dataEventActionForCategory:m,dataEventActionForTitle:h,dataEventCategoryForBanner:u,dataEventCategoryForBookmark:g,dataEventCategoryForCategory:b,dataEventCategoryForTitle:f,dataEventLabelForBanner:v,dataEventLabelForBookmark:y,dataEventLabelForCategory:x,dataEventLabelForTitle:w,direction:E="horizontal",hasAffiliate:k,isBookmark:C=!1,isBookmarkDisplayed:S=!0,isMobile:N=!0,onBookmark:B,onClickCategoryName:T,section:D="normal",size:I="md",specialty:z,style:_,styleBanner:L,styleLabel:P,styleTitle:$,text:M,title:O,type:j="author",uploadTime:F,articleLinkTarget:H,isPremium:R})=>{const U=e=>{e.stopPropagation(),null==B||B()},V="lg"===I&&"expert"===j?"h4":"lg"===I&&"home"===D?N?"h4":"h3":"lg"===I?"h4":"h5",W="lg"===I?"p3":"p4",G=N||"home"!==D||"lg"!==I||"author"!==j?"c2":"c1";return e.createElement("article",{className:`${ha} ${s||""}`,"data-size":I,style:_,"data-direction":E,"data-is-expert":"expert"===j||void 0},e.createElement("div",{className:"banner",style:L},e.createElement("a",{className:pa,"data-event-category":u,"data-event-action":c,"data-event-label":v,href:t||"#",target:H},r),R&&e.createElement("img",{loading:"lazy",className:"premium",src:oe.getAssetPath("premium-crown.svg")}),k&&e.createElement(fa,null)),e.createElement("div",{className:"content"},e.createElement("div",{className:"inner-content"},e.createElement(p,{style:P,className:"label",size:G,weight:"caption"},e.createElement("a",{className:pa,"data-event-category":b,"data-event-action":m,"data-event-label":x,href:o||"#",onClick:T},l),S&&e.createElement("a",{className:"bookmark",onClick:U},C?e.createElement(va,{dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}):e.createElement(ya,{dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}))),e.createElement(A,{tag:V,style:$,className:"title",as:"lg"===I?"h2":"h3"},e.createElement("a",{className:pa,"data-event-category":f,"data-event-action":h,"data-event-label":w,href:t||"#",target:H},O)),M&&e.createElement("a",{href:t||"#",target:H},e.createElement(p,{size:W,className:"text"},M))),e.createElement("div",{className:"footer"},"author"===j?e.createElement(ga,{size:I,avatarImg:i,authorName:n,authorLink:a,uploadTime:F,handleClick:U,isBookmarked:C,dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}):e.createElement(ba,{size:I,isMobile:N,avatarImg:i,specialty:z,name:n,link:a,handleClick:U,isBookmarked:C,dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}))))},wa=t=>{var a,n,i,{article:r,author:o,authorAvatar:l,badge:s="",hideDescription:c=!1,isBookmarked:d=!1,onBookmark:m,time:h,tracking:u}=t,g=se(t,["article","author","authorAvatar","badge","hideDescription","isBookmarked","onBookmark","time","tracking"]);const{isMobile:b}=De();return console.log({article:r}),e.createElement(ue,Object.assign({padding:0,radius:0,sx:{display:"flex",flexDirection:"row",gap:24}},g),e.createElement(ue.Section,{w:"100%",h:"100%",miw:264,m:0,className:"pointer"},e.createElement("img",{src:(b?r.featureImageMobile:r.featureImage)||r.featureImage,alt:r.postName,style:{width:"100%"},loading:"lazy"})),e.createElement(ue.Section,null,e.createElement(ge,{position:"apart",mt:16,mb:4},e.createElement(Ie,{href:(null===(a=null==r?void 0:r.primaryCategory)||void 0===a?void 0:a.permalink)||"#"},e.createElement(p,{size:"p4",color:"blue.6"},null===(n=null==r?void 0:r.primaryCategory)||void 0===n?void 0:n.displayName)),e.createElement(de,{sx:{cursor:"pointer"},role:"button",onClick:m},d?e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==u?void 0:u.bookmark),e.createElement("path",{d:"M6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7Z",fill:"#595959"})):e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==u?void 0:u.bookmark),e.createElement("path",{d:"M7 17.95L12 15.8L17 17.95V5.3C17 5.23333 16.9667 5.16667 16.9 5.1C16.8333 5.03333 16.7667 5 16.7 5H7.3C7.23333 5 7.16667 5.03333 7.1 5.1C7.03333 5.16667 7 5.23333 7 5.3V17.95ZM6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7ZM7 5H17H12H7Z",fill:"#595959"})))),e.createElement(p,{size:c?"s2":"s1",mb:8,weight:"semiBold",className:"pointer"},r.postTitle||r.postName||""),!c&&e.createElement(p,{size:"p2",mb:16,lineClamp:3,className:"pointer"},Te(r.excerpt||r.description||(null===(i=r.postContent)||void 0===i?void 0:i.split("\r\n")[0])||"")),e.createElement(pe,{gap:12,align:"center"},e.createElement(ze,{size:32,src:l,withIndicator:!0,indicatorConfig:{offset:5,size:18,label:e.createElement("img",{loading:"lazy",src:s,alt:""})}},"A"),e.createElement(p,{size:"n1",c:"gray.6"},o," • ",h))))};var Ea=be(((e,{})=>({root:{},image:{},title:{},category:{},description:{},author:{}})));const ka=648/440,Ca=1.5,Sa=t=>{var a,i,r,{article:o,author:l,authorAvatar:s,badge:c="",bannerImageWrapProps:d,hideDescription:m=!1,isBookmarked:h=!1,onBookmark:u,time:g,tracking:b,classNames:f,styles:v,unstyled:y,className:x}=t,w=se(t,["article","author","authorAvatar","badge","bannerImageWrapProps","hideDescription","isBookmarked","onBookmark","time","tracking","classNames","styles","unstyled","className"]);const{isMobile:E}=De(),{classes:k,cx:C}=Ea({},{name:"ArticleCard",classNames:f,styles:v,unstyled:y}),S=n((()=>m?Ca:ka),[m]);return e.createElement(ue,Object.assign({className:C(k.root,x),padding:"lg",radius:0},w),e.createElement(ue.Section,{className:C(k.image,"pointer")},e.createElement(_e,Object.assign({ratio:S},d),e.createElement("img",{src:(E?o.featureImageMobile:o.featureImage)||o.featureImage,alt:o.postName,style:{objectFit:"cover"}}))),e.createElement(ue.Section,null,e.createElement(ge,{position:"apart",mt:16,mb:4},e.createElement(Ie,{className:k.category,href:(null===(a=null==o?void 0:o.primaryCategory)||void 0===a?void 0:a.permalink)||"#"},e.createElement(p,{size:"p4",color:"blue.6"},null===(i=null==o?void 0:o.primaryCategory)||void 0===i?void 0:i.displayName)),e.createElement(de,{sx:{cursor:"pointer"},role:"button",onClick:u},h?e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==b?void 0:b.bookmark),e.createElement("path",{d:"M6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7Z",fill:"#595959"})):e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==b?void 0:b.bookmark),e.createElement("path",{d:"M7 17.95L12 15.8L17 17.95V5.3C17 5.23333 16.9667 5.16667 16.9 5.1C16.8333 5.03333 16.7667 5 16.7 5H7.3C7.23333 5 7.16667 5.03333 7.1 5.1C7.03333 5.16667 7 5.23333 7 5.3V17.95ZM6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7ZM7 5H17H12H7Z",fill:"#595959"})))),e.createElement(p,{className:C(k.title,"pointer"),size:m?"s2":"s1",mb:8,weight:"semiBold"},o.postTitle||o.postName||""),!m&&e.createElement(p,{className:C(k.description,"pointer"),size:"p2",mb:16,lineClamp:3},Te(o.excerpt||o.description||(null===(r=o.postContent)||void 0===r?void 0:r.split("\r\n")[0])||"")),e.createElement(pe,{className:k.author,gap:12,align:"center"},e.createElement(ze,{size:32,src:s,withIndicator:!0,indicatorConfig:{offset:5,size:18,label:e.createElement("img",{loading:"lazy",src:c,alt:""})}},"A"),e.createElement(p,{size:"n1",c:"gray.6"},l," • ",g))))},Na=t=>{var{variant:a="vertical"}=t,n=se(t,["variant"]);return"horizontal"===a?e.createElement(wa,Object.assign({},n)):e.createElement(Sa,Object.assign({},n))},Ba=Ve.a`
|
|
1
|
+
import e,{useState as t,useRef as a,useMemo as n,useEffect as i,Fragment as r,memo as o,useCallback as l,useImperativeHandle as s,forwardRef as c,createContext as d,useContext as m}from"react";import{T as p,I as h}from"./index-fc471630.js";import{f as u,g,h as b,i as f,j as v,k as y,l as x,m as w,n as E,o as k,p as C,q as S,r as N,s as B,t as T,u as D,v as I,w as z,x as _,H as A,T as L,y as P,Z as $,P as M,z as O,A as j,B as F,C as H,E as R,d as U,F as V,I as W,J as G}from"./index.styles-d8ab3053.js";import{i as q,M as Z}from"./screenSizeContext-be2375b1.js";import{T as Y}from"./index-e9467986.js";import{b as X,u as K}from"./useTranslations-3a1f0a5e.js";import"lodash/debounce";import{i as J}from"./isProduction-52c76560.js";import{d as Q,L as ee,F as te,Q as ae,R as ne,a as ie,G as re}from"./index-2edd91fd.js";import"./useCategory-e6bf1fff.js";import{CommonGAssets as oe}from"./gAssets.js";import{t as le}from"./theme-17fe8568.js";import{_ as se,a as ce}from"./tslib.es6-4213f703.js";import{Box as de,Radio as me,Flex as pe,rem as he,Card as ue,Group as ge,createStyles as be,getStylesRef as fe,useMantineTheme as ve,Container as ye,Stack as xe,UnstyledButton as we,AspectRatio as Ee,ScrollArea as ke,Chip as Ce,Badge as Se,MultiSelect as Ne,Stepper as Be}from"@mantine/core";import Te from"innertext";import{u as De,A as Ie,a as ze,b as _e,c as Ae,d as Le,B as Pe,e as $e,I as Me,f as Oe,g as je,t as Fe}from"./index-f7d54b3e.js";import"@mantine/dates";import{G as He,L as Re}from"./Onboarding-8c3938e0.js";import Ue from"dayjs";import Ve,{keyframes as We,css as Ge}from"styled-components";import"./translationsContext-8efd3a3b.js";import"string-format";import{useViewportSize as qe}from"@mantine/hooks";import{i as Ze}from"./index-9d32e317.js";import Ye from"lodash/throttle";import{L as Xe}from"./index-0cefeefb.js";import{B as Ke}from"./index-75dfeb72.js";import{I as Je}from"./index-433c4190.js";import{format as Qe,addDays as et,isBefore as tt,startOfMonth as at,addMonths as nt,subMonths as it,getDaysInMonth as rt,isToday as ot,isSameDay as lt,isWithinInterval as st,isAfter as ct,isPast as dt}from"date-fns";import"./utils-de689222.js";import"./index.styled-be95abd0.js";import"./index-5a0dc9ca.js";import{L as mt}from"./constants-bb592d87.js";import{D as pt}from"./types-028758a2.js";import{S as ht}from"./index-48ddad2b.js";import{M as ut}from"./index-bf09c5ae.js";import{b as gt}from"./index.styled-5f810be8.js";import{C as bt}from"./index-fa94e465.js";import{useForm as ft,Controller as vt}from"react-hook-form";import{u as yt}from"./useHealthToolCache-3e969843.js";import{yupResolver as xt}from"@hookform/resolvers/yup";import{B as wt,D as Et}from"./index-23a3b10b.js";import{f as kt}from"./index-efc1382a.js";import Ct from"react-day-picker/DayPickerInput";import{a as St}from"./useOutsideClick-3515d44f.js";import Nt from"date-fns/locale/en-US";import Bt from"date-fns/locale/id";import Tt from"date-fns/locale/vi";import Dt from"date-fns/locale/zh-TW";import{g as It}from"./getSocialList-07d25384.js";import{v4 as zt}from"uuid";import{g as _t,a as At}from"./routing-998bc5c2.js";import{useForm as Lt,isNotEmpty as Pt}from"@mantine/form";import{M as $t}from"./index-66ec59ce.js";import Mt from"js-cookie";import Ot from"lodash/flatten";import"react-contenteditable";import"react-dom";import jt from"lodash/uniqBy";var Ft="CHw-fZZ",Ht="_03U6VRS",Rt="EO828Vv";const Ut=({style:t,onClose:a,text:n,type:i,contentIcon:r,closeIcon:o,className:l,description:s})=>e.createElement("div",{className:`${Ft} ${l||""}`,style:t,"data-alert-type":i},e.createElement("div",{className:Ht},e.createElement("div",{className:"icon-title"},r,e.createElement(p,{weight:"bold",size:"label1"},n)),e.createElement(p,{weight:"regular",size:"p3"},s)),e.createElement("div",{className:Rt,onClick:a},o)),Vt=({amount:t,type:a,size:n="medium",color:i="primary",icon:r,className:o})=>e.createElement(u,{"data-notification-type":a,"data-notification-size":n,"data-notification-color":i,"data-has-icon":!!r||void 0,notificationType:a,notificationSize:n,notificationColor:i,hasIcon:!!r,className:o},e.createElement("div",null,t&&e.createElement("span",null,t)," ",r&&e.createElement("div",null,r))),Wt=({style:t,children:a,className:n,size:i="lg",type:r="bold",upperCase:o,as:l="h4",color:s})=>e.createElement(g,{style:Object.assign({color:s},t),className:n,"data-size":i,"data-type":r,"data-uppercase":o,as:l},a),Gt=()=>e.createElement("style",null,".file-dropdown-path{fill:none;stroke:#595959;stroke-linecap:round;stroke-linejoin:round;stroke-width:1.5px}"),qt=()=>e.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 12.17 14.83"},e.createElement("defs",null,e.createElement("clipPath",{id:"prefix__clip-path",transform:"translate(-1.92 -1.54)"},e.createElement("path",{fill:"none",d:"M0 .96h16v16H0z"}))),e.createElement("title",null,"File"),e.createElement("g",{clipPath:"url(#prefix__clip-path)"},e.createElement("path",{className:"file-dropdown-path",d:"M8.67 2.29H4a1.33 1.33 0 00-1.33 1.33v10.67A1.33 1.33 0 004 15.62h8a1.33 1.33 0 001.33-1.33V7z",transform:"translate(-1.92 -1.54)"}),e.createElement("path",{className:"file-dropdown-path",d:"M8.67 2.29V7h4.66",transform:"translate(-1.92 -1.54)"}))),Zt=()=>e.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 13.5 13.5"},e.createElement("title",null,"download"),e.createElement("path",{className:"file-dropdown-path",d:"M14 11v2.66A1.33 1.33 0 0112.67 15H3.33A1.33 1.33 0 012 13.62V11M4.67 7.62L8 11l3.33-3.34M8 11V3",transform:"translate(-1.25 -2.21)"})),Yt=()=>e.createElement("svg",{id:"prefix__Layer_1","data-name":"Layer 1",viewBox:"0 0 13.5 13.5"},e.createElement("title",null,"upload"),e.createElement("path",{className:"file-dropdown-path",d:"M14 11v2.66A1.33 1.33 0 0112.67 15H3.33A1.33 1.33 0 012 13.62V11M11.33 6.29L8 3 4.67 6.29M8 3v8",transform:"translate(-1.25 -2.21)"})),Xt=({className:n,value:i,options:r,onUploadSelected:o,id:l,placeholderIcon:s,placeholder:c,style:d})=>{const[m,p]=t(!1),h=()=>p(!m),u=a(r.map((t=>"upload"===t.type&&e.createElement("input",{id:"uploader-dropdown-input-"+l+"-"+t.value,key:"uploader-dropdown-input-"+l+"-"+t.value,accept:t.fileAcceptedType,multiple:t.multiple,type:"file",style:{display:"none"},onChange:e=>{console.log("change"),o(e.target.files)}}))));return e.createElement(b,{className:n,"data-dropdown-open":!!m,id:l,"data-has-icons":!0,style:d,onBlur:()=>p(!1),tabIndex:0},e.createElement(Gt,null),e.createElement(f,{onClick:h},s||e.createElement(qt,null)," ",e.createElement("span",null,i&&i.value?i.label:c)),m&&e.createElement(v,{onClick:h,"data-has-icons":!0},r.map((t=>e.createElement(y,{key:`${l}-${t.value}`,"data-selected":i&&i.value===t.value||void 0,onClick:()=>{return"upload"===t.type?(a="#uploader-dropdown-input-"+l+"-"+t.value,void(null===(n=document.querySelector(a))||void 0===n||n.click())):void((e=t.url)&&window.open(e,"_blank"));var e,a,n}},e.createElement(x,null,t.icon||"download"===t.type?e.createElement(Zt,null):e.createElement(Yt,null)),t.label)))),e.createElement(e.Fragment,null,u.current))},Kt=({className:t,columns:a,columnsDesktop:n,gridTemplateColumns:i,gridTemplateColumnsDesktop:r,gap:o,children:l,justifyChildren:s,style:c,alignItems:d})=>e.createElement(w,{className:t,style:c,theme:{columns:a,columnsDesktop:n,gap:o,justifyChildren:s,gridTemplateColumns:i,gridTemplateColumnsDesktop:r,alignItems:d}},l),Jt=({pagesAmount:a,activePage:n,handlePageChange:o,handleClick:l,href:s,queryPageName:c="page"})=>{const d=[...Array(a)].map(((e,t)=>t+1)),[m,p]=t(n<=4?d.slice(0,5):n>=d.length-3?d.slice(d.length-5,d.length):d.slice(n-2,n+1));return i((()=>{n<=4?p(d.slice(0,5)):n>=d.length-3?p(d.slice(d.length-5,d.length)):p(d.slice(n-2,n+1))}),[n]),e.createElement(r,null,n>4&&e.createElement(r,null,e.createElement(C,{onClick:()=>o(1)},s?e.createElement("a",{href:s,onClick:l},1):1),e.createElement(C,null,"...")),m.map((t=>e.createElement(C,{key:`pagination+${t}`,"data-page-active":t===n||void 0,onClick:()=>o(t)},s?e.createElement("a",{href:q(s,t,c),onClick:l},t):t))),n<d.length-3&&e.createElement(r,null,e.createElement(C,null,"..."),e.createElement(C,{onClick:()=>o(d.length)},s?e.createElement("a",{href:q(s,d.length,c),onClick:l},d.length):d.length)))},Qt=({className:a,pagesAmount:r,currentPage:o,onChange:l,onClick:s,style:c,href:d,queryPageName:m="page"})=>{const p=[...Array(r)].map(((e,t)=>t+1)),[h,u]=t(o),g=n((()=>d&&d.endsWith("&page=")?d.replace("&page=",""):d),[d]),b=r-1,f=e=>{e<=r&&e>0&&(u(e),l(e))},v=e=>{s&&s(e)};return i((()=>{u(o)}),[o]),e.createElement(E,{className:a,style:c},e.createElement(k,{className:"prev-page",onClick:()=>f(h-1),"data-last-page":1===h||void 0},g?e.createElement("a",{href:q(g,h,m),onClick:v},e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M5.5 9L1.5 5L5.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))):e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M5.5 9L1.5 5L5.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))),p.length>8?e.createElement(Jt,{pagesAmount:r,activePage:h,handlePageChange:f,handleClick:v,href:g,queryPageName:m}):p.map((t=>e.createElement(C,{key:`pagination+${t}`,"data-page-active":t===h||void 0,onClick:()=>f(t)},g?e.createElement("a",{href:q(g,t,m),onClick:v},t):t))),e.createElement(k,{className:"next-page",onClick:()=>f(h+1),"data-last-page":h===b+1||void 0},g?e.createElement("a",{href:q(g,h,m),onClick:v},e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M1.5 9L5.5 5L1.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))):e.createElement("svg",{width:"7",height:"10",viewBox:"0 0 7 10",fill:"none"},e.createElement("path",{d:"M1.5 9L5.5 5L1.5 1",stroke:"#2D87F3",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))))},ea=({type:t,size:a="small",label:n,name:i,checked:r,value:o,className:l,isDisabled:s=!1,onChange:c,dataEventCategory:d,dataEventAction:m,dataEventLabel:p})=>{const h=!!m&&!!d&&!!p?{"data-event-category":d,"data-event-action":m,"data-event-label":p}:{};return e.createElement(S,{"data-disabled":s,className:l,"data-type":t,"data-size":a},e.createElement("label",Object.assign({style:{display:"flex",alignItems:"center"},"data-checked":r},h),e.createElement("input",Object.assign({type:"radio",checked:r,name:i,value:o,onChange:()=>c(o)},h)),n))},ta=({type:t,children:a,style:n,isInline:i,isSquared:r=!1,className:o,isLight:l,hasMorePadding:s,isLink:c,isSelected:d,textProps:m={size:"sm"}})=>{const p=m.color?{"--text-props-color":m.color}:{};return e.createElement(N,{"data-is-squared":r||void 0,"data-tag-type":t,"data-is-light":l||void 0,"data-has-more-padding":s||void 0,"data-is-inline":i||void 0,style:Object.assign(Object.assign({},n),p),className:o,"data-is-selected":d||void 0,"data-is-link":c||void 0,tagType:t,isInline:i,tagHasMorePadding:s,tagIsLight:l,tagIsSquared:r,tagIsALink:c},e.createElement(Y,Object.assign({},m),a))},aa=({className:t,id:a,onChange:n,checked:i,style:r,label:o})=>e.createElement(B,{className:t,style:r},e.createElement("input",{type:"checkbox",id:a,onChange:n,checked:i}),e.createElement("label",{htmlFor:a},e.createElement(T,null),o&&e.createElement(D,null,o))),na=({label:t,name:a,checked:n,className:i,isDisabled:r,onChange:o,value:l,isRectangle:s,inputDataTestId:c,siteType:d})=>e.createElement(I,{className:i,"data-disabled":r||void 0,"data-is-rectangle":s||void 0,"data-label-text":t,"data-theme":d},e.createElement("input",{type:"checkbox",checked:n,name:a,onChange:()=>o(l,!n),disabled:r,value:l,id:`${a}-${l}`,"data-label-text":t,"data-testid":c}),!s&&e.createElement("label",{htmlFor:`${a}-${l}`},t)),ia=t=>e.createElement("svg",Object.assign({},t,{viewBox:"0 0 32 32",fill:"none"}),e.createElement("path",{d:"M16.0002 23.0266L22.8935 27.1866C23.4002 27.4933 24.0268 27.04 23.8935 26.4666L22.0668 18.6266L28.1468 13.36C28.5868 12.9733 28.3602 12.24 27.7602 12.1866L19.7468 11.5066L16.6135 4.11996C16.3868 3.57329 15.6135 3.57329 15.3868 4.11996L12.2535 11.5066L4.24016 12.1866C3.65349 12.24 3.41349 12.9733 3.86682 13.36L9.94682 18.6266L8.12016 26.4666C7.98682 27.04 8.61349 27.4933 9.12016 27.1866L16.0002 23.0266Z",fill:"#D2D6DC"})),ra=t=>e.createElement("svg",Object.assign({},t,{width:"32",height:"32",viewBox:"0 0 32 32",fill:"none"}),e.createElement("path",{d:"M16.0002 23.0266L22.8935 27.1866C23.4002 27.4933 24.0268 27.04 23.8935 26.4666L22.0668 18.6266L28.1468 13.36C28.5868 12.9733 28.3602 12.24 27.7602 12.1866L19.7468 11.5066L16.6135 4.11996C16.3868 3.57329 15.6135 3.57329 15.3868 4.11996L12.2535 11.5066L4.24016 12.1866C3.65349 12.24 3.41349 12.9733 3.86682 13.36L9.94682 18.6266L8.12016 26.4666C7.98682 27.04 8.61349 27.4933 9.12016 27.1866L16.0002 23.0266Z",fill:"#FFC326"})),oa=t=>{const a=X();return e.createElement("svg",Object.assign({},t,{viewBox:"0 0 24 24",fill:"none"}),e.createElement("path",{d:"M12.0001 17.2697L17.1701 20.3897C17.5501 20.6197 18.0201 20.2797 17.9201 19.8497L16.5501 13.9697L21.1101 10.0197C21.4401 9.72973 21.2701 9.17973 20.8201 9.13973L14.8101 8.62973L12.4601 3.08973C12.2901 2.67973 11.7101 2.67973 11.5401 3.08973L9.19006 8.62973L3.18006 9.13973C2.74006 9.17973 2.56006 9.72973 2.90006 10.0197L7.46006 13.9697L6.09006 19.8497C5.99006 20.2797 6.46006 20.6197 6.84006 20.3897L12.0001 17.2697Z",fill:"#E4E8EC"}),e.createElement("mask",{id:a,maskUnits:"userSpaceOnUse",x:"2",y:"0",width:"10",height:"24"},e.createElement("rect",{x:"2",width:"10",height:"24",fill:"#C4C4C4"})),e.createElement("g",{mask:`url(#${a})`},e.createElement("path",{d:"M11.9998 17.2697L17.1698 20.3897C17.5498 20.6197 18.0198 20.2797 17.9198 19.8497L16.5498 13.9697L21.1098 10.0197C21.4398 9.72973 21.2698 9.17973 20.8198 9.13973L14.8098 8.62973L12.4598 3.08973C12.2898 2.67973 11.7098 2.67973 11.5398 3.08973L9.18981 8.62973L3.17981 9.13973C2.73981 9.17973 2.55981 9.72973 2.89981 10.0197L7.45981 13.9697L6.08981 19.8497C5.98981 20.2797 6.45981 20.6197 6.83981 20.3897L11.9998 17.2697Z",fill:"#FFC326"})))},la=({gap:a=2,size:n=24,star:i,totalStars:r=5,onSelect:o,hideEmptyStars:l,style:s,className:c})=>{const d=Math.floor(i),m=i-d>=.5?1:0,[p,h]=t(null),u=p||d,g=p?0:m;return e.createElement(z,{"data-selectable":!!o,style:Object.assign({"--gap":a,"--star-size":n},s),className:c},Array.from({length:l?d+m:r}).map(((t,a)=>{const n=()=>!!o&&h(a+1),i=()=>!!o&&h(null);return a+1<=u?e.createElement(ra,{key:a,onClick:()=>null==o?void 0:o(a+1),onMouseOver:n,onMouseLeave:i}):a+1===u+g?e.createElement(oa,{key:a,onClick:()=>null==o?void 0:o(a+1),onMouseOver:n,onMouseLeave:i}):e.createElement(ia,{key:a,onClick:()=>null==o?void 0:o(a+1),onMouseOver:n,onMouseLeave:i})})))},sa=r=>{var{label:o,availableValue:l,styles:s,isBaby:c,genderValue:d={male:"male",female:"female"}}=r,m=se(r,["label","availableValue","styles","isBaby","genderValue"]);const{t:h}=K(),{classes:u,cx:g}=_(void 0,{name:"GenderOptionControl",styles:s}),[b,f]=t(),v=a(null),y=n((()=>[{value:d.male,label:h(c?"gender.boy":"gender.male"),icon:oe.getAssetPath(c?"health-tools/boy-icon.svg":"health-tools/male-icon.svg")},{value:d.female,label:h(c?"gender.girl":"gender.female"),icon:oe.getAssetPath(c?"health-tools/girl-icon.svg":"health-tools/female-icon.svg")}]),[]);return i((()=>{f(l)}),[l]),e.createElement(de,{ref:v,className:u.root},e.createElement(me.Group,Object.assign({className:"radio-group",label:e.createElement(p,{as:"label",size:"s4",weight:"semiBold"},o||h(c?"tools.selectBabyGender":"tools.selectGender")),size:"lg"},m,{classNames:{error:u.groupErr}}),e.createElement(pe,{className:g(u.wrapper)},y.map((t=>e.createElement(me,Object.assign({className:"gender-item",classNames:{root:u.itemRoot,labelWrapper:u.itemLabelWrapper,label:u.itemLabel,inner:u.itemInner},key:t.value,value:t.value},b&&t.value!==b&&{disabled:!0},{label:e.createElement(pe,{gap:he(8),align:"center",justify:"center",sx:{zIndex:0}},e.createElement("img",{src:t.icon,className:"gender-image",alt:"female",loading:"lazy"}),e.createElement(p,{size:"p3"},t.label))})))))))};var ca="tliWyii";const da=({className:t,theme:a,hideText:n})=>{const{t:i}=K();return e.createElement("div",{className:`${ca} ${t}`},e.createElement(h.Spinner,{isMarryBaby:"marryBaby"===a}),!n&&i("loading"))};var ma="PiqKaXk",pa="HgbW6-m",ha="_6lkfLYy",ua="j7c-onH";const ga=({avatarImg:t,authorName:a,authorLink:n,uploadTime:i,size:r})=>e.createElement("div",{className:ua},e.createElement("div",{className:"author"},e.createElement("div",{className:"avatar","data-size":r},t),e.createElement("div",{className:"poster","data-is-disabled-url":!n},e.createElement(p,{size:"lg"===r?"p3":"p4"},e.createElement("a",{href:n},e.createElement("span",{className:"name"},a),"•"," "),e.createElement("span",null,i))))),ba=({isMobile:t,avatarImg:a,name:n,link:i,size:r="lg",specialty:o})=>e.createElement("div",{className:ua},e.createElement("div",{className:"author"},e.createElement("div",{className:"expert-avatar","data-size":r},a),e.createElement("div",{className:"expert","data-is-disabled-url":!i},t?e.createElement("a",{href:i},"lg"===r?e.createElement(e.Fragment,null,e.createElement(A,{tag:"h6",className:"expert__name",color:le.colors.gray600},n),e.createElement(p,{color:le.colors.gray500,size:"p3",className:"specialty"},o)):e.createElement(e.Fragment,null,e.createElement(A,{tag:"h6",className:"expert__name",color:le.colors.gray600},n))):e.createElement("a",{href:i},"lg"===r?e.createElement(e.Fragment,null,e.createElement(A,{tag:"h6",className:"expert__name",color:le.colors.gray600},n),e.createElement(p,{color:le.colors.gray500,size:"p3",className:"specialty"},o)):e.createElement(e.Fragment,null,e.createElement("h6",{color:le.colors.gray600,className:`${ma} expert__name`},n),e.createElement(p,{color:le.colors.gray500,size:"p4",className:"specialty"},o)))))),fa=o((()=>e.createElement("div",{className:"shoppable"},e.createElement("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},e.createElement("rect",{width:"24",height:"24",rx:"12",fill:"#1B3250"}),e.createElement("path",{d:"M16.6667 8.00033H15.3333C15.3333 6.16033 13.84 4.66699 12 4.66699C10.16 4.66699 8.66667 6.16033 8.66667 8.00033H7.33333C6.6 8.00033 6 8.60033 6 9.33366V17.3337C6 18.067 6.6 18.667 7.33333 18.667H16.6667C17.4 18.667 18 18.067 18 17.3337V9.33366C18 8.60033 17.4 8.00033 16.6667 8.00033ZM12 6.00033C13.1067 6.00033 14 6.89366 14 8.00033H10C10 6.89366 10.8933 6.00033 12 6.00033ZM12 12.667C10.4467 12.667 9.14 11.607 8.77333 10.167C8.66 9.74699 8.98667 9.33366 9.42 9.33366C9.73333 9.33366 9.98667 9.56033 10.0733 9.86699C10.3067 10.7137 11.08 11.3337 12 11.3337C12.92 11.3337 13.6933 10.7137 13.9267 9.86699C14.0133 9.56033 14.2667 9.33366 14.58 9.33366C15.0133 9.33366 15.3333 9.74699 15.2267 10.167C14.86 11.607 13.5533 12.667 12 12.667Z",fill:"white"}))))),va=o((({dataEventCategoryForBookmark:t,dataEventActionForBookmark:a,dataEventLabelForBookmark:n})=>e.createElement("svg",{"data-event-category":t,"data-event-action":a,"data-event-label":n,width:"14",height:"16",viewBox:"0 0 14 16",fill:"none"},e.createElement("path",{d:"M13 15L7 11.1111L1 15V2.55556C1 2.143 1.18061 1.74733 1.5021 1.45561C1.82359 1.16389 2.25963 1 2.71429 1H11.2857C11.7404 1 12.1764 1.16389 12.4979 1.45561C12.8194 1.74733 13 2.143 13 2.55556V15Z",fill:"#2ED69E",stroke:"#2ED69E",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})))),ya=o((({dataEventCategoryForBookmark:t,dataEventActionForBookmark:a,dataEventLabelForBookmark:n})=>e.createElement("svg",{"data-event-category":t,"data-event-action":a,"data-event-label":n,width:"18",height:"18",viewBox:"0 0 18 18",fill:"none"},e.createElement("path",{d:"M12.75 2.25H5.25C4.425 2.25 3.75 2.925 3.75 3.75V15.75L9 13.5L14.25 15.75V3.75C14.25 2.925 13.575 2.25 12.75 2.25Z",fill:"#D2D6DC"})))),xa=({articleLink:t,authorLink:a,authorName:n,avatarImg:i,banner:r,categoryLink:o,categoryName:l,className:s,dataEventActionForBanner:c,dataEventActionForBookmark:d,dataEventActionForCategory:m,dataEventActionForTitle:h,dataEventCategoryForBanner:u,dataEventCategoryForBookmark:g,dataEventCategoryForCategory:b,dataEventCategoryForTitle:f,dataEventLabelForBanner:v,dataEventLabelForBookmark:y,dataEventLabelForCategory:x,dataEventLabelForTitle:w,direction:E="horizontal",hasAffiliate:k,isBookmark:C=!1,isBookmarkDisplayed:S=!0,isMobile:N=!0,onBookmark:B,onClickCategoryName:T,section:D="normal",size:I="md",specialty:z,style:_,styleBanner:L,styleLabel:P,styleTitle:$,text:M,title:O,type:j="author",uploadTime:F,articleLinkTarget:H,isPremium:R})=>{const U=e=>{e.stopPropagation(),null==B||B()},V="lg"===I&&"expert"===j?"h4":"lg"===I&&"home"===D?N?"h4":"h3":"lg"===I?"h4":"h5",W="lg"===I?"p3":"p4",G=N||"home"!==D||"lg"!==I||"author"!==j?"c2":"c1";return e.createElement("article",{className:`${ha} ${s||""}`,"data-size":I,style:_,"data-direction":E,"data-is-expert":"expert"===j||void 0},e.createElement("div",{className:"banner",style:L},e.createElement("a",{className:pa,"data-event-category":u,"data-event-action":c,"data-event-label":v,href:t||"#",target:H},r),R&&e.createElement("img",{loading:"lazy",className:"premium",src:oe.getAssetPath("premium-crown.svg")}),k&&e.createElement(fa,null)),e.createElement("div",{className:"content"},e.createElement("div",{className:"inner-content"},e.createElement(p,{style:P,className:"label",size:G,weight:"caption"},e.createElement("a",{className:pa,"data-event-category":b,"data-event-action":m,"data-event-label":x,href:o||"#",onClick:T},l),S&&e.createElement("a",{className:"bookmark",onClick:U},C?e.createElement(va,{dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}):e.createElement(ya,{dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}))),e.createElement(A,{tag:V,style:$,className:"title",as:"lg"===I?"h2":"h3"},e.createElement("a",{className:pa,"data-event-category":f,"data-event-action":h,"data-event-label":w,href:t||"#",target:H},O)),M&&e.createElement("a",{href:t||"#",target:H},e.createElement(p,{size:W,className:"text"},M))),e.createElement("div",{className:"footer"},"author"===j?e.createElement(ga,{size:I,avatarImg:i,authorName:n,authorLink:a,uploadTime:F,handleClick:U,isBookmarked:C,dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}):e.createElement(ba,{size:I,isMobile:N,avatarImg:i,specialty:z,name:n,link:a,handleClick:U,isBookmarked:C,dataEventCategoryForBookmark:g,dataEventActionForBookmark:d,dataEventLabelForBookmark:y}))))},wa=t=>{var a,n,i,{article:r,author:o,authorAvatar:l,badge:s="",hideDescription:c=!1,isBookmarked:d=!1,onBookmark:m,time:h,tracking:u}=t,g=se(t,["article","author","authorAvatar","badge","hideDescription","isBookmarked","onBookmark","time","tracking"]);const{isMobile:b}=De();return console.log({article:r}),e.createElement(ue,Object.assign({padding:0,radius:0,sx:{display:"flex",flexDirection:"row",gap:24}},g),e.createElement(ue.Section,{w:"100%",h:"100%",miw:264,m:0,className:"pointer"},e.createElement("img",{src:(b?r.featureImageMobile:r.featureImage)||r.featureImage,alt:r.postName,style:{width:"100%"},loading:"lazy"})),e.createElement(ue.Section,null,e.createElement(ge,{position:"apart",mt:16,mb:4},e.createElement(Ie,{href:(null===(a=null==r?void 0:r.primaryCategory)||void 0===a?void 0:a.permalink)||"#"},e.createElement(p,{size:"p4",color:"blue.6"},null===(n=null==r?void 0:r.primaryCategory)||void 0===n?void 0:n.displayName)),e.createElement(de,{sx:{cursor:"pointer"},role:"button",onClick:m},d?e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==u?void 0:u.bookmark),e.createElement("path",{d:"M6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7Z",fill:"#595959"})):e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==u?void 0:u.bookmark),e.createElement("path",{d:"M7 17.95L12 15.8L17 17.95V5.3C17 5.23333 16.9667 5.16667 16.9 5.1C16.8333 5.03333 16.7667 5 16.7 5H7.3C7.23333 5 7.16667 5.03333 7.1 5.1C7.03333 5.16667 7 5.23333 7 5.3V17.95ZM6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7ZM7 5H17H12H7Z",fill:"#595959"})))),e.createElement(p,{size:c?"s2":"s1",mb:8,weight:"semiBold",className:"pointer"},r.postTitle||r.postName||""),!c&&e.createElement(p,{size:"p2",mb:16,lineClamp:3,className:"pointer"},Te(r.excerpt||r.description||(null===(i=r.postContent)||void 0===i?void 0:i.split("\r\n")[0])||"")),e.createElement(pe,{gap:12,align:"center"},e.createElement(ze,{size:32,src:l,withIndicator:!0,indicatorConfig:{offset:5,size:18,label:e.createElement("img",{loading:"lazy",src:s,alt:""})}},"A"),e.createElement(p,{size:"n1",c:"gray.6"},o," • ",h))))};var Ea=be(((e,{})=>({root:{},image:{},title:{},category:{},description:{},author:{}})));const ka=648/440,Ca=1.5,Sa=t=>{var a,i,r,{article:o,author:l,authorAvatar:s,badge:c="",bannerImageWrapProps:d,hideDescription:m=!1,isBookmarked:h=!1,onBookmark:u,time:g,tracking:b,classNames:f,styles:v,unstyled:y,className:x}=t,w=se(t,["article","author","authorAvatar","badge","bannerImageWrapProps","hideDescription","isBookmarked","onBookmark","time","tracking","classNames","styles","unstyled","className"]);const{isMobile:E}=De(),{classes:k,cx:C}=Ea({},{name:"ArticleCard",classNames:f,styles:v,unstyled:y}),S=n((()=>m?Ca:ka),[m]);return e.createElement(ue,Object.assign({className:C(k.root,x),padding:"lg",radius:0},w),e.createElement(ue.Section,{className:C(k.image,"pointer")},e.createElement(_e,Object.assign({ratio:S},d),e.createElement("img",{src:(E?o.featureImageMobile:o.featureImage)||o.featureImage,alt:o.postName,style:{objectFit:"cover"}}))),e.createElement(ue.Section,null,e.createElement(ge,{position:"apart",mt:16,mb:4},e.createElement(Ie,{className:k.category,href:(null===(a=null==o?void 0:o.primaryCategory)||void 0===a?void 0:a.permalink)||"#"},e.createElement(p,{size:"p4",color:"blue.6"},null===(i=null==o?void 0:o.primaryCategory)||void 0===i?void 0:i.displayName)),e.createElement(de,{sx:{cursor:"pointer"},role:"button",onClick:u},h?e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==b?void 0:b.bookmark),e.createElement("path",{d:"M6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7Z",fill:"#595959"})):e.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},null==b?void 0:b.bookmark),e.createElement("path",{d:"M7 17.95L12 15.8L17 17.95V5.3C17 5.23333 16.9667 5.16667 16.9 5.1C16.8333 5.03333 16.7667 5 16.7 5H7.3C7.23333 5 7.16667 5.03333 7.1 5.1C7.03333 5.16667 7 5.23333 7 5.3V17.95ZM6.775 19.7C6.475 19.8333 6.18733 19.8123 5.912 19.637C5.63733 19.4623 5.5 19.2083 5.5 18.875V5.3C5.5 4.8 5.675 4.375 6.025 4.025C6.375 3.675 6.8 3.5 7.3 3.5H16.7C17.2 3.5 17.625 3.675 17.975 4.025C18.325 4.375 18.5 4.8 18.5 5.3V18.875C18.5 19.2083 18.3623 19.4623 18.087 19.637C17.8123 19.8123 17.525 19.8333 17.225 19.7L12 17.45L6.775 19.7ZM7 5H17H12H7Z",fill:"#595959"})))),e.createElement(p,{className:C(k.title,"pointer"),size:m?"s2":"s1",mb:8,weight:"semiBold"},o.postTitle||o.postName||""),!m&&e.createElement(p,{className:C(k.description,"pointer"),size:"p2",mb:16,lineClamp:3},Te(o.excerpt||o.description||(null===(r=o.postContent)||void 0===r?void 0:r.split("\r\n")[0])||"")),e.createElement(pe,{className:k.author,gap:12,align:"center"},e.createElement(ze,{size:32,src:s,withIndicator:!0,indicatorConfig:{offset:5,size:18,label:e.createElement("img",{loading:"lazy",src:c,alt:""})}},"A"),e.createElement(p,{size:"n1",c:"gray.6"},l," • ",g))))},Na=t=>{var{variant:a="vertical"}=t,n=se(t,["variant"]);return"horizontal"===a?e.createElement(wa,Object.assign({},n)):e.createElement(Sa,Object.assign({},n))},Ba=Ve.a`
|
|
2
2
|
display: flex;
|
|
3
3
|
height: 125px;
|
|
4
4
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e,{useMemo as a}from"react";import{CommonGAssets as t}from"./gAssets.js";import{i as s,a as l,b as o,c as r,S as n,L as g,d as m}from"./utils-
|
|
1
|
+
import e,{useMemo as a}from"react";import{CommonGAssets as t}from"./gAssets.js";import{i as s,a as l,b as o,c as r,S as n,L as g,d as m}from"./utils-de689222.js";import{I as i}from"./index-f7d54b3e.js";const c=({type:c,className:h,style:u,isLightLogo:w,customSize:d,badge:N,locale:f,dateForSeasonal:y,isPro:p})=>{const E=a((()=>{if(!y||isNaN(new Date(y).getTime()))return{isChristmas:!1,isLunarNewYear:!1,isNewYear:!1};const e=new Date(y),a=s(e),t=l.includes(f)&&o(e);return{isChristmas:a,isLunarNewYear:t,isNewYear:!t&&r(e)}}),[f,new Date(y).getDate()]);return e.createElement(n,{className:h,style:u,"data-logo-is-light":w||void 0,"data-has-badge":!!N,"data-christmas":E.isChristmas,"data-new-year":E.isNewYear,"data-lunar-new-year":E.isLunarNewYear},E.isChristmas?e.createElement(e.Fragment,null,e.createElement(i,{alt:"left xmas logo",src:t.getAssetPath("logo/xmas-left.png"),className:"common-logo-seasonal-left"}),e.createElement(i,{alt:"right xmas logo",src:t.getAssetPath("logo/xmas-right.png"),className:"common-logo-seasonal-right"})):E.isNewYear?e.createElement(e.Fragment,null,e.createElement(i,{alt:"left new year logo",src:t.getAssetPath("logo/new-year-left.png"),className:"common-logo-seasonal-left"}),e.createElement(i,{alt:"right new year logo",src:t.getAssetPath("logo/new-year-right.png"),className:"common-logo-seasonal-right"})):E.isLunarNewYear?e.createElement(e.Fragment,null,e.createElement(i,{alt:"left lunar new year logo",loading:"lazy",src:t.getAssetPath("logo/lunar-new-year-left.png"),className:"common-logo-seasonal-left"}),e.createElement(i,{alt:"right lunar new year logo",loading:"lazy",src:t.getAssetPath("logo/lunar-new-year-right.png"),className:"common-logo-seasonal-right"})):null,e.createElement(g,{type:c,width:null==d?void 0:d.width,height:null==d?void 0:d.height}),p?e.createElement(m,{src:t.getAssetPath("logo/pro-suffix.svg")}):null,N)};export{c as L};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{_ as o}from"./tslib.es6-4213f703.js";import t from"react";import{Indicator as e}from"@mantine/core";import"dayjs";import"./screenSizeContext-be2375b1.js";import"styled-components";import{t as s}from"./theme-17fe8568.js";import"./index-2edd91fd.js";import"./isProduction-52c76560.js";import"./Onboarding-8c3938e0.js";import"./gAssets.js";const r=r=>{var{styles:i,color:n=s.colors.red700}=r,m=o(r,["styles","color"]);return t.createElement(e,Object.assign({inline:!0,position:"top-end",offset:4,styles:Object.assign({processing:{animationDirection:"alternate"}},i),color:n},m))};export{r as I};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as l}from"@mantine/core";import{t as n,M as i}from"./screenSizeContext-
|
|
1
|
+
import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as l}from"@mantine/core";import{t as n,M as i}from"./screenSizeContext-be2375b1.js";import{a4 as r,a5 as d,a6 as s,a7 as c,a8 as m,a9 as h,y as p}from"./index.styles-d8ab3053.js";import{T as u,I as g}from"./index-fc471630.js";import{u as y}from"./useScrollbarSize-6e27c5de.js";import{createPortal as b}from"react-dom";import f from"styled-components";import{u as v}from"./useTranslations-3a1f0a5e.js";import{G as x}from"./Onboarding-8c3938e0.js";import{M as C,a as E}from"./index-bf09c5ae.js";import{t as w}from"./theme-17fe8568.js";import{T as k}from"./index-e9467986.js";const B=({open:t=!1,onClickOutside:a})=>e.createElement(r,{"data-open":t,onClick:a}),_=({children:o,title:i,onClose:r,open:m=!1,placement:h="left",destroyOnClose:p=!1,isPropagationEvent:g=!0,className:y})=>{const b=t();a((()=>(n(m),()=>n(!1))),[m]);const f=()=>{b.current.classList.add("slideOut"),setTimeout((()=>{r()}),800)};return!m&&p?null:e.createElement(l,null,e.createElement(d,{className:y,open:m},e.createElement(B,{open:m,onClickOutside:f}),e.createElement(s,{open:m,placement:h,ref:b,hasTitle:Boolean(i)},e.createElement("div",{className:"title"},i&&e.createElement(u,{size:"s2",weight:"semiBold"},i),e.createElement("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",className:"close-button",onClick:f},e.createElement("path",{d:"M5.99007 4.99067C5.79114 4.99072 5.59674 5.0501 5.43173 5.16121C5.26672 5.27233 5.1386 5.43013 5.06374 5.61444C4.98889 5.79875 4.9707 6.0012 5.0115 6.1959C5.05231 6.39061 5.15025 6.56872 5.29281 6.70747L10.5858 12.0004L5.29281 17.2934C5.19684 17.3855 5.12021 17.4959 5.06743 17.618C5.01464 17.7402 4.98676 17.8716 4.9854 18.0046C4.98405 18.1377 5.00926 18.2697 5.05954 18.3928C5.10983 18.516 5.1842 18.6279 5.27827 18.722C5.37235 18.8161 5.48426 18.8904 5.60743 18.9407C5.73061 18.991 5.86259 19.0162 5.99563 19.0149C6.12867 19.0135 6.2601 18.9856 6.38223 18.9328C6.50436 18.8801 6.61473 18.8034 6.70687 18.7075L11.9998 13.4145L17.2928 18.7075C17.385 18.8034 17.4953 18.8801 17.6175 18.9328C17.7396 18.9856 17.871 19.0135 18.0041 19.0149C18.1371 19.0162 18.2691 18.991 18.3922 18.9407C18.5154 18.8904 18.6273 18.8161 18.7214 18.722C18.8155 18.6279 18.8899 18.516 18.9401 18.3928C18.9904 18.2697 19.0156 18.1377 19.0143 18.0047C19.0129 17.8716 18.985 17.7402 18.9323 17.618C18.8795 17.4959 18.8028 17.3855 18.7069 17.2934L13.4139 12.0004L18.7069 6.70747C18.8514 6.567 18.9501 6.38616 18.99 6.18864C19.03 5.99112 19.0093 5.78614 18.9308 5.60055C18.8523 5.41497 18.7195 5.25744 18.5499 5.14861C18.3803 5.03978 18.1817 4.98473 17.9803 4.99067C17.7205 4.99841 17.4739 5.10699 17.2928 5.2934L11.9998 10.5864L6.70687 5.2934C6.61368 5.19761 6.50224 5.12146 6.37912 5.06947C6.25601 5.01747 6.12372 4.99068 5.99007 4.99067Z",fill:"#595959"}))),e.createElement(c,{onClick:e=>{g&&e.stopPropagation()}},o&&(e.isValidElement(o)?o:"function"==typeof o?o({internalClose:f}):null)))))},$=({value:t,options:a,className:l,direction:n="horizontal",onChange:i,isDisabled:r,siteType:d})=>{const[s,c]=o(t),p="marryBaby"===d;return e.createElement(m,{className:l,"data-direction":n},a.map(((a,o)=>e.createElement(h,{"data-selected":(t||s)===a.value,"data-is-mb":p,"data-disabled":r,key:o,onClick:()=>{var e;e=a.value,r||(c(e),i&&i(e))}},e.createElement("div",null,a.content,a.label&&e.createElement(e.Fragment,null,p?e.createElement(C,{type:"subtitle-2",color:(t||s)===a.value?w.mbColors.dark:w.mbColors.midGray},a.label):e.createElement(k,{type:"bold",color:(t||s)===a.value?"#2D87F3":"black",className:"radio-group-item-heading",size:"label1"},a.label)))))))},j="hhgcomp-modal-modal",N=p(f.div`
|
|
2
2
|
position: relative;
|
|
3
3
|
z-index: 200;
|
|
4
4
|
background-color: ${e=>e.theme.colors.white};
|
|
@@ -27,7 +27,7 @@ import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as
|
|
|
27
27
|
background-color: none;
|
|
28
28
|
box-shadow: none;
|
|
29
29
|
}
|
|
30
|
-
`,j),L=
|
|
30
|
+
`,j),L=f.div`
|
|
31
31
|
position: fixed;
|
|
32
32
|
top: 0;
|
|
33
33
|
left: 0;
|
|
@@ -130,7 +130,7 @@ import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as
|
|
|
130
130
|
}
|
|
131
131
|
}
|
|
132
132
|
}
|
|
133
|
-
`,z=
|
|
133
|
+
`,z=f.div`
|
|
134
134
|
position: fixed;
|
|
135
135
|
top: 0;
|
|
136
136
|
left: 0;
|
|
@@ -144,7 +144,7 @@ import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as
|
|
|
144
144
|
&[data-type='video'] {
|
|
145
145
|
background-color: ${e=>e.theme.colors.secondaryDark};
|
|
146
146
|
}
|
|
147
|
-
`,T="hhg-modals",G=()=>{document.querySelectorAll('.hhg-modal[data-open="true"]').length<1&&document.body.classList.remove("hhc-modal-show")},D=()=>{document.querySelectorAll('.hhg-modal[data-open="true"]').length<1&&(document.body.style.overflow="",document.body.style.paddingRight="",document.body.classList.remove("hhc-disabled-scroll"))},M=({type:l="lead",closeIcon:n,isOpen:i=!0,onClose:r,children:d,className:s="",animationType:c="slideTop",isStaticBackdrop:m=!1,siteType:h})=>{const[p,u]=o(!1),g=t(null),{width:
|
|
147
|
+
`,T="hhg-modals",G=()=>{document.querySelectorAll('.hhg-modal[data-open="true"]').length<1&&document.body.classList.remove("hhc-modal-show")},D=()=>{document.querySelectorAll('.hhg-modal[data-open="true"]').length<1&&(document.body.style.overflow="",document.body.style.paddingRight="",document.body.classList.remove("hhc-disabled-scroll"))},M=({type:l="lead",closeIcon:n,isOpen:i=!0,onClose:r,children:d,className:s="",animationType:c="slideTop",isStaticBackdrop:m=!1,siteType:h})=>{const[p,u]=o(!1),g=t(null),{width:f}=y();if(!g.current&&p&&(g.current=document.createElement("div")),a((()=>(u(!0),()=>{u(!1),G(),D()})),[]),a((()=>{if(p){const e=(()=>{let e=document.getElementById(T);return e||(e=document.createElement("div"),e.setAttribute("id",T),document.body.append(e)),e})();return e.appendChild(g.current),()=>{e.removeChild(g.current)}}}),[p]),a((()=>{i?document.body.classList.add("hhc-modal-show"):G()}),[i]),a((()=>{i?(document.body.style.overflow="hidden",document.body.style.paddingRight=f+"px",document.body.classList.add("hhc-disabled-scroll")):D()}),[i,f]),!p)return null;const v=["hhg-modal__wrapper",s,c].filter((e=>e)).join(" ");return b(e.createElement(L,{className:v,"data-open":i,"data-type":l},!m&&e.createElement(z,{"data-open":i,onClick:r,"data-type":l}),!m&&"video"===l&&!!n&&e.createElement("div",{className:"hhg-modal__close",onClick:r},n),e.createElement(N,{className:"hhg-modal","data-open":i,"data-site-type":h},e.createElement("div",{className:"video"===l?"hhg-modal__video":"hhg-modal__content"},!!n&&"video"!==l&&e.createElement("div",{className:"hhg-modal__close",onClick:r},n),d))),g.current)},O=f.div`
|
|
148
148
|
& > :not(:last-child) {
|
|
149
149
|
margin-bottom: 8px;
|
|
150
150
|
}
|
|
@@ -162,7 +162,7 @@ import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as
|
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
164
|
}
|
|
165
|
-
`,S=
|
|
165
|
+
`,S=f($)`
|
|
166
166
|
& > div > div {
|
|
167
167
|
display: flex;
|
|
168
168
|
flex-direction: row;
|
|
@@ -174,4 +174,4 @@ import e,{useRef as t,useEffect as a,useState as o}from"react";import{Portal as
|
|
|
174
174
|
.radio-group-item-heading {
|
|
175
175
|
margin-top: 0;
|
|
176
176
|
}
|
|
177
|
-
`,R=({value:t,onChange:a,siteType:o})=>{const{t:l}=
|
|
177
|
+
`,R=({value:t,onChange:a,siteType:o})=>{const{t:l}=v(),n="marryBaby"==o;return e.createElement(O,{"data-is-marryBaby":n},n?e.createElement(E,{type:"h4",color:w.mbColors.dark},l("tools.selectBabyGender")):e.createElement(u,{size:"label2",weight:"bold",style:{marginBottom:"0.5rem"}},l("tools.selectBabyGender")),e.createElement(S,{siteType:o,options:[{value:x.Boy,label:l("gender.male"),content:n?e.createElement(g.BabyBoyMB,null):e.createElement(g.GenderChooseBoy,null)},{value:x.Girl,label:l("gender.female"),content:n?e.createElement(g.BabyGirlMB,null):e.createElement(g.GenderChooseGirl,null)}],value:t,onChange:a,className:"gender-selector"}))};export{R as B,_ as D,M,$ as R};
|