diff options
author | Dan <danjm.com@gmail.com> | 2017-09-29 18:10:50 +0800 |
---|---|---|
committer | Chi Kei Chan <chikeichan@gmail.com> | 2017-10-02 10:02:21 +0800 |
commit | 47ebcbb2ed09a4cd4b062c5fa4cb6d259369149f (patch) | |
tree | e465ea9a722bbaac505681787c3739e7792209e6 /ui/app/components/dropdowns/token-menu-dropdown.js | |
parent | ff64fe98dde7746775396cbf94d63a1a0e91d069 (diff) | |
download | tangerine-wallet-browser-47ebcbb2ed09a4cd4b062c5fa4cb6d259369149f.tar.gz tangerine-wallet-browser-47ebcbb2ed09a4cd4b062c5fa4cb6d259369149f.tar.zst tangerine-wallet-browser-47ebcbb2ed09a4cd4b062c5fa4cb6d259369149f.zip |
Token menu ui.
Diffstat (limited to 'ui/app/components/dropdowns/token-menu-dropdown.js')
-rw-r--r-- | ui/app/components/dropdowns/token-menu-dropdown.js | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/ui/app/components/dropdowns/token-menu-dropdown.js b/ui/app/components/dropdowns/token-menu-dropdown.js new file mode 100644 index 000000000..b948534c2 --- /dev/null +++ b/ui/app/components/dropdowns/token-menu-dropdown.js @@ -0,0 +1,38 @@ +const Component = require('react').Component +const h = require('react-hyperscript') +const inherits = require('util').inherits + +module.exports = TokenMenuDropdown + +inherits(TokenMenuDropdown, Component) +function TokenMenuDropdown () { + Component.call(this) + + this.onClose = this.onClose.bind(this) +} + +TokenMenuDropdown.prototype.onClose = function (e) { + e.stopPropagation() + this.props.onClose() +} + +TokenMenuDropdown.prototype.render = function () { + return h('div.token-menu-dropdown', {}, [ + h('div.token-menu-dropdown__close-area', { + onClick: this.onClose, + }), + h('div.token-menu-dropdown__container', {}, [ + h('div.token-menu-dropdown__options', {}, [ + + h('div.token-menu-dropdown__option', { + onClick: (e) => { + e.stopPropagation() + console.log('div.token-menu-dropdown__option!') + }, + }, 'Hide Token') + + ]), + ]), + ]) +} + |