import clsx from 'clsx'; import { Authorized } from '@/portainer/hooks/useUser'; import { Link } from '@/portainer/components/Link'; import { react2angular } from '@/react-tools/react2angular'; import { DockerContainerStatus } from '@/docker/containers/types'; import styles from './ContainerQuickActions.module.css'; interface QuickActionsState { showQuickActionAttach: boolean; showQuickActionExec: boolean; showQuickActionInspect: boolean; showQuickActionLogs: boolean; showQuickActionStats: boolean; } interface Props { taskId?: string; containerId?: string; nodeName: string; state: QuickActionsState; status: DockerContainerStatus; } export function ContainerQuickActions({ taskId, containerId, nodeName, state, status, }: Props) { if (taskId) { return ; } const isActive = ['starting', 'running', 'healthy', 'unhealthy'].includes( status ); return (
{state.showQuickActionLogs && (