2023-01-11 21:16:48 +01:00
|
|
|
import { MWStream } from "./streams";
|
|
|
|
|
|
|
|
export enum MWEmbedType {
|
2023-02-18 22:42:24 +01:00
|
|
|
M4UFREE = "m4ufree",
|
|
|
|
STREAMM4U = "streamm4u",
|
|
|
|
PLAYM4U = "playm4u"
|
2023-01-11 21:16:48 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
export type MWEmbed = {
|
|
|
|
type: MWEmbedType | null;
|
|
|
|
url: string;
|
|
|
|
};
|
|
|
|
|
|
|
|
export type MWEmbedContext = {
|
|
|
|
progress(percentage: number): void;
|
|
|
|
url: string;
|
|
|
|
};
|
|
|
|
|
|
|
|
export type MWEmbedScraper = {
|
|
|
|
id: string;
|
2023-01-15 16:01:07 +01:00
|
|
|
displayName: string;
|
2023-01-11 21:16:48 +01:00
|
|
|
for: MWEmbedType;
|
|
|
|
rank: number;
|
|
|
|
disabled?: boolean;
|
|
|
|
|
|
|
|
getStream(ctx: MWEmbedContext): Promise<MWStream>;
|
|
|
|
};
|