From 36b08ee0ca316e1b00568294584136313cd41292 Mon Sep 17 00:00:00 2001
From: Avanish V Patil <71136529+avanish23@users.noreply.github.com>
Date: Thu, 31 Oct 2024 17:57:47 +0530
Subject: [PATCH] hide namespaces via settings (#9547)
(cherry picked from commit 534a365efcf56aa7b3592b55e0885d021f97688c)
added translation; bumped up charts version;fixed lint
revert chart version bumpup
add hideAllNamespaces in externalSettings func
fix conflict
---
charts/kubernetes-dashboard/values.yaml | 2 ++
modules/web/i18n/de/messages.de.xlf | 8 ++++++++
modules/web/i18n/es/messages.es.xlf | 8 ++++++++
modules/web/i18n/fr/messages.fr.xlf | 8 ++++++++
modules/web/i18n/ja/messages.ja.xlf | 8 ++++++++
modules/web/i18n/ko/messages.ko.xlf | 8 ++++++++
modules/web/i18n/messages.xlf | 6 ++++++
modules/web/i18n/zh-Hans/messages.zh-Hans.xlf | 8 ++++++++
.../i18n/zh-Hant-HK/messages.zh-Hant-HK.xlf | 8 ++++++++
modules/web/i18n/zh-Hant/messages.zh-Hant.xlf | 8 ++++++++
modules/web/pkg/settings/settings.go | 2 ++
.../common/components/namespace/component.ts | 4 ++++
.../common/components/namespace/template.html | 2 +-
.../common/services/global/globalsettings.ts | 5 +++++
modules/web/src/settings/global/component.ts | 5 +++++
modules/web/src/settings/global/template.html | 18 ++++++++++++++++++
modules/web/src/typings/root.api.ts | 1 +
17 files changed, 108 insertions(+), 1 deletion(-)
diff --git a/charts/kubernetes-dashboard/values.yaml b/charts/kubernetes-dashboard/values.yaml
index cc7db3f365c9..1ff579b61f27 100644
--- a/charts/kubernetes-dashboard/values.yaml
+++ b/charts/kubernetes-dashboard/values.yaml
@@ -84,6 +84,8 @@ app:
# resourceAutoRefreshTimeInterval: 10
# # Hide all access denied warnings in the notification panel
# disableAccessDeniedNotifications: false
+ # # Hide all namespaces option in namespace selection dropdown to avoid accidental selection in large clusters thus preventing OOM errors
+ # hideAllNamespaces: false
# # Namespace that should be selected by default after logging in.
# defaultNamespace: default
# # List of namespaces that should be presented to user without namespace list privileges.
diff --git a/modules/web/i18n/de/messages.de.xlf b/modules/web/i18n/de/messages.de.xlf
index 738785464d63..036f36645b5a 100644
--- a/modules/web/i18n/de/messages.de.xlf
+++ b/modules/web/i18n/de/messages.de.xlf
@@ -2672,6 +2672,14 @@
Owner
Owner
+
+ Hide All Namespaces option
+ Hide All Namespaces option
+
+
+ Hides all-namespaces option from the namespaces dropdown list in UI.
+ Hides all-namespaces option from the namespaces dropdown list in UI.
+