mirror of
https://github.com/ajnart/homarr.git
synced 2025-11-10 15:35:55 +01:00
✨Re-add the docker component
This commit is contained in:
@@ -7,17 +7,9 @@ import { useTranslation } from 'next-i18next';
|
||||
import { useEffect, useState } from 'react';
|
||||
|
||||
import { useConfigContext } from '../../config/provider';
|
||||
import { IModule } from '../ModuleTypes';
|
||||
import ContainerActionBar from './ContainerActionBar';
|
||||
import DockerTable from './DockerTable';
|
||||
|
||||
export const DockerModule: IModule = {
|
||||
title: 'Docker',
|
||||
icon: IconBrandDocker,
|
||||
component: DockerMenuButton,
|
||||
id: 'docker',
|
||||
};
|
||||
|
||||
export default function DockerMenuButton(props: any) {
|
||||
const [opened, setOpened] = useState(false);
|
||||
const [containers, setContainers] = useState<Docker.ContainerInfo[]>([]);
|
||||
@@ -61,8 +53,7 @@ export default function DockerMenuButton(props: any) {
|
||||
if (!dockerEnabled) {
|
||||
return null;
|
||||
}
|
||||
// Check if the user has at least one container
|
||||
if (containers.length < 1) return null;
|
||||
|
||||
return (
|
||||
<>
|
||||
<Drawer
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
export { DockerModule } from './DockerModule';
|
||||
Reference in New Issue
Block a user