chore: add more popular social media routes

This commit is contained in:
pseudoyu
2024-10-23 18:50:59 +08:00
parent 01c0e1c001
commit 686a21fc7a
4 changed files with 12 additions and 8 deletions
+3 -2
View File
@@ -1,4 +1,4 @@
import { Route } from '@/types';
import { Route, ViewType } from '@/types';
import cache from '@/utils/cache';
import querystring from 'querystring';
import got from '@/utils/got';
@@ -6,7 +6,8 @@ import { fallback, queryToBoolean, queryToInteger } from '@/utils/readable-socia
import { config } from '@/config';
export const route: Route = {
path: '/people/:userid/status/:routeParams?',
categories: ['social-media'],
categories: ['social-media', 'popular'],
view: ViewType.SocialMedia,
example: '/douban/people/75118396/status',
parameters: { userid: '整数型用户 id', routeParams: '额外参数;见下' },
name: '用户广播',
+3 -2
View File
@@ -1,4 +1,4 @@
import { Route } from '@/types';
import { Route, ViewType } from '@/types';
import cache from '@/utils/cache';
import got from '@/utils/got';
import { baseUrl, getPlurk } from './utils';
@@ -8,7 +8,8 @@ const categoryList = new Set(['topReplurks', 'topFavorites', 'topResponded']);
export const route: Route = {
path: '/top/:category?/:lang?',
categories: ['social-media'],
categories: ['social-media', 'popular'],
view: ViewType.SocialMedia,
example: '/plurk/top/topReplurks',
parameters: { category: 'Category, see the table below, `topReplurks` by default', lang: 'Language, see the table below, `en` by default' },
features: {
+3 -2
View File
@@ -1,4 +1,4 @@
import { Route } from '@/types';
import { Route, ViewType } from '@/types';
import cache from '@/utils/cache';
import got from '@/utils/got';
import { load } from 'cheerio';
@@ -6,7 +6,8 @@ import { baseUrl, fetchFriends, getPlurk } from './utils';
export const route: Route = {
path: '/topic/:topic',
categories: ['social-media'],
categories: ['social-media', 'popular'],
view: ViewType.SocialMedia,
example: '/plurk/topic/standwithukraine',
parameters: { topic: 'Topic ID, can be found in URL' },
features: {
+3 -2
View File
@@ -1,4 +1,4 @@
import { Route } from '@/types';
import { Route, ViewType } from '@/types';
import cache from '@/utils/cache';
import got from '@/utils/got';
import { load } from 'cheerio';
@@ -6,7 +6,8 @@ import { baseUrl, fetchFriends, getPlurk } from './utils';
export const route: Route = {
path: '/user/:user',
categories: ['social-media'],
categories: ['social-media', 'popular'],
view: ViewType.SocialMedia,
example: '/plurk/user/plurkoffice',
parameters: { user: 'User ID, can be found in URL' },
features: {