mirror of
https://github.com/JetSprow/J-Board-Lite.git
synced 2026-05-01 01:14:10 +05:30
polish: refine lite admin controls
This commit is contained in:
@@ -110,13 +110,11 @@ export function ProxyPricingFields({
|
||||
plan,
|
||||
pricingMode,
|
||||
setPricingMode,
|
||||
allowTrafficTopup,
|
||||
}: {
|
||||
fieldId: FieldId;
|
||||
plan?: PlanFormValue;
|
||||
pricingMode: PlanPricingMode;
|
||||
setPricingMode: Dispatch<SetStateAction<PlanPricingMode>>;
|
||||
allowTrafficTopup: boolean;
|
||||
}) {
|
||||
const pricingModeLabels: Record<string, string> = {
|
||||
TRAFFIC_SLIDER: "用户自选流量",
|
||||
@@ -150,7 +148,7 @@ export function ProxyPricingFields({
|
||||
type="number"
|
||||
step="0.01"
|
||||
defaultValue={plan?.pricePerGb ?? ""}
|
||||
placeholder="例如 0.5"
|
||||
placeholder="0.5"
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
@@ -160,7 +158,7 @@ export function ProxyPricingFields({
|
||||
name="minTrafficGb"
|
||||
type="number"
|
||||
defaultValue={plan?.minTrafficGb ?? ""}
|
||||
placeholder="例如 10"
|
||||
placeholder="10"
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
@@ -170,7 +168,7 @@ export function ProxyPricingFields({
|
||||
name="maxTrafficGb"
|
||||
type="number"
|
||||
defaultValue={plan?.maxTrafficGb ?? ""}
|
||||
placeholder="例如 1000"
|
||||
placeholder="1000"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -184,7 +182,7 @@ export function ProxyPricingFields({
|
||||
type="number"
|
||||
min={1}
|
||||
defaultValue={plan?.fixedTrafficGb ?? plan?.minTrafficGb ?? ""}
|
||||
placeholder="例如 200"
|
||||
placeholder="200"
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
@@ -196,7 +194,7 @@ export function ProxyPricingFields({
|
||||
step="0.01"
|
||||
min={0.01}
|
||||
defaultValue={plan?.fixedPrice ?? ""}
|
||||
placeholder="例如 29.9"
|
||||
placeholder="29.9"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -210,13 +208,8 @@ export function ProxyPricingFields({
|
||||
type="number"
|
||||
min={1}
|
||||
defaultValue={plan?.totalTrafficGb ?? ""}
|
||||
placeholder="留空=无限流量"
|
||||
placeholder="空=不限"
|
||||
/>
|
||||
{allowTrafficTopup && (
|
||||
<p className="mt-1.5 text-xs text-muted-foreground">
|
||||
增流量上限按剩余总流量实时计算。
|
||||
</p>
|
||||
)}
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
@@ -234,7 +227,6 @@ export function ProxyConfigSection(props: {
|
||||
selectedInboundIds: string[];
|
||||
setSelectedInboundIds: Dispatch<SetStateAction<string[]>>;
|
||||
toggleInbound: (inboundId: string) => void;
|
||||
allowTrafficTopup: boolean;
|
||||
pricingMode: PlanPricingMode;
|
||||
setPricingMode: Dispatch<SetStateAction<PlanPricingMode>>;
|
||||
}) {
|
||||
|
||||
Reference in New Issue
Block a user