Commit 9ab36c49 authored by Luke Schoen's avatar Luke Schoen Committed by Thibaut Sardan
Browse files

fix: Fixes #494 Drag vs Context menu. Import options page error and colour (#496)

* fix: Fixes #494 drag and context menu. import options spacing for error

* refactor: Remove css class that is not being used
parent 21ca5d69
Pipeline #35481 passed with stages
in 9 minutes and 56 seconds
......@@ -218,7 +218,6 @@ class AccountImportOptions extends Component {
`${packageNS}:account.import.phrase.label_msg_recover_phrase`
)}
</p>
<FetherForm.Field
as='textarea'
label={i18n.t(
......@@ -245,14 +244,14 @@ class AccountImportOptions extends Component {
{signerCard}
{spacer}
{!importingFromSigner && phraseCard}
<p>{error}</p>
<nav className='form-nav -space-around'>
{currentStep > 1 && (
<p className='error-import-account'>{error}</p>
{currentStep > 1 && (
<nav className='form-nav -space-around'>
<button className='button -back' onClick={history.goBack}>
{i18n.t(`${packageNS}:navigation.back`)}
</button>
)}
</nav>
</nav>
)}
</div>
</RequireHealthOverlay>
);
......
......@@ -96,14 +96,14 @@ class CreateAccount extends Component {
</div>
</div>
<nav className='footer-nav'>
{step > 1 ? (
<div className='footer-nav_status'>
<Health />
</div>
) : (
<div className='footer-nav_option'>
{isImport ? null : (
{isImport ? null : (
<nav className='footer-nav'>
{step > 1 ? (
<div className='footer-nav_status'>
<Health />
</div>
) : (
<div className='footer-nav_option'>
<p>
{i18n.t(`${packageNS}:account.import.question`)}
<button
......@@ -113,10 +113,10 @@ class CreateAccount extends Component {
{i18n.t(`${packageNS}:account.import.title`)}
</button>
</p>
)}
</div>
)}
</nav>
</div>
)}
</nav>
)}
</React.Fragment>
);
}
......
.error-import-account {
color: red;
font-size: ms(0);
margin-top: 0.25rem;
text-align: center;
}
.recover-from-seed-phrase {
.form_field textarea {
height: 2.5rem;
}
}
......@@ -14,8 +14,6 @@ body {
font-size: ms(0);
line-height: ms(0) * 1.3;
position: relative;
/* https://electronjs.org/docs/api/frameless-window#draggable-region */
-webkit-app-region: drag;
}
.hidden {
......@@ -54,10 +52,22 @@ textarea,
.header-nav_left, /* i.e. back button in header */
.header-nav_right, /* i.e. menu */
.window_content, /* i.e. main body (e.g. accounts list) */
.footer-nav,
.text {
-webkit-app-region: no-drag;
}
.header-nav_title,
.footer-nav {
/**
* Right-clicking to trigger the 'contextmenu' event that displays the Fether context menu
* only works on elements whose styles are `-webkit-app-region: drag;`
*
* Reference: https://electronjs.org/docs/api/frameless-window#draggable-region
*/
-webkit-app-region: drag;
}
h1, /* i.e. Send Ether title */
.account.-header,
.status,
......
......@@ -23,6 +23,7 @@
@import './assets/sass/components/logo'
@import './assets/sass/components/token'
@import './assets/sass/components/account'
@import './assets/sass/components/account-import'
@import './assets/sass/components/accounts-list'
@import './assets/sass/components/status'
@import './assets/sass/components/header-nav'
......
......@@ -67,7 +67,7 @@ export class InputFile extends React.PureComponent {
disableClick
>
{({ open }) => (
<div className='dropzone -md'>
<div className='dropzone -sm'>
<label htmlFor='backupKeyfile'>{label}</label>
<button type='button' className='button' onClick={() => open()}>
{i18n.t(`${packageNS}:ui.form_input_file.select_file`)}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment