Simplified code, removed not needed code
This commit is contained in:
parent
98b565d41a
commit
be8023a087
@ -236,17 +236,13 @@ function Home({ initialSettings }) {
|
||||
}
|
||||
})
|
||||
|
||||
const tabs = useMemo( () => {
|
||||
if (!settings.layout) return [];
|
||||
|
||||
return [
|
||||
...new Set(
|
||||
Object.keys(settings.layout).map(
|
||||
(groupName) => settings.layout[groupName]?.tab
|
||||
).filter(group => group)
|
||||
)
|
||||
]
|
||||
}, [settings.layout]);
|
||||
const tabs = useMemo( () => [
|
||||
...new Set(
|
||||
Object.keys(settings.layout ?? {}).map(
|
||||
(groupName) => settings.layout[groupName]?.tab
|
||||
).filter(group => group)
|
||||
)
|
||||
], [settings.layout]);
|
||||
|
||||
if (!activeTab) {
|
||||
const initialTab = decodeURI(asPath.substring(asPath.indexOf("#") + 1));
|
||||
|
||||
@ -286,7 +286,6 @@ export async function servicesFromKubernetes() {
|
||||
export function cleanServiceGroups(groups) {
|
||||
return groups.map((serviceGroup) => ({
|
||||
name: serviceGroup.name,
|
||||
tabs: serviceGroup?.tabs,
|
||||
services: serviceGroup.services.map((service) => {
|
||||
const cleanedService = { ...service };
|
||||
if (cleanedService.showStats !== undefined) cleanedService.showStats = JSON.parse(cleanedService.showStats);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user