fix(dashboard): remover next/dynamic com ssr:false em Server Component; usar NewTicketDialogDeferred (client) como ação primária
This commit is contained in:
parent
9a65d935ce
commit
3814203de3
1 changed files with 2 additions and 10 deletions
|
|
@ -1,18 +1,10 @@
|
|||
import dynamic from "next/dynamic"
|
||||
import { AppShell } from "@/components/app-shell"
|
||||
import { SectionCards } from "@/components/section-cards"
|
||||
import { SiteHeader } from "@/components/site-header"
|
||||
import { RecentTicketsPanel } from "@/components/tickets/recent-tickets-panel"
|
||||
import { TicketQueueSummaryCards } from "@/components/tickets/ticket-queue-summary"
|
||||
import { ChartAreaInteractive } from "@/components/chart-area-interactive"
|
||||
|
||||
const NewTicketDialog = dynamic(
|
||||
() =>
|
||||
import("@/components/tickets/new-ticket-dialog").then((module) => ({
|
||||
default: module.NewTicketDialog,
|
||||
})),
|
||||
{ ssr: false }
|
||||
)
|
||||
import { NewTicketDialogDeferred } from "@/components/tickets/new-ticket-dialog.client"
|
||||
|
||||
export default function Dashboard() {
|
||||
return (
|
||||
|
|
@ -22,7 +14,7 @@ export default function Dashboard() {
|
|||
title="Central de operações"
|
||||
lead="Monitoramento em tempo real"
|
||||
secondaryAction={<SiteHeader.SecondaryButton>Modo play</SiteHeader.SecondaryButton>}
|
||||
primaryAction={<NewTicketDialog />}
|
||||
primaryAction={<NewTicketDialogDeferred />}
|
||||
/>
|
||||
}
|
||||
>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue