mirror of
https://github.com/gorhill/uBlock.git
synced 2024-10-06 09:37:12 +02:00
Support keyboard shortcut to open popup panel
Related discussion: - https://www.reddit.com/r/uBlockOrigin/comments/dt47s0/
This commit is contained in:
parent
7bf5ac0ca2
commit
e2fdc1b94b
@ -19,6 +19,8 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"commands": {
|
"commands": {
|
||||||
|
"_execute_browser_action": {
|
||||||
|
},
|
||||||
"launch-element-zapper": {
|
"launch-element-zapper": {
|
||||||
"description": "__MSG_popupTipZapper__"
|
"description": "__MSG_popupTipZapper__"
|
||||||
},
|
},
|
||||||
|
@ -204,7 +204,12 @@
|
|||||||
const template = document.querySelector('#templates .commandEntry');
|
const template = document.querySelector('#templates .commandEntry');
|
||||||
const tbody = document.querySelector('.commandEntries tbody');
|
const tbody = document.querySelector('.commandEntries tbody');
|
||||||
for ( const command of commands ) {
|
for ( const command of commands ) {
|
||||||
if ( command.description === '' ) { continue; }
|
if (
|
||||||
|
typeof command.description !== 'string' ||
|
||||||
|
command.description === '' )
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
const tr = template.cloneNode(true);
|
const tr = template.cloneNode(true);
|
||||||
tr.setAttribute('data-name', command.name);
|
tr.setAttribute('data-name', command.name);
|
||||||
tr.querySelector('.commandDesc').textContent = command.description;
|
tr.querySelector('.commandDesc').textContent = command.description;
|
||||||
|
Loading…
Reference in New Issue
Block a user