diff options
author | metamuffin <metamuffin@disroot.org> | 2025-03-22 14:27:25 +0100 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2025-03-22 14:27:25 +0100 |
commit | 5d4cb7864dc3ca19669877def6c298eb96d19b16 (patch) | |
tree | 92444bfd31c9080e8c09aa7368e3f6cb4156ed35 /client-web/source/room_watches.ts | |
parent | 2f5d47d21dfc308c1b930cf45e13b34445d3a8e5 (diff) | |
download | keks-meet-5d4cb7864dc3ca19669877def6c298eb96d19b16.tar keks-meet-5d4cb7864dc3ca19669877def6c298eb96d19b16.tar.bz2 keks-meet-5d4cb7864dc3ca19669877def6c298eb96d19b16.tar.zst |
new translation system
Diffstat (limited to 'client-web/source/room_watches.ts')
-rw-r--r-- | client-web/source/room_watches.ts | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/client-web/source/room_watches.ts b/client-web/source/room_watches.ts index d738359..66d11fd 100644 --- a/client-web/source/room_watches.ts +++ b/client-web/source/room_watches.ts @@ -5,7 +5,7 @@ */ /// <reference lib="dom" /> import { array_swap, e } from "./helper.ts"; -import { PO } from "./locale/mod.ts"; +import { tr } from "./locale.ts"; import { PREFS, change_pref } from "./preferences/mod.ts"; import { room_hash } from "./protocol/crypto.ts"; import { SignalingConnection } from "./protocol/mod.ts"; @@ -61,8 +61,8 @@ export function ui_room_watches(conn: SignalingConnection): HTMLElement { e("div", { class: "users" }, ...ucont), )) if (edit) el.append(e("button", { onclick(_) { watches = watches.filter(e => e != w); update_listing() } }, "X")) - if (edit && wi > 0) el.append(e("button", { onclick(_) { array_swap(watches, wi, wi - 1); update_listing() } }, PO.move_up)) - if (edit && wi < watches.length - 1) el.append(e("button", { onclick(_) { array_swap(watches, wi, wi + 1); update_listing() } }, PO.move_down)) + if (edit && wi > 0) el.append(e("button", { onclick(_) { array_swap(watches, wi, wi - 1); update_listing() } }, tr("room_watches.edit.move_up"))) + if (edit && wi < watches.length - 1) el.append(e("button", { onclick(_) { array_swap(watches, wi, wi + 1); update_listing() } }, tr("room_watches.edit.move_down"))) listing.append(el) } @@ -77,14 +77,14 @@ export function ui_room_watches(conn: SignalingConnection): HTMLElement { update_watches() input.value = "" } - }, PO.add), + }, tr("room_watches.edit.add")), e("button", { async onclick() { if (!conn.room) return await add_watch(conn.room) update_watches() } - }, PO.add_current_room) + }, tr("room_watches.edit.add_current_room")) )) } } @@ -98,7 +98,7 @@ export function ui_room_watches(conn: SignalingConnection): HTMLElement { edit = e; } return e("div", { class: "room-watches", role: "dialog", aria_label: "known rooms" }, - e("h2", {}, PO.known_rooms), + e("h2", {}, tr("room_watches")), listing, button_edit = e("button", { icon: "edit", @@ -106,7 +106,7 @@ export function ui_room_watches(conn: SignalingConnection): HTMLElement { set_edit(true) update_listing() } - }, PO.edit), + }, tr("room_watches.edit")), button_finish = e("button", { icon: "check", hidden: true, @@ -116,6 +116,6 @@ export function ui_room_watches(conn: SignalingConnection): HTMLElement { update_watches() update_listing() } - }, PO.finish_edit), + }, tr("room_watches.edit.finish")), ) } |