开发: 聊天页面修改

This commit is contained in:
zhengw
2023-04-12 10:10:16 +08:00
parent ce3d942371
commit d67758d361
13 changed files with 416 additions and 52 deletions

View File

@@ -16,9 +16,9 @@ export const ChatTime: React.FC<IChatTimeProps> = (props) => {
const yesterday = new Date();
yesterday.setDate(yesterday.getDate() - 1);
const dayDiff =
(Date.parse(
(new Date(
`${now.getFullYear()}-${padWith(now.getMonth() + 1)}-${padWith(now.getDate())} 00:00:00`,
) -
).getTime() -
new Date(props.msgtime).getTime()) /
(24 * 60 * 60 * 1000) +
1;
@@ -58,7 +58,7 @@ export const ChatTime: React.FC<IChatTimeProps> = (props) => {
};
return (
<div style={{ display: 'flex', justifyContent: 'center' }}>
<div style={{ display: 'flex', justifyContent: 'center', marginBottom: 12 }}>
<div
style={{
background: '#DADADA',