- src/tts-blocklist.txt: slurs, self-harm/threat phrases, sexual violence, hate slogans (no normal swearing); merged into Settings once (tts_blocklist_seeded), editable there afterwards - Matching is now whole words/phrases with plurals, look-alike swaps and spaced-out letters, so raccoon / spicy / therapist / grape are fine Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
98 lines
4.2 KiB
Text
98 lines
4.2 KiB
Text
<h2>Settings</h2>
|
||
|
||
<article>
|
||
<header><strong>Overlay URL</strong></header>
|
||
<p>Add this as a <strong>Browser Source</strong> in OBS (1920×1080, transparent background):</p>
|
||
<code><%= baseUrl %>/overlay/<%= settings.overlay_id %></code>
|
||
</article>
|
||
|
||
<form method="POST" action="/settings">
|
||
|
||
<h3>Chat</h3>
|
||
<label>
|
||
Twitch channel
|
||
<input type="text" name="channel" value="<%= settings.channel %>" placeholder="yourchannel">
|
||
</label>
|
||
<div style="display:grid; grid-template-columns:1fr 1fr; gap:1rem;">
|
||
<label>
|
||
Message timeout (seconds)
|
||
<input type="number" name="message_timeout" value="<%= settings.message_timeout %>" min="0" max="600">
|
||
<small>0 = messages stay forever</small>
|
||
</label>
|
||
<label>
|
||
Max messages shown
|
||
<input type="number" name="max_messages" value="<%= settings.max_messages %>" min="1" max="100">
|
||
</label>
|
||
</div>
|
||
|
||
<h3>Gap audio</h3>
|
||
<p><small>Plays a sound when a new message arrives after a period of silence.</small></p>
|
||
<label>
|
||
<input type="checkbox" name="gap_audio_enabled" role="switch" <%= settings.gap_audio_enabled ? 'checked' : '' %>>
|
||
Enable gap audio
|
||
</label>
|
||
<label>
|
||
Sound URL
|
||
<input type="text" name="gap_audio_url" value="<%= settings.gap_audio_url %>" placeholder="https://... or /media/filename.mp3">
|
||
</label>
|
||
<div style="display:grid; grid-template-columns:1fr 1fr 1fr; gap:1rem;">
|
||
<label>
|
||
Min silence before triggering (s)
|
||
<input type="number" name="gap_audio_min_silence" value="<%= settings.gap_audio_min_silence %>" min="0">
|
||
<small>Sound won't play if chat was more recent than this</small>
|
||
</label>
|
||
<label>
|
||
Min volume (0–1)
|
||
<input type="number" name="gap_audio_min_volume" value="<%= settings.gap_audio_min_volume %>" min="0" max="1" step="0.05">
|
||
<small>Volume right after min silence</small>
|
||
</label>
|
||
<label>
|
||
Max volume (0–1)
|
||
<input type="number" name="gap_audio_max_volume" value="<%= settings.gap_audio_max_volume %>" min="0" max="1" step="0.05">
|
||
<small>Volume after long silence</small>
|
||
</label>
|
||
</div>
|
||
<label>
|
||
Full volume after silence of (seconds)
|
||
<input type="number" name="gap_audio_loud_after" value="<%= settings.gap_audio_loud_after %>" min="0">
|
||
<small>e.g. 3600 = 1 hour of silence → max volume</small>
|
||
</label>
|
||
|
||
<h3>TTS redeems</h3>
|
||
<p><small>For redeem variations with a TTS voice (set on the Redeems page; voices are made on the TTS page).</small></p>
|
||
<div style="display:grid; grid-template-columns:1fr 1fr; gap:1rem;">
|
||
<label>
|
||
Max length (characters)
|
||
<input type="number" name="tts_max_chars" value="<%= settings.tts_max_chars %>" min="20" max="500">
|
||
<small>Longer messages are cut at a word.</small>
|
||
</label>
|
||
<label style="align-self:center;">
|
||
<input type="checkbox" name="tts_say_name" role="switch" <%= settings.tts_say_name ? 'checked' : '' %>>
|
||
Say the name first ("ChickenWhisperer says: …")
|
||
</label>
|
||
</div>
|
||
<label>
|
||
Blocked words
|
||
<textarea name="tts_blocklist" rows="4" placeholder="one per line, or comma-separated"><%= settings.tts_blocklist %></textarea>
|
||
<small>If a message contains one, nothing is read and the letter shows "(message removed)". Whole words and phrases, not case-sensitive, plurals included; also catches swaps like 0→o, $→s and spaced-out letters (k y s). Starts with a list of slurs and Twitch-risky phrases (normal swearing is allowed); edit freely. Links are always removed.</small>
|
||
</label>
|
||
|
||
<h3>Custom CSS / JS</h3>
|
||
<label>
|
||
Custom CSS (injected into the overlay)
|
||
<textarea name="custom_css" rows="6" style="font-family:monospace"><%= settings.custom_css %></textarea>
|
||
</label>
|
||
<label>
|
||
Custom JS (injected into the overlay, runs after init)
|
||
<textarea name="custom_js" rows="6" style="font-family:monospace"><%= settings.custom_js %></textarea>
|
||
</label>
|
||
|
||
<button type="submit">Save settings</button>
|
||
</form>
|
||
|
||
<hr>
|
||
<h3>EventSub</h3>
|
||
<form method="POST" action="/settings/reconnect" style="display:inline;">
|
||
<button type="submit" class="outline">Reconnect EventSub</button>
|
||
</form>
|
||
<small style="margin-left:1rem;">Use this if Twitch alerts stop working after a token refresh.</small>
|