From 45ba1350340e11102701b991d2be4c1b5201b16a Mon Sep 17 00:00:00 2001 From: Vendicated Date: Sat, 6 Dec 2025 21:11:41 +0100 Subject: [PATCH] LastFM: add api key guide back. our shared key may get ratelimited --- src/plugins/lastfmRichPresence/index.tsx | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/src/plugins/lastfmRichPresence/index.tsx b/src/plugins/lastfmRichPresence/index.tsx index b6164b196..4848b7438 100644 --- a/src/plugins/lastfmRichPresence/index.tsx +++ b/src/plugins/lastfmRichPresence/index.tsx @@ -17,6 +17,11 @@ */ import { definePluginSettings } from "@api/Settings"; +import { LinkButton } from "@components/Button"; +import { Card } from "@components/Card"; +import { Heading } from "@components/Heading"; +import { Margins } from "@components/margins"; +import { Paragraph } from "@components/Paragraph"; import { Devs } from "@utils/constants"; import { Logger } from "@utils/Logger"; import definePlugin, { OptionType } from "@utils/types"; @@ -61,6 +66,10 @@ function setActivity(activity: Activity | null) { } const settings = definePluginSettings({ + apiKey: { + description: "Custom Last.fm API key. Not required but highly recommended to avoid rate limiting with our shared key", + type: OptionType.STRING, + }, username: { description: "Last.fm username", type: OptionType.STRING, @@ -165,10 +174,6 @@ const settings = definePluginSettings({ type: OptionType.BOOLEAN, default: true, }, - apiKey: { - description: "Custom Last.fm API key. You shouldn't need to set this", - type: OptionType.STRING, - }, }); export default definePlugin({ @@ -178,6 +183,16 @@ export default definePlugin({ settings, + settingsAboutComponent() { + return ( + + How to create an API key + Set Application name and Application description to anything and leave the rest blank. + Create API Key + + ); + }, + start() { this.updatePresence(); this.updateInterval = setInterval(() => { this.updatePresence(); }, 16000);