From 9aab99beea5af56f2329eb6de421617994435354 Mon Sep 17 00:00:00 2001 From: jackyzha0 Date: Sat, 6 Mar 2021 16:18:50 -0800 Subject: paste modal fixes --- frontend/src/components/Form/Button.js | 1 + frontend/src/components/modals/PasswordModal.js | 26 ++++++-------- frontend/src/components/modals/PasteModal.js | 47 ++++++++++++------------- frontend/src/components/modals/shared.js | 11 ++---- 4 files changed, 35 insertions(+), 50 deletions(-) diff --git a/frontend/src/components/Form/Button.js b/frontend/src/components/Form/Button.js index 146919a..290e52a 100644 --- a/frontend/src/components/Form/Button.js +++ b/frontend/src/components/Form/Button.js @@ -6,6 +6,7 @@ const Base = css` ${Rounded} ${ButtonLike} margin-right: 2em; + cursor: pointer; ` const Primary = css` diff --git a/frontend/src/components/modals/PasswordModal.js b/frontend/src/components/modals/PasswordModal.js index 637e20a..64e984b 100644 --- a/frontend/src/components/modals/PasswordModal.js +++ b/frontend/src/components/modals/PasswordModal.js @@ -1,7 +1,7 @@ import React, { useRef } from 'react'; import Modal from 'react-modal'; import { Password } from '../Inputs' -import {RightPad, LeftPad, ModalHeader, Padding, modalStyles} from './shared' +import {RightPad, LeftPad, ModalHeader, Padding, modalStyles, Form} from './shared' import Error from '../Err'; const PasswordModal = (props) => { @@ -20,21 +20,15 @@ const PasswordModal = (props) => { style={modalStyles} contentLabel="enter paste password" > -
- - 🚧 err: password protected - - - - - - - - - -
+
+ 🚧 err: password protected + + + + + ); } diff --git a/frontend/src/components/modals/PasteModal.js b/frontend/src/components/modals/PasteModal.js index ff2e639..a6d637f 100644 --- a/frontend/src/components/modals/PasteModal.js +++ b/frontend/src/components/modals/PasteModal.js @@ -1,6 +1,6 @@ import React from 'react'; import Modal from 'react-modal'; -import {LeftPad, ModalHeader, modalStyles, RightPad} from './shared' +import {Form, LeftPad, ModalHeader, modalStyles, RightPad} from './shared' import { useHistory } from 'react-router-dom'; import { Text } from '../Inputs' import { useClipboard } from 'use-clipboard-copy'; @@ -24,30 +24,27 @@ const PasteModal = (props) => { style={modalStyles} contentLabel="paste created" > -
- - 📎 paste created - - - - - - - - -
+
+ + 📎 paste created + + + + + ); } diff --git a/frontend/src/components/modals/shared.js b/frontend/src/components/modals/shared.js index 7c38dc2..0336818 100644 --- a/frontend/src/components/modals/shared.js +++ b/frontend/src/components/modals/shared.js @@ -12,15 +12,8 @@ export const modalStyles = { }; export const Form = styled.form` - z-index: 999; -` - -export const RightPad = styled.div` - margin-right: 3em; -` - -export const LeftPad = styled.div` - margin-left: 2em; + margin: 2em; + margin-right: 3em; ` export const ModalHeader = styled.h3` -- cgit v1.2.3