1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-08-05 22:05:23 +02:00

feat: add warning events count next to the status badge (#828)

This commit is contained in:
Steven Kang 2025-07-04 10:07:57 +12:00 committed by GitHub
parent f4df51884c
commit 1332f718ae
18 changed files with 120 additions and 37 deletions

View file

@ -100,18 +100,14 @@ function useSecretRowData(
): SecretRowData[] {
return useMemo(
() =>
secrets?.map(
(secret) =>
({
...secret,
inUse: secret.IsUsed,
isSystem: namespaces
? namespaces.find(
(namespace) => namespace.Name === secret.Namespace
)?.IsSystem ?? false
: false,
}) ?? []
),
(secrets ?? []).map((secret) => ({
...secret,
inUse: secret.IsUsed,
isSystem: namespaces
? namespaces.find((namespace) => namespace.Name === secret.Namespace)
?.IsSystem ?? false
: false,
})),
[secrets, namespaces]
);
}