Merge pull request #3806 from prince0xdev/feat/thumbnail-team-memory
Add favicon icons and auto-redirect to last selected team
This commit is contained in:
@@ -1,6 +1,8 @@
|
|||||||
import Link from 'next/link';
|
import Link from 'next/link';
|
||||||
import { DataGrid } from '@/components/common/DataGrid';
|
import { DataGrid } from '@/components/common/DataGrid';
|
||||||
import { useLoginQuery, useNavigation, useUserWebsitesQuery } from '@/components/hooks';
|
import { useLoginQuery, useNavigation, useUserWebsitesQuery } from '@/components/hooks';
|
||||||
|
import { Favicon } from '@/index';
|
||||||
|
import { Icon, Row } from '@umami/react-zen';
|
||||||
import { WebsitesTable } from './WebsitesTable';
|
import { WebsitesTable } from './WebsitesTable';
|
||||||
|
|
||||||
export function WebsitesDataTable({
|
export function WebsitesDataTable({
|
||||||
@@ -21,7 +23,12 @@ export function WebsitesDataTable({
|
|||||||
const { renderUrl } = useNavigation();
|
const { renderUrl } = useNavigation();
|
||||||
|
|
||||||
const renderLink = (row: any) => (
|
const renderLink = (row: any) => (
|
||||||
<Link href={renderUrl(`/websites/${row.id}`, false)}>{row.name}</Link>
|
<Row alignItems="center" gap="3">
|
||||||
|
<Icon size="md" color="muted">
|
||||||
|
<Favicon domain={row.domain} />
|
||||||
|
</Icon>
|
||||||
|
<Link href={renderUrl(`/websites/${row.id}`, false)}>{row.name}</Link>
|
||||||
|
</Row>
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -25,8 +25,7 @@ export function LoginForm() {
|
|||||||
onSuccess: async ({ token, user }) => {
|
onSuccess: async ({ token, user }) => {
|
||||||
setClientAuthToken(token);
|
setClientAuthToken(token);
|
||||||
setUser(user);
|
setUser(user);
|
||||||
|
router.push('/');
|
||||||
router.push('/websites');
|
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user