From 78808161c6b8726be5e18427a5da4328ab1fa26f Mon Sep 17 00:00:00 2001 From: Arjun Satarkar Date: Mon, 29 Jul 2024 01:10:14 +0530 Subject: Refactor --- priv/discord_activity.html.eex | 10 ++++++---- priv/home.html.eex | 10 +++++----- priv/room.html.eex | 32 +++++++++++++++++++++++++++++--- priv/static/room/main.js | 4 ++-- 4 files changed, 42 insertions(+), 14 deletions(-) (limited to 'priv') diff --git a/priv/discord_activity.html.eex b/priv/discord_activity.html.eex index 5cb8a68..cfdba73 100644 --- a/priv/discord_activity.html.eex +++ b/priv/discord_activity.html.eex @@ -1,5 +1,8 @@ -<% home_url="/.proxy/?#{Mediasync.Constants.query_param_discord_activity_inner()}" %> +<% +import Mediasync.Constants +home_url="/.proxy/?#{query_param_discord_activity_inner()}" +%> @@ -72,15 +75,14 @@ currently hosting:
- diff --git a/priv/static/room/main.js b/priv/static/room/main.js index 7e0ade5..9a0b2ec 100644 --- a/priv/static/room/main.js +++ b/priv/static/room/main.js @@ -40,10 +40,10 @@ { let customIconPosition = 1; const Button = videojs.getComponent("Button"); - if (HOME_URL !== null) { + if (HOME_BUTTON_URL !== null) { const homeButton = new Button(player, { clickHandler: (_) => { - location = HOME_URL; + location = HOME_BUTTON_URL; }, }); homeButton.addClass("icon-home"); -- cgit v1.2.3-57-g22cb