tg-map-vue3
Version:
封装 百度地图, Google地图, Here地图(未完成) 的Vue3组件库
26 lines (25 loc) • 1.1 kB
TypeScript
import { HERE_SUPPORTED_VERSIONS } from '../utils/here-utils';
import type { DeepPartial } from '../utils/mapped-types';
export interface MapConfig {
key: string;
version: string;
}
export interface TgMapConfig {
google: MapConfig & {
/** @see https://developers.google.com/maps/documentation/javascript/versions */
version: 'weekly' | 'quarterly' | 'beta' | 'alpha' | '3.49' | '3.50' | '3.51' | '3.52';
language: string;
/** @see https://developers.google.com/maps/documentation/javascript/libraries */
libraries: ('drawing' | 'geometry' | 'journeySharing' | 'localContext' | 'marker' | 'places' | 'visualization')[];
};
baidu: MapConfig & {
/** @see https://lbsyun.baidu.com/index.php?title=jspopular3.0/theupdatelog */
version: '3.0';
};
here: MapConfig & {
version: typeof HERE_SUPPORTED_VERSIONS[number];
};
}
export type PartialTgMapConfig = DeepPartial<TgMapConfig>;
export declare function getTgMapConfig(): TgMapConfig;
export declare function setTgMapConfig(config?: PartialTgMapConfig): void;