Spaces:
Configuration error
Configuration error
Download frontend/src/components/shared/modals/confirmation-modals/danger-modal.tsx from flyingdarkdev/README: direct link, hf CLI and curl.
- Browser
- Download file 769 Bytes
-
https://huggingface.co/spaces/flyingdarkdev/README/resolve/main/frontend/src/components/shared/modals/confirmation-modals/danger-modal.tsx
- Command line
-
hf download hf://spaces/flyingdarkdev/README/frontend/src/components/shared/modals/confirmation-modals/danger-modal.tsx
-
curl -L -o danger-modal.tsx https://huggingface.co/spaces/flyingdarkdev/README/resolve/main/frontend/src/components/shared/modals/confirmation-modals/danger-modal.tsx
769 Bytes
| import { BaseModal } from "./base-modal"; | |
| interface DangerModalProps { | |
| testId?: string; | |
| title: string; | |
| description: string; | |
| buttons: { | |
| danger: { text: string; onClick: () => void }; | |
| cancel: { text: string; onClick: () => void }; | |
| }; | |
| } | |
| export function DangerModal({ | |
| testId, | |
| title, | |
| description, | |
| buttons, | |
| }: DangerModalProps) { | |
| return ( | |
| <BaseModal | |
| testId={testId} | |
| title={title} | |
| description={description} | |
| buttons={[ | |
| { | |
| text: buttons.danger.text, | |
| onClick: buttons.danger.onClick, | |
| className: "bg-danger", | |
| }, | |
| { | |
| text: buttons.cancel.text, | |
| onClick: buttons.cancel.onClick, | |
| className: "bg-neutral-500", | |
| }, | |
| ]} | |
| /> | |
| ); | |
| } | |