aboutsummaryrefslogtreecommitdiff
path: root/client-web/source/locale
diff options
context:
space:
mode:
Diffstat (limited to 'client-web/source/locale')
-rw-r--r--client-web/source/locale/en.ts63
-rw-r--r--client-web/source/locale/mod.ts72
2 files changed, 135 insertions, 0 deletions
diff --git a/client-web/source/locale/en.ts b/client-web/source/locale/en.ts
new file mode 100644
index 0000000..da9d949
--- /dev/null
+++ b/client-web/source/locale/en.ts
@@ -0,0 +1,63 @@
+import { LanguageStrings } from "./mod.ts";
+
+export const PO_EN_US: LanguageStrings = {
+ microphone: "Microphone",
+ chatbox_placeholder: "Type a message",
+ chatbox_label: "send message",
+ join_message: author => [author, " joined."],
+ leave_message: author => [author, " left."],
+ summary_empty_message: "(empty message)",
+ summery_image: "(image)",
+ camera: "Camera",
+ file: "File",
+ leave: "Leave",
+ screen: "Screen",
+ image_alt: "Image (click to open)",
+ warn_mem_download: "Downloading to memory because serviceworker is not available.",
+ confirm_update: "Really update?",
+ warn_short_secret: "Room name is very short. E2EE is insecure!",
+ warn_secure_context: "This page is not a 'Secure Context'",
+ warn_no_webrtc: "WebRTC not supported.",
+ warn_no_crypto: "SubtleCrypto not availible",
+ warn_no_sw: "Your browser does not support the Service Worker API, forced automatic updates are unavoidable.",
+ warn_old_url: "You were redirected from the old URL format. The server knows the room secret now - E2EE is insecure!",
+ confirm_quit: "You have local resources shared. Really quit?",
+ controls: "Controls",
+ license: "License",
+ source_code: "Source code",
+ stop_sharing: "Stop sharing",
+ documentation: "Documentation",
+ known_rooms: "Known Rooms",
+ chat: "Chat",
+ settings: "Settings",
+ edit: "Edit",
+ finish_edit: "Finish edit",
+ add_current_room: "Add current room",
+ add: "Add",
+ move_down: "Move down",
+ move_up: "Move up",
+ unknown_user: "Unknown user",
+ status_checking: "Checking...",
+ status_connected: "Connected",
+ status_failed: "Connection failed",
+ status_disconnected: "Disconnected",
+ status_no_conn: "Not connected",
+ status_await_channel_open: "Waiting for data channel to open…",
+ status_await_channel_close: "Waiting for data channel to close…",
+ downloading: "Downloading…",
+ download_again: "Download again",
+ download: "Download",
+ status_drain_buffer: amount => `Draining buffers… (buffer: ${amount})`,
+ status_buffering: "Buffering…",
+ status_closing: "Channel closing…",
+ mute: "Mute",
+ video_stream: "video stream",
+ audio_stream: "video stream",
+ disable: "Disable",
+ enable: "Enable",
+ status_await_track: "Awaiting track…",
+ notification_perm_explain: "For keks-meet to send notifications, it needs you to grant permission: ",
+ grant: "Grant",
+ clear_prefs: "Want to clear all settings? Use this:",
+
+}
diff --git a/client-web/source/locale/mod.ts b/client-web/source/locale/mod.ts
new file mode 100644
index 0000000..4febcec
--- /dev/null
+++ b/client-web/source/locale/mod.ts
@@ -0,0 +1,72 @@
+import { PO_EN_US } from "./en.ts";
+
+export let PO: LanguageStrings;
+
+export function init_locale(lang: string) {
+ PO = LOCALES[lang]
+}
+
+export const LOCALES: { [key: string]: LanguageStrings } = {
+ "en-US": PO_EN_US
+}
+
+export interface LanguageStrings {
+ microphone: string,
+ camera: string,
+ screen: string,
+ file: string,
+ warn_short_secret: string,
+ warn_no_webrtc: string,
+ warn_secure_context: string,
+ warn_no_crypto: string,
+ warn_no_sw: string,
+ warn_old_url: string,
+ warn_mem_download: string,
+ chatbox_placeholder: string,
+ chatbox_label: string,
+ confirm_quit: string,
+ controls: string,
+ license: string,
+ source_code: string,
+ documentation: string,
+ chat: string,
+ settings: string,
+ known_rooms: string,
+ leave: string,
+ confirm_update: string,
+ image_alt: string,
+ join_message(author: HTMLElement | string): (HTMLElement | string)[],
+ leave_message(author: HTMLElement | string): (HTMLElement | string)[],
+ summary_empty_message: string,
+ summery_image: string,
+ edit: string,
+ finish_edit: string,
+ add_current_room: string,
+ add: string,
+ move_up: string,
+ move_down: string,
+ unknown_user: string,
+ status_connected: string,
+ status_no_conn: string,
+ status_checking: string,
+ status_disconnected: string,
+ status_failed: string,
+ downloading: string,
+ download: string,
+ download_again: string,
+ stop_sharing: string,
+ status_await_channel_open: string,
+ status_await_channel_close: string,
+ status_drain_buffer(amount: number): string,
+ status_buffering: string,
+ status_closing: string,
+ mute: string,
+ video_stream: string,
+ audio_stream: string,
+ enable: string,
+ disable: string,
+ notification_perm_explain: string,
+ grant: string,
+ status_await_track: string,
+ clear_prefs: string,
+}