diff --git a/src/components/stops/StopPane.svelte b/src/components/stops/StopPane.svelte
index 2993242..fb0974b 100644
--- a/src/components/stops/StopPane.svelte
+++ b/src/components/stops/StopPane.svelte
@@ -119,7 +119,7 @@
{$t('no_arrivals_or_departures_in_next_30_minutes')}
{:else}
- {#key arrivalsAndDepartures.arrivalsAndDepartures}
+ {#key arrivalsAndDepartures.stopId}
{#each arrivalsAndDepartures.arrivalsAndDepartures as arrival}
diff --git a/src/lib/Provider/OpenStreetMapProvider.svelte.js b/src/lib/Provider/OpenStreetMapProvider.svelte.js
index 227b67a..632be87 100644
--- a/src/lib/Provider/OpenStreetMapProvider.svelte.js
+++ b/src/lib/Provider/OpenStreetMapProvider.svelte.js
@@ -273,17 +273,19 @@ export default class OpenStreetMapProvider {
marker.setLatLng([vehicleStatus.position.lat, vehicleStatus.position.lon]);
marker.setIcon(updatedIcon);
- marker.vehicleData = {
+ let vehicleData = $state({
...marker.vehicleData,
nextDestination: activeTrip.tripHeadsign,
vehicleId: vehicleStatus.vehicleId,
lastUpdateTime: vehicleStatus.lastUpdateTime,
nextStopName: this.stopsMap.get(vehicleStatus.nextStop)?.name || 'N/A',
predicted: vehicleStatus.predicted
- };
+ });
+
+ marker.vehicleData = vehicleData;
if (marker.isPopupOpen() && marker.popupComponent) {
- marker.popupComponent.$set(marker.vehicleData);
+ marker.popupComponent = vehicleData;
}
}
removeVehicleMarker(marker) {