From 7c3a7e9572a7f52bc1c0ce17b36f5ac592bc7d52 Mon Sep 17 00:00:00 2001 From: Miroslav Pejic Date: Fri, 10 Jan 2025 09:21:18 +0100 Subject: [PATCH] [call-me] - make app title and name customizable --- package.json | 2 +- public/client.js | 5 +++++ public/config.js | 2 ++ public/index.html | 4 ++-- 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 0b2f760..3bf8af4 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "call-me", - "version": "1.0.46", + "version": "1.0.47", "description": "Your Go-To for Instant Video Calls", "author": "Miroslav Pejic - miroslav.pejic.85@gmail.com", "license": "AGPLv3", diff --git a/public/client.js b/public/client.js index 874d406..c41d376 100755 --- a/public/client.js +++ b/public/client.js @@ -13,6 +13,8 @@ const socket = io(); const config = { iceServers: [{ urls: 'stun:stun.l.google.com:19302' }] }; // DOM elements +const appTitle = document.getElementById('appTitle'); +const appName = document.getElementById('appName'); const attribution = document.getElementById('attribution'); const randomImage = document.getElementById('randomImage'); const sessionTime = document.getElementById('sessionTime'); @@ -50,6 +52,9 @@ document.addEventListener('DOMContentLoaded', async function () { }); // Handle config +appTitle.innerText = app.title; +appName.innerText = app.name; + const elementsToHide = [ { condition: !app.showGithub, element: githubDiv }, { condition: !app.attribution, element: attribution }, diff --git a/public/config.js b/public/config.js index 736303d..91d24b9 100644 --- a/public/config.js +++ b/public/config.js @@ -1,6 +1,8 @@ 'use strict'; const app = { + title: 'Call-me', + name: 'Call-me', showGithub: true, attribution: true, //... diff --git a/public/index.html b/public/index.html index 3b3ca64..a9ad6bd 100755 --- a/public/index.html +++ b/public/index.html @@ -1,7 +1,7 @@ - Call-me + Call-me @@ -64,7 +64,7 @@
-

Call-me

+

Call-me