@tui-cruises/mein-schiff-web-react-component-library 2.0.0-rc.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 (556) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/LICENSE +14 -0
  3. package/README.md +26 -0
  4. package/custom.d.ts +14 -0
  5. package/icons/icons/360.tsx +20 -0
  6. package/icons/icons/add-circle.tsx +26 -0
  7. package/icons/icons/airplane.tsx +20 -0
  8. package/icons/icons/anchor.tsx +20 -0
  9. package/icons/icons/angle-tool.tsx +26 -0
  10. package/icons/icons/arrow-down.tsx +20 -0
  11. package/icons/icons/arrow-left.tsx +20 -0
  12. package/icons/icons/arrow-right.tsx +20 -0
  13. package/icons/icons/at.tsx +20 -0
  14. package/icons/icons/baggage.tsx +20 -0
  15. package/icons/icons/balcony.tsx +20 -0
  16. package/icons/icons/bathroom.tsx +32 -0
  17. package/icons/icons/beach.tsx +20 -0
  18. package/icons/icons/bed.tsx +26 -0
  19. package/icons/icons/bell.tsx +20 -0
  20. package/icons/icons/bording.tsx +20 -0
  21. package/icons/icons/cabins.tsx +20 -0
  22. package/icons/icons/calendar.tsx +32 -0
  23. package/icons/icons/cancel.tsx +20 -0
  24. package/icons/icons/cash.tsx +44 -0
  25. package/icons/icons/check-circle.tsx +18 -0
  26. package/icons/icons/check.tsx +20 -0
  27. package/icons/icons/circle.tsx +20 -0
  28. package/icons/icons/clear.tsx +24 -0
  29. package/icons/icons/clock-rotate-right.tsx +20 -0
  30. package/icons/icons/clock.tsx +26 -0
  31. package/icons/icons/cloud-sunny.tsx +43 -0
  32. package/icons/icons/cloud.tsx +20 -0
  33. package/icons/icons/compass.tsx +26 -0
  34. package/icons/icons/delete-circle.tsx +26 -0
  35. package/icons/icons/departure.tsx +20 -0
  36. package/icons/icons/details.tsx +20 -0
  37. package/icons/icons/diamond.tsx +20 -0
  38. package/icons/icons/edit-pencil.tsx +20 -0
  39. package/icons/icons/excellence.tsx +20 -0
  40. package/icons/icons/expand.tsx +20 -0
  41. package/icons/icons/eye-closed.tsx +20 -0
  42. package/icons/icons/eye-empty.tsx +26 -0
  43. package/icons/icons/eye-off.tsx +32 -0
  44. package/icons/icons/eye.tsx +26 -0
  45. package/icons/icons/fallback.tsx +26 -0
  46. package/icons/icons/filter.tsx +20 -0
  47. package/icons/icons/flag.tsx +20 -0
  48. package/icons/icons/fog.tsx +22 -0
  49. package/icons/icons/glases.tsx +28 -0
  50. package/icons/icons/group.tsx +32 -0
  51. package/icons/icons/heart-filled.tsx +20 -0
  52. package/icons/icons/heart.tsx +20 -0
  53. package/icons/icons/help-circle.tsx +24 -0
  54. package/icons/icons/home.tsx +22 -0
  55. package/icons/icons/humidity.tsx +30 -0
  56. package/icons/icons/impressions.tsx +20 -0
  57. package/icons/icons/inclusive-services.tsx +20 -0
  58. package/icons/icons/index.ts +141 -0
  59. package/icons/icons/info-empty.tsx +26 -0
  60. package/icons/icons/language.tsx +20 -0
  61. package/icons/icons/lifebuoy.tsx +30 -0
  62. package/icons/icons/loading.tsx +18 -0
  63. package/icons/icons/location.tsx +24 -0
  64. package/icons/icons/log-in.tsx +26 -0
  65. package/icons/icons/log-out.tsx +26 -0
  66. package/icons/icons/mail-open.tsx +20 -0
  67. package/icons/icons/map.tsx +20 -0
  68. package/icons/icons/maps-arrow-diagonal.tsx +20 -0
  69. package/icons/icons/media-image-list.tsx +32 -0
  70. package/icons/icons/menu.tsx +21 -0
  71. package/icons/icons/metropolis.tsx +20 -0
  72. package/icons/icons/minus.tsx +20 -0
  73. package/icons/icons/more-horiz.tsx +35 -0
  74. package/icons/icons/more-vert.tsx +35 -0
  75. package/icons/icons/mostly-cloudy-night.tsx +24 -0
  76. package/icons/icons/ms-ship.tsx +20 -0
  77. package/icons/icons/music.tsx +20 -0
  78. package/icons/icons/nav-arrow-down.tsx +20 -0
  79. package/icons/icons/nav-arrow-left.tsx +20 -0
  80. package/icons/icons/nav-arrow-right.tsx +20 -0
  81. package/icons/icons/nav-arrow-up.tsx +20 -0
  82. package/icons/icons/no-wifi.tsx +18 -0
  83. package/icons/icons/old-trips.tsx +20 -0
  84. package/icons/icons/percentage.tsx +20 -0
  85. package/icons/icons/phone.tsx +20 -0
  86. package/icons/icons/pin.tsx +20 -0
  87. package/icons/icons/play.tsx +20 -0
  88. package/icons/icons/plus-circle.tsx +20 -0
  89. package/icons/icons/plus.tsx +20 -0
  90. package/icons/icons/point.tsx +15 -0
  91. package/icons/icons/rain.tsx +22 -0
  92. package/icons/icons/receipt.tsx +20 -0
  93. package/icons/icons/refresh-double.tsx +32 -0
  94. package/icons/icons/search.tsx +26 -0
  95. package/icons/icons/security-pass.tsx +26 -0
  96. package/icons/icons/settings.tsx +20 -0
  97. package/icons/icons/share-ios.tsx +26 -0
  98. package/icons/icons/ship-account.tsx +20 -0
  99. package/icons/icons/ship-info.tsx +20 -0
  100. package/icons/icons/ship-position.tsx +27 -0
  101. package/icons/icons/shooting-stars.tsx +28 -0
  102. package/icons/icons/sleet.tsx +22 -0
  103. package/icons/icons/snow-flake.tsx +20 -0
  104. package/icons/icons/snow.tsx +22 -0
  105. package/icons/icons/sofa.tsx +32 -0
  106. package/icons/icons/star-dashed.tsx +20 -0
  107. package/icons/icons/star-filled.tsx +25 -0
  108. package/icons/icons/star-half-dashed.tsx +26 -0
  109. package/icons/icons/star.tsx +20 -0
  110. package/icons/icons/substract.tsx +26 -0
  111. package/icons/icons/sun-light.tsx +42 -0
  112. package/icons/icons/temperature-high.tsx +26 -0
  113. package/icons/icons/thunderstorm.tsx +26 -0
  114. package/icons/icons/tornado.tsx +18 -0
  115. package/icons/icons/trash.tsx +20 -0
  116. package/icons/icons/travel-assistant.tsx +24 -0
  117. package/icons/icons/tropical-storm.tsx +71 -0
  118. package/icons/icons/upcoming-trips.tsx +27 -0
  119. package/icons/icons/user.tsx +26 -0
  120. package/icons/icons/warning-circle.tsx +26 -0
  121. package/icons/icons/warning-hexagon.tsx +26 -0
  122. package/icons/icons/weather.tsx +20 -0
  123. package/icons/icons/wifi.tsx +20 -0
  124. package/icons/icons/wind.tsx +22 -0
  125. package/icons/icons/windrose.tsx +42 -0
  126. package/icons/icons/windsock.tsx +20 -0
  127. package/icons/pictograms/24h-meals.tsx +25 -0
  128. package/icons/pictograms/ad-template.tsx +23 -0
  129. package/icons/pictograms/add.tsx +25 -0
  130. package/icons/pictograms/adventure-club-only.tsx +25 -0
  131. package/icons/pictograms/allergy.tsx +30 -0
  132. package/icons/pictograms/anchor.tsx +23 -0
  133. package/icons/pictograms/arrival.tsx +23 -0
  134. package/icons/pictograms/baby-awake.tsx +20 -0
  135. package/icons/pictograms/baby-monitor.tsx +20 -0
  136. package/icons/pictograms/baby-sleep.tsx +20 -0
  137. package/icons/pictograms/baggage-information.tsx +23 -0
  138. package/icons/pictograms/baggage.tsx +23 -0
  139. package/icons/pictograms/bedroom-check.tsx +23 -0
  140. package/icons/pictograms/bedroom.tsx +23 -0
  141. package/icons/pictograms/beverages.tsx +28 -0
  142. package/icons/pictograms/billboard.tsx +23 -0
  143. package/icons/pictograms/blog.tsx +23 -0
  144. package/icons/pictograms/brochure.tsx +23 -0
  145. package/icons/pictograms/calendar-check.tsx +18 -0
  146. package/icons/pictograms/calendar-default.tsx +18 -0
  147. package/icons/pictograms/calendar-disabled.tsx +18 -0
  148. package/icons/pictograms/calendar-focus.tsx +25 -0
  149. package/icons/pictograms/champagne-glasses.tsx +25 -0
  150. package/icons/pictograms/check.tsx +25 -0
  151. package/icons/pictograms/checklist-check.tsx +18 -0
  152. package/icons/pictograms/checklist.tsx +21 -0
  153. package/icons/pictograms/checkmark.tsx +23 -0
  154. package/icons/pictograms/chef-hat.tsx +30 -0
  155. package/icons/pictograms/chevron-down.tsx +25 -0
  156. package/icons/pictograms/chevron-up.tsx +25 -0
  157. package/icons/pictograms/circles.tsx +25 -0
  158. package/icons/pictograms/cleaning-trolley.tsx +30 -0
  159. package/icons/pictograms/clock-0-30.tsx +23 -0
  160. package/icons/pictograms/clock-0.tsx +23 -0
  161. package/icons/pictograms/clock-1-30.tsx +23 -0
  162. package/icons/pictograms/clock-1.tsx +23 -0
  163. package/icons/pictograms/clock-10-30.tsx +23 -0
  164. package/icons/pictograms/clock-10.tsx +23 -0
  165. package/icons/pictograms/clock-11-30.tsx +23 -0
  166. package/icons/pictograms/clock-11.tsx +23 -0
  167. package/icons/pictograms/clock-2-30.tsx +23 -0
  168. package/icons/pictograms/clock-2.tsx +23 -0
  169. package/icons/pictograms/clock-3-30.tsx +23 -0
  170. package/icons/pictograms/clock-3.tsx +23 -0
  171. package/icons/pictograms/clock-4-30.tsx +23 -0
  172. package/icons/pictograms/clock-4.tsx +23 -0
  173. package/icons/pictograms/clock-5-30.tsx +23 -0
  174. package/icons/pictograms/clock-5.tsx +23 -0
  175. package/icons/pictograms/clock-6-30.tsx +23 -0
  176. package/icons/pictograms/clock-6.tsx +23 -0
  177. package/icons/pictograms/clock-7-30.tsx +23 -0
  178. package/icons/pictograms/clock-7.tsx +23 -0
  179. package/icons/pictograms/clock-8-30.tsx +23 -0
  180. package/icons/pictograms/clock-8.tsx +23 -0
  181. package/icons/pictograms/clock-9-30.tsx +23 -0
  182. package/icons/pictograms/clock-9.tsx +23 -0
  183. package/icons/pictograms/clock-default.tsx +23 -0
  184. package/icons/pictograms/close.tsx +25 -0
  185. package/icons/pictograms/clothing.tsx +23 -0
  186. package/icons/pictograms/cloud.tsx +23 -0
  187. package/icons/pictograms/cocktails.tsx +23 -0
  188. package/icons/pictograms/coffee-machine.tsx +23 -0
  189. package/icons/pictograms/compass.tsx +23 -0
  190. package/icons/pictograms/couple.tsx +25 -0
  191. package/icons/pictograms/crew-love.tsx +28 -0
  192. package/icons/pictograms/crown.tsx +23 -0
  193. package/icons/pictograms/dart.tsx +23 -0
  194. package/icons/pictograms/decoration.tsx +23 -0
  195. package/icons/pictograms/departure-check.tsx +25 -0
  196. package/icons/pictograms/departure-germany.tsx +20 -0
  197. package/icons/pictograms/departure-time.tsx +35 -0
  198. package/icons/pictograms/departure.tsx +23 -0
  199. package/icons/pictograms/diamond.tsx +23 -0
  200. package/icons/pictograms/discount-card.tsx +35 -0
  201. package/icons/pictograms/discount.tsx +30 -0
  202. package/icons/pictograms/documents.tsx +23 -0
  203. package/icons/pictograms/download-document.tsx +23 -0
  204. package/icons/pictograms/download.tsx +23 -0
  205. package/icons/pictograms/dripping-dew.tsx +23 -0
  206. package/icons/pictograms/dumbbell.tsx +25 -0
  207. package/icons/pictograms/early-bird.tsx +23 -0
  208. package/icons/pictograms/edit.tsx +23 -0
  209. package/icons/pictograms/energy-saving.tsx +23 -0
  210. package/icons/pictograms/enjoyer-club-only.tsx +18 -0
  211. package/icons/pictograms/environment.tsx +30 -0
  212. package/icons/pictograms/environmental-officer.tsx +30 -0
  213. package/icons/pictograms/explorer-club-only.tsx +18 -0
  214. package/icons/pictograms/family.tsx +25 -0
  215. package/icons/pictograms/fb-community.tsx +25 -0
  216. package/icons/pictograms/finance.tsx +25 -0
  217. package/icons/pictograms/fog.tsx +25 -0
  218. package/icons/pictograms/food-certificate.tsx +30 -0
  219. package/icons/pictograms/gastronomy.tsx +25 -0
  220. package/icons/pictograms/gift.tsx +23 -0
  221. package/icons/pictograms/globetrotter-club-only.tsx +18 -0
  222. package/icons/pictograms/hairdresser.tsx +20 -0
  223. package/icons/pictograms/handbag.tsx +30 -0
  224. package/icons/pictograms/hands-holding-heart.tsx +30 -0
  225. package/icons/pictograms/heart-beat.tsx +29 -0
  226. package/icons/pictograms/heart.tsx +23 -0
  227. package/icons/pictograms/home.tsx +23 -0
  228. package/icons/pictograms/hospital-cross.tsx +23 -0
  229. package/icons/pictograms/hot-dish.tsx +23 -0
  230. package/icons/pictograms/hot-drink.tsx +25 -0
  231. package/icons/pictograms/human-heart.tsx +30 -0
  232. package/icons/pictograms/human-holding-heart.tsx +30 -0
  233. package/icons/pictograms/human-open-arms.tsx +23 -0
  234. package/icons/pictograms/human-profile.tsx +23 -0
  235. package/icons/pictograms/human-swimming.tsx +25 -0
  236. package/icons/pictograms/ice-cream.tsx +23 -0
  237. package/icons/pictograms/important.tsx +23 -0
  238. package/icons/pictograms/index.ts +285 -0
  239. package/icons/pictograms/information.tsx +30 -0
  240. package/icons/pictograms/internet.tsx +23 -0
  241. package/icons/pictograms/jogging.tsx +21 -0
  242. package/icons/pictograms/kid-playing.tsx +23 -0
  243. package/icons/pictograms/life-jacket.tsx +21 -0
  244. package/icons/pictograms/lifebuoy.tsx +20 -0
  245. package/icons/pictograms/lightbulb.tsx +23 -0
  246. package/icons/pictograms/lightning.tsx +23 -0
  247. package/icons/pictograms/location-mark.tsx +30 -0
  248. package/icons/pictograms/log-in.tsx +23 -0
  249. package/icons/pictograms/long-term-trips.tsx +20 -0
  250. package/icons/pictograms/lotte-chatbot.tsx +28 -0
  251. package/icons/pictograms/lotte-mail.tsx +28 -0
  252. package/icons/pictograms/mail-at.tsx +23 -0
  253. package/icons/pictograms/mail-information.tsx +23 -0
  254. package/icons/pictograms/mailbox.tsx +23 -0
  255. package/icons/pictograms/many-sea-days.tsx +20 -0
  256. package/icons/pictograms/medal.tsx +23 -0
  257. package/icons/pictograms/microphone.tsx +23 -0
  258. package/icons/pictograms/ms-1.tsx +23 -0
  259. package/icons/pictograms/ms-2.tsx +30 -0
  260. package/icons/pictograms/ms-3.tsx +30 -0
  261. package/icons/pictograms/ms-4.tsx +30 -0
  262. package/icons/pictograms/ms-5.tsx +30 -0
  263. package/icons/pictograms/ms-6.tsx +30 -0
  264. package/icons/pictograms/ms-7-new-eng.tsx +37 -0
  265. package/icons/pictograms/ms-7-new.tsx +30 -0
  266. package/icons/pictograms/ms-7.tsx +30 -0
  267. package/icons/pictograms/ms-default.tsx +30 -0
  268. package/icons/pictograms/ms-flow-new-eng.tsx +37 -0
  269. package/icons/pictograms/ms-flow-new.tsx +49 -0
  270. package/icons/pictograms/ms-flow.tsx +41 -0
  271. package/icons/pictograms/ms-relax-new-eng.tsx +37 -0
  272. package/icons/pictograms/ms-relax-new.tsx +36 -0
  273. package/icons/pictograms/ms-ship.tsx +23 -0
  274. package/icons/pictograms/music-book.tsx +23 -0
  275. package/icons/pictograms/my-account.tsx +22 -0
  276. package/icons/pictograms/my-trips.tsx +29 -0
  277. package/icons/pictograms/navigation-arrow.tsx +23 -0
  278. package/icons/pictograms/no-wifi.tsx +21 -0
  279. package/icons/pictograms/not-available.tsx +23 -0
  280. package/icons/pictograms/offer.tsx +23 -0
  281. package/icons/pictograms/offline.tsx +25 -0
  282. package/icons/pictograms/onboard-announcement.tsx +20 -0
  283. package/icons/pictograms/package-newspaper.tsx +27 -0
  284. package/icons/pictograms/paper-news.tsx +23 -0
  285. package/icons/pictograms/paper-plane.tsx +28 -0
  286. package/icons/pictograms/payment-check.tsx +32 -0
  287. package/icons/pictograms/payment.tsx +28 -0
  288. package/icons/pictograms/people-check.tsx +25 -0
  289. package/icons/pictograms/people.tsx +25 -0
  290. package/icons/pictograms/permanent-make-up.tsx +20 -0
  291. package/icons/pictograms/person-single.tsx +23 -0
  292. package/icons/pictograms/phone.tsx +20 -0
  293. package/icons/pictograms/play-button.tsx +20 -0
  294. package/icons/pictograms/presentation.tsx +23 -0
  295. package/icons/pictograms/price-tag.tsx +21 -0
  296. package/icons/pictograms/printer.tsx +23 -0
  297. package/icons/pictograms/rain.tsx +23 -0
  298. package/icons/pictograms/receipt.tsx +25 -0
  299. package/icons/pictograms/remove.tsx +25 -0
  300. package/icons/pictograms/safety.tsx +23 -0
  301. package/icons/pictograms/screen.tsx +23 -0
  302. package/icons/pictograms/search.tsx +23 -0
  303. package/icons/pictograms/service.tsx +23 -0
  304. package/icons/pictograms/sewage.tsx +30 -0
  305. package/icons/pictograms/ship-outstanding.tsx +23 -0
  306. package/icons/pictograms/ship-transfer.tsx +23 -0
  307. package/icons/pictograms/shooting-stars.tsx +23 -0
  308. package/icons/pictograms/shore-excursions-old.tsx +23 -0
  309. package/icons/pictograms/shore-excursions.tsx +32 -0
  310. package/icons/pictograms/short-notice-departures.tsx +20 -0
  311. package/icons/pictograms/short-trips.tsx +21 -0
  312. package/icons/pictograms/size.tsx +23 -0
  313. package/icons/pictograms/smartphone.tsx +23 -0
  314. package/icons/pictograms/smiley.tsx +23 -0
  315. package/icons/pictograms/social-media.tsx +37 -0
  316. package/icons/pictograms/spa-balcony-cabin.tsx +43 -0
  317. package/icons/pictograms/speech-bubble-faq.tsx +23 -0
  318. package/icons/pictograms/speech-bubble-hello.tsx +23 -0
  319. package/icons/pictograms/speech-bubble-ok.tsx +30 -0
  320. package/icons/pictograms/speedboat.tsx +23 -0
  321. package/icons/pictograms/star-cancel.tsx +23 -0
  322. package/icons/pictograms/star-check.tsx +23 -0
  323. package/icons/pictograms/star-plus.tsx +23 -0
  324. package/icons/pictograms/star.tsx +23 -0
  325. package/icons/pictograms/sun-cloud.tsx +23 -0
  326. package/icons/pictograms/sun-lounger.tsx +23 -0
  327. package/icons/pictograms/sun.tsx +23 -0
  328. package/icons/pictograms/theater-mask.tsx +35 -0
  329. package/icons/pictograms/thermometer.tsx +23 -0
  330. package/icons/pictograms/tickets.tsx +21 -0
  331. package/icons/pictograms/towels.tsx +23 -0
  332. package/icons/pictograms/transportation.tsx +30 -0
  333. package/icons/pictograms/travel-protection-check.tsx +23 -0
  334. package/icons/pictograms/travel-protection.tsx +23 -0
  335. package/icons/pictograms/video.tsx +23 -0
  336. package/icons/pictograms/waste-management.tsx +30 -0
  337. package/icons/pictograms/webinar.tsx +23 -0
  338. package/icons/pictograms/wheel-of-fortune.tsx +23 -0
  339. package/icons/pictograms/wifi.tsx +20 -0
  340. package/icons/pictograms/wind.tsx +25 -0
  341. package/index.tsx +73 -0
  342. package/package.json +119 -0
  343. package/public/favicon-16x16.png +0 -0
  344. package/public/favicon-32x32.png +0 -0
  345. package/public/videos/placeholder.mp4 +0 -0
  346. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_It.ttf +0 -0
  347. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_It.woff +0 -0
  348. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_It.woff2 +0 -0
  349. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_Rg.ttf +0 -0
  350. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_Rg.woff +0 -0
  351. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_Rg.woff2 +0 -0
  352. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBd.ttf +0 -0
  353. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBd.woff +0 -0
  354. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBd.woff2 +0 -0
  355. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBdIt.ttf +0 -0
  356. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBdIt.woff +0 -0
  357. package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBdIt.woff2 +0 -0
  358. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.eot +0 -0
  359. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.svg +338 -0
  360. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.ttf +0 -0
  361. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.woff +0 -0
  362. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.woff2 +0 -0
  363. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.eot +0 -0
  364. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.svg +345 -0
  365. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.ttf +0 -0
  366. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.woff +0 -0
  367. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.woff2 +0 -0
  368. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.eot +0 -0
  369. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.svg +338 -0
  370. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.ttf +0 -0
  371. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.woff +0 -0
  372. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.woff2 +0 -0
  373. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.eot +0 -0
  374. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.svg +346 -0
  375. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.ttf +0 -0
  376. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.woff +0 -0
  377. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.woff2 +0 -0
  378. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.eot +0 -0
  379. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.svg +337 -0
  380. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.ttf +0 -0
  381. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.woff +0 -0
  382. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.woff2 +0 -0
  383. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.eot +0 -0
  384. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.svg +342 -0
  385. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.ttf +0 -0
  386. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.woff +0 -0
  387. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.woff2 +0 -0
  388. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.eot +0 -0
  389. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.svg +337 -0
  390. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.ttf +0 -0
  391. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.woff +0 -0
  392. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.woff2 +0 -0
  393. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.eot +0 -0
  394. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.svg +339 -0
  395. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.ttf +0 -0
  396. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.woff +0 -0
  397. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.woff2 +0 -0
  398. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.eot +0 -0
  399. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.svg +337 -0
  400. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.ttf +0 -0
  401. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.woff +0 -0
  402. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.woff2 +0 -0
  403. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.eot +0 -0
  404. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.svg +340 -0
  405. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.ttf +0 -0
  406. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.woff +0 -0
  407. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.woff2 +0 -0
  408. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.eot +0 -0
  409. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.svg +343 -0
  410. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.ttf +0 -0
  411. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.woff +0 -0
  412. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.woff2 +0 -0
  413. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.eot +0 -0
  414. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.svg +337 -0
  415. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.ttf +0 -0
  416. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.woff +0 -0
  417. package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.woff2 +0 -0
  418. package/src/assets/images/placeholder-blueish.jpg +0 -0
  419. package/src/assets/images/placeholder-sepia.jpg +0 -0
  420. package/src/assets/images/placeholder.jpg +0 -0
  421. package/src/components/core/Accordion/Accordion.tsx +228 -0
  422. package/src/components/core/Accordion/AccordionItem.tsx +72 -0
  423. package/src/components/core/Accordion/AccordionTab.tsx +39 -0
  424. package/src/components/core/Accordion/index.ts +3 -0
  425. package/src/components/core/Accordion/utils.tsx +13 -0
  426. package/src/components/core/Alert/Alert.tsx +131 -0
  427. package/src/components/core/Alert/index.ts +1 -0
  428. package/src/components/core/AlertDialog/AlertDialog.tsx +288 -0
  429. package/src/components/core/AlertDialog/index.ts +1 -0
  430. package/src/components/core/Badge/Badge.tsx +70 -0
  431. package/src/components/core/Badge/index.ts +1 -0
  432. package/src/components/core/BirthdateField/BirthdateField.tsx +269 -0
  433. package/src/components/core/BirthdateField/index.ts +1 -0
  434. package/src/components/core/Button/Button.tsx +178 -0
  435. package/src/components/core/Button/index.ts +1 -0
  436. package/src/components/core/ButtonGroup/ButtonGroup.tsx +71 -0
  437. package/src/components/core/ButtonGroup/index.ts +1 -0
  438. package/src/components/core/Calendar/Calendar.tsx +303 -0
  439. package/src/components/core/Calendar/index.ts +1 -0
  440. package/src/components/core/Checkbox/Checkbox.tsx +107 -0
  441. package/src/components/core/Checkbox/index.ts +1 -0
  442. package/src/components/core/CheckboxField/CheckboxField.tsx +156 -0
  443. package/src/components/core/CheckboxField/CheckboxFieldError.tsx +14 -0
  444. package/src/components/core/CheckboxField/CheckboxFieldLabel.tsx +25 -0
  445. package/src/components/core/CheckboxField/CheckboxFieldNote.tsx +16 -0
  446. package/src/components/core/CheckboxField/index.ts +1 -0
  447. package/src/components/core/Countdown/Countdown.tsx +67 -0
  448. package/src/components/core/Countdown/index.ts +1 -0
  449. package/src/components/core/DataTable/DataTable.tsx +98 -0
  450. package/src/components/core/DataTable/index.ts +1 -0
  451. package/src/components/core/Dialog/Dialog.tsx +443 -0
  452. package/src/components/core/Dialog/index.ts +1 -0
  453. package/src/components/core/Divider/Divider.tsx +37 -0
  454. package/src/components/core/Divider/index.ts +1 -0
  455. package/src/components/core/FavoriteButton/FavoriteButton.tsx +294 -0
  456. package/src/components/core/FavoriteButton/index.ts +1 -0
  457. package/src/components/core/Fieldset/Fieldset.tsx +42 -0
  458. package/src/components/core/Fieldset/index.ts +1 -0
  459. package/src/components/core/FormLabel/FormLabel.tsx +88 -0
  460. package/src/components/core/FormLabel/index.ts +1 -0
  461. package/src/components/core/Icon/Icon.tsx +106 -0
  462. package/src/components/core/Icon/index.ts +1 -0
  463. package/src/components/core/IconButton/IconButton.tsx +169 -0
  464. package/src/components/core/IconButton/index.ts +1 -0
  465. package/src/components/core/InputField/InputField.tsx +128 -0
  466. package/src/components/core/InputField/InputFieldError.tsx +17 -0
  467. package/src/components/core/InputField/InputFieldInput.tsx +67 -0
  468. package/src/components/core/InputField/InputFieldLabel.tsx +29 -0
  469. package/src/components/core/InputField/InputFieldNote.tsx +16 -0
  470. package/src/components/core/InputField/index.ts +1 -0
  471. package/src/components/core/LoadingSpinner/LoadingSpinner.tsx +50 -0
  472. package/src/components/core/LoadingSpinner/index.ts +1 -0
  473. package/src/components/core/Pagination/Pagination.tsx +191 -0
  474. package/src/components/core/Pagination/index.ts +1 -0
  475. package/src/components/core/PasswordField/PasswordField.tsx +187 -0
  476. package/src/components/core/PasswordField/PasswordFieldRequirementsList.tsx +78 -0
  477. package/src/components/core/PasswordField/index.ts +1 -0
  478. package/src/components/core/PhoneNumberInput/PhoneNumberInput.tsx +201 -0
  479. package/src/components/core/PhoneNumberInput/countries.json +242 -0
  480. package/src/components/core/PhoneNumberInput/index.ts +1 -0
  481. package/src/components/core/Pictogram/Pictogram.tsx +67 -0
  482. package/src/components/core/Pictogram/index.ts +1 -0
  483. package/src/components/core/Popover/Popover.tsx +61 -0
  484. package/src/components/core/Popover/index.ts +1 -0
  485. package/src/components/core/Portlist/Portlist.tsx +28 -0
  486. package/src/components/core/Portlist/index.ts +1 -0
  487. package/src/components/core/PriceInput/PriceInput.tsx +100 -0
  488. package/src/components/core/PriceInput/index.ts +1 -0
  489. package/src/components/core/QuantityItem/QuantityItem.tsx +37 -0
  490. package/src/components/core/QuantityItem/index.ts +1 -0
  491. package/src/components/core/Radio/Radio.tsx +64 -0
  492. package/src/components/core/Radio/index.ts +1 -0
  493. package/src/components/core/RadioField/RadioField.tsx +66 -0
  494. package/src/components/core/RadioField/index.ts +1 -0
  495. package/src/components/core/RadixRadio/RadixRadio.tsx +56 -0
  496. package/src/components/core/RadixRadio/index.ts +1 -0
  497. package/src/components/core/RadixSelect/RadixSelect.tsx +172 -0
  498. package/src/components/core/RadixSelect/index.ts +1 -0
  499. package/src/components/core/RangeSlider/RangeSlider.tsx +59 -0
  500. package/src/components/core/RangeSlider/index.ts +1 -0
  501. package/src/components/core/Section/Section.tsx +62 -0
  502. package/src/components/core/Section/index.ts +1 -0
  503. package/src/components/core/SegmentedControl/SegmentedControl.tsx +65 -0
  504. package/src/components/core/SegmentedControl/index.ts +1 -0
  505. package/src/components/core/Select/Select.tsx +171 -0
  506. package/src/components/core/Select/index.ts +1 -0
  507. package/src/components/core/SelectField/SelectField.tsx +67 -0
  508. package/src/components/core/SelectField/index.ts +1 -0
  509. package/src/components/core/Skeleton/Skeleton.tsx +23 -0
  510. package/src/components/core/Skeleton/SkeletonTextLines.tsx +37 -0
  511. package/src/components/core/Skeleton/index.ts +2 -0
  512. package/src/components/core/Stepper/Stepper.tsx +116 -0
  513. package/src/components/core/Stepper/index.ts +1 -0
  514. package/src/components/core/SwitchToggle/SwitchToggle.tsx +46 -0
  515. package/src/components/core/SwitchToggle/index.ts +1 -0
  516. package/src/components/core/Tabs/Tabs.tsx +130 -0
  517. package/src/components/core/Tabs/index.ts +1 -0
  518. package/src/components/core/Tag/Tag.tsx +61 -0
  519. package/src/components/core/Tag/index.ts +1 -0
  520. package/src/components/core/TextButton/TextButton.tsx +108 -0
  521. package/src/components/core/TextButton/index.ts +1 -0
  522. package/src/components/core/Toast/Toast.tsx +65 -0
  523. package/src/components/core/Toast/index.ts +1 -0
  524. package/src/components/core/Tooltip/Tooltip.tsx +110 -0
  525. package/src/components/core/Tooltip/index.ts +1 -0
  526. package/src/components/shared/NextFontMeinSchiffSansPro/NextFontMeinSchiffSansPro.tsx +160 -0
  527. package/src/components/shared/NextFontMeinSchiffSansPro/index.ts +1 -0
  528. package/src/components/shared/UniversalCarousel/CarouselContext.ts +61 -0
  529. package/src/components/shared/UniversalCarousel/CarouselDefaultPagination.tsx +92 -0
  530. package/src/components/shared/UniversalCarousel/CarouselInterface.tsx +152 -0
  531. package/src/components/shared/UniversalCarousel/CarouselStage.tsx +235 -0
  532. package/src/components/shared/UniversalCarousel/UniversalCarousel.tsx +125 -0
  533. package/src/components/shared/UniversalCarousel/helpers.ts +206 -0
  534. package/src/components/shared/UniversalCarousel/index.ts +4 -0
  535. package/src/helpers/children.ts +27 -0
  536. package/src/helpers/cookies.ts +22 -0
  537. package/src/helpers/dateFormat.ts +245 -0
  538. package/src/helpers/dateToYearMonthDay.ts +17 -0
  539. package/src/helpers/elementVisibility.ts +53 -0
  540. package/src/helpers/i18n.ts +197 -0
  541. package/src/helpers/price.ts +26 -0
  542. package/src/helpers/responsive-property.ts +118 -0
  543. package/src/helpers/screen.ts +14 -0
  544. package/src/helpers/sleep.ts +5 -0
  545. package/src/helpers/slot.tsx +68 -0
  546. package/src/helpers/ssr.ts +5 -0
  547. package/src/helpers/store.ts +75 -0
  548. package/src/helpers/types.ts +18 -0
  549. package/src/helpers/utils.ts +3 -0
  550. package/src/hooks/use-active-screen-names.ts +100 -0
  551. package/src/hooks/use-intersection-observer.ts +190 -0
  552. package/src/hooks/use-screen-name-at-least.ts +32 -0
  553. package/src/hooks/use-screen-name.ts +34 -0
  554. package/src/hooks/use-store.ts +45 -0
  555. package/src/hooks/use-toasts.ts +111 -0
  556. package/src/stores/toasts-store.ts +11 -0
@@ -0,0 +1,443 @@
1
+ 'use client';
2
+
3
+ import * as DialogPrimitive from '@radix-ui/react-dialog';
4
+ import { formatTrackingString, trackEvent } from '@tuic/lib/helpers/tracking';
5
+ import { EventClickArea } from '@tuic/lib/tracking/tealium';
6
+ import { ComponentProps, FC, PropsWithChildren, ReactNode } from 'react';
7
+ import { twJoin } from 'tailwind-merge';
8
+ import { IconButton } from '../../core/IconButton';
9
+
10
+ export type DialogContentProps = PropsWithChildren<{
11
+ /**
12
+ * Change the default rendered element for the one passed as a child, merging their props and behavior.
13
+ * Read [Radix Composition guide](https://www.radix-ui.com/primitives/docs/guides/composition) for more details.
14
+ */
15
+ asChild?: ComponentProps<typeof DialogPrimitive.Content>['asChild'];
16
+
17
+ /**
18
+ * Used to force mounting when more control is needed. Useful when controlling animation with React animation libraries. It inherits from Dialog.Portal.
19
+ */
20
+ forceMount?: ComponentProps<typeof DialogPrimitive.Content>['forceMount'];
21
+
22
+ /**
23
+ * Event handler called when focus moves into the component after opening. It can be prevented by calling `event.preventDefault`.
24
+ */
25
+ onOpenAutoFocus?: ComponentProps<
26
+ typeof DialogPrimitive.Content
27
+ >['onOpenAutoFocus'];
28
+
29
+ /**
30
+ * Event handler called when focus moves to the trigger after closing. It can be prevented by calling `event.preventDefault`.
31
+ */
32
+ onCloseAutoFocus?: ComponentProps<
33
+ typeof DialogPrimitive.Content
34
+ >['onCloseAutoFocus'];
35
+
36
+ /**
37
+ * Event handler called when the escape key is down. It can be prevented by calling `event.preventDefault`.
38
+ */
39
+ onEscapeKeyDown?: ComponentProps<
40
+ typeof DialogPrimitive.Content
41
+ >['onEscapeKeyDown'];
42
+
43
+ /**
44
+ * Event handler called when a pointer event occurs outside the bounds of the component. It can be prevented by calling `event.preventDefault`.
45
+ */
46
+ onPointerDownOutside?: ComponentProps<
47
+ typeof DialogPrimitive.Content
48
+ >['onPointerDownOutside'];
49
+
50
+ /**
51
+ * Event handler called when an interaction (pointer or focus event) happens outside the bounds of the component. It can be prevented by calling `event.preventDefault`.
52
+ */
53
+ onInteractOutside?: ComponentProps<
54
+ typeof DialogPrimitive.Content
55
+ >['onInteractOutside'];
56
+
57
+ /**
58
+ * The title displayed at the top of the dialog.
59
+ */
60
+ title?: string;
61
+
62
+ /**
63
+ * Used to display the Dialog in a fullscreen mode across the entire viewport.
64
+ */
65
+ fullscreen?: boolean;
66
+
67
+ /**
68
+ * Used to display the Dialog in a windowed mode on smaller viewport.
69
+ */
70
+ mobileWindowed?: boolean;
71
+
72
+ /**
73
+ * Used to display the Dialog in the maximum height (regadless of it's childrens height).
74
+ */
75
+ expanded?: boolean;
76
+
77
+ /**
78
+ * Used to display a medium or large width dialog on desktop. Defaults to `'md'`.
79
+ */
80
+ desktopSize?: 'md' | 'lg' | 'xl';
81
+
82
+ /**
83
+ * Specifies the container in which the dialog will render. If not provided, the dialog will render as a child of its parent in the DOM tree.
84
+ */
85
+ container?: ComponentProps<typeof DialogPrimitive.Portal>['container'];
86
+
87
+ /**
88
+ * Used to remove the default padding from the dialog content.
89
+ */
90
+ disableSpacing?: boolean;
91
+
92
+ /**
93
+ * The CTA-Link on the left side
94
+ */
95
+ ctaLink?: React.ReactNode;
96
+
97
+ /**
98
+ * The CTA-Button on the right side
99
+ */
100
+ ctaButton?: React.ReactNode;
101
+
102
+ /**
103
+ * The hero content of the dialog, displayed at the top of the dialog.
104
+ */
105
+ heroContent?: React.ReactNode;
106
+
107
+ /**
108
+ * The footer content of the dialog. Sticks to the bottom of the dialog.
109
+ */
110
+ footerContent?: ReactNode;
111
+
112
+ /**
113
+ * Limits the height of the content to the dialog height (useful when a fixed bottom bar is needed)
114
+ */
115
+ heightLimited?: boolean;
116
+
117
+ /**
118
+ * Wird benutzt um die Größe im Mobile auf 90vh zu fixen
119
+ */
120
+ nearlyFullScreen?: boolean;
121
+
122
+ /**
123
+ * Displays a back button inside the dialog header.
124
+ */
125
+ showBackButton?: boolean;
126
+
127
+ /**
128
+ * Callback to call on click on back button.
129
+ */
130
+ onBack?: () => void;
131
+
132
+ /**
133
+ * Displays the close button inside the dialog header (default = true)
134
+ */
135
+ showCloseButton?: boolean;
136
+
137
+ /**
138
+ * CSS classes on dialog body.
139
+ */
140
+ bodyClassName?: string;
141
+
142
+ /**
143
+ * Name of the Dialog used for tracking
144
+ */
145
+ trackingName?: string;
146
+
147
+ /**
148
+ * Disable the focus reset which occurs after the closing of a dialog.
149
+ * When focus reset is disabled, the trigger of the dialog is focused once the dialog closes.
150
+ */
151
+ disableOnCloseFocusReset?: boolean;
152
+ }>;
153
+
154
+ export type DialogProps = PropsWithChildren<{
155
+ /**
156
+ * The open state of the dialog when it is initially rendered. Use when you do not need to control its open state.
157
+ */
158
+ defaultOpen?: ComponentProps<typeof DialogPrimitive.Root>['defaultOpen'];
159
+
160
+ /**
161
+ * Callback fired when the dialog's open state changes.
162
+ */
163
+ onOpenChange?: ComponentProps<typeof DialogPrimitive.Root>['onOpenChange'];
164
+
165
+ /**
166
+ * The controlled open state of the dialog. Must be used in conjunction with onOpenChange.
167
+ */
168
+ open?: ComponentProps<typeof DialogPrimitive.Root>['open'];
169
+
170
+ /**
171
+ * The modality of the dialog. When set to true, interaction with outside elements will be disabled and only dialog content will be visible to screen readers.
172
+ */
173
+ modal?: ComponentProps<typeof DialogPrimitive.Root>['modal'];
174
+
175
+ /**
176
+ * Name of the Dialog used for tracking
177
+ */
178
+ trackingName?: string;
179
+ }>;
180
+
181
+ export type DialogTriggerProps = PropsWithChildren<{
182
+ /**
183
+ * Change the default rendered element for the one passed as a child, merging their props and behavior.
184
+ * Read [Radix Composition guide](https://www.radix-ui.com/primitives/docs/guides/composition) for more details.
185
+ */
186
+ asChild?: ComponentProps<typeof DialogPrimitive.Trigger>['asChild'];
187
+
188
+ className?: ComponentProps<typeof DialogPrimitive.Trigger>['className'];
189
+ }>;
190
+
191
+ /**
192
+ * The Dialog component can be used to isolate the user from the main window by overlaying
193
+ * another window that requires the users attention.
194
+ *
195
+ * Based on [Radix Dialog](https://radix-ui.com/primitives/docs/components/dialog) (see for further documentation).
196
+ *
197
+ * ### Developer Notes
198
+ *
199
+ * * The content should be wrapped in a `DialogContent`.
200
+ * * Dialogs can also be nested (though this should be avoided).
201
+ * * By default, the Dialog is wrapped in a `DialogPortal` that portals the `DialogOverlay` and `DialogContent` into the body - this can be adjusted to any other place with the `container` prop.
202
+ * * The dialog can be controlled or uncontrolled:
203
+ *
204
+ * ```tsx
205
+ * // controlled:
206
+ * // use the `open` and `onOpenChange` props to control
207
+ * // the appearance state of the dialog from outside.
208
+ *
209
+ * import { useState } from 'react';
210
+ * import Button from '@tui-cruises/mein-schiff-web-react-component-library';
211
+ * import { Dialog, DialogContent } from '@tui-cruises/mein-schiff-web-react-component-library';
212
+ *
213
+ * const [open, setOpen] = useState(false);
214
+ *
215
+ * // ...
216
+ *
217
+ * <Button label="Open Dialog" onClick={() => setOpen(true)}/>
218
+ *
219
+ * <Dialog open={open} onOpenChange={setOpen}>
220
+ * <DialogContent title="Title of the Dialog">
221
+ * <div>
222
+ * Content of the dialog.
223
+ * </div>
224
+ * </DialogContent>
225
+ * </Dialog>
226
+ * ```
227
+ * ```tsx
228
+ * // uncontrolled:
229
+ * // use the `DialogTrigger` inside the main `Dialog` component
230
+ * // to let the dialog itself handle the appearance state.
231
+ *
232
+ * import Button from '@tui-cruises/mein-schiff-web-react-component-library';
233
+ * import { Dialog, DialogContent, DialogTrigger } from '@tui-cruises/mein-schiff-web-react-component-library';
234
+ *
235
+ * // ...
236
+ *
237
+ * <Dialog>
238
+ * <DialogTrigger asChild>
239
+ * <Button label="Open Dialog" />
240
+ * </DialogTrigger>
241
+ * <DialogContent title="Title of the Dialog">
242
+ * <div>
243
+ * Content of the dialog.
244
+ * </div>
245
+ * </DialogContent>
246
+ * </Dialog>
247
+ * ```
248
+ *
249
+ *
250
+ */
251
+
252
+ const Dialog = (props: DialogProps) => {
253
+ const { onOpenChange, trackingName, ...rest } = props;
254
+
255
+ const handleOpenChange = (open: boolean) => {
256
+ if (trackingName) {
257
+ trackEvent({
258
+ event_name: open ? 'layer-open-user' : 'layer-close',
259
+ layer_name: formatTrackingString(trackingName),
260
+ });
261
+ }
262
+ onOpenChange && onOpenChange(open);
263
+ };
264
+
265
+ return <DialogPrimitive.Root {...rest} onOpenChange={handleOpenChange} />;
266
+ };
267
+
268
+ const DialogTrigger: FC<DialogTriggerProps> = DialogPrimitive.Trigger;
269
+
270
+ const DialogClose = DialogPrimitive.Close;
271
+
272
+ const DialogContent = ({
273
+ title,
274
+ fullscreen = false,
275
+ mobileWindowed = false,
276
+ desktopSize = 'md',
277
+ expanded = false,
278
+ container,
279
+ children,
280
+ disableSpacing = false,
281
+ heightLimited = false,
282
+ nearlyFullScreen = false,
283
+ ctaLink,
284
+ ctaButton,
285
+ heroContent,
286
+ footerContent,
287
+ showBackButton,
288
+ onBack,
289
+ showCloseButton = true,
290
+ bodyClassName,
291
+ trackingName,
292
+ disableOnCloseFocusReset,
293
+ ...rest
294
+ }: DialogContentProps) => {
295
+ return (
296
+ <DialogPrimitive.Portal container={container || undefined}>
297
+ <DialogPrimitive.Overlay
298
+ className={twJoin(
299
+ 'fixed inset-0 z-dialog flex',
300
+ 'data-[state=open]:animate-in data-[state=closed]:animate-out',
301
+ 'data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0',
302
+ 'firefox:data-[state=closed]:animate-none firefox:data-[state=open]:animate-none',
303
+ !fullscreen &&
304
+ twJoin(
305
+ 'items-end bg-overlay backdrop-blur-sm md:items-center md:justify-center md:p-8',
306
+ 'data-[state=open]:duration-300',
307
+ 'data-[state=closed]:duration-500',
308
+ ),
309
+ mobileWindowed && 'items-center justify-center p-4',
310
+ )}
311
+ >
312
+ <DialogPrimitive.Content
313
+ onCloseAutoFocus={createOnCloseAutoFocusHandler(
314
+ disableOnCloseFocusReset,
315
+ )}
316
+ data-track-click-area={EventClickArea.Dialog}
317
+ data-track-dialog={
318
+ trackingName ? formatTrackingString(trackingName) : title
319
+ }
320
+ className={twJoin(
321
+ 'relative flex w-full overflow-hidden bg-surface-secondary-7',
322
+ 'duration-200',
323
+ 'data-[state=open]:animate-in data-[state=open]:fade-in-0 md:data-[state=open]:zoom-in-95',
324
+ 'data-[state=closed]:animate-out data-[state=closed]:fade-out-0 md:data-[state=closed]:zoom-out-95',
325
+ fullscreen && 'fixed inset-0 h-full w-full',
326
+ !fullscreen &&
327
+ twJoin(
328
+ 'max-h-[calc(100%_-_theme(space.8))] rounded-t-md shadow-md md:max-h-full md:rounded-md',
329
+ 'data-[state=open]:duration-300 data-[state=open]:slide-in-from-bottom-1/2 md:data-[state=open]:slide-in-from-bottom-0',
330
+ 'data-[state=closed]:duration-500 data-[state=closed]:slide-out-to-bottom-1/2 md:data-[state=closed]:slide-out-to-bottom-0',
331
+ ),
332
+ !fullscreen && desktopSize === 'md' && 'md:max-w-[640px]',
333
+ !fullscreen && desktopSize === 'lg' && 'md:max-w-[996px]',
334
+ !fullscreen && desktopSize === 'xl' && 'md:max-w-[1600px]',
335
+ nearlyFullScreen && 'h-[90vh]',
336
+ expanded && 'h-full',
337
+ mobileWindowed && 'rounded-md rounded-t-md',
338
+ )}
339
+ {...rest}
340
+ >
341
+ <button className="h-0 w-0" name="trap-focus-placeholder" />
342
+ <div
343
+ className={twJoin(
344
+ 'absolute left-0 top-0 flex h-12 w-full flex-col items-center justify-center bg-surface-white px-12 py-2 text-center',
345
+ !fullscreen && 'rounded-t-md',
346
+ )}
347
+ >
348
+ <DialogPrimitive.Title className="relative max-w-full truncate text-nowrap text-lg font-semibold text-marine-high-emphasis">
349
+ {title}
350
+ </DialogPrimitive.Title>
351
+ {showCloseButton && (
352
+ <div className="absolute right-2 top-0 flex h-12 items-center justify-center">
353
+ <DialogPrimitive.Close asChild>
354
+ <IconButton
355
+ iconName="cancel"
356
+ variant="ghost"
357
+ size="sm"
358
+ aria-label={`close-${title}`}
359
+ />
360
+ </DialogPrimitive.Close>
361
+ </div>
362
+ )}
363
+ </div>
364
+ <div
365
+ className={twJoin(
366
+ 'mt-12 flex max-h-[calc(100%_-_theme(space.12))] w-full flex-col overflow-y-auto',
367
+ bodyClassName,
368
+ )}
369
+ >
370
+ {heroContent}
371
+ <div
372
+ className={twJoin(
373
+ 'flex grow flex-col gap-8',
374
+ !disableSpacing && 'p-6 md:p-10',
375
+ heightLimited && 'max-h-full',
376
+ )}
377
+ >
378
+ {children}
379
+ {(!!ctaLink || !!ctaButton) && (
380
+ <div className="flex flex-col justify-between gap-4 sm:flex-row">
381
+ <div>
382
+ {!!ctaLink && (
383
+ <div className="text-base text-marine-high-emphasis underline">
384
+ {ctaLink}
385
+ </div>
386
+ )}
387
+ </div>
388
+ <div className="flex gap-6">{ctaButton}</div>
389
+ </div>
390
+ )}
391
+ </div>
392
+
393
+ {footerContent && (
394
+ <div
395
+ className={twJoin(
396
+ 'sticky -bottom-0 left-0 right-0',
397
+ 'pb-6 pt-4 md:pb-4',
398
+ !disableSpacing && 'px-6 md:px-10',
399
+ 'bg-surface-white',
400
+ )}
401
+ >
402
+ {footerContent}
403
+ </div>
404
+ )}
405
+ </div>
406
+
407
+ {showBackButton && (
408
+ <div className="absolute left-4 top-0 flex h-12 items-center justify-center">
409
+ <IconButton
410
+ iconName="arrow-left"
411
+ aria-label={`navigate-back-${title}`}
412
+ variant="secondary"
413
+ size="sm"
414
+ onClick={onBack}
415
+ />
416
+ </div>
417
+ )}
418
+ </DialogPrimitive.Content>
419
+ </DialogPrimitive.Overlay>
420
+ </DialogPrimitive.Portal>
421
+ );
422
+ };
423
+
424
+ const createOnCloseAutoFocusHandler = (
425
+ disableOnCloseFocusReset: boolean | undefined,
426
+ ): DialogContentProps['onCloseAutoFocus'] => {
427
+ if (disableOnCloseFocusReset === true) {
428
+ return undefined;
429
+ }
430
+
431
+ return event => {
432
+ event.preventDefault();
433
+
434
+ const target = event.target as HTMLElement | null;
435
+
436
+ if (!target) return;
437
+
438
+ target.focus();
439
+ target.blur();
440
+ };
441
+ };
442
+
443
+ export { Dialog, DialogTrigger, DialogContent, DialogClose };
@@ -0,0 +1 @@
1
+ export * from './Dialog';
@@ -0,0 +1,37 @@
1
+ import type { FC, HTMLAttributes } from 'react';
2
+ import { twMerge } from 'tailwind-merge';
3
+ import { Slot } from '@radix-ui/react-slot';
4
+
5
+ type Props = HTMLAttributes<HTMLDivElement> & {
6
+ asChild?: boolean;
7
+ align?: 'vertical' | 'horizontal';
8
+ color?: 'secondary-20' | 'secondary-40' | 'primary-40' | 'primary-100';
9
+ };
10
+
11
+ /**
12
+ * Dividers are thin lines that group and/or divide content in lists or other containers.
13
+ */
14
+ export const Divider: FC<Props> = ({
15
+ asChild,
16
+ align = 'horizontal',
17
+ color = 'secondary-40',
18
+ ...rest
19
+ }) => {
20
+ const classNames = {
21
+ 'secondary-20': 'bg-stroke-secondary-20',
22
+ 'secondary-40': 'bg-stroke-secondary-40',
23
+ 'primary-40': 'bg-stroke-primary-40',
24
+ 'primary-100': 'bg-stroke-primary-100',
25
+ };
26
+
27
+ const colorClass = classNames[color] || classNames['secondary-40'];
28
+ const className = twMerge(
29
+ align === 'horizontal' ? 'h-px w-full' : 'h-full w-px',
30
+ rest.className,
31
+ `border-0 appearance-none ${colorClass}`,
32
+ );
33
+
34
+ const Element = asChild ? Slot : 'div';
35
+
36
+ return <Element {...rest} className={className} />;
37
+ };
@@ -0,0 +1 @@
1
+ export * from './Divider';