From 4574821ed82ef5917e6a097852a92ea94ca7513a Mon Sep 17 00:00:00 2001 From: notCharles Date: Tue, 2 Jul 2024 16:50:39 -0400 Subject: [PATCH] Also nuke this --- .../components/dashboard/ServerRow.tsx | 20 +++---------------- .../server/console/ServerDetailsBlock.tsx | 12 +---------- 2 files changed, 4 insertions(+), 28 deletions(-) diff --git a/resources/scripts/components/dashboard/ServerRow.tsx b/resources/scripts/components/dashboard/ServerRow.tsx index 08637bfc2..99e9fec42 100644 --- a/resources/scripts/components/dashboard/ServerRow.tsx +++ b/resources/scripts/components/dashboard/ServerRow.tsx @@ -1,10 +1,10 @@ import React, { memo, useEffect, useRef, useState } from 'react'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; -import { faEthernet, faHdd, faMemory, faMicrochip, faServer } from '@fortawesome/free-solid-svg-icons'; +import { faHdd, faMemory, faMicrochip, faServer } from '@fortawesome/free-solid-svg-icons'; import { Link } from 'react-router-dom'; import { Server } from '@/api/server/getServer'; import getServerResourceUsage, { ServerPowerState, ServerStats } from '@/api/server/getServerResourceUsage'; -import { bytesToString, ip, mbToBytes } from '@/lib/formatters'; +import { bytesToString, mbToBytes } from '@/lib/formatters'; import tw from 'twin.macro'; import GreyRowBox from '@/components/elements/GreyRowBox'; import Spinner from '@/components/elements/Spinner'; @@ -90,7 +90,7 @@ export default ({ server, className }: { server: Server; className?: string }) = return ( -
+
@@ -101,20 +101,6 @@ export default ({ server, className }: { server: Server; className?: string }) = )}
-
-
- -

- {server.allocations - .filter((alloc) => alloc.isDefault) - .map((allocation) => ( - - {allocation.alias || ip(allocation.ip)}:{allocation.port} - - ))} -

-
-
{!stats || isSuspended ? ( isSuspended ? ( diff --git a/resources/scripts/components/server/console/ServerDetailsBlock.tsx b/resources/scripts/components/server/console/ServerDetailsBlock.tsx index a3a009612..66831a782 100644 --- a/resources/scripts/components/server/console/ServerDetailsBlock.tsx +++ b/resources/scripts/components/server/console/ServerDetailsBlock.tsx @@ -6,9 +6,8 @@ import { faHdd, faMemory, faMicrochip, - faWifi, } from '@fortawesome/free-solid-svg-icons'; -import { bytesToString, ip, mbToBytes } from '@/lib/formatters'; +import { bytesToString, mbToBytes } from '@/lib/formatters'; import { ServerContext } from '@/state/server'; import { SocketEvent, SocketRequest } from '@/components/server/events'; import UptimeDuration from '@/components/server/UptimeDuration'; @@ -56,12 +55,6 @@ const ServerDetailsBlock = ({ className }: { className?: string }) => { [limits] ); - const allocation = ServerContext.useStoreState((state) => { - const match = state.server.data!.allocations.find((allocation) => allocation.isDefault); - - return !match ? 'n/a' : `${match.alias || ip(match.ip)}:${match.port}`; - }); - useEffect(() => { if (!connected || !instance) { return; @@ -90,9 +83,6 @@ const ServerDetailsBlock = ({ className }: { className?: string }) => { return (
- - {allocation} -