mirror of
https://github.com/EchoSixHIYA/WebSpeak-client-for-TeamSpeak.git
synced 2026-12-03 03:52:50 +08:00
feat(skin): expose visitor count widget for skins
This commit is contained in:
1 parent
26c638c2a2
commit
42a0755ad0
14 files changed
+256
-159
No files matched your search
Binary file not shown.
@@ -65,60 +65,93 @@
|
||||
"tag": "svg",
|
||||
"part": "illustration",
|
||||
"attributes": {
|
||||
"viewbox": "0 0 550 510",
|
||||
"viewbox": "0 0 640 480",
|
||||
"role": "img",
|
||||
"aria-label": "WebSpeak 展示插画"
|
||||
"aria-label": "WebSpeak voice connection illustration"
|
||||
},
|
||||
"children": [
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 45,
|
||||
"y": 65,
|
||||
"width": 460,
|
||||
"height": 400,
|
||||
"rx": 80,
|
||||
"x": 40,
|
||||
"y": 22,
|
||||
"width": 560,
|
||||
"height": 436,
|
||||
"rx": 88,
|
||||
"fill": "#b0f49b"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M526 51v-18M549 61l13-13",
|
||||
"stroke": "#ff9b70",
|
||||
"stroke-width": 12,
|
||||
"fill": "none",
|
||||
"stroke-linecap": "round"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "circle",
|
||||
"attributes": {
|
||||
"cx": 526,
|
||||
"cy": 83,
|
||||
"r": 23,
|
||||
"fill": "#ff9b70"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 90,
|
||||
"y": 145,
|
||||
"width": 370,
|
||||
"height": 275,
|
||||
"rx": 28,
|
||||
"x": 295,
|
||||
"y": 394,
|
||||
"width": 50,
|
||||
"height": 29,
|
||||
"rx": 7,
|
||||
"fill": "#223641"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 103,
|
||||
"y": 157,
|
||||
"width": 344,
|
||||
"height": 250,
|
||||
"rx": 18,
|
||||
"fill": "#f7fff7"
|
||||
"x": 250,
|
||||
"y": 418,
|
||||
"width": 140,
|
||||
"height": 16,
|
||||
"rx": 8,
|
||||
"fill": "#223641"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 103,
|
||||
"y": 157,
|
||||
"width": 344,
|
||||
"height": 45,
|
||||
"rx": 18,
|
||||
"x": 120,
|
||||
"y": 110,
|
||||
"width": 400,
|
||||
"height": 288,
|
||||
"rx": 25,
|
||||
"fill": "#223641"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M147 122h346a15 15 0 0 1 15 15v234a15 15 0 0 1-15 15H147a15 15 0 0 1-15-15V137a15 15 0 0 1 15-15Z",
|
||||
"fill": "#f5fff4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M147 122h346a15 15 0 0 1 15 15v31H132v-31a15 15 0 0 1 15-15Z",
|
||||
"fill": "#e4f5e6"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "circle",
|
||||
"attributes": {
|
||||
"cx": 128,
|
||||
"cy": 178,
|
||||
"cx": 156,
|
||||
"cy": 145,
|
||||
"r": 6,
|
||||
"fill": "#82cd62"
|
||||
}
|
||||
@@ -126,8 +159,8 @@
|
||||
{
|
||||
"tag": "circle",
|
||||
"attributes": {
|
||||
"cx": 149,
|
||||
"cy": 178,
|
||||
"cx": 177,
|
||||
"cy": 145,
|
||||
"r": 6,
|
||||
"fill": "#c2e3b2"
|
||||
}
|
||||
@@ -135,10 +168,10 @@
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 135,
|
||||
"y": 236,
|
||||
"width": 135,
|
||||
"height": 14,
|
||||
"x": 160,
|
||||
"y": 205,
|
||||
"width": 128,
|
||||
"height": 13,
|
||||
"rx": 7,
|
||||
"fill": "#acdca6"
|
||||
}
|
||||
@@ -146,10 +179,10 @@
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 135,
|
||||
"y": 265,
|
||||
"width": 100,
|
||||
"height": 12,
|
||||
"x": 160,
|
||||
"y": 233,
|
||||
"width": 94,
|
||||
"height": 11,
|
||||
"rx": 6,
|
||||
"fill": "#d6e8d8"
|
||||
}
|
||||
@@ -157,10 +190,21 @@
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 135,
|
||||
"y": 292,
|
||||
"width": 110,
|
||||
"height": 12,
|
||||
"x": 160,
|
||||
"y": 258,
|
||||
"width": 112,
|
||||
"height": 11,
|
||||
"rx": 6,
|
||||
"fill": "#d6e8d8"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 160,
|
||||
"y": 283,
|
||||
"width": 84,
|
||||
"height": 11,
|
||||
"rx": 6,
|
||||
"fill": "#d6e8d8"
|
||||
}
|
||||
@@ -168,16 +212,16 @@
|
||||
{
|
||||
"tag": "circle",
|
||||
"attributes": {
|
||||
"cx": 348,
|
||||
"cy": 287,
|
||||
"r": 54,
|
||||
"fill": "#7dcf4b"
|
||||
"cx": 418,
|
||||
"cy": 250,
|
||||
"r": 46,
|
||||
"fill": "#77d33d"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M319 287v-10a29 29 0 0 1 58 0v10",
|
||||
"d": "M394 251v-10a24 24 0 0 1 48 0v10",
|
||||
"stroke": "white",
|
||||
"stroke-width": 10,
|
||||
"fill": "none",
|
||||
@@ -187,81 +231,55 @@
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 311,
|
||||
"y": 279,
|
||||
"width": 17,
|
||||
"height": 32,
|
||||
"rx": 8,
|
||||
"fill": "white"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 369,
|
||||
"y": 279,
|
||||
"width": 17,
|
||||
"height": 32,
|
||||
"rx": 8,
|
||||
"fill": "white"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 255,
|
||||
"y": 417,
|
||||
"width": 143,
|
||||
"height": 13,
|
||||
"x": 387,
|
||||
"y": 246,
|
||||
"width": 13,
|
||||
"height": 27,
|
||||
"rx": 6,
|
||||
"fill": "#233641"
|
||||
"fill": "white"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "rect",
|
||||
"attributes": {
|
||||
"x": 436,
|
||||
"y": 246,
|
||||
"width": 13,
|
||||
"height": 27,
|
||||
"rx": 6,
|
||||
"fill": "white"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "circle",
|
||||
"attributes": {
|
||||
"cx": 77,
|
||||
"cy": 348,
|
||||
"r": 39,
|
||||
"cx": 99,
|
||||
"cy": 338,
|
||||
"r": 38,
|
||||
"fill": "#55c3cf"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M58 342h12l14-12v37l-14-12H58z",
|
||||
"d": "M76 330h9l14-12v38l-14-12h-9z",
|
||||
"fill": "white"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M92 340q12 12 0 25",
|
||||
"d": "M107 327q13 13 0 27",
|
||||
"stroke": "white",
|
||||
"stroke-width": 5,
|
||||
"fill": "none"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "circle",
|
||||
"attributes": {
|
||||
"cx": 457,
|
||||
"cy": 100,
|
||||
"r": 18,
|
||||
"fill": "#ff9b70"
|
||||
}
|
||||
},
|
||||
{
|
||||
"tag": "path",
|
||||
"attributes": {
|
||||
"d": "M454 75v-23M478 76l15-14",
|
||||
"stroke": "#ff9b70",
|
||||
"stroke-width": 9,
|
||||
"fill": "none",
|
||||
"stroke-linecap": "round"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"widget": "home.visitor-count",
|
||||
"part": "visitor-stats"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"packageType": "open-skin",
|
||||
"id": "community.kaak-voice",
|
||||
"name": "KAAK",
|
||||
"version": "3.1.108",
|
||||
"version": "3.1.115",
|
||||
"author": "WebSpeak Project",
|
||||
"license": "AGPL-3.0-only",
|
||||
"description": "A KOOK-inspired WebSpeak skin with a split-screen connection home, searchable server header, TeamSpeak banner, nested channel members, unified chat with local history, and a compact audio dock.",
|
||||
|
||||
@@ -16,14 +16,19 @@
|
||||
--skin-kaak-font: "PingFang SC", "Microsoft YaHei New", 微软雅黑, "Microsoft Yahei", "Microsoft JhengHei", 宋体, SimSun, "Helvetica Neue", Helvetica, Arial, sans-serif;
|
||||
}
|
||||
|
||||
[data-ws-plugin-part="kaak-home"] {
|
||||
[data-ws-plugin-part="kaak-home.home"] {
|
||||
--skin-kaak-home-green: #77cb25;
|
||||
--skin-kaak-home-text: #273248;
|
||||
--skin-kaak-home-muted: #8995a5;
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
|
||||
min-height: 100vh;
|
||||
min-height: 100dvh;
|
||||
grid-template-rows: minmax(0, 1fr);
|
||||
width: 100%;
|
||||
height: calc(var(--ws-viewport-height, 100dvh) / var(--ui-scale, 1));
|
||||
min-height: calc(var(--ws-viewport-height, 100dvh) / var(--ui-scale, 1));
|
||||
max-height: calc(var(--ws-viewport-height, 100dvh) / var(--ui-scale, 1));
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
color: var(--skin-kaak-home-text);
|
||||
color-scheme: light;
|
||||
font-family: Arial, "Microsoft YaHei", sans-serif;
|
||||
@@ -120,7 +125,10 @@
|
||||
|
||||
[data-ws-plugin-part="kaak-home.hero"] {
|
||||
position: relative;
|
||||
min-height: 600px;
|
||||
display: grid;
|
||||
grid-template-rows: auto auto auto minmax(0, 1fr);
|
||||
min-width: 0;
|
||||
min-height: 0;
|
||||
overflow: visible;
|
||||
background: linear-gradient(145deg, #f7ffbd, #d9ffb3 55%, #b7f89e);
|
||||
}
|
||||
@@ -225,21 +233,42 @@
|
||||
}
|
||||
|
||||
[data-ws-plugin-part="kaak-home.hero-media"] {
|
||||
position: absolute;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
inset: 43% 6% 5%;
|
||||
display: grid;
|
||||
width: auto;
|
||||
min-width: 0;
|
||||
min-height: 0;
|
||||
margin: clamp(16px, 2.8dvh, 32px) 6% 5%;
|
||||
place-items: center;
|
||||
overflow: hidden;
|
||||
border-radius: 20px;
|
||||
}
|
||||
|
||||
[data-ws-plugin-part="kaak-home.illustration"] {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
min-width: 0;
|
||||
max-height: 100%;
|
||||
}
|
||||
|
||||
[data-ws-plugin-part="kaak-home.visitor-stats"] {
|
||||
position: absolute;
|
||||
top: 64%;
|
||||
left: 50%;
|
||||
z-index: 2;
|
||||
width: max-content;
|
||||
max-width: 58%;
|
||||
transform: translate(-50%, -50%);
|
||||
}
|
||||
|
||||
[data-ws-plugin-part="kaak-home.visitor-stats"] [data-ws-part="home.visitors"] {
|
||||
max-width: 100%;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
[data-ws-plugin-part="kaak-home.right"] {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -507,7 +536,7 @@
|
||||
}
|
||||
|
||||
@media (max-width: 850px) {
|
||||
[data-ws-plugin-part="kaak-home"] {
|
||||
[data-ws-plugin-part="kaak-home.home"] {
|
||||
grid-template-columns: minmax(0, 1fr);
|
||||
}
|
||||
|
||||
@@ -2061,8 +2090,8 @@
|
||||
[data-ws-plugin-part="kaak-workspace"][data-ws-plugin-surface="voice"] .ws-plugin-disconnect-control:hover { background: #3a292b; }
|
||||
|
||||
[data-ws-plugin-part="kaak-workspace"][data-ws-plugin-surface="voice"] button:focus-visible,
|
||||
[data-ws-plugin-part="kaak-home"] button:focus-visible,
|
||||
[data-ws-plugin-part="kaak-home"] input:focus-visible {
|
||||
[data-ws-plugin-part="kaak-home.home"] button:focus-visible,
|
||||
[data-ws-plugin-part="kaak-home.home"] input:focus-visible {
|
||||
outline: 2px solid var(--skin-kaak-accent);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
@@ -2228,7 +2257,7 @@
|
||||
[data-ws-plugin-part="kaak-workspace"][data-ws-plugin-surface="voice"] { transition: none; }
|
||||
[data-ws-plugin-part="kaak-workspace.conversation"],
|
||||
[data-ws-plugin-part="kaak-workspace.chat-panel-expand"] { transition: none; }
|
||||
[data-ws-plugin-part="kaak-home"] *,
|
||||
[data-ws-plugin-part="kaak-home.home"] *,
|
||||
[data-ws-plugin-part="kaak-workspace"][data-ws-plugin-surface="voice"] * {
|
||||
scroll-behavior: auto;
|
||||
animation-duration: .01ms;
|
||||
|
||||
Reference in new issue
Block a user