refactor(import): 移除旧预设兼容层

This commit is contained in:
tbphp committed 2026-08-01 21:01:29 +08:00
1 parent ec54fc37c8
commit 1bc1eb334c
1 file changed
-23
@@ -102,26 +102,3 @@ export function isProviderPresetID(value: unknown): value is ProviderPresetID {
export function findProviderPreset(id: ProviderPresetID): RegisteredProviderPreset | undefined {
return providerPresetRegistry.find((preset) => preset.id === id)
}
// Temporary compatibility for the legacy stepped components removed by Task 6.
export interface ChannelPreset {
id: ProviderPresetID
labelKey: string
upstream_url: string
protocols: readonly GroupProtocol[]
}
export const channelPresets: readonly ChannelPreset[] = [
...providerPresetRegistry.map((preset) => ({
id: preset.id,
labelKey: preset.nameKey,
upstream_url: preset.upstream_url,
protocols: preset.protocols,
})),
{
id: 'custom',
labelKey: 'import.presets.custom.name',
upstream_url: '',
protocols: [],
},
]