From 2bd909cdda42b41c8673661d50cfcee1a2d129d0 Mon Sep 17 00:00:00 2001 From: David Grudl Date: Tue, 29 Oct 2024 17:56:12 +0100 Subject: [PATCH] dumper: added cmd-click to open in editor On a Mac, Ctrl-click is equivalent to a right-click --- src/Tracy/Dumper/assets/dumper.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Tracy/Dumper/assets/dumper.js b/src/Tracy/Dumper/assets/dumper.js index 1651935b7..81417ad71 100644 --- a/src/Tracy/Dumper/assets/dumper.js +++ b/src/Tracy/Dumper/assets/dumper.js @@ -47,8 +47,8 @@ class Dumper { document.documentElement.addEventListener('click', (e) => { let el; - // enables & ctrl key - if (e.ctrlKey && (el = e.target.closest('[data-tracy-href]'))) { + // enables & ctrl or cmd key + if ((e.ctrlKey || e.metaKey) && (el = e.target.closest('[data-tracy-href]'))) { location.href = el.getAttribute('data-tracy-href'); return false; }