diff options
Diffstat (limited to 'modern/src/map')
-rw-r--r-- | modern/src/map/MapPositions.js | 2 | ||||
-rw-r--r-- | modern/src/map/core/preloadImages.js | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/modern/src/map/MapPositions.js b/modern/src/map/MapPositions.js index 070ec0c8..89a48df1 100644 --- a/modern/src/map/MapPositions.js +++ b/modern/src/map/MapPositions.js @@ -20,7 +20,7 @@ const MapPositions = ({ positions, onClick, showStatus }) => { deviceId: position.deviceId, name: device.name, category: device.category || 'default', - color: showStatus ? getStatusColor(device.status) : 'neutral', + color: showStatus ? position.attributes.color || getStatusColor(device.status) : 'neutral', }; }; diff --git a/modern/src/map/core/preloadImages.js b/modern/src/map/core/preloadImages.js index c66ec5de..8649a347 100644 --- a/modern/src/map/core/preloadImages.js +++ b/modern/src/map/core/preloadImages.js @@ -57,7 +57,7 @@ export default async () => { mapImages.direction = await prepareIcon(await loadImage(directionSvg)); await Promise.all(Object.keys(mapIcons).map(async (category) => { const results = []; - ['positive', 'negative', 'neutral'].forEach((color) => { + ['primary', 'positive', 'negative', 'neutral'].forEach((color) => { results.push(loadImage(mapIcons[category]).then((icon) => { mapImages[`${category}-${color}`] = prepareIcon(background, icon, palette.colors[color]); })); |