mirror of
https://github.com/alexhopeoconnor/dnsmasq-webui.git
synced 2026-10-03 22:12:00 +10:00
Reorganize: Hubs→Realtime, Dnsmasq→Status/Logs/AppLogs, Extensions→DI/Hosting/Interop, EffectiveConfig→shared feature
This commit is contained in:
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq
|
@namespace DnsmasqWebUI.Components.Dnsmasq.AppLogs
|
||||||
@inject ILoggingClient LoggingClient
|
@inject ILoggingClient LoggingClient
|
||||||
@inject IJSRuntime JSRuntime
|
@inject IJSRuntime JSRuntime
|
||||||
@implements IAsyncDisposable
|
@implements IAsyncDisposable
|
||||||
+2
-2
@@ -1,10 +1,10 @@
|
|||||||
using DnsmasqWebUI.Extensions;
|
using DnsmasqWebUI.Extensions.Interop;
|
||||||
using DnsmasqWebUI.Infrastructure.Client.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Client.Abstractions;
|
||||||
using Microsoft.AspNetCore.Components;
|
using Microsoft.AspNetCore.Components;
|
||||||
using Microsoft.AspNetCore.Components.Web;
|
using Microsoft.AspNetCore.Components.Web;
|
||||||
using Microsoft.JSInterop;
|
using Microsoft.JSInterop;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Components.Dnsmasq;
|
namespace DnsmasqWebUI.Components.Dnsmasq.AppLogs;
|
||||||
|
|
||||||
public partial class AppLogsFiltersModal : IAsyncDisposable
|
public partial class AppLogsFiltersModal : IAsyncDisposable
|
||||||
{
|
{
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq
|
@namespace DnsmasqWebUI.Components.Dnsmasq.AppLogs
|
||||||
@* App logs — live view via SignalR from ILogger *@
|
@* App logs — live view via SignalR from ILogger *@
|
||||||
@using DnsmasqWebUI.Models.Logs
|
@using DnsmasqWebUI.Models.Logs
|
||||||
@using Microsoft.AspNetCore.SignalR.Client
|
@using Microsoft.AspNetCore.SignalR.Client
|
||||||
+2
-2
@@ -1,11 +1,11 @@
|
|||||||
using DnsmasqWebUI.Extensions;
|
using DnsmasqWebUI.Extensions.Interop;
|
||||||
using DnsmasqWebUI.Infrastructure.Client.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Client.Abstractions;
|
||||||
using DnsmasqWebUI.Models.Logs;
|
using DnsmasqWebUI.Models.Logs;
|
||||||
using Microsoft.AspNetCore.Components;
|
using Microsoft.AspNetCore.Components;
|
||||||
using Microsoft.AspNetCore.SignalR.Client;
|
using Microsoft.AspNetCore.SignalR.Client;
|
||||||
using Microsoft.JSInterop;
|
using Microsoft.JSInterop;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Components.Dnsmasq;
|
namespace DnsmasqWebUI.Components.Dnsmasq.AppLogs;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// App logs block: connects to LogsHub, receives AppLogsUpdate pushes, polls at interval as fallback.
|
/// App logs block: connects to LogsHub, receives AppLogsUpdate pushes, polls at interval as fallback.
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq
|
@namespace DnsmasqWebUI.Components.Dnsmasq.Logs
|
||||||
@* Renders a pre element for logs. Once Freeze is true, stops re-rendering so Blazor does not overwrite JS-owned content. *@
|
@* Renders a pre element for logs. Once Freeze is true, stops re-rendering so Blazor does not overwrite JS-owned content. *@
|
||||||
<pre id="@Id" class="pre-block mb-0" style="max-height: 24rem;">@Placeholder</pre>
|
<pre id="@Id" class="pre-block mb-0" style="max-height: 24rem;">@Placeholder</pre>
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq
|
@namespace DnsmasqWebUI.Components.Dnsmasq.Logs
|
||||||
@* Recent logs — live view via SignalR from LogsCommand; client polls at interval, server pushes deltas *@
|
@* Recent logs — live view via SignalR from LogsCommand; client polls at interval, server pushes deltas *@
|
||||||
@using DnsmasqWebUI.Models.Logs
|
@using DnsmasqWebUI.Models.Logs
|
||||||
@using Microsoft.AspNetCore.SignalR.Client
|
@using Microsoft.AspNetCore.SignalR.Client
|
||||||
+2
-2
@@ -1,11 +1,11 @@
|
|||||||
using DnsmasqWebUI.Extensions;
|
using DnsmasqWebUI.Extensions.Interop;
|
||||||
using DnsmasqWebUI.Models.Dnsmasq;
|
using DnsmasqWebUI.Models.Dnsmasq;
|
||||||
using DnsmasqWebUI.Models.Logs;
|
using DnsmasqWebUI.Models.Logs;
|
||||||
using Microsoft.AspNetCore.Components;
|
using Microsoft.AspNetCore.Components;
|
||||||
using Microsoft.AspNetCore.SignalR.Client;
|
using Microsoft.AspNetCore.SignalR.Client;
|
||||||
using Microsoft.JSInterop;
|
using Microsoft.JSInterop;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Components.Dnsmasq;
|
namespace DnsmasqWebUI.Components.Dnsmasq.Logs;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Recent logs block: connects to LogsHub, polls at interval via RequestDnsmasqLogs,
|
/// Recent logs block: connects to LogsHub, polls at interval via RequestDnsmasqLogs,
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq
|
@namespace DnsmasqWebUI.Components.Dnsmasq.Status
|
||||||
@* Service status — output of StatusShowCommand; only this component re-renders on its timer *@
|
@* Service status — output of StatusShowCommand; only this component re-renders on its timer *@
|
||||||
@if (_status != null && _status.StatusShowConfigured)
|
@if (_status != null && _status.StatusShowConfigured)
|
||||||
{
|
{
|
||||||
+1
-1
@@ -2,7 +2,7 @@ using DnsmasqWebUI.Infrastructure.Client.Abstractions;
|
|||||||
using DnsmasqWebUI.Models.Dnsmasq;
|
using DnsmasqWebUI.Models.Dnsmasq;
|
||||||
using Microsoft.AspNetCore.Components;
|
using Microsoft.AspNetCore.Components;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Components.Dnsmasq;
|
namespace DnsmasqWebUI.Components.Dnsmasq.Status;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Service status block: polls StatusShowCommand output at its own interval and re-renders only itself.
|
/// Service status block: polls StatusShowCommand output at its own interval and re-renders only itself.
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@inject IJSRuntime JSRuntime
|
@inject IJSRuntime JSRuntime
|
||||||
|
|
||||||
<div class="d-flex align-items-center gap-1 @CssClass">
|
<div class="d-flex align-items-center gap-1 @CssClass">
|
||||||
+1
-1
@@ -3,7 +3,7 @@ using Microsoft.AspNetCore.Components.Web;
|
|||||||
using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig;
|
using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig;
|
namespace DnsmasqWebUI.Components.EffectiveConfig;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Base for effective-config custom value displays. Provides shared parameters,
|
/// Base for effective-config custom value displays. Provides shared parameters,
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
|
|
||||||
<div class="ec-toolbar @(IsEditMode ? "ec-edit-toolbar" : "")">
|
<div class="ec-toolbar @(IsEditMode ? "ec-edit-toolbar" : "")">
|
||||||
@if (ShowSearchBox)
|
@if (ShowSearchBox)
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig.CustomDisplays
|
@namespace DnsmasqWebUI.Components.EffectiveConfig.CustomDisplays
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@inherits EffectiveConfigValueDisplayBase
|
@inherits EffectiveConfigValueDisplayBase
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig.CustomDisplays
|
@namespace DnsmasqWebUI.Components.EffectiveConfig.CustomDisplays
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@inherits EffectiveConfigValueDisplayBase
|
@inherits EffectiveConfigValueDisplayBase
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig.CustomDisplays
|
@namespace DnsmasqWebUI.Components.EffectiveConfig.CustomDisplays
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@inherits EffectiveConfigValueDisplayBase
|
@inherits EffectiveConfigValueDisplayBase
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig.CustomDisplays
|
@namespace DnsmasqWebUI.Components.EffectiveConfig.CustomDisplays
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@inherits EffectiveConfigValueDisplayBase
|
@inherits EffectiveConfigValueDisplayBase
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig.CustomDisplays
|
@namespace DnsmasqWebUI.Components.EffectiveConfig.CustomDisplays
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@inherits EffectiveConfigValueDisplayBase
|
@inherits EffectiveConfigValueDisplayBase
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Config
|
@using DnsmasqWebUI.Models.Config
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
+2
-2
@@ -1,5 +1,5 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Extensions
|
@using DnsmasqWebUI.Extensions.DependencyInjection
|
||||||
@using Microsoft.AspNetCore.Components
|
@using Microsoft.AspNetCore.Components
|
||||||
@using Microsoft.JSInterop
|
@using Microsoft.JSInterop
|
||||||
@using System.Text.Json.Serialization
|
@using System.Text.Json.Serialization
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions
|
@using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions
|
@using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
<ConfigOptionHelpModal HelpKey="@HelpKey" AnchorId="@AnchorId" Visible="@Visible" Title="@Title"
|
<ConfigOptionHelpModal HelpKey="@HelpKey" AnchorId="@AnchorId" Visible="@Visible" Title="@Title"
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
<span id="@AnchorId" class="@EffectiveCssClass" title="@Title" @onclick="OnClick" @onmouseleave="OnMouseLeave">
|
<span id="@AnchorId" class="@EffectiveCssClass" title="@Title" @onclick="OnClick" @onmouseleave="OnMouseLeave">
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
||||||
|
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
||||||
@using DnsmasqWebUI.Extensions
|
@using DnsmasqWebUI.Extensions
|
||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
@namespace DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@namespace DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq
|
@using DnsmasqWebUI.Models.Dnsmasq
|
||||||
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig
|
||||||
|
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
using DnsmasqWebUI.Extensions;
|
|
||||||
using DnsmasqWebUI.Models.Client;
|
using DnsmasqWebUI.Models.Client;
|
||||||
|
using DnsmasqWebUI.Extensions.Interop;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.UI.Settings.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.UI.Settings.Abstractions;
|
||||||
using Microsoft.AspNetCore.Components;
|
using Microsoft.AspNetCore.Components;
|
||||||
using Microsoft.AspNetCore.Components.Web;
|
using Microsoft.AspNetCore.Components.Web;
|
||||||
|
|||||||
@@ -7,7 +7,9 @@
|
|||||||
@using Microsoft.AspNetCore.Components.Web.Virtualization
|
@using Microsoft.AspNetCore.Components.Web.Virtualization
|
||||||
@using Microsoft.JSInterop
|
@using Microsoft.JSInterop
|
||||||
@using DnsmasqWebUI
|
@using DnsmasqWebUI
|
||||||
@using DnsmasqWebUI.Extensions
|
@using DnsmasqWebUI.Extensions.DependencyInjection
|
||||||
|
@using DnsmasqWebUI.Extensions.Hosting
|
||||||
|
@using DnsmasqWebUI.Extensions.Interop
|
||||||
@using DnsmasqWebUI.Models.Client
|
@using DnsmasqWebUI.Models.Client
|
||||||
@using DnsmasqWebUI.Models.Client.Abstractions
|
@using DnsmasqWebUI.Models.Client.Abstractions
|
||||||
@using DnsmasqWebUI.Infrastructure.Services.Common.Process.Abstractions
|
@using DnsmasqWebUI.Infrastructure.Services.Common.Process.Abstractions
|
||||||
@@ -23,7 +25,10 @@
|
|||||||
@using DnsmasqWebUI.Components.Shared
|
@using DnsmasqWebUI.Components.Shared
|
||||||
@using DnsmasqWebUI.Components.Modals
|
@using DnsmasqWebUI.Components.Modals
|
||||||
@using DnsmasqWebUI.Components.Dnsmasq
|
@using DnsmasqWebUI.Components.Dnsmasq
|
||||||
@using DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig
|
@using DnsmasqWebUI.Components.Dnsmasq.Status
|
||||||
|
@using DnsmasqWebUI.Components.Dnsmasq.Logs
|
||||||
|
@using DnsmasqWebUI.Components.Dnsmasq.AppLogs
|
||||||
|
@using DnsmasqWebUI.Components.EffectiveConfig
|
||||||
@using DnsmasqWebUI.Components.Hosts
|
@using DnsmasqWebUI.Components.Hosts
|
||||||
@using DnsmasqWebUI.Infrastructure
|
@using DnsmasqWebUI.Infrastructure
|
||||||
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
@using DnsmasqWebUI.Infrastructure.Helpers.Config
|
||||||
|
|||||||
+1
-1
@@ -7,7 +7,7 @@ using Microsoft.Extensions.Configuration;
|
|||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Extensions;
|
namespace DnsmasqWebUI.Extensions.DependencyInjection;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// App logs setup: buffer, channel, and provider.
|
/// App logs setup: buffer, channel, and provider.
|
||||||
+1
-1
@@ -5,7 +5,7 @@ using DnsmasqWebUI.Infrastructure.Services.Registration.Abstractions;
|
|||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Extensions;
|
namespace DnsmasqWebUI.Extensions.DependencyInjection;
|
||||||
|
|
||||||
public static class ServiceCollectionExtensions
|
public static class ServiceCollectionExtensions
|
||||||
{
|
{
|
||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
using Microsoft.AspNetCore.Builder;
|
using Microsoft.AspNetCore.Builder;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Extensions;
|
namespace DnsmasqWebUI.Extensions.Hosting;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// CORS configuration from app settings (Cors:Enabled, Cors:PolicyName, Cors:AllowAnyOrigin, etc.).
|
/// CORS configuration from app settings (Cors:Enabled, Cors:PolicyName, Cors:AllowAnyOrigin, etc.).
|
||||||
+1
-1
@@ -2,7 +2,7 @@ using System.Net;
|
|||||||
using Microsoft.AspNetCore.Builder;
|
using Microsoft.AspNetCore.Builder;
|
||||||
using Microsoft.AspNetCore.HttpOverrides;
|
using Microsoft.AspNetCore.HttpOverrides;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Extensions;
|
namespace DnsmasqWebUI.Extensions.Hosting;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Middleware configuration from app settings (forwarded headers, HTTPS, CORS).
|
/// Middleware configuration from app settings (forwarded headers, HTTPS, CORS).
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
using Microsoft.JSInterop;
|
using Microsoft.JSInterop;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Extensions;
|
namespace DnsmasqWebUI.Extensions.Interop;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Safe JS module interop helpers that swallow disconnect/cancel/dispose exceptions.
|
/// Safe JS module interop helpers that swallow disconnect/cancel/dispose exceptions.
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
using Microsoft.JSInterop;
|
using Microsoft.JSInterop;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Extensions;
|
namespace DnsmasqWebUI.Extensions.Interop;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Safe JS interop helpers that swallow disconnect/cancel/dispose exceptions.
|
/// Safe JS interop helpers that swallow disconnect/cancel/dispose exceptions.
|
||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
using DnsmasqWebUI.Infrastructure.Services.Logs.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.Logs.Abstractions;
|
||||||
using Microsoft.AspNetCore.SignalR;
|
using Microsoft.AspNetCore.SignalR;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Hubs;
|
namespace DnsmasqWebUI.Infrastructure.Realtime.Hubs;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// SignalR hub for log streaming. Clients receive DnsmasqLogsUpdate and AppLogsUpdate.
|
/// SignalR hub for log streaming. Clients receive DnsmasqLogsUpdate and AppLogsUpdate.
|
||||||
+1
-1
@@ -4,7 +4,7 @@ using DnsmasqWebUI.Models.Dnsmasq;
|
|||||||
using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig;
|
using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig;
|
||||||
using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig.Abstractions;
|
using DnsmasqWebUI.Models.Dnsmasq.EffectiveConfig.Abstractions;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.EffectiveConfig.Abstractions;
|
||||||
using DnsmasqWebUI.Components.Dnsmasq.EffectiveConfig.CustomDisplays;
|
using DnsmasqWebUI.Components.EffectiveConfig.CustomDisplays;
|
||||||
|
|
||||||
namespace DnsmasqWebUI.Infrastructure.Services.EffectiveConfig;
|
namespace DnsmasqWebUI.Infrastructure.Services.EffectiveConfig;
|
||||||
|
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ using System.Text;
|
|||||||
using DnsmasqWebUI.Infrastructure.Services.Common.Process.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.Common.Process.Abstractions;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.Logs.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.Logs.Abstractions;
|
||||||
using DnsmasqWebUI.Models.Config;
|
using DnsmasqWebUI.Models.Config;
|
||||||
|
using DnsmasqWebUI.Infrastructure.Realtime.Hubs;
|
||||||
using DnsmasqWebUI.Models.Logs;
|
using DnsmasqWebUI.Models.Logs;
|
||||||
using Microsoft.AspNetCore.SignalR;
|
using Microsoft.AspNetCore.SignalR;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
@@ -21,7 +22,7 @@ public sealed class LogsService : ILogsService
|
|||||||
/// <summary>Max bytes per SignalR message (under 32KB default).</summary>
|
/// <summary>Max bytes per SignalR message (under 32KB default).</summary>
|
||||||
private const int MaxMessageContentBytes = 28 * 1024;
|
private const int MaxMessageContentBytes = 28 * 1024;
|
||||||
|
|
||||||
private readonly IHubContext<Hubs.LogsHub> _hubContext;
|
private readonly IHubContext<LogsHub> _hubContext;
|
||||||
private readonly IServiceScopeFactory _scopeFactory;
|
private readonly IServiceScopeFactory _scopeFactory;
|
||||||
private readonly IOptions<DnsmasqOptions> _options;
|
private readonly IOptions<DnsmasqOptions> _options;
|
||||||
private readonly IAppLogsBuffer _appLogsBuffer;
|
private readonly IAppLogsBuffer _appLogsBuffer;
|
||||||
@@ -30,7 +31,7 @@ public sealed class LogsService : ILogsService
|
|||||||
private string _lastDnsmasqOutput = "";
|
private string _lastDnsmasqOutput = "";
|
||||||
|
|
||||||
public LogsService(
|
public LogsService(
|
||||||
IHubContext<Hubs.LogsHub> hubContext,
|
IHubContext<LogsHub> hubContext,
|
||||||
IServiceScopeFactory scopeFactory,
|
IServiceScopeFactory scopeFactory,
|
||||||
IOptions<DnsmasqOptions> options,
|
IOptions<DnsmasqOptions> options,
|
||||||
IAppLogsBuffer appLogsBuffer,
|
IAppLogsBuffer appLogsBuffer,
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
using System.Text.Json;
|
using System.Text.Json;
|
||||||
using DnsmasqWebUI.Extensions;
|
using DnsmasqWebUI.Extensions.Interop;
|
||||||
using DnsmasqWebUI.Models.Client;
|
using DnsmasqWebUI.Models.Client;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.UI.Settings.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.UI.Settings.Abstractions;
|
||||||
using Microsoft.JSInterop;
|
using Microsoft.JSInterop;
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Text.Json;
|
using System.Text.Json;
|
||||||
using DnsmasqWebUI.Extensions;
|
using DnsmasqWebUI.Extensions.DependencyInjection;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.Updates.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.Updates.Abstractions;
|
||||||
using DnsmasqWebUI.Models.Config;
|
using DnsmasqWebUI.Models.Config;
|
||||||
using Microsoft.Extensions.Options;
|
using Microsoft.Extensions.Options;
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
using DnsmasqWebUI.Components;
|
using DnsmasqWebUI.Components;
|
||||||
using DnsmasqWebUI.Hubs;
|
using DnsmasqWebUI.Infrastructure.Realtime.Hubs;
|
||||||
using DnsmasqWebUI.Models.Config;
|
using DnsmasqWebUI.Models.Config;
|
||||||
using DnsmasqWebUI.Extensions;
|
using DnsmasqWebUI.Extensions.DependencyInjection;
|
||||||
|
using DnsmasqWebUI.Extensions.Hosting;
|
||||||
using DnsmasqWebUI.Infrastructure.Helpers.Http;
|
using DnsmasqWebUI.Infrastructure.Helpers.Http;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.UI.Settings;
|
using DnsmasqWebUI.Infrastructure.Services.UI.Settings;
|
||||||
using DnsmasqWebUI.Infrastructure.Services.UI.Settings.Abstractions;
|
using DnsmasqWebUI.Infrastructure.Services.UI.Settings.Abstractions;
|
||||||
|
|||||||
Reference in New Issue
Block a user