feat(ui): use NavSection in ListClansModal
This commit is contained in:
@@ -12,13 +12,4 @@
|
|||||||
.clans {
|
.clans {
|
||||||
@apply flex flex-col gap-2;
|
@apply flex flex-col gap-2;
|
||||||
}
|
}
|
||||||
|
|
||||||
.clan {
|
|
||||||
@apply flex items-center justify-between;
|
|
||||||
@apply px-4 py-5 bg-def-2;
|
|
||||||
|
|
||||||
.meta {
|
|
||||||
@apply flex flex-col gap-1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import { For, Show } from "solid-js";
|
|||||||
import { activeClanURI, clanURIs, setActiveClanURI } from "@/src/stores/clan";
|
import { activeClanURI, clanURIs, setActiveClanURI } from "@/src/stores/clan";
|
||||||
import { useClanListQuery } from "@/src/hooks/queries";
|
import { useClanListQuery } from "@/src/hooks/queries";
|
||||||
import { Alert } from "@/src/components/Alert/Alert";
|
import { Alert } from "@/src/components/Alert/Alert";
|
||||||
|
import { NavSection } from "../NavSection/NavSection";
|
||||||
|
|
||||||
export interface ListClansModalProps {
|
export interface ListClansModalProps {
|
||||||
onClose?: () => void;
|
onClose?: () => void;
|
||||||
@@ -78,20 +79,10 @@ export const ListClansModal = (props: ListClansModalProps) => {
|
|||||||
<ul class={cx(styles.clans)}>
|
<ul class={cx(styles.clans)}>
|
||||||
<For each={clanList()}>
|
<For each={clanList()}>
|
||||||
{(clan) => (
|
{(clan) => (
|
||||||
<li class={cx(styles.clan)}>
|
<li>
|
||||||
<div class={cx(styles.meta)}>
|
<NavSection
|
||||||
<Typography hierarchy="label" weight="bold" size="default">
|
label={clan.data.name}
|
||||||
{clan.data.name}
|
description={clan.data.description ?? undefined}
|
||||||
</Typography>
|
|
||||||
<Typography hierarchy="body" size="s">
|
|
||||||
{clan.data.description}
|
|
||||||
</Typography>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<Button
|
|
||||||
hierarchy="secondary"
|
|
||||||
ghost
|
|
||||||
icon="CaretRight"
|
|
||||||
onClick={selectClan(clan.data.uri)}
|
onClick={selectClan(clan.data.uri)}
|
||||||
/>
|
/>
|
||||||
</li>
|
</li>
|
||||||
|
|||||||
Reference in New Issue
Block a user