feat: add support i18n (#1468)

This commit is contained in:
JellyBrick
2023-12-01 01:30:46 +09:00
committed by GitHub
parent 7f71c36dc0
commit 7401cf69ad
65 changed files with 1226 additions and 303 deletions

View File

@ -1,5 +1,7 @@
import { createPlugin } from '@/utils';
import { t } from '@/i18n';
import type { VideoDataChanged } from '@/types/video-data-changed';
import type { YoutubePlayer } from '@/types/youtube-player';
@ -19,8 +21,8 @@ export default createPlugin<
},
DisableAutoPlayPluginConfig
>({
name: 'Disable Autoplay',
description: 'Makes every song start in "paused" mode',
name: t('plugins.disable-autoplay.name'),
description: t('plugins.disable-autoplay.description'),
restartNeeded: false,
config: {
enabled: false,
@ -31,7 +33,7 @@ export default createPlugin<
return [
{
label: 'Applies only on startup',
label: t('plugins.disable-autoplay.menu.apply-once'),
type: 'checkbox',
checked: config.applyOnce,
async click() {