Commit 010fae9e authored by's avatar
Browse files

add feature to use external buttons for opening the menu

parent 4536ed54
...@@ -140,6 +140,11 @@ ...@@ -140,6 +140,11 @@
toggle.appendChild(image); toggle.appendChild(image);
menu.appendChild(toggle); menu.appendChild(toggle);
// search for external menu triggers
var trgs = document.getElementsByClassName("ipick-trigger-button");
for (var i in trgs)
trgs[i].onclick = openMenu;
// add menu to the dom // add menu to the dom
document.body.appendChild(menu); document.body.appendChild(menu);
document.body.appendChild(backdrop); document.body.appendChild(backdrop);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment