# wimwamwom/jellyfin-plugin-custom-logo architecture

> Architecture diagram of the GitHub repository wimwamwom/jellyfin-plugin-custom-logo, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/wimwamwom/jellyfin-plugin-custom-logo
- Repository: https://github.com/wimwamwom/jellyfin-plugin-custom-logo

## Overview

Custom Logo is a Jellyfin plugin that replaces selected web-client branding using administrator settings and uploaded or URL-based images. The main path is configuration, asset resolution, HTML/CSS transformation, then middleware rewriting the served index page. Upload management is a separate branch. The README documents the branding targets and dashboard workflow; some UI-to-endpoint wiring is not shown in the excerpts, so that relationship is marked unverified.

Main entry points: [`Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs`](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs) (Index transformer), [`Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs`](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs) (Image upload API), [`Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs`](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs) (HTML middleware), [`Jellyfin.Plugin.CustomLogo/Configuration/PluginConfiguration.cs`](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/PluginConfiguration.cs) (Plugin configuration)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_admin["Administration"]
  node_settings["Dashboard settings<br/>[configPage.html]"]
  node_config["Plugin configuration"]
  node_plugin["Plugin host<br/>[Plugin.cs]"]
end

subgraph group_assets["Image assets"]
  node_uploads["Image upload API"]
  node_slots["Image slots"]
  node_imagefiles[("Uploaded image files")]
  node_resolver["Asset resolver"]
end

subgraph group_branding["Branding transformation"]
  node_transformer["Index transformer"]
  node_css["Custom CSS builder"]
end

subgraph group_delivery["Web delivery"]
  node_registration["Service registration"]
  node_startup["Startup filter"]
  node_middleware["HTML middleware"]
end

node_admin(("Administrator"))
node_webclient["Jellyfin web client"]

node_admin -->|"configures"| node_settings
node_settings -.->|"sets options"| node_config
node_settings -.->|"uploads images"| node_uploads
node_uploads -->|"selects slot"| node_slots
node_uploads -->|"writes files"| node_imagefiles
node_uploads -->|"updates metadata"| node_config
node_plugin -->|"owns settings"| node_config
node_registration -->|"registers filter"| node_startup
node_registration -->|"registers service"| node_transformer
node_startup -->|"adds middleware"| node_middleware
node_webclient -.->|"requests index"| node_middleware
node_middleware -->|"transforms HTML"| node_transformer
node_transformer -->|"reads settings"| node_config
node_transformer -->|"resolves assets"| node_resolver
node_transformer -->|"builds styles"| node_css
node_resolver -->|"reads uploads"| node_imagefiles
node_middleware -->|"serves branded page"| node_webclient

click node_settings "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/configPage.html"
click node_config "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/PluginConfiguration.cs"
click node_plugin "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Plugin.cs"
click node_uploads "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs"
click node_slots "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/BrandingImageSlot.cs"
click node_resolver "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/BrandingAssetResolver.cs"
click node_transformer "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs"
click node_css "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomCssBuilder.cs"
click node_registration "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/PluginServiceRegistrator.cs"
click node_startup "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomLogoStartupFilter.cs"
click node_middleware "https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_settings,node_config,node_plugin,node_webclient toneBlue
class node_uploads,node_slots,node_imagefiles,node_resolver toneAmber
class node_transformer,node_css toneMint
class node_registration,node_startup,node_middleware toneRose
class node_admin toneIndigo
```

## Components

### Administration

- [Dashboard settings](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/configPage.html): `Jellyfin.Plugin.CustomLogo/Configuration/configPage.html`
- [Plugin configuration](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/PluginConfiguration.cs): `Jellyfin.Plugin.CustomLogo/Configuration/PluginConfiguration.cs`
- [Plugin host](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Plugin.cs): `Jellyfin.Plugin.CustomLogo/Plugin.cs`

### Image assets

- [Image upload API](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs): `Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs`
- [Image slots](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Configuration/BrandingImageSlot.cs): `Jellyfin.Plugin.CustomLogo/Configuration/BrandingImageSlot.cs`
- **Uploaded image files**
- [Asset resolver](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/BrandingAssetResolver.cs): `Jellyfin.Plugin.CustomLogo/Injection/BrandingAssetResolver.cs`

### Branding transformation

- [Index transformer](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs): `Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs`
- [Custom CSS builder](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomCssBuilder.cs): `Jellyfin.Plugin.CustomLogo/Injection/CustomCssBuilder.cs`

### Web delivery

- [Service registration](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/PluginServiceRegistrator.cs): `Jellyfin.Plugin.CustomLogo/PluginServiceRegistrator.cs`
- [Startup filter](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomLogoStartupFilter.cs): `Jellyfin.Plugin.CustomLogo/Injection/CustomLogoStartupFilter.cs`
- [HTML middleware](https://github.com/wimwamwom/jellyfin-plugin-custom-logo/blob/main/Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs): `Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs`

### Other components

- **Administrator**
- **Jellyfin web client**

## Connections

- Administrator → Dashboard settings: configures (evidence: `README.md`)
- Dashboard settings → Plugin configuration: sets options
- Dashboard settings → Image upload API: uploads images
- Image upload API → Image slots: selects slot (evidence: `Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs`)
- Image upload API → Uploaded image files: writes files (evidence: `Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs`)
- Image upload API → Plugin configuration: updates metadata (evidence: `Jellyfin.Plugin.CustomLogo/Controllers/CustomLogoController.cs`)
- Plugin host → Plugin configuration: owns settings (evidence: `Jellyfin.Plugin.CustomLogo/Plugin.cs`)
- Service registration → Startup filter: registers filter (evidence: `Jellyfin.Plugin.CustomLogo/PluginServiceRegistrator.cs`)
- Service registration → Index transformer: registers service (evidence: `Jellyfin.Plugin.CustomLogo/PluginServiceRegistrator.cs`)
- Startup filter → HTML middleware: adds middleware (evidence: `Jellyfin.Plugin.CustomLogo/Injection/CustomLogoStartupFilter.cs`)
- Jellyfin web client → HTML middleware: requests index
- HTML middleware → Index transformer: transforms HTML (evidence: `Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs`)
- Index transformer → Plugin configuration: reads settings (evidence: `Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs`)
- Index transformer → Asset resolver: resolves assets (evidence: `Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs`)
- Index transformer → Custom CSS builder: builds styles (evidence: `Jellyfin.Plugin.CustomLogo/Injection/IndexHtmlTransformer.cs`)
- Asset resolver → Uploaded image files: reads uploads (evidence: `Jellyfin.Plugin.CustomLogo/Injection/BrandingAssetResolver.cs`)
- HTML middleware → Jellyfin web client: serves branded page (evidence: `Jellyfin.Plugin.CustomLogo/Injection/CustomLogoMiddleware.cs`)
