qm-map-maplibre-gl 0.0.1
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/README.md +162 -0
- package/dist/context/mapContext.d.ts +6 -0
- package/dist/index.d.ts +20 -0
- package/dist/maplibregl/MapWrapper.d.ts +56 -0
- package/dist/maplibregl/layer/BaseLayer.d.ts +11 -0
- package/dist/maplibregl/layer/LayerGroupWrapper.d.ts +18 -0
- package/dist/maplibregl/layer/LayerWrapper.d.ts +12 -0
- package/dist/maplibregl/typings/TEvent.d.ts +25 -0
- package/dist/maplibregl/typings/TLayerOptions.d.ts +29 -0
- package/dist/maplibregl/typings/TMapOptions.d.ts +4 -0
- package/dist/qm-map.css +2 -0
- package/dist/qm-map.es.js +1547 -0
- package/dist/qm-map.umd.js +28 -0
- package/dist/utils.d.ts +36 -0
- package/dist/widget/BaseWidget/index.d.ts +24 -0
- package/dist/widget/Draw/constant.d.ts +57 -0
- package/dist/widget/Draw/index.d.ts +17 -0
- package/dist/widget/LayerList/index.d.ts +5 -0
- package/dist/widget/LayerList/tree/index.d.ts +16 -0
- package/dist/widget/Legend/index.d.ts +5 -0
- package/dist/widget/MapWidget/index.d.ts +16 -0
- package/dist/widget/PopupPanel/index.d.ts +10 -0
- package/dist/widget/PopupWrapper/index.d.ts +16 -0
- package/dist/widget/Print/MapGenerator/CrosshairManager.d.ts +8 -0
- package/dist/widget/Print/MapGenerator/ImageExporter.d.ts +4 -0
- package/dist/widget/Print/MapGenerator/MapGenerator.d.ts +26 -0
- package/dist/widget/Print/MapGenerator/MarkersManager.d.ts +22 -0
- package/dist/widget/Print/MapGenerator/NorthIconManager.d.ts +44 -0
- package/dist/widget/Print/MapGenerator/PDFGenerator.d.ts +10 -0
- package/dist/widget/Print/MapGenerator/PrintableAreaManager.d.ts +12 -0
- package/dist/widget/Print/MapGenerator/SVGExporter.d.ts +3 -0
- package/dist/widget/Print/MapGenerator/types.d.ts +58 -0
- package/dist/widget/Print/index.d.ts +5 -0
- package/dist/widget/Swipe/MapCompare/index.d.ts +43 -0
- package/dist/widget/Swipe/MapCompare/sync-maps.d.ts +6 -0
- package/dist/widget/Swipe/index.d.ts +5 -0
- package/dist/widget/Swipe/modal/index.d.ts +31 -0
- package/package.json +63 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export interface ModalProps {
|
|
3
|
+
/** 弹窗标题 */
|
|
4
|
+
title?: ReactNode;
|
|
5
|
+
/** 是否显示弹窗 */
|
|
6
|
+
open?: boolean;
|
|
7
|
+
/** 点击蒙层是否允许关闭 */
|
|
8
|
+
maskClosable?: boolean;
|
|
9
|
+
/** 蒙层配置 (Antd风格) */
|
|
10
|
+
mask?: {
|
|
11
|
+
closable?: boolean;
|
|
12
|
+
};
|
|
13
|
+
/** 弹窗宽度 */
|
|
14
|
+
width?: number | string;
|
|
15
|
+
/** 底部内容 */
|
|
16
|
+
footer?: ReactNode;
|
|
17
|
+
/** 关闭回调 */
|
|
18
|
+
onCancel?: () => void;
|
|
19
|
+
/** 关闭后销毁内容 */
|
|
20
|
+
destroyOnHidden?: boolean;
|
|
21
|
+
/** 自定义className */
|
|
22
|
+
className?: string;
|
|
23
|
+
/** 自定义样式 */
|
|
24
|
+
style?: React.CSSProperties;
|
|
25
|
+
/** 子元素 */
|
|
26
|
+
children?: ReactNode;
|
|
27
|
+
/** 居中 */
|
|
28
|
+
centered?: boolean;
|
|
29
|
+
}
|
|
30
|
+
declare const _default: import('react').MemoExoticComponent<(props: ModalProps) => import('react').ReactPortal | null>;
|
|
31
|
+
export default _default;
|
package/package.json
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "qm-map-maplibre-gl",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"license": "MIT",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "dist/qm-map.es.js",
|
|
7
|
+
"style": "dist/qm-map.css",
|
|
8
|
+
"module": "dist/qm-map.umd.cjs",
|
|
9
|
+
"types": "dist/index.d.ts",
|
|
10
|
+
"files": [
|
|
11
|
+
"dist/*"
|
|
12
|
+
],
|
|
13
|
+
"scripts": {
|
|
14
|
+
"dev": "vite",
|
|
15
|
+
"build": "tsc -b && vite build",
|
|
16
|
+
"lint": "eslint --ext .js,.jsx,.ts,.tsx --fix --quiet ./",
|
|
17
|
+
"preview": "vite preview"
|
|
18
|
+
},
|
|
19
|
+
"lint-staged": {
|
|
20
|
+
"*.{js,jsx,tsx,ts}": [
|
|
21
|
+
"npm run lint"
|
|
22
|
+
]
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@mapbox/mapbox-gl-draw": "^1.5.1",
|
|
26
|
+
"@turf/area": "^7.3.5",
|
|
27
|
+
"maplibre-gl": "^5.24.0"
|
|
28
|
+
},
|
|
29
|
+
"peerDependencies": {
|
|
30
|
+
"react": "^19.2.6",
|
|
31
|
+
"react-dom": "^19.2.6"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@commitlint/cli": "^21.0.1",
|
|
35
|
+
"@commitlint/config-conventional": "^21.0.1",
|
|
36
|
+
"@eslint/js": "^10.0.1",
|
|
37
|
+
"@types/geojson": "^7946.0.16",
|
|
38
|
+
"@types/mapbox__mapbox-gl-draw": "^1.4.9",
|
|
39
|
+
"@types/node": "^24.12.3",
|
|
40
|
+
"@types/react": "^19.2.14",
|
|
41
|
+
"@types/react-dom": "^19.2.3",
|
|
42
|
+
"@vitejs/plugin-react": "^6.0.1",
|
|
43
|
+
"antd": "^6.4.3",
|
|
44
|
+
"eslint": "^10.3.0",
|
|
45
|
+
"eslint-config-prettier": "^10.1.8",
|
|
46
|
+
"eslint-plugin-prettier": "^5.5.5",
|
|
47
|
+
"eslint-plugin-react-hooks": "^7.1.1",
|
|
48
|
+
"eslint-plugin-react-refresh": "^0.5.2",
|
|
49
|
+
"globals": "^17.6.0",
|
|
50
|
+
"husky": "^9.1.7",
|
|
51
|
+
"less": "^4.6.4",
|
|
52
|
+
"lint-staged": "^17.0.5",
|
|
53
|
+
"maplibre-gl": "^5.24.0",
|
|
54
|
+
"prettier": "^3.8.3",
|
|
55
|
+
"react": "^19.2.6",
|
|
56
|
+
"react-dom": "^19.2.6",
|
|
57
|
+
"tslib": "^2.8.1",
|
|
58
|
+
"typescript": "~6.0.2",
|
|
59
|
+
"typescript-eslint": "^8.59.2",
|
|
60
|
+
"vite": "^8.0.12",
|
|
61
|
+
"vite-plugin-dts": "^5.0.1"
|
|
62
|
+
}
|
|
63
|
+
}
|