feedscout 1.9.0 → 2.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/common/discover/defaults.js +1 -3
- package/dist/common/discover/utils.d.ts +2 -3
- package/dist/common/uris/feed/types.d.ts +2 -2
- package/dist/feeds/extractors.js +2 -2
- package/dist/feeds/platform/handlers/discourse.js +2 -6
- package/dist/feeds/platform/handlers/libsyn.js +1 -1
- package/package.json +23 -62
- package/dist/blogrolls/defaults.cjs +0 -57
- package/dist/blogrolls/defaults.d.cts +0 -16
- package/dist/blogrolls/extractors.cjs +0 -21
- package/dist/blogrolls/extractors.d.cts +0 -7
- package/dist/blogrolls/index.cjs +0 -25
- package/dist/blogrolls/index.d.cts +0 -7
- package/dist/blogrolls/types.d.cts +0 -6
- package/dist/blogrolls.cjs +0 -12
- package/dist/blogrolls.d.cts +0 -4
- package/dist/common/discover/defaults.cjs +0 -46
- package/dist/common/discover/defaults.d.cts +0 -6
- package/dist/common/discover/index.cjs +0 -105
- package/dist/common/discover/utils.cjs +0 -101
- package/dist/common/discover/utils.d.cts +0 -6
- package/dist/common/locales.cjs +0 -348
- package/dist/common/types.cjs +0 -10
- package/dist/common/types.d.cts +0 -90
- package/dist/common/uris/feed/index.cjs +0 -12
- package/dist/common/uris/feed/index.d.cts +0 -6
- package/dist/common/uris/feed/types.d.cts +0 -9
- package/dist/common/uris/guess/index.cjs +0 -8
- package/dist/common/uris/guess/index.d.cts +0 -7
- package/dist/common/uris/guess/types.d.cts +0 -10
- package/dist/common/uris/guess/utils.cjs +0 -42
- package/dist/common/uris/guess/utils.d.cts +0 -8
- package/dist/common/uris/headers/index.cjs +0 -26
- package/dist/common/uris/headers/index.d.cts +0 -6
- package/dist/common/uris/headers/types.d.cts +0 -9
- package/dist/common/uris/html/handlers.cjs +0 -59
- package/dist/common/uris/html/index.cjs +0 -35
- package/dist/common/uris/html/index.d.cts +0 -6
- package/dist/common/uris/html/types.d.cts +0 -13
- package/dist/common/uris/index.cjs +0 -32
- package/dist/common/uris/platform/index.cjs +0 -10
- package/dist/common/uris/platform/index.d.cts +0 -7
- package/dist/common/uris/platform/types.d.cts +0 -13
- package/dist/common/utils.cjs +0 -98
- package/dist/common/utils.d.cts +0 -12
- package/dist/favicons/defaults.cjs +0 -65
- package/dist/favicons/defaults.d.cts +0 -18
- package/dist/favicons/extractors.cjs +0 -25
- package/dist/favicons/extractors.d.cts +0 -7
- package/dist/favicons/index.cjs +0 -29
- package/dist/favicons/index.d.cts +0 -7
- package/dist/favicons/platform/handlers/bluesky.cjs +0 -27
- package/dist/favicons/platform/handlers/codeberg.cjs +0 -19
- package/dist/favicons/platform/handlers/deviantart.cjs +0 -29
- package/dist/favicons/platform/handlers/devto.cjs +0 -31
- package/dist/favicons/platform/handlers/github.cjs +0 -19
- package/dist/favicons/platform/handlers/githubGist.cjs +0 -19
- package/dist/favicons/platform/handlers/gitlab.cjs +0 -38
- package/dist/favicons/platform/handlers/lobsters.cjs +0 -21
- package/dist/favicons/platform/handlers/mastodon.cjs +0 -40
- package/dist/favicons/platform/handlers/reddit.cjs +0 -42
- package/dist/favicons/platform/handlers/sourceforge.cjs +0 -21
- package/dist/favicons/platform/handlers/tumblr.cjs +0 -16
- package/dist/favicons/types.d.cts +0 -4
- package/dist/favicons/utils.cjs +0 -10
- package/dist/favicons.cjs +0 -12
- package/dist/favicons.d.cts +0 -4
- package/dist/feeds/defaults.cjs +0 -290
- package/dist/feeds/defaults.d.cts +0 -21
- package/dist/feeds/extractors.cjs +0 -46
- package/dist/feeds/extractors.d.cts +0 -7
- package/dist/feeds/index.cjs +0 -26
- package/dist/feeds/index.d.cts +0 -7
- package/dist/feeds/platform/handlers/acast.cjs +0 -26
- package/dist/feeds/platform/handlers/ameblo.cjs +0 -36
- package/dist/feeds/platform/handlers/applePodcasts.cjs +0 -26
- package/dist/feeds/platform/handlers/arena.cjs +0 -42
- package/dist/feeds/platform/handlers/artstation.cjs +0 -52
- package/dist/feeds/platform/handlers/audioboom.cjs +0 -23
- package/dist/feeds/platform/handlers/bearblog.cjs +0 -45
- package/dist/feeds/platform/handlers/behance.cjs +0 -56
- package/dist/feeds/platform/handlers/blogspot.cjs +0 -72
- package/dist/feeds/platform/handlers/bluesky.cjs +0 -20
- package/dist/feeds/platform/handlers/bookwyrm.cjs +0 -48
- package/dist/feeds/platform/handlers/buttondown.cjs +0 -43
- package/dist/feeds/platform/handlers/buzzsprout.cjs +0 -22
- package/dist/feeds/platform/handlers/codeberg.cjs +0 -69
- package/dist/feeds/platform/handlers/csdn.cjs +0 -20
- package/dist/feeds/platform/handlers/dailymotion.cjs +0 -86
- package/dist/feeds/platform/handlers/deviantart.cjs +0 -85
- package/dist/feeds/platform/handlers/devto.cjs +0 -58
- package/dist/feeds/platform/handlers/discourse.cjs +0 -70
- package/dist/feeds/platform/handlers/douban.cjs +0 -56
- package/dist/feeds/platform/handlers/dreamwidth.cjs +0 -48
- package/dist/feeds/platform/handlers/exblog.cjs +0 -35
- package/dist/feeds/platform/handlers/fireside.cjs +0 -24
- package/dist/feeds/platform/handlers/friendica.cjs +0 -44
- package/dist/feeds/platform/handlers/ghost.cjs +0 -30
- package/dist/feeds/platform/handlers/github.cjs +0 -122
- package/dist/feeds/platform/handlers/githubGist.cjs +0 -56
- package/dist/feeds/platform/handlers/gitlab.cjs +0 -98
- package/dist/feeds/platform/handlers/goodreads.cjs +0 -49
- package/dist/feeds/platform/handlers/hackernews.cjs +0 -21
- package/dist/feeds/platform/handlers/hashnode.cjs +0 -16
- package/dist/feeds/platform/handlers/hatenablog.cjs +0 -56
- package/dist/feeds/platform/handlers/hearthis.cjs +0 -32
- package/dist/feeds/platform/handlers/heyWorld.cjs +0 -18
- package/dist/feeds/platform/handlers/insanejournal.cjs +0 -69
- package/dist/feeds/platform/handlers/itchio.cjs +0 -111
- package/dist/feeds/platform/handlers/kickstarter.cjs +0 -22
- package/dist/feeds/platform/handlers/lemmy.cjs +0 -88
- package/dist/feeds/platform/handlers/letterboxd.cjs +0 -46
- package/dist/feeds/platform/handlers/libsyn.cjs +0 -25
- package/dist/feeds/platform/handlers/listed.cjs +0 -20
- package/dist/feeds/platform/handlers/livejournal.cjs +0 -68
- package/dist/feeds/platform/handlers/lobsters.cjs +0 -57
- package/dist/feeds/platform/handlers/mastodon.cjs +0 -74
- package/dist/feeds/platform/handlers/mataroa.cjs +0 -16
- package/dist/feeds/platform/handlers/medium.cjs +0 -68
- package/dist/feeds/platform/handlers/microblog.cjs +0 -55
- package/dist/feeds/platform/handlers/misskey.cjs +0 -40
- package/dist/feeds/platform/handlers/myanimelist.cjs +0 -43
- package/dist/feeds/platform/handlers/naverBlog.cjs +0 -21
- package/dist/feeds/platform/handlers/nebula.cjs +0 -68
- package/dist/feeds/platform/handlers/note.cjs +0 -53
- package/dist/feeds/platform/handlers/observable.cjs +0 -34
- package/dist/feeds/platform/handlers/odysee.cjs +0 -20
- package/dist/feeds/platform/handlers/pagecord.cjs +0 -16
- package/dist/feeds/platform/handlers/paragraph.cjs +0 -20
- package/dist/feeds/platform/handlers/pika.cjs +0 -35
- package/dist/feeds/platform/handlers/pinterest.cjs +0 -57
- package/dist/feeds/platform/handlers/pixelfed.cjs +0 -46
- package/dist/feeds/platform/handlers/pleroma.cjs +0 -34
- package/dist/feeds/platform/handlers/podbean.cjs +0 -29
- package/dist/feeds/platform/handlers/podigee.cjs +0 -29
- package/dist/feeds/platform/handlers/posthaven.cjs +0 -24
- package/dist/feeds/platform/handlers/producthunt.cjs +0 -29
- package/dist/feeds/platform/handlers/prose.cjs +0 -26
- package/dist/feeds/platform/handlers/qiita.cjs +0 -58
- package/dist/feeds/platform/handlers/reddit.cjs +0 -149
- package/dist/feeds/platform/handlers/rssCom.cjs +0 -20
- package/dist/feeds/platform/handlers/seesaa.cjs +0 -22
- package/dist/feeds/platform/handlers/soundcloud.cjs +0 -39
- package/dist/feeds/platform/handlers/sourceforge.cjs +0 -53
- package/dist/feeds/platform/handlers/spreaker.cjs +0 -21
- package/dist/feeds/platform/handlers/stackExchange.cjs +0 -64
- package/dist/feeds/platform/handlers/steam.cjs +0 -35
- package/dist/feeds/platform/handlers/substack.cjs +0 -23
- package/dist/feeds/platform/handlers/tildes.cjs +0 -41
- package/dist/feeds/platform/handlers/tistory.cjs +0 -16
- package/dist/feeds/platform/handlers/transistor.cjs +0 -29
- package/dist/feeds/platform/handlers/tumblr.cjs +0 -24
- package/dist/feeds/platform/handlers/v2ex.cjs +0 -35
- package/dist/feeds/platform/handlers/velog.cjs +0 -24
- package/dist/feeds/platform/handlers/vimeo.cjs +0 -75
- package/dist/feeds/platform/handlers/weblogLol.cjs +0 -26
- package/dist/feeds/platform/handlers/weebly.cjs +0 -25
- package/dist/feeds/platform/handlers/wordpress.cjs +0 -209
- package/dist/feeds/platform/handlers/wpengine.cjs +0 -10
- package/dist/feeds/platform/handlers/writeas.cjs +0 -51
- package/dist/feeds/platform/handlers/ximalaya.cjs +0 -20
- package/dist/feeds/platform/handlers/youtube.cjs +0 -97
- package/dist/feeds/platform/handlers/zenn.cjs +0 -54
- package/dist/feeds/types.d.cts +0 -9
- package/dist/feeds.cjs +0 -16
- package/dist/feeds.d.cts +0 -4
- package/dist/hubs/discover/index.cjs +0 -30
- package/dist/hubs/discover/index.d.cts +0 -7
- package/dist/hubs/discover/types.d.cts +0 -15
- package/dist/hubs/feed/index.cjs +0 -32
- package/dist/hubs/headers/index.cjs +0 -17
- package/dist/hubs/html/index.cjs +0 -28
- package/dist/hubs.cjs +0 -0
- package/dist/hubs.d.cts +0 -2
- package/dist/index.cjs +0 -13
- package/dist/index.d.cts +0 -8
- package/dist/methods.cjs +0 -15
- package/dist/methods.d.cts +0 -7
- package/dist/utils.cjs +0 -9
- package/dist/utils.d.cts +0 -3
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/artstation.ts
|
|
3
|
-
const hosts = ["artstation.com", "www.artstation.com"];
|
|
4
|
-
const domainSuffix = /\.artstation\.com$/i;
|
|
5
|
-
const excludedPaths = [
|
|
6
|
-
"blogs",
|
|
7
|
-
"channels",
|
|
8
|
-
"contests",
|
|
9
|
-
"features",
|
|
10
|
-
"jobs",
|
|
11
|
-
"learning",
|
|
12
|
-
"login",
|
|
13
|
-
"marketplace",
|
|
14
|
-
"prints",
|
|
15
|
-
"search",
|
|
16
|
-
"signup",
|
|
17
|
-
"studios",
|
|
18
|
-
"terms"
|
|
19
|
-
];
|
|
20
|
-
const artstationHandler = {
|
|
21
|
-
match: (url) => {
|
|
22
|
-
return require_utils.isHostOf(url, hosts) || require_utils.isSubdomainOf(url, "artstation.com");
|
|
23
|
-
},
|
|
24
|
-
resolve: (url) => {
|
|
25
|
-
const parsed = new URL(url);
|
|
26
|
-
if (!require_utils.isHostOf(url, hosts) && require_utils.isSubdomainOf(url, "artstation.com")) return [{
|
|
27
|
-
uri: `https://www.artstation.com/${parsed.hostname.replace(domainSuffix, "")}.rss`,
|
|
28
|
-
hint: require_utils.composeHint("artstation:portfolio")
|
|
29
|
-
}];
|
|
30
|
-
const pathSegments = parsed.pathname.split("/").filter(Boolean);
|
|
31
|
-
if (pathSegments[0] === "artwork" || pathSegments.length === 0) {
|
|
32
|
-
const uris = [];
|
|
33
|
-
uris.push({
|
|
34
|
-
uri: "https://www.artstation.com/artwork.rss",
|
|
35
|
-
hint: require_utils.composeHint("artstation:artwork")
|
|
36
|
-
});
|
|
37
|
-
uris.push({
|
|
38
|
-
uri: "https://www.artstation.com/artwork.rss?sorting=trending",
|
|
39
|
-
hint: require_utils.composeHint("artstation:artwork-trending")
|
|
40
|
-
});
|
|
41
|
-
return uris;
|
|
42
|
-
}
|
|
43
|
-
const username = pathSegments[0];
|
|
44
|
-
if (require_utils.isAnyOf(username, excludedPaths)) return [];
|
|
45
|
-
return [{
|
|
46
|
-
uri: `https://www.artstation.com/${username}.rss`,
|
|
47
|
-
hint: require_utils.composeHint("artstation:portfolio")
|
|
48
|
-
}];
|
|
49
|
-
}
|
|
50
|
-
};
|
|
51
|
-
//#endregion
|
|
52
|
-
exports.artstationHandler = artstationHandler;
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/audioboom.ts
|
|
3
|
-
const hosts = ["audioboom.com", "www.audioboom.com"];
|
|
4
|
-
const channelRegex = /^\/channels\/(\d+)/;
|
|
5
|
-
const audioboomHandler = {
|
|
6
|
-
match: (url) => {
|
|
7
|
-
return require_utils.isHostOf(url, hosts);
|
|
8
|
-
},
|
|
9
|
-
resolve: (url) => {
|
|
10
|
-
const { pathname } = new URL(url);
|
|
11
|
-
const match = pathname.match(channelRegex);
|
|
12
|
-
if (!match?.[1]) return [];
|
|
13
|
-
const channelId = match[1];
|
|
14
|
-
const uris = [];
|
|
15
|
-
uris.push({
|
|
16
|
-
uri: `https://audioboom.com/channels/${channelId}.rss`,
|
|
17
|
-
hint: require_utils.composeHint("audioboom:podcast")
|
|
18
|
-
});
|
|
19
|
-
return uris;
|
|
20
|
-
}
|
|
21
|
-
};
|
|
22
|
-
//#endregion
|
|
23
|
-
exports.audioboomHandler = audioboomHandler;
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/bearblog.ts
|
|
3
|
-
const apexHosts = ["bearblog.dev", "www.bearblog.dev"];
|
|
4
|
-
const bearblogHandler = {
|
|
5
|
-
match: (url) => {
|
|
6
|
-
return require_utils.isSubdomainOf(url, "bearblog.dev") || require_utils.isHostOf(url, apexHosts);
|
|
7
|
-
},
|
|
8
|
-
resolve: (url) => {
|
|
9
|
-
const { origin, searchParams } = new URL(url);
|
|
10
|
-
const uris = [];
|
|
11
|
-
if (require_utils.isHostOf(url, apexHosts)) {
|
|
12
|
-
uris.push({
|
|
13
|
-
uri: "https://bearblog.dev/discover/feed/",
|
|
14
|
-
hint: require_utils.composeHint("bearblog:discover-atom")
|
|
15
|
-
});
|
|
16
|
-
uris.push({
|
|
17
|
-
uri: "https://bearblog.dev/discover/feed/?type=rss",
|
|
18
|
-
hint: require_utils.composeHint("bearblog:discover-rss")
|
|
19
|
-
});
|
|
20
|
-
return uris;
|
|
21
|
-
}
|
|
22
|
-
const tag = searchParams.get("q");
|
|
23
|
-
if (tag) {
|
|
24
|
-
uris.push({
|
|
25
|
-
uri: `${origin}/feed/?q=${encodeURIComponent(tag)}`,
|
|
26
|
-
hint: require_utils.composeHint("bearblog:tag-atom")
|
|
27
|
-
});
|
|
28
|
-
uris.push({
|
|
29
|
-
uri: `${origin}/feed/?type=rss&q=${encodeURIComponent(tag)}`,
|
|
30
|
-
hint: require_utils.composeHint("bearblog:tag-rss")
|
|
31
|
-
});
|
|
32
|
-
}
|
|
33
|
-
uris.push({
|
|
34
|
-
uri: `${origin}/feed/`,
|
|
35
|
-
hint: require_utils.composeHint("bearblog:posts-atom")
|
|
36
|
-
});
|
|
37
|
-
uris.push({
|
|
38
|
-
uri: `${origin}/feed/?type=rss`,
|
|
39
|
-
hint: require_utils.composeHint("bearblog:posts-rss")
|
|
40
|
-
});
|
|
41
|
-
return uris;
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
//#endregion
|
|
45
|
-
exports.bearblogHandler = bearblogHandler;
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/behance.ts
|
|
3
|
-
const hosts = ["behance.net", "www.behance.net"];
|
|
4
|
-
const userRegex = /^\/([a-zA-Z0-9_-]+)(?:\/(appreciated))?\/?$/;
|
|
5
|
-
const excludedPaths = [
|
|
6
|
-
"search",
|
|
7
|
-
"galleries",
|
|
8
|
-
"curated",
|
|
9
|
-
"features",
|
|
10
|
-
"live",
|
|
11
|
-
"joblist",
|
|
12
|
-
"hire",
|
|
13
|
-
"blog",
|
|
14
|
-
"about",
|
|
15
|
-
"privacy",
|
|
16
|
-
"tos",
|
|
17
|
-
"help",
|
|
18
|
-
"onboarding",
|
|
19
|
-
"settings",
|
|
20
|
-
"notifications",
|
|
21
|
-
"messages",
|
|
22
|
-
"adobe"
|
|
23
|
-
];
|
|
24
|
-
const behanceHandler = {
|
|
25
|
-
match: (url) => {
|
|
26
|
-
return require_utils.isHostOf(url, hosts);
|
|
27
|
-
},
|
|
28
|
-
resolve: (url) => {
|
|
29
|
-
const { pathname } = new URL(url);
|
|
30
|
-
if (pathname === "/" || pathname === "" || pathname === "/galleries") return [{
|
|
31
|
-
uri: "https://www.behance.net/feeds/projects",
|
|
32
|
-
hint: require_utils.composeHint("behance:projects")
|
|
33
|
-
}, {
|
|
34
|
-
uri: "https://feeds.feedburner.com/behance/vorr",
|
|
35
|
-
hint: require_utils.composeHint("behance:featured")
|
|
36
|
-
}];
|
|
37
|
-
const userMatch = pathname.match(userRegex);
|
|
38
|
-
if (userMatch?.[1]) {
|
|
39
|
-
const username = userMatch[1];
|
|
40
|
-
const subpage = userMatch[2];
|
|
41
|
-
if (!require_utils.isAnyOf(username, excludedPaths)) {
|
|
42
|
-
if (subpage === "appreciated") return [{
|
|
43
|
-
uri: `https://www.behance.net/feeds/user?username=${username}&content=appreciated`,
|
|
44
|
-
hint: require_utils.composeHint("behance:appreciated")
|
|
45
|
-
}];
|
|
46
|
-
return [{
|
|
47
|
-
uri: `https://www.behance.net/feeds/user?username=${username}`,
|
|
48
|
-
hint: require_utils.composeHint("behance:portfolio")
|
|
49
|
-
}];
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
return [];
|
|
53
|
-
}
|
|
54
|
-
};
|
|
55
|
-
//#endregion
|
|
56
|
-
exports.behanceHandler = behanceHandler;
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/blogspot.ts
|
|
3
|
-
const blogspotDomainRegex = /^.+\.blogspot\.(?:com|co\.[a-z]{2}|com\.[a-z]{2}|[a-z]{2,3})$/;
|
|
4
|
-
const labelRegex = /^\/search\/label\/([^/]+)/;
|
|
5
|
-
const postRegex = /^\/\d{4}\/\d{2}\/[^/]+\.html$/;
|
|
6
|
-
const postCommentsFeedRegex = /href="[^"]*\/feeds\/(\d+)\/comments\/default/;
|
|
7
|
-
const blogspotHandler = {
|
|
8
|
-
match: (url) => {
|
|
9
|
-
try {
|
|
10
|
-
const hostname = new URL(url).hostname.toLowerCase();
|
|
11
|
-
return blogspotDomainRegex.test(hostname);
|
|
12
|
-
} catch {}
|
|
13
|
-
return false;
|
|
14
|
-
},
|
|
15
|
-
resolve: (url, content) => {
|
|
16
|
-
const { origin, pathname } = new URL(url);
|
|
17
|
-
const uris = [];
|
|
18
|
-
const labelMatch = pathname.match(labelRegex);
|
|
19
|
-
if (labelMatch?.[1]) {
|
|
20
|
-
const label = labelMatch[1];
|
|
21
|
-
uris.push({
|
|
22
|
-
uri: `${origin}/feeds/posts/default/-/${label}`,
|
|
23
|
-
hint: require_utils.composeHint("blogspot:label-atom")
|
|
24
|
-
});
|
|
25
|
-
uris.push({
|
|
26
|
-
uri: `${origin}/feeds/posts/default/-/${label}?alt=rss`,
|
|
27
|
-
hint: require_utils.composeHint("blogspot:label-rss")
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
if (content && postRegex.test(pathname)) {
|
|
31
|
-
const postIdMatch = content.match(postCommentsFeedRegex);
|
|
32
|
-
if (postIdMatch?.[1]) {
|
|
33
|
-
const postId = postIdMatch[1];
|
|
34
|
-
uris.push({
|
|
35
|
-
uri: `${origin}/feeds/${postId}/comments/default`,
|
|
36
|
-
hint: require_utils.composeHint("blogspot:post-comments-atom")
|
|
37
|
-
});
|
|
38
|
-
uris.push({
|
|
39
|
-
uri: `${origin}/feeds/${postId}/comments/default?alt=rss`,
|
|
40
|
-
hint: require_utils.composeHint("blogspot:post-comments-rss")
|
|
41
|
-
});
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
uris.push({
|
|
45
|
-
uri: `${origin}/feeds/posts/default`,
|
|
46
|
-
hint: require_utils.composeHint("blogspot:posts-atom")
|
|
47
|
-
});
|
|
48
|
-
uris.push({
|
|
49
|
-
uri: `${origin}/feeds/posts/default?alt=rss`,
|
|
50
|
-
hint: require_utils.composeHint("blogspot:posts-rss")
|
|
51
|
-
});
|
|
52
|
-
uris.push({
|
|
53
|
-
uri: `${origin}/feeds/posts/summary`,
|
|
54
|
-
hint: require_utils.composeHint("blogspot:posts-summary-atom")
|
|
55
|
-
});
|
|
56
|
-
uris.push({
|
|
57
|
-
uri: `${origin}/feeds/posts/summary?alt=rss`,
|
|
58
|
-
hint: require_utils.composeHint("blogspot:posts-summary-rss")
|
|
59
|
-
});
|
|
60
|
-
uris.push({
|
|
61
|
-
uri: `${origin}/feeds/comments/default`,
|
|
62
|
-
hint: require_utils.composeHint("blogspot:comments-atom")
|
|
63
|
-
});
|
|
64
|
-
uris.push({
|
|
65
|
-
uri: `${origin}/feeds/comments/default?alt=rss`,
|
|
66
|
-
hint: require_utils.composeHint("blogspot:comments-rss")
|
|
67
|
-
});
|
|
68
|
-
return uris;
|
|
69
|
-
}
|
|
70
|
-
};
|
|
71
|
-
//#endregion
|
|
72
|
-
exports.blogspotHandler = blogspotHandler;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/bluesky.ts
|
|
3
|
-
const profileRegex = /^\/profile\/([^/]+)/;
|
|
4
|
-
const hosts = ["bsky.app", "www.bsky.app"];
|
|
5
|
-
const blueskyHandler = {
|
|
6
|
-
match: (url) => {
|
|
7
|
-
return require_utils.isHostOf(url, hosts);
|
|
8
|
-
},
|
|
9
|
-
resolve: (url) => {
|
|
10
|
-
const { pathname } = new URL(url);
|
|
11
|
-
const handle = pathname.match(profileRegex)?.[1];
|
|
12
|
-
if (!handle) return [];
|
|
13
|
-
return [{
|
|
14
|
-
uri: `https://bsky.app/profile/${handle}/rss`,
|
|
15
|
-
hint: require_utils.composeHint("bluesky:posts")
|
|
16
|
-
}];
|
|
17
|
-
}
|
|
18
|
-
};
|
|
19
|
-
//#endregion
|
|
20
|
-
exports.blueskyHandler = blueskyHandler;
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/bookwyrm.ts
|
|
3
|
-
const profileRegex = /^\/user\/([^/]+)/;
|
|
4
|
-
const shelfRegex = /^\/user\/([^/]+)\/(?:shelf|books)\/([^/]+)\/?/;
|
|
5
|
-
const isBookwyrmHtml = (content) => {
|
|
6
|
-
return require_utils.hasMetaContent(content, "generator", "BookWyrm");
|
|
7
|
-
};
|
|
8
|
-
const bookwyrmHandler = {
|
|
9
|
-
match: (url, content) => {
|
|
10
|
-
try {
|
|
11
|
-
if (!content || !isBookwyrmHtml(content)) return false;
|
|
12
|
-
const { pathname } = new URL(url);
|
|
13
|
-
return profileRegex.test(pathname);
|
|
14
|
-
} catch {}
|
|
15
|
-
return false;
|
|
16
|
-
},
|
|
17
|
-
resolve: (url) => {
|
|
18
|
-
try {
|
|
19
|
-
const { origin, pathname } = new URL(url);
|
|
20
|
-
const match = pathname.match(profileRegex);
|
|
21
|
-
if (!match?.[1]) return [];
|
|
22
|
-
const user = match[1];
|
|
23
|
-
const uris = [];
|
|
24
|
-
const shelfMatch = pathname.match(shelfRegex);
|
|
25
|
-
if (shelfMatch?.[2]) uris.push({
|
|
26
|
-
uri: `${origin}/user/${user}/${pathname.split("/")[3]}/${shelfMatch[2]}/rss`,
|
|
27
|
-
hint: require_utils.composeHint("bookwyrm:shelf")
|
|
28
|
-
});
|
|
29
|
-
uris.push({
|
|
30
|
-
uri: `${origin}/user/${user}/rss`,
|
|
31
|
-
hint: require_utils.composeHint("bookwyrm:activity")
|
|
32
|
-
}, {
|
|
33
|
-
uri: `${origin}/user/${user}/rss-reviews`,
|
|
34
|
-
hint: require_utils.composeHint("bookwyrm:reviews")
|
|
35
|
-
}, {
|
|
36
|
-
uri: `${origin}/user/${user}/rss-quotes`,
|
|
37
|
-
hint: require_utils.composeHint("bookwyrm:quotes")
|
|
38
|
-
}, {
|
|
39
|
-
uri: `${origin}/user/${user}/rss-comments`,
|
|
40
|
-
hint: require_utils.composeHint("bookwyrm:comments")
|
|
41
|
-
});
|
|
42
|
-
return uris;
|
|
43
|
-
} catch {}
|
|
44
|
-
return [];
|
|
45
|
-
}
|
|
46
|
-
};
|
|
47
|
-
//#endregion
|
|
48
|
-
exports.bookwyrmHandler = bookwyrmHandler;
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/buttondown.ts
|
|
3
|
-
const hosts = [
|
|
4
|
-
"buttondown.com",
|
|
5
|
-
"www.buttondown.com",
|
|
6
|
-
"buttondown.email",
|
|
7
|
-
"www.buttondown.email"
|
|
8
|
-
];
|
|
9
|
-
const excludedPaths = [
|
|
10
|
-
"about",
|
|
11
|
-
"api",
|
|
12
|
-
"blog",
|
|
13
|
-
"changelog",
|
|
14
|
-
"docs",
|
|
15
|
-
"features",
|
|
16
|
-
"help",
|
|
17
|
-
"legal",
|
|
18
|
-
"login",
|
|
19
|
-
"pricing",
|
|
20
|
-
"privacy",
|
|
21
|
-
"refer",
|
|
22
|
-
"register",
|
|
23
|
-
"settings",
|
|
24
|
-
"terms"
|
|
25
|
-
];
|
|
26
|
-
const buttondownHandler = {
|
|
27
|
-
match: (url) => {
|
|
28
|
-
return require_utils.isHostOf(url, hosts);
|
|
29
|
-
},
|
|
30
|
-
resolve: (url) => {
|
|
31
|
-
const { pathname } = new URL(url);
|
|
32
|
-
const pathSegments = pathname.split("/").filter(Boolean);
|
|
33
|
-
if (pathSegments.length === 0) return [];
|
|
34
|
-
const username = pathSegments[0];
|
|
35
|
-
if (require_utils.isAnyOf(username, excludedPaths)) return [];
|
|
36
|
-
return [{
|
|
37
|
-
uri: `https://buttondown.com/${username}/rss`,
|
|
38
|
-
hint: require_utils.composeHint("buttondown:newsletter")
|
|
39
|
-
}];
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
//#endregion
|
|
43
|
-
exports.buttondownHandler = buttondownHandler;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/buzzsprout.ts
|
|
3
|
-
const hosts = ["buzzsprout.com", "www.buzzsprout.com"];
|
|
4
|
-
const numericRegex = /^\d+$/;
|
|
5
|
-
const buzzsproutHandler = {
|
|
6
|
-
match: (url) => {
|
|
7
|
-
return require_utils.isHostOf(url, hosts);
|
|
8
|
-
},
|
|
9
|
-
resolve: (url) => {
|
|
10
|
-
const { pathname } = new URL(url);
|
|
11
|
-
const pathSegments = pathname.split("/").filter(Boolean);
|
|
12
|
-
if (pathSegments.length === 0) return [];
|
|
13
|
-
const podcastId = pathSegments[0];
|
|
14
|
-
if (!numericRegex.test(podcastId)) return [];
|
|
15
|
-
return [{
|
|
16
|
-
uri: `https://rss.buzzsprout.com/${podcastId}.rss`,
|
|
17
|
-
hint: require_utils.composeHint("buzzsprout:podcast")
|
|
18
|
-
}];
|
|
19
|
-
}
|
|
20
|
-
};
|
|
21
|
-
//#endregion
|
|
22
|
-
exports.buzzsproutHandler = buzzsproutHandler;
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/codeberg.ts
|
|
3
|
-
const hosts = [
|
|
4
|
-
"codeberg.org",
|
|
5
|
-
"www.codeberg.org",
|
|
6
|
-
"gitea.com",
|
|
7
|
-
"www.gitea.com"
|
|
8
|
-
];
|
|
9
|
-
const excludedPaths = [
|
|
10
|
-
"explore",
|
|
11
|
-
"admin",
|
|
12
|
-
"user",
|
|
13
|
-
"assets",
|
|
14
|
-
"api",
|
|
15
|
-
"swagger.json",
|
|
16
|
-
"robots.txt",
|
|
17
|
-
"sitemap.xml",
|
|
18
|
-
"-"
|
|
19
|
-
];
|
|
20
|
-
const codebergHandler = {
|
|
21
|
-
match: (url) => {
|
|
22
|
-
return require_utils.isHostOf(url, hosts);
|
|
23
|
-
},
|
|
24
|
-
resolve: (url) => {
|
|
25
|
-
const { origin, pathname } = new URL(url);
|
|
26
|
-
const pathSegments = pathname.split("/").filter(Boolean);
|
|
27
|
-
if (pathSegments.length === 1) {
|
|
28
|
-
const user = pathSegments[0];
|
|
29
|
-
if (!require_utils.isAnyOf(user, excludedPaths)) return [{
|
|
30
|
-
uri: [`${origin}/${user}.atom`, `${origin}/${user}.rss`],
|
|
31
|
-
hint: require_utils.composeHint("codeberg:activity")
|
|
32
|
-
}];
|
|
33
|
-
}
|
|
34
|
-
if (pathSegments.length >= 2) {
|
|
35
|
-
const user = pathSegments[0];
|
|
36
|
-
const repo = pathSegments[1];
|
|
37
|
-
if (!require_utils.isAnyOf(user, excludedPaths)) {
|
|
38
|
-
const feeds = [
|
|
39
|
-
{
|
|
40
|
-
uri: [`${origin}/${user}/${repo}/releases.atom`, `${origin}/${user}/${repo}/releases.rss`],
|
|
41
|
-
hint: require_utils.composeHint("codeberg:releases")
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
uri: [`${origin}/${user}/${repo}/tags.atom`, `${origin}/${user}/${repo}/tags.rss`],
|
|
45
|
-
hint: require_utils.composeHint("codeberg:tags")
|
|
46
|
-
},
|
|
47
|
-
{
|
|
48
|
-
uri: [`${origin}/${user}/${repo}.atom`, `${origin}/${user}/${repo}.rss`],
|
|
49
|
-
hint: require_utils.composeHint("codeberg:activity")
|
|
50
|
-
}
|
|
51
|
-
];
|
|
52
|
-
if (require_utils.isHostOf(url, ["gitea.com", "www.gitea.com"]) && pathSegments[2] === "src" && pathSegments[3] === "branch" && pathSegments[4]) {
|
|
53
|
-
const branch = pathSegments[4];
|
|
54
|
-
const filePath = pathSegments.slice(5).join("/");
|
|
55
|
-
feeds.unshift({
|
|
56
|
-
uri: `${origin}/${user}/${repo}/rss/branch/${branch}${filePath ? `/${filePath}` : ""}`,
|
|
57
|
-
hint: require_utils.composeHint(filePath ? "codeberg:file-history" : "codeberg:branch-commits")
|
|
58
|
-
});
|
|
59
|
-
}
|
|
60
|
-
return feeds;
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
return [];
|
|
64
|
-
}
|
|
65
|
-
};
|
|
66
|
-
//#endregion
|
|
67
|
-
exports.codebergHandler = codebergHandler;
|
|
68
|
-
exports.excludedPaths = excludedPaths;
|
|
69
|
-
exports.hosts = hosts;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/csdn.ts
|
|
3
|
-
const userRegex = /^\/([^/]+)/;
|
|
4
|
-
const hosts = ["blog.csdn.net"];
|
|
5
|
-
const csdnHandler = {
|
|
6
|
-
match: (url) => {
|
|
7
|
-
return require_utils.isHostOf(url, hosts);
|
|
8
|
-
},
|
|
9
|
-
resolve: (url) => {
|
|
10
|
-
const { pathname } = new URL(url);
|
|
11
|
-
const username = pathname.match(userRegex)?.[1];
|
|
12
|
-
if (!username) return [];
|
|
13
|
-
return [{
|
|
14
|
-
uri: [`https://rss.csdn.net/${username}/rss/map`, `https://blog.csdn.net/${username}/rss/list`],
|
|
15
|
-
hint: require_utils.composeHint("csdn:blog")
|
|
16
|
-
}];
|
|
17
|
-
}
|
|
18
|
-
};
|
|
19
|
-
//#endregion
|
|
20
|
-
exports.csdnHandler = csdnHandler;
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/dailymotion.ts
|
|
3
|
-
const hosts = ["dailymotion.com", "www.dailymotion.com"];
|
|
4
|
-
const userRegex = /^\/([a-zA-Z0-9_-]+)$/;
|
|
5
|
-
const playlistRegex = /^\/playlist\/([a-zA-Z0-9_-]+)/;
|
|
6
|
-
const channelRegex = /^\/channel\/([a-zA-Z0-9_-]+)/;
|
|
7
|
-
const searchRegex = /^\/search\/([^/]+)/;
|
|
8
|
-
const excludedPaths = [
|
|
9
|
-
"signin",
|
|
10
|
-
"signout",
|
|
11
|
-
"signup",
|
|
12
|
-
"login",
|
|
13
|
-
"logout",
|
|
14
|
-
"register",
|
|
15
|
-
"search",
|
|
16
|
-
"legal",
|
|
17
|
-
"about",
|
|
18
|
-
"careers",
|
|
19
|
-
"terms",
|
|
20
|
-
"privacy",
|
|
21
|
-
"feedback",
|
|
22
|
-
"help",
|
|
23
|
-
"settings",
|
|
24
|
-
"upload",
|
|
25
|
-
"partner",
|
|
26
|
-
"monetize",
|
|
27
|
-
"studio",
|
|
28
|
-
"video",
|
|
29
|
-
"live",
|
|
30
|
-
"channels",
|
|
31
|
-
"playlist",
|
|
32
|
-
"topics",
|
|
33
|
-
"trending",
|
|
34
|
-
"dm",
|
|
35
|
-
"creator",
|
|
36
|
-
"premium",
|
|
37
|
-
"explore",
|
|
38
|
-
"following",
|
|
39
|
-
"subscriptions",
|
|
40
|
-
"notifications",
|
|
41
|
-
"history",
|
|
42
|
-
"watch",
|
|
43
|
-
"contact",
|
|
44
|
-
"ads",
|
|
45
|
-
"dmca",
|
|
46
|
-
"copyright",
|
|
47
|
-
"community"
|
|
48
|
-
];
|
|
49
|
-
const dailymotionHandler = {
|
|
50
|
-
match: (url) => {
|
|
51
|
-
return require_utils.isHostOf(url, hosts);
|
|
52
|
-
},
|
|
53
|
-
resolve: (url) => {
|
|
54
|
-
const { pathname } = new URL(url);
|
|
55
|
-
if (pathname === "/" || pathname === "" || pathname === "/trending") return [{
|
|
56
|
-
uri: "https://www.dailymotion.com/rss/trending",
|
|
57
|
-
hint: require_utils.composeHint("dailymotion:trending")
|
|
58
|
-
}];
|
|
59
|
-
const playlistMatch = pathname.match(playlistRegex);
|
|
60
|
-
if (playlistMatch?.[1]) return [{
|
|
61
|
-
uri: `https://www.dailymotion.com/rss/playlist/${playlistMatch[1]}`,
|
|
62
|
-
hint: require_utils.composeHint("dailymotion:playlist")
|
|
63
|
-
}];
|
|
64
|
-
const searchMatch = pathname.match(searchRegex);
|
|
65
|
-
if (searchMatch?.[1]) return [{
|
|
66
|
-
uri: `https://www.dailymotion.com/rss/search/${searchMatch[1]}`,
|
|
67
|
-
hint: require_utils.composeHint("dailymotion:search")
|
|
68
|
-
}];
|
|
69
|
-
const channelMatch = pathname.match(channelRegex);
|
|
70
|
-
if (channelMatch?.[1]) return [{
|
|
71
|
-
uri: `https://www.dailymotion.com/rss/channel/${channelMatch[1]}`,
|
|
72
|
-
hint: require_utils.composeHint("dailymotion:channel")
|
|
73
|
-
}];
|
|
74
|
-
const userMatch = pathname.match(userRegex);
|
|
75
|
-
if (userMatch?.[1]) {
|
|
76
|
-
const username = userMatch[1];
|
|
77
|
-
if (!require_utils.isAnyOf(username, excludedPaths)) return [{
|
|
78
|
-
uri: `https://www.dailymotion.com/rss/${username}`,
|
|
79
|
-
hint: require_utils.composeHint("dailymotion:videos")
|
|
80
|
-
}];
|
|
81
|
-
}
|
|
82
|
-
return [];
|
|
83
|
-
}
|
|
84
|
-
};
|
|
85
|
-
//#endregion
|
|
86
|
-
exports.dailymotionHandler = dailymotionHandler;
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
const require_utils = require("../../../common/utils.cjs");
|
|
2
|
-
//#region src/feeds/platform/handlers/deviantart.ts
|
|
3
|
-
const tagRegex = /^\/tag\/([^/]+)/;
|
|
4
|
-
const favouritesRegex = /^\/([a-zA-Z0-9_-]+)\/favourites\/?$/;
|
|
5
|
-
const folderRegex = /^\/([a-zA-Z0-9_-]+)\/gallery\/(\d+)(?:\/|$)/;
|
|
6
|
-
const journalRegex = /^\/([a-zA-Z0-9_-]+)\/journal(?:\/|$)/;
|
|
7
|
-
const profileRegex = /^\/([a-zA-Z0-9_-]+)(?:\/gallery(?:\/all)?)?(?:\/|$)/;
|
|
8
|
-
const hosts = ["deviantart.com", "www.deviantart.com"];
|
|
9
|
-
const feedBaseUrl = "https://backend.deviantart.com/rss.xml";
|
|
10
|
-
const excludedPaths = [
|
|
11
|
-
"about",
|
|
12
|
-
"core-membership",
|
|
13
|
-
"daily-deviations",
|
|
14
|
-
"developers",
|
|
15
|
-
"join",
|
|
16
|
-
"notifications",
|
|
17
|
-
"popular",
|
|
18
|
-
"search",
|
|
19
|
-
"settings",
|
|
20
|
-
"shop",
|
|
21
|
-
"submit",
|
|
22
|
-
"team",
|
|
23
|
-
"topic",
|
|
24
|
-
"watch"
|
|
25
|
-
];
|
|
26
|
-
const deviantartHandler = {
|
|
27
|
-
match: (url) => {
|
|
28
|
-
return require_utils.isHostOf(url, hosts);
|
|
29
|
-
},
|
|
30
|
-
resolve: (url) => {
|
|
31
|
-
const { pathname } = new URL(url);
|
|
32
|
-
if (pathname === "/daily-deviations" || pathname === "/daily-deviations/") return [{
|
|
33
|
-
uri: `${feedBaseUrl}?q=${encodeURIComponent("special:dd")}`,
|
|
34
|
-
hint: require_utils.composeHint("deviantart:daily-deviations")
|
|
35
|
-
}];
|
|
36
|
-
if (pathname === "/popular" || pathname === "/popular/") return [{
|
|
37
|
-
uri: `${feedBaseUrl}?type=deviation&q=${encodeURIComponent("boost:popular")}`,
|
|
38
|
-
hint: require_utils.composeHint("deviantart:popular")
|
|
39
|
-
}];
|
|
40
|
-
const tagMatch = pathname.match(tagRegex);
|
|
41
|
-
if (tagMatch?.[1]) {
|
|
42
|
-
const tag = tagMatch[1];
|
|
43
|
-
return [{
|
|
44
|
-
uri: `${feedBaseUrl}?type=deviation&q=${encodeURIComponent(`tag:${tag}`)}`,
|
|
45
|
-
hint: require_utils.composeHint("deviantart:tag")
|
|
46
|
-
}];
|
|
47
|
-
}
|
|
48
|
-
const favMatch = pathname.match(favouritesRegex);
|
|
49
|
-
if (favMatch?.[1]) {
|
|
50
|
-
const username = favMatch[1];
|
|
51
|
-
if (!require_utils.isAnyOf(username, excludedPaths)) return [{
|
|
52
|
-
uri: `${feedBaseUrl}?type=deviation&q=${encodeURIComponent(`favby:${username}`)}`,
|
|
53
|
-
hint: require_utils.composeHint("deviantart:favorites")
|
|
54
|
-
}];
|
|
55
|
-
}
|
|
56
|
-
const folderMatch = pathname.match(folderRegex);
|
|
57
|
-
if (folderMatch?.[1] && folderMatch?.[2]) {
|
|
58
|
-
const username = folderMatch[1];
|
|
59
|
-
const folderId = folderMatch[2];
|
|
60
|
-
if (!require_utils.isAnyOf(username, excludedPaths)) return [{
|
|
61
|
-
uri: `${feedBaseUrl}?type=deviation&q=${encodeURIComponent(`gallery:${username}/${folderId}`)}`,
|
|
62
|
-
hint: require_utils.composeHint("deviantart:gallery")
|
|
63
|
-
}];
|
|
64
|
-
}
|
|
65
|
-
const journalMatch = pathname.match(journalRegex);
|
|
66
|
-
if (journalMatch?.[1]) {
|
|
67
|
-
const username = journalMatch[1];
|
|
68
|
-
if (!require_utils.isAnyOf(username, excludedPaths)) return [{
|
|
69
|
-
uri: `${feedBaseUrl}?q=${encodeURIComponent(`journal:${username}`)}`,
|
|
70
|
-
hint: require_utils.composeHint("deviantart:journal")
|
|
71
|
-
}];
|
|
72
|
-
}
|
|
73
|
-
const username = pathname.match(profileRegex)?.[1];
|
|
74
|
-
if (!username || require_utils.isAnyOf(username, excludedPaths)) return [];
|
|
75
|
-
const query = `by:${username} sort:time meta:all`;
|
|
76
|
-
return [{
|
|
77
|
-
uri: `${feedBaseUrl}?type=deviation&q=${encodeURIComponent(query)}`,
|
|
78
|
-
hint: require_utils.composeHint("deviantart:deviations")
|
|
79
|
-
}];
|
|
80
|
-
}
|
|
81
|
-
};
|
|
82
|
-
//#endregion
|
|
83
|
-
exports.deviantartHandler = deviantartHandler;
|
|
84
|
-
exports.excludedPaths = excludedPaths;
|
|
85
|
-
exports.hosts = hosts;
|