Adding zoom control
This commit is contained in:
1 parent
d8c3035bb2
commit
8ec7e7d045
1 file changed
+3
-2
@@ -1,6 +1,6 @@
|
|||||||
import react from "react";
|
import react from "react";
|
||||||
import { useState, useEffect } from "react";
|
import { useState, useEffect } from "react";
|
||||||
import { Map, Marker } from "pigeon-maps"
|
import { Map, Marker, ZoomControl } from "pigeon-maps"
|
||||||
import { Geolocation } from "@awesome-cordova-plugins/geolocation";
|
import { Geolocation } from "@awesome-cordova-plugins/geolocation";
|
||||||
|
|
||||||
const LiveMap: react.FC = () => {
|
const LiveMap: react.FC = () => {
|
||||||
@@ -26,7 +26,8 @@ const LiveMap: react.FC = () => {
|
|||||||
setCenter(center);
|
setCenter(center);
|
||||||
setZoom(zoom);
|
setZoom(zoom);
|
||||||
}
|
}
|
||||||
}>
|
} animate={true}>
|
||||||
|
<ZoomControl />
|
||||||
<Marker width={20} anchor={position} />
|
<Marker width={20} anchor={position} />
|
||||||
</Map>
|
</Map>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in new issue
Block a user