mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Add buttons to quicky filter the current view by a specific namespace (#6677)
* Add quick namespace filtering in pods view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to HorizontalPodAutoscalers view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Leases view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to LimitRanges view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to ConfigMaps view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Remove last usage of legacy global Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to PodDisruptionBudgets view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to ResourceQuotas view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Secrets view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Remove last usage of legacy global secretsStore Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to CustomResources view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Events view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to HelmReleases view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Endpoints view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Remove last usage of legacy global endpointsStore Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Ingresses view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to NetworkPolicies view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to PortForwards view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Services view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to PersistentVolumeClaims view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to RoleBindings view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Roles view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to ServiceAccounts view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to CronJobs view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to DaemonSets view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Deployments view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to Jobs view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to StatefulSets view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Add quick namespace filtering to ReplicaSets view Signed-off-by: Sebastian Malton <sebastian@malton.name> * Remove last usage of legacy global replicaSetStore Signed-off-by: Sebastian Malton <sebastian@malton.name> * Fix up missing styles Signed-off-by: Sebastian Malton <sebastian@malton.name> * Fix tests Signed-off-by: Sebastian Malton <sebastian@malton.name> Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
1 parent
ab4a99bd93
commit
a546f3b8ae
79 files changed
+1184
-433
No files matched your search
+19
@@ -0,0 +1,19 @@
|
||||
/**
|
||||
* Copyright (c) OpenLens Authors. All rights reserved.
|
||||
* Licensed under MIT License. See LICENSE in root directory for more information.
|
||||
*/
|
||||
import { getInjectable } from "@ogre-tools/injectable";
|
||||
import namespaceStoreInjectable from "../store.injectable";
|
||||
|
||||
export type FilterByNamespace = (namespace: string) => void;
|
||||
|
||||
const filterByNamespaceInjectable = getInjectable({
|
||||
id: "filter-by-namespace",
|
||||
instantiate: (di): FilterByNamespace => {
|
||||
const namespaceStore = di.inject(namespaceStoreInjectable);
|
||||
|
||||
return (namespace) => namespaceStore.selectSingle(namespace);
|
||||
},
|
||||
});
|
||||
|
||||
export default filterByNamespaceInjectable;
|
||||
Reference in new issue
Block a user