import { faMinusCircle as deleteIcon } from '@fortawesome/free-solid-svg-icons'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; import { useToggle } from '@shlinkio/shlink-frontend-kit'; import classNames from 'classnames'; import type { FC, PropsWithChildren } from 'react'; import type { FCWithDeps } from '../container/utils'; import { componentFactory, useDependencies } from '../container/utils'; import type { ServerWithId } from './data'; import type { DeleteServerModalProps } from './DeleteServerModal'; export type DeleteServerButtonProps = PropsWithChildren<{ server: ServerWithId; className?: string; textClassName?: string; }>; type DeleteServerButtonDeps = { DeleteServerModal: FC; }; const DeleteServerButton: FCWithDeps = ( { server, className, children, textClassName }, ) => { const { DeleteServerModal } = useDependencies(DeleteServerButton); const [isModalOpen, , showModal, hideModal] = useToggle(); return ( <> ); }; export const DeleteServerButtonFactory = componentFactory(DeleteServerButton, ['DeleteServerModal']);