activity -> shares (#141)

This commit is contained in:
Michael Quigley 2023-01-03 14:58:19 -05:00
parent 67dabbf73a
commit 2b5e4dda21
No known key found for this signature in database
GPG Key ID: 9B60314A9DD20A62
3 changed files with 10 additions and 10 deletions

View File

@ -1,6 +1,6 @@
import AccountDetail from "./AccountDetail";
import ShareDetail from "./ShareDetail";
import EnvironmentDetail from "./environment/EnvironmentDetail";
import Environment from "./environment/Environment";
const Detail = (props) => {
let detailComponent = <h1>{props.selection.id} ({props.selection.type})</h1>;
@ -11,7 +11,7 @@ const Detail = (props) => {
break;
case "environment":
detailComponent = <EnvironmentDetail selection={props.selection} />;
detailComponent = <Environment selection={props.selection} />;
break;
case "service":

View File

@ -1,12 +1,12 @@
import {Tab, Tabs} from "react-bootstrap";
import Activity from "./Activity";
import Shares from "./Shares";
import {useEffect, useState} from "react";
import Icon from "@mdi/react";
import {mdiConsoleNetwork} from "@mdi/js";
import {getEnvironmentDetail} from "../../../api/metadata";
import Detail from "./Detail";
const EnvironmentDetail = (props) => {
const Environment = (props) => {
const [detail, setDetail] = useState({});
useEffect(() => {
@ -20,9 +20,9 @@ const EnvironmentDetail = (props) => {
return (
<div>
<h2><Icon path={mdiConsoleNetwork} size={2} />{" "}{detail.environment.description}</h2>
<Tabs defaultActiveKey={"activity"} className={"mb-3"}>
<Tab eventKey={"activity"} title={"Activity"}>
<Activity selection={props.selection} />
<Tabs defaultActiveKey={"shares"} className={"mb-3"}>
<Tab eventKey={"shares"} title={"Shares"}>
<Shares selection={props.selection} />
</Tab>
<Tab eventKey={"detail"} title={"Detail"}>
<Detail environment={detail.environment} />
@ -34,4 +34,4 @@ const EnvironmentDetail = (props) => {
return <></>;
};
export default EnvironmentDetail;
export default Environment;

View File

@ -5,7 +5,7 @@ import {Sparklines, SparklinesLine, SparklinesSpots} from "react-sparklines";
import {mdiConsoleNetwork} from "@mdi/js";
import Icon from "@mdi/react";
const Activity = (props) => {
const Shares = (props) => {
const [detail, setDetail] = useState({});
useEffect(() => {
@ -77,4 +77,4 @@ const Activity = (props) => {
return <></>;
}
export default Activity;
export default Shares;