File tree Expand file tree Collapse file tree
src/components/Elements/Modal Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ import { Button , Modal } from 'src/components/Elements'
2+ import './confirmModal.css'
3+
4+ interface LogoutModalProps {
5+ showModal : boolean
6+ title : string
7+ description : string
8+ onClose : ( ) => void
9+ onConfirm : ( ) => void
10+ }
11+
12+ export const ConfirmModal = ( {
13+ showModal,
14+ title,
15+ description,
16+ onClose,
17+ onConfirm,
18+ } : LogoutModalProps ) => {
19+ return (
20+ < Modal
21+ showModal = { showModal }
22+ onClose = { onClose }
23+ header = { {
24+ title : title ,
25+ className : undefined ,
26+ icon : undefined ,
27+ } }
28+ className = "confirmModal" >
29+ < div className = "content" >
30+ < p className = "description" > { description } </ p >
31+ < div className = "buttons" >
32+ < Button onClick = { onClose } size = "medium" >
33+ Cancel
34+ </ Button >
35+ < Button onClick = { onConfirm } size = "medium" >
36+ Confirm
37+ </ Button >
38+ </ div >
39+ </ div >
40+ </ Modal >
41+ )
42+ }
Original file line number Diff line number Diff line change 1+ @media (min-width : 768px ) {
2+ .confirmModal {
3+ width : 400px ;
4+ overflow-y : hidden;
5+ }
6+ }
7+
8+ .confirmModal .content {
9+ display : flex;
10+ flex-direction : column;
11+ }
12+ .confirmModal .description {
13+ font-size : 1em ;
14+ }
15+ .confirmModal .buttons {
16+ display : flex;
17+ flex-direction : row;
18+ gap : 10px ;
19+ align-self : flex-end;
20+ }
Original file line number Diff line number Diff line change 1+ export * from './ConfirmModal'
12export * from './Modal'
You can’t perform that action at this time.
0 commit comments