File tree Expand file tree Collapse file tree
ui/src/components/forms/stop/components Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import { useTranslation } from 'react-i18next';
55import { Link } from 'react-router' ;
66import { twMerge } from 'tailwind-merge' ;
77import { useObservationDateQueryParam } from '../../../../hooks' ;
8+ import { mapVehicleModeToUiName } from '../../../../i18n/uiNameMappings' ;
89import { Path , routeDetails } from '../../../../router/routeDetails' ;
910import { ExpandButton } from '../../../../uiComponents' ;
1011import { LabeledDetail } from '../../../stop-registry/stops/stop-details/layout' ;
@@ -45,6 +46,9 @@ export const StopAreaInfoSection: FC<StopAreaInfoSectionProps> = ({
4546 } ) ;
4647
4748 const stopArea = useWatch < StopFormState , 'stopArea' > ( { name : 'stopArea' } ) ;
49+ const vehicleMode = useWatch < StopFormState , 'vehicleMode' > ( {
50+ name : 'vehicleMode' ,
51+ } ) ;
4852
4953 if ( ! stopArea ) {
5054 return null ;
@@ -143,6 +147,13 @@ export const StopAreaInfoSection: FC<StopAreaInfoSectionProps> = ({
143147 </ >
144148 ) }
145149 </ Transition >
150+
151+ { vehicleMode && (
152+ < span className = "mt-1 font-bold" >
153+ { t ( 'stopArea.transportMode' ) } :{ ' ' }
154+ { mapVehicleModeToUiName ( t , vehicleMode ) }
155+ </ span >
156+ ) }
146157 </ div >
147158 ) ;
148159} ;
You can’t perform that action at this time.
0 commit comments