Updated metar querying logic and parsing
This commit is contained in:
@@ -4,7 +4,12 @@ import { Metar } from './metar.types';
|
||||
export enum AirportCategory {
|
||||
SMALL = 'small_airport',
|
||||
MEDIUM = 'medium_airport',
|
||||
LARGE = 'large_airport'
|
||||
LARGE = 'large_airport',
|
||||
HELIPORT = 'heliport',
|
||||
BALLOONPORT = 'balloonport',
|
||||
CLOSED = 'closed',
|
||||
SEAPLANE = 'seaplane_base',
|
||||
UNKNOWN = 'unknown',
|
||||
}
|
||||
|
||||
export function airportCategoryToText(category: AirportCategory): string {
|
||||
@@ -15,6 +20,16 @@ export function airportCategoryToText(category: AirportCategory): string {
|
||||
return 'Medium';
|
||||
case AirportCategory.LARGE:
|
||||
return 'Large';
|
||||
case AirportCategory.HELIPORT:
|
||||
return 'Helipad';
|
||||
case AirportCategory.CLOSED:
|
||||
return 'Closed';
|
||||
case AirportCategory.SEAPLANE:
|
||||
return 'Seaplane Base';
|
||||
case AirportCategory.BALLOONPORT:
|
||||
return 'Balloonport';
|
||||
default:
|
||||
return 'Unknown';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ export default function MapTiles() {
|
||||
northEast: { lat: ne.lat, lon: ne.lng },
|
||||
southWest: { lat: sw.lat, lon: sw.lng }
|
||||
},
|
||||
categories: ['small_airport', 'medium_airport', 'large_airport'],
|
||||
categories: ['large_airport'],
|
||||
order_field: AirportOrderField.CATEGORY,
|
||||
order_by: 'asc',
|
||||
limit: 250,
|
||||
|
||||
Reference in New Issue
Block a user