fix "Render note" and "Execute script" buttons + refactoring around data-trigger-command handling

This commit is contained in:
zadam
2020-05-05 23:58:52 +02:00
parent b452d7e5c5
commit 8aa5608085
8 changed files with 50 additions and 49 deletions

View File

@@ -93,8 +93,8 @@ function updateDisplayedShortcuts($container) {
}
});
$container.find('button[data-command],a.icon-action[data-command],.kb-in-title').each(async (i, el) => {
const actionName = $(el).attr('data-command');
$container.find('[data-trigger-command]').each(async (i, el) => {
const actionName = $(el).attr('data-trigger-command');
const action = await getAction(actionName, true);
if (action) {