improve en performance

This commit is contained in:
Vladimir Mandic
2023-11-04 12:58:45 -04:00
parent ca0af39086
commit 6e05fa865a
11 changed files with 50 additions and 69 deletions
+1 -1
View File
@@ -104,7 +104,7 @@ function initContextMenu() {
};
for (const tab of ['txt2img', 'img2img']) {
for (const el of ['prompt > label > textarea', 'generate']) {
for (const el of ['generate', 'interrupt', 'skip', 'pause', 'paste', 'clear_prompt', 'extra_networks_btn']) {
const id = `#${tab}_${el}`;
appendContextMenuOption(id, 'Copy to clipboard', () => navigator.clipboard.writeText(document.querySelector(`#${tab}_prompt > label > textarea`).value));
appendContextMenuOption(id, 'Generate forever', () => generateForever(`#${tab}_generate`));