feat(kaak): refine audio controls and diagnostics

This commit is contained in:
illusia committed 2026-10-11 00:47:06 +08:00
1 parent afa1e89136
commit bdd0c3473c
9 files changed
+417 -60

No files matched your search

+1 -1
View File
@@ -46,7 +46,7 @@ export const BUILTIN_SKIN_CATALOG: SkinCatalogEntry[] = [
{
id: BUILTIN_KAAK_SKIN_ID,
name: "KAAK",
version: "3.1.24",
version: "3.1.27",
author: "WebSpeak Project",
license: "AGPL-3.0-only",
description: "A KOOK-inspired voice-room workspace with collapsible voice groups and current voice-channel chat, TeamSpeak profile cards, and host-owned voice controls.",
+5 -4
View File
@@ -464,7 +464,7 @@ test("the distributable KAAK package provides full home and voice surfaces", asy
const file = new File([archive], "kaak-voice.wskin", { type: "application/octet-stream" });
const skin = await importSkinPack(file);
assert.equal(skin.id, "community.kaak-voice");
assert.equal(skin.version, "3.1.24");
assert.equal(skin.version, "3.1.27");
assert.equal(BUILTIN_SKIN_CATALOG.find((entry) => entry.id === skin.id)?.version, skin.version);
assert.equal(skin.schemaVersion, 3);
const home = skin.pluginData?.components.find((component) => component.page === "home");
@@ -483,6 +483,7 @@ test("the distributable KAAK package provides full home and voice surfaces", asy
assert.ok(voice?.permissions.includes("chat.channel.send"));
assert.ok(voice?.permissions.includes("audio.microphone.control"));
assert.ok(voice?.permissions.includes("audio.output.control"));
assert.ok(voice?.permissions.includes("voice.screenShare.read"));
assert.ok(voice?.permissions.includes("voice.screenShare.control"));
function findPart(node: SkinPluginNode | undefined, part: string): SkinPluginNode | undefined {
if (!node) return undefined;
@@ -527,8 +528,8 @@ test("the distributable KAAK package provides full home and voice surfaces", asy
assert.equal(findPart(voice?.root, "voice-stage")?.attributes?.["aria-label"], "语音房间 / Voice room");
assert.equal(findPart(voice?.root, "member-cards")?.widget, "voice.member-cards");
assert.equal(findPart(voice?.root, "member-list"), undefined);
assert.equal(findPart(voice?.root, "screen-player")?.widget, "voice.screen-share-player");
assert.equal(findPart(voice?.root, "performance-panel"), undefined);
assert.equal(findPart(voice?.root, "screen-player"), undefined);
assert.equal(findPart(voice?.root, "performance-panel")?.widget, "voice.performance-panel");
assert.equal(findPart(voice?.root, "chat-input")?.bindValue, "message");
assert.equal(findPart(voice?.root, "chat-input")?.attributes?.placeholder, "给 #{{session.status.channelName}} 发消息");
assert.equal(findPart(voice?.root, "conversation-glyph")?.children?.[0]?.text, "#");
@@ -536,7 +537,7 @@ test("the distributable KAAK package provides full home and voice surfaces", asy
assert.equal(findPart(voice?.root, "chat-message-avatar")?.children?.[0]?.text, "{{message.author}}");
assert.equal(findPart(voice?.root, "chat-message-body")?.children?.[0]?.part, "chat-message-heading");
assert.equal(findPart(voice?.root, "chat-message-body")?.attributes?.["data-kind"], "{{message.kind}}");
assert.equal(findPart(voice?.root, "screen-share-start")?.widget, "voice.screen-share-start");
assert.equal(findPart(voice?.root, "screen-share-start"), undefined);
assert.equal(findPart(voice?.root, "audio-controls")?.widget, "voice.audio-controls");
assert.ok(skin.css.includes('[data-ws-plugin-part="kaak-workspace.channel-row"]'));
assert.match(skin.css, /kaak-workspace\.voice-channel-group-toggle/);