@vcmap/ui 5.0.0-rc.25 → 5.0.0-rc.27
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/build/buildCesium.js +7 -0
- package/config/dev.config.json +4 -0
- package/dist/assets/cesium/ThirdParty/Workers/basis_transcoder.js +21 -0
- package/dist/assets/cesium/ThirdParty/Workers/draco_decoder_nodejs.js +117 -0
- package/dist/assets/cesium/ThirdParty/Workers/package.json +1 -0
- package/dist/assets/cesium/ThirdParty/Workers/pako_deflate.min.js +2 -0
- package/dist/assets/cesium/ThirdParty/Workers/pako_inflate.min.js +2 -0
- package/dist/assets/cesium/ThirdParty/Workers/z-worker-pako.js +1 -0
- package/dist/assets/cesium/ThirdParty/basis_transcoder.wasm +0 -0
- package/dist/assets/cesium/ThirdParty/draco_decoder.wasm +0 -0
- package/dist/assets/cesium/ThirdParty/google-earth-dbroot-parser.js +8337 -0
- package/dist/assets/{cesium.1457fa.js → cesium.82fdbe.js} +4 -4
- package/dist/assets/cesium.js +1 -1
- package/dist/assets/{core.47836f.js → core.df069a.js} +2 -2
- package/dist/assets/core.js +1 -1
- package/dist/assets/index-1cff371d.js +1 -0
- package/dist/assets/ol.js +1 -1
- package/dist/assets/style/icon-marker-blue.534e37.png +0 -0
- package/dist/assets/style/icon-marker-green.0b6a92.png +0 -0
- package/dist/assets/style/icon-marker-o-blue.7b6d62.png +0 -0
- package/dist/assets/style/icon-marker-o-green.c863c0.png +0 -0
- package/dist/assets/style/icon-marker-o-red.93ff58.png +0 -0
- package/dist/assets/style/icon-marker-o.036477.png +0 -0
- package/dist/assets/style/icon-marker-red.313d03.png +0 -0
- package/dist/assets/style/icon-marker.70960f.png +0 -0
- package/dist/assets/style/icon-pin-blue.7be369.png +0 -0
- package/dist/assets/style/icon-pin-green.cbb935.png +0 -0
- package/dist/assets/style/icon-pin-red.3f25b2.png +0 -0
- package/dist/assets/style/icon-pin.b7ce77.png +0 -0
- package/dist/assets/{ui.6ed89d.css → ui.3ed7ff.css} +2 -2
- package/dist/assets/ui.3ed7ff.js +14763 -0
- package/dist/assets/ui.js +1 -1
- package/dist/assets/vue.js +2 -2
- package/dist/assets/{vuetify.d2131d.js → vuetify.614278.js} +1 -1
- package/dist/assets/vuetify.js +2 -2
- package/dist/index.html +1 -1
- package/index.js +19 -1
- package/package.json +1 -1
- package/plugins/@vcmap/create-link/index.js +8 -8
- package/plugins/@vcmap-show-case/collection-manager-example/index.js +6 -1
- package/plugins/@vcmap-show-case/form-inputs-example/FormInputsExample.vue +36 -8
- package/plugins/@vcmap-show-case/form-inputs-example/exampleActions.js +0 -19
- package/plugins/@vcmap-show-case/form-inputs-example/index.js +1 -2
- package/plugins/@vcmap-show-case/style-input-example/README.md +4 -0
- package/plugins/@vcmap-show-case/style-input-example/index.js +42 -0
- package/plugins/@vcmap-show-case/style-input-example/package.json +5 -0
- package/plugins/@vcmap-show-case/style-input-example/styleExample.vue +191 -0
- package/plugins/@vcmap-show-case/window-tester/WindowExample.vue +12 -13
- package/plugins/@vcmap-show-case/window-tester/windowExampleToggleChild.vue +44 -0
- package/public/assets/style/icon-marker-blue.png +0 -0
- package/public/assets/style/icon-marker-green.png +0 -0
- package/public/assets/style/icon-marker-o-blue.png +0 -0
- package/public/assets/style/icon-marker-o-green.png +0 -0
- package/public/assets/style/icon-marker-o-red.png +0 -0
- package/public/assets/style/icon-marker-o.png +0 -0
- package/public/assets/style/icon-marker-red.png +0 -0
- package/public/assets/style/icon-marker.png +0 -0
- package/public/assets/style/icon-pin-blue.png +0 -0
- package/public/assets/style/icon-pin-green.png +0 -0
- package/public/assets/style/icon-pin-red.png +0 -0
- package/public/assets/style/icon-pin.png +0 -0
- package/src/actions/actionHelper.js +1 -0
- package/src/application/VcsApp.vue +11 -4
- package/src/application/VcsNavbar.vue +11 -9
- package/src/components/buttons/VcsActionButtonList.vue +1 -0
- package/src/components/form-inputs-controls/VcsCheckbox.vue +3 -2
- package/src/components/form-inputs-controls/VcsFormSection.vue +59 -9
- package/src/components/form-inputs-controls/VcsLabel.vue +10 -0
- package/src/components/form-inputs-controls/VcsRadioGrid.vue +175 -0
- package/src/components/form-inputs-controls/VcsSelect.vue +3 -0
- package/src/components/form-inputs-controls/VcsTextField.vue +12 -0
- package/src/components/icons/+all.js +4 -0
- package/src/components/icons/EditVerticesIcon.vue +39 -0
- package/src/components/lists/VcsActionList.vue +2 -0
- package/src/components/style/MenuWrapper.vue +138 -0
- package/src/components/style/VcsFillMenu.vue +61 -0
- package/src/components/style/VcsFillSelector.vue +45 -0
- package/src/components/style/VcsImageMenu.vue +84 -0
- package/src/components/style/VcsImageSelector.vue +609 -0
- package/src/components/style/VcsStrokeMenu.vue +73 -0
- package/src/components/style/VcsStrokeSelector.vue +87 -0
- package/src/components/style/VcsTextMenu.vue +81 -0
- package/src/components/style/VcsTextSelector.vue +271 -0
- package/src/components/style/VcsVectorStyleComponent.vue +119 -0
- package/src/components/style/composables.js +84 -0
- package/src/components/tables/VcsDataTable.vue +3 -1
- package/src/components/tables/VcsTable.vue +1 -1
- package/src/contentTree/contentTreeCollection.js +1 -0
- package/src/i18n/de.js +51 -17
- package/src/i18n/en.js +56 -22
- package/src/legend/vcsLegend.vue +7 -5
- package/src/manager/collectionManager/CollectionComponent.vue +9 -17
- package/src/manager/collectionManager/CollectionComponentList.vue +22 -9
- package/src/manager/collectionManager/CollectionManager.vue +20 -1
- package/src/manager/collectionManager/collectionComponent.js +11 -0
- package/src/manager/window/WindowComponent.vue +2 -1
- package/src/manager/window/WindowManager.vue +45 -14
- package/src/manager/window/windowHelper.js +76 -4
- package/src/manager/window/windowManager.js +38 -6
- package/src/styles/_theming.scss +0 -16
- package/src/vcsUiApp.js +1 -0
- package/dist/assets/index-bb372634.js +0 -1
- package/dist/assets/logo-mobile.2d10a6.svg +0 -9
- package/dist/assets/logo.27089a.svg +0 -26
- package/dist/assets/ui.6ed89d.js +0 -13461
- /package/dist/assets/{ol.9e4d23.js → ol.90a5d0.js} +0 -0
- /package/dist/assets/{vue.7327e4.js → vue.537ff3.js} +0 -0
- /package/dist/assets/{vuetify.d2131d.css → vuetify.614278.css} +0 -0
- /package/{public/assets → src}/logo-mobile.svg +0 -0
- /package/{public/assets → src}/logo.svg +0 -0
@@ -0,0 +1,138 @@
|
|
1
|
+
<template>
|
2
|
+
<v-sheet>
|
3
|
+
<div class="d-flex align-center py-1">
|
4
|
+
<VcsCheckbox
|
5
|
+
:value="!!value"
|
6
|
+
@change="handleCheckbox"
|
7
|
+
:disabled="disabled"
|
8
|
+
/>
|
9
|
+
<v-menu
|
10
|
+
:close-on-content-click="false"
|
11
|
+
:close-on-click="false"
|
12
|
+
v-model="isMenuOpen"
|
13
|
+
:absolute="true"
|
14
|
+
:disabled="!value || disabled"
|
15
|
+
min-width="300"
|
16
|
+
max-width="300"
|
17
|
+
>
|
18
|
+
<template #activator="{ on, attrs }">
|
19
|
+
<VcsTooltip :tooltip="name">
|
20
|
+
<template #activator="{ on: tooltipOn, attrs: tooltipAttrs }">
|
21
|
+
<v-card
|
22
|
+
rounded
|
23
|
+
height="24px"
|
24
|
+
width="32px"
|
25
|
+
v-bind="{ ...attrs, ...tooltipAttrs }"
|
26
|
+
v-on="{ ...on, ...tooltipOn }"
|
27
|
+
class="tiled-background"
|
28
|
+
>
|
29
|
+
<slot name="preview" />
|
30
|
+
</v-card>
|
31
|
+
</template>
|
32
|
+
</VcsTooltip>
|
33
|
+
</template>
|
34
|
+
<VcsFormSection
|
35
|
+
:heading="name"
|
36
|
+
:header-actions="[
|
37
|
+
{
|
38
|
+
name: 'reset',
|
39
|
+
title: 'components.style.reset',
|
40
|
+
icon: '$vcsReturn',
|
41
|
+
callback: () => {
|
42
|
+
reset();
|
43
|
+
},
|
44
|
+
},
|
45
|
+
{
|
46
|
+
name: 'close',
|
47
|
+
title: 'components.close',
|
48
|
+
icon: 'mdi-close-thick',
|
49
|
+
callback: () => {
|
50
|
+
close();
|
51
|
+
},
|
52
|
+
},
|
53
|
+
]"
|
54
|
+
>
|
55
|
+
<slot name="content" />
|
56
|
+
</VcsFormSection>
|
57
|
+
</v-menu>
|
58
|
+
<span class="ml-2">{{ $t(name) }}</span>
|
59
|
+
</div>
|
60
|
+
</v-sheet>
|
61
|
+
</template>
|
62
|
+
|
63
|
+
<script>
|
64
|
+
import { ref } from 'vue';
|
65
|
+
import { VSheet, VMenu, VCard } from 'vuetify/lib';
|
66
|
+
import { VcsFormSection, VcsTooltip, VcsCheckbox } from '@vcmap/ui';
|
67
|
+
|
68
|
+
/**
|
69
|
+
* @description A wrapper for style components, that provides:
|
70
|
+
* - a 32 x 24 px preview
|
71
|
+
* - a checkbox that emits null when unchecked and the value of the valueDefault prop when checked again. If the vauleDefault is undefined or null, the valueFallback will be emitted.
|
72
|
+
* - a menu that pops up when clicking the preview. It has also a reset button that emits the value of the valueDefault prop when clicked
|
73
|
+
* @vue-prop {Object} [value] - Style options that are modelled by the checkbox.
|
74
|
+
* @vue-prop {string} name - The name that is displayed in the header of the menu and in the tooltip of the preview.
|
75
|
+
* @vue-prop {Object} [valueDefault] - The default Options, that are applied when clicking reset or setting the checkbox from null to true.
|
76
|
+
* @vue-prop {Object} valueFallback - The fallback Options, in case the valueDefault is null or undefined. These are applied when the checkbox is checked again and the default value is null. The fallback value must not be null or undefined.
|
77
|
+
*/
|
78
|
+
export default {
|
79
|
+
name: 'MenuWrapper',
|
80
|
+
components: {
|
81
|
+
VSheet,
|
82
|
+
VMenu,
|
83
|
+
VCard,
|
84
|
+
VcsFormSection,
|
85
|
+
VcsTooltip,
|
86
|
+
VcsCheckbox,
|
87
|
+
},
|
88
|
+
props: {
|
89
|
+
value: {
|
90
|
+
default: undefined,
|
91
|
+
required: false,
|
92
|
+
type: Object,
|
93
|
+
},
|
94
|
+
valueDefault: {
|
95
|
+
default: undefined,
|
96
|
+
type: Object,
|
97
|
+
},
|
98
|
+
valueFallback: {
|
99
|
+
required: true,
|
100
|
+
type: Object,
|
101
|
+
},
|
102
|
+
name: {
|
103
|
+
required: true,
|
104
|
+
type: String,
|
105
|
+
},
|
106
|
+
disabled: {
|
107
|
+
default: false,
|
108
|
+
type: Boolean,
|
109
|
+
},
|
110
|
+
},
|
111
|
+
setup(props, { emit }) {
|
112
|
+
const isMenuOpen = ref(false);
|
113
|
+
|
114
|
+
return {
|
115
|
+
isMenuOpen,
|
116
|
+
reset() {
|
117
|
+
emit('input', props.valueDefault);
|
118
|
+
},
|
119
|
+
close() {
|
120
|
+
isMenuOpen.value = false;
|
121
|
+
},
|
122
|
+
handleCheckbox(value) {
|
123
|
+
emit(
|
124
|
+
'input',
|
125
|
+
value ? props.valueDefault || props.valueFallback : null,
|
126
|
+
);
|
127
|
+
},
|
128
|
+
};
|
129
|
+
},
|
130
|
+
};
|
131
|
+
</script>
|
132
|
+
|
133
|
+
<style scoped>
|
134
|
+
.tiled-background {
|
135
|
+
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAGElEQVQYlWNgYGCQwoKxgqGgcJA5h3yFAAs8BRWVSwooAAAAAElFTkSuQmCC)
|
136
|
+
repeat;
|
137
|
+
}
|
138
|
+
</style>
|
@@ -0,0 +1,61 @@
|
|
1
|
+
<template>
|
2
|
+
<MenuWrapper
|
3
|
+
v-bind="{ value, valueDefault, disabled }"
|
4
|
+
:value-fallback="{ color: [255, 255, 255, 1] }"
|
5
|
+
v-on="$listeners"
|
6
|
+
name="components.style.fill"
|
7
|
+
>
|
8
|
+
<template #preview>
|
9
|
+
<v-sheet :color="rgbaString" width="100%" height="100%" />
|
10
|
+
</template>
|
11
|
+
<template #content>
|
12
|
+
<VcsFillSelector :value="value" v-on="$listeners" />
|
13
|
+
</template>
|
14
|
+
</MenuWrapper>
|
15
|
+
</template>
|
16
|
+
|
17
|
+
<script>
|
18
|
+
import { computed } from 'vue';
|
19
|
+
import { VSheet } from 'vuetify/lib';
|
20
|
+
import { VcsFillSelector } from '@vcmap/ui';
|
21
|
+
import MenuWrapper from './MenuWrapper.vue';
|
22
|
+
import { useColorObject, rgbaObjectToString } from './composables.js';
|
23
|
+
|
24
|
+
/**
|
25
|
+
* @description A wrapper for the VcsFillSelector, that has a small color preview and a menu that pops up when clicking the preview, containing the fill selector.
|
26
|
+
* When clicking the reset button, the valueDefault is emitted, when unchecking the checkbox in front of the preview, null is emitted. If it is checked again, valueDefault is emitted. If the valueDefault is undefined or null, { color: [255, 255, 255, 1] } is emitted.
|
27
|
+
* @vue-prop {import("ol/style/Fill").Options} [value] - The Fill Options
|
28
|
+
* @vue-prop {import("ol/style/Fill").Options} [valueDefault] - The default Fill Options
|
29
|
+
* @vue-prop {boolean} [disabled=false] - Disable the input
|
30
|
+
*/
|
31
|
+
export default {
|
32
|
+
name: 'VcsFillMenu',
|
33
|
+
components: {
|
34
|
+
VSheet,
|
35
|
+
VcsFillSelector,
|
36
|
+
MenuWrapper,
|
37
|
+
},
|
38
|
+
props: {
|
39
|
+
value: {
|
40
|
+
type: Object,
|
41
|
+
default: undefined,
|
42
|
+
},
|
43
|
+
valueDefault: {
|
44
|
+
type: Object,
|
45
|
+
default: undefined,
|
46
|
+
},
|
47
|
+
disabled: {
|
48
|
+
type: Boolean,
|
49
|
+
default: false,
|
50
|
+
},
|
51
|
+
},
|
52
|
+
setup(props) {
|
53
|
+
const rgbaObject = useColorObject(() => props.value?.color);
|
54
|
+
return {
|
55
|
+
rgbaString: computed(() => rgbaObjectToString(rgbaObject.value)),
|
56
|
+
};
|
57
|
+
},
|
58
|
+
};
|
59
|
+
</script>
|
60
|
+
|
61
|
+
<style scoped></style>
|
@@ -0,0 +1,45 @@
|
|
1
|
+
<template>
|
2
|
+
<v-sheet>
|
3
|
+
<v-color-picker
|
4
|
+
:value="rgbaObject"
|
5
|
+
@input="updateColor"
|
6
|
+
mode="rgba"
|
7
|
+
:hide-mode-switch="true"
|
8
|
+
:disabled="!value"
|
9
|
+
/>
|
10
|
+
</v-sheet>
|
11
|
+
</template>
|
12
|
+
|
13
|
+
<script>
|
14
|
+
import { VSheet, VColorPicker } from 'vuetify/lib';
|
15
|
+
import { useColorObject } from './composables.js';
|
16
|
+
|
17
|
+
/**
|
18
|
+
* @description Allows to model a JSON representation of ol/Fill vector style with a vuetify VColorPicker.
|
19
|
+
* @vue-prop {import("ol/style/Fill").Options} value - The Fill Options
|
20
|
+
*/
|
21
|
+
export default {
|
22
|
+
name: 'VcsFillSelector',
|
23
|
+
components: {
|
24
|
+
VSheet,
|
25
|
+
VColorPicker,
|
26
|
+
},
|
27
|
+
props: {
|
28
|
+
value: {
|
29
|
+
type: Object,
|
30
|
+
default: undefined,
|
31
|
+
},
|
32
|
+
},
|
33
|
+
setup(props, { emit }) {
|
34
|
+
return {
|
35
|
+
rgbaObject: useColorObject(() => props.value?.color),
|
36
|
+
updateColor(rgba) {
|
37
|
+
const fill = {
|
38
|
+
color: [rgba.r, rgba.g, rgba.b, rgba.a],
|
39
|
+
};
|
40
|
+
emit('input', fill);
|
41
|
+
},
|
42
|
+
};
|
43
|
+
},
|
44
|
+
};
|
45
|
+
</script>
|
@@ -0,0 +1,84 @@
|
|
1
|
+
<template>
|
2
|
+
<MenuWrapper
|
3
|
+
v-bind="{ value, valueDefault }"
|
4
|
+
:value-fallback="{
|
5
|
+
radius: 10,
|
6
|
+
fill: { color: [255, 255, 255, 1] },
|
7
|
+
stroke: { color: [0, 0, 0, 1], width: 2 },
|
8
|
+
}"
|
9
|
+
v-on="$listeners"
|
10
|
+
name="components.style.image"
|
11
|
+
>
|
12
|
+
<template #preview>
|
13
|
+
<canvas ref="canvas" width="32" height="24" />
|
14
|
+
</template>
|
15
|
+
<template #content>
|
16
|
+
<VcsImageSelector
|
17
|
+
v-bind="{ value, valueDefault, iconOptions, extendedShapeSettings }"
|
18
|
+
v-on="$listeners"
|
19
|
+
class="pb-2"
|
20
|
+
/>
|
21
|
+
</template>
|
22
|
+
</MenuWrapper>
|
23
|
+
</template>
|
24
|
+
|
25
|
+
<script>
|
26
|
+
import { onMounted, ref, watch } from 'vue';
|
27
|
+
import { VcsImageSelector } from '@vcmap/ui';
|
28
|
+
import MenuWrapper from './MenuWrapper.vue';
|
29
|
+
import { drawImageStyle } from './VcsImageSelector.vue';
|
30
|
+
|
31
|
+
/**
|
32
|
+
* @description A wrapper for the VcsImageSelector, that has a small shape/icon preview and a menu that pops up when clicking the preview, containing the image selector.
|
33
|
+
* @vue-prop {import("ol/style/RegularShape").Options | import("ol/style/Circle").Options | import("ol/style/Icon").Options} value - The Image options
|
34
|
+
* @vue-prop {import("ol/style/RegularShape").Options | import("ol/style/Circle").Options | import("ol/style/Icon").Options} valueDefault - The default image options
|
35
|
+
* @vue-prop {import("ol/style/Icon").Options} iconOptions - The icon options too choose from. Scale and opacity are ignored.
|
36
|
+
* @vue-prop {boolean} [extendedShapeSettings=false] - If true, there are all the input fields needed to create arbitrary ol RegularShapes.
|
37
|
+
*/
|
38
|
+
export default {
|
39
|
+
name: 'VcsImageMenu',
|
40
|
+
components: {
|
41
|
+
MenuWrapper,
|
42
|
+
VcsImageSelector,
|
43
|
+
},
|
44
|
+
props: {
|
45
|
+
value: {
|
46
|
+
type: Object,
|
47
|
+
default: undefined,
|
48
|
+
},
|
49
|
+
valueDefault: {
|
50
|
+
type: Object,
|
51
|
+
default: undefined,
|
52
|
+
},
|
53
|
+
iconOptions: {
|
54
|
+
type: Array,
|
55
|
+
default: undefined,
|
56
|
+
},
|
57
|
+
extendedShapeSettings: {
|
58
|
+
type: Boolean,
|
59
|
+
default: false,
|
60
|
+
},
|
61
|
+
},
|
62
|
+
setup(props) {
|
63
|
+
const canvas = ref(null);
|
64
|
+
|
65
|
+
onMounted(() => {
|
66
|
+
drawImageStyle(canvas.value, props.value, true);
|
67
|
+
watch(
|
68
|
+
() => props.value,
|
69
|
+
() => {
|
70
|
+
// XXX Maybe add some sort of timeout funciton, so it draws only once when user stops using the slider
|
71
|
+
drawImageStyle(canvas.value, props.value, true);
|
72
|
+
},
|
73
|
+
{ deep: true },
|
74
|
+
);
|
75
|
+
});
|
76
|
+
|
77
|
+
return {
|
78
|
+
canvas,
|
79
|
+
};
|
80
|
+
},
|
81
|
+
};
|
82
|
+
</script>
|
83
|
+
|
84
|
+
<style scoped></style>
|