From b3ea20974c1e92d8f5762ba214eea14a8a990636 Mon Sep 17 00:00:00 2001
From: Johannes7k75 <57235955+Johannes7k75@users.noreply.github.com>
Date: Fri, 1 Aug 2025 14:48:43 +0200
Subject: [PATCH] fix: Add install instructions for websocket plugin (#318)
* Add install instructions for websocket plugin
* Add cleare description
* add install instructions also into Plugin config
---
.../youtubeMusicControls/README.md | 14 +++++++++
.../youtubeMusicControls/index.tsx | 31 ++++++++++++++++++-
2 files changed, 44 insertions(+), 1 deletion(-)
diff --git a/src/equicordplugins/youtubeMusicControls/README.md b/src/equicordplugins/youtubeMusicControls/README.md
index a26ecc3a7..8ad40cd85 100644
--- a/src/equicordplugins/youtubeMusicControls/README.md
+++ b/src/equicordplugins/youtubeMusicControls/README.md
@@ -13,5 +13,19 @@ Plugins that have to be enabled
- API Websocket
# Installation
+- [git](https://git-scm.com/downloads)
+- [node.js](https://nodejs.org/en/download) >= 22.12.0
+- [pnpm](https://pnpm.io/installation)
+
+```bash
+git clone https://github.com/th-ch/youtube-music
+cd .\youtube-music\
+git remote add johannes https://github.com/Johannes7k75/youtube-music.git
+git fetch johannes
+git merge johannes/feat/api-websocket
+pnpm install --frozen-lockfile
+pnpm dist:win
+```
+
See the [forum thread](https://discord.com/channels/1015060230222131221/1257038407503446176/1257038407503446176) / [Vencord docs](https://docs.vencord.dev/installing/custom-plugins/)
\ No newline at end of file
diff --git a/src/equicordplugins/youtubeMusicControls/index.tsx b/src/equicordplugins/youtubeMusicControls/index.tsx
index 675ec1ab6..c1e036b9a 100644
--- a/src/equicordplugins/youtubeMusicControls/index.tsx
+++ b/src/equicordplugins/youtubeMusicControls/index.tsx
@@ -26,6 +26,7 @@ import { Player as SpotifyPlayer } from "plugins/spotifyControls/PlayerComponent
import hoverOnlyStyle from "./hoverOnly.css?managed";
import { Player } from "./PlayerComponent";
+import { Forms, MaskedLink } from "@webpack/common";
function toggleHoverControls(value: boolean) {
(value ? enableStyle : disableStyle)(hoverOnlyStyle);
@@ -40,7 +41,35 @@ function isUrlValid(value: string) {
}
}
+function InstallIstructions() {
+ return (
+
+ How to install
+ Instructions on how to install YouTube music with websocket plugin
+
+
+
+ Software needed: git,node.js >= 22.12.0,pnpm
+
+
+ git clone https://github.com/th-ch/youtube-music
+ cd .\youtube-music\
+ git remote add johannes https://github.com/Johannes7k75/youtube-music.git
+ git fetch johannes
+ git merge johannes/feat/api-websocket
+ pnpm install --frozen-lockfile
+ pnpm dist:win
+
+
+
+ );
+}
+
const settings = definePluginSettings({
+ installYtmWithWebsocket: {
+ type: OptionType.COMPONENT,
+ component: () =>
+ },
hoverControls: {
description: "Show controls on hover",
type: OptionType.BOOLEAN,
@@ -65,7 +94,7 @@ const settings = definePluginSettings({
export default definePlugin({
name: "YouTubeMusicControls",
- description: "Adds a YouTube Music player above the account panel",
+ description: "Adds a YouTube Music player above the account panel, requires `https://github.com/th-ch/youtube-music` with an custom websocket plugin. See Readme of ths Plugin for instructions",
authors: [EquicordDevs.Johannes7k75],
settings,
patches: [