diff options
| author | metamuffin <metamuffin@disroot.org> | 2022-09-16 21:32:09 +0200 | 
|---|---|---|
| committer | metamuffin <metamuffin@disroot.org> | 2022-09-16 21:32:09 +0200 | 
| commit | 6b5e64510395c4476a3c27a9db015135e50cf878 (patch) | |
| tree | 24f47bf9b02558102e95e604c70fc6083064002a /client-web | |
| parent | 1fb9614478adc6e107324274310ebf83146779ba (diff) | |
| download | keks-meet-6b5e64510395c4476a3c27a9db015135e50cf878.tar keks-meet-6b5e64510395c4476a3c27a9db015135e50cf878.tar.bz2 keks-meet-6b5e64510395c4476a3c27a9db015135e50cf878.tar.zst | |
optional streams (5, minor fixes; done)
Diffstat (limited to 'client-web')
| -rw-r--r-- | client-web/source/chat.ts | 2 | ||||
| -rw-r--r-- | client-web/source/keybinds.ts | 3 | ||||
| -rw-r--r-- | client-web/source/preferences/ui.ts | 2 | ||||
| -rw-r--r-- | client-web/source/resource/mod.ts | 2 | ||||
| -rw-r--r-- | client-web/source/resource/track.ts | 8 | ||||
| -rw-r--r-- | client-web/source/user/local.ts | 11 | 
6 files changed, 14 insertions, 14 deletions
| diff --git a/client-web/source/chat.ts b/client-web/source/chat.ts index d6aeb00..67622d4 100644 --- a/client-web/source/chat.ts +++ b/client-web/source/chat.ts @@ -1,3 +1,5 @@ +/// <reference lib="dom" /> +  import { ChatMessage } from "../../common/packets.d.ts";  import { ediv, espan, image_view, notify, OverlayUi } from "./helper.ts";  import { log } from "./logger.ts"; diff --git a/client-web/source/keybinds.ts b/client-web/source/keybinds.ts index 028e119..fba0047 100644 --- a/client-web/source/keybinds.ts +++ b/client-web/source/keybinds.ts @@ -1,5 +1,6 @@ -import { Room } from "./room.ts" +/// <reference lib="dom" /> +import { Room } from "./room.ts"  export function setup_keybinds(room: Room) {      let command_mode = false diff --git a/client-web/source/preferences/ui.ts b/client-web/source/preferences/ui.ts index 634d945..f07996f 100644 --- a/client-web/source/preferences/ui.ts +++ b/client-web/source/preferences/ui.ts @@ -1,3 +1,5 @@ +/// <reference lib="dom" /> +  import { ebr, ebutton, ediv, elabel, espan, etd, etr, OverlayUi } from "../helper.ts";  import { PREF_DECLS } from "./decl.ts";  import { change_pref, on_pref_changed, PrefDecl, PREFS } from "./mod.ts"; diff --git a/client-web/source/resource/mod.ts b/client-web/source/resource/mod.ts index 9583604..50bc91c 100644 --- a/client-web/source/resource/mod.ts +++ b/client-web/source/resource/mod.ts @@ -1,3 +1,5 @@ +/// <reference lib="dom" /> +  import { ProvideInfo } from "../../../common/packets.d.ts"  import { ediv } from "../helper.ts"  import { log } from "../logger.ts" diff --git a/client-web/source/resource/track.ts b/client-web/source/resource/track.ts index bc26acc..b2f73ab 100644 --- a/client-web/source/resource/track.ts +++ b/client-web/source/resource/track.ts @@ -1,3 +1,5 @@ +/// <reference lib="dom" /> +  import { ProvideInfo } from "../../../common/packets.d.ts";  import { ebutton } from "../helper.ts";  import { TrackHandle } from "../track_handle.ts"; @@ -29,8 +31,10 @@ export class TrackResource extends Resource {          super.destroy()      } +    // TODO --- all the following code could be more generic and prettier in the UI --- +      create_preview(): HTMLElement { -        return ebutton("Enable", { +        return ebutton(`Enable ${this.info.kind}`, {              onclick: (e) => {                  (e as HTMLButtonElement).disabled = true;                  this.request() @@ -40,7 +44,7 @@ export class TrackResource extends Resource {      create_element() {          if (!this.track) { return this.create_preview() }          const el = document.createElement("div") -        el.append(ebutton("Disable", { +        el.append(ebutton(`Enable ${this.info.kind}`, {              onclick: (e) => {                  (e as HTMLButtonElement).disabled = true;                  this.request_stop() diff --git a/client-web/source/user/local.ts b/client-web/source/user/local.ts index 571295d..49f0099 100644 --- a/client-web/source/user/local.ts +++ b/client-web/source/user/local.ts @@ -78,17 +78,6 @@ export class LocalUser extends User {          }      } -    // send_track(t: TrackHandle) { -    //     this.room.remote_users.forEach(u => u.peer.addTrack(t.track)) -    //     t.addEventListener("ended", () => { -    //         this.room.remote_users.forEach(u => { -    //             u.peer.getSenders().forEach(s => { -    //                 if (s.track == t.track) u.peer.removeTrack(s) -    //             }) -    //         }) -    //     }) -    // } -      async create_camera_res() {          log("media", "requesting user media (camera)")          const user_media = await window.navigator.mediaDevices.getUserMedia({ | 
