From e4d38a4c649e9e2fe531de3ca95ac45dc3f35222 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Sun, 11 Sep 2022 15:58:40 +0200 Subject: webrtc debugger --- client-web/source/user/mod.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'client-web/source/user/mod.ts') diff --git a/client-web/source/user/mod.ts b/client-web/source/user/mod.ts index e2db9e9..581ac7e 100644 --- a/client-web/source/user/mod.ts +++ b/client-web/source/user/mod.ts @@ -1,5 +1,6 @@ /// +import { epre, espan } from "../helper.ts"; import { ROOM_CONTAINER } from "../index.ts"; import { log } from "../logger.ts" import { Room } from "../room.ts" @@ -11,7 +12,8 @@ export abstract class User { public local = false public tracks: Set = new Set() - private name_el = document.createElement("span") + private name_el = espan("") + protected stats_el = epre("", { class: "stats" }) private _name?: string get name() { return this._name } set name(n: string | undefined) { this._name = n; this.name_el.textContent = this.display_name } @@ -49,7 +51,7 @@ export abstract class User { info_el.classList.add("info") this.name_el.textContent = this.display_name this.name_el.classList.add("name") - info_el.append(this.name_el) + info_el.append(this.name_el, this.stats_el) this.el.append(info_el) } -- cgit v1.2.3-70-g09d2