@dative-gpi/foundation-shared-components 1.0.128-fix-mobile-12 → 1.0.128-fix-mobile-map
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/components/FSFadeOut.vue
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
class="fs-fade-out"
|
|
4
4
|
ref="fadeOutRef"
|
|
5
5
|
:id="elementId"
|
|
6
|
-
:style="style"
|
|
7
6
|
@scroll="$emit('scroll', $event); debounceMasks()"
|
|
8
7
|
>
|
|
9
8
|
<slot />
|
|
@@ -11,7 +10,7 @@
|
|
|
11
10
|
</template>
|
|
12
11
|
|
|
13
12
|
<script lang="ts">
|
|
14
|
-
import { computed, defineComponent, onMounted, onUnmounted, type PropType, ref,
|
|
13
|
+
import { computed, defineComponent, onMounted, onUnmounted, type PropType, ref, watch } from "vue";
|
|
15
14
|
|
|
16
15
|
import { useBreakpoints, useColors, useDebounce } from "@dative-gpi/foundation-shared-components/composables";
|
|
17
16
|
import { ColorEnum } from "@dative-gpi/foundation-shared-components/models";
|
|
@@ -65,6 +64,10 @@ export default defineComponent({
|
|
|
65
64
|
type: Boolean,
|
|
66
65
|
required: false,
|
|
67
66
|
default: false
|
|
67
|
+
},
|
|
68
|
+
style:{
|
|
69
|
+
type: Object,
|
|
70
|
+
required: false
|
|
68
71
|
}
|
|
69
72
|
},
|
|
70
73
|
emits: ["scroll"],
|
|
@@ -75,7 +78,7 @@ export default defineComponent({
|
|
|
75
78
|
|
|
76
79
|
const backgrounds = getColors(ColorEnum.Background);
|
|
77
80
|
|
|
78
|
-
const fadeOutRef = ref(null);
|
|
81
|
+
const fadeOutRef = ref<HTMLElement | null>(null);
|
|
79
82
|
const bottomMaskHeight = ref("0px");
|
|
80
83
|
const topMaskHeight = ref("0px");
|
|
81
84
|
const lastScroll = ref(0);
|
|
@@ -86,7 +89,7 @@ export default defineComponent({
|
|
|
86
89
|
|
|
87
90
|
const showOutsideScrollbar = computed(() => props.scrollOutside && !isTouchScreenEnabled.value);
|
|
88
91
|
|
|
89
|
-
const style = computed(():
|
|
92
|
+
const style = computed((): {[index: string]: string} => ({
|
|
90
93
|
"--fs-fade-out-height" : props.height ? sizeToVar(props.height) : "initial",
|
|
91
94
|
"--fs-fade-out-max-height" : props.maxHeight ? sizeToVar(props.maxHeight) : "initial",
|
|
92
95
|
"--fs-fade-out-width" : sizeToVar(props.width),
|
|
@@ -97,7 +100,8 @@ export default defineComponent({
|
|
|
97
100
|
"--fs-fade-out-mask-color" : backgrounds.base,
|
|
98
101
|
"--fs-fade-out-top-mask-height" : props.disableTopMask ? '0px' : topMaskHeight.value,
|
|
99
102
|
"--fs-fade-out-bottom-mask-height": props.disableBottomMask ? '0px' : bottomMaskHeight.value,
|
|
100
|
-
"--fs-fade-out-x-overflow" : props.hideHorizontalOverflow ? 'hidden' : 'auto'
|
|
103
|
+
"--fs-fade-out-x-overflow" : props.hideHorizontalOverflow ? 'hidden' : 'auto',
|
|
104
|
+
...props.style
|
|
101
105
|
}));
|
|
102
106
|
|
|
103
107
|
const handleMasks = () => {
|
|
@@ -148,6 +152,15 @@ export default defineComponent({
|
|
|
148
152
|
|
|
149
153
|
watch([() => windowWidth.value, () => windowHeight.value], debounceMasks);
|
|
150
154
|
|
|
155
|
+
watch(() => [style.value, fadeOutRef.value], () => {
|
|
156
|
+
if(!fadeOutRef.value || !style.value) {
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
159
|
+
for(const key in style.value){
|
|
160
|
+
fadeOutRef.value.style.setProperty(key, style.value[key])
|
|
161
|
+
}
|
|
162
|
+
}, { immediate: true})
|
|
163
|
+
|
|
151
164
|
return {
|
|
152
165
|
fadeOutRef,
|
|
153
166
|
elementId,
|
package/components/map/FSMap.vue
CHANGED
|
@@ -259,7 +259,7 @@ export default defineComponent({
|
|
|
259
259
|
name: "map",
|
|
260
260
|
label: $tr("ui.map-layer.map", "Map"),
|
|
261
261
|
image: new URL("../../assets/images/map/map.png", import.meta.url).href,
|
|
262
|
-
layer: tileLayer(`
|
|
262
|
+
layer: tileLayer(`https://{s}.google.com/vt/lyrs=m&x={x}&y={y}&z={z}&key=${import.meta.env.VITE_GOOGLE_MAPS_API_KEY ?? ""}`, {
|
|
263
263
|
maxZoom: 22,
|
|
264
264
|
subdomains: ['mt0', 'mt1', 'mt2', 'mt3'],
|
|
265
265
|
attribution: '© Google Map Data'
|
|
@@ -269,7 +269,7 @@ export default defineComponent({
|
|
|
269
269
|
name: "imagery",
|
|
270
270
|
label: $tr("ui.map-layer.imagery", "Imagery"),
|
|
271
271
|
image: new URL("../../assets/images/map/imagery.png", import.meta.url).href,
|
|
272
|
-
layer: tileLayer(`
|
|
272
|
+
layer: tileLayer(`https://{s}.google.com/vt/lyrs=s,h&x={x}&y={y}&z={z}&key=${import.meta.env.VITE_GOOGLE_MAPS_API_KEY ?? ""}`, {
|
|
273
273
|
maxZoom: 22,
|
|
274
274
|
subdomains: ['mt0', 'mt1', 'mt2', 'mt3'],
|
|
275
275
|
attribution: '© Google Map Data'
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dative-gpi/foundation-shared-components",
|
|
3
3
|
"sideEffects": false,
|
|
4
|
-
"version": "1.0.128-fix-mobile-
|
|
4
|
+
"version": "1.0.128-fix-mobile-map",
|
|
5
5
|
"description": "",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"author": "",
|
|
11
11
|
"license": "ISC",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@dative-gpi/foundation-shared-domain": "1.0.128-fix-mobile-
|
|
14
|
-
"@dative-gpi/foundation-shared-services": "1.0.128-fix-mobile-
|
|
13
|
+
"@dative-gpi/foundation-shared-domain": "1.0.128-fix-mobile-map",
|
|
14
|
+
"@dative-gpi/foundation-shared-services": "1.0.128-fix-mobile-map"
|
|
15
15
|
},
|
|
16
16
|
"peerDependencies": {
|
|
17
17
|
"@dative-gpi/bones-ui": "^1.0.0",
|
|
@@ -35,5 +35,5 @@
|
|
|
35
35
|
"sass": "1.71.1",
|
|
36
36
|
"sass-loader": "13.3.2"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "a5512820c57c64f4ffe5653bbfc138f438098ac8"
|
|
39
39
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
.v-overlay__content:has(.fs-dialog-menu) {
|
|
2
2
|
width: fit-content !important;
|
|
3
|
-
max-height: calc(
|
|
3
|
+
max-height: calc(100dvh - 40px) !important;
|
|
4
4
|
justify-content: center;
|
|
5
5
|
align-items: center;
|
|
6
6
|
}
|
|
7
7
|
|
|
8
8
|
.fs-dialog-menu {
|
|
9
|
-
max-height: calc(
|
|
9
|
+
max-height: calc(100dvh - 40px) !important;
|
|
10
10
|
max-width: calc(100vw - 40px) !important;
|
|
11
11
|
}
|