document optimize & bump to 1.2.0

This commit is contained in:
zombieyang
2024-07-30 19:00:33 +08:00
parent 728fb8fad3
commit 2f5643d1b8
10 changed files with 58 additions and 12 deletions
Binary file not shown.
+8
View File
@@ -380,6 +380,7 @@
const insertedSendWidgetsByElem = new WeakMap();
const insertedGetWidgets = new Set();
const insertedSendWidgets = new Set();
let downloadButtonProcessed = false;
onUiUpdate(() => {
gradioApp().querySelectorAll(".gradio-image").forEach((el) => {
@@ -396,5 +397,12 @@
insertedSendWidgetsByElem.set(el, widget);
insertedSendWidgets.add(new WeakRef(widget))
})
const downloadButton = gradioApp().querySelector('#setting_sd-ppp_download')
if (!downloadButton || downloadButtonProcessed) return;
downloadButton.innerHTML = "Download SD-PPP PS .ccx plugin"
downloadButton.addEventListener('click', () => {
location.href = "/file=extensions/sd-ppp/javascript/plugins/sd-ppp_PS.ccx"
})
downloadButtonProcessed = true
})
})();