Skip to content

Commit

Permalink
Merge branch 'master' into nearby-view-support
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-heppner-ibigroup committed Nov 13, 2023
2 parents 694575d + 68a603e commit 1354178
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 15 deletions.
13 changes: 5 additions & 8 deletions packages/building-blocks/package.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,18 @@
{
"name": "@opentripplanner/building-blocks",
"version": "1.0.0",
"description": "Styling and UI Component Lbrary",
"version": "1.0.1",
"description": "Styling and UI Component Library",
"author": "@binh-dam-ibigroup",
"homepage": "https://github.com/opentripplanner/otp-ui/#readme",
"license": "MIT",
"main": "lib/index.js",
"module": "esm/index.js",
"private": false,
"dependencies": {
"mapbox-gl": "npm:[email protected]",
"maplibre-gl": "^2.1.9",
"react-map-gl": "^7.0.15",
"@opentripplanner/core-utils": "11.1.2"
"devDependencies": {
"@opentripplanner/core-utils": "^11.1.3"
},
"peerDependencies": {
"@opentripplanner/types": "^6.1.1",
"@opentripplanner/types": "^6.2.0",
"react": "^16.14.0",
"styled-components": "^5.3.0"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/core-utils/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentripplanner/core-utils",
"version": "11.1.2",
"version": "11.1.3",
"description": "Core functionality that is shared among numerous UI components",
"engines": {
"node": ">=13"
Expand Down
7 changes: 7 additions & 0 deletions packages/core-utils/src/planQuery.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,13 @@ query Plan(
timezone
url
}
alerts {
alertDescriptionText
alertHeaderText
alertUrl
effectiveStartDate
id
}
arrivalDelay
departureDelay
distance
Expand Down
2 changes: 1 addition & 1 deletion packages/geocoder/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentripplanner/geocoder",
"version": "1.4.2",
"version": "2.0.0",
"description": "Geocoding tools for multiple geocoding providers",
"main": "lib/index.js",
"module": "esm/index.js",
Expand Down
5 changes: 3 additions & 2 deletions packages/geocoder/src/apis/otp/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,12 @@ type OTPGeocoderResponse = {
results: {
coordinate: {
lat: number,
lng: number,
lon: number,
},
code: string,
name: string,
id: string
id: string,
modes: string[]
}[]
} | undefined

Expand Down
4 changes: 2 additions & 2 deletions packages/geocoder/src/geocoders/otp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ export default class OTPGeocoder extends Geocoder {
rewriteAutocompleteResponse(response: OTPGeocoderResponse): MultiGeocoderResponse {
return {
features: response?.results?.map(stop => ({
geometry: { type: "Point", coordinates: [stop.coordinate.lng, stop.coordinate.lat] },
geometry: { type: "Point", coordinates: [stop.coordinate.lon, stop.coordinate.lat] },
id: stop.id,
// TODO: if non-stops are supported, these need to be detected here and
// this layer property updated accordingly
properties: { layer: "stops", source: "otp", name: stop.name, label: stop.code },
properties: { layer: "stops", source: "otp", modes: stop.modes, name: stop.name, label: `${stop.name} (${stop.code})` },
type: "Feature"
})),
type: "FeatureCollection"
Expand Down
2 changes: 1 addition & 1 deletion packages/types/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opentripplanner/types",
"version": "6.1.1",
"version": "6.2.0",
"description": "TypeScript types used across multiple OTP-UI packages",
"main": "lib/index.js",
"types": "lib/index.d.ts",
Expand Down
3 changes: 3 additions & 0 deletions packages/types/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,8 @@ export type StopLayerStop = LayerEntity & {
name: string;
};

export type StopEventHandler = (stop: Stop | { stopId: string }) => void;

/**
* This models data about a stop and it's associated routes that is obtained
* from a transit index API.
Expand All @@ -485,6 +487,7 @@ export type Stop = {
color?: string;
dist?: number;
geometries?: { geoJson?: GeoJSON.Polygon };
gtfsId: string;
id: string;
lat?: number;
lon?: number;
Expand Down
10 changes: 10 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3241,6 +3241,16 @@
resolved "https://registry.yarnpkg.com/@open-draft/until/-/until-1.0.3.tgz#db9cc719191a62e7d9200f6e7bab21c5b848adca"
integrity sha512-Aq58f5HiWdyDlFffbbSjAlv596h/cOnt2DO1w3DOC7OJ5EHs0hd/nycJfiu9RJbT6Yk6F1knnRRXNSpxoIVZ9Q==

"@opentripplanner/geocoder@^1.4.2":
version "1.4.2"
resolved "https://registry.yarnpkg.com/@opentripplanner/geocoder/-/geocoder-1.4.2.tgz#0f827dffca42c7f7a23063b54990a291dd028b80"
integrity sha512-yzMVrKXEHO6Y50j9kntk1+odvHaqn9K9D4aKJAd+EabhiZckesfScLb0updmWRUloEWjN45nuDSFto8fbU7Uiw==
dependencies:
"@conveyal/geocoder-arcgis-geojson" "^0.0.3"
"@conveyal/lonlat" "^1.4.1"
isomorphic-mapzen-search "^1.6.1"
lodash.memoize "^4.1.2"

"@opentripplanner/[email protected]":
version "7.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@opentripplanner/types/-/types-7.0.0-alpha.2.tgz#d10c69f99b2da6d1e80ab5989520bde8e558627b"
Expand Down

0 comments on commit 1354178

Please sign in to comment.