完善页尾链接功能与样式 & 修复表单提交触发问题
This commit is contained in:
@@ -148,19 +148,6 @@ export default function WhitelistPage(props: WhitelistPageProps) {
|
||||
setSelection(new Set(selection))
|
||||
}
|
||||
|
||||
const toggleSelectAll = () => {
|
||||
if (selection.size === data.list.length) {
|
||||
setSelection(new Set())
|
||||
}
|
||||
else {
|
||||
const newSelection = new Set<number>()
|
||||
data.list.forEach((item) => {
|
||||
newSelection.add(item.id)
|
||||
})
|
||||
setSelection(newSelection)
|
||||
}
|
||||
}
|
||||
|
||||
// ======================
|
||||
// 表单
|
||||
// ======================
|
||||
@@ -316,7 +303,7 @@ export default function WhitelistPage(props: WhitelistPageProps) {
|
||||
<Form<SchemaType>
|
||||
className="flex flex-col gap-4 py-4"
|
||||
form={form}
|
||||
onSubmit={onSubmit}>
|
||||
handler={form.handleSubmit(onSubmit)}>
|
||||
<FormField name="host" label="IP地址">
|
||||
{({id, field}) => (
|
||||
<div className="flex gap-2">
|
||||
|
||||
Reference in New Issue
Block a user