@heycar/heycars-map 0.10.1 → 0.10.3-relay1

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 (68) hide show
  1. package/README.md +7 -0
  2. package/dist/index.d.ts +1 -1
  3. package/dist/index.js +1 -1
  4. package/dist/v2/App.js +3 -3
  5. package/dist/v2/Demo/Demo.js +3 -3
  6. package/dist/v2/Demo/DemoBusinessTaxiService.d.ts +1 -0
  7. package/dist/v2/Demo/DemoBusinessTaxiService.js +39 -19
  8. package/dist/v2/api/cdn.d.ts +1 -0
  9. package/dist/v2/api/cdn.js +3 -1
  10. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.d.ts +2 -0
  11. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.js +25 -3
  12. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.d.ts +5 -0
  13. package/dist/v2/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.js +141 -0
  14. package/dist/v2/business-components/PlaceCircle/PlaceCircle.js +1 -1
  15. package/dist/v2/business-components/StartEndPoint/StartEndPoint.css.d.ts +5 -0
  16. package/dist/v2/business-components/StartEndPoint/StartEndPoint.d.ts +1 -1
  17. package/dist/v2/business-components/StartEndPoint/StartEndPoint.js +3 -3
  18. package/dist/v2/business-components/TaxiCar/TaxiCar.js +1 -1
  19. package/dist/v2/chunks/{StartEndPoint.css.8242788c.js → StartEndPoint.css.38f98dca.js} +4 -4
  20. package/dist/v2/components/Amap/Amap.d.ts +2 -3
  21. package/dist/v2/components/Amap/Amap.js +2 -11
  22. package/dist/v2/components/MapProvider/MapProvider.js +2 -2
  23. package/dist/{v3/css/PlaceCircle-3c051f4e.css → v2/css/PlaceCircle-fe58915a.css} +1 -0
  24. package/dist/v2/css/{StartEndPoint-d7806e8e.css → StartEndPoint-5bf29d8c.css} +7 -2
  25. package/dist/v2/hooks/useDeviationCorrectionDrivingRoute.d.ts +2 -1
  26. package/dist/v2/hooks/useDeviationCorrectionDrivingRoute.js +12 -5
  27. package/dist/v2/hooks/useDrivingRoute.d.ts +4 -3
  28. package/dist/v2/hooks/useDrivingRoute.js +14 -12
  29. package/dist/v2/types/amap/index.d.ts +1 -0
  30. package/dist/v2/types/amap/options.d.ts +8 -0
  31. package/dist/v2/types/amap/options.js +1 -0
  32. package/dist/v2/types/interface.d.ts +1 -1
  33. package/dist/v2/utils/log.js +1 -1
  34. package/dist/v2/utils/transform.d.ts +1 -3
  35. package/dist/v2/utils/transform.js +0 -10
  36. package/dist/v3/App.js +3 -3
  37. package/dist/v3/Demo/Demo.js +3 -3
  38. package/dist/v3/Demo/DemoBusinessTaxiService.d.ts +1 -0
  39. package/dist/v3/Demo/DemoBusinessTaxiService.js +39 -19
  40. package/dist/v3/api/cdn.d.ts +1 -0
  41. package/dist/v3/api/cdn.js +3 -1
  42. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.d.ts +2 -0
  43. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceMap.js +21 -3
  44. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.d.ts +9 -0
  45. package/dist/v3/business-components/BusinessTaxiServiceMap/BusinessTaxiServiceSection.js +113 -0
  46. package/dist/v3/business-components/PlaceCircle/PlaceCircle.js +1 -1
  47. package/dist/v3/business-components/StartEndPoint/StartEndPoint.css.d.ts +5 -0
  48. package/dist/v3/business-components/StartEndPoint/StartEndPoint.d.ts +1 -1
  49. package/dist/v3/business-components/StartEndPoint/StartEndPoint.js +3 -3
  50. package/dist/v3/business-components/TaxiCar/TaxiCar.js +1 -1
  51. package/dist/v3/chunks/{StartEndPoint.css.8242788c.js → StartEndPoint.css.38f98dca.js} +4 -4
  52. package/dist/v3/components/Amap/Amap.d.ts +2 -3
  53. package/dist/v3/components/Amap/Amap.js +2 -11
  54. package/dist/v3/components/MapProvider/MapProvider.js +2 -2
  55. package/dist/{v2/css/PlaceCircle-3c051f4e.css → v3/css/PlaceCircle-fe58915a.css} +1 -0
  56. package/dist/v3/css/{StartEndPoint-d7806e8e.css → StartEndPoint-5bf29d8c.css} +7 -2
  57. package/dist/v3/hooks/useDeviationCorrectionDrivingRoute.d.ts +2 -1
  58. package/dist/v3/hooks/useDeviationCorrectionDrivingRoute.js +12 -5
  59. package/dist/v3/hooks/useDrivingRoute.d.ts +4 -3
  60. package/dist/v3/hooks/useDrivingRoute.js +14 -12
  61. package/dist/v3/types/amap/index.d.ts +1 -0
  62. package/dist/v3/types/amap/options.d.ts +8 -0
  63. package/dist/v3/types/amap/options.js +1 -0
  64. package/dist/v3/types/interface.d.ts +1 -1
  65. package/dist/v3/utils/log.js +1 -1
  66. package/dist/v3/utils/transform.d.ts +1 -3
  67. package/dist/v3/utils/transform.js +0 -10
  68. package/package.json +1 -1
package/README.md CHANGED
@@ -431,6 +431,13 @@ export default defineComponent({
431
431
  lat: 1.2966426,
432
432
  lng: 103.7763939,
433
433
  }}
434
+ relayTo={{
435
+ displayName: "UFOU沃达迈Waldmann(虹桥南丰城南区店)",
436
+ name: "虹桥南丰城南区2楼208号",
437
+ lat: 31.207145,
438
+ lng: 121.407842,
439
+ }}
440
+ relayToTitle="上个乘客将\n在这下车"
434
441
  driverStatus={"driverArrived"}
435
442
  bookDispatchingTitle="2月14日 11:00 用车"
436
443
  dispatchingTitle="正在为您搜索附近司机"
package/dist/index.d.ts CHANGED
@@ -1 +1 @@
1
- export * from "./v2"
1
+ export * from "./v3"
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- export * from "./v2"
1
+ export * from "./v3"
package/dist/v2/App.js CHANGED
@@ -2,11 +2,11 @@ import { h } from "vue";
2
2
  import { defineComponent } from "vue-demi";
3
3
  import { DemoBusinessQuoting } from "./Demo/DemoBusinessQuoting.js";
4
4
  import { MapProvider } from "./components/MapProvider/MapProvider.js";
5
- const gmapApiKey = "AIzaSyCRtkaNSWMOhOXDOUpJK4OVbm5RIstYj-I";
5
+ const gmapApiKey = "AIzaSyCCOe8MAeS3EYvSraKsBX6ztVyLxj69z94";
6
6
  const gmapId = "d0af0c05331af64a";
7
7
  const gmapRasterId = "e02db3cb62a7b46";
8
- const amapApiKey = "81ed1d2b5b77187683717a5f2f19591a";
9
- const amapApiSecret = "1dfe626553258a9f91d7c4552c0816d2";
8
+ const amapApiKey = "fcb7b14c930354a248e21f4031dfa179";
9
+ const amapApiSecret = "11ad0e3d585b80d18b1ada5b0d947c4a";
10
10
  const App = defineComponent({
11
11
  setup() {
12
12
  return () => h(MapProvider, {
@@ -1481,9 +1481,9 @@ const chinaSeaBounds = [
1481
1481
  21.500669
1482
1482
  ]
1483
1483
  ];
1484
- const gmapApiKey = "AIzaSyCRtkaNSWMOhOXDOUpJK4OVbm5RIstYj-I";
1485
- const amapApiKey = "81ed1d2b5b77187683717a5f2f19591a";
1486
- const amapApiSecret = "1dfe626553258a9f91d7c4552c0816d2";
1484
+ const gmapApiKey = "AIzaSyCCOe8MAeS3EYvSraKsBX6ztVyLxj69z94";
1485
+ const amapApiKey = "fcb7b14c930354a248e21f4031dfa179";
1486
+ const amapApiSecret = "11ad0e3d585b80d18b1ada5b0d947c4a";
1487
1487
  const DemoGmap = defineSetup("DemoGmap", function() {
1488
1488
  const latRef = ref(0);
1489
1489
  const visibleRef = ref(false);
@@ -2394,6 +2394,7 @@ export declare const DemoBusinessTaxiService: import("vue-demi").DefineComponent
2394
2394
  }, {
2395
2395
  from: Partial<Place>;
2396
2396
  to: Partial<Place>;
2397
+ relayTo: Partial<Place>;
2397
2398
  status: DriverStatus;
2398
2399
  contentHeight: number;
2399
2400
  }, {}, {
@@ -4,7 +4,23 @@ import { BusinessTaxiServiceMap } from "../business-components/BusinessTaxiServi
4
4
  import { useBusinessTaxiServiceMap } from "../hooks-business/useBusinessTaxiServiceMap.js";
5
5
  import { isPlace } from "../utils/helper.js";
6
6
  import { l as layout, a as adjustedDemo } from "../chunks/Demo.css.e921a2f6.js";
7
- const allDriverStatus = ["dispatching", "book-dispatching", "dispatched", "driverStartService", "book-driverStartService", "book-dispatched", "driverArrived", "inService", "canceled", "endService", "completed", "canceling", "banlanceRefund", "waitBanlanceRefund", "rechargePayed", "waitRechargePay", "payed", "waitpay", "refund", "confirmed", "assign"];
7
+ const allDriverStatus = ["dispatching", "book-dispatching", "dispatched", "driverStartRelayService", "driverStartService", "book-driverStartService", "book-dispatched", "driverArrived", "inService", "canceled", "endService", "completed", "canceling", "banlanceRefund", "waitBanlanceRefund", "rechargePayed", "waitRechargePay", "payed", "waitpay", "refund", "confirmed", "assign"];
8
+ const mockDriverTrackPoints = [{
9
+ lng: 121.4036983,
10
+ lat: 31.216324,
11
+ angle: 30,
12
+ timestamp: 1698058438e3
13
+ }, {
14
+ lng: 121.4036983,
15
+ lat: 31.216324,
16
+ angle: 30,
17
+ timestamp: 1698058439e3
18
+ }, {
19
+ lng: 121.403581,
20
+ lat: 31.216415,
21
+ angle: 30,
22
+ timestamp: 1698058442e3
23
+ }];
8
24
  const DemoBusinessTaxiService = defineComponent({
9
25
  name: "DemoBusinessTaxiService",
10
26
  setup() {
@@ -21,7 +37,8 @@ const DemoBusinessTaxiService = defineComponent({
21
37
  return {
22
38
  from: {},
23
39
  to: {},
24
- status: "dispatched",
40
+ relayTo: {},
41
+ status: "driverStartRelayService",
25
42
  contentHeight: 200
26
43
  };
27
44
  },
@@ -37,6 +54,11 @@ const DemoBusinessTaxiService = defineComponent({
37
54
  lng: 121.3995217963426,
38
55
  name: "上海站"
39
56
  };
57
+ this.relayTo = {
58
+ lat: 31.207145,
59
+ lng: 121.407842,
60
+ name: "UFOU沃达迈Waldmann(虹桥南丰城南区店)"
61
+ };
40
62
  }, 1e3);
41
63
  setTimeout(() => {
42
64
  this.contentHeight = 600;
@@ -46,28 +68,23 @@ const DemoBusinessTaxiService = defineComponent({
46
68
  const {
47
69
  value: status
48
70
  } = statusIterator.next();
49
- this.status = status;
71
+ if (status) {
72
+ this.status = status;
73
+ }
50
74
  return status;
51
75
  };
76
+ window.addDriverPosition = (lng, lat, angle = 0) => {
77
+ mockDriverTrackPoints.push({
78
+ lng,
79
+ lat,
80
+ angle,
81
+ timestamp: Date.now()
82
+ });
83
+ };
52
84
  },
53
85
  methods: {
54
86
  getDriverPositionTrack() {
55
- return Promise.resolve([{
56
- lng: 121.4036983,
57
- lat: 31.216324,
58
- angle: 30,
59
- timestamp: 1698058438e3
60
- }, {
61
- lng: 121.4036983,
62
- lat: 31.216324,
63
- angle: 30,
64
- timestamp: 1698058439e3
65
- }, {
66
- lng: 121.403581,
67
- lat: 31.216415,
68
- angle: 30,
69
- timestamp: 1698058442e3
70
- }]);
87
+ return Promise.resolve(mockDriverTrackPoints);
71
88
  }
72
89
  },
73
90
  render() {
@@ -77,6 +94,7 @@ const DemoBusinessTaxiService = defineComponent({
77
94
  registerFitVeiw,
78
95
  from,
79
96
  to,
97
+ relayTo,
80
98
  status
81
99
  } = this;
82
100
  const isReady = isPlace(from) && isPlace(to);
@@ -92,7 +110,9 @@ const DemoBusinessTaxiService = defineComponent({
92
110
  "attrs": {
93
111
  "from": from,
94
112
  "to": to,
113
+ "relayTo": relayTo,
95
114
  "driverStatus": status,
115
+ "relayToTitle": "上个乘客将\n在这下车",
96
116
  "bookDispatchingTitle": "2月14日 11:00 用车",
97
117
  "dispatchingTitle": "正在为您搜索附近司机",
98
118
  "driverArrivedTitle": "司机已等待 00:35",
@@ -5,3 +5,4 @@ export declare const ICON_END_POINT_EN_URL = "https://overseas-oss.heycars.cn/he
5
5
  export declare const ICON_END_POINT_ZH_TW_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/end-point-zh-TW.svg";
6
6
  export declare const ICON_TAXI_CAR_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/taxi-car.svg";
7
7
  export declare const ICON_DOT_LOADING_URL = "https://overseas-oss.heycars.cn/heycar-map/gif/dot-loading.gif";
8
+ export declare const ICON_WAYPOINT_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/waypoint.svg";
@@ -5,6 +5,7 @@ const ICON_END_POINT_EN_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/en
5
5
  const ICON_END_POINT_ZH_TW_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/end-point-zh-TW.svg";
6
6
  const ICON_TAXI_CAR_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/taxi-car.svg";
7
7
  const ICON_DOT_LOADING_URL = "https://overseas-oss.heycars.cn/heycar-map/gif/dot-loading.gif";
8
+ const ICON_WAYPOINT_URL = "https://overseas-oss.heycars.cn/heycar-map/svg/waypoint.svg";
8
9
  export {
9
10
  AMAP_DEFAULT_MARKER_ICON_URL,
10
11
  ICON_DOT_LOADING_URL,
@@ -12,5 +13,6 @@ export {
12
13
  ICON_END_POINT_ZH_TW_URL,
13
14
  ICON_FULL_SCREEN_URL,
14
15
  ICON_START_POINT_EN_URL,
15
- ICON_TAXI_CAR_URL
16
+ ICON_TAXI_CAR_URL,
17
+ ICON_WAYPOINT_URL
16
18
  };
@@ -5,6 +5,8 @@ export type BusinessTaxiServiceMapProps = Omit<HeycarMapProps, "center" | "zoom"
5
5
  from: Place;
6
6
  to: Place;
7
7
  log?: boolean;
8
+ relayTo?: Place;
9
+ relayToTitle?: string;
8
10
  dispatchingTitle: string;
9
11
  bookDispatchingTitle: string;
10
12
  driverArrivedTitle: string;
@@ -9,8 +9,8 @@ import { assertNotEmptyArray } from "../../utils/helper.js";
9
9
  import { toPlaceType, place2point, combineHandler, pipeDefer, toTrackPoints, lnglat2point } from "../../utils/transform.js";
10
10
  import { AuxiliaryGraspRoad } from "../AuxiliaryGraspRoad/AuxiliaryGraspRoad.js";
11
11
  import { DeviceOrientation } from "../DeviceOrientation/DeviceOrientation.js";
12
- import { SectionDispatching, SectionConfirmed, SectionDriverStartService, SectionBookDispatched, SectionInService, SectionDriverArrived, SectionCanceled, SectionEndService } from "./BusinessTaxiServiceSection.js";
13
- const STATUS_NEED_CAR_POSITION = ["book-driverStartService", "dispatched", "driverStartService", "inService", "driverArrived"];
12
+ import { SectionDispatching, SectionConfirmed, SectionDriverStartRelayService, SectionDriverStartService, SectionBookDispatched, SectionInService, SectionDriverArrived, SectionCanceled, SectionEndService } from "./BusinessTaxiServiceSection.js";
13
+ const STATUS_NEED_CAR_POSITION = ["book-driverStartService", "dispatched", "driverStartRelayService", "driverStartService", "inService", "driverArrived"];
14
14
  const IS_ENABLE_AUXILIARY_GRASP_ROAD = apiGetAuxiliaryGrapStatus();
15
15
  const BusinessTaxiServiceMap = defineLagecySetup("BusinessTaxiServiceMap", function(props, {
16
16
  attrs
@@ -64,12 +64,15 @@ const BusinessTaxiServiceMap = defineLagecySetup("BusinessTaxiServiceMap", funct
64
64
  driverStatus,
65
65
  from: inputFrom,
66
66
  to: inputTo,
67
+ relayTo: inputRelayTo,
68
+ relayToTitle,
67
69
  dispatchingTitle,
68
70
  bookDispatchingTitle,
69
71
  driverArrivedTitle
70
72
  } = props;
71
73
  const from = toPlaceType(inputFrom);
72
74
  const to = toPlaceType(inputTo);
75
+ const relayTo = inputRelayTo ? toPlaceType(inputRelayTo) : void 0;
73
76
  const carPosition = carPositionRef.value;
74
77
  const carAngle = carAngleRef.value;
75
78
  const carTrackPositions = carTrackPositionsRef.value;
@@ -113,6 +116,25 @@ const BusinessTaxiServiceMap = defineLagecySetup("BusinessTaxiServiceMap", funct
113
116
  }
114
117
  })
115
118
  }
119
+ }) : driverStatus === "driverStartRelayService" ? h(DeviceOrientation, {
120
+ "attrs": {
121
+ "elementRef": mapElementRef,
122
+ "disable": !passengerPosition,
123
+ "render": (orientation) => h(SectionDriverStartRelayService, {
124
+ "attrs": {
125
+ "from": from,
126
+ "relayTo": relayTo,
127
+ "carPosition": carPosition,
128
+ "carAngle": carAngle,
129
+ "carTrackPositions": carTrackPositions,
130
+ "passengerPosition": passengerPosition,
131
+ "passengerAngle": orientation == null ? void 0 : orientation.cssRotationVariableName,
132
+ "relayToTitle": relayToTitle,
133
+ "renderTitle": renderStartSerivceTitle,
134
+ "registerOverlay": registerOverlay
135
+ }
136
+ })
137
+ }
116
138
  }) : driverStatus === "dispatched" || driverStatus === "driverStartService" || driverStatus === "book-driverStartService" ? h(DeviceOrientation, {
117
139
  "attrs": {
118
140
  "elementRef": mapElementRef,
@@ -199,7 +221,7 @@ const BusinessTaxiServiceMap = defineLagecySetup("BusinessTaxiServiceMap", funct
199
221
  }
200
222
  })]);
201
223
  };
202
- }).props(["bookDispatchingTitle", "dispatchingTitle", "driverArrivedTitle", "driverStatus", "fallback", "from", "getDriverPositionTrack", "interval", "disablePassenger", "loading", "mapRef", "renderInServiceTitle", "renderStartSerivceTitle", "to", "registerOverlay"]);
224
+ }).props(["bookDispatchingTitle", "dispatchingTitle", "driverArrivedTitle", "driverStatus", "fallback", "from", "getDriverPositionTrack", "interval", "disablePassenger", "loading", "mapRef", "relayTo", "relayToTitle", "renderInServiceTitle", "renderStartSerivceTitle", "to", "registerOverlay"]);
203
225
  export {
204
226
  BusinessTaxiServiceMap
205
227
  };
@@ -13,6 +13,11 @@ type SectionConfirmedProps = Required<MROP> & {
13
13
  to: Place;
14
14
  };
15
15
  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
+ interface SectionDriverStartRelayServiceProps extends SectionDriverStartServiceProps {
17
+ relayTo?: Place;
18
+ relayToTitle?: string;
19
+ }
20
+ export declare const SectionDriverStartRelayService: import("vue").DefineComponent<import("vue3").ComponentObjectPropsOptions<SectionDriverStartRelayServiceProps>, 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<SectionDriverStartRelayServiceProps, Required<SectionDriverStartRelayServiceProps>>, never, SectionDriverStartRelayServiceProps>;
16
21
  type SectionDriverStartServiceProps = Required<MROP> & {
17
22
  passengerPosition?: Point;
18
23
  passengerAngle?: string;
@@ -141,6 +141,146 @@ const SectionConfirmed = defineSetup("SectionConfirmed", function(props) {
141
141
  })]);
142
142
  };
143
143
  });
144
+ const SectionDriverStartRelayService = defineSetup("SectionDriverStartRelayService", function(props) {
145
+ const {
146
+ registerOverlay
147
+ } = props;
148
+ const fittableRegistryOverlay = createFittableRegisterOverlay({
149
+ registerOverlay,
150
+ immediate: true
151
+ });
152
+ const {
153
+ language
154
+ } = useMapSupplier();
155
+ const {
156
+ apiMapDistance
157
+ } = useMapGeometry();
158
+ return () => {
159
+ const {
160
+ from: fromPlace,
161
+ relayTo: relayToPlace,
162
+ carPosition,
163
+ carAngle,
164
+ carTrackPositions,
165
+ passengerPosition,
166
+ passengerAngle,
167
+ relayToTitle,
168
+ renderTitle
169
+ } = props;
170
+ const from = place2point(fromPlace);
171
+ const relayTo = relayToPlace ? place2point(relayToPlace) : void 0;
172
+ const waypoints = relayTo ? [relayTo] : void 0;
173
+ const passengerDistance = passengerPosition ? apiMapDistance(passengerPosition, from) : void 0;
174
+ const carDistance = carPosition ? apiMapDistance(carPosition, from) : void 0;
175
+ return h("div", [h(ConditionalFittablePassengerCircle, {
176
+ "attrs": {
177
+ "position": passengerPosition,
178
+ "angle": passengerAngle,
179
+ "condition": !!passengerDistance && passengerDistance < PASSENGER_DISTANCE_MAX,
180
+ "registerOverlay": registerOverlay
181
+ }
182
+ }), h(StartEndPoint, {
183
+ "attrs": {
184
+ "type": "start",
185
+ "position": from,
186
+ "registerOverlay": registerOverlay,
187
+ "language": language
188
+ }
189
+ }), h(PlaceCircle, {
190
+ "attrs": {
191
+ "position": from,
192
+ "label": fromPlace.displayName,
193
+ "hideIcon": true
194
+ }
195
+ }), !!relayTo && h(StartEndPoint, {
196
+ "attrs": {
197
+ "type": "waypoint",
198
+ "position": relayTo,
199
+ "registerOverlay": registerOverlay,
200
+ "language": language
201
+ }
202
+ }), !!relayTo && !!relayToTitle && h(PlaceCircle, {
203
+ "attrs": {
204
+ "position": relayTo,
205
+ "label": relayToTitle,
206
+ "hideIcon": true
207
+ }
208
+ }), !(carTrackPositions == null ? void 0 : carTrackPositions.length) || !carDistance ? null : carDistance > CAR_DISTANCE_MIN ? h(DeviationCorrectionDrivingRoute, {
209
+ "attrs": {
210
+ "tracks": carTrackPositions,
211
+ "to": from,
212
+ "waypoints": waypoints,
213
+ "deviation": MAX_DEVIATION_DISTANCE,
214
+ "render": ({
215
+ path,
216
+ angle,
217
+ distance,
218
+ duration
219
+ }) => {
220
+ var _a;
221
+ return [h(DrivingLine, {
222
+ "attrs": {
223
+ "path": path
224
+ }
225
+ }), h(TaxiCar, {
226
+ "attrs": {
227
+ "position": (_a = path[0]) != null ? _a : carPosition,
228
+ "angle": angle != null ? angle : carAngle,
229
+ "title": renderTitle({
230
+ distance,
231
+ duration
232
+ }),
233
+ "registerOverlay": fittableRegistryOverlay
234
+ }
235
+ })];
236
+ }
237
+ }
238
+ }) : h(GraspRoad, {
239
+ "attrs": {
240
+ "tracks": carTrackPositions,
241
+ "render": ({
242
+ path: graspRoadPath,
243
+ angle
244
+ }) => {
245
+ var _a;
246
+ return h(TaxiCar, {
247
+ "attrs": {
248
+ "position": (_a = graspRoadPath[graspRoadPath.length - 1]) != null ? _a : carPosition,
249
+ "angle": angle != null ? angle : carAngle,
250
+ "title": renderTitle({
251
+ distance: carDistance,
252
+ duration: carDurationWithinMinDistance(carDistance)
253
+ }),
254
+ "registerOverlay": fittableRegistryOverlay
255
+ }
256
+ });
257
+ }
258
+ }
259
+ }), !!passengerPosition && passengerDistance && passengerDistance < PASSENGER_DISTANCE_MAX && passengerDistance > PASSENGER_DISTANCE_MIN && h(WalkingRoute, {
260
+ "attrs": {
261
+ "from": passengerPosition,
262
+ "to": from,
263
+ "render": ({
264
+ path
265
+ }) => h(WalkingLine, {
266
+ "attrs": {
267
+ "path": path
268
+ }
269
+ })
270
+ }
271
+ }), h(FitViewOnce, {
272
+ "attrs": {
273
+ "registerOverlay": registerOverlay,
274
+ "immediate": true
275
+ }
276
+ }), h(InterruptableIntervalFitView, {
277
+ "attrs": {
278
+ "interval": AUTO_FIT_VIEW_INTERVAL,
279
+ "registerOverlay": registerOverlay
280
+ }
281
+ })]);
282
+ };
283
+ });
144
284
  const SectionDriverStartService = defineSetup("SectionDriverStartService", function(props) {
145
285
  const {
146
286
  registerOverlay
@@ -651,6 +791,7 @@ export {
651
791
  SectionConfirmed,
652
792
  SectionDispatching,
653
793
  SectionDriverArrived,
794
+ SectionDriverStartRelayService,
654
795
  SectionDriverStartService,
655
796
  SectionEndService,
656
797
  SectionInService
@@ -1,4 +1,4 @@
1
- import "../../css/PlaceCircle-3c051f4e.css";
1
+ import "../../css/PlaceCircle-fe58915a.css";
2
2
  import { h } from "vue";
3
3
  import { computed } from "vue-demi";
4
4
  import { ZINDEX_PLACE_LAYER } from "../../api/contants.js";
@@ -16,6 +16,11 @@ export declare const pointIcon: import("@vanilla-extract/recipes").RuntimeFn<{
16
16
  width: "6.192vw";
17
17
  height: "7.998vw";
18
18
  };
19
+ waypoint: {
20
+ marginTop: "1.33vw";
21
+ width: "6.192vw";
22
+ height: "7.998vw";
23
+ };
19
24
  };
20
25
  }>;
21
26
  export declare const textLayout: import("@vanilla-extract/recipes").RuntimeFn<{
@@ -2,7 +2,7 @@ import type { GmapOverlay, MapRegisterOverlayProps } from "../../hooks/useOverla
2
2
  import type { Language, Point } from "../../types/interface";
3
3
  export interface StartEndPointProps<T> extends MapRegisterOverlayProps<T> {
4
4
  language: Language;
5
- type: "start" | "end";
5
+ type: "start" | "end" | "waypoint";
6
6
  position: [number, number];
7
7
  title?: string;
8
8
  description?: string;
@@ -1,6 +1,6 @@
1
1
  import { h } from "vue";
2
2
  import { computed } from "vue-demi";
3
- import { ICON_START_POINT_EN_URL, ICON_END_POINT_ZH_TW_URL, ICON_END_POINT_EN_URL } from "../../api/cdn.js";
3
+ import { ICON_WAYPOINT_URL, ICON_START_POINT_EN_URL, ICON_END_POINT_ZH_TW_URL, ICON_END_POINT_EN_URL } from "../../api/cdn.js";
4
4
  import { ZINDEX_START_END_LOGO_LAYER } from "../../api/contants.js";
5
5
  import { i as imgArrowRight } from "../../chunks/arrow-right.eedc7433.js";
6
6
  import { AmapMarker } from "../../components/AmapMarker/AmapMarker.js";
@@ -10,7 +10,7 @@ import { useMapSupplier } from "../../hooks/useMapSupplier.js";
10
10
  import { defineSetup } from "../../types/helper.js";
11
11
  import { createDom } from "../../utils/dom.js";
12
12
  import { decodeAsterisk, vec2lnglat } from "../../utils/transform.js";
13
- import { p as pointInfoBoxEmphasize, a as pointIcon, b as pointLayout, c as pointSingleInfoBox, d as pointInfoBoxTitle, t as textLayout, e as arrowRight, f as pointInfoBox, g as pointInfoBoxDescription } from "../../chunks/StartEndPoint.css.8242788c.js";
13
+ import { p as pointInfoBoxEmphasize, a as pointIcon, b as pointLayout, c as pointSingleInfoBox, d as pointInfoBoxTitle, t as textLayout, e as arrowRight, f as pointInfoBox, g as pointInfoBoxDescription } from "../../chunks/StartEndPoint.css.38f98dca.js";
14
14
  const imgEndPoint = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IHgxPSI3Mi4zMzklIiB5MT0iNTAlIiB4Mj0iMCUiIHkyPSI1MCUiIGlkPSJwcmVmaXhfX2EiPjxzdG9wIHN0b3AtY29sb3I9IiNGRjg0NDciIG9mZnNldD0iMCUiLz48c3RvcCBzdG9wLWNvbG9yPSIjRkY4QjRBIiBvZmZzZXQ9IjUwLjU5NiUiLz48c3RvcCBzdG9wLWNvbG9yPSIjRkZBOTVBIiBvZmZzZXQ9IjEwMCUiLz48L2xpbmVhckdyYWRpZW50P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
16
  const AStartEndPoint = defineSetup("AStartEndPoint", function(props, {
@@ -24,7 +24,7 @@ const AStartEndPoint = defineSetup("AStartEndPoint", function(props, {
24
24
  type,
25
25
  language
26
26
  } = props;
27
- const icon = type === "start" ? language === "zh" || language === "zh-TW" ? imgStartPoint : ICON_START_POINT_EN_URL : language === "zh" ? imgEndPoint : language === "zh-TW" ? ICON_END_POINT_ZH_TW_URL : ICON_END_POINT_EN_URL;
27
+ const icon = type === "waypoint" ? ICON_WAYPOINT_URL : type === "start" ? language === "zh" || language === "zh-TW" ? imgStartPoint : ICON_START_POINT_EN_URL : language === "zh" ? imgEndPoint : language === "zh-TW" ? ICON_END_POINT_ZH_TW_URL : ICON_END_POINT_EN_URL;
28
28
  const descriptionRow = !description ? "" : decodeAsterisk(description).map((item) => item.type === "normal" ? item.value : `<span class="${pointInfoBoxEmphasize}">${item.value}</span>`).join("");
29
29
  if (!description && !title)
30
30
  return `<img class="AStartEndPoint ${pointIcon({
@@ -10,7 +10,7 @@ import { useMapSupplier } from "../../hooks/useMapSupplier.js";
10
10
  import { defineSetup } from "../../types/helper.js";
11
11
  import { createDom } from "../../utils/dom.js";
12
12
  import { decodeAsterisk, vec2lnglat } from "../../utils/transform.js";
13
- import { p as pointInfoBoxEmphasize, b as pointLayout, c as pointSingleInfoBox } from "../../chunks/StartEndPoint.css.8242788c.js";
13
+ import { p as pointInfoBoxEmphasize, b as pointLayout, c as pointSingleInfoBox } from "../../chunks/StartEndPoint.css.38f98dca.js";
14
14
  import { c as createRuntimeFn } from "../../chunks/vanilla-extract-recipes-createRuntimeFn.esm.bd6fc290.js";
15
15
  const TaxiCar_css_ts_vanilla = "";
16
16
  var carIcon = "_65j3sr1";
@@ -1,15 +1,15 @@
1
- import "../css/StartEndPoint-d7806e8e.css";
1
+ import "../css/StartEndPoint-5bf29d8c.css";
2
2
  import { c as createRuntimeFn } from "./vanilla-extract-recipes-createRuntimeFn.esm.bd6fc290.js";
3
3
  const StartEndPoint_css_ts_vanilla = "";
4
- var arrowRight = createRuntimeFn({ defaultClassName: "_4a4ovka", variantClassNames: { withArrow: { true: "_4a4ovkb", false: "_4a4ovkc" } }, defaultVariants: {}, compoundVariants: [] });
5
- var pointIcon = createRuntimeFn({ defaultClassName: "", variantClassNames: { type: { start: "_4a4ovk6", end: "_4a4ovk7" } }, defaultVariants: {}, compoundVariants: [] });
4
+ var arrowRight = createRuntimeFn({ defaultClassName: "_4a4ovkb", variantClassNames: { withArrow: { true: "_4a4ovkc", false: "_4a4ovkd" } }, defaultVariants: {}, compoundVariants: [] });
5
+ var pointIcon = createRuntimeFn({ defaultClassName: "", variantClassNames: { type: { start: "_4a4ovk6", end: "_4a4ovk7", waypoint: "_4a4ovk8" } }, defaultVariants: {}, compoundVariants: [] });
6
6
  var pointInfoBox = "_4a4ovk1";
7
7
  var pointInfoBoxDescription = "_4a4ovk4";
8
8
  var pointInfoBoxEmphasize = "_4a4ovk5";
9
9
  var pointInfoBoxTitle = "_4a4ovk3";
10
10
  var pointLayout = "_4a4ovk0";
11
11
  var pointSingleInfoBox = "_4a4ovk2";
12
- var textLayout = createRuntimeFn({ defaultClassName: "", variantClassNames: { withArrow: { true: "_4a4ovk8", false: "_4a4ovk9" } }, defaultVariants: {}, compoundVariants: [] });
12
+ var textLayout = createRuntimeFn({ defaultClassName: "", variantClassNames: { withArrow: { true: "_4a4ovk9", false: "_4a4ovka" } }, defaultVariants: {}, compoundVariants: [] });
13
13
  export {
14
14
  pointIcon as a,
15
15
  pointLayout as b,
@@ -1,9 +1,8 @@
1
1
  import type { SetMap } from "../../hooks/useHeycarMap";
2
2
  import type { AmapMap } from "../../types/interface";
3
3
  import type { MapEventHandler } from "../../types/mapHelper";
4
- import { type VectorMapForeign } from "../../utils/transform";
5
- export interface AmapProps extends Omit<AMap.MapOptions, "vectorMapForeign"> {
6
- vectorMapForeign?: VectorMapForeign;
4
+ export interface AmapProps extends Omit<AMap.MapOptions, "viewMode"> {
5
+ viewMode?: "2D" | "3D";
7
6
  mapRef?: SetMap<AmapMap>;
8
7
  dragEnable?: boolean;
9
8
  zoomEnable?: boolean;
@@ -14,15 +14,7 @@ import { SafeAmap } from "./SafeAmap.js";
14
14
  const Amap_css_ts_vanilla = "";
15
15
  var amap = "_1d8ur7t0";
16
16
  const Amap = defineSetup("Amap", function(props, { slots, emit, attrs }) {
17
- const {
18
- onDragStart,
19
- onDragEnd,
20
- onZoomEnd,
21
- onResize,
22
- mapRef: setMap,
23
- vectorMapForeign = "style_zh_cn",
24
- ...defaultOptions
25
- } = props;
17
+ const { onDragStart, onDragEnd, onZoomEnd, onResize, mapRef: setMap, ...defaultOptions } = props;
26
18
  const statusOptions = computed(() => {
27
19
  const {
28
20
  dragEnable = true,
@@ -65,8 +57,7 @@ const Amap = defineSetup("Amap", function(props, { slots, emit, attrs }) {
65
57
  const map = new SafeAmap(elementRef.value, {
66
58
  ...defaultOptions,
67
59
  scrollWheel: defaultOptions.touchZoomCenter ? false : defaultOptions.scrollWheel,
68
- doubleClickZoom: defaultOptions.touchZoomCenter ? false : defaultOptions.doubleClickZoom,
69
- vectorMapForeign
60
+ doubleClickZoom: defaultOptions.touchZoomCenter ? false : defaultOptions.doubleClickZoom
70
61
  });
71
62
  window.GlobalAmap = map;
72
63
  mapRef.value = map;
@@ -7,7 +7,7 @@ import { defineLagecySetup } from "../../types/helper.js";
7
7
  import "../../utils/alipayPolyfill.js";
8
8
  import { loadTraditionalChineseConvertOnce } from "../../utils/cn2tw.js";
9
9
  import { detectWebGL, WEBGL_STATUS, detectBrowserPlatform, OS_PLATFORM, BRWOSER_PLATFORM, detectOSPlatform } from "../../utils/platform.js";
10
- import { language2vectorMapForeign, vec2lnglat } from "../../utils/transform.js";
10
+ import { vec2lnglat } from "../../utils/transform.js";
11
11
  import { Amap } from "../Amap/Amap.js";
12
12
  import { Gmap } from "../Gmap/Gmap.js";
13
13
  const style_css_ts_vanilla = "";
@@ -136,7 +136,7 @@ const HeycarMap = defineLagecySetup("HeycarMap", function(props, {
136
136
  }, [h(Amap, {
137
137
  "attrs": {
138
138
  "mapRef": setMap,
139
- "vectorMapForeign": language2vectorMapForeign(language),
139
+ "showOversea": true,
140
140
  "center": center,
141
141
  "zoom": zoom,
142
142
  "dragEnable": touchEnable,
@@ -43,6 +43,7 @@
43
43
  -webkit-line-clamp: 2;
44
44
  -webkit-box-orient: vertical;
45
45
  overflow: hidden;
46
+ white-space: pre-line;
46
47
  }
47
48
  .fhyw8d {
48
49
  position: absolute;
@@ -58,13 +58,18 @@
58
58
  height: 7.998vw;
59
59
  }
60
60
  ._4a4ovk8 {
61
+ margin-top: 1.33vw;
62
+ width: 6.192vw;
63
+ height: 7.998vw;
64
+ }
65
+ ._4a4ovk9 {
61
66
  padding-right: 2.67vw;
62
67
  }
63
- ._4a4ovka {
68
+ ._4a4ovkb {
64
69
  width: 1.758vw;
65
70
  height: 2.93vw;
66
71
  filter: invert(1);
67
72
  }
68
- ._4a4ovkc {
73
+ ._4a4ovkd {
69
74
  display: none;
70
75
  }
@@ -2,6 +2,7 @@ import type { Point, Route, TrackPoint } from "../types/interface";
2
2
  export interface UseDeviationCorrectionDrivingRouteProps {
3
3
  tracks: TrackPoint[];
4
4
  to: Point;
5
+ waypoints?: Point[];
5
6
  deviation: number;
6
7
  }
7
8
  interface SubRoute extends Route {
@@ -44,6 +45,6 @@ export declare const useDeviationCorrectionDrivingRoute: (props?: UseDeviationCo
44
45
  trackIntersectionPathRef: import("vue-demi").Ref<Point[] | undefined>;
45
46
  routeIntersectionPathRef: import("vue-demi").Ref<Point[] | undefined>;
46
47
  extendedIntersectionPointRef: import("vue-demi").Ref<Point | undefined>;
47
- apiMapDeviationCorrectionDrivingRoute: (tracks: TrackPoint[], to: Point, deviation: number, preRoute: SubRoute) => Promise<ApiMapDeviationCorrectionDrivingRouteOutput>;
48
+ apiMapDeviationCorrectionDrivingRoute: (tracks: TrackPoint[], to: Point, deviation: number, preRoute: SubRoute, waypoints?: Point[]) => Promise<ApiMapDeviationCorrectionDrivingRouteOutput>;
48
49
  };
49
50
  export {};