First working version of EVE-PI
This commit is contained in:
35
src/app/components/Account/AccountCard.tsx
Normal file
35
src/app/components/Account/AccountCard.tsx
Normal file
@@ -0,0 +1,35 @@
|
||||
import { AccessToken } from "@/types";
|
||||
import { Box, Stack, Typography } from "@mui/material";
|
||||
import { CharacterRow } from "../Characters/CharacterRow";
|
||||
import { PlanetaryInteractionRow } from "../PlanetaryInteraction/PlanetaryInteractionRow";
|
||||
|
||||
export const AccountCard = ({
|
||||
characters,
|
||||
sessionReady,
|
||||
}: {
|
||||
characters: AccessToken[];
|
||||
sessionReady: boolean;
|
||||
}) => {
|
||||
return (
|
||||
<Box
|
||||
sx={{
|
||||
background: "#262626",
|
||||
padding: 1,
|
||||
borderRadius: 1,
|
||||
margin: 1,
|
||||
}}
|
||||
>
|
||||
<Typography paddingLeft={2}>Account: {characters[0].account}</Typography>
|
||||
{characters.map((c) => (
|
||||
<Stack
|
||||
key={c.character.characterId}
|
||||
direction="row"
|
||||
alignItems="flex-start"
|
||||
>
|
||||
<CharacterRow character={c} />
|
||||
{sessionReady && <PlanetaryInteractionRow character={c} />}
|
||||
</Stack>
|
||||
))}
|
||||
</Box>
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user