Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / web / core / profiles / demo_umami / themes / umami / js / components / navigation / menu-main / menu-main.js
diff --git a/web/core/profiles/demo_umami/themes/umami/js/components/navigation/menu-main/menu-main.js b/web/core/profiles/demo_umami/themes/umami/js/components/navigation/menu-main/menu-main.js
new file mode 100644 (file)
index 0000000..0705b50
--- /dev/null
@@ -0,0 +1,19 @@
+/**
+* DO NOT EDIT THIS FILE.
+* See the following change record for more information,
+* https://www.drupal.org/node/2815083
+* @preserve
+**/
+
+(function () {
+  var toggler = document.querySelector('[data-drupal-selector="menu-main-toggle"]');
+  var menu = document.querySelector('[data-drupal-selector="menu-main"]');
+
+  function toggleMenu() {
+    toggler.classList.toggle('menu-main-toggle--active');
+    menu.classList.toggle('menu-main--active');
+    return false;
+  }
+
+  toggler.addEventListener('click', toggleMenu);
+})();
\ No newline at end of file