@supermapgis/vue-iclient-leaflet 11.2.1 → 11.3.0
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/iclient-leaflet-vue.css +23 -9
- package/dist/iclient-leaflet-vue.js +21689 -44354
- package/dist/iclient-leaflet-vue.min.css +2 -2
- package/dist/iclient-leaflet-vue.min.js +39 -293
- package/lib/_assets/iconfont/icon-sm-components.css +21 -7
- package/lib/_assets/iconfont/icon-sm-components.ttf +0 -0
- package/lib/_assets/iconfont/icon-sm-components.woff +0 -0
- package/lib/_assets/iconfont/icon-sm-components.woff2 +0 -0
- package/lib/_lang/en.js +20 -8
- package/lib/_lang/index.js +18 -18
- package/lib/_lang/zh.js +20 -8
- package/lib/_mixin/AntdRender.js +15 -17
- package/lib/_mixin/Card.js +10 -11
- package/lib/_mixin/GridLayer.js +4 -4
- package/lib/_mixin/Layer.js +4 -4
- package/lib/_mixin/Options.js +2 -2
- package/lib/_mixin/Popper.js +2 -2
- package/lib/_mixin/Theme.js +13 -15
- package/lib/_mixin/ThirdService.js +15 -16
- package/lib/_mixin/TileLayer.js +4 -4
- package/lib/_mixin/Timer.js +8 -9
- package/lib/_mixin/VmUpdater.js +10 -11
- package/lib/_mixin/map-events.js +8 -9
- package/lib/_mixin/map-getter.js +13 -14
- package/lib/_types/AddressMatchParameter.js +2 -2
- package/lib/_types/GeoJSONParamter.js +2 -2
- package/lib/_types/RestDataParameter.js +5 -6
- package/lib/_types/RestMapParameter.js +5 -6
- package/lib/_types/RestParameter.js +2 -2
- package/lib/_types/event/BaseTypes.js +2 -2
- package/lib/_types/event/Event.js +4 -4
- package/lib/_types/event/Events.js +10 -10
- package/lib/_types/event/Pixel.js +2 -2
- package/lib/_types/event/Util.js +2 -2
- package/lib/_types/iPortalDataParameter.js +3 -2
- package/lib/_types/iServerBaseParameter.js +3 -2
- package/lib/_types/iServerDataParameter.js +5 -6
- package/lib/_types/iServerMapParameter.js +5 -6
- package/lib/_types/index.js +18 -18
- package/lib/_types/map-event.js +6 -6
- package/lib/_utils/EchartsDataService.js +24 -24
- package/lib/_utils/RestService.js +1345 -1149
- package/lib/_utils/epsg-define.js +45 -34
- package/lib/_utils/get-features.js +23 -10
- package/lib/_utils/global-event.js +6 -6
- package/lib/_utils/iPortalDataService.js +1368 -1147
- package/lib/_utils/iServerRestService.js +1518 -1269
- package/lib/_utils/props-binder.js +2 -2
- package/lib/_utils/statistics.js +8 -17
- package/lib/_utils/style/color/colorPalette.js +4 -4
- package/lib/_utils/style/color/serialColors.js +8 -8
- package/lib/_utils/style/theme/chart.js +1343 -1146
- package/lib/_utils/style/theme/set-theme.js +10 -10
- package/lib/_utils/style/theme/theme.json +6 -6
- package/lib/_utils/util.js +12 -12
- package/lib/_utils/vue-types/utils.js +2 -2
- package/lib/attribute-panel/style/attribute-panel.css +1 -0
- package/lib/attribute-panel/style/css.js +7 -0
- package/lib/attribute-panel/style/index.js +7 -0
- package/lib/avatar/index.js +25 -25
- package/lib/border/index.js +77 -77
- package/lib/breadcrumb/index.js +47 -41
- package/lib/button/index.js +53 -50
- package/lib/card/index.js +47 -41
- package/lib/chart/index.js +1437 -1238
- package/lib/checkbox/index.js +36 -33
- package/lib/collapse/index.js +39 -36
- package/lib/collapse-card/index.js +71 -76
- package/lib/color-picker/index.js +48 -49
- package/lib/date-picker/index.js +107 -95
- package/lib/dropdown/index.js +27 -27
- package/lib/empty/index.js +27 -27
- package/lib/icon/index.js +25 -25
- package/lib/identify/index.js +58 -59
- package/lib/iframe/index.js +31 -31
- package/lib/image/index.js +226 -42
- package/lib/image/style/image.css +1 -1
- package/lib/index.js +4 -4
- package/lib/indicator/index.js +70 -67
- package/lib/init.js +8 -8
- package/lib/input/index.js +150 -135
- package/lib/input-number/index.js +100 -97
- package/lib/layout/index.js +72 -60
- package/lib/liquid-fill/index.js +73 -73
- package/lib/marker/index.js +43 -44
- package/lib/menu/index.js +47 -41
- package/lib/message/index.js +3 -3
- package/lib/message/style/message.css +1 -1
- package/lib/modal/index.js +67 -67
- package/lib/modal/style/modal.css +1 -1
- package/lib/notification/index.js +6 -6
- package/lib/notification/style/notification.css +1 -1
- package/lib/pagination/index.js +34 -34
- package/lib/popup/index.js +45 -46
- package/lib/progress/index.js +440 -440
- package/lib/radio/index.js +48 -42
- package/lib/select/index.js +47 -41
- package/lib/slider/index.js +27 -27
- package/lib/slideshow/index.js +103 -160
- package/lib/spin/index.js +30 -30
- package/lib/steps/index.js +35 -32
- package/lib/switch/index.js +25 -25
- package/lib/table/index.js +50 -44
- package/lib/table/style/table.css +1 -1
- package/lib/table-popup/index.js +43 -37
- package/lib/table-popup/style/table-popup.css +1 -1
- package/lib/tabs/index.js +35 -32
- package/lib/text/index.js +39 -39
- package/lib/tile-layer/index.js +35 -36
- package/lib/time-line/index.js +41 -43
- package/lib/time-picker/index.js +27 -27
- package/lib/time-range/index.js +53 -55
- package/lib/time-slider/index.js +73 -75
- package/lib/time-text/index.js +31 -31
- package/lib/tooltip/index.js +25 -25
- package/lib/tooltip/style/tooltip.css +1 -0
- package/lib/transfer/index.js +27 -27
- package/lib/tree/index.js +48 -42
- package/lib/tree-select/index.js +37 -34
- package/lib/video-player/index.js +98 -97
- package/lib/video-player/style/video-player.css +1 -1
- package/lib/web-map/index.js +2336 -103
- package/package.json +2 -4
- package/src/common/_assets/iconfont/icon-sm-components.css +21 -7
- package/src/common/_assets/iconfont/icon-sm-components.ttf +0 -0
- package/src/common/_assets/iconfont/icon-sm-components.woff +0 -0
- package/src/common/_assets/iconfont/icon-sm-components.woff2 +0 -0
- package/src/common/_lang/en.js +19 -8
- package/src/common/_lang/zh.js +18 -6
- package/src/common/_mixin/Card.ts +1 -1
- package/src/common/_types/iPortalDataParameter.js +1 -0
- package/src/common/_types/iServerBaseParameter.ts +3 -0
- package/src/common/_utils/epsg-define.js +32 -27
- package/src/common/_utils/get-features.js +13 -2
- package/src/common/_utils/iPortalDataService.js +14 -3
- package/src/common/_utils/iServerRestService.js +144 -78
- package/src/common/_utils/statistics.js +6 -14
- package/src/common/_utils/style/theme/theme.json +6 -6
- package/src/common/attribute-panel/AttributePanel.vue +58 -0
- package/src/common/attribute-panel/__test__/AttributePanel.spec.js +39 -0
- package/src/common/attribute-panel/index.js +9 -0
- package/src/common/attribute-panel/style/attribute-panel.scss +35 -0
- package/src/common/attribute-panel/style/index.js +4 -0
- package/src/common/collapse-card/style/collapse-card.scss +2 -2
- package/src/common/iframe/Iframe.vue +1 -1
- package/src/common/image/Image.vue +68 -6
- package/src/common/image/style/image.scss +32 -0
- package/src/common/message/style/message.scss +1 -0
- package/src/common/modal/style/modal.scss +36 -0
- package/src/common/notification/style/notification.scss +9 -0
- package/src/common/slideshow/Slideshow.vue +42 -95
- package/src/common/slideshow/Swiper.js +1 -1
- package/src/common/table/style/table.scss +36 -0
- package/src/common/table-popup/TablePopup.vue +5 -0
- package/src/common/tooltip/style/tooltip.scss +3 -0
- package/src/common/video-player/style/video-player.scss +1 -1
- package/src/leaflet/entrys.json +0 -2
- package/src/leaflet/package.json +2 -4
- package/src/leaflet/web-map/WebMap.vue +4 -4
- package/src/leaflet/web-map/WebMapViewModel.ts +64 -17
- package/static/libs/iclient-common/iclient-common-webmapv2base.js +2 -0
- package/static/libs/iclient-common/iclient-common.js +1 -1
- package/static/libs/iclient-leaflet/iclient-leaflet.min.js +5 -1738
- package/lib/_assets/iconfont/icon-sm-components.eot +0 -0
- package/lib/_assets/iconfont/icon-sm-components.svg +0 -197
- package/lib/_mixin/WebMapBase.js +0 -3467
- package/lib/_utils/WebMapService.js +0 -1607
- package/src/common/_assets/iconfont/icon-sm-components.eot +0 -0
- package/src/common/_assets/iconfont/icon-sm-components.svg +0 -197
- package/src/common/_utils/WebMapService.ts +0 -1292
- package/src/common/web-map/WebMapBase.ts +0 -1178
- package/src/common/web-map/config/MunicipalCenter.json +0 -1
- package/src/common/web-map/config/ProvinceCenter.json +0 -1
|
@@ -1,22 +1,36 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="sm-component-image" :style="[getBackgroundStyle, getTextColorStyle]">
|
|
3
|
-
<a
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
<div v-if="src" class="sm-component-image__content" :style="[repeatStyle,imgUrl]"></div>
|
|
3
|
+
<a :class="['sm-component-image__link']" :href="realHref" @click="handleLinkClick" :target="target">
|
|
4
|
+
<div v-if="src" @click="startPreview" class="sm-component-image__content" :style="[repeatStyle, imgUrl]">
|
|
5
|
+
<!-- 用img标签确保没有给定宽高时,能使用src图片的宽高 -->
|
|
6
|
+
<img :src="src" style="visibility: hidden; max-width: 100%; max-height: 100%" />
|
|
7
|
+
</div>
|
|
9
8
|
<i v-else class="sm-components-icon-tupian sm-component-image__defaultImg"></i>
|
|
10
9
|
</a>
|
|
10
|
+
<sm-modal
|
|
11
|
+
v-model="previewVisible"
|
|
12
|
+
:zIndex="1009"
|
|
13
|
+
centered
|
|
14
|
+
width="50%"
|
|
15
|
+
:dialogClass="fullScreenStyle.dialogClass"
|
|
16
|
+
:dialogStyle="fullScreenStyle.dialogStyle"
|
|
17
|
+
:bodyStyle="fullScreenStyle.bodyStyle"
|
|
18
|
+
:footer="null"
|
|
19
|
+
>
|
|
20
|
+
<img :src="src" @click="endPreview" :style="{ 'object-fit': 'contain', width: '100%', height: '100%' }" />
|
|
21
|
+
</sm-modal>
|
|
11
22
|
</div>
|
|
12
23
|
</template>
|
|
13
24
|
|
|
14
25
|
<script>
|
|
15
26
|
import Theme from 'vue-iclient/src/common/_mixin/Theme';
|
|
16
27
|
import { parseUrl } from 'vue-iclient/src/common/_utils/util';
|
|
28
|
+
import SmModal from 'vue-iclient/src/common/modal/Modal.vue';
|
|
29
|
+
import Message from 'vue-iclient/src/common/message/index.js';
|
|
17
30
|
|
|
18
31
|
export default {
|
|
19
32
|
name: 'SmImage',
|
|
33
|
+
components: { SmModal },
|
|
20
34
|
mixins: [Theme],
|
|
21
35
|
props: {
|
|
22
36
|
src: {
|
|
@@ -30,6 +44,10 @@ export default {
|
|
|
30
44
|
type: String,
|
|
31
45
|
default: ''
|
|
32
46
|
},
|
|
47
|
+
previewMode: {
|
|
48
|
+
type: String,
|
|
49
|
+
default: 'none'
|
|
50
|
+
},
|
|
33
51
|
target: {
|
|
34
52
|
type: String,
|
|
35
53
|
default: '_self'
|
|
@@ -37,12 +55,18 @@ export default {
|
|
|
37
55
|
},
|
|
38
56
|
data() {
|
|
39
57
|
return {
|
|
58
|
+
previewVisible: false,
|
|
40
59
|
repeatOption: {
|
|
41
60
|
center: {
|
|
42
61
|
backgroundRepeat: 'no-repeat',
|
|
43
62
|
backgroundPosition: 'center',
|
|
44
63
|
backgroundSize: 'contain'
|
|
45
64
|
},
|
|
65
|
+
left: {
|
|
66
|
+
backgroundRepeat: 'no-repeat',
|
|
67
|
+
backgroundPosition: 'left center',
|
|
68
|
+
backgroundSize: 'contain'
|
|
69
|
+
},
|
|
46
70
|
noRepeat: {
|
|
47
71
|
backgroundSize: '100% 100%',
|
|
48
72
|
backgroundRepeat: 'no-repeat'
|
|
@@ -63,6 +87,27 @@ export default {
|
|
|
63
87
|
};
|
|
64
88
|
},
|
|
65
89
|
computed: {
|
|
90
|
+
fullScreenStyle() {
|
|
91
|
+
return this.previewMode === 'full'
|
|
92
|
+
? {
|
|
93
|
+
dialogStyle: {
|
|
94
|
+
backgroundColor: 'transparent',
|
|
95
|
+
height: '100%'
|
|
96
|
+
},
|
|
97
|
+
dialogClass: 'sm-component-image__full',
|
|
98
|
+
bodyStyle: {
|
|
99
|
+
padding: 0,
|
|
100
|
+
width: '100%',
|
|
101
|
+
height: '100%'
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
: {
|
|
105
|
+
dialogClass: 'sm-component-image__preview',
|
|
106
|
+
bodyStyle: {
|
|
107
|
+
padding: 0
|
|
108
|
+
}
|
|
109
|
+
};
|
|
110
|
+
},
|
|
66
111
|
repeatStyle() {
|
|
67
112
|
return this.repeatOption[this.repeat];
|
|
68
113
|
},
|
|
@@ -78,6 +123,23 @@ export default {
|
|
|
78
123
|
}
|
|
79
124
|
return href;
|
|
80
125
|
}
|
|
126
|
+
},
|
|
127
|
+
methods: {
|
|
128
|
+
handleLinkClick(e) {
|
|
129
|
+
if (!this.href) {
|
|
130
|
+
e.preventDefault();
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
startPreview() {
|
|
134
|
+
if (this.previewMode === 'none') {
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
Message.info(this.previewMode === 'popup' ? this.$t('info.pressEscToExit') : this.$t('info.pressEscOrClickToExit'), 3);
|
|
138
|
+
this.previewVisible = true;
|
|
139
|
+
},
|
|
140
|
+
endPreview() {
|
|
141
|
+
this.previewVisible = false;
|
|
142
|
+
}
|
|
81
143
|
}
|
|
82
144
|
};
|
|
83
145
|
</script>
|
|
@@ -17,6 +17,38 @@
|
|
|
17
17
|
cursor: pointer;
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
|
+
@include e(preview) {
|
|
21
|
+
.sm-component-modal-content {
|
|
22
|
+
.sm-component-modal-close {
|
|
23
|
+
margin-left: -64px;
|
|
24
|
+
.sm-component-modal-close-x {
|
|
25
|
+
font-size: 40px;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
@include e(full) {
|
|
32
|
+
width: 100% !important;
|
|
33
|
+
padding: 0 !important;
|
|
34
|
+
.sm-component-modal-content {
|
|
35
|
+
background-color: transparent !important;
|
|
36
|
+
box-shadow: none !important;
|
|
37
|
+
width: 100%;
|
|
38
|
+
height: 100%;
|
|
39
|
+
.sm-component-modal-close {
|
|
40
|
+
display: none;
|
|
41
|
+
}
|
|
42
|
+
.sm-component-modal-close {
|
|
43
|
+
margin-left: -64px;
|
|
44
|
+
.sm-component-modal-close-x {
|
|
45
|
+
font-size: 40px;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
20
52
|
@include e(noLink){
|
|
21
53
|
pointer-events: none;
|
|
22
54
|
}
|
|
@@ -3,12 +3,32 @@
|
|
|
3
3
|
@import '../../_utils/style/theme/theme.scss';
|
|
4
4
|
|
|
5
5
|
@include b (modal) {
|
|
6
|
+
$modal-prefix: &;
|
|
7
|
+
|
|
6
8
|
@include e(content, '-') {
|
|
7
9
|
background-color: $modal-content-bg;
|
|
10
|
+
|
|
11
|
+
#{$modal-prefix}-header {
|
|
12
|
+
padding: 14px 24px;
|
|
13
|
+
border-color: $border-color-secondary;
|
|
14
|
+
#{$modal-prefix}-title {
|
|
15
|
+
line-height: 24px;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
#{$modal-prefix}-footer {
|
|
19
|
+
padding: 10px 24px;
|
|
20
|
+
border-color: $border-color-secondary;
|
|
21
|
+
}
|
|
8
22
|
}
|
|
9
23
|
|
|
10
24
|
@include e(close, '-') {
|
|
11
25
|
color: $text-color-secondary;
|
|
26
|
+
&-x {
|
|
27
|
+
line-height: 52px;
|
|
28
|
+
height: 52px;
|
|
29
|
+
width: 64px;
|
|
30
|
+
}
|
|
31
|
+
|
|
12
32
|
}
|
|
13
33
|
|
|
14
34
|
@include e(confirm, '-') {
|
|
@@ -19,5 +39,21 @@
|
|
|
19
39
|
&-confirm &-body > .#{$iconfont-css-prefix} {
|
|
20
40
|
color: $warning-color;
|
|
21
41
|
}
|
|
42
|
+
&-body &-title {
|
|
43
|
+
line-height: 24px;
|
|
44
|
+
}
|
|
45
|
+
&-body {
|
|
46
|
+
.#{$iconfont-css-prefix} {
|
|
47
|
+
margin-right: 12px;
|
|
48
|
+
font-size: 24px;
|
|
49
|
+
|
|
50
|
+
+ #{$modal-prefix}-title + #{$modal-prefix}-content {
|
|
51
|
+
margin-left: 36px;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
#{$modal-prefix}-body {
|
|
56
|
+
padding: 20px 24px;
|
|
57
|
+
}
|
|
22
58
|
}
|
|
23
59
|
}
|
|
@@ -3,7 +3,9 @@
|
|
|
3
3
|
|
|
4
4
|
@include b(notification) {
|
|
5
5
|
&-notice {
|
|
6
|
+
$notice-prefix: &;
|
|
6
7
|
background: $message-background;
|
|
8
|
+
padding: 20px 24px 24px;
|
|
7
9
|
|
|
8
10
|
&-message {
|
|
9
11
|
color: $heading-color;
|
|
@@ -11,6 +13,7 @@
|
|
|
11
13
|
|
|
12
14
|
@at-root {
|
|
13
15
|
.#{$iconfont-css-prefix}#{&}-icon {
|
|
16
|
+
margin-left: 0;
|
|
14
17
|
&-warning {
|
|
15
18
|
color: $warning-color;
|
|
16
19
|
}
|
|
@@ -26,5 +29,11 @@
|
|
|
26
29
|
color: $text-color;
|
|
27
30
|
}
|
|
28
31
|
}
|
|
32
|
+
|
|
33
|
+
&-with-icon {
|
|
34
|
+
#{$notice-prefix}-message, #{$notice-prefix}-description {
|
|
35
|
+
margin-left: 36px;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
29
38
|
}
|
|
30
39
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
-
import type { CreateElement
|
|
2
|
+
import type { CreateElement } from 'vue';
|
|
3
3
|
import Theme from 'vue-iclient/src/common/_mixin/Theme';
|
|
4
4
|
import Swiper from './Swiper';
|
|
5
5
|
import BaseCard from 'vue-iclient/src/common/_mixin/Card';
|
|
@@ -11,22 +11,23 @@ import { addListener, removeListener } from 'resize-detector';
|
|
|
11
11
|
import 'swiper/swiper-bundle.min.css';
|
|
12
12
|
|
|
13
13
|
interface swiperOptionsType {
|
|
14
|
-
initialSlide:
|
|
15
|
-
direction:
|
|
16
|
-
speed:
|
|
17
|
-
loopedSlides:
|
|
18
|
-
loop:
|
|
19
|
-
grabCursor:
|
|
20
|
-
mousewheel:
|
|
21
|
-
keyboard:
|
|
22
|
-
autoplay:
|
|
23
|
-
effect:
|
|
14
|
+
initialSlide: number;
|
|
15
|
+
direction: string;
|
|
16
|
+
speed: number;
|
|
17
|
+
loopedSlides: number;
|
|
18
|
+
loop: boolean;
|
|
19
|
+
grabCursor: boolean;
|
|
20
|
+
mousewheel: boolean;
|
|
21
|
+
keyboard: boolean;
|
|
22
|
+
autoplay: boolean | Object;
|
|
23
|
+
effect: string;
|
|
24
24
|
navigation?: Object;
|
|
25
25
|
pagination?: Object;
|
|
26
26
|
scrollbar?: Object;
|
|
27
|
-
observer:
|
|
28
|
-
observeParents:
|
|
29
|
-
observeSlideChildren:
|
|
27
|
+
observer: boolean;
|
|
28
|
+
observeParents: boolean;
|
|
29
|
+
observeSlideChildren: boolean;
|
|
30
|
+
on: Object;
|
|
30
31
|
}
|
|
31
32
|
|
|
32
33
|
@Component({
|
|
@@ -39,7 +40,7 @@ interface swiperOptionsType {
|
|
|
39
40
|
class Slideshow extends Mixins(Theme, BaseCard) {
|
|
40
41
|
__resizeHandler: Function;
|
|
41
42
|
swiper: any;
|
|
42
|
-
|
|
43
|
+
swiperCmptKey: number = +new Date();
|
|
43
44
|
manualUpdateProps: string[] = [
|
|
44
45
|
'speed',
|
|
45
46
|
'loop',
|
|
@@ -52,8 +53,6 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
52
53
|
'direction'
|
|
53
54
|
];
|
|
54
55
|
|
|
55
|
-
activeIndexData: number = 0;
|
|
56
|
-
|
|
57
56
|
// 当 loop 为 true && effect 为 cube, 幻灯片页数等于3会出现重叠。
|
|
58
57
|
loopedSlides: number = 3;
|
|
59
58
|
|
|
@@ -89,7 +88,7 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
89
88
|
|
|
90
89
|
get swiperOptions() {
|
|
91
90
|
let options: swiperOptionsType = {
|
|
92
|
-
initialSlide: this.defaultActiveIndex,
|
|
91
|
+
initialSlide: this.activeIndex ?? this.defaultActiveIndex,
|
|
93
92
|
direction: this.direction,
|
|
94
93
|
speed: this.speed,
|
|
95
94
|
loop: this.loop,
|
|
@@ -101,7 +100,10 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
101
100
|
effect: this.effect,
|
|
102
101
|
observer: true,
|
|
103
102
|
observeParents: true,
|
|
104
|
-
observeSlideChildren: true
|
|
103
|
+
observeSlideChildren: true,
|
|
104
|
+
on: {
|
|
105
|
+
init: this.slideInit
|
|
106
|
+
}
|
|
105
107
|
};
|
|
106
108
|
this.navigation && (options.navigation = this.navigation);
|
|
107
109
|
this.pagination && (options.pagination = this.pagination);
|
|
@@ -134,13 +136,7 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
134
136
|
this.autoResizeHandler();
|
|
135
137
|
}
|
|
136
138
|
|
|
137
|
-
created() {
|
|
138
|
-
this.activeIndexData = this.defaultActiveIndex || this.activeIndex;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
139
|
mounted() {
|
|
142
|
-
// @ts-ignore
|
|
143
|
-
this.swiper = this.$refs.mySwiper.$swiper;
|
|
144
140
|
this.watchOptions();
|
|
145
141
|
this.autoResizeHandler();
|
|
146
142
|
}
|
|
@@ -150,6 +146,12 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
150
146
|
removeListener(this.$el, this.__resizeHandler);
|
|
151
147
|
}
|
|
152
148
|
|
|
149
|
+
slideInit(swiper: any) {
|
|
150
|
+
this.swiper = swiper;
|
|
151
|
+
this.goTo(this.swiperOptions.initialSlide, 0);
|
|
152
|
+
this.$emit('init', swiper);
|
|
153
|
+
}
|
|
154
|
+
|
|
153
155
|
slideChange() {
|
|
154
156
|
let changeParameter = {
|
|
155
157
|
progress: this.swiper.progress,
|
|
@@ -159,62 +161,11 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
159
161
|
};
|
|
160
162
|
this.$emit('change', changeParameter);
|
|
161
163
|
this.$emit('indexChange', this.swiper.realIndex);
|
|
162
|
-
this.activeIndexData = this.swiper.realIndex;
|
|
163
164
|
}
|
|
164
165
|
|
|
165
166
|
_activeIndexChangedHandler(newIndex: number) {
|
|
166
|
-
const prevActiveIndexData = this.activeIndexData;
|
|
167
|
-
if (prevActiveIndexData === newIndex) {
|
|
168
|
-
return;
|
|
169
|
-
}
|
|
170
|
-
this.activeIndexData = newIndex;
|
|
171
|
-
if (this.loop) {
|
|
172
|
-
const changeType = this._getChangeType(newIndex, prevActiveIndexData);
|
|
173
|
-
if (['next', 'loopToFirst'].includes(changeType)) {
|
|
174
|
-
this.next();
|
|
175
|
-
return;
|
|
176
|
-
}
|
|
177
|
-
if (['prev', 'loopToLast'].includes(changeType)) {
|
|
178
|
-
this.prev();
|
|
179
|
-
return;
|
|
180
|
-
}
|
|
181
|
-
}
|
|
182
|
-
this.goTo(newIndex, this.speed);
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
_getChangeType(newIndex, oldIndex) {
|
|
186
|
-
const childrenLength = this._getChildrenLength();
|
|
187
|
-
const offset = newIndex - oldIndex;
|
|
188
|
-
if (offset === 1) {
|
|
189
|
-
return 'next';
|
|
190
|
-
}
|
|
191
|
-
if (offset === -1) {
|
|
192
|
-
return 'prev';
|
|
193
|
-
}
|
|
194
|
-
if (oldIndex === childrenLength - 1 && newIndex === 0) {
|
|
195
|
-
return 'loopToFirst';
|
|
196
|
-
}
|
|
197
|
-
if (oldIndex === 0 && newIndex === childrenLength - 1) {
|
|
198
|
-
return 'loopToLast';
|
|
199
|
-
}
|
|
200
|
-
return 'jump';
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
_observerUpdate(swiper, mutationRecord) {
|
|
204
|
-
if (mutationRecord.type === 'childList') {
|
|
205
|
-
this.goTo(this.activeIndexData, 0);
|
|
206
|
-
this.$emit('childrenlistchange');
|
|
207
|
-
}
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
_reload() {
|
|
211
|
-
this.isRefresh = false;
|
|
212
167
|
this.$nextTick(() => {
|
|
213
|
-
this.
|
|
214
|
-
this.$nextTick(() => {
|
|
215
|
-
// @ts-ignore
|
|
216
|
-
this.swiper = this.$refs.mySwiper.$swiper;
|
|
217
|
-
});
|
|
168
|
+
this.goTo(newIndex, 0);
|
|
218
169
|
});
|
|
219
170
|
}
|
|
220
171
|
|
|
@@ -231,7 +182,7 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
231
182
|
this.swiper.slidePrev(speed);
|
|
232
183
|
}
|
|
233
184
|
|
|
234
|
-
goTo(index: number, speed
|
|
185
|
+
goTo(index: number, speed: number) {
|
|
235
186
|
if (this.swiper) {
|
|
236
187
|
this.loop ? this.swiper.slideToLoop(index, speed) : this.swiper.slideTo(index, speed);
|
|
237
188
|
}
|
|
@@ -255,7 +206,7 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
255
206
|
item,
|
|
256
207
|
function (newVal, oldVal) {
|
|
257
208
|
if (!isequal(newVal, oldVal)) {
|
|
258
|
-
this.
|
|
209
|
+
this.swiperCmptKey = +new Date();
|
|
259
210
|
}
|
|
260
211
|
},
|
|
261
212
|
{ deep: true }
|
|
@@ -313,23 +264,19 @@ class Slideshow extends Mixins(Theme, BaseCard) {
|
|
|
313
264
|
textColor: this.textColor,
|
|
314
265
|
splitLine: this.splitLine
|
|
315
266
|
};
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
{
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
on: {
|
|
325
|
-
slideChange: this.slideChange,
|
|
326
|
-
observerUpdate: this._observerUpdate
|
|
327
|
-
},
|
|
328
|
-
ref: 'mySwiper'
|
|
267
|
+
const SwiperCompt = h(
|
|
268
|
+
// @ts-ignore
|
|
269
|
+
Swiper,
|
|
270
|
+
{
|
|
271
|
+
domProps: { realIndex: this.activeIndex },
|
|
272
|
+
props: { options: this.swiperOptions },
|
|
273
|
+
on: {
|
|
274
|
+
slideChange: this.slideChange
|
|
329
275
|
},
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
276
|
+
key: this.swiperCmptKey
|
|
277
|
+
},
|
|
278
|
+
slots
|
|
279
|
+
);
|
|
333
280
|
return h(
|
|
334
281
|
'sm-collapse-card',
|
|
335
282
|
{
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
&-thead > tr > th {
|
|
9
9
|
background: $table-header-bg;
|
|
10
|
+
position: relative;
|
|
10
11
|
// .#{$iconfont-css-prefix}-filter,
|
|
11
12
|
// #{$table-prefix}-filter-icon {
|
|
12
13
|
// color: $table-header-icon-color;
|
|
@@ -116,6 +117,41 @@
|
|
|
116
117
|
}
|
|
117
118
|
}
|
|
118
119
|
}
|
|
120
|
+
&:not(&-bordered) {
|
|
121
|
+
#{$table-prefix}-thead > tr > th::after {
|
|
122
|
+
content: "";
|
|
123
|
+
position: absolute;
|
|
124
|
+
top: 50%;
|
|
125
|
+
right: 0;
|
|
126
|
+
width: 1px;
|
|
127
|
+
height: 14px;
|
|
128
|
+
background-color: $border-color-secondary;
|
|
129
|
+
transform: translateY(-50%);
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
&-thead > tr > th,
|
|
134
|
+
&-tbody > tr > td {
|
|
135
|
+
padding: 13px 24px;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
&-middle {
|
|
139
|
+
> #{$table-prefix}-content > #{$table-prefix}-body > table {
|
|
140
|
+
> #{$table-prefix}-thead > tr > th,
|
|
141
|
+
> #{$table-prefix}-tbody > tr > td {
|
|
142
|
+
padding: 9px 24px;
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
&-small {
|
|
148
|
+
> #{$table-prefix}-content > #{$table-prefix}-body > table {
|
|
149
|
+
> #{$table-prefix}-thead > tr > th,
|
|
150
|
+
> #{$table-prefix}-tbody > tr > td {
|
|
151
|
+
padding: 5px 24px;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
}
|
|
119
155
|
|
|
120
156
|
// &-selection {
|
|
121
157
|
// .#{$iconfont-css-prefix}-down {
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
:columns="columns"
|
|
10
10
|
:rowKey="(record, index) => index"
|
|
11
11
|
:pagination="false"
|
|
12
|
+
:showHeader="showHeader"
|
|
12
13
|
/>
|
|
13
14
|
</div>
|
|
14
15
|
</template>
|
|
@@ -39,6 +40,10 @@ export default {
|
|
|
39
40
|
splitLine: {
|
|
40
41
|
type: Boolean,
|
|
41
42
|
default: true
|
|
43
|
+
},
|
|
44
|
+
showHeader: {
|
|
45
|
+
type: Boolean,
|
|
46
|
+
default: true
|
|
42
47
|
}
|
|
43
48
|
},
|
|
44
49
|
watch: {
|
|
@@ -226,6 +226,7 @@
|
|
|
226
226
|
}
|
|
227
227
|
}
|
|
228
228
|
.sm-component-video-player-modal {
|
|
229
|
+
background: rgba(0, 0, 0, 0.7);
|
|
229
230
|
.sm-component-modal-close {
|
|
230
231
|
color: #a2a3a5;
|
|
231
232
|
right: -5%;
|
|
@@ -257,7 +258,6 @@
|
|
|
257
258
|
}
|
|
258
259
|
}
|
|
259
260
|
}
|
|
260
|
-
background: rgba(0, 0, 0, 0.7);
|
|
261
261
|
}
|
|
262
262
|
.sm-component-video-full-fill{
|
|
263
263
|
video{
|
package/src/leaflet/entrys.json
CHANGED
|
@@ -59,7 +59,6 @@
|
|
|
59
59
|
"_mixin/ThirdService": "vue-iclient/src/common/_mixin/ThirdService.ts",
|
|
60
60
|
"_mixin/Timer": "vue-iclient/src/common/_mixin/Timer.ts",
|
|
61
61
|
"_mixin/VmUpdater": "vue-iclient/src/common/_mixin/VmUpdater.ts",
|
|
62
|
-
"_mixin/WebMapBase": "vue-iclient/src/common/web-map/WebMapBase.ts",
|
|
63
62
|
"_mixin/GridLayer": "vue-iclient/src/leaflet/_mixin/GridLayer.js",
|
|
64
63
|
"_mixin/Layer": "vue-iclient/src/leaflet/_mixin/Layer.js",
|
|
65
64
|
"_mixin/map-getter": "vue-iclient/src/leaflet/_mixin/map-getter.ts",
|
|
@@ -93,7 +92,6 @@
|
|
|
93
92
|
"_utils/RestService": "vue-iclient/src/common/_utils/RestService.js",
|
|
94
93
|
"_utils/statistics": "vue-iclient/src/common/_utils/statistics.js",
|
|
95
94
|
"_utils/util": "vue-iclient/src/common/_utils/util.js",
|
|
96
|
-
"_utils/WebMapService": "vue-iclient/src/common/_utils/WebMapService.ts",
|
|
97
95
|
"_utils/vue-types/index": "vue-iclient/src/common/_utils/vue-types/index.js",
|
|
98
96
|
"_utils/vue-types/utils": "vue-iclient/src/common/_utils/vue-types/utils.js",
|
|
99
97
|
"_utils/style/theme/chart": "vue-iclient/src/common/_utils/style/theme/chart.js",
|
package/src/leaflet/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@supermapgis/vue-iclient-leaflet",
|
|
3
3
|
"description": "SuperMap iClient for Vue.js",
|
|
4
|
-
"version": "11.
|
|
4
|
+
"version": "11.3.0",
|
|
5
5
|
"homepage": "http://iclient.supermap.io",
|
|
6
6
|
"main": "lib/index",
|
|
7
7
|
"dependencies": {
|
|
@@ -13,7 +13,6 @@
|
|
|
13
13
|
"@turf/length": "^6.0.2",
|
|
14
14
|
"@turf/rhumb-bearing": "^6.0.1",
|
|
15
15
|
"@turf/transform-scale": "^5.1.5",
|
|
16
|
-
"@turf/meta": "^6.5.0",
|
|
17
16
|
"@types/geojson": "^7946.0.7",
|
|
18
17
|
"@types/leaflet": "^1.5.5",
|
|
19
18
|
"@types/node": "^12.0.3",
|
|
@@ -40,14 +39,13 @@
|
|
|
40
39
|
"lodash.isnumber": "^3.0.3",
|
|
41
40
|
"lodash.isplainobject": "^4.0.6",
|
|
42
41
|
"lodash.max": "^4.0.1",
|
|
43
|
-
"lodash.min": "^4.0.1",
|
|
44
42
|
"lodash.merge": "^4.6.1",
|
|
45
43
|
"lodash.orderby": "^4.6.0",
|
|
46
44
|
"lodash.tonumber": "^4.0.3",
|
|
47
45
|
"lodash.uniqueid": "^4.0.1",
|
|
48
46
|
"mux.js": "^5.6.7",
|
|
49
47
|
"omit.js": "^2.0.2",
|
|
50
|
-
"proj4": "^2.
|
|
48
|
+
"proj4": "^2.8.0",
|
|
51
49
|
"resize-detector": "^0.2.0",
|
|
52
50
|
"simple-statistics": "^7.8.3",
|
|
53
51
|
"swiper": "^6.8.4",
|
|
@@ -165,7 +165,7 @@ class SmWebMap extends Mixins(VmUpdater, MapEvents) {
|
|
|
165
165
|
*/
|
|
166
166
|
this.load({ map: e.map });
|
|
167
167
|
},
|
|
168
|
-
|
|
168
|
+
mapcreatefailed: e => {
|
|
169
169
|
/**
|
|
170
170
|
* @event getMapFailed
|
|
171
171
|
* @desc 获取 WebMap 地图信息失败。
|
|
@@ -176,7 +176,7 @@ class SmWebMap extends Mixins(VmUpdater, MapEvents) {
|
|
|
176
176
|
Message.error(e.error.message);
|
|
177
177
|
this.spinning = false;
|
|
178
178
|
},
|
|
179
|
-
|
|
179
|
+
layercreatefailed: e => {
|
|
180
180
|
/**
|
|
181
181
|
* @event getLayerDatasourceFailed
|
|
182
182
|
* @desc 获取图层数据失败。
|
|
@@ -193,9 +193,9 @@ class SmWebMap extends Mixins(VmUpdater, MapEvents) {
|
|
|
193
193
|
Message.error(this.$t('webmap.getLayerInfoFailed'));
|
|
194
194
|
}
|
|
195
195
|
},
|
|
196
|
-
|
|
196
|
+
mvtnotsupport: () => {
|
|
197
197
|
// @ts-ignore
|
|
198
|
-
Message.error('
|
|
198
|
+
Message.error(this.$t('webmap.mvtNotSupport'));
|
|
199
199
|
this.spinning = false;
|
|
200
200
|
}
|
|
201
201
|
});
|