From bd4beab82f530e13c9155a1eb2f18390c5d311d1 Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 16:41:28 +0800 Subject: [PATCH 1/8] =?UTF-8?q?fix:=20=E5=BA=95=E5=9B=BE=20customTiles=20?= =?UTF-8?q?=E5=B1=9E=E6=80=A7=E9=80=8F=E5=87=BA=E5=92=8C=E6=96=87=E6=A1=A3?= =?UTF-8?q?=E8=A1=A5=E5=85=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/docs/index.md | 29 ++++++++++--------- .../official-layer-control/index.tsx | 28 +++++++++--------- src/locales/langs/zh-CN.ts | 2 +- src/pages/index.tsx | 2 ++ src/recoil/atomState.ts | 2 +- src/types/l7editor.ts | 11 +++++++ 6 files changed, 45 insertions(+), 29 deletions(-) diff --git a/docs/docs/index.md b/docs/docs/index.md index 5303aed..060d923 100644 --- a/docs/docs/index.md +++ b/docs/docs/index.md @@ -42,6 +42,7 @@ title: API | wasmPath | sam 组件的 wasm 路径 | `string` | `\` | | showDrawDistance | 绘制时是否展示距离文本 | `boolean` | `false` | | showDrawArea | 绘制时是否展示面积文本 | `boolean` | `false` | +| customTiles | 自定义瓦片底图图层 | [customTilesProps](#customtilesprops) | `[]` | #### `tabItems` @@ -98,25 +99,27 @@ LngLat 文本编辑器,可以通过输入 LngLat 数据实现数据展示(目 } ``` -#### `officialLayers`¸ - -底图数据选择 - -`['googleSatellite'] | ['amapSatellite','amapRoadNet','AmapBuildings', 'amapTraffic']` +#### `customTilesProps` ```js { - officialLayers: ['amapSatellite', 'amapRoadNet']; + customTiles: [ + { + id: 'id', + image: 'img', + title: 'title', + layers: ['layerUrl'], + }, + ]; } ``` -| 属性 | 描述 | -| --------------- | ---------- | -| googleSatellite | 谷歌卫星图 | -| amapSatellite | 高德卫星图 | -| amapRoadNet | 高德路网图 | -| amapBuildings | 高德楼块图 | -| amapTraffic | 高德路况图 | +| 属性 | 描述 | 类型 | +| ------ | ------------ | ---------- | +| id | 唯一标识 | `string` | +| image | 图片 | `string` | +| title | 图层名称 | `string` | +| layers | 瓦片图层链接 | `string[]` | #### coordConvert diff --git a/src/components/map-control-group/official-layer-control/index.tsx b/src/components/map-control-group/official-layer-control/index.tsx index a2db7ad..25893c1 100644 --- a/src/components/map-control-group/official-layer-control/index.tsx +++ b/src/components/map-control-group/official-layer-control/index.tsx @@ -58,14 +58,14 @@ export function OfficialLayerControl() { const BASE_LAYER_GROUP = [ { - type: OfficeLayerEnum.VectorMap, + id: OfficeLayerEnum.VectorMap, title: t('official_layer_control.index.shiLiangDiTu'), image: 'https://mdn.alipayobjects.com/huamei_qa8qxu/afts/img/A*qdFDSbvIalgAAAAAAAAAAAAADmJ7AQ/original', layers: [], }, { - type: OfficeLayerEnum.GoogleSatellite, + id: OfficeLayerEnum.GoogleSatellite, title: t('official_layer_control.index.guGeWeiXingTu'), image: 'https://mdn.alipayobjects.com/huamei_k6sfo0/afts/img/A*zi2jSqqZ2-8AAAAAAAAAAAAADjWqAQ/original', @@ -92,14 +92,14 @@ export function OfficialLayerControl() { }; const onItemClick = (item: { - type: any; + id: any; image: string; title: string; layers: string[]; }) => { - setRadioValue(item.type); + setRadioValue(item.id); setLayerType( - item.type === OfficeLayerEnum.VectorMap ? [] : ([item.type] as string[]), + item.id === OfficeLayerEnum.VectorMap ? [] : ([item.id] as string[]), ); }; @@ -108,7 +108,7 @@ export function OfficialLayerControl() { const cloneCustomTiles = cloneDeep(customTiles); const newImgUrl = Array.isArray(e.img) ? e.img[0].url : `${base64}`; cloneCustomTiles[editIndex - 2] = { - type: e.name, + id: e.name, image: newImgUrl, title: e.name, layers: e.urls, @@ -120,7 +120,7 @@ export function OfficialLayerControl() { setCustomTiles((prevState) => [ ...prevState, { - type: e.name, + id: e.name, image: `${base64}`, title: e.name, layers: e.urls, @@ -143,7 +143,7 @@ export function OfficialLayerControl() { const onConfirm = ( e: React.MouseEvent | undefined, item: { - type: string; + id: string; image?: string; title?: string; layers?: string[]; @@ -151,9 +151,9 @@ export function OfficialLayerControl() { ) => { e?.stopPropagation(); const newCustomTiles = customTiles.filter((val) => { - return val.type !== item.type; + return val.id !== item.id; }); - if (item.type === radioValue) { + if (item.id === radioValue) { setRadioValue(OfficeLayerEnum.VectorMap); setLayerType([]); } @@ -214,7 +214,7 @@ export function OfficialLayerControl() { const rasterLayer = useMemo(() => { if (layerType.length) { const findItem = officeLayerGroup.find( - (item) => item.type === layerType[0], + (item) => item.id === layerType[0], ); return findItem?.layers.map((item) => { return ( @@ -222,7 +222,7 @@ export function OfficialLayerControl() { { return (
{ set(textLayerFieldsState, props?.textLayerFields ?? undefined); set(showDrawDistanceState, props.showDrawDistance ?? false); set(showDrawAreaState, props.showDrawArea ?? false); + set(customTilesState, props.customTiles ?? []); }; }, [props]); diff --git a/src/recoil/atomState.ts b/src/recoil/atomState.ts index c8d3cf1..0c983b1 100644 --- a/src/recoil/atomState.ts +++ b/src/recoil/atomState.ts @@ -175,7 +175,7 @@ const textLayerFieldsState = atom({ const customTilesState = atom< { [x: string]: any; - type: string; + id: string; image: string; title: string; layers: string[]; diff --git a/src/types/l7editor.ts b/src/types/l7editor.ts index 64c0d9b..57a4728 100644 --- a/src/types/l7editor.ts +++ b/src/types/l7editor.ts @@ -146,4 +146,15 @@ export interface L7EditorProps { * 绘制时是否显示面积 */ showDrawArea?: boolean; + + /** + * 自定义瓦片底图图层 + */ + customTiles?: { + [x: string]: any; + id: string; + image: string; + title: string; + layers: string[]; + }[]; } From 875d49da620be7b5d302d3128116840c53d686f6 Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 16:42:24 +0800 Subject: [PATCH 2/8] =?UTF-8?q?fix:=20=E5=8D=87=E7=BA=A7=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0c0149c..cffb5f5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@antv/l7-editor", - "version": "1.1.10", + "version": "1.1.11", "description": "Geographic data editing tool based on L7", "files": [ "lib", From 44b954bc8d77203bd79d40d29e029804e15e3c72 Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 17:03:09 +0800 Subject: [PATCH 3/8] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9ts=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/docs/index.md | 8 ++++---- src/recoil/atomState.ts | 15 ++++----------- src/types/l7editor.ts | 16 +++++++++------- 3 files changed, 17 insertions(+), 22 deletions(-) diff --git a/docs/docs/index.md b/docs/docs/index.md index 060d923..4ee44de 100644 --- a/docs/docs/index.md +++ b/docs/docs/index.md @@ -105,10 +105,10 @@ LngLat 文本编辑器,可以通过输入 LngLat 数据实现数据展示(目 { customTiles: [ { - id: 'id', - image: 'img', - title: 'title', - layers: ['layerUrl'], + id: 'GaodeSatellite', + image: 'https://mdn.alipayobjects.com/huamei_k6sfo0/afts/img/A*zi2jSqqZ2-8AAAAAAAAAAAAADjWqAQ/original', + title: '高德卫星底图', + layers: [' https://webst01.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}'], }, ]; } diff --git a/src/recoil/atomState.ts b/src/recoil/atomState.ts index 0c983b1..fa20650 100644 --- a/src/recoil/atomState.ts +++ b/src/recoil/atomState.ts @@ -5,6 +5,7 @@ import { atom, DefaultValue } from 'recoil'; import { LocalStorageKey } from '../constants'; import type { IFeatures, LngLatImportType } from '../types'; import type { FilterNode } from '../types/filter'; +import type { customTilesProps } from '../types/l7editor'; const localStorageEffect = (key: string) => @@ -172,15 +173,7 @@ const textLayerFieldsState = atom({ effects: [localStorageEffect(LocalStorageKey.textLayerFields)], }); -const customTilesState = atom< - { - [x: string]: any; - id: string; - image: string; - title: string; - layers: string[]; - }[] ->({ +const customTilesState = atom({ key: 'customTiles', default: [], effects: [localStorageEffect(LocalStorageKey.customTiles)], @@ -199,13 +192,11 @@ const wasmPathState = atom({ export { activeTabState, - showDrawAreaState, autoFitBoundsState, baseMapState, cityHistoryState, convertState, customTilesState, - showDrawDistanceState, editorTextState, featureState, filterState, @@ -221,6 +212,8 @@ export { rightWidthState, savedTextState, sceneState, + showDrawAreaState, + showDrawDistanceState, showTextLayerState, textLayerFieldsState, themeState, diff --git a/src/types/l7editor.ts b/src/types/l7editor.ts index 57a4728..f3789dc 100644 --- a/src/types/l7editor.ts +++ b/src/types/l7editor.ts @@ -2,6 +2,14 @@ import type { LarkMapProps } from '@antv/larkmap'; import type { Feature } from '@turf/turf'; import type { TabsProps } from 'antd'; +export type customTilesProps = { + [key: string]: any; + id: string; + image: string; + title: string; + layers: string[]; +}[]; + export interface MapControlProps { logoControl?: boolean; drawControl?: boolean; @@ -150,11 +158,5 @@ export interface L7EditorProps { /** * 自定义瓦片底图图层 */ - customTiles?: { - [x: string]: any; - id: string; - image: string; - title: string; - layers: string[]; - }[]; + customTiles?: customTilesProps; } From b4e2cb5f0ffa0c2e373444df8678fe785f6c20a0 Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 17:08:20 +0800 Subject: [PATCH 4/8] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9ts=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../official-layer-control/index.tsx | 21 ++++++++----------- 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/src/components/map-control-group/official-layer-control/index.tsx b/src/components/map-control-group/official-layer-control/index.tsx index 25893c1..9dcfd5a 100644 --- a/src/components/map-control-group/official-layer-control/index.tsx +++ b/src/components/map-control-group/official-layer-control/index.tsx @@ -31,6 +31,13 @@ const enLayout = { wrapperCol: { span: 15 }, }; +type customTilesItemProps = { + id: string; + image?: string; + title?: string; + layers?: string[]; +}; + export function OfficialLayerControl() { const [form] = Form.useForm(); const styles = useStyle(); @@ -91,12 +98,7 @@ export function OfficialLayerControl() { return false; // 阻止antd组件自动上传 }; - const onItemClick = (item: { - id: any; - image: string; - title: string; - layers: string[]; - }) => { + const onItemClick = (item: customTilesItemProps) => { setRadioValue(item.id); setLayerType( item.id === OfficeLayerEnum.VectorMap ? [] : ([item.id] as string[]), @@ -142,12 +144,7 @@ export function OfficialLayerControl() { const onConfirm = ( e: React.MouseEvent | undefined, - item: { - id: string; - image?: string; - title?: string; - layers?: string[]; - }, + item: customTilesItemProps, ) => { e?.stopPropagation(); const newCustomTiles = customTiles.filter((val) => { From 3d49292e2454b5d5a5a022dd14dab2b6a4afadeb Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 17:16:33 +0800 Subject: [PATCH 5/8] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9ts=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../map-control-group/official-layer-control/index.tsx | 6 +++--- src/recoil/atomState.ts | 4 ++-- src/types/l7editor.ts | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/components/map-control-group/official-layer-control/index.tsx b/src/components/map-control-group/official-layer-control/index.tsx index 9dcfd5a..221be3c 100644 --- a/src/components/map-control-group/official-layer-control/index.tsx +++ b/src/components/map-control-group/official-layer-control/index.tsx @@ -31,7 +31,7 @@ const enLayout = { wrapperCol: { span: 15 }, }; -type customTilesItemProps = { +type CustomTilesItemProps = { id: string; image?: string; title?: string; @@ -98,7 +98,7 @@ export function OfficialLayerControl() { return false; // 阻止antd组件自动上传 }; - const onItemClick = (item: customTilesItemProps) => { + const onItemClick = (item: CustomTilesItemProps) => { setRadioValue(item.id); setLayerType( item.id === OfficeLayerEnum.VectorMap ? [] : ([item.id] as string[]), @@ -144,7 +144,7 @@ export function OfficialLayerControl() { const onConfirm = ( e: React.MouseEvent | undefined, - item: customTilesItemProps, + item: CustomTilesItemProps, ) => { e?.stopPropagation(); const newCustomTiles = customTiles.filter((val) => { diff --git a/src/recoil/atomState.ts b/src/recoil/atomState.ts index fa20650..a7da11d 100644 --- a/src/recoil/atomState.ts +++ b/src/recoil/atomState.ts @@ -5,7 +5,7 @@ import { atom, DefaultValue } from 'recoil'; import { LocalStorageKey } from '../constants'; import type { IFeatures, LngLatImportType } from '../types'; import type { FilterNode } from '../types/filter'; -import type { customTilesProps } from '../types/l7editor'; +import type { CustomTilesProps } from '../types/l7editor'; const localStorageEffect = (key: string) => @@ -173,7 +173,7 @@ const textLayerFieldsState = atom({ effects: [localStorageEffect(LocalStorageKey.textLayerFields)], }); -const customTilesState = atom({ +const customTilesState = atom({ key: 'customTiles', default: [], effects: [localStorageEffect(LocalStorageKey.customTiles)], diff --git a/src/types/l7editor.ts b/src/types/l7editor.ts index f3789dc..8fa4493 100644 --- a/src/types/l7editor.ts +++ b/src/types/l7editor.ts @@ -2,7 +2,7 @@ import type { LarkMapProps } from '@antv/larkmap'; import type { Feature } from '@turf/turf'; import type { TabsProps } from 'antd'; -export type customTilesProps = { +export type CustomTilesProps = { [key: string]: any; id: string; image: string; @@ -158,5 +158,5 @@ export interface L7EditorProps { /** * 自定义瓦片底图图层 */ - customTiles?: customTilesProps; + customTiles?: CustomTilesProps; } From 03acf52dec8c4fb88518b6bd27ea4774fd35edba Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 17:23:15 +0800 Subject: [PATCH 6/8] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9ts=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../official-layer-control/index.tsx | 12 +++--------- src/recoil/atomState.ts | 2 +- src/types/l7editor.ts | 6 +++--- 3 files changed, 7 insertions(+), 13 deletions(-) diff --git a/src/components/map-control-group/official-layer-control/index.tsx b/src/components/map-control-group/official-layer-control/index.tsx index 221be3c..cc28cbc 100644 --- a/src/components/map-control-group/official-layer-control/index.tsx +++ b/src/components/map-control-group/official-layer-control/index.tsx @@ -20,6 +20,7 @@ import { OfficeLayerEnum, } from '../../../constants'; import { useGlobal } from '../../../recoil'; +import type { CustomTilesProps } from '../../../types/l7editor'; import useStyle from './styles'; const layout = { @@ -31,13 +32,6 @@ const enLayout = { wrapperCol: { span: 15 }, }; -type CustomTilesItemProps = { - id: string; - image?: string; - title?: string; - layers?: string[]; -}; - export function OfficialLayerControl() { const [form] = Form.useForm(); const styles = useStyle(); @@ -98,7 +92,7 @@ export function OfficialLayerControl() { return false; // 阻止antd组件自动上传 }; - const onItemClick = (item: CustomTilesItemProps) => { + const onItemClick = (item: CustomTilesProps) => { setRadioValue(item.id); setLayerType( item.id === OfficeLayerEnum.VectorMap ? [] : ([item.id] as string[]), @@ -144,7 +138,7 @@ export function OfficialLayerControl() { const onConfirm = ( e: React.MouseEvent | undefined, - item: CustomTilesItemProps, + item: CustomTilesProps, ) => { e?.stopPropagation(); const newCustomTiles = customTiles.filter((val) => { diff --git a/src/recoil/atomState.ts b/src/recoil/atomState.ts index a7da11d..b75ccef 100644 --- a/src/recoil/atomState.ts +++ b/src/recoil/atomState.ts @@ -173,7 +173,7 @@ const textLayerFieldsState = atom({ effects: [localStorageEffect(LocalStorageKey.textLayerFields)], }); -const customTilesState = atom({ +const customTilesState = atom({ key: 'customTiles', default: [], effects: [localStorageEffect(LocalStorageKey.customTiles)], diff --git a/src/types/l7editor.ts b/src/types/l7editor.ts index 8fa4493..a9574b7 100644 --- a/src/types/l7editor.ts +++ b/src/types/l7editor.ts @@ -2,13 +2,13 @@ import type { LarkMapProps } from '@antv/larkmap'; import type { Feature } from '@turf/turf'; import type { TabsProps } from 'antd'; -export type CustomTilesProps = { +export interface CustomTilesProps { [key: string]: any; id: string; image: string; title: string; layers: string[]; -}[]; +} export interface MapControlProps { logoControl?: boolean; @@ -158,5 +158,5 @@ export interface L7EditorProps { /** * 自定义瓦片底图图层 */ - customTiles?: CustomTilesProps; + customTiles?: CustomTilesProps[]; } From 02800cb757c83a20451a26df088310c89ed5a1ff Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 17:28:53 +0800 Subject: [PATCH 7/8] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9ts=E5=90=8D?= =?UTF-8?q?=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/docs/index.md | 7 +++++-- .../map-control-group/official-layer-control/index.tsx | 6 +++--- src/recoil/atomState.ts | 4 ++-- src/types/l7editor.ts | 4 ++-- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/docs/docs/index.md b/docs/docs/index.md index 4ee44de..80095b3 100644 --- a/docs/docs/index.md +++ b/docs/docs/index.md @@ -106,9 +106,12 @@ LngLat 文本编辑器,可以通过输入 LngLat 数据实现数据展示(目 customTiles: [ { id: 'GaodeSatellite', - image: 'https://mdn.alipayobjects.com/huamei_k6sfo0/afts/img/A*zi2jSqqZ2-8AAAAAAAAAAAAADjWqAQ/original', + image: + 'https://mdn.alipayobjects.com/huamei_k6sfo0/afts/img/A*zi2jSqqZ2-8AAAAAAAAAAAAADjWqAQ/original', title: '高德卫星底图', - layers: [' https://webst01.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}'], + layers: [ + 'https://webst01.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}', + ], }, ]; } diff --git a/src/components/map-control-group/official-layer-control/index.tsx b/src/components/map-control-group/official-layer-control/index.tsx index cc28cbc..c858a34 100644 --- a/src/components/map-control-group/official-layer-control/index.tsx +++ b/src/components/map-control-group/official-layer-control/index.tsx @@ -20,7 +20,7 @@ import { OfficeLayerEnum, } from '../../../constants'; import { useGlobal } from '../../../recoil'; -import type { CustomTilesProps } from '../../../types/l7editor'; +import type { CustomTiles } from '../../../types/l7editor'; import useStyle from './styles'; const layout = { @@ -92,7 +92,7 @@ export function OfficialLayerControl() { return false; // 阻止antd组件自动上传 }; - const onItemClick = (item: CustomTilesProps) => { + const onItemClick = (item: CustomTiles) => { setRadioValue(item.id); setLayerType( item.id === OfficeLayerEnum.VectorMap ? [] : ([item.id] as string[]), @@ -138,7 +138,7 @@ export function OfficialLayerControl() { const onConfirm = ( e: React.MouseEvent | undefined, - item: CustomTilesProps, + item: CustomTiles, ) => { e?.stopPropagation(); const newCustomTiles = customTiles.filter((val) => { diff --git a/src/recoil/atomState.ts b/src/recoil/atomState.ts index b75ccef..c97b040 100644 --- a/src/recoil/atomState.ts +++ b/src/recoil/atomState.ts @@ -5,7 +5,7 @@ import { atom, DefaultValue } from 'recoil'; import { LocalStorageKey } from '../constants'; import type { IFeatures, LngLatImportType } from '../types'; import type { FilterNode } from '../types/filter'; -import type { CustomTilesProps } from '../types/l7editor'; +import type { CustomTiles } from '../types/l7editor'; const localStorageEffect = (key: string) => @@ -173,7 +173,7 @@ const textLayerFieldsState = atom({ effects: [localStorageEffect(LocalStorageKey.textLayerFields)], }); -const customTilesState = atom({ +const customTilesState = atom({ key: 'customTiles', default: [], effects: [localStorageEffect(LocalStorageKey.customTiles)], diff --git a/src/types/l7editor.ts b/src/types/l7editor.ts index a9574b7..0dc1719 100644 --- a/src/types/l7editor.ts +++ b/src/types/l7editor.ts @@ -2,7 +2,7 @@ import type { LarkMapProps } from '@antv/larkmap'; import type { Feature } from '@turf/turf'; import type { TabsProps } from 'antd'; -export interface CustomTilesProps { +export interface CustomTiles { [key: string]: any; id: string; image: string; @@ -158,5 +158,5 @@ export interface L7EditorProps { /** * 自定义瓦片底图图层 */ - customTiles?: CustomTilesProps[]; + customTiles?: CustomTiles[]; } From 101e936114df9b8c2c95ff7d434e61a86d3d5d82 Mon Sep 17 00:00:00 2001 From: syb01094648 Date: Thu, 7 Mar 2024 17:44:27 +0800 Subject: [PATCH 8/8] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9ts=E5=90=8D?= =?UTF-8?q?=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/types/l7editor.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/types/l7editor.ts b/src/types/l7editor.ts index 0dc1719..6fcefce 100644 --- a/src/types/l7editor.ts +++ b/src/types/l7editor.ts @@ -2,13 +2,13 @@ import type { LarkMapProps } from '@antv/larkmap'; import type { Feature } from '@turf/turf'; import type { TabsProps } from 'antd'; -export interface CustomTiles { +export type CustomTiles = { [key: string]: any; id: string; image: string; title: string; layers: string[]; -} +}; export interface MapControlProps { logoControl?: boolean;