From e30111018453b2eae498ebaaa799a069c90bea68 Mon Sep 17 00:00:00 2001 From: Daniel Rosel Date: Mon, 24 Nov 2025 23:49:31 +0100 Subject: [PATCH] refactored design --- .../feats/airline/AirlineDetails.tsx | 114 ++++++++---------- .../components/feats/hotel/HotelDetails.tsx | 100 +++++++-------- 2 files changed, 103 insertions(+), 111 deletions(-) diff --git a/web/src/components/feats/airline/AirlineDetails.tsx b/web/src/components/feats/airline/AirlineDetails.tsx index 295c5a7..d68ea6f 100644 --- a/web/src/components/feats/airline/AirlineDetails.tsx +++ b/web/src/components/feats/airline/AirlineDetails.tsx @@ -10,73 +10,65 @@ interface AirlineDetailsProps { export default function AirlineDetails({ product, onAddToCart, addedToCart }: AirlineDetailsProps) { return ( -
-
- Flight Image +
+ {/* Image Section */} +
+ Flight Image
-
-

{product.flightType}

-

{product.cabinClass} Class

-
- -
-
-

Departure

-

{product.departure.time}

-

{product.departure.airport}

-
-
-

Arrival

-

{product.arrival.time}

-

{product.arrival.airport}

-
-
- -
-
-

Duration

-

{product.duration}

-
-
-

Stops

-

- {product.stops === 0 ? 'Nonstop' : `${product.stops} stop${product.stops > 1 ? 's' : ''}`} -

-
-
-

Availability

-

{product.availability} seats

-
-
- -
-

Fare Details

-

{product.fareRule}

- {product.refundable && ( -
-

Refundable fare

-
- )} -
- -
-
+ {/* Details Section */} +
+
-

Total price

-

${product.basePrice}

+

{product.flightType}

+

{product.cabinClass} Class

+
+
+

${product.basePrice}

+ {product.refundable && ( + + Refundable + + )}
-
-
- +
+
+

{product.departure.time}

+

{product.departure.airport}

+
+ +
+

{product.duration}

+
+
+
+

+ {product.stops === 0 ? 'Nonstop' : `${product.stops} stop${product.stops > 1 ? 's' : ''}`} +

+
+ +
+

{product.arrival.time}

+

{product.arrival.airport}

+
+
+ +
+
+ {product.availability} seats remaining + + {product.fareRule} +
+ +
); diff --git a/web/src/components/feats/hotel/HotelDetails.tsx b/web/src/components/feats/hotel/HotelDetails.tsx index f270edf..498a1f9 100644 --- a/web/src/components/feats/hotel/HotelDetails.tsx +++ b/web/src/components/feats/hotel/HotelDetails.tsx @@ -10,64 +10,64 @@ interface HotelDetailsProps { export default function HotelDetails({ product, onAddToCart, addedToCart }: HotelDetailsProps) { return ( -
-
- Hotel Image +
+ {/* Image Section - Larger and cleaner */} +
+ Hotel Image
-
-

{product.name}

-

{product.roomType}

-
- -
-
-

Check-in

-

{product.checkIn}

+ {/* Details Section - Full height/width usage */} +
+
+

{product.name}

+

{product.roomType}

-
-

Check-out

-

{product.checkOut}

-
-
-
-

Amenities

-
- {product.amenities.map(a => ( - - {a} - - ))} -
-
- - {product.refundable && ( -
-

Free cancellation available

-
- )} - -
-
+
-

Price per night

-

${product.pricePerNight}

-

- Total for {product.nights} night{product.nights > 1 ? 's' : ''}: ${product.pricePerNight * product.nights} -

+

Check-in

+

{product.checkIn}

+
+
+

Check-out

+

{product.checkOut}

-
-
- +
+

Amenities

+
+ {product.amenities.map(a => ( + + {a} + + ))} +
+
+ + {product.refundable && ( +
+ Free cancellation available +
+ )} + +
+
+

Total for {product.nights} night{product.nights > 1 ? 's' : ''}

+
+ ${product.pricePerNight * product.nights} + / {product.nights} nights +
+
+ + +
);