PluginProbe
GiveWP – Donation Plugin and Fundraising Platform / 4.17.0
GiveWP – Donation Plugin and Fundraising Platform v4.17.0
4.17.0 4.16.9 4.16.8.1 4.16.8 4.16.7.2 4.16.7.1 4.16.7 4.16.6.1 4.16.6 4.16.5.1 4.16.5 4.16.4 4.16.3 4.16.2 4.16.1 4.16.0 4.15.5 4.15.4 4.15.3 4.15.2 4.15.1 4.15.0 2.3.0 2.3.1 2.3.2 All 256 releases
give / src / Campaigns / resources / admin / components / CampaignDetailsPage / Components / ArchiveCampaignDialog.tsx

ArchiveCampaignDialog.tsx in GiveWP – Donation Plugin and Fundraising Platform 4.17.0, at src/Campaigns/resources/admin/components/CampaignDetailsPage/Components/ArchiveCampaignDialog.tsx

54 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 import {__} from '@wordpress/i18n'
2 import ModalDialog from '@givewp/components/AdminUI/ModalDialog';
3 import {ErrorIcon} from '../../Icons';
4 import styles from '../CampaignDetailsPage.module.scss'
5
6 /**
7 * @since 4.0.0
8 */
9 export default ({
10 isOpen,
11 title,
12 handleClose,
13 handleConfirm,
14 className,
15 }: {
16 isOpen: boolean;
17 handleClose: () => void;
18 handleConfirm: () => void;
19 title: string;
20 className?: string;
21 }) => {
22 return (
23 <ModalDialog
24 icon={<ErrorIcon />}
25 isOpen={isOpen}
26 showHeader={true}
27 handleClose={handleClose}
28 title={title}
29 wrapperClassName={className}
30 >
31 <>
32 <div className={styles.archiveDialogContent}>
33 {__('Are you sure you want to archive your campaign? All forms associated with this campaign will be inaccessible to donors.', 'give')}
34 </div>
35 <div className={styles.archiveDialogButtons}>
36 <button
37 className={styles.cancelButton}
38 onClick={handleClose}
39
40 >
41 {__('Cancel', 'give')}
42 </button>
43 <button
44 className={styles.confirmButton}
45 onClick={handleConfirm}
46 >
47 {__('Archive campaign', 'give')}
48 </button>
49 </div>
50 </>
51 </ModalDialog>
52 );
53 }
54