Files
KVideo/lib/utils/source-names.ts
T
kuekhaoyang ad9e75bc8c feat: Implement video player components and search functionality
- Added EpisodeList component for displaying a list of episodes with selection functionality.
- Created PlayerError component to handle and display video playback errors.
- Developed VideoMetadata component to show detailed information about the video.
- Implemented VideoPlayer component for video playback with error handling and loading states.
- Introduced EmptyState and NoResults components for search results handling.
- Created ResultsHeader component to display search results summary.
- Developed SearchForm component for user input and search initiation.
- Implemented SourceBadges component to show available video sources.
- Created VideoGrid component to display search results in a grid format.
- Added useSearchCache and useSearchStream hooks for managing search state and caching results.
- Implemented useVideoPlayer hook for fetching and managing video details.
- Added utility function to map source IDs to their respective names.
2025-11-17 13:51:03 +08:00

28 lines
744 B
TypeScript

export function getSourceName(sourceId: string): string {
const sourceNames: Record<string, string> = {
'dytt': '电影天堂',
'ruyi': '如意',
'baofeng': '暴风',
'tianya': '天涯',
'feifan': '非凡影视',
'sanliuling': '360',
'wolong': '卧龙',
'jisu': '极速',
'mozhua': '魔爪',
'modu': '魔都',
'zuida': '最大',
'yinghua': '樱花',
'baiduyun': '百度云',
'wujin': '无尽',
'wangwang': '旺旺',
'ikun': 'iKun',
};
return sourceNames[sourceId] || sourceId;
}
export const SOURCE_IDS = [
'dytt', 'ruyi', 'baofeng', 'tianya', 'feifan',
'sanliuling', 'wolong', 'jisu', 'mozhua', 'modu',
'zuida', 'yinghua', 'baiduyun', 'wujin', 'wangwang', 'ikun'
];