From f6566f63130c03613823acb0af4000408604cf12 Mon Sep 17 00:00:00 2001 From: Peter Stuifzand Date: Mon, 17 Jan 2022 00:15:52 +0100 Subject: [PATCH] Problem: burger menu does not work on mobile Solution: add even handler to open/close hamburger menu --- editor/src/index.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/editor/src/index.js b/editor/src/index.js index 9ddd855..c9624b3 100644 --- a/editor/src/index.js +++ b/editor/src/index.js @@ -111,4 +111,10 @@ $(document).on('click', '.tab', function () { $(function () { activateTab($('.tab-bar .tab-active')[0]); + + $('.navbar-burger').on('click', function () { + let open = $(this).hasClass('is-active') + $('#' + $(this).data('target')).toggleClass('is-active', !open) + $(this).toggleClass('is-active', !open) + }); });