@geops/rvf-mobility-web-component 0.1.99 → 0.1.101
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/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@geops/rvf-mobility-web-component",
|
|
3
3
|
"license": "UNLICENSED",
|
|
4
4
|
"description": "Web components for rvf in the domains of mobility and logistics.",
|
|
5
|
-
"version": "0.1.
|
|
5
|
+
"version": "0.1.101",
|
|
6
6
|
"homepage": "https://rvf-mobility-web-component-geops.vercel.app/",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"main": "index.js",
|
|
@@ -4,7 +4,6 @@ import { memo, useEffect, useMemo, useState } from "preact/compat";
|
|
|
4
4
|
|
|
5
5
|
import I18n from "../I18n";
|
|
6
6
|
import SituationDetails from "../SituationDetails";
|
|
7
|
-
import useI18n from "../utils/hooks/useI18n";
|
|
8
7
|
|
|
9
8
|
import MobilityNotificationsAttributes from "./MobilityNotificationsAttributes";
|
|
10
9
|
|
|
@@ -39,21 +38,15 @@ function MobilityNotifications({
|
|
|
39
38
|
notificationurl,
|
|
40
39
|
}: MobilityNotificationsProps) {
|
|
41
40
|
const [situations, setSituations] = useState<SituationType[]>([]);
|
|
42
|
-
const { locale } = useI18n();
|
|
43
41
|
|
|
44
42
|
// Define fallback languages from the notificationlang attribute
|
|
45
43
|
const fallbackLangs = useMemo(() => {
|
|
46
44
|
return (
|
|
47
|
-
notificationlang
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
return l.trim();
|
|
51
|
-
})
|
|
52
|
-
.filter((l) => {
|
|
53
|
-
return l !== locale();
|
|
54
|
-
}) || []
|
|
45
|
+
notificationlang?.split(",").map((l) => {
|
|
46
|
+
return l.trim();
|
|
47
|
+
}) || []
|
|
55
48
|
);
|
|
56
|
-
}, [
|
|
49
|
+
}, [notificationlang]);
|
|
57
50
|
|
|
58
51
|
useEffect(() => {
|
|
59
52
|
new MocoAPI({
|
|
@@ -65,7 +65,7 @@ function RvfMapLayout({
|
|
|
65
65
|
{...props}
|
|
66
66
|
>
|
|
67
67
|
<RvfSelectedFeatureHighlightLayer />
|
|
68
|
-
<StationsLayer
|
|
68
|
+
<StationsLayer {...stationsLayerProps} />
|
|
69
69
|
<RvfTarifZonenLayer />
|
|
70
70
|
<RvfSellingPointsLayer />
|
|
71
71
|
<RvfPoisLayer />
|