mirror of
https://github.com/stoatchat/for-legacy-web.git
synced 2026-03-07 17:35:28 +00:00
feat: back port discriminators and display names
This commit is contained in:
@@ -5,7 +5,7 @@ import { useTriggerEvents } from "preact-context-menu";
|
||||
import { memo } from "preact/compat";
|
||||
import { useEffect, useState } from "preact/hooks";
|
||||
|
||||
import { Category, Button } from "@revoltchat/ui";
|
||||
import { Category } from "@revoltchat/ui";
|
||||
|
||||
import { internalEmit } from "../../../lib/eventEmitter";
|
||||
import { isTouchscreenDevice } from "../../../lib/isTouchscreenDevice";
|
||||
|
||||
@@ -68,7 +68,9 @@ export const Username = observer(
|
||||
override,
|
||||
...otherProps
|
||||
}: UsernameProps) => {
|
||||
let username = user?.username;
|
||||
let username =
|
||||
(user as unknown as { display_name: string })?.display_name ??
|
||||
user?.username;
|
||||
let color = masquerade?.colour;
|
||||
let timed_out: Date | undefined;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user