import { FileCode, Lock } from 'lucide-react'; import { useCurrentStateAndParams } from '@uirouter/react'; import { PageHeader } from '@@/PageHeader'; import { Tab, WidgetTabs, findSelectedTabIndex } from '@@/Widget/WidgetTabs'; import { ConfigMapsDatatable } from './ConfigMapsDatatable'; import { SecretsDatatable } from './SecretsDatatable'; const tabs: Tab[] = [ { name: 'ConfigMaps', icon: FileCode, widget: , selectedTabParam: 'configmaps', }, { name: 'Secrets', icon: Lock, widget: , selectedTabParam: 'secrets', }, ]; export function ConfigmapsAndSecretsView() { const currentTabIndex = findSelectedTabIndex( useCurrentStateAndParams(), tabs ); return ( <> <>
{tabs[currentTabIndex].widget}
); }