From 86c904708dab021d3ec9aaba417af9556e0550ed Mon Sep 17 00:00:00 2001 From: Kurisu Date: Tue, 25 Oct 2022 17:40:28 +0800 Subject: [PATCH] bug修复 --- lib/src/route/driving-route.tsx | 36 ------------------------------------ lib/src/route/route-plan.tsx | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 36 deletions(-) delete mode 100644 lib/src/route/driving-route.tsx create mode 100644 lib/src/route/route-plan.tsx diff --git a/lib/src/route/driving-route.tsx b/lib/src/route/driving-route.tsx deleted file mode 100644 index 2f9110d..0000000 --- a/lib/src/route/driving-route.tsx +++ /dev/null @@ -1,36 +0,0 @@ -import * as React from "react"; -import { requireNativeComponent } from "react-native"; -import Component from "../component"; -// @ts-ignore -import resolveAssetSource from "react-native/Libraries/Image/resolveAssetSource"; -import { RouteProps, LatLng, RouteType } from "../types"; - -export default class extends Component { - name = name; - static defaultProps = { width: 8, throughPointVisible: true, type: RouteType.DRIVE }; - - /** - * 路线规划 - */ - public routePlan(start: LatLng, end: LatLng, throughPointList: LatLng[] = []) { - this.invoke("searchRoute", [start, end, throughPointList]); - } - - render() { - const props = { - ...this.props, - }; - return ( - - ); - } -} - -const name = "RoutePlan"; -const NativeRoutePlan = requireNativeComponent(name); diff --git a/lib/src/route/route-plan.tsx b/lib/src/route/route-plan.tsx new file mode 100644 index 0000000..2f9110d --- /dev/null +++ b/lib/src/route/route-plan.tsx @@ -0,0 +1,36 @@ +import * as React from "react"; +import { requireNativeComponent } from "react-native"; +import Component from "../component"; +// @ts-ignore +import resolveAssetSource from "react-native/Libraries/Image/resolveAssetSource"; +import { RouteProps, LatLng, RouteType } from "../types"; + +export default class extends Component { + name = name; + static defaultProps = { width: 8, throughPointVisible: true, type: RouteType.DRIVE }; + + /** + * 路线规划 + */ + public routePlan(start: LatLng, end: LatLng, throughPointList: LatLng[] = []) { + this.invoke("searchRoute", [start, end, throughPointList]); + } + + render() { + const props = { + ...this.props, + }; + return ( + + ); + } +} + +const name = "RoutePlan"; +const NativeRoutePlan = requireNativeComponent(name); -- libgit2 0.22.2