forked from creations/profilePage
move all colors to :root, add activity small image and hover text, add support for streaming indicator, creations/profilePage#2
This commit is contained in:
parent
d91e832eab
commit
66744ddd10
5 changed files with 205 additions and 67 deletions
|
@ -30,11 +30,18 @@ async function handler(): Promise<Response> {
|
|||
const presence: LanyardData = data.data;
|
||||
const readme: string | Promise<string> | null = await handleReadMe(presence);
|
||||
|
||||
let status: string;
|
||||
if (presence.activities.some((activity) => activity.type === 1)) {
|
||||
status = "streaming";
|
||||
} else {
|
||||
status = presence.discord_status;
|
||||
}
|
||||
|
||||
const ejsTemplateData: EjsTemplateData = {
|
||||
title: presence.discord_user.global_name || presence.discord_user.username,
|
||||
username:
|
||||
presence.discord_user.global_name || presence.discord_user.username,
|
||||
status: presence.discord_status,
|
||||
status: status,
|
||||
activities: presence.activities,
|
||||
user: presence.discord_user,
|
||||
platform: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue