@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.
- package/CHANGELOG.md +7 -0
- package/LICENSE +14 -0
- package/README.md +26 -0
- package/custom.d.ts +14 -0
- package/icons/icons/360.tsx +20 -0
- package/icons/icons/add-circle.tsx +26 -0
- package/icons/icons/airplane.tsx +20 -0
- package/icons/icons/anchor.tsx +20 -0
- package/icons/icons/angle-tool.tsx +26 -0
- package/icons/icons/arrow-down.tsx +20 -0
- package/icons/icons/arrow-left.tsx +20 -0
- package/icons/icons/arrow-right.tsx +20 -0
- package/icons/icons/at.tsx +20 -0
- package/icons/icons/baggage.tsx +20 -0
- package/icons/icons/balcony.tsx +20 -0
- package/icons/icons/bathroom.tsx +32 -0
- package/icons/icons/beach.tsx +20 -0
- package/icons/icons/bed.tsx +26 -0
- package/icons/icons/bell.tsx +20 -0
- package/icons/icons/bording.tsx +20 -0
- package/icons/icons/cabins.tsx +20 -0
- package/icons/icons/calendar.tsx +32 -0
- package/icons/icons/cancel.tsx +20 -0
- package/icons/icons/cash.tsx +44 -0
- package/icons/icons/check-circle.tsx +18 -0
- package/icons/icons/check.tsx +20 -0
- package/icons/icons/circle.tsx +20 -0
- package/icons/icons/clear.tsx +24 -0
- package/icons/icons/clock-rotate-right.tsx +20 -0
- package/icons/icons/clock.tsx +26 -0
- package/icons/icons/cloud-sunny.tsx +43 -0
- package/icons/icons/cloud.tsx +20 -0
- package/icons/icons/compass.tsx +26 -0
- package/icons/icons/delete-circle.tsx +26 -0
- package/icons/icons/departure.tsx +20 -0
- package/icons/icons/details.tsx +20 -0
- package/icons/icons/diamond.tsx +20 -0
- package/icons/icons/edit-pencil.tsx +20 -0
- package/icons/icons/excellence.tsx +20 -0
- package/icons/icons/expand.tsx +20 -0
- package/icons/icons/eye-closed.tsx +20 -0
- package/icons/icons/eye-empty.tsx +26 -0
- package/icons/icons/eye-off.tsx +32 -0
- package/icons/icons/eye.tsx +26 -0
- package/icons/icons/fallback.tsx +26 -0
- package/icons/icons/filter.tsx +20 -0
- package/icons/icons/flag.tsx +20 -0
- package/icons/icons/fog.tsx +22 -0
- package/icons/icons/glases.tsx +28 -0
- package/icons/icons/group.tsx +32 -0
- package/icons/icons/heart-filled.tsx +20 -0
- package/icons/icons/heart.tsx +20 -0
- package/icons/icons/help-circle.tsx +24 -0
- package/icons/icons/home.tsx +22 -0
- package/icons/icons/humidity.tsx +30 -0
- package/icons/icons/impressions.tsx +20 -0
- package/icons/icons/inclusive-services.tsx +20 -0
- package/icons/icons/index.ts +141 -0
- package/icons/icons/info-empty.tsx +26 -0
- package/icons/icons/language.tsx +20 -0
- package/icons/icons/lifebuoy.tsx +30 -0
- package/icons/icons/loading.tsx +18 -0
- package/icons/icons/location.tsx +24 -0
- package/icons/icons/log-in.tsx +26 -0
- package/icons/icons/log-out.tsx +26 -0
- package/icons/icons/mail-open.tsx +20 -0
- package/icons/icons/map.tsx +20 -0
- package/icons/icons/maps-arrow-diagonal.tsx +20 -0
- package/icons/icons/media-image-list.tsx +32 -0
- package/icons/icons/menu.tsx +21 -0
- package/icons/icons/metropolis.tsx +20 -0
- package/icons/icons/minus.tsx +20 -0
- package/icons/icons/more-horiz.tsx +35 -0
- package/icons/icons/more-vert.tsx +35 -0
- package/icons/icons/mostly-cloudy-night.tsx +24 -0
- package/icons/icons/ms-ship.tsx +20 -0
- package/icons/icons/music.tsx +20 -0
- package/icons/icons/nav-arrow-down.tsx +20 -0
- package/icons/icons/nav-arrow-left.tsx +20 -0
- package/icons/icons/nav-arrow-right.tsx +20 -0
- package/icons/icons/nav-arrow-up.tsx +20 -0
- package/icons/icons/no-wifi.tsx +18 -0
- package/icons/icons/old-trips.tsx +20 -0
- package/icons/icons/percentage.tsx +20 -0
- package/icons/icons/phone.tsx +20 -0
- package/icons/icons/pin.tsx +20 -0
- package/icons/icons/play.tsx +20 -0
- package/icons/icons/plus-circle.tsx +20 -0
- package/icons/icons/plus.tsx +20 -0
- package/icons/icons/point.tsx +15 -0
- package/icons/icons/rain.tsx +22 -0
- package/icons/icons/receipt.tsx +20 -0
- package/icons/icons/refresh-double.tsx +32 -0
- package/icons/icons/search.tsx +26 -0
- package/icons/icons/security-pass.tsx +26 -0
- package/icons/icons/settings.tsx +20 -0
- package/icons/icons/share-ios.tsx +26 -0
- package/icons/icons/ship-account.tsx +20 -0
- package/icons/icons/ship-info.tsx +20 -0
- package/icons/icons/ship-position.tsx +27 -0
- package/icons/icons/shooting-stars.tsx +28 -0
- package/icons/icons/sleet.tsx +22 -0
- package/icons/icons/snow-flake.tsx +20 -0
- package/icons/icons/snow.tsx +22 -0
- package/icons/icons/sofa.tsx +32 -0
- package/icons/icons/star-dashed.tsx +20 -0
- package/icons/icons/star-filled.tsx +25 -0
- package/icons/icons/star-half-dashed.tsx +26 -0
- package/icons/icons/star.tsx +20 -0
- package/icons/icons/substract.tsx +26 -0
- package/icons/icons/sun-light.tsx +42 -0
- package/icons/icons/temperature-high.tsx +26 -0
- package/icons/icons/thunderstorm.tsx +26 -0
- package/icons/icons/tornado.tsx +18 -0
- package/icons/icons/trash.tsx +20 -0
- package/icons/icons/travel-assistant.tsx +24 -0
- package/icons/icons/tropical-storm.tsx +71 -0
- package/icons/icons/upcoming-trips.tsx +27 -0
- package/icons/icons/user.tsx +26 -0
- package/icons/icons/warning-circle.tsx +26 -0
- package/icons/icons/warning-hexagon.tsx +26 -0
- package/icons/icons/weather.tsx +20 -0
- package/icons/icons/wifi.tsx +20 -0
- package/icons/icons/wind.tsx +22 -0
- package/icons/icons/windrose.tsx +42 -0
- package/icons/icons/windsock.tsx +20 -0
- package/icons/pictograms/24h-meals.tsx +25 -0
- package/icons/pictograms/ad-template.tsx +23 -0
- package/icons/pictograms/add.tsx +25 -0
- package/icons/pictograms/adventure-club-only.tsx +25 -0
- package/icons/pictograms/allergy.tsx +30 -0
- package/icons/pictograms/anchor.tsx +23 -0
- package/icons/pictograms/arrival.tsx +23 -0
- package/icons/pictograms/baby-awake.tsx +20 -0
- package/icons/pictograms/baby-monitor.tsx +20 -0
- package/icons/pictograms/baby-sleep.tsx +20 -0
- package/icons/pictograms/baggage-information.tsx +23 -0
- package/icons/pictograms/baggage.tsx +23 -0
- package/icons/pictograms/bedroom-check.tsx +23 -0
- package/icons/pictograms/bedroom.tsx +23 -0
- package/icons/pictograms/beverages.tsx +28 -0
- package/icons/pictograms/billboard.tsx +23 -0
- package/icons/pictograms/blog.tsx +23 -0
- package/icons/pictograms/brochure.tsx +23 -0
- package/icons/pictograms/calendar-check.tsx +18 -0
- package/icons/pictograms/calendar-default.tsx +18 -0
- package/icons/pictograms/calendar-disabled.tsx +18 -0
- package/icons/pictograms/calendar-focus.tsx +25 -0
- package/icons/pictograms/champagne-glasses.tsx +25 -0
- package/icons/pictograms/check.tsx +25 -0
- package/icons/pictograms/checklist-check.tsx +18 -0
- package/icons/pictograms/checklist.tsx +21 -0
- package/icons/pictograms/checkmark.tsx +23 -0
- package/icons/pictograms/chef-hat.tsx +30 -0
- package/icons/pictograms/chevron-down.tsx +25 -0
- package/icons/pictograms/chevron-up.tsx +25 -0
- package/icons/pictograms/circles.tsx +25 -0
- package/icons/pictograms/cleaning-trolley.tsx +30 -0
- package/icons/pictograms/clock-0-30.tsx +23 -0
- package/icons/pictograms/clock-0.tsx +23 -0
- package/icons/pictograms/clock-1-30.tsx +23 -0
- package/icons/pictograms/clock-1.tsx +23 -0
- package/icons/pictograms/clock-10-30.tsx +23 -0
- package/icons/pictograms/clock-10.tsx +23 -0
- package/icons/pictograms/clock-11-30.tsx +23 -0
- package/icons/pictograms/clock-11.tsx +23 -0
- package/icons/pictograms/clock-2-30.tsx +23 -0
- package/icons/pictograms/clock-2.tsx +23 -0
- package/icons/pictograms/clock-3-30.tsx +23 -0
- package/icons/pictograms/clock-3.tsx +23 -0
- package/icons/pictograms/clock-4-30.tsx +23 -0
- package/icons/pictograms/clock-4.tsx +23 -0
- package/icons/pictograms/clock-5-30.tsx +23 -0
- package/icons/pictograms/clock-5.tsx +23 -0
- package/icons/pictograms/clock-6-30.tsx +23 -0
- package/icons/pictograms/clock-6.tsx +23 -0
- package/icons/pictograms/clock-7-30.tsx +23 -0
- package/icons/pictograms/clock-7.tsx +23 -0
- package/icons/pictograms/clock-8-30.tsx +23 -0
- package/icons/pictograms/clock-8.tsx +23 -0
- package/icons/pictograms/clock-9-30.tsx +23 -0
- package/icons/pictograms/clock-9.tsx +23 -0
- package/icons/pictograms/clock-default.tsx +23 -0
- package/icons/pictograms/close.tsx +25 -0
- package/icons/pictograms/clothing.tsx +23 -0
- package/icons/pictograms/cloud.tsx +23 -0
- package/icons/pictograms/cocktails.tsx +23 -0
- package/icons/pictograms/coffee-machine.tsx +23 -0
- package/icons/pictograms/compass.tsx +23 -0
- package/icons/pictograms/couple.tsx +25 -0
- package/icons/pictograms/crew-love.tsx +28 -0
- package/icons/pictograms/crown.tsx +23 -0
- package/icons/pictograms/dart.tsx +23 -0
- package/icons/pictograms/decoration.tsx +23 -0
- package/icons/pictograms/departure-check.tsx +25 -0
- package/icons/pictograms/departure-germany.tsx +20 -0
- package/icons/pictograms/departure-time.tsx +35 -0
- package/icons/pictograms/departure.tsx +23 -0
- package/icons/pictograms/diamond.tsx +23 -0
- package/icons/pictograms/discount-card.tsx +35 -0
- package/icons/pictograms/discount.tsx +30 -0
- package/icons/pictograms/documents.tsx +23 -0
- package/icons/pictograms/download-document.tsx +23 -0
- package/icons/pictograms/download.tsx +23 -0
- package/icons/pictograms/dripping-dew.tsx +23 -0
- package/icons/pictograms/dumbbell.tsx +25 -0
- package/icons/pictograms/early-bird.tsx +23 -0
- package/icons/pictograms/edit.tsx +23 -0
- package/icons/pictograms/energy-saving.tsx +23 -0
- package/icons/pictograms/enjoyer-club-only.tsx +18 -0
- package/icons/pictograms/environment.tsx +30 -0
- package/icons/pictograms/environmental-officer.tsx +30 -0
- package/icons/pictograms/explorer-club-only.tsx +18 -0
- package/icons/pictograms/family.tsx +25 -0
- package/icons/pictograms/fb-community.tsx +25 -0
- package/icons/pictograms/finance.tsx +25 -0
- package/icons/pictograms/fog.tsx +25 -0
- package/icons/pictograms/food-certificate.tsx +30 -0
- package/icons/pictograms/gastronomy.tsx +25 -0
- package/icons/pictograms/gift.tsx +23 -0
- package/icons/pictograms/globetrotter-club-only.tsx +18 -0
- package/icons/pictograms/hairdresser.tsx +20 -0
- package/icons/pictograms/handbag.tsx +30 -0
- package/icons/pictograms/hands-holding-heart.tsx +30 -0
- package/icons/pictograms/heart-beat.tsx +29 -0
- package/icons/pictograms/heart.tsx +23 -0
- package/icons/pictograms/home.tsx +23 -0
- package/icons/pictograms/hospital-cross.tsx +23 -0
- package/icons/pictograms/hot-dish.tsx +23 -0
- package/icons/pictograms/hot-drink.tsx +25 -0
- package/icons/pictograms/human-heart.tsx +30 -0
- package/icons/pictograms/human-holding-heart.tsx +30 -0
- package/icons/pictograms/human-open-arms.tsx +23 -0
- package/icons/pictograms/human-profile.tsx +23 -0
- package/icons/pictograms/human-swimming.tsx +25 -0
- package/icons/pictograms/ice-cream.tsx +23 -0
- package/icons/pictograms/important.tsx +23 -0
- package/icons/pictograms/index.ts +285 -0
- package/icons/pictograms/information.tsx +30 -0
- package/icons/pictograms/internet.tsx +23 -0
- package/icons/pictograms/jogging.tsx +21 -0
- package/icons/pictograms/kid-playing.tsx +23 -0
- package/icons/pictograms/life-jacket.tsx +21 -0
- package/icons/pictograms/lifebuoy.tsx +20 -0
- package/icons/pictograms/lightbulb.tsx +23 -0
- package/icons/pictograms/lightning.tsx +23 -0
- package/icons/pictograms/location-mark.tsx +30 -0
- package/icons/pictograms/log-in.tsx +23 -0
- package/icons/pictograms/long-term-trips.tsx +20 -0
- package/icons/pictograms/lotte-chatbot.tsx +28 -0
- package/icons/pictograms/lotte-mail.tsx +28 -0
- package/icons/pictograms/mail-at.tsx +23 -0
- package/icons/pictograms/mail-information.tsx +23 -0
- package/icons/pictograms/mailbox.tsx +23 -0
- package/icons/pictograms/many-sea-days.tsx +20 -0
- package/icons/pictograms/medal.tsx +23 -0
- package/icons/pictograms/microphone.tsx +23 -0
- package/icons/pictograms/ms-1.tsx +23 -0
- package/icons/pictograms/ms-2.tsx +30 -0
- package/icons/pictograms/ms-3.tsx +30 -0
- package/icons/pictograms/ms-4.tsx +30 -0
- package/icons/pictograms/ms-5.tsx +30 -0
- package/icons/pictograms/ms-6.tsx +30 -0
- package/icons/pictograms/ms-7-new-eng.tsx +37 -0
- package/icons/pictograms/ms-7-new.tsx +30 -0
- package/icons/pictograms/ms-7.tsx +30 -0
- package/icons/pictograms/ms-default.tsx +30 -0
- package/icons/pictograms/ms-flow-new-eng.tsx +37 -0
- package/icons/pictograms/ms-flow-new.tsx +49 -0
- package/icons/pictograms/ms-flow.tsx +41 -0
- package/icons/pictograms/ms-relax-new-eng.tsx +37 -0
- package/icons/pictograms/ms-relax-new.tsx +36 -0
- package/icons/pictograms/ms-ship.tsx +23 -0
- package/icons/pictograms/music-book.tsx +23 -0
- package/icons/pictograms/my-account.tsx +22 -0
- package/icons/pictograms/my-trips.tsx +29 -0
- package/icons/pictograms/navigation-arrow.tsx +23 -0
- package/icons/pictograms/no-wifi.tsx +21 -0
- package/icons/pictograms/not-available.tsx +23 -0
- package/icons/pictograms/offer.tsx +23 -0
- package/icons/pictograms/offline.tsx +25 -0
- package/icons/pictograms/onboard-announcement.tsx +20 -0
- package/icons/pictograms/package-newspaper.tsx +27 -0
- package/icons/pictograms/paper-news.tsx +23 -0
- package/icons/pictograms/paper-plane.tsx +28 -0
- package/icons/pictograms/payment-check.tsx +32 -0
- package/icons/pictograms/payment.tsx +28 -0
- package/icons/pictograms/people-check.tsx +25 -0
- package/icons/pictograms/people.tsx +25 -0
- package/icons/pictograms/permanent-make-up.tsx +20 -0
- package/icons/pictograms/person-single.tsx +23 -0
- package/icons/pictograms/phone.tsx +20 -0
- package/icons/pictograms/play-button.tsx +20 -0
- package/icons/pictograms/presentation.tsx +23 -0
- package/icons/pictograms/price-tag.tsx +21 -0
- package/icons/pictograms/printer.tsx +23 -0
- package/icons/pictograms/rain.tsx +23 -0
- package/icons/pictograms/receipt.tsx +25 -0
- package/icons/pictograms/remove.tsx +25 -0
- package/icons/pictograms/safety.tsx +23 -0
- package/icons/pictograms/screen.tsx +23 -0
- package/icons/pictograms/search.tsx +23 -0
- package/icons/pictograms/service.tsx +23 -0
- package/icons/pictograms/sewage.tsx +30 -0
- package/icons/pictograms/ship-outstanding.tsx +23 -0
- package/icons/pictograms/ship-transfer.tsx +23 -0
- package/icons/pictograms/shooting-stars.tsx +23 -0
- package/icons/pictograms/shore-excursions-old.tsx +23 -0
- package/icons/pictograms/shore-excursions.tsx +32 -0
- package/icons/pictograms/short-notice-departures.tsx +20 -0
- package/icons/pictograms/short-trips.tsx +21 -0
- package/icons/pictograms/size.tsx +23 -0
- package/icons/pictograms/smartphone.tsx +23 -0
- package/icons/pictograms/smiley.tsx +23 -0
- package/icons/pictograms/social-media.tsx +37 -0
- package/icons/pictograms/spa-balcony-cabin.tsx +43 -0
- package/icons/pictograms/speech-bubble-faq.tsx +23 -0
- package/icons/pictograms/speech-bubble-hello.tsx +23 -0
- package/icons/pictograms/speech-bubble-ok.tsx +30 -0
- package/icons/pictograms/speedboat.tsx +23 -0
- package/icons/pictograms/star-cancel.tsx +23 -0
- package/icons/pictograms/star-check.tsx +23 -0
- package/icons/pictograms/star-plus.tsx +23 -0
- package/icons/pictograms/star.tsx +23 -0
- package/icons/pictograms/sun-cloud.tsx +23 -0
- package/icons/pictograms/sun-lounger.tsx +23 -0
- package/icons/pictograms/sun.tsx +23 -0
- package/icons/pictograms/theater-mask.tsx +35 -0
- package/icons/pictograms/thermometer.tsx +23 -0
- package/icons/pictograms/tickets.tsx +21 -0
- package/icons/pictograms/towels.tsx +23 -0
- package/icons/pictograms/transportation.tsx +30 -0
- package/icons/pictograms/travel-protection-check.tsx +23 -0
- package/icons/pictograms/travel-protection.tsx +23 -0
- package/icons/pictograms/video.tsx +23 -0
- package/icons/pictograms/waste-management.tsx +30 -0
- package/icons/pictograms/webinar.tsx +23 -0
- package/icons/pictograms/wheel-of-fortune.tsx +23 -0
- package/icons/pictograms/wifi.tsx +20 -0
- package/icons/pictograms/wind.tsx +25 -0
- package/index.tsx +73 -0
- package/package.json +119 -0
- package/public/favicon-16x16.png +0 -0
- package/public/favicon-32x32.png +0 -0
- package/public/videos/placeholder.mp4 +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_It.ttf +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_It.woff +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_It.woff2 +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_Rg.ttf +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_Rg.woff +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_Rg.woff2 +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBd.ttf +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBd.woff +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBd.woff2 +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBdIt.ttf +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBdIt.woff +0 -0
- package/src/assets/fonts/mein-schiff-sans-pro/MeinSchiffSansPro_SBdIt.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.svg +338 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.svg +345 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-200italic.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.svg +338 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.svg +346 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-300italic.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.svg +337 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.svg +342 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-600italic.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.svg +337 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.svg +339 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-700italic.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.svg +337 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.svg +340 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-900italic.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.svg +343 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-italic.woff2 +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.eot +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.svg +337 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.ttf +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.woff +0 -0
- package/src/assets/fonts/source-sans-pro/source-sans-pro-v21-latin-regular.woff2 +0 -0
- package/src/assets/images/placeholder-blueish.jpg +0 -0
- package/src/assets/images/placeholder-sepia.jpg +0 -0
- package/src/assets/images/placeholder.jpg +0 -0
- package/src/components/core/Accordion/Accordion.tsx +228 -0
- package/src/components/core/Accordion/AccordionItem.tsx +72 -0
- package/src/components/core/Accordion/AccordionTab.tsx +39 -0
- package/src/components/core/Accordion/index.ts +3 -0
- package/src/components/core/Accordion/utils.tsx +13 -0
- package/src/components/core/Alert/Alert.tsx +131 -0
- package/src/components/core/Alert/index.ts +1 -0
- package/src/components/core/AlertDialog/AlertDialog.tsx +288 -0
- package/src/components/core/AlertDialog/index.ts +1 -0
- package/src/components/core/Badge/Badge.tsx +70 -0
- package/src/components/core/Badge/index.ts +1 -0
- package/src/components/core/BirthdateField/BirthdateField.tsx +269 -0
- package/src/components/core/BirthdateField/index.ts +1 -0
- package/src/components/core/Button/Button.tsx +178 -0
- package/src/components/core/Button/index.ts +1 -0
- package/src/components/core/ButtonGroup/ButtonGroup.tsx +71 -0
- package/src/components/core/ButtonGroup/index.ts +1 -0
- package/src/components/core/Calendar/Calendar.tsx +303 -0
- package/src/components/core/Calendar/index.ts +1 -0
- package/src/components/core/Checkbox/Checkbox.tsx +107 -0
- package/src/components/core/Checkbox/index.ts +1 -0
- package/src/components/core/CheckboxField/CheckboxField.tsx +156 -0
- package/src/components/core/CheckboxField/CheckboxFieldError.tsx +14 -0
- package/src/components/core/CheckboxField/CheckboxFieldLabel.tsx +25 -0
- package/src/components/core/CheckboxField/CheckboxFieldNote.tsx +16 -0
- package/src/components/core/CheckboxField/index.ts +1 -0
- package/src/components/core/Countdown/Countdown.tsx +67 -0
- package/src/components/core/Countdown/index.ts +1 -0
- package/src/components/core/DataTable/DataTable.tsx +98 -0
- package/src/components/core/DataTable/index.ts +1 -0
- package/src/components/core/Dialog/Dialog.tsx +443 -0
- package/src/components/core/Dialog/index.ts +1 -0
- package/src/components/core/Divider/Divider.tsx +37 -0
- package/src/components/core/Divider/index.ts +1 -0
- package/src/components/core/FavoriteButton/FavoriteButton.tsx +294 -0
- package/src/components/core/FavoriteButton/index.ts +1 -0
- package/src/components/core/Fieldset/Fieldset.tsx +42 -0
- package/src/components/core/Fieldset/index.ts +1 -0
- package/src/components/core/FormLabel/FormLabel.tsx +88 -0
- package/src/components/core/FormLabel/index.ts +1 -0
- package/src/components/core/Icon/Icon.tsx +106 -0
- package/src/components/core/Icon/index.ts +1 -0
- package/src/components/core/IconButton/IconButton.tsx +169 -0
- package/src/components/core/IconButton/index.ts +1 -0
- package/src/components/core/InputField/InputField.tsx +128 -0
- package/src/components/core/InputField/InputFieldError.tsx +17 -0
- package/src/components/core/InputField/InputFieldInput.tsx +67 -0
- package/src/components/core/InputField/InputFieldLabel.tsx +29 -0
- package/src/components/core/InputField/InputFieldNote.tsx +16 -0
- package/src/components/core/InputField/index.ts +1 -0
- package/src/components/core/LoadingSpinner/LoadingSpinner.tsx +50 -0
- package/src/components/core/LoadingSpinner/index.ts +1 -0
- package/src/components/core/Pagination/Pagination.tsx +191 -0
- package/src/components/core/Pagination/index.ts +1 -0
- package/src/components/core/PasswordField/PasswordField.tsx +187 -0
- package/src/components/core/PasswordField/PasswordFieldRequirementsList.tsx +78 -0
- package/src/components/core/PasswordField/index.ts +1 -0
- package/src/components/core/PhoneNumberInput/PhoneNumberInput.tsx +201 -0
- package/src/components/core/PhoneNumberInput/countries.json +242 -0
- package/src/components/core/PhoneNumberInput/index.ts +1 -0
- package/src/components/core/Pictogram/Pictogram.tsx +67 -0
- package/src/components/core/Pictogram/index.ts +1 -0
- package/src/components/core/Popover/Popover.tsx +61 -0
- package/src/components/core/Popover/index.ts +1 -0
- package/src/components/core/Portlist/Portlist.tsx +28 -0
- package/src/components/core/Portlist/index.ts +1 -0
- package/src/components/core/PriceInput/PriceInput.tsx +100 -0
- package/src/components/core/PriceInput/index.ts +1 -0
- package/src/components/core/QuantityItem/QuantityItem.tsx +37 -0
- package/src/components/core/QuantityItem/index.ts +1 -0
- package/src/components/core/Radio/Radio.tsx +64 -0
- package/src/components/core/Radio/index.ts +1 -0
- package/src/components/core/RadioField/RadioField.tsx +66 -0
- package/src/components/core/RadioField/index.ts +1 -0
- package/src/components/core/RadixRadio/RadixRadio.tsx +56 -0
- package/src/components/core/RadixRadio/index.ts +1 -0
- package/src/components/core/RadixSelect/RadixSelect.tsx +172 -0
- package/src/components/core/RadixSelect/index.ts +1 -0
- package/src/components/core/RangeSlider/RangeSlider.tsx +59 -0
- package/src/components/core/RangeSlider/index.ts +1 -0
- package/src/components/core/Section/Section.tsx +62 -0
- package/src/components/core/Section/index.ts +1 -0
- package/src/components/core/SegmentedControl/SegmentedControl.tsx +65 -0
- package/src/components/core/SegmentedControl/index.ts +1 -0
- package/src/components/core/Select/Select.tsx +171 -0
- package/src/components/core/Select/index.ts +1 -0
- package/src/components/core/SelectField/SelectField.tsx +67 -0
- package/src/components/core/SelectField/index.ts +1 -0
- package/src/components/core/Skeleton/Skeleton.tsx +23 -0
- package/src/components/core/Skeleton/SkeletonTextLines.tsx +37 -0
- package/src/components/core/Skeleton/index.ts +2 -0
- package/src/components/core/Stepper/Stepper.tsx +116 -0
- package/src/components/core/Stepper/index.ts +1 -0
- package/src/components/core/SwitchToggle/SwitchToggle.tsx +46 -0
- package/src/components/core/SwitchToggle/index.ts +1 -0
- package/src/components/core/Tabs/Tabs.tsx +130 -0
- package/src/components/core/Tabs/index.ts +1 -0
- package/src/components/core/Tag/Tag.tsx +61 -0
- package/src/components/core/Tag/index.ts +1 -0
- package/src/components/core/TextButton/TextButton.tsx +108 -0
- package/src/components/core/TextButton/index.ts +1 -0
- package/src/components/core/Toast/Toast.tsx +65 -0
- package/src/components/core/Toast/index.ts +1 -0
- package/src/components/core/Tooltip/Tooltip.tsx +110 -0
- package/src/components/core/Tooltip/index.ts +1 -0
- package/src/components/shared/NextFontMeinSchiffSansPro/NextFontMeinSchiffSansPro.tsx +160 -0
- package/src/components/shared/NextFontMeinSchiffSansPro/index.ts +1 -0
- package/src/components/shared/UniversalCarousel/CarouselContext.ts +61 -0
- package/src/components/shared/UniversalCarousel/CarouselDefaultPagination.tsx +92 -0
- package/src/components/shared/UniversalCarousel/CarouselInterface.tsx +152 -0
- package/src/components/shared/UniversalCarousel/CarouselStage.tsx +235 -0
- package/src/components/shared/UniversalCarousel/UniversalCarousel.tsx +125 -0
- package/src/components/shared/UniversalCarousel/helpers.ts +206 -0
- package/src/components/shared/UniversalCarousel/index.ts +4 -0
- package/src/helpers/children.ts +27 -0
- package/src/helpers/cookies.ts +22 -0
- package/src/helpers/dateFormat.ts +245 -0
- package/src/helpers/dateToYearMonthDay.ts +17 -0
- package/src/helpers/elementVisibility.ts +53 -0
- package/src/helpers/i18n.ts +197 -0
- package/src/helpers/price.ts +26 -0
- package/src/helpers/responsive-property.ts +118 -0
- package/src/helpers/screen.ts +14 -0
- package/src/helpers/sleep.ts +5 -0
- package/src/helpers/slot.tsx +68 -0
- package/src/helpers/ssr.ts +5 -0
- package/src/helpers/store.ts +75 -0
- package/src/helpers/types.ts +18 -0
- package/src/helpers/utils.ts +3 -0
- package/src/hooks/use-active-screen-names.ts +100 -0
- package/src/hooks/use-intersection-observer.ts +190 -0
- package/src/hooks/use-screen-name-at-least.ts +32 -0
- package/src/hooks/use-screen-name.ts +34 -0
- package/src/hooks/use-store.ts +45 -0
- package/src/hooks/use-toasts.ts +111 -0
- package/src/stores/toasts-store.ts +11 -0
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import type { FC } from 'react';
|
|
2
|
+
import { dynamicComponents as dynamicComponentsPictograms } from '../../../../icons/pictograms';
|
|
3
|
+
import { twMerge } from 'tailwind-merge';
|
|
4
|
+
|
|
5
|
+
type CollectionPictograms = typeof dynamicComponentsPictograms;
|
|
6
|
+
|
|
7
|
+
export type PictogramName = keyof CollectionPictograms;
|
|
8
|
+
|
|
9
|
+
type IconComponent = CollectionPictograms[PictogramName];
|
|
10
|
+
|
|
11
|
+
export type PictogramProps = {
|
|
12
|
+
className?: string;
|
|
13
|
+
name: PictogramName;
|
|
14
|
+
size?: number | 'sm' | 'md';
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Determines and returns width and height attributes based on the size parameter.
|
|
19
|
+
*/
|
|
20
|
+
const getSizeAttributes = (size: PictogramProps['size']) => {
|
|
21
|
+
switch (size) {
|
|
22
|
+
case 'sm':
|
|
23
|
+
return { width: '40', height: '40' };
|
|
24
|
+
case 'md':
|
|
25
|
+
return { width: '60', height: '60' };
|
|
26
|
+
default:
|
|
27
|
+
return {
|
|
28
|
+
width: size?.toString() || '40',
|
|
29
|
+
height: size?.toString() || '40',
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Renders the icon.
|
|
36
|
+
*/
|
|
37
|
+
const renderIcon = (
|
|
38
|
+
Element: IconComponent,
|
|
39
|
+
wrapperAttrs: Record<string, string>,
|
|
40
|
+
svgAttrs?: Record<string, string>,
|
|
41
|
+
) => {
|
|
42
|
+
const className = twMerge('inline-block', wrapperAttrs.className);
|
|
43
|
+
|
|
44
|
+
return (
|
|
45
|
+
<div {...wrapperAttrs} className={className}>
|
|
46
|
+
<Element {...svgAttrs} />
|
|
47
|
+
</div>
|
|
48
|
+
);
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Component to display an pictogram, based on the [local pictogram library](/docs/foundation-icons-pictograms--docs).
|
|
53
|
+
*/
|
|
54
|
+
const Pictogram: FC<PictogramProps> = ({ size = 'sm', name, ...rest }) => {
|
|
55
|
+
const Element = dynamicComponentsPictograms[name];
|
|
56
|
+
if (!Element) {
|
|
57
|
+
return null;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
const { width, height } = getSizeAttributes(size);
|
|
61
|
+
|
|
62
|
+
return renderIcon(Element, rest, { width, height, viewBox: '0 0 40 40' });
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
Pictogram.displayName = 'Pictogram';
|
|
66
|
+
|
|
67
|
+
export { Pictogram };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Pictogram';
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import * as PopoverPrimitive from '@radix-ui/react-popover';
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { IconButton } from '../../core/IconButton';
|
|
6
|
+
|
|
7
|
+
// Root component for the Popover.
|
|
8
|
+
const Popover = PopoverPrimitive.Root;
|
|
9
|
+
|
|
10
|
+
// Trigger component for opening the Popover.
|
|
11
|
+
const PopoverTrigger = PopoverPrimitive.Trigger;
|
|
12
|
+
|
|
13
|
+
// Anchor component for positioning the Popover.
|
|
14
|
+
const PopoverAnchor = PopoverPrimitive.Anchor;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Props for the PopoverContent component.
|
|
18
|
+
*/
|
|
19
|
+
export type PopoverContentProps = React.ComponentPropsWithoutRef<
|
|
20
|
+
typeof PopoverPrimitive.Content
|
|
21
|
+
>;
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* PopoverContent displays the content inside the popover.
|
|
25
|
+
*
|
|
26
|
+
* @param {PopoverContentProps} props - The properties for the PopoverContent.
|
|
27
|
+
* @returns {JSX.Element} The Popover content component.
|
|
28
|
+
*/
|
|
29
|
+
const PopoverContent = (props: PopoverContentProps) => {
|
|
30
|
+
const { align = 'center', sideOffset = 4, children } = props;
|
|
31
|
+
|
|
32
|
+
return (
|
|
33
|
+
<PopoverPrimitive.Portal>
|
|
34
|
+
<PopoverPrimitive.Content
|
|
35
|
+
align={align}
|
|
36
|
+
side={'top'}
|
|
37
|
+
sideOffset={sideOffset}
|
|
38
|
+
avoidCollisions
|
|
39
|
+
collisionPadding={16}
|
|
40
|
+
className="z-popover w-[312px] rounded-sm bg-surface-white px-4 pb-6 pt-2 drop-shadow-md md:max-w-[232px]"
|
|
41
|
+
>
|
|
42
|
+
<div className="flex">
|
|
43
|
+
<PopoverPrimitive.Close asChild>
|
|
44
|
+
<IconButton
|
|
45
|
+
iconName="cancel"
|
|
46
|
+
variant="ghost"
|
|
47
|
+
size="sm"
|
|
48
|
+
className="ml-auto"
|
|
49
|
+
aria-label="popover-close"
|
|
50
|
+
/>
|
|
51
|
+
</PopoverPrimitive.Close>
|
|
52
|
+
</div>
|
|
53
|
+
<div className="grid gap-2 text-marine-high-emphasis">{children}</div>
|
|
54
|
+
<div className="absolute bottom-0 left-0 right-0 z-10 h-2 w-full rounded-md bg-surface-white" />
|
|
55
|
+
<PopoverPrimitive.Arrow className="h-3 w-5 fill-white drop-shadow-md" />
|
|
56
|
+
</PopoverPrimitive.Content>
|
|
57
|
+
</PopoverPrimitive.Portal>
|
|
58
|
+
);
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Popover';
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { twMerge } from '@tui-cruises/mein-schiff-web-tailwind-config';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { twJoin } from 'tailwind-merge';
|
|
4
|
+
|
|
5
|
+
type Props = {
|
|
6
|
+
className?: string;
|
|
7
|
+
ports: string[];
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export const Portlist = ({ ports, className }: Props) => {
|
|
11
|
+
return (
|
|
12
|
+
<div className={twMerge('mt-2 flex-grow text-xs', className)}>
|
|
13
|
+
{ports.map((port, index) => (
|
|
14
|
+
<span
|
|
15
|
+
className={twJoin(
|
|
16
|
+
index === ports.length - 1 && 'font-semibold',
|
|
17
|
+
index === 0 && 'font-semibold',
|
|
18
|
+
)}
|
|
19
|
+
key={port}
|
|
20
|
+
>
|
|
21
|
+
{index === 1 ? ' → ' : ''}
|
|
22
|
+
{port}
|
|
23
|
+
{index < ports.length - 1 && index !== 0 ? ' → ' : ''}
|
|
24
|
+
</span>
|
|
25
|
+
))}
|
|
26
|
+
</div>
|
|
27
|
+
);
|
|
28
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Portlist';
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { Locale } from '@tuic/i18n';
|
|
4
|
+
import { InputHTMLAttributes, forwardRef, useEffect, useState } from 'react';
|
|
5
|
+
import { Price, formatPrice } from '../../../helpers/price';
|
|
6
|
+
|
|
7
|
+
type InputAttributes = Omit<
|
|
8
|
+
InputHTMLAttributes<HTMLInputElement>,
|
|
9
|
+
'className' | 'placeholder' | 'onChange' | 'value'
|
|
10
|
+
>;
|
|
11
|
+
|
|
12
|
+
export type PriceInputProps = InputAttributes & {
|
|
13
|
+
locale: Locale;
|
|
14
|
+
label?: string;
|
|
15
|
+
id?: string;
|
|
16
|
+
price?: Price;
|
|
17
|
+
onChangeValue?: (value: Price) => void;
|
|
18
|
+
onFinish?: (value: Price) => void;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
const PriceInput = forwardRef<HTMLInputElement, PriceInputProps>(
|
|
22
|
+
({ label, id, price, onChangeValue, onFinish, locale, ...rest }, ref) => {
|
|
23
|
+
const [formattedPrice, setFormattedPrice] = useState('');
|
|
24
|
+
|
|
25
|
+
useEffect(() => {
|
|
26
|
+
if (price) {
|
|
27
|
+
const formatted = formatPrice(locale, {
|
|
28
|
+
maximumFractionDigits: 0,
|
|
29
|
+
...price,
|
|
30
|
+
});
|
|
31
|
+
setFormattedPrice(formatted);
|
|
32
|
+
} else {
|
|
33
|
+
setFormattedPrice('');
|
|
34
|
+
}
|
|
35
|
+
}, [price]);
|
|
36
|
+
|
|
37
|
+
const handleChange = (ev: React.ChangeEvent<HTMLInputElement>) => {
|
|
38
|
+
const inputValue = parseInt(ev.target.value.replace(/\D/g, '')) || 0;
|
|
39
|
+
|
|
40
|
+
const newValue: Price = {
|
|
41
|
+
currency: price?.currency ?? '',
|
|
42
|
+
price: inputValue,
|
|
43
|
+
};
|
|
44
|
+
setFormattedPrice(ev.target.value);
|
|
45
|
+
onChangeValue && onChangeValue(newValue);
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
const handleBlur = (ev: React.ChangeEvent<HTMLInputElement>) => {
|
|
49
|
+
const inputValue = parseInt(ev.target.value.replace(/\D/g, '')) || 0;
|
|
50
|
+
|
|
51
|
+
const newValue: Price = {
|
|
52
|
+
currency: price?.currency ?? '',
|
|
53
|
+
price: inputValue,
|
|
54
|
+
};
|
|
55
|
+
setFormattedPrice(
|
|
56
|
+
formatPrice(locale, {
|
|
57
|
+
maximumFractionDigits: 0,
|
|
58
|
+
...newValue,
|
|
59
|
+
}),
|
|
60
|
+
);
|
|
61
|
+
onFinish && onFinish(newValue);
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
const handleKeyPress = (ev: React.KeyboardEvent<HTMLInputElement>) => {
|
|
65
|
+
if (ev.key === 'Enter') {
|
|
66
|
+
ev.preventDefault();
|
|
67
|
+
ev.currentTarget.blur();
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
return (
|
|
72
|
+
<div className="h-13 relative flex w-full items-center overflow-hidden rounded-sm border border-stroke-secondary-40 bg-surface-white px-2 py-1 text-base text-marine-high-emphasis focus-within:shadow-focus-state data-[invalid]:border-stroke-error-100">
|
|
73
|
+
<input
|
|
74
|
+
type="text"
|
|
75
|
+
placeholder=" "
|
|
76
|
+
value={formattedPrice}
|
|
77
|
+
onChange={handleChange}
|
|
78
|
+
onBlur={handleBlur}
|
|
79
|
+
onKeyDown={handleKeyPress}
|
|
80
|
+
ref={ref}
|
|
81
|
+
{...rest}
|
|
82
|
+
id={id}
|
|
83
|
+
className="peer mt-4 flex-1 pl-1 text-marine-high-emphasis focus:outline-none"
|
|
84
|
+
/>
|
|
85
|
+
{label && (
|
|
86
|
+
<label
|
|
87
|
+
htmlFor={id}
|
|
88
|
+
className="absolute left-3 top-0 my-auto cursor-text text-xs text-secondary-marine-48 transition-all peer-placeholder-shown:top-auto peer-placeholder-shown:text-base"
|
|
89
|
+
>
|
|
90
|
+
{label}
|
|
91
|
+
</label>
|
|
92
|
+
)}
|
|
93
|
+
</div>
|
|
94
|
+
);
|
|
95
|
+
},
|
|
96
|
+
);
|
|
97
|
+
|
|
98
|
+
PriceInput.displayName = 'PriceInput';
|
|
99
|
+
|
|
100
|
+
export { PriceInput };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './PriceInput';
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { FC, HTMLAttributes } from 'react';
|
|
2
|
+
import { twMerge } from 'tailwind-merge';
|
|
3
|
+
import { Icon } from '../Icon';
|
|
4
|
+
|
|
5
|
+
export type QuantityItemProps = {
|
|
6
|
+
current: number;
|
|
7
|
+
max: number;
|
|
8
|
+
variant?: 'dark' | 'light';
|
|
9
|
+
} & HTMLAttributes<HTMLDivElement>;
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* QuantityItem component displays the current quantity out of a maximum value.
|
|
13
|
+
*/
|
|
14
|
+
export const QuantityItem: FC<QuantityItemProps> = ({
|
|
15
|
+
current,
|
|
16
|
+
max,
|
|
17
|
+
className,
|
|
18
|
+
variant = 'dark',
|
|
19
|
+
...props
|
|
20
|
+
}) => {
|
|
21
|
+
const derivedClassName = twMerge(
|
|
22
|
+
'inline-flex items-center justify-center gap-1 rounded-md px-2 py-1 text-sm font-semibold tracking-wider',
|
|
23
|
+
className,
|
|
24
|
+
variant === 'dark'
|
|
25
|
+
? 'bg-opacity-black-60 text-white'
|
|
26
|
+
: 'bg-surface-white text-marine-high-emphasis',
|
|
27
|
+
);
|
|
28
|
+
|
|
29
|
+
return (
|
|
30
|
+
<div className={derivedClassName} {...props}>
|
|
31
|
+
<Icon name="media-image-list" size="sm" />
|
|
32
|
+
<span>
|
|
33
|
+
{current}/{max}
|
|
34
|
+
</span>
|
|
35
|
+
</div>
|
|
36
|
+
);
|
|
37
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './QuantityItem';
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import type { ForwardRefRenderFunction, InputHTMLAttributes } from 'react';
|
|
4
|
+
import { forwardRef, useEffect, useImperativeHandle, useRef } from 'react';
|
|
5
|
+
import { twJoin } from 'tailwind-merge';
|
|
6
|
+
|
|
7
|
+
type BaseProps = {
|
|
8
|
+
invalid?: string;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export type RadioProps = BaseProps &
|
|
12
|
+
Omit<InputHTMLAttributes<HTMLInputElement>, keyof BaseProps | 'type'>;
|
|
13
|
+
|
|
14
|
+
const RadioRenderFunction: ForwardRefRenderFunction<
|
|
15
|
+
HTMLInputElement | null,
|
|
16
|
+
RadioProps
|
|
17
|
+
> = ({ invalid, ...attrs }, forwardedRef) => {
|
|
18
|
+
const ref = useRef<HTMLInputElement | null>(null);
|
|
19
|
+
|
|
20
|
+
useImperativeHandle<HTMLInputElement | null, HTMLInputElement | null>(
|
|
21
|
+
forwardedRef,
|
|
22
|
+
() => ref.current,
|
|
23
|
+
);
|
|
24
|
+
|
|
25
|
+
useEffect(() => {
|
|
26
|
+
ref.current?.setCustomValidity(invalid ?? '');
|
|
27
|
+
}, [ref, invalid]);
|
|
28
|
+
|
|
29
|
+
return (
|
|
30
|
+
<input
|
|
31
|
+
{...attrs}
|
|
32
|
+
className={twJoin(
|
|
33
|
+
'relative size-8 flex-shrink-0 appearance-none rounded-full md:size-6',
|
|
34
|
+
'border border-stroke-primary-100',
|
|
35
|
+
'before:absolute before:inset-2 before:hidden before:rounded-full before:bg-surface-white md:before:inset-1.5',
|
|
36
|
+
'hover:cursor-pointer',
|
|
37
|
+
'checked:border-transparent checked:bg-surface-primary-100',
|
|
38
|
+
'checked:before:block',
|
|
39
|
+
'disabled:border-stroke-secondary-40 disabled:hover:cursor-not-allowed disabled:hover:bg-transparent',
|
|
40
|
+
'invalid:border-stroke-error-100',
|
|
41
|
+
'focus:outline-none focus-visible:shadow-focus-state',
|
|
42
|
+
)}
|
|
43
|
+
type="radio"
|
|
44
|
+
ref={ref}
|
|
45
|
+
/>
|
|
46
|
+
);
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Radio
|
|
51
|
+
*
|
|
52
|
+
* <Radio />
|
|
53
|
+
*
|
|
54
|
+
* ## Invalid Radios (Radios with Errors)
|
|
55
|
+
*
|
|
56
|
+
* Provide an error message in the `invalid` attribute to mark the checkbox as errored.
|
|
57
|
+
*
|
|
58
|
+
* ```tsx
|
|
59
|
+
* <Radio invalid="You can't select this." />
|
|
60
|
+
* ```
|
|
61
|
+
*/
|
|
62
|
+
export const Radio = forwardRef<HTMLInputElement | null, RadioProps>(
|
|
63
|
+
RadioRenderFunction,
|
|
64
|
+
);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Radio';
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
ForwardRefRenderFunction,
|
|
5
|
+
ReactNode,
|
|
6
|
+
useEffect,
|
|
7
|
+
useImperativeHandle,
|
|
8
|
+
useRef,
|
|
9
|
+
} from 'react';
|
|
10
|
+
import { forwardRef } from 'react';
|
|
11
|
+
import { Radio, RadioProps } from '../Radio';
|
|
12
|
+
import { Item as RadixItem } from '@radix-ui/react-radio-group';
|
|
13
|
+
|
|
14
|
+
type Props = {
|
|
15
|
+
label?: ReactNode;
|
|
16
|
+
note?: ReactNode;
|
|
17
|
+
error?: string;
|
|
18
|
+
asRadix?: boolean;
|
|
19
|
+
} & RadioProps;
|
|
20
|
+
|
|
21
|
+
const RadioFieldRenderFunction: ForwardRefRenderFunction<
|
|
22
|
+
HTMLInputElement | null,
|
|
23
|
+
Props
|
|
24
|
+
> = ({ label, note, error, asRadix, ...attrs }, forwardedRef) => {
|
|
25
|
+
let inputRef = useRef<HTMLInputElement>(null);
|
|
26
|
+
|
|
27
|
+
useImperativeHandle<HTMLInputElement | null, HTMLInputElement | null>(
|
|
28
|
+
forwardedRef,
|
|
29
|
+
() => inputRef.current,
|
|
30
|
+
);
|
|
31
|
+
|
|
32
|
+
useEffect(() => {
|
|
33
|
+
if (asRadix) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
inputRef.current?.setCustomValidity(error ?? '');
|
|
38
|
+
}, [asRadix, error]);
|
|
39
|
+
|
|
40
|
+
return (
|
|
41
|
+
<div className="space-y-1">
|
|
42
|
+
<label className="flex cursor-pointer gap-2 text-marine-high-emphasis">
|
|
43
|
+
{!asRadix && <Radio {...attrs} ref={inputRef} />}
|
|
44
|
+
|
|
45
|
+
{asRadix && (
|
|
46
|
+
<RadixItem asChild value={(attrs.value ?? '').toString()}>
|
|
47
|
+
<Radio {...attrs} />
|
|
48
|
+
</RadixItem>
|
|
49
|
+
)}
|
|
50
|
+
|
|
51
|
+
{(label || note) && (
|
|
52
|
+
<div>
|
|
53
|
+
{label && <div className="font-semibold">{label}</div>}
|
|
54
|
+
{note && <div className="text-sm">{note}</div>}
|
|
55
|
+
</div>
|
|
56
|
+
)}
|
|
57
|
+
</label>
|
|
58
|
+
|
|
59
|
+
{error && <div className="text-sm text-error-100">{error}</div>}
|
|
60
|
+
</div>
|
|
61
|
+
);
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
export const RadioField = forwardRef<HTMLInputElement | null, Props>(
|
|
65
|
+
RadioFieldRenderFunction,
|
|
66
|
+
);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './RadioField';
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
Root,
|
|
5
|
+
Item,
|
|
6
|
+
Indicator,
|
|
7
|
+
RadioGroupItemProps,
|
|
8
|
+
} from '@radix-ui/react-radio-group';
|
|
9
|
+
import { twMerge } from '@tui-cruises/mein-schiff-web-tailwind-config';
|
|
10
|
+
import React, {
|
|
11
|
+
ComponentPropsWithoutRef,
|
|
12
|
+
forwardRef,
|
|
13
|
+
ForwardRefRenderFunction,
|
|
14
|
+
} from 'react';
|
|
15
|
+
|
|
16
|
+
export const RadixRadioGroup = Root;
|
|
17
|
+
|
|
18
|
+
const RadioRenderFunction: ForwardRefRenderFunction<
|
|
19
|
+
HTMLButtonElement,
|
|
20
|
+
RadioGroupItemProps
|
|
21
|
+
> = (props, ref) => {
|
|
22
|
+
return (
|
|
23
|
+
<Item
|
|
24
|
+
ref={ref}
|
|
25
|
+
{...props}
|
|
26
|
+
className={twMerge(
|
|
27
|
+
'focus-visible:ring-ring text-primary aspect-square size-8 rounded-full border-stroke-primary-100 ring-offset-background focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=unchecked]:border data-[state=checked]:bg-surface-primary-100 md:size-6',
|
|
28
|
+
props.className,
|
|
29
|
+
)}
|
|
30
|
+
>
|
|
31
|
+
<Indicator className="flex items-center justify-center">
|
|
32
|
+
<div className="size-4 rounded-full bg-surface-white md:size-3" />
|
|
33
|
+
</Indicator>
|
|
34
|
+
</Item>
|
|
35
|
+
);
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
type RadioItemProps = {
|
|
39
|
+
label: string;
|
|
40
|
+
id: string;
|
|
41
|
+
} & ComponentPropsWithoutRef<typeof RadixRadiobutton>;
|
|
42
|
+
export function RadixRadioItem({ label, id, ...props }: RadioItemProps) {
|
|
43
|
+
return (
|
|
44
|
+
<div className="inline-flex flex-row items-center gap-2">
|
|
45
|
+
<RadixRadiobutton id={id} {...props} />
|
|
46
|
+
<label className="label-md select-none" htmlFor={id}>
|
|
47
|
+
{label}
|
|
48
|
+
</label>
|
|
49
|
+
</div>
|
|
50
|
+
);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export const RadixRadiobutton = forwardRef<
|
|
54
|
+
HTMLButtonElement,
|
|
55
|
+
RadioGroupItemProps
|
|
56
|
+
>(RadioRenderFunction);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './RadixRadio';
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import React, { PropsWithChildren, ReactNode } from 'react';
|
|
4
|
+
import * as SelectPrimitive from '@radix-ui/react-select';
|
|
5
|
+
import { Icon } from '../../core/Icon';
|
|
6
|
+
import { twJoin } from 'tailwind-merge';
|
|
7
|
+
|
|
8
|
+
export type RadixSelectProps = PropsWithChildren<{
|
|
9
|
+
variant?: 'block' | 'inline';
|
|
10
|
+
ariaLabel?: string;
|
|
11
|
+
placeholder?: string;
|
|
12
|
+
triggerClassName?: string;
|
|
13
|
+
freeFloating?: boolean;
|
|
14
|
+
showUpDownButtons?: boolean;
|
|
15
|
+
displayValue?: ReactNode;
|
|
16
|
+
align?: 'start' | 'center' | 'end';
|
|
17
|
+
withFlexibleWidth?: boolean;
|
|
18
|
+
}> &
|
|
19
|
+
React.ComponentPropsWithoutRef<typeof SelectPrimitive.Root>;
|
|
20
|
+
|
|
21
|
+
export type RadixSelectItemProps = PropsWithChildren<{
|
|
22
|
+
className?: string;
|
|
23
|
+
}> &
|
|
24
|
+
React.ComponentPropsWithoutRef<typeof SelectPrimitive.Item>;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* `Select` provides a customizable dropdown menu for users to select an option. It uses Radix UI primitives for accessibility and flexibility.
|
|
28
|
+
*
|
|
29
|
+
* ## Basic Usage
|
|
30
|
+
*
|
|
31
|
+
* To use the Select component, wrap `SelectItem` components inside it. You can provide `ariaLabel` and `placeholder` as props to customize the accessible label and placeholder text.
|
|
32
|
+
*
|
|
33
|
+
* ```tsx
|
|
34
|
+
* <Select ariaLabel="Choose an option" placeholder="Select one">
|
|
35
|
+
* <SelectItem>Option 1</SelectItem>
|
|
36
|
+
* <SelectItem>Option 2</SelectItem>
|
|
37
|
+
* </Select>
|
|
38
|
+
* ```
|
|
39
|
+
*
|
|
40
|
+
* `SelectItem` represents an individual option within the Select dropdown. It can be customized with a className for specific styling needs.
|
|
41
|
+
*
|
|
42
|
+
* ## Basic Usage of SelectItem
|
|
43
|
+
*
|
|
44
|
+
* `SelectItem` is used within `Select` to represent the options. You can pass children to define the content of each option.
|
|
45
|
+
*
|
|
46
|
+
* ```tsx
|
|
47
|
+
* <Select>
|
|
48
|
+
* <SelectItem className="custom-select-item-style">Option 1</SelectItem>
|
|
49
|
+
* <SelectItem>Option 2</SelectItem>
|
|
50
|
+
* </Select>
|
|
51
|
+
* ```
|
|
52
|
+
*
|
|
53
|
+
* ## Disabled SelectItem
|
|
54
|
+
*
|
|
55
|
+
* To disable a specific option, set the `disabled` prop on `SelectItem`.
|
|
56
|
+
*
|
|
57
|
+
* ```tsx
|
|
58
|
+
* <Select>
|
|
59
|
+
* <SelectItem disabled>Disabled Option</SelectItem>
|
|
60
|
+
* <SelectItem>Option 2</SelectItem>
|
|
61
|
+
* </Select>
|
|
62
|
+
* ```
|
|
63
|
+
*/
|
|
64
|
+
|
|
65
|
+
export const RadixSelect = React.forwardRef<
|
|
66
|
+
HTMLButtonElement,
|
|
67
|
+
RadixSelectProps
|
|
68
|
+
>(
|
|
69
|
+
(
|
|
70
|
+
{
|
|
71
|
+
children,
|
|
72
|
+
ariaLabel = 'Auswahl',
|
|
73
|
+
variant = 'block',
|
|
74
|
+
triggerClassName,
|
|
75
|
+
placeholder,
|
|
76
|
+
showUpDownButtons = false,
|
|
77
|
+
freeFloating = false,
|
|
78
|
+
withFlexibleWidth = false,
|
|
79
|
+
align = 'start',
|
|
80
|
+
displayValue,
|
|
81
|
+
...props
|
|
82
|
+
},
|
|
83
|
+
forwardedRef,
|
|
84
|
+
) => {
|
|
85
|
+
return (
|
|
86
|
+
<SelectPrimitive.Root {...props}>
|
|
87
|
+
<SelectPrimitive.Trigger
|
|
88
|
+
ref={forwardedRef}
|
|
89
|
+
className={twJoin(
|
|
90
|
+
variant == 'block' &&
|
|
91
|
+
twJoin(
|
|
92
|
+
'inline-flex h-[58px] w-full items-center justify-between p-4',
|
|
93
|
+
'rounded-md border border-stroke-secondary-40 bg-surface-white text-base text-marine-high-emphasis outline-none',
|
|
94
|
+
'focus:outline-none focus-visible:shadow-focus-state',
|
|
95
|
+
'hover:border-stroke-secondary-40',
|
|
96
|
+
'disabled:cursor-not-allowed',
|
|
97
|
+
'data-[invalid]:border-stroke-error-100',
|
|
98
|
+
'data-[placeholder]:text-secondary-marine-48',
|
|
99
|
+
'data-[state=open]:rounded-b-none data-[state=open]:border-b-transparent data-[state=open]:shadow-md',
|
|
100
|
+
),
|
|
101
|
+
variant == 'inline' && 'inline-flex flex-row items-center gap-2',
|
|
102
|
+
triggerClassName,
|
|
103
|
+
)}
|
|
104
|
+
aria-label={ariaLabel}
|
|
105
|
+
>
|
|
106
|
+
<SelectPrimitive.Value placeholder={placeholder}>
|
|
107
|
+
{displayValue}
|
|
108
|
+
</SelectPrimitive.Value>
|
|
109
|
+
<SelectPrimitive.Icon className="text-marine-high-emphasis">
|
|
110
|
+
<Icon name="nav-arrow-down" size="sm" />
|
|
111
|
+
</SelectPrimitive.Icon>
|
|
112
|
+
</SelectPrimitive.Trigger>
|
|
113
|
+
<SelectPrimitive.Portal>
|
|
114
|
+
<SelectPrimitive.Content
|
|
115
|
+
className={twJoin(
|
|
116
|
+
'z-[50000] overflow-hidden bg-surface-white shadow-md',
|
|
117
|
+
'border border-stroke-secondary-40',
|
|
118
|
+
'max-h-[var(--radix-select-content-available-height)] ',
|
|
119
|
+
!withFlexibleWidth && 'w-[var(--radix-select-trigger-width)]',
|
|
120
|
+
!freeFloating && 'border-t-0 rounded-b-md',
|
|
121
|
+
freeFloating && 'rounded-md',
|
|
122
|
+
)}
|
|
123
|
+
position="popper"
|
|
124
|
+
align={align}
|
|
125
|
+
>
|
|
126
|
+
{showUpDownButtons && (
|
|
127
|
+
<SelectPrimitive.ScrollUpButton className="SelectScrollButton">
|
|
128
|
+
<Icon name="nav-arrow-up" />
|
|
129
|
+
</SelectPrimitive.ScrollUpButton>
|
|
130
|
+
)}
|
|
131
|
+
|
|
132
|
+
<SelectPrimitive.Viewport className="pb-2">
|
|
133
|
+
{children}
|
|
134
|
+
</SelectPrimitive.Viewport>
|
|
135
|
+
|
|
136
|
+
{showUpDownButtons && (
|
|
137
|
+
<SelectPrimitive.ScrollDownButton className="SelectScrollButton">
|
|
138
|
+
<Icon name="nav-arrow-down" />
|
|
139
|
+
</SelectPrimitive.ScrollDownButton>
|
|
140
|
+
)}
|
|
141
|
+
</SelectPrimitive.Content>
|
|
142
|
+
</SelectPrimitive.Portal>
|
|
143
|
+
</SelectPrimitive.Root>
|
|
144
|
+
);
|
|
145
|
+
},
|
|
146
|
+
);
|
|
147
|
+
|
|
148
|
+
export const RadixSelectItem = React.forwardRef<
|
|
149
|
+
HTMLDivElement,
|
|
150
|
+
RadixSelectItemProps
|
|
151
|
+
>(({ children, className, ...props }, forwardedRef) => {
|
|
152
|
+
return (
|
|
153
|
+
<SelectPrimitive.Item
|
|
154
|
+
className={twJoin(
|
|
155
|
+
'flex cursor-pointer select-none items-center px-4 py-3',
|
|
156
|
+
'data-[disabled]:pointer-events-none data-[highlighted]:border-stroke-secondary-40 data-[disabled]:text-marine-high-emphasis data-[highlighted]:outline-none',
|
|
157
|
+
'focus:bg-surface-secondary-10',
|
|
158
|
+
'data-[state=checked]:font-semibold',
|
|
159
|
+
className,
|
|
160
|
+
)}
|
|
161
|
+
{...props}
|
|
162
|
+
ref={forwardedRef}
|
|
163
|
+
>
|
|
164
|
+
<SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>
|
|
165
|
+
{/*
|
|
166
|
+
<SelectPrimitive.ItemIndicator className="absolute left-2 inline-flex items-center justify-center">
|
|
167
|
+
<Icon name="check" />
|
|
168
|
+
</SelectPrimitive.ItemIndicator>
|
|
169
|
+
*/}
|
|
170
|
+
</SelectPrimitive.Item>
|
|
171
|
+
);
|
|
172
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './RadixSelect';
|