From 98768def80fc542685866ec872cc9fcd01a99bb9 Mon Sep 17 00:00:00 2001 From: Dean Lofts Date: Sat, 14 Sep 2024 16:00:03 +1000 Subject: [PATCH] remove debugging --- app/javascript/controllers/dropdown_controller.js | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/app/javascript/controllers/dropdown_controller.js b/app/javascript/controllers/dropdown_controller.js index b53ac6b..6b68ea3 100644 --- a/app/javascript/controllers/dropdown_controller.js +++ b/app/javascript/controllers/dropdown_controller.js @@ -3,25 +3,15 @@ import { Controller } from "@hotwired/stimulus" export default class extends Controller { static targets = [ "menu" ] - connect() { - console.log("Dropdown controller connected", this.element) - console.log("Menu target:", this.menuTarget) - } - toggle() { - console.log("Toggle called") if (this.hasMenuTarget) { - console.log("Menu target found, toggling visibility") this.menuTarget.classList.toggle('hidden') - } else { - console.error("Menu target not found") } } hide(event) { if (!this.element.contains(event.target)) { - console.log("Hiding dropdown") this.menuTarget.classList.add('hidden') } } -} \ No newline at end of file +}