Merge remote-tracking branch 'upstream/dev' into dev

This commit is contained in:
thororen1234 2025-02-03 23:02:16 -05:00
commit f7856649c7
16 changed files with 101 additions and 59 deletions

View file

@ -141,7 +141,7 @@ function getBadges({ userId }: BadgeUserArgs): ProfileBadge[] {
}));
}
const PlatformIndicator = ({ user, wantMargin = true, wantTopMargin = false, small = false }: { user: User; wantMargin?: boolean; wantTopMargin?: boolean; small?: boolean; }) => {
const PlatformIndicator = ({ user, small = false }: { user: User; small?: boolean; }) => {
if (!user || (user.bot && !Settings.plugins.PlatformIndicators.showBots)) return null;
ensureOwnStatus(user);
@ -163,11 +163,7 @@ const PlatformIndicator = ({ user, wantMargin = true, wantTopMargin = false, sma
return (
<span
className="vc-platform-indicator"
style={{
marginLeft: wantMargin ? 4 : 0,
top: wantTopMargin ? 2 : 0,
gap: 2
}}
style={{ gap: "2px" }}
>
{icons}
</span>
@ -198,7 +194,7 @@ const indicatorLocations = {
description: "Inside messages",
onEnable: () => addMessageDecoration("platform-indicator", props =>
<ErrorBoundary noop>
<PlatformIndicator user={props.message?.author} wantTopMargin={true} />
<PlatformIndicator user={props.message?.author} />
</ErrorBoundary>
),
onDisable: () => removeMessageDecoration("platform-indicator")