This commit is contained in:
parent
99151c6692
commit
3676dc46ed
16 changed files with 894 additions and 89 deletions
|
|
@ -347,7 +347,7 @@
|
|||
{message.username.charAt(0).toUpperCase()}
|
||||
</div>
|
||||
{/if}
|
||||
<button class="username-btn" style="color: {safeUserColor}" on:click={handleUsernameClick} on:dblclick={handleUsernameDoubleClick}>
|
||||
<button class="username-btn" class:guest={message.isGuest} style="color: {message.isGuest ? 'lightgrey' : safeUserColor}" on:click={handleUsernameClick} on:dblclick={handleUsernameDoubleClick}>
|
||||
{message.username}
|
||||
</button>
|
||||
{#if message.usedRoll}
|
||||
|
|
@ -579,6 +579,12 @@
|
|||
filter: invert(1);
|
||||
}
|
||||
|
||||
.username-btn.guest {
|
||||
background-color: #1f184e;
|
||||
padding: 0.1rem 0.3rem;
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
.badge {
|
||||
font-size: 0.55rem;
|
||||
padding: 0.05rem 0.25rem;
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
import { watchSync, canControl, currentVideo } from '$lib/stores/watchSync';
|
||||
import { auth } from '$lib/stores/auth';
|
||||
import { getGuestFingerprint } from '$lib/fingerprint';
|
||||
// watchSync is already imported above for sendLockUpdate
|
||||
|
||||
export let realmId;
|
||||
export let playlist = [];
|
||||
|
|
@ -295,6 +296,9 @@
|
|||
item.id === itemId ? { ...item, isLocked: locked } : item
|
||||
);
|
||||
dispatch('playlistUpdated');
|
||||
|
||||
// Notify watch sync WebSocket about lock change (for immediate in-memory state update)
|
||||
watchSync.sendLockUpdate(itemId, locked);
|
||||
}
|
||||
} catch (e) {
|
||||
console.error('Failed to toggle lock:', e);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue