mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-07 21:53:04 -04:00
This commit is contained in:
parent
d3ab1930aa
commit
8e01e87868
1 changed files with 8 additions and 2 deletions
|
@ -21,7 +21,7 @@ import "./style.css";
|
||||||
import { addMemberListDecorator, removeMemberListDecorator } from "@api/MemberListDecorators";
|
import { addMemberListDecorator, removeMemberListDecorator } from "@api/MemberListDecorators";
|
||||||
import { addMessageDecoration, removeMessageDecoration } from "@api/MessageDecorations";
|
import { addMessageDecoration, removeMessageDecoration } from "@api/MessageDecorations";
|
||||||
import { addNicknameIcon, removeNicknameIcon } from "@api/NicknameIcons";
|
import { addNicknameIcon, removeNicknameIcon } from "@api/NicknameIcons";
|
||||||
import { definePluginSettings, migratePluginSetting } from "@api/Settings";
|
import { definePluginSettings, migratePluginSetting, Settings } from "@api/Settings";
|
||||||
import { Devs } from "@utils/constants";
|
import { Devs } from "@utils/constants";
|
||||||
import { classes } from "@utils/misc";
|
import { classes } from "@utils/misc";
|
||||||
import definePlugin, { OptionType } from "@utils/types";
|
import definePlugin, { OptionType } from "@utils/types";
|
||||||
|
@ -146,7 +146,7 @@ interface PlatformIndicatorProps {
|
||||||
}
|
}
|
||||||
|
|
||||||
const PlatformIndicator = ({ user, isProfile, isMessage, isMemberList }: PlatformIndicatorProps) => {
|
const PlatformIndicator = ({ user, isProfile, isMessage, isMemberList }: PlatformIndicatorProps) => {
|
||||||
if (user == null || user.bot) return null;
|
if (user == null || (user.bot && !Settings.plugins.PlatformIndicators.showBots)) return null;
|
||||||
useEnsureOwnStatus(user);
|
useEnsureOwnStatus(user);
|
||||||
|
|
||||||
const status: Record<Platform, string> | undefined = useStateFromStores([PresenceStore], () => PresenceStore.getState()?.clientStatuses?.[user.id]);
|
const status: Record<Platform, string> | undefined = useStateFromStores([PresenceStore], () => PresenceStore.getState()?.clientStatuses?.[user.id]);
|
||||||
|
@ -227,6 +227,12 @@ const settings = definePluginSettings({
|
||||||
default: true,
|
default: true,
|
||||||
restartNeeded: true
|
restartNeeded: true
|
||||||
},
|
},
|
||||||
|
showBots: {
|
||||||
|
type: OptionType.BOOLEAN,
|
||||||
|
description: "Whether to show platform indicators on bots",
|
||||||
|
default: false,
|
||||||
|
restartNeeded: false
|
||||||
|
},
|
||||||
ConsoleIcon: {
|
ConsoleIcon: {
|
||||||
type: OptionType.SELECT,
|
type: OptionType.SELECT,
|
||||||
description: "What console icon to use",
|
description: "What console icon to use",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue