summaryrefslogtreecommitdiff
path: root/client-web/source
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2023-02-21 15:52:06 +0100
committermetamuffin <metamuffin@disroot.org>2023-02-21 15:52:06 +0100
commite31c48f5a9cfe6fd8988b83b17e00538fa69d6d3 (patch)
tree84576e2ca97dcbb939c0daa744fc26e16f602d78 /client-web/source
parent630cd2b82887da49cacb2deb032c6a51b3c2faf7 (diff)
downloadkeks-meet-e31c48f5a9cfe6fd8988b83b17e00538fa69d6d3.tar
keks-meet-e31c48f5a9cfe6fd8988b83b17e00538fa69d6d3.tar.bz2
keks-meet-e31c48f5a9cfe6fd8988b83b17e00538fa69d6d3.tar.zst
server-side appearance config
Diffstat (limited to 'client-web/source')
-rw-r--r--client-web/source/index.ts16
-rw-r--r--client-web/source/preferences/decl.ts6
-rw-r--r--client-web/source/protocol/mod.ts1
3 files changed, 15 insertions, 8 deletions
diff --git a/client-web/source/index.ts b/client-web/source/index.ts
index 4590625..83f1dfc 100644
--- a/client-web/source/index.ts
+++ b/client-web/source/index.ts
@@ -18,7 +18,13 @@ export const VERSION = "0.1.12"
export const ROOM_CONTAINER = esection({ class: "room", aria_label: "user list" })
export interface ClientConfig {
- appearance: { accent: string }
+ appearance?: {
+ accent: string
+ accent_dark: string
+ accent_light: string
+ background: string
+ background_dark: string
+ }
webrtc: {
stun: string,
turn?: string,
@@ -73,6 +79,14 @@ export async function main() {
username: config.webrtc.turn_user,
}]
}
+ if (config.appearance) {
+ document.body.style.setProperty("--ac", config.appearance.accent)
+ document.body.style.setProperty("--ac-dark", config.appearance.accent_dark)
+ document.body.style.setProperty("--ac-light", config.appearance.accent_light)
+ document.body.style.setProperty("--bg", config.appearance.background)
+ document.body.style.setProperty("--bg-dark", config.appearance.background_dark)
+
+ }
r = new Room(conn, rtc_config)
diff --git a/client-web/source/preferences/decl.ts b/client-web/source/preferences/decl.ts
index 68cb9ee..f3f8e84 100644
--- a/client-web/source/preferences/decl.ts
+++ b/client-web/source/preferences/decl.ts
@@ -18,13 +18,7 @@ export const PREF_DECLS = {
username: { type: string, default: "guest-" + hex_id(), description: "Username", allow_url: true },
warn_redirect: { type: bool, hidden: true, default: false, description: "Internal option that is set by a server redirect.", allow_url: true },
image_view_popup: { type: bool, default: true, description: "Open image in popup instead of new tab" },
-
- // TODO!
- /* WEBRTC */
webrtc_debug: { type: bool, default: false, description: "Show additional information for WebRTC related stuff" },
- webrtc_stun: { type: string, default: "stun:meet.metamuffin.org:16900", description: "Custom STUN server (all participants must use the same server)" },
- webrtc_turn: { type: optional(string), default: "turn:meet.metamuffin.org:16900", description: "Custom TURN server (all participants must use the same server)" },
- webrtc_turn_cred: { type: optional(string), description: "TURN server credentials" },
/* MEDIA */
microphone_enabled: { type: bool, default: false, description: "Add one microphone track on startup" },
diff --git a/client-web/source/protocol/mod.ts b/client-web/source/protocol/mod.ts
index 3674c08..6d49a17 100644
--- a/client-web/source/protocol/mod.ts
+++ b/client-web/source/protocol/mod.ts
@@ -33,7 +33,6 @@ export class SignalingConnection {
this.on_open()
r()
})
- log("ws", "connection opened")
return this
}