File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
src/components/ResourceBrowser Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -49,13 +49,18 @@ const ResourceBrowser: React.FC = () => {
49
49
)
50
50
51
51
const sortedClusterList : ClusterDetail [ ] = useMemo (
52
+ ( ) => sortObjectArrayAlphabetically ( detailClusterList || clusterListMinData || [ ] , 'name' ) ,
53
+ [ detailClusterList , clusterListMinData ] ,
54
+ )
55
+
56
+ const filteredSortedCluserList = useMemo (
52
57
( ) =>
53
- sortObjectArrayAlphabetically ( detailClusterList || clusterListMinData || [ ] , 'name' ) . filter (
58
+ sortedClusterList . filter (
54
59
( option ) =>
55
60
! ( window . _env_ . HIDE_DEFAULT_CLUSTER && option . id === DEFAULT_CLUSTER_ID ) &&
56
61
! option . isVirtualCluster ,
57
62
) ,
58
- [ detailClusterList , clusterListMinData ] ,
63
+ [ sortedClusterList ] ,
59
64
)
60
65
61
66
const renderContent = ( ) => {
@@ -66,7 +71,7 @@ const ResourceBrowser: React.FC = () => {
66
71
return (
67
72
< ClusterListView
68
73
parentRef = { parentRef }
69
- clusterOptions = { sortedClusterList }
74
+ clusterOptions = { filteredSortedCluserList }
70
75
clusterListLoader = { detailClusterListLoading }
71
76
initialLoading = { initialLoading }
72
77
refreshData = { reloadDetailClusterList }
You can’t perform that action at this time.
0 commit comments