Download client/src/components/Input/Generations/Button.tsx from Zhitomir/chat: direct link, hf CLI and curl.
- Browser
- Download file 688 Bytes
-
https://huggingface.co/spaces/Zhitomir/chat/resolve/main/client/src/components/Input/Generations/Button.tsx
- Command line
-
hf download hf://spaces/Zhitomir/chat/client/src/components/Input/Generations/Button.tsx
-
curl -L -o Button.tsx https://huggingface.co/spaces/Zhitomir/chat/resolve/main/client/src/components/Input/Generations/Button.tsx
688 Bytes
| import { cn, removeFocusOutlines } from '~/utils/'; | |
| export default function Button({ | |
| type = 'regenerate', | |
| children, | |
| onClick, | |
| className = '', | |
| }: { | |
| type?: 'regenerate' | 'continue' | 'stop'; | |
| children: React.ReactNode; | |
| onClick: (e: React.MouseEvent<HTMLButtonElement>) => void; | |
| className?: string; | |
| }) { | |
| return ( | |
| <button | |
| data-testid={`${type}-generation-button`} | |
| className={cn( | |
| 'custom-btn btn-neutral relative -z-0 whitespace-nowrap border-0 md:border', | |
| removeFocusOutlines, | |
| className, | |
| )} | |
| onClick={onClick} | |
| > | |
| <div className="flex w-full items-center justify-center gap-2">{children}</div> | |
| </button> | |
| ); | |
| } | |