1
This commit is contained in:
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+1
-1
@@ -28,7 +28,7 @@
|
||||
}
|
||||
})();
|
||||
</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">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -437,60 +437,64 @@ const AdminApiKeys: React.FC = () => {
|
||||
</Form.Item>
|
||||
</Form>
|
||||
|
||||
{/* 超分配置(独立面板) */}
|
||||
<Divider />
|
||||
<Typography.Text strong style={{ fontSize: 14 }}>🎬 超分配置</Typography.Text>
|
||||
<div style={{ marginTop: 16 }}>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}>
|
||||
<Typography.Text>启用超分:</Typography.Text>
|
||||
<Switch checked={upscaleEnabled} onChange={setUpscaleEnabled} checkedChildren="启用" unCheckedChildren="关闭" />
|
||||
</div>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}>
|
||||
<Typography.Text>成功后删除源文件:</Typography.Text>
|
||||
<Switch checked={deleteSource} onChange={setDeleteSource} checkedChildren="是" unCheckedChildren="否" />
|
||||
</div>
|
||||
<Typography.Text type="secondary" style={{ fontSize: 12 }}>超分规则:</Typography.Text>
|
||||
<div style={{ marginTop: 8 }}>
|
||||
<div style={{ display: 'flex', flexDirection: 'column', gap: 8 }}>
|
||||
{(upscaleRules || []).map((rule, idx) => (
|
||||
<Card key={idx} size="small" style={{ background: '#f8f9fc' }}>
|
||||
<div style={{ display: 'flex', gap: 8, alignItems: 'center' }}>
|
||||
<Select
|
||||
value={rule.targetResolution}
|
||||
onChange={v => handleUpscaleRuleChange(idx, 'targetResolution', v)}
|
||||
style={{ width: 100 }}
|
||||
options={['480p', '720p', '1080p', '2K', '4K'].map(r => ({ label: r, value: r }))}
|
||||
/>
|
||||
<span>→</span>
|
||||
<Select
|
||||
value={rule.providerGenerationResolution}
|
||||
onChange={v => handleUpscaleRuleChange(idx, 'providerGenerationResolution', v)}
|
||||
style={{ width: 100 }}
|
||||
options={['480p', '720p', '1080p'].map(r => ({ label: r, value: r }))}
|
||||
/>
|
||||
<Select
|
||||
value={rule.processorKey}
|
||||
onChange={v => handleUpscaleRuleChange(idx, 'processorKey', v)}
|
||||
style={{ width: 140 }}
|
||||
options={[
|
||||
{ label: '本地FFmpeg', value: 'local_ffmpeg_crop_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>
|
||||
</div>
|
||||
</Card>
|
||||
))}
|
||||
<Button type="dashed" size="small" icon={<PlusOutlined />} onClick={handleAddUpscaleRule}>
|
||||
添加规则
|
||||
</Button>
|
||||
{/* 超分配置(仅编辑模式显示,新建时没ID) */}
|
||||
{modal.key?.id && (
|
||||
<>
|
||||
<Divider />
|
||||
<Typography.Text strong style={{ fontSize: 14 }}>🎬 超分配置</Typography.Text>
|
||||
<div style={{ marginTop: 16 }}>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}>
|
||||
<Typography.Text>启用超分:</Typography.Text>
|
||||
<Switch checked={upscaleEnabled} onChange={setUpscaleEnabled} checkedChildren="启用" unCheckedChildren="关闭" />
|
||||
</div>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: 8, marginBottom: 12 }}>
|
||||
<Typography.Text>成功后删除源文件:</Typography.Text>
|
||||
<Switch checked={deleteSource} onChange={setDeleteSource} checkedChildren="是" unCheckedChildren="否" />
|
||||
</div>
|
||||
<Typography.Text type="secondary" style={{ fontSize: 12 }}>超分规则:</Typography.Text>
|
||||
<div style={{ marginTop: 8 }}>
|
||||
<div style={{ display: 'flex', flexDirection: 'column', gap: 8 }}>
|
||||
{(upscaleRules || []).map((rule, idx) => (
|
||||
<Card key={idx} size="small" style={{ background: '#f8f9fc' }}>
|
||||
<div style={{ display: 'flex', gap: 8, alignItems: 'center' }}>
|
||||
<Select
|
||||
value={rule.targetResolution}
|
||||
onChange={v => handleUpscaleRuleChange(idx, 'targetResolution', v)}
|
||||
style={{ width: 100 }}
|
||||
options={['480p', '720p', '1080p', '2K', '4K'].map(r => ({ label: r, value: r }))}
|
||||
/>
|
||||
<span>→</span>
|
||||
<Select
|
||||
value={rule.providerGenerationResolution}
|
||||
onChange={v => handleUpscaleRuleChange(idx, 'providerGenerationResolution', v)}
|
||||
style={{ width: 100 }}
|
||||
options={['480p', '720p', '1080p'].map(r => ({ label: r, value: r }))}
|
||||
/>
|
||||
<Select
|
||||
value={rule.processorKey}
|
||||
onChange={v => handleUpscaleRuleChange(idx, 'processorKey', v)}
|
||||
style={{ width: 140 }}
|
||||
options={[
|
||||
{ label: '本地FFmpeg', value: 'local_ffmpeg_crop_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>
|
||||
</div>
|
||||
</Card>
|
||||
))}
|
||||
<Button type="dashed" size="small" icon={<PlusOutlined />} onClick={handleAddUpscaleRule}>
|
||||
添加规则
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
)}
|
||||
|
||||
{/* 虚拟素材库配额(仅编辑模式显示,新建时没ID) */}
|
||||
{modal.key?.id && (
|
||||
|
||||
Reference in New Issue
Block a user