Skip to content

Commit

Permalink
Replaced document.onkeydown to dismiss modals w/ `.addEventListener…
Browse files Browse the repository at this point in the history
…()` to accommodate potential other listeners ↞ [auto-sync from `adamlui/ai-web-extensions`]
  • Loading branch information
kudo-sync-bot committed Oct 20, 2024
1 parent c058a71 commit 2e744b2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions greasemonkey/bravegpt.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@
// @description:zu Yengeza izimpendulo ze-AI ku-Brave Search (inikwa amandla yi-GPT-4o!)
// @author KudoAI
// @namespace https://kudoai.com
// @version 2024.10.17.3
// @version 2024.10.19
// @license MIT
// @icon https://media.bravegpt.com/images/icons/bravegpt/icon48.png?0a9e287
// @icon64 https://media.bravegpt.com/images/icons/bravegpt/icon64.png?0a9e287
Expand Down Expand Up @@ -3715,7 +3715,7 @@
saveAppDiv() // to fight Brave mutations

// Add key listener to DISMISS modals
document.onkeydown = modals.keyHandler
document.addEventListener('keydown', modals.keyHandler)

// Observe/listen for Brave Search + system SCHEME CHANGES to update BraveGPT scheme if auto-scheme mode
new MutationObserver(handleSchemeChange).observe( // class changes from Brave Search theme settings
Expand Down

0 comments on commit 2e744b2

Please sign in to comment.