@heycar/heycars-map 2.14.0-walkOptimize2 → 2.15.0-domestic2

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 (80) hide show
  1. package/README.md +47 -15
  2. package/dist/v2/Demo/DemoBusinessRecomendPlace.js +2 -1
  3. package/dist/v2/Demo/DemoBusinessTaxiEnd.d.ts +2 -1
  4. package/dist/v2/Demo/DemoBusinessTaxiEnd.js +9 -2
  5. package/dist/v2/Demo/DemoBusinessTaxiService.d.ts +4 -1
  6. package/dist/v2/Demo/DemoBusinessTaxiService.js +19 -1
  7. package/dist/v2/Demo/demo.data.mock.d.ts +4 -0
  8. package/dist/v2/Demo/demo.data.mock.js +1194 -0
  9. package/dist/v2/business-components/BusinessRecomendPlaceMap/BusinessRecomendPlaceMap.d.ts +2 -2
  10. package/dist/v2/business-components/BusinessRecomendPlaceMap/BusinessRecomendPlaceMap.js +2 -1
  11. package/dist/v2/business-components/BusinessRecomendPlaceMap/index.js +1 -1
  12. package/dist/v2/business-components/BusinessRecomendPlaceMap/useCacheCenterPlace.d.ts +1 -2
  13. package/dist/v2/business-components/BusinessRecomendPlaceMap/useCacheCenterPlace.js +6 -14
  14. package/dist/v2/business-components/BusinessReselectPlaceMap/BusinessReselectPlaceMap.js +1 -1
  15. package/dist/v2/business-components/BusinessTaxiEndMap/BusinessTaxiEndMap.d.ts +4 -3
  16. package/dist/v2/business-components/BusinessTaxiEndMap/BusinessTaxiEndMap.js +6 -2
  17. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.d.ts +4 -1
  18. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.js +45 -7
  19. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.d.ts +6 -1
  20. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.js +80 -16
  21. package/dist/v2/business-components/TaxiCar/RandomCars.d.ts +6 -0
  22. package/dist/v2/business-components/TaxiCar/RandomCars.js +47 -0
  23. package/dist/v2/chunks/{BusinessRecomendPlaceMap.8a4a1015.js → BusinessRecomendPlaceMap.eebd0822.js} +9 -5
  24. package/dist/{v3/chunks/Loading.4c949ec9.js → v2/chunks/Loading.8aa3aad3.js} +47 -27
  25. package/dist/v2/components/Loading/Loading.js +1 -1
  26. package/dist/v2/components/Loading/index.js +1 -1
  27. package/dist/v2/components/MapProvider/MapProvider.js +21 -10
  28. package/dist/v2/hooks/useMapCoordinatify.d.ts +2 -1
  29. package/dist/v2/hooks/useMapCoordinatify.js +6 -1
  30. package/dist/v2/hooks/useMapLoader.js +3 -3
  31. package/dist/v2/hooks-business/useBusinessRecomendPlaceMap.js +1 -1
  32. package/dist/v2/index.js +1 -1
  33. package/dist/v2/types/interface.d.ts +12 -0
  34. package/dist/v2/utils/geometryPolygon.d.ts +9 -0
  35. package/dist/v2/utils/geometryPolygon.js +19 -0
  36. package/dist/v2/utils/log.js +1 -1
  37. package/dist/v2/utils/platform.d.ts +2 -1
  38. package/dist/v2/utils/platform.js +2 -1
  39. package/dist/v2/utils/typeChecking.d.ts +7 -1
  40. package/dist/v2/utils/typeChecking.js +18 -0
  41. package/dist/v3/Demo/DemoBusinessRecomendPlace.js +2 -1
  42. package/dist/v3/Demo/DemoBusinessTaxiEnd.d.ts +2 -1
  43. package/dist/v3/Demo/DemoBusinessTaxiEnd.js +9 -2
  44. package/dist/v3/Demo/DemoBusinessTaxiService.d.ts +4 -1
  45. package/dist/v3/Demo/DemoBusinessTaxiService.js +19 -1
  46. package/dist/v3/Demo/demo.data.mock.d.ts +4 -0
  47. package/dist/v3/Demo/demo.data.mock.js +1194 -0
  48. package/dist/v3/business-components/BusinessRecomendPlaceMap/BusinessRecomendPlaceMap.d.ts +2 -2
  49. package/dist/v3/business-components/BusinessRecomendPlaceMap/BusinessRecomendPlaceMap.js +2 -1
  50. package/dist/v3/business-components/BusinessRecomendPlaceMap/index.js +1 -1
  51. package/dist/v3/business-components/BusinessRecomendPlaceMap/useCacheCenterPlace.d.ts +1 -2
  52. package/dist/v3/business-components/BusinessRecomendPlaceMap/useCacheCenterPlace.js +6 -14
  53. package/dist/v3/business-components/BusinessReselectPlaceMap/BusinessReselectPlaceMap.js +1 -1
  54. package/dist/v3/business-components/BusinessTaxiEndMap/BusinessTaxiEndMap.d.ts +4 -3
  55. package/dist/v3/business-components/BusinessTaxiEndMap/BusinessTaxiEndMap.js +6 -2
  56. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.d.ts +4 -1
  57. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.js +45 -7
  58. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.d.ts +6 -1
  59. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.js +62 -16
  60. package/dist/v3/business-components/TaxiCar/RandomCars.d.ts +8 -0
  61. package/dist/v3/business-components/TaxiCar/RandomCars.js +45 -0
  62. package/dist/v3/chunks/{BusinessRecomendPlaceMap.b30ca4e4.js → BusinessRecomendPlaceMap.71c439c6.js} +7 -5
  63. package/dist/{v2/chunks/Loading.70dfc720.js → v3/chunks/Loading.4b53c31f.js} +34 -30
  64. package/dist/v3/components/Loading/Loading.js +1 -1
  65. package/dist/v3/components/Loading/index.js +1 -1
  66. package/dist/v3/components/MapProvider/MapProvider.js +21 -10
  67. package/dist/v3/hooks/useMapCoordinatify.d.ts +2 -1
  68. package/dist/v3/hooks/useMapCoordinatify.js +6 -1
  69. package/dist/v3/hooks/useMapLoader.js +3 -3
  70. package/dist/v3/hooks-business/useBusinessRecomendPlaceMap.js +1 -1
  71. package/dist/v3/index.js +1 -1
  72. package/dist/v3/types/interface.d.ts +12 -0
  73. package/dist/v3/utils/geometryPolygon.d.ts +9 -0
  74. package/dist/v3/utils/geometryPolygon.js +19 -0
  75. package/dist/v3/utils/log.js +1 -1
  76. package/dist/v3/utils/platform.d.ts +2 -1
  77. package/dist/v3/utils/platform.js +2 -1
  78. package/dist/v3/utils/typeChecking.d.ts +7 -1
  79. package/dist/v3/utils/typeChecking.js +18 -0
  80. package/package.json +1 -1
@@ -5,7 +5,7 @@ import { type UseMapDragProps } from "../../hooks/useMapDrag";
5
5
  import type { UseMapPlaceProps } from "../../hooks/useMapPlace";
6
6
  import { type UseMapRecomendPlaceProps } from "../../hooks/useMapRecomendPlace";
7
7
  import type { Coordinatify, CoordinatifyProps } from "../../types/coordinatify";
8
- import { type BusinessGeolocationPositionError, type CoordinatePlace, type CoordinatePoint } from "../../types/interface";
8
+ import { type BusinessGeolocationPositionError, type CoordinatePlace } from "../../types/interface";
9
9
  import { type AbsoluteAddressBoxProps } from "../AbsoluteAddressBox";
10
10
  import { type PickupPointsProps } from "../PickupPoints";
11
11
  export declare const RECOMMEND_PLACE_DRAG_LIMIT = 10;
@@ -28,12 +28,12 @@ export interface BusinessRecomendPlaceMapProps extends CoordinatifyProps<Omit<He
28
28
  emptyTitle: string;
29
29
  queryingTitle: string;
30
30
  recomendDescription: string;
31
+ enableNearbyCars?: boolean;
31
32
  disableLocator?: boolean;
32
33
  disableLocatorPhoto?: boolean;
33
34
  geoErrorOnceNotificationKey?: string;
34
35
  mapContext: CoordinatifyProps<BusinessRecomendPlaceContext>;
35
36
  defaultCenterPlace?: CoordinatePlace | ((place?: CoordinatePlace) => CoordinatePlace | undefined);
36
- skipWaitGeo?: boolean | CoordinatePlace | CoordinatePoint;
37
37
  renderPlacePhoto?: (place: CoordinatePlace) => undefined | {
38
38
  src: string;
39
39
  title?: string;
@@ -26,8 +26,9 @@ import "../DeviceOrientation/DeviceOrientation.js";
26
26
  import "../GreenZone/GreenZone.js";
27
27
  import "../PassengerCircle/PassengerCircle.js";
28
28
  import "../PickupPoints/PickupPoints.js";
29
+ import "../TaxiCar/RandomCars.js";
29
30
  import "./useCacheCenterPlace.js";
30
- import { B, f, D, E, R, c, a, e, b, d, Z } from "../../chunks/BusinessRecomendPlaceMap.8a4a1015.js";
31
+ import { B, f, D, E, R, c, a, e, b, d, Z } from "../../chunks/BusinessRecomendPlaceMap.eebd0822.js";
31
32
  export {
32
33
  B as BusinessRecomendPlaceMap,
33
34
  f as BusinessRecomendPlaceMapInner,
@@ -1,4 +1,4 @@
1
- import { B, f, D, E, R, c, a, e, b, d, Z } from "../../chunks/BusinessRecomendPlaceMap.8a4a1015.js";
1
+ import { B, f, D, E, R, c, a, e, b, d, Z } from "../../chunks/BusinessRecomendPlaceMap.eebd0822.js";
2
2
  export {
3
3
  B as BusinessRecomendPlaceMap,
4
4
  f as BusinessRecomendPlaceMapInner,
@@ -1,8 +1,7 @@
1
- import type { CoordinatePlace, CoordinatePoint, Point } from "../../types/interface";
1
+ import type { CoordinatePlace, Point } from "../../types/interface";
2
2
  interface UseDefaultCenterPlaceProps {
3
3
  emptyTitle: string;
4
4
  geoLoadingTitle: string;
5
- skipWaitGeo?: boolean | CoordinatePlace | CoordinatePoint;
6
5
  defaultCenterPlace?: CoordinatePlace | ((place?: CoordinatePlace) => CoordinatePlace | undefined);
7
6
  }
8
7
  export declare const useCacheCenterPlace: (props: UseDefaultCenterPlaceProps) => {
@@ -3,21 +3,13 @@ import { apiGetCenterPlaceFromCache } from "../../api/browser.js";
3
3
  import { apiMemoryShouldSkipByKey } from "../../api/memory.js";
4
4
  import { useMapCoordinatify } from "../../hooks/useMapCoordinatify.js";
5
5
  import { maybeFunctionToFunction, lnglat2point } from "../../utils/transform.js";
6
- import { t as throttle } from "../../chunks/throttle.8bdd8d3b.js";
7
6
  const IS_FIRST_LOAD_KEY = "IS_FIRST_LOAD_KEY";
8
- const THROTTLE_TIME = 3e3;
9
- const throttledApiMemoryShouldSkipByKey = throttle(apiMemoryShouldSkipByKey, THROTTLE_TIME, {
10
- trailing: false
11
- });
12
7
  const useCacheCenterPlace = (props) => {
13
- var _a;
14
- const { geoLoadingTitle, emptyTitle, skipWaitGeo } = props;
15
- const isAppFirstLoad = !throttledApiMemoryShouldSkipByKey(IS_FIRST_LOAD_KEY);
16
- const isFirstLoadWithGps = isAppFirstLoad && !skipWaitGeo;
8
+ const { geoLoadingTitle, emptyTitle } = props;
9
+ const isFirstLoad = !apiMemoryShouldSkipByKey(IS_FIRST_LOAD_KEY);
17
10
  const getDefaultCenterPlace = maybeFunctionToFunction(props.defaultCenterPlace);
18
11
  const { unCoordinatifyPlace } = useMapCoordinatify();
19
- const inputSkipGeoPlace = typeof skipWaitGeo === "object" ? skipWaitGeo : void 0;
20
- const inputDefaultCenterPlace = (_a = isAppFirstLoad ? inputSkipGeoPlace : void 0) != null ? _a : getDefaultCenterPlace == null ? void 0 : getDefaultCenterPlace(apiGetCenterPlaceFromCache());
12
+ const inputDefaultCenterPlace = getDefaultCenterPlace == null ? void 0 : getDefaultCenterPlace(apiGetCenterPlaceFromCache());
21
13
  const defaultCenterPlace = {
22
14
  lng: 0,
23
15
  lat: 0,
@@ -29,10 +21,10 @@ const useCacheCenterPlace = (props) => {
29
21
  const centerPlace = reactive({
30
22
  lng: defaultCenterPlace.lng,
31
23
  lat: defaultCenterPlace.lat,
32
- name: isFirstLoadWithGps ? geoLoadingTitle : defaultCenterPlace.name,
33
- displayName: isFirstLoadWithGps ? geoLoadingTitle : defaultCenterPlace.displayName
24
+ name: isFirstLoad ? geoLoadingTitle : defaultCenterPlace.name,
25
+ displayName: isFirstLoad ? geoLoadingTitle : defaultCenterPlace.displayName
34
26
  });
35
- return { isFirstLoad: isFirstLoadWithGps, centerPlace, geoDefaultPosition, defaultCenterPlace };
27
+ return { isFirstLoad, centerPlace, geoDefaultPosition, defaultCenterPlace };
36
28
  };
37
29
  export {
38
30
  useCacheCenterPlace
@@ -21,7 +21,7 @@ import { detectBrowserPlatform } from "../../utils/platform.js";
21
21
  import { place2point, isPlaceEqual, isZoneEqual, geoPositionError2businessTimeout, pipeDefer } from "../../utils/transform.js";
22
22
  import { toCoordinatePlaceType, toCoordinatePointType, toCoordinateRecommendZonePlacesType } from "../../utils/typeChecking.js";
23
23
  import { AbsoluteAddressBox } from "../AbsoluteAddressBox/AbsoluteAddressBox.js";
24
- import { E as EMPTY_PLACE, m as memoize, R as RECOMMEND_PLACE_DRAG_LIMIT, a as RECOMMEND_PLACE_LARGE_LIMIT, b as RECOMMEND_PLACE_ZONE_ICON_MIN, c as RECOMMEND_PLACE_ICON_ZOOM_MIN, d as RECOMMEND_PLACE_ZONE_TEXT_MIN, e as RECOMMEND_PLACE_TEXT_ZOOM_MIN, D as DEFAULT_ZOOM, Z as ZONE_FITVIEW_PANDING } from "../../chunks/BusinessRecomendPlaceMap.8a4a1015.js";
24
+ import { E as EMPTY_PLACE, m as memoize, R as RECOMMEND_PLACE_DRAG_LIMIT, a as RECOMMEND_PLACE_LARGE_LIMIT, b as RECOMMEND_PLACE_ZONE_ICON_MIN, c as RECOMMEND_PLACE_ICON_ZOOM_MIN, d as RECOMMEND_PLACE_ZONE_TEXT_MIN, e as RECOMMEND_PLACE_TEXT_ZOOM_MIN, D as DEFAULT_ZOOM, Z as ZONE_FITVIEW_PANDING } from "../../chunks/BusinessRecomendPlaceMap.eebd0822.js";
25
25
  import { DeviceOrientation } from "../DeviceOrientation/DeviceOrientation.js";
26
26
  import { GreenZone } from "../GreenZone/GreenZone.js";
27
27
  import { PassengerCircle } from "../PassengerCircle/PassengerCircle.js";
@@ -1,7 +1,8 @@
1
- import type { Place } from "../../types/interface";
1
+ import type { CoordinatePlace, CoordinatePoint } from "../../types/interface";
2
2
  export interface BusinessTaxiEndMapProps {
3
- from: Partial<Place>;
4
- to: Partial<Place>;
3
+ from: Partial<CoordinatePlace>;
4
+ to: Partial<CoordinatePlace>;
5
+ path?: CoordinatePoint[];
5
6
  }
6
7
  export declare const BusinessTaxiEndMapInner: import("vue/types/v3-define-component").DefineComponent<import("@vue/runtime-core").ComponentObjectPropsOptions<BusinessTaxiEndMapProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<BusinessTaxiEndMapProps, Required<BusinessTaxiEndMapProps>>, never, BusinessTaxiEndMapProps>;
7
8
  export declare const BusinessTaxiEndMap: import("vue/types/v3-define-component").DefineComponent<import("@vue/runtime-core").ComponentObjectPropsOptions<BusinessTaxiEndMapProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<BusinessTaxiEndMapProps, Required<BusinessTaxiEndMapProps>>, never, BusinessTaxiEndMapProps>;
@@ -8,7 +8,7 @@ import { useMapFitView } from "../../hooks/useMapFitView.js";
8
8
  import { useMapSupplier } from "../../hooks/useMapSupplier.js";
9
9
  import { defineSetup } from "../../types/helper.js";
10
10
  import { place2point, pipeDefer } from "../../utils/transform.js";
11
- import { isCoordinatePoint, toCoordinatePlaceType } from "../../utils/typeChecking.js";
11
+ import { isCoordinatePoint, toCoordinatePlaceType, toCoordinatePointType } from "../../utils/typeChecking.js";
12
12
  import { SectionEndService } from "../BusinessTaxiServiceMap/BusinessTaxiServiceSection.js";
13
13
  const BusinessTaxiEndMapInner = defineSetup("BusinessTaxiEndMapInner", function(props, {
14
14
  attrs
@@ -18,6 +18,7 @@ const BusinessTaxiEndMapInner = defineSetup("BusinessTaxiEndMapInner", function(
18
18
  setMap
19
19
  } = useHeycarMap();
20
20
  const {
21
+ unCoordinatifyPoint,
21
22
  unCoordinatifyPlace
22
23
  } = useMapCoordinatify();
23
24
  const {
@@ -31,11 +32,13 @@ const BusinessTaxiEndMapInner = defineSetup("BusinessTaxiEndMapInner", function(
31
32
  return () => {
32
33
  const {
33
34
  from: inputFrom,
34
- to: inputTo
35
+ to: inputTo,
36
+ path: inputPath
35
37
  } = props;
36
38
  const isReady = isCoordinatePoint(inputFrom) && isCoordinatePoint(inputTo);
37
39
  const from = unCoordinatifyPlace(toCoordinatePlaceType(inputFrom));
38
40
  const to = unCoordinatifyPlace(toCoordinatePlaceType(inputTo));
41
+ const path = inputPath == null ? void 0 : inputPath.map((p) => unCoordinatifyPoint(toCoordinatePointType(p)));
39
42
  const center = isReady ? place2point(from) : [...BEIJIN_POINT];
40
43
  return h(HeycarMap, {
41
44
  "class": attrs.class,
@@ -53,6 +56,7 @@ const BusinessTaxiEndMapInner = defineSetup("BusinessTaxiEndMapInner", function(
53
56
  "attrs": {
54
57
  "from": from,
55
58
  "to": to,
59
+ "routePath": path,
56
60
  "registerOverlay": registerFitVeiw
57
61
  }
58
62
  })]);
@@ -1,7 +1,7 @@
1
1
  import { type HeycarMapProps } from "../../components/MapProvider";
2
2
  import type { BusinessTaxiServiceContext } from "../../hooks-business/useBusinessTaxiServiceMap";
3
3
  import type { CoordinatifyProps } from "../../types/coordinatify";
4
- import type { CoordinatePlace, CoordinateTrackPoint, DriverStatus } from "../../types/interface";
4
+ import type { CoordinatePlace, CoordinatePoint, CoordinateTrackPoint, DriverStatus, GetDriverRouteOrTrackOutput } from "../../types/interface";
5
5
  export type BusinessTaxiServiceMapProps = CoordinatifyProps<Omit<HeycarMapProps, "center" | "zoom" | "mapRef">> & {
6
6
  from: CoordinatePlace;
7
7
  to: CoordinatePlace;
@@ -15,6 +15,8 @@ export type BusinessTaxiServiceMapProps = CoordinatifyProps<Omit<HeycarMapProps,
15
15
  driverStatus: DriverStatus;
16
16
  interval: number;
17
17
  disablePassenger?: boolean;
18
+ confirmedPath?: CoordinatePoint[];
19
+ endServicePath?: CoordinatePoint[];
18
20
  mapContext: CoordinatifyProps<BusinessTaxiServiceContext>;
19
21
  renderStartSerivceTitle: (titleProps: {
20
22
  distance: number;
@@ -25,6 +27,7 @@ export type BusinessTaxiServiceMapProps = CoordinatifyProps<Omit<HeycarMapProps,
25
27
  duration: number;
26
28
  }) => string;
27
29
  getDriverPositionTrack?: () => Promise<CoordinateTrackPoint[]>;
30
+ getDriverRouteOrTrack?: () => Promise<GetDriverRouteOrTrackOutput>;
28
31
  };
29
32
  export declare const BusinessTaxiServiceMapInner: import("vue-demi").DefineComponent<import("@vue/runtime-core").ComponentObjectPropsOptions<BusinessTaxiServiceMapProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<BusinessTaxiServiceMapProps, Required<BusinessTaxiServiceMapProps>>, "resize" | "dragEnd" | "zoomEnd", BusinessTaxiServiceMapProps>;
30
33
  export declare const BusinessTaxiServiceMap: import("vue-demi").DefineComponent<import("@vue/runtime-core").ComponentObjectPropsOptions<BusinessTaxiServiceMapProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<BusinessTaxiServiceMapProps, Required<BusinessTaxiServiceMapProps>>, "resize" | "dragEnd" | "zoomEnd", BusinessTaxiServiceMapProps>;
@@ -10,9 +10,10 @@ import { useMapFitView } from "../../hooks/useMapFitView.js";
10
10
  import { useMapAssertSupplier, useMapSupplier } from "../../hooks/useMapSupplier.js";
11
11
  import { defineSetup, defineLagecySetup } from "../../types/helper.js";
12
12
  import { MANUAL_ABORT_MESSAGE } from "../../utils/ManualAbortError.js";
13
+ import { computeLineAngle } from "../../utils/geometryPolygon.js";
13
14
  import { createAbortable, assertNotEmptyArray } from "../../utils/helper.js";
14
15
  import { place2point, pipeDefer, lnglat2point } from "../../utils/transform.js";
15
- import { toCoordinatePlaceType, toCoordinateTrackPoint } from "../../utils/typeChecking.js";
16
+ import { toCoordinatePlaceType, toCoordinatePointType, createTypeError, toCoordinateExternalRoute, toCoordinateTrackPoint } from "../../utils/typeChecking.js";
16
17
  import { AuxiliaryGraspRoad } from "../AuxiliaryGraspRoad/AuxiliaryGraspRoad.js";
17
18
  import { AuxiliaryPassanger } from "../AuxiliaryPassanger/AuxiliaryPassanger.js";
18
19
  import { DeviceOrientation } from "../DeviceOrientation/DeviceOrientation.js";
@@ -23,6 +24,7 @@ const IS_ENABLE_AUXILIARY_GRASP_ROAD = apiGetAuxiliaryGrapStatus();
23
24
  const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", function(props, {
24
25
  attrs
25
26
  }) {
27
+ var _a;
26
28
  const {
27
29
  interval,
28
30
  disablePassenger,
@@ -40,10 +42,17 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
40
42
  } = useMapAssertSupplier();
41
43
  const abortController = new AbortController();
42
44
  const abortable = createAbortable(abortController.signal);
43
- const getDriverPositionTrack = abortable(props.getDriverPositionTrack);
45
+ const getDriverRouteOrTrack = abortable((_a = props.getDriverRouteOrTrack) != null ? _a : async () => {
46
+ var _a2;
47
+ return {
48
+ tracks: await ((_a2 = props.getDriverPositionTrack) == null ? void 0 : _a2.call(props))
49
+ };
50
+ });
44
51
  const {
52
+ unCoordinatifyPoint,
45
53
  unCoordinatifyPlace,
46
- unCoordinatifyTrackPoint
54
+ unCoordinatifyTrackPoint,
55
+ unCoordinatifyExternalRoute
47
56
  } = useMapCoordinatify();
48
57
  const {
49
58
  registerFitVeiw: registerOverlay,
@@ -64,11 +73,27 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
64
73
  const carPositionRef = ref();
65
74
  const carAngleRef = ref();
66
75
  const carTrackPositionsRef = ref([]);
76
+ const carRouteRef = ref();
67
77
  watch(() => props.driverStatus, (status, _, onCleanup) => {
68
78
  if (!STATUS_NEED_CAR_POSITION.includes(status))
69
79
  return;
70
80
  const update = async () => {
71
- const tracks = await (getDriverPositionTrack == null ? void 0 : getDriverPositionTrack());
81
+ const output = await (getDriverRouteOrTrack == null ? void 0 : getDriverRouteOrTrack());
82
+ if (!("tracks" in output) && !("routes" in output)) {
83
+ throw createTypeError("GetDriverRouteOrTrackOutput", output);
84
+ }
85
+ if ("routes" in output) {
86
+ const routes = unCoordinatifyExternalRoute(toCoordinateExternalRoute(output.routes));
87
+ assertNotEmptyArray(routes.path, "routes.path");
88
+ carPositionRef.value = routes.path[0];
89
+ carAngleRef.value = computeLineAngle(routes.path[0], routes.path[1]);
90
+ carTrackPositionsRef.value = [];
91
+ carRouteRef.value = routes;
92
+ return;
93
+ }
94
+ const {
95
+ tracks
96
+ } = output;
72
97
  assertNotEmptyArray(tracks, "tracks");
73
98
  const trackPositions = tracks.map((p) => unCoordinatifyTrackPoint(toCoordinateTrackPoint(p)));
74
99
  const [{
@@ -77,6 +102,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
77
102
  carPositionRef.value = lnglat2point(trackPositions[trackPositions.length - 1]);
78
103
  carAngleRef.value = angle;
79
104
  carTrackPositionsRef.value = trackPositions;
105
+ carRouteRef.value = void 0;
80
106
  };
81
107
  const timer = setInterval(update, interval);
82
108
  update();
@@ -95,16 +121,21 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
95
121
  dispatchingTitle,
96
122
  bookDispatchingTitle,
97
123
  bookDispatchedTitle,
98
- driverArrivedTitle
124
+ driverArrivedTitle,
125
+ confirmedPath: inputConfirmedPath,
126
+ endServicePath: inputEndServicePath
99
127
  } = props;
100
128
  const from = unCoordinatifyPlace(toCoordinatePlaceType(inputFrom));
101
129
  const to = unCoordinatifyPlace(toCoordinatePlaceType(inputTo));
102
130
  const relayTo = inputRelayTo ? unCoordinatifyPlace(toCoordinatePlaceType(inputRelayTo)) : void 0;
131
+ const confirmedPath = inputConfirmedPath == null ? void 0 : inputConfirmedPath.map((p) => unCoordinatifyPoint(toCoordinatePointType(p)));
132
+ const endServicePath = inputEndServicePath == null ? void 0 : inputEndServicePath.map((p) => unCoordinatifyPoint(toCoordinatePointType(p)));
103
133
  const carPosition = carPositionRef.value;
104
134
  const carAngle = carAngleRef.value;
105
135
  const carTrackPositions = carTrackPositionsRef.value;
106
136
  const touchEnable = !["canceled", "canceling", "completed", "endService", "waitpay", "waitRechargePay", "refund", "rechargePayed", "payed"].includes(driverStatus);
107
137
  const passengerPosition = disablePassenger || geoLoading.value || geoError.value ? void 0 : geoPosition.value;
138
+ const carRoute = carRouteRef.value;
108
139
  return h(HeycarMap, {
109
140
  "class": attrs.class,
110
141
  "style": attrs.style,
@@ -137,6 +168,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
137
168
  "attrs": {
138
169
  "from": from,
139
170
  "to": to,
171
+ "routePath": confirmedPath,
140
172
  "passengerPosition": passengerPosition,
141
173
  "passengerAngle": orientation == null ? void 0 : orientation.cssRotationVariableName,
142
174
  "registerOverlay": registerOverlay
@@ -154,6 +186,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
154
186
  "carPosition": carPosition,
155
187
  "carAngle": carAngle,
156
188
  "carTrackPositions": carTrackPositions,
189
+ "carRoute": carRoute,
157
190
  "passengerPosition": passengerPosition,
158
191
  "passengerAngle": orientation == null ? void 0 : orientation.cssRotationVariableName,
159
192
  "relayToTitle": relayToTitle,
@@ -172,6 +205,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
172
205
  "carPosition": carPosition,
173
206
  "carAngle": carAngle,
174
207
  "carTrackPositions": carTrackPositions,
208
+ "carRoute": carRoute,
175
209
  "passengerPosition": passengerPosition,
176
210
  "passengerAngle": orientation == null ? void 0 : orientation.cssRotationVariableName,
177
211
  "renderTitle": renderStartSerivceTitle,
@@ -188,6 +222,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
188
222
  "from": from,
189
223
  "to": to,
190
224
  "title": bookDispatchedTitle,
225
+ "routePath": confirmedPath,
191
226
  "passengerPosition": passengerPosition,
192
227
  "passengerAngle": orientation == null ? void 0 : orientation.cssRotationVariableName,
193
228
  "registerOverlay": registerOverlay
@@ -200,6 +235,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
200
235
  "carPosition": carPosition,
201
236
  "carAngle": carAngle,
202
237
  "carTrackPositions": carTrackPositions,
238
+ "carRoute": carRoute,
203
239
  "renderTitle": renderInServiceTitle,
204
240
  "registerOverlay": registerOverlay
205
241
  },
@@ -230,6 +266,7 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
230
266
  "attrs": {
231
267
  "from": from,
232
268
  "to": to,
269
+ "routePath": endServicePath,
233
270
  "registerOverlay": registerOverlay
234
271
  }
235
272
  }) : (
@@ -238,10 +275,11 @@ const BusinessTaxiServiceMapInner = defineSetup("BusinessTaxiServiceMapInner", f
238
275
  "attrs": {
239
276
  "from": from,
240
277
  "to": to,
278
+ "routePath": endServicePath,
241
279
  "registerOverlay": registerOverlay
242
280
  }
243
281
  })
244
- ), IS_ENABLE_AUXILIARY_GRASP_ROAD && h(AuxiliaryGraspRoad, {
282
+ ), IS_ENABLE_AUXILIARY_GRASP_ROAD && !carRoute && h(AuxiliaryGraspRoad, {
245
283
  "attrs": {
246
284
  "status": driverStatus,
247
285
  "trackPoints": carTrackPositions,
@@ -271,7 +309,7 @@ const BusinessTaxiServiceMap = defineLagecySetup("BusinessTaxiServiceMap", funct
271
309
  attrs: props,
272
310
  key: `${payload.supplier}${instanceNo}`
273
311
  });
274
- }).props(["bookDispatchingTitle", "bookDispatchedTitle", "dispatchingTitle", "driverArrivedTitle", "driverStatus", "fallback", "from", "getDriverPositionTrack", "interval", "disablePassenger", "loading", "mapContext", "relayTo", "relayToTitle", "renderInServiceTitle", "renderStartSerivceTitle", "to"]);
312
+ }).props(["bookDispatchingTitle", "bookDispatchedTitle", "dispatchingTitle", "driverArrivedTitle", "driverStatus", "fallback", "from", "getDriverPositionTrack", "getDriverRouteOrTrack", "interval", "disablePassenger", "loading", "mapContext", "relayTo", "relayToTitle", "renderInServiceTitle", "renderStartSerivceTitle", "confirmedPath", "endServicePath", "to"]);
275
313
  export {
276
314
  BusinessTaxiServiceMap,
277
315
  BusinessTaxiServiceMapInner
@@ -1,5 +1,5 @@
1
1
  import type { MROP } from "../../hooks/useOverlay";
2
- import type { Place, Point, TrackPoint } from "../../types/interface";
2
+ import type { ExternalRoute, Place, Point, TrackPoint } from "../../types/interface";
3
3
  import { type DrivingRouteRenderProps } from "../DrivingRoute";
4
4
  type SectionDispatchingProps = Required<MROP> & {
5
5
  title: string;
@@ -11,6 +11,7 @@ type SectionConfirmedProps = Required<MROP> & {
11
11
  passengerAngle?: string;
12
12
  from: Place;
13
13
  to: Place;
14
+ routePath?: Point[];
14
15
  };
15
16
  export declare const SectionConfirmed: import("vue").DefineComponent<import("vue3").ComponentObjectPropsOptions<SectionConfirmedProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<SectionConfirmedProps, Required<SectionConfirmedProps>>, never, SectionConfirmedProps>;
16
17
  interface SectionDriverStartRelayServiceProps extends SectionDriverStartServiceProps {
@@ -24,6 +25,7 @@ type SectionDriverStartServiceProps = Required<MROP> & {
24
25
  carPosition?: Point;
25
26
  carAngle?: number;
26
27
  carTrackPositions?: TrackPoint[];
28
+ carRoute?: ExternalRoute;
27
29
  from: Place;
28
30
  renderTitle: (props: Pick<DrivingRouteRenderProps, "duration" | "distance">) => string;
29
31
  };
@@ -33,6 +35,7 @@ type SectionBookDispatchedProps = Required<MROP> & {
33
35
  passengerAngle?: string;
34
36
  from: Place;
35
37
  to: Place;
38
+ routePath?: Point[];
36
39
  title?: string;
37
40
  };
38
41
  export declare const SectionBookDispatched: import("vue").DefineComponent<import("vue3").ComponentObjectPropsOptions<SectionBookDispatchedProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<SectionBookDispatchedProps, Required<SectionBookDispatchedProps>>, never, SectionBookDispatchedProps>;
@@ -50,6 +53,7 @@ type SectionInServiceProps = Required<MROP> & {
50
53
  carPosition?: Point;
51
54
  carAngle?: number;
52
55
  carTrackPositions?: TrackPoint[];
56
+ carRoute?: ExternalRoute;
53
57
  renderTitle: (props: Pick<DrivingRouteRenderProps, "duration" | "distance">) => string;
54
58
  };
55
59
  export declare const SectionInService: import("vue").DefineComponent<import("vue3").ComponentObjectPropsOptions<SectionInServiceProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<SectionInServiceProps, Required<SectionInServiceProps>>, never, SectionInServiceProps>;
@@ -61,6 +65,7 @@ export declare const SectionCanceled: import("vue").DefineComponent<import("vue3
61
65
  export type SectionEndServiceProps = Required<MROP> & {
62
66
  from: Place;
63
67
  to: Place;
68
+ routePath?: Point[];
64
69
  };
65
70
  export declare const SectionEndService: import("vue").DefineComponent<import("vue3").ComponentObjectPropsOptions<SectionEndServiceProps>, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").Empty, import("../../types/helper").EmitByProps<SectionEndServiceProps, Required<SectionEndServiceProps>>, never, SectionEndServiceProps>;
66
71
  export {};
@@ -77,12 +77,17 @@ const SectionConfirmed = defineSetup("SectionConfirmed", function(props) {
77
77
  to: toPlace,
78
78
  passengerPosition,
79
79
  passengerAngle,
80
+ routePath,
80
81
  registerOverlay
81
82
  } = props;
82
83
  const from = place2point(fromPlace);
83
84
  const to = place2point(toPlace);
84
85
  const passengerDistance = passengerPosition ? apiMapDistance(passengerPosition, from) : void 0;
85
- return h("div", [h(DrivingRoute, {
86
+ return h("div", [routePath ? h(DrivingLine, {
87
+ "attrs": {
88
+ "path": routePath
89
+ }
90
+ }) : h(DrivingRoute, {
86
91
  "attrs": {
87
92
  "to": to,
88
93
  "from": from,
@@ -157,12 +162,14 @@ const SectionDriverStartRelayService = defineSetup("SectionDriverStartRelayServi
157
162
  apiMapDistance
158
163
  } = useMapGeometry();
159
164
  return () => {
165
+ var _a;
160
166
  const {
161
167
  from: fromPlace,
162
168
  relayTo: relayToPlace,
163
169
  carPosition,
164
170
  carAngle,
165
171
  carTrackPositions,
172
+ carRoute,
166
173
  passengerPosition,
167
174
  passengerAngle,
168
175
  relayToTitle,
@@ -206,7 +213,21 @@ const SectionDriverStartRelayService = defineSetup("SectionDriverStartRelayServi
206
213
  "label": relayToTitle,
207
214
  "hideIcon": true
208
215
  }
209
- }), !(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : h(DeviationCorrectionDrivingRoute, {
216
+ }), carRoute ? [h(DrivingLine, {
217
+ "attrs": {
218
+ "path": carRoute.path
219
+ }
220
+ }), h(TaxiCar, {
221
+ "attrs": {
222
+ "position": (_a = carRoute.path[0]) != null ? _a : carPosition,
223
+ "angle": carAngle,
224
+ "title": renderTitle({
225
+ distance: carRoute.distance,
226
+ duration: carRoute.duration
227
+ }),
228
+ "registerOverlay": fittableRegistryOverlay
229
+ }
230
+ })] : !(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : h(DeviationCorrectionDrivingRoute, {
210
231
  "attrs": {
211
232
  "tracks": carTrackPositions,
212
233
  "to": from,
@@ -219,7 +240,7 @@ const SectionDriverStartRelayService = defineSetup("SectionDriverStartRelayServi
219
240
  duration,
220
241
  trafficJams
221
242
  }) => {
222
- var _a;
243
+ var _a2;
223
244
  return [relayTo ? h(TrafficDrivingLine, {
224
245
  "attrs": {
225
246
  "path": path,
@@ -227,7 +248,7 @@ const SectionDriverStartRelayService = defineSetup("SectionDriverStartRelayServi
227
248
  }
228
249
  }) : null, h(TaxiCar, {
229
250
  "attrs": {
230
- "position": (_a = path[0]) != null ? _a : carPosition,
251
+ "position": (_a2 = path[0]) != null ? _a2 : carPosition,
231
252
  "angle": angle != null ? angle : carAngle,
232
253
  "title": renderTitle({
233
254
  distance,
@@ -278,11 +299,13 @@ const SectionDriverStartService = defineSetup("SectionDriverStartService", funct
278
299
  apiMapDistance
279
300
  } = useMapGeometry();
280
301
  return () => {
302
+ var _a;
281
303
  const {
282
304
  from: fromPlace,
283
305
  carPosition,
284
306
  carAngle,
285
307
  carTrackPositions,
308
+ carRoute,
286
309
  passengerPosition,
287
310
  passengerAngle,
288
311
  renderTitle
@@ -310,7 +333,21 @@ const SectionDriverStartService = defineSetup("SectionDriverStartService", funct
310
333
  "label": fromPlace.displayName,
311
334
  "hideIcon": true
312
335
  }
313
- }), !(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : carDistance > CAR_DISTANCE_MIN ? h(DeviationCorrectionDrivingRoute, {
336
+ }), carRoute ? [h(DrivingLine, {
337
+ "attrs": {
338
+ "path": carRoute.path
339
+ }
340
+ }), h(TaxiCar, {
341
+ "attrs": {
342
+ "position": (_a = carRoute.path[0]) != null ? _a : carPosition,
343
+ "angle": carAngle,
344
+ "title": renderTitle({
345
+ distance: carRoute.distance,
346
+ duration: carRoute.duration
347
+ }),
348
+ "registerOverlay": fittableRegistryOverlay
349
+ }
350
+ })] : !(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : carDistance > CAR_DISTANCE_MIN ? h(DeviationCorrectionDrivingRoute, {
314
351
  "attrs": {
315
352
  "tracks": carTrackPositions,
316
353
  "to": from,
@@ -322,7 +359,7 @@ const SectionDriverStartService = defineSetup("SectionDriverStartService", funct
322
359
  duration,
323
360
  trafficJams
324
361
  }) => {
325
- var _a;
362
+ var _a2;
326
363
  return [h(TrafficDrivingLine, {
327
364
  "attrs": {
328
365
  "path": path,
@@ -330,7 +367,7 @@ const SectionDriverStartService = defineSetup("SectionDriverStartService", funct
330
367
  }
331
368
  }), h(TaxiCar, {
332
369
  "attrs": {
333
- "position": (_a = path[0]) != null ? _a : carPosition,
370
+ "position": (_a2 = path[0]) != null ? _a2 : carPosition,
334
371
  "angle": angle != null ? angle : carAngle,
335
372
  "title": renderTitle({
336
373
  distance,
@@ -348,10 +385,10 @@ const SectionDriverStartService = defineSetup("SectionDriverStartService", funct
348
385
  path: graspRoadPath,
349
386
  angle
350
387
  }) => {
351
- var _a;
388
+ var _a2;
352
389
  return h(TaxiCar, {
353
390
  "attrs": {
354
- "position": (_a = graspRoadPath[graspRoadPath.length - 1]) != null ? _a : carPosition,
391
+ "position": (_a2 = graspRoadPath[graspRoadPath.length - 1]) != null ? _a2 : carPosition,
355
392
  "angle": angle != null ? angle : carAngle,
356
393
  "title": renderTitle({
357
394
  distance: carDistance,
@@ -401,12 +438,17 @@ const SectionBookDispatched = defineSetup("SectionBookDispatched", function(prop
401
438
  title,
402
439
  passengerPosition,
403
440
  passengerAngle,
441
+ routePath,
404
442
  registerOverlay
405
443
  } = props;
406
444
  const from = place2point(fromPlace);
407
445
  const to = place2point(toPlace);
408
446
  const passengerDistance = passengerPosition ? apiMapDistance(passengerPosition, from) : void 0;
409
- return h("div", [h(DrivingRoute, {
447
+ return h("div", [routePath ? h(DrivingLine, {
448
+ "attrs": {
449
+ "path": routePath
450
+ }
451
+ }) : h(DrivingRoute, {
410
452
  "attrs": {
411
453
  "to": to,
412
454
  "from": from,
@@ -565,11 +607,13 @@ const SectionInService = defineSetup("SectionInService", function(props) {
565
607
  immediate: true
566
608
  });
567
609
  return () => {
610
+ var _a;
568
611
  const {
569
612
  to: toPlace,
570
613
  carPosition,
571
614
  carAngle,
572
615
  carTrackPositions,
616
+ carRoute,
573
617
  renderTitle
574
618
  } = props;
575
619
  const to = place2point(toPlace);
@@ -580,7 +624,21 @@ const SectionInService = defineSetup("SectionInService", function(props) {
580
624
  apiMapDistance
581
625
  } = useMapGeometry();
582
626
  const carDistance = carPosition ? apiMapDistance(carPosition, to) : void 0;
583
- return h("div", [!(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : carDistance > CAR_DISTANCE_MIN ? h(DeviationCorrectionDrivingRoute, {
627
+ return h("div", [carRoute ? [h(DrivingLine, {
628
+ "attrs": {
629
+ "path": carRoute.path
630
+ }
631
+ }), h(TaxiCar, {
632
+ "attrs": {
633
+ "position": (_a = carRoute.path[0]) != null ? _a : carPosition,
634
+ "angle": carAngle,
635
+ "title": renderTitle({
636
+ distance: carRoute.distance,
637
+ duration: carRoute.duration
638
+ }),
639
+ "registerOverlay": fittableRegistryOverlay
640
+ }
641
+ })] : !(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : carDistance > CAR_DISTANCE_MIN ? h(DeviationCorrectionDrivingRoute, {
584
642
  "attrs": {
585
643
  "tracks": carTrackPositions,
586
644
  "to": to,
@@ -592,7 +650,7 @@ const SectionInService = defineSetup("SectionInService", function(props) {
592
650
  duration,
593
651
  trafficJams
594
652
  }) => {
595
- var _a;
653
+ var _a2;
596
654
  return [h(TrafficDrivingLine, {
597
655
  "attrs": {
598
656
  "path": path,
@@ -600,7 +658,7 @@ const SectionInService = defineSetup("SectionInService", function(props) {
600
658
  }
601
659
  }), h(TaxiCar, {
602
660
  "attrs": {
603
- "position": (_a = path[0]) != null ? _a : carPosition,
661
+ "position": (_a2 = path[0]) != null ? _a2 : carPosition,
604
662
  "angle": angle != null ? angle : carAngle,
605
663
  "title": renderTitle({
606
664
  distance,
@@ -618,10 +676,10 @@ const SectionInService = defineSetup("SectionInService", function(props) {
618
676
  path: graspRoadPath,
619
677
  angle
620
678
  }) => {
621
- var _a;
679
+ var _a2;
622
680
  return h(TaxiCar, {
623
681
  "attrs": {
624
- "position": (_a = graspRoadPath[graspRoadPath.length - 1]) != null ? _a : carPosition,
682
+ "position": (_a2 = graspRoadPath[graspRoadPath.length - 1]) != null ? _a2 : carPosition,
625
683
  "angle": angle != null ? angle : carAngle,
626
684
  "title": renderTitle({
627
685
  distance: carDistance,
@@ -718,11 +776,17 @@ const SectionEndService = defineSetup("SectionEndService", function(props) {
718
776
  const {
719
777
  from: fromPlace,
720
778
  to: toPlace,
779
+ routePath,
721
780
  registerOverlay
722
781
  } = props;
723
782
  const from = place2point(fromPlace);
724
783
  const to = place2point(toPlace);
725
- return h("div", [h(DrivingRoute, {
784
+ return h("div", [routePath ? h(DrivingLine, {
785
+ "attrs": {
786
+ "path": routePath,
787
+ "status": "DONE"
788
+ }
789
+ }) : h(DrivingRoute, {
726
790
  "attrs": {
727
791
  "from": from,
728
792
  "to": to,