♻️ 帖子显示版块信息

This commit is contained in:
目棃
2024-07-27 21:08:15 +08:00
parent 942e63654e
commit b502cf4025
4 changed files with 98 additions and 58 deletions

View File

@@ -1,10 +1,17 @@
/**
* @file web/constant/TGConstant.ts
* @description 常量
* @since Beta v0.3.6
* @since Beta v0.5.1
*/
import { BBS_APP_ID, BBS_SALT, BBS_UA_MOBILE, BBS_UA_PC, BBS_VERSION } from "./bbs.js";
import {
BBS_APP_ID,
BBS_SALT,
BBS_UA_MOBILE,
BBS_UA_PC,
BBS_VERSION,
CHANNEL_LIST,
} from "./bbs.js";
import SERVER from "./server.js";
import { GAME_BIZ } from "./utils.js";
@@ -14,6 +21,7 @@ const TGConstant = {
UA_PC: BBS_UA_PC,
UA_MOBILE: BBS_UA_MOBILE,
APP_ID: BBS_APP_ID,
CHANNELS: CHANNEL_LIST,
},
Salt: BBS_SALT,
Server: SERVER,

View File

@@ -1,7 +1,7 @@
/**
* @file web/constant/bbs.ts
* @description 常量-应用数据
* @since Beta v0.5.0
* @since Beta v0.5.1
*/
export const BBS_VERSION = "2.72.2";
@@ -21,3 +21,63 @@ export const BBS_SALT = {
X6: "t0qEgfub6cvueAPgR5m9aQWWVciEer7v",
PROD: "t0qEgfub6cvueAPgR5m9aQWWVciEer7v",
};
/**
* @description 频道列表
* @version 2.72.2
* @since Beta v0.5.1
* @interface ToChannelItem
* @property {string} title - 频道名称
* @property {string} icon - 频道图标
* @property {string} gid - 频道 gid
* @return ToChannelItem
*/
export interface ToChannelItem {
title: string;
icon: string;
gid: string;
}
/**
* @description 渠道列表
* @version 2.72.2
* @since Beta v0.5.1
* @type {Array<ToChannelItem>}
*/
export const CHANNEL_LIST: ToChannelItem[] = [
{
title: "原神",
icon: "/platforms/mhy/ys.webp",
gid: "2",
},
{
title: "崩坏:星穹铁道",
icon: "/platforms/mhy/sr.webp",
gid: "6",
},
{
title: "绝区零",
icon: "/platforms/mhy/zzz.webp",
gid: "8",
},
{
title: "崩坏3",
icon: "/platforms/mhy/bh3.webp",
gid: "1",
},
{
title: "崩坏2",
icon: "/platforms/mhy/bh2.webp",
gid: "3",
},
{
title: "未定事件簿",
icon: "/platforms/mhy/wd.webp",
gid: "4",
},
{
title: "大别野",
icon: "/platforms/mhy/dby.webp",
gid: "5",
},
];