"use strict"; const common_vendor = require("../../common/vendor.js"); const utils_map = require("../../utils/map.js"); if (!Array) { const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons"); _easycom_uni_icons2(); } const _easycom_uni_icons = () => "../../node-modules/@dcloudio/uni-ui/lib/uni-icons/uni-icons.js"; if (!Math) { _easycom_uni_icons(); } const _sfc_main = { __name: "map-findbike", setup(__props) { common_vendor.ref("mapRef"); let oMap = null; const scale = common_vendor.ref(15); const markers = common_vendor.ref(); const mapcenter = common_vendor.ref({ longitude: "", latitude: "" }); common_vendor.onMounted(() => { oMap = utils_map.getMap("mapRef", common_vendor.getCurrentInstance()); }); common_vendor.onLoad((option) => { const { longitude: lng, latitude: lat } = option; mapcenter.value = { longitude: lng, latitude: lat }; const arrPoints = markers.value || []; arrPoints.push(utils_map.addMarker(arrPoints.length, lng, lat, "bike-choose.png")); markers.value = arrPoints; }); const onZoom = (lx) => { switch (lx) { case "out": scale.value = scale.value + 1; break; case "in": scale.value = scale.value - 1; break; } }; const getLocation = () => { utils_map.getLoalcation(oMap, (res) => { }); }; return (_ctx, _cache) => { return { a: common_vendor.o(($event) => onZoom("out")), b: common_vendor.p({ ["custom-prefix"]: "iconfont", type: "icon-ebikejia", color: _ctx.iconcolor, size: _ctx.iconsize }), c: common_vendor.o(($event) => onZoom("in")), d: common_vendor.p({ ["custom-prefix"]: "iconfont", type: "icon-ebikejian", color: _ctx.iconcolor, size: _ctx.iconsize }), e: common_vendor.p({ ["custom-prefix"]: "iconfont", type: "icon-ebikedingwei2", color: _ctx.iconcolor, size: _ctx.iconsize }), f: common_vendor.o(getLocation), g: scale.value, h: markers.value, i: mapcenter.value.longitude, j: mapcenter.value.latitude }; }; } }; const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-84967cba"]]); wx.createPage(MiniProgramPage); //# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/map/map-findbike.js.map