Merge pull request #9 from Lavorther/main

Update "Send to miniPaint" button to match webUI's new emoji buttons
pull/10/head
0Tick 2023-10-05 15:55:37 +02:00 committed by GitHub
commit da1e1d3910
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

File diff suppressed because one or more lines are too long

View File

@ -219,9 +219,10 @@ class File_send_class {
if (window.parent.gradioApp().querySelector(`#${queryId}_open_in_minipaint`) == null){
const newButton = existingButton.cloneNode(true);
newButton.id = `${queryId}_open_in_minipaint`;
newButton.textContent = "Send to miniPaint";
newButton.textContent = "✏️";
newButton.title= "Send image to miniPaint tab.";
newButton.addEventListener("click", addButton);
window.parent.gradioApp().querySelector(`#${queryId}`).appendChild(newButton);
window.parent.gradioApp().querySelector(`#${queryId} .form`).appendChild(newButton);
}
else {
existingButton = window.parent.gradioApp().querySelector(`#${queryId}_open_in_minipaint`);