Ui 2 small UI fixes
This commit is contained in:
Jaco Greeff 2017-05-09 17:31:48 +02:00 committed by GitHub
parent 4007865bec
commit 861cbb874b
6 changed files with 31 additions and 26 deletions

View File

@ -34,16 +34,12 @@
} }
.icon { .icon {
align-items: center;
background: rgb(167, 151, 0); background: rgb(167, 151, 0);
border-radius: 50%; border-radius: 50%;
display: flex;
flex: 0 0 5em;
flex-direction: column;
height: 5em; height: 5em;
justify-content: center;
margin-right: 1.5em; margin-right: 1.5em;
padding: 0.75em; padding: 0.75em;
text-align: center;
width: 5em; width: 5em;
img { img {
@ -51,12 +47,10 @@
padding: 0; padding: 0;
} }
svg { i {
fill: white !important; color: white;
font-size: 3.5em !important; font-size: 3.5rem;
height: 3.5em !important; margin: 0.75rem -0.125rem;
margin: 0 !important;
width: 3.5em !important;
} }
} }
} }

View File

@ -120,7 +120,7 @@ $backgroundOverlay: rgba(255, 255, 255, 0.95);
font-size: 3em; font-size: 3em;
position: absolute; position: absolute;
right: 1rem; right: 1rem;
top: 0.5rem; top: 1.5rem;
z-index: 100; z-index: 100;
i { i {

View File

@ -28,35 +28,45 @@ export default class TypeIcon extends Component {
} }
render () { render () {
const { className, createStore, type } = this.props; const { className } = this.props;
return (
<div className={ className }>
{ this.getIcon() }
</div>
);
}
getIcon () {
const { createStore, type } = this.props;
const { createType, stage } = createStore; const { createType, stage } = createStore;
if (stage === STAGE_INFO) { if (stage === STAGE_INFO) {
return <DoneIcon className={ className } />; return <DoneIcon />;
} }
switch (type || createType) { switch (type || createType) {
case 'fromGeth': case 'fromGeth':
return <FileUploadIcon className={ className } />; return <FileUploadIcon />;
case 'fromJSON': case 'fromJSON':
return <FileIcon className={ className } />; return <FileIcon />;
case 'fromPhrase': case 'fromPhrase':
return <KeyboardIcon className={ className } />; return <KeyboardIcon />;
case 'fromPresale': case 'fromPresale':
return <MembershipIcon className={ className } />; return <MembershipIcon />;
case 'fromQr': case 'fromQr':
return <QrIcon className={ className } />; return <QrIcon />;
case 'fromRaw': case 'fromRaw':
return <KeyIcon className={ className } />; return <KeyIcon />;
case 'fromNew': case 'fromNew':
default: default:
return <AccountsIcon className={ className } />; return <AccountsIcon />;
} }
} }
} }

View File

@ -111,9 +111,8 @@
.icon { .icon {
color: rgb(167, 151, 0) !important; color: rgb(167, 151, 0) !important;
flex: 0 0 56px; flex: 0 0 56px;
height: 56px !important; font-size: 56px;
margin-right: 0.75em; margin: 1.5rem 1.5rem 0 0;
width: 56px !important;
} }
.info { .info {

View File

@ -19,7 +19,7 @@ import React, { Component, PropTypes } from 'react';
import { FormattedMessage } from 'react-intl'; import { FormattedMessage } from 'react-intl';
import { Button, Form, Input, InputAddress, ModalBox, Portal } from '~/ui'; import { Button, Form, Input, InputAddress, ModalBox, Portal } from '~/ui';
import { AddIcon, AddressesIcon, CancelIcon } from '~/ui/Icons'; import { AddIcon, AddressIcon, CancelIcon } from '~/ui/Icons';
import Store from './store'; import Store from './store';
@ -97,7 +97,7 @@ export default class AddAddress extends Component {
return ( return (
<ModalBox <ModalBox
icon={ <AddressesIcon /> } icon={ <AddressIcon /> }
summary={ summary={
<FormattedMessage <FormattedMessage
id='addAddress.header' id='addAddress.header'

View File

@ -276,6 +276,7 @@ export default class LoadContract extends Component {
return [ return [
<Button <Button
icon={ <CancelIcon /> } icon={ <CancelIcon /> }
key='cancel'
label={ label={
<FormattedMessage <FormattedMessage
id='loadContract.button.cancel' id='loadContract.button.cancel'
@ -287,6 +288,7 @@ export default class LoadContract extends Component {
<Button <Button
disabled={ this.state.selected === -1 } disabled={ this.state.selected === -1 }
icon={ <CheckIcon /> } icon={ <CheckIcon /> }
key='load'
label={ label={
<FormattedMessage <FormattedMessage
id='loadContract.button.load' id='loadContract.button.load'