import React from 'react'; import { StyleSheet } from 'react-native'; import { useTheme, Surface } from 'react-native-paper'; import { LeafletMap } from './LeafletMap'; import type { LatLng } from '../../types/location'; export interface RoutePreviewProps { /** Origin coordinate */ origin: LatLng; /** Destination coordinate */ destination: LatLng; /** Height of the preview in dp (default 180) */ height?: number; /** Optional color for the route polyline */ polylineColor?: string; } /** * Small, non-interactive map showing a route polyline between two * points. Wrapped in a Surface with rounded corners. */ export function RoutePreview({ origin, destination, height = 180, polylineColor = '#1B6B4D', }: RoutePreviewProps) { const theme = useTheme(); // Calculate a center point between origin and destination const centerLat = (origin.lat + destination.lat) / 2; const centerLng = (origin.lng + destination.lng) / 2; return ( ); } const styles = StyleSheet.create({ container: { overflow: 'hidden', }, });