feat(recipes): add toggle to strip <lora:> tags when copying prompt/negative_prompt

Adds a compact inline toggle in the Generation Parameters section of the
Recipe Modal that, when enabled, strips <lora:name:weight> tags and
cleans up residual punctuation before copying to clipboard. The setting
persists across sessions via localStorage.
This commit is contained in:
Will Miao
2026-05-13 11:47:02 +08:00
parent 60cfb3b8e0
commit 3bf396d003
4 changed files with 102 additions and 8 deletions

View File

@@ -22,7 +22,16 @@
</div>
<div class="info-section recipe-gen-params">
<h3>Generation Parameters</h3>
<div class="gen-params-header-row">
<h3>Generation Parameters</h3>
<label class="inline-toggle-container lora-strip-toggle" title="When enabled, &lt;lora:...&gt; tags are removed from prompt text when copying">
<span class="inline-toggle-label">Strip &lt;lora:&gt;</span>
<div class="toggle-switch">
<input type="checkbox" id="stripLoraOnCopyToggle">
<span class="toggle-slider"></span>
</div>
</label>
</div>
<div class="gen-params-container">
<!-- Prompt -->