diff options
author | AUTOMATIC <16777216c@gmail.com> | 2023-05-09 19:42:37 +0000 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2023-05-09 19:42:37 +0000 |
commit | c8791c1d37502f162b8616b066303bfadc4a749b (patch) | |
tree | 6843c3505117f26549dfe1dc9cd40aacd5ccdfd3 /javascript/edit-attention.js | |
parent | 6fbd85dd0c0dffc06560bff91f4c4b65e441ca5f (diff) | |
parent | 31397986e70d20e392d9c3ec70d3aef8ecc2c1ff (diff) | |
download | stable-diffusion-webui-gfx803-c8791c1d37502f162b8616b066303bfadc4a749b.tar.gz stable-diffusion-webui-gfx803-c8791c1d37502f162b8616b066303bfadc4a749b.tar.bz2 stable-diffusion-webui-gfx803-c8791c1d37502f162b8616b066303bfadc4a749b.zip |
Merge branch 'dev' into release_candidate
Diffstat (limited to 'javascript/edit-attention.js')
-rw-r--r-- | javascript/edit-attention.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/javascript/edit-attention.js b/javascript/edit-attention.js index 588c7b77..d2c2f190 100644 --- a/javascript/edit-attention.js +++ b/javascript/edit-attention.js @@ -69,8 +69,8 @@ function keyupEditAttention(event){ event.preventDefault();
- closeCharacter = ')'
- delta = opts.keyedit_precision_attention
+ var closeCharacter = ')'
+ var delta = opts.keyedit_precision_attention
if (selectionStart > 0 && text[selectionStart - 1] == '<'){
closeCharacter = '>'
@@ -91,8 +91,8 @@ function keyupEditAttention(event){ selectionEnd += 1;
}
- end = text.slice(selectionEnd + 1).indexOf(closeCharacter) + 1;
- weight = parseFloat(text.slice(selectionEnd + 1, selectionEnd + 1 + end));
+ var end = text.slice(selectionEnd + 1).indexOf(closeCharacter) + 1;
+ var weight = parseFloat(text.slice(selectionEnd + 1, selectionEnd + 1 + end));
if (isNaN(weight)) return;
weight += isPlus ? delta : -delta;
|