import { c } from "react-compiler-runtime";
import { useState } from "react";
//#region src/map-library/functions/mapFunctions.js
const useControlZoom = (initial) => {
	const $ = c(7);
	const [zoom, setZoom] = useState(initial);
	let t0;
	if ($[0] !== zoom) {
		t0 = (input) => {
			setZoom(zoom + (input === "in" ? 1 : -1));
		};
		$[0] = zoom;
		$[1] = t0;
	} else t0 = $[1];
	const handleSetZoom = t0;
	let t1;
	if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
		t1 = (event, newValue) => {
			setZoom(newValue);
		};
		$[2] = t1;
	} else t1 = $[2];
	const handleSliderChange = t1;
	let t2;
	if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
		t2 = (event_0) => {
			setZoom(event_0.target.value === "" ? "" : Number(event_0.target.value));
		};
		$[3] = t2;
	} else t2 = $[3];
	const handleInputChange = t2;
	let t3;
	if ($[4] !== handleSetZoom || $[5] !== zoom) {
		t3 = [
			zoom,
			handleSetZoom,
			handleSliderChange,
			handleInputChange
		];
		$[4] = handleSetZoom;
		$[5] = zoom;
		$[6] = t3;
	} else t3 = $[6];
	return t3;
};
const usePosition = (initial) => {
	const $ = c(3);
	const [center, setCenter] = useState(initial);
	let t0;
	if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
		t0 = (input) => {
			setCenter(input);
		};
		$[0] = t0;
	} else t0 = $[0];
	const handlePosition = t0;
	let t1;
	if ($[1] !== center) {
		t1 = [center, handlePosition];
		$[1] = center;
		$[2] = t1;
	} else t1 = $[2];
	return t1;
};
//#endregion
export { useControlZoom, usePosition };

//# sourceMappingURL=mapFunctions.mjs.map