mirror of
https://github.com/Sagit-chu/flvx.git
synced 2026-10-13 04:36:37 +08:00
style: move maxConn and speed limit inputs to advanced settings accordion (#464)
This commit is contained in:
@@ -54,6 +54,7 @@ import { Switch } from "@/shadcn-bridge/heroui/switch";
|
||||
import { Alert } from "@/shadcn-bridge/heroui/alert";
|
||||
import { Progress } from "@/shadcn-bridge/heroui/progress";
|
||||
import { Checkbox } from "@/shadcn-bridge/heroui/checkbox";
|
||||
import { Accordion, AccordionItem } from "@/shadcn-bridge/heroui/accordion";
|
||||
import {
|
||||
createForward,
|
||||
getForwardList,
|
||||
@@ -4729,6 +4730,25 @@ export default function ForwardPage() {
|
||||
</ModalHeader>
|
||||
<ModalBody>
|
||||
<div className="space-y-4 pb-4">
|
||||
<Input
|
||||
errorMessage={errors.name}
|
||||
isInvalid={!!errors.name}
|
||||
label="规则名称"
|
||||
placeholder="请输入规则名称"
|
||||
value={form.name}
|
||||
variant="bordered"
|
||||
onChange={(e) =>
|
||||
setForm((prev) => ({ ...prev, name: e.target.value }))
|
||||
}
|
||||
/>
|
||||
|
||||
<Accordion variant="bordered">
|
||||
<AccordionItem
|
||||
key="advanced"
|
||||
aria-label="高级设置"
|
||||
title="高级设置"
|
||||
>
|
||||
<div className="space-y-4 pb-2">
|
||||
<Input
|
||||
label="最大连接数"
|
||||
placeholder="0 或空表示不限制"
|
||||
@@ -4742,19 +4762,6 @@ export default function ForwardPage() {
|
||||
description="此设置优先于用户的全局连接数限制。0 表示不限制。"
|
||||
variant="bordered"
|
||||
/>
|
||||
|
||||
<Input
|
||||
errorMessage={errors.name}
|
||||
isInvalid={!!errors.name}
|
||||
label="规则名称"
|
||||
placeholder="请输入规则名称"
|
||||
value={form.name}
|
||||
variant="bordered"
|
||||
onChange={(e) =>
|
||||
setForm((prev) => ({ ...prev, name: e.target.value }))
|
||||
}
|
||||
/>
|
||||
|
||||
{isAdmin && (
|
||||
<Select
|
||||
label="规则限速"
|
||||
@@ -4786,6 +4793,9 @@ export default function ForwardPage() {
|
||||
))}
|
||||
</Select>
|
||||
)}
|
||||
</div>
|
||||
</AccordionItem>
|
||||
</Accordion>
|
||||
|
||||
<Select
|
||||
description={
|
||||
|
||||
Reference in New Issue
Block a user