Skip to content

Commit

Permalink
Add LatTeam
Browse files Browse the repository at this point in the history
  • Loading branch information
Morea committed Aug 24, 2024
1 parent cf071e0 commit 7774e21
Show file tree
Hide file tree
Showing 5 changed files with 203 additions and 101 deletions.
45 changes: 23 additions & 22 deletions Find Unique Titles/config/userscript.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,40 +28,41 @@ export const UserScriptConfig: IWebpackUserScript = {
namespace: "http://tampermonkey.net/",
author: "Mea01",
match: [
"https://cinemageddon.net/browse.php*",
"https://karagarga.in/browse.php*",
"https://hdbits.org/browse.php*",
"https://passthepopcorn.me/torrents.php*",
"https://passthepopcorn.me/torrents.php?type=seeding",
"https://beyond-hd.me/library/*",
"https://beyond-hd.me/torrents*",
"https://cinemaz.to/movies*",
"https://aither.cc/torrents?*",
"https://avistaz.to/movies*",
"https://beyond-hd.me/torrents*",
"https://beyond-hd.me/library/*",
"https://blutopia.cc/torrents?*",
"https://aither.cc/torrents?*",
"https://www.torrentleech.org/torrents/browse*",
"https://secret-cinema.pw/torrents.php*",
"https://www.clan-sudamerica.net/invision/*",
"https://newinsane.info/browse.php*",
"https://btarg.com.ar/tracker/browse.php*",
"https://js.chddiy.xyz/torrents.php*",
"https://ptchdbits.co/torrents.php*",
"https://cinemageddon.net/browse.php*",
"https://www.cinematik.net/browse.php*",
"https://cinemaz.to/movies*",
"https://filelist.io/browse.php*",
"https://jptv.club/torrents*",
"https://www.clan-sudamerica.net/invision/*",
"https://greatposterwall.com/torrents.php*",
"https://hdbits.org/browse.php*",
"https://hdsky.me/torrents.php*",
"https://hd-torrents.org/torrents.php*",
"https://iptorrents.com/t*",
"https://jpopsuki.eu/torrents.php*",
"https://jptv.club/torrents*",
"https://karagarga.in/browse.php*",
"https://kp.m-team.cc/*",
"https://lat-team.com/torrents*",
"https://www.morethantv.me/torrents/browse*",
"https://ncore.pro/torrents.php*",
"https://greatposterwall.com/torrents.php*",
"https://ptchdbits.co/torrents.php*",
"https://js.chddiy.xyz/torrents.php*",
"https://hdsky.me/torrents.php*",
"https://www.cinematik.net/browse.php*",
"https://newinsane.info/browse.php*",
"https://passthepopcorn.me/torrents.php*",
"https://passthepopcorn.me/torrents.php?type=seeding",
"https://pterclub.com/torrents.php*",
"https://secret-cinema.pw/torrents.php*",
"https://tntracker.org/*",
"https://www.torrentleech.org/torrents/browse*",
"https://pterc.com/torrents.php*",
"https://torrentseeds.org/torrents*",
"https://torrentseeds.org/categories/*",
"https://www.morethantv.me/torrents/browse*",
"https://jpopsuki.eu/torrents.php*",
"https://tntracker.org/*",
],
require: [
`https://cdn.jsdelivr.net/npm/jquery@${pkg.dependencies.jquery}/dist/jquery.min.js`,
Expand Down
126 changes: 66 additions & 60 deletions Find Unique Titles/dist/find.unique.titles.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
// @match https://www.morethantv.me/torrents/browse*
// @match https://jpopsuki.eu/torrents.php*
// @match https://tntracker.org/*
// @match https://lat-team.com/torrents*
// @downloadURL https://github.com/Moreasan/trackers-userscripts/blob/master/Find%20Unique%20Titles/dist/find.unique.titles.user.js
// @grant GM.xmlHttpRequest
// @grant GM.setValue
Expand Down Expand Up @@ -2582,69 +2583,74 @@
try {
__webpack_require__.r(__webpack_exports__);
__webpack_require__.d(__webpack_exports__, {
Aither: () => _Aither__WEBPACK_IMPORTED_MODULE_18__.default,
AvistaZ: () => _AvistaZ__WEBPACK_IMPORTED_MODULE_12__.default,
BHD: () => _BHD__WEBPACK_IMPORTED_MODULE_7__.default,
BLU: () => _BLU__WEBPACK_IMPORTED_MODULE_8__.default,
BTarg: () => _BTarg__WEBPACK_IMPORTED_MODULE_10__.default,
CG: () => _CG__WEBPACK_IMPORTED_MODULE_4__.default,
CHD: () => _CHD__WEBPACK_IMPORTED_MODULE_21__.default,
CLANSUD: () => _CLAN_SUD__WEBPACK_IMPORTED_MODULE_2__.default,
CinemaZ: () => _CinemaZ__WEBPACK_IMPORTED_MODULE_11__.default,
FL: () => _FL__WEBPACK_IMPORTED_MODULE_14__.default,
GPW: () => _GPW__WEBPACK_IMPORTED_MODULE_15__.default,
HDB: () => _HDB__WEBPACK_IMPORTED_MODULE_16__.default,
HDSky: () => _HDSky__WEBPACK_IMPORTED_MODULE_22__.default,
HDT: () => _HDT__WEBPACK_IMPORTED_MODULE_5__.default,
IPT: () => _IPT__WEBPACK_IMPORTED_MODULE_6__.default,
JPTV: () => _JPTV__WEBPACK_IMPORTED_MODULE_13__.default,
JPop: () => _JPop__WEBPACK_IMPORTED_MODULE_27__.default,
KG: () => _KG__WEBPACK_IMPORTED_MODULE_3__.default,
MTV: () => _MTV__WEBPACK_IMPORTED_MODULE_26__.default,
MTeam: () => _MTeam__WEBPACK_IMPORTED_MODULE_19__.default,
NewInsane: () => _NewInsane__WEBPACK_IMPORTED_MODULE_9__.default,
PTP: () => _PTP__WEBPACK_IMPORTED_MODULE_0__.default,
Pter: () => _Pter__WEBPACK_IMPORTED_MODULE_24__.default,
RED: () => _RED__WEBPACK_IMPORTED_MODULE_28__.default,
SC: () => _SC__WEBPACK_IMPORTED_MODULE_1__.default,
TL: () => _TL__WEBPACK_IMPORTED_MODULE_17__.default,
Aither: () => _Aither__WEBPACK_IMPORTED_MODULE_1__.default,
AvistaZ: () => _AvistaZ__WEBPACK_IMPORTED_MODULE_2__.default,
BHD: () => _BHD__WEBPACK_IMPORTED_MODULE_3__.default,
BLU: () => _BLU__WEBPACK_IMPORTED_MODULE_4__.default,
BTarg: () => _BTarg__WEBPACK_IMPORTED_MODULE_5__.default,
CG: () => _CG__WEBPACK_IMPORTED_MODULE_6__.default,
CHD: () => _CHD__WEBPACK_IMPORTED_MODULE_7__.default,
CLANSUD: () => _CLAN_SUD__WEBPACK_IMPORTED_MODULE_8__.default,
CinemaZ: () => _CinemaZ__WEBPACK_IMPORTED_MODULE_9__.default,
FL: () => _FL__WEBPACK_IMPORTED_MODULE_10__.default,
GPW: () => _GPW__WEBPACK_IMPORTED_MODULE_11__.default,
HDB: () => _HDB__WEBPACK_IMPORTED_MODULE_12__.default,
HDSky: () => _HDSky__WEBPACK_IMPORTED_MODULE_13__.default,
HDT: () => _HDT__WEBPACK_IMPORTED_MODULE_14__.default,
IPT: () => _IPT__WEBPACK_IMPORTED_MODULE_15__.default,
JPTV: () => _JPTV__WEBPACK_IMPORTED_MODULE_16__.default,
JPop: () => _JPop__WEBPACK_IMPORTED_MODULE_17__.default,
KG: () => _KG__WEBPACK_IMPORTED_MODULE_18__.default,
MTV: () => _MTV__WEBPACK_IMPORTED_MODULE_19__.default,
MTeam: () => _MTeam__WEBPACK_IMPORTED_MODULE_20__.default,
NewInsane: () => _NewInsane__WEBPACK_IMPORTED_MODULE_22__.default,
PTP: () => _PTP__WEBPACK_IMPORTED_MODULE_24__.default,
Pter: () => _Pter__WEBPACK_IMPORTED_MODULE_23__.default,
RED: () => _RED__WEBPACK_IMPORTED_MODULE_25__.default,
SC: () => _SC__WEBPACK_IMPORTED_MODULE_26__.default,
TL: () => _TL__WEBPACK_IMPORTED_MODULE_28__.default,
TNT: () => _TNT__WEBPACK_IMPORTED_MODULE_29__.default,
TSeeds: () => _TSeeds__WEBPACK_IMPORTED_MODULE_25__.default,
TiK: () => _TiK__WEBPACK_IMPORTED_MODULE_23__.default,
nCore: () => _nCore__WEBPACK_IMPORTED_MODULE_20__.default
TSeeds: () => _TSeeds__WEBPACK_IMPORTED_MODULE_30__.default,
TiK: () => _TiK__WEBPACK_IMPORTED_MODULE_27__.default,
nCore: () => _nCore__WEBPACK_IMPORTED_MODULE_21__.default
});
var _Aither__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__("./src/trackers/Aither.ts");
var _AvistaZ__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__("./src/trackers/AvistaZ.ts");
var _BHD__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__("./src/trackers/BHD.ts");
var _BLU__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__("./src/trackers/BLU.ts");
var _BTarg__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__("./src/trackers/BTarg.ts");
var _CG__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("./src/trackers/CG.ts");
var _CHD__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__("./src/trackers/CHD.ts");
var _CLAN_SUD__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("./src/trackers/CLAN-SUD.ts");
var _CinemaZ__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__("./src/trackers/CinemaZ.ts");
var _FL__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__("./src/trackers/FL.ts");
var _GPW__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__("./src/trackers/GPW.ts");
var _HDB__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__("./src/trackers/HDB.ts");
var _HDSky__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__("./src/trackers/HDSky.ts");
var _HDT__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__("./src/trackers/HDT.ts");
var _IPT__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__("./src/trackers/IPT.ts");
var _JPTV__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__("./src/trackers/JPTV.ts");
var _JPop__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__("./src/trackers/JPop.ts");
var _KG__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("./src/trackers/KG.ts");
var _MTV__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__("./src/trackers/MTV.ts");
var _MTeam__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__("./src/trackers/MTeam.ts");
var _NewInsane__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__("./src/trackers/NewInsane.ts");
var _PTP__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("./src/trackers/PTP.ts");
var _Pter__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__("./src/trackers/Pter.ts");
var _RED__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__("./src/trackers/RED.ts");
var _SC__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/trackers/SC.ts");
var _TL__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__("./src/trackers/TL.ts");
var _Aither__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/trackers/Aither.ts");
var _AvistaZ__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__("./src/trackers/AvistaZ.ts");
var _BHD__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__("./src/trackers/BHD.ts");
var _BLU__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__("./src/trackers/BLU.ts");
var _BTarg__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__("./src/trackers/BTarg.ts");
var _CG__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__("./src/trackers/CG.ts");
var _CHD__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__("./src/trackers/CHD.ts");
var _CLAN_SUD__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__("./src/trackers/CLAN-SUD.ts");
var _CinemaZ__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__("./src/trackers/CinemaZ.ts");
var _FL__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__("./src/trackers/FL.ts");
var _GPW__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__("./src/trackers/GPW.ts");
var _HDB__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__("./src/trackers/HDB.ts");
var _HDSky__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__("./src/trackers/HDSky.ts");
var _HDT__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__("./src/trackers/HDT.ts");
var _IPT__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__("./src/trackers/IPT.ts");
var _JPTV__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__("./src/trackers/JPTV.ts");
var _JPop__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__("./src/trackers/JPop.ts");
var _KG__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__("./src/trackers/KG.ts");
Object(function webpackMissingModule() {
var e = new Error("Cannot find module './LatTeam.js'");
e.code = "MODULE_NOT_FOUND";
throw e;
}());
var _MTV__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__("./src/trackers/MTV.ts");
var _MTeam__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__("./src/trackers/MTeam.ts");
var _NewInsane__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__("./src/trackers/NewInsane.ts");
var _PTP__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__("./src/trackers/PTP.ts");
var _Pter__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__("./src/trackers/Pter.ts");
var _RED__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__("./src/trackers/RED.ts");
var _SC__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__("./src/trackers/SC.ts");
var _TL__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__("./src/trackers/TL.ts");
var _TNT__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__("./src/trackers/TNT.ts");
var _TSeeds__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__("./src/trackers/TSeeds.ts");
var _TiK__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__("./src/trackers/TiK.ts");
var _nCore__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__("./src/trackers/nCore.ts");
var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([ _PTP__WEBPACK_IMPORTED_MODULE_0__ ]);
_PTP__WEBPACK_IMPORTED_MODULE_0__ = (__webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__)[0];
var _TSeeds__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__("./src/trackers/TSeeds.ts");
var _TiK__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__("./src/trackers/TiK.ts");
var _nCore__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__("./src/trackers/nCore.ts");
var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([ _PTP__WEBPACK_IMPORTED_MODULE_24__ ]);
_PTP__WEBPACK_IMPORTED_MODULE_24__ = (__webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__)[0];
__webpack_async_result__();
} catch (e) {
__webpack_async_result__(e);
Expand Down
93 changes: 93 additions & 0 deletions Find Unique Titles/src/trackers/LatTeam.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
import {
parseCodec,
parseResolution,
parseSize,
parseTags,
parseYearAndTitle,
} from "../utils/utils";
import { Category, MetaData, Request, SearchResult, tracker } from "./tracker";
import { addChild } from "common/dom";

const parseCategory = (element: Element) => {
const icon = element.querySelector(".torrent-search--list__category i");
if (!icon) return Category.OTHER;
if (icon?.classList.contains("fa-film")) return Category.MOVIE;
if (icon?.classList.contains("fa-tv-retro")) return Category.TV;

return Category.OTHER;
};
export default class LatTeam implements tracker {
canBeUsedAsSource(): boolean {
return true;
}

canBeUsedAsTarget(): boolean {
return false;
}

canRun(url: string): boolean {
return url.includes("lat-team.com");
}

async *getSearchRequest(): AsyncGenerator<MetaData | Request, void, void> {
const rows = document.querySelectorAll(
".torrent-search--list__results tbody tr"
);
let elements = Array.from(rows);
yield {
total: elements.length,
};
for (let element of elements) {
const imdbId = element.getAttribute("data-imdb-id");
let fullTitle = element
.querySelector("a.torrent-search--list__name")
?.textContent?.trim();
const { title, year } = parseYearAndTitle(fullTitle);
const size = parseSize(
element
.querySelector(".torrent-search--list__size")
?.textContent?.trim()
);
const tags = parseTags(fullTitle);
const category = parseCategory(element);
const resolution = parseResolution(
element
.querySelector(".torrent-search--list__resolution")
?.textContent?.trim()
);

const request: Request = {
torrents: [
{
dom: element,
size,
tags,
resolution,
container: parseCodec(fullTitle),
},
],
dom: [element],
imdbId,
title,
year,
category,
};
yield request;
}
}

name(): string {
return "LatTeam";
}

insertTrackersSelect(select: HTMLElement): void {
select.classList.add("form__select");
select.style.width = "180px";
addChild(
document.querySelector(
".panelV2.torrent-search__results .panel__actions"
) as HTMLElement,
select
);
}
}
38 changes: 20 additions & 18 deletions Find Unique Titles/src/trackers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import IPT from "./IPT";
import JPTV from "./JPTV";
import JPop from "./JPop";
import KG from "./KG";
import LatTeam from "./LatTeam.js";
import MTV from "./MTV";
import MTeam from "./MTeam";
import NewInsane from "./NewInsane";
Expand All @@ -30,34 +31,35 @@ import TiK from "./TiK";
import nCore from "./nCore";

export {
PTP,
SC,
CLANSUD,
KG,
CG,
HDT,
IPT,
Aither,
AvistaZ,
BHD,
BLU,
NewInsane,
BTarg,
CG,
CHD,
CLANSUD,
CinemaZ,
AvistaZ,
JPTV,
FL,
GPW,
HDB,
TL,
Aither,
HDSky,
HDT,
IPT,
JPTV,
JPop,
KG,
LatTeam,
MTV,
MTeam,
nCore,
CHD,
HDSky,
TiK,
NewInsane,
Pter,
TSeeds,
MTV,
JPop,
PTP,
RED,
SC,
TiK,
TL,
TNT,
TSeeds,
};
2 changes: 1 addition & 1 deletion Find Unique Titles/src/utils/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const parseImdbId = (text: string) => {
return results[0];
};

export const parseResolution = (text: string): Resolution | undefined => {
export const parseResolution = (text: string|undefined): Resolution | undefined => {
if (!text) return undefined;
const resolutionsAndAliases: Record<Resolution, string[]> = {
SD: ["sd", "pal", "ntsc"],
Expand Down

0 comments on commit 7774e21

Please sign in to comment.