补充前端模块状态说明注释
This commit is contained in:
@@ -108,6 +108,7 @@ export async function loadAdminCurrentLossCoverEvent() {
|
||||
return;
|
||||
}
|
||||
|
||||
// 待开始、进行中和待结算活动允许管理员手动结束,已结束/已关闭状态不再展示按钮。
|
||||
const canClose = ["scheduled", "active", "settlement_pending"].includes(event.status);
|
||||
const closeButton = canClose
|
||||
? `<button type="button" data-blc-close-current="${Number(event.id)}" style="margin-top:10px; padding:7px 14px; border:none; border-radius:999px; background:#dc2626; color:#fff; font-size:12px; font-weight:bold; cursor:pointer;">立即结束</button>`
|
||||
@@ -145,6 +146,7 @@ export async function openAdminBaccaratLossCoverModal() {
|
||||
}
|
||||
|
||||
const now = new Date();
|
||||
// 默认活动 30 分钟,领奖截止延后 24 小时,便于管理员打开后直接微调。
|
||||
const end = new Date(now.getTime() + 30 * 60 * 1000);
|
||||
const claimDeadline = new Date(end.getTime() + 24 * 60 * 60 * 1000);
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
import { escapeHtml } from "./html.js";
|
||||
|
||||
// 排行榜页码、排序与绑定标记需要跨打开/关闭弹窗保持一致。
|
||||
let bankRankPage = 1;
|
||||
let bankRankSort = "desc";
|
||||
let bankModalEventsBound = false;
|
||||
@@ -149,6 +150,7 @@ export async function bankLoadInfo() {
|
||||
}
|
||||
|
||||
if (window.chatContext) {
|
||||
// 同步全局金币缓存,供聊天室其他金币展示或后续购买逻辑读取最新余额。
|
||||
window.chatContext.myGold = data.jjb;
|
||||
window.chatContext.bankGold = data.bank_jjb;
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
export const BLOCKABLE_SYSTEM_SENDERS = ["钓鱼播报", "星海小博士", "百家乐", "跑马", "神秘箱子"];
|
||||
export const BLOCKED_SYSTEM_SENDERS_STORAGE_KEY = "chat_blocked_system_senders";
|
||||
export const CHAT_SOUND_MUTED_STORAGE_KEY = "chat_sound_muted";
|
||||
// 白名单、localStorage key 与绑定标记共同保证偏好读取可控、事件只注册一次。
|
||||
let soundMuteEventsBound = false;
|
||||
let blockMenuEventsBound = false;
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
import { escapeHtml } from "./html.js";
|
||||
|
||||
// 默认空态供右侧面板和手机抽屉共用,调用方仍可通过 options.emptyHtml 覆盖。
|
||||
const EMPTY_ROOMS_HTML =
|
||||
'<div style="text-align:center;color:#bbb;padding:16px 0;font-size:11px;">暂无房间</div>';
|
||||
|
||||
@@ -76,6 +77,7 @@ export function renderRoomStatusRow(room, options = {}) {
|
||||
? `<span style="background:#e8f5e9;color:#2e7d32;border-radius:8px;padding:0 ${variant === "mobile" ? "6px" : "5px"};font-size:10px;font-weight:bold;white-space:nowrap;flex-shrink:0;">${room.online}${variant === "mobile" ? "" : " "}人</span>`
|
||||
: `<span style="background:#f5f5f5;color:#bbb;border-radius:8px;padding:0 ${variant === "mobile" ? "6px" : "5px"};font-size:10px;white-space:nowrap;flex-shrink:0;">空</span>`;
|
||||
|
||||
// 手机和桌面只区分容器尺寸与视觉密度,房间数据口径保持同一套。
|
||||
if (variant === "mobile") {
|
||||
return `<div ${clickHandler}
|
||||
style="display:flex;align-items:center;justify-content:space-between;
|
||||
|
||||
Reference in New Issue
Block a user