Embeddable ParityBar (#4222)
* Embeddable ParityBar * Replacing storage with store * Fixing references. * Addressing style issues * Supporting parity background
This commit is contained in:
committed by
Jaco Greeff
parent
275fd5096c
commit
3e70e886a0
@@ -14,13 +14,15 @@
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Parity. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import store from 'store';
|
||||
|
||||
const LS_KEY = 'tooltips';
|
||||
|
||||
let currentId = -1;
|
||||
let maxId = 0;
|
||||
|
||||
function closeTooltips (state, action) {
|
||||
window.localStorage.setItem(LS_KEY, '{"state":"off"}');
|
||||
store.set(LS_KEY, '{"state":"off"}');
|
||||
|
||||
currentId = -1;
|
||||
|
||||
@@ -41,7 +43,7 @@ function newTooltip (state, action) {
|
||||
}
|
||||
|
||||
function nextTooltip (state, action) {
|
||||
const hideTips = window.localStorage.getItem(LS_KEY);
|
||||
const hideTips = store.get(LS_KEY);
|
||||
|
||||
currentId = hideTips
|
||||
? -1
|
||||
|
||||
Reference in New Issue
Block a user