feat: implement multi-provider support in media library
- Introduced IProviderRegistry to manage multiple media providers. - Updated AppState to use provider_registry instead of a single media_provider. - Refactored library routes to support provider-specific queries for collections, series, genres, and items. - Enhanced ProgrammingBlock to include provider_id for algorithmic and manual content types. - Modified frontend components to allow selection of providers and updated API calls to include provider parameters. - Adjusted hooks and types to accommodate provider-specific functionality.
This commit is contained in:
@@ -57,8 +57,8 @@ export interface RecyclePolicy {
|
||||
}
|
||||
|
||||
export type BlockContent =
|
||||
| { type: "algorithmic"; filter: MediaFilter; strategy: FillStrategy }
|
||||
| { type: "manual"; items: string[] };
|
||||
| { type: "algorithmic"; filter: MediaFilter; strategy: FillStrategy; provider_id?: string }
|
||||
| { type: "manual"; items: string[]; provider_id?: string };
|
||||
|
||||
export interface ProgrammingBlock {
|
||||
id: string;
|
||||
@@ -95,8 +95,16 @@ export interface ProviderCapabilities {
|
||||
rescan: boolean;
|
||||
}
|
||||
|
||||
export interface ProviderInfo {
|
||||
id: string;
|
||||
capabilities: ProviderCapabilities;
|
||||
}
|
||||
|
||||
export interface ConfigResponse {
|
||||
allow_registration: boolean;
|
||||
/** All registered providers. Added in multi-provider update. */
|
||||
providers: ProviderInfo[];
|
||||
/** Primary provider capabilities — kept for backward compat. */
|
||||
provider_capabilities: ProviderCapabilities;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user