diff --git a/docs/anime.md b/docs/anime.md
index 1f52d8e59..33d7f8782 100644
--- a/docs/anime.md
+++ b/docs/anime.md
@@ -652,3 +652,9 @@ Sources
### 最新汉化
+
+## アニメ新番組
+
+### 當季新番
+
+
diff --git a/lib/v2/bangumi/maintainer.js b/lib/v2/bangumi/maintainer.js
index b4a30df31..52659f4b7 100644
--- a/lib/v2/bangumi/maintainer.js
+++ b/lib/v2/bangumi/maintainer.js
@@ -1,4 +1,5 @@
module.exports = {
+ '/online': ['devinmugen'],
'/': ['nczitzk'],
'/:tags?': ['nczitzk'],
};
diff --git a/lib/v2/bangumi/online.js b/lib/v2/bangumi/online.js
new file mode 100644
index 000000000..658e2b603
--- /dev/null
+++ b/lib/v2/bangumi/online.js
@@ -0,0 +1,26 @@
+const got = require('@/utils/got');
+const { art } = require('@/utils/render');
+const path = require('path');
+
+module.exports = async (ctx) => {
+ const url = 'https://bangumi.online/api/home';
+
+ const response = await got.post(url);
+
+ const list = response.data.data.list;
+
+ const items = list.map((item) => ({
+ title: `${item.title_zh} - 第 ${item.volume} 集`,
+ description: art(path.join(__dirname, 'templates/image.art'), {
+ src: `https:${item.cover}`,
+ alt: `${item.title_zh} - 第 ${item.volume} 集`,
+ }),
+ link: `https://bangumi.online/watch/${item.vid}`,
+ }));
+
+ ctx.state.data = {
+ title: 'アニメ新番組',
+ link: 'https://bangumi.online',
+ item: items,
+ };
+};
diff --git a/lib/v2/bangumi/radar.js b/lib/v2/bangumi/radar.js
index 98c9fbc76..eea70864b 100644
--- a/lib/v2/bangumi/radar.js
+++ b/lib/v2/bangumi/radar.js
@@ -1,6 +1,6 @@
module.exports = {
- '萌番组 Bangumi Moe': {
- _name: 'bangumi.moe',
+ 'bangumi.moe': {
+ _name: '萌番組',
'.': [
{
title: '最新',
@@ -16,4 +16,15 @@ module.exports = {
},
],
},
+ 'bangumi.online': {
+ _name: 'アニメ新番組',
+ '.': [
+ {
+ title: '當季新番',
+ docs: 'https://docs.rsshub.app/anime.html#アニメ-xin-fan-zu-dang-ji-xin-fan',
+ source: ['/'],
+ target: '/bangumi/online',
+ },
+ ],
+ },
};
diff --git a/lib/v2/bangumi/router.js b/lib/v2/bangumi/router.js
index 406315685..5c90781a2 100644
--- a/lib/v2/bangumi/router.js
+++ b/lib/v2/bangumi/router.js
@@ -1,3 +1,4 @@
module.exports = function (router) {
+ router.get('/online', require('./online'));
router.get(/([\w-/]+)?/, require('./index'));
};
diff --git a/lib/v2/bangumi/templates/image.art b/lib/v2/bangumi/templates/image.art
new file mode 100644
index 000000000..40140a947
--- /dev/null
+++ b/lib/v2/bangumi/templates/image.art
@@ -0,0 +1 @@
+