feat: 本次提交更新内容如下

优化弹窗
This commit is contained in:
笔记本里的永平
2025-07-23 13:48:16 +08:00
parent 55ba56fcf1
commit 4804bab90a
15 changed files with 723 additions and 476 deletions

View File

@@ -2,11 +2,11 @@ import React, { useState, useEffect } from "react";
import {
SearchOutlined,
CloseOutlined,
LeftOutlined,
RightOutlined,
ArrowLeftOutlined,
ArrowRightOutlined,
DeleteOutlined,
} from "@ant-design/icons";
import { Button as AntdButton, Input as AntdInput } from "antd";
import { Button, Input } from "antd";
import { Popup, Toast } from "antd-mobile";
import { getGroupList } from "./api";
import style from "./index.module.scss";
@@ -182,7 +182,7 @@ export default function GroupSelection({
{/* 输入框 */}
{showInput && (
<div className={`${style.inputWrapper} ${className}`}>
<AntdInput
<Input
placeholder={placeholder}
value={getDisplayText()}
onClick={openPopup}
@@ -234,7 +234,7 @@ export default function GroupSelection({
{group.name || group.chatroomId || group.id}
</div>
{!readonly && (
<AntdButton
<Button
type="text"
icon={<DeleteOutlined />}
size="small"
@@ -267,7 +267,7 @@ export default function GroupSelection({
<div className={style.popupHeader}>
<div className={style.popupTitle}></div>
<div className={style.searchWrapper}>
<AntdInput
<Input
placeholder="搜索群聊"
value={searchQuery}
onChange={(e) => setSearchQuery(e.target.value)}
@@ -278,7 +278,7 @@ export default function GroupSelection({
/>
<SearchOutlined className={style.searchIcon} />
{searchQuery && !readonly && (
<AntdButton
<Button
type="text"
icon={<CloseOutlined />}
size="small"
@@ -365,7 +365,7 @@ export default function GroupSelection({
<div className={style.paginationRow}>
<div className={style.totalCount}> {totalGroups} </div>
<div className={style.paginationControls}>
<AntdButton
<Button
type="text"
size="small"
onClick={() => setCurrentPage(Math.max(1, currentPage - 1))}
@@ -373,12 +373,12 @@ export default function GroupSelection({
className={style.pageBtn}
style={{ borderRadius: 16 }}
>
<LeftOutlined />
</AntdButton>
<ArrowLeftOutlined />
</Button>
<span className={style.pageInfo}>
{currentPage} / {totalPages}
</span>
<AntdButton
<Button
type="text"
size="small"
onClick={() =>
@@ -388,8 +388,8 @@ export default function GroupSelection({
className={style.pageBtn}
style={{ borderRadius: 16 }}
>
<RightOutlined />
</AntdButton>
<ArrowRightOutlined />
</Button>
</div>
</div>
{/* 底部按钮栏 */}
@@ -398,12 +398,12 @@ export default function GroupSelection({
{selectedGroups.length}
</div>
<div className={style.footerBtnGroup}>
<AntdButton type="default" onClick={() => setRealVisible(false)}>
<Button type="default" onClick={() => setRealVisible(false)}>
</AntdButton>
<AntdButton type="primary" onClick={handleConfirm}>
</Button>
<Button type="primary" onClick={handleConfirm}>
</AntdButton>
</Button>
</div>
</div>
</div>