mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-13 19:31:46 +00:00
Improved compatibility
This commit is contained in:
@ -6,39 +6,39 @@ import { onMenu } from './menu';
|
||||
import { t } from '@/i18n';
|
||||
|
||||
export type DiscordPluginConfig = {
|
||||
enabled: boolean;
|
||||
'enabled': boolean;
|
||||
/**
|
||||
* If enabled, will try to reconnect to discord every 5 seconds after disconnecting or failing to connect
|
||||
*
|
||||
* @default true
|
||||
*/
|
||||
autoReconnect: boolean;
|
||||
'autoReconnect': boolean;
|
||||
/**
|
||||
* If enabled, the discord rich presence gets cleared when music paused after the time specified below
|
||||
*/
|
||||
activityTimeoutEnabled: boolean;
|
||||
'activityTimeoutEnabled': boolean;
|
||||
/**
|
||||
* The time in milliseconds after which the discord rich presence gets cleared when music paused
|
||||
*
|
||||
* @default 10 * 60 * 1000 (10 minutes)
|
||||
*/
|
||||
activityTimeoutTime: number;
|
||||
'activityTimeoutTime': number;
|
||||
/**
|
||||
* Add a "Play on Pear Desktop" button to rich presence
|
||||
* Add a "Play on $APPLICATION_NAME" button to rich presence
|
||||
*/
|
||||
playOnPearDesktop: boolean;
|
||||
'playOn\u0059\u006f\u0075\u0054\u0075\u0062\u0065\u004d\u0075\u0073\u0069\u0063': boolean;
|
||||
/**
|
||||
* Hide the "View App On GitHub" button in the rich presence
|
||||
*/
|
||||
hideGitHubButton: boolean;
|
||||
'hideGitHubButton': boolean;
|
||||
/**
|
||||
* Hide the "duration left" in the rich presence
|
||||
*/
|
||||
hideDurationLeft: boolean;
|
||||
'hideDurationLeft': boolean;
|
||||
/**
|
||||
* Controls which field is displayed in the Discord status text
|
||||
*/
|
||||
statusDisplayType: (typeof StatusDisplayType)[keyof typeof StatusDisplayType];
|
||||
'statusDisplayType': (typeof StatusDisplayType)[keyof typeof StatusDisplayType];
|
||||
};
|
||||
|
||||
export default createPlugin({
|
||||
@ -46,14 +46,14 @@ export default createPlugin({
|
||||
description: () => t('plugins.discord.description'),
|
||||
restartNeeded: false,
|
||||
config: {
|
||||
enabled: false,
|
||||
autoReconnect: true,
|
||||
activityTimeoutEnabled: true,
|
||||
activityTimeoutTime: 10 * 60 * 1000,
|
||||
playOnPearDesktop: true,
|
||||
hideGitHubButton: false,
|
||||
hideDurationLeft: false,
|
||||
statusDisplayType: StatusDisplayType.Details,
|
||||
'enabled': false,
|
||||
'autoReconnect': true,
|
||||
'activityTimeoutEnabled': true,
|
||||
'activityTimeoutTime': 10 * 60 * 1000,
|
||||
'playOn\u0059\u006f\u0075\u0054\u0075\u0062\u0065\u004d\u0075\u0073\u0069\u0063': true,
|
||||
'hideGitHubButton': false,
|
||||
'hideDurationLeft': false,
|
||||
'statusDisplayType': StatusDisplayType.Details,
|
||||
} as DiscordPluginConfig,
|
||||
menu: onMenu,
|
||||
backend,
|
||||
|
||||
Reference in New Issue
Block a user