Skip to content

Commit

Permalink
Merge pull request #1216 from visualize-admin/feat/login-improvements-3
Browse files Browse the repository at this point in the history
feat: Handle chart names in profile table
  • Loading branch information
bprusinowski authored Oct 12, 2023
2 parents 4024985 + f91b01e commit 6e7d5bb
Showing 1 changed file with 17 additions and 3 deletions.
20 changes: 17 additions & 3 deletions app/login/components/profile-tables.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -237,9 +237,23 @@ const ProfileVisualizationsRow = (props: ProfileVisualizationsRowProps) => {
</Typography>
</TableCell>
<TableCell width="auto">
<Typography variant="body2">
{config.data.meta.title[locale]}
</Typography>
<NextLink href={`/v/${config.key}`} passHref legacyBehavior>
<Link target="_blank" color="primary">
{config.data.chartConfigs.length === 1 ? (
<Typography variant="body2">
{config.data.chartConfigs[0].meta.title[locale]}
</Typography>
) : (
<Box sx={{ display: "flex", flexDirection: "column", gap: 1 }}>
{config.data.chartConfigs.map((d, i) => (
<Typography key={i} variant="body2">
{i + 1}. {d.meta.title[locale]}
</Typography>
))}
</Box>
)}
</Link>
</NextLink>
</TableCell>
<TableCell width="40%">
{fetching ? (
Expand Down

1 comment on commit 6e7d5bb

@vercel
Copy link

@vercel vercel bot commented on 6e7d5bb Oct 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

visualization-tool – ./

visualization-tool-alpha.vercel.app
visualization-tool-ixt1.vercel.app
visualization-tool-git-main-ixt1.vercel.app

Please sign in to comment.