aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/components
diff options
context:
space:
mode:
authorChi Kei Chan <chikeichan@gmail.com>2017-09-05 06:55:14 +0800
committerChi Kei Chan <chikeichan@gmail.com>2017-09-05 06:57:43 +0800
commit75c3009f839f94a19830673673f4b9ac25342633 (patch)
tree2420c6c282bfd562cac8ed9d6f5e8867d6494002 /ui/app/components
parent9213789c44beaf4bf734bc6192dc646d706d5c44 (diff)
downloadtangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.tar
tangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.tar.gz
tangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.tar.bz2
tangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.tar.lz
tangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.tar.xz
tangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.tar.zst
tangerine-wallet-browser-75c3009f839f94a19830673673f4b9ac25342633.zip
Fix header style; Address comments
Diffstat (limited to 'ui/app/components')
-rw-r--r--ui/app/components/dropdowns/account-selection-dropdown.js2
-rw-r--r--ui/app/components/dropdowns/components/account-dropdowns.js31
-rw-r--r--ui/app/components/dropdowns/components/dropdown.js11
-rw-r--r--ui/app/components/dropdowns/network-dropdown.js28
-rw-r--r--ui/app/components/menu-droppo.js4
5 files changed, 37 insertions, 39 deletions
diff --git a/ui/app/components/dropdowns/account-selection-dropdown.js b/ui/app/components/dropdowns/account-selection-dropdown.js
index b1f4d68ce..7a8502d18 100644
--- a/ui/app/components/dropdowns/account-selection-dropdown.js
+++ b/ui/app/components/dropdowns/account-selection-dropdown.js
@@ -15,7 +15,7 @@ module.exports = AccountSelectionDropdown
// TODO: selectedAddress is not defined... should we use selected?
AccountSelectionDropdown.prototype.render = function () {
const { selected, network, identities, style, dropdownWrapperStyle, menuItemStyles } = this.props
- console.log({style})
+
return h(AccountDropdowns, {
enableAccountOptions: false,
enableAccountsSelector: true,
diff --git a/ui/app/components/dropdowns/components/account-dropdowns.js b/ui/app/components/dropdowns/components/account-dropdowns.js
index be9245c0e..1961a61b5 100644
--- a/ui/app/components/dropdowns/components/account-dropdowns.js
+++ b/ui/app/components/dropdowns/components/account-dropdowns.js
@@ -181,7 +181,6 @@ class AccountDropdowns extends Component {
h('span', {
style: {
marginLeft: '20px',
- fontSize: '18px',
fontFamily: 'DIN OT',
fontSize: '16px',
lineHeight: '23px',
@@ -215,7 +214,6 @@ class AccountDropdowns extends Component {
h('span', {
style: {
marginLeft: '20px',
- fontSize: '18px',
marginBottom: '5px',
fontFamily: 'DIN OT',
fontSize: '16px',
@@ -231,6 +229,10 @@ class AccountDropdowns extends Component {
renderAccountOptions () {
const { actions, dropdownWrapperStyle, useCssTransition } = this.props
const { optionsMenuActive, menuItemStyles } = this.state
+ const dropdownMenuItemStyle = {
+ fontFamily: 'DIN OT',
+ fontSize: 16,
+ }
return h(
Dropdown,
@@ -262,10 +264,7 @@ class AccountDropdowns extends Component {
this.props.actions.showAccountDetailModal()
},
style: Object.assign(
- {
- fontFamily: 'DIN OT',
- fontSize: 16,
- },
+ dropdownMenuItemStyle,
menuItemStyles,
),
},
@@ -281,10 +280,7 @@ class AccountDropdowns extends Component {
global.platform.openWindow({ url })
},
style: Object.assign(
- {
- fontFamily: 'DIN OT',
- fontSize: 16,
- },
+ dropdownMenuItemStyle,
menuItemStyles,
),
},
@@ -300,10 +296,7 @@ class AccountDropdowns extends Component {
copyToClipboard(checkSumAddress)
},
style: Object.assign(
- {
- fontFamily: 'DIN OT',
- fontSize: 16,
- },
+ dropdownMenuItemStyle,
menuItemStyles,
),
},
@@ -317,10 +310,7 @@ class AccountDropdowns extends Component {
actions.requestAccountExport()
},
style: Object.assign(
- {
- fontFamily: 'DIN OT',
- fontSize: 16,
- },
+ dropdownMenuItemStyle,
menuItemStyles,
),
},
@@ -334,10 +324,7 @@ class AccountDropdowns extends Component {
actions.showAddTokenPage()
},
style: Object.assign(
- {
- fontFamily: 'DIN OT',
- fontSize: 16,
- },
+ dropdownMenuItemStyle,
menuItemStyles,
),
},
diff --git a/ui/app/components/dropdowns/components/dropdown.js b/ui/app/components/dropdowns/components/dropdown.js
index 1f35f0c70..c4b2c2550 100644
--- a/ui/app/components/dropdowns/components/dropdown.js
+++ b/ui/app/components/dropdowns/components/dropdown.js
@@ -8,7 +8,15 @@ const noop = () => {}
class Dropdown extends Component {
render () {
- const { isOpen, onClickOutside, style, innerStyle, children, useCssTransition } = this.props
+ const {
+ containerClassName,
+ isOpen,
+ onClickOutside,
+ style,
+ innerStyle,
+ children,
+ useCssTransition,
+ } = this.props
const innerStyleDefaults = extend({
borderRadius: '4px',
@@ -20,6 +28,7 @@ class Dropdown extends Component {
return h(
MenuDroppo,
{
+ containerClassName,
useCssTransition,
isOpen,
zIndex: 30,
diff --git a/ui/app/components/dropdowns/network-dropdown.js b/ui/app/components/dropdowns/network-dropdown.js
index 23af3f7e4..fa0bb899e 100644
--- a/ui/app/components/dropdowns/network-dropdown.js
+++ b/ui/app/components/dropdowns/network-dropdown.js
@@ -54,7 +54,7 @@ NetworkDropdown.prototype.render = function () {
fontFamily: 'DIN OT',
fontSize: '16px',
lineHeight: '20px',
- };
+ }
return h(Dropdown, {
useCssTransition: true,
@@ -72,10 +72,10 @@ NetworkDropdown.prototype.render = function () {
this.props.hideNetworkDropdown()
}
},
+ containerClassName: 'network-droppo',
zIndex: 11,
style: {
position: 'absolute',
- right: '2px',
top: '38px',
minWidth: '309px',
},
@@ -95,9 +95,9 @@ NetworkDropdown.prototype.render = function () {
[
providerType === 'mainnet' ? h('.network-check', '✓') : h('.network-check__transparent', '✓'),
h('.menu-icon.diamond'),
- h('span.network-name', {
+ h('span.network-name-item', {
style: {
- color: providerType === 'mainnet' ? '#ffffff' : '#9b9b9b'
+ color: providerType === 'mainnet' ? '#ffffff' : '#9b9b9b',
},
}, 'Main Ethereum Network'),
]
@@ -114,9 +114,9 @@ NetworkDropdown.prototype.render = function () {
[
providerType === 'ropsten' ? h('.network-check', '✓') : h('.network-check__transparent', '✓'),
h('.menu-icon.red-dot'),
- h('span.network-name', {
+ h('span.network-name-item', {
style: {
- color: providerType === 'ropsten' ? '#ffffff' : '#9b9b9b'
+ color: providerType === 'ropsten' ? '#ffffff' : '#9b9b9b',
},
}, 'Ropsten Test Network'),
]
@@ -133,9 +133,9 @@ NetworkDropdown.prototype.render = function () {
[
providerType === 'kovan' ? h('.network-check', '✓') : h('.network-check__transparent', '✓'),
h('.menu-icon.hollow-diamond'),
- h('span.network-name', {
+ h('span.network-name-item', {
style: {
- color: providerType === 'kovan' ? '#ffffff' : '#9b9b9b'
+ color: providerType === 'kovan' ? '#ffffff' : '#9b9b9b',
},
}, 'Kovan Test Network'),
]
@@ -152,9 +152,9 @@ NetworkDropdown.prototype.render = function () {
[
providerType === 'rinkeby' ? h('.network-check', '✓') : h('.network-check__transparent', '✓'),
h('.menu-icon.golden-square'),
- h('span.network-name', {
+ h('span.network-name-item', {
style: {
- color: providerType === 'rinkeby' ? '#ffffff' : '#9b9b9b'
+ color: providerType === 'rinkeby' ? '#ffffff' : '#9b9b9b',
},
}, 'Rinkeby Test Network'),
]
@@ -171,9 +171,9 @@ NetworkDropdown.prototype.render = function () {
[
activeNetwork === 'http://localhost:8545' ? h('.network-check', '✓') : h('.network-check__transparent', '✓'),
h('i.fa.fa-question-circle.fa-lg.menu-icon'),
- h('span.network-name', {
+ h('span.network-name-item', {
style: {
- color: activeNetwork === 'http://localhost:8545' ? '#ffffff' : '#9b9b9b'
+ color: activeNetwork === 'http://localhost:8545' ? '#ffffff' : '#9b9b9b',
},
}, 'Localhost 8545'),
]
@@ -192,9 +192,9 @@ NetworkDropdown.prototype.render = function () {
[
activeNetwork === 'custom' ? h('.check', '✓') : h('.network-check__transparent', '✓'),
h('i.fa.fa-question-circle.fa-lg.menu-icon'),
- h('span.network-name', {
+ h('span.network-name-item', {
style: {
- color: activeNetwork === 'custom' ? '#ffffff' : '#9b9b9b'
+ color: activeNetwork === 'custom' ? '#ffffff' : '#9b9b9b',
},
}, 'Custom RPC'),
]
diff --git a/ui/app/components/menu-droppo.js b/ui/app/components/menu-droppo.js
index 2f173544e..95b75f54c 100644
--- a/ui/app/components/menu-droppo.js
+++ b/ui/app/components/menu-droppo.js
@@ -13,6 +13,7 @@ function MenuDroppoComponent () {
}
MenuDroppoComponent.prototype.render = function () {
+ const { containerClassName = '' } = this.props
const speed = this.props.speed || '300ms'
const useCssTransition = this.props.useCssTransition
const zIndex = ('zIndex' in this.props) ? this.props.zIndex : 0
@@ -26,8 +27,9 @@ MenuDroppoComponent.prototype.render = function () {
style.zIndex = zIndex
return (
- h('.menu-droppo-container', {
+ h('div', {
style,
+ className: `.menu-droppo-container ${containerClassName}`,
}, [
h('style', `
.menu-droppo-enter {