MCPcopy Create free account
hub / github.com/DenOfEquity/ersatzForge / cardClicked

Function cardClicked

javascript/extraNetworks.js:297–305  ·  view source on GitHub ↗
(tabname, textToAdd, textToAddNegative, allowNegativePrompt)

Source from the content-addressed store, hash-verified

295 }
296
297 updateInput(textArea);
298}
299
300function cardClicked(tabname, textToAdd, textToAddNegative, allowNegativePrompt) {
301 if (textToAddNegative.length > 0) {
302 updatePromptArea(textToAdd, gradioApp().querySelector("#" + tabname + "_prompt > label > textarea"));
303 updatePromptArea(textToAddNegative, gradioApp().querySelector("#" + tabname + "_neg_prompt > label > textarea"), true);
304 } else {
305 var textarea = allowNegativePrompt ? activePromptTextarea[tabname] : gradioApp().querySelector("#" + tabname + "_prompt > label > textarea");
306 updatePromptArea(textToAdd, textarea);
307 }
308}

Callers

nothing calls this directly

Calls 2

updatePromptAreaFunction · 0.85
gradioAppFunction · 0.85

Tested by

no test coverage detected