From 70a69d400276ff5182f9bbc0726e8a18d0404046 Mon Sep 17 00:00:00 2001 From: lvisei Date: Wed, 12 Jun 2024 15:33:56 +0800 Subject: [PATCH] chore: type mis (#356) * chore: type mis * chore: compiler options target --- packages/l7plot/__tests__/helper/plot.ts | 3 +-- packages/l7plot/src/types/map.ts | 5 ++--- tsconfig.json | 2 +- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/packages/l7plot/__tests__/helper/plot.ts b/packages/l7plot/__tests__/helper/plot.ts index 09276923c..6f9a0b2ac 100644 --- a/packages/l7plot/__tests__/helper/plot.ts +++ b/packages/l7plot/__tests__/helper/plot.ts @@ -4,8 +4,7 @@ import { L7PlotOptions, PlotOptions } from '../../src/types'; import { createDiv } from './dom'; const mapConfig = { - type: 'mapbox', - token: 'pk.eyJ1IjoibGl1dmlnb25nenVvc2hpIiwiYSI6ImNrdW02cjU3ZjNvaHIyb3FsbGR2b2dja2MifQ.OLUdvRf2ZY3lhnJzBU9ToQ', + type: 'map', }; export const createPlot = , U extends PlotOptions>(PlotClass: any, options: U): T => { diff --git a/packages/l7plot/src/types/map.ts b/packages/l7plot/src/types/map.ts index 52e473627..69669424e 100644 --- a/packages/l7plot/src/types/map.ts +++ b/packages/l7plot/src/types/map.ts @@ -1,6 +1,5 @@ import type { Map as MapboxglMap } from 'mapbox-gl'; import type { Map, IStatusOptions, PositionName, ISourceCFG, MapStyle, Source } from '@antv/l7'; -import type { IAMapInstance, IMapboxInstance } from '@antv/l7-maps/typings'; import type { TooltipOptions } from './tooltip'; import type { LegendOptions } from './legend'; import type { LayerMenuControlOptions, ScaleControlOptions, ZoomControlOptions } from './control'; @@ -10,8 +9,8 @@ export type { MapboxglMap, Source }; export type StatusOptions = IStatusOptions; export type MapInstance = Map; -export type AMapInstance = AMap.Map & IAMapInstance; -export type MapboxInstance = MapboxglMap & IMapboxInstance; +export type AMapInstance = AMap.Map; +export type MapboxInstance = MapboxglMap; /** * 底图类型 diff --git a/tsconfig.json b/tsconfig.json index d4823ef2e..fedf37970 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -3,7 +3,7 @@ /* Visit https://aka.ms/tsconfig.json to read more about this file */ /* Basic Options */ - "target": "es5", + "target": "es6", "module": "commonjs", "lib": ["DOM", "ESNext", "WebWorker"], "allowJs": false,