wip
This commit is contained in:
parent
11f185bf72
commit
7c833c3568
8 changed files with 161 additions and 9 deletions
10
src/frontend/components/CurrentUser.tsx
Normal file
10
src/frontend/components/CurrentUser.tsx
Normal file
|
@ -0,0 +1,10 @@
|
|||
import React from 'react';
|
||||
import { useGetSessionQuery } from '../services/session';
|
||||
import { Skeleton } from './Skeleton';
|
||||
|
||||
export const CurrentUser: React.VFC = () => {
|
||||
const {data} = useGetSessionQuery(undefined);
|
||||
return data ? (
|
||||
<h1 className="text-125">{data.username}<span className="text-dimmed">@{data.host}</span></h1>
|
||||
) : <Skeleton height="1.5rem" />;
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue