@@ -3,8 +3,8 @@ import maplibregl from 'maplibre-gl';
33import 'maplibre-gl/dist/maplibre-gl.css' ;
44import { AvalancheReportCard } from './AvalancheReportCard' ;
55import { logger } from '../utils/logger' ;
6- import { Navigation } from 'lucide-react ' ;
7- import { Region } from '../config/regions ' ;
6+ import type { Region } from '../config/regions ' ;
7+ import { ArrowLeft , Navigation2 , AlertCircle , AlertTriangle , Loader2 , ArrowRightLeft , Navigation } from 'lucide-react ' ;
88
99interface RouteStats {
1010 travelTime : string ;
@@ -481,8 +481,8 @@ export const RoutePlanner: React.FC<RoutePlannerProps> = ({
481481 </ div >
482482 </ div >
483483
484- < div style = { { display : 'flex' , gap : '1rem' , marginBottom : '1rem' } } >
485- < div style = { { flex : 1 } } >
484+ < div className = "route-inputs-grid" >
485+ < div style = { { flex : 1 , width : '100%' } } >
486486 < label style = { { display : 'block' , marginBottom : '0.5rem' , fontWeight : 500 } } > From</ label >
487487 < select
488488 value = { from }
@@ -498,7 +498,22 @@ export const RoutePlanner: React.FC<RoutePlannerProps> = ({
498498 ) ) }
499499 </ select >
500500 </ div >
501- < div style = { { flex : 1 } } >
501+
502+ < div
503+ className = "route-swap-btn"
504+ onClick = { ( ) => {
505+ const temp = from ;
506+ onFromChange ( destination ) ;
507+ onDestinationChange ( temp ) ;
508+ } }
509+ title = "Swap Origin and Destination"
510+ role = "button"
511+ tabIndex = { 0 }
512+ >
513+ < ArrowRightLeft size = { 20 } />
514+ </ div >
515+
516+ < div style = { { flex : 1 , width : '100%' } } >
502517 < label style = { { display : 'block' , marginBottom : '0.5rem' , fontWeight : 500 } } > To</ label >
503518 < select
504519 value = { destination }
0 commit comments