Skip to content

Conversation

kamilkosek
Copy link

Summary

  • Introduces a new settings entry settings.tvSidebarLinks to configure custom TV app sidebar links (name,type: library|collection, id, icon).
  • Extends SidebarLink to support optional sections (reusing the existing Section model) so each sidebar link can render curated content like “Recently Added” or “Continue Watching”.

Why

Enables richer navigation in the TV app by letting admins present curated, link-specific content pages, improving usability and discoverability.

Notes

Backward compatible: tvSidebarLinks and sections are optional.
UI/editor and consumption logic can be extended to render per-link sections similarly to home.sections.

@kamilkosek kamilkosek changed the title Feat/tv sidebar options feat: tv sidebar options Sep 16, 2025
@lostb1t lostb1t requested a review from Copilot September 16, 2025 08:39
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Introduces TV app sidebar customization by adding a new tvSidebarLinks setting that allows administrators to configure custom sidebar links with optional content sections. This enhancement improves TV app navigation by enabling curated content pages for specific libraries or collections.

  • Adds SidebarLink model with support for libraries/collections and optional sections
  • Introduces SidebarLinkType enum to differentiate between library and collection links
  • Extends settings configuration to include tvSidebarLinks with default empty array

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
examples/full.yml Provides comprehensive configuration examples for TV sidebar links with sections
Jellyfin.Plugin.Streamyfin/Configuration/Settings/Settings.cs Defines SidebarLink model and adds tvSidebarLinks property to Settings
Jellyfin.Plugin.Streamyfin/Configuration/Settings/Enums.cs Adds SidebarLinkType enum for library/collection differentiation
Jellyfin.Plugin.Streamyfin/Configuration/PluginConfiguration.cs Initializes tvSidebarLinks with empty array default

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.


[NotNull]
[Display(Name = "TV sidebar links", Description = "Custom links to show in the TV app sidebar")]
public Lockable<SidebarLink[]?>? tvSidebarLinks { get; set; }
Copy link
Preview

Copilot AI Sep 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The nested nullable types Lockable<SidebarLink[]?>? create unnecessary complexity. Consider simplifying to Lockable<SidebarLink[]>? since the inner array can be empty instead of null.

Suggested change
public Lockable<SidebarLink[]?>? tvSidebarLinks { get; set; }
public Lockable<SidebarLink[]>? tvSidebarLinks { get; set; }

Copilot uses AI. Check for mistakes.

marlinServerUrl = new() { value = "Enter marlin server url" },
libraryOptions = new() { value = new LibraryOptions() },
libraryOptions = new() { value = new LibraryOptions() },
tvSidebarLinks = new() { value = new SidebarLink[] { } },
Copy link
Preview

Copilot AI Sep 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using Array.Empty<SidebarLink>() instead of new SidebarLink[] { } for better performance and clarity when initializing empty arrays.

Suggested change
tvSidebarLinks = new() { value = new SidebarLink[] { } },
tvSidebarLinks = new() { value = Array.Empty<SidebarLink>() },

Copilot uses AI. Check for mistakes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant