minify again

This commit is contained in:
himanshu8443
2025-07-13 11:25:52 +05:30
parent 4d450e5be5
commit bd060abce3
139 changed files with 139 additions and 10578 deletions

View File

@@ -1,18 +1 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.genres = exports.catalog = void 0;
exports.catalog = [
{
title: "Home",
filter: "",
},
{
title: "Movies",
filter: "/movie",
},
{
title: "TV Shows",
filter: "/tv",
},
];
exports.genres = [];
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.genres=exports.catalog=void 0,exports.catalog=[{title:"Home",filter:""},{title:"Movies",filter:"/movie"},{title:"TV Shows",filter:"/tv"}],exports.genres=[];

View File

@@ -1,54 +1 @@
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.getEpisodes = void 0;
const getEpisodes = function (_a) {
return __awaiter(this, arguments, void 0, function* ({ url: id, providerContext, }) {
const { axios } = providerContext;
try {
const [fileId, febboxId] = id.split("&");
const febLink = febboxId
? `https://www.febbox.com/file/file_share_list?share_key=${fileId}&pwd=&parent_id=${febboxId}&is_html=0`
: `https://www.febbox.com/file/file_share_list?share_key=${fileId}&pwd=&is_html=0`;
const res = yield axios.get(febLink);
const data = res.data;
const fileList = data.data.file_list;
const episodeLinks = [];
fileList === null || fileList === void 0 ? void 0 : fileList.map((file) => {
const fileName = formatEpisodeName(file.file_name);
const epId = file === null || file === void 0 ? void 0 : file.fid;
if (!file.is_dir && fileName && epId) {
episodeLinks.push({
title: fileName,
link: `${fileId}&${epId}`,
});
}
});
return episodeLinks;
}
catch (err) {
return [];
}
});
};
exports.getEpisodes = getEpisodes;
function formatEpisodeName(title) {
const regex = /[sS](\d+)\s*[eE](\d+)/;
const match = title.match(regex);
if (match) {
const season = match[1].padStart(2, "0");
const episode = match[2].padStart(2, "0");
return `Season${season} Episode${episode}`;
}
else {
return title;
}
}
"use strict";var __awaiter=this&&this.__awaiter||function(thisArg,_arguments,P,generator){return new(P||(P=Promise))(function(resolve,reject){function fulfilled(value){try{step(generator.next(value))}catch(e){reject(e)}}function rejected(value){try{step(generator.throw(value))}catch(e){reject(e)}}function step(result){var value;result.done?resolve(result.value):(value=result.value,value instanceof P?value:new P(function(resolve){resolve(value)})).then(fulfilled,rejected)}step((generator=generator.apply(thisArg,_arguments||[])).next())})};Object.defineProperty(exports,"__esModule",{value:!0}),exports.getEpisodes=void 0;const getEpisodes=function(_a){return __awaiter(this,arguments,void 0,function*({url:id,providerContext:providerContext}){const{axios:axios}=providerContext;try{const[fileId,febboxId]=id.split("&"),febLink=febboxId?`https://www.febbox.com/file/file_share_list?share_key=${fileId}&pwd=&parent_id=${febboxId}&is_html=0`:`https://www.febbox.com/file/file_share_list?share_key=${fileId}&pwd=&is_html=0`,res=yield axios.get(febLink),fileList=res.data.data.file_list,episodeLinks=[];return null==fileList||fileList.map(file=>{const fileName=formatEpisodeName(file.file_name),epId=null==file?void 0:file.fid;!file.is_dir&&fileName&&epId&&episodeLinks.push({title:fileName,link:`${fileId}&${epId}`})}),episodeLinks}catch(err){return[]}})};function formatEpisodeName(title){const match=title.match(/[sS](\d+)\s*[eE](\d+)/);if(match){return`Season${match[1].padStart(2,"0")} Episode${match[2].padStart(2,"0")}`}return title}exports.getEpisodes=getEpisodes;

77
dist/showbox/meta.js vendored
View File

@@ -1,76 +1 @@
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.getMeta = void 0;
const getMeta = function (_a) {
return __awaiter(this, arguments, void 0, function* ({ link, providerContext, }) {
var _b, _c, _d, _e, _f, _g, _h, _j, _k;
try {
const { axios, cheerio, getBaseUrl } = providerContext;
const baseUrlShowbox = yield getBaseUrl("showbox");
const url = baseUrlShowbox + link;
const res = yield axios.get(url);
const data = res.data;
const $ = cheerio.load(data);
const type = url.includes("tv") ? "series" : "movie";
const imdbId = "";
const title = $(".heading-name").text();
const rating = ((_c = (_b = $(".btn-imdb")
.text()) === null || _b === void 0 ? void 0 : _b.match(/\d+(\.\d+)?/g)) === null || _c === void 0 ? void 0 : _c[0]) || "";
const image = ((_e = (_d = $(".cover_follow").attr("style")) === null || _d === void 0 ? void 0 : _d.split("url(")[1]) === null || _e === void 0 ? void 0 : _e.split(")")[0]) || "";
const synopsis = (_g = (_f = $(".description")
.text()) === null || _f === void 0 ? void 0 : _f.replace(/[\n\t]/g, "")) === null || _g === void 0 ? void 0 : _g.trim();
const febID = (_j = (_h = $(".heading-name").find("a").attr("href")) === null || _h === void 0 ? void 0 : _h.split("/")) === null || _j === void 0 ? void 0 : _j.pop();
const baseUrl = url.split("/").slice(0, 3).join("/");
const indexUrl = `${baseUrl}/index/share_link?id=${febID}&type=${type === "movie" ? "1" : "2"}`;
const indexRes = yield axios.get(indexUrl);
const indexData = indexRes.data;
const febKey = indexData.data.link.split("/").pop();
const febLink = `https://www.febbox.com/file/file_share_list?share_key=${febKey}&is_html=0`;
const febRes = yield axios.get(febLink);
const febData = febRes.data;
const fileList = (_k = febData === null || febData === void 0 ? void 0 : febData.data) === null || _k === void 0 ? void 0 : _k.file_list;
const links = [];
if (fileList) {
fileList.map((file) => {
const fileName = `${file.file_name} (${file.file_size})`;
const fileId = file.fid;
links.push({
title: fileName,
episodesLink: file.is_dir ? `${febKey}&${fileId}` : `${febKey}&`,
});
});
}
return {
title,
rating,
synopsis,
image,
imdbId,
type,
linkList: links,
};
}
catch (err) {
console.error("Error fetching metadata:", err);
return {
title: "",
rating: "",
synopsis: "",
image: "",
imdbId: "",
type: "",
linkList: [],
};
}
});
};
exports.getMeta = getMeta;
"use strict";var __awaiter=this&&this.__awaiter||function(thisArg,_arguments,P,generator){return new(P||(P=Promise))(function(resolve,reject){function fulfilled(value){try{step(generator.next(value))}catch(e){reject(e)}}function rejected(value){try{step(generator.throw(value))}catch(e){reject(e)}}function step(result){var value;result.done?resolve(result.value):(value=result.value,value instanceof P?value:new P(function(resolve){resolve(value)})).then(fulfilled,rejected)}step((generator=generator.apply(thisArg,_arguments||[])).next())})};Object.defineProperty(exports,"__esModule",{value:!0}),exports.getMeta=void 0;const getMeta=function(_a){return __awaiter(this,arguments,void 0,function*({link:link,providerContext:providerContext}){var _b,_c,_d,_e,_f,_g,_h,_j,_k;try{const{axios:axios,cheerio:cheerio,getBaseUrl:getBaseUrl}=providerContext,url=(yield getBaseUrl("showbox"))+link,data=(yield axios.get(url)).data,$=cheerio.load(data),type=url.includes("tv")?"series":"movie",imdbId="",title=$(".heading-name").text(),rating=(null===(_c=null===(_b=$(".btn-imdb").text())||void 0===_b?void 0:_b.match(/\d+(\.\d+)?/g))||void 0===_c?void 0:_c[0])||"",image=(null===(_e=null===(_d=$(".cover_follow").attr("style"))||void 0===_d?void 0:_d.split("url(")[1])||void 0===_e?void 0:_e.split(")")[0])||"",synopsis=null===(_g=null===(_f=$(".description").text())||void 0===_f?void 0:_f.replace(/[\n\t]/g,""))||void 0===_g?void 0:_g.trim(),febID=null===(_j=null===(_h=$(".heading-name").find("a").attr("href"))||void 0===_h?void 0:_h.split("/"))||void 0===_j?void 0:_j.pop(),indexUrl=`${url.split("/").slice(0,3).join("/")}/index/share_link?id=${febID}&type=${"movie"===type?"1":"2"}`,indexRes=yield axios.get(indexUrl),febKey=indexRes.data.data.link.split("/").pop(),febLink=`https://www.febbox.com/file/file_share_list?share_key=${febKey}&is_html=0`,febData=(yield axios.get(febLink)).data,fileList=null===(_k=null==febData?void 0:febData.data)||void 0===_k?void 0:_k.file_list,links=[];return fileList&&fileList.map(file=>{const fileName=`${file.file_name} (${file.file_size})`,fileId=file.fid;links.push({title:fileName,episodesLink:file.is_dir?`${febKey}&${fileId}`:`${febKey}&`})}),{title:title,rating:rating,synopsis:synopsis,image:image,imdbId:imdbId,type:type,linkList:links}}catch(err){return{title:"",rating:"",synopsis:"",image:"",imdbId:"",type:"",linkList:[]}}})};exports.getMeta=getMeta;

63
dist/showbox/posts.js vendored
View File

@@ -1,62 +1 @@
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.getSearchPosts = exports.getPosts = void 0;
const getPosts = function (_a) {
return __awaiter(this, arguments, void 0, function* ({ filter, page,
// providerValue,
signal, providerContext, }) {
const { getBaseUrl, axios, cheerio } = providerContext;
const baseUrl = yield getBaseUrl("showbox");
const url = `${baseUrl + filter}?page=${page}/`;
return posts({ url, signal, baseUrl, axios, cheerio });
});
};
exports.getPosts = getPosts;
const getSearchPosts = function (_a) {
return __awaiter(this, arguments, void 0, function* ({ searchQuery, page,
// providerValue,
signal, providerContext, }) {
const { getBaseUrl, axios, cheerio } = providerContext;
const baseUrl = yield getBaseUrl("showbox");
const url = `${baseUrl}/search?keyword=${searchQuery}&page=${page}`;
return posts({ url, signal, baseUrl, axios, cheerio });
});
};
exports.getSearchPosts = getSearchPosts;
function posts(_a) {
return __awaiter(this, arguments, void 0, function* ({ url, signal,
// baseUrl,
axios, cheerio, }) {
try {
const res = yield axios.get(url, { signal });
const data = res.data;
const $ = cheerio.load(data);
const catalog = [];
$(".movie-item,.flw-item").map((i, element) => {
const title = $(element).find(".film-name").text().trim();
const link = $(element).find("a").attr("href");
const image = $(element).find("img").attr("src");
if (title && link && image) {
catalog.push({
title: title,
link: link,
image: image,
});
}
});
return catalog;
}
catch (err) {
return [];
}
});
}
"use strict";var __awaiter=this&&this.__awaiter||function(thisArg,_arguments,P,generator){return new(P||(P=Promise))(function(resolve,reject){function fulfilled(value){try{step(generator.next(value))}catch(e){reject(e)}}function rejected(value){try{step(generator.throw(value))}catch(e){reject(e)}}function step(result){var value;result.done?resolve(result.value):(value=result.value,value instanceof P?value:new P(function(resolve){resolve(value)})).then(fulfilled,rejected)}step((generator=generator.apply(thisArg,_arguments||[])).next())})};Object.defineProperty(exports,"__esModule",{value:!0}),exports.getSearchPosts=exports.getPosts=void 0;const getPosts=function(_a){return __awaiter(this,arguments,void 0,function*({filter:filter,page:page,signal:signal,providerContext:providerContext}){const{getBaseUrl:getBaseUrl,axios:axios,cheerio:cheerio}=providerContext,baseUrl=yield getBaseUrl("showbox");return posts({url:`${baseUrl+filter}?page=${page}/`,signal:signal,baseUrl:baseUrl,axios:axios,cheerio:cheerio})})};exports.getPosts=getPosts;const getSearchPosts=function(_a){return __awaiter(this,arguments,void 0,function*({searchQuery:searchQuery,page:page,signal:signal,providerContext:providerContext}){const{getBaseUrl:getBaseUrl,axios:axios,cheerio:cheerio}=providerContext,baseUrl=yield getBaseUrl("showbox");return posts({url:`${baseUrl}/search?keyword=${searchQuery}&page=${page}`,signal:signal,baseUrl:baseUrl,axios:axios,cheerio:cheerio})})};function posts(_a){return __awaiter(this,arguments,void 0,function*({url:url,signal:signal,axios:axios,cheerio:cheerio}){try{const data=(yield axios.get(url,{signal:signal})).data,$=cheerio.load(data),catalog=[];return $(".movie-item,.flw-item").map((i,element)=>{const title=$(element).find(".film-name").text().trim(),link=$(element).find("a").attr("href"),image=$(element).find("img").attr("src");title&&link&&image&&catalog.push({title:title,link:link,image:image})}),catalog}catch(err){return[]}})}exports.getSearchPosts=getSearchPosts;

View File

@@ -1,47 +1 @@
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.getStream = void 0;
const getStream = function (_a) {
return __awaiter(this, arguments, void 0, function* ({ link: id,
// type,
signal, providerContext, }) {
try {
const { axios, cheerio } = providerContext;
const stream = [];
const [, epId] = id.split("&");
const url = `https://febbox.vercel.app/api/video-quality?fid=${epId}`;
const res = yield axios.get(url, { signal });
const data = res.data;
const $ = cheerio.load(data.html);
$(".file_quality").each((i, el) => {
const server = $(el).find("p.name").text() +
" - " +
$(el).find("p.size").text() +
" - " +
$(el).find("p.speed").text();
const link = $(el).attr("data-url");
if (link) {
stream.push({
server: server,
type: "mkv",
link: link,
});
}
});
return stream;
}
catch (err) {
return [];
}
});
};
exports.getStream = getStream;
"use strict";var __awaiter=this&&this.__awaiter||function(thisArg,_arguments,P,generator){return new(P||(P=Promise))(function(resolve,reject){function fulfilled(value){try{step(generator.next(value))}catch(e){reject(e)}}function rejected(value){try{step(generator.throw(value))}catch(e){reject(e)}}function step(result){var value;result.done?resolve(result.value):(value=result.value,value instanceof P?value:new P(function(resolve){resolve(value)})).then(fulfilled,rejected)}step((generator=generator.apply(thisArg,_arguments||[])).next())})};Object.defineProperty(exports,"__esModule",{value:!0}),exports.getStream=void 0;const getStream=function(_a){return __awaiter(this,arguments,void 0,function*({link:id,signal:signal,providerContext:providerContext}){try{const{axios:axios,cheerio:cheerio}=providerContext,stream=[],[,epId]=id.split("&"),url=`https://febbox.vercel.app/api/video-quality?fid=${epId}`,data=(yield axios.get(url,{signal:signal})).data,$=cheerio.load(data.html);return $(".file_quality").each((i,el)=>{const server=$(el).find("p.name").text()+" - "+$(el).find("p.size").text()+" - "+$(el).find("p.speed").text(),link=$(el).attr("data-url");link&&stream.push({server:server,type:"mkv",link:link})}),stream}catch(err){return[]}})};exports.getStream=getStream;