Skip to content

Commit

Permalink
chore: auto build DIYgod/RSSHub@e8b0d7d
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Mar 24, 2024
1 parent 6cc37dd commit 2e037bf
Show file tree
Hide file tree
Showing 2 changed files with 185 additions and 96 deletions.
188 changes: 94 additions & 94 deletions .vitepress/config/data.ts
Original file line number Diff line number Diff line change
@@ -1,140 +1,140 @@
export const categories = [
{
"icon": "💬",
"link": "/routes/social-media",
"en": "Social Media",
"zh": "社交媒体"
icon: '💬',
link: '/routes/social-media',
en: 'Social Media',
zh: '社交媒体',
},
{
"icon": "📱",
"link": "/routes/new-media",
"en": "New media",
"zh": "新媒体"
icon: '📱',
link: '/routes/new-media',
en: 'New media',
zh: '新媒体',
},
{
"icon": "📰",
"link": "/routes/traditional-media",
"en": "Traditional media",
"zh": "传统媒体"
icon: '📰',
link: '/routes/traditional-media',
en: 'Traditional media',
zh: '传统媒体',
},
{
"icon": "💬️",
"link": "/routes/bbs",
"en": "BBS",
"zh": "论坛"
icon: '💬️',
link: '/routes/bbs',
en: 'BBS',
zh: '论坛',
},
{
"icon": "🖊️️",
"link": "/routes/blog",
"en": "Blog",
"zh": "博客"
icon: '🖊️️',
link: '/routes/blog',
en: 'Blog',
zh: '博客',
},
{
"icon": "💻",
"link": "/routes/programming",
"en": "Programming",
"zh": "编程"
icon: '💻',
link: '/routes/programming',
en: 'Programming',
zh: '编程',
},
{
"icon": "🎨️",
"link": "/routes/design",
"en": "Design",
"zh": "设计"
icon: '🎨️',
link: '/routes/design',
en: 'Design',
zh: '设计',
},
{
"icon": "🎥",
"link": "/routes/live",
"en": "Live",
"zh": "直播"
icon: '🎥',
link: '/routes/live',
en: 'Live',
zh: '直播',
},
{
"icon": "🔊",
"link": "/routes/multimedia",
"en": "Multimedia",
"zh": "音视频"
icon: '🔊',
link: '/routes/multimedia',
en: 'Multimedia',
zh: '音视频',
},
{
"icon": "🖼️",
"link": "/routes/picture",
"en": "Picture",
"zh": "图片"
icon: '🖼️',
link: '/routes/picture',
en: 'Picture',
zh: '图片',
},
{
"icon": "🎨️",
"link": "/routes/anime",
"en": "ACG",
"zh": "二次元"
icon: '🎨️',
link: '/routes/anime',
en: 'ACG',
zh: '二次元',
},
{
"icon": "🔄",
"link": "/routes/program-update",
"en": "Application Updates",
"zh": "程序更新"
icon: '🔄',
link: '/routes/program-update',
en: 'Application Updates',
zh: '程序更新',
},
{
"icon": "🎓",
"link": "/routes/university",
"en": "University",
"zh": "大学通知"
icon: '🎓',
link: '/routes/university',
en: 'University',
zh: '大学通知',
},
{
"icon": "❗️",
"link": "/routes/forecast",
"en": "Forecast and Alerts",
"zh": "预报预警"
icon: '❗️',
link: '/routes/forecast',
en: 'Forecast and Alerts',
zh: '预报预警',
},
{
"icon": "🛫",
"link": "/routes/travel",
"en": "Travel",
"zh": "出行旅游"
icon: '🛫',
link: '/routes/travel',
en: 'Travel',
zh: '出行旅游',
},
{
"icon": "🛍️",
"link": "/routes/shopping",
"en": "Shopping",
"zh": "购物"
icon: '🛍️',
link: '/routes/shopping',
en: 'Shopping',
zh: '购物',
},
{
"icon": "🎮",
"link": "/routes/game",
"en": "Gaming",
"zh": "游戏"
icon: '🎮',
link: '/routes/game',
en: 'Gaming',
zh: '游戏',
},
{
"icon": "📚",
"link": "/routes/reading",
"en": "Reading",
"zh": "阅读"
icon: '📚',
link: '/routes/reading',
en: 'Reading',
zh: '阅读',
},
{
"icon": "📢",
"link": "/routes/government",
"en": "Government",
"zh": "政务消息"
icon: '📢',
link: '/routes/government',
en: 'Government',
zh: '政务消息',
},
{
"icon": "📖",
"link": "/routes/study",
"en": "Study",
"zh": "学习"
icon: '📖',
link: '/routes/study',
en: 'Study',
zh: '学习',
},
{
"icon": "🔬",
"link": "/routes/journal",
"en": "Scientific Journal",
"zh": "科学期刊"
icon: '🔬',
link: '/routes/journal',
en: 'Scientific Journal',
zh: '科学期刊',
},
{
"icon": "💰",
"link": "/routes/finance",
"en": "Finance",
"zh": "金融"
icon: '💰',
link: '/routes/finance',
en: 'Finance',
zh: '金融',
},
{
"icon": "🔍",
"link": "/routes/other",
"en": "Uncategorized",
"zh": "其他"
}
]
icon: '🔍',
link: '/routes/other',
en: 'Uncategorized',
zh: '其他',
},
];
93 changes: 91 additions & 2 deletions .vitepress/theme/types.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,87 @@
import type { Context } from 'hono';

// Make sure it's synchronise with scripts/workflow/data.ts
type Category =
| 'social-media'
| 'new-media'
| 'traditional-media'
| 'bbs'
| 'blog'
| 'programming'
| 'design'
| 'live'
| 'multimedia'
| 'picture'
| 'anime'
| 'program-update'
| 'university'
| 'forecast'
| 'travel'
| 'shopping'
| 'game'
| 'reading'
| 'government'
| 'study'
| 'journal'
| 'finance'
| 'other';

// rss
export type DataItem = {
title: string;
description?: string;
pubDate?: number | string | Date;
link?: string;
category?: string[];
author?: string | { name: string }[];
doi?: string;
guid?: string;
id?: string;
content?: {
html: string;
text: string;
};
image?: string;
banner?: string;
updated?: number | string | Date;
language?: string;
enclosure_url?: string;
enclosure_type?: string;
enclosure_title?: string;
enclosure_length?: number;
itunes_duration?: number | string;
itunes_item_image?: string;
media?: Record<string, Record<string, string>>;

_extra?: Record<string, any> & {
links?: {
url: string;
type: string;
content_html?: string;
}[];
};
};

export type Data = {
title: string;
description?: string;
link?: string;
item?: DataItem[];
allowEmpty?: boolean;
image?: string;
author?: string;
language?: string;
feedLink?: string;
lastBuildDate?: string;
itunes_author?: string;
itunes_category?: string;
itunes_explicit?: string | boolean;
id?: string;

atomlink?: string;
ttl?: number;
};

// namespace
interface NamespaceItem {
/**
Expand All @@ -14,7 +98,7 @@ interface NamespaceItem {
/**
* The classification of the namespace, which will be written into the corresponding classification document
*/
categories?: string[];
categories?: Category[];

/**
* Hints and additional explanations for users using this namespace, it will be inserted into the documentation
Expand Down Expand Up @@ -56,6 +140,11 @@ interface RouteItem {
*/
maintainers: string[];

/**
* The handler function of the route
*/
handler: (ctx: Context) => Promise<Data> | Data;

/**
* An example URL of the route
*/
Expand All @@ -74,7 +163,7 @@ interface RouteItem {
/**
* The classification of the route, which will be written into the corresponding classification documentation
*/
categories?: string[];
categories?: Category[];

/**
* Special features of the route, such as what configuration items it depends on, whether it is strict anti-crawl, whether it supports a certain function and so on
Expand Down

0 comments on commit 2e037bf

Please sign in to comment.