mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-11 02:46:16 -08:00
feat(epg): support playlist-scoped sources
Add playlist-scoped EPG source support for M3U playlists.
This commit is contained in:
1 parent
36a7ce9f3d
commit
e801028005
71 files changed
+4876
-373
No files matched your search
@@ -206,6 +206,10 @@ export interface ElectronBridgeEpgFreshnessResult {
|
||||
freshUrls: string[];
|
||||
}
|
||||
|
||||
export interface ElectronBridgeEpgLookupOptions {
|
||||
sourceUrls?: string[];
|
||||
}
|
||||
|
||||
export interface ElectronBridgeEpgProgressStats {
|
||||
totalChannels: number;
|
||||
totalPrograms: number;
|
||||
@@ -509,12 +513,17 @@ export interface ElectronBridgeApi {
|
||||
urls: string[],
|
||||
options?: ElectronBridgeTrustOptions
|
||||
) => Promise<ElectronBridgeEpgFetchResult>;
|
||||
getChannelPrograms: (channelId: string) => Promise<EpgProgram[]>;
|
||||
getChannelPrograms: (
|
||||
channelId: string,
|
||||
options?: ElectronBridgeEpgLookupOptions
|
||||
) => Promise<EpgProgram[]>;
|
||||
getCurrentProgramsBatch: (
|
||||
channelIds: string[]
|
||||
channelIds: string[],
|
||||
options?: ElectronBridgeEpgLookupOptions
|
||||
) => Promise<Record<string, EpgProgram | null>>;
|
||||
getEpgChannelMetadata: (
|
||||
channelIds: string[]
|
||||
channelIds: string[],
|
||||
options?: ElectronBridgeEpgLookupOptions
|
||||
) => Promise<Record<string, EpgChannelMetadata | null>>;
|
||||
getEpgChannels: () => Promise<ElectronBridgeEpgChannelListResult>;
|
||||
getEpgChannelsByRange: (
|
||||
@@ -526,6 +535,7 @@ export interface ElectronBridgeApi {
|
||||
options?: ElectronBridgeTrustOptions
|
||||
) => Promise<ElectronBridgeEpgFetchResult>;
|
||||
clearEpgData: () => Promise<ElectronBridgeResult>;
|
||||
clearEpgDataForSource: (sourceUrl: string) => Promise<ElectronBridgeResult>;
|
||||
checkEpgFreshness: (
|
||||
urls: string[],
|
||||
maxAgeHours?: number
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
export interface ParsedPlaylist {
|
||||
header: {
|
||||
attrs: {
|
||||
'x-tvg-url': string;
|
||||
};
|
||||
attrs: Record<string, string | undefined>;
|
||||
raw: string;
|
||||
};
|
||||
items: ParsedPlaylistItem[];
|
||||
|
||||
@@ -12,6 +12,10 @@ export type PlaylistMeta = Pick<
|
||||
| 'referrer'
|
||||
| 'origin'
|
||||
| 'filePath'
|
||||
| 'epgUrls'
|
||||
| 'detectedEpgUrls'
|
||||
| 'manualEpgUrls'
|
||||
| 'disabledEpgUrls'
|
||||
| 'updateDate'
|
||||
| 'updateState'
|
||||
| 'position'
|
||||
|
||||
@@ -33,6 +33,14 @@ export interface Playlist {
|
||||
referrer?: string;
|
||||
origin?: string;
|
||||
filePath?: string;
|
||||
/** M3U-scoped EPG source URLs enabled for automatic import and lookup. */
|
||||
epgUrls?: string[];
|
||||
/** All M3U EPG source URLs detected from the playlist header. */
|
||||
detectedEpgUrls?: string[];
|
||||
/** Playlist-local EPG source URLs explicitly enabled by the user. */
|
||||
manualEpgUrls?: string[];
|
||||
/** Detected playlist EPG source URLs explicitly disabled by the user. */
|
||||
disabledEpgUrls?: string[];
|
||||
autoRefresh: boolean;
|
||||
updateDate?: number;
|
||||
updateState?: PlaylistUpdateState;
|
||||
|
||||
Reference in new issue
Block a user