Spaces:
Paused
Paused
Download novel-reader/src/components/ConfirmDialog.jsx from tanlang002/tupload07: direct link, hf CLI and curl.
- Browser
- Download file 660 Bytes
-
https://huggingface.co/spaces/tanlang002/tupload07/resolve/main/novel-reader/src/components/ConfirmDialog.jsx
- Command line
-
hf download hf://spaces/tanlang002/tupload07/novel-reader/src/components/ConfirmDialog.jsx
-
curl -L -o ConfirmDialog.jsx https://huggingface.co/spaces/tanlang002/tupload07/resolve/main/novel-reader/src/components/ConfirmDialog.jsx
660 Bytes
| export default function ConfirmDialog({ | |
| title = '确认操作', | |
| message = '', | |
| confirmText = '确定', | |
| cancelText = '取消', | |
| onConfirm, | |
| onCancel, | |
| }) { | |
| return ( | |
| <div className="confirm-mask" onClick={onCancel}> | |
| <div className="confirm-box" onClick={(event) => event.stopPropagation()}> | |
| <h3>{title}</h3> | |
| <p>{message}</p> | |
| <div className="confirm-actions"> | |
| <button className="btn ghost" onClick={onCancel}> | |
| {cancelText} | |
| </button> | |
| <button className="btn danger" onClick={onConfirm}> | |
| {confirmText} | |
| </button> | |
| </div> | |
| </div> | |
| </div> | |
| ); | |
| } | |