aboutsummaryrefslogtreecommitdiffstats
path: root/javascript/dragdrop.js
diff options
context:
space:
mode:
authord8ahazard <d8ahazard@gmail.com>2022-10-12 23:17:26 +0000
committerd8ahazard <d8ahazard@gmail.com>2022-10-12 23:17:26 +0000
commit54e0051bdd7dea7348825c09600ec61ea0771cb8 (patch)
tree78c225890f9e9700a9af209d5855622e9beb8522 /javascript/dragdrop.js
parentcc5803603b8591075542d99ae8596ab5b130a82f (diff)
downloadstable-diffusion-webui-gfx803-54e0051bdd7dea7348825c09600ec61ea0771cb8.tar.gz
stable-diffusion-webui-gfx803-54e0051bdd7dea7348825c09600ec61ea0771cb8.tar.bz2
stable-diffusion-webui-gfx803-54e0051bdd7dea7348825c09600ec61ea0771cb8.zip
Add drag/drop param loading.
Drop an image or generational text onto the prompt bar, it loads the info for parsing.
Diffstat (limited to 'javascript/dragdrop.js')
-rw-r--r--javascript/dragdrop.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/javascript/dragdrop.js b/javascript/dragdrop.js
index 5aac57f7..cf900f50 100644
--- a/javascript/dragdrop.js
+++ b/javascript/dragdrop.js
@@ -53,6 +53,9 @@ window.document.addEventListener('dragover', e => {
window.document.addEventListener('drop', e => {
const target = e.composedPath()[0];
+ if (target.placeholder === "Prompt") {
+ return;
+ }
const imgWrap = target.closest('[data-testid="image"]');
if ( !imgWrap ) {
return;