Add toggle for pretty view

This commit is contained in:
Gregory Schier
2023-02-27 09:08:48 -08:00
parent bb61602fd2
commit 09d16a03ef
8 changed files with 93 additions and 16 deletions

View File

@@ -1,15 +1,14 @@
import { Link } from 'react-router-dom';
import { useWorkspaces } from '../hooks/useWorkspaces';
import { Button } from '../components/Button';
import { ButtonLink } from '../components/ButtonLink';
export function Workspaces() {
const workspaces = useWorkspaces();
return (
<ul className="p-12">
{workspaces.data?.map((w) => (
<Button as={Link} key={w.id} to={`/workspaces/${w.id}`}>
<ButtonLink key={w.id} to={`/workspaces/${w.id}`}>
{w.name}
</Button>
</ButtonLink>
))}
</ul>
);