@antv/aimapui 0.3.0 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +49 -1
- package/dist/index.d.ts +266 -29
- package/dist/index.es.js +13637 -5887
- package/dist/index.iife.js +49 -1
- package/dist/style.css +1 -1
- package/package.json +16 -16
package/dist/index.d.ts
CHANGED
|
@@ -1,17 +1,10 @@
|
|
|
1
|
-
import { BaiduMap } from '@antv/l7-maps';
|
|
2
1
|
import { Component } from 'react';
|
|
3
2
|
import { default as default_2 } from 'react';
|
|
4
|
-
import { default as default_3 } from 'node_modules/@antv/l7-maps/es/amap-next';
|
|
5
3
|
import { Feature } from 'geojson';
|
|
6
|
-
import { GoogleMap } from '@antv/l7-maps';
|
|
7
4
|
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
|
8
|
-
import { Map as Map_2 } from '@antv/l7-maps';
|
|
9
|
-
import { Mapbox } from '@antv/l7-maps';
|
|
10
|
-
import { MapLibre } from '@antv/l7-maps';
|
|
11
5
|
import { ReactNode } from 'react';
|
|
6
|
+
import { RefObject } from 'react';
|
|
12
7
|
import { Scene } from '@antv/l7';
|
|
13
|
-
import { TencentMap } from '@antv/l7-maps';
|
|
14
|
-
import { TMap } from '@antv/l7-maps';
|
|
15
8
|
|
|
16
9
|
export declare type ActiveConfig = boolean | {
|
|
17
10
|
color: string;
|
|
@@ -819,6 +812,86 @@ export declare interface AnimateConfig {
|
|
|
819
812
|
repeat?: number;
|
|
820
813
|
}
|
|
821
814
|
|
|
815
|
+
export declare const AnnotationControl: default_2.ForwardRefExoticComponent<AnnotationControlProps & default_2.RefAttributes<AnnotationControlHandle>>;
|
|
816
|
+
|
|
817
|
+
export declare interface AnnotationControlHandle {
|
|
818
|
+
setMode: (mode: AnnotationMode) => void;
|
|
819
|
+
addAnnotation: (feature: AnnotationFeature) => void;
|
|
820
|
+
updateAnnotation: (id: string, properties: Partial<AnnotationProperties>) => void;
|
|
821
|
+
deleteAnnotation: (id: string) => void;
|
|
822
|
+
clearAll: () => void;
|
|
823
|
+
getAnnotations: () => AnnotationFeature[];
|
|
824
|
+
selectAnnotation: (id: string | null) => void;
|
|
825
|
+
}
|
|
826
|
+
|
|
827
|
+
export declare interface AnnotationControlProps {
|
|
828
|
+
position?: L7ControlPosition;
|
|
829
|
+
defaultFeatures?: AnnotationFeature[];
|
|
830
|
+
features?: AnnotationFeature[];
|
|
831
|
+
tools?: AnnotationToolMode[];
|
|
832
|
+
styles?: AnnotationStyleConfig;
|
|
833
|
+
onUpload?: (file: File, type: 'image' | 'video') => Promise<string>;
|
|
834
|
+
className?: string;
|
|
835
|
+
style?: React.CSSProperties;
|
|
836
|
+
onAnnotationCreate?: (feature: AnnotationFeature) => void;
|
|
837
|
+
onAnnotationUpdate?: (feature: AnnotationFeature) => void;
|
|
838
|
+
onAnnotationDelete?: (feature: AnnotationFeature) => void;
|
|
839
|
+
onAnnotationSelect?: (feature: AnnotationFeature | null) => void;
|
|
840
|
+
onModeChange?: (mode: AnnotationMode) => void;
|
|
841
|
+
onChange?: (features: AnnotationFeature[]) => void;
|
|
842
|
+
}
|
|
843
|
+
|
|
844
|
+
export declare interface AnnotationFeature extends Feature {
|
|
845
|
+
id: string;
|
|
846
|
+
properties: AnnotationProperties;
|
|
847
|
+
}
|
|
848
|
+
|
|
849
|
+
export declare type AnnotationMode = 'marker' | 'highlighter' | 'text' | 'note' | 'link' | 'image' | 'video' | 'select' | 'none';
|
|
850
|
+
|
|
851
|
+
export declare type AnnotationProperties = MarkerAnnotationProperties | HighlighterAnnotationProperties | TextAnnotationProperties | NoteAnnotationProperties | LinkAnnotationProperties | ImageAnnotationProperties | VideoAnnotationProperties;
|
|
852
|
+
|
|
853
|
+
declare interface AnnotationPropertiesBase {
|
|
854
|
+
annotationType: AnnotationType;
|
|
855
|
+
color?: string;
|
|
856
|
+
createdAt?: string;
|
|
857
|
+
updatedAt?: string;
|
|
858
|
+
}
|
|
859
|
+
|
|
860
|
+
export declare interface AnnotationStyleConfig {
|
|
861
|
+
marker?: {
|
|
862
|
+
color?: string;
|
|
863
|
+
size?: number;
|
|
864
|
+
};
|
|
865
|
+
highlighter?: {
|
|
866
|
+
color?: string;
|
|
867
|
+
width?: number;
|
|
868
|
+
opacity?: number;
|
|
869
|
+
};
|
|
870
|
+
text?: {
|
|
871
|
+
color?: string;
|
|
872
|
+
fontSize?: number;
|
|
873
|
+
fontFamily?: string;
|
|
874
|
+
};
|
|
875
|
+
note?: {
|
|
876
|
+
color?: string;
|
|
877
|
+
maxWidth?: number;
|
|
878
|
+
};
|
|
879
|
+
link?: {
|
|
880
|
+
color?: string;
|
|
881
|
+
};
|
|
882
|
+
image?: {
|
|
883
|
+
maxWidth?: number;
|
|
884
|
+
borderRadius?: number;
|
|
885
|
+
};
|
|
886
|
+
video?: {
|
|
887
|
+
maxWidth?: number;
|
|
888
|
+
};
|
|
889
|
+
}
|
|
890
|
+
|
|
891
|
+
export declare type AnnotationToolMode = Exclude<AnnotationMode, 'none'>;
|
|
892
|
+
|
|
893
|
+
declare type AnnotationType = 'marker' | 'highlighter' | 'text' | 'note' | 'link' | 'image' | 'video';
|
|
894
|
+
|
|
822
895
|
export declare function applyControlDefaults(control: ControlSchema): ControlSchema;
|
|
823
896
|
|
|
824
897
|
export declare function applyLayerDefaults(layer: LayerSchema): LayerSchema;
|
|
@@ -1007,6 +1080,8 @@ export declare interface BottomSheetProps {
|
|
|
1007
1080
|
|
|
1008
1081
|
export declare type BottomSheetSnap = 'collapsed' | 'half' | 'expanded';
|
|
1009
1082
|
|
|
1083
|
+
export declare const BUBBLE_SIZE_LEVELS: readonly [8, 16, 32, 48, 64];
|
|
1084
|
+
|
|
1010
1085
|
declare type BubbleAnchor = 'center' | 'top' | 'right' | 'bottom' | 'left' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
1011
1086
|
|
|
1012
1087
|
/**
|
|
@@ -1021,7 +1096,7 @@ declare type BubbleAnchor = 'center' | 'top' | 'right' | 'bottom' | 'left' | 'to
|
|
|
1021
1096
|
* - bubbleAnchor='center', labelAnchor='center' — 标签居中覆盖气泡(适合短文本)
|
|
1022
1097
|
* - bubbleAnchor='bottom', labelAnchor='top' — 标签在气泡上方(经典布局)
|
|
1023
1098
|
*/
|
|
1024
|
-
export declare function BubbleLayer({ source, sourceType, sourceConfig, labelField, labelColor, labelSize, showLabel,
|
|
1099
|
+
export declare function BubbleLayer({ source, sourceType, sourceConfig, labelField, labelColor, labelSize, showLabel, labelOffset, sizeDomain, bubbleAnchor, labelAnchor, hoverEffect, clickEffect, tooltipEffect, tooltipFields, tooltipTemplate, semanticColorField, color, size, sizeField, sizeValues, style, active, select, onClick, onMouseMove, onMouseEnter, onMouseLeave, ...rest }: BubbleLayerProps): JSX_2.Element;
|
|
1025
1100
|
|
|
1026
1101
|
export declare interface BubbleLayerProps extends Omit<LayerSchema, 'type' | 'source' | 'sourceType' | 'sourceConfig'> {
|
|
1027
1102
|
source: LayerSchema['source'];
|
|
@@ -1032,8 +1107,6 @@ export declare interface BubbleLayerProps extends Omit<LayerSchema, 'type' | 'so
|
|
|
1032
1107
|
labelColor?: string;
|
|
1033
1108
|
labelSize?: number;
|
|
1034
1109
|
showLabel?: boolean;
|
|
1035
|
-
/** 文本标签触发方式:'always' 始终显示 | 'hover' 鼠标划过时显示,默认 'always' */
|
|
1036
|
-
labelTrigger?: 'always' | 'hover';
|
|
1037
1110
|
/** 文本偏移量,默认根据气泡最大半径自动计算 */
|
|
1038
1111
|
labelOffset?: [number, number];
|
|
1039
1112
|
/** sizeField 为离散值时,对应每个 sizeValues 的域值顺序(默认 1..N) */
|
|
@@ -1262,7 +1335,7 @@ export declare type ControlType = 'zoom' | 'scale' | 'fullscreen' | 'geoLocate'
|
|
|
1262
1335
|
* 底图工厂 — 根据配置创建 L7 Map 实例
|
|
1263
1336
|
* 动态导入各底图模块,避免未使用时打包
|
|
1264
1337
|
*/
|
|
1265
|
-
export declare function createBasemap(schema: MapSchema): Promise<
|
|
1338
|
+
export declare function createBasemap(schema: MapSchema): Promise<unknown>;
|
|
1266
1339
|
|
|
1267
1340
|
/**
|
|
1268
1341
|
* 创建 EventBus 实例
|
|
@@ -1582,28 +1655,33 @@ export declare interface ExportConfig {
|
|
|
1582
1655
|
quality?: number;
|
|
1583
1656
|
}
|
|
1584
1657
|
|
|
1585
|
-
export declare
|
|
1658
|
+
export declare const ExportImageControl: default_2.ForwardRefExoticComponent<ExportImageControlProps & default_2.RefAttributes<ExportImageHandle>>;
|
|
1586
1659
|
|
|
1587
1660
|
/**
|
|
1588
1661
|
* ExportImage 导出图片控件
|
|
1589
1662
|
*
|
|
1590
|
-
*
|
|
1591
|
-
*
|
|
1592
|
-
*
|
|
1593
|
-
*
|
|
1594
|
-
*
|
|
1663
|
+
* 导图为底图(高德)和可视化图层(L7)的合并图。
|
|
1664
|
+
* 优先使用 L7 API(exportMap + exportPng),
|
|
1665
|
+
* 失败时回退到直接抓取 map 容器内的所有 canvas 合并。
|
|
1666
|
+
*
|
|
1667
|
+
* ```tsx
|
|
1668
|
+
* const ref = useRef<ExportImageHandle>(null);
|
|
1669
|
+
* <ExportImageControl ref={ref} />
|
|
1670
|
+
* const base64 = await ref.current?.exportImage();
|
|
1671
|
+
* ```
|
|
1595
1672
|
*/
|
|
1596
1673
|
export declare interface ExportImageControlProps {
|
|
1597
|
-
/** 控件位置,默认 topright */
|
|
1598
1674
|
position?: L7ControlPosition;
|
|
1599
|
-
/** 图片格式,默认 png */
|
|
1600
1675
|
format?: 'png' | 'jpg';
|
|
1601
1676
|
className?: string;
|
|
1602
1677
|
style?: default_2.CSSProperties;
|
|
1603
|
-
/** 导出回调 */
|
|
1604
1678
|
onExport?: (base64: string) => void;
|
|
1605
1679
|
}
|
|
1606
1680
|
|
|
1681
|
+
export declare interface ExportImageHandle {
|
|
1682
|
+
exportImage(format?: 'png' | 'jpg'): Promise<string | undefined>;
|
|
1683
|
+
}
|
|
1684
|
+
|
|
1607
1685
|
/** 导出选项(向后兼容) */
|
|
1608
1686
|
export declare interface ExportOptions {
|
|
1609
1687
|
maxWidth?: number;
|
|
@@ -1740,6 +1818,13 @@ export declare interface GestureConfig {
|
|
|
1740
1818
|
dragRotate?: boolean;
|
|
1741
1819
|
}
|
|
1742
1820
|
|
|
1821
|
+
/**
|
|
1822
|
+
* 根据控件 position 计算弹出面板的初始方向
|
|
1823
|
+
* - top* → 向下弹出, bottom* → 向上弹出
|
|
1824
|
+
* - left* → 向右弹出, right* → 向左弹出
|
|
1825
|
+
*/
|
|
1826
|
+
export declare function getPopperDirection(pos: L7ControlPosition): string;
|
|
1827
|
+
|
|
1743
1828
|
/**
|
|
1744
1829
|
* 字体图标标注图层(GlyphLayer)
|
|
1745
1830
|
*
|
|
@@ -1839,6 +1924,32 @@ export declare interface GlyphLayerProps extends Omit<LayerSchema, 'type' | 'sou
|
|
|
1839
1924
|
onMouseLeave?: (payload: LayerEventPayload) => void;
|
|
1840
1925
|
}
|
|
1841
1926
|
|
|
1927
|
+
export declare const H3_SEQUENTIAL_COLORS: readonly ["#dbeafe", "#93c5fd", "#60a5fa", "#3b82f6", "#2563eb"];
|
|
1928
|
+
|
|
1929
|
+
export declare interface H3DataItem {
|
|
1930
|
+
[key: string]: unknown;
|
|
1931
|
+
}
|
|
1932
|
+
|
|
1933
|
+
export declare function H3Layer({ source, h3Field, color, colorField, colorValues, opacity, showStroke, strokeColor, strokeWidth, hoverEffect, clickEffect, showLabel, labelField, labelColor, labelSize, active, select, style, onClick, onMouseMove, onMouseEnter, onMouseLeave, ...rest }: H3LayerProps): JSX_2.Element;
|
|
1934
|
+
|
|
1935
|
+
export declare interface H3LayerProps extends Omit<LayerSchema, 'type' | 'source' | 'sourceType' | 'sourceConfig' | 'shape' | 'shapeField' | 'shapeValues'> {
|
|
1936
|
+
source: H3DataItem[];
|
|
1937
|
+
h3Field?: string;
|
|
1938
|
+
showStroke?: boolean;
|
|
1939
|
+
strokeColor?: string;
|
|
1940
|
+
strokeWidth?: number;
|
|
1941
|
+
hoverEffect?: boolean;
|
|
1942
|
+
clickEffect?: boolean;
|
|
1943
|
+
showLabel?: boolean;
|
|
1944
|
+
labelField?: string;
|
|
1945
|
+
labelColor?: string;
|
|
1946
|
+
labelSize?: number;
|
|
1947
|
+
onClick?: (payload: LayerEventPayload) => void;
|
|
1948
|
+
onMouseMove?: (payload: LayerEventPayload) => void;
|
|
1949
|
+
onMouseEnter?: (payload: LayerEventPayload) => void;
|
|
1950
|
+
onMouseLeave?: (payload: LayerEventPayload) => void;
|
|
1951
|
+
}
|
|
1952
|
+
|
|
1842
1953
|
/**
|
|
1843
1954
|
* 热力图图层组件
|
|
1844
1955
|
*
|
|
@@ -1887,6 +1998,12 @@ export { HexagonLayerProps }
|
|
|
1887
1998
|
*/
|
|
1888
1999
|
export declare function hexToRgba(hex: string, alpha?: number): string;
|
|
1889
2000
|
|
|
2001
|
+
declare interface HighlighterAnnotationProperties extends AnnotationPropertiesBase {
|
|
2002
|
+
annotationType: 'highlighter';
|
|
2003
|
+
strokeWidth?: number;
|
|
2004
|
+
strokeOpacity?: number;
|
|
2005
|
+
}
|
|
2006
|
+
|
|
1890
2007
|
export declare type IconAnchor = 'center' | 'top' | 'bottom' | 'left' | 'right';
|
|
1891
2008
|
|
|
1892
2009
|
/** 图标锚点位置 */
|
|
@@ -1949,12 +2066,22 @@ export declare interface IconLayerProps extends Omit<LayerSchema, 'type' | 'sour
|
|
|
1949
2066
|
onMouseLeave?: (payload: LayerEventPayload) => void;
|
|
1950
2067
|
}
|
|
1951
2068
|
|
|
2069
|
+
declare interface ImageAnnotationProperties extends AnnotationPropertiesBase {
|
|
2070
|
+
annotationType: 'image';
|
|
2071
|
+
src: string;
|
|
2072
|
+
alt?: string;
|
|
2073
|
+
width?: number;
|
|
2074
|
+
height?: number;
|
|
2075
|
+
}
|
|
2076
|
+
|
|
1952
2077
|
export declare const ImageCalibrationControl: default_2.ForwardRefExoticComponent<ImageCalibrationControlProps & default_2.RefAttributes<ImageCalibrationHandle>>;
|
|
1953
2078
|
|
|
1954
2079
|
/** ImageCalibrationControl 组件 Props */
|
|
1955
2080
|
export declare interface ImageCalibrationControlProps {
|
|
1956
2081
|
/** 控件位置 */
|
|
1957
2082
|
position?: L7ControlPosition;
|
|
2083
|
+
/** 布局方向,默认 vertical */
|
|
2084
|
+
layout?: 'vertical' | 'horizontal';
|
|
1958
2085
|
/** 受控模式:外部传入角点 */
|
|
1959
2086
|
corners?: GeoCorners;
|
|
1960
2087
|
/** 非受控模式:初始角点 */
|
|
@@ -1965,32 +2092,64 @@ export declare interface ImageCalibrationControlProps {
|
|
|
1965
2092
|
opacity?: number;
|
|
1966
2093
|
/** 接受的文件类型,默认 'image/*' */
|
|
1967
2094
|
accept?: string;
|
|
2095
|
+
/** 是否启用图片裁剪功能,默认 true */
|
|
2096
|
+
enableCrop?: boolean;
|
|
2097
|
+
/** 是否启用初始坐标输入功能,默认 true */
|
|
2098
|
+
enableInitialCoords?: boolean;
|
|
1968
2099
|
/** 额外 className */
|
|
1969
2100
|
className?: string;
|
|
1970
2101
|
/** 额外 style */
|
|
1971
2102
|
style?: React.CSSProperties;
|
|
1972
2103
|
/** 角点变化回调 */
|
|
1973
|
-
onCornersChange?: (corners: GeoCorners) => void;
|
|
2104
|
+
onCornersChange?: (imageId: string, corners: GeoCorners) => void;
|
|
1974
2105
|
/** 确认配准回调 */
|
|
1975
|
-
onCalibrate?: (result: CalibrationResult) => void;
|
|
2106
|
+
onCalibrate?: (imageId: string, result: CalibrationResult) => void;
|
|
1976
2107
|
/** 导出完成回调 */
|
|
1977
|
-
onExport?: (result: ExportResult) => void;
|
|
2108
|
+
onExport?: (imageId: string, result: ExportResult) => void;
|
|
1978
2109
|
/** 图片加载完成回调 */
|
|
1979
|
-
onImageLoad?: (dimensions: {
|
|
2110
|
+
onImageLoad?: (imageId: string, dimensions: {
|
|
1980
2111
|
width: number;
|
|
1981
2112
|
height: number;
|
|
1982
2113
|
}) => void;
|
|
2114
|
+
/** 裁剪预处理完成回调,返回裁剪后的尺寸和可选的初始坐标 */
|
|
2115
|
+
onPreprocess?: (imageId: string, result: {
|
|
2116
|
+
croppedDimensions: {
|
|
2117
|
+
width: number;
|
|
2118
|
+
height: number;
|
|
2119
|
+
};
|
|
2120
|
+
initialCorners: GeoCorners | null;
|
|
2121
|
+
}) => void;
|
|
1983
2122
|
/** 清除回调 */
|
|
1984
|
-
onClear?: () => void;
|
|
2123
|
+
onClear?: (imageId: string) => void;
|
|
2124
|
+
/** 图片列表变化回调 */
|
|
2125
|
+
onImagesChange?: (images: RegisteredImage[]) => void;
|
|
2126
|
+
/** 切换图片回调 */
|
|
2127
|
+
onImageSwitch?: (imageId: string) => void;
|
|
2128
|
+
/** 图片重命名回调 */
|
|
2129
|
+
onImageRename?: (imageId: string, oldName: string, newName: string) => void;
|
|
2130
|
+
/** 图片列表拖拽排序回调 */
|
|
2131
|
+
onImagesReorder?: (images: RegisteredImage[]) => void;
|
|
2132
|
+
/** 上传新图片回调 */
|
|
2133
|
+
onImageAdd?: (image: RegisteredImage) => void;
|
|
2134
|
+
/** 删除图片回调 */
|
|
2135
|
+
onImageRemove?: (imageId: string) => void;
|
|
1985
2136
|
}
|
|
1986
2137
|
|
|
1987
2138
|
/** 命令式 Handle */
|
|
1988
2139
|
export declare interface ImageCalibrationHandle {
|
|
1989
2140
|
getCorners(): GeoCorners | null;
|
|
1990
2141
|
setCorners(corners: GeoCorners): void;
|
|
1991
|
-
setImage(source: ImageSource): void;
|
|
2142
|
+
setImage(source: ImageSource, initialCorners?: GeoCorners | null): void;
|
|
1992
2143
|
exportImage(config?: ExportConfig): Promise<ExportResult>;
|
|
1993
2144
|
clear(): void;
|
|
2145
|
+
/** 获取所有已注册的图片列表 */
|
|
2146
|
+
getImages(): RegisteredImage[];
|
|
2147
|
+
/** 切换激活图片 */
|
|
2148
|
+
switchImage(id: string): void;
|
|
2149
|
+
/** 删除指定图片 */
|
|
2150
|
+
deleteImage(id: string): void;
|
|
2151
|
+
/** 获取当前激活图片 ID */
|
|
2152
|
+
getActiveImageId(): string | null;
|
|
1994
2153
|
}
|
|
1995
2154
|
|
|
1996
2155
|
/**
|
|
@@ -2475,6 +2634,12 @@ export declare interface LineLayerProps extends Omit<LayerSchema, 'type' | 'sour
|
|
|
2475
2634
|
onLayerCreated?: (layer: any) => void;
|
|
2476
2635
|
}
|
|
2477
2636
|
|
|
2637
|
+
declare interface LinkAnnotationProperties extends AnnotationPropertiesBase {
|
|
2638
|
+
annotationType: 'link';
|
|
2639
|
+
url: string;
|
|
2640
|
+
title?: string;
|
|
2641
|
+
}
|
|
2642
|
+
|
|
2478
2643
|
export declare function LogoControl({ logos, position, className, style, }: LogoControlProps): JSX_2.Element;
|
|
2479
2644
|
|
|
2480
2645
|
export declare interface LogoControlProps {
|
|
@@ -2577,7 +2742,10 @@ declare interface MapSceneRendererProps {
|
|
|
2577
2742
|
}
|
|
2578
2743
|
|
|
2579
2744
|
export declare interface MapSchema {
|
|
2580
|
-
|
|
2745
|
+
/** 底图类型(与 engine 二选一,传 engine 时可省略) */
|
|
2746
|
+
basemap?: BasemapType;
|
|
2747
|
+
/** 外部注入的地图引擎构造函数,跳过动态 import */
|
|
2748
|
+
engine?: new (opts: Record<string, unknown>) => unknown;
|
|
2581
2749
|
token?: string;
|
|
2582
2750
|
style?: MapStylePreset | string;
|
|
2583
2751
|
center?: [number, number];
|
|
@@ -2611,6 +2779,12 @@ export declare interface MapThemeControlProps {
|
|
|
2611
2779
|
|
|
2612
2780
|
export declare function Marker({ longitude, latitude, variant, color, icon, label, content, children, draggable, className, overlayContainer, onClick, onMouseEnter, onMouseLeave, onDoubleClick, onDragEnd, onDragging, onDragStart, selected, inactive, anchor, offsets, overflowHide, }: MarkerProps): null;
|
|
2613
2781
|
|
|
2782
|
+
declare interface MarkerAnnotationProperties extends AnnotationPropertiesBase {
|
|
2783
|
+
annotationType: 'marker';
|
|
2784
|
+
icon?: string;
|
|
2785
|
+
label?: string;
|
|
2786
|
+
}
|
|
2787
|
+
|
|
2614
2788
|
/**
|
|
2615
2789
|
* Marker 聚合图层(基于 supercluster)
|
|
2616
2790
|
*
|
|
@@ -2783,6 +2957,12 @@ export declare interface MouseLocationControlProps {
|
|
|
2783
2957
|
style?: default_2.CSSProperties;
|
|
2784
2958
|
}
|
|
2785
2959
|
|
|
2960
|
+
declare interface NoteAnnotationProperties extends AnnotationPropertiesBase {
|
|
2961
|
+
annotationType: 'note';
|
|
2962
|
+
title: string;
|
|
2963
|
+
body?: string;
|
|
2964
|
+
}
|
|
2965
|
+
|
|
2786
2966
|
/**
|
|
2787
2967
|
* Mapbox / Maplibre 主题预设 — 基于 openfreemap 样式
|
|
2788
2968
|
*/
|
|
@@ -2976,6 +3156,31 @@ export declare interface RasterLayerProps extends Omit<LayerSchema, 'type' | 'so
|
|
|
2976
3156
|
*/
|
|
2977
3157
|
export declare type RasterRenderMode = 'raster' | 'rgb' | 'ndi';
|
|
2978
3158
|
|
|
3159
|
+
/** 单张配准图片(多图管理) */
|
|
3160
|
+
declare interface RegisteredImage {
|
|
3161
|
+
id: string;
|
|
3162
|
+
name: string;
|
|
3163
|
+
/** 图片来源(File 或 URL),用于重新加载 */
|
|
3164
|
+
source: ImageSource;
|
|
3165
|
+
/** 缩略图 URL */
|
|
3166
|
+
thumbnailUrl: string;
|
|
3167
|
+
/** 图片尺寸 */
|
|
3168
|
+
dimensions: {
|
|
3169
|
+
width: number;
|
|
3170
|
+
height: number;
|
|
3171
|
+
} | null;
|
|
3172
|
+
/** 当前阶段 */
|
|
3173
|
+
phase: CalibrationPhase;
|
|
3174
|
+
/** 当前角点 */
|
|
3175
|
+
corners: GeoCorners | null;
|
|
3176
|
+
/** 透明度 0-1 */
|
|
3177
|
+
opacity: number;
|
|
3178
|
+
/** 需要释放的 ObjectURL */
|
|
3179
|
+
revokeUrl: (() => void) | null;
|
|
3180
|
+
/** 裁剪产生的额外 URL 需要释放 */
|
|
3181
|
+
croppedRevokeUrl: (() => void) | null;
|
|
3182
|
+
}
|
|
3183
|
+
|
|
2979
3184
|
declare type ResolvedMapSchema = MapSchema & {
|
|
2980
3185
|
basemap: NonNullable<MapSchema['basemap']>;
|
|
2981
3186
|
center: NonNullable<MapSchema['center']>;
|
|
@@ -3025,7 +3230,7 @@ export declare interface ResponsiveSchema {
|
|
|
3025
3230
|
* />
|
|
3026
3231
|
* ```
|
|
3027
3232
|
*/
|
|
3028
|
-
export declare function RouteLayer({ path, segments, stops, routeType, onRouteQuery, onRouteResult, color, lineWidth, opacity, glow, animate, animateSpeed, stopSize, stopColor, endColor, showStopIndex, stopRenderer, stopMarkerVariant, stopIconMap, stopIconField, stopIconSize, stopIconAnchor, showStopPopup, activeColor, onPathClick, onStopClick, }: RouteLayerProps): JSX_2.Element | null;
|
|
3233
|
+
export declare function RouteLayer({ path, segments, stops, routeType, onRouteQuery, onRouteResult, color, lineWidth, opacity, glow, animate, animateSpeed, stopSize, stopColor, endColor, showStopIndex, showStopName, stopNameColor, stopNameSize, stopRenderer, stopMarkerVariant, stopIconMap, stopIconField, stopIconSize, stopIconAnchor, showStopPopup, activeColor, onPathClick, onStopClick, }: RouteLayerProps): JSX_2.Element | null;
|
|
3029
3234
|
|
|
3030
3235
|
export declare interface RouteLayerProps {
|
|
3031
3236
|
/** 路径坐标 — 完整线坐标或分段 */
|
|
@@ -3060,6 +3265,12 @@ export declare interface RouteLayerProps {
|
|
|
3060
3265
|
endColor?: string;
|
|
3061
3266
|
/** 是否显示途经点序号,默认 true */
|
|
3062
3267
|
showStopIndex?: boolean;
|
|
3268
|
+
/** 是否显示途经点名称,默认 true */
|
|
3269
|
+
showStopName?: boolean;
|
|
3270
|
+
/** 名称文字颜色,默认 '#334155' */
|
|
3271
|
+
stopNameColor?: string;
|
|
3272
|
+
/** 名称文字大小,默认 11 */
|
|
3273
|
+
stopNameSize?: number;
|
|
3063
3274
|
/** 停留点渲染模式,默认 'point' */
|
|
3064
3275
|
stopRenderer?: 'point' | 'marker' | 'icon';
|
|
3065
3276
|
/** marker 模式下的默认变体,默认 'circle' */
|
|
@@ -3300,6 +3511,12 @@ declare interface SourceOutput {
|
|
|
3300
3511
|
|
|
3301
3512
|
export declare type SourceType = 'geojson' | 'json' | 'csv' | 'raster' | 'rasterTile' | 'image';
|
|
3302
3513
|
|
|
3514
|
+
declare interface TextAnnotationProperties extends AnnotationPropertiesBase {
|
|
3515
|
+
annotationType: 'text';
|
|
3516
|
+
text: string;
|
|
3517
|
+
fontSize?: number;
|
|
3518
|
+
}
|
|
3519
|
+
|
|
3303
3520
|
declare interface ThemeContextValue {
|
|
3304
3521
|
/** 当前解析后的实际主题(light 或 dark) */
|
|
3305
3522
|
resolvedTheme: 'light' | 'dark';
|
|
@@ -3542,6 +3759,19 @@ export declare function useMapControl(position?: L7ControlPosition): {
|
|
|
3542
3759
|
*/
|
|
3543
3760
|
export declare function useMapPosition(scene: Scene | null, longitude: number, latitude: number, onPositionUpdate: PositionCallback_2): void;
|
|
3544
3761
|
|
|
3762
|
+
/**
|
|
3763
|
+
* Popper 弹出方向 Hook —— 根据控件 position 给出初始方向,
|
|
3764
|
+
* 弹出后检测视口溢出并自动翻转。
|
|
3765
|
+
*
|
|
3766
|
+
* 返回 { popperRef, popperClass }
|
|
3767
|
+
* - popperRef:挂到弹出容器 div 上
|
|
3768
|
+
* - popperClass:当前计算出的 CSS class 字符串
|
|
3769
|
+
*/
|
|
3770
|
+
export declare function usePopperPosition(position: L7ControlPosition, open: boolean, anchorRef: React.RefObject<HTMLElement | null>): {
|
|
3771
|
+
popperRef: RefObject<HTMLDivElement>;
|
|
3772
|
+
popperClass: string;
|
|
3773
|
+
};
|
|
3774
|
+
|
|
3545
3775
|
export declare function useResponsive(): ResponsiveContextValue;
|
|
3546
3776
|
|
|
3547
3777
|
export declare function useScene(): Scene | null;
|
|
@@ -3573,6 +3803,13 @@ export declare interface ValidationError {
|
|
|
3573
3803
|
severity: 'error' | 'warning';
|
|
3574
3804
|
}
|
|
3575
3805
|
|
|
3806
|
+
declare interface VideoAnnotationProperties extends AnnotationPropertiesBase {
|
|
3807
|
+
annotationType: 'video';
|
|
3808
|
+
url: string;
|
|
3809
|
+
thumbnailUrl?: string;
|
|
3810
|
+
title?: string;
|
|
3811
|
+
}
|
|
3812
|
+
|
|
3576
3813
|
declare interface VisualConfig {
|
|
3577
3814
|
color?: ColorConfig;
|
|
3578
3815
|
size?: SizeConfig;
|