| | |
| | | import type { MapdataType } from "./center.map";
|
| | | const option = ref({});
|
| | | const code = ref("china"); //china 代表中国 其他地市是行政编码
|
| | | const centerMapRef = ref();
|
| | |
|
| | | withDefaults(
|
| | | defineProps<{
|
| | | // 结束数值
|
| | |
| | | }
|
| | | });
|
| | | await nextTick();
|
| | | centerMapRef.value?.resize();
|
| | |
|
| | | option.value = optionHandle(regionCode, list, mapData);
|
| | | };
|
| | |
| | | mapjson = mapjson.geoJSON;
|
| | | resolve(mapjson);
|
| | | } else {
|
| | | mapjson = await GETNOBASE(`/map-geojson/${regionCode}.json`).then(
|
| | | mapjson = await GETNOBASE(`map-geojson/${regionCode}.json`).then(
|
| | | (data) => data
|
| | | );
|
| | | code.value=regionCode
|
| | |
| | | :option="option"
|
| | | ref="centerMapRef"
|
| | | @click="mapClick"
|
| | | v-if="JSON.stringify(option)!='{}'"
|
| | | />
|
| | | </div>
|
| | | </div>
|
| | |
| | | }
|
| | |
|
| | | .mapwrap {
|
| | | height: 548px;
|
| | | height: 580px;
|
| | | width: 100%;
|
| | | // padding: 0 0 10px 0;
|
| | | box-sizing: border-box;
|