Fixed 'use client' usage.
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
'use client';
|
||||
import { useContext } from 'react';
|
||||
import { useFormat, useMessages, useFilters } from 'components/hooks';
|
||||
import {
|
||||
@@ -13,7 +12,7 @@ import {
|
||||
} from 'react-basics';
|
||||
import Icons from 'components/icons';
|
||||
import BaseParameters from '../[reportId]/BaseParameters';
|
||||
import { ReportContext } from '../[reportId]/Report';
|
||||
import { ReportContext } from '../[reportId]/ReportPage';
|
||||
import ParameterList from '../[reportId]/ParameterList';
|
||||
import FilterSelectForm from '../[reportId]/FilterSelectForm';
|
||||
import FieldSelectForm from '../[reportId]/FieldSelectForm';
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
'use client';
|
||||
import Report from '../[reportId]/Report';
|
||||
import ReportPage from '../[reportId]/ReportPage';
|
||||
import ReportHeader from '../[reportId]/ReportHeader';
|
||||
import ReportMenu from '../[reportId]/ReportMenu';
|
||||
import ReportBody from '../[reportId]/ReportBody';
|
||||
@@ -15,7 +14,7 @@ const defaultParameters = {
|
||||
|
||||
export default function InsightsReport({ reportId }: { reportId?: string }) {
|
||||
return (
|
||||
<Report reportId={reportId} defaultParameters={defaultParameters}>
|
||||
<ReportPage reportId={reportId} defaultParameters={defaultParameters}>
|
||||
<ReportHeader icon={<Lightbulb />} />
|
||||
<ReportMenu>
|
||||
<InsightsParameters />
|
||||
@@ -23,6 +22,6 @@ export default function InsightsReport({ reportId }: { reportId?: string }) {
|
||||
<ReportBody>
|
||||
<InsightsTable />
|
||||
</ReportBody>
|
||||
</Report>
|
||||
</ReportPage>
|
||||
);
|
||||
}
|
||||
|
||||
6
src/app/(main)/reports/insights/InsightsReportPage.tsx
Normal file
6
src/app/(main)/reports/insights/InsightsReportPage.tsx
Normal file
@@ -0,0 +1,6 @@
|
||||
'use client';
|
||||
import InsightsReport from './InsightsReport';
|
||||
|
||||
export default function InsightsReportPage() {
|
||||
return <InsightsReport />;
|
||||
}
|
||||
@@ -1,8 +1,7 @@
|
||||
'use client';
|
||||
import { useContext, useEffect, useState } from 'react';
|
||||
import { GridTable, GridColumn } from 'react-basics';
|
||||
import { useFormat, useMessages } from 'components/hooks';
|
||||
import { ReportContext } from '../[reportId]/Report';
|
||||
import { ReportContext } from '../[reportId]/ReportPage';
|
||||
import EmptyPlaceholder from 'components/common/EmptyPlaceholder';
|
||||
|
||||
export function InsightsTable() {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import InsightsReport from './InsightsReport';
|
||||
import InsightsReportPage from './InsightsReportPage';
|
||||
import { Metadata } from 'next';
|
||||
|
||||
export default function InsightsReportPage() {
|
||||
return <InsightsReport />;
|
||||
export default function () {
|
||||
return <InsightsReportPage />;
|
||||
}
|
||||
|
||||
export const metadata: Metadata = {
|
||||
|
||||
Reference in New Issue
Block a user