colocate the base modal styles with the modal component (#9151)

finalizes the colocation of styles with the consuming components.
feature/default_network_editable
Brad Decker 4 years ago committed by GitHub
parent 163f45beed
commit b2813f0b54
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      ui/app/components/app/modals/fade-modal.js
  2. 40
      ui/app/components/app/modals/index.scss
  3. 1
      ui/app/css/itcss/components/index.scss
  4. 30
      ui/app/css/itcss/components/modal.scss

@ -192,7 +192,7 @@ class FadeModal extends Component {
const backdrop = this.props.backdrop const backdrop = this.props.backdrop
? ( ? (
<div <div
className="backdrop" className="modal__backdrop"
style={backdropStyle} style={backdropStyle}
onClick={this.props.closeOnClick onClick={this.props.closeOnClick
? this.handleBackdropClick ? this.handleBackdropClick
@ -208,7 +208,7 @@ class FadeModal extends Component {
<span> <span>
<div className="modal" style={modalStyle}> <div className="modal" style={modalStyle}>
<div <div
className="content" className="modal__content"
ref={(el) => (this.content = el)} ref={(el) => (this.content = el)}
tabIndex="-1" tabIndex="-1"
style={contentStyle} style={contentStyle}

@ -1,14 +1,46 @@
@import 'account-details-modal/index'; @import 'account-details-modal/index';
@import 'account-modal-container/index'; @import 'account-modal-container/index';
@import 'add-to-addressbook-modal/index';
@import 'cancel-transaction/index'; @import 'cancel-transaction/index';
@import 'confirm-remove-account/index'; @import 'confirm-remove-account/index';
@import 'deposit-ether-modal/index'; @import 'deposit-ether-modal/index';
@import 'edit-approval-permission/index';
@import 'export-private-key-modal/index'; @import 'export-private-key-modal/index';
@import 'hide-token-confirmation-modal/index'; @import 'hide-token-confirmation-modal/index';
@import 'metametrics-opt-in-modal/index';
@import 'new-account-modal/index';
@import 'notification-modal/index'; @import 'notification-modal/index';
@import 'qr-scanner/index'; @import 'qr-scanner/index';
@import 'transaction-confirmed/index'; @import 'transaction-confirmed/index';
@import 'metametrics-opt-in-modal/index';
@import './add-to-addressbook-modal/index'; .modal {
@import './edit-approval-permission/index'; z-index: 1050;
@import './new-account-modal/index'; position: fixed;
width: 500px;
transform: translate3d(-50%, -50%, 0);
top: 50%;
left: 50%;
&__content {
margin: 0;
background-color: white;
animation-fill-mode: forwards;
}
&__backdrop {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 1040;
background-color: #373a47;
animation-fill-mode: forwards;
animation-duration: 0.3s;
}
& > div:focus {
outline: none !important;
}
}

@ -6,7 +6,6 @@
@import '../../../components/ui/icon/preloader/index'; @import '../../../components/ui/icon/preloader/index';
@import './footer'; @import './footer';
@import './network'; @import './network';
@import './modal';
@import './newui-sections'; @import './newui-sections';
@import './send'; @import './send';
@import './loading-overlay'; @import './loading-overlay';

@ -1,30 +0,0 @@
.modal {
z-index: 1050;
position: fixed;
width: 500px;
transform: translate3d(-50%, -50%, 0);
top: 50%;
left: 50%;
.content {
margin: 0;
background-color: white;
animation-fill-mode: forwards;
}
}
.backdrop {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 1040;
background-color: #373a47;
animation-fill-mode: forwards;
animation-duration: 0.3s;
}
.modal > div:focus {
outline: none !important;
}
Loading…
Cancel
Save