Skip to content

Commit

Permalink
fixed theme for modals
Browse files Browse the repository at this point in the history
  • Loading branch information
soaibsafi committed Jun 9, 2024
1 parent 0b1c6d9 commit b9dab90
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 8 deletions.
31 changes: 31 additions & 0 deletions frontend/src/assets/style/Modal.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
.modal-content {
background-color: var(--background-color);
color: var(--primary-text-color);
}

.modal-header {
border-bottom: 1px solid var(--border-color);
}

.modal-footer {
border-top: 1px solid var(--border-color);
}

.modal-title {
color: var(--foreground-color);
}

.btn-close:hover {
color: var(--select-hover);
}

.modal-body p {
color: var(--primary-text-color);
}
.modal-header .btn-close {
display: none;
}

.modal-footer .btn {
box-shadow: none;
}
14 changes: 7 additions & 7 deletions frontend/src/components/Utils/Modals/ConfirmModal.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useState } from 'react';
import React from 'react';
import {
MDBBtn,
MDBModal,
Expand All @@ -9,7 +9,7 @@ import {
MDBModalBody,
MDBModalFooter,
} from 'mdb-react-ui-kit';

import '../../../assets/style/Modal.css'

const ConfirmModal = ({ isOpen, onClose, title, message, onConfirm }) => {
const toggleOpen = () => onClose();
Expand All @@ -27,13 +27,13 @@ const ConfirmModal = ({ isOpen, onClose, title, message, onConfirm }) => {
onClose={toggleOpen}
tabIndex='-1'>
<MDBModalDialog>
<MDBModalContent>
<MDBModalHeader>
<MDBModalTitle>{title}</MDBModalTitle>
<MDBModalContent className='model-content'>
<MDBModalHeader className='modal-header'>
<MDBModalTitle className='modal-title'>{title}</MDBModalTitle>
<MDBBtn className='btn-close' color='none' onClick={toggleOpen}></MDBBtn>
</MDBModalHeader>
<MDBModalBody> <p>{message}</p></MDBModalBody>
<MDBModalFooter>
<MDBModalBody className='modal-body'> <p>{message}</p></MDBModalBody>
<MDBModalFooter className='modal-footer'>
<MDBBtn color='secondary' onClick={toggleOpen}>
Close
</MDBBtn>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/Utils/Modals/MessageModal.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useState } from "react";
import React from "react";
import {
MDBBtn,
MDBModal,
Expand Down

0 comments on commit b9dab90

Please sign in to comment.