parent
c5462e9790
commit
f07489750c
65 changed files with 3727 additions and 2607 deletions
79
views/settings.ejs
Normal file
79
views/settings.ejs
Normal file
|
|
@ -0,0 +1,79 @@
|
|||
<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>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>
|
||||
Loading…
Add table
Add a link
Reference in a new issue