From 1d2f35ca4732c789f09fe8a5c8d6ccfd77708a92 Mon Sep 17 00:00:00 2001 From: sara-pervana Date: Fri, 26 Jan 2024 00:59:51 +0100 Subject: [PATCH] small formatting fixes --- pkgs/ui/src/app/client/client.tsx | 2 +- pkgs/ui/src/components/consume_action/index.tsx | 5 +++++ pkgs/ui/src/components/entity_actions/index.tsx | 3 +-- pkgs/ui/src/config/client_1/index.tsx | 5 +---- 4 files changed, 8 insertions(+), 7 deletions(-) create mode 100644 pkgs/ui/src/components/consume_action/index.tsx diff --git a/pkgs/ui/src/app/client/client.tsx b/pkgs/ui/src/app/client/client.tsx index 7994702..155ed18 100644 --- a/pkgs/ui/src/app/client/client.tsx +++ b/pkgs/ui/src/app/client/client.tsx @@ -1,5 +1,5 @@ "use client"; -import { useEffect, useMemo, useRef, useState } from "react"; +import { useEffect, useMemo, useState } from "react"; import { ClientTableConfig, ServiceTableConfig } from "@/config/client_1"; import CustomTable from "@/components/table"; import { diff --git a/pkgs/ui/src/components/consume_action/index.tsx b/pkgs/ui/src/components/consume_action/index.tsx new file mode 100644 index 0000000..0ae9bc8 --- /dev/null +++ b/pkgs/ui/src/components/consume_action/index.tsx @@ -0,0 +1,5 @@ +const ConsumeAction = () => { + return <>; +}; + +export default ConsumeAction; diff --git a/pkgs/ui/src/components/entity_actions/index.tsx b/pkgs/ui/src/components/entity_actions/index.tsx index 7a3ba8d..27d2b3d 100644 --- a/pkgs/ui/src/components/entity_actions/index.tsx +++ b/pkgs/ui/src/components/entity_actions/index.tsx @@ -26,7 +26,7 @@ const EntityActions = ({ endpointData, rowData }: Props) => { severity: AlertColor; }>(SNACKBAR_DEFAULT); - console.error("Error registering/deregistering:", error); + if (error) console.error("Error registering/deregistering:", error); const onDeleteEntity = async () => { if (rowData) @@ -34,7 +34,6 @@ const EntityActions = ({ endpointData, rowData }: Props) => { const response = await deleteEntity({ entity_did: rowData?.entity_did, }); - console.log("On Delete:", response.data.message); setSnackbar({ open: true, message: response.data.message, diff --git a/pkgs/ui/src/config/client_1/index.tsx b/pkgs/ui/src/config/client_1/index.tsx index 64a9e2d..d8190f2 100644 --- a/pkgs/ui/src/config/client_1/index.tsx +++ b/pkgs/ui/src/config/client_1/index.tsx @@ -1,7 +1,4 @@ -import { Button, IconButton, Tooltip } from "@mui/material"; -import AddCircleIcon from "@mui/icons-material/AddCircle"; -import RemoveCircleIcon from "@mui/icons-material/RemoveCircle"; -import DeleteIcon from "@mui/icons-material/Delete"; +import { Button } from "@mui/material"; import EntityActions from "@/components/entity_actions"; export const ClientTableConfig = [