Admin section updates.

This commit is contained in:
Mike Cao
2025-07-10 20:04:17 -07:00
parent 87449ece9e
commit 1b81074752
20 changed files with 274 additions and 647 deletions

View File

@@ -1,11 +0,0 @@
.filters {
display: flex;
justify-content: flex-start;
align-items: flex-start;
}
.tag {
text-align: center;
margin-bottom: 10px;
margin-inline-end: 20px;
}

View File

@@ -1,38 +0,0 @@
import { Button, Icon, Text } from '@umami/react-zen';
import { Close } from '@/components/icons';
import styles from './WebsiteTags.module.css';
export function WebsiteTags({
items = [],
websites = [],
onClick,
}: {
items: any[];
websites: any[];
onClick: (e: Event) => void;
}) {
if (websites.length === 0) {
return null;
}
return (
<div className={styles.filters}>
{websites.map(websiteId => {
const website = items.find(a => a.id === websiteId);
return (
<div key={websiteId} className={styles.tag}>
<Button onPress={() => onClick(websiteId)} variant="primary" size="sm">
<Text>
<b>{`${website.name}`}</b>
</Text>
<Icon>
<Close />
</Icon>
</Button>
</div>
);
})}
</div>
);
}