Healthcheck updates, UI to remove wierd bar
This commit is contained in:
+13
-1
@@ -2433,11 +2433,13 @@ function ResourceOverviewTab({
|
||||
canRead,
|
||||
canExec,
|
||||
canDelete,
|
||||
onNodesChanged,
|
||||
}: {
|
||||
section: ResourceSectionId
|
||||
canRead: boolean
|
||||
canExec: boolean
|
||||
canDelete: boolean
|
||||
onNodesChanged: () => void
|
||||
}) {
|
||||
const [nodes, setNodes] = useState<ReadonlyArray<Node>>([])
|
||||
const [isLoading, setIsLoading] = useState(true)
|
||||
@@ -2532,6 +2534,7 @@ function ResourceOverviewTab({
|
||||
)
|
||||
} finally {
|
||||
setCheckingNodeId(null)
|
||||
onNodesChanged()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2546,6 +2549,7 @@ function ResourceOverviewTab({
|
||||
),
|
||||
)
|
||||
setPendingDeleteNodeId(null)
|
||||
onNodesChanged()
|
||||
}
|
||||
|
||||
if (!canRead) {
|
||||
@@ -2996,12 +3000,14 @@ function ResourceSectionPanel({
|
||||
onResourceTabChange,
|
||||
nodeId,
|
||||
nodeDetailTab,
|
||||
onNodesChanged,
|
||||
}: {
|
||||
section: ResourceSectionId
|
||||
activeResourceTab: ResourceTabId
|
||||
onResourceTabChange: (tab: ResourceTabId) => void
|
||||
nodeId: string | null
|
||||
nodeDetailTab: NodeDetailTabId
|
||||
onNodesChanged: () => void
|
||||
}) {
|
||||
const [me, setMe] = useState<MeResponse | null>(null)
|
||||
const [overviewKey, setOverviewKey] = useState(0)
|
||||
@@ -3040,6 +3046,7 @@ function ResourceSectionPanel({
|
||||
section={section}
|
||||
nodeId={nodeId}
|
||||
activeTab={nodeDetailTab}
|
||||
onNodesChanged={onNodesChanged}
|
||||
/>
|
||||
)
|
||||
}
|
||||
@@ -3086,6 +3093,7 @@ function ResourceSectionPanel({
|
||||
canRead={canRead}
|
||||
canExec={canExec}
|
||||
canDelete={canDelete}
|
||||
onNodesChanged={onNodesChanged}
|
||||
/>
|
||||
) : null}
|
||||
{activeResourceTab === 'security' ? (
|
||||
@@ -3848,6 +3856,7 @@ function App() {
|
||||
useState<NodeSectionCounts | null>(null)
|
||||
const [nodeHealthErrorCounts, setNodeHealthErrorCounts] =
|
||||
useState<NodeSectionCounts | null>(null)
|
||||
const [sidebarCountsRefreshToken, setSidebarCountsRefreshToken] = useState(0)
|
||||
const [authFailuresToday, setAuthFailuresToday] = useState<number | null>(
|
||||
null,
|
||||
)
|
||||
@@ -3969,7 +3978,7 @@ function App() {
|
||||
isCancelled = true
|
||||
window.clearInterval(pollIntervalId)
|
||||
}
|
||||
}, [bootState.kind, canReadLogs, activeSection])
|
||||
}, [bootState.kind, canReadLogs, activeSection, sidebarCountsRefreshToken])
|
||||
|
||||
useEffect(() => {
|
||||
if (bootState.kind !== 'ready') {
|
||||
@@ -4272,6 +4281,9 @@ function App() {
|
||||
onResourceTabChange={goToResourceTab}
|
||||
nodeId={activeNodeId}
|
||||
nodeDetailTab={activeNodeDetailTab}
|
||||
onNodesChanged={() => {
|
||||
setSidebarCountsRefreshToken((token) => token + 1)
|
||||
}}
|
||||
/>
|
||||
) : (
|
||||
<p>Coming soon</p>
|
||||
|
||||
Reference in New Issue
Block a user