This commit is contained in:
2026-08-06 14:12:46 +08:00
parent 4766bab453
commit dc3c4f7e4d
3 changed files with 59 additions and 55 deletions
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -28,7 +28,7 @@
} }
})(); })();
</script> </script>
<script type="module" crossorigin src="/assets/index-C5-PCv54.js"></script> <script type="module" crossorigin src="/assets/index-nOnojq6k.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-D3fwIbOp.css"> <link rel="stylesheet" crossorigin href="/assets/index-D3fwIbOp.css">
</head> </head>
<body> <body>
+57 -53
View File
@@ -437,60 +437,64 @@ const AdminApiKeys: React.FC = () => {
</Form.Item> </Form.Item>
</Form> </Form>
{/* 超分配置(独立面板 */} {/* 超分配置(仅编辑模式显示,新建时没ID */}
<Divider /> {modal.key?.id && (
<Typography.Text strong style={{ fontSize: 14 }}>🎬 </Typography.Text> <>
<div style={{ marginTop: 16 }}> <Divider />
<div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}> <Typography.Text strong style={{ fontSize: 14 }}>🎬 </Typography.Text>
<Typography.Text></Typography.Text> <div style={{ marginTop: 16 }}>
<Switch checked={upscaleEnabled} onChange={setUpscaleEnabled} checkedChildren="启用" unCheckedChildren="关闭" /> <div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}>
</div> <Typography.Text></Typography.Text>
<div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}> <Switch checked={upscaleEnabled} onChange={setUpscaleEnabled} checkedChildren="启用" unCheckedChildren="关闭" />
<Typography.Text></Typography.Text> </div>
<Switch checked={deleteSource} onChange={setDeleteSource} checkedChildren="是" unCheckedChildren="否" /> <div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}>
</div> <Typography.Text></Typography.Text>
<Typography.Text type="secondary" style={{ fontSize: 12 }}></Typography.Text> <Switch checked={deleteSource} onChange={setDeleteSource} checkedChildren="是" unCheckedChildren="否" />
<div style={{ marginTop: 8 }}> </div>
<div style={{ display: 'flex', flexDirection: 'column', gap: 8 }}> <Typography.Text type="secondary" style={{ fontSize: 12 }}></Typography.Text>
{(upscaleRules || []).map((rule, idx) => ( <div style={{ marginTop: 8 }}>
<Card key={idx} size="small" style={{ background: '#f8f9fc' }}> <div style={{ display: 'flex', flexDirection: 'column', gap: 8 }}>
<div style={{ display: 'flex', gap: 8, alignItems: 'center' }}> {(upscaleRules || []).map((rule, idx) => (
<Select <Card key={idx} size="small" style={{ background: '#f8f9fc' }}>
value={rule.targetResolution} <div style={{ display: 'flex', gap: 8, alignItems: 'center' }}>
onChange={v => handleUpscaleRuleChange(idx, 'targetResolution', v)} <Select
style={{ width: 100 }} value={rule.targetResolution}
options={['480p', '720p', '1080p', '2K', '4K'].map(r => ({ label: r, value: r }))} onChange={v => handleUpscaleRuleChange(idx, 'targetResolution', v)}
/> style={{ width: 100 }}
<span></span> options={['480p', '720p', '1080p', '2K', '4K'].map(r => ({ label: r, value: r }))}
<Select />
value={rule.providerGenerationResolution} <span></span>
onChange={v => handleUpscaleRuleChange(idx, 'providerGenerationResolution', v)} <Select
style={{ width: 100 }} value={rule.providerGenerationResolution}
options={['480p', '720p', '1080p'].map(r => ({ label: r, value: r }))} onChange={v => handleUpscaleRuleChange(idx, 'providerGenerationResolution', v)}
/> style={{ width: 100 }}
<Select options={['480p', '720p', '1080p'].map(r => ({ label: r, value: r }))}
value={rule.processorKey} />
onChange={v => handleUpscaleRuleChange(idx, 'processorKey', v)} <Select
style={{ width: 140 }} value={rule.processorKey}
options={[ onChange={v => handleUpscaleRuleChange(idx, 'processorKey', v)}
{ label: '本地FFmpeg', value: 'local_ffmpeg_crop_v1' }, style={{ width: 140 }}
{ label: '火山标准版', value: 'volc_standard_v1' }, options={[
{ label: '火山专业版', value: 'volc_professional_v1' }, { label: '本地FFmpeg', value: 'local_ffmpeg_crop_v1' },
{ label: '火山大模型', value: 'volc_large_model_v1' }, { label: '火山标准版', value: 'volc_standard_v1' },
]} { label: '火山专业版', value: 'volc_professional_v1' },
/> { label: '火山大模型', value: 'volc_large_model_v1' },
<Popconfirm title="确定删除此规则?" onConfirm={() => handleRemoveUpscaleRule(idx)}> ]}
<Button type="link" danger size="small" icon={<DeleteOutlined />} /> />
</Popconfirm> <Popconfirm title="确定删除此规则?" onConfirm={() => handleRemoveUpscaleRule(idx)}>
</div> <Button type="link" danger size="small" icon={<DeleteOutlined />} />
</Card> </Popconfirm>
))} </div>
<Button type="dashed" size="small" icon={<PlusOutlined />} onClick={handleAddUpscaleRule}> </Card>
))}
</Button> <Button type="dashed" size="small" icon={<PlusOutlined />} onClick={handleAddUpscaleRule}>
</Button>
</div>
</div>
</div> </div>
</div> </>
</div> )}
{/* 虚拟素材库配额(仅编辑模式显示,新建时没ID) */} {/* 虚拟素材库配额(仅编辑模式显示,新建时没ID) */}
{modal.key?.id && ( {modal.key?.id && (