vue-openlayers-plugin 1.0.73 → 1.0.74
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/lib/{index-363194c0.mjs → index-e0d64ecc.mjs} +450 -300
- package/lib/{index.es-a7ad7c48.mjs → index.es-4f33fe12.mjs} +1 -1
- package/lib/index.esm.js +1 -1
- package/lib/index.umd.js +450 -299
- package/lib/style.css +114 -0
- package/package.json +1 -1
- package/types/src/components/CustomOpenlayer/components/OlBaseLayerSwitcher.vue.d.ts +19 -0
- package/types/src/components/CustomOpenlayer/components/OlBaseLayerSwitcher.vue.d.ts.map +1 -0
package/lib/style.css
CHANGED
|
@@ -2399,6 +2399,120 @@ label {
|
|
|
2399
2399
|
}
|
|
2400
2400
|
}
|
|
2401
2401
|
|
|
2402
|
+
.ol-base-layer-switcher[data-v-396e5ed1] {
|
|
2403
|
+
position: absolute;
|
|
2404
|
+
bottom: 20px;
|
|
2405
|
+
right: 20px;
|
|
2406
|
+
z-index: 100;
|
|
2407
|
+
height: 70px; /* 60px + 5px padding * 2 */
|
|
2408
|
+
background: #fff;
|
|
2409
|
+
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
|
2410
|
+
border-radius: 4px;
|
|
2411
|
+
padding: 5px;
|
|
2412
|
+
box-sizing: border-box;
|
|
2413
|
+
transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
2414
|
+
overflow: hidden;
|
|
2415
|
+
/* 即使内容还没出来,也要从右边开始长出来 */
|
|
2416
|
+
display: flex;
|
|
2417
|
+
justify-content: flex-end;
|
|
2418
|
+
}
|
|
2419
|
+
|
|
2420
|
+
/* 列表面板 */
|
|
2421
|
+
.layer-panel[data-v-396e5ed1] {
|
|
2422
|
+
display: flex;
|
|
2423
|
+
gap: 10px;
|
|
2424
|
+
height: 100%;
|
|
2425
|
+
/* 绝对定位以防止宽度变化时的挤压,或者使用flex布局 */
|
|
2426
|
+
min-width: max-content;
|
|
2427
|
+
}
|
|
2428
|
+
|
|
2429
|
+
/* 收起状态的触发器 */
|
|
2430
|
+
.layer-trigger[data-v-396e5ed1] {
|
|
2431
|
+
position: absolute;
|
|
2432
|
+
right: 5px;
|
|
2433
|
+
top: 5px;
|
|
2434
|
+
width: 86px;
|
|
2435
|
+
height: 60px;
|
|
2436
|
+
pointer-events: none; /* 让鼠标事件穿透到底下的 panel */
|
|
2437
|
+
transition: opacity 0.2s;
|
|
2438
|
+
z-index: 10;
|
|
2439
|
+
background: #fff; /* 遮挡下面的列表 */
|
|
2440
|
+
}
|
|
2441
|
+
.layer-trigger.is-hidden[data-v-396e5ed1] {
|
|
2442
|
+
opacity: 0;
|
|
2443
|
+
pointer-events: none;
|
|
2444
|
+
}
|
|
2445
|
+
|
|
2446
|
+
/* 通用图层项样式 */
|
|
2447
|
+
.layer-item[data-v-396e5ed1], .current-layer-box[data-v-396e5ed1] {
|
|
2448
|
+
width: 86px;
|
|
2449
|
+
height: 60px;
|
|
2450
|
+
border-radius: 2px;
|
|
2451
|
+
background-size: cover;
|
|
2452
|
+
background-position: center;
|
|
2453
|
+
position: relative;
|
|
2454
|
+
box-sizing: border-box;
|
|
2455
|
+
border: 1px solid #e4e7ed;
|
|
2456
|
+
cursor: pointer;
|
|
2457
|
+
transition: all 0.2s;
|
|
2458
|
+
overflow: hidden;
|
|
2459
|
+
}
|
|
2460
|
+
.layer-item[data-v-396e5ed1]:hover {
|
|
2461
|
+
border-color: #409eff;
|
|
2462
|
+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12);
|
|
2463
|
+
}
|
|
2464
|
+
.layer-item.active[data-v-396e5ed1] {
|
|
2465
|
+
border: 2px solid #409eff;
|
|
2466
|
+
}
|
|
2467
|
+
|
|
2468
|
+
/* 选中状态的蓝色边框和对勾 */
|
|
2469
|
+
.active-border[data-v-396e5ed1] {
|
|
2470
|
+
position: absolute;
|
|
2471
|
+
top: 0;
|
|
2472
|
+
left: 0;
|
|
2473
|
+
width: 100%;
|
|
2474
|
+
height: 100%;
|
|
2475
|
+
border: 2px solid #409eff;
|
|
2476
|
+
box-sizing: border-box;
|
|
2477
|
+
border-radius: 2px;
|
|
2478
|
+
pointer-events: none;
|
|
2479
|
+
}
|
|
2480
|
+
.check-icon[data-v-396e5ed1] {
|
|
2481
|
+
position: absolute;
|
|
2482
|
+
bottom: 0;
|
|
2483
|
+
right: 0;
|
|
2484
|
+
width: 0;
|
|
2485
|
+
height: 0;
|
|
2486
|
+
border-bottom: 24px solid #409eff;
|
|
2487
|
+
border-left: 24px solid transparent;
|
|
2488
|
+
}
|
|
2489
|
+
.check-icon svg[data-v-396e5ed1] {
|
|
2490
|
+
position: absolute;
|
|
2491
|
+
right: -1px;
|
|
2492
|
+
bottom: -13px;
|
|
2493
|
+
transform: scale(0.7);
|
|
2494
|
+
}
|
|
2495
|
+
|
|
2496
|
+
/* 图层名称标签 */
|
|
2497
|
+
.layer-name[data-v-396e5ed1] {
|
|
2498
|
+
position: absolute;
|
|
2499
|
+
bottom: 0;
|
|
2500
|
+
left: 0;
|
|
2501
|
+
width: 100%;
|
|
2502
|
+
background: rgba(0, 0, 0, 0.6);
|
|
2503
|
+
color: #fff;
|
|
2504
|
+
font-size: 12px;
|
|
2505
|
+
padding: 2px 4px;
|
|
2506
|
+
text-align: center;
|
|
2507
|
+
white-space: nowrap;
|
|
2508
|
+
overflow: hidden;
|
|
2509
|
+
text-overflow: ellipsis;
|
|
2510
|
+
box-sizing: border-box;
|
|
2511
|
+
}
|
|
2512
|
+
.layer-item:hover .layer-name[data-v-396e5ed1] {
|
|
2513
|
+
background: rgba(0, 0, 0, 0.7);
|
|
2514
|
+
}
|
|
2515
|
+
|
|
2402
2516
|
.context-menu {
|
|
2403
2517
|
background: white;
|
|
2404
2518
|
border: 1px solid #dcdfe6;
|
package/package.json
CHANGED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Map } from 'ol';
|
|
2
|
+
import { LayerConfig } from '../types';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
map: Map | undefined;
|
|
6
|
+
baseLayers: LayerConfig[];
|
|
7
|
+
}
|
|
8
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<Props>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToRuntimeProps<Props>>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
9
|
+
export default _default;
|
|
10
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
11
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
12
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
13
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
14
|
+
} : {
|
|
15
|
+
type: import('vue').PropType<T[K]>;
|
|
16
|
+
required: true;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=OlBaseLayerSwitcher.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OlBaseLayerSwitcher.vue.d.ts","sourceRoot":"","sources":["../../../../../src/components/CustomOpenlayer/components/OlBaseLayerSwitcher.vue"],"names":[],"mappings":"AAwCA;AAGA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,IAAI,CAAA;AAC7B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAK3C,UAAU,KAAK;IACb,GAAG,EAAE,GAAG,GAAG,SAAS,CAAA;IACpB,UAAU,EAAE,WAAW,EAAE,CAAA;CAC1B;;AAkTD,wBAMG;AACH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC"}
|