更改一些问题

This commit is contained in:
al 2024-12-13 19:31:50 +08:00
parent e4f22d3fa8
commit a6b03ef3fb
5 changed files with 22 additions and 8 deletions

View File

@ -379,3 +379,14 @@ textarea {
.adm-modal .adm-modal-content {
max-height: 100vh;
}
.notice-toast {
.adm-toast-main {
width: calc(100vw - 40px) !important;
max-width: calc(100vw - 40px) !important;
top: 10% !important;
.adm-auto-center-content {
width: 100%;
}
}
}

View File

@ -112,8 +112,9 @@ const MessageList = forwardRef(({ mid, changeNoticeCount }, ref) => {
Object.keys(noticeObj).forEach((it) => {
newInfoItems[parseInt(it)]["count"] = noticeObj[it].unread_cnt;
if (noticeObj[it]["most_recent_notif"]) {
const time = noticeObj[it]["most_recent_notif"]["push_time"];
newInfoItems[parseInt(it)]["time"] = formatTimestamp(
noticeObj[it]["most_recent_notif"]["push_time"]
time ? time : noticeObj[it]["most_recent_notif"]["ct"]
);
newInfoItems[parseInt(it)]["subtitle"] =
noticeObj[it].most_recent_notif.title;

View File

@ -59,7 +59,7 @@ export default function HostList() {
<List.Item key={item.mid} className="p-0 bg-[#07050A]">
<div
onClick={() => router.push(`space/${item.mid}`)}
className="flex flex-row py-3"
className="grid grid-cols-[48px,auto] py-3"
>
<Image
src={item.image.images[0].urls[0]}
@ -69,9 +69,9 @@ export default function HostList() {
className="rounded-full"
placeholder=""
/>
<div className="ml-2 justify-around flex-1 truncate">
<div className="flex flex-row items-center">
<span className="text-base text-white font-medium whitespace-nowrap">
<div className="ml-2 justify-around flex-1 ">
<div className="flex flex-row items-center ">
<span className="text-base text-white font-medium whitespace-nowrap truncate max-w-[30%]">
{item.title}
</span>
{index < 3 && (

View File

@ -160,8 +160,9 @@ function BottomNav({ changeNoticeCount, changeInviter, noticeCount }) {
const { n_type, title } = data.d.notif;
Toast.show({
type: "info",
maskClassName: "notice-toast",
content: (
<div className="w-1/2">
<div className="flex flex-col gap-2">
<p className="text-base">{`🔔 收到一条${
n_type === 0
? "系统"
@ -171,10 +172,11 @@ function BottomNav({ changeNoticeCount, changeInviter, noticeCount }) {
? "付费"
: "活动"
}通知`}</p>
<p className="text-sm">{title}</p>
<p className="text-sm text-[#ffffff80]">{title}</p>
</div>
),
position: "top",
duration: 5000,
});
}
};

View File

@ -1,7 +1,7 @@
"use client";
import React, { useEffect, useState } from "react";
import { Mask, Image, Button } from "antd-mobile";
import { Mask, Image } from "antd-mobile";
import { getStreamer } from "@/api/streamer";
import { useRouter } from "next/navigation";
import { connect } from "react-redux";