refactor(types): eliminate all as any type assertions (30 → 0)
- Replace MouseEvent-only handlers with MouseEvent | KeyboardEvent unions in multi-select and ChatTabBar
- Define LegacyInstalledPlugin type for backward compatibility in plugin-api
- Create getTokenValue() helper for type-safe theme token access in AppearanceTab
- Define ModelConfig interface for model configuration type safety in modelProvider
- All modifications maintain exact business logic equivalence
- Build passes with zero TypeScript errors (bun run build ✅)
- LSP diagnostics clean on all modified files
This commit is contained in:
@@ -806,7 +806,7 @@ export function ChatPage() {
|
||||
}
|
||||
|
||||
// 关闭标签页
|
||||
const closeTab = (tabId: string, e?: React.MouseEvent) => {
|
||||
const closeTab = (tabId: string, e?: React.MouseEvent | React.KeyboardEvent) => {
|
||||
e?.stopPropagation()
|
||||
|
||||
// 不能关闭默认 WebUI 标签页
|
||||
|
||||
Reference in New Issue
Block a user