Skip to content

Commit 1e9749b

Browse files
committed
同步最新代码
1 parent 0a3772d commit 1e9749b

File tree

26 files changed

+54
-35
lines changed

26 files changed

+54
-35
lines changed

src/marsgis/common/store/test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* store 状态管理
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星吴彦祖 2021-12-30
4+
* @author 火星吴彦祖 2022-02-19
55
*/
66
import { Store, createStore } from "vuex"
77
import { InjectionKey } from "vue"

src/marsgis/common/uses/use-lifecycle.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* 组件中开启 map.ts 生命周期
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星吴彦祖 2021-12-30
4+
* @author 火星吴彦祖 2022-02-19
55
*/
66
import { inject, onBeforeMount, onUnmounted } from "vue"
77

src/marsgis/components/mars-ui/function.less

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* 通用 class
33
*
44
* @copyright 火星科技 mars3d.cn
5-
* @author 火星吴彦祖 2021-11-01
5+
* @author 火星吴彦祖 2022-01-01
66
*/
77

88
.f-pt {

src/marsgis/components/mars-ui/index.less

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* 所有页面全局公共CSS
33
*
44
* @copyright 火星科技 mars3d.cn
5-
* @author 火星吴彦祖 2021-11-01
5+
* @author 火星吴彦祖 2022-01-01
66
*/
77

88
/* 清除内外边距 */

src/marsgis/components/mars-ui/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* 统一导出公共组件, 按需初始化ant-design-vue
33
* @copyright 火星科技 mars3d.cn
4-
* @author 木遥 2021-11-01
4+
* @author 木遥 2022-01-01
55
*/
66
import { App } from "vue"
77
import MarsSelect from "./mars-select/index.vue"

src/marsgis/components/mars-ui/mars-alert/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import "./alert.less"
77
* @export
88
* @param {App} app vue实例
99
* @copyright 火星科技 mars3d.cn
10-
* @author 木遥 2021-11-01
10+
* @author 木遥 2022-01-01
1111
* @returns { void }
1212
*/
1313
export const $alert = (content: any, title = "提示", type: keyof typeof Modal = "info") => {

src/marsgis/components/mars-ui/mars-color-picker/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import "./mars-color-picker.less"
88
* 颜色选择器
99
*
1010
* @copyright 火星科技 mars3d.cn
11-
* @author 木遥 2021-11-01
11+
* @author 木遥 2022-01-01
1212
*/
1313
const MarsColorPicker = defineComponent({
1414
name: "mars-color-picker",

src/marsgis/components/mars-ui/mars-color-picker/mars-color-picker.less

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* 颜色选择器
33
*
44
* @copyright 火星科技 mars3d.cn
5-
* @author 木遥 2021-11-01
5+
* @author 木遥 2022-01-01
66
*/
77

88
.hu-color-picker {

src/marsgis/components/mars-ui/mars-dialog/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
/**
3535
* dislog弹框
3636
* @copyright 火星科技 mars3d.cn
37-
* @author 火星吴彦祖 2021-12-30
37+
* @author 火星吴彦祖 2022-02-19
3838
*/
3939
import { computed, onMounted, onUnmounted, ref } from "vue"
4040
import { getConfig } from "../index"

src/marsgis/components/mars-ui/mars-dropdown/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import "./dropdown.less"
66
* 下拉菜单
77
*
88
* @copyright 火星科技 mars3d.cn
9-
* @author 木遥 2021-11-01
9+
* @author 木遥 2022-01-01
1010
*/
1111

1212
const MarsDropdown = defineComponent({

src/marsgis/components/mars-ui/mars-echarts/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import * as echarts from "echarts"
22
/**
33
* echarts公共样式配置
44
* @copyright 火星科技 mars3d.cn
5-
* @author 火星吴彦祖 2021-12-30
5+
* @author 火星吴彦祖 2022-02-19
66
*/
77

88
echarts.registerTheme("dark", {

src/marsgis/components/mars-ui/mars-loading/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { App } from "vue"
77
* @export
88
* @param {App} app vue实例
99
* @copyright 火星科技 mars3d.cn
10-
* @author 火星吴彦祖 2021-12-30
10+
* @author 火星吴彦祖 2022-02-19
1111
* @returns { void }
1212
*/
1313
let loadingNum = 0

src/marsgis/components/mars-ui/mars-message/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import "./message.less"
77
* @export
88
* @param {App} app vue实例
99
* @copyright 火星科技 mars3d.cn
10-
* @author 木遥 2021-11-01
10+
* @author 木遥 2022-01-01
1111
* @returns {void}
1212
*/
1313

src/marsgis/components/mars-ui/mars-notify/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import "./notify.less"
77
* @export
88
* @param {App} app vue实例
99
* @copyright 火星科技 mars3d.cn
10-
* @author 木遥 2021-11-01
10+
* @author 木遥 2022-01-01
1111
* @returns { void }
1212
*/
1313
export const $notify = (message: any, description: any, options: any = {}, type: keyof typeof notification = "info") => {

src/marsgis/components/mars-ui/mars-pannel/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
/**
1717
* pannel面板
1818
* @copyright 火星科技 mars3d.cn
19-
* @author 火星吴彦祖 2021-12-30
19+
* @author 火星吴彦祖 2022-02-19
2020
*/
2121
import { onMounted, ref, computed } from "vue"
2222
import { getConfig } from "../index"

src/marsgis/components/mars-ui/mars-tree/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import "./tree.less"
66
/**
77
* 树控件
88
* @copyright 火星科技 mars3d.cn
9-
* @author 火星吴彦祖 2021-11-01
9+
* @author 火星吴彦祖 2022-01-01
1010
*/
1111
const MarsTree = defineComponent({
1212
name: "mars-tree",

src/marsgis/misc/env.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* 统一定义ts模块类型
44
* @copyright 火星科技 mars3d.cn
5-
* @author 木遥 2021-11-01
5+
* @author 木遥 2022-01-01
66
*/
77

88
declare module "*.vue" {

src/marsgis/utils/file-util.ts

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,17 @@
1+
/**
2+
* 文件处理相关 静态Util方法
3+
*
4+
* @copyright 火星科技 mars3d.cn
5+
* @author 木遥 2022-01-01
6+
*/
7+
import { toKml } from "kml-geojson"
18

29
/**
3-
* 读取json文件内容
10+
* 读取json文件内容
411
*
512
* @template T 返回的数据类型
613
* @param {*} file 文件选择框选择的文件对象
7-
* @return {*} {Promise<T>}
14+
* @return {*} {Promise<T>}
815
*/
916
export function readJSON<T>(file: any): Promise<T> {
1017
return new Promise((resolve) => {
@@ -25,6 +32,18 @@ export function readJSON<T>(file: any): Promise<T> {
2532
})
2633
}
2734

35+
export function saveGeoJSON2Kml(geojson: string, options: any): any {
36+
const geojsonObject = clone(geojson, null, null)
37+
38+
const kml = toKml(geojsonObject, {
39+
name: "Mars3D标绘数据",
40+
documentName: "Mars3D标绘数据文件",
41+
documentDescription: "标绘数据 by mars3d.cn",
42+
simplestyle: true,
43+
...options
44+
})
45+
return kml
46+
}
2847

2948
function clone(obj: any, removeKeys: any, level: any): any {
3049
// 避免死循环,拷贝的层级最大深度

src/marsgis/utils/mars-util.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
/**
2-
* 公共静态Util方法
2+
* 项目内通用 静态Util方法
33
*
44
* @copyright 火星科技 mars3d.cn
5-
* @author 木遥 2021-11-01
5+
* @author 木遥 2022-01-01
66
*/
77

88
/**

src/marsgis/widget-store.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* index页面的widget配置
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星吴彦祖 2021-12-30
4+
* @author 火星吴彦祖 2022-02-19
55
*/
66
import { defineAsyncComponent, markRaw } from "vue"
77
import { WidgetState } from "@mars/common/store/widget"
@@ -31,7 +31,7 @@ const store: StoreOptions<WidgetState> = {
3131
component: markRaw(defineAsyncComponent(() => import(/* webpackChunkName: "manage-layers" */ "@mars/widgets/basic/manage-layers/index.vue"))),
3232
name: "manage-layers",
3333
group: "manage",
34-
disableOther: ["roamfly"]
34+
disableOther: ["roamLine"]
3535
},
3636
{
3737
component: markRaw(
@@ -56,8 +56,8 @@ const store: StoreOptions<WidgetState> = {
5656
name: "layer-picture-guihua"
5757
},
5858
{
59-
component: markRaw(defineAsyncComponent(() => import(/* webpackChunkName: "select-point" */ "@mars/widgets/basic/select-point/index.vue"))),
60-
name: "select-point",
59+
component: markRaw(defineAsyncComponent(() => import(/* webpackChunkName: "location-point" */ "@mars/widgets/basic/location-point/index.vue"))),
60+
name: "location-point",
6161
group: "tools"
6262
}
6363
],

src/marsgis/widgets/basic/select-point/map.ts renamed to src/marsgis/widgets/basic/location-point/map.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* 图上选点
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星 胡椒 2021-12-20
4+
* @author 火星胡椒 2022-01-10
55
*/
66
import * as mars3d from "mars3d"
77
let map: mars3d.Map // 地图对象

src/marsgis/widgets/basic/manage-basemap/map.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* 底图控制
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星吴彦祖 2021-12-10
4+
* @author 火星吴彦祖 2022-01-10
55
*/
66
import * as mars3d from "mars3d"
77

src/marsgis/widgets/basic/manage-layers/map.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* 图层管理
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星吴彦祖 2021-12-10
4+
* @author 火星吴彦祖 2022-01-10
55
*/
66
import * as mars3d from "mars3d"
77
const Cesium = mars3d.Cesium

src/marsgis/widgets/basic/query-poi/map.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* 高德POI 查询栏 (左上角)
33
* @copyright 火星科技 mars3d.cn
4-
* @author 火星吴彦祖 2021-12-10
4+
* @author 火星吴彦祖 2022-01-10
55
*/
66
import * as mars3d from "mars3d"
77
const Cesium = mars3d.Cesium

src/marsgis/widgets/basic/toolbar/index.vue

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
/**
3030
* 导航菜单按钮 (右上角)
3131
* @copyright 火星科技 mars3d.cn
32-
* @author 火星吴彦祖 2021-12-10
32+
* @author 火星吴彦祖 2022-01-10
3333
*/
3434
import { useWidget } from "@mars/common/store/widget"
3535
@@ -43,17 +43,17 @@ const data = [
4343
icon: "icon-park-outline:tool",
4444
children: [
4545
// { name: "图上量算", icon: "icon-park-outline:ruler", widget: "measure" },
46-
// { name: "空间分析", icon: "icon-park-outline:analysis", widget: "analysis" },
47-
{ name: "坐标定位", icon: "icon-park-outline:local", widget: "select-point" }
48-
// { name: "地区导航", icon: "icon-park-outline:navigation", widget: "navigation" },
46+
// { name: "空间分析", icon: "icon-park-outline:analysis", widget: "analysis" }
47+
{ name: "坐标定位", icon: "icon-park-outline:local", widget: "location-point" }
48+
// { name: "地区导航", icon: "icon-park-outline:location-region", widget: "location-region" },
4949
// { name: "我的标记", icon: "icon-park-outline:mark", widget: "addmarker" },
5050
// { name: "视角书签", icon: "icon-park-outline:bookmark", widget: "bookmark" },
5151
// { name: "地图打印", icon: "icon-park-outline:printer", widget: "print" },
52-
// { name: "飞行漫游", icon: "icon-park-outline:take-off", widget: "roamLine" },
52+
// { name: "飞行漫游", icon: "icon-park-outline:take-off", widget: "roamLine-list" },
5353
// { name: "图上标绘", icon: "icon-park-outline:hand-painted-plate", widget: "plot" },
5454
// { name: "路线导航", icon: "icon-park-outline:connection", widget: "query-route" },
5555
// { name: "卷帘对比", icon: "icon-park-outline:switch-contrast", widget: "map-split" },
56-
// { name: "分屏对比", icon: "icon-park-outline:full-screen-play", widget: "screen-compare" }
56+
// { name: "分屏对比", icon: "icon-park-outline:full-screen-play", widget: "map-compare" }
5757
// { name: "百度街景", icon: h(City, { theme: "outline", size: "18" }), widget: "street-view" }
5858
]
5959
}

0 commit comments

Comments
 (0)