refactor: delete subtitle.ts (#1899 #1900)

This commit is contained in:
2026-09-14 20:45:15 +08:00
parent d8596fec28
commit 60d44c11dc
@@ -1,46 +0,0 @@
/**
* 字幕样式相关类型与常量
* 单独抽离以满足 react-refresh/only-export-components 规则
*/
/* ──────────── 类型 ──────────── */
export type SubtitleMode = "manual" | "asr"
export interface SubtitleStyleConfig {
/** 是否启用字幕 */
enabled: boolean
/** 字幕模式:手动输入 / ASR 自动识别 */
mode: SubtitleMode
/** 字体大小 px */
fontSize: number
/** 字体颜色 */
fontColor: string
/** 描边 */
stroke: boolean
/** 阴影 */
shadow: boolean
/** 字幕位置 */
position: "top" | "center" | "bottom"
/** 字体 */
font: string
/** 动画效果 */
animation: string
/** ASR 语言(仅 ASR 模式) */
asrLanguage: "zh" | "en"
}
/* ──────────── 默认值 ──────────── */
export const DEFAULT_SUBTITLE_STYLE: SubtitleStyleConfig = {
enabled: true,
mode: "asr",
fontSize: 16,
fontColor: "#ffffff",
stroke: true,
shadow: false,
position: "bottom",
font: "思源黑体",
animation: "none",
asrLanguage: "zh",
}