summaryrefslogtreecommitdiff
path: root/opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js
diff options
context:
space:
mode:
authorFabian Mastenbroek <mail.fabianm@gmail.com>2022-10-10 14:46:09 +0200
committerFabian Mastenbroek <mail.fabianm@gmail.com>2022-10-10 15:29:24 +0200
commit4ebe2f28ba940aabdaa1f57653fbe86a91582ebd (patch)
treea54e3f9d3a44a0248ef1b17430eed9b5d47ff5de /opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js
parent70630a40b54218ab8f8fd7a5e2dfb424d3dec378 (diff)
fix(web/ui): Fix UnitInfo popover
This change addresses an issue with the topology sidebar where hovering a CPU or GPU would not present the correct information due to bug.
Diffstat (limited to 'opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js')
-rw-r--r--opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js b/opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js
index 6b136120..a0054ef6 100644
--- a/opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js
+++ b/opendc-web/opendc-web-ui/src/components/topologies/sidebar/machine/UnitAddContainer.js
@@ -25,6 +25,7 @@ import React from 'react'
import { useDispatch, useSelector } from 'react-redux'
import UnitAddComponent from './UnitAddComponent'
import { addUnit } from '../../../../redux/actions/topology/machine'
+import UnitType from './UnitType'
function UnitAddContainer({ machineId, unitType }) {
const units = useSelector((state) => Object.values(state.topology[unitType]))
@@ -37,7 +38,7 @@ function UnitAddContainer({ machineId, unitType }) {
UnitAddContainer.propTypes = {
machineId: PropTypes.string.isRequired,
- unitType: PropTypes.string.isRequired,
+ unitType: UnitType.isRequired,
}
export default UnitAddContainer