From 7a0c1e44882d3796f2e4c91d992a6a092c340b5c Mon Sep 17 00:00:00 2001
From: CodeDevMLH <145071728+CodeDevMLH@users.noreply.github.com>
Date: Thu, 19 Feb 2026 18:20:17 +0100
Subject: [PATCH] Enhance script injection by removing legacy tags and
improving logging
---
Injector_new.cs | 246 ++++++++++++++++++
.../ScriptInjector.cs | 65 ++++-
2 files changed, 300 insertions(+), 11 deletions(-)
create mode 100644 Injector_new.cs
diff --git a/Injector_new.cs b/Injector_new.cs
new file mode 100644
index 0000000..0d5003c
--- /dev/null
+++ b/Injector_new.cs
@@ -0,0 +1,246 @@
+using System;
+using System.Reflection;
+using System.IO;
+using System.Collections.Generic;
+using System.Linq;
+using System.Runtime.Loader;
+using Microsoft.Extensions.Logging;
+using Newtonsoft.Json.Linq;
+using MediaBrowser.Common.Configuration;
+using Jellyfin.Plugin.MediaBarEnhanced.Helpers;
+
+namespace Jellyfin.Plugin.MediaBarEnhanced
+{
+ ///
+ /// Handles the injection of the MediaBarEnhanced script into the Jellyfin web interface.
+ ///
+ public class ScriptInjector
+ {
+ private readonly IApplicationPaths _appPaths;
+ private readonly ILogger _logger;
+ public const string ScriptTag = "";
+ public const string CssTag = "";
+ public const string ScriptMarker = "