@heycar/heycars-map 0.5.1 → 0.5.3

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.
@@ -9,3 +9,4 @@ export declare const hide: import("@vanilla-extract/recipes").RuntimeFn<{
9
9
  false: {};
10
10
  };
11
11
  }>;
12
+ export declare const taxiCarTitle: string;
@@ -12,6 +12,7 @@ export interface AmapProps extends Omit<AMap.MapOptions, "vectorMapForeign"> {
12
12
  touchZoom?: boolean;
13
13
  keyboardEnable?: boolean;
14
14
  pitchEnable?: boolean;
15
+ touchZoomCenter?: 0 | 1;
15
16
  onDragStart?: MapEventHandler<AMap.Map>;
16
17
  onDragEnd?: MapEventHandler<AMap.Map>;
17
18
  onZoomEnd?: MapEventHandler<AMap.Map>;
@@ -7,9 +7,10 @@ export type MapProviderProps = UseMapLoaderProps & Pick<MapSupplierPayolad, "gma
7
7
  export declare const MapProvider: import("vue").DefineComponent<import("vue/types/v3-component-props").ComponentObjectPropsOptions<MapProviderProps>, 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<MapProviderProps, Required<MapProviderProps>>, "change", MapProviderProps, {}>;
8
8
  export interface HeycarMapProps extends Pick<GmapLoaderProps, "fallback" | "loading">, Pick<AmapProps, "center" | "zoom"> {
9
9
  mapRef?: SetMap<AMap.Map> | SetMap<google.maps.Map>;
10
+ touchZoomCenter?: boolean;
11
+ touchEnable?: boolean;
10
12
  onDragEnd?: (value: [number, number]) => any;
11
13
  onZoomEnd?: (value: number) => any;
12
14
  onResize?: () => any;
13
- touchEnable?: boolean;
14
15
  }
15
16
  export declare const HeycarMap: import("vue").DefineComponent<import("vue/types/v3-component-props").ComponentObjectPropsOptions<HeycarMapProps>, 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<HeycarMapProps, Required<HeycarMapProps>>, "resize" | "dragEnd" | "zoomEnd", HeycarMapProps, {}>;
@@ -0,0 +1,8 @@
1
+ /// <reference types="google.maps" />
2
+ import { Ref, ShallowRef } from "vue-demi";
3
+ interface UseWheelZoomCenterProps<M = AMap.Map | google.maps.Map> {
4
+ mapRef: ShallowRef<M | undefined>;
5
+ enableRef?: Ref<boolean>;
6
+ }
7
+ export declare const useAmapWheelZoomCenter: (props: UseWheelZoomCenterProps<AMap.Map>) => void;
8
+ export {};
package/dist/index.cjs CHANGED
@@ -1859,6 +1859,31 @@ const useMapLoader = (props) => {
1859
1859
  onChange
1860
1860
  });
1861
1861
  };
1862
+ const ZOOM_WHEEL_RATIO = -135e-5;
1863
+ const useAmapWheelZoomCenter = (props) => {
1864
+ const { mapRef, enableRef } = props;
1865
+ const handleWheel = (e) => {
1866
+ var _a, _b, _c;
1867
+ const { deltaY } = e;
1868
+ const prevZoom = (_b = (_a = mapRef.value) == null ? void 0 : _a.getZoom()) != null ? _b : 0;
1869
+ const zoom = prevZoom + ZOOM_WHEEL_RATIO * deltaY;
1870
+ (_c = mapRef.value) == null ? void 0 : _c.setZoom(zoom);
1871
+ };
1872
+ Vue.watch(
1873
+ () => enableRef == null ? void 0 : enableRef.value,
1874
+ (enable, _, onCleanup) => {
1875
+ if (enable) {
1876
+ addEventListener("wheel", handleWheel);
1877
+ } else {
1878
+ removeEventListener("wheel", handleWheel);
1879
+ }
1880
+ onCleanup(() => {
1881
+ removeEventListener("wheel", handleWheel);
1882
+ });
1883
+ },
1884
+ { immediate: true }
1885
+ );
1886
+ };
1862
1887
  const Amap_css_ts_vanilla = "";
1863
1888
  var amap = "_1d8ur7t0";
1864
1889
  const Amap = defineSetup(function Amap2(props, { slots, emit }) {
@@ -1881,9 +1906,10 @@ const Amap = defineSetup(function Amap2(props, { slots, emit }) {
1881
1906
  animateEnable = true,
1882
1907
  keyboardEnable = true,
1883
1908
  doubleClickZoom = true,
1884
- scrollWheel = true,
1885
- touchZoom = true
1909
+ touchZoom = true,
1910
+ touchZoomCenter = 0
1886
1911
  } = props;
1912
+ const scrollWheel = touchZoomCenter ? false : props.scrollWheel;
1887
1913
  return {
1888
1914
  dragEnable,
1889
1915
  zoomEnable,
@@ -1894,17 +1920,20 @@ const Amap = defineSetup(function Amap2(props, { slots, emit }) {
1894
1920
  keyboardEnable,
1895
1921
  doubleClickZoom,
1896
1922
  scrollWheel,
1897
- touchZoom
1923
+ touchZoom,
1924
+ touchZoomCenter
1898
1925
  };
1899
1926
  });
1900
1927
  const elementRef = Vue.shallowRef();
1901
1928
  const mapRef = Vue.shallowRef();
1902
1929
  provideAmap(mapRef);
1930
+ useAmapWheelZoomCenter({ mapRef, enableRef: Vue.computed(() => !!props.touchZoomCenter) });
1903
1931
  Vue.watchPostEffect(() => {
1904
1932
  if (mapRef.value || !elementRef.value)
1905
1933
  return;
1906
1934
  const map = new AMap.Map(elementRef.value, {
1907
1935
  ...defaultOptions,
1936
+ scrollWheel: defaultOptions.touchZoomCenter ? false : defaultOptions.scrollWheel,
1908
1937
  vectorMapForeign,
1909
1938
  mapStyle: "amap://styles/95498a904992a4c0b866a3e4d7729682"
1910
1939
  });
@@ -2005,6 +2034,7 @@ const Gmap = defineSetup(function Gmap2(props, { slots, emit }) {
2005
2034
  return Vue.h("div", { ref: elementRef, class: gmap }, (_a = slots.default) == null ? void 0 : _a.call(slots));
2006
2035
  };
2007
2036
  });
2037
+ window.movingDraw = !new URLSearchParams(location.search).has("disableMovingDraw");
2008
2038
  const MapProvider = defineLagecySetup(function MapProvider2(props, {
2009
2039
  slots
2010
2040
  }) {
@@ -2063,7 +2093,8 @@ const HeycarMap = defineLagecySetup(function HeycarMap2(props, {
2063
2093
  mapRef: setMap,
2064
2094
  center,
2065
2095
  zoom,
2066
- touchEnable = true
2096
+ touchEnable = true,
2097
+ touchZoomCenter
2067
2098
  } = props;
2068
2099
  if (status === Status.LOADING)
2069
2100
  return (_a = slots.loading) == null ? void 0 : _a.call(slots);
@@ -2104,6 +2135,7 @@ const HeycarMap = defineLagecySetup(function HeycarMap2(props, {
2104
2135
  "doubleClickZoom": touchEnable,
2105
2136
  "scrollWheel": touchEnable,
2106
2137
  "touchZoom": touchEnable,
2138
+ "touchZoomCenter": touchZoomCenter ? 1 : 0,
2107
2139
  "keyboardEnable": touchEnable,
2108
2140
  "pitchEnable": touchEnable
2109
2141
  },
@@ -2114,7 +2146,7 @@ const HeycarMap = defineLagecySetup(function HeycarMap2(props, {
2114
2146
  }, [children]);
2115
2147
  }
2116
2148
  };
2117
- }).props(["center", "fallback", "loading", "mapRef", "zoom", "touchEnable"]);
2149
+ }).props(["center", "fallback", "loading", "mapRef", "zoom", "touchEnable", "touchZoomCenter"]);
2118
2150
  const AmapPolyline = defineSetup(function AmapPolyline2(props) {
2119
2151
  const polylineRef = Vue.shallowRef();
2120
2152
  const mapRef = useAmap();
@@ -2489,7 +2521,7 @@ const useAmapFitView = (props) => {
2489
2521
  const overlayGroup = /* @__PURE__ */ new Set();
2490
2522
  let timer = void 0;
2491
2523
  const setFitView = () => {
2492
- var _a;
2524
+ var _a, _b;
2493
2525
  const map = mapRef.value;
2494
2526
  if (!map)
2495
2527
  return;
@@ -2497,6 +2529,12 @@ const useAmapFitView = (props) => {
2497
2529
  const [top, right, bottom, left] = (_a = props.padding) != null ? _a : [0, 0, 0, 0];
2498
2530
  spaceLog("setFitView", "overlayGroup = ", overlayGroup);
2499
2531
  map.setFitView([...overlayGroup], false, [top * vw, bottom * vw, left * vw, right * vw]);
2532
+ if (overlayGroup.size === 1) {
2533
+ const [overlay] = [...overlayGroup];
2534
+ const position = (_b = overlay.getPosition) == null ? void 0 : _b.call(overlay);
2535
+ if (position)
2536
+ map.panTo(position);
2537
+ }
2500
2538
  };
2501
2539
  const registerFitVeiw = {
2502
2540
  add: (overlay) => {
@@ -2746,7 +2784,7 @@ var pointIcon = createRuntimeFn({ defaultClassName: "", variantClassNames: { typ
2746
2784
  var pointInfoBox = "_4a4ovk1";
2747
2785
  var pointInfoBoxDescription = "_4a4ovk4";
2748
2786
  var pointInfoBoxEmphasize$1 = "_4a4ovk5";
2749
- var pointInfoBoxTitle$1 = "_4a4ovk3";
2787
+ var pointInfoBoxTitle = "_4a4ovk3";
2750
2788
  var pointLayout$1 = "_4a4ovk0";
2751
2789
  var pointSingleInfoBox$1 = "_4a4ovk2";
2752
2790
  const AStartEndPoint = defineSetup(function AStartEndPoint2(props) {
@@ -2762,7 +2800,7 @@ const AStartEndPoint = defineSetup(function AStartEndPoint2(props) {
2762
2800
  return `
2763
2801
  <div class="${pointLayout$1}">
2764
2802
  <div class="${pointSingleInfoBox$1}">
2765
- <div class="${pointInfoBoxTitle$1}">${props.title}</div>
2803
+ <div class="${pointInfoBoxTitle}">${props.title}</div>
2766
2804
  </div>
2767
2805
  <img src="${icon}" class="${pointIcon({
2768
2806
  type: props.type
@@ -2772,7 +2810,7 @@ const AStartEndPoint = defineSetup(function AStartEndPoint2(props) {
2772
2810
  return `
2773
2811
  <div class="${pointLayout$1}">
2774
2812
  <div class="${pointInfoBox}">
2775
- <div class="${pointInfoBoxTitle$1}">${(_a = props.title) != null ? _a : ""}</div>
2813
+ <div class="${pointInfoBoxTitle}">${(_a = props.title) != null ? _a : ""}</div>
2776
2814
  <div class="${pointInfoBoxDescription}">${descriptionRow}</div>
2777
2815
  </div>
2778
2816
  <img src="${icon}" class="${pointIcon({
@@ -2808,7 +2846,7 @@ const GStartEndPoint = defineSetup(function GStartEndPoint2(props) {
2808
2846
  class: pointLayout$1
2809
2847
  }, `
2810
2848
  <div class="${pointSingleInfoBox$1}">
2811
- <div class="${pointInfoBoxTitle$1}">${props.title}</div>
2849
+ <div class="${pointInfoBoxTitle}">${props.title}</div>
2812
2850
  </div>
2813
2851
  <img src="${icon}" class="${pointIcon({
2814
2852
  type: props.type
@@ -2818,7 +2856,7 @@ const GStartEndPoint = defineSetup(function GStartEndPoint2(props) {
2818
2856
  class: pointLayout$1
2819
2857
  }, `
2820
2858
  <div class="${pointInfoBox}">
2821
- <div class="${pointInfoBoxTitle$1}">${(_a = props.title) != null ? _a : ""}</div>
2859
+ <div class="${pointInfoBoxTitle}">${(_a = props.title) != null ? _a : ""}</div>
2822
2860
  <div class="${pointInfoBoxDescription}">${descriptionRow}</div>
2823
2861
  </div>
2824
2862
  <img src="${icon}" class="${pointIcon({
@@ -3999,6 +4037,7 @@ const BusinessRecomendPlaceMap = defineLagecySetup(function BusinessRecomendPlac
3999
4037
  "attrs": {
4000
4038
  "center": centerPoint.value,
4001
4039
  "zoom": zoomRef.value,
4040
+ "touchZoomCenter": true,
4002
4041
  "mapRef": setMap
4003
4042
  }
4004
4043
  }, [!geoLoading.value && !geoError.value && Vue.h(PassengerCircle, {
@@ -4052,9 +4091,9 @@ const TaxiCar_css_ts_vanilla = "";
4052
4091
  var carIcon = "_65j3sr1";
4053
4092
  var hide = createRuntimeFn({ defaultClassName: "", variantClassNames: { hide: { true: "_65j3sr2", false: "_65j3sr3" } }, defaultVariants: {}, compoundVariants: [] });
4054
4093
  var pointInfoBoxEmphasize = "_4a4ovk5";
4055
- var pointInfoBoxTitle = "_4a4ovk3";
4056
4094
  var pointLayout = "_4a4ovk0";
4057
4095
  var pointSingleInfoBox = "_4a4ovk2";
4096
+ var taxiCarTitle = "_65j3sr4";
4058
4097
  const ATaxiCar = defineSetup(function ATaxiCar2(props) {
4059
4098
  const contentRef = Vue.computed(() => {
4060
4099
  var _a;
@@ -4069,7 +4108,7 @@ const ATaxiCar = defineSetup(function ATaxiCar2(props) {
4069
4108
  <div class="${pointSingleInfoBox} ${hide({
4070
4109
  hide: !hide$1
4071
4110
  })}">
4072
- <div class="${pointInfoBoxTitle}">${titleRow}</div>
4111
+ <div class="${taxiCarTitle}">${titleRow}</div>
4073
4112
  </div>
4074
4113
  <img src="${imgTaxicar}" class="${carIcon} ${hide({
4075
4114
  hide: hide$1
@@ -4118,7 +4157,7 @@ const GTaxiCar = defineSetup(function GTaxiCar2(props) {
4118
4157
  <div class="${pointSingleInfoBox} ${hide({
4119
4158
  hide: !hide$1
4120
4159
  })}">
4121
- <div class="${pointInfoBoxTitle}">${titleRow}</div>
4160
+ <div class="${taxiCarTitle}">${titleRow}</div>
4122
4161
  </div>
4123
4162
  <img src="${imgTaxicar}" class="${carIcon} ${hide({
4124
4163
  hide: hide$1
package/dist/index.js CHANGED
@@ -1857,6 +1857,31 @@ const useMapLoader = (props) => {
1857
1857
  onChange
1858
1858
  });
1859
1859
  };
1860
+ const ZOOM_WHEEL_RATIO = -135e-5;
1861
+ const useAmapWheelZoomCenter = (props) => {
1862
+ const { mapRef, enableRef } = props;
1863
+ const handleWheel = (e) => {
1864
+ var _a, _b, _c;
1865
+ const { deltaY } = e;
1866
+ const prevZoom = (_b = (_a = mapRef.value) == null ? void 0 : _a.getZoom()) != null ? _b : 0;
1867
+ const zoom = prevZoom + ZOOM_WHEEL_RATIO * deltaY;
1868
+ (_c = mapRef.value) == null ? void 0 : _c.setZoom(zoom);
1869
+ };
1870
+ watch(
1871
+ () => enableRef == null ? void 0 : enableRef.value,
1872
+ (enable, _, onCleanup) => {
1873
+ if (enable) {
1874
+ addEventListener("wheel", handleWheel);
1875
+ } else {
1876
+ removeEventListener("wheel", handleWheel);
1877
+ }
1878
+ onCleanup(() => {
1879
+ removeEventListener("wheel", handleWheel);
1880
+ });
1881
+ },
1882
+ { immediate: true }
1883
+ );
1884
+ };
1860
1885
  const Amap_css_ts_vanilla = "";
1861
1886
  var amap = "_1d8ur7t0";
1862
1887
  const Amap = defineSetup(function Amap2(props, { slots, emit }) {
@@ -1879,9 +1904,10 @@ const Amap = defineSetup(function Amap2(props, { slots, emit }) {
1879
1904
  animateEnable = true,
1880
1905
  keyboardEnable = true,
1881
1906
  doubleClickZoom = true,
1882
- scrollWheel = true,
1883
- touchZoom = true
1907
+ touchZoom = true,
1908
+ touchZoomCenter = 0
1884
1909
  } = props;
1910
+ const scrollWheel = touchZoomCenter ? false : props.scrollWheel;
1885
1911
  return {
1886
1912
  dragEnable,
1887
1913
  zoomEnable,
@@ -1892,17 +1918,20 @@ const Amap = defineSetup(function Amap2(props, { slots, emit }) {
1892
1918
  keyboardEnable,
1893
1919
  doubleClickZoom,
1894
1920
  scrollWheel,
1895
- touchZoom
1921
+ touchZoom,
1922
+ touchZoomCenter
1896
1923
  };
1897
1924
  });
1898
1925
  const elementRef = shallowRef();
1899
1926
  const mapRef = shallowRef();
1900
1927
  provideAmap(mapRef);
1928
+ useAmapWheelZoomCenter({ mapRef, enableRef: computed(() => !!props.touchZoomCenter) });
1901
1929
  watchPostEffect(() => {
1902
1930
  if (mapRef.value || !elementRef.value)
1903
1931
  return;
1904
1932
  const map = new AMap.Map(elementRef.value, {
1905
1933
  ...defaultOptions,
1934
+ scrollWheel: defaultOptions.touchZoomCenter ? false : defaultOptions.scrollWheel,
1906
1935
  vectorMapForeign,
1907
1936
  mapStyle: "amap://styles/95498a904992a4c0b866a3e4d7729682"
1908
1937
  });
@@ -2003,6 +2032,7 @@ const Gmap = defineSetup(function Gmap2(props, { slots, emit }) {
2003
2032
  return h("div", { ref: elementRef, class: gmap }, (_a = slots.default) == null ? void 0 : _a.call(slots));
2004
2033
  };
2005
2034
  });
2035
+ window.movingDraw = !new URLSearchParams(location.search).has("disableMovingDraw");
2006
2036
  const MapProvider = defineLagecySetup(function MapProvider2(props, {
2007
2037
  slots
2008
2038
  }) {
@@ -2061,7 +2091,8 @@ const HeycarMap = defineLagecySetup(function HeycarMap2(props, {
2061
2091
  mapRef: setMap,
2062
2092
  center,
2063
2093
  zoom,
2064
- touchEnable = true
2094
+ touchEnable = true,
2095
+ touchZoomCenter
2065
2096
  } = props;
2066
2097
  if (status === Status.LOADING)
2067
2098
  return (_a = slots.loading) == null ? void 0 : _a.call(slots);
@@ -2102,6 +2133,7 @@ const HeycarMap = defineLagecySetup(function HeycarMap2(props, {
2102
2133
  "doubleClickZoom": touchEnable,
2103
2134
  "scrollWheel": touchEnable,
2104
2135
  "touchZoom": touchEnable,
2136
+ "touchZoomCenter": touchZoomCenter ? 1 : 0,
2105
2137
  "keyboardEnable": touchEnable,
2106
2138
  "pitchEnable": touchEnable
2107
2139
  },
@@ -2112,7 +2144,7 @@ const HeycarMap = defineLagecySetup(function HeycarMap2(props, {
2112
2144
  }, [children]);
2113
2145
  }
2114
2146
  };
2115
- }).props(["center", "fallback", "loading", "mapRef", "zoom", "touchEnable"]);
2147
+ }).props(["center", "fallback", "loading", "mapRef", "zoom", "touchEnable", "touchZoomCenter"]);
2116
2148
  const AmapPolyline = defineSetup(function AmapPolyline2(props) {
2117
2149
  const polylineRef = shallowRef();
2118
2150
  const mapRef = useAmap();
@@ -2487,7 +2519,7 @@ const useAmapFitView = (props) => {
2487
2519
  const overlayGroup = /* @__PURE__ */ new Set();
2488
2520
  let timer = void 0;
2489
2521
  const setFitView = () => {
2490
- var _a;
2522
+ var _a, _b;
2491
2523
  const map = mapRef.value;
2492
2524
  if (!map)
2493
2525
  return;
@@ -2495,6 +2527,12 @@ const useAmapFitView = (props) => {
2495
2527
  const [top, right, bottom, left] = (_a = props.padding) != null ? _a : [0, 0, 0, 0];
2496
2528
  spaceLog("setFitView", "overlayGroup = ", overlayGroup);
2497
2529
  map.setFitView([...overlayGroup], false, [top * vw, bottom * vw, left * vw, right * vw]);
2530
+ if (overlayGroup.size === 1) {
2531
+ const [overlay] = [...overlayGroup];
2532
+ const position = (_b = overlay.getPosition) == null ? void 0 : _b.call(overlay);
2533
+ if (position)
2534
+ map.panTo(position);
2535
+ }
2498
2536
  };
2499
2537
  const registerFitVeiw = {
2500
2538
  add: (overlay) => {
@@ -2744,7 +2782,7 @@ var pointIcon = createRuntimeFn({ defaultClassName: "", variantClassNames: { typ
2744
2782
  var pointInfoBox = "_4a4ovk1";
2745
2783
  var pointInfoBoxDescription = "_4a4ovk4";
2746
2784
  var pointInfoBoxEmphasize$1 = "_4a4ovk5";
2747
- var pointInfoBoxTitle$1 = "_4a4ovk3";
2785
+ var pointInfoBoxTitle = "_4a4ovk3";
2748
2786
  var pointLayout$1 = "_4a4ovk0";
2749
2787
  var pointSingleInfoBox$1 = "_4a4ovk2";
2750
2788
  const AStartEndPoint = defineSetup(function AStartEndPoint2(props) {
@@ -2760,7 +2798,7 @@ const AStartEndPoint = defineSetup(function AStartEndPoint2(props) {
2760
2798
  return `
2761
2799
  <div class="${pointLayout$1}">
2762
2800
  <div class="${pointSingleInfoBox$1}">
2763
- <div class="${pointInfoBoxTitle$1}">${props.title}</div>
2801
+ <div class="${pointInfoBoxTitle}">${props.title}</div>
2764
2802
  </div>
2765
2803
  <img src="${icon}" class="${pointIcon({
2766
2804
  type: props.type
@@ -2770,7 +2808,7 @@ const AStartEndPoint = defineSetup(function AStartEndPoint2(props) {
2770
2808
  return `
2771
2809
  <div class="${pointLayout$1}">
2772
2810
  <div class="${pointInfoBox}">
2773
- <div class="${pointInfoBoxTitle$1}">${(_a = props.title) != null ? _a : ""}</div>
2811
+ <div class="${pointInfoBoxTitle}">${(_a = props.title) != null ? _a : ""}</div>
2774
2812
  <div class="${pointInfoBoxDescription}">${descriptionRow}</div>
2775
2813
  </div>
2776
2814
  <img src="${icon}" class="${pointIcon({
@@ -2806,7 +2844,7 @@ const GStartEndPoint = defineSetup(function GStartEndPoint2(props) {
2806
2844
  class: pointLayout$1
2807
2845
  }, `
2808
2846
  <div class="${pointSingleInfoBox$1}">
2809
- <div class="${pointInfoBoxTitle$1}">${props.title}</div>
2847
+ <div class="${pointInfoBoxTitle}">${props.title}</div>
2810
2848
  </div>
2811
2849
  <img src="${icon}" class="${pointIcon({
2812
2850
  type: props.type
@@ -2816,7 +2854,7 @@ const GStartEndPoint = defineSetup(function GStartEndPoint2(props) {
2816
2854
  class: pointLayout$1
2817
2855
  }, `
2818
2856
  <div class="${pointInfoBox}">
2819
- <div class="${pointInfoBoxTitle$1}">${(_a = props.title) != null ? _a : ""}</div>
2857
+ <div class="${pointInfoBoxTitle}">${(_a = props.title) != null ? _a : ""}</div>
2820
2858
  <div class="${pointInfoBoxDescription}">${descriptionRow}</div>
2821
2859
  </div>
2822
2860
  <img src="${icon}" class="${pointIcon({
@@ -3997,6 +4035,7 @@ const BusinessRecomendPlaceMap = defineLagecySetup(function BusinessRecomendPlac
3997
4035
  "attrs": {
3998
4036
  "center": centerPoint.value,
3999
4037
  "zoom": zoomRef.value,
4038
+ "touchZoomCenter": true,
4000
4039
  "mapRef": setMap
4001
4040
  }
4002
4041
  }, [!geoLoading.value && !geoError.value && h(PassengerCircle, {
@@ -4050,9 +4089,9 @@ const TaxiCar_css_ts_vanilla = "";
4050
4089
  var carIcon = "_65j3sr1";
4051
4090
  var hide = createRuntimeFn({ defaultClassName: "", variantClassNames: { hide: { true: "_65j3sr2", false: "_65j3sr3" } }, defaultVariants: {}, compoundVariants: [] });
4052
4091
  var pointInfoBoxEmphasize = "_4a4ovk5";
4053
- var pointInfoBoxTitle = "_4a4ovk3";
4054
4092
  var pointLayout = "_4a4ovk0";
4055
4093
  var pointSingleInfoBox = "_4a4ovk2";
4094
+ var taxiCarTitle = "_65j3sr4";
4056
4095
  const ATaxiCar = defineSetup(function ATaxiCar2(props) {
4057
4096
  const contentRef = computed(() => {
4058
4097
  var _a;
@@ -4067,7 +4106,7 @@ const ATaxiCar = defineSetup(function ATaxiCar2(props) {
4067
4106
  <div class="${pointSingleInfoBox} ${hide({
4068
4107
  hide: !hide$1
4069
4108
  })}">
4070
- <div class="${pointInfoBoxTitle}">${titleRow}</div>
4109
+ <div class="${taxiCarTitle}">${titleRow}</div>
4071
4110
  </div>
4072
4111
  <img src="${imgTaxicar}" class="${carIcon} ${hide({
4073
4112
  hide: hide$1
@@ -4116,7 +4155,7 @@ const GTaxiCar = defineSetup(function GTaxiCar2(props) {
4116
4155
  <div class="${pointSingleInfoBox} ${hide({
4117
4156
  hide: !hide$1
4118
4157
  })}">
4119
- <div class="${pointInfoBoxTitle}">${titleRow}</div>
4158
+ <div class="${taxiCarTitle}">${titleRow}</div>
4120
4159
  </div>
4121
4160
  <img src="${imgTaxicar}" class="${carIcon} ${hide({
4122
4161
  hide: hide$1
package/dist/style.css CHANGED
@@ -108,6 +108,9 @@
108
108
  height: 3.2vw;
109
109
  }._1d8ur7t0 {
110
110
  position: relative;
111
+ }
112
+ .amap-logo, .amap-copyright {
113
+ opacity: 0;
111
114
  }._7anfuo0 {
112
115
  height: inherit;
113
116
  width: inherit;
@@ -230,6 +233,14 @@
230
233
  }
231
234
  ._65j3sr2 {
232
235
  visibility: hidden;
236
+ }
237
+ ._65j3sr4 {
238
+ font-size: 3.2vw;
239
+ font-family: PingFangSC-Medium, PingFang SC;
240
+ font-weight: 500;
241
+ color: #1E1E1E;
242
+ line-height: 3.8vw;
243
+ white-space: nowrap;
233
244
  }@keyframes rrvp0y0 {
234
245
  0% {
235
246
  transform: scale(0);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heycar/heycars-map",
3
- "version": "0.5.1",
3
+ "version": "0.5.3",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "dev": "vite -c vite.config.dev.ts",
package/todo.md CHANGED
@@ -5,6 +5,7 @@ https://dawchihliou.github.io/articles/building-custom-google-maps-marker-react-
5
5
  4. 做完其他事情进入首页,变成了获取定位失败,但其实 gps 是 ok 的,因为刷新页面是有点位的
6
6
  5. map 的两个 slot loading 和 error slot 没有生效
7
7
  6. 企业微信如果关闭定位,会不停的跳 geoError 事件
8
+ 7. 司机已接单页面,title 倒计时, 1s 更新一次 title,引起 walking 接口 1s 触发
8
9
 
9
10
  缩放问题
10
11
 
@@ -79,3 +80,12 @@ https://dawchihliou.github.io/articles/building-custom-google-maps-marker-react-
79
80
  - 5347
80
81
  - 5348
81
82
  - 5057
83
+
84
+ 0.5.3
85
+
86
+ - 4867
87
+ - 4920
88
+ - 5252
89
+ - 5366
90
+ - 5364
91
+ - 5373