@hhgtech/hhg-components 1.19.0-beta-3 → 1.19.0-beta-5

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.
Files changed (177) hide show
  1. package/build/assets/svg/index.d.ts +5 -9
  2. package/build/cache/core.d.ts +7 -0
  3. package/build/cache/index.d.ts +1 -0
  4. package/build/cache.js +2 -0
  5. package/build/cache.js.map +1 -0
  6. package/build/care/components/organisms/bookingSearchBar/index.styled.d.ts +1 -1
  7. package/build/care/components/organisms/bookingSearchBar/mobileTopbar/index.styled.d.ts +1 -1
  8. package/build/care/components/organisms/bookingSearchBar/resultSection/index.styled.d.ts +1 -1
  9. package/build/care/components/organisms/bookingSearchBar/resultSectionItem/index.styled.d.ts +1 -1
  10. package/build/care/components/organisms/bookingSearchBar/searchInputs/index.d.ts +2 -1
  11. package/build/care.js +1 -1
  12. package/build/components/atoms/flag/icons/cambodia.d.ts +2 -2
  13. package/build/components/atoms/flag/icons/india.d.ts +2 -2
  14. package/build/components/atoms/flag/icons/indonesia.d.ts +5 -3
  15. package/build/components/atoms/flag/icons/philippines.d.ts +2 -2
  16. package/build/components/atoms/flag/index.d.ts +2 -1
  17. package/build/components/atoms/index.d.ts +6 -3
  18. package/build/components/atoms/input/index.d.ts +4 -12
  19. package/build/components/atoms/pureInput/index.d.ts +1 -0
  20. package/build/components/atoms/text/index.d.ts +4 -1
  21. package/build/components/molecules/articleCard/index.d.ts +2 -1
  22. package/build/components/molecules/dateRangePicker/calendar/index.d.ts +9 -0
  23. package/build/components/molecules/dateRangePicker/calendar/index.styled.d.ts +13 -0
  24. package/build/components/molecules/dateRangePicker/index.d.ts +13 -0
  25. package/build/components/molecules/dateRangePicker/index.styled.d.ts +2 -0
  26. package/build/components/molecules/dateRangePicker/types.d.ts +4 -0
  27. package/build/components/molecules/dateRangePicker/utils.d.ts +2 -0
  28. package/build/components/molecules/index.d.ts +18 -8
  29. package/build/components/organisms/index.d.ts +1 -1
  30. package/build/components/organisms/navigationLayout/navigationBar/index.d.ts +1 -1
  31. package/build/components/organisms/navigationProfileButton/index.d.ts +2 -1
  32. package/build/components/organisms/navigationV2/index.d.ts +2 -0
  33. package/build/components.js +1 -1
  34. package/build/cookieHelper-40ab50eb.js +2 -0
  35. package/build/cookieHelper-40ab50eb.js.map +1 -0
  36. package/build/core-8fcc56eb.js +2 -0
  37. package/build/core-8fcc56eb.js.map +1 -0
  38. package/build/core.d.ts +1 -0
  39. package/build/core.js +1 -1
  40. package/build/esm/assets/svg/index.d.ts +5 -9
  41. package/build/esm/cache/core.d.ts +7 -0
  42. package/build/esm/cache/index.d.ts +1 -0
  43. package/build/esm/cache.js +2 -0
  44. package/build/esm/cache.js.map +1 -0
  45. package/build/esm/care/components/organisms/bookingSearchBar/index.styled.d.ts +1 -1
  46. package/build/esm/care/components/organisms/bookingSearchBar/mobileTopbar/index.styled.d.ts +1 -1
  47. package/build/esm/care/components/organisms/bookingSearchBar/resultSection/index.styled.d.ts +1 -1
  48. package/build/esm/care/components/organisms/bookingSearchBar/resultSectionItem/index.styled.d.ts +1 -1
  49. package/build/esm/care/components/organisms/bookingSearchBar/searchInputs/index.d.ts +2 -1
  50. package/build/esm/care.js +1 -1
  51. package/build/esm/components/atoms/flag/icons/cambodia.d.ts +2 -2
  52. package/build/esm/components/atoms/flag/icons/india.d.ts +2 -2
  53. package/build/esm/components/atoms/flag/icons/indonesia.d.ts +5 -3
  54. package/build/esm/components/atoms/flag/icons/philippines.d.ts +2 -2
  55. package/build/esm/components/atoms/flag/index.d.ts +2 -1
  56. package/build/esm/components/atoms/index.d.ts +6 -3
  57. package/build/esm/components/atoms/input/index.d.ts +4 -12
  58. package/build/esm/components/atoms/pureInput/index.d.ts +1 -0
  59. package/build/esm/components/atoms/text/index.d.ts +4 -1
  60. package/build/esm/components/molecules/articleCard/index.d.ts +2 -1
  61. package/build/esm/components/molecules/dateRangePicker/calendar/index.d.ts +9 -0
  62. package/build/esm/components/molecules/dateRangePicker/calendar/index.styled.d.ts +13 -0
  63. package/build/esm/components/molecules/dateRangePicker/index.d.ts +13 -0
  64. package/build/esm/components/molecules/dateRangePicker/index.styled.d.ts +2 -0
  65. package/build/esm/components/molecules/dateRangePicker/types.d.ts +4 -0
  66. package/build/esm/components/molecules/dateRangePicker/utils.d.ts +2 -0
  67. package/build/esm/components/molecules/index.d.ts +18 -8
  68. package/build/esm/components/organisms/index.d.ts +1 -1
  69. package/build/esm/components/organisms/navigationLayout/navigationBar/index.d.ts +1 -1
  70. package/build/esm/components/organisms/navigationProfileButton/index.d.ts +2 -1
  71. package/build/esm/components/organisms/navigationV2/index.d.ts +2 -0
  72. package/build/esm/components.js +1 -1
  73. package/build/esm/cookieHelper-caf76f93.js +2 -0
  74. package/build/esm/cookieHelper-caf76f93.js.map +1 -0
  75. package/build/esm/core-3d8a3f90.js +2 -0
  76. package/build/esm/core-3d8a3f90.js.map +1 -0
  77. package/build/esm/core.d.ts +1 -0
  78. package/build/esm/core.js +1 -1
  79. package/build/esm/hooks/useCSSFocusPopupHelper.d.ts +3 -4
  80. package/build/esm/hooks/useFbDataLayer.d.ts +2 -0
  81. package/build/esm/i18n.js +1 -1
  82. package/build/esm/{index-2e9c7339.js → index-0348b56b.js} +2 -2
  83. package/build/esm/{index-2e9c7339.js.map → index-0348b56b.js.map} +1 -1
  84. package/build/esm/index-680f53de.js +2 -0
  85. package/build/esm/index-680f53de.js.map +1 -0
  86. package/build/esm/index-dda5ff2a.js +2 -0
  87. package/build/esm/index-dda5ff2a.js.map +1 -0
  88. package/build/esm/{index-e3983194.js → index-f799fba8.js} +2 -2
  89. package/build/esm/{index-e3983194.js.map → index-f799fba8.js.map} +1 -1
  90. package/build/esm/index.d.ts +1 -0
  91. package/build/esm/index.js +1 -1
  92. package/build/esm/index.styled-64f8f6e8.js +2 -0
  93. package/build/esm/index.styled-64f8f6e8.js.map +1 -0
  94. package/build/esm/misc/utils.d.ts +11 -1
  95. package/build/esm/navigation.js +1 -1
  96. package/build/esm/together/components/atoms/cardReactions/index.styled.d.ts +1 -1
  97. package/build/esm/together.js +1 -1
  98. package/build/esm/translationsContext-b0b4655d.js +2 -0
  99. package/build/esm/{translationsContext-977d7bc4.js.map → translationsContext-b0b4655d.js.map} +1 -1
  100. package/build/esm/translationsProvider-a15863c9.js +2 -0
  101. package/build/esm/{translationsProvider-94e1d5d1.js.map → translationsProvider-a15863c9.js.map} +1 -1
  102. package/build/esm/types-26f12b26.js +2 -0
  103. package/build/esm/types-26f12b26.js.map +1 -0
  104. package/build/esm/{types-f59e54c0.js → types-5c8ce743.js} +2 -2
  105. package/build/esm/{types-f59e54c0.js.map → types-5c8ce743.js.map} +1 -1
  106. package/build/esm/useFbDataLayer-58443cc1.js +2 -0
  107. package/build/esm/useFbDataLayer-58443cc1.js.map +1 -0
  108. package/build/esm/useOutsideClick-6004483a.js +2 -0
  109. package/build/esm/useOutsideClick-6004483a.js.map +1 -0
  110. package/build/esm/useTranslations-0c13f2cb.js +2 -0
  111. package/build/esm/useTranslations-0c13f2cb.js.map +1 -0
  112. package/build/hooks/useCSSFocusPopupHelper.d.ts +3 -4
  113. package/build/hooks/useFbDataLayer.d.ts +2 -0
  114. package/build/i18n.js +1 -1
  115. package/build/index-4fa610b1.js +2 -0
  116. package/build/index-4fa610b1.js.map +1 -0
  117. package/build/index-5b032a36.js +2 -0
  118. package/build/index-5b032a36.js.map +1 -0
  119. package/build/{index-1db4ad2d.js → index-8b1e9d3e.js} +2 -2
  120. package/build/{index-1db4ad2d.js.map → index-8b1e9d3e.js.map} +1 -1
  121. package/build/{index-467d1dc9.js → index-eed59e93.js} +2 -2
  122. package/build/{index-467d1dc9.js.map → index-eed59e93.js.map} +1 -1
  123. package/build/index.d.ts +1 -0
  124. package/build/index.js +1 -1
  125. package/build/index.styled-89837cca.js +2 -0
  126. package/build/index.styled-89837cca.js.map +1 -0
  127. package/build/misc/utils.d.ts +11 -1
  128. package/build/navigation.js +1 -1
  129. package/build/together/components/atoms/cardReactions/index.styled.d.ts +1 -1
  130. package/build/together.js +1 -1
  131. package/build/translationsContext-351bc1a7.js +2 -0
  132. package/build/{translationsContext-63e3e5ec.js.map → translationsContext-351bc1a7.js.map} +1 -1
  133. package/build/translationsProvider-eb4d9fd6.js +2 -0
  134. package/build/{translationsProvider-4f6e12c9.js.map → translationsProvider-eb4d9fd6.js.map} +1 -1
  135. package/build/{types-9741aa58.js → types-5985800a.js} +2 -2
  136. package/build/{types-9741aa58.js.map → types-5985800a.js.map} +1 -1
  137. package/build/types-df74aec0.js +2 -0
  138. package/build/types-df74aec0.js.map +1 -0
  139. package/build/useFbDataLayer-508d5450.js +2 -0
  140. package/build/useFbDataLayer-508d5450.js.map +1 -0
  141. package/build/useOutsideClick-528bfd6c.js +2 -0
  142. package/build/useOutsideClick-528bfd6c.js.map +1 -0
  143. package/build/useTranslations-29326df5.js +2 -0
  144. package/build/useTranslations-29326df5.js.map +1 -0
  145. package/package.json +22 -53
  146. package/build/cookieHelper-dda8dbe1.js +0 -2
  147. package/build/cookieHelper-dda8dbe1.js.map +0 -1
  148. package/build/esm/cookieHelper-6f220950.js +0 -2
  149. package/build/esm/cookieHelper-6f220950.js.map +0 -1
  150. package/build/esm/index-19ea8cf0.js +0 -2
  151. package/build/esm/index-19ea8cf0.js.map +0 -1
  152. package/build/esm/index-d055a48d.js +0 -2
  153. package/build/esm/index-d055a48d.js.map +0 -1
  154. package/build/esm/index.styled-1585c8b9.js +0 -2
  155. package/build/esm/index.styled-1585c8b9.js.map +0 -1
  156. package/build/esm/translationsContext-977d7bc4.js +0 -2
  157. package/build/esm/translationsProvider-94e1d5d1.js +0 -2
  158. package/build/esm/types-4a772485.js +0 -2
  159. package/build/esm/types-4a772485.js.map +0 -1
  160. package/build/esm/types-9b8cf2f7.js +0 -2
  161. package/build/esm/types-9b8cf2f7.js.map +0 -1
  162. package/build/esm/useTranslations-824bc4ba.js +0 -2
  163. package/build/esm/useTranslations-824bc4ba.js.map +0 -1
  164. package/build/index-23709986.js +0 -2
  165. package/build/index-23709986.js.map +0 -1
  166. package/build/index-c75ec8f5.js +0 -2
  167. package/build/index-c75ec8f5.js.map +0 -1
  168. package/build/index.styled-86510d9f.js +0 -2
  169. package/build/index.styled-86510d9f.js.map +0 -1
  170. package/build/translationsContext-63e3e5ec.js +0 -2
  171. package/build/translationsProvider-4f6e12c9.js +0 -2
  172. package/build/types-105cb1d7.js +0 -2
  173. package/build/types-105cb1d7.js.map +0 -1
  174. package/build/types-521f641a.js +0 -2
  175. package/build/types-521f641a.js.map +0 -1
  176. package/build/useTranslations-0aa60f65.js +0 -2
  177. package/build/useTranslations-0aa60f65.js.map +0 -1
@@ -0,0 +1,2 @@
1
+ import{useState as t,useEffect as n}from"react";var e=Object.freeze({__proto__:null}),i=function(e){var i=t(""),o=i[0],r=i[1];n((function(){fetch("https://api.ipify.org").then((function(t){return t.text()})).then((function(t){t?r(t):fetch("https://icanhazip.com").then((function(t){return t.text()})).then((function(t){t&&r(t)}))}))}),[]),n((function(){var t=null;return e&&o&&function n(){window.fbq?window.fbq("track","FB Conversion",{user_data:[{em:e.email||"",fn:"",ln:"",ph:e.phone||"",client_ip_address:o||""}]}):t=setTimeout(n,2e3)}(),function(){t&&clearTimeout(t)}}),[e,o])};export{e as t,i as u};
2
+ //# sourceMappingURL=useFbDataLayer-58443cc1.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useFbDataLayer-58443cc1.js","sources":["../../src/hooks/useFbDataLayer.tsx"],"sourcesContent":["import { useEffect, useState } from 'react'\n\nimport { UserInfo } from 'interfaces/types'\n\nexport const useFbDataLayer = (userInfo?: UserInfo | null) => {\n const [userIp, setUserIp] = useState('')\n useEffect(() => {\n fetch('https://api.ipify.org')\n .then((res) => res.text())\n .then((ip) => {\n if (ip) setUserIp(ip)\n else\n fetch('https://icanhazip.com')\n .then((res) => res.text())\n .then((ip) => {\n if (ip) setUserIp(ip)\n })\n })\n }, [])\n useEffect(() => {\n let timeout: ReturnType<typeof setTimeout> | null = null\n if (userInfo && userIp) {\n ;(function waitFbq() {\n // check for the generic script\n // easiest check to prevent race condition\n if (window.fbq) {\n window.fbq('track', 'FB Conversion', {\n user_data: [\n {\n em: userInfo.email || '',\n fn: '',\n ln: '',\n ph: userInfo.phone || '',\n client_ip_address: userIp || '',\n },\n ],\n })\n } else {\n timeout = setTimeout(waitFbq, 2000)\n }\n })()\n }\n return () => {\n if (timeout) {\n clearTimeout(timeout)\n }\n }\n }, [userInfo, userIp])\n}\n"],"names":["useFbDataLayer","userInfo","_a","useState","userIp","setUserIp","useEffect","fetch","then","res","text","ip","timeout","waitFbq","window","fbq","user_data","em","email","fn","ln","ph","phone","client_ip_address","setTimeout","clearTimeout"],"mappings":"sFAIaA,EAAiB,SAACC,GACvB,IAAAC,EAAsBC,EAAS,IAA9BC,EAAMF,EAAA,GAAEG,EAASH,EAAA,GACxBI,GAAU,WACRC,MAAM,yBACHC,MAAK,SAACC,GAAQ,OAAAA,EAAIC,UAClBF,MAAK,SAACG,GACDA,EAAIN,EAAUM,GAEhBJ,MAAM,yBACHC,MAAK,SAACC,GAAQ,OAAAA,EAAIC,UAClBF,MAAK,SAACG,GACDA,GAAIN,EAAUM,WAG3B,IACHL,GAAU,WACR,IAAIM,EAAgD,KAsBpD,OArBIX,GAAYG,GACb,SAAUS,IAGLC,OAAOC,IACTD,OAAOC,IAAI,QAAS,gBAAiB,CACnCC,UAAW,CACT,CACEC,GAAIhB,EAASiB,OAAS,GACtBC,GAAI,GACJC,GAAI,GACJC,GAAIpB,EAASqB,OAAS,GACtBC,kBAAmBnB,GAAU,OAKnCQ,EAAUY,WAAWX,EAAS,KAhBjC,GAoBI,WACDD,GACFa,aAAab,MAGhB,CAACX,EAAUG"}
@@ -0,0 +1,2 @@
1
+ import{useCallback as n,useEffect as t}from"react";var e=function(e,r){var o=n((function(n){e.current&&!e.current.contains(n.target)&&r(n.target)}),[]);t((function(){return document.addEventListener("mousedown",o),function(){document.removeEventListener("mousedown",o)}}))};export{e as u};
2
+ //# sourceMappingURL=useOutsideClick-6004483a.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useOutsideClick-6004483a.js","sources":["../../src/hooks/useOutsideClick.ts"],"sourcesContent":["import { useCallback, useEffect } from 'react'\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst useOutsideClick = (ref: any, callback: any) => {\n const handleClick = useCallback((e: MouseEvent) => {\n if (ref.current && !ref.current.contains(e.target)) {\n callback(e.target)\n }\n }, [])\n\n useEffect(() => {\n document.addEventListener('mousedown', handleClick)\n\n return () => {\n document.removeEventListener('mousedown', handleClick)\n }\n })\n}\n\nexport { useOutsideClick }\n"],"names":["useOutsideClick","ref","callback","handleClick","useCallback","e","current","contains","target","useEffect","document","addEventListener","removeEventListener"],"mappings":"mDAGA,IAAMA,EAAkB,SAACC,EAAUC,GACjC,IAAMC,EAAcC,GAAY,SAACC,GAC3BJ,EAAIK,UAAYL,EAAIK,QAAQC,SAASF,EAAEG,SACzCN,EAASG,EAAEG,UAEZ,IAEHC,GAAU,WAGR,OAFAC,SAASC,iBAAiB,YAAaR,GAEhC,WACLO,SAASE,oBAAoB,YAAaT"}
@@ -0,0 +1,2 @@
1
+ import{c as n,a as t}from"./tslib.es6-fd0a5c98.js";import{css as e}from"styled-components";import{useContext as a,useMemo as r}from"react";import{T as o,d as i}from"./translationsContext-b0b4655d.js";var c,d,u,s,p={spLayout:!1,pcLayout:!1,tdLayout:!1,mbLayout:!1},l=function(){return p.spLayout||(console.error("spLayout is deprecated. Use `MediaQueries.mbDown` instead."),p.spLayout=!0),function(a){for(var r=[],o=1;o<arguments.length;o++)r[o-1]=arguments[o];return e(c||(c=n(["\n @media (max-width: ","px) {\n ",";\n }\n "],["\n @media (max-width: ","px) {\n ",";\n }\n "])),767,e.apply(void 0,t([a],r,!1)))}},m=function(){return p.mbLayout||(console.error("mbLayout is deprecated. Use `MediaQueries.tdDown` instead."),p.mbLayout=!0),function(a){for(var r=[],o=1;o<arguments.length;o++)r[o-1]=arguments[o];return e(d||(d=n(["\n @media (max-width: ","px) {\n ",";\n }\n "],["\n @media (max-width: ","px) {\n ",";\n }\n "])),1023,e.apply(void 0,t([a],r,!1)))}},_=function(){return p.tdLayout||(console.error("tdLayout is deprecated. Use `MediaQueries.tdOnly` instead."),p.tdLayout=!0),function(a){for(var r=[],o=1;o<arguments.length;o++)r[o-1]=arguments[o];return e(u||(u=n(["\n @media (min-width: ","px) and (max-width: ","px) {\n ",";\n }\n "],["\n @media (min-width: ","px) and (max-width: ","px) {\n ",";\n }\n "])),768,1023,e.apply(void 0,t([a],r,!1)))}},f=function(a){return p.pcLayout||(console.error("pcLayout is deprecated. if pcLayout(true) use `MediaQueries.mbUp`. If pcLayout() use `MediaQueries.tdUp`."),p.pcLayout=!0),function(r){for(var o=[],i=1;i<arguments.length;i++)o[i-1]=arguments[i];return e(s||(s=n(["\n @media (min-width: ","px) {\n ",";\n }\n "],["\n @media (min-width: ","px) {\n ",";\n }\n "])),a?768:1024,e.apply(void 0,t([r],o,!1)))}},E=function(n){var t=Object.keys(n);return t.length?"?"+t.map((function(t){return"".concat(t,"=").concat(n[t])})).join("&"):""},L=function(n,t,e){void 0===t&&(t=1),void 0===e&&(e="page");var a=n.split("?"),r=a[0],o=a[1],i=new URLSearchParams(o||""),c={};return i.forEach((function(n,t){n&&(c[t]=n)})),Number(t)>1?c[e]=String(t):delete c[e],r+E(c)},I=function(n){"undefined"!=typeof window&&(document.documentElement.classList.toggle("noscroll",n),document.body.classList.toggle("noscroll",n))},O={BREAK_POINT_SMALL_MOBILE:481,BREAK_POINT_MOBILE:768,BREAK_POINT_TABLET:1024,BREAK_POINT_PC:1200},T={smbDown:"@media (max-width: ".concat(O.BREAK_POINT_SMALL_MOBILE-1,"px)"),smbUp:"@media (min-width: ".concat(O.BREAK_POINT_SMALL_MOBILE,"px)"),mbDown:"@media (max-width: ".concat(O.BREAK_POINT_MOBILE-1,"px)"),mbOnly:"@media (min-width: ".concat(O.BREAK_POINT_SMALL_MOBILE,"px) and (max-width: ").concat(O.BREAK_POINT_MOBILE-1,"px)"),mbUp:"@media (min-width: ".concat(O.BREAK_POINT_MOBILE,"px)"),tdDown:"@media (max-width: ".concat(O.BREAK_POINT_TABLET-1,"px)"),tdOnly:"@media (min-width: ".concat(O.BREAK_POINT_MOBILE,"px) and (max-width: ").concat(O.BREAK_POINT_TABLET-1,"px)"),tdUp:"@media (min-width: ".concat(O.BREAK_POINT_TABLET,"px)"),pcUp:"@media (min-width: ".concat(O.BREAK_POINT_PC,"px)"),pcOnly:"@media (min-width: ".concat(O.BREAK_POINT_TABLET,"px) and (max-width: ").concat(O.BREAK_POINT_PC-1,"px)"),pcDown:"@media (max-width: ".concat(O.BREAK_POINT_PC-1,"px)")},B=function(n){switch(n){case"smbDown":return[0,O.BREAK_POINT_SMALL_MOBILE-1];case"smbUp":return[O.BREAK_POINT_SMALL_MOBILE,0];case"mbDown":return[0,O.BREAK_POINT_MOBILE-1];case"mbOnly":return[O.BREAK_POINT_SMALL_MOBILE,O.BREAK_POINT_MOBILE-1];case"mbUp":return[O.BREAK_POINT_MOBILE,0];case"tdDown":return[0,O.BREAK_POINT_TABLET-1];case"tdOnly":return[O.BREAK_POINT_MOBILE,O.BREAK_POINT_TABLET-1];case"tdUp":return[O.BREAK_POINT_TABLET,0];case"pcUp":return[O.BREAK_POINT_PC,0];case"pcOnly":return[O.BREAK_POINT_TABLET,O.BREAK_POINT_PC-1];case"pcDown":return[0,O.BREAK_POINT_PC-1]}},w="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function A(n){var t={exports:{}};return n(t,t.exports),t.exports}var x=A((function(n){(function(t){function e(n){var t=new Error(n);return t.name="ValueError",t}function a(n){return function(t){var a=Array.prototype.slice.call(arguments,1),r=0,o="UNDEFINED";return t.replace(/([{}])\1|[{](.*?)(?:!(.+?))?[}]/g,(function(t,i,c,d){if(null!=i)return i;var u=c;if(u.length>0){if("IMPLICIT"===o)throw e("cannot switch from implicit to explicit numbering");o="EXPLICIT"}else{if("EXPLICIT"===o)throw e("cannot switch from explicit to implicit numbering");o="IMPLICIT",u=String(r),r+=1}var s=u.split("."),p=(/^\d+$/.test(s[0])?s:["0"].concat(s)).reduce((function(n,t){return n.reduce((function(n,e){return null!=e&&t in Object(e)?["function"==typeof e[t]?e[t]():e[t]]:[]}),[])}),[a]).reduce((function(n,t){return t}),"");if(null==d)return p;if(Object.prototype.hasOwnProperty.call(n,d))return n[d](p);throw e('no transformer named "'+d+'"')}))}}var r=a({});r.create=a,r.extend=function(n,e){var r=a(e);n.format=function(){var n=Array.prototype.slice.call(arguments);return n.unshift(this),r.apply(t,n)}},n.exports=r}).call(w,w)}));function y(){var n=a(o)||{locale:"en-PH"},t=n.values,e=n.locale;return r((function(){return{t:function(n,a){return t?t[n]?a?x(t[n]||n,a):t[n]||n:(console.warn("[useTranslations] Missing translation for key ".concat(n," and locale ").concat(e)),a?x(i[n]||n,a):i[n]||n):(console.error("[useTranslations] t method called before translation values are loaded"),n)},locale:e}}),[t,e])}export{O as B,T as M,E as a,I as b,A as c,w as d,x as e,L as f,B as g,m,f as p,l as s,_ as t,y as u};
2
+ //# sourceMappingURL=useTranslations-0c13f2cb.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useTranslations-0c13f2cb.js","sources":["../../src/misc/utils.ts","../../node_modules/string-format/index.js","../../src/hooks/useTranslations.tsx"],"sourcesContent":["import { css } from 'styled-components'\nconst BREAK_POINT = 768\nconst BREAK_POINT_TABLET = 1024\n\nconst logDeprecate = {\n spLayout: false,\n pcLayout: false,\n tdLayout: false,\n mbLayout: false,\n}\n\n/**\n * The breakpoint for smartphone devices less than 768.\n * @example\n * ${(props: ThemeProps) => spLayout()`\n * color: ${props.theme.colors.neutral100};\n * `}\n * @example\n * ${spLayout()`\n * color: ${(props) => props.theme.colors.neutral100};\n * `}\n */\n\nexport const spLayout = () => {\n if (!logDeprecate.spLayout) {\n console.error('spLayout is deprecated. Use `MediaQueries.mbDown` instead.')\n logDeprecate.spLayout = true\n }\n return (style: TemplateStringsArray, ...exps) => css`\n @media (max-width: ${BREAK_POINT - 1}px) {\n ${css(style, ...exps)};\n }\n `\n}\n\n/**\n * The breakpoint for mobile and tablet devices less than 1024\n * @example\n * ${(props: ThemeProps) => mbLayout()`\n * color: ${props.theme.colors.neutral100};\n * `}\n * @example\n * ${mbLayout()`\n * color: ${(props) => props.theme.colors.neutral100};\n * `}\n */\nexport const mbLayout = () => {\n if (!logDeprecate.mbLayout) {\n console.error('mbLayout is deprecated. Use `MediaQueries.tdDown` instead.')\n logDeprecate.mbLayout = true\n }\n return (style: TemplateStringsArray, ...exps) => css`\n @media (max-width: ${BREAK_POINT_TABLET - 1}px) {\n ${css(style, ...exps)};\n }\n `\n}\n\n/**\n * The breakpoint for tablet devices only between 768 and 1024\n * @example\n * ${(props: ThemeProps) => tdLayout()`\n * color: ${props.theme.colors.neutral100};\n * `}\n * @example\n * ${tdLayout()`\n * color: ${(props) => props.theme.colors.neutral100};\n * `}\n */\nexport const tdLayout = () => {\n if (!logDeprecate.tdLayout) {\n console.error('tdLayout is deprecated. Use `MediaQueries.tdOnly` instead.')\n logDeprecate.tdLayout = true\n }\n return (style: TemplateStringsArray, ...exps) => css`\n @media (min-width: ${BREAK_POINT}px) and (max-width: ${BREAK_POINT_TABLET - 1}px) {\n ${css(style, ...exps)};\n }\n `\n}\n\n/**\n * The breakpoint for pc/laptop devices greater than or equal 1024.\n * @example\n * ${(props: ThemeProps) => pcLayout()`\n * color: ${props.theme.colors.neutral100};\n * `}\n * @example\n * ${pcLayout()`\n * color: ${(props) => props.theme.colors.neutral100};\n * `}\n */\nexport const pcLayout = (useBreakpointMobile?: boolean) => {\n if (!logDeprecate.pcLayout) {\n console.error('pcLayout is deprecated. if pcLayout(true) use `MediaQueries.mbUp`. If pcLayout() use `MediaQueries.tdUp`.')\n logDeprecate.pcLayout = true\n }\n return (style: TemplateStringsArray, ...exps) => css`\n @media (min-width: ${useBreakpointMobile ? BREAK_POINT : BREAK_POINT_TABLET}px) {\n ${css(style, ...exps)};\n }\n `\n}\n\nexport const makeParams = (params: Record<string, string>): string => {\n const paramKeys = Object.keys(params)\n if (!paramKeys.length) {\n return ''\n }\n return '?' + paramKeys.map((k: string) => `${k}=${params[k]}`).join('&')\n}\n\nexport const formatUrlWithPageParam = (\n path: string,\n page = 1,\n queryPageName = 'page',\n) => {\n const [urlPart, queryPart] = path.split('?')\n const urlObj = new URLSearchParams(queryPart || '')\n const params: Record<string, string> = {}\n\n urlObj.forEach((val, key) => {\n if (val) {\n params[key] = val\n }\n })\n\n if (Number(page) > 1) {\n params[queryPageName] = String(page) // Default is params.page\n } else {\n // Do not display \"page=1\" on the URL\n delete params[queryPageName] // Default is params.page\n }\n\n return urlPart + makeParams(params)\n}\n\nexport const toggleNoScroll = (isNoScroll?: boolean) => {\n if (typeof window !== 'undefined') {\n document.documentElement.classList.toggle('noscroll', isNoScroll)\n document.body.classList.toggle('noscroll', isNoScroll)\n }\n}\n\nexport const Breakpoints = {\n BREAK_POINT_SMALL_MOBILE: 481,\n BREAK_POINT_MOBILE: 768,\n BREAK_POINT_TABLET: 1024,\n BREAK_POINT_PC: 1200,\n}\n\n/**\n * List of mediaQueries to use in StyledComponents\n * New naming convention base around breakpoints\n*\n * Note: smb = small mobile; mb = mobile; td = tablet device; pc = pc/laptop device\n *\n * smbDown: BREAK_POINT_SMALL_MOBILE go down.\n * smbUp: BREAK_POINT_SMALL_MOBILE go up\n *\n * mbDown: REPLACE spLayout. BREAK_POINT_MOBILE go down.\n * mbOnly: from BREAK_POINT_SMALL_MOBILE to BREAK_POINT_MOBILE\n * mbUp: REPLACE pcLayout(true). BREAK_POINT_MOBILE go up\n *\n * tdDown: REPLACE mbLayout. BREAK_POINT_TABLET go down\n * tdOnly: REPLACE tdLayout. from BREAK_POINT_MOBILE to BREAK_POINT_TABLET\n * tdUp: REPLACE pcLayout(). BREAK_POINT_TABLET go up\n *\n * pcDown: BREAK_POINT_PC go down\n * pcOnly: from BREAK_POINT_TABLET to BREAK_POINT_PC\n * pcUp: BREAK_POINT_PC go up\n *\n * @example\n * ${MediaQueries.mbDown} {\n * color: ${(props) => props.theme.colors.neutral100 }};\n * }\n */\nexport const MediaQueries = {\n smbDown: `@media (max-width: ${Breakpoints.BREAK_POINT_SMALL_MOBILE - 1}px)`,\n smbUp: `@media (min-width: ${Breakpoints.BREAK_POINT_SMALL_MOBILE}px)`,\n\n mbDown: `@media (max-width: ${Breakpoints.BREAK_POINT_MOBILE - 1}px)`,\n mbOnly: `@media (min-width: ${Breakpoints.BREAK_POINT_SMALL_MOBILE}px) and (max-width: ${Breakpoints.BREAK_POINT_MOBILE - 1}px)`,\n mbUp: `@media (min-width: ${Breakpoints.BREAK_POINT_MOBILE}px)`,\n \n tdDown: `@media (max-width: ${Breakpoints.BREAK_POINT_TABLET - 1}px)`,\n tdOnly: `@media (min-width: ${Breakpoints.BREAK_POINT_MOBILE\n }px) and (max-width: ${Breakpoints.BREAK_POINT_TABLET - 1}px)`,\n tdUp: `@media (min-width: ${Breakpoints.BREAK_POINT_TABLET}px)`,\n \n pcUp: `@media (min-width: ${Breakpoints.BREAK_POINT_PC}px)`,\n pcOnly: `@media (min-width: ${Breakpoints.BREAK_POINT_TABLET}px) and (max-width: ${Breakpoints.BREAK_POINT_PC - 1}px)`,\n pcDown: `@media (max-width: ${Breakpoints.BREAK_POINT_PC - 1}px)`,\n}\n\nexport const getBoundariesFromMediaQueryKey = (key?: keyof typeof MediaQueries) => {\n // zero mean not set\n switch(key) {\n case 'smbDown': return [0, Breakpoints.BREAK_POINT_SMALL_MOBILE - 1]\n case 'smbUp': return [Breakpoints.BREAK_POINT_SMALL_MOBILE, 0]\n\n case 'mbDown': return [0, Breakpoints.BREAK_POINT_MOBILE - 1]\n case 'mbOnly': return [Breakpoints.BREAK_POINT_SMALL_MOBILE, Breakpoints.BREAK_POINT_MOBILE - 1]\n case 'mbUp': return [Breakpoints.BREAK_POINT_MOBILE, 0]\n\n case 'tdDown': return [0, Breakpoints.BREAK_POINT_TABLET - 1]\n case 'tdOnly': return [Breakpoints.BREAK_POINT_MOBILE, Breakpoints.BREAK_POINT_TABLET - 1]\n case 'tdUp': return [Breakpoints.BREAK_POINT_TABLET, 0]\n\n case 'pcUp': return [Breakpoints.BREAK_POINT_PC, 0]\n case 'pcOnly': return [Breakpoints.BREAK_POINT_TABLET, Breakpoints.BREAK_POINT_PC - 1]\n case 'pcDown': return [0, Breakpoints.BREAK_POINT_PC - 1]\n }\n}","void function(global) {\n\n 'use strict';\n\n // ValueError :: String -> Error\n function ValueError(message) {\n var err = new Error(message);\n err.name = 'ValueError';\n return err;\n }\n\n // create :: Object -> String,*... -> String\n function create(transformers) {\n return function(template) {\n var args = Array.prototype.slice.call(arguments, 1);\n var idx = 0;\n var state = 'UNDEFINED';\n\n return template.replace(\n /([{}])\\1|[{](.*?)(?:!(.+?))?[}]/g,\n function(match, literal, _key, xf) {\n if (literal != null) {\n return literal;\n }\n var key = _key;\n if (key.length > 0) {\n if (state === 'IMPLICIT') {\n throw ValueError('cannot switch from ' +\n 'implicit to explicit numbering');\n }\n state = 'EXPLICIT';\n } else {\n if (state === 'EXPLICIT') {\n throw ValueError('cannot switch from ' +\n 'explicit to implicit numbering');\n }\n state = 'IMPLICIT';\n key = String(idx);\n idx += 1;\n }\n\n // 1. Split the key into a lookup path.\n // 2. If the first path component is not an index, prepend '0'.\n // 3. Reduce the lookup path to a single result. If the lookup\n // succeeds the result is a singleton array containing the\n // value at the lookup path; otherwise the result is [].\n // 4. Unwrap the result by reducing with '' as the default value.\n var path = key.split('.');\n var value = (/^\\d+$/.test(path[0]) ? path : ['0'].concat(path))\n .reduce(function(maybe, key) {\n return maybe.reduce(function(_, x) {\n return x != null && key in Object(x) ?\n [typeof x[key] === 'function' ? x[key]() : x[key]] :\n [];\n }, []);\n }, [args])\n .reduce(function(_, x) { return x; }, '');\n\n if (xf == null) {\n return value;\n } else if (Object.prototype.hasOwnProperty.call(transformers, xf)) {\n return transformers[xf](value);\n } else {\n throw ValueError('no transformer named \"' + xf + '\"');\n }\n }\n );\n };\n }\n\n // format :: String,*... -> String\n var format = create({});\n\n // format.create :: Object -> String,*... -> String\n format.create = create;\n\n // format.extend :: Object,Object -> ()\n format.extend = function(prototype, transformers) {\n var $format = create(transformers);\n prototype.format = function() {\n var args = Array.prototype.slice.call(arguments);\n args.unshift(this);\n return $format.apply(global, args);\n };\n };\n\n /* istanbul ignore else */\n if (typeof module !== 'undefined') {\n module.exports = format;\n } else if (typeof define === 'function' && define.amd) {\n define(function() { return format; });\n } else {\n global.format = format;\n }\n\n}.call(this, this);\n","import { useContext, useMemo } from 'react'\n\nimport { defaultTranslations, TranslationsKey } from 'i18n/translations'\nimport { TranslationsContext } from 'i18n/translationsContext'\nimport { LocaleType } from 'interfaces/types'\nimport formatString from 'string-format'\n\ntype UseTranslationsReturn<L> = {\n locale: L\n t: (k: TranslationsKey, option?: { [key: string]: any }) => string\n}\n\nexport function useTranslations<L = LocaleType>(): UseTranslationsReturn<L> {\n const { values, locale } = useContext(TranslationsContext) || {\n locale: 'en-PH',\n }\n return useMemo(\n () => ({\n t(k, option?) {\n if (!values) {\n console.error(\n '[useTranslations] t method called before translation values are loaded',\n )\n return k\n }\n if (values[k]) {\n return option ? formatString(values[k] || k, option) : values[k] || k\n }\n console.warn(\n `[useTranslations] Missing translation for key ${k} and locale ${locale}`,\n )\n return option\n ? formatString(defaultTranslations[k] || k, option)\n : defaultTranslations[k] || k\n },\n // @ts-ignore\n locale,\n }),\n [values, locale],\n )\n}\n"],"names":["logDeprecate","spLayout","pcLayout","tdLayout","mbLayout","console","error","style","exps","_i","arguments","length","css","templateObject_1","__makeTemplateObject","BREAK_POINT","apply","__spreadArray","templateObject_2","BREAK_POINT_TABLET","useBreakpointMobile","makeParams","params","paramKeys","Object","keys","map","k","concat","join","formatUrlWithPageParam","path","page","queryPageName","_a","split","urlPart","queryPart","urlObj","URLSearchParams","forEach","val","key","Number","String","toggleNoScroll","isNoScroll","window","document","documentElement","classList","toggle","body","Breakpoints","BREAK_POINT_SMALL_MOBILE","BREAK_POINT_MOBILE","BREAK_POINT_PC","MediaQueries","smbDown","smbUp","mbDown","mbOnly","mbUp","tdDown","tdOnly","tdUp","pcUp","pcOnly","pcDown","getBoundariesFromMediaQueryKey","global","ValueError","message","err","Error","name","create","transformers","template","args","Array","prototype","slice","call","idx","state","replace","match","literal","_key","xf","value","test","reduce","maybe","_","x","hasOwnProperty","format","extend","$format","unshift","this","module","exports","useTranslations","useContext","TranslationsContext","locale","values","useMemo","t","option","formatString","warn","defaultTranslations"],"mappings":"wMACA,YAGMA,EAAe,CACnBC,UAAU,EACVC,UAAU,EACVC,UAAU,EACVC,UAAU,GAeCH,EAAW,WAKtB,OAJKD,EAAaC,WAChBI,QAAQC,MAAM,8DACdN,EAAaC,UAAW,GAEnB,SAACM,OAA6B,IAAOC,EAAA,GAAAC,EAAA,EAAPA,EAAOC,UAAAC,OAAPF,IAAAD,EAAOC,EAAA,GAAAC,UAAAD,GAAK,OAAAG,EAAGC,IAAAA,EAAAC,EAAA,CAAA,4BAAA,gBAAA,gBAAA,CAAA,4BACd,gBACb,kBADFC,IACjBH,EAAII,WAAA,EAAAC,EAAA,CAAAV,GAAUC,GAAI,OAgBbJ,EAAW,WAKtB,OAJKJ,EAAaI,WAChBC,QAAQC,MAAM,8DACdN,EAAaI,UAAW,GAEnB,SAACG,OAA6B,IAAOC,EAAA,GAAAC,EAAA,EAAPA,EAAOC,UAAAC,OAAPF,IAAAD,EAAOC,EAAA,GAAAC,UAAAD,GAAK,OAAAG,EAAGM,IAAAA,EAAAJ,EAAA,CAAA,4BAAA,gBAAA,gBAAA,CAAA,4BACP,gBACpB,kBADFK,KACjBP,EAAII,WAAA,EAAAC,EAAA,CAAAV,GAAUC,GAAI,OAgBbL,EAAW,WAKtB,OAJKH,EAAaG,WAChBE,QAAQC,MAAM,8DACdN,EAAaG,UAAW,GAEnB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,EAAWJ,GAClC,IAAIuB,EAAUxB,EAAOC,GACrBI,EAAUiB,OAAS,WACjB,IAAInB,EAAOC,MAAMC,UAAUC,MAAMC,KAAKzE,WAEtC,OADAqE,EAAKsB,QAAQC,MACNF,EAAQpF,MAAMsD,EAAQS,KAM/BwB,EAAAC,QAAiBN,IAOnBf,KAAKmB,EAAMA,eCnFGG,IACR,IAAAvE,EAAqBwE,EAAWC,IAAwB,CAC5DC,OAAQ,SADFC,EAAM3E,EAAA2E,OAAED,WAGhB,OAAOE,GACL,WAAM,MAAC,CACLC,EAAA,SAAEpF,EAAGqF,GACH,OAAKH,EAMDA,EAAOlF,GACFqF,EAASC,EAAaJ,EAAOlF,IAAMA,EAAGqF,GAAUH,EAAOlF,IAAMA,GAEtEtB,QAAQ6G,KACN,iDAAAtF,OAAiDD,EAAgB,gBAAAC,OAAAgF,IAE5DI,EACHC,EAAaE,EAAoBxF,IAAMA,EAAGqF,GAC1CG,EAAoBxF,IAAMA,IAb5BtB,QAAQC,MACN,0EAEKqB,IAaXiF,OAAMA,KAER,CAACC,EAAQD"}
@@ -1,11 +1,10 @@
1
- /// <reference types="react" />
2
- export declare const useCSSFocusPopupHelper: <T = HTMLDivElement>(configs?: {
1
+ import { MouseEvent } from 'react';
2
+ export declare const useCSSFocusPopupHelper: <T = HTMLDivElement, ButtonType = HTMLDivElement>(configs?: {
3
3
  allowBgScroll?: boolean;
4
4
  }) => {
5
5
  containerRef: import("react").MutableRefObject<T & HTMLElement>;
6
- focusTimeRef: import("react").MutableRefObject<number>;
7
6
  onContainerFocus: () => void;
8
7
  onContainerBlur: () => void;
9
- onButtonClick: () => void;
8
+ onButtonMouseDown: (e: MouseEvent<ButtonType, globalThis.MouseEvent>) => void;
10
9
  onClose: () => void;
11
10
  };
@@ -0,0 +1,2 @@
1
+ import { UserInfo } from 'interfaces/types';
2
+ export declare const useFbDataLayer: (userInfo?: UserInfo | null) => void;
package/build/i18n.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./translationsProvider-4f6e12c9.js"),r=require("./translationsContext-63e3e5ec.js");require("./tslib.es6-f7929e76.js"),require("react"),exports.TranslationsProvider=e.TranslationsProvider,exports.translationsMap=e.translationsMap,exports.TranslationsContext=r.TranslationsContext,exports.defaultTranslations=r.defaultTranslations;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("./translationsProvider-eb4d9fd6.js"),e=require("./translationsContext-351bc1a7.js");require("./tslib.es6-f7929e76.js"),require("react"),exports.TranslationsProvider=r.TranslationsProvider,exports.translationsMap=r.translationsMap,exports.TranslationsContext=e.TranslationsContext,exports.defaultTranslations=e.defaultTranslations;
2
2
  //# sourceMappingURL=i18n.js.map