aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/spotifyControls
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/spotifyControls')
-rw-r--r--src/plugins/spotifyControls/PlayerComponent.tsx3
-rw-r--r--src/plugins/spotifyControls/SpotifyStore.ts2
2 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/spotifyControls/PlayerComponent.tsx b/src/plugins/spotifyControls/PlayerComponent.tsx
index f4c7c81..c0ba0fe 100644
--- a/src/plugins/spotifyControls/PlayerComponent.tsx
+++ b/src/plugins/spotifyControls/PlayerComponent.tsx
@@ -23,6 +23,7 @@ import { Flex } from "@components/Flex";
import { ImageIcon, LinkIcon, OpenExternalIcon } from "@components/Icons";
import { Link } from "@components/Link";
import { debounce } from "@utils/debounce";
+import { openImageModal } from "@utils/discord";
import { classes, copyWithToast } from "@utils/misc";
import { ContextMenu, FluxDispatcher, Forms, Menu, React, useEffect, useState, useStateFromStores } from "@webpack/common";
@@ -231,7 +232,7 @@ function AlbumContextMenu({ track }: { track: Track; }) {
id="view-cover"
label="View Album Cover"
// trolley
- action={() => (Vencord.Plugins.plugins.ViewIcons as any).openImage(track.album.image.url)}
+ action={() => openImageModal(track.album.image.url)}
icon={ImageIcon}
/>
<Menu.MenuControlItem
diff --git a/src/plugins/spotifyControls/SpotifyStore.ts b/src/plugins/spotifyControls/SpotifyStore.ts
index c713249..d65be74 100644
--- a/src/plugins/spotifyControls/SpotifyStore.ts
+++ b/src/plugins/spotifyControls/SpotifyStore.ts
@@ -89,7 +89,7 @@ export const SpotifyStore = proxyLazy(() => {
public isSettingPosition = false;
public openExternal(path: string) {
- const url = Settings.plugins.SpotifyControls.useSpotifyUris
+ const url = Settings.plugins.SpotifyControls.useSpotifyUris || Vencord.Plugins.isPluginEnabled("OpenInApp")
? "spotify:" + path.replaceAll("/", (_, idx) => idx === 0 ? "" : ":")
: "https://open.spotify.com" + path;