Skip to content

Commit 3b7a16f

Browse files
Merge branch 'for-maplibregl'
2 parents f20c4eb + 9f143a0 commit 3b7a16f

File tree

367 files changed

+35439
-6156
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

367 files changed

+35439
-6156
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"Visualization":{"default":[],"L7":{"default":["L7Layer"]}}}

build/jsdocs/maplibregl/docs.json

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
{
2+
"opts": {
3+
"recurse": true,
4+
"template": "../template",
5+
"configPath": "../maplibregl",
6+
"destination": "./docs/maplibregl"
7+
},
8+
"disqus": "",
9+
"tags": {
10+
"allowUnknownTags": true,
11+
"linkdoc-maplibregl": "https://maplibre.org/maplibre-gl-js-docs/api/"
12+
},
13+
"i18n": {
14+
"defaultLang": "en",
15+
"possibleLang": ["en"],
16+
"dbFilePath": "./build/jsdocs/maplibregl"
17+
},
18+
"source": {
19+
"includePattern": ".+\\.js?$",
20+
"excludePattern": ".+[\\\\/]src[\\\\/]common[\\\\/]iServer[\\\\/].*Service.js?$",
21+
"include": ["src/maplibregl"],
22+
"exclude": ["src/common"]
23+
},
24+
"plugins": ["plugins/markdown", "../plugins/usage"],
25+
"markdown": {
26+
"tags": ["usage"]
27+
},
28+
"templates": {
29+
"cleverLinks": true,
30+
"monospaceLinks": true,
31+
"default": {
32+
"outputSourceFiles": false
33+
},
34+
"namespace": "maplibregl.supermap",
35+
"npm": "@supermap/iclient-maplibregl",
36+
"cdn": "https://iclient.supermap.io/dist/maplibregl/iclient-maplibregl.js"
37+
}
38+
}

build/jsdocs/maplibregl/index.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# SuperMap iClient for MaplibreGL API
2+
3+
SuperMap iClient for MaplibreGL 是一套基于 MaplibreGL v1 的云 GIS 网络客户端开发平台, 支持访问 SuperMap iServer / iEdge / iPortal / iManager / Online 的地图、服务和资源,为用户提供了完整专业的 GIS 能力, 同时提供了优秀的可视化功能。
4+
5+
- 官网(website):<a href="https://iclient.supermap.io/web/introduction/maplibregl.html#introduce" target="_parent">https://iclient.supermap.io/web/introduction/maplibregl.html#introduce</a>
6+
7+
- 源码(source code):<a href="https://github.com/SuperMap/iClient-JavaScript/tree/master/src/maplibregl" target="_blank">https://github.com/SuperMap/iClient-JavaScript/tree/master/src/maplibregl</a>
8+
9+
## 参考 API
10+
11+
- Maplibre GL JS API:<a href="https://www.maplibre.com/maplibre-gl-js/api/" target="_blank">https://www.maplibre.com/maplibre-gl-js/api/</a>
12+
- ECharts API:<a href="https://echarts.baidu.com/api.html#echarts" target="_blank">https://echarts.baidu.com/api.html#echarts</a>
13+
- MapV API:<a href="https://github.com/huiyan-fe/mapv/blob/master/API.md" target="_blank">https://github.com/huiyan-fe/mapv/blob/master/API.md</a>

build/jsdocs/template/config.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,6 +365,10 @@
365365
"name": "DeckGL",
366366
"name_en": "DeckGL"
367367
},
368+
"L7": {
369+
"name": "L7",
370+
"name_en": "L7"
371+
},
368372
"Theme": {
369373
"name": "客户端专题图",
370374
"name_en": "Theme"

build/jsdocs/template/publish.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -562,6 +562,9 @@ var whiteLists = {
562562
'WebMap',
563563
'WKTFormat'
564564
],
565+
maplibregl:[
566+
'L7Layer',
567+
],
565568
openlayers: [
566569
'AddressMatchService',
567570
'ChartService',

build/jsdocs/template/typeLinkExt.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
var olapi = "https://openlayers.org/en/v6.14.1/apidoc/";
22
var lfapi = "https://leafletjs.com/reference.html";
33
var mbglapi = "https://www.mapbox.com/mapbox-gl-js/api/";
4+
var mlbglapi = "https://maplibre.org/maplibre-gl-js-docs/api/";
45
var mapv = "https://github.com/huiyan-fe/mapv/blob/master/src/";
56
var classicapi="https://iclient.supermap.io/web/libs/iclient8c/apidoc/files/SuperMap"
67
var geojsonapi = "https://geojson.org";
@@ -80,6 +81,10 @@ var typeLinks = {
8081
"mapboxgl.LngLat": mbglapi + '#lnglat',
8182
"mapboxgl.Point": mbglapi + '#point',
8283
"mapboxgl.source": 'https://docs.mapbox.com/mapbox-gl-js/style-spec/sources/#geojson',
84+
85+
//maplibregl
86+
"maplibregl.Map": mlbglapi + '#map',
87+
8388
//mapv
8489
"Mapv.DataSet": mapv + 'data/DataSet.md',
8590
"Mapv.BaiduMapLayer": mapv + 'map/baidu-map/Layer.md',

build/webpack.config.base.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ module.exports = {
5858
resolve: {
5959
extensions: ['.js', '.json', '.css'],
6060
mainFields: ['browser', 'main'],
61+
alias: {
62+
process: "process/browser"
63+
},
6164
fallback: {
6265
fs: false,
6366
http: require.resolve('stream-http'),
@@ -109,7 +112,10 @@ module.exports = {
109112
new LintExportWebpackPlugin(libName),
110113
new webpack.BannerPlugin(this.bannerInfo(productName)),
111114
new MiniCssExtractPlugin({filename:`./${productName}.css`}),
112-
new ESLintPlugin({ failOnError: true, files: 'src' })
115+
new ESLintPlugin({ failOnError: true, files: 'src' }),
116+
new webpack.ProvidePlugin({
117+
process: 'process/browser',
118+
}),
113119
];
114120
}
115121
};

build/webpack.config.maplibregl.js

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
const configBase = require('./webpack.config.base');
2+
//端名
3+
const libName = 'maplibregl';
4+
//产品包名
5+
const productName = 'iclient-maplibregl';
6+
7+
module.exports = {
8+
target: configBase.target,
9+
mode: 'development' || configBase.mode,
10+
devtool: 'inline-cheap-module-source-map',
11+
//页面入口文件配置
12+
entry: configBase.entry,
13+
//入口文件输出配置
14+
output: configBase.output(libName, productName),
15+
//是否启用压缩
16+
optimization: configBase.optimization,
17+
//不显示打包文件大小相关警告
18+
performance: configBase.performance,
19+
//其它解决方案配置
20+
resolve: configBase.resolve,
21+
22+
externals: Object.assign({}, configBase.externals, {
23+
'maplibre-gl': 'maplibregl',
24+
'@antv/l7': 'L7',
25+
three: 'THREE',
26+
'webgl-debug': '(function(){try{return webgl-debug}catch(e){return {}}})()'
27+
}),
28+
29+
module: {
30+
noParse: /[\/\\]node_modules[\/\\]maplibre-gl[\/\\]dist[\/\\]maplibre-gl\.js$/,
31+
rules: (function () {
32+
let moduleRules = [];
33+
moduleRules.push(configBase.module.rules.img);
34+
const babelConfig = {
35+
test: [/\.js$/],
36+
include: /node_modules[\/\\](proj4|@antv[\/\\]l7|maplibre-gl)/,
37+
loader: 'babel-loader',
38+
options: {
39+
presets: ['@babel/preset-env'],
40+
plugins: [
41+
[
42+
'@babel/plugin-transform-runtime',
43+
{
44+
absoluteRuntime: false,
45+
corejs: false,
46+
helpers: false,
47+
regenerator: true,
48+
useESModules: false
49+
}
50+
],
51+
'@babel/plugin-proposal-nullish-coalescing-operator'
52+
]
53+
}
54+
};
55+
configBase.moduleVersion === 'es6';
56+
moduleRules.push(babelConfig);
57+
moduleRules.push(configBase.module.rules.css);
58+
return moduleRules;
59+
})()
60+
},
61+
plugins: configBase.plugins(libName, productName)
62+
};

dist/maplibregl/iclient-maplibregl.css

Whitespace-only changes.

dist/maplibregl/iclient-maplibregl.min.css

Whitespace-only changes.

0 commit comments

Comments
 (0)