From 9e4ff35e8e82b4751f6b6636778b3bf7eb067baa Mon Sep 17 00:00:00 2001 From: Moepchi Date: Sat, 24 Oct 2026 08:12:23 +0000 Subject: [PATCH] Invite a friend: WebSpeak3 join link, whisper history cleanup as spin box, German typing attenuation label Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Hu2cuPLqpuKVfd9wWFFakU --- web/src/App.tsx | 42 ++++++++++++++++++++++++++++---------- web/src/locales/cs-CZ.json | 4 ++-- web/src/locales/de.json | 6 +++--- web/src/locales/en.json | 4 ++-- web/src/locales/fa.json | 4 ++-- web/src/locales/zh-CN.json | 4 ++-- 6 files changed, 42 insertions(+), 22 deletions(-) diff --git a/web/src/App.tsx b/web/src/App.tsx index d935a35..9cc9e38 100644 --- a/web/src/App.tsx +++ b/web/src/App.tsx @@ -3667,19 +3667,30 @@ function CollectedUrlsDialog({ function InviteFriendDialog({ host, channelId, + channelPath, onClose, }: { host: string; channelId: number | null; + /** "Parent/Child" names, what ?channel= of a WebSpeak3 link expects. */ + channelPath: string | null; onClose: () => void; }) { const t = useT(); + const [type, setType] = useState<"webspeak3" | "ts3server">("webspeak3"); const [includeChannel, setIncludeChannel] = useState(false); const [copied, setCopied] = useState(false); const linkInputRef = useRef(null); const backdrop = useBackdropDismiss(onClose); - const link = `ts3server://${host}${includeChannel && channelId !== null ? `?channel=${channelId}` : ""}`; + const withChannel = includeChannel && channelId !== null; + // Opens this same WebSpeak3 instance and joins right away (see AUTO_CONNECT_FROM_URL). + const webspeak3Link = () => { + const params = new URLSearchParams({ connect: host }); + if (withChannel && channelPath) params.set("channel", channelPath); + return `${window.location.origin}${window.location.pathname}?${params}`; + }; + const link = type === "webspeak3" ? webspeak3Link() : `ts3server://${host}${withChannel ? `?channel=${channelId}` : ""}`; return (
@@ -3694,7 +3705,8 @@ function InviteFriendDialog({
@@ -6743,8 +6755,6 @@ function ActionIcon({ children }: { children: ReactNode }) { ); } -const WHISPER_CLEAR_OPTIONS = [1, 5, 10, 30, 60, 0]; - function WhisperPanel({ onOpenWhisperLists }: { onOpenWhisperLists: () => void }) { const t = useT(); const { whisper, setWhisper } = useContext(DisplayPrefsContext); @@ -6779,13 +6789,17 @@ function WhisperPanel({ onOpenWhisperLists }: { onOpenWhisperLists: () => void }
@@ -13470,6 +13484,12 @@ function AppInner() { { + if (selected?.type !== "channel") return null; + const names: string[] = []; + for (let ch = channels.find((c) => c.id === selected.id); ch && names.length < 50; ch = channels.find((c) => c.id === ch!.parent)) names.unshift(ch.name); + return names.join("/"); + })()} onClose={() => setInviteFriendOpen(false)} /> )} diff --git a/web/src/locales/cs-CZ.json b/web/src/locales/cs-CZ.json index 2868bb6..7643ef4 100644 --- a/web/src/locales/cs-CZ.json +++ b/web/src/locales/cs-CZ.json @@ -149,6 +149,7 @@ "inviteFriend.type": "Typ pozvánky", "inviteFriend.includeChannel": "Vložit aktuální kanál", "inviteFriend.link": "Odkaz", + "inviteFriend.webspeak3Link": "Odkaz WebSpeak3", "inviteFriend.addPermissionKey": "Přidat klíč oprávnění", "inviteFriend.copyToClipboard": "Kopírovat do schránky", "inviteFriend.copied": "Zkopírováno!", @@ -174,8 +175,7 @@ "whisperSettings.sound": "Přehrát zvuk, když vám někdo šeptá", "whisperSettings.openHistory": "Vždy otevřít historii šeptání, když vám někdo šeptá", "whisperSettings.clearAfter": "Odebrat klienty z historie šeptání po", - "whisperSettings.never": "Nikdy", - "whisperSettings.minutes": "{count} min", + "whisperSettings.minutes": "minut", "whisperHistory.received": "{name} vám šeptal(a)", "whisperHistory.stopped": "Šeptání zastaveno", "whisperHistory.clear": "Vymazat", diff --git a/web/src/locales/de.json b/web/src/locales/de.json index b2df3d3..9799f5f 100644 --- a/web/src/locales/de.json +++ b/web/src/locales/de.json @@ -149,6 +149,7 @@ "inviteFriend.type": "Art der Einladung", "inviteFriend.includeChannel": "Aktuellen Channel einfügen", "inviteFriend.link": "Link", + "inviteFriend.webspeak3Link": "WebSpeak3-Link", "inviteFriend.addPermissionKey": "Berechtigungsschlüssel hinzufügen", "inviteFriend.copyToClipboard": "In Zwischenablage kopieren", "inviteFriend.copied": "Kopiert!", @@ -174,8 +175,7 @@ "whisperSettings.sound": "Sound abspielen, wenn Sie angewhispert werden", "whisperSettings.openHistory": "Whisper Verlauf immer öffnen, wenn Sie angewhispert werden", "whisperSettings.clearAfter": "Clients in Whisper Verlauf löschen nach", - "whisperSettings.never": "Nie", - "whisperSettings.minutes": "{count} Min.", + "whisperSettings.minutes": "Minuten", "whisperHistory.received": "{name} hat dir zugewhispert", "whisperHistory.stopped": "Whispern beendet", "whisperHistory.clear": "Löschen", @@ -448,7 +448,7 @@ "recording.hangoverDelay": "Abschaltverzögerung:", "recording.secondsUnit": "Sek", "recording.dsp": "Digital Signal Processing", - "recording.typingAttenuation": "Typing attenuation", + "recording.typingAttenuation": "Tippgeräusche dämpfen", "recording.echoCancellation": "Echo Dämpfung", "recording.noiseSuppression": "Hintergrundgeräusche entfernen", "recording.autoGainControl": "Automatische Verstärkung", diff --git a/web/src/locales/en.json b/web/src/locales/en.json index 8ce9049..4a8309c 100644 --- a/web/src/locales/en.json +++ b/web/src/locales/en.json @@ -149,6 +149,7 @@ "inviteFriend.type": "Invitation type", "inviteFriend.includeChannel": "Insert current channel", "inviteFriend.link": "Link", + "inviteFriend.webspeak3Link": "WebSpeak3 link", "inviteFriend.addPermissionKey": "Add permission key", "inviteFriend.copyToClipboard": "Copy to clipboard", "inviteFriend.copied": "Copied!", @@ -174,8 +175,7 @@ "whisperSettings.sound": "Play a sound when someone whispers to you", "whisperSettings.openHistory": "Always open the whisper history when someone whispers to you", "whisperSettings.clearAfter": "Remove clients from the whisper history after", - "whisperSettings.never": "Never", - "whisperSettings.minutes": "{count} min", + "whisperSettings.minutes": "minutes", "whisperHistory.received": "{name} whispered to you", "whisperHistory.stopped": "Stopped whispering", "whisperHistory.clear": "Clear", diff --git a/web/src/locales/fa.json b/web/src/locales/fa.json index b886ee7..30e49a5 100644 --- a/web/src/locales/fa.json +++ b/web/src/locales/fa.json @@ -149,6 +149,7 @@ "inviteFriend.type": "نوع دعوت", "inviteFriend.includeChannel": "افزودن کانال فعلی", "inviteFriend.link": "لینک", + "inviteFriend.webspeak3Link": "لینک WebSpeak3", "inviteFriend.addPermissionKey": "افزودن کلید مجوز", "inviteFriend.copyToClipboard": "کپی در کلیپ‌بورد", "inviteFriend.copied": "کپی شد!", @@ -174,8 +175,7 @@ "whisperSettings.sound": "پخش صدا هنگام دریافت نجوا", "whisperSettings.openHistory": "باز کردن تاریخچهٔ نجوا هنگام دریافت نجوا", "whisperSettings.clearAfter": "حذف کاربران از تاریخچهٔ نجوا پس از", - "whisperSettings.never": "هرگز", - "whisperSettings.minutes": "{count} دقیقه", + "whisperSettings.minutes": "دقیقه", "whisperHistory.received": "{name} با شما نجوا کرد", "whisperHistory.stopped": "نجوا متوقف شد", "whisperHistory.clear": "پاک کردن", diff --git a/web/src/locales/zh-CN.json b/web/src/locales/zh-CN.json index 73fa5d5..db87133 100644 --- a/web/src/locales/zh-CN.json +++ b/web/src/locales/zh-CN.json @@ -88,6 +88,7 @@ "inviteFriend.type": "邀请类型", "inviteFriend.includeChannel": "包含当前频道", "inviteFriend.link": "链接", + "inviteFriend.webspeak3Link": "WebSpeak3 链接", "inviteFriend.addPermissionKey": "添加权限密钥", "inviteFriend.copyToClipboard": "复制到剪贴板", "inviteFriend.copied": "已复制!", @@ -113,8 +114,7 @@ "whisperSettings.sound": "有人对你悄悄话时播放声音", "whisperSettings.openHistory": "有人对你悄悄话时总是打开悄悄话记录", "whisperSettings.clearAfter": "从悄悄话记录中移除客户端的时间", - "whisperSettings.never": "从不", - "whisperSettings.minutes": "{count} 分钟", + "whisperSettings.minutes": "分钟", "whisperHistory.received": "{name} 对你说了悄悄话", "whisperHistory.stopped": "已停止悄悄话", "whisperHistory.clear": "清除",