mirror of
https://github.com/kilyabin/psysonic.git
synced 2026-07-22 06:25:41 +00:00
feat(orbit): per-guest suggestion mute + global pending-cap setting
Two anti-spam knobs the host can dial during a live session: 1. Per-guest suggestion mute — Mic / MicOff toggle next to the kick/ban buttons in the participants popover. Symmetric (re-enable later). State lives in OrbitState.suggestionBlocked: string[]; the guest reads it and disables its own Suggest controls so the user sees a clear "muted" state instead of silent failures. Host-side sweep also drops their outbox entries as a safety net. 2. Max pending approvals cap — number input in the session-settings popover, default 0 (= unlimited so existing sessions are unaffected). When set, the host sweep stops folding new outbox entries into the approval list once the cap is reached. The OrbitQueueHead surfaces "X / Y pending" so guests can see when they're getting close. State changes are additive on the wire — both fields are optional, with parseOrbitState defaulting them, so older clients keep working. evaluateOrbitSuggestGate() centralises the guest-side allow/block check shared between useOrbitSongRowBehavior and the ContextMenu Add-to-Session items, plus suggestOrbitTrack as a defensive last line. i18n: en + de + fr + nl + zh + nb + ru + es. Also fixes an earlier dedupe-key collision: the (user, trackId) cache keys were missing their separator (NULL byte slipped in during the previous patch), so two tracks could share a key and one of them silently overwrite the other. Restored the space separator. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1554,6 +1554,10 @@ export const zhTranslation = {
|
||||
participantsRemoveAria: '从此会话中移除 {{user}}',
|
||||
participantsBanTooltip: '永久封禁',
|
||||
participantsBanAria: '永久封禁 {{user}}',
|
||||
participantsMuteTooltip: '禁止投歌',
|
||||
participantsUnmuteTooltip: '允许投歌',
|
||||
participantsMuteAria: '禁止 {{user}} 投歌',
|
||||
participantsUnmuteAria: '允许 {{user}} 重新投歌',
|
||||
confirmRemoveTitle: '从会话中移除?',
|
||||
confirmRemoveBody: '{{user}} 将从会话中移除,但可以通过你的邀请链接重新加入。',
|
||||
confirmRemoveConfirm: '移除',
|
||||
@@ -1579,6 +1583,12 @@ export const zhTranslation = {
|
||||
settingAutoShuffleHint: '即将播放队列的定期 Fisher-Yates 洗牌。关闭:顺序仅在你手动重新排列时改变。',
|
||||
settingShuffleInterval: '洗牌间隔',
|
||||
settingShuffleIntervalHint: '会话运行时即将播放队列的重新洗牌频率。',
|
||||
settingMaxPending: '最大待审投歌数',
|
||||
settingMaxPendingHint: '同时等待审核的访客投歌上限。0 = 不限制。',
|
||||
pendingCounter: '{{count}} / {{max}} 待审',
|
||||
pendingCounterTooltip: '等待中的访客投歌 / 上限',
|
||||
suggestBlockedMuted: '主持人已禁止你在本场会话投歌。',
|
||||
suggestBlockedCap: '审核队列已满,等主持人处理一些再继续。',
|
||||
settingShuffleIntervalValue_one: '{{count}} 分钟',
|
||||
settingShuffleIntervalValue_other: '{{count}} 分钟',
|
||||
settingShuffleNow: '立即洗牌',
|
||||
|
||||
Reference in New Issue
Block a user