@dative-gpi/foundation-shared-components 1.0.106 → 1.0.107
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/FSDialog.vue
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
:class="classes"
|
|
5
5
|
:modelValue="$props.modelValue"
|
|
6
6
|
@update:modelValue="$emit('update:modelValue', $event)"
|
|
7
|
-
|
|
7
|
+
:width="$props.width"
|
|
8
8
|
v-bind="$attrs"
|
|
9
9
|
>
|
|
10
10
|
<slot>
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
:width="$props.width"
|
|
15
15
|
:modelValue="$props.modelValue"
|
|
16
16
|
@update:modelValue="$emit('update:modelValue', $event)"
|
|
17
|
-
@click.stop="$emit('click', $event)"
|
|
18
17
|
>
|
|
19
18
|
<template
|
|
20
19
|
v-for="(_, name) in $slots"
|
package/components/map/FSMap.vue
CHANGED
|
@@ -327,7 +327,24 @@ export default defineComponent({
|
|
|
327
327
|
if(!map.value) {
|
|
328
328
|
return;
|
|
329
329
|
}
|
|
330
|
-
|
|
330
|
+
|
|
331
|
+
if(isExtraSmall.value) {
|
|
332
|
+
// We wait for bottom offset to be calculated and stable to focus on the right position
|
|
333
|
+
let tries = 0;
|
|
334
|
+
let oldBottomOffset = bottomOffset.value;
|
|
335
|
+
const interval = setInterval(() => {
|
|
336
|
+
if(oldBottomOffset === bottomOffset.value || tries >= 30) {
|
|
337
|
+
clearInterval(interval);
|
|
338
|
+
map.value!.flyTo(calculateTargetPosition(latLng(lat, lng), zoom), zoom, options);
|
|
339
|
+
}
|
|
340
|
+
oldBottomOffset = bottomOffset.value;
|
|
341
|
+
tries++;
|
|
342
|
+
}, 20);
|
|
343
|
+
|
|
344
|
+
} else {
|
|
345
|
+
map.value.flyTo(calculateTargetPosition(latLng(lat, lng), zoom), zoom, options);
|
|
346
|
+
}
|
|
347
|
+
|
|
331
348
|
}
|
|
332
349
|
|
|
333
350
|
const setView = (lat: number, lng: number, zoom: number) => {
|
|
@@ -338,23 +355,23 @@ export default defineComponent({
|
|
|
338
355
|
}
|
|
339
356
|
|
|
340
357
|
const fitBounds = (bounds: LatLngBounds, options?: FitBoundsOptions) => {
|
|
341
|
-
if (!map.value) {
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
358
|
+
if (!map.value) {return;}
|
|
359
|
+
const paddingTopLeft: [number, number] = [
|
|
360
|
+
leftOffset.value,
|
|
361
|
+
0
|
|
362
|
+
];
|
|
363
|
+
|
|
364
|
+
const paddingBottomRight: [number, number] = [
|
|
365
|
+
0,
|
|
366
|
+
bottomOffset.value
|
|
367
|
+
];
|
|
368
|
+
const paddingOptions = {
|
|
369
|
+
paddingTopLeft,
|
|
370
|
+
paddingBottomRight,
|
|
371
|
+
...options,
|
|
372
|
+
};
|
|
356
373
|
|
|
357
|
-
map.value.fitBounds(
|
|
374
|
+
map.value.fitBounds(bounds, paddingOptions);
|
|
358
375
|
};
|
|
359
376
|
|
|
360
377
|
onMounted(() => {
|
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
/>
|
|
8
8
|
<FSDialog
|
|
9
9
|
v-model="dialog"
|
|
10
|
-
width="500px"
|
|
11
10
|
:title="$tr('ui.map.select-layer', 'Select layer')"
|
|
12
11
|
:contained="true"
|
|
13
12
|
>
|
|
@@ -16,6 +15,7 @@
|
|
|
16
15
|
>
|
|
17
16
|
<FSRow
|
|
18
17
|
align="center-center"
|
|
18
|
+
:wrap="false"
|
|
19
19
|
>
|
|
20
20
|
<FSImageCard
|
|
21
21
|
v-for="layer in layers"
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
v-show="isExtraSmall"
|
|
11
11
|
ref="mobileOverlayWrapper"
|
|
12
12
|
class="fs-map-overlay-mobile"
|
|
13
|
-
:style="{ height: $props.mode === 'expand' ? '90%' : ($props.mode === 'half' ? '
|
|
13
|
+
:style="{ height: $props.mode === 'expand' ? '90%' : ($props.mode === 'half' ? '60%' : '20px') }"
|
|
14
14
|
>
|
|
15
15
|
<FSCard
|
|
16
16
|
width="100%"
|
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.
|
|
4
|
+
"version": "1.0.107",
|
|
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.
|
|
14
|
-
"@dative-gpi/foundation-shared-services": "1.0.
|
|
13
|
+
"@dative-gpi/foundation-shared-domain": "1.0.107",
|
|
14
|
+
"@dative-gpi/foundation-shared-services": "1.0.107"
|
|
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": "eb566a0c7b51ca46c2d469196aa8e6e83b70bae3"
|
|
39
39
|
}
|
|
@@ -1,16 +1,9 @@
|
|
|
1
1
|
.fs-dialog-mobile > .v-overlay__content {
|
|
2
2
|
flex-direction: column-reverse !important;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.fs-dialog > .v-overlay__content {
|
|
6
|
-
justify-content: center !important;
|
|
7
|
-
align-items: center !important;
|
|
8
|
-
}
|
|
9
3
|
|
|
10
|
-
.v-dialog > .v-overlay__content {
|
|
11
4
|
max-height: 100vh !important;
|
|
12
5
|
max-width: 100vw !important;
|
|
13
6
|
height: 100% !important;
|
|
14
7
|
width: 100% !important;
|
|
15
8
|
margin: 0 !important;
|
|
16
|
-
}
|
|
9
|
+
}
|