Event data updates.

This commit is contained in:
Mike Cao 2023-07-11 01:16:17 -07:00
parent d1e93b8e62
commit 55701c9e8c
15 changed files with 642 additions and 693 deletions

View file

@ -48,10 +48,7 @@ export function WebsiteHeader({ websiteId, showLinks = true, children }) {
{showLinks && (
<Flexbox alignItems="center">
{links.map(({ label, icon, path }) => {
const query = path.indexOf('?');
const selected = path
? asPath.endsWith(query >= 0 ? path.substring(0, query) : path)
: pathname === '/websites/[id]';
const selected = path ? pathname.endsWith(path) : pathname === '/websites/[id]';
return (
<Link key={label} href={`/websites/${websiteId}${path}`} shallow={true}>