From 80d748facbb26ee20efac176ae3d3641d152bab4 Mon Sep 17 00:00:00 2001 From: Joshen Lim Date: Fri, 17 May 2024 17:38:19 +0800 Subject: [PATCH] Disable restart button if replica is not active healthy (#26429) * Disable restart button if replica is not active healthy * Prettier --- .../InfrastructureConfiguration/InstanceNode.tsx | 16 ++++++++++++---- .../InfrastructureConfiguration/MapView.tsx | 12 ++++++++++-- 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/InstanceNode.tsx b/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/InstanceNode.tsx index 9398f4a6cd7..5c0dfeea2b2 100644 --- a/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/InstanceNode.tsx +++ b/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/InstanceNode.tsx @@ -332,7 +332,7 @@ export const ReplicaNode = ({ data }: NodeProps) => { @@ -340,7 +340,7 @@ export const ReplicaNode = ({ data }: NodeProps) => { @@ -348,13 +348,21 @@ export const ReplicaNode = ({ data }: NodeProps) => { - onSelectRestartReplica()}> + onSelectRestartReplica()} + > Restart replica {/* onSelectResizeReplica()}> Resize replica */} - onSelectDropReplica()}> + onSelectDropReplica()} + > Drop replica diff --git a/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/MapView.tsx b/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/MapView.tsx index e11b25f62de..749d63a686d 100644 --- a/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/MapView.tsx +++ b/apps/studio/components/interfaces/Settings/Infrastructure/InfrastructureConfiguration/MapView.tsx @@ -280,14 +280,20 @@ const MapView = ({