summaryrefslogtreecommitdiff
path: root/src/components/ScanDetail.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/ScanDetail.js')
-rw-r--r--src/components/ScanDetail.js15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/components/ScanDetail.js b/src/components/ScanDetail.js
index 34e7a12..9cf4740 100644
--- a/src/components/ScanDetail.js
+++ b/src/components/ScanDetail.js
@@ -7,6 +7,8 @@ import Tooltip from "@mui/material/Tooltip";
import InfoOutlinedIcon from "@mui/icons-material/InfoOutlined";
+import { resultClassName } from "../util";
+
class ScanDetail extends React.Component {
render() {
return (
@@ -126,18 +128,7 @@ function CustomElement(props) {
function Result(props) {
return (
<div className="resultContainer">
- <Card
- className={
- "result" +
- (() => {
- if (props.vulnerable) return " vulnerable";
- else if (props.investigation_needed)
- return " investigation_needed";
- else return "";
- })()
- }
- variant="outlined"
- >
+ <Card className={resultClassName(props)} variant="outlined">
{props.display_name}
{props.description && (
<Tooltip title={props.description}>