aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/components/dropdowns/account-options-dropdown.js
diff options
context:
space:
mode:
authorChi Kei Chan <chikeichan@gmail.com>2017-10-19 13:58:46 +0800
committerChi Kei Chan <chikeichan@gmail.com>2017-10-19 13:58:46 +0800
commitc8c773d6416f92c520a509a9811d73f68aa00fc0 (patch)
tree495a798eeb4a5272c80d93725f5146a6fbcf85c8 /ui/app/components/dropdowns/account-options-dropdown.js
parent5bdee96e73f65a0b369277e9c56b0afe5159e65b (diff)
parentde1da7d1b215ade650fc644adf63384a401dc240 (diff)
downloadtangerine-wallet-browser-c8c773d6416f92c520a509a9811d73f68aa00fc0.tar.gz
tangerine-wallet-browser-c8c773d6416f92c520a509a9811d73f68aa00fc0.tar.zst
tangerine-wallet-browser-c8c773d6416f92c520a509a9811d73f68aa00fc0.zip
Merge branch 'NewUI-flat' into merge
Diffstat (limited to 'ui/app/components/dropdowns/account-options-dropdown.js')
-rw-r--r--ui/app/components/dropdowns/account-options-dropdown.js29
1 files changed, 29 insertions, 0 deletions
diff --git a/ui/app/components/dropdowns/account-options-dropdown.js b/ui/app/components/dropdowns/account-options-dropdown.js
new file mode 100644
index 000000000..50e793d87
--- /dev/null
+++ b/ui/app/components/dropdowns/account-options-dropdown.js
@@ -0,0 +1,29 @@
+const Component = require('react').Component
+const h = require('react-hyperscript')
+const inherits = require('util').inherits
+const AccountDropdowns = require('./components/account-dropdowns')
+
+inherits(AccountOptionsDropdown, Component)
+function AccountOptionsDropdown () {
+ Component.call(this)
+}
+
+module.exports = AccountOptionsDropdown
+
+// TODO: specify default props and proptypes
+// TODO: hook up to state, connect to redux to clean up API
+// TODO: selectedAddress is not defined... should we use selected?
+AccountOptionsDropdown.prototype.render = function () {
+ const { selected, network, identities, style, dropdownWrapperStyle, menuItemStyles } = this.props
+
+ return h(AccountDropdowns, {
+ enableAccountOptions: true,
+ enableAccountsSelector: false,
+ selected: selectedAddress,
+ network,
+ identities,
+ style: style || {},
+ dropdownWrapperStyle: dropdownWrapperStyle || {},
+ menuItemStyles: menuItemStyles || {},
+ }, [])
+}