diff options
author | brunobar79 <brunobar79@gmail.com> | 2018-07-19 14:31:02 +0800 |
---|---|---|
committer | brunobar79 <brunobar79@gmail.com> | 2018-07-19 14:31:02 +0800 |
commit | 76981c2ad9b0f8f13fa61ba3b60c07203a81eb57 (patch) | |
tree | dfd375c3a0adb26a393d4b9dcf7456141a936423 /ui/app/actions.js | |
parent | 514148ffa1652b4e23ffe04fbe23bb0eadbdecb7 (diff) | |
download | tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.tar tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.tar.gz tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.tar.bz2 tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.tar.lz tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.tar.xz tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.tar.zst tangerine-wallet-browser-76981c2ad9b0f8f13fa61ba3b60c07203a81eb57.zip |
added new global alert
Diffstat (limited to 'ui/app/actions.js')
-rw-r--r-- | ui/app/actions.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/ui/app/actions.js b/ui/app/actions.js index 3da56ebc2..4557b5961 100644 --- a/ui/app/actions.js +++ b/ui/app/actions.js @@ -26,6 +26,11 @@ var actions = { SIDEBAR_CLOSE: 'UI_SIDEBAR_CLOSE', showSidebar: showSidebar, hideSidebar: hideSidebar, + // sidebar state + ALERT_OPEN: 'UI_ALERT_OPEN', + ALERT_CLOSE: 'UI_ALERT_CLOSE', + showAlert: showAlert, + hideAlert: hideAlert, // network dropdown open NETWORK_DROPDOWN_OPEN: 'UI_NETWORK_DROPDOWN_OPEN', NETWORK_DROPDOWN_CLOSE: 'UI_NETWORK_DROPDOWN_CLOSE', @@ -1724,6 +1729,19 @@ function hideSidebar () { } } +function showAlert (msg) { + return { + type: actions.ALERT_OPEN, + value: msg, + } +} + +function hideAlert () { + return { + type: actions.ALERT_CLOSE, + } +} + function showLoadingIndication (message) { return { |