diff --git a/src/app/cars/[id]/page.jsx b/src/app/cars/[id]/page.jsx new file mode 100644 index 0000000..9566897 --- /dev/null +++ b/src/app/cars/[id]/page.jsx @@ -0,0 +1,195 @@ +import React from 'react'; +import { ChevronLeft, ChevronRight } from 'lucide-react'; + +const CarDetailsPage = () => { + // Dados de exemplo (depois virão do backend) + const car = { + id: 1, + name: 'BMW M4 2024', + images: [ + '/api/placeholder/800/400', + '/api/placeholder/800/400', + '/api/placeholder/800/400', + '/api/placeholder/800/400' + ], + technical: { + engine: { + layout: 'Inline', + volume: '3 L', + type: 'RWD', + power: '374 hp', + powerKW: '275 kW', + torque: '369', + compression: '10.2:1' + }, + performance: { + topSpeed: '155 mph', + acceleration: '4.7 s' + }, + transmission: { + type: 'Automatic', + gears: '8' + } + }, + extras: [ + 'ABS', + 'Auxiliary heating', + 'Bluetooth', + 'ESP', + 'Full LED headlights', + 'Monitoring system', + 'Nitro', + 'Storage package', + 'Turbo-engine' + ] + }; + + const [currentImage, setCurrentImage] = React.useState(0); + + return ( +
+ {/* Header */} +
+
+
+ LOGO +
+
+
+ +
+ {/* Car Title */} +

{car.name}

+ + {/* Image Gallery */} +
+
+ {`${car.name} + + +
+
+ {car.images.map((img, idx) => ( + {`${car.name} setCurrentImage(idx)} + /> + ))} +
+
+ + {/* Technical Specifications */} +
+

Technical

+ +
+ {/* Engine Section */} +
+
+ ⚙️ +

Engine

+
+
+ {Object.entries(car.technical.engine).map(([key, value]) => ( +
+ {key.replace('_', ' ')} + {value} +
+ ))} +
+
+ + {/* Performance & Transmission */} +
+
+
+ 🎯 +

Performance

+
+
+ {Object.entries(car.technical.performance).map(([key, value]) => ( +
+ {key.replace('_', ' ')} + {value} +
+ ))} +
+
+ +
+
+ 🔄 +

Transmission

+
+
+ {Object.entries(car.technical.transmission).map(([key, value]) => ( +
+ {key.replace('_', ' ')} + {value} +
+ ))} +
+
+
+
+
+ + {/* Extras/Features */} +
+

Features & Extras

+
+ {car.extras.map((extra, idx) => ( +
+
+ + + +
+ {extra} +
+ ))} +
+
+
+ + {/* Footer */} + +
+ ); +}; + +export default CarDetailsPage;