zIndex overlapping bug fixed

This commit is contained in:
Alexander Bell 2018-06-17 02:19:04 -07:00
parent f76d93841a
commit 30c0e5df0a
2 changed files with 4 additions and 5 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "react-animated-menus", "name": "react-animated-menus",
"version": "1.0.13", "version": "1.0.14",
"description": "React component that mounts three dot button that morphs into a menu by clicking on it.", "description": "React component that mounts three dot button that morphs into a menu by clicking on it.",
"main": "./lib/index.js", "main": "./lib/index.js",
"license": "MIT", "license": "MIT",

View File

@ -78,10 +78,9 @@ class App extends Component {
//Styles //Styles
targetButton.forEach((element) => { targetButton.forEach((element) => {
element.style.display = "block"; element.style.display = "block";
element.style.zIndex = 1000;
}); });
targetDots.forEach((element) => { targetMenu.forEach((element) => {
element.style.zIndex = 1000; element.style.zIndex = 2000;
}) })
//Remove hover effect //Remove hover effect
@ -156,7 +155,7 @@ class App extends Component {
element.style.display = "none"; element.style.display = "none";
element.style.zIndex = 1; element.style.zIndex = 1;
}); });
targetDots.forEach((element) => { targetMenu.forEach((element) => {
element.style.zIndex = 1; element.style.zIndex = 1;
}) })
}; };