feat: add danmuku plugin documentation and i18n setup guide

- Created a new documentation file for the danmuku plugin with code examples.
- Added comprehensive i18n setup instructions, including default language settings, language imports, and examples for adding and modifying languages.
- Updated the structure and content of the i18n documentation to enhance clarity and usability.
This commit is contained in:
Harvey Zack committed 2025-09-06 13:48:25 +08:00
1 parent 18475f08fd
commit 5b1cebb334
82 files changed
+268 -174

No files matched your search

+17 -15
View File
@@ -710,19 +710,19 @@ export interface Icons {
type I18nKeys
= | 'en'
| 'zh-cn'
| 'zh-tw'
| 'pl'
| 'cs'
| 'es'
| 'fa'
| 'fr'
| 'id'
| 'ru'
| 'tr'
| 'ar'
| 'vi'
| (string & Record<never, never>)
| 'zh-cn'
| 'zh-tw'
| 'pl'
| 'cs'
| 'es'
| 'fa'
| 'fr'
| 'id'
| 'ru'
| 'tr'
| 'ar'
| 'vi'
| (string & Record<never, never>)
interface I18nValue {
'Video Info': string
@@ -765,14 +765,15 @@ interface I18nValue {
export type I18n = Partial<Record<I18nKeys, Partial<I18nValue>>>
declare module "artplayer/i18n/*" {
declare module 'artplayer/i18n/*' {
const lang: Partial<I18nValue>
// @ts-ignore
// @ts-expect-error TS2666
export default lang
}
export type Bar = 'loaded' | 'played' | 'hover'
export interface Events {
@@ -1310,5 +1311,6 @@ export default class Artplayer extends Player {
) => Promise<Artplayer['plugins']> | Artplayer['plugins']
} & Record<string, unknown>
}
export = Artplayer;
export as namespace Artplayer;