diff --git a/src/app/(main)/settings/SettingsLayout.tsx b/src/app/(main)/settings/SettingsLayout.tsx index 787d6c64c..5af26fa5a 100644 --- a/src/app/(main)/settings/SettingsLayout.tsx +++ b/src/app/(main)/settings/SettingsLayout.tsx @@ -1,10 +1,10 @@ 'use client'; +import { ReactNode } from 'react'; +import { Grid, Column } from '@umami/react-zen'; +import { useMessages, useNavigation } from '@/components/hooks'; import { PageBody } from '@/components/common/PageBody'; import { SideMenu } from '@/components/common/SideMenu'; -import { useMessages, useNavigation } from '@/components/hooks'; -import { Settings2, UserCircle, Users } from '@/components/icons'; -import { Column, Grid } from '@umami/react-zen'; -import { ReactNode } from 'react'; +import { UserCircle, Users, Settings2 } from '@/components/icons'; export function SettingsLayout({ children }: { children: ReactNode }) { const { formatMessage, labels } = useMessages(); @@ -46,15 +46,8 @@ export function SettingsLayout({ children }: { children: ReactNode }) { .find(({ path }) => path && pathname.includes(path.split('?')[0]))?.id; return ( - - + + }) { const { auth, error } = await parseRequest(request); @@ -41,7 +41,7 @@ export async function POST( return notFound(); } - if (!(await canUpdateWebsite(auth, websiteId))) { + if (!(await canUpdateReport(auth, report))) { return unauthorized(); } @@ -70,7 +70,7 @@ export async function DELETE( const { reportId } = await params; const report = await getReport(reportId); - if (!(await canDeleteWebsite(auth, report.websiteId))) { + if (!(await canDeleteReport(auth, report))) { return unauthorized(); } diff --git a/src/components/input/NavButton.tsx b/src/components/input/NavButton.tsx index b57c2ecdc..e1f7129d7 100644 --- a/src/components/input/NavButton.tsx +++ b/src/components/input/NavButton.tsx @@ -69,7 +69,7 @@ export function NavButton({ showText = true }: TeamsButtonProps) { shadow="1" maxHeight="40px" role="button" - style={{ cursor: 'pointer', textWrap: 'nowrap', overflow: 'hidden', outline: 'none' }} + style={{ cursor: 'pointer', textWrap: 'nowrap', outline: 'none' }} > {teamId ? : }