@admin-layout/tailwind-design-pro 10.1.1-alpha.9 → 11.2.1-alpha.1

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 (443) hide show
  1. package/README.md +376 -250
  2. package/lib/cdm-locales/en/menu.json +2 -1
  3. package/lib/cdm-locales/en/settings.json +6 -1
  4. package/lib/cdm-locales/es/menu.json +2 -1
  5. package/lib/cdm-locales/es/settings.json +6 -1
  6. package/lib/cdm-locales/index.d.ts +2 -0
  7. package/lib/cdm-locales/index.d.ts.map +1 -0
  8. package/lib/cdm-locales/index.ts +1 -0
  9. package/lib/components/LanguageMenu/LanguageMenu.d.ts +2 -1
  10. package/lib/components/LanguageMenu/LanguageMenu.d.ts.map +1 -1
  11. package/lib/components/LanguageMenu/LanguageMenu.js +40 -61
  12. package/lib/components/LanguageMenu/LanguageMenu.js.map +1 -1
  13. package/lib/components/Layout/BasicLayout/index.d.ts +6 -5
  14. package/lib/components/Layout/BasicLayout/index.d.ts.map +1 -1
  15. package/lib/components/Layout/BasicLayout/index.js +255 -175
  16. package/lib/components/Layout/BasicLayout/index.js.map +1 -1
  17. package/lib/components/Layout/BasicLayout/utils.d.ts +4 -2
  18. package/lib/components/Layout/BasicLayout/utils.d.ts.map +1 -1
  19. package/lib/components/Layout/BasicLayout/utils.js +80 -109
  20. package/lib/components/Layout/BasicLayout/utils.js.map +1 -1
  21. package/lib/components/Layout/GlobalFooter/BottomMenuDropdown.d.ts.map +1 -1
  22. package/lib/components/Layout/GlobalFooter/BottomMenuDropdown.js +28 -38
  23. package/lib/components/Layout/GlobalFooter/BottomMenuDropdown.js.map +1 -1
  24. package/lib/components/Layout/GlobalFooter/Copyright.d.ts +2 -1
  25. package/lib/components/Layout/GlobalFooter/Copyright.d.ts.map +1 -1
  26. package/lib/components/Layout/GlobalFooter/Footer.d.ts +2 -1
  27. package/lib/components/Layout/GlobalFooter/Footer.d.ts.map +1 -1
  28. package/lib/components/Layout/GlobalHeader/Header.d.ts +0 -1
  29. package/lib/components/Layout/GlobalHeader/Header.d.ts.map +1 -1
  30. package/lib/components/Layout/GlobalHeader/Header.js +82 -66
  31. package/lib/components/Layout/GlobalHeader/Header.js.map +1 -1
  32. package/lib/components/Layout/GlobalHeader/MainHeader.d.ts +0 -2
  33. package/lib/components/Layout/GlobalHeader/MainHeader.d.ts.map +1 -1
  34. package/lib/components/Layout/GlobalHeader/MainHeader.js +119 -162
  35. package/lib/components/Layout/GlobalHeader/MainHeader.js.map +1 -1
  36. package/lib/components/Layout/GlobalHeader/OrganizationDropdown.d.ts.map +1 -1
  37. package/lib/components/Layout/GlobalHeader/OrganizationDropdown.js +26 -30
  38. package/lib/components/Layout/GlobalHeader/OrganizationDropdown.js.map +1 -1
  39. package/lib/components/Layout/GlobalHeader/RightContent.d.ts +1 -0
  40. package/lib/components/Layout/GlobalHeader/RightContent.d.ts.map +1 -1
  41. package/lib/components/Layout/GlobalHeader/RightContent.js +82 -19
  42. package/lib/components/Layout/GlobalHeader/RightContent.js.map +1 -1
  43. package/lib/components/Layout/GlobalHeader/RightMenu.d.ts.map +1 -1
  44. package/lib/components/Layout/GlobalHeader/RightMenu.js +116 -158
  45. package/lib/components/Layout/GlobalHeader/RightMenu.js.map +1 -1
  46. package/lib/components/Layout/GlobalHeader/SearchBar.d.ts.map +1 -1
  47. package/lib/components/Layout/GlobalHeader/SearchBar.js +36 -45
  48. package/lib/components/Layout/GlobalHeader/SearchBar.js.map +1 -1
  49. package/lib/components/Layout/GlobalHeader/index.d.ts +0 -1
  50. package/lib/components/Layout/GlobalHeader/index.d.ts.map +1 -1
  51. package/lib/components/Layout/ProTailwindLayout.d.ts +2 -2
  52. package/lib/components/Layout/ProTailwindLayout.d.ts.map +1 -1
  53. package/lib/components/Layout/ProTailwindLayout.js +70 -9
  54. package/lib/components/Layout/ProTailwindLayout.js.map +1 -1
  55. package/lib/components/Layout/Sidebar/BottomMenu.d.ts +4 -0
  56. package/lib/components/Layout/Sidebar/BottomMenu.d.ts.map +1 -0
  57. package/lib/components/Layout/Sidebar/BottomMenu.js +294 -0
  58. package/lib/components/Layout/Sidebar/BottomMenu.js.map +1 -0
  59. package/lib/components/Layout/Sidebar/Divider.d.ts +2 -1
  60. package/lib/components/Layout/Sidebar/Divider.d.ts.map +1 -1
  61. package/lib/components/Layout/Sidebar/Divider.js +26 -28
  62. package/lib/components/Layout/Sidebar/Divider.js.map +1 -1
  63. package/lib/components/Layout/Sidebar/DynamicIcon.d.ts +1 -1
  64. package/lib/components/Layout/Sidebar/DynamicIcon.d.ts.map +1 -1
  65. package/lib/components/Layout/Sidebar/DynamicIcon.js +10 -11
  66. package/lib/components/Layout/Sidebar/DynamicIcon.js.map +1 -1
  67. package/lib/components/Layout/Sidebar/MainSidebar.d.ts +5 -0
  68. package/lib/components/Layout/Sidebar/MainSidebar.d.ts.map +1 -0
  69. package/lib/components/Layout/Sidebar/MainSidebar.js +224 -0
  70. package/lib/components/Layout/Sidebar/MainSidebar.js.map +1 -0
  71. package/lib/components/Layout/Sidebar/MainSidebarMenu.d.ts +6 -0
  72. package/lib/components/Layout/Sidebar/MainSidebarMenu.d.ts.map +1 -0
  73. package/lib/components/Layout/Sidebar/MainSidebarMenu.js +451 -0
  74. package/lib/components/Layout/Sidebar/MainSidebarMenu.js.map +1 -0
  75. package/lib/components/Layout/Sidebar/PerplexSidebar.d.ts +4 -0
  76. package/lib/components/Layout/Sidebar/PerplexSidebar.d.ts.map +1 -0
  77. package/lib/components/Layout/Sidebar/PerplexSidebar.js +254 -0
  78. package/lib/components/Layout/Sidebar/PerplexSidebar.js.map +1 -0
  79. package/lib/components/Layout/Sidebar/PerplexSidebarMenu.d.ts +4 -0
  80. package/lib/components/Layout/Sidebar/PerplexSidebarMenu.d.ts.map +1 -0
  81. package/lib/components/Layout/Sidebar/PerplexSidebarMenu.js +318 -0
  82. package/lib/components/Layout/Sidebar/PerplexSidebarMenu.js.map +1 -0
  83. package/lib/components/Layout/TailwindLayout.d.ts.map +1 -1
  84. package/lib/components/Layout/TailwindLayout.js +37 -20
  85. package/lib/components/Layout/TailwindLayout.js.map +1 -1
  86. package/lib/components/Layout/getPageTitle.js.map +1 -1
  87. package/lib/components/Layout/slot-fill/AdditionalSettings.d.ts +3 -2
  88. package/lib/components/Layout/slot-fill/AdditionalSettings.d.ts.map +1 -1
  89. package/lib/components/Layout/slot-fill/AdditionalSettings.js +2 -2
  90. package/lib/components/Layout/slot-fill/AdditionalSettings.js.map +1 -1
  91. package/lib/components/Layout/slot-fill/Footer.d.ts +3 -2
  92. package/lib/components/Layout/slot-fill/Footer.d.ts.map +1 -1
  93. package/lib/components/Layout/slot-fill/Footer.js +2 -2
  94. package/lib/components/Layout/slot-fill/Footer.js.map +1 -1
  95. package/lib/components/Layout/slot-fill/HeaderNotice.d.ts +3 -2
  96. package/lib/components/Layout/slot-fill/HeaderNotice.d.ts.map +1 -1
  97. package/lib/components/Layout/slot-fill/HeaderNotice.js +7 -0
  98. package/lib/components/Layout/slot-fill/HeaderNotice.js.map +1 -0
  99. package/lib/components/Layout/slot-fill/HeaderSearchBar.d.ts +2 -1
  100. package/lib/components/Layout/slot-fill/HeaderSearchBar.d.ts.map +1 -1
  101. package/lib/components/Layout/slot-fill/HeaderSearchBar.js +2 -2
  102. package/lib/components/Layout/slot-fill/HeaderSearchBar.js.map +1 -1
  103. package/lib/components/Layout/slot-fill/HeaderSearchButton.d.ts +2 -1
  104. package/lib/components/Layout/slot-fill/HeaderSearchButton.d.ts.map +1 -1
  105. package/lib/components/Layout/slot-fill/HeaderSearchButton.js +2 -2
  106. package/lib/components/Layout/slot-fill/HeaderSearchButton.js.map +1 -1
  107. package/lib/components/Layout/slot-fill/Logo.d.ts +5 -0
  108. package/lib/components/Layout/slot-fill/Logo.d.ts.map +1 -0
  109. package/lib/components/Layout/slot-fill/Logo.js +7 -0
  110. package/lib/components/Layout/slot-fill/Logo.js.map +1 -0
  111. package/lib/components/Layout/slot-fill/RightContent.d.ts +2 -1
  112. package/lib/components/Layout/slot-fill/RightContent.d.ts.map +1 -1
  113. package/lib/components/Layout/slot-fill/RightContent.js +2 -2
  114. package/lib/components/Layout/slot-fill/RightContent.js.map +1 -1
  115. package/lib/components/Layout/slot-fill/SideMenuLogo.d.ts +5 -0
  116. package/lib/components/Layout/slot-fill/SideMenuLogo.d.ts.map +1 -0
  117. package/lib/components/Layout/slot-fill/SideMenuLogo.js +7 -0
  118. package/lib/components/Layout/slot-fill/SideMenuLogo.js.map +1 -0
  119. package/lib/components/Layout/slot-fill/index.d.ts +2 -0
  120. package/lib/components/Layout/slot-fill/index.d.ts.map +1 -1
  121. package/lib/components/Layout/util.js +1 -1
  122. package/lib/components/Layout/util.js.map +1 -1
  123. package/lib/components/SettingDrawer/SettingDrawer.d.ts +2 -2
  124. package/lib/components/SettingDrawer/SettingDrawer.d.ts.map +1 -1
  125. package/lib/components/SettingDrawer/SettingDrawer.js +190 -499
  126. package/lib/components/SettingDrawer/SettingDrawer.js.map +1 -1
  127. package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.d.ts +8 -0
  128. package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.d.ts.map +1 -0
  129. package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.js +21 -0
  130. package/lib/components/SettingDrawer/components/ApplyToAllRoutesToggle.js.map +1 -0
  131. package/lib/components/SettingDrawer/components/CheckBoxTheme.d.ts +4 -0
  132. package/lib/components/SettingDrawer/components/CheckBoxTheme.d.ts.map +1 -0
  133. package/lib/components/SettingDrawer/components/CheckBoxTheme.js +119 -0
  134. package/lib/components/SettingDrawer/components/CheckBoxTheme.js.map +1 -0
  135. package/lib/components/SettingDrawer/components/DeviceTabs.d.ts +8 -0
  136. package/lib/components/SettingDrawer/components/DeviceTabs.d.ts.map +1 -0
  137. package/lib/components/SettingDrawer/components/DeviceTabs.js +74 -0
  138. package/lib/components/SettingDrawer/components/DeviceTabs.js.map +1 -0
  139. package/lib/components/SettingDrawer/components/InvitationSettings.d.ts +4 -0
  140. package/lib/components/SettingDrawer/components/InvitationSettings.d.ts.map +1 -0
  141. package/lib/components/SettingDrawer/components/InvitationSettings.js +72 -0
  142. package/lib/components/SettingDrawer/components/InvitationSettings.js.map +1 -0
  143. package/lib/components/SettingDrawer/components/LayoutChange.d.ts +4 -0
  144. package/lib/components/SettingDrawer/components/LayoutChange.d.ts.map +1 -0
  145. package/lib/components/SettingDrawer/components/LayoutChange.js +111 -0
  146. package/lib/components/SettingDrawer/components/LayoutChange.js.map +1 -0
  147. package/lib/components/SettingDrawer/components/MenuVisibilitySettings.d.ts +21 -0
  148. package/lib/components/SettingDrawer/components/MenuVisibilitySettings.d.ts.map +1 -0
  149. package/lib/components/SettingDrawer/components/MenuVisibilitySettings.js +106 -0
  150. package/lib/components/SettingDrawer/components/MenuVisibilitySettings.js.map +1 -0
  151. package/lib/components/SettingDrawer/components/NavigationsModes.d.ts +4 -0
  152. package/lib/components/SettingDrawer/components/NavigationsModes.d.ts.map +1 -0
  153. package/lib/components/SettingDrawer/components/NavigationsModes.js +322 -0
  154. package/lib/components/SettingDrawer/components/NavigationsModes.js.map +1 -0
  155. package/lib/components/SettingDrawer/components/RegionalSettings.d.ts +4 -0
  156. package/lib/components/SettingDrawer/components/RegionalSettings.d.ts.map +1 -0
  157. package/lib/components/SettingDrawer/components/RegionalSettings.js +519 -0
  158. package/lib/components/SettingDrawer/components/RegionalSettings.js.map +1 -0
  159. package/lib/components/SettingDrawer/components/SettingsActions.d.ts +13 -0
  160. package/lib/components/SettingDrawer/components/SettingsActions.d.ts.map +1 -0
  161. package/lib/components/SettingDrawer/components/SettingsActions.js +42 -0
  162. package/lib/components/SettingDrawer/components/SettingsActions.js.map +1 -0
  163. package/lib/components/SettingDrawer/components/SettingsDrawerHeader.d.ts +5 -0
  164. package/lib/components/SettingDrawer/components/SettingsDrawerHeader.d.ts.map +1 -0
  165. package/lib/components/SettingDrawer/components/SettingsDrawerHeader.js +22 -0
  166. package/lib/components/SettingDrawer/components/SettingsDrawerHeader.js.map +1 -0
  167. package/lib/components/SettingDrawer/components/Switch.d.ts +4 -0
  168. package/lib/components/SettingDrawer/components/Switch.d.ts.map +1 -0
  169. package/lib/components/SettingDrawer/components/Switch.js +20 -0
  170. package/lib/components/SettingDrawer/components/Switch.js.map +1 -0
  171. package/lib/components/SettingDrawer/components/ThemeColor.d.ts +4 -0
  172. package/lib/components/SettingDrawer/components/ThemeColor.d.ts.map +1 -0
  173. package/lib/components/SettingDrawer/components/ThemeColor.js +45 -0
  174. package/lib/components/SettingDrawer/components/ThemeColor.js.map +1 -0
  175. package/lib/components/SettingDrawer/components/ThemeSelector.d.ts +4 -0
  176. package/lib/components/SettingDrawer/components/ThemeSelector.d.ts.map +1 -0
  177. package/lib/components/SettingDrawer/components/ThemeSelector.js +16 -0
  178. package/lib/components/SettingDrawer/components/ThemeSelector.js.map +1 -0
  179. package/lib/components/SettingDrawer/components/WebFontsSelector.d.ts +4 -0
  180. package/lib/components/SettingDrawer/components/WebFontsSelector.d.ts.map +1 -0
  181. package/lib/components/SettingDrawer/components/WebFontsSelector.js +22 -0
  182. package/lib/components/SettingDrawer/components/WebFontsSelector.js.map +1 -0
  183. package/lib/components/SettingDrawer/hooks/useSettingsOperations.d.ts +18 -0
  184. package/lib/components/SettingDrawer/hooks/useSettingsOperations.d.ts.map +1 -0
  185. package/lib/components/SettingDrawer/hooks/useSettingsOperations.js +115 -0
  186. package/lib/components/SettingDrawer/hooks/useSettingsOperations.js.map +1 -0
  187. package/lib/components/SettingDrawer/utils/constants.d.ts +11 -0
  188. package/lib/components/SettingDrawer/utils/constants.d.ts.map +1 -0
  189. package/lib/components/SettingDrawer/utils/constants.js +77 -0
  190. package/lib/components/SettingDrawer/utils/constants.js.map +1 -0
  191. package/lib/components/SettingDrawer/utils/helper.d.ts +37 -0
  192. package/lib/components/SettingDrawer/utils/helper.d.ts.map +1 -0
  193. package/lib/components/SettingDrawer/utils/helper.js +154 -0
  194. package/lib/components/SettingDrawer/utils/helper.js.map +1 -0
  195. package/lib/components/SettingDrawer/utils/transformers.d.ts +15 -0
  196. package/lib/components/SettingDrawer/utils/transformers.d.ts.map +1 -0
  197. package/lib/components/SettingDrawer/utils/transformers.js +73 -0
  198. package/lib/components/SettingDrawer/utils/transformers.js.map +1 -0
  199. package/lib/components/SettingDrawer/{types.d.ts → utils/types.d.ts} +14 -0
  200. package/lib/components/SettingDrawer/utils/types.d.ts.map +1 -0
  201. package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.d.ts +13 -4
  202. package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.d.ts.map +1 -1
  203. package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.js +97 -4
  204. package/lib/components/UpdateSettingsResource/UpdateSettingsResource.server.js.map +1 -1
  205. package/lib/components/index.d.ts +0 -2
  206. package/lib/components/index.d.ts.map +1 -1
  207. package/lib/components/index.js +1 -1
  208. package/lib/components/typings.d.ts +20 -6
  209. package/lib/components/typings.d.ts.map +1 -1
  210. package/lib/compute.d.ts.map +1 -1
  211. package/lib/compute.js +10 -2
  212. package/lib/compute.js.map +1 -1
  213. package/lib/config/analytics-config.d.ts +59 -0
  214. package/lib/config/analytics-config.d.ts.map +1 -0
  215. package/lib/config/constants.js.map +1 -1
  216. package/lib/config/env-config.d.ts +6 -0
  217. package/lib/config/env-config.d.ts.map +1 -1
  218. package/lib/config/env-config.js +21 -1
  219. package/lib/config/env-config.js.map +1 -1
  220. package/lib/config/index.d.ts +3 -0
  221. package/lib/config/index.d.ts.map +1 -0
  222. package/lib/helpers/DynamicIcon.d.ts +1 -1
  223. package/lib/helpers/DynamicIcon.d.ts.map +1 -1
  224. package/lib/helpers/DynamicIcon.js +16 -17
  225. package/lib/helpers/DynamicIcon.js.map +1 -1
  226. package/lib/hooks/index.d.ts +0 -3
  227. package/lib/hooks/index.d.ts.map +1 -1
  228. package/lib/hooks/useMediaQuery.js.map +1 -1
  229. package/lib/hooks/useScrollThreshold.js.map +1 -1
  230. package/lib/hooks/useTailwindTheme.js.map +1 -1
  231. package/lib/icons.d.ts +2 -0
  232. package/lib/icons.d.ts.map +1 -1
  233. package/lib/icons.js +4 -2
  234. package/lib/icons.js.map +1 -1
  235. package/lib/index.d.ts +1 -1
  236. package/lib/index.d.ts.map +1 -1
  237. package/lib/index.js +1 -1
  238. package/lib/index.js.map +1 -1
  239. package/lib/machines/selectors.d.ts +118 -0
  240. package/lib/machines/selectors.d.ts.map +1 -0
  241. package/lib/machines/settingsMachine.d.ts +25 -2
  242. package/lib/machines/settingsMachine.d.ts.map +1 -1
  243. package/lib/machines/settingsMachine.js +133 -168
  244. package/lib/machines/settingsMachine.js.map +1 -1
  245. package/lib/machines/types.d.ts +107 -9
  246. package/lib/machines/types.d.ts.map +1 -1
  247. package/lib/machines/types.js.map +1 -1
  248. package/lib/module.js.map +1 -1
  249. package/lib/redux/searchReducer.d.ts +1 -1
  250. package/lib/redux/searchReducer.d.ts.map +1 -1
  251. package/lib/redux/searchReducer.js.map +1 -1
  252. package/lib/routes.json +9 -1
  253. package/lib/styles/index.css +602 -372
  254. package/lib/tailwindConfig.d.ts +85 -27
  255. package/lib/tailwindConfig.d.ts.map +1 -1
  256. package/lib/tailwindConfig.js +96 -18
  257. package/lib/tailwindConfig.js.map +1 -1
  258. package/lib/utils/__tests__/analytics-utils.test.d.ts +2 -0
  259. package/lib/utils/__tests__/analytics-utils.test.d.ts.map +1 -0
  260. package/lib/utils/__tests__/configOverrides.test.d.ts +2 -0
  261. package/lib/utils/__tests__/configOverrides.test.d.ts.map +1 -0
  262. package/lib/utils/__tests__/menu.test.d.ts +2 -0
  263. package/lib/utils/__tests__/menu.test.d.ts.map +1 -0
  264. package/lib/utils/__tests__/selectors.test.d.ts +2 -0
  265. package/lib/utils/__tests__/selectors.test.d.ts.map +1 -0
  266. package/lib/utils/__tests__/settingsMachine.test.d.ts +2 -0
  267. package/lib/utils/__tests__/settingsMachine.test.d.ts.map +1 -0
  268. package/lib/utils/__tests__/settingsUtils.test.d.ts +2 -0
  269. package/lib/utils/__tests__/settingsUtils.test.d.ts.map +1 -0
  270. package/lib/utils/analytics-utils.d.ts +43 -0
  271. package/lib/utils/analytics-utils.d.ts.map +1 -0
  272. package/lib/utils/analytics.d.ts +48 -0
  273. package/lib/utils/analytics.d.ts.map +1 -0
  274. package/lib/utils/configOverrides.d.ts +213 -0
  275. package/lib/utils/configOverrides.d.ts.map +1 -0
  276. package/lib/utils/configOverrides.js +91 -0
  277. package/lib/utils/configOverrides.js.map +1 -0
  278. package/lib/utils/isBrowser/index.js.map +1 -1
  279. package/lib/utils/settingsUtils.d.ts +20 -0
  280. package/lib/utils/settingsUtils.d.ts.map +1 -0
  281. package/lib/utils/settingsUtils.js +74 -0
  282. package/lib/utils/settingsUtils.js.map +1 -0
  283. package/lib/utils/utils/index.js.map +1 -1
  284. package/package.json +7 -15
  285. package/lib/components/Layout/GlobalHeader/Logo.d.ts +0 -4
  286. package/lib/components/Layout/GlobalHeader/Logo.d.ts.map +0 -1
  287. package/lib/components/Layout/GlobalHeader/Logo.js +0 -141
  288. package/lib/components/Layout/GlobalHeader/Logo.js.map +0 -1
  289. package/lib/components/Layout/Sidebar/Sidebar.d.ts +0 -5
  290. package/lib/components/Layout/Sidebar/Sidebar.d.ts.map +0 -1
  291. package/lib/components/Layout/Sidebar/Sidebar.js +0 -186
  292. package/lib/components/Layout/Sidebar/Sidebar.js.map +0 -1
  293. package/lib/components/Layout/Sidebar/SidebarMenu.d.ts +0 -4
  294. package/lib/components/Layout/Sidebar/SidebarMenu.d.ts.map +0 -1
  295. package/lib/components/Layout/Sidebar/SidebarMenu.js +0 -183
  296. package/lib/components/Layout/Sidebar/SidebarMenu.js.map +0 -1
  297. package/lib/components/SettingDrawer/CheckBoxTheme.d.ts +0 -3
  298. package/lib/components/SettingDrawer/CheckBoxTheme.d.ts.map +0 -1
  299. package/lib/components/SettingDrawer/CheckBoxTheme.js +0 -123
  300. package/lib/components/SettingDrawer/CheckBoxTheme.js.map +0 -1
  301. package/lib/components/SettingDrawer/LayoutChange.d.ts +0 -3
  302. package/lib/components/SettingDrawer/LayoutChange.d.ts.map +0 -1
  303. package/lib/components/SettingDrawer/LayoutChange.js +0 -123
  304. package/lib/components/SettingDrawer/LayoutChange.js.map +0 -1
  305. package/lib/components/SettingDrawer/NavigationsModes.d.ts +0 -3
  306. package/lib/components/SettingDrawer/NavigationsModes.d.ts.map +0 -1
  307. package/lib/components/SettingDrawer/NavigationsModes.js +0 -289
  308. package/lib/components/SettingDrawer/NavigationsModes.js.map +0 -1
  309. package/lib/components/SettingDrawer/RegionalSettings.d.ts +0 -3
  310. package/lib/components/SettingDrawer/RegionalSettings.d.ts.map +0 -1
  311. package/lib/components/SettingDrawer/RegionalSettings.js +0 -740
  312. package/lib/components/SettingDrawer/RegionalSettings.js.map +0 -1
  313. package/lib/components/SettingDrawer/Switch/index.d.ts +0 -3
  314. package/lib/components/SettingDrawer/Switch/index.d.ts.map +0 -1
  315. package/lib/components/SettingDrawer/Switch/index.js +0 -22
  316. package/lib/components/SettingDrawer/Switch/index.js.map +0 -1
  317. package/lib/components/SettingDrawer/ThemeColor.d.ts +0 -3
  318. package/lib/components/SettingDrawer/ThemeColor.d.ts.map +0 -1
  319. package/lib/components/SettingDrawer/ThemeColor.js +0 -35
  320. package/lib/components/SettingDrawer/ThemeColor.js.map +0 -1
  321. package/lib/components/SettingDrawer/ThemeSelector.d.ts +0 -3
  322. package/lib/components/SettingDrawer/ThemeSelector.d.ts.map +0 -1
  323. package/lib/components/SettingDrawer/ThemeSelector.js +0 -18
  324. package/lib/components/SettingDrawer/ThemeSelector.js.map +0 -1
  325. package/lib/components/SettingDrawer/WebFontsSelector.d.ts +0 -3
  326. package/lib/components/SettingDrawer/WebFontsSelector.d.ts.map +0 -1
  327. package/lib/components/SettingDrawer/WebFontsSelector.js +0 -24
  328. package/lib/components/SettingDrawer/WebFontsSelector.js.map +0 -1
  329. package/lib/components/SettingDrawer/types.d.ts.map +0 -1
  330. package/lib/components/ThemeProvider/ThemeProvider.d.ts +0 -8
  331. package/lib/components/ThemeProvider/ThemeProvider.d.ts.map +0 -1
  332. package/lib/components/ThemeProvider/ThemeProvider.js +0 -60
  333. package/lib/components/ThemeProvider/ThemeProvider.js.map +0 -1
  334. package/lib/components/ThemeProvider/ThemeToggle.d.ts +0 -7
  335. package/lib/components/ThemeProvider/ThemeToggle.d.ts.map +0 -1
  336. package/lib/components/ThemeProvider/ThemeToggle.js +0 -50
  337. package/lib/components/ThemeProvider/ThemeToggle.js.map +0 -1
  338. package/lib/components/ThemeProvider/index.d.ts +0 -4
  339. package/lib/components/ThemeProvider/index.d.ts.map +0 -1
  340. package/lib/components/ThemeProvider/themes/airbnb.d.ts +0 -3
  341. package/lib/components/ThemeProvider/themes/airbnb.d.ts.map +0 -1
  342. package/lib/components/ThemeProvider/themes/airbnb.js +0 -186
  343. package/lib/components/ThemeProvider/themes/airbnb.js.map +0 -1
  344. package/lib/components/ThemeProvider/themes/default.d.ts +0 -3
  345. package/lib/components/ThemeProvider/themes/default.d.ts.map +0 -1
  346. package/lib/components/ThemeProvider/themes/default.js +0 -183
  347. package/lib/components/ThemeProvider/themes/default.js.map +0 -1
  348. package/lib/components/ThemeProvider/themes/github.d.ts +0 -3
  349. package/lib/components/ThemeProvider/themes/github.d.ts.map +0 -1
  350. package/lib/components/ThemeProvider/themes/github.js +0 -190
  351. package/lib/components/ThemeProvider/themes/github.js.map +0 -1
  352. package/lib/components/ThemeProvider/themes/index.d.ts +0 -15
  353. package/lib/components/ThemeProvider/themes/index.d.ts.map +0 -1
  354. package/lib/components/ThemeProvider/themes/index.js +0 -7
  355. package/lib/components/ThemeProvider/themes/index.js.map +0 -1
  356. package/lib/components/ThemeProvider/themes/slack.d.ts +0 -3
  357. package/lib/components/ThemeProvider/themes/slack.d.ts.map +0 -1
  358. package/lib/components/ThemeProvider/themes/slack.js +0 -188
  359. package/lib/components/ThemeProvider/themes/slack.js.map +0 -1
  360. package/lib/components/ThemeProvider/themes/spotify.d.ts +0 -3
  361. package/lib/components/ThemeProvider/themes/spotify.d.ts.map +0 -1
  362. package/lib/components/ThemeProvider/themes/spotify.js +0 -189
  363. package/lib/components/ThemeProvider/themes/spotify.js.map +0 -1
  364. package/lib/components/ThemeProvider/types.d.ts +0 -112
  365. package/lib/components/ThemeProvider/types.d.ts.map +0 -1
  366. package/lib/components/UI/CardList.d.ts +0 -61
  367. package/lib/components/UI/CardList.d.ts.map +0 -1
  368. package/lib/components/UI/CardList.js +0 -43
  369. package/lib/components/UI/CardList.js.map +0 -1
  370. package/lib/components/UI/CategoriesTypeList.d.ts +0 -29
  371. package/lib/components/UI/CategoriesTypeList.d.ts.map +0 -1
  372. package/lib/components/UI/CategoriesTypeList.js +0 -140
  373. package/lib/components/UI/CategoriesTypeList.js.map +0 -1
  374. package/lib/components/UI/LazyLoadingGoogleMarker.d.ts +0 -83
  375. package/lib/components/UI/LazyLoadingGoogleMarker.d.ts.map +0 -1
  376. package/lib/components/UI/LazyLoadingGoogleMarker.js +0 -107
  377. package/lib/components/UI/LazyLoadingGoogleMarker.js.map +0 -1
  378. package/lib/components/UI/Pagination.d.ts +0 -6
  379. package/lib/components/UI/Pagination.d.ts.map +0 -1
  380. package/lib/components/UI/Pagination.js +0 -59
  381. package/lib/components/UI/Pagination.js.map +0 -1
  382. package/lib/components/UI/ParamSearchResultContainer.d.ts +0 -99
  383. package/lib/components/UI/ParamSearchResultContainer.d.ts.map +0 -1
  384. package/lib/components/UI/ParamSearchResultContainer.js +0 -120
  385. package/lib/components/UI/ParamSearchResultContainer.js.map +0 -1
  386. package/lib/components/UI/PropertyCard.d.ts +0 -24
  387. package/lib/components/UI/PropertyCard.d.ts.map +0 -1
  388. package/lib/components/UI/PropertyCard.js +0 -375
  389. package/lib/components/UI/PropertyCard.js.map +0 -1
  390. package/lib/components/UI/PropertyCardOnMap.d.ts +0 -10
  391. package/lib/components/UI/PropertyCardOnMap.d.ts.map +0 -1
  392. package/lib/components/UI/PropertyCardOnMap.js +0 -108
  393. package/lib/components/UI/PropertyCardOnMap.js.map +0 -1
  394. package/lib/components/UI/VehicleCard/PricePopover.d.ts +0 -8
  395. package/lib/components/UI/VehicleCard/PricePopover.d.ts.map +0 -1
  396. package/lib/components/UI/VehicleCard/PricePopover.js +0 -98
  397. package/lib/components/UI/VehicleCard/PricePopover.js.map +0 -1
  398. package/lib/components/UI/VehicleCard/VehicleBadge.d.ts +0 -7
  399. package/lib/components/UI/VehicleCard/VehicleBadge.d.ts.map +0 -1
  400. package/lib/components/UI/VehicleCard/VehicleFeature.d.ts +0 -9
  401. package/lib/components/UI/VehicleCard/VehicleFeature.d.ts.map +0 -1
  402. package/lib/components/UI/VehicleCard/VehicleFeature.js +0 -23
  403. package/lib/components/UI/VehicleCard/VehicleFeature.js.map +0 -1
  404. package/lib/components/UI/VehicleCard/types.d.ts +0 -59
  405. package/lib/components/UI/VehicleCard/types.d.ts.map +0 -1
  406. package/lib/components/UI/VehicleCard.d.ts +0 -15
  407. package/lib/components/UI/VehicleCard.d.ts.map +0 -1
  408. package/lib/components/UI/VehicleCard.js +0 -166
  409. package/lib/components/UI/VehicleCard.js.map +0 -1
  410. package/lib/components/UI/VehicleCardList.d.ts +0 -14
  411. package/lib/components/UI/VehicleCardList.d.ts.map +0 -1
  412. package/lib/components/UI/VehicleCardList.js +0 -38
  413. package/lib/components/UI/VehicleCardList.js.map +0 -1
  414. package/lib/components/UI/VehicleParamSearchResultContainer.d.ts +0 -90
  415. package/lib/components/UI/VehicleParamSearchResultContainer.d.ts.map +0 -1
  416. package/lib/components/UI/icons/LocationIcon.d.ts +0 -7
  417. package/lib/components/UI/icons/LocationIcon.d.ts.map +0 -1
  418. package/lib/components/UI/icons/LocationIcon.js +0 -18
  419. package/lib/components/UI/icons/LocationIcon.js.map +0 -1
  420. package/lib/components/UI/icons/index.d.ts +0 -2
  421. package/lib/components/UI/icons/index.d.ts.map +0 -1
  422. package/lib/components/UI/index.d.ts +0 -10
  423. package/lib/components/UI/index.d.ts.map +0 -1
  424. package/lib/components/typings.js +0 -6
  425. package/lib/components/typings.js.map +0 -1
  426. package/lib/hooks/use-get-current-lat-long.d.ts +0 -18
  427. package/lib/hooks/use-get-current-lat-long.d.ts.map +0 -1
  428. package/lib/hooks/use-get-current-lat-long.js +0 -29
  429. package/lib/hooks/use-get-current-lat-long.js.map +0 -1
  430. package/lib/hooks/useWindowSize.d.ts +0 -6
  431. package/lib/hooks/useWindowSize.d.ts.map +0 -1
  432. package/lib/hooks/useWindowSize.js +0 -20
  433. package/lib/hooks/useWindowSize.js.map +0 -1
  434. package/lib/middlewares/airbnbDatasourcesMiddleware.d.ts +0 -6
  435. package/lib/middlewares/airbnbDatasourcesMiddleware.d.ts.map +0 -1
  436. package/lib/middlewares/bookingCarRentalMiddleware.d.ts +0 -6
  437. package/lib/middlewares/bookingCarRentalMiddleware.d.ts.map +0 -1
  438. package/lib/middlewares/bookingDatasourcesMiddleware.d.ts +0 -7
  439. package/lib/middlewares/bookingDatasourcesMiddleware.d.ts.map +0 -1
  440. package/lib/middlewares/datasourcesMiddleware.d.ts +0 -6
  441. package/lib/middlewares/datasourcesMiddleware.d.ts.map +0 -1
  442. package/lib/middlewares/pricelineDatasourcesMiddleware.d.ts +0 -7
  443. package/lib/middlewares/pricelineDatasourcesMiddleware.d.ts.map +0 -1
@@ -1,375 +0,0 @@
1
- import {jsx,Fragment,jsxs}from'react/jsx-runtime';import {useMemo,useState,useEffect,useCallback}from'react';import {BsHeart}from'@react-icons/all-files/bs/BsHeart.js';import {BsStarFill}from'@react-icons/all-files/bs/BsStarFill.js';import {FaUserAlt}from'@react-icons/all-files/fa/FaUserAlt.js';import {useTranslation}from'react-i18next';import {WithAuthentication}from'@adminide-stack/user-auth0-browser/lib/index.component.js';import {Splide,SplideSlide}from'@cdmbase/react-splide';import {useLocation}from'@remix-run/react';import {format}from'date-fns';import {startCase}from'lodash-es';import {useTailwindTheme}from'../../hooks/useTailwindTheme.js';import {useGetCurrentLongLat}from'../../hooks/use-get-current-lat-long.js';import {LocationIcon}from'./icons/LocationIcon.js';import {renderDynamicIcon}from'../../helpers/DynamicIcon.js';import {config}from'../../config/env-config.js';const convertHotelName = name => {
2
- return name.toLowerCase().replace(/[^a-z0-9\s-]/g, '').replace(/[\s-]+/g, '-').replace(/-+/g, '-');
3
- };
4
- const generateHref = (room, from, to, adults, children) => {
5
- switch (room.__typename) {
6
- case 'AirbnbProperty':
7
- return `https://www.airbnb.com/rooms/${room.id}?check_in=${from}&check_out=${to}&guests=${adults + children || 1}`;
8
- case 'BookingProperty':
9
- return `https://www.booking.com/hotel/${room.address.city.state.country.id}/${convertHotelName(room.name)}.html`;
10
- case 'PricelineProperty':
11
- const propertyId = room.metadata?.id_t;
12
- const cityId = room?.metadata?.city?.id || '';
13
- const checkInDate = typeof from === 'string' ? from : format(new Date(from), 'yyyyMMdd');
14
- const checkOutDate = typeof to === 'string' ? to : format(new Date(to), 'yyyyMMdd');
15
- const roomCount = 1;
16
- const adultCount = adults;
17
- return `https://www.priceline.com/relax/at/${propertyId}/from/${checkInDate}/to/${checkOutDate}/rooms/${roomCount}/adults/${adultCount}?cityId=${cityId}&cur=USD&psl=${propertyId}`;
18
- default:
19
- return `/property/${room.id}`;
20
- }
21
- };
22
- const DealCard = ({
23
- site,
24
- price
25
- }) => jsxs("div", {
26
- className: "flex flex-col items-center p-2 rounded-md",
27
- children: [jsx("span", {
28
- className: "text-xs font-bold text-gray-700",
29
- children: site
30
- }), jsx("span", {
31
- className: "text-base font-bold text-black",
32
- children: typeof price === 'number' ? price.toLocaleString() : price
33
- })]
34
- });
35
- function calculateDuration(checkIn, checkOut) {
36
- const checkInDate = new Date(checkIn);
37
- const checkOutDate = new Date(checkOut);
38
- const duration = Math.ceil((checkOutDate.getTime() - checkInDate.getTime()) / (1000 * 60 * 60 * 24));
39
- return duration;
40
- }
41
- function formatDuration(days) {
42
- if (days < 7) {
43
- return `${days} ${days === 1 ? 'day' : 'days'}`;
44
- } else {
45
- const weeks = Math.floor(days / 7);
46
- const remainingDays = days % 7;
47
- let result = `${weeks} ${weeks === 1 ? 'week' : 'weeks'}`;
48
- if (remainingDays > 0) {
49
- result += `, ${remainingDays} ${remainingDays === 1 ? 'day' : 'days'}`;
50
- }
51
- return result;
52
- }
53
- }
54
- const PropertyCard = ({
55
- item,
56
- isSaved,
57
- setFocus,
58
- setBlur,
59
- handleLike,
60
- likeBtnLoading,
61
- categoryTypes,
62
- authenticated,
63
- extraIcons = [],
64
- ...props
65
- }) => {
66
- const images = useMemo(() => item?.images?.data.map(({
67
- url
68
- }) => ({
69
- src: url
70
- })), [item]);
71
- const [didLike, setDidLike] = useState(false);
72
- useMemo(() => item?.totalReview == 0 ? 0 : item?.totalStar / item?.totalReview || 0, [item]);
73
- const {
74
- isDark,
75
- grayColor
76
- } = useTailwindTheme();
77
- const {
78
- t
79
- } = useTranslation(['common', 'property-types']);
80
- const types = useMemo(() => categoryTypes?.filter(type => item?.types?.includes(type.id)), [item, categoryTypes]);
81
- const {
82
- fetchCurrentLatLong,
83
- location} = useGetCurrentLongLat();
84
- const locationUrl = useLocation();
85
- const params = new URLSearchParams(locationUrl.search);
86
- const checkIn = params.get('checkIn') || params.get('from') || '';
87
- const checkOut = params.get('checkOut') || params.get('to') || '';
88
- const duration = calculateDuration(checkIn, checkOut);
89
- const formattedDuration = formatDuration(duration);
90
- useEffect(() => {
91
- fetchCurrentLatLong();
92
- }, []);
93
- const getPriceType = useCallback(room => {
94
- const type = room.preferences?.property?.pricing?.option?.priceType;
95
- if (type === 'HOUR') {
96
- return t('property.hr');
97
- }
98
- return t('property.night');
99
- }, [t]);
100
- useCallback(address => {
101
- if (!location || !address) return null;
102
- if (typeof window !== 'undefined' && window.google && window.google.maps && window.google.maps.LatLng) {
103
- const point1 = new window.google.maps.LatLng(location.latitude, location.longitude);
104
- const point2 = new window.google.maps.LatLng(address.latitude_around, address.longitude_around);
105
- if (window.google.maps.geometry && window.google.maps.geometry.spherical) {
106
- const distance = window.google.maps.geometry.spherical.computeDistanceBetween(point1, point2);
107
- const distanceInMiles = distance * 0.000621371;
108
- return Math.floor(distanceInMiles);
109
- } else {
110
- console.error('Google Maps geometry library is not loaded.');
111
- return null;
112
- }
113
- } else {
114
- return null;
115
- }
116
- }, [location]);
117
- const searchParams = new URLSearchParams(window.location.search);
118
- const adults = parseInt(searchParams.get('adults') || '0', 10) || 1;
119
- const children = parseInt(searchParams.get('children') || '0', 10);
120
- const amenities = item?.preferences?.property?.amenities;
121
- const displayedIcons = amenities ? Object.entries(amenities)?.flatMap(([key, value]) => {
122
- const enabledAmenities = Object.entries(value ?? {})?.filter(([key1, value1]) => value1?.enable && value1?.icon);
123
- const displayedAmenities = enabledAmenities.slice(0, 8);
124
- return displayedAmenities.length > 0 ? displayedAmenities.map(([key1, value1]) => renderDynamicIcon({
125
- name: value1.icon,
126
- style: {
127
- iconColor: grayColor,
128
- w: '20px',
129
- h: '20px'
130
- }
131
- })) : [];
132
- }) : [];
133
- const LikeButton = () => jsx(Fragment, {
134
- children: likeBtnLoading ? jsx("div", {
135
- className: "w-12 h-12 border-4 border-t-blue-500 rounded-full animate-spin border-gray-200"
136
- }) : jsx("button", {
137
- className: `w-7 h-9.5 rounded-full flex items-center justify-center ${didLike ? 'bg-blue-400' : isDark ? 'bg-gray-800' : 'bg-white'}`,
138
- onClick: () => handleLike(item.id),
139
- "aria-label": "Select as your favourite",
140
- children: jsx(BsHeart, {
141
- className: isDark ? 'text-white' : 'text-gray-800'
142
- })
143
- })
144
- });
145
- WithAuthentication(LikeButton);
146
- return jsx(Fragment, {
147
- children: jsxs("div", {
148
- className: "flex flex-row p-2 relative max-w-[370px]",
149
- onMouseEnter: () => setFocus(item.id),
150
- onMouseLeave: () => setBlur(item.id),
151
- ...props,
152
- children: [item?.status === 'pending' && jsxs(Fragment, {
153
- children: [jsx("div", {
154
- className: "absolute w-full h-full bg-black bg-opacity-60 rounded-2xl z-10"
155
- }), jsx("div", {
156
- className: "absolute left-1/2 top-1/2 transform -translate-x-1/2 translate-y-1/2 text-white z-20",
157
- children: jsx("p", {
158
- className: "text-lg font-normal",
159
- children: t('property.coming_soon')
160
- })
161
- })]
162
- }), jsx("div", {
163
- className: "w-full max-w-[100%] border border-solid border-gray-200 rounded-2xl overflow-hidden shadow-md transition-all duration-300 hover:transform hover:-translate-y-1 hover:shadow-lg",
164
- children: jsxs("div", {
165
- className: "w-full h-full flex flex-col justify-between space-y-4",
166
- children: [jsxs("div", {
167
- className: "relative w-full h-full rounded-xl",
168
- children: [jsx("div", {
169
- className: "absolute top-2 left-2 bg-green-600 text-white px-3 py-1 rounded-md text-sm font-bold shadow-md z-10",
170
- children: "Breakfast included"
171
- }), jsxs(Splide, {
172
- "aria-label": "Property Images",
173
- options: {
174
- type: 'slide',
175
- drag: 'free',
176
- perPage: 1,
177
- perMove: 1,
178
- lazyLoad: 'sequential',
179
- wheel: true,
180
- releaseWheel: true,
181
- pagination: false,
182
- speed: 800
183
- },
184
- children: [jsx("div", {
185
- className: "absolute top-2.5 right-2.5 z-10",
186
- children: jsx(LikeButton, {})
187
- }), images.map((image, i) => jsx(SplideSlide, {
188
- children: jsx("a", {
189
- href: generateHref(item, checkIn, checkOut, adults, children),
190
- target: "_blank",
191
- rel: "noopener noreferrer",
192
- children: jsx("div", {
193
- className: "w-full h-full rounded-xl",
194
- children: jsx("img", {
195
- src: image.src,
196
- className: "rounded-xl h-[250px] w-full max-w-full object-cover cursor-pointer transition-all duration-500 hover:brightness-50",
197
- loading: "lazy",
198
- alt: `Property ${i + 1}`
199
- }, 'image_' + i)
200
- }, 'sliderImage_' + i)
201
- })
202
- }, 'sliderslide_' + i))]
203
- })]
204
- }), jsxs("div", {
205
- className: "w-full px-4 flex flex-col pt-2",
206
- children: [jsxs("div", {
207
- className: "flex flex-wrap items-center space-x-2 mb-2",
208
- children: [jsxs("span", {
209
- className: "text-sm font-medium",
210
- children: [t('property.property_type'), ":"]
211
- }), types?.map((item, index) => jsx("span", {
212
- className: "bg-gray-100 text-gray-800 text-xs px-2 py-1 rounded-full capitalize",
213
- children: t(`property-types:${item.description}`)
214
- }, index))]
215
- }), jsx("h3", {
216
- className: "text-lg font-medium mb-2 line-clamp-2",
217
- children: item?.title
218
- }), item?.address && item?.address.city && item?.address.city.state && jsxs("div", {
219
- className: "flex items-center text-sm text-gray-500 mb-2",
220
- children: [jsx(LocationIcon, {
221
- w: "16px",
222
- h: "20px"
223
- }), jsxs("span", {
224
- className: "truncate",
225
- children: [item?.address.city.name + ', ' + item?.address.city.state.name, item?.address?.number ? ' · ' + item?.address?.number : '']
226
- })]
227
- }), displayedIcons.length > 0 && jsx("div", {
228
- className: "flex space-x-3 mt-2 mb-3",
229
- children: displayedIcons
230
- }), jsxs("div", {
231
- className: "flex flex-wrap space-x-2 mt-1 mb-3",
232
- children: [item?.preferences?.property?.booking?.policy?.instantBookingEnabled && jsx("span", {
233
- className: "bg-blue-100 text-blue-800 px-2 py-1 rounded-md text-xs capitalize",
234
- children: t('property.instant_book')
235
- }), item?.preferences?.property?.booking?.policy?.cancellation && jsx("span", {
236
- className: "bg-green-100 text-green-800 px-2 py-1 rounded-md text-xs capitalize",
237
- children: t('property.cancellation_policy')
238
- })]
239
- }), jsxs("div", {
240
- className: "flex items-center mb-4",
241
- children: [jsx(FaUserAlt, {
242
- className: "text-gray-500"
243
- }), jsxs("span", {
244
- className: "text-sm text-gray-600 ml-2",
245
- children: [item?.preferences?.property?.boarding?.maxPeople, " ", t('property.guests')]
246
- })]
247
- })]
248
- }), config.ENABLE_PROPERTY_PRICE_COMPARISON && jsx("div", {
249
- className: "px-4 w-full",
250
- children: jsxs("div", {
251
- className: "w-fit flex gap-4",
252
- children: [jsx("hr", {
253
- className: "w-full border-t border-gray-200"
254
- }), jsxs("div", {
255
- className: "flex flex-row",
256
- children: [jsx(DealCard, {
257
- site: "Vio.com",
258
- price: 41387
259
- }), jsx(DealCard, {
260
- site: "Expedia.com",
261
- price: 46369
262
- }), jsx(DealCard, {
263
- site: "More Deals",
264
- price: 'View all'
265
- })]
266
- }), jsx("hr", {
267
- className: "w-full border-t border-gray-200"
268
- })]
269
- })
270
- }), jsxs("div", {
271
- className: "flex flex-col sm:flex-row px-4 pb-4 w-full justify-between items-start sm:items-center",
272
- children: [jsxs("div", {
273
- className: "flex flex-col space-y-1 mb-3 sm:mb-0 w-full sm:w-auto",
274
- children: [jsxs("div", {
275
- className: "flex items-center",
276
- children: [jsx(BsStarFill, {
277
- className: "text-yellow-500 w-3 h-3 mr-1"
278
- }), jsxs("span", {
279
- className: "text-[0.832rem] font-bold text-gray-600",
280
- children: [item?.reviewsOverview ? item.reviewsOverview.rating : 0, " (", item.reviewsOverview ? item.reviewsOverview.ratingCount : 0, ' ', t('property.reviews'), ")"]
281
- })]
282
- }), item?.__typename && jsxs("span", {
283
- className: "text-[0.832rem] text-gray-500",
284
- children: ["Booking through ", startCase(item.__typename.replace('Property', ''))]
285
- })]
286
- }), jsxs("div", {
287
- className: "flex flex-col items-end space-y-2 w-full sm:w-auto",
288
- children: [jsxs("div", {
289
- className: "flex flex-col items-end space-y-1 w-full",
290
- children: [jsxs("span", {
291
- className: "text-[0.688rem] text-gray-500 text-right w-full",
292
- children: [formattedDuration, ", ", adults + children, ' ', adults + children === 1 ? 'guest' : 'guests']
293
- }), jsxs("div", {
294
- className: "flex flex-col items-end space-y-0 w-full",
295
- children: [item.preferences?.property?.pricing?.price?.price_breakdown?.details?.summary?.total !== item.preferences?.property?.pricing?.price?.price_breakdown?.details?.summary?.totalBeforeDiscount && jsxs("div", {
296
- className: "flex items-center group relative",
297
- children: [jsx("span", {
298
- className: "text-xs text-gray-500",
299
- children: "from"
300
- }), jsx("span", {
301
- className: "text-sm font-semibold text-gray-500 line-through ml-1 cursor-help hover:text-gray-600 group-hover:text-gray-600",
302
- children: item.preferences?.property?.pricing?.price?.price_breakdown?.details?.summary?.totalBeforeDiscount
303
- }), jsx("div", {
304
- className: "hidden group-hover:block absolute top-0 right-0 transform -translate-y-full mt-2 w-[300px] shadow-lg bg-white rounded-md p-4 z-50",
305
- children: jsxs("div", {
306
- className: "flex flex-col space-y-2",
307
- children: [item.preferences?.property?.pricing?.price?.price_breakdown?.details?.discounts?.items.map((charge, index) => jsxs("div", {
308
- className: "flex flex-col",
309
- children: [jsxs("div", {
310
- className: "flex justify-between",
311
- children: [jsx("span", {
312
- className: "mr-4",
313
- children: charge.name
314
- }), jsx("span", {
315
- className: "font-medium",
316
- children: charge?.amount_rounded
317
- })]
318
- }), charge.details && jsx("span", {
319
- className: "text-sm font-normal",
320
- children: charge?.details
321
- })]
322
- }, index)), jsxs("div", {
323
- className: "flex justify-between pt-2 border-t border-gray-200 font-bold",
324
- children: [jsx("span", {
325
- children: "Total discount"
326
- }), jsx("span", {
327
- children: item.preferences?.property?.pricing?.price?.price_breakdown?.details?.summary?.savings
328
- })]
329
- })]
330
- })
331
- })]
332
- }), jsxs("div", {
333
- className: "relative group",
334
- children: [jsx("span", {
335
- className: "text-2xl font-semibold text-right underline cursor-help",
336
- children: item.preferences?.property?.pricing?.price?.price_breakdown?.details?.summary?.total
337
- }), jsxs("div", {
338
- className: "hidden group-hover:block absolute bottom-0 right-0 transform translate-y-full mt-2 w-[300px] shadow-lg bg-white rounded-md z-50",
339
- children: [jsx("div", {
340
- className: "font-bold border-b border-gray-200 p-3 text-center",
341
- children: "Price breakdown"
342
- }), jsx("div", {
343
- className: "p-4",
344
- children: jsx("div", {
345
- className: "flex flex-col space-y-2",
346
- children: item.preferences?.property?.pricing?.price?.price_breakdown?.details?.charges?.items?.map((item, index) => jsxs("div", {
347
- className: "flex justify-between",
348
- children: [jsx("span", {
349
- children: item.name
350
- }), jsx("span", {
351
- children: item?.amount_rounded
352
- })]
353
- }, index))
354
- })
355
- })]
356
- })]
357
- })]
358
- }), jsxs("span", {
359
- className: "text-xs text-gray-500 text-right w-full",
360
- children: [item?.preferences?.property?.pricing?.price?.price_breakdown?.details?.pricing?.basePrice?.perNight, ' ', "per ", getPriceType(item)]
361
- })]
362
- }), jsx("button", {
363
- className: "bg-blue-500 hover:bg-blue-600 text-white font-semibold py-2 px-4 rounded w-full",
364
- onClick: () => {
365
- window.open(generateHref(item, checkIn, checkOut, adults, children), '_blank');
366
- },
367
- children: "View deal"
368
- })]
369
- })]
370
- })]
371
- })
372
- })]
373
- }, item.id)
374
- });
375
- };export{PropertyCard};//# sourceMappingURL=PropertyCard.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PropertyCard.js","sources":["../../../src/components/UI/PropertyCard.tsx"],"sourcesContent":[null],"names":["_jsxs","_jsx"],"mappings":"03BAqCA,MAAM,gBAAgB,GAAG,IAAC,IAAwB;AAC9C,EAAA,OAAA,IAAW,CAAA,WAAA,EAAA,CAAA,OAAA,CAAA,eAAA,EAAA,EAAA,CAAA,CAAA,OAAA,CAAA,SAAA,EAAA,GAAA,CAAA,CAAA,OAAA,CAAA,KAAA,EAAA,GAAA,CAAA;AACN,CAAA;AACA,MAAA,YAAQ,GAAA,CAAA,IAAA,EAAA,IAAe,EAAE,EAAE,EAAC,MAAA,EAAA,QAAA,KAAA;AAC5B,EAAA,QAAA,IAAA,CAAA,UAAQ;AACR,IAAA,KAAA,gBAAe;AACxB,MAAE,OAAA,CAAA,6BAAA,EAAA,IAAA,CAAA,EAAA,CAAA,UAAA,EAAA,IAAA,CAAA,WAAA,EAAA,EAAA,CAAA,QAAA,EAAA,MAAA,GAAA,QAAA,IAAA,CAAA,CAAA,CAAA;AAEF,IAAA,KAAkB,iBAAQ;AACtB,MAAA,OAAY,CAAA,8BAAc,EAAA,IAAA,CAAA,OAAA,CAAA,IAAA,CAAA,KAAA,CAAA,OAAA,CAAA,EAAA,CAAA,CAAA,EAAA,gBAAA,CAAA,IAAA,CAAA,IAAA,CAAA,CAAA,KAAA,CAAA;AACtB,IAAA,KAAA,mBAAqB;AACjB,MAAA,MAAA,UAAuC,GAAA,IAAA,CAAA,QAAA,EAAA,IAAA;AAG3C,MAAA,MAAA,MAAsB,GAAA,IAAA,EAAA,QAA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AA,EAAA,WAAA,EAAA,QAAA,EAAK,SAAK;AACb,EAAA,MAAA,cAAA,GAAA,SAAA,GAAA,MAAA,CAAA,OAAA,CAAA,SAEI,CAAA,EAAA,OAAA,CAAA,CAAA,CAAA,GAAS,EAAC,KAAA,CAAA,KAAA;AAgIH,IAAA,MAAA,gBAAA,GAAA,MAAA,CAAA,OAAA,CAAA,KAAA,IAAA,EAAA,CAAA,EAAA,MAAA,CAAA,CAAE,CAAK,IAAA,EAAA,MAAA,CAAA,KAAA,MAAA,EAAA,MAAA,IAAA,MAAA,EAAA,IAAA,CAAA;;AAEH,IAAA,OAAA,kBAAA,CAAA,MAAA,GAAA,CAAA,GAAA,kBAAA,CAAA,GAAA,CAAA,CAAA,CAAA,IAAS,EAAA,MAAqB,CAAA,KAAA,iBAClC,CAAA;;AAgC4B,MAAA,KAAA,EAAA;;;AAkDhC,QAAA,CAAA,EAAA;AACJ;AAWpC,KAAE,CAAA,CAAA,GAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,10 +0,0 @@
1
- import { Options } from '@cdmbase/react-splide';
2
- type PropertyCardOnMapProps = {
3
- room: any;
4
- isSaved: boolean;
5
- sliderOptions?: Options;
6
- className?: string;
7
- };
8
- export declare const PropertyCardOnMap: ({ room, isSaved, sliderOptions, className, ...props }: PropertyCardOnMapProps) => import("react/jsx-runtime").JSX.Element;
9
- export {};
10
- //# sourceMappingURL=PropertyCardOnMap.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PropertyCardOnMap.d.ts","sourceRoot":"","sources":["../../../src/components/UI/PropertyCardOnMap.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,OAAO,EAAuB,MAAM,uBAAuB,CAAC;AAIrE,KAAK,sBAAsB,GAAG;IAC1B,IAAI,EAAE,GAAG,CAAC;IACV,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAAI,uDAM/B,sBAAsB,4CA0FxB,CAAC"}
@@ -1,108 +0,0 @@
1
- import {jsxs,jsx}from'react/jsx-runtime';import {useMemo,useState,useEffect}from'react';import {useTranslation}from'react-i18next';import {Link}from'@remix-run/react';import {BsStarFill}from'@react-icons/all-files/bs/BsStarFill.js';import {Splide,SplideSlide}from'@cdmbase/react-splide';import {useLayoutSettings}from'@admin-layout/client';const PropertyCardOnMap = ({
2
- room,
3
- isSaved,
4
- sliderOptions = {},
5
- className = '',
6
- ...props
7
- }) => {
8
- const images = useMemo(() => room?.images?.data.map(({
9
- url
10
- }) => ({
11
- src: url
12
- })), [room]);
13
- const {
14
- t
15
- } = useTranslation();
16
- const {
17
- settings
18
- } = useLayoutSettings();
19
- const [star, setStar] = useState(0);
20
- useEffect(() => {
21
- let temp = room?.totalReview == 0 ? 0 : room?.totalStar / room?.totalReview;
22
- setStar(temp);
23
- }, [room?.totalReview, room?.totalStar]);
24
- // const { color, grayColor } = useColorTheme();
25
- return jsxs("div", {
26
- className: `flex flex-col flex-wrap mt-4 ${className}`,
27
- children: [jsx("div", {
28
- className: "w-full",
29
- children: jsxs(Splide, {
30
- "aria-label": t('property.property_images'),
31
- options: {
32
- type: 'loop',
33
- drag: 'free',
34
- height: '230px',
35
- perPage: 1,
36
- perMove: 1,
37
- wheel: true,
38
- releaseWheel: true,
39
- pagination: false,
40
- speed: 500,
41
- ...sliderOptions
42
- },
43
- children: [images && images.length == 0 && jsx(SplideSlide, {
44
- children: jsx("div", {
45
- className: "w-full h-full",
46
- children: jsx("img", {
47
- src: room.thumbnailUrl,
48
- className: "w-full h-full object-cover cursor-pointer transition-all duration-500 hover:brightness-50",
49
- loading: "lazy",
50
- alt: room.title || 'Property'
51
- })
52
- })
53
- }), images.map((image, i) => {
54
- return jsx(SplideSlide, {
55
- children: jsx(Link, {
56
- to: '/property/' + room.id,
57
- className: "w-full",
58
- children: jsx("div", {
59
- className: "w-full h-full",
60
- children: jsx("img", {
61
- src: image.src,
62
- className: "w-full h-full object-cover cursor-pointer transition-all duration-500 hover:brightness-50",
63
- loading: "lazy",
64
- alt: room.title || 'Property'
65
- })
66
- })
67
- })
68
- }, 'sliderImage1_' + i);
69
- })]
70
- })
71
- }), jsxs("div", {
72
- className: "w-full flex flex-col mt-2",
73
- children: [jsx("div", {
74
- className: "font-semibold text-sm",
75
- style: {
76
- color: settings?.primaryColor
77
- },
78
- children: room?.title
79
- }), jsxs("div", {
80
- className: "flex flex-row justify-between",
81
- children: [jsxs("div", {
82
- className: "flex flex-col",
83
- children: [jsx("div", {
84
- className: "mt-1 flex text-[9px] font-semibold",
85
- style: {
86
- color: settings?.primaryColor
87
- },
88
- children: room?.address && room?.address.city && room?.address.city.state ? room?.address.city.name + ', ' + room?.address.city.state.name : ''
89
- }), jsxs("div", {
90
- className: "flex items-center",
91
- children: [jsx(BsStarFill, {
92
- className: "text-yellow-500 w-3 h-3 mr-1"
93
- }), jsxs("span", {
94
- className: "text-[0.832rem] font-bold",
95
- style: {
96
- color: settings?.secondaryColor
97
- },
98
- children: [room?.reviewsOverview ? room.reviewsOverview.rating : 0, " (", room.reviewsOverview ? room.reviewsOverview.ratingCount : 0, " ", t('property.reviews'), ")"]
99
- })]
100
- })]
101
- }), jsx("div", {
102
- className: "text-lg font-bold mt-auto mb-[-2px]",
103
- children: room.preferences?.property?.pricing?.price?.price_breakdown?.details?.pricing?.finalPrice?.total
104
- })]
105
- })]
106
- })]
107
- });
108
- };export{PropertyCardOnMap};//# sourceMappingURL=PropertyCardOnMap.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PropertyCardOnMap.js","sources":["../../../src/components/UI/PropertyCardOnMap.tsx"],"sourcesContent":[null],"names":["_jsxs","_jsx"],"mappings":"0VAkBa,iBAAiB,GAAG,CAAC;AAO9B,EAAA,IAAA;AACA,EAAA,OAAA;AACA,EAAA,aAAgB,GAAA,EAAA;WAET,GAAI,EAAA;KACF;;QAEL,MAAO,GAAK,OAAE,CAAA,MAAA,IAAA,EAAA,MAAA,EAAA,IAAA,CAAA,GAAA,CAAA,CAAA;IAClB;SAEgD;IAEhD,GAAO,EAAA;AAMa,GAAA,CAAA,CAAA,EAAA,CAAA,IAAA,CAAA,CAAA;AACA,EAAA,MAAA;AACA,IAAA;AACA,GAAA,GAAA,cAAA,EAAA;AACA,EAAA,MAAA;AACA,IAAA;AACA,GAAA,GAAA,iBAAA,EAAA;AACA,EAAA,MAAA,CAAA,IAAA,EAAA,OAAA,CAAA,GAAA,QAAU,EAAE,CAAK;AACjB,EAAA,SAAA,CAAA,MAAA;AACA,IAAA,IAAA,IAAA,GAAA,IAAA,EAAA,WAAgB,IAAA,CAAA,GAAA,CAAA,GAAA,IAAA,EAAA,SAAA,GAAA,IAAA,EAAA,WAAA;;6BAgBT,EAAA,SACF,CAAA,CAAA;AAaT;AAWY,EAAA,OAAAA,IAAA,CAAA,KAAA,EAAA;6CACC;AAaD,IAAA,QAAA,EAAA,CAAAC,GAAA,CAAA,KAAA,EAAA;AAOhC,MAAE,SAAA,EAAA,QAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,8 +0,0 @@
1
- import React from 'react';
2
- import { CarPricing } from './types';
3
- interface PricePopoverProps {
4
- pricing: CarPricing;
5
- }
6
- declare const PricePopover: React.FC<PricePopoverProps>;
7
- export default PricePopover;
8
- //# sourceMappingURL=PricePopover.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PricePopover.d.ts","sourceRoot":"","sources":["../../../../src/components/UI/VehicleCard/PricePopover.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,UAAU,iBAAiB;IACvB,OAAO,EAAE,UAAU,CAAC;CACvB;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CAyF7C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1,98 +0,0 @@
1
- import {jsxs,Fragment,jsx}from'react/jsx-runtime';import {useState,useRef,useEffect}from'react';import {BiTag}from'@react-icons/all-files/bi/BiTag.js';const PricePopover = ({
2
- pricing
3
- }) => {
4
- const [position, setPosition] = useState({
5
- top: 0,
6
- left: 0
7
- });
8
- const popoverRef = useRef(null);
9
- const triggerRef = useRef(null);
10
- useEffect(() => {
11
- const updatePosition = () => {
12
- if (!popoverRef.current || !triggerRef.current) return;
13
- const trigger = triggerRef.current.getBoundingClientRect();
14
- const popover = popoverRef.current.getBoundingClientRect();
15
- const viewport = {
16
- width: window.innerWidth,
17
- height: window.innerHeight
18
- };
19
- let top = trigger.bottom + 8;
20
- let left = trigger.left;
21
- if (top + popover.height > viewport.height) {
22
- top = trigger.top - popover.height - 8;
23
- }
24
- if (left + popover.width > viewport.width) {
25
- left = viewport.width - popover.width - 16;
26
- }
27
- left = Math.max(16, left);
28
- setPosition({
29
- top,
30
- left
31
- });
32
- };
33
- updatePosition();
34
- window.addEventListener('scroll', updatePosition);
35
- window.addEventListener('resize', updatePosition);
36
- return () => {
37
- window.removeEventListener('scroll', updatePosition);
38
- window.removeEventListener('resize', updatePosition);
39
- };
40
- }, []);
41
- return jsxs(Fragment, {
42
- children: [jsx("div", {
43
- ref: triggerRef,
44
- className: "absolute inset-0"
45
- }), jsx("div", {
46
- ref: popoverRef,
47
- style: {
48
- top: position.top,
49
- left: position.left,
50
- position: 'fixed'
51
- },
52
- className: "invisible group-hover:visible opacity-0 group-hover:opacity-100 transition-all duration-200 bg-white rounded-lg shadow-xl border border-gray-100 p-4 min-w-[280px] z-50",
53
- children: jsxs("div", {
54
- className: "flex flex-col gap-3",
55
- children: [jsxs("div", {
56
- className: "flex items-center justify-between text-[15px]",
57
- children: [jsx("span", {
58
- className: "text-gray-600",
59
- children: "Base rate"
60
- }), jsxs("span", {
61
- className: "font-medium",
62
- children: [pricing.currency, " ", pricing.amount]
63
- })]
64
- }), pricing.discount && jsxs("div", {
65
- className: "flex items-center justify-between text-green-600",
66
- children: [jsxs("div", {
67
- className: "flex items-center",
68
- children: [jsx(BiTag, {
69
- className: "h-4 w-4 mr-1"
70
- }), jsx("span", {
71
- children: "Discount"
72
- })]
73
- }), jsxs("span", {
74
- children: ["-", pricing.discount]
75
- })]
76
- }), jsx("div", {
77
- className: "border-t border-gray-200 mt-1 pt-3",
78
- children: jsxs("div", {
79
- className: "flex items-center justify-between",
80
- children: [jsxs("span", {
81
- className: "font-medium text-[15px]",
82
- children: ["Total ", pricing.period && `(${pricing.period})`]
83
- }), jsxs("div", {
84
- className: "text-right",
85
- children: [jsxs("span", {
86
- className: "text-xl font-semibold",
87
- children: [pricing.currency, " ", pricing.amount]
88
- }), pricing.beforeTaxes && jsx("div", {
89
- className: "text-sm text-gray-500",
90
- children: "before taxes"
91
- })]
92
- })]
93
- })
94
- })]
95
- })
96
- })]
97
- });
98
- };export{PricePopover as default};//# sourceMappingURL=PricePopover.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PricePopover.js","sources":["../../../../src/components/UI/VehicleCard/PricePopover.tsx"],"sourcesContent":[null],"names":[],"mappings":"uJAQA,MAAM,YAAY,GAAgC,CAAC;AAC/C,EAAA;AACA,CAAA,KAAA;AACA,EAAA,MAAA,CAAA,qBAA0C,CAAA,GAAI,QAAE,CAAA;IAEhD,GAAS,EAAA,CAAA;QACL,EAAM;;kBACqD,GAAA,MAAA,CAAA,IAAA,CAA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
- label: string;
4
- }
5
- declare const VehicleBadge: React.FC<CardBadgeProps>;
6
- export default VehicleBadge;
7
- //# sourceMappingURL=VehicleBadge.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"VehicleBadge.d.ts","sourceRoot":"","sources":["../../../../src/components/UI/VehicleCard/VehicleBadge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,UAAU,cAAc;IACpB,KAAK,EAAE,MAAM,CAAC;CACjB;AAED,QAAA,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,cAAc,CAY1C,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1,9 +0,0 @@
1
- import React, { ReactNode } from 'react';
2
- interface CardFeatureProps {
3
- icon: ReactNode;
4
- label: string;
5
- iconColor?: string;
6
- }
7
- declare const VehicleFeature: React.FC<CardFeatureProps>;
8
- export default VehicleFeature;
9
- //# sourceMappingURL=VehicleFeature.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"VehicleFeature.d.ts","sourceRoot":"","sources":["../../../../src/components/UI/VehicleCard/VehicleFeature.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGzC,UAAU,gBAAgB;IACtB,IAAI,EAAE,SAAS,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,QAAA,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAiB9C,CAAC;AAEF,eAAe,cAAc,CAAC"}