@digitransit-search-util/digitransit-search-util-execute-search-immidiate 1.3.5 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +16 -11
  2. package/package.json +3 -3
package/index.js CHANGED
@@ -247,8 +247,8 @@ export function getSearchResults(
247
247
  parkingAreaSources,
248
248
  getLanguage,
249
249
  getStopAndStationsQuery,
250
- getFavouriteBikeRentalStationsQuery,
251
- getFavouriteBikeRentalStations,
250
+ getFavouriteVehicleRentalStationsQuery,
251
+ getFavouriteVehicleRentalStations,
252
252
  getFavouriteRoutesQuery,
253
253
  getFavouriteRoutes,
254
254
  getRoutesQuery,
@@ -337,7 +337,7 @@ export function getSearchResults(
337
337
  'selectFromMap',
338
338
  'futureRoute',
339
339
  'ownLocations',
340
- 'bikeRentalStation',
340
+ 'vehicleRentalStation',
341
341
  'bikepark',
342
342
  'carpark',
343
343
  'stop',
@@ -384,7 +384,7 @@ export function getSearchResults(
384
384
  'ownLocations',
385
385
  'favouritePlace',
386
386
  'bikestation',
387
- 'bikeRentalStation',
387
+ 'vehicleRentalStation',
388
388
  'back',
389
389
  'stop',
390
390
  'station',
@@ -468,7 +468,7 @@ export function getSearchResults(
468
468
  'futureRoute',
469
469
  'ownLocations',
470
470
  'favouritePlace',
471
- 'bikeRentalStation',
471
+ 'vehicleRentalStation',
472
472
  'back',
473
473
  ];
474
474
  dropLayers.push(...routeLayers);
@@ -476,7 +476,7 @@ export function getSearchResults(
476
476
  dropLayers.push(...parkingLayers);
477
477
  if (transportMode) {
478
478
  if (transportMode !== 'route-CITYBIKE') {
479
- dropLayers.push('bikeRentalStation');
479
+ dropLayers.push('vehicleRentalStation');
480
480
  dropLayers.push('bikestation');
481
481
  }
482
482
  searchComponents.push(
@@ -527,7 +527,7 @@ export function getSearchResults(
527
527
  ];
528
528
  if (transportMode) {
529
529
  if (transportMode !== 'route-CITYBIKE') {
530
- dropLayers.push('bikeRentalStation');
530
+ dropLayers.push('vehicleRentalStation');
531
531
  dropLayers.push('bikestation');
532
532
  }
533
533
  dropLayers.push(...routeLayers.filter(i => !(i === transportMode)));
@@ -540,11 +540,16 @@ export function getSearchResults(
540
540
  );
541
541
  }
542
542
  }
543
- if (allTargets || targets.includes('BikeRentalStations')) {
543
+ if (allTargets || targets.includes('VehicleRentalStations')) {
544
544
  if (sources.includes('Favourite')) {
545
- const favouriteBikeStations = getFavouriteBikeRentalStations(context);
545
+ const favouriteVehicleRentalStation = getFavouriteVehicleRentalStations(
546
+ context,
547
+ );
546
548
  searchComponents.push(
547
- getFavouriteBikeRentalStationsQuery(favouriteBikeStations, input),
549
+ getFavouriteVehicleRentalStationsQuery(
550
+ favouriteVehicleRentalStation,
551
+ input,
552
+ ),
548
553
  );
549
554
  }
550
555
  if (allSources || sources.includes('Datasource')) {
@@ -563,7 +568,7 @@ export function getSearchResults(
563
568
  geocodingLayers,
564
569
  ).then(results => {
565
570
  if (filterResults) {
566
- return filterResults(results, mode, 'BikeRentalStations');
571
+ return filterResults(results, mode, 'VehicleRentalStations');
567
572
  }
568
573
  return results;
569
574
  }),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digitransit-search-util/digitransit-search-util-execute-search-immidiate",
3
- "version": "1.3.5",
3
+ "version": "2.0.0",
4
4
  "description": "digitransit-search-util execute-search-immidiate module",
5
5
  "main": "index.js",
6
6
  "publishConfig": {
@@ -24,8 +24,8 @@
24
24
  "@digitransit-search-util/digitransit-search-util-filter-matching-to-input": "0.0.3",
25
25
  "@digitransit-search-util/digitransit-search-util-get-geocoding-results": "0.0.5",
26
26
  "@digitransit-search-util/digitransit-search-util-get-json": "0.0.4",
27
- "@digitransit-search-util/digitransit-search-util-helpers": "1.0.6",
27
+ "@digitransit-search-util/digitransit-search-util-helpers": "2.0.0",
28
28
  "lodash": "4.17.21"
29
29
  },
30
- "gitHead": "5c78ef7df03c2e12cc7a4be8d3ea3f2d76261d0a"
30
+ "gitHead": "f904285c98141cf0a03ca9c1fab54674c5c47e3e"
31
31
  }